You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
MPE does not return assignments for disconnected/isolated variables #66
When a probabilistic graphical model contains disconnected components or isolated variables (variables that don't appear in any pairwise/higher-order factors), the current MPE implementation does not include these variables in the returned assignment.
assignment=mpe(model)
# Returns: {0: x, 1: y, 2: z, 3: w} # All variables included
Root Cause
The contraction tree only includes tensors that are connected through shared variables. Isolated variables with only unary factors are not contracted into the tree and thus their optimal assignments are never computed.
Potential Solutions
Post-processing: After contraction, identify variables not in the assignment and compute their optimal values from unary factors
Preprocessing: Add dummy binary factors with uniform potentials to connect isolated components
Separate handling: Detect disconnected components before contraction and solve each component separately
Discovered During
UAI benchmark testing - some benchmark models have isolated variables or disconnected components.
Related
PR #65 - Tropical einsum module with OMEinsum-style design
Activity