AndreaVidali / Deep-QLearning-Agent-for-Traffic-Signal-Control

A framework where a deep Q-Learning Reinforcement Learning agent tries to choose the correct traffic light phase at an intersection to maximize traffic efficiency.
MIT License
405 stars 146 forks source link

Use collections.deque for memory storage #24

Open mtreca opened 3 years ago

mtreca commented 3 years ago

Hi,

Just stumbled upon your work yesterday, it provides a very nice starting point for my DQN experiments with SUMO.

A small suggestion (if you care about maintaining this project) would be to use a collections.deque data structure for your memory samples. By specifying a size_max on instantiation, you don't have to manually pop old observations from your memory DB.