Improved script consistency in numbers

This commit is contained in:
Ray Smith 2014-09-17 18:22:32 -07:00
parent 648e7ca311
commit e46b605469

View File

@ -129,7 +129,9 @@ class LanguageModel {
const LMConsistencyInfo &consistency_info) {
if (dawg_info != NULL) {
return ComputeAdjustment(consistency_info.NumInconsistentCase(),
language_model_penalty_case);
language_model_penalty_case) +
(consistency_info.inconsistent_script ?
language_model_penalty_script : 0.0f);
}
return (ComputeAdjustment(consistency_info.NumInconsistentPunc(),
language_model_penalty_punc) +