void blkarray_list_free(blkarray_list_t *bl) { blkarray_list_reset(bl); ckd_free(bl->ptr); ckd_free(bl); }
void fsg_history_set_fsg (fsg_history_t *h, word_fsg_t *fsg) { if (blkarray_list_n_valid(h->entries) != 0) { E_WARN("Switching FSG while history not empty; history cleared\n"); blkarray_list_reset (h->entries); } if (h->frame_entries) ckd_free_2d ((void **) h->frame_entries); h->frame_entries = NULL; h->fsg = fsg; if (fsg) { h->frame_entries = (glist_t **) ckd_calloc_2d (word_fsg_n_state(fsg), phoneCiCount(), sizeof(glist_t)); } }
void fsg_history_set_fsg(fsg_history_t *h, fsg_model_t *fsg, dict_t *dict) { if (blkarray_list_n_valid(h->entries) != 0) { E_WARN("Switching FSG while history not empty; history cleared\n"); blkarray_list_reset(h->entries); } if (h->frame_entries) ckd_free_2d((void **) h->frame_entries); h->frame_entries = NULL; h->fsg = fsg; if (fsg && dict) { h->n_ciphone = bin_mdef_n_ciphone(dict->mdef); h->frame_entries = (glist_t **) ckd_calloc_2d(fsg_model_n_state(fsg), bin_mdef_n_ciphone(dict->mdef), sizeof(glist_t)); } }
void fsg_history_reset (fsg_history_t *h) { blkarray_list_reset (h->entries); }