Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOC] Fix sample codes #2518

Open
wants to merge 5 commits into
base: branch-25.02
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions cpp/include/raft/cluster/kmeans.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ using KeyValueIndexOp = detail::KeyValueIndexOp<IndexT, DataT>;
* #include <raft/cluster/kmeans_types.hpp>
* using namespace raft::cluster;
* ...
* raft::raft::resources handle;
* raft::resources handle;
* raft::cluster::KMeansParams params;
* int n_features = 15, inertia, n_iter;
* auto centroids = raft::make_device_matrix<float, int>(handle, params.n_clusters, n_features);
Expand All @@ -61,7 +61,7 @@ using KeyValueIndexOp = detail::KeyValueIndexOp<IndexT, DataT>;
* params,
* X,
* std::nullopt,
* centroids,
* centroids.view(),
* raft::make_scalar_view(&inertia),
* raft::make_scalar_view(&n_iter));
* @endcode
Expand Down Expand Up @@ -107,7 +107,7 @@ template <typename DataT, typename IndexT>
* #include <raft/cluster/kmeans_types.hpp>
* using namespace raft::cluster;
* ...
* raft::raft::resources handle;
* raft::resources handle;
* raft::cluster::KMeansParams params;
* int n_features = 15, inertia, n_iter;
* auto centroids = raft::make_device_matrix<float, int>(handle, params.n_clusters, n_features);
Expand Down Expand Up @@ -175,7 +175,7 @@ template <typename DataT, typename IndexT>
* #include <raft/cluster/kmeans_types.hpp>
* using namespace raft::cluster;
* ...
* raft::raft::resources handle;
* raft::resources handle;
* raft::cluster::KMeansParams params;
* int n_features = 15, inertia, n_iter;
* auto centroids = raft::make_device_matrix<float, int>(handle, params.n_clusters, n_features);
Expand Down
4 changes: 2 additions & 2 deletions cpp/include/raft/comms/std_comms.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ using std_comms = detail::std_comms;
* #include <raft/core/device_mdarray.hpp>
*
* ncclComm_t nccl_comm;
* raft::raft::resources handle;
* raft::resources handle;
*
* build_comms_nccl_only(&handle, nccl_comm, 5, 0);
* ...
Expand Down Expand Up @@ -98,7 +98,7 @@ void build_comms_nccl_only(resources* handle, ncclComm_t nccl_comm, int num_rank
* #include <raft/core/device_mdarray.hpp>
*
* ncclComm_t nccl_comm;
* raft::raft::resources handle;
* raft::resources handle;
* ucp_worker_h ucp_worker;
* ucp_ep_h *ucp_endpoints_arr;
*
Expand Down
2 changes: 1 addition & 1 deletion cpp/include/raft/distance/distance-inl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,7 @@ void pairwise_distance(raft::resources const& handle,
* #include <raft/random/make_blobs.cuh>
* #include <raft/distance/distance.cuh>
*
* raft::raft::resources handle;
* raft::resources handle;
* int n_samples = 5000;
* int n_features = 50;
*
Expand Down
4 changes: 2 additions & 2 deletions cpp/include/raft/neighbors/epsilon_neighborhood.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ void epsUnexpL2SqNeighborhood(bool* adj,
* #include <raft/core/resources.hpp>
* #include <raft/core/device_mdarray.hpp>
* using namespace raft::neighbors;
* raft::raft::resources handle;
* raft::resources handle;
* ...
* auto adj = raft::make_device_matrix<bool>(handle, m * n);
* auto vd = raft::make_device_vector<int>(handle, m+1);
Expand Down Expand Up @@ -120,4 +120,4 @@ void eps_neighbors_l2sq(raft::resources const& handle,

} // namespace raft::neighbors::epsilon_neighborhood

#endif
#endif
Loading