I have an image with this shape:
(300,512,2)
I want to convert it to grayscale, I'm using this code:
grayscale = cv2.cvtColor(open_cv_image, cv2.COLOR_BGR2GRAY)
but getting an error:
> Invalid number of channels in input image:
> 'VScn::contains(scn)'
> where
> 'scn' is 2
I understand that cvtColor requires 3 channels. But I have only 2. What can I do now?