Added multiline context for postprocessing

Pattern matching can now apply line by line patterns for greater accuracy
This commit is contained in:
Matt Hill
2015-09-25 20:38:47 -04:00
parent af6dcdb587
commit 9ce8cf7d3c
7 changed files with 104 additions and 62 deletions

View File

@@ -347,9 +347,11 @@ namespace alpr
for (unsigned int c_idx = 0; c_idx < ppResults[pp].letter_details.size(); c_idx++)
{
AlprChar character_details;
character_details.character = ppResults[pp].letter_details[c_idx].letter;
character_details.confidence = ppResults[pp].letter_details[c_idx].totalscore;
cv::Rect char_rect = pipeline_data.charRegions[ppResults[pp].letter_details[c_idx].charposition];
Letter l = ppResults[pp].letter_details[c_idx];
character_details.character = l.letter;
character_details.confidence = l.totalscore;
cv::Rect char_rect = pipeline_data.charRegionsFlat[l.charposition];
std::vector<AlprCoordinate> charpoints = getCharacterPoints(char_rect, charTransformMatrix );
for (int cpt = 0; cpt < 4; cpt++)
character_details.corners[cpt] = charpoints[cpt];