Namespaces | |
opg | |
Typedefs | |
using | KMeansParams = cuvs::cluster::kmeans::params |
Functions | |
void | fit_predict (const raft::handle_t &handle, const KMeansParams ¶ms, const float *X, int n_samples, int n_features, const float *sample_weight, float *centroids, int *labels, float &inertia, int &n_iter) |
Compute k-means clustering and predicts cluster index for each sample in the input. More... | |
void | fit_predict (const raft::handle_t &handle, const KMeansParams ¶ms, const double *X, int n_samples, int n_features, const double *sample_weight, double *centroids, int *labels, double &inertia, int &n_iter) |
void | fit_predict (const raft::handle_t &handle, const KMeansParams ¶ms, const float *X, int64_t n_samples, int64_t n_features, const float *sample_weight, float *centroids, int64_t *labels, float &inertia, int64_t &n_iter) |
void | fit_predict (const raft::handle_t &handle, const KMeansParams ¶ms, const double *X, int64_t n_samples, int64_t n_features, const double *sample_weight, double *centroids, int64_t *labels, double &inertia, int64_t &n_iter) |
void | predict (const raft::handle_t &handle, const KMeansParams ¶ms, const float *centroids, const float *X, int n_samples, int n_features, const float *sample_weight, bool normalize_weights, int *labels, float &inertia) |
Predict the closest cluster each sample in X belongs to. More... | |
void | predict (const raft::handle_t &handle, const KMeansParams ¶ms, const double *centroids, const double *X, int n_samples, int n_features, const double *sample_weight, bool normalize_weights, int *labels, double &inertia) |
void | predict (const raft::handle_t &handle, const KMeansParams ¶ms, const float *centroids, const float *X, int64_t n_samples, int64_t n_features, const float *sample_weight, bool normalize_weights, int64_t *labels, float &inertia) |
void | predict (const raft::handle_t &handle, const KMeansParams ¶ms, const double *centroids, const double *X, int64_t n_samples, int64_t n_features, const double *sample_weight, bool normalize_weights, int64_t *labels, double &inertia) |
void | transform (const raft::handle_t &handle, const KMeansParams ¶ms, const float *centroids, const float *X, int n_samples, int n_features, float *X_new) |
Transform X to a cluster-distance space. More... | |
void | transform (const raft::handle_t &handle, const KMeansParams ¶ms, const double *centroids, const double *X, int n_samples, int n_features, double *X_new) |
void | transform (const raft::handle_t &handle, const KMeansParams ¶ms, const float *centroids, const float *X, int64_t n_samples, int64_t n_features, float *X_new) |
void | transform (const raft::handle_t &handle, const KMeansParams ¶ms, const double *centroids, const double *X, int64_t n_samples, int64_t n_features, double *X_new) |
using ML::kmeans::KMeansParams = typedef cuvs::cluster::kmeans::params |
void ML::kmeans::fit_predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const double * | X, | ||
int | n_samples, | ||
int | n_features, | ||
const double * | sample_weight, | ||
double * | centroids, | ||
int * | labels, | ||
double & | inertia, | ||
int & | n_iter | ||
) |
void ML::kmeans::fit_predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const double * | X, | ||
int64_t | n_samples, | ||
int64_t | n_features, | ||
const double * | sample_weight, | ||
double * | centroids, | ||
int64_t * | labels, | ||
double & | inertia, | ||
int64_t & | n_iter | ||
) |
void ML::kmeans::fit_predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const float * | X, | ||
int | n_samples, | ||
int | n_features, | ||
const float * | sample_weight, | ||
float * | centroids, | ||
int * | labels, | ||
float & | inertia, | ||
int & | n_iter | ||
) |
Compute k-means clustering and predicts cluster index for each sample in the input.
[in] | handle | The handle to the cuML library context that manages the CUDA resources. |
[in] | params | Parameters for KMeans model. |
[in] | X | Training instances to cluster. It must be noted that the data must be in row-major format and stored in device accessible location. |
[in] | n_samples | Number of samples in the input X. |
[in] | n_features | Number of features or the dimensions of each sample. |
[in] | sample_weight | The weights for each observation in X. |
[in,out] | centroids | [in] When init is InitMethod::Array, use centroids as the initial cluster centers [out] Otherwise, generated centroids from the kmeans algorithm is stored at the address pointed by 'centroids'. |
[out] | labels | Index of the cluster each sample in X belongs to. |
[out] | inertia | Sum of squared distances of samples to their closest cluster center. |
[out] | n_iter | Number of iterations run. |
void ML::kmeans::fit_predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const float * | X, | ||
int64_t | n_samples, | ||
int64_t | n_features, | ||
const float * | sample_weight, | ||
float * | centroids, | ||
int64_t * | labels, | ||
float & | inertia, | ||
int64_t & | n_iter | ||
) |
void ML::kmeans::predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const double * | centroids, | ||
const double * | X, | ||
int | n_samples, | ||
int | n_features, | ||
const double * | sample_weight, | ||
bool | normalize_weights, | ||
int * | labels, | ||
double & | inertia | ||
) |
void ML::kmeans::predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const double * | centroids, | ||
const double * | X, | ||
int64_t | n_samples, | ||
int64_t | n_features, | ||
const double * | sample_weight, | ||
bool | normalize_weights, | ||
int64_t * | labels, | ||
double & | inertia | ||
) |
void ML::kmeans::predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const float * | centroids, | ||
const float * | X, | ||
int | n_samples, | ||
int | n_features, | ||
const float * | sample_weight, | ||
bool | normalize_weights, | ||
int * | labels, | ||
float & | inertia | ||
) |
Predict the closest cluster each sample in X belongs to.
[in] | handle | The handle to the cuML library context that manages the CUDA resources. |
[in] | params | Parameters for KMeans model. |
[in] | centroids | Cluster centroids. It must be noted that the data must be in row-major format and stored in device accessible location. |
[in] | X | New data to predict. |
[in] | n_samples | Number of samples in the input X. |
[in] | n_features | Number of features or the dimensions of each sample in 'X' (value should be same as the dimension for each cluster centers in 'centroids'). |
[in] | sample_weight | The weights for each observation in X. |
[in] | normalize_weights | True if the weights should be normalized |
[out] | labels | Index of the cluster each sample in X belongs to. |
[out] | inertia | Sum of squared distances of samples to their closest cluster center. |
void ML::kmeans::predict | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const float * | centroids, | ||
const float * | X, | ||
int64_t | n_samples, | ||
int64_t | n_features, | ||
const float * | sample_weight, | ||
bool | normalize_weights, | ||
int64_t * | labels, | ||
float & | inertia | ||
) |
void ML::kmeans::transform | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const double * | centroids, | ||
const double * | X, | ||
int | n_samples, | ||
int | n_features, | ||
double * | X_new | ||
) |
void ML::kmeans::transform | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const double * | centroids, | ||
const double * | X, | ||
int64_t | n_samples, | ||
int64_t | n_features, | ||
double * | X_new | ||
) |
void ML::kmeans::transform | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const float * | centroids, | ||
const float * | X, | ||
int | n_samples, | ||
int | n_features, | ||
float * | X_new | ||
) |
Transform X to a cluster-distance space.
[in] | handle | The handle to the cuML library context that manages the CUDA resources. |
[in] | params | Parameters for KMeans model. |
[in] | centroids | Cluster centroids. It must be noted that the data must be in row-major format and stored in device accessible location. |
[in] | X | Training instances to cluster. It must be noted that the data must be in row-major format and stored in device accessible location. |
[in] | n_samples | Number of samples in the input X. |
[in] | n_features | Number of features or the dimensions of each sample in 'X' (it should be same as the dimension for each cluster centers in 'centroids'). |
[out] | X_new | X transformed in the new space.. |
void ML::kmeans::transform | ( | const raft::handle_t & | handle, |
const KMeansParams & | params, | ||
const float * | centroids, | ||
const float * | X, | ||
int64_t | n_samples, | ||
int64_t | n_features, | ||
float * | X_new | ||
) |