|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcalhoun.analysis.crf.io.InterleavedInputComponentBase
calhoun.analysis.crf.io.IntInput
public class IntInput
reads in an input consisting of a list of ints that correspond to binary values. Can be used as a standalone input component or part of an interleaved input.
| Constructor Summary | |
|---|---|
IntInput()
|
|
| Method Summary | |
|---|---|
static java.util.List<? extends TrainingSequence<?>> |
prepareData(java.lang.String str)
Convenience function for creating training sequences in test data. |
boolean |
read(java.io.BufferedReader r,
java.util.Map<java.lang.String,InputSequence<?>> output)
Read the contents of the sequence in from a reader. |
int[] |
readSequence(java.io.BufferedReader r)
|
void |
readTrainingSequences(java.lang.Object location,
java.util.List<TrainingSequence<java.util.Map<java.lang.String,java.lang.Object>>> seqs)
reads training sequences from the specified location. |
void |
write(java.io.Writer w,
java.util.Map<java.lang.String,? extends InputSequence<?>> data)
Output this sequence to the given writer. |
void |
writeSequence(java.io.Writer w,
int[] data)
|
void |
writeTrainingSequences(java.lang.Object location,
java.util.Iterator<int[]> data)
writes training sequences to the specified location. |
| Methods inherited from class calhoun.analysis.crf.io.InterleavedInputComponentBase |
|---|
getComponentNames, getName, readInputSequences, setName, writeInputSequences |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IntInput()
| Method Detail |
|---|
public boolean read(java.io.BufferedReader r,
java.util.Map<java.lang.String,InputSequence<?>> output)
throws java.io.IOException
InterleavedInputComponent
read in interface InterleavedInputComponentr - the buffered reader from which the next sequence should be read.output - a map to which new components for this input sequence should be added.
java.io.IOException
public int[] readSequence(java.io.BufferedReader r)
throws java.io.IOException
java.io.IOException
public void write(java.io.Writer w,
java.util.Map<java.lang.String,? extends InputSequence<?>> data)
throws java.io.IOException
InterleavedInputComponent
write in interface InterleavedInputComponentw - a writer to which this sequence should be writtendata - a map containing the data for the sequence to be written
java.io.IOException
public void writeSequence(java.io.Writer w,
int[] data)
throws java.io.IOException
java.io.IOException
public void readTrainingSequences(java.lang.Object location,
java.util.List<TrainingSequence<java.util.Map<java.lang.String,java.lang.Object>>> seqs)
throws java.io.IOException
TrainingSequenceIO
readTrainingSequences in interface TrainingSequenceIOlocation - location of the training sequences. Meaning is implementation dependent.seqs - a list of the input sequences to which hidden sequences should be added. Each hidden sequence is an array of integers containing hidden state indices.
java.io.IOException
public void writeTrainingSequences(java.lang.Object location,
java.util.Iterator<int[]> data)
throws java.io.IOException
TrainingSequenceIO
writeTrainingSequences in interface TrainingSequenceIOlocation - location of the training sequences. Meaning is implementation dependent.data - iterator over the hidden states to write.
java.io.IOException
public static java.util.List<? extends TrainingSequence<?>> prepareData(java.lang.String str)
throws java.lang.Exception
java.lang.Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||