in the example of week 1 under the heading “cnn example correction” of the course CNN, how do we calculate the no of parameters for a layer involving convolution?

given filter has f=5,s=1 (shape (5,1,3)) of conv1 layer and there are 8 such filters the no.of parameters of this layer is (5*5*3+1)*8, why do we add 1?

That is for the bias term on each filter. Each filter has f x f x nC_{prev} elements that you multiply against the input, then you add all those terms and add a single bias term to get the final answer for that output position.

thank you for the clarification