Implementing the Pong gaming bot
These are the implementation steps that we need to follow:
Initialization of the parameters
Weights stored in the form of matrices
Updating weights
How to move the agent
Understanding the process using NN
You can refer to the entire code by using this GitHub link: https://github.com/jalajthanaki/Atari_Pong_gaming_bot.
Initialization of the parameters
First, we define and initialize our parameters:
batch_size:
This parameter indicates how many rounds of games we should play before updating the weights of our network.gamma:
This is the discount factor. We use this to discount the effect of old actions of the game on the final result.decay_rate:
This parameter is used to update the weight.num_hidden_layer_neurons:
This parameter indicates how many neurons we should put in the hidden layer.learning_rate:
This is the speed at which our gaming agent learns from the results so that we can compute new weights. A higher learning rate means we react more strongly to results...