-
Notifications
You must be signed in to change notification settings - Fork 24
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
Handle dual infeasible subproblem in DwBundleDual (Issue211) #271
base: release-draft
Are you sure you want to change the base?
Conversation
Codecov ReportPatch coverage has no change and project coverage change:
Additional details and impacted files@@ Coverage Diff @@
## release-draft #271 +/- ##
==================================================
+ Coverage 11.88% 60.70% +48.82%
==================================================
Files 88 121 +33
Lines 10743 10213 -530
==================================================
+ Hits 1277 6200 +4923
+ Misses 9466 4013 -5453
☔ View full report in Codecov by Sentry. |
// // sind or s ??? | ||
// DSPdebugMessage("updated obj coefficient s: %d, sind: %d, coeff: %f\n", s, sind, osi_->si_->getObjCoefficients()[sind]); | ||
// } | ||
if (osi_->si_->getColLower()[sind] == 0.0 && osi_->si_->getColUpper()[sind] == 0.0) { |
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.
Perhaps there is a better way to check whether the bound has been updated or not.
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.
create variables that raises flags
examples/cpp/Makefile
Outdated
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.
See #269
examples/cpp/farmer.cpp
Outdated
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.
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.
Modified the initial master problem to allow dual infeasible subproblem. The master problem is changed when feasible subproblem solutions are discovered.
fix primal row rhs to zero https://github.com/Argonne-National-Laboratory/DSP/pull/271/files#diff-2d4d0cb25c1e9cb704b9bda7e46ec45f47981f1f5ab2084c8b44707c184a5967R167-R168
fix primal row rhs to one https://github.com/Argonne-National-Laboratory/DSP/pull/271/files#diff-2d4d0cb25c1e9cb704b9bda7e46ec45f47981f1f5ab2084c8b44707c184a5967R689
fix dual column to zero https://github.com/Argonne-National-Laboratory/DSP/pull/271/files#diff-2d4d0cb25c1e9cb704b9bda7e46ec45f47981f1f5ab2084c8b44707c184a5967R246-R247
relax dual column bounds https://github.com/Argonne-National-Laboratory/DSP/pull/271/files#diff-2d4d0cb25c1e9cb704b9bda7e46ec45f47981f1f5ab2084c8b44707c184a5967R246-R247
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.
I want to go through the math formulations together.
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.
Previously, columns were generated only when all the subproblems were not dual infeasible. The code was changed to addCols
for every iterations.
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.
Can you add in-line descriptions to further explain this?
src/Solver/DantzigWolfe/DwWorker.cpp
Outdated
break; | ||
case OsiGrb: | ||
// rays = osi_[s]->getUnbdRay(); | ||
throw CoinError("getPrimalRays not implemented in Gurobi.", "DwWorker", "DwWorker.cpp"); |
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.
When throwing the error, does the code print out the message that describes the solution status? If not, please add the proper message to explain the solution status.
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.
"Encountered unbounded subproblem. getPrimalRays not implemented in Gurobi."
rays = osi_[s]->getUnbdRay(); | ||
break; | ||
case OsiGrb: | ||
// rays = osi_[s]->getUnbdRay(); |
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.
Why is this commented out? This was implemented in this PR.
@@ -207,6 +207,14 @@ class DspOsiCpx : public DspOsi { | |||
CPXsetdblparam(cpx_->getEnvironmentPtr(), CPX_PARAM_EPGAP, CoinMax(0.0, CoinMin(1.0, tol))); | |||
} | |||
|
|||
/** return unbounded ray */ | |||
virtual std::vector< double * > getUnbdRay() { |
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.
Should we switch to LP here?
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.
add a description of initial solve: CPLEX Error 1254
Fail at cpx_dw_noswot and cpx_dw_dec_farmer. It works on my local machine using Gurobi and the server using CPLEX. |
The original implementation did not add cuts when at least one of the subproblems was dual infeasible. This is fixed to generate columns using extreme rays.