Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

HOW TO: mser constructor with algorithm parameters (python)

Hi all,

I've noticed that using C++ it is possible to set the algorithm parameters when constructing the object. (see: http://docs.opencv.org/modules/features2d/doc/feature_detection_and_description.html?highlight=mser#MSER : public FeatureDetector)

I do not succeed to do the same in python (see code below). The object is constructed without errors, but I can't see the properties, nor modify them or set them manually. Any ideas? Btw, I'm using this mser method because it returns me the contours and not only the key points.

_delta = 10 
_min_area = 25 
_max_area = 2000
_max_variation = 10.0 
_min_diversity = 10.0
_max_evolution = 10 
_area_threshold = 12.0
_min_margin = 2.9 
_edge_blur_size = 3    

mser2 = cv2.MSER(_delta,_min_area,_max_area,
      _max_variation, _min_diversity,
      _max_evolution, _area_threshold,
      _min_margin, _edge_blur_size )

Best of wishes for 2014!

Kind regards, Koen