Hello,
I want to use Imshow in Jupyter Notebook (PyCharm just for checking if it is a Jupyter specific problem, but I get the same result there).
When I type in
img1 = cv2.imread(r"savefig/plotXBIC_singlecell/01.png")
cv2.imshow("image",img1)
cv2.waitKey(0)
cv2.destroyAllWindows()
I get the error message:
OpenCV(4.2.0) /io/opencv/modules/highgui/src/window.cpp:376: error: (-215:Assertion failed) size.width>0 && size.height>0 in function 'imshow'
And when I do this:
gray = cv2.cvtColor(img1, cv2.COLOR_BGR2GRAY)
I get the error message:
OpenCV(4.2.0) /io/opencv/modules/imgproc/src/color.cpp:182: error: (-215:Assertion failed) !_src.empty() in function 'cvtColor'
Can you help me, please? :)