ps_sweep: preserve proven color mismatches in exact reports (DRAFT-63) #1318

Merged
fin-github merged 1 commit from upstream-pr/1318 into main 2026-11-29 00:45:54 +00:00
fin-github commented 2026-11-24 21:49:43 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fin-github on 2026-11-24T21:49:43Z.


Claimed in the coordination issue as: DRAFT-63 (https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7145408470)

Supersedes draft #63. Cherry-picked Oleg Makarov's commit from old-pr/9787 onto main with its original authorship.

What and why

ps_sweep compare --exact now keeps the draw classified as a mismatch when complete color readbacks already differ and the depth readback is missing or short. The report still records the depth diagnostic for each draw. The regression also checks that a draw with matching colors and missing depth is still classified as missing.

Tested

Windows 11 (build 26200.9974), Python 3.14.4. Synthetic files only.

  • Before, on upstream/main at 4a50cafc7 with the draft test only, python -I tests/test_ps_sweep.py ran 25 tests with the new regression failing, 21 passing and 3 Vulkan-worker skips. The report counted two missing and one incompatible draw where two mismatches and one missing draw were expected.
  • After the cherry-pick, python -I tests/test_ps_sweep.py had 22 passes and the same 3 skips.
  • python -I tests/test_ab_control_flow.py had 65 passes and 1 skip.
  • python -I scripts/check_no_game_data.py tools/ps_sweep.py tests/test_ps_sweep.py and git diff upstream/main --check exited 0.

GPUs tested: no GPU

AI-assisted (Codex) for takeover and verification. The original draft records OpenCode, Muse Spark 1.3, and GPT-6.2 Sol.

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5480912466 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/1318). Originally posted by [fin-github](https://github.com/fin-github) on 2026-11-24T21:49:43Z. --- Claimed in the coordination issue as: DRAFT-63 (https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7145408470) Supersedes draft #63. Cherry-picked Oleg Makarov's commit from `old-pr/9787` onto `main` with its original authorship. ### What and why `ps_sweep compare --exact` now keeps the draw classified as a mismatch when complete color readbacks already differ and the depth readback is missing or short. The report still records the depth diagnostic for each draw. The regression also checks that a draw with matching colors and missing depth is still classified as missing. ### Tested Windows 11 (build 26200.9974), Python 3.14.4. Synthetic files only. - Before, on `upstream/main` at `4a50cafc7` with the draft test only, `python -I tests/test_ps_sweep.py` ran 25 tests with the new regression failing, 21 passing and 3 Vulkan-worker skips. The report counted two missing and one incompatible draw where two mismatches and one missing draw were expected. - After the cherry-pick, `python -I tests/test_ps_sweep.py` had 22 passes and the same 3 skips. - `python -I tests/test_ab_control_flow.py` had 65 passes and 1 skip. - `python -I scripts/check_no_game_data.py tools/ps_sweep.py tests/test_ps_sweep.py` and `git diff upstream/main --check` exited 0. GPUs tested: no GPU AI-assisted (Codex) for takeover and verification. The original draft records OpenCode, Muse Spark 1.3, and GPT-6.2 Sol.
whoalin1 commented 2026-11-24 23:41:07 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by whoalin1 on 2026-11-24T23:41:07Z.


Verified on Windows host (AI-assisted review), commit d8f36f1d6.

  • python -I tests/test_ps_sweep.py: 25 tests OK, 3 skipped (the PS_SWEEP_TEST_EXE-gated Vulkan worker tests — need game data/hardware, correctly skipped).
  • The new test test_exact_keeps_color_mismatch_with_bad_depth exercises exactly the changed branch: color-mismatch draws with missing and truncated depth files now keep class: mismatch while depth_class still records missing/incompatible.
  • Logic check: exact_pair returns "mismatch" only after full successful readback comparison, so preserving it over unusable depth is correct — a missing depth file cannot un-prove observed color differences. The elif chain still lets depth_class: mismatch downgrade only non-mismatch outcomes.

Verdict: LGTM, fix is correct and well-tested.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7147680080 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/1318#issuecomment-7147680080). Originally posted by [whoalin1](https://github.com/whoalin1) on 2026-11-24T23:41:07Z. --- Verified on Windows host (AI-assisted review), commit d8f36f1d6. - `python -I tests/test_ps_sweep.py`: 25 tests OK, 3 skipped (the PS_SWEEP_TEST_EXE-gated Vulkan worker tests — need game data/hardware, correctly skipped). - The new test `test_exact_keeps_color_mismatch_with_bad_depth` exercises exactly the changed branch: color-mismatch draws with missing and truncated depth files now keep `class: mismatch` while `depth_class` still records `missing`/`incompatible`. - Logic check: `exact_pair` returns "mismatch" only after full successful readback comparison, so preserving it over unusable depth is correct — a missing depth file cannot un-prove observed color differences. The elif chain still lets `depth_class: mismatch` downgrade only non-mismatch outcomes. Verdict: LGTM, fix is correct and well-tested.
zmasi commented 2026-11-28 22:14:16 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by zmasi on 2026-11-28T22:14:16Z.


Native Windows 11 Verification (d8f36f1d62)

Verified d8f36f1d6236dce1e306f972d3cc72d1f32e4c86 merged cleanly onto origin/main (c7753ed98a56677f10e34078b37eab0540e190ec, git merge-tree --write-tree rc=0) on native Windows 11 (26200):

  • Red (origin/main c7753ed98a): python -I tests/test_ps_sweep.py failed (FAILED (failures=1, skipped=3) out of 25 tests — compare_exact overwrote observed pixel color "mismatch" outcomes with "missing" / "incompatible" when depth data was absent or short).
  • Green (origin/main + d8f36f1d62): python -I tests/test_ps_sweep.py passed 25 ran, OK (skipped=3), preserving "mismatch" in class and draws while still recording depth_class separately and classifying matching-color draws with absent depth as "missing".

AI-assisted.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7246592966 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/1318#issuecomment-7246592966). Originally posted by [zmasi](https://github.com/zmasi) on 2026-11-28T22:14:16Z. --- ### Native Windows 11 Verification (`d8f36f1d62`) Verified `d8f36f1d6236dce1e306f972d3cc72d1f32e4c86` merged cleanly onto `origin/main` (`c7753ed98a56677f10e34078b37eab0540e190ec`, `git merge-tree --write-tree` `rc=0`) on native **Windows 11 (`26200`)**: - **Red (`origin/main` `c7753ed98a`)**: `python -I tests/test_ps_sweep.py` failed (`FAILED (failures=1, skipped=3)` out of `25` tests — `compare_exact` overwrote observed pixel color `"mismatch"` outcomes with `"missing"` / `"incompatible"` when depth data was absent or short). - **Green (`origin/main + d8f36f1d62`)**: `python -I tests/test_ps_sweep.py` passed **`25 ran, OK (skipped=3)`**, preserving `"mismatch"` in `class` and `draws` while still recording `depth_class` separately and classifying matching-color draws with absent depth as `"missing"`. AI-assisted.
TheGeogeo commented 2026-11-29 00:17:38 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by TheGeogeo on 2026-11-29T00:17:38Z.


Tested d8f36f1d6 merged (no commit) with main 829530dbd: Python 3.12.4, Windows 11 10.0.26300, CPU only. check_no_game_data.py is clean.

  • Green: tests/test_ps_sweep.py, 25 tests pass (3 skipped).
  • Red: with tools/ps_sweep.py back to main, 1 failure ({'missing': 2, 'incompatible': 1} != {'mismatch': 2, 'missing': 1}).

No blocker from my side.

AI-assisted (Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7248011478 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/1318#issuecomment-7248011478). Originally posted by [TheGeogeo](https://github.com/TheGeogeo) on 2026-11-29T00:17:38Z. --- Tested `d8f36f1d6` merged (no commit) with `main` `829530dbd`: Python 3.12.4, Windows 11 10.0.26300, CPU only. `check_no_game_data.py` is clean. - Green: `tests/test_ps_sweep.py`, 25 tests pass (3 skipped). - Red: with `tools/ps_sweep.py` back to `main`, 1 failure (`{'missing': 2, 'incompatible': 1} != {'mismatch': 2, 'missing': 1}`). No blocker from my side. AI-assisted (Claude Code).
MoonEyes commented 2026-11-29 00:45:57 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-11-29T00:45:57Z.


Merged after TheGeogeo's red/green check (check) (Windows, Python tests, no GPU needed) and a local re-check here. Merged after local re-verification: this PR merged onto main d8b57246c without conflict, and its test file(s) (tests/test_ps_sweep.py) pass there. Earlier today the same tests failed on main without the PR (red/green) and a bundle with other open PRs showed no new failures. check_no_game_data.py is clean. Windows 11, Python 3.14; no GPU needed for these tests.

AI-assisted (Claude Code, Claude Opus 5.5), merged for MoonEyes.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7248335489 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/1318#issuecomment-7248335489). Originally posted by [MoonEyes](https://github.com/MoonEyes) on 2026-11-29T00:45:57Z. --- Merged after **TheGeogeo**'s red/green check ([check](https://github.com/ProjectLeonida/mandy/pull/1318#issuecomment-7248011478)) (Windows, Python tests, no GPU needed) and a local re-check here. Merged after local re-verification: this PR merged onto `main` d8b57246c without conflict, and its test file(s) (`tests/test_ps_sweep.py`) pass there. Earlier today the same tests failed on `main` without the PR (red/green) and a bundle with other open PRs showed no new failures. `check_no_game_data.py` is clean. Windows 11, Python 3.14; no GPU needed for these tests. _AI-assisted (Claude Code, Claude Opus 5.5), merged for MoonEyes._
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
ProjectLeonida/mandy!1318
No description provided.