lmb-freiburg / flownet2

FlowNet 2.0: Evolution of Optical Flow Estimation with Deep Networks
https://lmb.informatik.uni-freiburg.de/Publications/2017/IMKDB17/
Other
1k stars 318 forks source link

Error while compiling Caffe #63

Closed letatanu closed 7 years ago

letatanu commented 7 years ago

I got this issue when compiling Caffe. I did some researches and found nothing. Can anyone help me?

CXX .build_release/src/caffe/proto/caffe.pb.cc tools/convert_imageset_and_flow.cpp:5:1: warning: multi-line comment [-Wcomment] // convert_imageset [-g] ROOTFOLDER/ LISTFILE DB_NAME RANDOM_SHUFFLE[0 or 1] \ ^ tools/convert_imageset_and_flow.cpp: In function ‘int main(int, char**)’: tools/convert_imageset_and_flow.cpp:398:7: warning: variable ‘data_size’ set but not used [-Wunused-but-set-variable] int data_size; ^ tools/convert_imageset_and_flow.cpp:448:16: warning: ‘batch’ may be used uninitialized in this function [-Wmaybe-uninitialized] delete batch; ^ AR -o .build_release/lib/libcaffe.a LD -o .build_release/lib/libcaffe.so.1.0.0-rc3 /usr/bin/ld: cannot find -lhdf5_hl /usr/bin/ld: cannot find -lhdf5 collect2: error: ld returned 1 exit status Makefile:567: recipe for target '.build_release/lib/libcaffe.so.1.0.0-rc3' failed make: *** [.build_release/lib/libcaffe.so.1.0.0-rc3] Error 1

Thank you.

nikolausmayer commented 7 years ago

You are missing HDF5 libraries. Either they are not installed or the linker is looking in the wrong folder. Remake with VERBOSE=1 make to see any special linker locations (-L). Look for the files yourself: locate libhdf5.so.

letatanu commented 7 years ago

Thank you. I added the path of libhdf5 to Makefile.config and it worked. The path is:

INCLUDE_DIRS := $(PYTHON_INCLUDE) /home/'user name'/anaconda3/lib/ /usr/include/hdf5/serial/

LIBRARY_DIRS := $(PYTHON_LIB) /home/'user name'/anaconda3/lib/ /usr/lib/x86_64-linux-gnu/hdf5/serial/