I am trying to compare the two circular areas in Image1 and Image2. My current code gets me a white circle for image1, but falls apart for image2.
Is there another way to find the two circular areas for both images?
import cv2
import numpy as np
img = cv2.imread('Resources/Image2.jpg')
imgHSV = cv2.cvtColor(img,cv2.COLOR_BGR2HSV)
lower = np.array([40,28,18])
upper = np.array([70,161,255])
#imgGray = cv2.cvtColor(img,cv2.COLOR_BGR2GRAY)
mask = cv2.inRange(imgHSV, lower, upper)
maskInv = cv2.bitwise_not(mask)
#imgCanny = cv2.Canny(imgBitGrey,150,200)
cv2.imwrite('Resources/Image2_Inv.jpg', maskInv)
#cv2.imshow('Original',img)
#cv2.imshow('Grey',imgGray)
#cv2.imshow('BitGrey',imgBitGrey)
#cv2.imshow('Canny',imgCanny)
#cv2.imshow('InvCanny',imgInvCanny)
cv2.imshow('maskInv',maskInv)
cv2.imshow('Mask',mask)
#cv2.imshow('Invert',imgInvMask)
cv2.waitKey(0)