This is going to change with ngram_* in sphinxbase, but still.
Models are incompatible with sphinx4. The reason is that wid is equal to -1 for every unigram in the model. Previously it was increasing from zero to the dictionary size. I see it's assigning correct wid in ReadUnigrams, but later resets it:
/* E_INFO("lm->dict %d\n",lm->dict_size); */ for (u = 0; u < lm->n_ug; u++) lm->ug[u].dictwid = BAD_S3WID;
It's supposed to be restored later with wid_dict_lm_map but it's not the lm_convert case.
Log in to post a comment.