Skip to content

Commit

Permalink
update doc
Browse files Browse the repository at this point in the history
  • Loading branch information
viclafargue committed Mar 15, 2023
1 parent afbb337 commit 7392e52
Showing 1 changed file with 32 additions and 33 deletions.
65 changes: 32 additions & 33 deletions cpp/include/raft/neighbors/ivf_pq.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ namespace raft::neighbors::ivf_pq {
* @tparam T data element type
* @tparam IdxT type of the indices in the source dataset
*
* @param handle
* @param params configure the index building
* @param[in] handle
* @param[in] params configure the index building
* @param[in] dataset a device matrix view to a row-major matrix [n_rows, dim]
*
* @return the constructed ivf-pq index
Expand All @@ -67,12 +67,12 @@ auto build(raft::device_resources const& handle,
* @tparam T data element type
* @tparam IdxT type of the indices in the source dataset
*
* @param handle
* @param[inout] idx
* @param[in] handle
* @param[in] new_vectors a device matrix view to a row-major matrix [n_rows, index.dim()]
* @param[in] new_indices a device matrix view to a vector of indices [n_rows].
* If the original index is empty (`index.size() == 0`), you can pass `nullptr`
* If the original index is empty (`idx.size() == 0`), you can pass `std::nullopt`
* here to imply a continuous range `[0...n_rows)`.
* @param[inout] idx
*/
template <typename T, typename IdxT>
index<IdxT> extend(raft::device_resources const& handle,
Expand Down Expand Up @@ -102,12 +102,12 @@ index<IdxT> extend(raft::device_resources const& handle,
* @tparam T data element type
* @tparam IdxT type of the indices in the source dataset
*
* @param handle
* @param[inout] idx
* @param[in] handle
* @param[in] new_vectors a device matrix view to a row-major matrix [n_rows, index.dim()]
* @param[in] new_indices a device matrix view to a vector of indices [n_rows].
* If the original index is empty (`index.size() == 0`), you can pass `nullptr`
* If the original index is empty (`idx.size() == 0`), you can pass std::nullopt
* here to imply a continuous range `[0...n_rows)`.
* @param[inout] idx
*/
template <typename T, typename IdxT>
void extend(raft::device_resources const& handle,
Expand Down Expand Up @@ -147,10 +147,10 @@ void extend(raft::device_resources const& handle,
* @tparam T data element type
* @tparam IdxT type of the indices
*
* @param handle
* @param params configure the search
* @param idx ivf-pq constructed index
* @param[in] queries a device matrix view to a row-major matrix [n_queries, index->dim()]
* @param[in] handle
* @param[in] params configure the search
* @param[in] idx ivf-pq constructed index
* @param[in] queries a device matrix view to a row-major matrix [n_queries, index.dim()]
* @param[out] neighbors a device matrix view to the indices of the neighbors in the source dataset
* [n_queries, k]
* @param[out] distances a device matrix view to the distances to the selected neighbors [n_queries,
Expand Down Expand Up @@ -212,11 +212,11 @@ void search(raft::device_resources const& handle,
* @tparam T data element type
* @tparam IdxT type of the indices in the source dataset
*
* @param handle
* @param params configure the index building
* @param[in] handle
* @param[in] params configure the index building
* @param[in] dataset a device/host pointer to a row-major matrix [n_rows, dim]
* @param n_rows the number of samples
* @param dim the dimensionality of the data
* @param[in] n_rows the number of samples
* @param[in] dim the dimensionality of the data
*
* @return the constructed ivf-pq index
*/
Expand Down Expand Up @@ -252,13 +252,13 @@ auto build(raft::device_resources const& handle,
* @tparam T data element type
* @tparam IdxT type of the indices in the source dataset
*
* @param handle
* @param idx original index
* @param[in] new_vectors a device/host pointer to a row-major matrix [n_rows, index.dim()]
* @param[in] handle
* @param[in] idx original index
* @param[in] new_vectors a device/host pointer to a row-major matrix [n_rows, idx.dim()]
* @param[in] new_indices a device/host pointer to a vector of indices [n_rows].
* If the original index is empty (`index.size() == 0`), you can pass `nullptr`
* If the original index is empty (`idx.size() == 0`), you can pass `nullptr`
* here to imply a continuous range `[0...n_rows)`.
* @param n_rows the number of samples
* @param[in] n_rows the number of samples
*
* @return the constructed extended ivf-pq index
*/
Expand All @@ -278,14 +278,13 @@ auto extend(raft::device_resources const& handle,
* @tparam T data element type
* @tparam IdxT type of the indices in the source dataset
*
* @param handle
* @param[in] handle
* @param[inout] idx
* @param[in] new_vectors a device/host pointer to a row-major matrix [n_rows, index.dim()]
* @param[in] new_vectors a device/host pointer to a row-major matrix [n_rows, idx.dim()]
* @param[in] new_indices a device/host pointer to a vector of indices [n_rows].
* If the original index is empty (`index.size() == 0`), you can pass `nullptr`
* If the original index is empty (`idx.size() == 0`), you can pass `nullptr`
* here to imply a continuous range `[0...n_rows)`.
* @param[inout] idx
* @param n_rows the number of samples
* @param[in] n_rows the number of samples
*/
template <typename T, typename IdxT>
void extend(raft::device_resources const& handle,
Expand Down Expand Up @@ -327,17 +326,17 @@ void extend(raft::device_resources const& handle,
* @tparam T data element type
* @tparam IdxT type of the indices
*
* @param handle
* @param params configure the search
* @param idx ivf-pq constructed index
* @param[in] handle
* @param[in] params configure the search
* @param[in] idx ivf-pq constructed index
* @param[in] queries a device pointer to a row-major matrix [n_queries, index->dim()]
* @param n_queries the batch size
* @param k the number of neighbors to find for each query.
* @param[in] n_queries the batch size
* @param[in] k the number of neighbors to find for each query.
* @param[out] neighbors a device pointer to the indices of the neighbors in the source dataset
* [n_queries, k]
* @param[out] distances a device pointer to the distances to the selected neighbors [n_queries, k]
* @param mr an optional memory resource to use across the searches (you can provide a large enough
* memory pool here to avoid memory allocations within search).
* @param[in] mr an optional memory resource to use across the searches (you can provide a large
* enough memory pool here to avoid memory allocations within search).
*/
template <typename T, typename IdxT>
void search(raft::device_resources const& handle,
Expand Down

0 comments on commit 7392e52

Please sign in to comment.