-
Notifications
You must be signed in to change notification settings - Fork 10
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
[ANT-2299] Enable save/restore with xpress and enable by default #959
base: develop
Are you sure you want to change the base?
Conversation
We don't necessarily write an mps file anymore
This reverts commit 764fac1.
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.
Note that when writing the master problem at the end of each iteration, we still use write_prob_mps
(which is further read in sensitivity analysis with read_prob_mps
), should we keep it like this or use save/restore as well here ?
@@ -45,6 +45,13 @@ std::function<int(XPRSprob prob, const char* filename, const char* flags)> | |||
XPRSwritebasis = nullptr; | |||
std::function<int(XPRSprob prob, const char* filename, const char* flags)> | |||
XPRSreadprob = nullptr; | |||
std::function<int(XPRSprob prob, int nr, int nc, const int mrow[], |
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.
Not related to this PR, but needed later for presolve
@@ -10,3 +10,9 @@ void Problem::read_prob_mps(const std::filesystem::path& filename) { | |||
std::tie(mc_year, week) = McYearAndWeek(filename); | |||
solver_abstract_->read_prob_mps(filename); | |||
} | |||
void Problem::save_prob(const std::filesystem::path& filename) { |
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.
Do we need to do std::tie(mc_year, week) = McYearAndWeek(filename);
similarly as in the previous function ?
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.
Maybe, will need to check
@@ -0,0 +1,5 @@ | |||
#include "gtest/gtest.h" |
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.
Need to remove
Expend solver API with save_prob and restore_prob. Mirror Xpress API to save and restore problems
Coin solvers lack save/restore options. Using those method default to writing mps files