Package org.apache.solr.search
Class ReRankScaler
- java.lang.Object
-
- org.apache.solr.search.ReRankScaler
-
public class ReRankScaler extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classReRankScaler.MinMaxExplainstatic classReRankScaler.ReRankScalerExplain
-
Field Summary
Fields Modifier and Type Field Description protected booleandebugQueryprotected intmainQueryMaxprotected intmainQueryMinprotected ReRankOperatorreRankOperatorprotected intreRankQueryMaxprotected intreRankQueryMinprotected ReRankScaler.ReRankScalerExplainreRankScalerExplain
-
Constructor Summary
Constructors Constructor Description ReRankScaler(String mainScale, String reRankScale, double reRankScaleWeight, ReRankOperator reRankOperator, org.apache.lucene.search.QueryRescorer replaceRescorer, boolean debugQuery)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static floatcombineScores(float orginalScore, float reRankScore, double reRankScaleWeight, ReRankOperator reRankOperator)booleanequals(Object o)org.apache.lucene.search.Explanationexplain(int doc, org.apache.lucene.search.Explanation mainQueryExplain, org.apache.lucene.search.Explanation reRankQueryExplain)intgetMainQueryMax()intgetMainQueryMin()static ReRankScaler.MinMaxExplaingetMinMaxExplain(float scaleMin, float scaleMax, Map<Integer,Float> docScoreMap)org.apache.lucene.search.QueryRescorergetReplaceRescorer()intgetReRankQueryMax()intgetReRankQueryMin()ReRankScaler.ReRankScalerExplaingetReRankScalerExplain()doublegetReRankScaleWeight()inthashCode()static Map<Integer,Float>minMaxScaleScores(Map<Integer,Float> docScoreMap, ReRankScaler.MinMaxExplain explain)booleanscaleMainScores()booleanscaleReRankScores()booleanscaleScores()org.apache.lucene.search.ScoreDoc[]scaleScores(org.apache.lucene.search.ScoreDoc[] originalDocs, org.apache.lucene.search.ScoreDoc[] rescoredDocs, int howMany)
-
-
-
Field Detail
-
mainQueryMin
protected int mainQueryMin
-
mainQueryMax
protected int mainQueryMax
-
reRankQueryMin
protected int reRankQueryMin
-
reRankQueryMax
protected int reRankQueryMax
-
debugQuery
protected boolean debugQuery
-
reRankOperator
protected ReRankOperator reRankOperator
-
reRankScalerExplain
protected ReRankScaler.ReRankScalerExplain reRankScalerExplain
-
-
Constructor Detail
-
ReRankScaler
public ReRankScaler(String mainScale, String reRankScale, double reRankScaleWeight, ReRankOperator reRankOperator, org.apache.lucene.search.QueryRescorer replaceRescorer, boolean debugQuery) throws SyntaxError
- Throws:
SyntaxError
-
-
Method Detail
-
getReplaceRescorer
public org.apache.lucene.search.QueryRescorer getReplaceRescorer()
-
getMainQueryMin
public int getMainQueryMin()
-
getMainQueryMax
public int getMainQueryMax()
-
getReRankQueryMin
public int getReRankQueryMin()
-
getReRankQueryMax
public int getReRankQueryMax()
-
getReRankScalerExplain
public ReRankScaler.ReRankScalerExplain getReRankScalerExplain()
-
getReRankScaleWeight
public double getReRankScaleWeight()
-
scaleScores
public boolean scaleScores()
-
scaleMainScores
public boolean scaleMainScores()
-
scaleReRankScores
public boolean scaleReRankScores()
-
scaleScores
public org.apache.lucene.search.ScoreDoc[] scaleScores(org.apache.lucene.search.ScoreDoc[] originalDocs, org.apache.lucene.search.ScoreDoc[] rescoredDocs, int howMany)
-
combineScores
public static float combineScores(float orginalScore, float reRankScore, double reRankScaleWeight, ReRankOperator reRankOperator)
-
explain
public org.apache.lucene.search.Explanation explain(int doc, org.apache.lucene.search.Explanation mainQueryExplain, org.apache.lucene.search.Explanation reRankQueryExplain)
-
getMinMaxExplain
public static ReRankScaler.MinMaxExplain getMinMaxExplain(float scaleMin, float scaleMax, Map<Integer,Float> docScoreMap)
-
-