Implementing scalable deep Q-learning algorithms using Ray
In this section, we will implement a parallelized DQN variate using the Ray library. Ray is a powerful, general-purpose, yet simple framework for building and running distributed applications on a single machine as well as on large clusters. Ray has been built for applications that have heterogenous computational needs in mind. This is exactly what modern DRL algorithms require as they involve a mix of long and short running tasks, usage of GPU and CPU resources, and more. In fact, Ray itself has a powerful RL library that is called RLlib. Both Ray and RLlib have been increasingly adopted in academia and industry.
Info
For a comparison of Ray to other distributed backend frameworks such as Spark and Dask, see https://bit.ly/2T44AzK. You will see that Ray is a very competitive alternative, even beating Python's own multiprocessing implementation in some benchmarks.
Writing a production-grade distributed application...