cc.mallet.fst.confidence
Class TransducerConfidenceEstimator
java.lang.Object
cc.mallet.fst.confidence.TransducerConfidenceEstimator
- All Implemented Interfaces:
- java.io.Serializable
- Direct Known Subclasses:
- ConstrainedForwardBackwardConfidenceEstimator, GammaAverageConfidenceEstimator, GammaProductConfidenceEstimator, MaxEntConfidenceEstimator, RandomConfidenceEstimator
public abstract class TransducerConfidenceEstimator
- extends java.lang.Object
- implements java.io.Serializable
Abstract class that estimates the confidence of a Segment
extracted by a Transducer
.
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
model
protected Transducer model
TransducerConfidenceEstimator
public TransducerConfidenceEstimator(Transducer model)
estimateConfidenceFor
public double estimateConfidenceFor(Segment segment)
- Calculates the confidence in the tagging of a
Segment
.
estimateConfidenceFor
public abstract double estimateConfidenceFor(Segment segment,
SumLatticeDefault lattice)
getSegmentConfidences
public java.util.Vector getSegmentConfidences()
rankSegmentsByConfidence
public Segment[] rankSegmentsByConfidence(InstanceList ilist,
java.lang.Object[] startTags,
java.lang.Object[] continueTags)
- Ranks all
Segment
s in this InstanceList
by
confidence estimate.
- Parameters:
ilist
- list of segmentation instancesstartTags
- represent the labels for the start states (B-)
of all segmentscontinueTags
- represent the labels for the continue state
(I-) of all segments
- Returns:
- array of
Segment
s ordered by non-decreasing
confidence scores, as calculated by estimateConfidenceFor
rankSegmentsByConfidence
public Segment[] rankSegmentsByConfidence(Instance instance,
java.lang.Object[] startTags,
java.lang.Object[] continueTags)
- ranks the segments in one
Instance
- Parameters:
instance
- instances to be segmentedstartTags
- represent the labels for the start states (e.g. B-)
of all segmentscontinueTags
- represent the labels for the continue state
(e.g. I-) of all segments
- Returns:
- array of
Segment
s ordered by non-decreasing
confidence scores, as calculated by estimateConfidenceFor
getTransducer
public Transducer getTransducer()