22 #ifndef CRNSpectralClustering_HEADER
23 #define CRNSpectralClustering_HEADER
33 class SpectralClustering;
38 class SquareMatrixDouble;
67 const std::multimap<double, MatrixDouble>&
GetEigenpairs() const noexcept {
return eigenpairs; }
73 std::vector<std::vector<double>>
ProjectData(
size_t ncoordinates,
bool normalize)
const;
79 std::multimap<double, MatrixDouble> eigenpairs;
SpectralClustering & operator=(const SpectralClustering &)=delete
std::vector< std::vector< double > > ProjectData(size_t ncoordinates, bool normalize) const
Projects the data on the first coordinates.
static SpectralClustering CreateGlobalScaleFromDimension(const SquareMatrixDouble &distance_matrix, size_t dimension, double epsilon=std::numeric_limits< double >::max())
Clustering with global automatic scale.
static SpectralClustering CreateLocalScaleFromNN(const SquareMatrixDouble &distance_matrix, size_t sigma_neighborhood=7, double epsilon=std::numeric_limits< double >::max())
Clustering with local automatic scale.
std::vector< double > GetEigenvalues() const
Returns the eigenvalues (sorted from highest to lowest)
size_t EstimateClusterNumber(double limit=1.0) const
Estimates the number of clusters.
static SpectralClustering CreateGlobalScaleFromNN(const SquareMatrixDouble &distance_matrix, size_t sigma_neighborhood=1, double epsilon=std::numeric_limits< double >::max())
Clustering with global automatic scale.
static SpectralClustering CreateFixedScale(const SquareMatrixDouble &distance_matrix, double sigma, double epsilon=std::numeric_limits< double >::max())
Clustering with global fixed scale.
const std::multimap< double, MatrixDouble > & GetEigenpairs() const noexcept
Gets the data projected on each coordinates (higher eigenvalues are associated the to most significan...
Square double matrix class.
CRN_ALIAS_SMART_PTR(ImageBW)
SpectralClustering(const SpectralClustering &)=delete