Fix 2024 Interconnection Queue - #16
Open
Yunzhi-Chen wants to merge 5 commits into
Open
Conversation
ReEDS moved the county_name/state lookup from inputs/county2zone.csv to inputs/zones/county_state.csv, so the script could no longer be run against a current ReEDS checkout. Fall back to the new location, and allow the ReEDS repo to be pointed at with REEDS_PATH instead of only the hardcoded default. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Same input file (lbnl_ix_queue_data_file_thru2024.xlsx) as before; only the script changed. National 2030 cumulative queue moves 2,050 GW -> 1,976 GW (-3.6%) and the county count rises as parishes and other counties whose LBNL spelling did not match ReEDS are no longer silently dropped. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fix two bugs in
process_interconnection_queues.pythat corrupted the county-level queue limits ReEDS consumes ascap_limit— one that silently dropped queues, one that double-counted capacity — and regenerateinterconnection_queues_2024.csvaccordingly. Also repoints the county mapping, which was broken against current ReEDS main.Technical details
The two bugs
1 — counties matched on name instead of FIPS . Queues were matched to ReEDS counties on lowercased county name + state, with
.str.lower()as the only normalisation. LBNL does not always use the ReEDS spelling — Louisiana is writtenAcadia Parishwhere ReEDS hasacadia— so unmatched rows were dropped at the merge and their capacity vanished. Louisiana lost essentially its entire queue. Matching on LBNL's FIPS code fixes that, but that code is sometimes stale (Oglala Lakota SD reports46113, current46102) or several codes concatenated for multi-county projects (5301353023= 53013 + 53023) — pure FIPS matching loses 99 rows / 20.2 GW that name matching had caught. So the fix is FIPS first, county name as fallback; the two methods' blind spots are complementary. Unmatched active capacity drops from 4.4% to 1.9%, the remainder being out of ReEDS scope (e.g.MX).2 —
t_2double-counted the IA Executed queue. The final-year column was built asmax(cap_t1, cap_t2) + cap_t1rather thancap_t1 + cap_t2. The two live on separate rows andmax()was being used to broadcast one onto the other, which only works whencap_t2 > cap_t1; otherwise the IA-Executed capacity was counted twice andcap_t2disappeared (cap_t1=300, cap_t2=100gave 600 instead of 400). Thet_1column was never affected.How the fixes were verified
Plot 2024 before bug fix:

Plot 2024 after bug fix:

Plot 2024 after - before bug fix:

LLM usage: Claude Code