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 p(x)=1Z∏sfs(xs) as a bipartite graph: one node per variable, one node per factor, and an edge when a variable appears in a factor.

Steps

  1. Write the joint as a product of local factors fs, each depending on a small subset xs of the variables.
  2. 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.
  3. A Bayesian network becomes a factor graph with one factor per conditional table p(xi∣pai). An MRF becomes one factor per clique potential.
  4. It removes ambiguity. In an MRF a triangle on x1,x2,x3 could be one factor f(x1,x2,x3) or three pairwise factors, and the plain graph cannot show which. The factor graph can.
  5. 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

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: A (2 states), B (3 states), C (2 states), D (2 states) and E (4 states). The arrows are A→C, B→C, C→D, B→E and D→E. How many free parameters does it need, and how does this compare with the full joint table?