Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cv2.error: OpenCV(4.3.0) /io/opencv/modules/imgproc/src/color.cpp:182: error: (-215:Assertion failed) #15

Open
MartinThoma opened this issue Sep 7, 2020 · 2 comments

Comments

@MartinThoma
Copy link

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/math/.pyenv/versions/3.8.4/lib/python3.8/site-packages/nowatermark/WatermarkRemover.py", line 32, in load_watermark_template
    self.generate_template_gray_and_mask(watermark_template_filename)
  File "/home/math/.pyenv/versions/3.8.4/lib/python3.8/site-packages/nowatermark/WatermarkRemover.py", line 57, in generate_template_gray_and_mask
    gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
cv2.error: OpenCV(4.3.0) /io/opencv/modules/imgproc/src/color.cpp:182: error: (-215:Assertion failed) !_src.empty() in function 'cvtColor'
@MartinThoma
Copy link
Author

My system:

  • WSL2 (Ubuntu 20.04)
  • cv2 version 4.3.0
  • Python 3.8.4

@touzilk
Copy link

touzilk commented Nov 27, 2020

路径问题,转义一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants