[mlpack-svn] r10779 - mlpack/trunk/src/mlpack/core/kernels

fastlab-svn at coffeetalk-1.cc.gatech.edu fastlab-svn at coffeetalk-1.cc.gatech.edu
Wed Dec 14 08:21:34 EST 2011


Author: rcurtin
Date: 2011-12-14 08:21:34 -0500 (Wed, 14 Dec 2011)
New Revision: 10779

Modified:
   mlpack/trunk/src/mlpack/core/kernels/gaussian_kernel.hpp
Log:
\bandwidth is not valid LaTeX... thanks regex...


Modified: mlpack/trunk/src/mlpack/core/kernels/gaussian_kernel.hpp
===================================================================
--- mlpack/trunk/src/mlpack/core/kernels/gaussian_kernel.hpp	2011-12-14 13:15:40 UTC (rev 10778)
+++ mlpack/trunk/src/mlpack/core/kernels/gaussian_kernel.hpp	2011-12-14 13:21:34 UTC (rev 10779)
@@ -16,10 +16,10 @@
 
 /**
  * The standard Gaussian kernel.  Given two vectors @f$ x @f$, @f$ y @f$, and a
- * bandwidth @f$ \bandwidth @f$ (set in the constructor),
+ * bandwidth @f$ \mu @f$ (set in the constructor),
  *
  * @f[
- * K(x, y) = \exp(-\frac{|| x - y ||^2}{2 \bandwidth^2}).
+ * K(x, y) = \exp(-\frac{|| x - y ||^2}{2 \mu^2}).
  * @f]
  *
  * The implementation is all in the header file because it is so simple.
@@ -35,7 +35,7 @@
   /**
    * Construct the Gaussian kernel with a custom bandwidth.
    *
-   * @param bandwidth The bandwidth of the kernel.
+   * @param bandwidth The bandwidth of the kernel (@f$\mu at f$).
    */
   GaussianKernel(double bandwidth) :
     bandwidth(bandwidth),
@@ -51,7 +51,7 @@
    * @tparam VecType Type of vector (likely arma::vec or arma::spvec).
    * @param a First vector.
    * @param b Second vector.
-   * @return K(a, b) using the bandwidth (@f$\bandwidth at f$) specified in the
+   * @return K(a, b) using the bandwidth (@f$\mu at f$) specified in the
    *   constructor.
    */
   template<typename VecType>
@@ -60,12 +60,13 @@
     // The precalculation of gamma saves us a little computation time.
     return exp(gamma * metric::SquaredEuclideanDistance::Evaluate(a, b));
   }
+
   /**
-   * Evaluation of the Gaussian kernel using a double precision argument
+   * Evaluation of the Gaussian kernel using a double precision argument.
    *
    * @param t double value.
-   * @return K(t) using the bandwidth (@f$\bandwidth at f$) specified in the
-   *   constructor.
+   * @return K(t) using the bandwidth (@f$\mu at f$) specified in the
+   *     constructor.
    */
   double Evaluate(double t) const
   {
@@ -84,7 +85,7 @@
   double normalizer;
 
   //! Precalculated constant depending on the bandwidth;
-  //! @f$ \gamma = -\frac{1}{2 \bandwidth^2} @f$.
+  //! @f$ \gamma = -\frac{1}{2 \mu^2} @f$.
   double gamma;
 };
 




More information about the mlpack-svn mailing list