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

Testing on my video getting an error #38

Open
FranciscoPark opened this issue Feb 15, 2024 · 0 comments
Open

Testing on my video getting an error #38

FranciscoPark opened this issue Feb 15, 2024 · 0 comments

Comments

@FranciscoPark
Copy link

hey, i am trying run this program only for court detection. It seems to work with your video_samples, however, when I try using my video, I get:

Traceback (most recent call last):
File "/home/isco/Desktop/ambient/opencv_court/predict_video.py", line 24, in
lines = court_detector.detect(frame)
File "/home/isco/Desktop/ambient/opencv_court/court_detector.py", line 71, in detect
return self.find_lines_location()
File "/home/isco/Desktop/ambient/opencv_court/court_detector.py", line 292, in find_lines_location
self.lines = cv2.perspectiveTransform(self.p, self.court_warp_matrix[-1]).reshape(-1)
cv2.error: OpenCV(4.9.0) /io/opencv/modules/core/src/matmul.dispatch.cpp:550: error: (-215:Assertion failed) scn + 1 == m.cols in function 'perspectiveTransform'

It seems it can not calculate court_warp_matrix correctly. I get None for this result. My video is not dramatically different from yours so I do not understand what the problem might be.

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

1 participant