我为python2.7创建了一个虚拟环境,并使用 conda install -c conda-forge caffe 命令安装了caffe。但是,当我尝试导入caffe时,它会引发以下错误。
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/data/home/eex608/.conda/envs/MyPython2.7Caffe/lib/python2.7/site-packages/caffe/__init__.py", line 1, in <module>
from .pycaffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, RMSPropSolver, AdaDeltaSolver, AdamSolver, NCCL, Timer
File "/data/home/eex608/.conda/envs/MyPython2.7Caffe/lib/python2.7/site-packages/caffe/pycaffe.py", line 13, in <module>
from ._caffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, \
ImportError: libopencv_highgui.so.3.3: cannot open shared object file: No such file or directory
有人可以告诉我如何解决此错误吗?
我安装了caffe之后的软件包信息(如果此信息对调试有用)
2018-10-08 23:07:03 (rev 1)
anaconda {5.3.0 -> custom}
blas {1.0 -> 1.1 (conda-forge)}
ca-certificates {2018.03.07 -> 2018.8.24 (conda-forge)}
certifi {2018.8.24 -> 2018.8.24 (conda-forge)}
h5py {2.8.0 -> 2.8.0 (conda-forge)}
harfbuzz {1.8.8 -> 1.7.6}
hdf5 {1.10.2 -> 1.10.1 (conda-forge)}
matplotlib {2.2.3 -> 2.2.3 (conda-forge)}
mkl-service {1.1.2 -> 1.1.2}
mkl_fft {1.0.4 -> 1.0.6 (conda-forge)}
mkl_random {1.0.1 -> 1.0.1 (conda-forge)}
numexpr {2.6.8 -> 2.6.6 (conda-forge)}
numpy {1.15.1 -> 1.15.2 (conda-forge)}
numpy-base {1.15.1 -> 1.15.2}
openssl {1.0.2p -> 1.0.2p (conda-forge)}
pyqt {5.9.2 -> 5.6.0}
pytables {3.4.4 -> 3.4.4 (conda-forge)}
qt {5.9.6 -> 5.6.3}
qtconsole {4.4.1 -> 4.4.1 (conda-forge)}
scikit-learn {0.19.2 -> 0.20.0 (conda-forge)}
scipy {1.1.0 -> 1.1.0 (conda-forge)}
+boost-1.66.0 (conda-forge)
+boost-cpp-1.66.0 (conda-forge)
+caffe-1.0 (conda-forge)
+ffmpeg-3.2.4 (conda-forge)
+gflags-2.2.1 (conda-forge)
+giflib-5.1.4 (conda-forge)
+glog-0.3.5 (conda-forge)
+jasper-1.900.1 (conda-forge)
+leveldb-1.18 (conda-forge)
+libgcc-7.2.0 (conda-forge)
+libgfortran-3.0.0 (conda-forge)
+libiconv-1.15 (conda-forge)
+libopenblas-0.3.3
+libprotobuf-3.5.2 (conda-forge)
+libwebp-0.5.2 (conda-forge)
+lmdb-0.9.22 (conda-forge)
+openblas-0.2.20 (conda-forge)
+opencv-3.4.1 (conda-forge)
+protobuf-3.5.2 (conda-forge)
+python-gflags-3.1.2 (conda-forge)
+python-leveldb-0.193 (conda-forge)
+x264-1!152.20180717 (conda-forge)