#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <float.h>
#include "segCommon.h"
#include "segStdLib.h"
#include "segModel.h"
Functions | |
int | segMakeStrictLRTopology (SEG_MODEL_SET *modelset) |
Force models to maintain strict left-to-right topology. | |
int | segCheckModelSet (SEG_MODEL_SET *modelset) |
Check the consistency of model parameter set. | |
SEG_MODEL_SET * | segReadModelSet (char *modelList, char *tiedList, int maxDur) |
Read a set of multi-level segmental-HMMs in the file of model name list. | |
int | segWriteModelSet (SEG_MODEL_SET *modelset, FILE *fp) |
Write a set of models to a file. | |
int | segWriteDump (SEG_MODEL_SET *modelset, char *fName) |
Write dump file contents. |
int segCheckModelSet | ( | SEG_MODEL_SET * | modelset | ) |
Check the consistency of model parameter set.
This function checks if a given model parameter set is consistent in terms of the dimensionality of vectors and matrices.
[in] | modelset | Pointer to the model-set structure variable |
NO_ERROR | Successful execution | |
RTN_ERROR | Inconsistency found in the set |
int segMakeStrictLRTopology | ( | SEG_MODEL_SET * | modelset | ) |
Force models to maintain strict left-to-right topology.
[in,out] | modelset | Pointer to the model-set structure variable |
NO_ERROR | Successful execution |
SEG_MODEL_SET* segReadModelSet | ( | char * | modelList, | |
char * | tiedList, | |||
int | maxDur | |||
) |
Read a set of multi-level segmental-HMMs in the file of model name list.
[in] | modelList | Name of file containing model file name list |
[in] | tiedList | Name of file containing tied-phone list |
[in] | maxDur | Maximal segment-duration |
NULL | Memory allocation/File read error | |
otherwise | Pointer to a read model set |
int segWriteDump | ( | SEG_MODEL_SET * | modelset, | |
char * | fName | |||
) |
Write dump file contents.
This function creates a dump file, which includes the label name, maximum segment-duration, the number of states, and duration count and skip count results, for debugging purpose.
[in] | modelset | Pointer to the model-set structure variable |
[in] | fName | Name of dump file |
RTN_ERROR | File open error | |
NO_ERROR | Successful execution |
int segWriteModelSet | ( | SEG_MODEL_SET * | modelset, | |
FILE * | fp | |||
) |
Write a set of models to a file.
[in] | modelset | Pointer to the model-set structure variable |
[in] | fp | File pointer |
RTN_ERROR | Memory allocation error / File write error | |
NO_ERROR | Successful execution |