# Where in the course do I find this?

The following information comes from the Practice lab on C2 W1 assignment. I need to better understand how the dimensions of W and b are determined. Can someone explain this to me please? Or point me to the video in the course where it is explained?

The parameters have dimensions that are sized for a neural network with 25 units in layer 1, 15units in layer 2 and 1 output unit in layer 3.

• Recall that the dimensions of these parameters are determined as follows:
• If network has π ππ units in a layer and π ππ’π‘ units in the next layer, then
• π will be of dimension π ππΓπ ππ’π‘.
• π will a vector with π ππ’π‘ elements

For each pair of adjacent layers, there is a weight matrix βWβ and a bias vector βbβ. They serve to connect the adjacent layers.

The size of the βWβ matrix is typically (outputs x inputs) - giving the number of rows and columns.

• The βoutputsβ are the number of units in the next layer.
• The βinputsβ are the number of units in the previous layer.

Note that this isnβt a concrete rule - the shape of the W matrix depends on the designer of the model.

For each unit in the previous layer, there is a value in the βbβ vector. So typically the shape is (inputs x 1). Though it could also be (1 x inputs), again depending on the designer of the model.