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

Pyomo update (Fixes #25) #36

Merged
merged 3 commits into from
Aug 26, 2021
Merged

Pyomo update (Fixes #25) #36

merged 3 commits into from
Aug 26, 2021

Conversation

grgmiller
Copy link
Collaborator

Fixes #25
Updates the code to work with Pyomo 6.1, from Pyomo 5.6.8, so that the code is compatible with CPLEX as a solver.
The environment.yml file has been updated to require use of Pyomo>=6.0.0 and pyutilib>=6.0.0, so continued use will require updating your environment.

Specific updates include:

  • pyomo elements with "Simple" in their name were renamed to "Scalar"
  • For any params with string elements, needed to manually specify within=Any when defining the param in order to silence a deprecation warning
  • Needed to manually specify dimen=1 for Sets that are used to index parameters when loading data
  • When loading data, you can no longer specify the index as a cross product of multiple sets (e.g. index=mod.PERIODS*mod.MONTHS). Instead, they must be specified as a list of Sets (e.g. index=[mod.PERIODS, mod.MONTHS])

Other cleanup included:

  • when loading data, replaced specifying multiple parameters as tuples with specifying them as lists, to speed the data loading process
  • Removed PERIODS_FOR_GEN_BLD_YR, and TPS_FOR_GEN_IN_PERIOD because they are not used in the model
  • changed the gen_capacity_value to elcc for Effective Load Carrying Capacity

@grgmiller grgmiller merged commit 3e0307d into dev Aug 26, 2021
@grgmiller grgmiller deleted the pyomo_update branch August 26, 2021 23:33
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.

1 participant