#tips_cmd time scale control command

Hello !
After a feedback from the developers, I finally found the python cmd to control time-scale in the editor .

" --time-scale=1 --capture-frame-rate=0 "

So after adding this command

[mlagents-learn saymyconfig.yaml --time-scale=1 --capture-frame-rate=0 --run-id=saymyid01]

the editor time scale sets into 1.
Then the models will be trained in the same time scale that the usual built models run in the play mode.

If only cmd " --time-scale=1" was called, the editor time scale sets into 1.
But realistically float Time.deltatime will stay about 3x time scale.

I was looking into this the other day. ML-Agents is doing what it says it's doing (it sets Time.timeScale to the value passed for --time-scale). But there are more complicated interactions between the other Time settings, which are not specific to ML-Agents.

As you noted, setting --time-scale=1 --capture-frame-rate=0 should keep Time.deltaTime and Time.unscaledDeltaTime equal.

If you want ML-Agents to leave all the Time values as their default, you should also pass --target-frame-rate=-1.

1 Like