API Reference#
Defines
-
NVPL_RAND_VERSION#
NVPL RAND library version.
-
struct nvplRandDistributionConfig#
Configuration to describe the properties of a data distribution.
Public Members
-
nvplRandDistributionType_t dist#
Distribution type.
-
double a#
For each of the distribution type, the double value
a
is:NVPL_RAND_CONTINUOUS_DIST_UNIFORM: not used
NVPL_RAND_CONTINUOUS_DIST_UNIFORM_RANGE : start value of the range (start, end]
NVPL_RAND_CONTINUOUS_DIST_NORMAL : mean of the normal distribution
NVPL_RAND_CONTINUOUS_DIST_LOGNORMAL : mean of the associated normal distribution
NVPL_RAND_CONTINUOUS_DIST_EXPONENTIAL : location parameter of exponential distribution, \( \lambda \)
NVPL_RAND_CONTINUOUS_DIST_GAMMA : shape parameter, \( \alpha > 0 \)
NVPL_RAND_CONTINUOUS_DIST_BETA : shape parameter, \( \alpha > 0 \)
NVPL_RAND_CONTINUOUS_DIST_DIRICHLET: not used
NVPL_RAND_DISCRETE_DIST_POISSON : rate parameter, \( \lambda > 0 \)
NVPL_RAND_DISCRETE_DIST_BERNOULLI : rate parameter, \( 1 >= \lambda >= 0 \)
NVPL_RAND_DISCRETE_DIST_CATEGORICAL : not used
NVPL_RAND_DISCRETE_DIST_BINOMIAL : rate parameter, \( 1 >= \lambda >= 0 \)
-
double b#
For each of the distribution type, the double value
b
needs to be defined only for the following distributions:NVPL_RAND_CONTINUOUS_DIST_UNIFORM_RANGE : end value of the range (start, end]
NVPL_RAND_CONTINUOUS_DIST_NORMAL : stddev of normal distribution
NVPL_RAND_CONTINUOUS_DIST_LOGNORMAL : stddev of associated normal distribution
NVPL_RAND_CONTINUOUS_DIST_GAMMA : scale parameter, \( \beta > 0 \)
NVPL_RAND_CONTINUOUS_DIST_BETA : shape parameter, \( \beta > 0 \)
-
double *p_array#
The double array
p_array
needs to be defined only for the following distributions:NVPL_RAND_CONTINUOUS_DIST_DIRICHLET: shape parameter arrays of size k, all > 0
NVPL_RAND_DISCRETE_DIST_CATEGORICAL: probability arrays, all >= 0
-
unsigned int nk#
The unsigned integer value
nk
needs to be defined only for the following distributions:NVPL_RAND_CONTINUOUS_DIST_DIRICHLET: size of the shape parameters
NVPL_RAND_DISCRETE_DIST_CATEGORICAL: size of the probability parameters, >1 (if =1, use Bernoulli)
NVPL_RAND_DISCRETE_DIST_BINOMIAL : size of Bernoulli trials, >1 (if =1, use Bernoulli)
NVPL_RAND_DISCRETE_DIST_MULTINOMIAL : size of the probability parameters, >1
-
unsigned int nt#
The unsigned integer value
nt
needs to be defined only for the following distribution:NVPL_RAND_DISCRETE_DIST_MULTINOMIAL : size of the Bernoulli trials >1
-
nvplRandDistributionType_t dist#