holtwinters.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 
17 #pragma once
18 
19 #include "holtwinters_params.h"
20 
21 namespace raft {
22 class handle_t;
23 }
24 
25 namespace ML {
26 namespace HoltWinters {
27 
49 void buffer_size(int n,
50  int batch_size,
51  int frequency,
52  int* start_leveltrend_len,
53  int* start_season_len,
54  int* components_len,
55  int* error_len,
56  int* leveltrend_coef_shift,
57  int* season_coef_shift);
58 
86 void fit(const raft::handle_t& handle,
87  int n,
88  int batch_size,
89  int frequency,
90  int start_periods,
91  ML::SeasonalType seasonal,
92  float epsilon,
93  float* data,
94  float* level_d,
95  float* trend_d,
96  float* season_d,
97  float* error_d);
98 void fit(const raft::handle_t& handle,
99  int n,
100  int batch_size,
101  int frequency,
102  int start_periods,
103  ML::SeasonalType seasonal,
104  double epsilon,
105  double* data,
106  double* level_d,
107  double* trend_d,
108  double* season_d,
109  double* error_d);
110 
134 void forecast(const raft::handle_t& handle,
135  int n,
136  int batch_size,
137  int frequency,
138  int h,
139  ML::SeasonalType seasonal,
140  float* level_d,
141  float* trend_d,
142  float* season_d,
143  float* forecast_d);
144 void forecast(const raft::handle_t& handle,
145  int n,
146  int batch_size,
147  int frequency,
148  int h,
149  ML::SeasonalType seasonal,
150  double* level_d,
151  double* trend_d,
152  double* season_d,
153  double* forecast_d);
154 
155 } // namespace HoltWinters
156 } // namespace ML
void fit(const raft::handle_t &handle, int n, int batch_size, int frequency, int start_periods, ML::SeasonalType seasonal, float epsilon, float *data, float *level_d, float *trend_d, float *season_d, float *error_d)
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)
void forecast(const raft::handle_t &handle, int n, int batch_size, int frequency, int h, ML::SeasonalType seasonal, float *level_d, float *trend_d, float *season_d, float *forecast_d)
Definition: dbscan.hpp:30
SeasonalType
Definition: holtwinters_params.h:24
Definition: dbscan.hpp:26