Skip to content

bugfix : propagate avg_power min/max in CPU and RAM power consumption#481

Merged
jnioche merged 3 commits intomainfrom
fix/power-consumption-min-max-propagation
Feb 24, 2026
Merged

bugfix : propagate avg_power min/max in CPU and RAM power consumption#481
jnioche merged 3 commits intomainfrom
fix/power-consumption-min-max-propagation

Conversation

@jnioche
Copy link
Copy Markdown
Collaborator

@jnioche jnioche commented Feb 23, 2026

In ComponentCPU.model_power_consumption() and
ComponentRAM.model_power_consumption(), the returned ImpactFactor used avg_power.value for all three of value, min, and max. This collapsed the power uncertainty range to a single point, causing use-phase min/max impacts for servers and cloud instances to be identical to the central value regardless of workload uncertainty.

For CPU, the consumption profile is now evaluated at time_workload.min and time_workload.max in addition to time_workload.value, and the results are passed as min/max to set_completed(). This properly captures the power uncertainty introduced by workload variation.

For RAM, apply_consumption_profile() is load-independent (power = factor × capacity), so min/max equal value. The return is still corrected to use avg_power.min and avg_power.max for semantic correctness and to propagate any bounds set upstream.

The TODO comment marking this as unimplemented is removed.

…ption

In ComponentCPU.model_power_consumption() and
ComponentRAM.model_power_consumption(), the returned ImpactFactor used
avg_power.value for all three of value, min, and max. This collapsed
the power uncertainty range to a single point, causing use-phase
min/max impacts for servers and cloud instances to be identical to
the central value regardless of workload uncertainty.

For CPU, the consumption profile is now evaluated at time_workload.min
and time_workload.max in addition to time_workload.value, and the
results are passed as min/max to set_completed(). This properly
captures the power uncertainty introduced by workload variation.

For RAM, apply_consumption_profile() is load-independent (power =
factor × capacity), so min/max equal value. The return is still
corrected to use avg_power.min and avg_power.max for semantic
correctness and to propagate any bounds set upstream.

The TODO comment marking this as unimplemented is removed.
@jnioche jnioche marked this pull request as draft February 23, 2026 13:24
@jnioche jnioche added the bug Something isn't working label Feb 23, 2026
@jnioche jnioche marked this pull request as ready for review February 24, 2026 08:35
@jnioche jnioche added this to the 2.0.3 milestone Feb 24, 2026
Copy link
Copy Markdown
Collaborator

@jonperron jonperron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems good to me 👍

@jnioche jnioche merged commit 11f1216 into main Feb 24, 2026
7 checks passed
@jnioche jnioche deleted the fix/power-consumption-min-max-propagation branch February 24, 2026 20:00
@jnioche
Copy link
Copy Markdown
Collaborator Author

jnioche commented Feb 24, 2026

thanks @Shillaker & @jonperron

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants