Open yanpanlau opened 7 years ago
I am also having this same issue. Control updates are getting sent at 5Hz which seems excessively slow
Hi, the same issue here. Any workaround for now?
If you don't need to use the gym-torcs environment specifically, I found using the SCRC patch on TORCS and the Snakeoil Python client together worked very nicely, I get 20Hz game state and control input. See my repo for code: https://github.com/kschan/torcs_scripts
Sorry if the code is not very clean.
Hi, @kschan , thanks for your work! Is there any possibility to enable image input?
Not via my code! I bet you could do something clever though.
Oh, I'll try to figure it out.
BTW, vtorcs-RL-color already has scr-patch applied.
I did some profiling, and the most time-consuming part of the code is:
sockdata,addr= self.so.recvfrom(data_size)
which is called at line 168 in snakeoil3_gym.py. It takes about 180 ms to complete. Also, if I make socket non-blocking, client is still waiting about 180 ms, so issue is on the TORCS side.
@yanpanlau , @ugo-nama-kun , do you have any ideas about this?
Well, I have figured it out. It is just here.
I got sustainable results with RCM_MAX_DT_ROBOTS of 0.05. If I make it less, TORCS eventually freezes. Also, in scr_server and here I changed the number of bots to 1 so not to waste precious resources.
And, here it is! As for me, it is really good result!
Hi, I am working on the new projects in gym_torcs which requires faster frames per second. I found that in
which calls line 122-124 in gym_torcs.py
is very slow. the 2 lines above took 0.2 seconds (so 5 fps)
Do you know if there is anyway I can improve the fps?
Thanks,
Ben