|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.lucene.facet.search.sampling.SamplingParams
public class SamplingParams
Parameters for sampling, dictating whether sampling is to take place and how.
Field Summary | |
---|---|
static int |
DEFAULT_MAX_SAMPLE_SIZE
Default maximum size of sample. |
static int |
DEFAULT_MIN_SAMPLE_SIZE
Default minimum size of sample. |
static double |
DEFAULT_OVERSAMPLE_FACTOR
Default factor by which more results are requested over the sample set. |
static double |
DEFAULT_SAMPLE_RATIO
Default ratio between size of sample to original size of document set. |
static int |
DEFAULT_SAMPLING_THRESHOLD
Default sampling threshold, if number of results is less than this number - no sampling will take place |
Constructor Summary | |
---|---|
SamplingParams()
|
Method Summary | |
---|---|
int |
getMaxSampleSize()
Return the maxSampleSize. |
int |
getMinSampleSize()
Return the minSampleSize. |
double |
getOversampleFactor()
Return the oversampleFactor. |
double |
getSampleRatio()
|
int |
getSamplingThreshold()
Return the samplingThreshold. |
void |
setMaxSampleSize(int maxSampleSize)
|
void |
setMinSampleSize(int minSampleSize)
|
void |
setOversampleFactor(double oversampleFactor)
|
void |
setSampingThreshold(int sampingThreshold)
Set a sampling-threshold |
void |
setSampleRatio(double sampleRatio)
|
boolean |
validate()
Check validity of sampling settings, making sure that minSampleSize <= maxSampleSize <= samplingThreshold
0 < samplingRatio <= 1
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final double DEFAULT_OVERSAMPLE_FACTOR
getOversampleFactor()
,
Constant Field Valuespublic static final double DEFAULT_SAMPLE_RATIO
Sampler.getSampleSet(org.apache.lucene.facet.search.ScoredDocIDs)
,
Constant Field Valuespublic static final int DEFAULT_MAX_SAMPLE_SIZE
Sampler.getSampleSet(org.apache.lucene.facet.search.ScoredDocIDs)
,
Constant Field Valuespublic static final int DEFAULT_MIN_SAMPLE_SIZE
Sampler.getSampleSet(org.apache.lucene.facet.search.ScoredDocIDs)
,
Constant Field Valuespublic static final int DEFAULT_SAMPLING_THRESHOLD
getSampleRatio()
,
Constant Field ValuesConstructor Detail |
---|
public SamplingParams()
Method Detail |
---|
public final int getMaxSampleSize()
Sampler.getSampleSet(org.apache.lucene.facet.search.ScoredDocIDs)
public final int getMinSampleSize()
Sampler.getSampleSet(org.apache.lucene.facet.search.ScoredDocIDs)
public final double getSampleRatio()
Sampler.getSampleSet(org.apache.lucene.facet.search.ScoredDocIDs)
public final int getSamplingThreshold()
public void setMaxSampleSize(int maxSampleSize)
maxSampleSize
- the maxSampleSize to setgetMaxSampleSize()
public void setMinSampleSize(int minSampleSize)
minSampleSize
- the minSampleSize to setgetMinSampleSize()
public void setSampleRatio(double sampleRatio)
sampleRatio
- the sampleRatio to setgetSampleRatio()
public void setSampingThreshold(int sampingThreshold)
getSamplingThreshold()
public boolean validate()
minSampleSize <= maxSampleSize <= samplingThreshold
0 < samplingRatio <= 1
public final double getOversampleFactor()
TakmiSampleFixer
. When this value is smaller than 1, it is
ignored and no oversampling takes place.
public void setOversampleFactor(double oversampleFactor)
oversampleFactor
- the oversampleFactor to setgetOversampleFactor()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |