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

[class mqpbo] Multilabel QPBO (MQPBO) Implements the algorithms described in i) Ivan Kovtun: Partial Optimal Labeling Search for a NP-Hard Subclass of (max, +) Problems. DAGM-Symposium 2003 (part. opt. for potts) ii) P. Kohli, A. Shekhovtsov, C. Rother, V. Kolmogorov, and P. Torr: On partial optimality in multi-label MRFs, ICML 2008 (MQPBO) iii) P. Swoboda, B. Savchynskyy, J.H. Kappes, and C. Schnörr : Partial Optimality via Iterative Pruning for the Potts Model, SSVM 2013 (MQPBO with permutation sampling) More...

#include <mqpbo.hxx>

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

Classes

class  Parameter
 

Public Types

enum  PermutationType { NONE, RANDOM, MINMARG }
 
typedef ACC AccumulationType
 
typedef GM GmType
 
typedef GM GraphicalModelType
 
typedef visitors::VerboseVisitor< MQPBO< GM, ACC > > VerboseVisitorType
 
typedef visitors::EmptyVisitor< MQPBO< GM, ACC > > EmptyVisitorType
 
typedef visitors::TimingVisitor< MQPBO< GM, ACC > > TimingVisitorType
 
typedef ValueType GraphValueType
 
- Public Types inherited from opengm::Inference< GM, ACC >
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

 MQPBO (const GmType &, const Parameter &=Parameter())
 [class mqpbo] More...
 
 ~MQPBO ()
 
std::string name () const
 
const GmTypegraphicalModel () const
 
InferenceTermination infer ()
 
void reset ()
 reset assumes that the structure of the graphical model has not changed More...
 
GM::ValueType bound () const
 return a bound on the solution More...
 
GM::ValueType value () const
 return the solution (value) More...
 
template<class VisitorType >
InferenceTermination infer (VisitorType &)
 
InferenceTermination testQuess (std::vector< LabelType > &guess)
 
InferenceTermination testPermutation (PermutationType permutationType)
 
void setStartingPoint (typename std::vector< typename GM::LabelType >::const_iterator)
 set starting point More...
 
virtual InferenceTermination arg (std::vector< LabelType > &, const size_t=1) const
 output a solution More...
 
const std::vector< opengm::Tribool > & partialOptimality (IndexType var) const
 
bool partialOptimality (IndexType var, LabelType &l) const
 
double optimalityV () const
 
double optimality () const
 
- Public Member Functions inherited from opengm::Inference< GM, ACC >
virtual ~Inference ()
 
virtual void setStartingPoint (typename std::vector< LabelType >::const_iterator)
 set initial labeling 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...
 
InferenceTermination constrainedOptimum (std::vector< IndexType > &, std::vector< LabelType > &, std::vector< LabelType > &) const
 
InferenceTermination modeFromMarginal (std::vector< LabelType > &) const
 
InferenceTermination modeFromFactorMarginal (std::vector< LabelType > &) const
 

Public Attributes

 OPENGM_GM_TYPE_TYPEDEFS
 

Detailed Description

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

[class mqpbo] Multilabel QPBO (MQPBO) Implements the algorithms described in i) Ivan Kovtun: Partial Optimal Labeling Search for a NP-Hard Subclass of (max, +) Problems. DAGM-Symposium 2003 (part. opt. for potts) ii) P. Kohli, A. Shekhovtsov, C. Rother, V. Kolmogorov, and P. Torr: On partial optimality in multi-label MRFs, ICML 2008 (MQPBO) iii) P. Swoboda, B. Savchynskyy, J.H. Kappes, and C. Schnörr : Partial Optimality via Iterative Pruning for the Potts Model, SSVM 2013 (MQPBO with permutation sampling)

Corresponding author: Joerg Hendrik Kappes

Definition at line 37 of file mqpbo.hxx.

Member Typedef Documentation

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

Definition at line 40 of file mqpbo.hxx.

template<class GM, class ACC>
typedef visitors::EmptyVisitor<MQPBO<GM, ACC> > opengm::MQPBO< GM, ACC >::EmptyVisitorType

Definition at line 45 of file mqpbo.hxx.

template<class GM, class ACC>
typedef GM opengm::MQPBO< GM, ACC >::GmType

Definition at line 41 of file mqpbo.hxx.

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

Definition at line 42 of file mqpbo.hxx.

template<class GM, class ACC>
typedef ValueType opengm::MQPBO< GM, ACC >::GraphValueType

Definition at line 47 of file mqpbo.hxx.

template<class GM, class ACC>
typedef visitors::TimingVisitor<MQPBO<GM, ACC> > opengm::MQPBO< GM, ACC >::TimingVisitorType

Definition at line 46 of file mqpbo.hxx.

template<class GM, class ACC>
typedef visitors::VerboseVisitor<MQPBO<GM, ACC> > opengm::MQPBO< GM, ACC >::VerboseVisitorType

Definition at line 44 of file mqpbo.hxx.

Constructor & Destructor Documentation

template<class GM , class ACC >
opengm::MQPBO< GM, ACC >::MQPBO ( const GmType gm,
const Parameter parameter = Parameter() 
)

[class mqpbo]

Definition at line 114 of file mqpbo.hxx.

template<class GM , class ACC >
opengm::MQPBO< GM, ACC >::~MQPBO ( )

Definition at line 180 of file mqpbo.hxx.

Member Function Documentation

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

output a solution

Parameters
[out]arglabeling
argIndexsolution index (1=best, 2=second best, etc.)

Reimplemented from opengm::Inference< GM, ACC >.

Definition at line 935 of file mqpbo.hxx.

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

return a bound on the solution

Reimplemented from opengm::Inference< GM, ACC >.

Definition at line 920 of file mqpbo.hxx.

template<class GM , class ACC >
const MQPBO< GM, ACC >::GmType & opengm::MQPBO< GM, ACC >::graphicalModel ( ) const
inlinevirtual

Implements opengm::Inference< GM, ACC >.

Definition at line 215 of file mqpbo.hxx.

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

Implements opengm::Inference< GM, ACC >.

Definition at line 789 of file mqpbo.hxx.

template<class GM , class ACC >
template<class VisitorType >
InferenceTermination opengm::MQPBO< GM, ACC >::infer ( VisitorType &  visitor)

Definition at line 798 of file mqpbo.hxx.

+ Here is the call graph for this function:

template<class GM , class ACC >
std::string opengm::MQPBO< GM, ACC >::name ( ) const
inlinevirtual

Implements opengm::Inference< GM, ACC >.

Definition at line 208 of file mqpbo.hxx.

template<class GM , class ACC >
double opengm::MQPBO< GM, ACC >::optimality ( ) const

Definition at line 885 of file mqpbo.hxx.

template<class GM , class ACC >
double opengm::MQPBO< GM, ACC >::optimalityV ( ) const

Definition at line 903 of file mqpbo.hxx.

template<class GM, class ACC>
const std::vector<opengm::Tribool>& opengm::MQPBO< GM, ACC >::partialOptimality ( IndexType  var) const
inline

Definition at line 77 of file mqpbo.hxx.

template<class GM, class ACC>
bool opengm::MQPBO< GM, ACC >::partialOptimality ( IndexType  var,
LabelType l 
) const
inline

Definition at line 78 of file mqpbo.hxx.

template<class GM , class ACC >
void opengm::MQPBO< GM, ACC >::reset ( )
inline

reset assumes that the structure of the graphical model has not changed

TODO

Definition at line 190 of file mqpbo.hxx.

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

set starting point

TODO

Definition at line 199 of file mqpbo.hxx.

template<class GM , class ACC >
InferenceTermination opengm::MQPBO< GM, ACC >::testPermutation ( PermutationType  permutationType)
inline

Definition at line 386 of file mqpbo.hxx.

+ Here is the call graph for this function:

template<class GM , class ACC >
InferenceTermination opengm::MQPBO< GM, ACC >::testQuess ( std::vector< LabelType > &  guess)
inline

Definition at line 287 of file mqpbo.hxx.

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

return the solution (value)

Reimplemented from opengm::Inference< GM, ACC >.

Definition at line 926 of file mqpbo.hxx.

Member Data Documentation

template<class GM, class ACC>
opengm::MQPBO< GM, ACC >::OPENGM_GM_TYPE_TYPEDEFS

Definition at line 43 of file mqpbo.hxx.