Merge pull request #3005 from joakim-hove/sched-tuning

Access tuning class from ScheduleState
This commit is contained in:
Joakim Hove
2021-01-07 07:49:29 +01:00
committed by GitHub
2 changed files with 4 additions and 5 deletions

View File

@@ -166,8 +166,7 @@ public:
bool enableTUNING = EWOMS_GET_PARAM(TypeTag, bool, EnableTuning);
if (enableAdaptive) {
if (enableTUNING) {
adaptiveTimeStepping_ = std::make_unique<TimeStepper>(
schedule().getTuning(timer.currentStepNum()), terminalOutput_);
adaptiveTimeStepping_ = std::make_unique<TimeStepper>(schedule()[timer.currentStepNum()].tuning(), terminalOutput_);
}
else {
adaptiveTimeStepping_ = std::make_unique<TimeStepper>(terminalOutput_);
@@ -247,7 +246,7 @@ public:
if (adaptiveTimeStepping_) {
if (enableTUNING) {
if (events.hasEvent(ScheduleEvents::TUNING_CHANGE,timer.currentStepNum())) {
adaptiveTimeStepping_->updateTUNING(schedule().getTuning(timer.currentStepNum()));
adaptiveTimeStepping_->updateTUNING(schedule()[timer.currentStepNum()].tuning());
}
}