Browse Source

Fixed wrong size of stateLabeling if no probability 0 states were found

tempestpy_adaptions
Alexander Bork 5 years ago
parent
commit
7afc47f354
  1. 4
      src/storm-pomdp/transformer/KnownProbabilityTransformer.cpp

4
src/storm-pomdp/transformer/KnownProbabilityTransformer.cpp

@ -16,7 +16,9 @@ namespace storm {
std::map<uint64_t, uint64_t> stateMap; std::map<uint64_t, uint64_t> stateMap;
std::map<uint32_t, uint32_t> observationMap; std::map<uint32_t, uint32_t> observationMap;
storm::models::sparse::StateLabeling newLabeling(pomdp.getNumberOfStates() - prob0States.getNumberOfSetBits() - prob1States.getNumberOfSetBits() + 2);
uint64_t nrNewStates = prob0States.empty() ? 1 : 2;
storm::models::sparse::StateLabeling newLabeling(pomdp.getNumberOfStates() - prob0States.getNumberOfSetBits() - prob1States.getNumberOfSetBits() + nrNewStates);
std::vector<uint32_t> newObservations; std::vector<uint32_t> newObservations;

Loading…
Cancel
Save