How to set load_system_dawg
and load_freq_dawg
to false
??
I need to disable the dictionary.. So I guess these are the two parameteres I need to set to false?
tesseract::TessBaseAPI *api = new tesseract::TessBaseAPI();
if(api->Init(NULL, "dan+eng")){
// error
}
api->SetImage(image);
api->Recognize(0);
tesseract 3.05.01
tessdata
directory create a configs
directoryload_system_dawg F load_freq_dawg F
Modify your code
auto numOfConfigs = 1;
auto **configs = new char *[numOfConfigs];
configs[i] = (char *) "name of your config file";
tesseract::TessBaseAPI *api = new tesseract::TessBaseAPI();
if(api->Init(NULL, "dan+eng", tesseract::OEM_DEFAULT, configs, numOfConfigs, nullptr, nullptr, false)){
// error
}
P.S. It is also possible to do with last couple of arguments of Init function, feel free to try them out yourself.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With