11template<
typename ValueType, storm::OptimizationDirection Dir,
bool TrivialRowGrouping>
15 : schedulerStorage(schedulerStorage), robustIndices(robustIndices), applyUpdates(applyUpdates) {
22 void processRobustRow(ValueType&& value, uint64_t row, std::vector<std::pair<ValueType, std::pair<ValueType, uint64_t>>>
const& info) {
23 currStart = robustIndices[row];
24 for (uint64_t i = 0; i < info.size(); ++i) {
25 isConverged &= schedulerStorage[currStart + i] == info[i].second.second;
26 schedulerStorage[currStart + i] = info[i].second.second;
48 std::vector<uint64_t>& schedulerStorage;
49 std::vector<uint64_t>
const& robustIndices;
55 bool const applyUpdates;
59 std::vector<std::pair<uint64_t, ValueType>> currValues;
65template<
typename ValueType,
typename SolutionType = ValueType,
bool TrivialRowGrouping = false>
89 std::vector<SolutionType>* operandOut =
nullptr, boost::optional<std::vector<uint64_t>>
const& robustIndices = boost::none)
const;
95 template<storm::OptimizationDirection Dir, storm::OptimizationDirection RobustDir>
96 bool computeScheduler(std::vector<SolutionType>& operandIn, std::vector<ValueType>
const& offsets, std::vector<uint64_t>& schedulerStorage,
97 std::vector<SolutionType>* operandOut, boost::optional<std::vector<uint64_t>>
const& robustIndices = boost::none)
const;
100 std::shared_ptr<ValueIterationOperator<ValueType, TrivialRowGrouping, SolutionType>> viOperator;
void endOfIteration() const
RobustSchedulerTrackingBackend(std::vector< uint64_t > &schedulerStorage, std::vector< uint64_t > const &robustIndices, bool applyUpdates)
bool constexpr abort() const
void processRobustRow(ValueType &&value, uint64_t row, std::vector< std::pair< ValueType, std::pair< ValueType, uint64_t > > > const &info)
void applyUpdate(ValueType &currValue, uint64_t)
Helper class to extract optimal scheduler choices from a MinMax equation system solution.
bool computeScheduler(std::vector< SolutionType > &operandIn, std::vector< ValueType > const &offsets, storm::OptimizationDirection const &dir, std::vector< uint64_t > &schedulerStorage, UncertaintyResolutionMode uncertaintyResolutionMode, std::vector< SolutionType > *operandOut=nullptr, boost::optional< std::vector< uint64_t > > const &robustIndices=boost::none) const
Computes the optimal choices from the given solution.
This class represents the Value Iteration Operator (also known as Bellman operator).
UncertaintyResolutionMode