警告!***HDF5 库版本不匹配错误*** python pandas windows
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/45411700/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Warning! ***HDF5 library version mismatched error*** python pandas windows
提问by oso_ted
I'm using pandas/python to save a DataFrame in a HDFStore format. When I apply the my_data_frame.to_hdf(arguments...)command I have an error message:Warning! ***HDF5 library version mismatched error*** and my program is stopped.
我正在使用 pandas/python 以 HDFStore 格式保存 DataFrame。当我应用my_data_frame.to_hdf(arguments...)命令时,我收到一条错误消息:警告!*** HDF5 库版本不匹配错误*** 并且我的程序已停止。
I'm working on Windows 7 (64bits), using Python 3.5.2 :: Anaconda 4.1.1 (64-bit).
我正在 Windows 7(64 位)上工作,使用 Python 3.5.2 :: Anaconda 4.1.1(64 位)。
I've been reading about this error message and as it says it's a problem between the version of HDF5 installed on my computer and the one used by Anacondas. According thispost, a simple "conda install -c anaconda hdf5=1.8.18"could resolve my problem but I'm still having the same message error.
我一直在阅读有关此错误消息的信息,因为它说这是我计算机上安装的 HDF5 版本与 Anacondas 使用的版本之间的问题。根据这篇文章,一个简单的“conda install -c anaconda hdf5=1.8.18”可以解决我的问题,但我仍然遇到相同的消息错误。
Thanks for your help guys.
谢谢你们的帮助。
Here I put a complete log of the error:
这里我放了一个完整的错误日志:
Warning! ***HDF5 library version mismatched error*** The HDF5 header files used to compile this application do not match the version used by the HDF5 library to which this application is linked. Data corruption or segmentation faults may occur if the application continues. This can happen when an application was compiled by one version of HDF5 but linked with a different version of static or shared HDF5 library. You should recompile the application or check your shared library related settings such as 'LD_LIBRARY_PATH'. You can, at your own risk, disable this warning by setting the environment variable 'HDF5_DISABLE_VERSION_CHECK' to a value of '1'. Setting it to 2 or higher will suppress the warning messages totally. Headers are 1.8.15, library is 1.8.18 SUMMARY OF THE HDF5 CONFIGURATION ================================= General Information: ------------------- HDF5 Version: 1.8.18 Configured on: 2017-05-31 Configured by: NMake Makefiles Configure mode: CMAKE 3.8.0 Host system: Windows-6.3.9600 Uname information: Windows Byte sex: little-endian Libraries: Installation point: C:/bld/hdf5_1496269860661/_b_env/Library Compiling Options: ------------------ Compilation Mode: RELEASE C Compiler: C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/amd64/cl.exe CFLAGS: /DWIN32 /D_WINDOWS /W3 H5_CFLAGS: AM_CFLAGS: CPPFLAGS: H5_CPPFLAGS: AM_CPPFLAGS: Shared C Library: YES Static C Library: YES Statically Linked Executables: OFF LDFLAGS: /machine:x64 AM_LDFLAGS: Extra libraries: C:/bld/hdf5_1496269860661/_b_env/Library/lib/z. lib Archiver: Ranlib: Debugged Packages: API Tracing: OFF Languages: ---------- Fortran: OFF Fortran Compiler: Fortran 2003 Compiler: Fortran Flags: H5 Fortran Flags: AM Fortran Flags: Shared Fortran Library: YES Static Fortran Library: YES C++: ON C++ Compiler: C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/amd64/cl.exe C++ Flags: /DWIN32 /D_WINDOWS /W3 /GR /EHsc H5 C++ Flags: AM C++ Flags: Shared C++ Library: YES Static C++ Library: YES Features: --------- Parallel HDF5: OFF High Level library: ON Threadsafety: ON Default API Mapping: v18 With Deprecated Public Symbols: ON I/O filters (external): DEFLATE MPE: Direct VFD: dmalloc: Clear file buffers before write: ON Using memory checker: OFF Function Stack Tracing: OFF Strict File Format Checks: OFF Optimization Instrumentation:
回答by youDaily
Headers are 1.8.15, library is 1.8.18
Your error information shown this, so you need install the 1.8.15
version.
您的错误信息显示了这一点,因此您需要安装该1.8.15
版本。
conda install -c anaconda hdf5=1.8.15
回答by John Gherga
This fixed it for me, hope it helps.
这为我修复了它,希望它有所帮助。
Step one
步骤1
pip uninstall h5py
pip uninstall h5py
Step two
第二步
pip install h5py
pip install h5py
回答by jtlz2
The only procedure that worked for me on macOS was to create a virtualenv:
在 macOS 上对我有用的唯一程序是创建一个 virtualenv:
virtualenv -p python3 myenv
. myenv/bin/activate
pip3 install h5py==1.10.4 #?or whichever version you want
Absolutely nothing else worked!
绝对没有其他工作!
You may need a brew install hdf5
你可能需要一个 brew install hdf5
github issue that did not help:
没有帮助的 github 问题:
回答by Ehsan Jelodar
also you can force to install custom package version:
您也可以强制安装自定义软件包版本:
conda install --force-reinstall anaconda hdf5==1.8.15
or
或者
conda install -c conda-forge hdf5=1.8.15
回答by Brooke Polak
In case someone is having this problem and no amount of uninstalling with pip
or conda
or anything will work: I went through every /lib
path and manually deleted libhdf5*
files, then installed hdf5
with macports
.
如果有人遇到此问题并且使用pip
或conda
或任何东西进行卸载都无效:我遍历了每个/lib
路径并手动删除了libhdf5*
文件,然后hdf5
使用macports
.