def METHOD_NAME(self, event: Event, state: State, logger: Optional[Logger]) -> Optional[int]:
    assert state.optimizers is not None
    state.optimizers = tuple(
        SAMOptimizer(
            base_optimizer=optimizer,
            rho=self.rho,
            epsilon=self.epsilon,
            interval=self.interval,
        ) for optimizer in ensure_tuple(state.optimizers))