-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(ballot-interpreter): improve vertical streak detection (#5522)
* fix(ballot-interpreter): exclude more ballot edges When scanning in VxCentralScan sometimes we get wider gray areas outside the ballot paper than we expected. Most of this gray is binarized to black, leading to false positives when detecting streaks. This reduces the likelihood of false positives while preserving detection of streaks within the ballot, including within the timing marks. * feat(ballot-interpreter): improve vertical streak debug images Binarizes the debug image to make it clearer what the streak detector was working with. * test(ballot-interpreter): fix comment ⟷ code mismatch The comment says to draw on side B, so I updated the code to do that. * test(ballot-interpreter): add more streak detection tests Ensures that streaks through timing marks are still detected and semi-wide edge "streaks" do not cause false positives.
- Loading branch information
1 parent
c4abe53
commit 0171ffa
Showing
5 changed files
with
98 additions
and
31 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Binary file added
BIN
+789 KB
libs/ballot-interpreter/test/fixtures/nh-test-ballot/grayscale-back.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+1020 KB
libs/ballot-interpreter/test/fixtures/nh-test-ballot/grayscale-front.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.