Repository navigation
feat(ocr): read the completion card with layout 1280x720-v10 - #50
Merged
Merged
Conversation
Adds the settlement_card ROI and parser for the new Bastion HUD: clear time, deaths, skips, map, difficulty, version, run code and earned titles. The stock recognition model reads the card crop at 0.999 confidence, so no model change is made. The 16:10 layout is unchanged until a sample exists.
The new HUD no longer prints the in-game name above the server load, so real_player falls back to the card's player line.
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.
Why
The new Bastion HUD (release 26.1030.1) moves clear time, run code, map, difficulty, version, deaths, skips and earned titles onto a 20-second card at the top centre, and hides the right column during it. Measured on development-build screenshots: the in-game HUD still reads, but no ROI covered the card, so completion evidence came back empty. The stock RapidOCR model reads the card crop at 0.999 confidence, so this change adds no model training.
Change
1280x720-v10adds thesettlement_cardROI (16:9 only).1280x800-v4is unchanged: there is no 16:10 sample yet, and its card fields staymissing.settlement_card.py: clear time (HH:MM:SS), player, deaths, skips, map and classic variant, difficulty, version, earned titles. An empty—title line gives no titles.通关代码label.real_playerfalls back to the card's player line.resolve_mapis now public inright_panel.pyso the card reuses the map matching.settlement-cardfixture set andsettlement-card-v1producer revision (its minimum game version is recorded when the HUD is released).Dependencies
feat/settlement-card-fixturemerged first, then thedatasetsgitlink bumped here.Verification
pytest: 433 passed. Layout manifest--checkand Rust tests pass.compatibility_gate.py: ok. Thesettlement-cardset matches all 9 critical fields, includingreal_player.Not covered
00:00:00, soduration_secondsis proven only for zero. A non-zero real card is needed.real_playercomes from the card'slocalPlayer, which may be a streamer-mode name. It is evidence only.