diff --git a/.claude/settings.local.json b/.claude/settings.local.json index e522f8f..f88d38e 100644 --- a/.claude/settings.local.json +++ b/.claude/settings.local.json @@ -49,7 +49,8 @@ "Read(//c/Users/nghia/Downloads/**)", "Bash(awk '{print \"OCR_Leak: \"$1}')", "Bash(awk 'NR==1 || NR%20==0 || NR==157 { *)", - "Bash(xargs file *)" + "Bash(xargs file *)", + "Bash(xargs grep *)" ] } } diff --git a/modules/ANSLPR/ANSLPR_OD.h b/modules/ANSLPR/ANSLPR_OD.h index 5694cec..825dc3e 100644 --- a/modules/ANSLPR/ANSLPR_OD.h +++ b/modules/ANSLPR/ANSLPR_OD.h @@ -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}; diff --git a/tests/ANSLPR-UnitTest/ANSLPR-UnitTest.cpp b/tests/ANSLPR-UnitTest/ANSLPR-UnitTest.cpp index ee3ef13..7d40447 100644 --- a/tests/ANSLPR-UnitTest/ANSLPR-UnitTest.cpp +++ b/tests/ANSLPR-UnitTest/ANSLPR-UnitTest.cpp @@ -570,7 +570,7 @@ int ANSLPR_OD_FolderInferences_Test() { ANSCENTER::ANSALPR* infHandle = nullptr; std::string licenseKey = ""; std::string modelZipFile = "C:\\ProgramData\\ANSCENTER\\ANSVIS Server\\ANSALPR\\ServerOptimised\\ANS_ALPR_v1.2_NVIDIAGeForceRTX4070LaptopGPU.zip"; - std::string folderPath = "E:\\Programs\\DemoAssets\\ImageSeries\\ALPR character M\\EventDebug_20260419_150533.690"; + std::string folderPath = "E:\\Programs\\DemoAssets\\ImageSeries\\ALPR character M\\EventDebug_20260419_151653.296"; int engineType = 1; double detectionThreshold = 0.3;