notadamking / RLTrader

A cryptocurrency trading environment using deep reinforcement learning and OpenAI's gym
https://discord.gg/ZZ7BGWh
GNU General Public License v3.0
1.73k stars 539 forks source link

Performance #116

Open jsztompka opened 5 years ago

rshtirmer commented 5 years ago

While I have not confirmed if this actually improves speed (i have a hunch it does), I have tested this PR with the latest codebase and can confirm it works.

jsztompka commented 5 years ago

It's fairly easy to test, if you use MlpPolicy on the agent (it's just a bit faster and more visual) , what I've noticed is that after about 2-3 minutes of running optimization the whole thing really slows down. If you look at the code in the _next_observation it keeps adding new observations to the frame and does all recalculations on the full frame so as the list grows it becomes slower.