commit | 5c9704fd7fe9e09f2797027f692d321455ae2c7d | [log] [tgz] |
---|---|---|
author | Cole Faust <colefaust@google.com> | Mon Nov 27 19:31:15 2023 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Mon Nov 27 19:31:15 2023 +0000 |
tree | 1b6515691e15a498044b385dca5ed3761a7c99a6 | |
parent | 08328687fbb2018e2f9787b3468d33ae1c5d2d96 [diff] | |
parent | 41457e085c2291368c38fa96fa142abae7e94bae [diff] |
Sandbox tflite-support genrules am: 41457e085c Original change: https://android-review.googlesource.com/c/platform/external/tflite-support/+/2841742 Change-Id: I36f18813ce5b7573ea837926fe406b4027ed7fee Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
TFLite Support is a toolkit that helps users to develop ML and deploy TFLite models onto mobile devices. It works cross-Platform and is supported on Java, C++ (WIP), and Swift (WIP). The TFLite Support project consists of the following major components:
TFLite Support library serves different tiers of deployment requirements from easy onboarding to fully customizable. There are three major use cases that TFLite Support targets at:
Provide ready-to-use APIs for users to interact with the model.
This is achieved by the TFLite Support Codegen tool, where users can get the model interface (contains ready-to-use APIs) simply by passing the model to the codegen tool. The automatic codegen strategy is designed based on the TFLite metadata.
Provide optimized model interface for popular ML tasks.
The model interfaces provided by the TFLite Support Task Library are specifically optimized compared to the codegen version in terms of both usability and performance. Users can also swap their own custom models with the default models in each task.
Provide the flexibility to customize model interface and build inference pipelines.
The TFLite Support Util Library contains varieties of util methods and data structures to perform pre/post processing and data conversion. It is also designed to match the behavior of TensorFlow modules, such as TF.Image and TF.text, ensuring consistency from training to inferencing.
See the documentation on tensorflow.org for more instruction and examples.
We use Bazel to build the project. When you're building the Java (Android) Utils, you need to set up following env variables correctly:
ANDROID_NDK_HOME
ANDROID_SDK_HOME
ANDROID_NDK_API_LEVEL
ANDROID_SDK_API_LEVEL
ANDROID_BUILD_TOOLS_VERSION
Let us know what you think about TFLite Support by creating a new Github issue, or email us at tflite-support-team@google.com.