Repository navigation
Add DMD2 and f-distill training losses - #2097
Closed
CharlelieLrt wants to merge 1 commit into
Closed
CharlelieLrt wants to merge 1 commit into
CharlelieLrt wants to merge 1 commit into
Conversation
Contributor
CODEOWNERS review mapCurrent for commit ⏳ @CharlelieLrt — 8 file(s)
⏳ @megnvidia — 1 file(s)
No CODEOWNER
Comment |
This was referenced Oct 14, 2026
CharlelieLrt
force-pushed
the
codex/diffusion-distillation
branch
from
October 14, 2026 05:35
e03650a to
5788d8a
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distribution-matching
branch
from
October 14, 2026 05:35
6d301d6 to
1f727bd
Compare
This was referenced Oct 14, 2026
CharlelieLrt
force-pushed
the
codex/diffusion-distribution-matching
branch
from
October 14, 2026 17:03
1f727bd to
a3caccc
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distillation
branch
2 times, most recently
from
October 16, 2026 01:19
d1b90c9 to
ac6b31b
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distribution-matching
branch
from
October 16, 2026 01:19
a3caccc to
1e9b326
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distillation
branch
from
October 16, 2026 02:52
ac6b31b to
e0d31b0
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distribution-matching
branch
from
October 16, 2026 02:52
1e9b326 to
0263bdd
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distillation
branch
from
October 16, 2026 20:15
e0d31b0 to
7d40640
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distribution-matching
branch
2 times, most recently
from
October 17, 2026 01:44
6eb2025 to
28bfa6a
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distillation
branch
from
October 17, 2026 01:44
7d40640 to
036fccc
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distillation
branch
from
October 28, 2026 03:42
036fccc to
d87a58a
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distribution-matching
branch
from
October 28, 2026 03:42
28bfa6a to
ac444c0
Compare
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
CharlelieLrt
force-pushed
the
codex/diffusion-distillation
branch
from
October 29, 2026 02:23
d87a58a to
0a3860d
Compare
CharlelieLrt
force-pushed
the
codex/diffusion-distribution-matching
branch
from
October 29, 2026 02:23
ac444c0 to
20a4d7a
Compare
This was referenced Oct 29, 2026
Collaborator
Author
|
Continued in PhysicsNeMo #2202, from branch |
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.
Description
This PR extends
DistillationLossto DMD2 and f-distill. Users supply theirstudent, teacher, and auxiliary models, then choose the training phase explicitly
in their optimizer loop:
The loss manages method-specific state, including f-distill ratio statistics,
while the caller controls phase order and optimizer updates. For adversarial
training, configure the teacher's
feature_namesand afeature_fn(prediction, extras)callback that selects named features from itsoutput. The teacher always returns its prediction, even when the discriminator
uses only its features.
Weighted losses exclude masked values from residuals and applicable statistics.
For masked adversarial training, users provide an
adversarial_fncallbackthat excludes corrupted inputs during feature
extraction and weights the resulting discriminator scores. A pixel mask alone
cannot determine which discriminator scores are valid.
Checklist
Dependencies
Depends on
Earlier prerequisites
Depends on this PR
Later follow-ups
Parallel FastGen work
Conditional follow-up
If FastGen maintainers decline FastGen #44, we would close PhysicsNeMo #2100.
The preceding PhysicsNeMo stack would remain available.
Review process
Reviewers can compare this PR with its immediate parent. After a parent merges,
we update the remaining branches and their PR bases to keep each diff focused.