Skip to content

DPS and SDA guidance for diffusion#1381

Merged
CharlelieLrt merged 268 commits intoNVIDIA:mainfrom
CharlelieLrt:diffusion-sda-guidance
Feb 18, 2026
Merged

DPS and SDA guidance for diffusion#1381
CharlelieLrt merged 268 commits intoNVIDIA:mainfrom
CharlelieLrt:diffusion-sda-guidance

Conversation

@CharlelieLrt
Copy link
Collaborator

PhysicsNeMo Pull Request

Description

Overview

This PR introduces a modular framework for Diffusion Posterior Sampling (DPS) guidance, enabling constrained generation and data assimilation with diffusion models.

New Abstractions

DPSGuidance Protocol (physicsnemo.diffusion.guidance)

Minimal interface for guidance implementations. Any callable (x, t, x_0) -> Tensor satisfies this protocol.

DPSDenoiser (physicsnemo.diffusion.guidance)

Transforms an x0-predictor into a score predictor by combining:

  • Input denoiser (x0-predictor from trained diffusion model)
  • One or more DPSGuidance instances
  • Conversion callback (x0_to_score_fn from noise scheduler)
Concrete Guidance Implementations
Class Use Case
ModelConsistencyDPSGuidance Generic (nonlinear) observation operators
DataConsistencyDPSGuidance Masked observations (inpainting, sparse probes)

Both support configurable norm order (L1, L2, etc.) and optional SDA scaling via gamma parameter.

Files Changed

  • physicsnemo/diffusion/guidance/dps_guidance.py — New guidance implementations
  • physicsnemo/diffusion/guidance/__init__.py — Updated exports

Future Work

  • Multi-diffusion guidance (planned for future PR)

Checklist

Dependencies

Review Process

All PRs are reviewed by the PhysicsNeMo team before merging.

Depending on which files are changed, GitHub may automatically assign a maintainer for review.

We are also testing AI-based code review tools (e.g., Greptile), which may add automated comments with a confidence score.
This score reflects the AI’s assessment of merge readiness and is not a qualitative judgment of your work, nor is
it an indication that the PR will be accepted / rejected.

AI-generated feedback should be reviewed critically for usefulness.
You are not required to respond to every AI comment, but they are intended to help both authors and reviewers.
Please react to Greptile comments with 👍 or 👎 to provide feedback on their accuracy.

coreyjadams and others added 30 commits November 5, 2025 09:37
phsyicsnemo.utils, launch.config is just gone.  It was empty.
* Move filesystems and version_check to core

* Fix version check tests

* Reorganize distributed, domain_parallel, and begin nn / utils cleanup.

* Move modules and meta to core.  Move registry to core.

No tests fixed yet.

* Add missing init files

* Update build system and specify some deps.

* Reorganize tests.

* Update init files

* Clean up neighbor tools.

* Update testing

* Fix compat tests

* Move core model tests to tests/core/

* Add import lint config

* Relocate layers

* Move graphcast utils into model directory

* Relocating util functionalities.

* Add FIGConvNet to crash example (NVIDIA#1207)

* Add FIGConvNet to crash example.

* Add FIGConvNet to crash example

* Update model config

* propose fix some typos (NVIDIA#1209)

Signed-off-by: John E <jeis4wpi@outlook.com>
Co-authored-by: Corey adams <6619961+coreyjadams@users.noreply.github.com>

* Further clean up and organize tests.

* utils tests are passing now

* Cleaning up distributed tests

* Patching tests working again in nn

* Fix sdf test

* Fix zenith angle tests

* Some organization of tests.  Checkpoints is moved into utils.

* Remove launch.utils and launch.config.  Checkpointing is moved to
phsyicsnemo.utils, launch.config is just gone.  It was empty.

* Most nn tests are passing

* Further cleanup.  Getting there!

* Remove constants file

* Add import linting to pre-commit.

---------

Signed-off-by: John E <jeis4wpi@outlook.com>
Co-authored-by: Alexey Kamenev <alex.kamenev@gmail.com>
Co-authored-by: John Eismeier <42679190+jeis4wpi@users.noreply.github.com>
* unmigrate the insolation utils

* Revert test and compat map

* Update importlinter
* Move filesystems and version_check to core

* Fix version check tests

* Reorganize distributed, domain_parallel, and begin nn / utils cleanup.

* Move modules and meta to core.  Move registry to core.

No tests fixed yet.

* Add missing init files

* Update build system and specify some deps.

* Reorganize tests.

* Update init files

* Clean up neighbor tools.

* Update testing

* Fix compat tests

* Move core model tests to tests/core/

* Add import lint config

* Relocate layers

* Move graphcast utils into model directory

* Relocating util functionalities.

* Further clean up and organize tests.

* utils tests are passing now

* Cleaning up distributed tests

* Patching tests working again in nn

* Fix sdf test

* Fix zenith angle tests

* Some organization of tests.  Checkpoints is moved into utils.

* Remove launch.utils and launch.config.  Checkpointing is moved to
phsyicsnemo.utils, launch.config is just gone.  It was empty.

* Most nn tests are passing

* Further cleanup.  Getting there!

* Remove constants file

* Add import linting to pre-commit.

* Move gnn layers and start to fix several model tests.

* AFNO is now passing.

* Rnn models passing.

* Fix improt

* Healpix tests are working

* Domino and unet working
* Update activations path in dlwp tests

* Update example paths
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
…iple guidances into a single denoiser

Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
@CharlelieLrt CharlelieLrt force-pushed the diffusion-sda-guidance branch from 6e35e73 to 723c53a Compare February 18, 2026 03:15
Signed-off-by: Charlelie Laurent <claurent@nvidia.com>
@CharlelieLrt
Copy link
Collaborator Author

/blossom-ci

@CharlelieLrt CharlelieLrt added this pull request to the merge queue Feb 18, 2026
Merged via the queue into NVIDIA:main with commit 8aa52ad Feb 18, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

! - Release PRs or Issues releating to a release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants