caffe編譯過程中protobuf的問題

2021-08-19 19:09:56 字數 1849 閱讀 9678

.build_release/src/caffe/proto/caffe.pb.h:31387:42: error: 『kemptystring』 is not a member of 『google::protobuf::internal』

type_ = const_cast< ::std::string*>(&::google::protobuf::internal::kemptystring);

^.build_release/src/caffe/proto/caffe.pb.h: in member function 『void caffe::v0layerparameter::clear_source()』:

.build_release/src/caffe/proto/caffe.pb.h:31743:19: error: 『kemptystring』 is not a member of 『google::protobuf::internal』

if (source_ != &::google::protobuf::internal::kemptystring) {

^.省略無數行

.build_release/src/caffe/proto/caffe.pb.cc: in member function 『virtual void caffe::v0layerparameter::clear()』:

.build_release/src/caffe/proto/caffe.pb.cc:41951:21: error: 『kemptystring』 is not a member of 『google::protobuf::internal』

if (name_ != &::google::protobuf::internal::kemptystring) {

^.build_release/src/caffe/proto/caffe.pb.cc:41956:21: error: 『kemptystring』 is not a member of 『google::protobuf::internal』

if (type_ != &::google::protobuf::internal::kemptystring) {

^.build_release/src/caffe/proto/caffe.pb.cc:41983:23: error: 『kemptystring』 is not a member of 『google::protobuf::internal』

if (source_ != &::google::protobuf::internal::kemptystring) {

^.build_release/src/caffe/proto/caffe.pb.cc:41989:25: error: 『kemptystring』 is not a member of 『google::protobuf::internal』

if (meanfile_ != &::google::protobuf::internal::kemptystring) {

^make: *** [.build_release/src/caffe/proto/caffe.pb.o] 錯誤 1

解決方案:

首先說一下我的電腦環境,ubuntu14+anaconda2,可能是因為安裝了anaconda,導致protobuf的版本極度混亂,剛開始嘗試了各種解決方案,解除安裝protobuf,然後重新安裝等,但是都不能解決問題,,在這裡感謝

按照這裡面的提示,我更改了makefile裡面的protoc的路徑

當然,你要查詢你自己的protoc的路徑,使用which protoc命令查詢。

更改完路徑後重新編譯就好了!

caffe安裝過程中的問題

1 問題顯示 src caffe layers hdf5 data layer.cpp 13 18 fatal error hdf5.h 沒有那個檔案或目錄 解決 1 檢視是否安裝了hdf5依賴庫,或直接再安裝一遍 sudo apt get libhdf5 serial dev2 修改caffe目錄...

bitcoind編譯過程中的問題

本文列出個人在編譯位元幣程式bitcoind以及啟動執行中遇到的問題。makefile.am 10 error libtool library used but libtool is undefined makefile.am 10 the usual way to define libtool i...

解決Caffe訓練過程中loss不變問題

這段在使用caffe的時候遇到了兩個問題都是在訓練的過程中loss基本保持常數值,特此記錄一下。loss等於87.33這個問題是在對inception v3網路不管是fine tuning還是train的時候遇到的,無論網路迭代多少次,網路的loss一直保持恆定。查閱相關資料以後發現是由於loss的...