Package com.bayesserver.inference
Class VariableEliminationInferenceFactory
- java.lang.Object
-
- com.bayesserver.inference.VariableEliminationInferenceFactory
-
- All Implemented Interfaces:
InferenceFactory
public final class VariableEliminationInferenceFactory extends Object implements InferenceFactory
Uses the factory design pattern to create inference related objects for the Variable elimination algorithm. SeeInferenceFactory
for more details.
-
-
Constructor Summary
Constructors Constructor Description VariableEliminationInferenceFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Inference
createInferenceEngine(Network network)
Uses the factory design pattern to create inference related objects for the Variable elimination algorithm.QueryOptions
createQueryOptions()
Creates aVariableEliminationQueryOptions
instance that governs the calculations performed by theVariableEliminationInference.query(com.bayesserver.inference.QueryOptions, com.bayesserver.inference.QueryOutput)
method.QueryOutput
createQueryOutput()
Creates aVariableEliminationQueryOutput
instance that collects information about eachquery
, in addition to thedistributions
.
-
-
-
Method Detail
-
createInferenceEngine
public Inference createInferenceEngine(Network network)
Uses the factory design pattern to create inference related objects for the Variable elimination algorithm. SeeInferenceFactory
for more details.- Specified by:
createInferenceEngine
in interfaceInferenceFactory
- Parameters:
network
- The target Bayesian network.- Returns:
- The inference algorithm/engine.
-
createQueryOptions
public QueryOptions createQueryOptions()
Creates aVariableEliminationQueryOptions
instance that governs the calculations performed by theVariableEliminationInference.query(com.bayesserver.inference.QueryOptions, com.bayesserver.inference.QueryOutput)
method.- Specified by:
createQueryOptions
in interfaceInferenceFactory
- Returns:
- The options for use with
VariableEliminationInference.query(com.bayesserver.inference.QueryOptions, com.bayesserver.inference.QueryOutput)
.
-
createQueryOutput
public QueryOutput createQueryOutput()
Creates aVariableEliminationQueryOutput
instance that collects information about eachquery
, in addition to thedistributions
.The output object can be created once, and reused over many calls to
Inference.query(com.bayesserver.inference.QueryOptions, com.bayesserver.inference.QueryOutput)
.- Specified by:
createQueryOutput
in interfaceInferenceFactory
- Returns:
- The output instance.
-
-