write_tadm_file(train_toks,
encoding,
stream)
| source code
|
Generate an input file for tadm based on the given corpus
of classified tokens.
- Parameters:
train_toks (list of tuples of (dict,
str)) - Training data, represented as a list of pairs, the first member
of which is a feature dictionary, and the second of which is a
classification label.
encoding (TadmEventMaxentFeatureEncoding) - A feature encoding, used to convert featuresets into feature
vectors.
stream (stream) - The stream to which the tadm input file should be
written.
|