├── .github └── workflows │ ├── cmsis-pack-examples-push.yml │ └── cmsis-pack-examples-zip.yml ├── .gitignore ├── LICENSE ├── README.md ├── armnn-mobilenet-android ├── .gitignore ├── .idea │ ├── .name │ ├── codeStyles │ │ └── Project.xml │ ├── gradle.xml │ ├── jarRepositories.xml │ ├── misc.xml │ ├── runConfigurations.xml │ └── vcs.xml ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── arm │ │ │ └── visualrecognizer │ │ │ └── ExampleInstrumentedTest.java │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── assets │ │ │ ├── labels.txt │ │ │ └── mobilenet_v2_1.0_224_quantized_1_default_1.tflite │ │ ├── java │ │ │ └── com │ │ │ │ └── arm │ │ │ │ └── visualrecognizer │ │ │ │ ├── MainActivity.java │ │ │ │ └── Recognizer.java │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ ├── ic_launcher_background.xml │ │ │ └── ic_liveview.xml │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── arm │ │ └── visualrecognizer │ │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── armnn-style-transfer-android ├── AUTHORS ├── CONTRIBUTORS ├── README.md ├── app │ ├── .DS_Store │ ├── .gitignore │ ├── app.iml │ ├── assets │ │ ├── des_glaneuses.tflite │ │ ├── la_muse.tflite │ │ ├── mirror.tflite │ │ ├── udnie.tflite │ │ └── wave_crop.tflite │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── .DS_Store │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── arm │ │ │ └── styletransfer │ │ │ └── ExampleInstrumentedTest.java │ │ ├── main │ │ ├── .DS_Store │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ ├── .DS_Store │ │ │ └── com │ │ │ │ ├── .DS_Store │ │ │ │ └── arm │ │ │ │ └── styletransfer │ │ │ │ ├── ImageClassifierActivity.java │ │ │ │ ├── ImagePreprocessor.java │ │ │ │ ├── MainActivity.java │ │ │ │ ├── PicturePreviewActivity.java │ │ │ │ ├── StylerService.java │ │ │ │ ├── TensorFlowHelper.java │ │ │ │ └── TensorFlowImageStyleTranfer.java │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ ├── ic_launcher_background.xml │ │ │ ├── image_des_glaneuses.jpeg │ │ │ ├── image_la_muse.png │ │ │ ├── image_mirror.jpeg │ │ │ ├── image_udnie.jpg │ │ │ └── image_wave_crop.jpg │ │ │ ├── layout │ │ │ ├── activity_imageclassifier.xml │ │ │ ├── activity_main.xml │ │ │ └── activity_picturepreview.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ └── ic_launcher_foreground.png │ │ │ ├── mipmap-mdpi │ │ │ └── ic_launcher_foreground.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ ├── ic_launcher_foreground.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ └── ic_launcher_foreground.png │ │ │ ├── mipmap-xxxhdpi │ │ │ └── ic_launcher_foreground.png │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── arm │ │ └── styletransfer │ │ └── ExampleUnitTest.java ├── armnn-style-transfer-android.iml ├── armnn-styletransfer.iml ├── build.gradle ├── gradle.properties ├── gradle │ ├── .DS_Store │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── local.properties ├── settings.gradle └── styletransferapp.iml ├── cmsis-pack-examples ├── .ci │ ├── README.md │ └── vcpkg-configuration.json ├── .clang-format ├── .github │ └── workflows │ │ ├── AVH-FVP-CI.yml │ │ └── Hardware-CI.yml ├── .vscode │ ├── launch.json │ └── tasks.json ├── LICENSE ├── README.md ├── cdefault.yml ├── common │ ├── common.clayer.yml │ └── include │ │ ├── BufAttributes.hpp │ │ └── ethosu_mem_config.h ├── device │ ├── alif-ensemble │ │ ├── alif-ensemble-E7-device.clayer.yml │ │ ├── include │ │ │ ├── BoardAudioUtils.hpp │ │ │ ├── BoardInit.hpp │ │ │ ├── BoardPlotUtils.hpp │ │ │ ├── CameraCapture.hpp │ │ │ ├── GpioSignal.hpp │ │ │ └── LcdDisplay.hpp │ │ └── src │ │ │ ├── BoardAudioUtils.cpp │ │ │ ├── BoardInit.cpp │ │ │ ├── BoardPlotUtils.cpp │ │ │ ├── CameraCapture.cpp │ │ │ ├── GpioSignal.cpp │ │ │ ├── LcdDisplay.cpp │ │ │ ├── gpio_wrapper.c │ │ │ ├── gpio_wrapper.h │ │ │ ├── retarget.c │ │ │ ├── uart_stdout.c │ │ │ └── uart_stdout.h │ ├── corstone │ │ ├── corstone-device.clayer.yml │ │ ├── fvp-configs │ │ │ ├── mps3_fvp_config.txt │ │ │ └── mps4_fvp_config.txt │ │ ├── include │ │ │ └── BoardInit.hpp │ │ ├── src │ │ │ ├── BoardInit.cpp │ │ │ ├── retarget.c │ │ │ ├── uart_cmsdk_apb.c │ │ │ ├── uart_config.h │ │ │ └── uart_stdout.h │ │ └── vsi │ │ │ ├── include │ │ │ └── arm_vsi.h │ │ │ ├── provenance.md │ │ │ ├── video │ │ │ ├── include │ │ │ │ └── video_drv.h │ │ │ ├── python │ │ │ │ ├── arm_vsi4.py │ │ │ │ ├── arm_vsi5.py │ │ │ │ ├── arm_vsi6.py │ │ │ │ ├── arm_vsi7.py │ │ │ │ ├── vsi_video.py │ │ │ │ └── vsi_video_server.py │ │ │ └── source │ │ │ │ └── video_drv.c │ │ │ └── vsi.clayer.yml │ ├── frdm-k64f │ │ ├── frdm-k64f-device.clayer.yml │ │ ├── include │ │ │ └── BoardInit.hpp │ │ └── src │ │ │ ├── BoardInit.cpp │ │ │ ├── retarget.c │ │ │ ├── uart_stdout.c │ │ │ └── uart_stdout.h │ └── stm32f746-discovery │ │ ├── include │ │ ├── BoardAudioUtils.hpp │ │ ├── BoardInit.hpp │ │ └── BoardPlotUtils.hpp │ │ ├── src │ │ ├── BoardAudioUtils.cpp │ │ ├── BoardInit.cpp │ │ ├── BoardPlotUtils.cpp │ │ ├── retarget.c │ │ ├── stm32f7xx │ │ │ └── drivers │ │ │ │ └── cmsis │ │ │ │ └── device │ │ │ │ ├── LICENSE.txt │ │ │ │ ├── Readme.md │ │ │ │ ├── startup_stm32f746xx.s │ │ │ │ └── system_stm32f7xx.c │ │ ├── uart_stdout.c │ │ └── uart_stdout.h │ │ └── stm32f746-discovery-device.clayer.yml ├── docs │ ├── 01-install-cmsis-packs.png │ └── 02-build-run.png ├── kws │ ├── include │ │ ├── InputFiles.hpp │ │ └── Labels.hpp │ ├── kws.cproject.yml │ ├── linker │ │ ├── alif-e7-m55-he.sct │ │ ├── frdm-k64f.sct │ │ ├── mps3-sse-300.sct │ │ ├── mps3-sse-310.sct │ │ ├── mps4-sse-315.sct │ │ └── stm32f746-disco.sct │ └── src │ │ ├── InputFiles.cpp │ │ ├── Labels.cpp │ │ ├── kws_micronet_m.tflite.cpp │ │ ├── kws_micronet_m_vela_H128.tflite.cpp │ │ ├── kws_micronet_m_vela_H256.tflite.cpp │ │ ├── kws_micronet_m_vela_Y256.tflite.cpp │ │ ├── kws_micronet_m_vela_Z256.tflite.cpp │ │ ├── main_live.cpp │ │ ├── main_wav.cpp │ │ └── sample_audio.cpp ├── mlek.csolution.yml ├── object-detection │ ├── include │ │ └── InputFiles.hpp │ ├── linker │ │ ├── alif-e7-m55-hp.sct │ │ ├── mps3-sse-300.sct │ │ ├── mps3-sse-310.sct │ │ └── mps4-sse-315.sct │ ├── object-detection.clayer.yml │ ├── object-detection.cproject.yml │ └── src │ │ ├── InputFiles.cpp │ │ ├── main_live.cpp │ │ ├── main_static.cpp │ │ ├── main_vsi.cpp │ │ ├── sample_image.cpp │ │ ├── yolo-fastest_192_face_v4.tflite.cpp │ │ ├── yolo-fastest_192_face_v4_vela_H256.tflite.cpp │ │ ├── yolo-fastest_192_face_v4_vela_Y256.tflite.cpp │ │ └── yolo-fastest_192_face_v4_vela_Z256.tflite.cpp ├── resources │ ├── files.md │ ├── sample_audio.wav │ └── sample_image.png └── vcpkg-configuration.json ├── ethos-u-corstone-300 ├── README.md └── train_and_deploy.ipynb ├── ethos-u-microspeech ├── MicroSpeech-EthosU55.ipynb └── README.md ├── kleidiai-examples ├── audiogen │ ├── .gitignore │ ├── README.md │ ├── app │ │ ├── CMakeLists.txt │ │ ├── README.md │ │ └── audiogen.cpp │ ├── install_requirements.sh │ ├── model.png │ └── scripts │ │ ├── README.md │ │ ├── export_conditioners.py │ │ ├── export_dit_autoencoder.py │ │ └── utils_load_model.py └── llama_cpp │ ├── 0001-Use-KleidiAI-Int4-Matmul-micro-kernels-in-llama.cpp.patch │ ├── LICENSE │ └── README.md ├── multi-gesture-recognition ├── LICENSE ├── README.md ├── audio │ ├── README.md │ ├── alarm-active.wav │ ├── good-evening.wav │ └── good-night.wav ├── camera.py ├── classify.py ├── merge.py ├── preview.py ├── record.py ├── run.py ├── story.py ├── test.py ├── train.py └── validate_split.py ├── pruning-clustering-ethos-u ├── README.md ├── pruning_clustering_for_Arm_Ethos_U55_U65.ipynb └── resources │ └── pruning_clustering.png ├── pyarmnn-fire-detection ├── README.md ├── fire_detection.tflite ├── predict_pyarmnn.py └── predict_tflite.py ├── pytorch-to-tflite ├── PyTorch_to_TensorFlow_Lite.ipynb ├── README.md └── resources │ ├── onnx_model.png │ ├── pad.png │ ├── pytorch_arm_ethos_flow.png │ ├── pytorch_model.png │ ├── relu6.png │ ├── reshape.png │ ├── transpose.png │ └── vela.png ├── rnn-unrolling-tflite ├── README.md ├── RNN_models_for_Arm_Ethos_U55_U65.ipynb └── resources │ ├── gru_network.png │ ├── rnn.png │ └── unroll.png ├── tflm-cmsisnn-mbed-image-recognition ├── CMakeLists.txt ├── LICENSE ├── README.md ├── clean.sh ├── generate_cmake_files.sh ├── image_recognition │ ├── CMakeLists.txt │ ├── image_dims.h │ ├── image_provider.h │ ├── image_recognition_model.h │ ├── image_recognition_model │ │ ├── LICENSE-2.0.txt │ │ └── image_recognition_model.cc │ ├── main.cpp │ ├── stm32f746_discovery │ │ ├── display_util.cc │ │ ├── display_util.h │ │ ├── image_provider.cc │ │ ├── image_util.cc │ │ └── image_util.h │ ├── test.cpp │ └── util.h ├── mbed-os.lib ├── mbed_app.json ├── patches │ ├── 0001-Drivers-patch.patch │ └── 0001-profiler.patch ├── requirements.txt ├── setup.sh └── test_performance.sh ├── tflu-kws-cortex-m ├── LICENSE └── README.md └── yeah-world ├── LICENSE ├── README.md ├── camera.py ├── mnet.pb ├── pinet.py ├── preview.py ├── randomsound.py ├── record.py ├── run.py ├── sounds ├── 1_person_cheering-Jett_Rifkin-1851518140.wav ├── 5_Sec_Crowd_Cheer-Mike_Koenig-1562033255.wav ├── Applause-SoundBible.com-151138312.wav └── README.md └── train.py /.github/workflows/cmsis-pack-examples-push.yml: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2022-2023 Arm Limited. All rights reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | name: Sync CMSIS-pack example project into Arm-Examples repo 17 | 18 | on: 19 | workflow_dispatch: 20 | push: 21 | branches: 22 | - main 23 | paths: 24 | - cmsis-pack-examples/** 25 | 26 | 27 | jobs: 28 | publish-cmsis-examples: 29 | runs-on: ubuntu-latest 30 | steps: 31 | - name: Checkout 32 | uses: actions/checkout@v3 33 | - name: Fetch action 34 | id: get-cmsis-pack-files 35 | uses: Rishabh510/Path-lister-action@1.0 36 | with: 37 | path: "cmsis-pack-examples/" 38 | type: ".yml" 39 | - name: Pushes to another repository 40 | uses: cpina/github-action-push-to-another-repository@v1.5.1 41 | env: 42 | API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} 43 | with: 44 | source-directory: 'cmsis-pack-examples' 45 | destination-github-username: 'Arm-Examples' 46 | destination-repository-name: 'mlek-cmsis-pack-examples' 47 | user-email: 'github-actions@arm.com' 48 | target-branch: 'main' 49 | 50 | -------------------------------------------------------------------------------- /.github/workflows/cmsis-pack-examples-zip.yml: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2022 Arm Limited. All rights reserved. 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | # Licensed under the Apache License, Version 2.0 (the "License"); 5 | # you may not use this file except in compliance with the License. 6 | # You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | name: Publish CMSIS-pack example project zip file 17 | 18 | on: 19 | workflow_dispatch: 20 | push: 21 | branches: 22 | - main 23 | paths: 24 | - cmsis-pack-examples/** 25 | 26 | jobs: 27 | zip-files: 28 | runs-on: ubuntu-latest 29 | steps: 30 | - uses: actions/checkout@v2 31 | - uses: vimtor/action-zip@v1 32 | with: 33 | files: cmsis-pack-examples/ 34 | recursive: true 35 | dest: cmsis-pack-examples.zip 36 | - name: Create Release 37 | id: create_release 38 | uses: actions/create-release@v1 39 | env: 40 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token 41 | with: 42 | tag_name: ${{ github.run_id }} 43 | release_name: Release ${{ github.run_id }} 44 | body: | 45 | CMSIS example packs release 46 | prerelease: false 47 | draft: false 48 | - name: Upload Release Asset 49 | id: upload-release-asset 50 | uses: actions/upload-release-asset@v1 51 | env: 52 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 53 | with: 54 | upload_url: ${{ steps.create_release.outputs.upload_url }} 55 | asset_path: ${{ github.workspace }}/cmsis-pack-examples.zip 56 | asset_name: cmsis-pack-examples.zip 57 | asset_content_type: application/zip 58 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *.py[cod] 4 | *$py.class 5 | 6 | # C extensions 7 | *.so 8 | 9 | # Distribution / packaging 10 | .Python 11 | env/ 12 | build/ 13 | develop-eggs/ 14 | dist/ 15 | downloads/ 16 | eggs/ 17 | .eggs/ 18 | lib/ 19 | lib64/ 20 | parts/ 21 | sdist/ 22 | var/ 23 | wheels/ 24 | *.egg-info/ 25 | .installed.cfg 26 | *.egg 27 | 28 | # PyInstaller 29 | # Usually these files are written by a python script from a template 30 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 31 | *.manifest 32 | *.spec 33 | 34 | # Installer logs 35 | pip-log.txt 36 | pip-delete-this-directory.txt 37 | 38 | # Unit test / coverage reports 39 | htmlcov/ 40 | .tox/ 41 | .coverage 42 | .coverage.* 43 | .cache 44 | nosetests.xml 45 | coverage.xml 46 | *.cover 47 | .hypothesis/ 48 | 49 | # Translations 50 | *.mo 51 | *.pot 52 | 53 | # Django stuff: 54 | *.log 55 | local_settings.py 56 | 57 | # Flask stuff: 58 | instance/ 59 | .webassets-cache 60 | 61 | # Scrapy stuff: 62 | .scrapy 63 | 64 | # Sphinx documentation 65 | docs/_build/ 66 | 67 | # PyBuilder 68 | target/ 69 | 70 | # Jupyter Notebook 71 | .ipynb_checkpoints 72 | 73 | # pyenv 74 | .python-version 75 | 76 | # celery beat schedule file 77 | celerybeat-schedule 78 | 79 | # SageMath parsed files 80 | *.sage.py 81 | 82 | # dotenv 83 | .env 84 | 85 | # virtualenv 86 | .venv 87 | venv/ 88 | ENV/ 89 | 90 | # Spyder project settings 91 | .spyderproject 92 | .spyproject 93 | 94 | # Rope project settings 95 | .ropeproject 96 | 97 | # vscode projet settings 98 | .vscode/ 99 | 100 | # mkdocs documentation 101 | /site 102 | 103 | # mypy 104 | .mypy_cache/ 105 | 106 | # targets 107 | mnist 108 | mnist_caffe 109 | 110 | # CMSIS-tools or packs based: 111 | packlist.txt 112 | **/.clangd 113 | *.cprj 114 | RTE/ 115 | out/ 116 | tmp/ 117 | *.cbuild.yml 118 | *.cbuild-idx.yml 119 | *.cbuild-pack.yml 120 | *.cbuild-set.yml 121 | 122 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/caches 5 | /.idea/libraries 6 | /.idea/modules.xml 7 | /.idea/workspace.xml 8 | /.idea/navEditor.xml 9 | /.idea/assetWizardSettings.xml 10 | .DS_Store 11 | /build 12 | /captures 13 | .externalNativeBuild 14 | .cxx 15 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/.idea/.name: -------------------------------------------------------------------------------- 1 | MobileNet Test -------------------------------------------------------------------------------- /armnn-mobilenet-android/.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 20 | 21 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/.idea/jarRepositories.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 9 | 10 | 14 | 15 | 19 | 20 | 24 | 25 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 9 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 30 5 | buildToolsVersion "30.0.2" 6 | compileOptions { 7 | sourceCompatibility JavaVersion.VERSION_1_8 8 | targetCompatibility JavaVersion.VERSION_1_8 9 | } 10 | aaptOptions { 11 | noCompress "tflite" 12 | } 13 | 14 | defaultConfig { 15 | applicationId "com.arm.visualrecognizer" 16 | minSdkVersion 28 17 | targetSdkVersion 30 18 | versionCode 1 19 | versionName "1.0" 20 | 21 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 22 | } 23 | 24 | buildTypes { 25 | release { 26 | minifyEnabled false 27 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 28 | } 29 | } 30 | } 31 | 32 | dependencies { 33 | implementation fileTree(dir: "libs", include: ["*.jar"]) 34 | implementation 'androidx.appcompat:appcompat:1.2.0' 35 | implementation 'androidx.constraintlayout:constraintlayout:2.0.1' 36 | testImplementation 'junit:junit:4.12' 37 | androidTestImplementation 'androidx.test.ext:junit:1.1.2' 38 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0' 39 | implementation 'org.tensorflow:tensorflow-lite:0.0.0-nightly' 40 | implementation 'org.tensorflow:tensorflow-lite-gpu:0.0.0-nightly' 41 | implementation 'org.tensorflow:tensorflow-lite-support:0.0.0-nightly' 42 | 43 | } -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/androidTest/java/com/arm/visualrecognizer/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.arm.visualrecognizer; 2 | 3 | import android.content.Context; 4 | 5 | import androidx.test.platform.app.InstrumentationRegistry; 6 | import androidx.test.ext.junit.runners.AndroidJUnit4; 7 | 8 | import org.junit.Test; 9 | import org.junit.runner.RunWith; 10 | 11 | import static org.junit.Assert.*; 12 | 13 | /** 14 | * Instrumented test, which will execute on an Android device. 15 | * 16 | * @see Testing documentation 17 | */ 18 | @RunWith(AndroidJUnit4.class) 19 | public class ExampleInstrumentedTest { 20 | @Test 21 | public void useAppContext() { 22 | // Context of the app under test. 23 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 24 | assertEquals("com.arm.visualrecognizer", appContext.getPackageName()); 25 | } 26 | } -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/assets/mobilenet_v2_1.0_224_quantized_1_default_1.tflite: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/assets/mobilenet_v2_1.0_224_quantized_1_default_1.tflite -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/drawable-v24/ic_launcher_foreground.xml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 9 | 15 | 18 | 21 | 22 | 23 | 24 | 30 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/drawable/ic_liveview.xml: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #6200EE 4 | #3700B3 5 | #03DAC5 6 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | MobileNet Test 3 | Select Image 4 | Classification 5 | Use NNAPI 6 | Confidence 7 | Execution Time 8 | Uncertain 9 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 9 | 10 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/app/src/test/java/com/arm/visualrecognizer/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.arm.visualrecognizer; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /armnn-mobilenet-android/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | buildscript { 3 | repositories { 4 | google() 5 | jcenter() 6 | } 7 | dependencies { 8 | classpath "com.android.tools.build:gradle:4.0.1" 9 | 10 | // NOTE: Do not place your application dependencies here; they belong 11 | // in the individual module build.gradle files 12 | } 13 | } 14 | 15 | allprojects { 16 | repositories { 17 | google() 18 | jcenter() 19 | } 20 | } 21 | 22 | task clean(type: Delete) { 23 | delete rootProject.buildDir 24 | } -------------------------------------------------------------------------------- /armnn-mobilenet-android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx2048m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # AndroidX package structure to make it clearer which packages are bundled with the 15 | # Android operating system, and which are packaged with your app"s APK 16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 17 | android.useAndroidX=true 18 | # Automatically convert third-party libraries to use AndroidX 19 | android.enableJetifier=true -------------------------------------------------------------------------------- /armnn-mobilenet-android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-mobilenet-android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /armnn-mobilenet-android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Sun Oct 04 21:09:11 EDT 2020 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.1.1-all.zip 7 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 11 | set DIRNAME=%~dp0 12 | if "%DIRNAME%" == "" set DIRNAME=. 13 | set APP_BASE_NAME=%~n0 14 | set APP_HOME=%DIRNAME% 15 | 16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 17 | set DEFAULT_JVM_OPTS= 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windows variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | 53 | :win9xME_args 54 | @rem Slurp the command line arguments. 55 | set CMD_LINE_ARGS= 56 | set _SKIP=2 57 | 58 | :win9xME_args_slurp 59 | if "x%~1" == "x" goto execute 60 | 61 | set CMD_LINE_ARGS=%* 62 | 63 | :execute 64 | @rem Setup the command line 65 | 66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 67 | 68 | @rem Execute Gradle 69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 70 | 71 | :end 72 | @rem End local scope for the variables with windows NT shell 73 | if "%ERRORLEVEL%"=="0" goto mainEnd 74 | 75 | :fail 76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 77 | rem the _cmd.exe /c_ return code! 78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 79 | exit /b 1 80 | 81 | :mainEnd 82 | if "%OS%"=="Windows_NT" endlocal 83 | 84 | :omega 85 | -------------------------------------------------------------------------------- /armnn-mobilenet-android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | rootProject.name = "MobileNet Test" -------------------------------------------------------------------------------- /armnn-style-transfer-android/AUTHORS: -------------------------------------------------------------------------------- 1 | 2 | # This is the official list of LiveStyle with Arm NN authors for copyright purposes. 3 | # This file is distinct from the CONTRIBUTORS files. 4 | # See the latter for an explanation. 5 | 6 | # Names should be added to this file as: 7 | # Name or Organization 8 | # The email address is not required for organizations. 9 | 10 | Manuel Bottini 11 | Sicong Li 12 | Giuseppe Rossini 13 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This is the official list of LiveStyle with Arm NN contributors for copyright purposes. 2 | # This file is distinct from the AUTHORS files. 3 | # See the latter for an explanation. 4 | 5 | # Names should be added to this file as: 6 | # Name or Organization 7 | # The email address is not required for organizations. 8 | 9 | Wei Xiao 10 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/.DS_Store -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/assets/des_glaneuses.tflite: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/assets/des_glaneuses.tflite -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/assets/la_muse.tflite: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/assets/la_muse.tflite -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/assets/mirror.tflite: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/assets/mirror.tflite -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/assets/udnie.tflite: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/assets/udnie.tflite -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/assets/wave_crop.tflite: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/assets/wave_crop.tflite -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 28 5 | buildToolsVersion "28.0.3" 6 | defaultConfig { 7 | applicationId "com.arm.livestyleapp" 8 | minSdkVersion 24 9 | targetSdkVersion 28 10 | versionCode 1 11 | versionName "1.0" 12 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 13 | } 14 | buildTypes { 15 | release { 16 | minifyEnabled false 17 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 18 | } 19 | } 20 | sourceSets { 21 | main { 22 | assets.srcDirs = ['./assets'] 23 | } 24 | } 25 | aaptOptions { 26 | noCompress "tflite" 27 | } 28 | } 29 | 30 | repositories { 31 | jcenter() 32 | } 33 | 34 | dependencies { 35 | implementation fileTree(dir: 'libs', include: ['*.jar']) 36 | implementation 'androidx.appcompat:appcompat:1.0.2' 37 | implementation 'org.tensorflow:tensorflow-lite:0.0.0-nightly' 38 | implementation 'androidx.constraintlayout:constraintlayout:1.1.3' 39 | testImplementation 'junit:junit:4.12' 40 | androidTestImplementation 'androidx.test:runner:1.2.0' 41 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' 42 | } 43 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/.DS_Store -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/androidTest/java/com/arm/styletransfer/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.arm.livestyleapp; 2 | 3 | import android.content.Context; 4 | 5 | import androidx.test.InstrumentationRegistry; 6 | import androidx.test.runner.AndroidJUnit4; 7 | 8 | import org.junit.Test; 9 | import org.junit.runner.RunWith; 10 | 11 | import static org.junit.Assert.*; 12 | 13 | /** 14 | * Instrumented test, which will execute on an Android device. 15 | * 16 | * @see Testing documentation 17 | */ 18 | @RunWith(AndroidJUnit4.class) 19 | public class ExampleInstrumentedTest { 20 | @Test 21 | public void useAppContext() { 22 | // Context of the app under test. 23 | Context appContext = InstrumentationRegistry.getTargetContext(); 24 | 25 | assertEquals("com.arm.styletransferapp", appContext.getPackageName()); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/.DS_Store -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 23 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/java/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/java/.DS_Store -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/java/com/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/java/com/.DS_Store -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/java/com/arm/styletransfer/MainActivity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright © 2019 Arm Ltd. All rights reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | package com.arm.styletransfer; 6 | 7 | import androidx.appcompat.app.AppCompatActivity; 8 | 9 | import android.content.Intent; 10 | import android.os.Bundle; 11 | import android.view.View; 12 | import android.widget.ImageButton; 13 | 14 | import com.arm.styletransferapp.R; 15 | 16 | public class MainActivity extends AppCompatActivity implements View.OnClickListener { 17 | 18 | private ImageButton mMainDesGlaneusesButton; 19 | private ImageButton mMainLaMuseButton; 20 | private ImageButton mMainMirrorButton; 21 | private ImageButton mMainUdnieButton; 22 | private ImageButton mMainWaveCropButton; 23 | 24 | @Override 25 | protected void onCreate(Bundle savedInstanceState) { 26 | super.onCreate(savedInstanceState); 27 | setContentView(R.layout.activity_main); 28 | 29 | mMainDesGlaneusesButton = findViewById(R.id.main_des_glaneuses_button); 30 | mMainDesGlaneusesButton.setOnClickListener(this); 31 | mMainLaMuseButton = findViewById(R.id.main_la_muse_button); 32 | mMainLaMuseButton.setOnClickListener(this); 33 | mMainMirrorButton = findViewById(R.id.main_mirror_button); 34 | mMainMirrorButton.setOnClickListener(this); 35 | mMainUdnieButton = findViewById(R.id.main_udnie_button); 36 | mMainUdnieButton.setOnClickListener(this); 37 | mMainWaveCropButton = findViewById(R.id.main_wave_crop_button); 38 | mMainWaveCropButton.setOnClickListener(this); 39 | } 40 | 41 | @Override 42 | public void onClick(View view) { 43 | Intent intent = new Intent(this, ImageClassifierActivity.class); 44 | switch (view.getId()) { 45 | case R.id.main_des_glaneuses_button: 46 | intent.putExtra(TensorFlowImageStyleTranfer.MODEL_FILE,TensorFlowImageStyleTranfer.MODEL_FILE_DES_GLANEUSES); 47 | startActivity(intent); 48 | break; 49 | case R.id.main_la_muse_button: 50 | intent.putExtra(TensorFlowImageStyleTranfer.MODEL_FILE,TensorFlowImageStyleTranfer.MODEL_FILE_LA_MUSE); 51 | startActivity(intent); 52 | break; 53 | 54 | case R.id.main_mirror_button: 55 | intent.putExtra(TensorFlowImageStyleTranfer.MODEL_FILE,TensorFlowImageStyleTranfer.MODEL_FILE_MIRROR); 56 | startActivity(intent); 57 | break; 58 | 59 | case R.id.main_udnie_button: 60 | intent.putExtra(TensorFlowImageStyleTranfer.MODEL_FILE,TensorFlowImageStyleTranfer.MODEL_FILE_UDNIE); 61 | startActivity(intent); 62 | break; 63 | 64 | case R.id.main_wave_crop_button: 65 | intent.putExtra(TensorFlowImageStyleTranfer.MODEL_FILE,TensorFlowImageStyleTranfer.MODEL_FILE_WAVE_CROP); 66 | startActivity(intent); 67 | break; 68 | } 69 | 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/res/drawable-v24/ic_launcher_foreground.xml: -------------------------------------------------------------------------------- 1 | 7 | 12 | 13 | 19 | 22 | 25 | 26 | 27 | 28 | 34 | 35 | -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/res/drawable/image_des_glaneuses.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/res/drawable/image_des_glaneuses.jpeg -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/res/drawable/image_la_muse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/res/drawable/image_la_muse.png -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/res/drawable/image_mirror.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/res/drawable/image_mirror.jpeg -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/res/drawable/image_udnie.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/res/drawable/image_udnie.jpg -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/res/drawable/image_wave_crop.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ARM-software/ML-examples/a6434d5f6f6a187a3d84289e18033b2c03d0f41d/armnn-style-transfer-android/app/src/main/res/drawable/image_wave_crop.jpg -------------------------------------------------------------------------------- /armnn-style-transfer-android/app/src/main/res/layout/activity_imageclassifier.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 14 | 15 | 25 | 26 |