solvi.costs¶
Run-time costs: CostBook (system.cost_book) and MeasuredCosts (System(cost_policy="measured")). Part of
solvi.learned up to 0.7; the learned order and producer policy are in solvi.strategist.
Run-time costs: CostBook, the moving average of each part's run time (ms) that every System keeps (system.cost_book)
and updates after every ask; MeasuredCosts, the settings under which the cost-optimal planner plans with those
measurements (System(cost_policy="measured")). Moved out of solvi.learned in 0.8 (nothing here is learned).
MeasuredCosts ¶
Costs from measurements for the cost-optimal planner (System(..., cost_policy="measured") or costs=MeasuredCosts(...)).
The planner (solvi.strategy.ModelStrategist with producers="equivalent") picks the cheapest plan by the cost of each
producer: its measured run time (system.cost_book, a moving average in ms) once it has run min_samples times; before
that its declared cost=, or — undeclared — 0 ms, so that it is tried and measured (warm-up). A producer not run for
recheck asks counts 0 ms again for one plan (it may have got faster; None: never). alpha sets the smoothing of
system.cost_book (the weight of the newest run; None: keep CostBook's). System.freeze_costs() fixes the costs the planner
uses; the plan record of each trace says which cost decided each choice and where it came from.