Ask Your Question

Revision history [back]

I think there is a bug in opencv-python==4.0.0.21 (pip install) If I use opencv-python====3.4.5.20 ((pip install)) there is no problem with your code

Now I cannot reproduce your bug on my computer using my own version of opencv-python

I think we need that someone could confirm my answer @berak ?

PS please don't forget to check image is not None when you use imread

I think there is a bug in opencv-python==4.0.0.21 (pip install) If I use opencv-python====3.4.5.20 ((pip install)) there is no problem with your code

Now I cannot reproduce your bug on my computer using my own version of opencv-python

I think we need that someone could confirm my answer @berak ?

Issue https://github.com/skvark/opencv-python/issues/168 and https://github.com/opencv/opencv/issues/13689

PS please don't forget to check image is not None when you use imread