-
-
Notifications
You must be signed in to change notification settings - Fork 12k
DEP: Deprecate np.MachAr
#20201
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DEP: Deprecate np.MachAr
#20201
Conversation
|
Is there any use for |
There are a few In [11]: import numpy as np
In [12]: finfo_f8 = np.finfo(np.float64)
...: machar_f8 = np.MachAr(np.float64)
In [14]: set(dir(machar_f8)) - set(dir(finfo_f8))
Out[14]:
{'_do_init',
'_str_xmax',
'_str_xmin',
'epsilon',
'huge',
'ibeta',
'irnd',
'it',
'ngrd',
'title',
'xmax',
'xmin'} |
|
Hmm, fair point. On some of these, I would be willing to just gamble that nobody uses them anyway, i.e. |
|
Ah well, let's give deprecating |
|
Thanks Bas. |
This PR deprecates the
np.MachArclass, the matchingnp.core.macharmodule andnp.finfo.macharattribute.As an alternative it is recommended to use to directly grab the property of interest from the
np.finfoinstance.Note that the module is technically private, but with the lack of underscores it's better to be safe than sorry.