예제 #1
0
 def has_checkpoint(self):
     """
     Returns:
         bool: whether a checkpoint exists in the target directory.
     """
     save_file = os.path.join(self.save_dir, "last_checkpoint")
     return PathManager.exists(save_file)
예제 #2
0
 def has_checkpoint(self):
     save_file = os.path.join(self.save_dir, f"last_weight_{self.rank:02d}")
     return PathManager.exists(save_file)