且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

在Tesseract中禁用字典

更新时间:2023-09-13 23:43:22

尝试将这些变量设置为false:

Try to set these variables (put them in a config file) to false:

load_system_dawg 
load_freq_dawg
load_punc_dawg
load_number_dawg
load_unambig_dawg
load_bigram_dawg
load_fixed_length_dawgs

https://groups.google.com/forum/?fromgroups=#!searchin/tesseract-ocr/Disable$20dictionary$20​​in$20Tesseract/tesseract- ocr / 5nvIo1DJxHE / f3gBi2pTKykJ

另请参阅如何增加对字典的信任/力量?在常见问题。从中:

Also read How to increase the trust in/strength of the dictionary? in the FAQ. From it:


对于tesseract-ocr< 3.01尝试将dict / permute.cpp中的NON_WERD和GARBAGE_STRING设置为3或甚至5。

For tesseract-ocr < 3.01 try upping NON_WERD and GARBAGE_STRING in dict/permute.cpp to maybe 3 or even 5.

对于tesseract-ocr> = 3.01,尝试增加变量 language_model_penalty_non_freq_dict_word language_model_penalty_non_dict_word 。默认情况下,它们分别为0.1和0.15。

For tesseract-ocr >= 3.01 try increasing the variables language_model_penalty_non_freq_dict_word and language_model_penalty_non_dict_word in a config file. By default they are 0.1 and 0.15 respectively.