Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: add flexibility to plot_upgrades_map #271

Merged
merged 14 commits into from
Apr 27, 2021

Conversation

danielolsen
Copy link
Contributor

Pull Request doc

Purpose

Allow transmission upgrades plots to be created using any interconnection, and to properly plot new branches as well as scaled branches.
Closes #267.

What the code is doing

In upgrades.py: we fix the merging of the two branch data frames to ensure that the lat/lon columns of the merged data frame include the lat/lon data of new branches.

In plot_upgrades_map.py:

  • We make use of the plot_states function to simplify border plotting.
  • Previously-hardcoded b2b_indices are now passed by the user.
  • Previously-hardcoded figure sizes can now be passed by the user (default sizing remains, which is good for plotting USA).
  • The user can specify explicit x_range and y_range, to be able to zoom into certain regions.
  • Scaling factors are now specified in pixels/GW, not pixels/MW, based on conversations in feat: improve flexibility of utilization, risk, and bind maps #266.

Testing

@danlivengood has been using this code to plot maps of Eastern scenarios with new branches.

Time estimate

10 minutes. The data frame merge is the most complex part, most everything else is just adding flexibility to previously-hardcoded values.

@danielolsen danielolsen self-assigned this Apr 26, 2021
Copy link
Collaborator

@BainanXia BainanXia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The logic makes sense. Given Research Dan has been testing this for multiple times, I believe this is good to go.

@danielolsen danielolsen force-pushed the daniel/plot_upgrades_map_flexibility branch from fceff76 to 14e5d6d Compare April 26, 2021 20:14
Copy link
Collaborator

@rouille rouille left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@danielolsen danielolsen merged commit 85b80d9 into develop Apr 27, 2021
@danielolsen danielolsen deleted the daniel/plot_upgrades_map_flexibility branch April 27, 2021 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Transmission upgrades visualization refactor
4 participants