code: def get_states(self, dump_optimizer=False):
          
          return pickle.dumps((self.states, self.optimizer) if dump_optimizer else self.states)
docs: Gets updater states.
  
          Parameters
          ----------
          dump_optimizer : bool, default False
              Whether to also save the optimizer itself. This would also save optimizer
              information such as learning rate and weight decay schedules.