OpenGM  2.3.x
Discrete Graphical Model Library
Public Types | Public Member Functions | List of all members
opengm::PottsNFunction< T, I, L > Class Template Reference

Potts function in N variables. More...

#include <pottsn.hxx>

+ Inheritance diagram for opengm::PottsNFunction< T, I, L >:
+ Collaboration diagram for opengm::PottsNFunction< T, I, L >:

Public Types

typedef T ValueType
 
typedef I IndexType
 
typedef L LabelType
 
typedef T value_type
 
- Public Types inherited from opengm::FunctionBase< PottsNFunction< T, I, L >, T, I, L >
typedef AccessorIterator< FunctionShapeAccessorType, true > FunctionShapeIteratorType
 

Public Member Functions

 PottsNFunction ()
 
template<class ITERATOR >
 PottsNFunction (ITERATOR, ITERATOR, const T, const T)
 
LabelType shape (const size_t) const
 
size_t size () const
 
size_t dimension () const
 
template<class ITERATOR >
ValueType operator() (ITERATOR) const
 
bool isPotts () const
 
bool isGeneralizedPotts () const
 
template<class ITERATOR >
operator() (ITERATOR begin) const
 
- Public Member Functions inherited from opengm::FunctionBase< PottsNFunction< T, I, L >, T, I, L >
bool isPotts () const
 
bool isGeneralizedPotts () const
 
bool isSubmodular () const
 
bool isSquaredDifference () const
 
bool isTruncatedSquaredDifference () const
 
bool isAbsoluteDifference () const
 
bool isTruncatedAbsoluteDifference () const
 
bool isLinearConstraint () const
 
MinMaxFunctor< T > minMax () const
 find minimum and maximum of the function in a single sweep More...
 
ReturnType min () const
 
ReturnType max () const
 
ReturnType sum () const
 
ReturnType product () const
 
ReturnType accumulate () const
 accumulate all values of the function More...
 
void forAllValuesInOrder (FUNCTOR &functor) const
 call a functor for each value of the function (in lexicographical order of the variable indices) More...
 
void forAllValuesInSwitchedOrder (FUNCTOR &functor) const
 
void forAllValuesInAnyOrder (FUNCTOR &functor) const
 call a functor for each value of the function (in un-specified order) More...
 
void forAtLeastAllUniqueValues (FUNCTOR &functor) const
 call a functor for at least all unique values of the function More...
 
void forAllValuesInOrderWithCoordinate (COORDINATE_FUNCTOR &functor) const
 
void forAllValuesInAnyOrderWithCoordinate (COORDINATE_FUNCTOR &functor) const
 
void forAtLeastAllUniqueValuesWithCoordinate (COORDINATE_FUNCTOR &functor) const
 
bool operator== (const PottsNFunction< T, I, L > &) const
 
FunctionShapeIteratorType functionShapeBegin () const
 
FunctionShapeIteratorType functionShapeEnd () const
 
size_t numberOfParameters () const
 
parameterIndex (const size_t paramNumber) const
 

Detailed Description

template<class T, class I = size_t, class L = size_t>
class opengm::PottsNFunction< T, I, L >

Potts function in N variables.

Definition at line 18 of file pottsn.hxx.

Member Typedef Documentation

template<class T, class I = size_t, class L = size_t>
typedef I opengm::PottsNFunction< T, I, L >::IndexType

Definition at line 22 of file pottsn.hxx.

template<class T, class I = size_t, class L = size_t>
typedef L opengm::PottsNFunction< T, I, L >::LabelType

Definition at line 23 of file pottsn.hxx.

template<class T, class I = size_t, class L = size_t>
typedef T opengm::PottsNFunction< T, I, L >::value_type

Definition at line 24 of file pottsn.hxx.

template<class T, class I = size_t, class L = size_t>
typedef T opengm::PottsNFunction< T, I, L >::ValueType

Definition at line 21 of file pottsn.hxx.

Constructor & Destructor Documentation

template<class T , class I , class L >
opengm::PottsNFunction< T, I, L >::PottsNFunction ( )
inline

Definition at line 90 of file pottsn.hxx.

template<class T, class I , class L >
template<class ITERATOR >
opengm::PottsNFunction< T, I, L >::PottsNFunction ( ITERATOR  shapeBegin,
ITERATOR  shapeEnd,
const T  valueEqual,
const T  valueNotEqual 
)
inline

Definition at line 74 of file pottsn.hxx.

Member Function Documentation

template<class T , class I , class L >
size_t opengm::PottsNFunction< T, I, L >::dimension ( ) const
inline

Definition at line 125 of file pottsn.hxx.

template<class T, class I = size_t, class L = size_t>
bool opengm::PottsNFunction< T, I, L >::isGeneralizedPotts ( ) const
inline

Definition at line 34 of file pottsn.hxx.

template<class T, class I = size_t, class L = size_t>
bool opengm::PottsNFunction< T, I, L >::isPotts ( ) const
inline

Definition at line 32 of file pottsn.hxx.

template<class T, class I = size_t, class L = size_t>
template<class ITERATOR >
ValueType opengm::PottsNFunction< T, I, L >::operator() ( ITERATOR  ) const
template<class T, class I = size_t, class L = size_t>
template<class ITERATOR >
T opengm::PottsNFunction< T, I, L >::operator() ( ITERATOR  begin) const
inline

Definition at line 101 of file pottsn.hxx.

template<class T , class I , class L >
PottsNFunction< T, I, L >::LabelType opengm::PottsNFunction< T, I, L >::shape ( const size_t  i) const
inline

Definition at line 116 of file pottsn.hxx.

template<class T , class I , class L >
size_t opengm::PottsNFunction< T, I, L >::size ( ) const
inline

Definition at line 131 of file pottsn.hxx.