Closed valentinmace closed 4 years ago
Hi @valentinmace, I think the settings you're looking for are available in the Academy (in Unity): https://github.com/Unity-Technologies/ml-agents/blob/master/docs/Learning-Environment-Design-Academy.md#academy-properties By default, training happens at 80x80 and 100x timescale, and inference is 1280x720 and normal timescale, but you can adjust them in the Academy.
Just a note that the interface for this will change in the next release; these parameters will be set on the python commandline or as arguments to UnityEnvironment.
Thanks for your quick answer @chriselion
You are right, I can change these parameters in the academy and it is working well, however the environment is always runing on training mode
I made some tests by playing with window width and height and no matter what I chose for the train_mode
parameter (True
or False
) in env.reset(), the game is runing with training mode only, never inference
Am I missing something ? Also I think that it is a great idea to put these parameters as arguments to UnityEnvironment
By default, when you connect with python, the academy thinks it's in "training" mode. You can change the behavior in Agents (in 0.12.0) by setting their BehaviorParameters Behavior Type to "Inference Only"; they'll use inference, but the Academy's decision of whether to use the "training" or "inference" configurations is based solely on whether it's connected to an external processes (i.e. Python).
If you want full control over the settings in 0.12.0, I'd recommend you do the equivalent of Academy.ConfigureEnvironmentHelper inside your Academy.Step implementation (unfortunately doing it in InitializeAcademy will get overwritten)
Thanks a lot
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.
Hi, I'm new to mlagents
I have a python script interacting with 3DBall environment
Everything seems to work, I can launch the game and get observations, provide actions etc.
However when I run the game, it is always in a small window and the game is going at full speed. My code looks like:
First note: When I only instantiate the environment with
env = UnityEnvironment(...)
and do nothing else, the game is in full window, going at normal speedSecond note: My goal is to train my own neural network (which I implemented myself so there is no TF or Pytorch) with my own algorithm. When the training is over I would like to visualize my NN playing in a full size window at normal speed
Thanks in advance for your answer, sorry if I the solution was in the doc and I missed it