Same cluster, same model, same duration: does location change the cost?
ops
intermediate
Compare identical training runs across four grid regions to discover whether geography matters more than hardware choice or training duration for carbon footprint.
The Question
A 256-GPU cluster (32 DGX H100 nodes) trains a model for 30 days. Where that cluster is located makes no difference to latency or throughput, which the hardware fixes. For carbon emissions, water usage, and total cost of ownership, does geography matter, and if so, by how much?
NotePrerequisites
Complete Tutorial 1: The Memory Wall. No other prerequisites are required; this tutorial can be completed independently.
NoteLearning Objectives
Calculate the carbon footprint of identical training runs in different regions
Quantify the gap between the cleanest and dirtiest electricity grids
Compare geography vs. training duration as levers for sustainability
Apply the EconomicsModel to show how carbon pricing changes the cheapest option
TipBackground: Grid Carbon Intensity
Every kilowatt-hour of electricity has a carbon cost, measured in grams of \(\text{CO}_2\) per kWh (\(\text{gCO}_2/\text{kWh}\)). This number depends entirely on how the electricity is generated. Representative profiles from mlsysim.Infrastructure.Grids span nearly two orders of magnitude:
Region
Primary Source
Carbon Intensity
PUE
Norway (Hydro)
Hydroelectric
10 gCO2/kWh
1.06
Quebec (Hydro)
Hydroelectric
20 gCO2/kWh
1.06
France (Nuclear)
Nuclear
50 gCO2/kWh
1.12
US Average
Mixed (gas, coal, renewables)
429 gCO2/kWh
1.12
Iowa (Coal/Gas Reference)
Coal and gas reference
680 gCO2/kWh
1.12
India Average
Coal-dominated
720 gCO2/kWh
1.58
Poland (Coal)
Coal-dominated
820 gCO2/kWh
1.58
The range is wide (41× in grid carbon intensity between Poland and Quebec, and 82× between Poland and Norway). This tutorial quantifies how that spread interacts with facility PUE and whether it matters more than other levers such as training duration or hardware choice.
1. Setup
import mlsysimfrom mlsysim import Engine
2. Two-Region Comparison
The first comparison runs the same training job in two locations: Quebec (Hydro) (20 gCO2/kWh, PUE 1.06) and Poland (Coal) (820 gCO2/kWh, PUE 1.58). The 256-GPU fleet, the model, and the 30-day duration are identical. The only variable is where the electricity comes from.
Same cluster. Same model. Same 30-day duration. Because Poland’s grid carbon intensity is 41× higher than Quebec’s (820 vs. 20 gCO2/kWh) and its facility PUE is 1.49× higher (1.58 vs. 1.06), the total carbon footprint differs by 61× (167.2 tonnes vs. 2.7 tonnes \(\text{CO}_2\)). The difference comes from a location decision, not from an algorithmic optimization.
3. All-Region Sweep
The next sweep expands the comparison to four grid regions in the Infrastructure Zoo, adding energy consumption, water usage, and PUE to the picture.
Region Energy (MWh) Carbon (t) Water (kL) PUE
──────────────────────────────────────────────────────────
Quebec (Hydro) 136.8 2.7 0.0 1.06
Norway (Hydro) 136.8 1.4 0.0 1.06
US Average 144.5 62.0 232.2 1.12
Poland (Coal) 203.9 167.2 232.2 1.58
Total facility energy varies across regions from 136.8 MWh in Quebec (Hydro) and Norway (Hydro) (PUE 1.06) to 203.9 MWh in Poland (Coal) (PUE 1.58). On-site cooling water ranges from 0.0 kL in closed-loop cold-climate hydro facilities (\(\text{WUE}_{\text{site}} = 0.0\;\text{L/kWh}_{\text{IT}}\)) to 232.2 kL in both US Average and Poland (Coal) (both share \(\text{WUE}_{\text{site}} = 1\.8\;\text{L/kWh}_{\text{IT}}\) applied to identical pre-PUE IT equipment energy). Combined with grid carbon intensity, emissions span 1.4 t in Norway (Hydro) and 2.7 t in Quebec (Hydro) up to 167.2 t in Poland (Coal) (61× vs. Quebec and 122× vs. Norway).
4. Geography vs. Training Duration
The trade-off between training longer in a clean region and shorter in a dirty region shows up in a comparison of 30 days in Quebec (Hydro) against 10 days in Poland (Coal).
# 30 days in Quebecres_30d_quebec = solver.solve( fleet=fleet, duration_days=30, datacenter=mlsysim.Infrastructure.Grids.Quebec)# 10 days in Poland (1/3 the training time)res_10d_poland = solver.solve( fleet=fleet, duration_days=10, datacenter=mlsysim.Infrastructure.Grids.Poland)c_q = res_30d_quebec.carbon_footprint.to("metric_ton").magnitudec_p = res_10d_poland.carbon_footprint.to("metric_ton").magnitudetable( ["Scenario", "Carbon (tonnes CO2)"], [ ["30 days in Quebec", f"{c_q:.1f}"], ["10 days in Poland", f"{c_p:.1f}"], ])info(Ratio=f"{c_p/c_q:.1f}x")
Scenario Carbon (tonnes CO2)
──────────────────────────────────────
30 days in Quebec 2.7
10 days in Poland 55.7
Ratio: 20.4x
ImportantKey Insight
Geography is a larger lever than training duration for carbon footprint. Even training for one-third the time (10 days vs. 30 days) in Poland (Coal) emits 55.7 tonnes of \(\text{CO}_2\), which is 20.4× more than the full 30-day run in Quebec (Hydro) (2.7 tonnes). Because grid carbon intensity differs by 41× and total facility emissions per day differ by 61×, no plausible reduction in training time can compensate for a coal-heavy grid. For any organization serious about sustainable AI, datacenter location is not a logistics detail but a first-order systems design decision.
5. Economic Angle: When Carbon Has a Price
Carbon pricing (through taxes or cap-and-trade) gives emissions a financial cost and changes the economics of datacenter location. The cell below computes TCO with a carbon price of $50/tonne.
Region TCO ($) Carbon Cost ($) Total ($)
────────────────────────────────────────────────────
Quebec (Hydro) $218,056 $137 $218,192
Norway (Hydro) $218,056 $68 $218,124
US Average $218,985 $3,100 $222,084
Poland (Coal) $226,107 $8,358 $234,465
At $50/tonne, carbon pricing adds $137 to the 30-day run in Quebec (Hydro) (bringing total cost from $218,056 to $218,192) versus $8,358 in Poland (Coal) (bringing total cost from $226,107 to $234,465, a $16,273 spread). At higher carbon prices, this location differential grows proportionally.