Create mapping between load zone IDs and time zones#339
Conversation
|
Can this data live in |
Yeah, if that would be preferred, I can definitely do that. Are you thinking that the data would live in |
Exactly. Within |
danielolsen
left a comment
There was a problem hiding this comment.
Thanks for humoring the code-golf!
BainanXia
left a comment
There was a problem hiding this comment.
Thanks for addressing the comments!
ed32ee8 to
021cb90
Compare
|
Thank you both for the feedback! |
Purpose
Create a means to map load zone IDs to time zones.
What the code is doing
Two dictionaries are created: one that maps time zones to load zone IDs and another that maps load zone IDs to time zones. The mappings were created manually. Most of the time zone to load zone ID mappings were simple (i.e., the load zone resided entirely in one time zone). Other mappings were less straightforward, especially for load zones that were in multiple time zones. The most notable of these were NE, SD, TN, and KY. Since each of these states were single load zones, I could only assign them to one time zone. In this case, I assigned the load zones to the time zone in which the majority of their load centers reside. This meant that NE (Omaha and Lincoln), SD (Sioux Falls), and TN (Nashville and Memphis) were placed in the Central time zone and KY (Louisville and Lexington) was placed in the Eastern time zone. States that had more load zones, such as TX and FL, benefitted from the mapping because load zones like El Paso, TX and the Florida Panhandle were able to be correctly attributed to their proper time zones (Mountain Time and Central Time, respectively) rather than the time zones used for the majority of their states.
Testing
I don't believe any rigorous testing is necessary. I tested the mappings to make sure the code worked as intended.
Where to look
This new code is in:
PowerSimData/powersimdata/network/usa_tamu/constants/zones.pyUsage Example/Visuals
These mappings will be used in the NREL Electrification Futures Study modules I'm working on in
PreREISE. The state-level data is labeled with local hour IDs (i.e., integers from 1 through 8760), so I need to be able to shift the data according to UTC time.Time estimate
I imagine this should be quick. Probably only a couple minutes.