Policy

class probnum.quad.solvers.policies.Policy(batch_size)

Bases: ABC

An abstract class for a policy that acquires nodes for Bayesian quadrature.

Parameters:

batch_size (IntLike) – Size of batch of nodes when calling the policy once.

Attributes Summary

requires_rng

Whether the policy requires a random number generator when called.

Methods Summary

__call__(bq_state, rng)

Find nodes according to the policy.

Attributes Documentation

requires_rng

Whether the policy requires a random number generator when called.

Methods Documentation

abstract __call__(bq_state, rng)[source]

Find nodes according to the policy.

Parameters:
  • bq_state (BQState) – State of the BQ belief.

  • rng (Generator | None) – A random number generator.

Returns:

shape=(batch_size, input_dim) – Nodes found according to the policy.

Return type:

nodes