Training OCR for France

376 views
Skip to first unread message

Lilian Cabé

unread,
Jul 26, 2016, 9:54:52 AM7/26/16
to OpenALPR
Hi, 

I am trying to improve OCR with french plates, because I noticed that there is no "leu.france.exp0.box" file in the train-ocr/eu/input folder. So I guess, when given "fr" as a region, the OCR tries to match with German, Serbian, Dutch or Belgian fonts.

I gathered many plates pictures and i noticed that there is many different fonts for the french license plates. My question is : how different have to be the characters to be considered as part of different fonts ?

For example, i decided to process these two plates as part of two different fonts, because of the difference with the 7 and the 3. All the other characters from the fonts are almost the same. Can i mix them or not ?

Thanks in advance.




Lilian Cabé

unread,
Jul 28, 2016, 4:40:26 AM7/28/16
to OpenALPR
I finally separated the two fonts showed previously. 
I did a complete training for the font from the 2nd picture (because it is the most common one in France). It improved my results with french plate.
Here are the leu.france.box and .tif file i made.
leu.france.exp0.box
leu.france.exp0.tif

Matt

unread,
Jul 28, 2016, 7:55:51 AM7/28/16
to OpenALPR
Very cool!  If you upload the original character tiles and (optionally) the two tif/box files, I can add a new "france" country to OpenALPR and keep it maintained.  I like to have the original char tiles in case the training workflow changes and we need to regenerate the training data.

Michael Halbout

unread,
Jul 29, 2016, 4:09:55 AM7/29/16
to OpenALPR
Thank you for this.
I update my domotic app with this elements

Lilian Cabé

unread,
Jul 29, 2016, 5:48:43 AM7/29/16
to OpenALPR

Here is the folder with all the tiles.

I had some issue with the font when i first tried it (very poor recognition), I had to change the tiles height and width when using the openalpr-utils-prepcharsfortraining. The characters are considered as lower case in the tile names. I revised the leu.france.exp0.box file to make the characters upper case (I don't know if it is really matters or not but i did it anyway)


I am currently training another french font, and i'll maybe try to improve this one. (I still have some bad results with 6/8 and M/H/W, so maybe i need more tiles)
I'll try to share all my work ! :)
output.zip

Lilian Cabé

unread,
Aug 5, 2016, 7:09:46 AM8/5/16
to OpenALPR
Hi,

I improved my french training, by removing some wrong tiles (from different fonts) and adding new ones.
Here is the last version for the french OCR. 
leu.france.exp0.box
leu.france.exp0.tif
leu.traineddata

Lilian Cabé

unread,
Aug 5, 2016, 7:13:18 AM8/5/16
to OpenALPR
I forgot the tile's folder.. here it is
french_tiles.zip

Matt

unread,
Aug 5, 2016, 9:18:12 AM8/5/16
to OpenALPR
Reply all
Reply to author
Forward
0 new messages