public class SequenceLabelerTrainer extends Object
| Constructor and Description |
|---|
SequenceLabelerTrainer(opennlp.tools.util.TrainingParameters params)
Construct a trainer with training and test data, and with options for
language, beamsize for decoding, sequence codec and corpus format (conll or
opennlp).
|
| Modifier and Type | Method and Description |
|---|---|
void |
createSequenceLabelerFactory(opennlp.tools.util.TrainingParameters params)
Create
SequenceLabelerFactory with custom features. |
String |
getSequenceCodec()
Get the Sequence codec.
|
SequenceLabelerFactory |
getSequenceLabelerFactory()
Get the features which are implemented in each of the trainers extending
this class.
|
static opennlp.tools.util.ObjectStream<SequenceLabelSample> |
getSequenceStream(String inputData,
String clearFeatures,
String aCorpusFormat)
Getting the stream with the right corpus format.
|
void |
setSequenceCodec(String aSeqCodec)
Set the sequence codec.
|
SequenceLabelerFactory |
setSequenceLabelerFactory(SequenceLabelerFactory tokenNameFinderFactory) |
SequenceLabelerModel |
train(opennlp.tools.util.TrainingParameters params) |
public SequenceLabelerTrainer(opennlp.tools.util.TrainingParameters params)
throws IOException
params - the training parametersIOException - io exceptionpublic void createSequenceLabelerFactory(opennlp.tools.util.TrainingParameters params)
throws IOException
SequenceLabelerFactory with custom features.params - the parameter training fileIOException - if io errorpublic final SequenceLabelerModel train(opennlp.tools.util.TrainingParameters params)
public static opennlp.tools.util.ObjectStream<SequenceLabelSample> getSequenceStream(String inputData, String clearFeatures, String aCorpusFormat) throws IOException
inputData - the input dataclearFeatures - clear the featuresaCorpusFormat - the corpus formatIOException - the io exceptionpublic final SequenceLabelerFactory getSequenceLabelerFactory()
public final SequenceLabelerFactory setSequenceLabelerFactory(SequenceLabelerFactory tokenNameFinderFactory)
public final String getSequenceCodec()
public final void setSequenceCodec(String aSeqCodec)
aSeqCodec - the sequence codec to be setCopyright © 2017 IXA pipes. All rights reserved.