我想识别图像的红色值。但我无法识别红点。程序只显示蓝色值?
import cv2
import numpy as np
img=cv2.imread("C:\Users\My Kindom\Documents\Youcam\mihira.JPG")
hsv=cv2.cvtColor(img,cv2.COLOR_BGR2HSV)
lower_red=np.array([100,50,50])
upper_red=np.array([130,255,255])
mask=cv2.inRange(hsv,lower_red,upper_red)
cv2.imshow("image",mask)
cv2.waitKey(0)