faustomorales / keras-ocr

A packaged and flexible version of the CRAFT text detector and Keras CRNN recognition model.
https://keras-ocr.readthedocs.io/
MIT License
1.37k stars 349 forks source link

Threshold boundaries? np.max(textmap[labels == component_id]) can return values greater than 1? #196

Open AIMLAPP opened 2 years ago

AIMLAPP commented 2 years ago

Hi,

I'd like to ask what the detection threshold boundaries are (min and max)? I assumed it was bounded between 0 and 1, but I've had cases where np.max(textmap[labels == component_id]) is greater than 1, and probabilities/confidence scores shouldn't exceed 1!

What do the values in textmap represent, since my initial assumption that the values are probabilities/confidence scores seems to be wrong.

Note: In the original CRAFT implementation, this greater than 1 occurence was also observed when I tested it.

Thank you very much for your attention.