Answer the question
In order to leave comments, you need to log in
How to remove error in opencv python?
I have a code that should just open an image as a window:
import cv2
my_photo = cv2.imread('man.png')
cv2.imshow('preview', my_photo)
cv2.waitKey(0)
cv2.destroyAllWindows()
Traceback (most recent call last):
File "c:/Users/Дом/Desktop/Py/pythoncv/main.py", line 3, in <module>
cv2.imshow('man', my_photo)
cv2.error: OpenCV(4.5.3) C:\Users\runneradmin\AppData\Local\Temp\pip-req-build-q3d_8t8e\opencv\modules\imgproc\src\color.cpp:182: error: (-215:Assertion failed) !_src.empty() in function 'cv::cvtColor'
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question