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

conflict opencv-python and opencv-contrib-python #388

Closed
dianaK-oss opened this issue Sep 15, 2020 · 1 comment
Closed

conflict opencv-python and opencv-contrib-python #388

dianaK-oss opened this issue Sep 15, 2020 · 1 comment

Comments

@dianaK-oss
Copy link

When I install opencv-python==3.4.2.17, after opencv-contrib-pytho==3.4.2.17 is installed, an error occurs:
AttributeError: module 'cv2.cv2' has no attribute 'xfeatures2d'

When I install opencv-python==3.3.0.10, after opencv-contrib-python==3.3.0.10 is installed,
cv2.Videocapture(path_to_video) returns None

If I do it vice versa, there's no such problem.

If I have a different version of opencv-contrib-python(ex:3.4.2.17) and opencv-python(ex: 4.2.0.34) the problems are the same

@skvark
Copy link
Member

skvark commented Sep 15, 2020

Did you read the installation guide...?! https://github.com/skvark/opencv-python#installation-and-usage

It literally says in CAPS LOCK that you should select only one of the four package variants.

I repeat: install only one package. You don't need multiple packages. In your case opencv-contrib-python is enough. It already contains all functionalities of opencv-python and in addition the extra modules (such as xfeatures2d).

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