Repository navigation
bench: diagnose why temporal trails FSR1 in motion (+ motion-adaptive cap candidate) - #107
Draft
DennisSmolek wants to merge 1 commit into
Draft
DennisSmolek wants to merge 1 commit into
DennisSmolek wants to merge 1 commit into
Conversation
…ap candidate Ranks the causes of temporal's motion deficit to FSR1 (Q4/Q19, production RCAS) against the ground-truth reference: 1. Accumulation length under motion: +2.58 / +1.72 / +1.58 dB recovered on Q4 translate / Q19 orbit-left / Q4 orbit with maxAccumulation 2. The loss sits on thin high-contrast features in both frequency bands; bilinear history costs another 0.55-0.90 dB, so the resampling chain is on the path. 2. Lanczos2 vs EASU single-frame upsample: -0.02 / -0.31 dB. 3-7. Auto-exposure, locks, disocclusion/young/border, the shading detector and input mip bias each measure <= 0.3 dB; harness alignment is exact. Prototype (bench-only, production shader and defaults untouched): a motion-adaptive accumulation cap via a new internal `_accumulateShader` option. `accumulate-motion-cap2-early-v1` puts temporal at or above FSR1 on all 8 motion windows (+0.01..+0.50 dB, from -0.01..-2.13), leaves every still window unchanged, and recovers +0.97 dB on the held-out Q2. Tooling: measure-reference-quality.mjs gains --reference-offset, --save-diagnostics and per-window guide stats; analyze-reference-error.mjs attributes the deficit by pixel class and frequency band. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
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.
Diagnosis follow-up to #104: why does temporal trail FSR1 spatial on every Q4/Q19 motion segment (−0.01 to −2.13 dB, production RCAS) while leading on every still one? This PR changes no production shader or library default. The fix is a bench-only prototype; whether to ship it is a separate decision.
Ranked causes
Full-frame PSNR at ratio 2 on the worst segments, in the order Q4 translate / Q19 orbit-left / Q4 orbit. Positive numbers are dB recovered toward FSR1.
maxAccumulation2maxAccumulation1Supporting evidence:
maxAccumulation4 everywhere keeps still-scene PSNR but raises still-scene temporal error 6× (0.118 → 0.706/255).Candidate fix (bench-only): motion-adaptive accumulation cap
bench/src/candidates/shaders/accumulateVariants.tsrewrites only the blend of productionACCUMULATE_SHADER:It is wired through a new internal
_accumulateShaderoption,_-prefixed and never exported, like_depthClipShader.accumulate-motion-cap2-early-v1uses cap 2 with a 0.05 → 0.5 px/frame ramp, the still-scene relax's own fade. Results:Not measured yet: GPU cost (expected negligible), ratio 3, the effect-graph scenarios, and an interactive look at slow pans for crawl.
Tooling
measure-reference-quality.mjsgains:--reference-offset, for alignment checks;--save-diagnostics, which keeps presented frames and temporal guides;scripts/analyze-reference-error.mjssplits one mode's deficit against another by pixel class (border, disoccluded, young, edge by motion third, interior) and by frequency band, and writes a signed difference PNG.Write-up with every reproduce command:
bench/docs/REFERENCE-QUALITY.md, section "Why temporal trails FSR1 in motion".PAPER-NOTES.mdand BENCHMARKING.md's identity table are updated.Follow-ups (not in this PR)
TemporalGuides.history(intypes.ts) anddocs/temporal-guides.mddocument.aas accumulation age in frames. The shader actually stores age ÷maxAccumulation(0–1).Verification
pnpm lint,pnpm typecheckandpnpm testpass (593 tests, including 2 new GPU-free structural tests for the candidate shaders).🤖 Generated with Claude Code