← Documentation
ADS-IDAC Engine 5.0.0
compiler.hpp
Go to the documentation of this file.
1#pragma once
11#include <memory>
12#include <string>
13#include <vector>
14
15namespace bncore {
16
19public:
44 static std::unique_ptr<JunctionTree>
45 compile(const Graph &graph, const std::string &heuristic = "min_fill");
46
47private:
49 static std::vector<std::vector<NodeId>> moralize(const Graph &graph);
50};
51
52} // namespace bncore
Directed graphical model over discrete variables.
Definition: graph.hpp:28
Builds a junction tree from a Bayesian network graph.
Definition: compiler.hpp:18
static std::vector< std::vector< NodeId > > moralize(const Graph &graph)
Moral graph as adjacency lists indexed by NodeId, each sorted ascending.
Definition: compiler.cpp:18
static std::unique_ptr< JunctionTree > compile(const Graph &graph, const std::string &heuristic="min_fill")
Compiles a junction tree.
Definition: compiler.cpp:53
bncore::Graph, the discrete Bayesian network model: variables, their states, directed edges and condi...
Junction tree data structure of BNCore: Clique, Separator and the JunctionTree container.