fuzzyclust.image.add_image_noise#
- fuzzyclust.image.add_image_noise(image, noise='gaussian', noise_level=0.1, random_state=None, value_range=None)[source]#
Corrupt an image with Gaussian, salt-and-pepper or both kinds of noise.
- Parameters:
- image
ndarrayofshape(H,W)or(H,W,C) - noise{“gaussian”, “salt_pepper”, “both”, “none”}, default=”gaussian”
- noise_level
float, default=0.1 Standard deviation of the Gaussian noise (in the units of the image) and/or the fraction of pixels hit by salt-and-pepper noise.
- random_state
int,RandomStateinstanceorNone - value_range
tuple(low,high),optional Values of “pepper” and “salt”; default the minimum and maximum of the image.
- image
- Returns:
- noisy
ndarray,sameshapeasimage
- noisy
Examples using fuzzyclust.image.add_image_noise#
Image segmentation under noise: six spatially constrained FCM variants
Image segmentation under noise: six spatially constrained FCM variants
Spatial FCM: the neighborhood weight and the window size
Spatial FCM: the neighborhood weight and the window size