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

Logical flow #71

Open
wants to merge 34 commits into
base: main
Choose a base branch
from
Open

Logical flow #71

wants to merge 34 commits into from

Conversation

samgdotson
Copy link
Collaborator

Summary of changes

This PR adds a new dispatch model to osier called LogicDispatchModel that follows a hierarchy of rules to dispatch energy. It is much faster (~4x speedup) than the original DispatchModel but it is myopic and therefore results may be sub-optimal. Other benefits include:

  • No solver required, commercial or otherwise. Thus osier is more self-contained.
  • Easier to understand since the mathematics have been reduced to a sequence of comparisons.
  • Drop-in replacement for DispatchModel. No change to syntax.
  • Enables parallelization of the genetic algorithm driving the CapacityExpansion model.

Note

There are a couple of new tests for new functionality. These tests should exceed the minimum code coverage required by the pyproject.toml file (75%). More tests are desired, but not necessary, here.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Checklist for Reviewers

Reviewers should use this link to get to the
Review Checklist before they begin their review.

@samgdotson samgdotson added Comp:Core This issue has to do with the main bulk of the code or document. (methods, main content) Difficulty:2-Challenging This issue may be complex or require specialized skills. Priority:1-Critical This is the highest priority (i.e. it is blocking other work or facing a deadline). Status:5-In Review This issue has been handled, and the solution is being reviewed. (probably as a PR) Type:Feature New feature or feature request labels Dec 23, 2024
@samgdotson samgdotson added this to the SET tool example problem milestone Dec 23, 2024
@samgdotson samgdotson self-assigned this Dec 23, 2024
@pep8speaks
Copy link

pep8speaks commented Dec 23, 2024

Hello @samgdotson! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 111:80: E501 line too long (92 > 79 characters)

Line 86:29: E128 continuation line under-indented for visual indent
Line 87:29: E128 continuation line under-indented for visual indent
Line 95:51: W291 trailing whitespace

Line 642:80: E501 line too long (86 > 79 characters)
Line 755:80: E501 line too long (86 > 79 characters)

Comment last updated at 2024-12-23 18:53:30 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Comp:Core This issue has to do with the main bulk of the code or document. (methods, main content) Difficulty:2-Challenging This issue may be complex or require specialized skills. Priority:1-Critical This is the highest priority (i.e. it is blocking other work or facing a deadline). Status:5-In Review This issue has been handled, and the solution is being reviewed. (probably as a PR) Type:Feature New feature or feature request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants