-
Notifications
You must be signed in to change notification settings - Fork 18.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make runtest failure #2320
Comments
I have exactly the same problem on my MacBookPro OS 10.10, CUDA 7.0. Any help will be much appreciated, thanks! output from "env | grep LIB": |
Follow the installation instructions and ask installation questions on the caffe-users group. You should not set |
This is bit old I guess. And I shouldn't be spamming with install advice but I just had the same problem. At the caffe user forum https://groups.google.com/forum/#!msg/caffe-users/BkMspfbYLIE/Pi6SUVANAKUJ someone said fix the
This worked for me. |
set DYLD_FALLBACK_LIBRARY_PATH solved my problem too |
I've set my and I still get
|
I have the exactly the same issue. I also already set DYLD_LIBRARY_PATH My version is also CUDA7.5. I think when I used CUDA7.0 before, everything is fine. |
Caffe seems to be linking in a pretty funny way ... If I run
I see something like this
So some library paths are static, others are run-time paths and others are just assumed to be in the executable path (which they aren't). Unfortunately, in my case at least there are not rpath's set for either the executables or the libcaffe :( Just check `otool -l .build_release/tools/caffe | grep RPATH' If you need a quick and dirty fix, you can add your CUDA path as an rpath
With that I can run |
If you are installing on OS X El Capitan, DYLD_FALLBACK_LIBRARY_PATH is cleared by the new System Integrity Protection feature of El Capitan: make runtest completed successfully after I disabled System Integrity Protection. |
@cecilpang Thanks for your tips and it really helps. here is the steps to disable Integrity Protection:
|
@a7744hsc @cecilpang Your solutions resolved my problem. Thanks! |
@jiajunshen Very glad to hear that |
Worked... but so annoying! And now what about my system's integrity? Will I ever be able to trust it again? |
Before you run 'make runtest', do 'make clean' once. |
@a7744hsc @cecilpang Your solutions resolved my problem too. Many thanks! |
Shouldn't this maybe be reopened, since there is no good fix for this? |
Please refer #3227 for a workaround without disabling Integrity protection on OSX 10.11. |
What should be the fix if there is no cuda gpu? |
Mac OS 10.9, CUDA 7.0
Make all and Make test ran without errors, except some warning about unused -pthread and 1 warning in test. But $make runtest gives segmentation fault. $make sudo runtest gives the error-
.build_release/tools/caffe
dyld: Library not loaded: @rpath/libcudart.7.0.dylib
Referenced from: /Users/deepsamal/Desktop/Research/caffe/.build_release/tools/caffe
Reason: image not found
make: *** [runtest] Trace/BPT trap: 5
Seems a problem with dynamic loading of the cuda library path.
checking the links of libcaffe.so, the paths to cuda libs are not resolved. But the libraries are present both in /usr/local/cuda/lib and in /Developer/NVIDIA.... folders.
Deep-Samals-MacBook-Pro:caffe deepsamal$ otool -L ~/Desktop/Research/caffe/build/lib/libcaffe.so
/Users/deepsamal/Desktop/Research/caffe/build/lib/libcaffe.so:
@rpath/libcaffe.so (compatibility version 0.0.0, current version 0.0.0)
@rpath/libcudart.7.0.dylib (compatibility version 0.0.0, current version 7.0.29)
@rpath/libcublas.7.0.dylib (compatibility version 0.0.0, current version 7.0.29)
@rpath/libcurand.7.0.dylib (compatibility version 0.0.0, current version 7.0.29)
/usr/local/lib/libglog.0.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/local/lib/libprotobuf.9.dylib (compatibility version 10.0.0, current version 10.1.0)
/usr/local/lib/libleveldb.1.dylib (compatibility version 0.0.0, current version 0.0.0)
/usr/local/lib/libsnappy.1.dylib (compatibility version 4.0.0, current version 4.0.0)
/usr/local/lib/liblmdb.dylib (compatibility version 0.0.0, current version 0.0.0)
/usr/local/lib/libboost_system.dylib (compatibility version 0.0.0, current version 0.0.0)
libhdf5_hl.9.dylib (compatibility version 10.0.0, current version 10.0.0)
libhdf5.9.dylib (compatibility version 10.0.0, current version 10.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)
/usr/local/opt/opencv/lib/libopencv_core.2.4.dylib (compatibility version 2.4.0, current version 2.4.11)
/usr/local/opt/opencv/lib/libopencv_highgui.2.4.dylib (compatibility version 2.4.0, current version 2.4.11)
/usr/local/opt/opencv/lib/libopencv_imgproc.2.4.dylib (compatibility version 2.4.0, current version 2.4.11)
/usr/local/lib/libboost_thread-mt.dylib (compatibility version 0.0.0, current version 0.0.0)
@rpath/libcudnn.6.5.dylib (compatibility version 0.0.0, current version 6.5.48)
/usr/local/lib/libboost_python.dylib (compatibility version 0.0.0, current version 0.0.0)
libpython2.7.dylib (compatibility version 2.7.0, current version 2.7.0)
libmkl_rt.dylib (compatibility version 0.0.0, current version 0.0.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.0.0)
Also I looked at links of the libcudart library-
$ otool -L /usr/local/cuda/lib/libcudart.7.0.dylib
/usr/local/cuda/lib/libcudart.7.0.dylib:
@rpath/libcudart.7.0.dylib (compatibility version 0.0.0, current version 7.0.29)
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 855.17.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)
In both the outputs, library links seem to be broken. But make all and test are fine, this means dynamic linking is okay, loading is not?
May be the problem is environment variable related, my variables are-
$ echo $DYLD_FALLBACK_LIBRARY_PATH
/usr/local/cuda/lib:/Developer/NVIDIA/CUDA-7.0/lib:/Users/deepsamal/anaconda/lib:/usr/local/lib:/usr/lib:/opt/intel/composer_xe_2015.2.132/mkl/lib/:/opt/intel/composer_xe_2015.2.132/compiler/lib
$ echo $DYLD_LIBRARY_PATH
/usr/local/cuda/lib
$ echo $LD_LIBRARY_PATH
/usr/local/cuda/lib:/opt/intel/composer_xe_2015.2.132/mkl/lib/
$ ECHO $PATH
/Developer/NVIDIA/CUDA-7.0/bin:/Users/deepsamal/anaconda/bin:/Applications/MATLAB_R2014a.app/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/git/bin
All advised paths are included, in fact, I even tried without setting LD_LIBRARY_PATH, same error. Any idea what might be the cause?
The text was updated successfully, but these errors were encountered: