Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support checkpointing in JAX decorators #5374

Merged
merged 5 commits into from
Mar 27, 2024

Conversation

szkarpinski
Copy link
Collaborator

@szkarpinski szkarpinski commented Mar 13, 2024

Category:

New feature (non-breaking change which adds functionality)

Description:

In this PR I add checkpoints kwarg to @data_iterator and @peekable_data_iterator, which (if provided) is forwarded to the underlying pipelines, allowing restoring them from checkpoints.

Additional information:

Affected modules and functionalities:

JAX @data_iterator and @peekable_data_iterator.

Key points relevant for the review:

Tests:

  • Existing tests apply
  • New tests added
    • Python tests
    • GTests
    • Benchmark
    • Other
  • N/A

Checklist

Documentation

  • Existing documentation applies
  • Documentation updated
    • Docstring
    • Doxygen
    • RST
    • Jupyter
    • Other
  • N/A

DALI team only

Requirements

  • Implements new requirements
  • Affects existing requirements
  • N/A

REQ IDs: N/A

JIRA TASK: DALI-3786

@szkarpinski
Copy link
Collaborator Author

!build

@szkarpinski szkarpinski marked this pull request as draft March 13, 2024 17:57
@@ -81,7 +81,8 @@ class DALIGenericIterator(_DaliBaseIterator):
prepare_first_batch : bool, optional, default = True
Whether DALI should buffer the first batch right after the creation of the iterator,
so one batch is already prepared when the iterator is prompted for the data
sharding : ``jax.sharding.Sharding`` compatible object that, if present, will be used to
sharding : `jax.sharding.Sharding`
`jax.sharding.Sharding` compatible object that, if present, will be used to
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looked like this before:
image

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [13498814]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [13498814]: BUILD FAILED

Signed-off-by: Szymon Karpiński <skarpinski@nvidia.com>
Signed-off-by: Szymon Karpiński <skarpinski@nvidia.com>
Signed-off-by: Szymon Karpiński <skarpinski@nvidia.com>
Signed-off-by: Szymon Karpiński <skarpinski@nvidia.com>
@szkarpinski szkarpinski marked this pull request as ready for review March 20, 2024 12:07
@szkarpinski szkarpinski marked this pull request as draft March 21, 2024 09:12
@szkarpinski szkarpinski marked this pull request as ready for review March 22, 2024 09:12
Signed-off-by: Szymon Karpiński <skarpinski@nvidia.com>
@szkarpinski
Copy link
Collaborator Author

!build

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [13825594]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [13825594]: BUILD PASSED

@szkarpinski szkarpinski merged commit 7c0695e into NVIDIA:main Mar 27, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants