svm_api.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2019-2021, 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 #pragma once
17 
18 #include <cuml/cuml_api.h>
19 
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23 
25 
65  float* input,
66  int n_rows,
67  int n_cols,
68  float* labels,
69  float C,
70  float cache_size,
71  int max_iter,
72  int nochange_steps,
73  float tol,
74  int verbosity,
75  cumlSvmKernelType kernel,
76  int degree,
77  float gamma,
78  float coef0,
79  int* n_support,
80  float* b,
81  float** dual_coefs,
82  float** x_support,
83  int** support_idx,
84  int* n_classes,
85  float** unique_labels);
86 
88  double* input,
89  int n_rows,
90  int n_cols,
91  double* labels,
92  double C,
93  double cache_size,
94  int max_iter,
95  int nochange_steps,
96  double tol,
97  int verbosity,
98  cumlSvmKernelType kernel,
99  int degree,
100  double gamma,
101  double coef0,
102  int* n_support,
103  double* b,
104  double** dual_coefs,
105  double** x_support,
106  int** support_idx,
107  int* n_classes,
108  double** unique_labels);
141  float* input,
142  int n_rows,
143  int n_cols,
144  cumlSvmKernelType kernel,
145  int degree,
146  float gamma,
147  float coef0,
148  int n_support,
149  float b,
150  float* dual_coefs,
151  float* x_support,
152  int n_classes,
153  float* unique_labels,
154  float* preds,
155  float buffer_size,
156  int predict_class);
157 
159  double* input,
160  int n_rows,
161  int n_cols,
162  cumlSvmKernelType kernel,
163  int degree,
164  double gamma,
165  double coef0,
166  int n_support,
167  double b,
168  double* dual_coefs,
169  double* x_support,
170  int n_classes,
171  double* unique_labels,
172  double* preds,
173  double buffer_size,
174  int predict_class);
176 #ifdef __cplusplus
177 }
178 #endif
int cumlHandle_t
Definition: cuml_api.h:37
cumlError_t
Definition: cuml_api.h:39
cumlError_t cumlSpSvcPredict(cumlHandle_t handle, float *input, int n_rows, int n_cols, cumlSvmKernelType kernel, int degree, float gamma, float coef0, int n_support, float b, float *dual_coefs, float *x_support, int n_classes, float *unique_labels, float *preds, float buffer_size, int predict_class)
Definition: svm_api.cpp:176
cumlError_t cumlDpSvcPredict(cumlHandle_t handle, double *input, int n_rows, int n_cols, cumlSvmKernelType kernel, int degree, double gamma, double coef0, int n_support, double b, double *dual_coefs, double *x_support, int n_classes, double *unique_labels, double *preds, double buffer_size, int predict_class)
Definition: svm_api.cpp:231
cumlError_t cumlSpSvcFit(cumlHandle_t handle, float *input, int n_rows, int n_cols, float *labels, float C, float cache_size, int max_iter, int nochange_steps, float tol, int verbosity, cumlSvmKernelType kernel, int degree, float gamma, float coef0, int *n_support, float *b, float **dual_coefs, float **x_support, int **support_idx, int *n_classes, float **unique_labels)
Definition: svm_api.cpp:28
cumlError_t cumlDpSvcFit(cumlHandle_t handle, double *input, int n_rows, int n_cols, double *labels, double C, double cache_size, int max_iter, int nochange_steps, double tol, int verbosity, cumlSvmKernelType kernel, int degree, double gamma, double coef0, int *n_support, double *b, double **dual_coefs, double **x_support, int **support_idx, int *n_classes, double **unique_labels)
Definition: svm_api.cpp:102
void buffer_size(int n, int batch_size, int frequency, int *start_leveltrend_len, int *start_season_len, int *components_len, int *error_len, int *leveltrend_coef_shift, int *season_coef_shift)
cumlSvmKernelType
Definition: svm_api.h:24
@ POLYNOMIAL
Definition: svm_api.h:24
@ TANH
Definition: svm_api.h:24
@ RBF
Definition: svm_api.h:24
@ LINEAR
Definition: svm_api.h:24