GoodputScenario
Serving scenarios · Implementation: mlsysim/engine/scenario_definitions/serving.py.
Construct this scenario with keyword inputs. The fields below show the types and defaults declared by this class.
ML productivity goodput of a job on a pool: scheduling, runtime, and program goodput.
ceilings gives, per factor (“S”, “R”, “P”), the value its owner’s lever can reach; device_hour_rate is the price of one offered device-hour.
Notes
Equation: useful fraction = scheduling * runtime * program; trade ratio divides the two products.
Assumptions: The factors describe successive boundaries with compatible denominators, as defined by GoodputModel.
Excludes: A universal performance metric independent of workload or a new measurement of the factors.
References
Derivation: This configuration forwards its stored inputs to mlsysim.solvers.GoodputModel.solve. The solver contract records the equations and their provenance.
Examples
The named scenario supplies illustrative inputs; the output is calculated.
>>> from mlsysim import Scenarios
>>> case = Scenarios.Llama2_70BSharedPoolGoodput128
>>> round(float(case.result.mpg), 3)
0.282Attributes
| Name | Description |
|---|---|
| ceilings | |
| device_hour_rate | |
| program | |
| result | Modeled result from mlsysim.solvers.GoodputModel.solve using this scenario’s |
| runtime | |
| scheduling |
Methods
| Name | Description |
|---|---|
| trade_ratio | Other scenario’s modeled useful-work fraction divided by this scenario’s fraction. |
trade_ratio
engine.scenario_types.GoodputScenario.trade_ratio(other)Other scenario’s modeled useful-work fraction divided by this scenario’s fraction.
Equation: return other.result.mpg / result.mpg.
scheduling
Type: float.
Declared default: required.
runtime
Type: float.
Declared default: required.
program
Type: float.
Declared default: required.
ceilings
Type: Dict[str, float].
Declared default: {}.
device_hour_rate
Type: Optional[Quantity].
Declared default: None.
result
engine.scenario_types.GoodputScenario.result
Modeled result from mlsysim.solvers.GoodputModel.solve using this scenario’s declared inputs; see that method for units, limits, and feasibility.
Equation: Delegates the declared fields to mlsysim.solvers.GoodputModel.solve; returned quantities and feasibility follow that contract.