MixedPolicy¶
- class itergp.methods.policies.MixedPolicy(base_policies, iters)¶
Bases:
LinearSolverPolicyMixed policy.
Policy which chooses actions based on a set of base policies.
- Parameters
base_policies (Tuple[policies.LinearSolverPolicy]) – Policies which make up the
MixedPolicy.iters (Tuple[int]) – Until which iteration (non-inclusive) to use the policy in the corresponding position in
base_policies. Assumed to be sorted in increasing order. Ifitershas one fewer entry thanbase_policies, the last policy is used for all remaining iterations.
- Return type
None
Methods Summary
__call__(solver_state[, rng])Return an action for a given solver state.
Methods Documentation
- __call__(solver_state, rng=None)[source]¶
Return an action for a given solver state.
- Parameters
solver_state (probnum.linalg.solvers.LinearSolverState) – Current state of the linear solver.
rng (Optional[SeedSequence]) – Random number generator.
- Returns
Next action to take.
- Return type
action