CV Practical
CV Practical
Note: We import numpy as we want to store the pixel values in the numpy array We import matplotlib to allow us to
display our images on the Jupyter notebook itself.
Note :OpenCV represents the images in BGR as opposed to the RGB we expect. Since it is in the reverse
order, you tend to see the blue color in images.
The numbers in your output shows the height ,width and the channels( RGB).
Note: The image is resized, but it is definitely distorted as we are not maintaining the aspect ratio. Not good
for our training purposes!
Take a look at your folder. Do you see the new file? Compare the size of the original and resized.
References:
• https://pyimagesearch.com/
• https://opencv.org/