Copybara import of the pull request https://github.com/google/flax/pull/2497
Copybara import of the pull request https://github.com/google/flax/pull/2497

--
e0b43740bbe0a6adf128f9d3b8fcabc03fb1d2c1 by ivyzheng <ivyzhengx@gmail.com>:

Explicitly raise error when Flax restore_checkpoint path given is nonexistent. Also fixing all third_party usages.

PiperOrigin-RevId: 488534739

google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research,google-research/google-research