Privugger Distributions

continuous module

class privugger.distributions.continuous.Beta(name, alpha=1, beta=1, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.continuous.Continuous

Class for the Beta distribution

name
Type

String of the name of the random variable

alpha
Type

value for the alpha parameter. Default: 1

beta
Type

value for the beta parameter. Default: 1

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.continuous.Exponential(name, lam=1, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.continuous.Continuous

Class for the Exponential distribution

name
Type

String of the name of the random variable

lam
Type

value for the lambda parameter. Default: 1

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.continuous.Normal(name, mu=0, std=1, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.continuous.Continuous

Class for the Gaussian distribution

name
Type

String of the name of the random variable

mu
Type

value for the mean of the distribution. Default: 0

std
Type

value for the standard deviation. Default: 1

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.continuous.Uniform(name, lower=0, upper=1, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.continuous.Continuous

Class for the Uniform distribution

name
Type

String of the name of the random variable

lower
Type

int for the lower bound. Default: 0

upper
Type

int for the upper bound. Default: 1

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]

discrete module

class privugger.distributions.discrete.Bernoulli(name, p=0.5, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.discrete.Discrete

Class for the Bernoulli distribution

name
Type

String of the name of the random variable

p
Type

float value [0,1] giving the probability. Default: 0.5

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.discrete.Binomial(name, n=2, p=0.5, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.discrete.Discrete

Class for the Binomial distribution

name
Type

String of the name of the random variable

n
Type

int specifying the number of trials. Default: 2

p
Type

float value [0,1] giving the probability. Default: 0.5

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.discrete.Categorical(name, p=None, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.discrete.Discrete

Class for the Categorical distribution

name
Type

String of the name of the random variable

p
Type

Float list of probabilities

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.discrete.Constant(name, val, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.discrete.Discrete

Class for the Constant distribution

name
Type

String of the name of the random variable

val
Type

The constant value

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.discrete.DiscreteUniform(name, lower=0, upper=1, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.discrete.Discrete

Class for the Discrete Uniform distribution

name
Type

String of the name of the random variable

lower
Type

int value giving the lower bound of the values. Default: 0

upper
Type

ine value giving the upper bound of the values. Default: 1

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]
class privugger.distributions.discrete.Geometric(p=0.5, num_elements=- 1, is_hyper_param=False)[source]

Bases: privugger.distributions.discrete.Discrete

Class for the Geometric distribution

name
Type

String of the name of the random variable

p
Type

float value [0,1] giving the probability. Default: 0.5

num_elements
Type

int specifying number of RV’s

is_hyper_param
Type

Boolean specifying if this RV is used as a hyper parameter. Default: False

get_params()[source]
pymc3_dist(name, hypers)[source]
scipy_dist(name)[source]