Course 1 Week 3: Vectorizing Multiple training Examples

I noticed between the videos “Computing a Neural Network’s Output” and “Vectorizing Across Multiple Training Examples” the notation for describing the matrices becomes a little confusing.

For a single training example, the video provides the notation as.
ai[l],l =layer,i=node

For multiple training examples the notation is:
a[l](i) ,l =layer,i=training example

i now takes on a new meaning. In the same video Andrew describes the X matrix as a n_x by m matrix, where m is the number of training examples. It seems m and i are used interchangeably which is confusing for newbies.

Am I correct in my interpretation? If so, I suggest a more standardized approach could be taken such that i is not “re-used” with multiple meanings, and then the same super/subscripts are used throughout multiple videos creating better consistency. I think the notation for multiple training examples is probably better described as

ai[l](m), l= layer, i= node, m= training example

Lastly, I realize it makes sense in a loop to say “for I = 1 to m”. So maybe the issue is in the first video with using i to describe the node.

Hi @sflemin2 , welcome to the community and thanks that’s an intriguing and sharp question!

I actually had to relook at the videos a few times to notice what you were saying… Prof Ng in the first video, as a side note, briefly explain the notation of he is using ai[l], in purple, between min 2 and 2:30. In the subsequent video the subscript notation is note used anymore and i is used to for the loop for i = 1 to m.

Your interpretation is correct, and the best way maybe is to clearly state the i is used in two different ways or change this in the first video for consistency. So far, we have not received any questions or confusion from beginning students, but I will bring it back to the Course Staff.

Thanks for spotting it, and let us know if you have any other suggestions,
regards Stephanus