def reset_patch(self, initial_patch_value: float | np.ndarray | None) -> None:
        """
        Reset the adversarial patch.

        :param initial_patch_value: Patch value to use for resetting the patch.
        """
        if initial_patch_value is None:
            self.patch = np.ones(shape=self.patch_shape).astype(np.float32) * self.mean_value
        elif isinstance(initial_patch_value, float):
            self.patch = np.ones(shape=self.patch_shape).astype(np.float32) * initial_patch_value
        elif self.patch is not None and self.patch.shape == initial_patch_value.shape:
            self.patch = initial_patch_value
        else:
            raise ValueError("Unexpected value for initial_patch_value.")

        Reset the adversarial patch.

        :param initial_patch_value: Patch value to use for resetting the patch.
        
art/attacks/evasion/adversarial_patch/adversarial_patch_numpy.py