How to build and use Google TensorFlow C++ api
One alternative to using Tensorflow C++ API I found is to use cppflow.
It's a lightweight C++ wrapper around Tensorflow C API. You get very small executables and it links against the libtensorflow.so
already compiled file. There are also examples of use and you use CMAKE instead of Bazel.
Is it possible to use TensorFlow C++ API on Windows?
It is certainly possible to use TensorFlow's C++ API on Windows, but it is not currently very easy. Right now, the easiest way to build against the C++ API on Windows would be to build with CMake, and adapt the CMake rules for the tf_tutorials_example_trainer
project (see the source code here). Building with CMake will give you a Visual Studio project in which you can implement your C++ TensorFlow program.
Note that the tf_tutorials_example_trainer
project builds a Console Application that statically links all of the TensorFlow runtime into your program. At present we have not written the necessary rules to create a reusable TensorFlow DLL, although this would be technially possible: for example, the Python extension is a DLL that includes the runtime, but does not export the necessary symbols to use TensorFlow's C or C++ APIs directly.
Installing C API for Tensorflow on Macbook M1
Here's a guide on how to build a version from scratch since outdated or legacy versions of software typically are harder to install especially when it comes to libraries.
Related Topics
Vector of Const Objects Giving Compile Error
C++ Array Assignment of Multiple Values
Shared-Memory Ipc Synchronization (Lock-Free)
Variadic Function Template with Pack Expansion Not in Last Parameter
Why Do Compilers Allow String Literals Not to Be Const
Overloading Operator<<: Cannot Bind Lvalue to 'Std::Basic_Ostream<Char>&&'
How Does One Securely Clear Std::String
Why Is It Allowed to Pass R-Values by Const Reference But Not by Normal Reference
How to Make C++ Cout Not Use Scientific Notation
Gcc C++ "Hello World" Program -> .Exe Is 500Kb Big When Compiled on Windows. How to Reduce Its Size
Stack Overflow Caused by Recursive Function
Scope of Variables in If Statements
C++ Compare Char Array with String
Void Pointers: Difference Between C and C++
C++, Usleep() Is Obsolete, Workarounds for Windows/Mingw
How to Use Member Initialization List to Initialize an Array