#include <trws_decomposition.hxx>
Public Types | |
typedef GM::IndexType | IndexType |
typedef GM::LabelType | LabelType |
typedef std::vector< IndexType > | IndexList |
typedef opengm::GraphicalModelDecomposition::SubVariable | SubVariable |
typedef opengm::GraphicalModelDecomposition::SubVariableListType | SubVariableListType |
Public Member Functions | |
Decomposition (const GM &gm, IndexType numSubModels=0) | |
virtual | ~Decomposition ()=0 |
virtual IndexType | getNumberOfSubModels () const |
virtual const IndexList & | getVariableList (IndexType subModelId) const |
virtual const IndexList & | getFactorList (IndexType subModelId) const |
virtual void | ComputeVariableDecomposition (std::vector< SubVariableListType > *plist) const |
Static Public Member Functions | |
static void | CheckUnaryFactors (const GM &gm) |
checks whether all variables have corresp. unary factor with the same index and vice versa | |
static void | CheckDuplicateUnaryFactors (const GM &gm) |
static void | CheckForIsolatedNodes (const GM &gm) |
Protected Types | |
typedef std::pair< IndexType, IndexType > | Edge |
typedef std::list< Edge > | EdgeList |
typedef std::vector< EdgeList > | NodeList |
Protected Member Functions | |
IndexType | _addSubModel () |
void | _addSubFactor (const IndexType &factorId) |
void | _addSubVariable (const IndexType &variableId) |
Static Protected Member Functions | |
static void | _CreateNodeList (const GM &gm, NodeList *pnodeList) |
Protected Attributes | |
IndexType | _numberOfModels |
std::vector< IndexList > | _variableLists |
std::vector< IndexList > | _pwFactorLists |
const GM & | _gm |
Definition at line 23 of file trws_decomposition.hxx.
typedef std::pair<IndexType,IndexType> trws_base::Decomposition< GM >::Edge [protected] |
Definition at line 53 of file trws_decomposition.hxx.
typedef std::list<Edge> trws_base::Decomposition< GM >::EdgeList [protected] |
Definition at line 54 of file trws_decomposition.hxx.
typedef std::vector<IndexType> trws_base::Decomposition< GM >::IndexList |
Reimplemented in trws_base::MonotoneChainsDecomposition< GM >, and trws_base::GridDecomposition< GM >.
Definition at line 28 of file trws_decomposition.hxx.
typedef GM::IndexType trws_base::Decomposition< GM >::IndexType |
Reimplemented in trws_base::MonotoneChainsDecomposition< GM >, and trws_base::GridDecomposition< GM >.
Definition at line 26 of file trws_decomposition.hxx.
typedef GM::LabelType trws_base::Decomposition< GM >::LabelType |
Reimplemented in trws_base::MonotoneChainsDecomposition< GM >, and trws_base::GridDecomposition< GM >.
Definition at line 27 of file trws_decomposition.hxx.
typedef std::vector<EdgeList> trws_base::Decomposition< GM >::NodeList [protected] |
Definition at line 55 of file trws_decomposition.hxx.
typedef opengm::GraphicalModelDecomposition::SubVariable trws_base::Decomposition< GM >::SubVariable |
Reimplemented in trws_base::MonotoneChainsDecomposition< GM >, and trws_base::GridDecomposition< GM >.
Definition at line 29 of file trws_decomposition.hxx.
typedef opengm::GraphicalModelDecomposition::SubVariableListType trws_base::Decomposition< GM >::SubVariableListType |
Reimplemented in trws_base::MonotoneChainsDecomposition< GM >, and trws_base::GridDecomposition< GM >.
Definition at line 30 of file trws_decomposition.hxx.
trws_base::Decomposition< GM >::Decomposition | ( | const GM & | gm, | |
IndexType | numSubModels = 0 | |||
) | [inline] |
numSubModels | numSubModels - ESTIMATED number of submodels to optimize memory allocation |
Definition at line 31 of file trws_decomposition.hxx.
trws_base::Decomposition< GM >::~Decomposition< GM > | ( | ) | [inline, pure virtual] |
void trws_base::Decomposition< GM >::_addSubFactor | ( | const IndexType & | factorId | ) | [inline, protected] |
Decomposition< GM >::IndexType trws_base::Decomposition< GM >::_addSubModel | ( | ) | [inline, protected] |
void trws_base::Decomposition< GM >::_addSubVariable | ( | const IndexType & | variableId | ) | [inline, protected] |
void trws_base::Decomposition< GM >::_CreateNodeList | ( | const GM & | gm, | |
NodeList * | pnodeList | |||
) | [inline, static, protected] |
void trws_base::Decomposition< GM >::CheckDuplicateUnaryFactors | ( | const GM & | gm | ) | [inline, static] |
Definition at line 359 of file trws_decomposition.hxx.
void trws_base::Decomposition< GM >::CheckForIsolatedNodes | ( | const GM & | gm | ) | [inline, static] |
void trws_base::Decomposition< GM >::CheckUnaryFactors | ( | const GM & | gm | ) | [inline, static] |
checks whether all variables have corresp. unary factor with the same index and vice versa
Definition at line 339 of file trws_decomposition.hxx.
void trws_base::Decomposition< GM >::ComputeVariableDecomposition | ( | std::vector< SubVariableListType > * | plist | ) | const [inline, virtual] |
Definition at line 390 of file trws_decomposition.hxx.
virtual const IndexList& trws_base::Decomposition< GM >::getFactorList | ( | IndexType | subModelId | ) | const [inline, virtual] |
Definition at line 41 of file trws_decomposition.hxx.
virtual IndexType trws_base::Decomposition< GM >::getNumberOfSubModels | ( | ) | const [inline, virtual] |
Definition at line 39 of file trws_decomposition.hxx.
virtual const IndexList& trws_base::Decomposition< GM >::getVariableList | ( | IndexType | subModelId | ) | const [inline, virtual] |
Definition at line 40 of file trws_decomposition.hxx.
const GM& trws_base::Decomposition< GM >::_gm [protected] |
Definition at line 60 of file trws_decomposition.hxx.
IndexType trws_base::Decomposition< GM >::_numberOfModels [protected] |
Definition at line 57 of file trws_decomposition.hxx.
std::vector<IndexList> trws_base::Decomposition< GM >::_pwFactorLists [protected] |
Definition at line 59 of file trws_decomposition.hxx.
std::vector<IndexList> trws_base::Decomposition< GM >::_variableLists [protected] |
Definition at line 58 of file trws_decomposition.hxx.