-
Notifications
You must be signed in to change notification settings - Fork 61
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
M1 Mac install fails due to numba #189
Comments
It looks like that you are using python3.10. Numba guys are working on the fix of python3.10 and new numpy version. I think it would be easier to just keep it for a while. They should be able to catch up soon. I have no problem with python3.7-3.9 Regarding the option of putting Numba as a extra library, I tried it but I failed. Something like the following won't work @requires(nb is not None, "numba not imported! Please install numba.")
@nb.njit(nb.f8[:](nb.f8[:], nb.f8, nb.f8, nb.f8, nb.f8, nb.i8), cache = True)
def mod_pseudo_voigt(x, fwhm, A, eta_h, eta_l, N): I don't know how to deal with this. So I will simply disable the pip install via python3.10. However, you can do |
I guess we can convert this issue into a tracker for when the py3.10 wheel becomes available then. |
Did you try this? @requires(nb is not None, "numba could not be imported! Please install numba.")
def _mod_pseudo_voigt(x, fwhm, A, eta_h, eta_l, N):
...
if nb is not None:
mod_pseudo_voigt = nb.njit(
nb.f8[:](nb.f8[:], nb.f8, nb.f8, nb.f8, nb.f8, nb.i8), cache = True
)(_mod_pseudo_voigt) |
@qzhu2017 Any update on this issue? |
pip install pyxtal
fails on M1 Macs due tonumba
not yet publishing anarm64
wheel to PyPI.Looks like they're working on that in numba/numba#7779.
In the meantime though, perhaps it would make sense to turn
numba
from a regular dependency to anextras_require
since it's only used by a single function inpyxtal
:PyXtal/pyxtal/XRD.py
Lines 613 to 619 in 9a17834
pymatgen
for instance does that with many of its optional dependencies through thefrom monty.dev import requires
decorator which informs users what install command to run once they try to use the functionality that actually requires it. See e.g. here:https://github.com/materialsproject/pymatgen/blob/07794afb624f7613b3dbcebdf0034cab4c9ee7ea/pymatgen/electronic_structure/plotter.py#L3893-L3899
pip install logs
The text was updated successfully, but these errors were encountered: