aGrUM  0.13.2
bruteForceKL.h
Go to the documentation of this file.
1 /***************************************************************************
2  * Copyright (C) 2005 by Christophe GONZALES and Pierre-Henri WUILLEMIN *
3  * {prenom.nom}_at_lip6.fr *
4  * *
5  * This program is free software; you can redistribute it and/or modify *
6  * it under the terms of the GNU General Public License as published by *
7  * the Free Software Foundation; either version 2 of the License, or *
8  * (at your option) any later version. *
9  * *
10  * This program is distributed in the hope that it will be useful, *
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13  * GNU General Public License for more details. *
14  * *
15  * You should have received a copy of the GNU General Public License *
16  * along with this program; if not, write to the *
17  * Free Software Foundation, Inc., *
18  * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
19  ***************************************************************************/
27 #ifndef GUM_BRUTE_FORCE_KL_H
28 #define GUM_BRUTE_FORCE_KL_H
29 
31 
32 namespace gum {
33 
65  template < typename GUM_SCALAR >
66  class BruteForceKL : public KL< GUM_SCALAR > {
67  public:
74  const IBayesNet< GUM_SCALAR >& Q);
75 
78  explicit BruteForceKL(const KL< GUM_SCALAR >& kl);
79 
81  virtual ~BruteForceKL();
82 
83  protected:
84  void _computeKL() final;
85 
90 
93 
96  };
97 
98 
99  extern template class BruteForceKL< float >;
100  extern template class BruteForceKL< double >;
101 
102 } // namespace gum
103 
105 
106 #endif // GUM_BRUTE_FORCE_KL_H
algorithm for KL divergence between BNs
virtual ~BruteForceKL()
destructor
BruteForceKL(const IBayesNet< GUM_SCALAR > &P, const IBayesNet< GUM_SCALAR > &Q)
constructor must give 2 BNs
Class representing the minimal interface for Bayesian Network.
Definition: IBayesNet.h:59
gum is the global namespace for all aGrUM entities
Definition: agrum.h:25
BruteForceKL computes exactly the KL divergence betweens 2 BNs.
Definition: bruteForceKL.h:66
KL is the base class for KL computation betweens 2 BNs.
Definition: KL.h:65
KL divergence between BNs brute force implementation.
void _computeKL() final