制作pycaffe - > "致命错误:cublas_v2.h:没有这样的文件或目录"

时间:2015-07-10 15:57:20

标签: python neural-network deep-learning caffe

我编译了caffe,我知道要编译pycaffe。当我在make pycaffe根文件夹中运行caffe时,我得到:

f@f-VirtualBox:~/caffe/caffe-master$ make pycaffe
CXX src/caffe/layer_factory.cpp
In file included from ./include/caffe/common.hpp:19:0,
                 from ./include/caffe/blob.hpp:8,
                 from ./include/caffe/layer.hpp:8,
                 from src/caffe/layer_factory.cpp:3:
./include/caffe/util/device_alternate.hpp:34:23: fatal error: 
 cublas_v2.h: No such file or directory
 #include <cublas_v2.h>
                       ^
compilation terminated.
Makefile:516: recipe for target '.build_release/src/caffe/layer_factory.o' failed
make: *** [.build_release/src/caffe/layer_factory.o] Error 1

如何解决这个问题?

1 个答案:

答案 0 :(得分:2)

如果您不打算使用GPU,可以通过在Makefile.config中取消注释CPU_ONLY := 1来解决问题:

# CPU-only switch (uncomment to build without GPU support).
CPU_ONLY := 1