def __init__(
        self,
        window_size: int = 3,
        channels_first: bool = False,
        clip_values: CLIP_VALUES_TYPE | None = None,
        apply_fit: bool = False,
        apply_predict: bool = True,
    ) -> None:
        """
        Create an instance of local spatial smoothing.

        :param channels_first: Set channels first or last.
        :param window_size: The size of the sliding window.
        :param clip_values: Tuple of the form `(min, max)` representing the minimum and maximum values allowed
               for features.
        :param apply_fit: True if applied during fitting/training.
        :param apply_predict: True if applied during predicting.
        """
        super().__init__(is_fitted=True, apply_fit=apply_fit, apply_predict=apply_predict)

        self.channels_first = channels_first
        self.window_size = window_size
        self.clip_values = clip_values
        self._check_params()

        Create an instance of local spatial smoothing.

        :param channels_first: Set channels first or last.
        :param window_size: The size of the sliding window.
        :param clip_values: Tuple of the form `(min, max)` representing the minimum and maximum values allowed
               for features.
        :param apply_fit: True if applied during fitting/training.
        :param apply_predict: True if applied during predicting.
        
art/defences/preprocessor/spatial_smoothing.py