Datasets:
city_id stringclasses 210
values | year int64 2.02k 2.03k | metric stringclasses 4
values | predicted_value float64 2.57 5.21k |
|---|---|---|---|
USC00042863 | 2,019 | annual_avg_temp | 66.88 |
USC00042863 | 2,019 | total_precip_in | 13.03 |
USC00042863 | 2,019 | hottest_day_temp | 103.89 |
USC00042863 | 2,019 | cdd | 1,690.03 |
USC00042863 | 2,020 | annual_avg_temp | 66.93 |
USC00042863 | 2,020 | total_precip_in | 13.03 |
USC00042863 | 2,020 | hottest_day_temp | 103.89 |
USC00042863 | 2,020 | cdd | 1,700.77 |
USC00042863 | 2,021 | annual_avg_temp | 66.99 |
USC00042863 | 2,021 | total_precip_in | 13.03 |
USC00042863 | 2,021 | hottest_day_temp | 103.89 |
USC00042863 | 2,021 | cdd | 1,711.56 |
USC00042863 | 2,022 | annual_avg_temp | 67.04 |
USC00042863 | 2,022 | total_precip_in | 13.03 |
USC00042863 | 2,022 | hottest_day_temp | 103.89 |
USC00042863 | 2,022 | cdd | 1,722.41 |
USC00042863 | 2,023 | annual_avg_temp | 67.09 |
USC00042863 | 2,023 | total_precip_in | 13.03 |
USC00042863 | 2,023 | hottest_day_temp | 103.89 |
USC00042863 | 2,023 | cdd | 1,733.3 |
USC00042863 | 2,024 | annual_avg_temp | 67.14 |
USC00042863 | 2,024 | total_precip_in | 13.03 |
USC00042863 | 2,024 | hottest_day_temp | 103.89 |
USC00042863 | 2,024 | cdd | 1,744.23 |
USC00042863 | 2,025 | annual_avg_temp | 67.19 |
USC00042863 | 2,025 | total_precip_in | 13.03 |
USC00042863 | 2,025 | hottest_day_temp | 103.89 |
USC00042863 | 2,025 | cdd | 1,755.2 |
USC00166584 | 2,019 | annual_avg_temp | 67.34 |
USC00166584 | 2,019 | total_precip_in | 56.78 |
USC00166584 | 2,019 | hottest_day_temp | 100.92 |
USC00166584 | 2,019 | cdd | 2,780.38 |
USC00166584 | 2,020 | annual_avg_temp | 67.4 |
USC00166584 | 2,020 | total_precip_in | 56.78 |
USC00166584 | 2,020 | hottest_day_temp | 100.92 |
USC00166584 | 2,020 | cdd | 2,791.74 |
USC00166584 | 2,021 | annual_avg_temp | 67.45 |
USC00166584 | 2,021 | total_precip_in | 56.78 |
USC00166584 | 2,021 | hottest_day_temp | 100.92 |
USC00166584 | 2,021 | cdd | 2,803.12 |
USC00166584 | 2,022 | annual_avg_temp | 67.5 |
USC00166584 | 2,022 | total_precip_in | 56.78 |
USC00166584 | 2,022 | hottest_day_temp | 100.92 |
USC00166584 | 2,022 | cdd | 2,814.5 |
USC00166584 | 2,023 | annual_avg_temp | 67.55 |
USC00166584 | 2,023 | total_precip_in | 56.78 |
USC00166584 | 2,023 | hottest_day_temp | 100.92 |
USC00166584 | 2,023 | cdd | 2,825.9 |
USC00166584 | 2,024 | annual_avg_temp | 67.6 |
USC00166584 | 2,024 | total_precip_in | 56.78 |
USC00166584 | 2,024 | hottest_day_temp | 100.92 |
USC00166584 | 2,024 | cdd | 2,837.31 |
USC00166584 | 2,025 | annual_avg_temp | 67.66 |
USC00166584 | 2,025 | total_precip_in | 56.78 |
USC00166584 | 2,025 | hottest_day_temp | 100.92 |
USC00166584 | 2,025 | cdd | 2,848.73 |
USC00280734 | 2,019 | annual_avg_temp | 51.69 |
USC00280734 | 2,019 | total_precip_in | 44.92 |
USC00280734 | 2,019 | hottest_day_temp | 94 |
USC00280734 | 2,019 | cdd | 779.88 |
USC00280734 | 2,020 | annual_avg_temp | 51.74 |
USC00280734 | 2,020 | total_precip_in | 44.92 |
USC00280734 | 2,020 | hottest_day_temp | 94 |
USC00280734 | 2,020 | cdd | 785.53 |
USC00280734 | 2,021 | annual_avg_temp | 51.8 |
USC00280734 | 2,021 | total_precip_in | 44.92 |
USC00280734 | 2,021 | hottest_day_temp | 94 |
USC00280734 | 2,021 | cdd | 791.2 |
USC00280734 | 2,022 | annual_avg_temp | 51.85 |
USC00280734 | 2,022 | total_precip_in | 44.92 |
USC00280734 | 2,022 | hottest_day_temp | 94 |
USC00280734 | 2,022 | cdd | 796.86 |
USC00280734 | 2,023 | annual_avg_temp | 51.9 |
USC00280734 | 2,023 | total_precip_in | 44.92 |
USC00280734 | 2,023 | hottest_day_temp | 94 |
USC00280734 | 2,023 | cdd | 802.53 |
USC00280734 | 2,024 | annual_avg_temp | 51.95 |
USC00280734 | 2,024 | total_precip_in | 44.92 |
USC00280734 | 2,024 | hottest_day_temp | 94 |
USC00280734 | 2,024 | cdd | 808.2 |
USC00280734 | 2,025 | annual_avg_temp | 52 |
USC00280734 | 2,025 | total_precip_in | 44.92 |
USC00280734 | 2,025 | hottest_day_temp | 94 |
USC00280734 | 2,025 | cdd | 813.87 |
USC00286055 | 2,019 | annual_avg_temp | 54.71 |
USC00286055 | 2,019 | total_precip_in | 49.5 |
USC00286055 | 2,019 | hottest_day_temp | 97.5 |
USC00286055 | 2,019 | cdd | 1,152.15 |
USC00286055 | 2,020 | annual_avg_temp | 54.77 |
USC00286055 | 2,020 | total_precip_in | 49.5 |
USC00286055 | 2,020 | hottest_day_temp | 97.5 |
USC00286055 | 2,020 | cdd | 1,158.79 |
USC00286055 | 2,021 | annual_avg_temp | 54.82 |
USC00286055 | 2,021 | total_precip_in | 49.5 |
USC00286055 | 2,021 | hottest_day_temp | 97.5 |
USC00286055 | 2,021 | cdd | 1,165.43 |
USC00286055 | 2,022 | annual_avg_temp | 54.87 |
USC00286055 | 2,022 | total_precip_in | 49.5 |
USC00286055 | 2,022 | hottest_day_temp | 97.5 |
USC00286055 | 2,022 | cdd | 1,172.08 |
YASS: Protostar Climate Challenge Submission
Negative result: no
Forecasts of yearly weather for 210 U.S. cities, 2019–2025, made as of the end of 2018 (no data that reveals 2019–2025 weather), for the Protostar Challenge: Climate Risk Intelligence.
Team
| Name | Hugging Face username | University, Program |
|---|---|---|
| Siddhi Apraj | @sapraj | Carnegie Mellon University, MSAII |
| Sanvi Patel | @sanvicpatel | Carnegie Mellon University, MSAII |
Method
Idea in one line: a city's level is best read from its recent years, but its trend is best read from all cities together; and a city's cooling demand grows with warming at a rate that depends on how hot the city already is.
| Metric | Model | Backtest skill vs 30-yr average |
|---|---|---|
annual_avg_temp |
recent level + national trend: mean of 2004–2018 (only years from the city's current station, if ≥ 5 such years) + national warming trend × (year − 2011). The trend is the median over the 210 cities of each city's 1979–2018 least-squares trend (+0.52 °F/decade). | +15.1 % |
cdd |
shifted history ("delta method"): for each of the city's last 15 years (current station), take that year's real daily temperatures, warm every day by national trend × (target year − that year), recompute CDD from the shifted days, and average over the 15 years. Uses the daily table (code/prep_cdd_shift.py → data/cdd_shift.parquet). |
+11.4 % |
total_precip_in |
30-year average (1989–2018) | 0 % (nothing we tried beat it) |
hottest_day_temp |
30-year average (1989–2018) | 0 % (nothing we tried beat it) |
Years count only if they pass the challenge's rule (≤ 10 missing days of the values the metric uses; for CDD we also require ≤ 10 days without both Tmax and Tmin, Days Both).
Why these choices. A city's own 30-year trend is noisy (one hot decade tilts it), so it does worse than a slope pooled across cities (+10.4 % vs +15.1 % for temperature). Station moves (32 in 1989–2018, e.g. Denver to DIA in 1995) shift a city's level, so the level window uses only the current station when possible. For CDD, a single national CDD slope treats Seattle and Phoenix alike, and CDD responds non-linearly to warming (a +1 °F shift pushes many 64 °F days over the 65 °F threshold). Our first fix scaled the national trend by each city's own CDD sensitivity (dCDD/dT from regressing yearly CDD on yearly mean temperature: median 97 CDD per °F, Phoenix ≈ 250, coolest tenth ≤ 41), which scored +10.6 %. Re-computing CDD from each city's real daily weather shifted by the expected warming captures the non-linearity exactly and scored +11.4 %, beating the baseline at all 15 origins, and was stable across window lengths (+11.4 % / +11.4 % / +11.5 % for 10 / 15 / 20 years), so we adopted it (code/experiments_v2.py).
How we checked it (no 2019–2025 data used): rolling-origin backtest inside the training data. For each origin year T = 1997, …, 2011 we used only data up to T, forecast T+1…T+7 (the challenge's 7-year horizon), and scored with the challenge's own formula (MAE vs the 30-year average needing ≥ 10 valid years). We compared ~100 configurations (code/backtest.py) plus the CDD-sensitivity model (code/backtest_extra.py) and kept, per metric, the one with the best mean skill over the 15 origins, preferring the more stable one when differences were within noise.
| Check | 30-yr avg MAE | Linear trend MAE | Our MAE |
|---|---|---|---|
| Practice run published by the organizers (train ≤ 2010, predict 2011–2018), CDD | 211.5 (published: 212) | 174.5 (published: 175) | 166.2 |
| Same practice run, average temperature (°F) | 1.66 | 1.43 | 1.37 |
Reproducing the organizers' 212 / 175 confirms our scoring code matches theirs (code/practice_run.py). Expected overall score from the backtests: about 6–7 on the 0–100 scale (≈ (15.1 + 0 + 0 + 11.4) / 4 ≈ 6.6), since precipitation and hottest day are dominated by year-to-year noise. Backtest scores vary a lot by period (e.g., the starter-code random forest scores 2.2 averaged over our 15 periods), so this number is for comparing models, not a prediction of the leaderboard.
Also tried, not adopted: forecasting daily highs and lows separately, each with its own (national or regional) trend, then averaging: +15.1 % for temperature, a tie with the simpler model.
ML bake-off (code/ml_experiments.py, results in code/ml_results.csv). We also tested machine-learning models in the same 15-origin backtest. Each was re-trained for every origin on ~125k past (city, origin, horizon) examples whose answer year was at or before the origin, with fixed default hyperparameters. Overall score on the challenge's 0–100 scale (mean skill over 15 origins):
| Model | Temp | Precip | Hottest | CDD | Overall |
|---|---|---|---|---|---|
| Our physical model (CDD-sensitivity version; the submitted shifted-history CDD scores +11.4 %) | +15.1 % | 0 | 0 | +10.5 % | 6.4 |
| Blend: physical + GBM on its residuals | +14.4 % | −0.3 % | −0.6 % | +10.6 % | 6.0 |
| Blend: physical + GBM | +14.0 % | −0.2 % | −0.6 % | +10.4 % | 5.9 |
| Ridge regression, 18 features | +9.3 % | +0.5 % | −1.9 % | +8.3 % | 4.0 |
| Gradient boosting on residuals of the physical model | +9.8 % | −1.6 % | −3.9 % | +8.0 % | 3.1 |
| Gradient boosting (absolute-error loss), 18 features | +9.0 % | −1.6 % | −3.9 % | +8.1 % | 2.9 |
| Random forest on last 10 values (starter-code style) | +8.9 % | −2.1 % | −4.0 % | +5.9 % | 2.2 |
| 30-year median | −1.8 % | −0.4 % | −0.3 % | −1.8 % | 0 |
The flexible models learn year-to-year noise that does not repeat, and tree models cannot extend a warming trend beyond the values they were trained on; pooling the trend across cities is what carries the skill.
AI Tools and Agents
- Tools and models: Claude Code (Claude Opus 5.5), as a coding agent in the Claude desktop app.
- What they did: read the challenge pages, downloaded the training data and template (read-only), wrote all code in
code/, ran the backtests, and drafted this README and the data card. - Guardrails: the agent worked under
code/AGENTS.md(the challenge's data rule). It downloaded only the challenge dataset and the template; it fetched no weather data from any other source.code/common.pystops if any input is dated after 2018. Everypredicted_valueis produced bycode/forecast.py; none came from the agent's memory. The agent made no submissions and did not upload anything.
Policy Idea
- What risk did we notice? Cooling demand is rising fastest where it is already highest. Our forecast puts the typical city's 2019–2025 CDD about 11 % above its 1989–2018 average, but the same warming (+0.52 °F/decade) adds very different amounts of demand: each +1 °F adds ~250 CDD in Phoenix or Tampa but under 50 in cool coastal cities. The largest absolute increases are in hot, fast-growing Sun Belt cities such as Galveston, Dallas–Fort Worth, Corpus Christi, Phoenix, Austin and Houston (≈ +280–330 CDD/year each;
code/analysis_cdd_by_city.csv). - What would we do about it, and who would do it? A "CDD-indexed cool-roof and shade standard": state energy offices adopt a rule that scales the required roof solar reflectance and the tree-canopy / shade target for new and re-roofed buildings by a city's forecast CDD sensitivity (published each year from data like this). Cities with high sensitivity (top quartile, ≳ 190 CDD per °F) get the strictest standard first; utilities fund it through existing efficiency rebates, since each avoided CDD cuts summer peak load.
- Why is it sustainable? Cool roofs and shade cut cooling energy with no fuel and low upkeep, lower peak demand (so fewer peaker plants), and protect people without air conditioning during heat waves. Targeting by sensitivity spends money where each degree of warming costs the most, rather than spreading it evenly.
Feedback to the Ecosystem
- What got in the way:
- No published scoring code. Each team has to re-implement the 10-missing-day rule, the "≥ 10 valid years" baseline rule and the skill formula before it can backtest. We matched the published practice run (212 / 175) only after implementing both rules exactly.
- CDD validity rule is ambiguous. The scoring note says CDD uses the Tmax/Tmin missing-day rule, while the dataset card notes 18 city-years where
Days Bothfails although Tmax and Tmin each pass. It is not stated which rule removes a CDD row from scoring. - No per-row "valid" flag.
annual_indicesstores values for invalid years (e.g., low totals from missing days) next to valid ones; a boolean column per metric would prevent silent errors. - Station changes live in a separate table.
Station Segmentis only incoverage_and_stations, andLat/Loninannual_indicesare the current station's for every year, so a user ofannual_indicesalone would not see that Denver's record mixes two locations. - Tooling: the starter code and quick start use the
datasetslibrary, which is not in the template'srequirements.txt;huggingface_hub.snapshot_download+pandas.read_parquet(both already required) were enough.
- What would fix it: publish the scorer (
score.py) and a backtest helper that takes any origin year; addvalid_<metric>columns toannual_indices; state the CDD rule in one sentence; copyStation Segmentintoannual_indices; either adddatasetstorequirements.txtor show thesnapshot_download+read_parquetroute in the quick start.
Files
| File | Content |
|---|---|
submission.csv |
Our forecasts: city_id,year,metric,predicted_value |
code/common.py |
Loads data/, applies the 10-missing-day rule, stops on any post-2018 input |
code/model.py |
The forecast models (level + pooled/regional trend; CDD sensitivity) |
code/prep_cdd_shift.py |
Builds data/cdd_shift.parquet from the daily table: each city-year's CDD if every day were 0.1…5 °F warmer |
code/cdd_shift_model.py |
The shifted-history CDD model |
code/backtest.py, code/backtest_extra.py, code/experiments_v2.py |
Rolling-origin backtests (origins 1997–2011) used to choose the models; *_results.csv hold every score |
code/ml_experiments.py |
ML bake-off (random forest, ridge, gradient boosting, blends); ml_results.csv, ml_experiments_log.txt |
code/practice_run.py |
Reproduces the organizers' practice run (212 / 175) |
code/forecast.py |
Writes submission.csv |
code/analysis.py |
Numbers for the policy idea; writes analysis_cdd_by_city.csv |
code/AGENTS.md |
Data-rule instructions given to the AI agent |
data/ |
The challenge tables our code reads; see data/README.md |
Metric codes: annual_avg_temp (°F), total_precip_in (inches), hottest_day_temp (°F), cdd (°F-days).
City IDs: the station ID from the city_info table of the training dataset (e.g., Pittsburgh = USW00094823).
How to Reproduce
pip install -r code/requirements.txtpython code/forecast.py(readsdata/, writessubmission.csv; takes a few seconds)- Optional:
python code/backtest.py,python code/backtest_extra.py,python code/experiments_v2.py,python code/ml_experiments.py(~15 min),python code/practice_run.py,python code/analysis.py - Optional, rebuild
data/cdd_shift.parquet: download thedailysubset (hf download CMU-OSPO/protostar-climate-train-to-2018 --repo-type dataset) and runpython code/prep_cdd_shift.py <path>/daily/train-00000-of-00001.parquet python code/check_submission.py
Data
- External data: none. Only the challenge dataset was used, for both the forecasts and the analysis.
- Curated data: see the data card in
data/README.md.
Training data: CMU-OSPO/protostar-climate-train-to-2018, from:
- Lai, Y., & Dzombak, D. A. (2019). Compiled historical daily temperature and precipitation data for selected 210 U.S. cities. Carnegie Mellon University. https://doi.org/10.1184/R1/7890488.v6
- Lai, Y., & Dzombak, D. A. (2019). Use of historical data to assess regional climate change. Journal of Climate, 32(14), 4299–4320. https://doi.org/10.1175/JCLI-D-18-0630.1
- Downloads last month
- 99