Unverified Commit d1d5ebb1 authored by Shijie Wu's avatar Shijie Wu Committed by GitHub
Browse files

Remove duplicated os.path.join (#17192)

parent a10f6183
...@@ -1808,7 +1808,7 @@ class Trainer: ...@@ -1808,7 +1808,7 @@ class Trainer:
local_rank = xm.get_local_ordinal() if is_torch_tpu_available() else self.args.local_rank local_rank = xm.get_local_ordinal() if is_torch_tpu_available() else self.args.local_rank
if local_rank != -1: if local_rank != -1:
rng_file = os.path.join(checkpoint, f"rng_state_{local_rank}.pth") rng_file = os.path.join(checkpoint, f"rng_state_{local_rank}.pth")
if not os.path.isfile(os.path.join(checkpoint, rng_file)): if not os.path.isfile(rng_file):
logger.info( logger.info(
f"Didn't find an RNG file for process {local_rank}, if you are resuming a training that " f"Didn't find an RNG file for process {local_rank}, if you are resuming a training that "
"wasn't launched in a distributed fashion, reproducibility is not guaranteed." "wasn't launched in a distributed fashion, reproducibility is not guaranteed."
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment