Answer the question
In order to leave comments, you need to log in
Python skip if such-and-such output, how to write?
Such a question, there is a cv2 script that is in a loop and goes through two folders. The problem occurs if one image is missing from the loop. How to write if such output in console, then move on to the next and else proceed as usual.
cv2.error: OpenCV(4.5.5) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\color.cpp:182: error: (-215:Assertion failed) !_src.empty() in function 'cv::cvtColor'
num = open("num.csv", "r")
for b in num:
...
тут идет все про путь, обработку и т.д
...
cv2.imshow('before'+(b), before)
cv2.waitKey(0)
cv2.destroyAllWindows()
Answer the question
In order to leave comments, you need to log in
I had a similar problem with the Intel driver. Judging by the answers in this thread , this happens when the libraries supplied with Android Studio are not compatible with the video driver installed on the system. I solved it by deleting the following files:
rm -rf $ANDROID_HOME/Sdk/tools/lib/libstdc++
rm -rf $ANDROID_HOME/Sdk/tools/lib64/libstdc++
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question