TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions

Module Contents

Classes

StationaryKernel

IsotropicStationaryKernel

OrnsteinUhlenbeck

SquaredExponentialKernel

GaussianProcess

Class for densities of the transport map type \(T_\sharp \pi\)

PoissonPointProcessDistribution

Abstract distribution \(\nu_\pi\).

PoissonPointProcessLogLikelihood

Abstract map \(T:\mathbb{R}^{d_x}\rightarrow\mathbb{R}^{d_y}\)

LogGaussianCoxProcessPosterior

Abstract distribution \(\nu_\pi\).

class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.StationaryKernel[source]

Bases: Kernel

distance(x1, x2)[source]
class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.IsotropicStationaryKernel[source]

Bases: StationaryKernel

distance(x1, x2)[source]
class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.OrnsteinUhlenbeck(l=1.0)[source]

Bases: IsotropicStationaryKernel

__call__(x1, x2)[source]
class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.SquaredExponentialKernel(l=1.0)[source]

Bases: IsotropicStationaryKernel

__call__(x1, x2)[source]
class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.GaussianProcess(pts, kernel, mu=None)[source]

Bases: TransportMaps.Distributions.PushForwardTransportMapDistribution

Class for densities of the transport map type \(T_\sharp \pi\)

Parameters:
  • transport_map (Maps.TriangularTransportMap) – transport map \(T\)

  • base_distribution (Distributions.Distribution) – distribution \(\pi\)

See also

TransportMapDistribution

class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.PoissonPointProcessDistribution(lmb)[source]

Bases: TransportMaps.Distributions.Distribution

Abstract distribution \(\nu_\pi\).

rvs(n)[source]

[Abstract] Generate \(m\) samples from the distribution.

Parameters:

m (int) – number of samples to generate

Returns:

(ndarray [\(m,d\)]) – \(m\)

\(d\)-dimensional samples

Raises:

NotImplementedError – the method needs to be defined in the sub-classes

pdf(x, *args, **kwargs)[source]

Evaluate the pdf. x is integer

log_pdf(x, *args, **kwargs)[source]

Evaluate the log_pdf. x is integer

class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.PoissonPointProcessLogLikelihood(obs, dim_in)[source]

Bases: TransportMaps.Maps.Map

Abstract map \(T:\mathbb{R}^{d_x}\rightarrow\mathbb{R}^{d_y}\)

Parameters:
  • dim_in (int) – input dimension

  • dim_out (int) – output dimension

evaluate(x, *args, **kwargs)[source]

Evaluate the log_pdf. x is integer

grad_x(x, *args, **kwargs)[source]

[Abstract] Evaluate the gradient \(\nabla_{\bf x}T\) at the points \({\bf x} \in \mathbb{R}^{m \times d_x}\).

Parameters:
  • x (ndarray [\(m,d_x\)]) – evaluation points

  • precomp (dict) – dictionary of precomputed values

  • idxs_slice (slice) – if precomputed values are present, this parameter indicates at which of the points to evaluate. The number of indices represented by idxs_slice must match x.shape[0].

Returns:

(ndarray [\(m,d_y,d_x\)]) – transformed points

Raises:

NotImplementedError – to be implemented in sub-classes

hess_x(x, *args, **kwargs)[source]

[Abstract] Evaluate the Hessian \(\nabla^2_{\bf x}T\) at the points \({\bf x} \in \mathbb{R}^{m \times d_x}\).

Parameters:
  • x (ndarray [\(m,d_x\)]) – evaluation points

  • precomp (dict) – dictionary of precomputed values

  • idxs_slice (slice) – if precomputed values are present, this parameter indicates at which of the points to evaluate. The number of indices represented by idxs_slice must match x.shape[0].

Returns:

(ndarray [\(m,d_y,d_x,d_x\)]) – transformed points

Raises:

NotImplementedError – to be implemented in sub-classes

class TransportMaps.Distributions.Examples.LogGaussianCoxProcess.LogGaussianCoxProcessDistributions.LogGaussianCoxProcessPosterior(reduced_gp, obs, full_N, full_obs_idxs, full_gp, full_lmb)[source]

Bases: TransportMaps.Distributions.Distribution

Abstract distribution \(\nu_\pi\).

pdf(x, *args, **kwargs)[source]

Evaluate \(\pi({\bf x})\)

Parameters:
  • x (ndarray [\(m,d\)]) – evaluation points

  • params (dict) – parameters

  • idxs_slice (slice) – if precomputed values are present, this parameter indicates at which of the points to evaluate. The number of indices represented by idxs_slice must match x.shape[0].

Returns:

(ndarray [\(m\)]) – values of \(\pi\)

at the x points.

Raises:

NotImplementedError – the method calls :fun:`log_pdf`

log_pdf(x, *args, **kwargs)[source]

[Abstract] Evaluate \(\log \pi({\bf x})\)

Parameters:
  • x (ndarray [\(m,d\)]) – evaluation points

  • params (dict) – parameters

  • idxs_slice (slice) – if precomputed values are present, this parameter indicates at which of the points to evaluate. The number of indices represented by idxs_slice must match x.shape[0].

Returns:

(ndarray [\(m\)]) – values of \(\log\pi\)

at the x points.

Raises:

NotImplementedError – the method needs to be defined in the sub-classes

grad_x_log_pdf(x, *args, **kwargs)[source]

[Abstract] Evaluate \(\nabla_{\bf x} \log \pi({\bf x})\)

Parameters:
  • x (ndarray [\(m,d\)]) – evaluation points

  • params (dict) – parameters

  • idxs_slice (slice) – if precomputed values are present, this parameter indicates at which of the points to evaluate. The number of indices represented by idxs_slice must match x.shape[0].

Returns:

(ndarray [\(m,d\)]) – values of

\(\nabla_x\log\pi\) at the x points.

Raises:

NotImplementedError – the method needs to be defined in the sub-classes

hess_x_log_pdf(x, *args, **kwargs)[source]

[Abstract] Evaluate \(\nabla^2_{\bf x} \log \pi({\bf x})\)

Parameters:
  • x (ndarray [\(m,d\)]) – evaluation points

  • params (dict) – parameters

  • idxs_slice (slice) – if precomputed values are present, this parameter indicates at which of the points to evaluate. The number of indices represented by idxs_slice must match x.shape[0].

Returns:

(ndarray [\(m,d,d\)]) – values of

\(\nabla^2_x\log\pi\) at the x points.

Raises:

NotImplementedError – the method needs to be defined in the sub-classes