distributions
57 memberslucid.distributions`lucid.distributions` — probability distributions with the reference-framework's interface (sample / rsample / log_prob / entropy / …).
Mirrors the reference framework's distributions surface for the most-used univariate and
discrete families plus MultivariateNormal, Beta, Gamma, and
Dirichlet from the gamma family. See [[api-python-distributions]]
for the full surface.
Classes
Bernoulli7 methodsBernoulli distribution over .
Geometric6 methodsGeometric distribution: number of failures before the first success.
Categorical6 methodsCategorical distribution — a discrete distribution over K labelled outcomes.
OneHotCategorical5 methodsCategorical distribution with one-hot encoded samples.
FisherSnedecor5 methodsFisher-Snedecor F-distribution — ratio of two scaled Chi-squared variates.
HalfCauchy3 methodsHalf-Cauchy distribution — the absolute value of a zero-location Cauchy.
HalfNormal6 methodsHalf-Normal distribution — the absolute value of a zero-mean Normal.
Pareto7 methodsPareto distribution — a heavy-tailed power-law family on .
Weibull7 methodsWeibull distribution — a flexible family for lifetime and survival analysis.
Binomial6 methodsBinomial distribution over the number of successes in n independent trials.
NegativeBinomial5 methodsNegative Binomial distribution over the number of failures before r successes.
Poisson7 methodsPoisson distribution over the non-negative integers.
Distribution15 methodsAbstract base for a probability distribution.
ExponentialFamilyMix-in for exponential-family distributions.
Cauchy5 methodsCauchy distribution on — heavy-tailed, all moments undefined.
Exponential9 methodsExponential distribution on .
Laplace7 methodsLaplace (double-exponential) distribution on .
Beta6 methodsBeta distribution on the open interval .
Chi21 methodsChi-squared distribution with degrees of freedom.
Dirichlet6 methodsDirichlet distribution on the -simplex.
Gamma7 methodsGamma distribution on — shape/rate parameterisation.
Independent10 methodsRe-interpret rightmost batch dimensions of a base distribution as event dims.
MixtureSameFamily5 methodsFinite mixture model where all components share the same distribution family.
MultivariateNormal8 methodsMultivariate Normal (Gaussian) distribution in .
LogNormal7 methodsLog-Normal distribution: where .
Normal10 methodsUnivariate Gaussian (Normal) distribution .
RelaxedBernoulli3 methodsConcrete (Gumbel-sigmoid) relaxation of the Bernoulli distribution.
RelaxedOneHotCategorical3 methodsConcrete distribution — a continuous relaxation of OneHotCategorical.
StudentT7 methodsStudent's t-distribution with location, scale, and degrees of freedom.
AbsTransform1 methodsElement-wise absolute value (folded, not bijective).
AffineTransform2 methodsElement-wise affine bijection .
CatTransform2 methodsApply different transforms to contiguous partitions along an axis.
ComposeTransform2 methodsFunction composition of a list of transforms — left-to-right.
CorrCholeskyTransform2 methodsBijection from to Cholesky factors of correlation matrices.
CumulativeDistributionTransform2 methodsProbability-integral transform via a base distribution's CDF.
ExpTransform1 methodsElement-wise exponential bijection .
IndependentTransform2 methodsReinterpret n trailing batch dimensions of an inner transform as event dims.
LowerCholeskyTransform1 methodsBijection mapping an unconstrained matrix to a positive-diagonal Cholesky factor.
PowerTransform2 methodsElement-wise power bijection .
ReshapeTransform2 methodsPure-shape reinterpretation of the event shape .
SigmoidTransform1 methodsElement-wise sigmoid bijection .
SoftmaxTransform1 methodsSoftmax transform mapping .
StackTransform2 methodsApply a list of transforms to indexed slices along a stack axis.
StickBreakingTransform1 methodsLogistic stick-breaking bijection .
TanhTransform1 methodsElement-wise hyperbolic tangent bijection .
Transform5 methodsAbstract bijection between two measurable spaces.
TransformedDistribution5 methodsPushforward of a base distribution through a (composite) bijector.
ContinuousBernoulli5 methodsContinuous Bernoulli distribution on .
Gumbel7 methodsGumbel (Type-I extreme value) distribution on .
InverseGamma6 methodsInverse-Gamma distribution on .
Kumaraswamy6 methodsKumaraswamy distribution on .
Multinomial7 methodsMultinomial distribution over categories.
LKJCholesky4 methodsLKJ distribution over Cholesky factors of correlation matrices.
Wishart6 methodsWishart distribution over symmetric positive-definite matrices.
Uniform9 methodsContinuous Uniform distribution on the half-open interval .