33 # define IBNG IBayesNetGenerator 35 # define IBNG IBayesNetGenerator< GUM_SCALAR, ICPTGenerator > 39 template <
typename GUM_SCALAR,
template <
typename >
class ICPTGenerator >
43 IBNG(nbrNodes, maxArcs, maxModality) {
60 template <
typename GUM_SCALAR,
template <
typename >
class ICPTGenerator >
71 template <
typename GUM_SCALAR,
template <
typename >
class ICPTGenerator >
76 std::stringstream strBuff;
88 float density = (float)(this->
_maxArcs * 2)
Class representing a Bayesian Network.
Class for generating bayesian networks.
Idx randomValue(const Size max=2)
Returns a random Idx between 0 and max-1 included.
void fillCPT()
function that insert random values in the CPT of each nodes according to the CPTGenerator.
double randomProba()
Returns a random double between 0 and 1 included (i.e.
gum is the global namespace for all aGrUM entities
BayesNet< GUM_SCALAR > _bayesNet
<agrum/BN/generator/simpleBayesNetGenerator.h>
void generateBN(BayesNet< GUM_SCALAR > &bayesNet) override
function that generates a bayesian networks.
std::size_t Size
In aGrUM, hashed values are unsigned long int.
value_type & insert(const Key &key, const Val &val)
Adds a new element (actually a copy of this element) into the hash table.
SimpleBayesNetGenerator(Size nbrNodes, Size maxArcs, Size maxModality=2)
Constructor.
~SimpleBayesNetGenerator() override
Destructor.