Skip to content

Skip unused Gaussian derivatives in xFit model evaluation - #65

Merged
tpn merged 1 commit into
mainfrom
codex/xfit-value-only-20260927
Sep 28, 2026
Merged

tpn merged 1 commit into
mainfrom
codex/xfit-value-only-20260927

Conversation

@tpn

@tpn tpn commented Sep 27, 2026 •

Copy link
Copy Markdown
Collaborator

Gaussian residual evaluation computes derivative arrays for both lobes and discards them. Return each lobe value before those calculations, preserving the model arithmetic and the existing Jacobian path.

This optimization can land independently of the FITS pipeline changes in #64. Its patch is unchanged by extraction from that stack. Validation of the extracted #63/#65 candidate: 2,653 CPU tests passed, 184 skipped, and all lint/type hooks passed. The following component and GPU results predate this extraction; no new GPU campaign was run for it. 151 CPU xFit tests pass. Ten matched GPU replay launches preserve exact scientific outputs and evaluation/status vectors, with warm fit medians improving by 1.056–1.089× across three frozen cases. Representative and slow cases include reversed-order independent repeats.

The committed wheel also passes exact full-output comparisons on 16 registered image pairs with eight GB200 GPUs, using both MPI and Dragon and forced KvikIO compatibility reads. Each baseline/candidate comparison preserves worker-to-item/GPU placement, candidates and solver settings. All 256 fits retain their evaluation/status vectors, including the same 14 fits reaching the 1,800-evaluation cap.

Each full-pipeline launch has one warmup and three measured rounds. Times below are baseline → candidate, in seconds:

Runtime Median measured batch Warmup batch Complete launch
MPI 25.739 → 23.921 31.557 → 106.163 140.067 → 212.951
Dragon 26.454 → 24.519 30.181 → 29.283 152.146 → 150.727

Measured batch median speed ratios are 1.076× and 1.079×, respectively. The complete MPI launch is slower with its long warmup; the cause is unestablished. Complete-launch times include all rounds, startup, coordinator audits and shutdown. These are single launches per source/runtime; MPI and Dragon use separate matched comparisons. The earlier fit replay timings are a separate measurement.

@tpn
tpn requested a review from melo-gonzo September 27, 2026 07:28
@coderabbitai

coderabbitai Bot commented Sep 27, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • ai-review

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository: NVIDIA/cuPhoton/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 594e44fe-1cd3-4701-8b1a-24fdbc1fec3d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Comment @coderabbitai help to get the list of available commands.

@tpn
tpn marked this pull request as ready for review September 28, 2026 16:07
@tpn
tpn force-pushed the codex/xscan-fits-pipeline branch from 777538f to f0a16d3 Compare September 28, 2026 17:25
@tpn
tpn force-pushed the codex/xfit-value-only-20260927 branch from f3a58cc to 16e1729 Compare September 28, 2026 17:25

@melo-gonzo melo-gonzo left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM. Local base/head comparisons preserve model values, Jacobians, and complete fit results exactly. The reported warm-batch gain and slower overall MPI launch remain clearly distinguished.

Gaussian residual evaluation only needs each lobe value. Return that
value before building derivative arrays, while retaining the existing
arithmetic and full Jacobian path.

Signed-off-by: Trent Nelson <trentn@nvidia.com>
@tpn
tpn force-pushed the codex/xfit-value-only-20260927 branch from ed0efe9 to 76224c4 Compare September 28, 2026 21:50
@tpn
tpn changed the base branch from codex/xscan-fits-pipeline to main September 28, 2026 21:51
@tpn
tpn merged commit 73c47b7 into main Sep 28, 2026
47 of 62 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.

2 participants