Classes | |
struct | StarGraph |
Public Member Functions | |
DiscreteFactorGraph::shared_ptr | iterate (const std::map< Key, DiscreteKey > &allDiscreteKeys) |
One step of belief propagation. More... | |
LoopyBelief (const DiscreteFactorGraph &graph, const std::map< Key, DiscreteKey > &allDiscreteKeys) | |
void | print (const std::string &s="") const |
print More... | |
Private Types | |
typedef std::map< Key, size_t > | CorrectedBeliefIndices |
typedef std::map< Key, StarGraph > | StarGraphs |
Private Member Functions | |
StarGraphs | buildStarGraphs (const DiscreteFactorGraph &graph, const std::map< Key, DiscreteKey > &allDiscreteKeys) const |
Private Attributes | |
StarGraphs | starGraphs_ |
star graph at each variable More... | |
Loopy belief solver for graphs with only binary and unary factors
Definition at line 24 of file testLoopyBelief.cpp.
|
private |
Star graph struct for each node, containing
Definition at line 32 of file testLoopyBelief.cpp.
|
private |
Definition at line 57 of file testLoopyBelief.cpp.
|
inline |
Constructor Need all discrete keys to access node's cardinality for creating belief factors TODO: so troublesome!!
Definition at line 66 of file testLoopyBelief.cpp.
|
inlineprivate |
Build star graphs for each node.
< access to all factors of each node
Definition at line 169 of file testLoopyBelief.cpp.
|
inline |
One step of belief propagation.
Definition at line 79 of file testLoopyBelief.cpp.
|
inline |
Definition at line 71 of file testLoopyBelief.cpp.
|
private |
star graph at each variable
Definition at line 58 of file testLoopyBelief.cpp.