I want to know what all header files are required in order to use Tensorflow's C++ APIs. Like in case of C APIs, there is just a single header c_api.h which has all the functions, etc. declared, is there any such single header for C++ APIs? I tried searching this, but unable to understand what is required and what is not.
There is a huge list of headers in tensorflow/cc, tensorflow/core and tensorflow/c which are used to build libtensorflow_cc.so and we also ship most of these in the tensorflow's distribution (By TF's distribution I mean TF which is built using bazel build -c opt --config=cuda //tensorflow/tools/pip_package:build_pip_package
). Is that list of headers sufficient in order to use C++ API? or do we need to build any additional target in tensorflow/BUILD?
I've also gone through https://www.tensorflow.org/api_docs/cc/ but can't really make out the exact list of required headers.
In one of the related posts, I found that tensorflow/bazel-genfiles contain the required headers. Please confirm this.
Thanks in advance, Nishidha
For those who are building TensorFlow v2 C++ for Windows using bazel, kindly use
bazel build --config=opt tensorflow:install_headers
This will generate an include
folder with the cc header files in bazel-bin/tensorflow/
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With