Closed
Description
In the second code block in the tutorial, the line pos = np.where(masks[i])
has been used to get the indices of the non zero points in the image. But numpy documentation for np.where()
advises to use np.nonzero()
when there is only one argument for np.where()
, and it also makes the code more readable.