TensorFlow-iOS-Example
TensorFlow-iOS-Example copied to clipboard
#import <tensorflow/core/public/session.h> error
'tensorflow/core/public/session.h' file not found
Sounds like you didn't set up the header search paths in the project settings (or did so incorrectly), so Xcode cannot find the TensorFlow header files.
actually, I did this as following:
-
You'll need to add the library at
tensorflow/contrib/lite/gen/lib/libtensorflow-lite.a
to your linking build stage(target->building phases->link binary with libraries), and addtensorflow/contrib/lite/gen/lib
to the building settings-> Library Search Paths setting. -
The building settings-> Header Search paths needs to contain the root folder of tensorflow:
-
tensorflow/contrib/lite/downloads
-
tensorflow/contrib/lite/downloads/flatbuffers/include
-
I don't know if there is any difference between your settings and mine~
thank!!
My article was written before TF-Lite existed, so it's possible the instructions are not 100% correct for this new version of TensorFlow.