Unverified Commit 1d6a8474 authored by Zach Mueller's avatar Zach Mueller Committed by GitHub
Browse files

Fix checkpoint path in `no_trainer` scripts (#26733)

checkpoint path
parent 6ecb2ab6
...@@ -465,7 +465,7 @@ def main(): ...@@ -465,7 +465,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -689,7 +689,7 @@ def main(): ...@@ -689,7 +689,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -588,7 +588,7 @@ def main(): ...@@ -588,7 +588,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -625,7 +625,7 @@ def main(): ...@@ -625,7 +625,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -571,7 +571,7 @@ def main(): ...@@ -571,7 +571,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -808,7 +808,7 @@ def main(): ...@@ -808,7 +808,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -839,7 +839,7 @@ def main(): ...@@ -839,7 +839,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -569,7 +569,7 @@ def main(): ...@@ -569,7 +569,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -640,7 +640,7 @@ def main(): ...@@ -640,7 +640,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -518,7 +518,7 @@ def main(): ...@@ -518,7 +518,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -678,7 +678,7 @@ def main(): ...@@ -678,7 +678,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
...@@ -621,7 +621,7 @@ def main(): ...@@ -621,7 +621,7 @@ def main():
path = os.path.basename(checkpoint_path) path = os.path.basename(checkpoint_path)
accelerator.print(f"Resumed from checkpoint: {checkpoint_path}") accelerator.print(f"Resumed from checkpoint: {checkpoint_path}")
accelerator.load_state(path) accelerator.load_state(checkpoint_path)
# Extract `epoch_{i}` or `step_{i}` # Extract `epoch_{i}` or `step_{i}`
training_difference = os.path.splitext(path)[0] training_difference = os.path.splitext(path)[0]
......
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