Install h5py on OS X

I spent this day trying to get the python h5py module to work, but to no avail. I installed the HDF5 shared libraries following the instructions I can find on the Internet to get it right. But this does not work, an error message appears below that I am trying to import into python. I tried installing through MacPorts, but again it did not work.

I am using Python27 32 bit (also for another module and thus installed the i386 HDF5 library ... if so?)

Any help is greatly appreciated!

Thanks!

 import h5py Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/h5py/__init__.py", line 1, in <module> from h5py import _errors ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/h5py/_errors.so, 2): Symbol not found: _H5E_ALREADYEXISTS_g Referenced from: /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/h5py/_errors.so Expected in: flat namespace in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/h5py/_errors.so 
+6
source share
2 answers

Make sure you are not in the h5py installation directory.

+10
source

My advice, if possible, is to install h5py using Anaconda's Open Data Science Core Distribution.

0
source

Source: https://habr.com/ru/post/894581/


All Articles