weiliu89 / caffe

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

Compile error #577

Open elirex opened 7 years ago

elirex commented 7 years ago

I follow the ssd installation step, when I run make -j8 then occur error.

Error Message:

PROTOC src/caffe/proto/caffe.proto
CXX src/caffe/solver.cpp
CXX src/caffe/layer.cpp
CXX src/caffe/data_reader.cpp
CXX src/caffe/layers/cudnn_lrn_layer.cpp
CXX src/caffe/layers/euclidean_loss_layer.cpp
CXX src/caffe/layers/rnn_layer.cpp
CXX src/caffe/layers/silence_layer.cpp
CXX src/caffe/layers/sigmoid_cross_entropy_loss_layer.cpp
CXX src/caffe/layers/eltwise_layer.cpp
CXX src/caffe/layers/hinge_loss_layer.cpp
In file included from ./include/caffe/layers/annotated_data_layer.hpp:9:0,
                 from src/caffe/data_reader.cpp:8:
./include/caffe/data_transformer.hpp:69:24: error: ‘AnnotatedDatum’ does not name a type
   void Transform(const AnnotatedDatum& anno_datum,
                        ^
./include/caffe/data_transformer.hpp:71:35: error: ‘AnnotationGroup’ was not declared in this scope
                  RepeatedPtrField<AnnotationGroup>* transformed_anno_vec);
                                   ^
./include/caffe/data_transformer.hpp:71:50: error: template argument 1 is invalid
                  RepeatedPtrField<AnnotationGroup>* transformed_anno_vec);
                                                  ^
./include/caffe/data_transformer.hpp:72:24: error: ‘AnnotatedDatum’ does not name a type
   void Transform(const AnnotatedDatum& anno_datum,
                        ^
./include/caffe/data_transformer.hpp:74:35: error: ‘AnnotationGroup’ was not declared in this scope
                  RepeatedPtrField<AnnotationGroup>* transformed_anno_vec,
                                   ^
./include/caffe/data_transformer.hpp:74:50: error: template argument 1 is invalid
                  RepeatedPtrField<AnnotationGroup>* transformed_anno_vec,
                                                  ^
./include/caffe/data_transformer.hpp:76:24: error: ‘AnnotatedDatum’ does not name a type
   void Transform(const AnnotatedDatum& anno_datum,
                        ^
./include/caffe/data_transformer.hpp:78:25: error: ‘AnnotationGroup’ was not declared in this scope
                  vector<AnnotationGroup>* transformed_anno_vec,
                         ^
./include/caffe/data_transformer.hpp:78:40: error: template argument 1 is invalid
                  vector<AnnotationGroup>* transformed_anno_vec,
                                        ^
./include/caffe/data_transformer.hpp:78:40: error: template argument 2 is invalid
./include/caffe/data_transformer.hpp:76:8: error: ‘void caffe::DataTransformer<Dtype>::Transform(const int&, caffe::Blob<Dtype>*, int*, bool*)’ cannot be overloaded
   void Transform(const AnnotatedDatum& anno_datum,
        ^
./include/caffe/data_transformer.hpp:72:8: error: with ‘void caffe::DataTransformer<Dtype>::Transform(const int&, caffe::Blob<Dtype>*, int*, bool*)’
   void Transform(const AnnotatedDatum& anno_datum,
        ^
./include/caffe/data_transformer.hpp:80:24: error: ‘AnnotatedDatum’ does not name a type
   void Transform(const AnnotatedDatum& anno_datum,
                        ^
./include/caffe/data_transformer.hpp:82:25: error: ‘AnnotationGroup’ was not declared in this scope
                  vector<AnnotationGroup>* transformed_anno_vec);
                         ^
./include/caffe/data_transformer.hpp:82:40: error: template argument 1 is invalid
                  vector<AnnotationGroup>* transformed_anno_vec);
                                        ^
./include/caffe/data_transformer.hpp:82:40: error: template argument 2 is invalid
./include/caffe/data_transformer.hpp:80:8: error: ‘void caffe::DataTransformer<Dtype>::Transform(const int&, caffe::Blob<Dtype>*, int*)’ cannot be overloaded
   void Transform(const AnnotatedDatum& anno_datum,
        ^
./include/caffe/data_transformer.hpp:69:8: error: with ‘void caffe::DataTransformer<Dtype>::Transform(const int&, caffe::Blob<Dtype>*, int*)’
   void Transform(const AnnotatedDatum& anno_datum,
        ^
./include/caffe/data_transformer.hpp:100:13: error: ‘AnnotatedDatum’ does not name a type
       const AnnotatedDatum& anno_datum, const bool do_resize,
             ^
./include/caffe/data_transformer.hpp:101:13: error: ‘NormalizedBBox’ does not name a type
       const NormalizedBBox& crop_bbox, const bool do_mirror,
             ^
./include/caffe/data_transformer.hpp:102:24: error: ‘AnnotationGroup’ was not declared in this scope
       RepeatedPtrField<AnnotationGroup>* transformed_anno_group_all);
                        ^
./include/caffe/data_transformer.hpp:102:39: error: template argument 1 is invalid
       RepeatedPtrField<AnnotationGroup>* transformed_anno_group_all);
                                       ^
./include/caffe/data_transformer.hpp:107:44: error: ‘NormalizedBBox’ does not name a type
   void CropImage(const Datum& datum, const NormalizedBBox& bbox,
                                            ^
./include/caffe/data_transformer.hpp:113:24: error: ‘AnnotatedDatum’ does not name a type
   void CropImage(const AnnotatedDatum& anno_datum, const NormalizedBBox& bbox,
                        ^
./include/caffe/data_transformer.hpp:113:58: error: ‘NormalizedBBox’ does not name a type
   void CropImage(const AnnotatedDatum& anno_datum, const NormalizedBBox& bbox,
                                                          ^
./include/caffe/data_transformer.hpp:114:18: error: ‘AnnotatedDatum’ has not been declared
                  AnnotatedDatum* cropped_anno_datum);
                  ^
./include/caffe/data_transformer.hpp:120:20: error: ‘NormalizedBBox’ has not been declared
                    NormalizedBBox* expand_bbox, Datum* expanded_datum);
                    ^
./include/caffe/data_transformer.hpp:125:26: error: ‘AnnotatedDatum’ does not name a type
   void ExpandImage(const AnnotatedDatum& anno_datum,
                          ^
./include/caffe/data_transformer.hpp:126:20: error: ‘AnnotatedDatum’ has not been declared
                    AnnotatedDatum* expanded_anno_datum);
                    ^
./include/caffe/data_transformer.hpp:158:18: error: ‘NormalizedBBox’ has not been declared
                  NormalizedBBox* crop_bbox, bool* do_mirror);
                  ^
./include/caffe/data_transformer.hpp:164:44: error: ‘NormalizedBBox’ does not name a type
   void CropImage(const cv::Mat& img, const NormalizedBBox& bbox,
                                            ^
./include/caffe/data_transformer.hpp:171:20: error: ‘NormalizedBBox’ has not been declared
                    NormalizedBBox* expand_bbox, cv::Mat* expand_img);
                    ^
./include/caffe/data_transformer.hpp:241:18: error: ‘NormalizedBBox’ has not been declared
                  NormalizedBBox* crop_bbox, bool* do_mirror);
                  ^
./include/caffe/data_transformer.hpp:249:18: error: ‘NormalizedBBox’ has not been declared
                  NormalizedBBox* crop_bbox, bool* do_mirror);
                  ^
In file included from src/caffe/data_reader.cpp:8:0:
./include/caffe/layers/annotated_data_layer.hpp:34:14: error: ‘AnnotatedDatum’ was not declared in this scope
   DataReader<AnnotatedDatum> reader_;
              ^
./include/caffe/layers/annotated_data_layer.hpp:34:28: error: template argument 1 is invalid
   DataReader<AnnotatedDatum> reader_;
                            ^
./include/caffe/layers/annotated_data_layer.hpp:36:3: error: ‘AnnotatedDatum_AnnotationType’ does not name a type
   AnnotatedDatum_AnnotationType anno_type_;
   ^
./include/caffe/layers/annotated_data_layer.hpp:37:10: error: ‘BatchSampler’ was not declared in this scope
   vector<BatchSampler> batch_samplers_;
          ^
./include/caffe/layers/annotated_data_layer.hpp:37:22: error: template argument 1 is invalid
   vector<BatchSampler> batch_samplers_;
                      ^
./include/caffe/layers/annotated_data_layer.hpp:37:22: error: template argument 2 is invalid
src/caffe/data_reader.cpp:24:39: error: ‘AnnotatedDatum’ was not declared in this scope
 map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >
                                       ^
src/caffe/data_reader.cpp:24:53: error: template argument 1 is invalid
 map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >
                                                     ^
src/caffe/data_reader.cpp:24:60: error: template argument 1 is invalid
 map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >
                                                            ^
src/caffe/data_reader.cpp:24:62: error: template argument 2 is invalid
 map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >
                                                              ^
src/caffe/data_reader.cpp:24:62: error: template argument 4 is invalid
src/caffe/data_reader.cpp:25:14: error: ‘AnnotatedDatum’ was not declared in this scope
   DataReader<AnnotatedDatum>::bodies_
              ^
src/caffe/data_reader.cpp:25:28: error: template argument 1 is invalid
   DataReader<AnnotatedDatum>::bodies_
                            ^
src/caffe/data_reader.cpp:26:43: error: ‘AnnotatedDatum’ was not declared in this scope
   = map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >();
                                           ^
src/caffe/data_reader.cpp:26:57: error: template argument 1 is invalid
   = map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >();
                                                         ^
src/caffe/data_reader.cpp:26:64: error: template argument 1 is invalid
   = map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >();
                                                                ^
src/caffe/data_reader.cpp:26:66: error: template argument 2 is invalid
   = map<const string, weak_ptr<DataReader<AnnotatedDatum>::Body> >();
                                                                  ^
src/caffe/data_reader.cpp:26:66: error: template argument 4 is invalid
src/caffe/data_reader.cpp:25:3: warning: too many template headers for caffe::bodies_ (should be 0)
   DataReader<AnnotatedDatum>::bodies_
   ^
src/caffe/data_reader.cpp:136:27: error: ‘AnnotatedDatum’ was not declared in this scope
 template class DataReader<AnnotatedDatum>;
                           ^
src/caffe/data_reader.cpp:136:41: error: template argument 1 is invalid
 template class DataReader<AnnotatedDatum>;
                                         ^
Makefile:575: recipe for target '.build_release/src/caffe/data_reader.o' failed
make: *** [.build_release/src/caffe/data_reader.o] Error 1
make: *** Waiting for unfinished jobs....
In file included from ./include/caffe/caffe.hpp:18:0,
                 from ./include/caffe/util/bbox_util.hpp:19,
                 from src/caffe/solver.cpp:9:
./include/caffe/util/io.hpp:192:40: error: ‘AnnotatedDatum_AnnotationType’ does not name a type
     const std::string& encoding, const AnnotatedDatum_AnnotationType type,
                                        ^
./include/caffe/util/io.hpp:194:5: error: ‘AnnotatedDatum’ has not been declared
     AnnotatedDatum* anno_datum);
     ^
./include/caffe/util/io.hpp:199:11: error: ‘AnnotatedDatum_AnnotationType’ does not name a type
     const AnnotatedDatum_AnnotationType type, const string& labeltype,
           ^
./include/caffe/util/io.hpp:200:49: error: ‘AnnotatedDatum’ has not been declared
     const std::map<string, int>& name_to_label, AnnotatedDatum* anno_datum) {
                                                 ^
./include/caffe/util/io.hpp:208:5: error: ‘AnnotatedDatum’ has not been declared
     AnnotatedDatum* anno_datum);
     ^
./include/caffe/util/io.hpp:212:5: error: ‘AnnotatedDatum’ has not been declared
     AnnotatedDatum* anno_datum);
     ^
./include/caffe/util/io.hpp:215:22: error: ‘AnnotatedDatum’ has not been declared
     const int width, AnnotatedDatum* anno_datum);
                      ^
./include/caffe/util/io.hpp:218:30: error: ‘LabelMap’ has not been declared
     const string& delimiter, LabelMap* map);
                              ^
./include/caffe/util/io.hpp:221:32: error: ‘LabelMap’ has not been declared
       bool include_background, LabelMap* map) {
                                ^
./include/caffe/util/io.hpp:225:61: error: ‘LabelMap’ has not been declared
 inline bool ReadLabelFileToLabelMap(const string& filename, LabelMap* map) {
                                                             ^
./include/caffe/util/io.hpp:229:27: error: ‘LabelMap’ does not name a type
 bool MapNameToLabel(const LabelMap& map, const bool strict_check,
                           ^
./include/caffe/util/io.hpp:232:34: error: ‘LabelMap’ does not name a type
 inline bool MapNameToLabel(const LabelMap& map,
                                  ^
./include/caffe/util/io.hpp:237:27: error: ‘LabelMap’ does not name a type
 bool MapLabelToName(const LabelMap& map, const bool strict_check,
                           ^
./include/caffe/util/io.hpp:240:34: error: ‘LabelMap’ does not name a type
 inline bool MapLabelToName(const LabelMap& map,
                                  ^
./include/caffe/util/io.hpp:245:34: error: ‘LabelMap’ does not name a type
 bool MapLabelToDisplayName(const LabelMap& map, const bool strict_check,
                                  ^
./include/caffe/util/io.hpp:248:41: error: ‘LabelMap’ does not name a type
 inline bool MapLabelToDisplayName(const LabelMap& map,
                                         ^
In file included from src/caffe/solver.cpp:9:0:
./include/caffe/util/bbox_util.hpp:23:9: error: ‘EmitConstraint_EmitType’ does not name a type
 typedef EmitConstraint_EmitType EmitType;
         ^
./include/caffe/util/bbox_util.hpp:24:9: error: ‘PriorBoxParameter_CodeType’ does not name a type
 typedef PriorBoxParameter_CodeType CodeType;
         ^
./include/caffe/util/bbox_util.hpp:25:9: error: ‘MultiBoxLossParameter_MatchType’ does not name a type
 typedef MultiBoxLossParameter_MatchType MatchType;
         ^
./include/caffe/util/bbox_util.hpp:26:9: error: ‘MultiBoxLossParameter_LocLossType’ does not name a type
 typedef MultiBoxLossParameter_LocLossType LocLossType;
         ^
./include/caffe/util/bbox_util.hpp:27:9: error: ‘MultiBoxLossParameter_ConfLossType’ does not name a type
 typedef MultiBoxLossParameter_ConfLossType ConfLossType;
         ^
./include/caffe/util/bbox_util.hpp:28:9: error: ‘MultiBoxLossParameter_MiningType’ does not name a type
 typedef MultiBoxLossParameter_MiningType MiningType;
         ^
./include/caffe/util/bbox_util.hpp:30:25: error: ‘NormalizedBBox’ was not declared in this scope
 typedef map<int, vector<NormalizedBBox> > LabelBBox;
                         ^
./include/caffe/util/bbox_util.hpp:30:39: error: template argument 1 is invalid
 typedef map<int, vector<NormalizedBBox> > LabelBBox;
                                       ^
./include/caffe/util/bbox_util.hpp:30:39: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:30:41: error: template argument 2 is invalid
 typedef map<int, vector<NormalizedBBox> > LabelBBox;
                                         ^
./include/caffe/util/bbox_util.hpp:30:41: error: template argument 4 is invalid
./include/caffe/util/bbox_util.hpp:34:27: error: ‘NormalizedBBox’ does not name a type
 bool SortBBoxAscend(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2);
                           ^
./include/caffe/util/bbox_util.hpp:34:56: error: ‘NormalizedBBox’ does not name a type
 bool SortBBoxAscend(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2);
                                                        ^
./include/caffe/util/bbox_util.hpp:38:28: error: ‘NormalizedBBox’ does not name a type
 bool SortBBoxDescend(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2);
                            ^
./include/caffe/util/bbox_util.hpp:38:57: error: ‘NormalizedBBox’ does not name a type
 bool SortBBoxDescend(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2);
                                                         ^
./include/caffe/util/bbox_util.hpp:53:1: error: ‘NormalizedBBox’ does not name a type
 NormalizedBBox UnitBBox();
 ^
./include/caffe/util/bbox_util.hpp:56:32: error: ‘NormalizedBBox’ does not name a type
 bool IsCrossBoundaryBBox(const NormalizedBBox& bbox);
                                ^
./include/caffe/util/bbox_util.hpp:59:26: error: ‘NormalizedBBox’ does not name a type
 void IntersectBBox(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2,
                          ^
./include/caffe/util/bbox_util.hpp:59:55: error: ‘NormalizedBBox’ does not name a type
 void IntersectBBox(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2,
                                                       ^
./include/caffe/util/bbox_util.hpp:60:20: error: ‘NormalizedBBox’ has not been declared
                    NormalizedBBox* intersect_bbox);
                    ^
./include/caffe/util/bbox_util.hpp:63:22: error: ‘NormalizedBBox’ does not name a type
 float BBoxSize(const NormalizedBBox& bbox, const bool normalized = true);
                      ^
./include/caffe/util/bbox_util.hpp:69:21: error: ‘NormalizedBBox’ does not name a type
 void ClipBBox(const NormalizedBBox& bbox, NormalizedBBox* clip_bbox);
                     ^
./include/caffe/util/bbox_util.hpp:69:43: error: ‘NormalizedBBox’ has not been declared
 void ClipBBox(const NormalizedBBox& bbox, NormalizedBBox* clip_bbox);
                                           ^
./include/caffe/util/bbox_util.hpp:72:21: error: ‘NormalizedBBox’ does not name a type
 void ClipBBox(const NormalizedBBox& bbox, const float height, const float width,
                     ^
./include/caffe/util/bbox_util.hpp:73:15: error: ‘NormalizedBBox’ has not been declared
               NormalizedBBox* clip_bbox);
               ^
./include/caffe/util/bbox_util.hpp:76:22: error: ‘NormalizedBBox’ does not name a type
 void ScaleBBox(const NormalizedBBox& bbox, const int height, const int width,
                      ^
./include/caffe/util/bbox_util.hpp:77:16: error: ‘NormalizedBBox’ has not been declared
                NormalizedBBox* scale_bbox);
                ^
./include/caffe/util/bbox_util.hpp:80:23: error: ‘NormalizedBBox’ does not name a type
 void OutputBBox(const NormalizedBBox& bbox, const pair<int, int>& img_size,
                       ^
./include/caffe/util/bbox_util.hpp:81:46: error: ‘ResizeParameter’ does not name a type
                 const bool has_resize, const ResizeParameter& resize_param,
                                              ^
./include/caffe/util/bbox_util.hpp:82:17: error: ‘NormalizedBBox’ has not been declared
                 NormalizedBBox* out_bbox);
                 ^
./include/caffe/util/bbox_util.hpp:85:23: error: ‘NormalizedBBox’ does not name a type
 void LocateBBox(const NormalizedBBox& src_bbox, const NormalizedBBox& bbox,
                       ^
./include/caffe/util/bbox_util.hpp:85:55: error: ‘NormalizedBBox’ does not name a type
 void LocateBBox(const NormalizedBBox& src_bbox, const NormalizedBBox& bbox,
                                                       ^
./include/caffe/util/bbox_util.hpp:86:17: error: ‘NormalizedBBox’ has not been declared
                 NormalizedBBox* loc_bbox);
                 ^
./include/caffe/util/bbox_util.hpp:89:24: error: ‘NormalizedBBox’ does not name a type
 bool ProjectBBox(const NormalizedBBox& src_bbox, const NormalizedBBox& bbox,
                        ^
./include/caffe/util/bbox_util.hpp:89:56: error: ‘NormalizedBBox’ does not name a type
 bool ProjectBBox(const NormalizedBBox& src_bbox, const NormalizedBBox& bbox,
                                                        ^
./include/caffe/util/bbox_util.hpp:90:18: error: ‘NormalizedBBox’ has not been declared
                  NormalizedBBox* proj_bbox);
                  ^
./include/caffe/util/bbox_util.hpp:94:28: error: ‘ResizeParameter’ does not name a type
 void ExtrapolateBBox(const ResizeParameter& param, const int height,
                            ^
./include/caffe/util/bbox_util.hpp:95:28: error: ‘NormalizedBBox’ does not name a type
     const int width, const NormalizedBBox& crop_bbox, NormalizedBBox* bbox);
                            ^
./include/caffe/util/bbox_util.hpp:95:55: error: ‘NormalizedBBox’ has not been declared
     const int width, const NormalizedBBox& crop_bbox, NormalizedBBox* bbox);
                                                       ^
./include/caffe/util/bbox_util.hpp:98:28: error: ‘NormalizedBBox’ does not name a type
 float JaccardOverlap(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2,
                            ^
./include/caffe/util/bbox_util.hpp:98:57: error: ‘NormalizedBBox’ does not name a type
 float JaccardOverlap(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2,
                                                         ^
./include/caffe/util/bbox_util.hpp:105:26: error: ‘NormalizedBBox’ does not name a type
 float BBoxCoverage(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2);
                          ^
./include/caffe/util/bbox_util.hpp:105:55: error: ‘NormalizedBBox’ does not name a type
 float BBoxCoverage(const NormalizedBBox& bbox1, const NormalizedBBox& bbox2);
                                                       ^
./include/caffe/util/bbox_util.hpp:108:23: error: ‘NormalizedBBox’ does not name a type
 void EncodeBBox(const NormalizedBBox& prior_bbox,
                       ^
./include/caffe/util/bbox_util.hpp:109:48: error: ‘CodeType’ does not name a type
     const vector<float>& prior_variance, const CodeType code_type,
                                                ^
./include/caffe/util/bbox_util.hpp:110:49: error: ‘NormalizedBBox’ does not name a type
     const bool encode_variance_in_target, const NormalizedBBox& bbox,
                                                 ^
./include/caffe/util/bbox_util.hpp:111:5: error: ‘NormalizedBBox’ has not been declared
     NormalizedBBox* encode_bbox);
     ^
./include/caffe/util/bbox_util.hpp:114:31: error: ‘NormalizedBBox’ does not name a type
 bool MeetEmitConstraint(const NormalizedBBox& src_bbox,
                               ^
./include/caffe/util/bbox_util.hpp:115:11: error: ‘NormalizedBBox’ does not name a type
     const NormalizedBBox& bbox, const EmitConstraint& emit_constraint);
           ^
./include/caffe/util/bbox_util.hpp:115:39: error: ‘EmitConstraint’ does not name a type
     const NormalizedBBox& bbox, const EmitConstraint& emit_constraint);
                                       ^
./include/caffe/util/bbox_util.hpp:118:23: error: ‘NormalizedBBox’ does not name a type
 void DecodeBBox(const NormalizedBBox& prior_bbox,
                       ^
./include/caffe/util/bbox_util.hpp:119:48: error: ‘CodeType’ does not name a type
     const vector<float>& prior_variance, const CodeType code_type,
                                                ^
./include/caffe/util/bbox_util.hpp:121:11: error: ‘NormalizedBBox’ does not name a type
     const NormalizedBBox& bbox, NormalizedBBox* decode_bbox);
           ^
./include/caffe/util/bbox_util.hpp:121:33: error: ‘NormalizedBBox’ has not been declared
     const NormalizedBBox& bbox, NormalizedBBox* decode_bbox);
                                 ^
./include/caffe/util/bbox_util.hpp:124:32: error: ‘NormalizedBBox’ was not declared in this scope
 void DecodeBBoxes(const vector<NormalizedBBox>& prior_bboxes,
                                ^
./include/caffe/util/bbox_util.hpp:124:46: error: template argument 1 is invalid
 void DecodeBBoxes(const vector<NormalizedBBox>& prior_bboxes,
                                              ^
./include/caffe/util/bbox_util.hpp:124:46: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:126:11: error: ‘CodeType’ does not name a type
     const CodeType code_type, const bool variance_encoded_in_target,
           ^
./include/caffe/util/bbox_util.hpp:127:40: error: ‘NormalizedBBox’ was not declared in this scope
     const bool clip_bbox, const vector<NormalizedBBox>& bboxes,
                                        ^
./include/caffe/util/bbox_util.hpp:127:54: error: template argument 1 is invalid
     const bool clip_bbox, const vector<NormalizedBBox>& bboxes,
                                                      ^
./include/caffe/util/bbox_util.hpp:127:54: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:128:12: error: ‘NormalizedBBox’ was not declared in this scope
     vector<NormalizedBBox>* decode_bboxes);
            ^
./include/caffe/util/bbox_util.hpp:128:26: error: template argument 1 is invalid
     vector<NormalizedBBox>* decode_bboxes);
                          ^
./include/caffe/util/bbox_util.hpp:128:26: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:132:18: error: ‘NormalizedBBox’ was not declared in this scope
     const vector<NormalizedBBox>& prior_bboxes,
                  ^
./include/caffe/util/bbox_util.hpp:132:32: error: template argument 1 is invalid
     const vector<NormalizedBBox>& prior_bboxes,
                                ^
./include/caffe/util/bbox_util.hpp:132:32: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:136:11: error: ‘CodeType’ does not name a type
     const CodeType code_type, const bool variance_encoded_in_target,
           ^
./include/caffe/util/bbox_util.hpp:140:29: error: ‘NormalizedBBox’ was not declared in this scope
 void MatchBBox(const vector<NormalizedBBox>& gt,
                             ^
./include/caffe/util/bbox_util.hpp:140:43: error: template argument 1 is invalid
 void MatchBBox(const vector<NormalizedBBox>& gt,
                                           ^
./include/caffe/util/bbox_util.hpp:140:43: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:141:18: error: ‘NormalizedBBox’ was not declared in this scope
     const vector<NormalizedBBox>& pred_bboxes, const int label,
                  ^
./include/caffe/util/bbox_util.hpp:141:32: error: template argument 1 is invalid
     const vector<NormalizedBBox>& pred_bboxes, const int label,
                                ^
./include/caffe/util/bbox_util.hpp:141:32: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:142:11: error: ‘MatchType’ does not name a type
     const MatchType match_type, const float overlap_threshold,
           ^
./include/caffe/util/bbox_util.hpp:156:29: error: ‘NormalizedBBox’ was not declared in this scope
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                             ^
./include/caffe/util/bbox_util.hpp:156:43: error: template argument 1 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                           ^
./include/caffe/util/bbox_util.hpp:156:43: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:156:45: error: template argument 2 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                             ^
./include/caffe/util/bbox_util.hpp:156:45: error: template argument 4 is invalid
./include/caffe/util/bbox_util.hpp:157:20: error: ‘NormalizedBBox’ was not declared in this scope
       const vector<NormalizedBBox>& prior_bboxes,
                    ^
./include/caffe/util/bbox_util.hpp:157:34: error: template argument 1 is invalid
       const vector<NormalizedBBox>& prior_bboxes,
                                  ^
./include/caffe/util/bbox_util.hpp:157:34: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:159:13: error: ‘MultiBoxLossParameter’ does not name a type
       const MultiBoxLossParameter& multibox_loss_param,
             ^
./include/caffe/util/bbox_util.hpp:181:27: error: ‘NormalizedBBox’ was not declared in this scope
     const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                           ^
./include/caffe/util/bbox_util.hpp:181:41: error: template argument 1 is invalid
     const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                         ^
./include/caffe/util/bbox_util.hpp:181:41: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:181:43: error: template argument 2 is invalid
     const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                           ^
./include/caffe/util/bbox_util.hpp:181:43: error: template argument 4 is invalid
./include/caffe/util/bbox_util.hpp:182:18: error: ‘NormalizedBBox’ was not declared in this scope
     const vector<NormalizedBBox>& prior_bboxes,
                  ^
./include/caffe/util/bbox_util.hpp:182:32: error: template argument 1 is invalid
     const vector<NormalizedBBox>& prior_bboxes,
                                ^
./include/caffe/util/bbox_util.hpp:182:32: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:185:11: error: ‘MultiBoxLossParameter’ does not name a type
     const MultiBoxLossParameter& multibox_loss_param,
           ^
./include/caffe/util/bbox_util.hpp:200:23: error: ‘NormalizedBBox’ was not declared in this scope
       map<int, vector<NormalizedBBox> >* all_gt_bboxes);
                       ^
./include/caffe/util/bbox_util.hpp:200:37: error: template argument 1 is invalid
       map<int, vector<NormalizedBBox> >* all_gt_bboxes);
                                     ^
./include/caffe/util/bbox_util.hpp:200:37: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:200:39: error: template argument 2 is invalid
       map<int, vector<NormalizedBBox> >* all_gt_bboxes);
                                       ^
./include/caffe/util/bbox_util.hpp:200:39: error: template argument 4 is invalid
./include/caffe/util/bbox_util.hpp:233:29: error: ‘NormalizedBBox’ was not declared in this scope
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                             ^
./include/caffe/util/bbox_util.hpp:233:43: error: template argument 1 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                           ^
./include/caffe/util/bbox_util.hpp:233:43: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:233:45: error: template argument 2 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                             ^
./include/caffe/util/bbox_util.hpp:233:45: error: template argument 4 is invalid
./include/caffe/util/bbox_util.hpp:235:20: error: ‘NormalizedBBox’ was not declared in this scope
       const vector<NormalizedBBox>& prior_bboxes,
                    ^
./include/caffe/util/bbox_util.hpp:235:34: error: template argument 1 is invalid
       const vector<NormalizedBBox>& prior_bboxes,
                                  ^
./include/caffe/util/bbox_util.hpp:235:34: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:237:13: error: ‘MultiBoxLossParameter’ does not name a type
       const MultiBoxLossParameter& multibox_loss_param,
             ^
./include/caffe/util/bbox_util.hpp:251:50: error: ‘LocLossType’ does not name a type
       const int num, const int num_priors, const LocLossType loc_loss_type,
                                                  ^
./include/caffe/util/bbox_util.hpp:295:44: error: ‘ConfLossType’ does not name a type
       const int background_label_id, const ConfLossType loss_type,
                                            ^
./include/caffe/util/bbox_util.hpp:297:29: error: ‘NormalizedBBox’ was not declared in this scope
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                             ^
./include/caffe/util/bbox_util.hpp:297:43: error: template argument 1 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                           ^
./include/caffe/util/bbox_util.hpp:297:43: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:297:45: error: template argument 2 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                             ^
./include/caffe/util/bbox_util.hpp:297:45: error: template argument 4 is invalid
./include/caffe/util/bbox_util.hpp:312:44: error: ‘ConfLossType’ does not name a type
       const int background_label_id, const ConfLossType loss_type,
                                            ^
./include/caffe/util/bbox_util.hpp:327:35: error: ‘MultiBoxLossParameter’ does not name a type
       const int num_priors, const MultiBoxLossParameter& multibox_loss_param,
                                   ^
./include/caffe/util/bbox_util.hpp:330:29: error: ‘NormalizedBBox’ was not declared in this scope
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                             ^
./include/caffe/util/bbox_util.hpp:330:43: error: template argument 1 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                           ^
./include/caffe/util/bbox_util.hpp:330:43: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:330:45: error: template argument 2 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                             ^
./include/caffe/util/bbox_util.hpp:330:45: error: template argument 4 is invalid
./include/caffe/util/bbox_util.hpp:340:14: error: ‘NormalizedBBox’ was not declared in this scope
       vector<NormalizedBBox>* prior_bboxes,
              ^
./include/caffe/util/bbox_util.hpp:340:28: error: template argument 1 is invalid
       vector<NormalizedBBox>* prior_bboxes,
                            ^
./include/caffe/util/bbox_util.hpp:340:28: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:398:28: error: ‘NormalizedBBox’ was not declared in this scope
 void ApplyNMS(const vector<NormalizedBBox>& bboxes, const vector<float>& scores,
                            ^
./include/caffe/util/bbox_util.hpp:398:42: error: template argument 1 is invalid
 void ApplyNMS(const vector<NormalizedBBox>& bboxes, const vector<float>& scores,
                                          ^
./include/caffe/util/bbox_util.hpp:398:42: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:402:28: error: ‘NormalizedBBox’ was not declared in this scope
 void ApplyNMS(const vector<NormalizedBBox>& bboxes, const vector<float>& scores,
                            ^
./include/caffe/util/bbox_util.hpp:402:42: error: template argument 1 is invalid
 void ApplyNMS(const vector<NormalizedBBox>& bboxes, const vector<float>& scores,
                                          ^
./include/caffe/util/bbox_util.hpp:402:42: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:417:32: error: ‘NormalizedBBox’ was not declared in this scope
 void ApplyNMSFast(const vector<NormalizedBBox>& bboxes,
                                ^
./include/caffe/util/bbox_util.hpp:417:46: error: template argument 1 is invalid
 void ApplyNMSFast(const vector<NormalizedBBox>& bboxes,
                                              ^
./include/caffe/util/bbox_util.hpp:417:46: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:469:17: error: ‘CodeType’ does not name a type
           const CodeType code_type, const bool variance_encoded_in_target,
                 ^
./include/caffe/util/bbox_util.hpp:506:44: error: ‘ConfLossType’ does not name a type
       const int background_label_id, const ConfLossType loss_type,
                                            ^
./include/caffe/util/bbox_util.hpp:508:29: error: ‘NormalizedBBox’ was not declared in this scope
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                             ^
./include/caffe/util/bbox_util.hpp:508:43: error: template argument 1 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                           ^
./include/caffe/util/bbox_util.hpp:508:43: error: template argument 2 is invalid
./include/caffe/util/bbox_util.hpp:508:45: error: template argument 2 is invalid
       const map<int, vector<NormalizedBBox> >& all_gt_bboxes,
                                             ^
./include/caffe/util/bbox_util.hpp:508:45: error: template argument 4 is invalid
src/caffe/solver.cpp: In member function ‘void caffe::Solver<Dtype>::TestAll()’:
src/caffe/solver.cpp:345:16: error: ‘class caffe::SolverParameter’ has no member named ‘eval_type’
     if (param_.eval_type() == "classification") {
                ^
src/caffe/solver.cpp:347:23: error: ‘class caffe::SolverParameter’ has no member named ‘eval_type’
     } else if (param_.eval_type() == "detection") {
                       ^
src/caffe/solver.cpp:350:59: error: ‘class caffe::SolverParameter’ has no member named ‘eval_type’
       LOG(FATAL) << "Unknown evaluation type: " << param_.eval_type();
                                                           ^
src/caffe/solver.cpp: In member function ‘void caffe::Solver<Dtype>::TestDetection(int)’:
src/caffe/solver.cpp:537:24: error: ‘class caffe::SolverParameter’ has no member named ‘ap_version’
                 param_.ap_version(), &prec, &rec, &(APs[label]));
                        ^
src/caffe/solver.cpp:539:18: error: ‘class caffe::SolverParameter’ has no member named ‘show_per_class_result’
       if (param_.show_per_class_result()) {
                  ^
Makefile:575: recipe for target '.build_release/src/caffe/solver.o' failed
make: *** [.build_release/src/caffe/solver.o] Error 1

How can I solve is problem? Thank you.

Your system configuration

Operating system: Ubuntu 16.04 Compiler: gcc 5.4.0, g++5.4.0 CUDA version (if applicable): 8.0 CUDNN version (if applicable): 5.1 BLAS: open Python or MATLAB version (for pycaffe and matcaffe respectively): python 2.7.13

weiliu89 commented 7 years ago

Try make proto beforehand.

elirex commented 7 years ago

That is not working.

dongxiao92 commented 7 years ago

I met the same problem.Does anyone find solutions yet?

oostap1 commented 7 years ago

Workaround:

@@ -404,7 +404,7 @@ LIBRARY_DIRS += $(LIB_BUILD_DIR)
 CXXFLAGS += -MMD -MP

 # Complete build flags.
-COMMON_FLAGS += $(foreach includedir,$(INCLUDE_DIRS),-isystem $(includedir))
+COMMON_FLAGS += $(foreach includedir,$(INCLUDE_DIRS),-I$(includedir))
 CXXFLAGS += -pthread -fPIC $(COMMON_FLAGS) $(WARNINGS)
 NVCCFLAGS += -ccbin=$(CXX) -Xcompiler -fPIC $(COMMON_FLAGS)
 # mex may invoke an older gcc that is too liberal with -Wuninitalized

And running make proto make -j 8

Believe there is reason to use -isystem instead -I. Hope workaround won't break functionality, at least master does not have -system flag replaced.

Update: Seems SSD works OK after

elirex commented 7 years ago

I found problem.

make proto command that included /usr/local/include/caffe/caffe.pb.h instead of ssd/src/proto/caffe.proto.

I change the filename of caffe.pb.h , in the/usr/local/include/caffe. I re-run make -j8 and compile succeed.

cklat commented 7 years ago

To what filename did you change it? caffe.proto?

miraclewkf commented 7 years ago

change MakeFile:

-COMMON_FLAGS += $(foreach includedir,$(INCLUDE_DIRS),-isystem $(includedir)) #- means delete
+COMMON_FLAGS += $(foreach includedir,$(INCLUDE_DIRS),-I$(includedir)) #+ means add

and change MakeFile.config:

-INCLUDE_DIRS := $(PYTHON_INCLUDE) /usr/local/include
-LIBRARY_DIRS := $(PYTHON_LIB) /usr/local/lib /usr/lib
+INCLUDE_DIRS := $(PYTHON_INCLUDE) /usr/local/include /usr/include/hdf5/serial/
+LIBRARY_DIRS := $(PYTHON_LIB) /usr/local/lib /usr/lib /usr/lib/x86_64-linux-gnu/hdf5/serial/

Then make -j8 it works