[英]Using pytables with python3 fails
importing pytables (3.1.1) in python 3.4.1 fails for me, complaining about a failed cPickle import i try to use potables (3.1.1) with python (3.4.1) 对我来说,在python 3.4.1中导入pytables(3.1.1)失败,我抱怨cPickle导入失败,我尝试在python(3.4.1)中使用便携式(3.1.1)
In [1]: import tables
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-1-389ecae14f10> in <module>()
----> 1 import tables
/work/projects/vEnv/lib/python3.4/site-packages/tables/__init__.py in <module>()
80
81 # Necessary imports to get versions stored on the cython extension
---> 82 from tables.utilsextension import (
83 get_pytables_version, get_hdf5_version, blosc_compressor_list,
84 blosc_compcode_to_compname_ as blosc_compcode_to_compname,
/work/projects/vEnv/lib/python3.4/site-packages/tables/utilsextension.pyx in init tables.utilsextension (tables/utilsextension.c:15600)()
/work/projects/vEnv/lib/python3.4/site-packages/tables/description.py in <module>()
22 import numpy
23
---> 24 from tables import atom
25 from tables.path import check_name_validity
26
/work/projects/vEnv/lib/python3.4/site-packages/tables/atom.py in <module>()
18 import sys
19 import inspect
---> 20 import cPickle
21
22 import numpy
As i understand cPickle is only used instead of pickle in python2. 据我了解,cPickle仅用于代替python2中的泡菜。 As of PyTable 3.x it should work fine with python3.x.
从PyTable 3.x开始,它应该可以在python3.x上正常工作。 How can there be a cPickle import than?
怎么会有cPickle导入呢?
What do i have to do to use pytables with python3? 使用pytables和python3我该怎么办?
The error was produced most likely due to a problem with my vEnv. 由于我的vEnv出现问题,很可能产生了该错误。 Uninstalling the package and reinstalling it fix the problem.
卸载软件包并重新安装可以解决该问题。
See github issue 见github问题
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.