Skip to content

Python Warped prespective  #21863

@dalpendre

Description

@dalpendre
  • OpenCV => 4.0.1
  • Operating System / Platform => Windows 64 Bit
  • Compiler => PyCharm 2021.3.1
Detailed description

I need to implement a warp perspective, and the following error happens:

Traceback (most recent call last):
File "C:/Users/Diogo Alpendre/OneDrive - IPLeiria/Para arrumar/Documentos/GitHub/T22_AD_Detection/perspective transormation.py", line 22, in
result = cv2.warpPerspective(frame, pts1, (640, 480))
cv2.error: OpenCV(4.0.1) C:\ci\opencv-suite_1573470242804\work\modules\imgproc\src\imgwarp.cpp:2927: error: (-215:Assertion failed) (M0.type() == CV_32F || M0.type() == CV_64F) && M0.rows == 3 && M0.cols == 3 in function 'cv::warpPerspective'

[ WARN:0] terminating async callback

Process finished with exit code 1

Steps to reproduce

Metadata

Metadata

Assignees

No one assigned

    Labels

    question (invalid tracker)ask questions and other "no action" items here: https://forum.opencv.org

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions