Closed dafnevk closed 8 years ago
Here's an overview of all the parameters that are in the code right now:
Basic options for running the complete program: find_holes find_islands find_indentations find_protrusions SE_size_factor area_factor connectivity binarize_datadriven
Parameters for sub-functions: remove_border_elements (but this depends on where the function remove_small_elements is used for) Threshold (for binarize, if it's not data driven or otsu - but not part of MSER?) lam_factor
Parameters that can be computed or reused: lam SE (not a primitive type. Could be link to .mat file)
Other options: visualize
I forgot the data_driven_binarization function, it has the additional arguments: area_factor_large area_factor_verylarge weights offset num_levels
Currently, the python functions take up a large number of arguments, which they have to pass along to other functions. This becomes very complicated, and default values are put in different places, which is undesired.
We need to refactor the code so that the global config properties (the size factors etc) can be given in a convenient manner to all the functions without the number of arguments being very large. For example using **kwargs and/or some config class where we store the parameters.