cobald.decorator.standardiser module

class cobald.decorator.standardiser.Standardiser(target: Pool, minimum: float = -inf, maximum: float = inf, granularity: int = 1, backlog: float = inf, surplus: float = inf)[source]

Bases: PoolDecorator

Limits for changes to the demand of a pool

  • target – the pool on which changes are standardised

  • minimum – minimum target.demand allowed

  • maximum – maximum target.demand allowed

  • granularity – granularity of target.demand

  • surplus – how much target.demand may be above

  • backlog – how much target.demand may be below

The supply and backlog clamp the demand such that supply - backlog <= demand <= supply + surplus holds.

The default values apply no limits at all so that isolated limits may be used. When several limits are set, granularity has the weakest priority, both surplus and backlog may limit the result of granularity, and minimum and maximum overrule all other limits.

property demand: float

The volume of resources to be provided by this site