Closed Irieo closed 7 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
a97febe
) 89.26% compared to head (ab97cca
) 89.26%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Awesome @Irieo, to increase the awesomeness, could you add a test for it, probably in test_model.py?
Awesome @Irieo, to increase the awesomeness, could you add a test for it, probably in test_model.py?
indeed, let's keep the level of awesomeness pumped up. I added a test.
Add functionality to remove a linear expression of the objective from the model. complements already existing functionality, such as
remove_variables()
andremove_constraints()
Useful for tutorials, and more generally, for any type of programming exercises when one wants to keep variables and parameters fromn.optimize.create_model()
but use own objective.example use:
n.optimize.create_model()
n.model.objective
n.model.remove_objective()
closes https://github.com/PyPSA/linopy/issues/209