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

Modifying eol method in component.py to allow multiple split #213

Open
wants to merge 1 commit into
base: dev-circfutures
Choose a base branch
from

Conversation

jwalzberg
Copy link
Collaborator

We modified one line (line 221) in the eol_process method of component.py to allow for multiple splits between one origin and several destimation options.

Basically, we allowed any key in self.split_dict starting with factype to proceed with the split. It assumes that cost_graph will optimize the pathway and the split will not occur for pathways that do not minimize costs.

Now that any string starting with factype works we can create duplicates of the split between one origin and several destinations in the scenario.yaml file. The modified code is below:

            # Added "startswith" method to allow multiple splits from
            # same source.
            if any(key.startswith(factype) for key in self.split_dict):

@jwalzberg jwalzberg requested a review from rjhanes January 9, 2025 03:33
@jwalzberg jwalzberg added the enhancement New feature or request label Jan 9, 2025
@jwalzberg jwalzberg self-assigned this Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants