Run the TensorFlow MNIST model in Android application.
You need to install the following tools in advance.
- Android SDK
- Android NDK
- Bazel
Fix WORKSPACE.
android_sdk_repository(
name="androidsdk",
path="</absolute/path/to/android-sdk>",
api_level = <api level>,
)
android_ndk_repository(
name = "androidndk",
path = "</absolute/path/to/android-ndk>",
api_level = 21,
)
Please install the following items.
- SDK Platform Tools for specified version
- SDK Build Tools
- Google Support Library
Run build.
bazel build app:net.ornew.mnist.appnet.ornew.mnist.app.apk is generated in ./bazel-bin/app/.
If you want to install the application:
bazel mobile-install app:net.ornew.mnist.appor
adb install -r bazel-bin/app/net.ornew.mnist.app.apkYou need to install the following tools.
- python
- TensorFlow
cd model
python mnist.pymnist.frozen.pb is generated in model/dist/.
Arata Furukawa <info@ornew.net>