In C1_W4_Lab_1_image_data_preprocessing_no_validation.ipynb why we have to use matplotlib.image?

In the file called C1_W4_Lab_1_image_data_preprocessing_no_validation.ipynb why we have to use import matplotlib.image as mpimg? Because in the previous lectures we have used only matplotlib.pyplot bur here we used this code img = mpimg.imread(img_path), plt.imshow(img)? why not only plt.imshow() is sufficient?

Apparently the .pyplot is for generic plots and .image module for reading in images into numpy arrays.

Here, you are reading the image as a numpy array and then plotting it.