checkpoints.restore_checkpoint` should raise an error for explicit paths that don't exist
- Dominant language
- Jupyter Notebook
- Stars
- 7.3k
- Forks
- 833
- Avg merge
- 5h 11m
- Merged PRs (30d)
- 5
Description
### Discussed in https://github.com/google/flax/discussions/1612
Originally posted by **PgLoLo** October 9, 2021
From documentation of `flax.training.checkpoints.restore_checkpoint`:
>Returns:
> Restored `target` updated from checkpoint file, or if no step specified and
> no checkpoint files present, returns the passed-in `target` unchanged.
> If a file path is specified and is not found, the passed-in `target` will be
> returned. This is to match the behavior of the case where a directory path
> is specified but the directory has not yet been created.
Why silently hiding the checkpoint absence (which is a great potential for a bug: by path misspecification, step misspecification, etc.) is a good idea? Makes no sense to me, is there any logic behind this decision?
Contributor guide
Assessment
This issue has not been assessed yet.