You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

README.md 2.1 kB

6 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. TensorFlow.NET pack all required libraries in architecture-specific assemblies folders per NuGet standard [Deprecated] .
  2. We changed to use `Microsoft.ML.TensorFlow.Redist` to maintain the TensorFlow library.
  3. ### Download manually
  4. Here are some pre-built TensorFlow binaries you can use for each platform:
  5. - Linux
  6. - CPU-only: https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-linux-x86_64-1.14.0.tar.gz
  7. - GPU-enabled: https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-gpu-linux-x86_64-1.14.0.tar.gz
  8. - Mac: https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-darwin-x86_64-1.14.0.tar.gz
  9. - Windows
  10. - CPU-only: https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-windows-x86_64-1.14.0.zip
  11. - GPU-enabled: https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-gpu-windows-x86_64-1.14.0.zip
  12. ### Run in Linux
  13. `Install-Package TensorFlow.NET`
  14. Download Linux pre-built library and unzip `libtensorflow.so` and `libtensorflow_framework.so` into current running directory.
  15. ### Run in Mac OS
  16. ### GPU Tensorflow for windows
  17. Before running verify you installed CUDA and cuDNN
  18. ### Build from source for Windows
  19. https://www.tensorflow.org/install/source_windows
  20. pacman -S git patch unzip
  21. 1. Build static library
  22. `bazel build --config=opt //tensorflow:libtensorflow.so`
  23. 2. Build pip package
  24. `bazel build --config=opt //tensorflow/tools/pip_package:build_pip_package`
  25. 3. Generate pip installation file
  26. `bazel-bin\tensorflow\tools\pip_package\build_pip_package C:/tmp/tensorflow_pkg`
  27. 4. Install from local wheel file.
  28. `pip install C:/tmp/tensorflow_pkg/tensorflow-1.14.0-cp36-cp36m-win_amd64.whl`
  29. ### Export more APIs
  30. Add more api to `c_api.h`
  31. ```c++
  32. TF_CAPI_EXPORT extern void AddControlInput(TF_Graph* graph, TF_Operation* op, TF_Operation* input);
  33. TF_CAPI_EXPORT extern void UpdateEdge(TF_Graph* graph, TF_Output new_src, TF_Input dst, TF_Status* status);
  34. TF_CAPI_EXPORT extern void RemoveAllControlInputs(TF_Graph* graph, TF_Operation* op);
  35. ```