GithubHelp home page GithubHelp logo

hummingbirds-unity-ml's Introduction

Hummingbirds Unity Machine Learning Agent

Hummingbird Unity machine learning agent is the artificial intelligent system where I tried to copy the Hummingbird flying nature in Unity game environment and train agents that can navigate to flowers, dip their beaks in, and drink nectar. These hummingbirds have six degrees of freedom, meaning they can fly and turn in any direction to find targets.

These hummingbirds have six degrees of freedom, meaning they can fly and turn in any direction to find targets. They have more complicated controls and their flight paths cannot be solved with traditional navigation systems. In this project I proposed a Reinforcement Learning model with newly Invented Unity Machine Learning .

Environment:

fig 1: Unity Environment

The hummingbird agent is the main machine learning agent and the simulation environment has different kind of obstacles for the agent.

Control:

Direction Key Direction Key
Forward W Pitch Up
Backward S Pitch Down
Left A Turn Left
Right D Turn Right
Up E
Down C

fig 2: pitch and yaw movement of flying object

Game Mode:

To Control the agent using keyboard, in Behavior Parameter change the Behavior Type of agent to Heuristic

Training:

In Behavior Parameter Change the Behavior Type of Hummingbird to Default.

1. Running training

mlagents-learn ./config/trainer_config.yaml --run-id trainingAgent

2. Visualization

use tensorboard --logdir ./config/summaries

fig 3: Shows the training progression on the four games using ML-Agents in the Unity environment. Mean cumulative training reward across eight game instances PPO (8) orange. The x-axis denotes steps. Note that rewards and the y-axis are different for each game. The results clearly show learning progress across all eight games, in line with the baselines.

fig 4: Shows that the Policy/Entropy curve is decreasing which means taking random decisions of the model slowly decrease during a successful training process. Policy/Extrinsic Reward, the mean cumulative reward received from the environment per-episode increases with training. Policy/Learning Rate, how large a step the training algorithm takes as it searches for the optimal policy is decreasing with time being.

3. Using Trained brain in Machine Learning Agent

Use the Hummingbird.nn file in the directory specified in --run-id parameter during training as Model for Hummingbird's Behavior Parameter. This Hummingbird is the Machine Learning agent against which the player will compete. For the Player Hummingbird, set Behavior Type to Heuristic Only.

Final result:

hummingbirds-unity-ml's People

Contributors

gunjanmimo avatar

Stargazers

Goose Goosington (Emma Steimann) avatar  avatar  avatar Xiaohu Zhu avatar

Watchers

James Cloos avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.