def restore_optimizers(self) -> None:
        """Restores the optimizer states from the pre-loaded checkpoint."""
        if not self._loaded_checkpoint:
            return

        # restore the optimizers
        self.trainer.strategy.load_optimizer_state_dict(self._loaded_checkpoint)
Restores the optimizer states from the pre-loaded checkpoint.
src/lightning/pytorch/trainer/connectors/checkpoint_connector.py