O'Reilly logo

Learn Unity ML-Agents - Fundamentals of Unity Machine Learning by Micheal Lanham

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Multi-agent environments

It likely started out as a fun experiment, but as it turns out, letting agents compete against themselves can really amp up training, and, well, it's just cool. There are a few configurations we can set up when working with multiple agents. The BananaCollector example we will look at uses a single brain shared among multiple competing agents. Open up Unity and follow this exercise to set up the scene:

  1. Load the BananaCollectorBananaRL scene file located in the Assets/ML-Agents/Examples/BananaCollectors/ folder.
  2. Leave the Brain on Player; if you changed it, change it back.
  3. Run the scene in Unity. Use the WASD keys to move the agent cubes around the scene and collect bananas. Notice how there are multiple cubes responding ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required