Skip to main content

ExpertWeightTrafficScenario

Optimization scenarios · Implementation: mlsysim/engine/scenario_definitions/optimization.py.

Construct this scenario with keyword inputs. The fields below show the types and defaults declared by this class.

Weight bytes of the mixture-of-experts workload, resident and read per token, against a dense model of dense_parameters that reads every weight each step.

Notes

Equation: resident_bytes is the worked quantity; each property below states its equation and units.

Assumptions: Resident storage uses total MoE parameters while per-token expert traffic uses active parameters.

Excludes: Routing skew, expert-cache behavior, activation traffic, and communication.

References

Derivation: The equations below follow the stated counts, geometric relations, or accounting definitions; scenario inputs are supplied assumptions or observations, not fitted predictions.

Examples

Execute the registered worked inputs; this is a modeled calculation.

>>> from mlsysim import Scenarios
>>> case = Scenarios.DeepSeekV3WeightTraffic
>>> value = case.resident_bytes
>>> print(f"{value:.3f~P}")
1342.000 GB

Attributes

Name Description
active_bytes Active MoE weight traffic in GB using active parameter count.
bytes_per_param
dense_bytes Dense comparison-model weight traffic in GB.
dense_parameters
dense_to_active Dimensionless dense-to-active MoE weight ratio.
resident_bytes Resident MoE weight storage in GB using total parameter count.
resident_to_active Dimensionless resident-to-active MoE weight ratio.
workload

workload

Type: Workload.

Declared default: required.

dense_parameters

Type: Quantity.

Declared default: required.

bytes_per_param

Type: Quantity.

Declared default: required.

resident_bytes

engine.scenario_types.ExpertWeightTrafficScenario.resident_bytes

Resident MoE weight storage in GB using total parameter count.

Equation: return memory_from_params(self.workload.parameters, self.bytes_per_param).to(‘GB’)

active_bytes

engine.scenario_types.ExpertWeightTrafficScenario.active_bytes

Active MoE weight traffic in GB using active parameter count.

Equation: return memory_from_params(self.workload.active_parameters, self.bytes_per_param).to(‘GB’)

dense_bytes

engine.scenario_types.ExpertWeightTrafficScenario.dense_bytes

Dense comparison-model weight traffic in GB.

Equation: return memory_from_params(self.dense_parameters, self.bytes_per_param).to(‘GB’)

resident_to_active

engine.scenario_types.ExpertWeightTrafficScenario.resident_to_active

Dimensionless resident-to-active MoE weight ratio.

Equation: return (self.resident_bytes / self.active_bytes).to(’’).magnitude

dense_to_active

engine.scenario_types.ExpertWeightTrafficScenario.dense_to_active

Dimensionless dense-to-active MoE weight ratio.

Equation: return (self.dense_bytes / self.active_bytes).to(’’).magnitude

Back to top