-
Notifications
You must be signed in to change notification settings - Fork 542
Update documentation for numpy >=1.9 #424
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
Comments
That is a good point -- I didn't realize that #404 made numpy 1.9 a requirement, so we should reflect that in our docs. I currently am on Ubuntu 14.10 with both the python-numpy package installed as well as numpy from pip. The former goes to /usr/lib/... and the latter goes to /usr/local/lib/.... By default, the Python interpreter picks up the latter first. What makes you say that the apt version must be removed before installing a pip version? |
Well for some reason, the apt-get NumPy was always chosen over the pip
|
That's odd. What does |
Closed per #425 |
I recently started using OpenMC again for the first time in a month. In the process, I've learned that PR #404 made
numpy
versions >=1.9 a new requirement to use the Python API. The reason is that thenumpy
types (e.g., numpy.int32, numpy.float64, etc.) only register themselves as Pythonnumbers.Integral
andnumbers.Real
datatypes starting in version 1.9 (link). Many of thecheck_type(...)
calls in the Python API look for types ofIntegral
andReal
in places where anumpy
datatype is in use (i.e., any downstream data processing from an HDF5 statepoint file). If an older version ofnumpy
is installed, these type checks will fail since thenumpy
datatype(s) will not appear asIntegral
orReal
.Of course it would appear that the quick and easy fix is to install
numpy
1.9. The default version of numpy installed with theapt-get
package manager in Ubuntu 14.10 is 1.8.2, but 1.9 can be (somewhat less easily) installed withpip
. However, one must first remove the older version of numpy installed withapt-get
(or any other package manager), which also happens to remove any versions ofscipy
,matplotlib
andh5py
installed withapt-get
. Any attempt to re-install one of these withapt-get
requires one to first blacklist the oldpython-numpy
package sinceapt-get
will attempt to install it alongside all of these three packages. The alternative I took is to install all three of these packages usingpip
which is slightly more painful since it required installing some unmet dependencies myself (i.e., libhd5f).Have any others run into this issue lately? I don't think that this is cause to change the Python API back to checking for explicit
numpy
datatypes, but I do think this should be reflected in the installation docs.The text was updated successfully, but these errors were encountered: