green-coding-solutions / green-metrics-tool

Measure energy and carbon consumption of software
https://metrics.green-coding.berlin
GNU Affero General Public License v3.0
141 stars 19 forks source link

Warmup for machines added if too cool #817

Closed ArneTR closed 2 weeks ago

ArneTR commented 2 weeks ago

This PR adds a temperature gate to the cluster.

Before it was only validated that the machine is cool enough, aka back again at it's baseline temperature.

However since machines can also be in sleep and only be awakened for a measuremet they might cool down so low that it will distort the start of the measurement.

We deem this range to be 5° and will warm a machine up if that threshhold is reached.

Warmup is done though a spin-lock style loop.

github-actions[bot] commented 2 weeks ago
Eco-CI Output: Label 🖥 avg. CPU utilization [%] 🔋 Total Energy [Joules] 🔌 avg. Power [Watts] Duration [Seconds]
Total Run (incl. overhead) 22.3211 1695.37 3.76 451
Measurement #1 22.25 1695.37 3.78 449

🌳 CO2 Data: City: San Jose, Lat: 37.1835, Lon: -121.7714 IP: 52.160.165.192 CO₂ from energy is: 0.196662920 g CO₂ from manufacturing (embodied carbon) is: 0.128676527 g Carbon Intensity for this location: 116 gCO₂eq/kWh SCI: 0.325339 gCO₂eq / pipeline run emitted