Use tracker and voting system to correct ALPR

This commit is contained in:
2026-04-22 11:19:42 +10:00
parent f7f356c044
commit 24d6d2e0a5
3 changed files with 8 additions and 4 deletions

View File

@@ -167,8 +167,11 @@ namespace ANSCENTER
// Master switch for tracker + voting post-processing inside
// RunInference / RunInferenceSingleFrame. When false, these methods
// return raw per-frame OCR output (no alprChecker.checkPlateByTrackId
// voting, no spatial ensureUniquePlateText dedup). Default: disabled.
bool _enableTrackerVoting{ false };
// voting, no spatial ensureUniquePlateText dedup). Default: enabled,
// so full-frame callers get temporal consensus out of the box. Pipeline
// crop callers still bypass voting automatically via the width gate in
// shouldUseALPRChecker. Opt out explicitly with SetTrackerVotingEnabled(false).
bool _enableTrackerVoting{ true };
struct ImageSizeTracker {
cv::Size lastSize{0, 0};