mroeder
mroeder

Reputation: 43

How to install OpenCV 3.3.1. Tracking API (Ubuntu 16.04)

I am using Ubuntu 16.04 and I installed OpenCV 3.3.1. from the sources from GitHub. What I want to use is the tracking API like in the following tutorial: https://docs.opencv.org/3.1.0/d2/d0a/tutorial_introduction_to_tracker.html

But it seems like the needed module is not included. I also tried to use the contrib library (https://github.com/opencv/opencv_contrib) as well, but it doesn't build for this OpenCV version. I always get errors like:

    error: ‘NMSBoxes’ is not a member of ‘cv::dnn’
        cv::dnn::NMSBoxes(bbox, outProbabillities, 0.3f, 0.4f, indexes);

Can anyone help me please?

Upvotes: 1

Views: 1475

Answers (2)

Run
Run

Reputation: 1

  1. Checking version of opencv and version of opencv_contrib.

    1.1 command: "cd opencv" ( source folder ) => command: "git tag" => show version.

    1.2 command: "cd opencv_contrib" ( source folder ) => command: "git tag" => show version.

  2. Set version of opencv same with version of opencv_contrib.

    2.1 command: "git checkout 3.3.1" at "opencv".

    2.1 command: "git checkout 3.3.1" at "opencv_contrib".

  3. command: "cd ".

  4. command: "cmake -DOPENCV_EXTRA_MODULES_PATH=/modules ".

  5. command: "make -j4".

Upvotes: 0

Rick 0xfff
Rick 0xfff

Reputation: 226

I ran into this as well. I had cloned both "opencv" and "opencv_contrib" from Github, and checked out "opencv" at tag 3.3.1, but failed to check out "opencv_contrib" at the same tag level. That produced the error looking for ‘NMSBoxes’.

After checking out "opencv_contrib" at the same tag as "opencv", the build ran to completion.

Upvotes: 4

Related Questions