|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.fu_berlin.ties.extract.reestimate.Reestimator
de.fu_berlin.ties.extract.reestimate.LengthFilter
public class LengthFilter
A very simple re-estimator that discards any extractions that are longer than the longest extraction of the same type seen in the training corpus, multipied with a tolerance factor.
Field Summary | |
---|---|
static int |
DEFAULT_LENGTH
The default length used for unknown types: 3. |
Fields inherited from class de.fu_berlin.ties.extract.reestimate.Reestimator |
---|
CONFIG_REESTIMATORS |
Constructor Summary | |
---|---|
LengthFilter(Reestimator precReestimator,
TiesConfiguration config)
Creates a new instance. |
Method Summary | |
---|---|
protected Extraction |
doReestimate(Extraction extraction)
Re-estimates the probability of an extraction. |
protected void |
doTrain(Extraction extraction)
Trains this re-estimator on an extraction. |
int |
toleratedLength(String type)
Returns the maximum length tolerated for extractions of a given type. |
String |
toString()
Returns a string representation of this object. |
Methods inherited from class de.fu_berlin.ties.extract.reestimate.Reestimator |
---|
createReestimators, createReestimators, getPrecedingReestimator, reestimate, train, trainOtherToken |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int DEFAULT_LENGTH
Constructor Detail |
---|
public LengthFilter(Reestimator precReestimator, TiesConfiguration config)
precReestimator
- the preceding re-estimator to use if this
re-estimator is part of a chain; null
otherwiseconfig
- the configuration to useMethod Detail |
---|
public int toleratedLength(String type)
type
- the extraction type
protected Extraction doReestimate(Extraction extraction)
doReestimate
in class Reestimator
extraction
- the extraction to re-estimate
null
if the
extraction should be deletedprotected void doTrain(Extraction extraction)
doTrain
in class Reestimator
extraction
- the extraction to trainpublic String toString()
toString
in class Reestimator
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |