Skip to content

Commit

Permalink
Don't download if we don't have to
Browse files Browse the repository at this point in the history
  • Loading branch information
epwalsh committed Oct 8, 2023
1 parent d22ef89 commit c110059
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion olmo/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -672,7 +672,9 @@ def restore_checkpoint(
)
elif checkpoint_type == CheckpointType.sharded or checkpoint_type is None:
try:
legacy_mode = resource_path(load_path, f"rank{get_global_rank()}.pt").is_file()
legacy_mode = resource_path(
load_path, f"rank{get_global_rank()}.pt", local_cache=local_cache
).is_file()
except FileNotFoundError:
legacy_mode = False
if legacy_mode:
Expand Down

0 comments on commit c110059

Please sign in to comment.