OpenGM  2.3.x
Discrete Graphical Model Library
Public Types | Public Member Functions | List of all members
opengm::Inference< GM, ACC > Class Template Referenceabstract

Inference algorithm interface. More...

#include <inference.hxx>

+ Inheritance diagram for opengm::Inference< GM, ACC >:
+ Collaboration diagram for opengm::Inference< GM, ACC >:

Public Types

typedef GM GraphicalModelType
 
typedef ACC AccumulationType
 
typedef GraphicalModelType::LabelType LabelType
 
typedef GraphicalModelType::IndexType IndexType
 
typedef GraphicalModelType::ValueType ValueType
 
typedef GraphicalModelType::OperatorType OperatorType
 
typedef GraphicalModelType::FactorType FactorType
 
typedef GraphicalModelType::IndependentFactorType IndependentFactorType
 
typedef GraphicalModelType::FunctionIdentifier FunctionIdentifier
 

Public Member Functions

virtual ~Inference ()
 
virtual std::string name () const =0
 
virtual const GraphicalModelTypegraphicalModel () const =0
 
virtual InferenceTermination infer ()=0
 
virtual void setStartingPoint (typename std::vector< LabelType >::const_iterator)
 set initial labeling More...
 
virtual InferenceTermination arg (std::vector< LabelType > &, const size_t=1) const
 output a solution More...
 
virtual InferenceTermination args (std::vector< std::vector< LabelType > > &) const
 
virtual InferenceTermination marginal (const size_t, IndependentFactorType &) const
 output a solution for a marginal for a specific variable More...
 
virtual InferenceTermination factorMarginal (const size_t, IndependentFactorType &) const
 output a solution for a marginal for all variables connected to a factor More...
 
virtual ValueType bound () const
 return a bound on the solution More...
 
virtual ValueType value () const
 return the solution (value) More...
 
InferenceTermination constrainedOptimum (std::vector< IndexType > &, std::vector< LabelType > &, std::vector< LabelType > &) const
 
InferenceTermination modeFromMarginal (std::vector< LabelType > &) const
 
InferenceTermination modeFromFactorMarginal (std::vector< LabelType > &) const
 

Detailed Description

template<class GM, class ACC>
class opengm::Inference< GM, ACC >

Inference algorithm interface.

Definition at line 43 of file inference.hxx.

Member Typedef Documentation

§ AccumulationType

template<class GM, class ACC>
typedef ACC opengm::Inference< GM, ACC >::AccumulationType

Definition at line 47 of file inference.hxx.

§ FactorType

template<class GM, class ACC>
typedef GraphicalModelType::FactorType opengm::Inference< GM, ACC >::FactorType

Definition at line 52 of file inference.hxx.

§ FunctionIdentifier

template<class GM, class ACC>
typedef GraphicalModelType::FunctionIdentifier opengm::Inference< GM, ACC >::FunctionIdentifier

Definition at line 54 of file inference.hxx.

§ GraphicalModelType

template<class GM, class ACC>
typedef GM opengm::Inference< GM, ACC >::GraphicalModelType

Definition at line 46 of file inference.hxx.

§ IndependentFactorType

template<class GM, class ACC>
typedef GraphicalModelType::IndependentFactorType opengm::Inference< GM, ACC >::IndependentFactorType

Definition at line 53 of file inference.hxx.

§ IndexType

template<class GM, class ACC>
typedef GraphicalModelType::IndexType opengm::Inference< GM, ACC >::IndexType

Definition at line 49 of file inference.hxx.

§ LabelType

template<class GM, class ACC>
typedef GraphicalModelType::LabelType opengm::Inference< GM, ACC >::LabelType

Definition at line 48 of file inference.hxx.

§ OperatorType

template<class GM, class ACC>
typedef GraphicalModelType::OperatorType opengm::Inference< GM, ACC >::OperatorType

Definition at line 51 of file inference.hxx.

§ ValueType

template<class GM, class ACC>
typedef GraphicalModelType::ValueType opengm::Inference< GM, ACC >::ValueType

Definition at line 50 of file inference.hxx.

Constructor & Destructor Documentation

§ ~Inference()

template<class GM, class ACC>
virtual opengm::Inference< GM, ACC >::~Inference ( )
inlinevirtual

Definition at line 56 of file inference.hxx.

Member Function Documentation

§ arg()

template<class GM , class ACC >
InferenceTermination opengm::Inference< GM, ACC >::arg ( std::vector< LabelType > &  arg,
const size_t  argIndex = 1 
) const
inlinevirtual

§ args()

template<class GM , class ACC >
InferenceTermination opengm::Inference< GM, ACC >::args ( std::vector< std::vector< LabelType > > &  out) const
inlinevirtual

Reimplemented in opengm::LPCplex< GM, ACC >, opengm::LPGurobi< GM, ACC >, opengm::AStar< GM, ACC >, and opengm::GreedyGremlin< GM, ACC >.

Definition at line 102 of file inference.hxx.

+ Here is the caller graph for this function:

§ bound()

template<class GM , class ACC >
GM::ValueType opengm::Inference< GM, ACC >::bound ( ) const
virtual

§ constrainedOptimum()

template<class GM , class ACC >
InferenceTermination opengm::Inference< GM, ACC >::constrainedOptimum ( std::vector< IndexType > &  variableIndices,
std::vector< LabelType > &  givenLabels,
std::vector< LabelType > &  conf 
) const

Definition at line 138 of file inference.hxx.

+ Here is the caller graph for this function:

§ factorMarginal()

template<class GM , class ACC >
InferenceTermination opengm::Inference< GM, ACC >::factorMarginal ( const size_t  factorIndex,
IndependentFactorType out 
) const
inlinevirtual

§ graphicalModel()

template<class GM, class ACC>
virtual const GraphicalModelType& opengm::Inference< GM, ACC >::graphicalModel ( ) const
pure virtual

Implemented in opengm::IntersectionBasedInf< GM, PROPOSAL_GEN >, opengm::FusionBasedInf< GM, PROPOSAL_GEN >, opengm::trws_base::SmoothingBasedInference< GM, ACC >, opengm::CombiLP< GM, ACC, LPSOLVER >, opengm::SelfFusion< INFERENCE >, opengm::LPCplex< GM, ACC >, opengm::LPGurobi< GM, ACC >, opengm::LazyFlipper< GM, ACC >, opengm::Multicut< GM, ACC >, opengm::CGC< GM, ACC >, opengm::LOC< GM, ACC >, opengm::LSA_TR< GM, ACC >, opengm::SwendsenWang< GM, ACC >, opengm::AStar< GM, ACC >, opengm::Gibbs< GM, ACC >, opengm::MessagePassing< GM, ACC, UPDATE_RULES, DIST >, opengm::ReducedInference< GM, ACC, INF >, opengm::external::MPLP< GM >, opengm::TRWSi< GM, ACC >, opengm::external::TRWS< GM >, opengm::external::libdai::LoopCorrectedBp< GM, ACC, CAVITY_INFERENCE >, opengm::external::DAOOPT< GM >, opengm::external::AD3Inf< GM, ACC >, opengm::external::libdai::DecMap< SUB_INFERENCE >, opengm::external::libdai::TreeReweightedBp< GM, ACC >, opengm::MQPBO< GM, ACC >, opengm::external::libdai::MeanField< GM, ACC >, opengm::LPInferenceBase< LP_INFERENCE_TYPE >, opengm::LPInferenceBase< LPGurobi2< GM_TYPE, ACC_TYPE > >, opengm::LPInferenceBase< LPCplex2< GM_TYPE, ACC_TYPE > >, opengm::AlphaExpansionFusion< GM, ACC >, opengm::AlphaExpansion< GM, INF >, opengm::DualDecompositionSubGradient< GM, INF, DUALBLOCK >, opengm::external::MRFLIB< GM >, opengm::external::QPBO< GM >, opengm::ICM< GM, ACC >, opengm::external::libdai::TreeExpectationPropagation< GM, ACC >, opengm::PartitionMove< GM, ACC >, opengm::external::GRANTE< GM >, opengm::InfAndFlip< GM, ACC, INF >, opengm::GreedyGremlin< GM, ACC >, opengm::external::FastPD< GM >, opengm::external::GCOLIB< GM >, opengm::external::SRMP< GM >, opengm::HQPBO< GM, ACC >, opengm::GraphCut< GM, ACC, MINSTCUT >, opengm::AlphaBetaSwap< GM, INF >, opengm::DynamicProgramming< GM, ACC >, opengm::DMC< GM, INF >, opengm::Bruteforce< GM, ACC >, opengm::SAT< GM >, and opengm::QPBO< GM, MIN_ST_CUT >.

+ Here is the caller graph for this function:

§ infer()

template<class GM, class ACC>
virtual InferenceTermination opengm::Inference< GM, ACC >::infer ( )
pure virtual

Implemented in opengm::IntersectionBasedInf< GM, PROPOSAL_GEN >, opengm::FusionBasedInf< GM, PROPOSAL_GEN >, opengm::CombiLP< GM, ACC, LPSOLVER >, opengm::SelfFusion< INFERENCE >, opengm::LPCplex< GM, ACC >, opengm::LPGurobi< GM, ACC >, opengm::LazyFlipper< GM, ACC >, opengm::CGC< GM, ACC >, opengm::Multicut< GM, ACC >, opengm::LOC< GM, ACC >, opengm::NesterovAcceleratedGradient< GM, ACC >, opengm::LSA_TR< GM, ACC >, opengm::MessagePassing< GM, ACC, UPDATE_RULES, DIST >, opengm::SwendsenWang< GM, ACC >, opengm::Gibbs< GM, ACC >, opengm::AStar< GM, ACC >, opengm::external::MPLP< GM >, opengm::ReducedInference< GM, ACC, INF >, opengm::ADSal< GM, ACC >, opengm::TRWSi< GM, ACC >, opengm::external::TRWS< GM >, opengm::external::libdai::LoopCorrectedBp< GM, ACC, CAVITY_INFERENCE >, opengm::external::DAOOPT< GM >, opengm::external::libdai::DecMap< SUB_INFERENCE >, opengm::external::libdai::TreeReweightedBp< GM, ACC >, opengm::external::AD3Inf< GM, ACC >, opengm::external::libdai::MeanField< GM, ACC >, opengm::MQPBO< GM, ACC >, opengm::AlphaExpansionFusion< GM, ACC >, opengm::external::MRFLIB< GM >, opengm::AlphaExpansion< GM, INF >, opengm::LPInferenceBase< LP_INFERENCE_TYPE >, opengm::LPInferenceBase< LPGurobi2< GM_TYPE, ACC_TYPE > >, opengm::LPInferenceBase< LPCplex2< GM_TYPE, ACC_TYPE > >, opengm::DualDecompositionSubGradient< GM, INF, DUALBLOCK >, opengm::external::libdai::TreeExpectationPropagation< GM, ACC >, opengm::external::QPBO< GM >, opengm::ICM< GM, ACC >, opengm::external::GRANTE< GM >, opengm::InfAndFlip< GM, ACC, INF >, opengm::PartitionMove< GM, ACC >, opengm::external::FastPD< GM >, opengm::GreedyGremlin< GM, ACC >, opengm::external::GCOLIB< GM >, opengm::external::SRMP< GM >, opengm::GraphCut< GM, ACC, MINSTCUT >, opengm::HQPBO< GM, ACC >, opengm::AlphaBetaSwap< GM, INF >, opengm::DynamicProgramming< GM, ACC >, opengm::DMC< GM, INF >, opengm::Bruteforce< GM, ACC >, opengm::SAT< GM >, and opengm::QPBO< GM, MIN_ST_CUT >.

+ Here is the caller graph for this function:

§ marginal()

template<class GM , class ACC >
InferenceTermination opengm::Inference< GM, ACC >::marginal ( const size_t  variableIndex,
IndependentFactorType out 
) const
inlinevirtual

§ modeFromFactorMarginal()

template<class GM , class ACC >
InferenceTermination opengm::Inference< GM, ACC >::modeFromFactorMarginal ( std::vector< LabelType > &  conf) const

Definition at line 359 of file inference.hxx.

+ Here is the caller graph for this function:

§ modeFromMarginal()

template<class GM , class ACC >
InferenceTermination opengm::Inference< GM, ACC >::modeFromMarginal ( std::vector< LabelType > &  conf) const

Definition at line 330 of file inference.hxx.

+ Here is the caller graph for this function:

§ name()

template<class GM, class ACC>
virtual std::string opengm::Inference< GM, ACC >::name ( ) const
pure virtual

Implemented in opengm::IntersectionBasedInf< GM, PROPOSAL_GEN >, opengm::FusionBasedInf< GM, PROPOSAL_GEN >, opengm::CombiLP< GM, ACC, LPSOLVER >, opengm::SelfFusion< INFERENCE >, opengm::LPCplex< GM, ACC >, opengm::LPGurobi< GM, ACC >, opengm::LazyFlipper< GM, ACC >, opengm::Multicut< GM, ACC >, opengm::CGC< GM, ACC >, opengm::LOC< GM, ACC >, opengm::NesterovAcceleratedGradient< GM, ACC >, opengm::LSA_TR< GM, ACC >, opengm::SwendsenWang< GM, ACC >, opengm::AStar< GM, ACC >, opengm::Gibbs< GM, ACC >, opengm::MessagePassing< GM, ACC, UPDATE_RULES, DIST >, opengm::ReducedInference< GM, ACC, INF >, opengm::ADSal< GM, ACC >, opengm::external::MPLP< GM >, opengm::TRWSi< GM, ACC >, opengm::external::TRWS< GM >, opengm::external::DAOOPT< GM >, opengm::external::AD3Inf< GM, ACC >, opengm::MQPBO< GM, ACC >, opengm::AlphaExpansionFusion< GM, ACC >, opengm::AlphaExpansion< GM, INF >, opengm::DualDecompositionSubGradient< GM, INF, DUALBLOCK >, opengm::external::MRFLIB< GM >, opengm::external::QPBO< GM >, opengm::ICM< GM, ACC >, opengm::PartitionMove< GM, ACC >, opengm::external::GRANTE< GM >, opengm::InfAndFlip< GM, ACC, INF >, opengm::GreedyGremlin< GM, ACC >, opengm::external::FastPD< GM >, opengm::external::GCOLIB< GM >, opengm::external::SRMP< GM >, opengm::HQPBO< GM, ACC >, opengm::GraphCut< GM, ACC, MINSTCUT >, opengm::AlphaBetaSwap< GM, INF >, opengm::DynamicProgramming< GM, ACC >, opengm::DMC< GM, INF >, opengm::Bruteforce< GM, ACC >, opengm::SAT< GM >, opengm::QPBO< GM, MIN_ST_CUT >, opengm::external::libdai::MeanField< GM, ACC >, opengm::external::libdai::TreeReweightedBp< GM, ACC >, opengm::external::libdai::LoopCorrectedBp< GM, ACC, CAVITY_INFERENCE >, opengm::external::libdai::TreeExpectationPropagation< GM, ACC >, opengm::external::libdai::DecMap< SUB_INFERENCE >, opengm::LPCplex2< GM_TYPE, ACC_TYPE >, and opengm::LPGurobi2< GM_TYPE, ACC_TYPE >.

+ Here is the caller graph for this function:

§ setStartingPoint()

template<class GM , class ACC >
void opengm::Inference< GM, ACC >::setStartingPoint ( typename std::vector< LabelType >::const_iterator  begin)
inlinevirtual

set initial labeling

Parameters
beginiterator to the beginning of a sequence of labels

Reimplemented in opengm::LPCplex< GM, ACC >, opengm::LazyFlipper< GM, ACC >, opengm::CGC< GM, ACC >, opengm::LOC< GM, ACC >, opengm::LSA_TR< GM, ACC >, opengm::Gibbs< GM, ACC >, opengm::AlphaExpansionFusion< GM, ACC >, opengm::ICM< GM, ACC >, and opengm::InfAndFlip< GM, ACC, INF >.

Definition at line 95 of file inference.hxx.

+ Here is the caller graph for this function:

§ value()

template<class GM , class ACC >
GM::ValueType opengm::Inference< GM, ACC >::value ( ) const
virtual