public abstract class AlgorithmCompareTree extends AlgorithmCompare
Modifier and Type | Field and Description |
---|---|
protected int |
bs
The bucket size for the tree
|
protected KD_Tree |
kdTree
The tree that stores the balanced datasets
|
bestEval, evalMetric
config, mathCompare, valueType
Constructor and Description |
---|
AlgorithmCompareTree()
Create a new instance of AlgorithmCompareTree.
|
AlgorithmCompareTree(java.lang.String thisValueType)
Create a new instance of AlgorithmCompareTree.
|
AlgorithmCompareTree(java.lang.String thisValueType,
java.util.HashMap<java.lang.String,?> thisConfig)
Create a new instance of AlgorithmCompareTree.
|
AlgorithmCompareTree(java.lang.String thisValueType,
java.util.HashMap<java.lang.String,?> thisConfig,
FunctionMetric thisEvalMetric,
EvaluateMathDef mathEval)
Create a new empty instance of AlgorithmCompareTree.
|
Modifier and Type | Method and Description |
---|---|
KD_Tree |
getDatasetTree()
Get the datasets/points that are this algorithm's tree.
|
protected void |
initialise()
Initialise the function values, setting the config parameters or other.
|
void |
resetValues()
Reset the evaluation results for a new test scenario.
|
void |
setDatasetTree(KD_Tree theDatasets)
Set the datasets/points that are this algorithm's tree.
|
protected java.util.ArrayList<MetricValue> |
updateTree(MetricDataset dataset)
Update the kd-tree by adding any new dataset points, as determined by the
value name.
|
getBestEvaluation
checkValueType, createFunction, createFunction, createFunction, evaluate, getConfigParams, innerObject, isLegalNumber, setConfigParams, setEvaluator, setValueType
protected int bs
protected KD_Tree kdTree
public AlgorithmCompareTree() throws java.lang.Exception
java.lang.Exception
- any error.public AlgorithmCompareTree(java.lang.String thisValueType) throws java.lang.Exception
thisValueType
- the type of object being evaluated.java.lang.Exception
- any error.public AlgorithmCompareTree(java.lang.String thisValueType, java.util.HashMap<java.lang.String,?> thisConfig) throws java.lang.Exception
thisValueType
- the type of object being evaluated. Can be null if set later or not used.thisConfig
- list of initialisation function-specific parameters.java.lang.Exception
- any error.public AlgorithmCompareTree(java.lang.String thisValueType, java.util.HashMap<java.lang.String,?> thisConfig, FunctionMetric thisEvalMetric, EvaluateMathDef mathEval) throws java.lang.Exception
thisValueType
- the type of object being evaluated. Can be null if set later or not used.thisConfig
- list of initialisation function-specific parameters.thisEvalMetric
- the distance function.mathEval
- for simple math comparisons.java.lang.Exception
- any error.protected void initialise() throws java.lang.Exception
initialise
in class AlgorithmCompare
java.lang.Exception
- any error.public void resetValues()
resetValues
in class AlgorithmCompare
protected java.util.ArrayList<MetricValue> updateTree(MetricDataset dataset) throws java.lang.Exception
dataset
- list of dataset points, of type MetricValue
.dataset
as hashtable of name-value pairs.java.lang.Exception
- any error.public void setDatasetTree(KD_Tree theDatasets)
theDatasets
- the datasets/points to compare with. Of type MetricValue
.public KD_Tree getDatasetTree()