Unable to install caffe

别说谁变了你拦得住时间么 提交于 2019-12-08 11:44:27

问题


I am new to caffe. I am trying to install it in Ubuntu 14.04 which is running as a dual boot on my macbook pro. I managed to get it running initially but soon after my laptop crashed, following which I have the same error "No module named caffe" I have followed the instructions to the letter and it seems to be an issue with opencv. I get an error message while compiling caffe which I have copied below.

/usr/bin/ld: cannot find -lopencv_imgcodecs collect2: error: ld
returned 1 exit status make: ***
[.build_release/lib/libcaffe.so.1.0.0-rc3] Error 1

This leads me to believe there is something wrong with my OpenCV installation? Would really appreciate some help!


回答1:


If you are using anaconda install OpenCV 3 with this:

conda install -c menpo opencv3=3.2.0

Or if you are using homebrew

brew install opencv3



回答2:


Check the installation guide

When compiling with OpenCV 3.0 or errors show imread,imencode,imdecode or VideoCapture open your Makefile with some text editor, add opencv_imgcodecs behind.

LIBRARIES += glog gflags protobuf leveldb snappy \ lmdb boost_system boost_filesystem hdf5_hl hdf5 m \ opencv_core opencv_highgui opencv_imgproc opencv_imgcodecs opencv_videoio

(See the discussion at: https://github.com/BVLC/caffe/issues/1276)



来源:https://stackoverflow.com/questions/37741072/unable-to-install-caffe

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!