-
-
Notifications
You must be signed in to change notification settings - Fork 438
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
SCIPBackend: Faster copy, remove_constraint methods #35103
SCIPBackend: Faster copy, remove_constraint methods #35103
Conversation
Codecov ReportBase: 88.58% // Head: 88.58% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## develop #35103 +/- ##
========================================
Coverage 88.58% 88.58%
========================================
Files 2140 2140
Lines 396961 396961
========================================
+ Hits 351655 351665 +10
+ Misses 45306 45296 -10
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
if self.constraints is None: | ||
return self.model.getNConss() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add a doctest showing this code path?
1 | ||
sage: p.add_linear_constraint([(0, 2), (1, 3)], None, 6) | ||
sage: p.add_linear_constraint([(0, 3), (1, 2)], None, 6) | ||
sage: p.remove_constraints([0, 1]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you extend this doctest to show the constraints have been removed?
It would also be good to have another doctest showing particular constraints (or just one) have been removed and the remaining are properly set.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea, I'll add these tests
Co-authored-by: Travis Scrimshaw <[email protected]>
fd00880
to
094beb3
Compare
Ready for another review? |
What is the status of this PR? |
…py_method Numerical/scipbackend faster copy method
…py_method add doctests, fix typos
Documentation preview for this PR (built with commit cc55c9e; changes) is ready! 🎉 |
Since, apparently, only very few people are using |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thank you!
Positive review for your changes from my side. Thank you! |
📚 Description
Fixes #34890
Authors: @mkoeppe, @mantepse
📝 Checklist
⌛ Dependencies