opencv_contrib | Repository for OpenCV 's extra modules | Command Line Interface library

 by   opencv C++ Version: 4.7.0 License: Apache-2.0

kandi X-RAY | opencv_contrib Summary

kandi X-RAY | opencv_contrib Summary

opencv_contrib is a C++ library typically used in Utilities, Command Line Interface, OpenCV applications. opencv_contrib has no bugs, it has no vulnerabilities, it has a Permissive License and it has medium support. You can download it from GitHub.

This repository is intended for the development of so-called "extra" modules, contributed functionality. New modules quite often do not have stable API, and they are not well-tested. Thus, they shouldn't be released as a part of official OpenCV distribution, since the library maintains binary compatibility, and tries to provide decent performance and stability. So, all the new modules should be developed separately, and published in the opencv_contrib repository at first. Later, when the module matures and gains popularity, it is moved to the central OpenCV repository, and the development team provides production-quality support for this module.

            kandi-support Support

              opencv_contrib has a medium active ecosystem.
              It has 8487 star(s) with 5627 fork(s). There are 388 watchers for this library.
              It had no major release in the last 6 months.
              There are 444 open issues and 944 have been closed. On average issues are closed in 103 days. There are 69 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of opencv_contrib is 4.7.0

            kandi-Quality Quality

              opencv_contrib has 0 bugs and 0 code smells.

            kandi-Security Security

              opencv_contrib has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              opencv_contrib code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              opencv_contrib is licensed under the Apache-2.0 License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              opencv_contrib releases are not available. You will need to build from source code and install.
              Installation instructions, examples and code snippets are available.
              It has 18307 lines of code, 350 functions and 93 files.
              It has high code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of opencv_contrib
            Get all kandi verified functions for this library.

            opencv_contrib Key Features

            No Key Features are available at this moment for opencv_contrib.

            opencv_contrib Examples and Code Snippets

            No Code Snippets are available at this moment for opencv_contrib.

            Community Discussions


            Building opencv from source in Mac m1
            Asked 2022-Feb-11 at 12:36

            I'm using the following Make to build OpenCV from source,



            Answered 2022-Feb-10 at 18:05

            I think that you've installed ffmpeg 5 and OpenCV is not yet compatible with it. Please try the following:



            How to find fundamental matrix based on other fundamental matrix and camera movement?
            Asked 2022-Jan-03 at 13:58

            I am trying to speed up some multi-camera system that relies on calculation of fundamental matrices between each camera pair.

            Please notice the following is pseudocode. @ means matrix multiplication, | means concatenation.

            I have code to calculate F for each pair calculate_f(camera_matrix1_3x4, camera_matrix1_3x4), and the naiive solution is



            Answered 2022-Jan-03 at 13:58

            Numpy is clearly not optimized for working on small matrices. The parsing of CPython input objects, internal checks and function calls introduce a significant overhead which is far bigger than the execution time need to perform the actual computation. Not to mention the creation of many temporary arrays is also expensive. One solution to solve this problem is to use Numba or Cython.

            Moreover, the computation of the determinant can be optimized a lot since you know the exact size of the matrix and a part of the matrix does not always change. Indeed, using a basic algebraic expression for the 4x4 determinant help compilers to optimize a lot the overall computation thanks to the common sub-expression elimination (not performed by the CPython interpreter) and the removal of complex loops/conditionals in np.linalg.det.

            Here is the resulting code:



            Conflict between OpenCV 4 and cv_bridge in ROS Node
            Asked 2021-Dec-02 at 14:19

            I'm starting a project with OpenCV with ROS and i need to use xfeatures2d that is in opencv_contrib. I follow this instructions and modify my CMake File in this way:



            Answered 2021-Dec-02 at 14:19

            I found a solution in Github:

            In catkin_ws/src:



            OpenCV Python Cuda CascadeClassifier Error
            Asked 2021-Nov-17 at 10:59

            I am trying to optimize my detector created with OpenCV in python using the GPU. The error I am encountering is the following:

            cv2.error: OpenCV(4.5.1) c:\opencv_build\opencv_contrib-4.5.1\modules\cudalegacy\src\cuda\ error: (-215:Assertion failed) haar.ClassifierSize.height > 0 && haar.ClassifierSize.width > 0 in function 'loadFromXML'

            The error arises when calling this function:



            Answered 2021-Nov-17 at 09:50

            the CUDA cascade classifier cannot read the output from the traincascade tool properly.

            you either need to train an LBP cascade (instead of HAAR), or fall back to the 2.x haartraining tool.




            Opencv-contrib installation error: file not found
            Asked 2021-Nov-04 at 16:11

            A Linux newbie here. On Linux Mint, python 3.8, under Anaconda, trying to install opencv-contrib-python by



            Answered 2021-Nov-04 at 16:11

            Removing Anaconda and working with the python supplied with my Linux distro solved the issue.



            Multi-stage docker build, prevent concurency for specific stage
            Asked 2021-Nov-02 at 14:32

            In docker multi-stage build, How do I prevent other stages running in parallel to a specific stage?

            I have a multistage Dockerfile. one of the stages builds opencv stack.



            Answered 2021-Nov-02 at 12:42

            Concurrency limits were recently added to buildkit in PR #2049. With docker buildx create you can pass a config file that includes the max-parallelism option to limit concurrent steps.



            OpenCV "not authorized to capture video" error on macOS (in Java)
            Asked 2021-Oct-10 at 22:07

            I am making a cross platform Java application that uses Computer Vision (OpenCV). I need to receive video from a webcam. Currently using standard OpenCV methods:



            Answered 2021-Oct-10 at 22:07

            Again I answer my own question...

            Thanks @ChristophRackwitz! After your question whether the camera works in python, I checked it (I don't know why I didn't do it before). And so, the camera in python (with opencv-contrib-python) works without problems, so I realized that the problem was with Java (JDK) itself.

            I have JDK 8 installed with this commands:



  'trainer/trainer.yml) could not find trainer.yml file
            Asked 2021-Jun-13 at 04:10

            I'm trying to run this code but it did not because I am not able to download this file from GitHub. Is there anyone who knows how I can download this file?

            This is the link to the file with the filename face-trainner.yml:…

            I'm getting this error when running my program:



            Answered 2021-Jun-12 at 21:14

            Go to the main section of the GitHub repository:

            1. Press the code button and then download as zip.
            2. Unzip the file in your downloads.
            3. Navigate to src/recognisers and the file face-trainner.yml should be there.
            4. Use that file how you want in your project (discard of the rest if you have no need for it).

            Also make sure that you have typed the correct file name in your program with the two 'n's (face-trainner.yml not face-trainer.yml)



            Build Bazel package from multiple repos
            Asked 2021-Jun-02 at 09:31

            I am trying to build OpenCV with external modules, but haven't been able to come up with a clean solution.

            I have successfully built OpenCV using CMake (rules_foreign_cc). But to be able to build with external modules I need to download a separate repo (opencv_contrib) and then build using the path to the second repo as a build argument.

            Is there a way I can do this without having to create a git repo of my own that combines these two git repos?



            Answered 2021-Jun-01 at 18:34

            You can use git_repository rule in your WORKSPACE file to have bazel automatically clone a git repo before building.

            Once you add it to the WORKSPACE file, then you can reference build targets of the remote repo inside your own repo.

            Check this repo for an example.



            Problem to run opencv patented SIFT and SURF although flag DOPENCV_ENABLE_NONFREE=ON is set
            Asked 2021-May-14 at 19:15

            I'm currently working on opencv vers. 4.5.1 and I want to use SIFT and SURF but I run into the well known problem that they're patented. I already know that under 4.5.1 there is the possibility to use the flags DOPENCV_ENABLE_NONFREE=ON and DBUILD_opencv_xfeatures2d=ON. But when I use the following command for cmake



            Answered 2021-May-14 at 19:15

            Build OpenCV with the following command:


            Community Discussions, Code Snippets contain sources that include Stack Exchange Network


            No vulnerabilities reported

            Install opencv_contrib

            You can build OpenCV, so it will include the modules from this repository. Contrib modules are under constant development and it is recommended to use them alongside the master branch or latest releases of OpenCV.
            Start cmake-gui.
            Select the opencv source code folder and the folder where binaries will be built (the 2 upper forms of the interface).
            Press the configure button. You will see all the opencv build parameters in the central interface.
            Browse the parameters and look for the form called OPENCV_EXTRA_MODULES_PATH (use the search form to focus rapidly on it).
            Complete this OPENCV_EXTRA_MODULES_PATH by the proper pathname to the <opencv_contrib>/modules value using its browse button.
            Press the configure button followed by the generate button (the first time, you will be asked which makefile style to use).
            Build the opencv core with the method you chose (make and make install if you chose Unix makefile at step 6).
            To run, linker flags to contrib modules will need to be added to use them in your code/IDE. For example to use the aruco module, "-lopencv_aruco" flag will be added.


            In order to keep a clean overview containing all contributed modules, the following files need to be created/adapted:.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
          • HTTPS


          • CLI

            gh repo clone opencv/opencv_contrib

          • sshUrl


          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Consider Popular Command Line Interface Libraries


            by ohmyzsh


            by microsoft


            by nvbn


            by junegunn


            by vercel

            Try Top Libraries by opencv


            by opencvC++


            by opencvTypeScript


            by opencvShell


            by opencvPython


            by opencvPython