Now, we have programmatically defined all of the individual components that are necessary to initialize our deep Q-learning agent. For this, we use the imported DQNAgent object from rl.agents.dqn and defined the appropriate parameters, as shown here:
#Initialize the atari_processor() class processor = AtariProcessor() # Initialize the DQN agent dqn = DQNAgent(model=model, #Compiled neural network model nb_actions=nb_actions, #Action space policy=policy, #Policy chosen (Try Boltzman Q policy) memory=memory, #Replay memory (Try Episode Parameter
memory) processor=processor, #Atari processor class
#Warmup steps to ignore initially (due to random initial weights) nb_steps_warmup=50000, ...