error: (-215:Assertion failed) _src.total() > 0 in function 'warpPerspective' problem solving

error: (-215:Assertion failed) _src.total() > 0 in function ‘warpPerspective’,

If you use opencv to do perspective changes, if you report this error, you can check whether the height and width of the input image are 0. There is a high probability that the coordinates will appear negative when the large image is sliced ​​into a small image, and whether the input projection transformation matrix is ​​0.

おすすめ

転載: blog.csdn.net/qq_36276587/article/details/118610583