gluonts.torch.distributions.generalized_pareto module#
- class gluonts.torch.distributions.generalized_pareto.GeneralizedPareto(xi, beta, validate_args=None)[source]#
Bases:
torch.distributions.distribution.Distribution
Generalised Pareto distribution.
- Parameters
- arg_constraints = {'beta': GreaterThan(lower_bound=0.0), 'xi': GreaterThan(lower_bound=0.0)}#
- has_rsample = False#
- property stddev#
Returns the standard deviation of the distribution.
- support = GreaterThan(lower_bound=0.0)#
- class gluonts.torch.distributions.generalized_pareto.GeneralizedParetoOutput[source]#
Bases:
gluonts.torch.distributions.distribution_output.DistributionOutput
- distr_cls#
alias of
gluonts.torch.distributions.generalized_pareto.GeneralizedPareto
- distribution(distr_args, loc: Optional[torch.Tensor] = None, scale: Optional[torch.Tensor] = None) gluonts.torch.distributions.generalized_pareto.GeneralizedPareto [source]#
Construct the associated distribution, given the collection of constructor arguments and, optionally, a scale tensor.
- Parameters
distr_args – Constructor arguments for the underlying Distribution type.
loc – Optional tensor, of the same shape as the batch_shape+event_shape of the resulting distribution.
scale – Optional tensor, of the same shape as the batch_shape+event_shape of the resulting distribution.
- classmethod domain_map(xi: torch.Tensor, beta: torch.Tensor) Tuple[torch.Tensor, torch.Tensor] [source]#
Converts arguments to the right shape and domain.
The domain depends on the type of distribution, while the correct shape is obtained by reshaping the trailing axis in such a way that the returned tensors define a distribution of the right event_shape.
- property event_shape: Tuple#
Shape of each individual event compatible with the output object.