Repository navigation
fix(sycl): clip integer_motion2 score to motion_max_val (1080p checkerboard drift) - #1315
Merged
Merged
Conversation
lusoris
force-pushed
the
fix/sycl-motion2-checkerboard-drift
branch
3 times, most recently
from
September 5, 2026 23:11
7294850 to
f4c8102
Compare
lusoris
force-pushed
the
fix/sycl-motion2-checkerboard-drift
branch
from
September 6, 2026 02:00
f4c8102 to
d090d46
Compare
lusoris
marked this pull request as ready for review
September 6, 2026 02:00
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
Fixes a numerical parity bug where the SYCL integer motion feature extractor emitted unclipped motion2 and score values when motion_max_val was configured.
In core/src/feature/sycl/integer_motion_sycl.cpp, motion2_clipped = MIN(motion2 * s->motion_fps_weight, s->motion_max_val) was computed, but the feature collector previously appended raw unclipped motion2 (line 841), raw motion_score in debug mode (line 848), and unclipped prev_motion_score in flush_fex_sycl (line 896).
On 1080p checkerboard reference pairs (checkerboard_1920_1080_10_3_0_0.yuv vs ..._1_0.yuv and ..._10_0.yuv), raw motion scores reach ~18.805 (frame 1) and ~18.858 (frame 2), so with motion_max_val=18.0 CPU clamped to 18.0 yielding pooled mean 12.000000, whereas SYCL yielded 12.554712.
Appending motion2_clipped and last_motion2 achieves exact 0 ULP diff on both 1080p checkerboard pairs (12.000000 on both CPU and SYCL) and maintains src01 parity within 1e-5.
The duplicate _x86_simd_strict_fp_extra hunk in core/src/meson.build carried by draft PR #1307 was dropped from this branch.
Parity verified via core/build/test/test_sycl_motion3_parity, python/test/sycl_motion_parity_test.py, and the CLI reproducer on Intel Arc A380.
Type
fix— Fix integer_motion2 score clipping to motion_max_val under SYCL backendChecklist
make format && make lintis green locally (pre-commit on every touched file).Bug-status hygiene (ADR-0165)
docs/state.md— added T-SYCL-MOTION2-CHECKERBOARD-DRIFT-2026-09-05 to Recently closed.Netflix golden-data gate (ADR-0024)
assertAlmostEqual(...)score in the Netflix golden Python tests.Deep-dive deliverables (ADR-0108)
AGENTS.mdinvariant note — no rebase-sensitive invariants: fork-local SYCL feature extractorchangelog.d/fixed/sycl-motion2-checkerboard-drift.mddocs/rebase-notes.mdentryReproducer
🤖 Generated with Claude Code