Class TMVAComplexityEvaluator
java.lang.Object
solvers.queueingnet.treeAlgorithms.ComplexityEvaluator
solvers.queueingnet.treeAlgorithms.tmva.TMVAComplexityEvaluator
Class responsible for evaluating the complexity of the tree MVA algorithm if
it were to be run on a given tree representing a network.
- Author:
- Ben Homer, 2014.
-
Nested Class Summary
Nested classes/interfaces inherited from class ComplexityEvaluator
ComplexityEvaluator.ComplexityBundle -
Field Summary
Fields inherited from class ComplexityEvaluator
ccu, fcfToPcRatio, perClassSparsityMeasure, qnm, sparcityOfDemandsMatrix, stdComplexity, treeComplexity -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ComplexityEvaluator.ComplexityBundlegetLeafNodeComplexity(Node node, PopulationVector pv) Gets the complexity of a leaf node computation in the TMVA algorithm.protected ComplexityEvaluator.ComplexityBundleGets the complexity of running standard/sequential MVA algorithm over a network with the specified population vector.protected ComplexityEvaluator.ComplexityBundlegetSubnetNodeComplexity(Node node, PopulationVector pv) Gets the complexity of a subnetwork node computation in the TMVA algorithm.protected voidPrints a summary of the complexity evaluators calculations.booleantreeHasAcceptableComplexity(Node root, PopulationVector pv) Determines if the TMVA for the specified tree has better complexity characteristics than the standard/sequential MVA algorithm for the same network.
-
Constructor Details
-
TMVAComplexityEvaluator
Constructor.- Parameters:
qnm- The queueing network model we are trying to solve.ccu- The ClassCoverageUtils object used for calculating the class coverage at certain nodes in the planted tree.
-
-
Method Details
-
treeHasAcceptableComplexity
Determines if the TMVA for the specified tree has better complexity characteristics than the standard/sequential MVA algorithm for the same network.- Specified by:
treeHasAcceptableComplexityin classComplexityEvaluator- Parameters:
root- The root node of the tree to test.pv- The per class population vector of the network.- Returns:
- A boolean indicating whether the tree has an acceptable expected complexity.
-
getLeafNodeComplexity
protected ComplexityEvaluator.ComplexityBundle getLeafNodeComplexity(Node node, PopulationVector pv) Gets the complexity of a leaf node computation in the TMVA algorithm.- Specified by:
getLeafNodeComplexityin classComplexityEvaluator- Parameters:
node- The leaf node.pv- The per class population vector of the network.- Returns:
- A ComplexityBundle containing the expected time and space complexities.
-
getSubnetNodeComplexity
protected ComplexityEvaluator.ComplexityBundle getSubnetNodeComplexity(Node node, PopulationVector pv) Gets the complexity of a subnetwork node computation in the TMVA algorithm.- Specified by:
getSubnetNodeComplexityin classComplexityEvaluator- Parameters:
node- The subnetwork node.pv- The per class population vector of the network.- Returns:
- A ComplexityBundle containing the expected time and space complexities.
-
getStandardAlgorithmComplexity
Gets the complexity of running standard/sequential MVA algorithm over a network with the specified population vector.- Specified by:
getStandardAlgorithmComplexityin classComplexityEvaluator- Parameters:
pv- The network's population vector.- Returns:
- A ComplexityBundle containing the expected time and space complexities.
-
printSummary
protected void printSummary()Prints a summary of the complexity evaluators calculations.- Specified by:
printSummaryin classComplexityEvaluator
-