727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
|
self.data.cur_weight = Real::infinity();
master.set_weight(1.0)?;
self.data.updated = true;
debug!("First Step");
debug!(" cur_val={}", self.data.cur_val);
debug!(" cur_y={}", self.data.cur_y);
} else if nxt_ub <= descent_bnd {
step = Step::Descent;
self.cnt_descent += 1;
// Note that we must update the weight *before* we
// change the internal data, so the old information
// that caused the descent step is still available.
|
|
|
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
|
self.data.cur_weight = Real::infinity();
master.set_weight(1.0)?;
self.data.updated = true;
debug!("First Step");
debug!(" cur_val={}", self.data.cur_val);
debug!(" cur_y={:?}", self.data.cur_y);
} else if nxt_ub <= descent_bnd {
step = Step::Descent;
self.cnt_descent += 1;
// Note that we must update the weight *before* we
// change the internal data, so the old information
// that caused the descent step is still available.
|
830
831
832
833
834
835
836
837
838
839
840
841
842
843
|
self.data
.nxt_cutvals
.resize(self.problem.num_subproblems(), -Real::infinity());
self.data.cnt_remaining_mins = self.problem.num_subproblems();
// Start evaluation of all subproblems at the new candidate.
let client_tx = self.client_tx.as_ref().ok_or(Error::NotInitialized)?;
self.start_eval_time = Instant::now();
for i in 0..self.problem.num_subproblems() {
self.problem
.evaluate(
i,
self.data.nxt_y.clone(),
ChannelResultSender::new(i, client_tx.clone()),
|
>
>
|
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
|
self.data
.nxt_cutvals
.resize(self.problem.num_subproblems(), -Real::infinity());
self.data.cnt_remaining_mins = self.problem.num_subproblems();
// Start evaluation of all subproblems at the new candidate.
let client_tx = self.client_tx.as_ref().ok_or(Error::NotInitialized)?;
debug!("Evaluate");
debug!(" nxt_y={:?}", self.data.nxt_y);
self.start_eval_time = Instant::now();
for i in 0..self.problem.num_subproblems() {
self.problem
.evaluate(
i,
self.data.nxt_y.clone(),
ChannelResultSender::new(i, client_tx.clone()),
|