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

Partition Move

Currently Partition Move only implements the Kernighan-Lin-Algorithm. More...

#include <partition-move.hxx>

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

Classes

struct  Parameter
 

Public Types

typedef ACC AccumulationType
 
typedef GM GraphicalModelType
 
typedef size_t LPIndexType
 
typedef visitors::VerboseVisitor< PartitionMove< GM, ACC > > VerboseVisitorType
 
typedef visitors::EmptyVisitor< PartitionMove< GM, ACC > > EmptyVisitorType
 
typedef visitors::TimingVisitor< PartitionMove< GM, ACC > > TimingVisitorType
 
typedef __gnu_cxx::hash_map< IndexType, LPIndexTypeEdgeMapType
 
typedef __gnu_cxx::hash_set< IndexTypeVariableSetType
 
- 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

 ~PartitionMove ()
 
 PartitionMove (const GraphicalModelType &, Parameter para=Parameter())
 
virtual std::string name () const
 
const GraphicalModelTypegraphicalModel () const
 
virtual InferenceTermination infer ()
 
template<class VisitorType >
InferenceTermination infer (VisitorType &)
 
virtual InferenceTermination arg (std::vector< LabelType > &, const size_t=1) const
 output a solution More...
 
- 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...
 
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
 

Public Attributes

 OPENGM_GM_TYPE_TYPEDEFS
 

Detailed Description

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

Partition Move

Currently Partition Move only implements the Kernighan-Lin-Algorithm.

Definition at line 39 of file partition-move.hxx.

Member Typedef Documentation

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

Definition at line 42 of file partition-move.hxx.

template<class GM , class ACC >
typedef __gnu_cxx::hash_map<IndexType, LPIndexType> opengm::PartitionMove< GM, ACC >::EdgeMapType

Definition at line 53 of file partition-move.hxx.

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

Definition at line 47 of file partition-move.hxx.

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

Definition at line 43 of file partition-move.hxx.

template<class GM , class ACC >
typedef size_t opengm::PartitionMove< GM, ACC >::LPIndexType

Definition at line 45 of file partition-move.hxx.

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

Definition at line 48 of file partition-move.hxx.

template<class GM , class ACC >
typedef __gnu_cxx::hash_set<IndexType> opengm::PartitionMove< GM, ACC >::VariableSetType

Definition at line 54 of file partition-move.hxx.

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

Definition at line 46 of file partition-move.hxx.

Constructor & Destructor Documentation

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

Definition at line 95 of file partition-move.hxx.

template<class GM , class ACC >
opengm::PartitionMove< GM, ACC >::PartitionMove ( const GraphicalModelType gm,
Parameter  para = Parameter() 
)

Definition at line 101 of file partition-move.hxx.

Member Function Documentation

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

output a solution

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

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

Definition at line 478 of file partition-move.hxx.

template<class GM , class ACC >
const GraphicalModelType& opengm::PartitionMove< GM, ACC >::graphicalModel ( ) const
inlinevirtual

Implements opengm::Inference< GM, ACC >.

Definition at line 65 of file partition-move.hxx.

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

Implements opengm::Inference< GM, ACC >.

Definition at line 223 of file partition-move.hxx.

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

Definition at line 233 of file partition-move.hxx.

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

Implements opengm::Inference< GM, ACC >.

Definition at line 64 of file partition-move.hxx.

Member Data Documentation

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

Definition at line 44 of file partition-move.hxx.