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

Compare LPs to improve testing of constraints #433

Open
brynpickering opened this issue Mar 17, 2023 · 1 comment
Open

Compare LPs to improve testing of constraints #433

brynpickering opened this issue Mar 17, 2023 · 1 comment
Assignees
Projects
Milestone

Comments

@brynpickering
Copy link
Member

brynpickering commented Mar 17, 2023

Problem description

The new math formulation implementation (#411) has a time penalty for very small models which slows down the tests.

To speed things up, we should reduce how much of a backend model we build on testing the validity of different constraints.

Following the approach of Oemof, we can build incomplete models and then write an LP file that we do a string comparison against. Then we don't need to solve the model each time, nor do we need (or want) to run m.build() in the tests. Instead, we should use the backend API for adding constraints/variables/expressions one at a time.

Calliope version

v0.7.0-dev

@brynpickering
Copy link
Member Author

Method to do so added in #453, now we just need to implement all tests in this format.

@brynpickering brynpickering added this to the 0.7.0 milestone Apr 21, 2023
@FraSanvit FraSanvit mentioned this issue Apr 21, 2023
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
v0.7.0
Constraints as YAML
Development

No branches or pull requests

1 participant