24template<
typename ValueType>
43 std::vector<generator::Choice<ValueType, uint32_t>>
const&
getChoices()
const;
54 bool step(uint64_t actionNumber);
98 std::shared_ptr<storm::generator::PrismNextStateGenerator<ValueType, uint32_t>>
stateGenerator;
110 std::unordered_map<uint32_t, generator::CompressedState>
idToState;
A simple implementation of the valuation interface.
This class provides a simulator interface on the prism program, and uses the next state generator.
storm::json< ValueType > getStateAsJson() const
std::unordered_map< uint32_t, generator::CompressedState > idToState
std::vector< ValueType > const & getLastRewards() const
Accessor for the last state action reward and the current state reward, added together.
storm::utility::RandomProbabilityGenerator< ValueType > generator
Random number generator.
std::shared_ptr< storm::generator::PrismNextStateGenerator< ValueType, uint32_t > > stateGenerator
Generator for the next states.
std::vector< generator::Choice< ValueType, uint32_t > > const & getChoices() const
std::vector< ValueType > lastActionRewards
Stores the action rewards from the last action.
generator::StateBehavior< ValueType > behavior
Obtained behavior of a state.
uint32_t getOrAddStateIndex(generator::CompressedState const &)
Helper function for (temp) storing states.
bool step(uint64_t actionNumber)
Make a step and randomly select the successor.
generator::CompressedState currentState
The current state in the program, in its compressed form.
std::vector< std::string > getRewardNames() const
The names of the rewards that are returned.
storm::storage::BitVectorHashMap< uint32_t > stateToId
Data structure to temp store states.
std::vector< std::string > getCurrentStateLabelling() const
bool resetToState(generator::CompressedState const &compressedState)
storm::json< ValueType > getObservationAsJson() const
void setSeed(uint64_t)
Set the simulation seed.
storm::prism::Program const & program
The program that we are simulating.
expressions::SimpleValuation getCurrentStateAsValuation() const
std::vector< ValueType > zeroRewards
Helper for last action reward construction.
std::string getCurrentStateString() const
generator::CompressedState const & getCurrentState() const
bool resetToInitial()
Reset to the (unique) initial state.
This class represents a hash-map whose keys are bit vectors.
A bit vector that is internally represented as a vector of 64-bit values.
nlohmann::basic_json< std::map, std::vector, std::string, bool, int64_t, uint64_t, ValueType > json