yjxiong / anet2016-cuhk

Action Recognition Toolbox for CUHK&ETHZ&SIAT submission to ActivityNet 2016
BSD 2-Clause "Simplified" License
252 stars 92 forks source link

caffe error #26

Closed haofanwang closed 6 years ago

haofanwang commented 6 years ago

/home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:38:25: error: ‘class caffe::TransformationParameter’ has no member named ‘max_distort’ maxdistort = param_.max_distort(); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:40:30: error: ‘class caffe::TransformationParameter’ has no member named ‘scale_ratiossize’ for (int i = 0; i < param.scale_ratios_size(); ++i){ ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:41:43: error: ‘class caffe::TransformationParameter’ has no member named ‘scale_ratios’ custom_scaleratios.pushback(param.scale_ratios(i)); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:43:26: error: ‘const class caffe::TransformationParameter’ has no member named ‘original_image’ org_sizeproc = param.original_image(); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp: In member function ‘void caffe::DataTransformer::Transform(const caffe::Datum&, Dtype)’: /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:163:38: error: ‘class caffe::TransformationParameter’ has no member named ‘multi_scale’ const bool do_multiscale = param.multi_scale(); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:226:18: error: ‘class caffe::TransformationParameter’ has no member named ‘fixcrop’ if (param.fix_crop()){ ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:228:30: error: ‘class caffe::TransformationParameter’ has no member named ‘more_fixcrop’ param.more_fix_crop(), offset_pairs); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:282:23: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && do_mirror && c%2 == 0) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:287:23: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && do_mirror && c%2 == 0) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:294:23: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && do_mirror && c%2 == 0) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:299:23: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && do_mirror && c%2 == 0) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp: In member function ‘void caffe::DataTransformer::Transform(const caffe::Datum&, const caffe::Datum&, caffe::Blob, caffe::Blob)’: /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:344:14: error: ‘class caffe::TransformationParameter’ has no member named ‘scale_ratiossize’ if (param.scale_ratios_size() == 2) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:346:26: error: ‘class caffe::TransformationParameter’ has no member named ‘scale_ratios’ lowerscale = param.scale_ratios(0); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:347:26: error: ‘class caffe::TransformationParameter’ has no member named ‘scale_ratios’ upperscale = param.scale_ratios(1); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/datatransformer.cpp:353:29: error: ‘class caffe::TransformationParameter’ has no member named ‘stride’ const int stride = param.stride(); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:380:14: error: ‘class caffe::TransformationParameter’ has no member named ‘has_uppersize’ if (param.has_upper_size()) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:382:48: error: ‘class caffe::TransformationParameter’ has no member named ‘upper_size’ crop_height = std::min(cropheight, param.upper_size()); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:383:46: error: ‘class caffe::TransformationParameter’ has no member named ‘upper_size’ crop_width = std::min(cropwidth, param.upper_size()); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:385:19: error: ‘class caffe::TransformationParameter’ has no member named ‘has_upperheight’ else if (param.has_upperheight() && param.has_upper_width()) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:385:48: error: ‘class caffe::TransformationParameter’ has no member named ‘has_upperwidth’ else if (param.has_upperheight() && param.has_upper_width()) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:387:48: error: ‘class caffe::TransformationParameter’ has no member named ‘upper_height’ crop_height = std::min(cropheight, param.upper_height()); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:388:46: error: ‘class caffe::TransformationParameter’ has no member named ‘upper_width’ crop_width = std::min(cropwidth, param.upper_width()); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp: In member function ‘void caffe::DataTransformer::Transform(const cv::Mat&, caffe::Blob)’: /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:582:38: error: ‘class caffe::TransformationParameter’ has no member named ‘multi_scale’ const bool do_multiscale = param.multi_scale(); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:635:20: error: ‘class caffe::TransformationParameter’ has no member named ‘fixcrop’ if (param.fix_crop()) { ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:637:32: error: ‘class caffe::TransformationParameter’ has no member named ‘more_fixcrop’ param.more_fix_crop(), offset_pairs); ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:714:22: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && do_mirror && c % 2 == 0) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:722:24: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && do_mirror && c % 2 == 0) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:729:24: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && do_mirror && c % 2 == 0) ^ /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp: In member function ‘void caffe::DataTransformer::Transform(caffe::Blob, caffe::Blob)’: /home/frank/PycharmProjects/end/caffe-action_recog/src/caffe/data_transformer.cpp:838:23: error: ‘class caffe::TransformationParameter’ has no member named ‘isflow’ if (param.is_flow() && c%2 == 0) ^ src/caffe/CMakeFiles/caffe.dir/build.make:81480: recipe for target 'src/caffe/CMakeFiles/caffe.dir/data_transformer.cpp.o' failed make[2]: [src/caffe/CMakeFiles/caffe.dir/data_transformer.cpp.o] Error 1 CMakeFiles/Makefile2:240: recipe for target 'src/caffe/CMakeFiles/caffe.dir/all' failed make[1]: [src/caffe/CMakeFiles/caffe.dir/all] Error 2 Makefile:129: recipe for target 'all' failed make: *** [all] Error 2

haofanwang commented 6 years ago

Solved.

This error means you are not using the exact caffe version. Check /usr/local and /usr/local/include, delete everything about caffe(caffe.pb.h in this case). And recompile it, good luck.

Closed.