Skip to content

Commit

Permalink
docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
kashif committed Sep 13, 2024
1 parent c405183 commit c61ba39
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/gluonts/torch/distributions/spliced_binned_pareto.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,14 @@ class ExGeneralizedPareto(Distribution):
r"""
Exponentiated Generalised Pareto distribution.
Parameters
----------
xi
Tensor containing the xi (heaviness) shape parameters. The tensor is
of shape (*batch_shape, 1)
beta
Tensor containing the beta scale parameters. The tensor is of
shape (*batch_shape, 1)
Parameters
----------
xi
Tensor containing the xi (heaviness) shape parameters. The tensor is
of shape (*batch_shape, 1)
beta
Tensor containing the beta scale parameters. The tensor is of
shape (*batch_shape, 1)
"""

arg_constraints = {
Expand Down Expand Up @@ -125,7 +125,7 @@ def log_prob(self, x):

def cdf(self, x):
"""
cdf values for a tensor x of shape (*batch_shape)
Cdf values for a tensor x of shape (*batch_shape)
"""
x = x.unsqueeze(dim=-1)
x_shifted = torch.div(x, self.beta)
Expand All @@ -134,7 +134,7 @@ def cdf(self, x):

def icdf(self, value):
"""
icdf values for a tensor quantile values of shape (*batch_shape)
Icdf values for a tensor quantile values of shape (*batch_shape)
"""
value = value.unsqueeze(dim=-1)
x_shifted = torch.div(torch.pow(1 - value, -self.xi) - 1, self.xi)
Expand Down

0 comments on commit c61ba39

Please sign in to comment.