Weighted median filtering with different rank masks.
The operator median_weighted calculates the median of the gray values within a local environment. In contrast to median, which uses all gray values within the environment exactly once, the operator median_weighted weights all gray values several times depending on their position. A gray value is received into the field to be sorted several times according to its weighting. The following masks are available:
'gauss' at MaskSize = 3 1 2 1 2 4 2 1 2 1 'inner' at MaskSize = 3 1 1 1 1 3 1 1 1 1The operator median_weighted means that, contrary to median, gray value corners remain.
|
Image (input_object) |
image(-array) -> object : byte / int2 |
| Image to be filtered. | |
|
ImageWMedian (output_object) |
image(-array) -> object : byte / int2 |
| Median filtered image. | |
|
MaskType (input_control) |
string -> string |
| Type of median mask. | |
| Default value: 'inner' | |
| List of values: 'inner', 'gauss' | |
|
MaskSize (input_control) |
integer -> integer |
| mask size. | |
| Default value: 3 | |
| List of values: 3 | |
read_image(:Image:'fabrik':) > median_weighted(Image:MedianWeighted:'gauss',3:) > disp_image(MedianWeighted:::).
For each pixel: O(F * log(F)) with F = area of MaskType.
threshold__, dyn_threshold__, regiongrowing__
R. Haralick, L. Shapiro; "Computer and Robot Vision"; Addison-Wesley, 1992, Seite 319