Ubuntu下编译GCC编译caffe,出现error
c++/4.8/bits/stl_algo.h:2245:19: error: passing const yolo_v2::DATA as this argument of bool yolo_v2::DATA::operator<(yolo_v2::DATA) discards qualifiers [-fpermissive]
while (__pivot < *__last)
大致的意思就是:将非变量传递的类型不一致导致错误
作者代码:
bool operator<( DATA data)
{
return this->confidence > data.confidence;
}
定位到STL的源码:
/// This is a helper function...
template<typename _RandomAc