62
62
* @param [out] result Output array.
63
63
*/
64
64
template <typename _DataType>
65
- INP_DLLEXPORT void dpnp_rng_beta_c (void * result, _DataType a, _DataType b, size_t size);
65
+ INP_DLLEXPORT void dpnp_rng_beta_c (void * result, const _DataType a, const _DataType b, const size_t size);
66
66
67
67
/* *
68
68
* @ingroup BACKEND_RANDOM_API
@@ -74,7 +74,7 @@ INP_DLLEXPORT void dpnp_rng_beta_c(void* result, _DataType a, _DataType b, size_
74
74
* @param [out] result Output array.
75
75
*/
76
76
template <typename _DataType>
77
- INP_DLLEXPORT void dpnp_rng_binomial_c (void * result, int ntrial, double p, size_t size);
77
+ INP_DLLEXPORT void dpnp_rng_binomial_c (void * result, const int ntrial, const double p, const size_t size);
78
78
79
79
/* *
80
80
* @ingroup BACKEND_RANDOM_API
@@ -85,7 +85,7 @@ INP_DLLEXPORT void dpnp_rng_binomial_c(void* result, int ntrial, double p, size_
85
85
* @param [out] result Output array.
86
86
*/
87
87
template <typename _DataType>
88
- INP_DLLEXPORT void dpnp_rng_chi_square_c (void * result, int df, size_t size);
88
+ INP_DLLEXPORT void dpnp_rng_chisquare_c (void * result, const int df, const size_t size);
89
89
90
90
/* *
91
91
* @ingroup BACKEND_RANDOM_API
@@ -96,7 +96,7 @@ INP_DLLEXPORT void dpnp_rng_chi_square_c(void* result, int df, size_t size);
96
96
* @param [out] result Output array.
97
97
*/
98
98
template <typename _DataType>
99
- INP_DLLEXPORT void dpnp_rng_exponential_c (void * result, _DataType beta, size_t size);
99
+ INP_DLLEXPORT void dpnp_rng_exponential_c (void * result, const _DataType beta, const size_t size);
100
100
101
101
/* *
102
102
* @ingroup BACKEND_RANDOM_API
@@ -108,7 +108,7 @@ INP_DLLEXPORT void dpnp_rng_exponential_c(void* result, _DataType beta, size_t s
108
108
* @param [out] result Output array.
109
109
*/
110
110
template <typename _DataType>
111
- INP_DLLEXPORT void dpnp_rng_f_c (void * result, _DataType df_num, _DataType df_den, size_t size);
111
+ INP_DLLEXPORT void dpnp_rng_f_c (void * result, const _DataType df_num, const _DataType df_den, const size_t size);
112
112
113
113
/* *
114
114
* @ingroup BACKEND_RANDOM_API
@@ -120,7 +120,7 @@ INP_DLLEXPORT void dpnp_rng_f_c(void* result, _DataType df_num, _DataType df_den
120
120
* @param [out] result Output array.
121
121
*/
122
122
template <typename _DataType>
123
- INP_DLLEXPORT void dpnp_rng_gamma_c (void * result, _DataType shape, _DataType scale, size_t size);
123
+ INP_DLLEXPORT void dpnp_rng_gamma_c (void * result, const _DataType shape, const _DataType scale, const size_t size);
124
124
125
125
/* *
126
126
* @ingroup BACKEND_RANDOM_API
@@ -132,43 +132,43 @@ INP_DLLEXPORT void dpnp_rng_gamma_c(void* result, _DataType shape, _DataType sca
132
132
* @param [out] result Output array.
133
133
*/
134
134
template <typename _DataType>
135
- INP_DLLEXPORT void dpnp_rng_gaussian_c (void * result, _DataType mean, _DataType stddev, size_t size);
135
+ INP_DLLEXPORT void dpnp_rng_gaussian_c (void * result, const _DataType mean, const _DataType stddev, const size_t size);
136
136
137
137
/* *
138
138
* @ingroup BACKEND_RANDOM_API
139
- * @brief math library implementation of random number generator (hypergeometric distribution)
139
+ * @brief math library implementation of random number generator (Geometric distribution)
140
140
*
141
141
* @param [in] size Number of elements in `result` arrays.
142
- * @param [in] l Lot size of l.
143
- * @param [in] s Size of sampling without replacement.
144
- * @param [in] m Number of marked elements m.
142
+ * @param [in] p The probability of success of an individual trial.
145
143
* @param [out] result Output array.
146
144
*/
147
145
template <typename _DataType>
148
- INP_DLLEXPORT void dpnp_rng_hypergeometric_c (void * result, int l, int s, int m, size_t size);
146
+ INP_DLLEXPORT void dpnp_rng_geometric_c (void * result, const float p, const size_t size);
149
147
150
148
/* *
151
149
* @ingroup BACKEND_RANDOM_API
152
- * @brief math library implementation of random number generator (geometric distribution)
150
+ * @brief math library implementation of random number generator (Gumbel distribution)
153
151
*
154
152
* @param [in] size Number of elements in `result` arrays.
155
- * @param [in] p Success probability p of a trial.
153
+ * @param [in] loc The location of the mode of the distribution.
154
+ * @param [in] scale The scale parameter of the distribution. Default is 1.
156
155
* @param [out] result Output array.
157
156
*/
158
157
template <typename _DataType>
159
- INP_DLLEXPORT void dpnp_rng_geometric_c (void * result, float p, size_t size);
158
+ INP_DLLEXPORT void dpnp_rng_gumbel_c (void * result, const double loc, const double scale, const size_t size);
160
159
161
160
/* *
162
161
* @ingroup BACKEND_RANDOM_API
163
- * @brief math library implementation of random number generator (gumbel distribution)
162
+ * @brief math library implementation of random number generator (hypergeometric distribution)
164
163
*
165
164
* @param [in] size Number of elements in `result` arrays.
166
- * @param [in] loc The location of the mode of the distribution.
167
- * @param [in] scale The scale parameter of the distribution.
165
+ * @param [in] l Lot size of l.
166
+ * @param [in] s Size of sampling without replacement.
167
+ * @param [in] m Number of marked elements m.
168
168
* @param [out] result Output array.
169
169
*/
170
170
template <typename _DataType>
171
- INP_DLLEXPORT void dpnp_rng_gumbel_c (void * result, double loc, double scale, size_t size);
171
+ INP_DLLEXPORT void dpnp_rng_hypergeometric_c (void * result, const int l, const int s, const int m, const size_t size);
172
172
173
173
/* *
174
174
* @ingroup BACKEND_RANDOM_API
@@ -180,7 +180,7 @@ INP_DLLEXPORT void dpnp_rng_gumbel_c(void* result, double loc, double scale, siz
180
180
* @param [out] result Output array.
181
181
*/
182
182
template <typename _DataType>
183
- INP_DLLEXPORT void dpnp_rng_laplace_c (void * result, double loc, double scale, size_t size);
183
+ INP_DLLEXPORT void dpnp_rng_laplace_c (void * result, const double loc, const double scale, const size_t size);
184
184
185
185
/* *
186
186
* @ingroup BACKEND_RANDOM_API
@@ -192,7 +192,7 @@ INP_DLLEXPORT void dpnp_rng_laplace_c(void* result, double loc, double scale, si
192
192
* @param [out] result Output array.
193
193
*/
194
194
template <typename _DataType>
195
- INP_DLLEXPORT void dpnp_rng_logistic_c (void * result, double loc, double scale, size_t size);
195
+ INP_DLLEXPORT void dpnp_rng_logistic_c (void * result, const double loc, double const scale, const size_t size);
196
196
197
197
/* *
198
198
* @ingroup BACKEND_RANDOM_API
@@ -204,7 +204,8 @@ INP_DLLEXPORT void dpnp_rng_logistic_c(void* result, double loc, double scale, s
204
204
* @param [out] result Output array.
205
205
*/
206
206
template <typename _DataType>
207
- INP_DLLEXPORT void dpnp_rng_lognormal_c (void * result, _DataType mean, _DataType stddev, size_t size);
207
+ INP_DLLEXPORT void dpnp_rng_lognormal_c (void * result, const _DataType mean, const _DataType stddev,
208
+ const size_t size);
208
209
209
210
/* *
210
211
* @ingroup BACKEND_RANDOM_API
@@ -217,8 +218,8 @@ INP_DLLEXPORT void dpnp_rng_lognormal_c(void* result, _DataType mean, _DataType
217
218
* @param [out] result Output array.
218
219
*/
219
220
template <typename _DataType>
220
- INP_DLLEXPORT void
221
- dpnp_rng_multinomial_c ( void * result, int ntrial, const double * p_vector, const size_t p_vector_size, size_t size);
221
+ INP_DLLEXPORT void dpnp_rng_multinomial_c ( void * result, const int ntrial, const double * p_vector,
222
+ const size_t p_vector_size, const size_t size);
222
223
223
224
/* *
224
225
* @ingroup BACKEND_RANDOM_API
@@ -239,7 +240,7 @@ INP_DLLEXPORT void dpnp_rng_multivariate_normal_c(void* result,
239
240
const size_t mean_vector_size,
240
241
const double * cov_vector,
241
242
const size_t cov_vector_size,
242
- size_t size);
243
+ const size_t size);
243
244
244
245
/* *
245
246
* @ingroup BACKEND_RANDOM_API
@@ -252,7 +253,7 @@ INP_DLLEXPORT void dpnp_rng_multivariate_normal_c(void* result,
252
253
*
253
254
*/
254
255
template <typename _DataType>
255
- INP_DLLEXPORT void dpnp_rng_negative_binomial_c (void * result, double a, double p, size_t size);
256
+ INP_DLLEXPORT void dpnp_rng_negative_binomial_c (void * result, const double a, const double p, const size_t size);
256
257
257
258
/* *
258
259
* @ingroup BACKEND_RANDOM_API
@@ -264,7 +265,7 @@ INP_DLLEXPORT void dpnp_rng_negative_binomial_c(void* result, double a, double p
264
265
* @param [out] result Output array.
265
266
*/
266
267
template <typename _DataType>
267
- INP_DLLEXPORT void dpnp_rng_normal_c (void * result, _DataType mean, _DataType stddev, size_t size);
268
+ INP_DLLEXPORT void dpnp_rng_normal_c (void * result, const _DataType mean, const _DataType stddev, const size_t size);
268
269
269
270
/* *
270
271
* @ingroup BACKEND_RANDOM_API
@@ -275,7 +276,7 @@ INP_DLLEXPORT void dpnp_rng_normal_c(void* result, _DataType mean, _DataType std
275
276
* @param [out] result Output array.
276
277
*/
277
278
template <typename _DataType>
278
- INP_DLLEXPORT void dpnp_rng_pareto_c (void * result, double alpha, size_t size);
279
+ INP_DLLEXPORT void dpnp_rng_pareto_c (void * result, const double alpha, const size_t size);
279
280
280
281
/* *
281
282
* @ingroup BACKEND_RANDOM_API
@@ -286,7 +287,7 @@ INP_DLLEXPORT void dpnp_rng_pareto_c(void* result, double alpha, size_t size);
286
287
* @param [out] result Output array.
287
288
*/
288
289
template <typename _DataType>
289
- INP_DLLEXPORT void dpnp_rng_poisson_c (void * result, double lambda, size_t size);
290
+ INP_DLLEXPORT void dpnp_rng_poisson_c (void * result, const double lambda, const size_t size);
290
291
291
292
/* *
292
293
* @ingroup BACKEND_RANDOM_API
@@ -297,7 +298,7 @@ INP_DLLEXPORT void dpnp_rng_poisson_c(void* result, double lambda, size_t size);
297
298
* @param [out] result Output array.
298
299
*/
299
300
template <typename _DataType>
300
- INP_DLLEXPORT void dpnp_rng_power_c (void * result, double alpha, size_t size);
301
+ INP_DLLEXPORT void dpnp_rng_power_c (void * result, const double alpha, const size_t size);
301
302
302
303
/* *
303
304
* @ingroup BACKEND_RANDOM_API
@@ -308,7 +309,7 @@ INP_DLLEXPORT void dpnp_rng_power_c(void* result, double alpha, size_t size);
308
309
* @param [out] result Output array.
309
310
*/
310
311
template <typename _DataType>
311
- INP_DLLEXPORT void dpnp_rng_rayleigh_c (void * result, _DataType scale, size_t size);
312
+ INP_DLLEXPORT void dpnp_rng_rayleigh_c (void * result, const _DataType scale, const size_t size);
312
313
313
314
/* *
314
315
* @ingroup BACKEND_RANDOM_API
@@ -326,7 +327,7 @@ INP_DLLEXPORT void dpnp_rng_srand_c(size_t seed = 1);
326
327
* @param [out] result Output array.
327
328
*/
328
329
template <typename _DataType>
329
- INP_DLLEXPORT void dpnp_rng_standard_cauchy_c (void * result, size_t size);
330
+ INP_DLLEXPORT void dpnp_rng_standard_cauchy_c (void * result, const size_t size);
330
331
331
332
/* *
332
333
* @ingroup BACKEND_RANDOM_API
@@ -336,7 +337,7 @@ INP_DLLEXPORT void dpnp_rng_standard_cauchy_c(void* result, size_t size);
336
337
* @param [out] result Output array.
337
338
*/
338
339
template <typename _DataType>
339
- INP_DLLEXPORT void dpnp_rng_standard_exponential_c (void * result, size_t size);
340
+ INP_DLLEXPORT void dpnp_rng_standard_exponential_c (void * result, const size_t size);
340
341
341
342
/* *
342
343
* @ingroup BACKEND_RANDOM_API
@@ -347,7 +348,7 @@ INP_DLLEXPORT void dpnp_rng_standard_exponential_c(void* result, size_t size);
347
348
* @param [out] result Output array.
348
349
*/
349
350
template <typename _DataType>
350
- INP_DLLEXPORT void dpnp_rng_standard_gamma_c (void * result, _DataType shape, size_t size);
351
+ INP_DLLEXPORT void dpnp_rng_standard_gamma_c (void * result, const _DataType shape, const size_t size);
351
352
352
353
/* *
353
354
* @ingroup BACKEND_RANDOM_API
@@ -357,7 +358,7 @@ INP_DLLEXPORT void dpnp_rng_standard_gamma_c(void* result, _DataType shape, size
357
358
* @param [out] result Output array.
358
359
*/
359
360
template <typename _DataType>
360
- INP_DLLEXPORT void dpnp_rng_standard_normal_c (void * result, size_t size);
361
+ INP_DLLEXPORT void dpnp_rng_standard_normal_c (void * result, const size_t size);
361
362
362
363
/* *
363
364
* @ingroup BACKEND_RANDOM_API
@@ -368,7 +369,7 @@ INP_DLLEXPORT void dpnp_rng_standard_normal_c(void* result, size_t size);
368
369
* @param [out] result Output array.
369
370
*/
370
371
template <typename _DataType>
371
- INP_DLLEXPORT void dpnp_rng_standard_t_c (void * result, _DataType df, size_t size);
372
+ INP_DLLEXPORT void dpnp_rng_standard_t_c (void * result, const _DataType df, const size_t size);
372
373
373
374
/* *
374
375
* @ingroup BACKEND_RANDOM_API
@@ -380,7 +381,7 @@ INP_DLLEXPORT void dpnp_rng_standard_t_c(void* result, _DataType df, size_t size
380
381
* @param [out] result Output array.
381
382
*/
382
383
template <typename _DataType>
383
- INP_DLLEXPORT void dpnp_rng_uniform_c (void * result, long low, long high, size_t size);
384
+ INP_DLLEXPORT void dpnp_rng_uniform_c (void * result, const long low, const long high, const size_t size);
384
385
385
386
/* *
386
387
* @ingroup BACKEND_RANDOM_API
@@ -391,6 +392,6 @@ INP_DLLEXPORT void dpnp_rng_uniform_c(void* result, long low, long high, size_t
391
392
* @param [out] result Output array.
392
393
*/
393
394
template <typename _DataType>
394
- INP_DLLEXPORT void dpnp_rng_weibull_c (void * result, double alpha, size_t size);
395
+ INP_DLLEXPORT void dpnp_rng_weibull_c (void * result, const double alpha, const size_t size);
395
396
396
397
#endif // BACKEND_IFACE_RANDOM_H
0 commit comments