![]() |
aGrUM 3.3.2
a C++ library for (probabilistic) graphical models
|
GibbsKL computes the KL divergence betweens 2 BNs using an approximation pattern: GIBBS sampling. More...
#include <GibbsBNdistance.h>
Public Types | |
| enum class | ApproximationSchemeSTATE : char { Undefined , Continue , Epsilon , Rate , Limit , TimeLimit , Stopped } |
| The different state of an approximation scheme. More... | |
Public Member Functions | |
| GibbsBNdistance (const IBayesNet< GUM_SCALAR > &P, const IBayesNet< GUM_SCALAR > &Q) | |
| constructor must give 2 BNs | |
| GibbsBNdistance (const BNdistance< GUM_SCALAR > &kl) | |
| copy constructor | |
| ~GibbsBNdistance () override | |
| destructor | |
| void | setBurnIn (Size b) |
| Number of burn in for one iteration. | |
| Size | burnIn () const |
| Returns the number of burn in. | |
| Complexity | difficulty () const |
| return KL::Complexity::Heavy,KL::Complexity::Difficult,KL::Complexity::Correct depending on the BNs p and q | |
| Size | nbrDrawnVar () const |
| Getters and setters. | |
| void | setNbrDrawnVar (Size nbr) |
| bool | isDrawnAtRandom () const |
| void | setDrawnAtRandom (bool atRandom) |
| Instantiation | monteCarloSample () |
| draws a first sample with a positive probability (starting point of a Gibbs chain) | |
| Instantiation | nextSample (Instantiation prev) |
| draws next sample of Gibbs sampling | |
Accessors to results. The first call do the computations. The | |
others do not. | |
| double | klPQ () |
| Size | errorPQ () |
| double | klQP () |
| Size | errorQP () |
| double | hellinger () |
| double | bhattacharya () |
| double | jsd () |
| const IBayesNet< GUM_SCALAR > & | p () const |
| const IBayesNet< GUM_SCALAR > & | q () const |
Getters and setters | |
| void | setEpsilon (double eps) override |
| Given that we approximate f(t), stopping criterion on |f(t+1)-f(t)|. | |
| double | epsilon () const override |
| Returns the value of epsilon. | |
| void | disableEpsilon () override |
| Disable stopping criterion on epsilon. | |
| void | enableEpsilon () override |
| Enable stopping criterion on epsilon. | |
| bool | isEnabledEpsilon () const override |
| Returns true if stopping criterion on epsilon is enabled, false otherwise. | |
| void | setMinEpsilonRate (double rate) override |
| Given that we approximate f(t), stopping criterion on d/dt(|f(t+1)-f(t)|). | |
| double | minEpsilonRate () const override |
| Returns the value of the minimal epsilon rate. | |
| void | disableMinEpsilonRate () override |
| Disable stopping criterion on epsilon rate. | |
| void | enableMinEpsilonRate () override |
| Enable stopping criterion on epsilon rate. | |
| bool | isEnabledMinEpsilonRate () const override |
| Returns true if stopping criterion on epsilon rate is enabled, false otherwise. | |
| void | setMaxIter (Size max) override |
| Stopping criterion on number of iterations. | |
| Size | maxIter () const override |
| Returns the criterion on number of iterations. | |
| void | disableMaxIter () override |
| Disable stopping criterion on max iterations. | |
| void | enableMaxIter () override |
| Enable stopping criterion on max iterations. | |
| bool | isEnabledMaxIter () const override |
| Returns true if stopping criterion on max iterations is enabled, false otherwise. | |
| void | setMaxTime (double timeout) override |
| Stopping criterion on timeout. | |
| double | maxTime () const override |
| Returns the timeout (in seconds). | |
| double | currentTime () const override |
| Returns the current running time in second. | |
| void | disableMaxTime () override |
| Disable stopping criterion on timeout. | |
| void | enableMaxTime () override |
| Enable stopping criterion on timeout. | |
| bool | isEnabledMaxTime () const override |
| Returns true if stopping criterion on timeout is enabled, false otherwise. | |
| void | setPeriodSize (Size p) override |
| How many samples between two stopping is enable. | |
| Size | periodSize () const override |
| Returns the period size. | |
| void | setVerbosity (bool v) override |
| Set the verbosity on (true) or off (false). | |
| bool | verbosity () const override |
| Returns true if verbosity is enabled. | |
| ApproximationSchemeSTATE | stateApproximationScheme () const override |
| Returns the approximation scheme state. | |
| Size | nbrIterations () const override |
| Returns the number of iterations. | |
| const std::vector< double > & | history () const override |
| Returns the scheme history. | |
| void | initApproximationScheme () |
| Initialise the scheme. | |
| bool | startOfPeriod () const |
| Returns true if we are at the beginning of a period (compute error is mandatory). | |
| void | updateApproximationScheme (unsigned int incr=1) |
| Update the scheme w.r.t the new error and increment steps. | |
| Size | remainingBurnIn () const |
| Returns the remaining burn in. | |
| void | stopApproximationScheme () |
| Stop the approximation scheme. | |
| bool | continueApproximationScheme (double error) |
| Update the scheme w.r.t the new error. | |
Getters and setters | |
| std::string | messageApproximationScheme () const |
| Returns the approximation scheme message. | |
Public Attributes | |
| Signaler< Size, double, double > | onProgress |
| Progression, error and time. | |
| Signaler< std::string_view > | onStop |
| Criteria messageApproximationScheme. | |
Protected Member Functions | |
| void | computeKL_ () final |
| void | process_ () |
| void | setFromConfiguration_ (const std::string §ion, bool withMaxTime, bool withVerbosity=true) |
| Set the parameters of the scheme from a section of gum::Configuration. | |
| void | updateSamplingNodes_ () |
Static Protected Member Functions | |
| static Size | sizeFromConfiguration_ (const std::string §ion, const std::string &key) |
| Read a non negative integer key of gum::Configuration. | |
Protected Attributes | |
| const IBayesNet< GUM_SCALAR > & | p_ |
| const IBayesNet< GUM_SCALAR > & | q_ |
| GUM_SCALAR | klPQ_ |
| GUM_SCALAR | klQP_ |
| Size | errorPQ_ |
| Size | errorQP_ |
| GUM_SCALAR | hellinger_ |
| GUM_SCALAR | bhattacharya_ |
| GUM_SCALAR | jsd_ |
| double | current_epsilon_ {-1.} |
| Current epsilon. | |
| double | last_epsilon_ {-1.} |
| Last epsilon value. | |
| double | current_rate_ {-1.} |
| Current rate. | |
| Size | current_step_ {0} |
| The current step. | |
| Timer | timer_ |
| The timer. | |
| ApproximationSchemeSTATE | current_state_ |
| The current state. | |
| std::vector< double > | history_ |
| The scheme history, used only if verbosity == true. | |
| double | eps_ |
| Threshold for convergence. | |
| bool | enabled_eps_ |
| If true, the threshold convergence is enabled. | |
| double | min_rate_eps_ |
| Threshold for the epsilon rate. | |
| bool | enabled_min_rate_eps_ |
| If true, the minimal threshold for epsilon rate is enabled. | |
| double | max_time_ |
| The timeout. | |
| bool | enabled_max_time_ |
| If true, the timeout is enabled. | |
| Size | max_iter_ |
| The maximum iterations. | |
| bool | enabled_max_iter_ |
| If true, the maximum iterations stopping criterion is enabled. | |
| Size | burn_in_ |
| Number of iterations before checking stopping criteria. | |
| Size | period_size_ |
| Checking criteria frequency. | |
| bool | verbosity_ |
| If true, verbosity is enabled. | |
| Size | counting_ |
| const IBayesNet< GUM_SCALAR > & | samplingBn_ |
| const NodeProperty< Idx > * | hardEv_ |
| Sequence< NodeId > | samplingNodes_ |
| Size | nbr_ |
| bool | atRandom_ |
Private Member Functions | |
| bool | _checkCompatibility_ () const |
| void | stopScheme_ (ApproximationSchemeSTATE new_state) |
| Stop the scheme given a new state. | |
| bool | _pruneDomains_ () |
| void | _mask_ (NodeId node, Tensor< GUM_SCALAR > &p) const |
| Instantiation | _forwardSample_ () |
| void | _drawVarMonteCarlo_ (NodeId nod, Instantiation *I) |
| bool | _isCompatible_ (const Instantiation &I) const |
| void | _smoothedGibbsSample_ (NodeId id, Instantiation *I, GUM_SCALAR epsilon) |
| void | _GibbsSample_ (NodeId id, Instantiation *I) |
| change in Instantiation I a new drawn value for id | |
Private Attributes | |
| Complexity | _difficulty_ |
| bool | _done_ |
| NodeProperty< std::vector< bool > > | _allowed_ |
| the values of each node that may belong to a sample with a positive probability | |
| NodeProperty< GUM_SCALAR > | _minNonZero_ |
| the smallest positive probability of the CPT of each node (for the smoothed Gibbs moves) | |
Static Private Attributes | |
| static constexpr Size | _nbrRejectionTries_ = 100 |
| number of forward samples drawn before searching a compatible sample by smoothed Gibbs moves | |
| static constexpr Size | _nbrSmoothingRestarts_ = 10 |
| number of restarts (from a new forward sample) of the smoothed Gibbs moves | |
| static constexpr std::array< double, 4 > | _smoothingLevels_ = {1e-3, 1e-2, 1e-1, 0.5} |
| growing smoothing levels: a null probability is replaced by epsilon times the smallest positive probability of its CPT | |
| static constexpr Size | _nbrSweepsBySmoothingLevel_ = 50 |
| maximal number of sweeps (over the non-evidence nodes) for each smoothing level | |
GibbsKL computes the KL divergence betweens 2 BNs using an approximation pattern: GIBBS sampling.
KL.process() computes KL(P||Q) using klPQ() and KL(Q||P) using klQP(). The computations are made once. The second is for free :) GibbsKL allows as well to compute in the same time the Hellinger distance ( \(*\sqrt{\sum_i (\sqrt{p_i}-\sqrt{q_i})^2}\)) (Kokolakis and Nanopoulos, 2001) and Bhattacharya distance (Kaylath,T. 1967)
It may happen that P*ln(P/Q) is not computable (Q=0 and P!=0). In such a case, KL keeps working but trace this error (errorPQ() and errorQP()). In those cases, Hellinger distance approximation is under-evaluated.
snippets :
Definition at line 96 of file GibbsBNdistance.h.
|
stronginherited |
The different state of an approximation scheme.
| Enumerator | |
|---|---|
| Undefined | |
| Continue | |
| Epsilon | |
| Rate | |
| Limit | |
| TimeLimit | |
| Stopped | |
Definition at line 87 of file IApproximationSchemeConfiguration.h.
| gum::GibbsBNdistance< GUM_SCALAR >::GibbsBNdistance | ( | const IBayesNet< GUM_SCALAR > & | P, |
| const IBayesNet< GUM_SCALAR > & | Q ) |
constructor must give 2 BNs
| gum::OperationNotAllowed | if the 2 BNs have not the same domainSize or compatible node sets. |
Definition at line 63 of file GibbsBNdistance_tpl.h.
References gum::ApproximationScheme::ApproximationScheme(), gum::BNdistance< GUM_SCALAR >::BNdistance(), GibbsBNdistance(), gum::GibbsOperator< GUM_SCALAR >::GibbsOperator(), and gum::ApproximationScheme::setFromConfiguration_().
Referenced by GibbsBNdistance(), GibbsBNdistance(), and ~GibbsBNdistance().
|
explicit |
copy constructor
Definition at line 73 of file GibbsBNdistance_tpl.h.
References gum::ApproximationScheme::ApproximationScheme(), gum::BNdistance< GUM_SCALAR >::BNdistance(), GibbsBNdistance(), gum::GibbsOperator< GUM_SCALAR >::GibbsOperator(), gum::BNdistance< GUM_SCALAR >::p(), and gum::ApproximationScheme::setFromConfiguration_().
|
override |
destructor
Definition at line 82 of file GibbsBNdistance_tpl.h.
References GibbsBNdistance().
|
privateinherited |
Definition at line 145 of file BNdistance_tpl.h.
References GUM_ERROR, gum::Variable::name(), p_, q_, and gum::DiscreteVariable::toString().
Referenced by BNdistance().
|
privateinherited |
Definition at line 287 of file gibbsOperator_tpl.h.
References _mask_(), gum::Instantiation::chgVal(), gum::Instantiation::erase(), and samplingBn_.
Referenced by _forwardSample_().
|
privateinherited |
Definition at line 153 of file gibbsOperator_tpl.h.
References _drawVarMonteCarlo_(), gum::Instantiation::add(), gum::Instantiation::chgVal(), hardEv_, and samplingBn_.
Referenced by monteCarloSample().
|
privateinherited |
change in Instantiation I a new drawn value for id
Definition at line 312 of file gibbsOperator_tpl.h.
References gum::Instantiation::chgVal(), gum::Tensor< GUM_SCALAR >::draw(), gum::Instantiation::erase(), gum::Tensor< GUM_SCALAR >::extract(), gum::MultiDimDecorator< GUM_ELEMENT >::nbrDim(), gum::Tensor< GUM_SCALAR >::normalize(), samplingBn_, and gum::Tensor< GUM_SCALAR >::sum().
Referenced by nextSample().
|
privateinherited |
Definition at line 168 of file gibbsOperator_tpl.h.
References samplingBn_.
Referenced by monteCarloSample().
|
privateinherited |
Definition at line 278 of file gibbsOperator_tpl.h.
References _allowed_, gum::Instantiation::end(), gum::Instantiation::inc(), gum::Instantiation::setFirst(), and gum::Instantiation::val().
Referenced by _drawVarMonteCarlo_(), and _smoothedGibbsSample_().
|
privateinherited |
Definition at line 198 of file gibbsOperator_tpl.h.
References _allowed_, gum::Set< Key >::contains(), gum::Instantiation::end(), gum::Set< Key >::erase(), hardEv_, gum::Instantiation::inc(), gum::Set< Key >::insert(), samplingBn_, gum::Instantiation::setFirst(), and gum::Instantiation::val().
Referenced by monteCarloSample().
|
privateinherited |
Definition at line 175 of file gibbsOperator_tpl.h.
References _mask_(), _minNonZero_, gum::Instantiation::chgVal(), gum::Tensor< GUM_SCALAR >::draw(), gum::Instantiation::end(), gum::Instantiation::erase(), gum::Instantiation::inc(), gum::Tensor< GUM_SCALAR >::normalize(), samplingBn_, and gum::Instantiation::setFirst().
Referenced by monteCarloSample().
|
inherited |
Definition at line 110 of file BNdistance_tpl.h.
References bhattacharya_, and process_().
| Size gum::GibbsBNdistance< GUM_SCALAR >::burnIn | ( | ) | const |
Returns the number of burn in.
Definition at line 175 of file GibbsBNdistance_tpl.h.
References gum::ApproximationScheme::burn_in_.
Referenced by computeKL_().
|
finalprotectedvirtual |
Reimplemented from gum::BNdistance< GUM_SCALAR >.
Definition at line 87 of file GibbsBNdistance_tpl.h.
References gum::BNdistance< GUM_SCALAR >::bhattacharya_, burnIn(), gum::ApproximationScheme::continueApproximationScheme(), gum::ApproximationScheme::disableMinEpsilonRate(), gum::ApproximationScheme::enableMinEpsilonRate(), gum::BNdistance< GUM_SCALAR >::errorPQ_, gum::BNdistance< GUM_SCALAR >::errorQP_, gum::BNdistance< GUM_SCALAR >::hellinger_, gum::ApproximationScheme::initApproximationScheme(), gum::HashTable< Key, Val >::insert(), gum::ApproximationScheme::isEnabledMinEpsilonRate(), gum::BNdistance< GUM_SCALAR >::jsd_, gum::BNdistance< GUM_SCALAR >::klPQ_, gum::BNdistance< GUM_SCALAR >::klQP_, gum::GibbsOperator< GUM_SCALAR >::monteCarloSample(), gum::Variable::name(), gum::Instantiation::nbrDim(), gum::ApproximationScheme::nbrIterations(), gum::GibbsOperator< GUM_SCALAR >::nextSample(), gum::BNdistance< GUM_SCALAR >::p_, gum::BNdistance< GUM_SCALAR >::q_, gum::ApproximationScheme::updateApproximationScheme(), gum::GibbsOperator< GUM_SCALAR >::updateSamplingNodes_(), and gum::Instantiation::variable().
Update the scheme w.r.t the new error.
Test the stopping criterion that are enabled.
| error | The new error value. |
| OperationNotAllowed | Raised if state != ApproximationSchemeSTATE::Continue. |
Definition at line 107 of file approximationScheme.cpp.
References gum::IApproximationSchemeConfiguration::Continue, current_epsilon_, current_rate_, current_state_, current_step_, enabled_eps_, enabled_max_iter_, enabled_max_time_, enabled_min_rate_eps_, eps_, gum::IApproximationSchemeConfiguration::Epsilon, GUM_EMIT3, GUM_ERROR, gum::__sig__::BasicSignaler< Args... >::hasListener(), history_, last_epsilon_, gum::IApproximationSchemeConfiguration::Limit, max_iter_, max_time_, gum::IApproximationSchemeConfiguration::messageApproximationScheme(), min_rate_eps_, gum::IApproximationSchemeConfiguration::onProgress, gum::IApproximationSchemeConfiguration::Rate, startOfPeriod(), stateApproximationScheme(), gum::Timer::step(), stopScheme_(), gum::IApproximationSchemeConfiguration::TimeLimit, timer_, and verbosity().
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::learning::GreedyHillClimbing::learnStructure(), gum::learning::GreedyThickThinning::learnStructure(), gum::learning::LocalSearchWithTabuList::learnStructure(), gum::SamplingInference< GUM_SCALAR >::loopApproxInference_(), gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInferenceByOrderedArcs_(), gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInferenceByRandomOrder_(), and gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInferenceNodeToNeighbours_().
|
overridevirtualinherited |
Returns the current running time in second.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 137 of file approximationScheme_inl.h.
References gum::Timer::step(), and timer_.
Referenced by gum::learning::IBNLearner::currentTime(), and gum::learning::IBNLearner::EMCurrentTime().
|
inherited |
return KL::Complexity::Heavy,KL::Complexity::Difficult,KL::Complexity::Correct depending on the BNs p and q
Definition at line 87 of file BNdistance_tpl.h.
References _difficulty_.
|
overridevirtualinherited |
Disable stopping criterion on epsilon.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 75 of file approximationScheme_inl.h.
References enabled_eps_.
Referenced by gum::learning::EMApproximationScheme::EMApproximationScheme(), gum::learning::LocalSearchWithTabuList::LocalSearchWithTabuList(), gum::learning::IBNLearner::disableEpsilon(), gum::learning::IBNLearner::EMdisableEpsilon(), gum::SamplingInference< GUM_SCALAR >::loopApproxInference_(), and gum::learning::EMApproximationScheme::setMinEpsilonRate().
|
overridevirtualinherited |
Disable stopping criterion on max iterations.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 116 of file approximationScheme_inl.h.
References enabled_max_iter_.
Referenced by gum::learning::GreedyHillClimbing::GreedyHillClimbing(), gum::learning::GreedyThickThinning::GreedyThickThinning(), gum::learning::LocalSearchWithTabuList::LocalSearchWithTabuList(), gum::learning::IBNLearner::disableMaxIter(), and gum::learning::IBNLearner::EMdisableMaxIter().
|
overridevirtualinherited |
Disable stopping criterion on timeout.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 140 of file approximationScheme_inl.h.
References enabled_max_time_.
Referenced by ApproximationScheme(), gum::learning::GreedyHillClimbing::GreedyHillClimbing(), gum::learning::GreedyThickThinning::GreedyThickThinning(), gum::learning::LocalSearchWithTabuList::LocalSearchWithTabuList(), gum::learning::IBNLearner::disableMaxTime(), and gum::learning::IBNLearner::EMdisableMaxTime().
|
overridevirtualinherited |
Disable stopping criterion on epsilon rate.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 96 of file approximationScheme_inl.h.
References enabled_min_rate_eps_.
Referenced by gum::learning::GreedyHillClimbing::GreedyHillClimbing(), gum::learning::GreedyThickThinning::GreedyThickThinning(), gum::learning::LocalSearchWithTabuList::LocalSearchWithTabuList(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::learning::IBNLearner::disableMinEpsilonRate(), gum::learning::IBNLearner::EMdisableMinEpsilonRate(), gum::SamplingInference< GUM_SCALAR >::loopApproxInference_(), and gum::learning::EMApproximationScheme::setEpsilon().
|
overridevirtualinherited |
Enable stopping criterion on epsilon.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 78 of file approximationScheme_inl.h.
References enabled_eps_.
Referenced by gum::learning::IBNLearner::EMenableEpsilon(), gum::learning::IBNLearner::enableEpsilon(), and gum::SamplingInference< GUM_SCALAR >::loopApproxInference_().
|
overridevirtualinherited |
Enable stopping criterion on max iterations.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 119 of file approximationScheme_inl.h.
References enabled_max_iter_.
Referenced by gum::learning::IBNLearner::EMenableMaxIter(), and gum::learning::IBNLearner::enableMaxIter().
|
overridevirtualinherited |
Enable stopping criterion on timeout.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 143 of file approximationScheme_inl.h.
References enabled_max_time_.
Referenced by gum::learning::IBNLearner::EMenableMaxTime(), and gum::learning::IBNLearner::enableMaxTime().
|
overridevirtualinherited |
Enable stopping criterion on epsilon rate.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 99 of file approximationScheme_inl.h.
References enabled_min_rate_eps_.
Referenced by gum::learning::EMApproximationScheme::EMApproximationScheme(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::learning::IBNLearner::EMenableMinEpsilonRate(), gum::learning::IBNLearner::enableMinEpsilonRate(), and gum::SamplingInference< GUM_SCALAR >::loopApproxInference_().
|
overridevirtualinherited |
Returns the value of epsilon.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 72 of file approximationScheme_inl.h.
References eps_.
Referenced by gum::credal::MultipleInferenceEngine< GUM_SCALAR, BNInferenceEngine >::_updateThreadCredalSets_(), gum::learning::IBNLearner::EMEpsilon(), gum::learning::IBNLearner::epsilon(), gum::SamplingInference< GUM_SCALAR >::loopApproxInference_(), gum::ImportanceSampling< GUM_SCALAR >::onContextualize_(), gum::ImportanceSampling< GUM_SCALAR >::unsharpenBN_(), and gum::credal::InferenceEngine< GUM_SCALAR >::updateCredalSets_().
|
inherited |
Definition at line 122 of file BNdistance_tpl.h.
References errorPQ_, and process_().
|
inherited |
Definition at line 128 of file BNdistance_tpl.h.
References errorQP_, and process_().
|
inherited |
Definition at line 104 of file BNdistance_tpl.h.
References hellinger_, and process_().
|
overridevirtualinherited |
Returns the scheme history.
| OperationNotAllowed | Raised if the scheme did not performed or if verbosity is set to false. |
Implements gum::IApproximationSchemeConfiguration.
Definition at line 179 of file approximationScheme_inl.h.
References GUM_ERROR, history_, stateApproximationScheme(), gum::IApproximationSchemeConfiguration::Undefined, and verbosity().
Referenced by gum::learning::IBNLearner::EMHistory(), and gum::learning::IBNLearner::history().
|
inherited |
Initialise the scheme.
Definition at line 190 of file approximationScheme_inl.h.
References gum::IApproximationSchemeConfiguration::Continue, current_epsilon_, current_rate_, current_state_, current_step_, history_, gum::Timer::reset(), and timer_.
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::learning::GreedyHillClimbing::learnStructure(), gum::learning::GreedyThickThinning::learnStructure(), gum::learning::LocalSearchWithTabuList::learnStructure(), gum::SamplingInference< GUM_SCALAR >::loopApproxInference_(), gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInference(), and gum::SamplingInference< GUM_SCALAR >::onStateChanged_().
|
inherited |
|
overridevirtualinherited |
Returns true if stopping criterion on epsilon is enabled, false otherwise.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 82 of file approximationScheme_inl.h.
References enabled_eps_.
Referenced by gum::learning::IBNLearner::EMisEnabledEpsilon(), gum::learning::IBNLearner::isEnabledEpsilon(), and gum::SamplingInference< GUM_SCALAR >::loopApproxInference_().
|
overridevirtualinherited |
Returns true if stopping criterion on max iterations is enabled, false otherwise.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 123 of file approximationScheme_inl.h.
References enabled_max_iter_.
Referenced by gum::learning::IBNLearner::EMisEnabledMaxIter(), and gum::learning::IBNLearner::isEnabledMaxIter().
|
overridevirtualinherited |
Returns true if stopping criterion on timeout is enabled, false otherwise.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 147 of file approximationScheme_inl.h.
References enabled_max_time_.
Referenced by gum::learning::IBNLearner::EMisEnabledMaxTime(), and gum::learning::IBNLearner::isEnabledMaxTime().
|
overridevirtualinherited |
Returns true if stopping criterion on epsilon rate is enabled, false otherwise.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 103 of file approximationScheme_inl.h.
References enabled_min_rate_eps_.
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::learning::IBNLearner::EMisEnabledMinEpsilonRate(), gum::learning::IBNLearner::isEnabledMinEpsilonRate(), and gum::SamplingInference< GUM_SCALAR >::loopApproxInference_().
|
inherited |
Definition at line 116 of file BNdistance_tpl.h.
References jsd_, and process_().
|
inherited |
Definition at line 92 of file BNdistance_tpl.h.
References klPQ_, and process_().
|
inherited |
Definition at line 98 of file BNdistance_tpl.h.
References klQP_, and process_().
|
overridevirtualinherited |
Returns the criterion on number of iterations.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 113 of file approximationScheme_inl.h.
References max_iter_.
Referenced by gum::learning::IBNLearner::EMMaxIter(), and gum::learning::IBNLearner::maxIter().
|
overridevirtualinherited |
Returns the timeout (in seconds).
Implements gum::IApproximationSchemeConfiguration.
Definition at line 134 of file approximationScheme_inl.h.
References max_time_.
Referenced by gum::learning::IBNLearner::EMMaxTime(), and gum::learning::IBNLearner::maxTime().
|
inherited |
Returns the approximation scheme message.
Definition at line 64 of file IApproximationSchemeConfiguration.cpp.
References Continue, Epsilon, epsilon(), Limit, maxIter(), maxTime(), minEpsilonRate(), Rate, stateApproximationScheme(), Stopped, TimeLimit, and Undefined.
Referenced by gum::ApproximationScheme::continueApproximationScheme(), gum::learning::IBNLearner::EMStateMessage(), and gum::credal::InferenceEngine< GUM_SCALAR >::getApproximationSchemeMsg().
|
overridevirtualinherited |
Returns the value of the minimal epsilon rate.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 93 of file approximationScheme_inl.h.
References min_rate_eps_.
Referenced by gum::learning::IBNLearner::EMMinEpsilonRate(), and gum::learning::IBNLearner::minEpsilonRate().
|
inherited |
draws a first sample with a positive probability (starting point of a Gibbs chain)
From a sample with a null probability, every Gibbs move may have a null mass: the chain would never leave it. Hence the search for a sample with a positive probability, which is a constraint satisfaction problem (NP-hard in general). The search is heuristic:
Limits: arc consistency is not complete (it may not detect an incompatibility involving several CPTs together, e.g. a parity constraint over a chain of XOR), and the search is stochastic and bounded. Hence, when the compatible samples are very rare (long chains of deterministic constraints, several deterministic plateaus), the search may fail even though such a sample exists, and the result may depend on the random seed. OperationNotAllowed then means "not found", not "does not exist". An exact inference (e.g. LazyPropagation) can decide whether the evidence is compatible (evidence probability > 0).
| IncompatibleEvidence | if the pruning proves that the evidence has a null probability |
| OperationNotAllowed | if no sample with a positive probability is found |
Definition at line 105 of file gibbsOperator_tpl.h.
References _forwardSample_(), _isCompatible_(), _minNonZero_, _nbrRejectionTries_, _nbrSmoothingRestarts_, _nbrSweepsBySmoothingLevel_, _pruneDomains_(), _smoothedGibbsSample_(), _smoothingLevels_, GUM_ERROR, hardEv_, and samplingBn_.
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), and gum::GibbsSampling< GUM_SCALAR >::monteCarloSample_().
|
inherited |
|
overridevirtualinherited |
Returns the number of iterations.
| OperationNotAllowed | Raised if the scheme did not perform. |
Implements gum::IApproximationSchemeConfiguration.
Definition at line 170 of file approximationScheme_inl.h.
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::learning::IBNLearner::EMnbrIterations(), and gum::learning::IBNLearner::nbrIterations().
|
inherited |
draws next sample of Gibbs sampling
Definition at line 299 of file gibbsOperator_tpl.h.
References _GibbsSample_(), atRandom_, counting_, nbr_, gum::randomValue(), and samplingNodes_.
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), and gum::GibbsSampling< GUM_SCALAR >::draw_().
|
inherited |
Definition at line 134 of file BNdistance_tpl.h.
References p_.
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::GibbsBNdistance().
|
overridevirtualinherited |
Returns the period size.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 156 of file approximationScheme_inl.h.
References period_size_.
Referenced by gum::learning::IBNLearner::EMPeriodSize(), and gum::learning::IBNLearner::periodSize().
|
protectedinherited |
Definition at line 177 of file BNdistance_tpl.h.
References _done_, and computeKL_().
Referenced by bhattacharya(), errorPQ(), errorQP(), hellinger(), jsd(), klPQ(), and klQP().
|
inherited |
|
inherited |
Returns the remaining burn in.
Definition at line 213 of file approximationScheme_inl.h.
| void gum::GibbsBNdistance< GUM_SCALAR >::setBurnIn | ( | Size | b | ) |
Number of burn in for one iteration.
| b | The number of burn in. |
| OutOfBounds | Raised if b < 1. |
Definition at line 170 of file GibbsBNdistance_tpl.h.
References gum::ApproximationScheme::burn_in_.
|
inherited |
Definition at line 341 of file gibbsOperator_tpl.h.
References atRandom_.
|
overridevirtualinherited |
Given that we approximate f(t), stopping criterion on |f(t+1)-f(t)|.
If the criterion was disabled it will be enabled.
| eps | The new epsilon value. |
| OutOfBounds | Raised if eps < 0. |
Implements gum::IApproximationSchemeConfiguration.
Reimplemented in gum::learning::EMApproximationScheme.
Definition at line 64 of file approximationScheme_inl.h.
References enabled_eps_, eps_, and GUM_ERROR.
Referenced by gum::GibbsSampling< GUM_SCALAR >::GibbsSampling(), gum::learning::GreedyHillClimbing::GreedyHillClimbing(), gum::learning::GreedyThickThinning::GreedyThickThinning(), gum::learning::EMApproximationScheme::setEpsilon(), gum::learning::IBNLearner::setEpsilon(), and setFromConfiguration_().
|
protectedinherited |
Set the parameters of the scheme from a section of gum::Configuration.
The keys epsilon, minEpsilonRate, maxIter and periodSize of the section are read (and maxTime if withMaxTime is true, verbosity if withVerbosity is true, burnIn if the section has this key) and applied through the corresponding setters, which enable the matching stopping criteria and check the values.
| section | The name of the section of the configuration. |
| withMaxTime | If true, the key maxTime is read and the timeout is enabled. |
| withVerbosity | If true, the key verbosity is read ; otherwise the verbosity is left unchanged. |
| OutOfBounds | Raised if a value of the section is not valid for its setter. |
Definition at line 90 of file approximationScheme.cpp.
References burn_in_, gum::Configuration::instance(), setEpsilon(), setMaxIter(), setMaxTime(), setMinEpsilonRate(), setPeriodSize(), setVerbosity(), and sizeFromConfiguration_().
Referenced by ApproximationScheme(), gum::GibbsBNdistance< GUM_SCALAR >::GibbsBNdistance(), gum::GibbsBNdistance< GUM_SCALAR >::GibbsBNdistance(), gum::MCBNDistance< GUM_SCALAR >::MCBNDistance(), gum::MCBNDistance< GUM_SCALAR >::MCBNDistance(), and gum::SamplingInference< GUM_SCALAR >::SamplingInference().
|
overridevirtualinherited |
Stopping criterion on number of iterations.
If the criterion was disabled it will be enabled.
| max | The maximum number of iterations. |
| OutOfBounds | Raised if max <= 1. |
Implements gum::IApproximationSchemeConfiguration.
Definition at line 106 of file approximationScheme_inl.h.
References enabled_max_iter_, GUM_ERROR, and max_iter_.
Referenced by gum::learning::IBNLearner::EMsetMaxIter(), setFromConfiguration_(), and gum::learning::IBNLearner::setMaxIter().
|
overridevirtualinherited |
Stopping criterion on timeout.
If the criterion was disabled it will be enabled.
| timeout | The timeout value in seconds. |
| OutOfBounds | Raised if timeout <= 0.0. |
Implements gum::IApproximationSchemeConfiguration.
Definition at line 127 of file approximationScheme_inl.h.
References enabled_max_time_, GUM_ERROR, and max_time_.
Referenced by gum::learning::IBNLearner::EMsetMaxTime(), setFromConfiguration_(), and gum::learning::IBNLearner::setMaxTime().
|
overridevirtualinherited |
Given that we approximate f(t), stopping criterion on d/dt(|f(t+1)-f(t)|).
If the criterion was disabled it will be enabled
| rate | The minimal epsilon rate. |
| OutOfBounds | if rate<0 |
Implements gum::IApproximationSchemeConfiguration.
Reimplemented in gum::learning::EMApproximationScheme.
Definition at line 85 of file approximationScheme_inl.h.
References enabled_min_rate_eps_, GUM_ERROR, and min_rate_eps_.
Referenced by gum::GibbsSampling< GUM_SCALAR >::GibbsSampling(), setFromConfiguration_(), gum::learning::EMApproximationScheme::setMinEpsilonRate(), and gum::learning::IBNLearner::setMinEpsilonRate().
|
inherited |
|
overridevirtualinherited |
How many samples between two stopping is enable.
| p | The new period value. |
| OutOfBounds | Raised if p < 1. |
Implements gum::IApproximationSchemeConfiguration.
Definition at line 150 of file approximationScheme_inl.h.
References GUM_ERROR, and period_size_.
Referenced by gum::learning::IBNLearner::EMsetPeriodSize(), setFromConfiguration_(), and gum::learning::IBNLearner::setPeriodSize().
|
overridevirtualinherited |
Set the verbosity on (true) or off (false).
| v | If true, then verbosity is turned on. |
Implements gum::IApproximationSchemeConfiguration.
Definition at line 159 of file approximationScheme_inl.h.
References verbosity_.
Referenced by gum::learning::IBNLearner::EMsetVerbosity(), setFromConfiguration_(), and gum::learning::IBNLearner::setVerbosity().
|
staticprotectedinherited |
Read a non negative integer key of gum::Configuration.
| section | The name of the section of the configuration. |
| key | The name of the key of the section. |
| OutOfBounds | Raised if the value is negative. |
Definition at line 79 of file approximationScheme.cpp.
References GUM_ERROR, gum::Configuration::instance(), and gum::Configuration::typed().
Referenced by gum::GibbsSampling< GUM_SCALAR >::GibbsSampling(), and setFromConfiguration_().
|
inherited |
Returns true if we are at the beginning of a period (compute error is mandatory).
Definition at line 200 of file approximationScheme_inl.h.
Referenced by continueApproximationScheme().
|
overridevirtualinherited |
Returns the approximation scheme state.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 165 of file approximationScheme_inl.h.
Referenced by continueApproximationScheme(), gum::learning::IBNLearner::EMState(), gum::learning::IBNLearner::EMStateApproximationScheme(), history(), and gum::learning::IBNLearner::stateApproximationScheme().
|
inherited |
Stop the approximation scheme.
Definition at line 222 of file approximationScheme_inl.h.
References gum::IApproximationSchemeConfiguration::Continue, and current_state_.
Referenced by gum::learning::GreedyHillClimbing::learnStructure(), gum::learning::GreedyThickThinning::learnStructure(), gum::learning::LocalSearchWithTabuList::learnStructure(), and gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInferenceNodeToNeighbours_().
|
privateinherited |
Stop the scheme given a new state.
| new_state | The scheme new state. |
Definition at line 231 of file approximationScheme_inl.h.
References gum::IApproximationSchemeConfiguration::Continue, and gum::IApproximationSchemeConfiguration::Undefined.
Referenced by continueApproximationScheme().
|
inherited |
Update the scheme w.r.t the new error and increment steps.
| incr | The new increment steps. |
Definition at line 209 of file approximationScheme_inl.h.
References current_step_.
Referenced by gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::learning::GreedyHillClimbing::learnStructure(), gum::learning::GreedyThickThinning::learnStructure(), gum::learning::LocalSearchWithTabuList::learnStructure(), gum::SamplingInference< GUM_SCALAR >::loopApproxInference_(), gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInferenceByOrderedArcs_(), gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInferenceByRandomOrder_(), and gum::credal::CNLoopyPropagation< GUM_SCALAR >::makeInferenceNodeToNeighbours_().
|
protectedinherited |
Definition at line 93 of file gibbsOperator_tpl.h.
References GUM_ERROR, hardEv_, nbr_, samplingBn_, and samplingNodes_.
Referenced by gum::GibbsSampling< GUM_SCALAR >::burnIn_(), and gum::GibbsBNdistance< GUM_SCALAR >::computeKL_().
|
overridevirtualinherited |
Returns true if verbosity is enabled.
Implements gum::IApproximationSchemeConfiguration.
Definition at line 161 of file approximationScheme_inl.h.
Referenced by ApproximationScheme(), gum::learning::EMApproximationScheme::EMApproximationScheme(), continueApproximationScheme(), gum::learning::IBNLearner::EMVerbosity(), history(), and gum::learning::IBNLearner::verbosity().
|
privateinherited |
the values of each node that may belong to a sample with a positive probability
Definition at line 166 of file gibbsOperator.h.
Referenced by _mask_(), and _pruneDomains_().
|
privateinherited |
Definition at line 171 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), and difficulty().
|
privateinherited |
Definition at line 172 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), and process_().
|
privateinherited |
the smallest positive probability of the CPT of each node (for the smoothed Gibbs moves)
Definition at line 169 of file gibbsOperator.h.
Referenced by _smoothedGibbsSample_(), and monteCarloSample().
|
staticconstexprprivateinherited |
number of forward samples drawn before searching a compatible sample by smoothed Gibbs moves
Definition at line 153 of file gibbsOperator.h.
Referenced by monteCarloSample().
|
staticconstexprprivateinherited |
number of restarts (from a new forward sample) of the smoothed Gibbs moves
Definition at line 156 of file gibbsOperator.h.
Referenced by monteCarloSample().
|
staticconstexprprivateinherited |
maximal number of sweeps (over the non-evidence nodes) for each smoothing level
Definition at line 163 of file gibbsOperator.h.
Referenced by monteCarloSample().
|
staticconstexprprivateinherited |
growing smoothing levels: a null probability is replaced by epsilon times the smallest positive probability of its CPT
Definition at line 160 of file gibbsOperator.h.
Referenced by monteCarloSample().
|
protectedinherited |
Definition at line 147 of file gibbsOperator.h.
Referenced by GibbsOperator(), isDrawnAtRandom(), nextSample(), and setDrawnAtRandom().
|
protectedinherited |
Definition at line 166 of file BNdistance.h.
Referenced by bhattacharya(), gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), and gum::MCBNDistance< GUM_SCALAR >::computeKL_().
|
protectedinherited |
Number of iterations before checking stopping criteria.
Definition at line 464 of file approximationScheme.h.
Referenced by ApproximationScheme(), gum::GibbsBNdistance< GUM_SCALAR >::burnIn(), gum::GibbsSampling< GUM_SCALAR >::burnIn(), gum::GibbsBNdistance< GUM_SCALAR >::setBurnIn(), gum::GibbsSampling< GUM_SCALAR >::setBurnIn(), and setFromConfiguration_().
|
protectedinherited |
Definition at line 141 of file gibbsOperator.h.
Referenced by GibbsOperator(), and nextSample().
|
protectedinherited |
Current epsilon.
Definition at line 419 of file approximationScheme.h.
Referenced by continueApproximationScheme(), and initApproximationScheme().
|
protectedinherited |
Current rate.
Definition at line 425 of file approximationScheme.h.
Referenced by continueApproximationScheme(), and initApproximationScheme().
|
protectedinherited |
The current state.
Definition at line 434 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), initApproximationScheme(), and stopApproximationScheme().
|
protectedinherited |
The current step.
Definition at line 428 of file approximationScheme.h.
Referenced by continueApproximationScheme(), initApproximationScheme(), gum::learning::Miic::initiation_(), gum::learning::Miic::iteration_(), gum::learning::Miic::learnMixedStructure(), gum::learning::Miic::learnSkeleton(), gum::learning::Miic::orientationMiic_(), and updateApproximationScheme().
|
protectedinherited |
If true, the threshold convergence is enabled.
Definition at line 443 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), disableEpsilon(), enableEpsilon(), isEnabledEpsilon(), and setEpsilon().
|
protectedinherited |
If true, the maximum iterations stopping criterion is enabled.
Definition at line 461 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), disableMaxIter(), enableMaxIter(), isEnabledMaxIter(), and setMaxIter().
|
protectedinherited |
If true, the timeout is enabled.
Definition at line 455 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), disableMaxTime(), enableMaxTime(), isEnabledMaxTime(), and setMaxTime().
|
protectedinherited |
If true, the minimal threshold for epsilon rate is enabled.
Definition at line 449 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), disableMinEpsilonRate(), enableMinEpsilonRate(), isEnabledMinEpsilonRate(), and setMinEpsilonRate().
|
protectedinherited |
Threshold for convergence.
Definition at line 440 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), epsilon(), and setEpsilon().
|
protectedinherited |
Definition at line 162 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), and errorPQ().
|
protectedinherited |
Definition at line 163 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), and errorQP().
|
protectedinherited |
Definition at line 143 of file gibbsOperator.h.
Referenced by GibbsOperator(), _forwardSample_(), _pruneDomains_(), monteCarloSample(), and updateSamplingNodes_().
|
protectedinherited |
Definition at line 165 of file BNdistance.h.
Referenced by gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), and hellinger().
|
protectedinherited |
The scheme history, used only if verbosity == true.
Definition at line 437 of file approximationScheme.h.
Referenced by continueApproximationScheme(), history(), and initApproximationScheme().
|
protectedinherited |
Definition at line 167 of file BNdistance.h.
Referenced by gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), and jsd().
|
protectedinherited |
Definition at line 159 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), and klPQ().
|
protectedinherited |
Definition at line 160 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), and klQP().
|
protectedinherited |
Last epsilon value.
Definition at line 422 of file approximationScheme.h.
Referenced by continueApproximationScheme().
|
protectedinherited |
The maximum iterations.
Definition at line 458 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), maxIter(), and setMaxIter().
|
protectedinherited |
The timeout.
Definition at line 452 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), maxTime(), and setMaxTime().
|
protectedinherited |
Threshold for the epsilon rate.
Definition at line 446 of file approximationScheme.h.
Referenced by ApproximationScheme(), continueApproximationScheme(), minEpsilonRate(), and setMinEpsilonRate().
|
protectedinherited |
Definition at line 146 of file gibbsOperator.h.
Referenced by GibbsOperator(), nbrDrawnVar(), nextSample(), setNbrDrawnVar(), and updateSamplingNodes_().
Progression, error and time.
Definition at line 81 of file IApproximationSchemeConfiguration.h.
Referenced by gum::ApproximationScheme::continueApproximationScheme(), gum::learning::IBNLearner::distributeProgress(), gum::learning::Miic::initiation_(), gum::learning::Miic::iteration_(), and gum::learning::Miic::orientationMiic_().
|
inherited |
Criteria messageApproximationScheme.
Definition at line 84 of file IApproximationSchemeConfiguration.h.
Referenced by gum::learning::IBNLearner::distributeStop().
|
protectedinherited |
Definition at line 156 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), _checkCompatibility_(), gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::drawSample_(), and p().
|
protectedinherited |
Checking criteria frequency.
Definition at line 467 of file approximationScheme.h.
Referenced by ApproximationScheme(), periodSize(), and setPeriodSize().
|
protectedinherited |
Definition at line 157 of file BNdistance.h.
Referenced by BNdistance(), BNdistance(), _checkCompatibility_(), gum::ExactBNdistance< GUM_SCALAR >::computeKL_(), gum::GibbsBNdistance< GUM_SCALAR >::computeKL_(), gum::MCBNDistance< GUM_SCALAR >::computeKL_(), and q().
|
protectedinherited |
Definition at line 142 of file gibbsOperator.h.
Referenced by GibbsOperator(), _drawVarMonteCarlo_(), _forwardSample_(), _GibbsSample_(), _isCompatible_(), _pruneDomains_(), _smoothedGibbsSample_(), monteCarloSample(), and updateSamplingNodes_().
|
protectedinherited |
Definition at line 144 of file gibbsOperator.h.
Referenced by nextSample(), and updateSamplingNodes_().
|
protectedinherited |
The timer.
Definition at line 431 of file approximationScheme.h.
Referenced by continueApproximationScheme(), currentTime(), initApproximationScheme(), gum::learning::Miic::initiation_(), gum::learning::Miic::iteration_(), gum::learning::Miic::learnMixedStructure(), gum::learning::Miic::learnSkeleton(), and gum::learning::Miic::orientationMiic_().
|
protectedinherited |
If true, verbosity is enabled.
Definition at line 470 of file approximationScheme.h.
Referenced by ApproximationScheme(), and setVerbosity().