mirror of
https://github.com/kerberos-io/openalpr-base.git
synced 2025-10-06 23:22:51 +08:00
Moved prewarp initialization higher, initializing detector with prewarp
This commit is contained in:
@@ -45,6 +45,8 @@ namespace alpr
|
||||
return;
|
||||
}
|
||||
|
||||
prewarp = new PreWarp(config);
|
||||
|
||||
loadRecognizers();
|
||||
|
||||
setNumThreads(0);
|
||||
@@ -53,8 +55,6 @@ namespace alpr
|
||||
this->topN = DEFAULT_TOPN;
|
||||
setDefaultRegion("");
|
||||
|
||||
prewarp = new PreWarp(config);
|
||||
|
||||
timespec endTime;
|
||||
getTimeMonotonic(&endTime);
|
||||
if (config->debugTiming)
|
||||
@@ -716,7 +716,7 @@ namespace alpr
|
||||
{
|
||||
// Country training data has not already been loaded. Load it.
|
||||
AlprRecognizers recognizer;
|
||||
recognizer.plateDetector = createDetector(config);
|
||||
recognizer.plateDetector = createDetector(config, prewarp);
|
||||
recognizer.ocr = new OCR(config);
|
||||
|
||||
#ifndef SKIP_STATE_DETECTION
|
||||
|
Reference in New Issue
Block a user