public class SegmentIterator extends AbstractPipeInputIterator
parentInstance| Constructor and Description |
|---|
SegmentIterator(InstanceList ilist,
Object[] startTags,
Object[] inTags,
ArrayList predictions)
Useful when no
Transduce is specified. |
SegmentIterator(Instance instance,
Object[] startTags,
Object[] inTags,
Sequence prediction)
Iterate over segments in one instance.
|
SegmentIterator(Sequence input,
Sequence predicted,
Sequence truth,
Object[] startTags,
Object[] inTags)
Iterate over segments in one labeled sequence
|
SegmentIterator(Transducer model,
InstanceList ilist,
Object[] segmentStartTags,
Object[] segmentContinueTags)
NOTE!: Assumes that
segmentStartTags[i] corresponds
to segmentContinueTags[i]. |
SegmentIterator(Transducer model,
Instance instance,
Object[] segmentStartTags,
Object[] segmentContinueTags)
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
hasNext() |
Instance |
nextInstance() |
Segment |
nextSegment() |
ArrayList |
toArrayList() |
next, remove, setParentInstanceclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemainingpublic SegmentIterator(Transducer model, InstanceList ilist, Object[] segmentStartTags, Object[] segmentContinueTags)
segmentStartTags[i] corresponds
to segmentContinueTags[i].model - model to segment input sequencesilist - list of instances to be segmentedsegmentStartTags - array of tags indicating the start of a segmentsegmentContinueTags - array of tags indicating the continuation of a segmentpublic SegmentIterator(Transducer model, Instance instance, Object[] segmentStartTags, Object[] segmentContinueTags)
public SegmentIterator(InstanceList ilist, Object[] startTags, Object[] inTags, ArrayList predictions)
Transduce is specified. A list of
sequences specifies the output.ilist - InstanceList containing sequence.segmentStartTags - array of tags indicating the start of a segmentsegmentContinueTags - array of tags indicating the continuation of a segmentpredictions - list of Sequences that are the
predicted output of some Transducerpublic SegmentIterator(Instance instance, Object[] startTags, Object[] inTags, Sequence prediction)
ilist - InstanceList containing sequence.segmentStartTags - array of tags indicating the start of a segmentsegmentContinueTags - array of tags indicating the continuation of a segmentpredictions - list of Sequences that are the
predicted output of some Transducerpublic Instance nextInstance()
nextInstance in interface PipeInputIteratornextInstance in class AbstractPipeInputIteratorpublic Segment nextSegment()
public boolean hasNext()
hasNext in interface IteratorhasNext in class AbstractPipeInputIteratorpublic ArrayList toArrayList()
Copyright © 2019 JULIE Lab, Germany. All rights reserved.