Package org.aksw.palmetto.vector
Class DirectConfirmationBasedVectorCreator
- java.lang.Object
-
- org.aksw.palmetto.vector.AbstractVectorCreator
-
- org.aksw.palmetto.vector.DirectConfirmationBasedVectorCreator
-
- All Implemented Interfaces:
VectorCreator
public class DirectConfirmationBasedVectorCreator extends AbstractVectorCreator
This vector creator uses a direct confirmation measure to create the vectors.- Author:
- m.roeder
-
-
Field Summary
Fields Modifier and Type Field Description private DirectConfirmationMeasurecalculationprivate doublegammaprivate OneOneAndSelfoneOneAndSelfCreator
-
Constructor Summary
Constructors Constructor Description DirectConfirmationBasedVectorCreator(ProbabilityEstimator supplier, DirectConfirmationMeasure calculation, double gamma)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SubsetVectorscreateVectors(int wordsetLength, SegmentationDefinition definition, SubsetProbabilities oneOneAndSelfProbabilities, SubsetProbabilities probabilities)Creates the vectors for a single wordset.SubsetVectors[]createVectors(String[][] wordsets, SegmentationDefinition[] definitions, SubsetProbabilities[] probabilities)doublegetGamma()StringgetVectorCreatorName()Returns the name of the direct confirmation measure which is used to create the vectors.voidsetGamma(double gamma)-
Methods inherited from class org.aksw.palmetto.vector.AbstractVectorCreator
getProbabilityEstimatorName, getVectors, getVectorSpaceName, setMinFrequency, setProbabilityEstimator
-
-
-
-
Field Detail
-
calculation
private DirectConfirmationMeasure calculation
-
oneOneAndSelfCreator
private OneOneAndSelf oneOneAndSelfCreator
-
gamma
private double gamma
-
-
Constructor Detail
-
DirectConfirmationBasedVectorCreator
public DirectConfirmationBasedVectorCreator(ProbabilityEstimator supplier, DirectConfirmationMeasure calculation, double gamma)
-
-
Method Detail
-
getVectorCreatorName
public String getVectorCreatorName()
Description copied from interface:VectorCreatorReturns the name of the direct confirmation measure which is used to create the vectors.- Returns:
-
createVectors
public SubsetVectors[] createVectors(String[][] wordsets, SegmentationDefinition[] definitions, SubsetProbabilities[] probabilities)
- Specified by:
createVectorsin classAbstractVectorCreator
-
createVectors
public SubsetVectors createVectors(int wordsetLength, SegmentationDefinition definition, SubsetProbabilities oneOneAndSelfProbabilities, SubsetProbabilities probabilities)
Creates the vectors for a single wordset.- Parameters:
wordsetLength- the length of the wordsetdefinition- the definition of the segmentations that will be copied into the created subset vector definitiononeOneAndSelfProbabilities- this probabilities instance should contain the segmentation of theOneOneAndSelfclass for the given word set. Note that although it is a probabilities instance probabilities instance, its probabilities will be internally overridden with the next probabilities parameter. Note this parameter is mainly used to reuse the generated OneOneAndSelf segmentation for a given set of wordsets.probabilities- the probabilities for the given word set.- Returns:
- subset vectors that comprise the vectors for the given wordset length
based on the given probabilities and the direct confirmation measure
of this class (
calculation). The subset vector instance will also contain the given segmentation information as well as the given probabilities.
-
setGamma
public void setGamma(double gamma)
-
getGamma
public double getGamma()
-
-