Deploy Unity Machine Learning Agents on Arm Android devices
Introduction
Machine Learning in games
Install Unity and the project
The Dr Arm game
Machine Learning in Unity
The Unity project
Objects and Components
Training our ML agents
Optimizations
Summary
Next Steps
Deploy Unity Machine Learning Agents on Arm Android devices
Who is this for?
Developers interested in leveraging the Unity Machine Learning Agents toolkit on Arm devices.
What will you learn?
Upon completion of this Learning Path, you will be able to:
- Get the Unity Machine Learning (ML) Agents toolkit running in a game that is deployable to Arm-powered Android devices.
- Note - Instructions on how to deploy Unity games to an Arm-powered Android device and how to profile them are included in separate Learning Paths.
Prerequisites
Before starting, you will need the following:
- A computer capable of running Unity. (Instructions are for Windows, but could be adapted to other platforms.)
- An Android mobile device that has a 64-bit processor and supports at least Android 8.
- A USB cable to connect the mobile device to your computer.
Summary
This summary was drafted with an approved AI-assisted workflow and reviewed by Arm contributors before publication. Human technical review remains part of the process so the final page reflects engineering rigor, accuracy, and Arm editorial standards.
You’ll use Unity ML-Agents to add machine-learning behavior to the Dr Arm fighting game. First, you’ll install Unity and its required modules, open the ready-to-play scene, and explore how an agent uses observations, actions, and rewards. Then, you’ll modify the gameplay scene components and scripts, set up Python tools, train agents or use supplied training data, and review training optimizations.
Frequently asked questions
These FAQs were drafted with an approved AI-assisted workflow and reviewed by Arm contributors before publication. Human technical review remains part of the process so the final page reflects engineering rigor, accuracy, and Arm editorial standards.
In the Project tab, open
Assets/#DevSummit2022/Scenes/Level_DevSummit2022. Use this incomplete scene for the walkthrough instead of Level_DevSummit2022_ReadyToPlay.You need Python tools for the training stage. To get started, install Unity first and return to the Python setup when you begin training.
Install Unity Hub and a Unity Editor. If you plan to deploy to Android, add Android Build Support, OpenJDK, and Android SDK & NDK Tools. You can install Microsoft Visual Studio Community 2022 with Unity support, or use another script editor, then download the Dr Arm project files.
Use the on-screen touch controls to move, roll, and perform attacks on mobile.
Reopen
Level_DevSummit2022, select AgentsSettings, and assign an NN Model asset to each Battle Brain property. You can use the supplied pre-trained models or models from your completed training.