I'm doing some quick exercises using CV library, trying to analyze some colored images.
This is my code:
import cv2 as cvimg01=cv.imread('PATH')from matplotlib import pyplot as pltplt.imshow(cv.cvtColor(img01,cv.COLOR_BGR2RGB))from matplotlib import pyplot as pltplt.imshow(cv.cvtColor(img01,cv.COLOR_BGR2RGB))
Once this is set, then I go to a specific place in the image to be analyzed using a for loop:
h,w,_=img01.shapefor i in range(50,150): for j in range(25,50): img01=[i,j]=(0,100,0)
But once I ran that part, I got this error:
ValueError: too many values to unpack (expected 2)
I have tried changing the parameters, the image or restarting the compilation, but it is not working.