class BoundedTreeWidthBN extends Error
The BoundedTreeWidthBN
class provides bounded treewidth Bayesian Networks.
- Alphabetic
- By Inheritance
- BoundedTreeWidthBN
- Error
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
Value Members
- val DEBUG: Boolean
-
def
addEdgesGreedily(g: MGraph[Double], mp: MGraph[Double], k: Int): Unit
Greedily add edges to 'g' that do not increase treewidth beyond 'kMax'.
Greedily add edges to 'g' that do not increase treewidth beyond 'kMax'.
- g
the maximum scoring graph of bounded treewidth
- mp
the triangulated moralized graph
- k
the current treewidth
-
def
blockSort(mp: MGraph[Double]): Array[Int]
Order the blocks in the graph.
Order the blocks in the graph.
- mp
the triangulated moralized graph
-
def
findbestEdge(g: MGraph[Double], mp: MGraph[Double], k: Int): Pair
Find and return the next best remaining edge.
Find and return the next best remaining edge. Return (-1, -1) if there are none.
- g
the maximum scoring graph of bounded treewidth
- mp
the triangulated moralized graph
- k
the current treewidth
-
final
def
flaw(method: String, message: String): Unit
- Definition Classes
- Error
-
def
learnBN(): MGraph[Double]
Learn a Bayesian Network with Bounded Treewidth.
Learn a Bayesian Network with Bounded Treewidth. Starting with a spanning tree, add score improving edges, so long as the 'kMax' bound on the graph's treewidth is not exceeded. This corresponds to Algorithm 1 in the paper.
-
def
maxCliqueSize(mp: MGraph[Double]): Int
Compute the size of the largest clique in the graph.
Compute the size of the largest clique in the graph.
- mp
the triangulated moralized graph whose maximum clique size is sought
-
def
orderVertices(g: MGraph[Double], mp: MGraph[Double]): (Array[Int], Array[Int])
Order the vertices and blocks in the graph.
Order the vertices and blocks in the graph.
- g
the graph built up from the spanning tree
- mp
the triangulated moralized graph
- See also
Algorithm 7
-
def
positiveEdges: Boolean
Determine whether positive scoring edges still exist.
- val stree: MinSpanningTree