Skip to content

Commit

Permalink
Merge branch 'release-draft' into kk/patch/1.5.3
Browse files Browse the repository at this point in the history
  • Loading branch information
kibaekkim committed Mar 2, 2023
2 parents 3a38e9e + 918333d commit ed15ac8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
6 changes: 5 additions & 1 deletion src/Solver/DualDecomp/DdDriverMpi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,11 @@ DSP_RTN_CODE DdDriverMpi::run()
dualsol_.resize(ndualsol);
CoinCopyN(mw_->master_->getBestDualSolution(), ndualsol, &dualsol_[0]);

numNodes_ = mw_->master_->getDspOsiPtr()->getNumNodes();
if (mw_->master_->getDspOsiPtr()) {
numNodes_ = mw_->master_->getDspOsiPtr()->getNumNodes();
} else {
numNodes_ = 0;
}
numIterations_ = mw_->getIterationCount();

/** communicate */
Expand Down
7 changes: 5 additions & 2 deletions src/Solver/DualDecomp/DdDriverSerial.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ DSP_RTN_CODE DdDriverSerial::run()

/** run */
DSP_RTN_CHECK_THROW(mw_->run());

/** toc */
cputime_ = CoinCpuTime() - cputime_;
walltime_ = CoinGetTimeOfDay() - walltime_;
Expand All @@ -70,7 +69,11 @@ DSP_RTN_CODE DdDriverSerial::run()
CoinCopyN(master->getBestDualSolution(), model_->getNumCouplingRows(), &dualsol_[0]);
bestprimsol_ = primsol_;
bestdualsol_ = dualsol_;
numNodes_ = master->getDspOsiPtr()->getNumNodes();
if (master->getDspOsiPtr()) {
numNodes_ = master->getDspOsiPtr()->getNumNodes();
} else {
numNodes_ = 0;
}
numIterations_ = mw_->getIterationCount();
}
/** nullify master pointer */
Expand Down
4 changes: 4 additions & 0 deletions src/Solver/DualDecomp/DdWorkerUB.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,10 @@ DSP_RTN_CODE DdWorkerUB::createProblem() {
for (int j = 0; j < mat_reco->getNumCols(); ++j)
{
obj_reco[j] *= tss->getProbability()[sind];
}

for (int j = 0; j < mat_reco->getNumCols(); ++j)
{
if (ctype_reco[j] != 'C')
{
has_integer = true;
Expand Down

0 comments on commit ed15ac8

Please sign in to comment.