public static double entropy (FactorGraph mdl)
{
JunctionTreeInferencer inf = new JunctionTreeInferencer ();
inf.computeMarginals (mdl);
JunctionTree jt = inf.lookupJunctionTree ();
return jt.entropy ();
}
/**
* Computes the KL divergence <tt>KL(mdl1||mdl2)</tt>. Junction tree is used to compute the entropy.
* <p>