New KNITRO direct solver interface#3707
Conversation
611fb3b to
0d7a162
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #3707 +/- ##
==========================================
- Coverage 89.18% 89.16% -0.03%
==========================================
Files 896 906 +10
Lines 103725 104488 +763
==========================================
+ Hits 92508 93166 +658
- Misses 11217 11322 +105
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Hi @eminyouskn - okay, so, the tests are running but a large number of them are failing. Here is part of the stacktrace: Most of the failures are just tolerance problems / the tolerance needs to be loosened. |
|
One-off failures: Second one-off: |
|
Thanks @mrmundt for the report. I didn’t run these tests locally since I didn’t have NumPy installed, and in that case, the tests are skipped. I’ll make sure to check them before pushing code from now on. I do have a question: is there a way to adjust the tolerance for all these tests at once? Ideally, we’d only change it for Knitro, but I imagine that might be more complicated. Regarding the two remaining failures, I’ve already fixed the one related to the objective. However, I’m not sure how to address the stale one, it’s not clear to me what exactly that test is supposed to check. |
|
We want this in today's release, so we are going to merge it. However, we think there are some lingering opportunities for improvement that we'd like to address with a future PR. Thanks, @eminyouskn ! |
jsiirola
left a comment
There was a problem hiding this comment.
This is great. Some notes for future development / improvements...
| This method computes the gradient of the expression with respect to all | ||
| variables and stores the results in the grad attribute. | ||
| """ | ||
| derivative = reverse_sd(self.func_expr) |
There was a problem hiding this comment.
TODO: we should evaluate the computational performance of native python symbolic derivatives. Some alternatives:
- compile the expressions into executable python code (to avoud needing to use the Pyomo expression evaluator
- use AD instead of SD (particularly the APPSI c-extension?)
Fixes NA
Summary/Motivation:
This PR introduced a new KNITRO direct solver interface.
Changes proposed in this PR:
Legal Acknowledgement
By contributing to this software project, I have read the contribution guide and agree to the following terms and conditions for my contribution: