BVLC / caffe

Caffe: a fast open framework for deep learning.
http://caffe.berkeleyvision.org/
Other
34.13k stars 18.68k forks source link

`make all ` error #6956

Open zongoalbert opened 4 years ago

zongoalbert commented 4 years ago

when i tap the command line make all i foind this error , please i need your help .

(zack) bpros@bpros-HP-ZBook-17-G6:~/Documents/caffe$ make all 
PROTOC src/caffe/proto/caffe.proto
NVCC src/caffe/solvers/sgd_solver.cu
NVCC src/caffe/solvers/nesterov_solver.cu
NVCC src/caffe/solvers/adagrad_solver.cu
NVCC src/caffe/solvers/adadelta_solver.cu
NVCC src/caffe/solvers/adam_solver.cu
NVCC src/caffe/layers/inner_product_layer.cu
NVCC src/caffe/layers/cudnn_conv_layer.cu
NVCC src/caffe/layers/softmax_loss_layer.cu
NVCC src/caffe/layers/batch_reindex_layer.cu
NVCC src/caffe/layers/cudnn_lrn_layer.cu
NVCC src/caffe/layers/cudnn_relu_layer.cu
NVCC src/caffe/layers/cudnn_softmax_layer.cu
NVCC src/caffe/layers/absval_layer.cu
NVCC src/caffe/layers/exp_layer.cu
NVCC src/caffe/layers/silence_layer.cu
NVCC src/caffe/layers/split_layer.cu
NVCC src/caffe/layers/bnll_layer.cu
NVCC src/caffe/layers/relu_layer.cu
NVCC src/caffe/layers/cudnn_sigmoid_layer.cu
NVCC src/caffe/layers/concat_layer.cu
NVCC src/caffe/layers/crop_layer.cu
NVCC src/caffe/layers/hdf5_data_layer.cu
NVCC src/caffe/layers/im2col_layer.cu
NVCC src/caffe/layers/elu_layer.cu
NVCC src/caffe/layers/recurrent_layer.cu
NVCC src/caffe/layers/tanh_layer.cu
NVCC src/caffe/layers/scale_layer.cu
NVCC src/caffe/layers/deconv_layer.cu
NVCC src/caffe/layers/power_layer.cu
NVCC src/caffe/layers/threshold_layer.cu
NVCC src/caffe/layers/slice_layer.cu
NVCC src/caffe/layers/mvn_layer.cu
NVCC src/caffe/layers/lstm_unit_layer.cu
NVCC src/caffe/layers/embed_layer.cu
NVCC src/caffe/layers/sigmoid_cross_entropy_loss_layer.cu
NVCC src/caffe/layers/lrn_layer.cu
NVCC src/caffe/layers/conv_layer.cu
NVCC src/caffe/layers/log_layer.cu
NVCC src/caffe/layers/hdf5_output_layer.cu
NVCC src/caffe/layers/swish_layer.cu
NVCC src/caffe/layers/pooling_layer.cu
NVCC src/caffe/layers/reduction_layer.cu
NVCC src/caffe/layers/contrastive_loss_layer.cu
NVCC src/caffe/layers/euclidean_loss_layer.cu
NVCC src/caffe/layers/cudnn_tanh_layer.cu
NVCC src/caffe/layers/batch_norm_layer.cu
NVCC src/caffe/layers/tile_layer.cu
NVCC src/caffe/layers/softmax_layer.cu
NVCC src/caffe/layers/sigmoid_layer.cu
NVCC src/caffe/layers/prelu_layer.cu
NVCC src/caffe/layers/base_data_layer.cu
NVCC src/caffe/layers/dropout_layer.cu
NVCC src/caffe/layers/cudnn_lcn_layer.cu
NVCC src/caffe/layers/eltwise_layer.cu
NVCC src/caffe/layers/cudnn_deconv_layer.cu
NVCC src/caffe/layers/bias_layer.cu
NVCC src/caffe/layers/cudnn_pooling_layer.cu
NVCC src/caffe/layers/accuracy_layer.cu
NVCC src/caffe/layers/clip_layer.cu
NVCC src/caffe/layers/filter_layer.cu
CXX tools/upgrade_solver_proto_text.cpp
CXX tools/convert_imageset.cpp
CXX tools/upgrade_net_proto_text.cpp
CXX tools/extract_features.cpp
CXX tools/compute_image_mean.cpp
CXX tools/upgrade_net_proto_binary.cpp
CXX tools/caffe.cpp
CXX examples/mnist/convert_mnist_data.cpp
CXX examples/cifar10/convert_cifar_data.cpp
CXX examples/cpp_classification/classification.cpp
CXX examples/siamese/convert_mnist_siamese_data.cpp
CXX .build_release/src/caffe/proto/caffe.pb.cc
CXX src/caffe/util/db_lmdb.cpp
CXX src/caffe/util/blocking_queue.cpp
CXX src/caffe/util/im2col.cpp
CXX src/caffe/util/math_functions.cpp
CXX src/caffe/util/db.cpp
CXX src/caffe/util/hdf5.cpp
CXX src/caffe/util/insert_splits.cpp
CXX src/caffe/util/db_leveldb.cpp
CXX src/caffe/util/benchmark.cpp
CXX src/caffe/util/io.cpp
CXX src/caffe/util/signal_handler.cpp
CXX src/caffe/util/upgrade_proto.cpp
CXX src/caffe/util/cudnn.cpp
CXX src/caffe/blob.cpp
CXX src/caffe/parallel.cpp
CXX src/caffe/data_transformer.cpp
CXX src/caffe/layer.cpp
CXX src/caffe/internal_thread.cpp
CXX src/caffe/net.cpp
CXX src/caffe/solvers/adam_solver.cpp
CXX src/caffe/solvers/sgd_solver.cpp
CXX src/caffe/solvers/rmsprop_solver.cpp
CXX src/caffe/solvers/adadelta_solver.cpp
CXX src/caffe/solvers/nesterov_solver.cpp
CXX src/caffe/solvers/adagrad_solver.cpp
CXX src/caffe/layer_factory.cpp
CXX src/caffe/layers/window_data_layer.cpp
CXX src/caffe/layers/cudnn_deconv_layer.cpp
CXX src/caffe/layers/pooling_layer.cpp
CXX src/caffe/layers/silence_layer.cpp
CXX src/caffe/layers/euclidean_loss_layer.cpp
CXX src/caffe/layers/hinge_loss_layer.cpp
CXX src/caffe/layers/mvn_layer.cpp
CXX src/caffe/layers/inner_product_layer.cpp
CXX src/caffe/layers/loss_layer.cpp
CXX src/caffe/layers/data_layer.cpp
CXX src/caffe/layers/dropout_layer.cpp
CXX src/caffe/layers/sigmoid_layer.cpp
CXX src/caffe/layers/hdf5_output_layer.cpp
CXX src/caffe/layers/im2col_layer.cpp
CXX src/caffe/layers/prelu_layer.cpp
CXX src/caffe/layers/reduction_layer.cpp
CXX src/caffe/layers/cudnn_lcn_layer.cpp
CXX src/caffe/layers/lstm_unit_layer.cpp
CXX src/caffe/layers/tile_layer.cpp
CXX src/caffe/layers/batch_reindex_layer.cpp
CXX src/caffe/layers/log_layer.cpp
CXX src/caffe/layers/batch_norm_layer.cpp
CXX src/caffe/layers/sigmoid_cross_entropy_loss_layer.cpp
CXX src/caffe/layers/base_data_layer.cpp
CXX src/caffe/layers/accuracy_layer.cpp
CXX src/caffe/layers/scale_layer.cpp
CXX src/caffe/layers/cudnn_relu_layer.cpp
CXX src/caffe/layers/absval_layer.cpp
CXX src/caffe/layers/clip_layer.cpp
CXX src/caffe/layers/rnn_layer.cpp
CXX src/caffe/layers/cudnn_pooling_layer.cpp
CXX src/caffe/layers/cudnn_tanh_layer.cpp
CXX src/caffe/layers/power_layer.cpp
CXX src/caffe/layers/eltwise_layer.cpp
CXX src/caffe/layers/recurrent_layer.cpp
CXX src/caffe/layers/deconv_layer.cpp
CXX src/caffe/layers/embed_layer.cpp
CXX src/caffe/layers/image_data_layer.cpp
CXX src/caffe/layers/relu_layer.cpp
CXX src/caffe/layers/lstm_layer.cpp
CXX src/caffe/layers/split_layer.cpp
CXX src/caffe/layers/flatten_layer.cpp
CXX src/caffe/layers/concat_layer.cpp
CXX src/caffe/layers/input_layer.cpp
CXX src/caffe/layers/swish_layer.cpp
CXX src/caffe/layers/threshold_layer.cpp
CXX src/caffe/layers/memory_data_layer.cpp
CXX src/caffe/layers/infogain_loss_layer.cpp
CXX src/caffe/layers/lrn_layer.cpp
CXX src/caffe/layers/parameter_layer.cpp
CXX src/caffe/layers/cudnn_softmax_layer.cpp
CXX src/caffe/layers/cudnn_conv_layer.cpp
CXX src/caffe/layers/filter_layer.cpp
CXX src/caffe/layers/multinomial_logistic_loss_layer.cpp
CXX src/caffe/layers/contrastive_loss_layer.cpp
CXX src/caffe/layers/elu_layer.cpp
CXX src/caffe/layers/cudnn_sigmoid_layer.cpp
CXX src/caffe/layers/neuron_layer.cpp
CXX src/caffe/layers/argmax_layer.cpp
CXX src/caffe/layers/slice_layer.cpp
CXX src/caffe/layers/reshape_layer.cpp
CXX src/caffe/layers/crop_layer.cpp
CXX src/caffe/layers/bias_layer.cpp
CXX src/caffe/layers/exp_layer.cpp
CXX src/caffe/layers/softmax_loss_layer.cpp
CXX src/caffe/layers/conv_layer.cpp
CXX src/caffe/layers/tanh_layer.cpp
CXX src/caffe/layers/spp_layer.cpp
CXX src/caffe/layers/bnll_layer.cpp
CXX src/caffe/layers/cudnn_lrn_layer.cpp
CXX src/caffe/layers/base_conv_layer.cpp
CXX src/caffe/layers/softmax_layer.cpp
CXX src/caffe/layers/hdf5_data_layer.cpp
CXX src/caffe/layers/dummy_data_layer.cpp
CXX src/caffe/common.cpp
CXX src/caffe/syncedmem.cpp
CXX src/caffe/solver.cpp
AR -o .build_release/lib/libcaffe.a
LD -o .build_release/lib/libcaffe.so.1.0.0
CXX/LD -o .build_release/tools/upgrade_solver_proto_text.bin
CXX/LD -o .build_release/tools/convert_imageset.bin
CXX/LD -o .build_release/tools/upgrade_net_proto_text.bin
CXX/LD -o .build_release/tools/extract_features.bin
CXX/LD -o .build_release/tools/compute_image_mean.bin
CXX/LD -o .build_release/tools/upgrade_net_proto_binary.bin
CXX/LD -o .build_release/tools/caffe.bin
CXX/LD -o .build_release/examples/mnist/convert_mnist_data.bin
CXX/LD -o .build_release/examples/cifar10/convert_cifar_data.bin
CXX/LD -o .build_release/examples/cpp_classification/classification.bin
CXX/LD -o .build_release/examples/siamese/convert_mnist_siamese_data.bin
.build_release/lib/libcaffe.so: undefined reference to `cv::imread(cv::String const&, int)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::allocate(unsigned long)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int, std::allocator<int> > const&)'
collect2: error: ld returned 1 exit status
Makefile:640: recipe for target '.build_release/examples/mnist/convert_mnist_data.bin' failed
make: *** [.build_release/examples/mnist/convert_mnist_data.bin] Error 1
make: *** Waiting for unfinished jobs....
.build_release/lib/libcaffe.so: undefined reference to `cv::imread(cv::String const&, int)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::allocate(unsigned long)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int, std::allocator<int> > const&)'
collect2: error: ld returned 1 exit status
Makefile:635: recipe for target '.build_release/tools/extract_features.bin' failed
make: *** [.build_release/tools/extract_features.bin] Error 1
.build_release/lib/libcaffe.so: undefined reference to `cv::imread(cv::String const&, int)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::allocate(unsigned long)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int, std::allocator<int> > const&)'
collect2: error: ld returned 1 exit status
Makefile:635: recipe for target '.build_release/tools/upgrade_net_proto_text.bin' failed
make: *** [.build_release/tools/upgrade_net_proto_text.bin] Error 1
.build_release/lib/libcaffe.so: undefined reference to `cv::imread(cv::String const&, int)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::allocate(unsigned long)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int, std::allocator<int> > const&)'
collect2: error: ld returned 1 exit status
.build_release/lib/libcaffe.so: undefined reference to `cv::imread(cv::String const&, int)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::allocate(unsigned long)'
.build_release/lib/Makefile:635: recipe for target '.build_release/tools/caffe.bin' failed
libcaffe.so:make: *** [.build_release/tools/caffe.bin] Error 1
 undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int, std::allocator<int> > const&)'
collect2: error: ld returned 1 exit status
Makefile:635: recipe for target '.build_release/tools/upgrade_net_proto_binary.bin' failed
make: *** [.build_release/tools/upgrade_net_proto_binary.bin] Error 1
.build_release/lib/libcaffe.so: undefined reference to `cv::imread(cv::String const&, int)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::allocate(unsigned long)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int, std::allocator<int> > const&)'
collect2: error: ld returned 1 exit status
Makefile:635: recipe for target '.build_release/tools/upgrade_solver_proto_text.bin' failed
make: *** [.build_release/tools/upgrade_solver_proto_text.bin] Error 1
.build_release/examples/cpp_classification/.classification.o:build_release /Inlib /functionlibcaffe.so :` Classifierundefined: :referenceWrapInputLayer (tostd :`:cvvector:<:cvimread:(:cvMat:,: Stringstd :const:&allocator,< cvint:):'Mat
>. build_release>/*lib)/'libcaffe.so::
 classification.cppundefined: (reference. textto+ 0x21a8`)cv:: :undefinedString :reference: allocateto( unsigned` cvlong:):'error
(.intbuild_release,/ libcv/:libcaffe.so::String  undefinedconst &reference,  tochar  `constcv*:,: Stringchar: :constdeallocate*(,) 'int
).'build_release
/classification.cpplib:/(libcaffe.so.:text +undefined0x21b2 )reference:  toundefined  `referencecv :to: imencode`(cvcv::::StringString: :constdeallocate&(,) 'cv
:classification.cpp::_InputArray( .consttext&+,0x21ef )std:: :undefinedvector <referenceunsigned  tochar ,` cvstd::::Stringallocator:<:unsigneddeallocate (char)>' 
>.&build_release,/ examplesstd/:cpp_classification:/vectorclassification.o<:int ,In  stdfunction: :`allocatorClassifier<:int:>SetMean (>std :const:&__cxx11):':
basic_string<char, std::char_traits<char>, std::allocator<char> > const&)collect2: error: ld returned 1 exit status
':
classification.cpp:(.text+0x38c4): undefined reference to `cv::error(int, cv::String const&, char const*, char const*, int)'
classification.cpp:(.text+0x38cc): undefined reference to `cv::String::deallocate()'
classification.cpp:(.text+0x3bad): undefined reference to `cv::String::deallocate()'
.build_release/examples/cpp_classification/classification.o: In function `cv::String::String(char const*)':
Makefile:635: recipe for target '.build_release/tools/compute_image_mean.bin' failed
classification.cpp:make: *** [.build_release/tools/compute_image_mean.bin] Error 1
(.text._ZN2cv6StringC2EPKc[_ZN2cv6StringC5EPKc]+0x30): undefined reference to `cv::String::allocate(unsigned long)'
.build_release/examples/cpp_classification/classification.o: In function `main':
classification.cpp:(.text.startup+0x233): undefined reference to `cv::imread(cv::String const&, int)'
classification.cpp:(.text.startup+0x23b): undefined reference to `cv::String::deallocate()'
classification.cpp:(.text.startup+0x55e): undefined reference to `cv::String::allocate(unsigned long)'
classification.cpp:(.text.startup+0x685): undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::.allocatorbuild_release</unsignedlib /charlibcaffe.so>:  >undefined& ,reference  stdto: :`vectorcv<:int:,imread (stdcv::::allocatorString< const&,int .>intbuild_release )/>'lib
 /.constlibcaffe.sobuild_release&:/ )libundefined'/ 
libcaffe.soreference:  toundefined  `referencecv :to: imread`(cvcv::::StringString: :constallocate&(,collect2: error: ld returned 1 exit status
unsigned  intlong))''

..build_releasebuild_release//liblib//libcaffe.solibcaffe.so::  undefinedundefined  referencereference  toto  ``cvcv::::StringString::::allocatedeallocate((unsigned) 'long
).'build_release
/.libbuild_release//libcaffe.solib:/ libcaffe.soundefined:  referenceundefined  toreference  `tocv :`:cvimencode:(:cvString::::Stringdeallocate (const)&',
 .cvbuild_release:/:lib_InputArray/ libcaffe.soconst:& ,undefined  stdreference: :tovector <`unsignedcv :char:,imencode (stdcv::::allocatorString< unsignedconst &char,>  cv>:&:,_InputArrayMakefile:640: recipe for target '.build_release/examples/cpp_classification/classification.bin' failed
  stdconstmake: *** [.build_release/examples/cpp_classification/classification.bin] Error 1
:&:, vectorstd<:int:,vector <stdunsigned: :charallocator,< intstd>: :>allocator <constunsigned& )char'>
 >&, std::vector<int, std::allocator<int> >collect2: error: ld returned 1 exit status
 const&)'
collect2: error: ld returned 1 exit status
Makefile:635: recipe for target '.build_release/tools/convert_imageset.bin' failed
make: *** [.build_release/tools/convert_imageset.bin] Error 1
Makefile:640: recipe for target '.build_release/examples/cifar10/convert_cifar_data.bin' failed
make: *** [.build_release/examples/cifar10/convert_cifar_data.bin] Error 1
.build_release/lib/libcaffe.so: undefined reference to `cv::imread(cv::String const&, int)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::allocate(unsigned long)'
.build_release/lib/libcaffe.so: undefined reference to `cv::String::deallocate()'
.build_release/lib/libcaffe.so: undefined reference to `cv::imencode(cv::String const&, cv::_InputArray const&, std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int, std::allocator<int> > const&)'
collect2: error: ld returned 1 exit status
Makefile:640: recipe for target '.build_release/examples/siamese/convert_mnist_siamese_data.bin' failed
make: *** [.build_release/examples/siamese/convert_mnist_siamese_data.bin] Error 1
jackiezhang11 commented 4 years ago

close your opencv in CMakeLists.txt file

smitheric95 commented 3 years ago

close your opencv in CMakeLists.txt file

@jackiezhang11, could you please expand on that?