Add Stable Cascade segmented checkpointing support - #2958
Merged
bghira merged 2 commits intoAug 3, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds Stable Cascade (UNet) support for segmented/interval-based gradient checkpointing controls, aligning this model family with the broader segmented-checkpointing feature set introduced in the base stack branch.
Changes:
- Adds Stable Cascade UNet hooks to apply interval + segment-stride checkpoint selection via
should_checkpoint_block. - Extends safety-check allow-lists to permit interval/stride flags for
stable_cascade. - Adds/extends unit tests covering Stable Cascade checkpoint interval/stride behavior and model-family capability declarations.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| tests/test_stable_cascade_modules.py | Adds behavioral unit test verifying which Stable Cascade blocks are checkpointed under interval/stride settings. |
| tests/test_segmented_checkpointing_model_support.py | Registers Stable Cascade in the shared “model supports which controls” test matrix. |
| simpletuner/helpers/training/default_settings/safety_check.py | Adds stable_cascade to the interval + segment-stride supported model allow-lists. |
| simpletuner/helpers/models/stable_cascade/unet.py | Implements interval/stride-aware checkpoint dispatch in Stable Cascade UNet forward path. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
bghira
force-pushed
the
agent/segmented-checkpointing-stable-cascade
branch
from
August 3, 2026 10:45
e1c726b to
da1e2aa
Compare
bghira
force-pushed
the
agent/segmented-checkpointing-stable-cascade
branch
from
August 3, 2026 15:30
da1e2aa to
041d629
Compare
bghira
force-pushed
the
agent/segmented-checkpointing-stable-cascade
branch
from
August 3, 2026 15:32
041d629 to
e4733f3
Compare
bghira
force-pushed
the
agent/segmented-checkpointing-stable-cascade
branch
from
August 3, 2026 15:33
e4733f3 to
3743bfb
Compare
bghira
force-pushed
the
agent/segmented-checkpointing-stable-cascade
branch
from
August 3, 2026 15:35
3743bfb to
1e28e25
Compare
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.
Summary
Splits the Stable Cascade segmented checkpointing support model integration out of #2925.
Stack
Base branch:
agent/segmented-checkpointing-sd3Validation
.venv/bin/python -m unittest tests.test_segmented_checkpointing_model_support -v.venv/bin/python -m unittest tests.test_stable_cascade_modules -v