Unity-Technologies / ml-agents

The Unity Machine Learning Agents Toolkit (ML-Agents) is an open-source project that enables games and simulations to serve as environments for training intelligent agents using deep reinforcement learning and imitation learning.
https://unity.com/products/machine-learning-agents
Other
16.93k stars 4.14k forks source link

RollerBall agent does not move when training #1888

Closed josephparis97 closed 5 years ago

josephparis97 commented 5 years ago

Hi ! It is very frustrating because I have followed "Making a New Learning Environment" tutorial and it doesn't work. When I hit the play button my agent stay still and the cmd is saying repeatedly :

"INFO:mlagents.trainers: RollerBall-1-0: RollerBallBrain: Step: 37000. No episode was completed since last summary. Training."

image

image

image

Could Someone help me ?

ShaneCaler commented 5 years ago

Have you tried removing RollerballPlayerBrain from the academy? Maybe it's waiting for some input from that to train the learning brain? I haven't messed much with player brains, though, so I'm not totally sure what the problem is.

josephparis97 commented 5 years ago

I have tried to remove the RollerballPlayerBrain but nothing changed. I forgot to put the pictures off the cmd image image

josephparis97 commented 5 years ago

I think that the learning brain never takes any decision because vectorAction is always equal to zero. I don't know why

ervteng commented 5 years ago

Hey @josephparis97, what Brain is assigned to the Agent game object? It should be the Learning brain, not the Player Brain.

josephparis97 commented 5 years ago

Oh you are right !!!!! The learnig brain was not assigned ! It was the player brain! thank you so much ! But now it is moving frame by frame, I there a way to make it more fluid ? roller agent

And I have another question, my training process stopped without me. Why ? image

ervteng commented 5 years ago

Ah, that's because it's training! The rendering is slow but you're getting many more steps. When you're happy with the reward it's getting, run ml-agents with the --load and --slow flags and it'll run at realtime.

josephparis97 commented 5 years ago

ok thank you really much !!! This ml agent IA toolkit is really cool ! I am actually trying to create littles creatures like this one :) creature1

warpdriv commented 5 years ago

Bug in instructions: https://github.com/Unity-Technologies/ml-agents/blob/master/docs/Learning-Environment-Create-New.md

Section : Final Editor Setup - Step 3. It says: Drag the Brain RollerBallPlayer from the Project window to the RollerAgent Brain field.

Should say: Drag the Brain RollerBallBrain from the Project window to the RollerAgent Brain field.

Please someone correct this. Thank you.

TheDozMan commented 5 years ago

Your training process stopped without you because it had reached 50,000 steps. This is the value it is configured to run until . You can see this in the trainer_config.yaml file. The line:

max_steps: 5.0e4

Is what determines this.

buddha314 commented 5 years ago

I just lost two days to this error. Man oh man. I read that line four times because it seemed wrong and then I forgot about it. Poop. Poop poop procreating poop.

shihzy commented 5 years ago

made a PR here to fix in develop

https://github.com/Unity-Technologies/ml-agents/pull/1993

shihzy commented 5 years ago

Thanks for reaching out to us. Hopefully you were able to resolve your issue. We are closing this due to inactivity, but if you need additional assistance, feel free to reopen the issue.

github-actions[bot] commented 3 years ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.