C2_W1_Assignment - How the number of layers and neurons were defined?

  • Course 2 - Week 1
  • Link to the classroom: (https://www.coursera.org/learn/advanced-learning-algorithms/programming/zgeR8/practice-lab-neural-networks-for-binary-classification)

In Notebook’s topic 2.3, how the number pf layers and neurons in each layer are defined?
I could not understand the explanation in the cell below:

The input units (number of features) and the output units (the labeled outputs) are defined by the data set.

The number of units in each hidden layer are determined by experimentation.

You want a system that gives good-enough performance, but not so complicated that is is difficult to train.

From the number of units, you can determine the sizes of the weight and bias matrices.

  • There is a weight matrix that connects each pair of adjacent layers. It size is based on the number of units in each of those layers.

  • Every hidden layer unit and every output layer unit also has a bias value. These are always defined as 1D vector for each layer.