Ask Your Question
0

Error static function 'bool pyopencv_to<DAISY_NormalizationType> not defined

asked 2019-01-08 18:20:36 -0500

D.H. Lee gravatar image

Hi. I've tried to compile opencv 3.4.5 for using nonfree (xfeatures2d). but I can't solve this problem. please help me.

  1. OS : windows 10 64bit
  2. compiler : visual studio 2017 community (set: release x64)
  3. compile error a. code : C2129 b. description : static function 'bool pyopencv_to <daisy_normalizationtype>(PyObject , T& const char)' declared but not defined
edit retag flag offensive close merge delete

Comments

Please full error message with line number and file name.

Can check this build\opencv\opencv2\opencv_modules.hpp? You should find #define HAVE_OPENCV_XFEATURES2D

You should have file opencv_contrib\modules\xfeatures2d\misc\python\pyopencv_xfeatures2d.hpp too can you check it?

If you don't need python binding you can try disable it in cmake-gui

LBerger gravatar imageLBerger ( 2019-01-09 02:54:41 -0500 )edit

are you sure, that your opencv main repo has exactly the same version as your contrib one ?

berak gravatar imageberak ( 2019-01-09 02:57:00 -0500 )edit

https://github.com/opencv/opencv/blob... missing in 3.4.5 (support for named enums)

berak gravatar imageberak ( 2019-01-09 03:02:40 -0500 )edit
1

@LBerger, @berak, thank you very much

D.H. Lee gravatar imageD.H. Lee ( 2019-01-10 19:51:33 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2019-01-09 03:02:05 -0500

berak gravatar image

it seems, you try to compile the master branch from opencv_contrib with 3.4.5 from opencv main, this won't work.

please either update your main opencv to master, or downgrade the contrib one to 3.4.5, too.

edit flag offensive delete link more

Comments

Thank you very much! I can compile by you help. I downgraded opencv_contrib to 3.4.5.(changed github branch from master to 3.4) Now I can run opencv-python but pylint works wrong. It doesn't recognize members of cv2, so I add an argument "extension-pkg-whitelist=cv2" to setting.

D.H. Lee gravatar imageD.H. Lee ( 2019-01-09 23:43:26 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2019-01-08 18:20:36 -0500

Seen: 69 times

Last updated: Jan 09