In this section, we will train an MLP for classification by discussing the required hyperparameters. Additionally, we will explore the various issues in optimization.
All MLPs are required to have their shape specified. This includes the number of hidden layers and how many neurons each layer has. Each neuron, which is a perceptron, has an activation function whose value will need to be passed to later neurons in the network. Here, the activation function needs to be selected.
Finally, to control overfitting, a regularization parameter can be specified to help weed out unhelpful neurons in the network, giving them little to no weight.