refined_start.hpp

Go to the documentation of this file.
00001 
00024 #ifndef __MLPACK_METHODS_KMEANS_REFINED_START_HPP
00025 #define __MLPACK_METHODS_KMEANS_REFINED_START_HPP
00026 
00027 #include <mlpack/core.hpp>
00028 
00029 namespace mlpack {
00030 namespace kmeans {
00031 
00047 class RefinedStart
00048 {
00049  public:
00055   RefinedStart(const size_t samplings = 100,
00056                const double percentage = 0.02) :
00057       samplings(samplings), percentage(percentage) { }
00058 
00069   template<typename MatType>
00070   void Cluster(const MatType& data,
00071                const size_t clusters,
00072                arma::Col<size_t>& assignments) const;
00073 
00075   size_t Samplings() const { return samplings; }
00077   size_t& Samplings() { return samplings; }
00078 
00080   double Percentage() const { return percentage; }
00082   double& Percentage() { return percentage; }
00083 
00084  private:
00086   size_t samplings;
00088   double percentage;
00089 };
00090 
00091 }; // namespace kmeans
00092 }; // namespace mlpack
00093 
00094 // Include implementation.
00095 #include "refined_start_impl.hpp"
00096 
00097 #endif

Generated on 29 Sep 2016 for MLPACK by  doxygen 1.6.1