Home
libcuml
cucim
cudf-java
cudf
cugraph
cuml
cuproj
cuspatial
cuvs
cuxfilter
dask-cuda
dask-cudf
kvikio
libcudf
libcuml
libcuproj
libcuspatial
libkvikio
libucxx
raft
rapids-cmake
rmm
nightly (24.12)
nightly (24.12)
stable (24.10)
legacy (24.08)
include
cuml
cluster
kmeans_mg.hpp
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2019-2024, NVIDIA CORPORATION.
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*/
16
17
#pragma once
18
19
#include <
cuml/cluster/kmeans.hpp
>
20
21
namespace
raft
{
22
class
handle_t;
23
}
24
25
namespace
ML
{
26
namespace
kmeans {
27
namespace
opg {
28
51
void
fit
(
const
raft::resources& handle,
52
const
KMeansParams
&
params
,
53
const
float
* X,
54
int
n_samples,
55
int
n_features,
56
const
float
* sample_weight,
57
float
* centroids,
58
float
& inertia,
59
int
& n_iter);
60
61
void
fit
(
const
raft::resources& handle,
62
const
KMeansParams
&
params
,
63
const
double
* X,
64
int
n_samples,
65
int
n_features,
66
const
double
* sample_weight,
67
double
* centroids,
68
double
& inertia,
69
int
& n_iter);
70
71
void
fit
(
const
raft::resources& handle,
72
const
KMeansParams
&
params
,
73
const
float
* X,
74
int64_t n_samples,
75
int64_t n_features,
76
const
float
* sample_weight,
77
float
* centroids,
78
float
& inertia,
79
int64_t& n_iter);
80
81
void
fit
(
const
raft::resources& handle,
82
const
KMeansParams
&
params
,
83
const
double
* X,
84
int64_t n_samples,
85
int64_t n_features,
86
const
double
* sample_weight,
87
double
* centroids,
88
double
& inertia,
89
int64_t& n_iter);
90
};
// end namespace opg
91
};
// end namespace kmeans
92
};
// end namespace ML
ML::params
Definition:
params.hpp:34
kmeans.hpp
ML::kmeans::opg::fit
void fit(const raft::resources &handle, const KMeansParams ¶ms, const float *X, int n_samples, int n_features, const float *sample_weight, float *centroids, float &inertia, int &n_iter)
Compute k-means clustering.
ML::kmeans::KMeansParams
cuvs::cluster::kmeans::params KMeansParams
Definition:
kmeans.hpp:31
ML
Definition:
dbscan.hpp:30
raft
Definition:
dbscan.hpp:26
Generated by
1.9.1