original_docstring: Loads the model and the optimizer.
  
          Args:
              save_dir: absolute path to loading dir.
          
docstring: Loads the model and the optimizer.
docstring_tokens: Loads the model and the optimizer .
code: def load(self, save_dir):
          """Loads the model and the optimizer.
  
          Args:
              save_dir: absolute path to loading dir.
          """
  
          file_name = os.path.join(save_dir, "model.p")
          self.load_state_dict(torch.load(file_name))
  
          file_name = os.path.join(save_dir, "optim.p")
          self.optimizer.load_state_dict(torch.load(file_name))
code_tokens: def load ( self , save_dir ) : file_name = os . path . join ( save_dir , "model.p" ) self . load_state_dict ( torch . load ( file_name ) ) file_name = os . path . join ( save_dir , "optim.p" ) self . optimizer . load_state_dict ( torch . load ( file_name ) )
short_docstring: Loads the model and the optimizer.
short_docstring_tokens: Loads the model and the optimizer .
comment: """Loads the model and the optimizer.
  
          Args:
              save_dir: absolute path to loading dir.
          """