What is a factor graph, and why is it the natural structure on which to run message passing?
Probabilistic models, Factor graphs
Level L2 Elementary. Length Short. Nature Th Theoretical.
What's being asked
Whether you know the bipartite structure of a factor graph and why it removes ambiguity compared with a plain undirected graph.
Key idea
A factor graph writes as a bipartite graph: one node per variable, one node per factor, and an edge when a variable appears in a factor.
Steps
- Write the joint as a product of local factors , each depending on a small subset of the variables.
- Draw a circle for each variable and a square for each factor. Connect a square to every variable that its factor uses. Edges only join a variable to a factor, never two variables.
- A Bayesian network becomes a factor graph with one factor per conditional table . An MRF becomes one factor per clique potential.
- It removes ambiguity. In an MRF a triangle on could be one factor or three pairwise factors, and the plain graph cannot show which. The factor graph can.
- Message passing (the sum-product algorithm) sends messages variable-to-factor and factor-to-variable along edges. If the factor graph is a tree, it gives exact marginals.
Common mistakes
- Drawing edges between two variables or two factors. The graph is bipartite.
- Assuming every factor graph is a tree. With loops, sum-product is only approximate (loopy belief propagation), and exact inference needs a junction tree.
- Forgetting that may be absent. For a Bayesian network, .
How long your answer should be
4–5 sentences and a small sketch in words.
Read this
Previous in Probabilistic models: How does a Markov random field (an undirected graphical model) differ from a Bayesian network, and what is the partition function?
Next in Probabilistic models: A Bayesian network has five discrete variables: (2 states), (3 states), (2 states), (2 states) and (4 states). The arrows are , , , and . How many free parameters does it need, and how does this compare with the full joint table?