mirror of
https://github.com/kerberos-io/openalpr-base.git
synced 2025-10-06 11:46:53 +08:00
Skipping OCR processing when num of possible characters is too small
This commit is contained in:
@@ -53,6 +53,10 @@ void OCR::performOCR(vector<Mat> thresholds, vector<Rect> charRegions)
|
||||
|
||||
postProcessor->clear();
|
||||
|
||||
// Don't waste time on OCR processing if it is impossible to get sufficient characters
|
||||
if (charRegions.size() < config->postProcessMinCharacters)
|
||||
return;
|
||||
|
||||
for (int i = 0; i < thresholds.size(); i++)
|
||||
{
|
||||
// Make it black text on white background
|
||||
|
Reference in New Issue
Block a user