OpenCV Tesseract API Parameters (SetVariable)

I’m using the OCRTesseract Api from OpenCV (strictly speaking OpenCVSharp).

I’m having the problem that in the font I’m trying to recognize, l and I look practically the same. Even though I baked a Dictionary into my fine tuned .traineddata. I still get CeII instead of Cell.

I’d like to play with parameters like segment_penalty_dict_nonword but the OpenCV Tesseract abstraction does not seem to offer that. Is that really true? I can’t quite believe that there is no possibility to set these params via the OpenCV Api.

Thanks!!

Okay I guess it really does not exist.

Found this

Looks like there’s no way to set vars in runtime. The only solution I found - incorporating config file with all required vars into traineddata file.

Wild choice to not implement that :frowning:

you could use the tesseract library directly.

that being in opencv at all is probably because someone contributed it as a GSoC that one time, and nobody cares enough about it to maintain it.