Ask Your Question
0

Why is the python binding not complete ?

asked 2018-11-07 08:07:47 -0600

Tyrossel gravatar image

Is there any reason why some functions or classes are not available in the python binding of OpenCV ?

This page in the documentation indicates how to export elements for python, and it is quite easy to use.

For example, the high-level cv2.Stitcher class is not very tunable, because the ExposureCompensator cannot be selected, or the stitch function does not exist with ROIs parameters.

edit retag flag offensive close merge delete

Comments

1

A pr is in progress and may be it will help you. "It is quite easy to use" yes but you should try yourself. Feel free to make a PR

LBerger gravatar imageLBerger ( 2018-11-07 08:25:39 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
1

answered 2018-11-07 08:18:29 -0600

berak gravatar image

the python bindings are auto-generated, and for some exotic c++ constructs there is no easy way to do this,

so none of those are exposed to the python api.

edit flag offensive delete link more

Comments

python binding it's easy ?

blender class is here

FeatherBlender is here

Now if you write:

   blender = cv.detail_FeatherBlender(1./blend_width)
   blender.prepare(corners, sizes)

Error

blender.prepare(corners, sizes) TypeError: detail_FeatherBlender.prepare() takes at most 1 argument (2 given)

and if you write

        blender = cv.detail.Blender_createDefault(cv.detail.Blender_FEATHER)
        blender.setSharpness(1./blend_width)
LBerger gravatar imageLBerger ( 2019-01-03 09:30:46 -0600 )edit

Error :

  blender.setSharpness(1./blend_width)  
  AttributeError: 'cv2.detail_Blender' object has no attribute 'setSharpness'
LBerger gravatar imageLBerger ( 2019-01-03 09:31:26 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2018-11-07 08:07:47 -0600

Seen: 472 times

Last updated: Nov 07 '18