State checkpointer refactor#394
Merged
Merged
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #394 +/- ##
==========================================
+ Coverage 76.83% 77.63% +0.79%
==========================================
Files 156 157 +1
Lines 9472 9553 +81
==========================================
+ Hits 7278 7416 +138
+ Misses 2194 2137 -57 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
fatemetkl
commented
Jun 5, 2025
fatemetkl
commented
Jun 5, 2025
| self.state_checkpoint_name | ||
| ) # self.state_checkpoint_name initialized in base FLServer Class | ||
| ): | ||
| self._load_server_state() |
Collaborator
Author
There was a problem hiding this comment.
We don't need to call _load_server_state() here because it will be called in FlServer's fit_with_per_round_checkpointing()
b5c6a6d to
80fbafd
Compare
019bc21 to
96f1858
Compare
…refactor Potential way to simplify a few things in refactor.
emersodb
reviewed
Jun 18, 2025
emersodb
left a comment
Collaborator
There was a problem hiding this comment.
Nearly ready to go I think a couple of small questions and suggested refactors, but looks great!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Type
Fix
Short Description
Clickup Ticket(s): https://app.clickup.com/t/868d4w5rt
Unifying our PerRoundStateCheckpointer and the Snapshotting functionality that supports early stopping.
This PR adds
checkpointing.state_checkpointermodules with classes that can be used to checkpoint the state of the server and clients.Tests Added
tests/checkpointing/test_state_checkpointer.pytests/utils/test_early_stopper.pyI also manually tested our
nnunet_exampleto make sureNnUnetServerCheckpointAndStateModuleworks as expected. We have a smoke test (load_from_checkpoint_example) forServerPerRoundStateCheckpointer.