KleinYuan / Caffe2-iOS

Caffe2 on iOS Real-time Demo. Test with Your Own Model and Photos.
MIT License
227 stars 45 forks source link

#include "caffe2/proto/caffe2.pb.h" not found #11

Closed dawand closed 7 years ago

dawand commented 7 years ago

not found in logging.h

I manually checked the cafe2 proto folder and the file is not there.

Am I missing something?

KleinYuan commented 7 years ago

@dawand hi, I guess you are testing feature-models branch right? In that case, yes, you will have this issue, because we are still developing this branch (in the stage of testing some error handling) and it's quite not stable. We will eventually publish a 2-0-stable branch for a clean/stable version of that branch.

I tested 1-0-stable, and it should not throw this error.

Also, this error thrown because in the feature-models branch, you are missing some files (which is too big for git an we didn't put it there.)

You can still do following to clean it:

1) Open it in Xcode and you will see under models folder, there are many pb files marked as red (due to it's too big and we don't put it here) 2) Choose all the red ones and right click, then delete them 3) change this line to let builtInModels = ["squeezeNet"] Then you will have no trouble.

Or, you can download for example tinyYoloInit.pb/tinyYoloPredict.pb in this repo: https://github.com/KleinYuan/caffe2-yolo

And do similar thing, remove whatever is not available or whatever you don't need.

In summary, the issue is that model files are missing and this branch is still under developing. Sorry for the confusion and we will publish 2-0-stable ASAP. :) hope helpful.

dawand commented 7 years ago

Thank you very much for the detailed explanation 👍 Keep going 💯

KleinYuan commented 7 years ago

@dawand thanks for your appreciation and feel free to ask any question here. Also if you like it, star us to encourage us. :)

KleinYuan commented 7 years ago

@dawand hey man, I actually thought about it and it seems that also possible that your caffe2 build is not successful. Could you double check on that. If everything build successfully, you will see that file in here: screen shot 2017-05-13 at 10 44 05 am

I have a friend having the same issue and please check following stuff are done:

You should not have any problem if those are done.

lihuoran commented 6 years ago

@KleinYuan Hi, I met the same error today when I was trying to build the Caffe2-iOS. When I run setup.sh, there is an error:

CMake Error at cmake/External/nnpack.cmake:102 (add_library):
  Cannot find source file:

    /Users/lihuoran/home/workspace/dl-on-mobile/demos/Caffe2-iOS/src/caffe2/third_party/NNPACK/src/psimd/fft-block-mac.c

  Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp
  .hxx .in .txx
Call Stack (most recent call first):
  cmake/Dependencies.cmake:52 (include)
  CMakeLists.txt:85 (include)

CMake Error: Cannot determine link language for target "CAFFE2_NNPACK".
CMake Error: CMake can not determine linker language for target: CAFFE2_NNPACK

Do you know what is going on and how to fix it? Thanks!

varunlakshmanan commented 6 years ago

@KleinYuan I am having the same exact problem as described above by @lihuoran when I run setup.sh. (This Imgur album has three images that show all of the errors and warnings I'm receiving in Terminal when running setup.sh. They are in chronological order from first image to third image.) In addition, I'm also getting these two warnings:

WARNING: Target "libprotoc" has EXCLUDE_FROM_ALL set and will not be built by default but an install rule has been provided for it. CMake does not define behavior for this case.

WARNING: Target "protoc" has EXCLUDE_FROM_ALL set and will not be built by default but an install rule has been provided for it. CMake does not define behavior for this case.

@lihuoran Please let me know if you find a solution to this error.

smoosh911 commented 6 years ago

Was there ever a fix for this issue?

I tried looking at https://github.com/KleinYuan/Caffe2-iOS/issues/23 but this isn't doing it for me either