araffin / rl-baselines-zoo

A collection of 100+ pre-trained RL agents using Stable Baselines, training and hyperparameter optimization included.
https://stable-baselines.readthedocs.io/
MIT License
1.12k stars 208 forks source link

GPU vs CPU Performance #72

Closed Mom0aut closed 4 years ago

Mom0aut commented 4 years ago

Hello,

first of all i wanna say thank you for this great Framework and those tuned Hyper parameters.

Now to my question: I tested the performance with my own gym/baselines examples and there were only 5-10 seconds difference. I also tested your implementation and the difference vs CPU and GPU is really small (about 5 sec.). Is this an normal behavior or must be the difference much higher (maybe i installed the nvidia-docker wrong with the wrong nvidia-runtime settings) ?

I hope maybe you can help me out

Thanks!!!

Regards Mom0

araffin commented 4 years ago

Duplicate of https://github.com/hill-a/stable-baselines/issues/308

Also related: https://github.com/hill-a/stable-baselines/issues/367

So for short, for small networks, there won't be any difference between of communication delay and also passing data from cpu to gpu back and forth. For bigger architecture and especially CNN, you should see a boost when using GPU.

Mom0aut commented 4 years ago

Ok thank you for your fast response.

I didn´t know that, i will try so test bigger networks.