knn_api.h
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/cuml_api.h>
20 
21 #include <stdbool.h>
22 #include <stdint.h>
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
54  float** input,
55  int* size,
56  int n_params,
57  int D,
58  float* search_items,
59  int n,
60  int64_t* res_I,
61  float* res_D,
62  int k,
63  bool rowMajorIndex,
64  bool rowMajorQuery,
65  int metric_type,
66  float metric_arg,
67  bool expanded);
68 
69 #ifdef __cplusplus
70 }
71 #endif
int cumlHandle_t
Definition: cuml_api.h:37
cumlError_t
Definition: cuml_api.h:39
cumlError_t knn_search(const cumlHandle_t handle, float **input, int *size, int n_params, int D, float *search_items, int n, int64_t *res_I, float *res_D, int k, bool rowMajorIndex, bool rowMajorQuery, int metric_type, float metric_arg, bool expanded)
Flat C API function to perform a brute force knn on a series of input arrays and combine the results ...