From 12dda40919add16ce911f78bd39a76249741439b Mon Sep 17 00:00:00 2001 From: sjunges Date: Fri, 3 Nov 2017 00:20:18 +0100 Subject: [PATCH] split IOSettings in BuildSettings and IOSettings, refactored some dependencies on settings object away if it doesnt hurt too much, moved GSPN and PGCL settings to their own libs --- src/storm-cli-utilities/model-handling.h | 37 ++++--- .../settings/modules/GSPNExportSettings.cpp | 4 +- .../settings/modules/GSPNExportSettings.h | 0 .../settings/modules/GSPNSettings.cpp | 2 +- .../settings/modules/GSPNSettings.h | 0 src/storm-pars-cli/storm-pars.cpp | 34 +----- src/storm-pgcl-cli/storm-pgcl.cpp | 2 +- .../settings/modules/PGCLSettings.cpp | 2 +- .../settings/modules/PGCLSettings.h | 0 src/storm/api/model_descriptions.cpp | 8 +- src/storm/api/model_descriptions.h | 2 +- src/storm/builder/BuilderOptions.cpp | 6 +- src/storm/builder/ExplicitModelBuilder.cpp | 4 +- .../parser/ImcaMarkovAutomatonParser.cpp | 4 +- src/storm/parser/PrismParser.cpp | 14 +-- src/storm/parser/PrismParser.h | 8 +- src/storm/settings/SettingsManager.cpp | 3 +- src/storm/settings/modules/BuildSettings.cpp | 95 ++++++++++++++++ src/storm/settings/modules/BuildSettings.h | 84 ++++++++++++++ src/storm/settings/modules/CoreSettings.h | 4 +- src/storm/settings/modules/IOSettings.cpp | 104 ++++-------------- src/storm/settings/modules/IOSettings.h | 81 +------------- src/storm/solver/AbstractEquationSolver.cpp | 1 - src/storm/storage/prism/Program.cpp | 20 ++-- src/storm/storage/prism/Program.h | 4 +- .../storm/builder/DdJaniModelBuilderTest.cpp | 26 ++--- .../storm/builder/DdPrismModelBuilderTest.cpp | 28 ++--- .../builder/ExplicitJaniModelBuilderTest.cpp | 14 +-- .../ExplicitJitJaniModelBuilderTest.cpp | 15 +-- .../builder/ExplicitPrismModelBuilderTest.cpp | 14 +-- .../GmmxxCtmcCslModelCheckerTest.cpp | 25 +---- .../GmmxxHybridCtmcCslModelCheckerTest.cpp | 45 ++------ .../NativeCtmcCslModelCheckerTest.cpp | 25 +---- .../NativeHybridCtmcCslModelCheckerTest.cpp | 42 ++----- 34 files changed, 340 insertions(+), 417 deletions(-) rename src/{storm => storm-gspn}/settings/modules/GSPNExportSettings.cpp (97%) rename src/{storm => storm-gspn}/settings/modules/GSPNExportSettings.h (100%) rename src/{storm => storm-gspn}/settings/modules/GSPNSettings.cpp (98%) rename src/{storm => storm-gspn}/settings/modules/GSPNSettings.h (100%) rename src/{storm => storm-pgcl}/settings/modules/PGCLSettings.cpp (98%) rename src/{storm => storm-pgcl}/settings/modules/PGCLSettings.h (100%) create mode 100644 src/storm/settings/modules/BuildSettings.cpp create mode 100644 src/storm/settings/modules/BuildSettings.h diff --git a/src/storm-cli-utilities/model-handling.h b/src/storm-cli-utilities/model-handling.h index d91d84479..35a8a0196 100644 --- a/src/storm-cli-utilities/model-handling.h +++ b/src/storm-cli-utilities/model-handling.h @@ -27,6 +27,7 @@ #include "storm/settings/SettingsManager.h" #include "storm/settings/modules/ResourceSettings.h" #include "storm/settings/modules/JitBuilderSettings.h" +#include "storm/settings/modules/BuildSettings.h" #include "storm/settings/modules/DebugSettings.h" #include "storm/settings/modules/IOSettings.h" #include "storm/settings/modules/CoreSettings.h" @@ -50,7 +51,7 @@ namespace storm { void parseSymbolicModelDescription(storm::settings::modules::IOSettings const& ioSettings, SymbolicInput& input) { if (ioSettings.isPrismOrJaniInputSet()) { if (ioSettings.isPrismInputSet()) { - input.model = storm::api::parseProgram(ioSettings.getPrismInputFilename()); + input.model = storm::api::parseProgram(ioSettings.getPrismInputFilename(), storm::settings::getModule().isPrismCompatibilityEnabled()); } else { auto janiInput = storm::api::parseJaniModel(ioSettings.getJaniInputFilename()); input.model = janiInput.first; @@ -95,6 +96,7 @@ namespace storm { SymbolicInput preprocessSymbolicInput(SymbolicInput const& input) { auto ioSettings = storm::settings::getModule(); + auto buildSettings = storm::settings::getModule(); auto coreSettings = storm::settings::getModule(); SymbolicInput output = input; @@ -113,7 +115,7 @@ namespace storm { // Check whether conversion for PRISM to JANI is requested or necessary. if (input.model && input.model.get().isPrismProgram()) { bool transformToJani = ioSettings.isPrismToJaniSet(); - bool transformToJaniForJit = coreSettings.getEngine() == storm::settings::modules::CoreSettings::Engine::Sparse && ioSettings.isJitSet(); + bool transformToJaniForJit = coreSettings.getEngine() == storm::settings::modules::CoreSettings::Engine::Sparse && buildSettings.isJitSet(); STORM_LOG_WARN_COND(transformToJani || !transformToJaniForJit, "The JIT-based model builder is only available for JANI models, automatically converting the PRISM input model."); transformToJani |= transformToJaniForJit; @@ -171,22 +173,22 @@ namespace storm { template std::shared_ptr buildModelDd(SymbolicInput const& input) { - return storm::api::buildSymbolicModel(input.model.get(), createFormulasToRespect(input.properties), storm::settings::getModule().isBuildFullModelSet()); + return storm::api::buildSymbolicModel(input.model.get(), createFormulasToRespect(input.properties), storm::settings::getModule().isBuildFullModelSet()); } template - std::shared_ptr buildModelSparse(SymbolicInput const& input, storm::settings::modules::IOSettings const& ioSettings) { + std::shared_ptr buildModelSparse(SymbolicInput const& input, storm::settings::modules::BuildSettings const& buildSettings) { auto counterexampleGeneratorSettings = storm::settings::getModule(); storm::builder::BuilderOptions options(createFormulasToRespect(input.properties)); - options.setBuildChoiceLabels(ioSettings.isBuildChoiceLabelsSet()); - options.setBuildStateValuations(ioSettings.isBuildStateValuationsSet()); + options.setBuildChoiceLabels(buildSettings.isBuildChoiceLabelsSet()); + options.setBuildStateValuations(buildSettings.isBuildStateValuationsSet()); options.setBuildChoiceOrigins(counterexampleGeneratorSettings.isMinimalCommandSetGenerationSet()); - options.setBuildAllLabels(ioSettings.isBuildFullModelSet()); - options.setBuildAllRewardModels(ioSettings.isBuildFullModelSet()); - if (ioSettings.isBuildFullModelSet()) { + options.setBuildAllLabels(buildSettings.isBuildFullModelSet()); + options.setBuildAllRewardModels(buildSettings.isBuildFullModelSet()); + if (buildSettings.isBuildFullModelSet()) { options.clearTerminalStates(); } - return storm::api::buildSparseModel(input.model.get(), options, ioSettings.isJitSet(), storm::settings::getModule().isDoctorSet()); + return storm::api::buildSparseModel(input.model.get(), options, buildSettings.isJitSet(), storm::settings::getModule().isDoctorSet()); } template @@ -206,13 +208,14 @@ namespace storm { template std::shared_ptr buildModel(storm::settings::modules::CoreSettings::Engine const& engine, SymbolicInput const& input, storm::settings::modules::IOSettings const& ioSettings) { storm::utility::Stopwatch modelBuildingWatch(true); + auto buildSettings = storm::settings::getModule(); std::shared_ptr result; if (input.model) { if (engine == storm::settings::modules::CoreSettings::Engine::Dd || engine == storm::settings::modules::CoreSettings::Engine::Hybrid) { result = buildModelDd(input); } else if (engine == storm::settings::modules::CoreSettings::Engine::Sparse) { - result = buildModelSparse(input, ioSettings); + result = buildModelSparse(input, buildSettings); } } else if (ioSettings.isExplicitSet() || ioSettings.isExplicitDRNSet() || ioSettings.isExplicitIMCASet()) { STORM_LOG_THROW(engine == storm::settings::modules::CoreSettings::Engine::Sparse, storm::exceptions::InvalidSettingsException, "Can only use sparse engine with explicit input."); @@ -254,18 +257,17 @@ namespace storm { std::pair>, bool> preprocessSparseModel(std::shared_ptr> const& model, SymbolicInput const& input) { auto generalSettings = storm::settings::getModule(); auto bisimulationSettings = storm::settings::getModule(); - auto ioSettings = storm::settings::getModule(); std::pair>, bool> result = std::make_pair(model, false); if (result.first->isOfType(storm::models::ModelType::MarkovAutomaton)) { - result.first = preprocessSparseMarkovAutomaton(result.first->template as>()); - result.second = true; + result.first = preprocessSparseMarkovAutomaton(result.first->template as>()); + result.second = true; } if (generalSettings.isBisimulationSet()) { - result.first = preprocessSparseModelBisimulation(result.first, input, bisimulationSettings); - result.second = true; + result.first = preprocessSparseModelBisimulation(result.first, input, bisimulationSettings); + result.second = true; } return result; @@ -597,8 +599,9 @@ namespace storm { template std::shared_ptr buildPreprocessExportModelWithValueTypeAndDdlib(SymbolicInput const& input, storm::settings::modules::CoreSettings::Engine engine) { auto ioSettings = storm::settings::getModule(); + auto buildSettings = storm::settings::getModule(); std::shared_ptr model; - if (!ioSettings.isNoBuildModelSet()) { + if (!buildSettings.isNoBuildModelSet()) { model = buildModel(engine, input, ioSettings); } diff --git a/src/storm/settings/modules/GSPNExportSettings.cpp b/src/storm-gspn/settings/modules/GSPNExportSettings.cpp similarity index 97% rename from src/storm/settings/modules/GSPNExportSettings.cpp rename to src/storm-gspn/settings/modules/GSPNExportSettings.cpp index 8a5c315dc..a3c46f250 100644 --- a/src/storm/settings/modules/GSPNExportSettings.cpp +++ b/src/storm-gspn/settings/modules/GSPNExportSettings.cpp @@ -1,5 +1,5 @@ -#include "GSPNExportSettings.h" -#include "JaniExportSettings.h" +#include "storm-gspn/settings/modules/GSPNExportSettings.h" +#include "storm/settings/modules/JaniExportSettings.h" #include "storm/settings/SettingsManager.h" #include "storm/settings/SettingMemento.h" diff --git a/src/storm/settings/modules/GSPNExportSettings.h b/src/storm-gspn/settings/modules/GSPNExportSettings.h similarity index 100% rename from src/storm/settings/modules/GSPNExportSettings.h rename to src/storm-gspn/settings/modules/GSPNExportSettings.h diff --git a/src/storm/settings/modules/GSPNSettings.cpp b/src/storm-gspn/settings/modules/GSPNSettings.cpp similarity index 98% rename from src/storm/settings/modules/GSPNSettings.cpp rename to src/storm-gspn/settings/modules/GSPNSettings.cpp index 9184f9137..2a0588b3d 100644 --- a/src/storm/settings/modules/GSPNSettings.cpp +++ b/src/storm-gspn/settings/modules/GSPNSettings.cpp @@ -1,4 +1,4 @@ -#include "GSPNSettings.h" +#include "storm-gspn/settings/modules/GSPNSettings.h" #include "storm/settings/SettingsManager.h" #include "storm/settings/SettingMemento.h" diff --git a/src/storm/settings/modules/GSPNSettings.h b/src/storm-gspn/settings/modules/GSPNSettings.h similarity index 100% rename from src/storm/settings/modules/GSPNSettings.h rename to src/storm-gspn/settings/modules/GSPNSettings.h diff --git a/src/storm-pars-cli/storm-pars.cpp b/src/storm-pars-cli/storm-pars.cpp index 907688ef4..8a8c9fa6a 100644 --- a/src/storm-pars-cli/storm-pars.cpp +++ b/src/storm-pars-cli/storm-pars.cpp @@ -29,34 +29,6 @@ namespace storm { typedef typename storm::cli::SymbolicInput SymbolicInput; - template - std::shared_ptr buildModelSparse(SymbolicInput const& input, storm::settings::modules::IOSettings const& ioSettings) { - return storm::api::buildSparseModel(input.model.get(), storm::api::extractFormulasFromProperties(input.properties), ioSettings.isBuildChoiceLabelsSet()); - } - - template - std::shared_ptr buildModel(storm::settings::modules::CoreSettings::Engine const& engine, SymbolicInput const& input, storm::settings::modules::IOSettings const& ioSettings) { - storm::utility::Stopwatch modelBuildingWatch(true); - - std::shared_ptr result; - if (input.model) { - if (engine == storm::settings::modules::CoreSettings::Engine::Dd || engine == storm::settings::modules::CoreSettings::Engine::Hybrid) { - result = storm::cli::buildModelDd(input); - } else if (engine == storm::settings::modules::CoreSettings::Engine::Sparse) { - result = storm::pars::buildModelSparse(input, ioSettings); - } - } else if (ioSettings.isExplicitSet() || ioSettings.isExplicitDRNSet()) { - STORM_LOG_THROW(engine == storm::settings::modules::CoreSettings::Engine::Sparse, storm::exceptions::InvalidSettingsException, "Can only use sparse engine with explicit input."); - result = storm::cli::buildModelExplicit(ioSettings); - } - - modelBuildingWatch.stop(); - if (result) { - STORM_PRINT_AND_LOG("Time for model construction: " << modelBuildingWatch << "." << std::endl << std::endl); - } - - return result; - } template @@ -271,14 +243,16 @@ namespace storm { void processInputWithValueTypeAndDdlib(SymbolicInput& input) { auto coreSettings = storm::settings::getModule(); auto ioSettings = storm::settings::getModule(); + + auto buildSettings = storm::settings::getModule(); auto parSettings = storm::settings::getModule(); auto engine = coreSettings.getEngine(); STORM_LOG_THROW(engine == storm::settings::modules::CoreSettings::Engine::Sparse || engine == storm::settings::modules::CoreSettings::Engine::Hybrid || engine == storm::settings::modules::CoreSettings::Engine::Dd, storm::exceptions::InvalidSettingsException, "The selected engine is not supported for parametric models."); std::shared_ptr model; - if (!ioSettings.isNoBuildModelSet()) { - model = storm::pars::buildModel(engine, input, ioSettings); + if (!buildSettings.isNoBuildModelSet()) { + model = storm::cli::buildModel(engine, input, ioSettings); } if (model) { diff --git a/src/storm-pgcl-cli/storm-pgcl.cpp b/src/storm-pgcl-cli/storm-pgcl.cpp index ce579938f..bfbb6cad4 100644 --- a/src/storm-pgcl-cli/storm-pgcl.cpp +++ b/src/storm-pgcl-cli/storm-pgcl.cpp @@ -15,7 +15,7 @@ #include "storm/settings/SettingsManager.h" #include "storm/settings/modules/GeneralSettings.h" #include "storm/settings/modules/ResourceSettings.h" -#include "storm/settings/modules/PGCLSettings.h" +#include "storm-pgcl/settings/modules/PGCLSettings.h" #include "storm/settings/modules/CoreSettings.h" #include "storm/settings/modules/DebugSettings.h" #include "storm/settings/modules/JaniExportSettings.h" diff --git a/src/storm/settings/modules/PGCLSettings.cpp b/src/storm-pgcl/settings/modules/PGCLSettings.cpp similarity index 98% rename from src/storm/settings/modules/PGCLSettings.cpp rename to src/storm-pgcl/settings/modules/PGCLSettings.cpp index 5035f3632..a70b87f6f 100644 --- a/src/storm/settings/modules/PGCLSettings.cpp +++ b/src/storm-pgcl/settings/modules/PGCLSettings.cpp @@ -1,4 +1,4 @@ -#include "storm/settings/modules/PGCLSettings.h" +#include "PGCLSettings.h" #include "storm/settings/SettingsManager.h" #include "storm/settings/SettingMemento.h" diff --git a/src/storm/settings/modules/PGCLSettings.h b/src/storm-pgcl/settings/modules/PGCLSettings.h similarity index 100% rename from src/storm/settings/modules/PGCLSettings.h rename to src/storm-pgcl/settings/modules/PGCLSettings.h diff --git a/src/storm/api/model_descriptions.cpp b/src/storm/api/model_descriptions.cpp index bd1e399f3..76ce24116 100644 --- a/src/storm/api/model_descriptions.cpp +++ b/src/storm/api/model_descriptions.cpp @@ -6,11 +6,15 @@ #include "storm/storage/jani/Model.h" #include "storm/storage/jani/Property.h" + +#include "storm/settings/SettingsManager.h" +#include "storm/settings/modules/BuildSettings.h" + namespace storm { namespace api { - storm::prism::Program parseProgram(std::string const& filename) { - storm::prism::Program program = storm::parser::PrismParser::parse(filename).simplify().simplify(); + storm::prism::Program parseProgram(std::string const& filename, bool prismCompatibility) { + storm::prism::Program program = storm::parser::PrismParser::parse(filename, prismCompatibility).simplify().simplify(); program.checkValidity(); return program; } diff --git a/src/storm/api/model_descriptions.h b/src/storm/api/model_descriptions.h index 99ab5d24d..533c5e8d1 100644 --- a/src/storm/api/model_descriptions.h +++ b/src/storm/api/model_descriptions.h @@ -14,7 +14,7 @@ namespace storm { namespace api { - storm::prism::Program parseProgram(std::string const& filename); + storm::prism::Program parseProgram(std::string const& filename, bool prismCompatibility = false); std::pair> parseJaniModel(std::string const& filename); diff --git a/src/storm/builder/BuilderOptions.cpp b/src/storm/builder/BuilderOptions.cpp index 2ee5bf37c..00718e3f1 100644 --- a/src/storm/builder/BuilderOptions.cpp +++ b/src/storm/builder/BuilderOptions.cpp @@ -3,7 +3,7 @@ #include "storm/logic/Formulas.h" #include "storm/settings/SettingsManager.h" -#include "storm/settings/modules/IOSettings.h" +#include "storm/settings/modules/BuildSettings.h" #include "storm/settings/modules/GeneralSettings.h" #include "storm/utility/macros.h" @@ -55,9 +55,9 @@ namespace storm { } } - auto const& ioSettings = storm::settings::getModule(); + auto const& buildSettings = storm::settings::getModule(); auto const& generalSettings = storm::settings::getModule(); - explorationChecks = ioSettings.isExplorationChecksSet(); + explorationChecks = buildSettings.isExplorationChecksSet(); showProgress = generalSettings.isVerboseSet(); showProgressDelay = generalSettings.getShowProgressDelay(); } diff --git a/src/storm/builder/ExplicitModelBuilder.cpp b/src/storm/builder/ExplicitModelBuilder.cpp index 48d5b2a75..d4aa08590 100644 --- a/src/storm/builder/ExplicitModelBuilder.cpp +++ b/src/storm/builder/ExplicitModelBuilder.cpp @@ -11,7 +11,7 @@ #include "storm/storage/expressions/ExpressionManager.h" #include "storm/settings/modules/CoreSettings.h" -#include "storm/settings/modules/IOSettings.h" +#include "storm/settings/modules/BuildSettings.h" #include "storm/builder/RewardModelBuilder.h" #include "storm/builder/ChoiceInformationBuilder.h" @@ -43,7 +43,7 @@ namespace storm { namespace builder { template - ExplicitModelBuilder::Options::Options() : explorationOrder(storm::settings::getModule().getExplorationOrder()) { + ExplicitModelBuilder::Options::Options() : explorationOrder(storm::settings::getModule().getExplorationOrder()) { // Intentionally left empty. } diff --git a/src/storm/parser/ImcaMarkovAutomatonParser.cpp b/src/storm/parser/ImcaMarkovAutomatonParser.cpp index c00b44497..01cb93671 100644 --- a/src/storm/parser/ImcaMarkovAutomatonParser.cpp +++ b/src/storm/parser/ImcaMarkovAutomatonParser.cpp @@ -1,7 +1,7 @@ #include "storm/parser/ImcaMarkovAutomatonParser.h" #include "storm/settings/SettingsManager.h" -#include "storm/settings/modules/IOSettings.h" +#include "storm/settings/modules/BuildSettings.h" #include "storm/settings/modules/CoreSettings.h" #include "storm/utility/file.h" #include "storm/utility/builder.h" @@ -11,7 +11,7 @@ namespace storm { template ImcaParserGrammar::ImcaParserGrammar() : ImcaParserGrammar::base_type(start), numStates(0), numChoices(0), numTransitions(0), hasStateReward(false), hasActionReward(false) { - buildChoiceLabels = storm::settings::getModule().isBuildChoiceLabelsSet(); + buildChoiceLabels = storm::settings::getModule().isBuildChoiceLabelsSet(); initialize(); } diff --git a/src/storm/parser/PrismParser.cpp b/src/storm/parser/PrismParser.cpp index 38ed0cb12..18f42d39c 100644 --- a/src/storm/parser/PrismParser.cpp +++ b/src/storm/parser/PrismParser.cpp @@ -2,7 +2,6 @@ #include "storm/storage/prism/Compositions.h" -#include "storm/settings/SettingsManager.h" #include "storm/exceptions/InvalidArgumentException.h" #include "storm/exceptions/InvalidTypeException.h" @@ -16,7 +15,7 @@ namespace storm { namespace parser { - storm::prism::Program PrismParser::parse(std::string const& filename) { + storm::prism::Program PrismParser::parse(std::string const& filename, bool prismCompatibility) { // Open file and initialize result. std::ifstream inputFileStream; storm::utility::openFile(filename, inputFileStream); @@ -25,7 +24,7 @@ namespace storm { // Now try to parse the contents of the file. try { std::string fileContent((std::istreambuf_iterator(inputFileStream)), (std::istreambuf_iterator())); - result = parseFromString(fileContent, filename); + result = parseFromString(fileContent, filename, prismCompatibility); } catch(std::exception& e) { // In case of an exception properly close the file before passing exception. storm::utility::closeFile(inputFileStream); @@ -37,7 +36,7 @@ namespace storm { return result; } - storm::prism::Program PrismParser::parseFromString(std::string const& input, std::string const& filename) { + storm::prism::Program PrismParser::parseFromString(std::string const& input, std::string const& filename, bool prismCompatibility) { PositionIteratorType first(input.begin()); PositionIteratorType iter = first; PositionIteratorType last(input.end()); @@ -47,7 +46,7 @@ namespace storm { storm::prism::Program result; // Create grammar. - storm::parser::PrismParser grammar(filename, first); + storm::parser::PrismParser grammar(filename, first, prismCompatibility); try { // Start first run. bool succeeded = qi::phrase_parse(iter, last, grammar, boost::spirit::ascii::space | qi::lit("//") >> *(qi::char_ - (qi::eol | qi::eoi)) >> (qi::eol | qi::eoi), result); @@ -74,7 +73,7 @@ namespace storm { return result; } - PrismParser::PrismParser(std::string const& filename, Iterator first) : PrismParser::base_type(start), secondRun(false), filename(filename), annotate(first), manager(new storm::expressions::ExpressionManager()), expressionParser(new ExpressionParser(*manager, keywords_, false, false)) { + PrismParser::PrismParser(std::string const& filename, Iterator first, bool prismCompatibility) : PrismParser::base_type(start), secondRun(false), prismCompatibility(prismCompatibility), filename(filename), annotate(first), manager(new storm::expressions::ExpressionManager()), expressionParser(new ExpressionParser(*manager, keywords_, false, false)) { ExpressionParser& expression_ = *expressionParser; // Parse simple identifier. @@ -671,8 +670,9 @@ namespace storm { STORM_LOG_WARN("Program does not specify model type. Implicitly assuming 'mdp'."); finalModelType = storm::prism::Program::ModelType::MDP; } + - return storm::prism::Program(manager, finalModelType, globalProgramInformation.constants, globalProgramInformation.globalBooleanVariables, globalProgramInformation.globalIntegerVariables, globalProgramInformation.formulas, globalProgramInformation.modules, globalProgramInformation.actionIndices, globalProgramInformation.rewardModels, globalProgramInformation.labels, secondRun && !globalProgramInformation.hasInitialConstruct ? boost::none : boost::make_optional(globalProgramInformation.initialConstruct), globalProgramInformation.systemCompositionConstruct, this->getFilename(), 1, this->secondRun); + return storm::prism::Program(manager, finalModelType, globalProgramInformation.constants, globalProgramInformation.globalBooleanVariables, globalProgramInformation.globalIntegerVariables, globalProgramInformation.formulas, globalProgramInformation.modules, globalProgramInformation.actionIndices, globalProgramInformation.rewardModels, globalProgramInformation.labels, secondRun && !globalProgramInformation.hasInitialConstruct ? boost::none : boost::make_optional(globalProgramInformation.initialConstruct), globalProgramInformation.systemCompositionConstruct, prismCompatibility, this->getFilename(), 1, this->secondRun); } void PrismParser::removeInitialConstruct(GlobalProgramInformation& globalProgramInformation) const { diff --git a/src/storm/parser/PrismParser.h b/src/storm/parser/PrismParser.h index 129cd7b43..fe7f0bc83 100644 --- a/src/storm/parser/PrismParser.h +++ b/src/storm/parser/PrismParser.h @@ -77,7 +77,7 @@ namespace storm { * @param filename the name of the file to parse. * @return The resulting PRISM program. */ - static storm::prism::Program parse(std::string const& filename); + static storm::prism::Program parse(std::string const& filename, bool prismCompatability = false); /*! * Parses the given input stream into the PRISM storage classes assuming it complies with the PRISM syntax. @@ -86,7 +86,7 @@ namespace storm { * @param filename The name of the file from which the input was read. * @return The resulting PRISM program. */ - static storm::prism::Program parseFromString(std::string const& input, std::string const& filename); + static storm::prism::Program parseFromString(std::string const& input, std::string const& filename, bool prismCompatability = false); private: struct modelTypeStruct : qi::symbols { @@ -150,7 +150,7 @@ namespace storm { * @param filename The filename that is to be read. This is used for proper error reporting. * @param first The iterator to the beginning of the input. */ - PrismParser(std::string const& filename, Iterator first); + PrismParser(std::string const& filename, Iterator first, bool prismCompatibility); /*! * Sets an internal flag that indicates the second run is now taking place. @@ -159,6 +159,8 @@ namespace storm { // A flag that stores whether the grammar is currently doing the second run. bool secondRun; + + bool prismCompatibility; /*! * Sets whether doubles literals are allowed in the parsed expression. diff --git a/src/storm/settings/SettingsManager.cpp b/src/storm/settings/SettingsManager.cpp index b271ca581..188d1cba2 100644 --- a/src/storm/settings/SettingsManager.cpp +++ b/src/storm/settings/SettingsManager.cpp @@ -1,7 +1,6 @@ #include "storm/settings/SettingsManager.h" #include -#include #include #include #include @@ -19,6 +18,7 @@ #include "storm/settings/modules/DebugSettings.h" #include "storm/settings/modules/CounterexampleGeneratorSettings.h" #include "storm/settings/modules/CuddSettings.h" +#include "storm/settings/modules/BuildSettings.h" #include "storm/settings/modules/SylvanSettings.h" #include "storm/settings/modules/EigenEquationSolverSettings.h" #include "storm/settings/modules/GmmxxEquationSolverSettings.h" @@ -511,6 +511,7 @@ namespace storm { // Register all known settings modules. storm::settings::addModule(); storm::settings::addModule(); + storm::settings::addModule(); storm::settings::addModule(); storm::settings::addModule(); storm::settings::addModule(); diff --git a/src/storm/settings/modules/BuildSettings.cpp b/src/storm/settings/modules/BuildSettings.cpp new file mode 100644 index 000000000..a813b08fa --- /dev/null +++ b/src/storm/settings/modules/BuildSettings.cpp @@ -0,0 +1,95 @@ +#include "storm/settings/modules/BuildSettings.h" + +#include "storm/settings/SettingsManager.h" +#include "storm/settings/SettingMemento.h" +#include "storm/settings/Option.h" +#include "storm/settings/OptionBuilder.h" +#include "storm/settings/ArgumentBuilder.h" +#include "storm/settings/Argument.h" +#include "storm/exceptions/InvalidSettingsException.h" +#include "storm/parser/CSVParser.h" + +#include "storm/utility/macros.h" +#include "storm/exceptions/IllegalArgumentValueException.h" + +namespace storm { + namespace settings { + namespace modules { + + const std::string BuildSettings::moduleName = "build"; + + const std::string jitOptionName = "jit"; + const std::string explorationOrderOptionName = "explorder"; + const std::string explorationOrderOptionShortName = "eo"; + const std::string explorationChecksOptionName = "explchecks"; + const std::string explorationChecksOptionShortName = "ec"; + const std::string prismCompatibilityOptionName = "prismcompat"; + const std::string prismCompatibilityOptionShortName = "pc"; + const std::string noBuildOptionName = "nobuild"; + const std::string fullModelBuildOptionName = "buildfull"; + const std::string buildChoiceLabelOptionName = "buildchoicelab"; + const std::string buildStateValuationsOptionName = "buildstateval"; + BuildSettings::BuildSettings() : ModuleSettings(moduleName) { + + std::vector explorationOrders = {"dfs", "bfs"}; + this->addOption(storm::settings::OptionBuilder(moduleName, prismCompatibilityOptionName, false, "Enables PRISM compatibility. This may be necessary to process some PRISM models.").setShortName(prismCompatibilityOptionShortName).build()); + this->addOption(storm::settings::OptionBuilder(moduleName, jitOptionName, false, "If set, the model is built using the JIT model builder.").build()); + this->addOption(storm::settings::OptionBuilder(moduleName, fullModelBuildOptionName, false, "If set, include all rewards and labels.").build()); + this->addOption(storm::settings::OptionBuilder(moduleName, buildChoiceLabelOptionName, false, "If set, also build the choice labels").build()); + this->addOption(storm::settings::OptionBuilder(moduleName, buildStateValuationsOptionName, false, "If set, also build the state valuations").build()); + this->addOption(storm::settings::OptionBuilder(moduleName, noBuildOptionName, false, "If set, do not build the model.").build()); + + this->addOption(storm::settings::OptionBuilder(moduleName, explorationOrderOptionName, false, "Sets which exploration order to use.").setShortName(explorationOrderOptionShortName) + .addArgument(storm::settings::ArgumentBuilder::createStringArgument("name", "The name of the exploration order to choose.").addValidatorString(ArgumentValidatorFactory::createMultipleChoiceValidator(explorationOrders)).setDefaultValueString("bfs").build()).build()); + this->addOption(storm::settings::OptionBuilder(moduleName, explorationChecksOptionName, false, "If set, additional checks (if available) are performed during model exploration to debug the model.").setShortName(explorationChecksOptionShortName).build()); + + } + + + bool BuildSettings::isJitSet() const { + return this->getOption(jitOptionName).getHasOptionBeenSet(); + } + + bool BuildSettings::isExplorationOrderSet() const { + return this->getOption(explorationOrderOptionName).getHasOptionBeenSet(); + } + + bool BuildSettings::isPrismCompatibilityEnabled() const { + return this->getOption(prismCompatibilityOptionName).getHasOptionBeenSet(); + } + + bool BuildSettings::isBuildFullModelSet() const { + return this->getOption(fullModelBuildOptionName).getHasOptionBeenSet(); + } + + bool BuildSettings::isNoBuildModelSet() const { + return this->getOption(noBuildOptionName).getHasOptionBeenSet(); + } + + bool BuildSettings::isBuildChoiceLabelsSet() const { + return this->getOption(buildChoiceLabelOptionName).getHasOptionBeenSet(); + } + + bool BuildSettings::isBuildStateValuationsSet() const { + return this->getOption(buildStateValuationsOptionName).getHasOptionBeenSet(); + } + + + storm::builder::ExplorationOrder BuildSettings::getExplorationOrder() const { + std::string explorationOrderAsString = this->getOption(explorationOrderOptionName).getArgumentByName("name").getValueAsString(); + if (explorationOrderAsString == "dfs") { + return storm::builder::ExplorationOrder::Dfs; + } else if (explorationOrderAsString == "bfs") { + return storm::builder::ExplorationOrder::Bfs; + } + STORM_LOG_THROW(false, storm::exceptions::IllegalArgumentValueException, "Unknown exploration order '" << explorationOrderAsString << "'."); + } + + bool BuildSettings::isExplorationChecksSet() const { + return this->getOption(explorationChecksOptionName).getHasOptionBeenSet(); + } + } + + + } +} diff --git a/src/storm/settings/modules/BuildSettings.h b/src/storm/settings/modules/BuildSettings.h new file mode 100644 index 000000000..4ef0f5193 --- /dev/null +++ b/src/storm/settings/modules/BuildSettings.h @@ -0,0 +1,84 @@ +#pragma once + + +#include "storm-config.h" +#include "storm/settings/modules/ModuleSettings.h" +#include "storm/builder/ExplorationOrder.h" + +namespace storm { + namespace settings { + namespace modules { + class BuildSettings : public ModuleSettings { + + public: + + /*! + * Creates a new set of core settings. + */ + BuildSettings(); + /*! + * Retrieves whether the option to use the JIT builder is set. + * + * @return True iff the JIT builder is to be used. + */ + bool isJitSet() const; + + /*! + * Retrieves whether the model exploration order was set. + * + * @return True if the model exploration option was set. + */ + bool isExplorationOrderSet() const; + + /*! + * Retrieves whether to perform additional checks during model exploration (e.g. out-of-bounds, etc.). + * + * @return True if additional checks are to be performed. + */ + bool isExplorationChecksSet() const; + + /*! + * Retrieves the exploration order if it was set. + * + * @return The chosen exploration order. + */ + storm::builder::ExplorationOrder getExplorationOrder() const; + + /*! + * Retrieves whether the PRISM compatibility mode was enabled. + * + * @return True iff the PRISM compatibility mode was enabled. + */ + bool isPrismCompatibilityEnabled() const; + + /** + * Retrieves whether no model should be build at all, in case one just want to translate models or parse a file. + */ + bool isNoBuildModelSet() const; + + /*! + * Retrieves whether the full model should be build, that is, the model including all labels and rewards. + * + * @return true iff the full model should be build. + */ + bool isBuildFullModelSet() const; + + /*! + * Retrieves whether the choice labels should be build + * @return + */ + bool isBuildChoiceLabelsSet() const; + + /*! + * Retrieves whether the choice labels should be build + * @return + */ + bool isBuildStateValuationsSet() const; + + + // The name of the module. + static const std::string moduleName; + }; + } + } +} \ No newline at end of file diff --git a/src/storm/settings/modules/CoreSettings.h b/src/storm/settings/modules/CoreSettings.h index e0359bf62..afd16cd78 100644 --- a/src/storm/settings/modules/CoreSettings.h +++ b/src/storm/settings/modules/CoreSettings.h @@ -117,9 +117,9 @@ namespace storm { bool isDdLibraryTypeSetFromDefaultValue() const; /*! - * Retrieves whether statistics are to be shown for counterexample generation. + * Retrieves whether statistics are to be shown * - * @return True iff statistics are to be shown for counterexample generation. + * @return True iff statistics are to be shown */ bool isShowStatisticsSet() const; diff --git a/src/storm/settings/modules/IOSettings.cpp b/src/storm/settings/modules/IOSettings.cpp index 44f94296d..ec36ef9d8 100644 --- a/src/storm/settings/modules/IOSettings.cpp +++ b/src/storm/settings/modules/IOSettings.cpp @@ -29,22 +29,13 @@ namespace storm { const std::string IOSettings::prismInputOptionName = "prism"; const std::string IOSettings::janiInputOptionName = "jani"; const std::string IOSettings::prismToJaniOptionName = "prism2jani"; - const std::string IOSettings::jitOptionName = "jit"; - const std::string IOSettings::explorationOrderOptionName = "explorder"; - const std::string IOSettings::explorationOrderOptionShortName = "eo"; - const std::string IOSettings::explorationChecksOptionName = "explchecks"; - const std::string IOSettings::explorationChecksOptionShortName = "ec"; + const std::string IOSettings::transitionRewardsOptionName = "transrew"; const std::string IOSettings::stateRewardsOptionName = "staterew"; const std::string IOSettings::choiceLabelingOptionName = "choicelab"; const std::string IOSettings::constantsOptionName = "constants"; const std::string IOSettings::constantsOptionShortName = "const"; - const std::string IOSettings::prismCompatibilityOptionName = "prismcompat"; - const std::string IOSettings::prismCompatibilityOptionShortName = "pc"; - const std::string IOSettings::noBuildOptionName = "nobuild"; - const std::string IOSettings::fullModelBuildOptionName = "buildfull"; - const std::string IOSettings::buildChoiceLabelOptionName = "buildchoicelab"; - const std::string IOSettings::buildStateValuationsOptionName = "buildstateval"; + const std::string IOSettings::janiPropertyOptionName = "janiproperty"; const std::string IOSettings::janiPropertyOptionShortName = "jprop"; const std::string IOSettings::propertyOptionName = "prop"; @@ -52,7 +43,6 @@ namespace storm { IOSettings::IOSettings() : ModuleSettings(moduleName) { - this->addOption(storm::settings::OptionBuilder(moduleName, prismCompatibilityOptionName, false, "Enables PRISM compatibility. This may be necessary to process some PRISM models.").setShortName(prismCompatibilityOptionShortName).build()); this->addOption(storm::settings::OptionBuilder(moduleName, exportDotOptionName, "", "If given, the loaded model will be written to the specified file in the dot format.") .addArgument(storm::settings::ArgumentBuilder::createStringArgument("filename", "The name of the file to which the model is to be written.").build()).build()); this->addOption(storm::settings::OptionBuilder(moduleName, exportJaniDotOptionName, "", "If given, the loaded jani model will be written to the specified file in the dot format.") @@ -73,19 +63,10 @@ namespace storm { this->addOption(storm::settings::OptionBuilder(moduleName, janiInputOptionName, false, "Parses the model given in the JANI format.") .addArgument(storm::settings::ArgumentBuilder::createStringArgument("filename", "The name of the file from which to read the JANI input.").addValidatorString(ArgumentValidatorFactory::createExistingFileValidator()).build()).build()); this->addOption(storm::settings::OptionBuilder(moduleName, prismToJaniOptionName, false, "If set, the input PRISM model is transformed to JANI.").build()); - this->addOption(storm::settings::OptionBuilder(moduleName, jitOptionName, false, "If set, the model is built using the JIT model builder.").build()); - this->addOption(storm::settings::OptionBuilder(moduleName, fullModelBuildOptionName, false, "If set, include all rewards and labels.").build()); - this->addOption(storm::settings::OptionBuilder(moduleName, buildChoiceLabelOptionName, false, "If set, also build the choice labels").build()); - this->addOption(storm::settings::OptionBuilder(moduleName, buildStateValuationsOptionName, false, "If set, also build the state valuations").build()); - this->addOption(storm::settings::OptionBuilder(moduleName, noBuildOptionName, false, "If set, do not build the model.").build()); this->addOption(storm::settings::OptionBuilder(moduleName, propertyOptionName, false, "Specifies the properties to be checked on the model.").setShortName(propertyOptionShortName) .addArgument(storm::settings::ArgumentBuilder::createStringArgument("property or filename", "The formula or the file containing the formulas.").build()) .addArgument(storm::settings::ArgumentBuilder::createStringArgument("filter", "The names of the properties to check.").setDefaultValueString("all").build()) .build()); - std::vector explorationOrders = {"dfs", "bfs"}; - this->addOption(storm::settings::OptionBuilder(moduleName, explorationOrderOptionName, false, "Sets which exploration order to use.").setShortName(explorationOrderOptionShortName) - .addArgument(storm::settings::ArgumentBuilder::createStringArgument("name", "The name of the exploration order to choose.").addValidatorString(ArgumentValidatorFactory::createMultipleChoiceValidator(explorationOrders)).setDefaultValueString("bfs").build()).build()); - this->addOption(storm::settings::OptionBuilder(moduleName, explorationChecksOptionName, false, "If set, additional checks (if available) are performed during model exploration to debug the model.").setShortName(explorationChecksOptionShortName).build()); this->addOption(storm::settings::OptionBuilder(moduleName, transitionRewardsOptionName, false, "If given, the transition rewards are read from this file and added to the explicit model. Note that this requires the model to be given as an explicit model (i.e., via --" + explicitOptionName + ").") .addArgument(storm::settings::ArgumentBuilder::createStringArgument("filename", "The file from which to read the transition rewards.").addValidatorString(ArgumentValidatorFactory::createExistingFileValidator()).build()).build()); @@ -102,7 +83,7 @@ namespace storm { bool IOSettings::isExportDotSet() const { return this->getOption(exportDotOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getExportDotFilename() const { return this->getOption(exportDotOptionName).getArgumentByName("filename").getValueAsString(); } @@ -114,11 +95,11 @@ namespace storm { std::string IOSettings::getExportJaniDotFilename() const { return this->getOption(exportJaniDotOptionName).getArgumentByName("filename").getValueAsString(); } - + bool IOSettings::isExportExplicitSet() const { return this->getOption(exportExplicitOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getExportExplicitFilename() const { return this->getOption(exportExplicitOptionName).getArgumentByName("filename").getValueAsString(); } @@ -126,11 +107,11 @@ namespace storm { bool IOSettings::isExplicitSet() const { return this->getOption(explicitOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getTransitionFilename() const { return this->getOption(explicitOptionName).getArgumentByName("transition filename").getValueAsString(); } - + std::string IOSettings::getLabelingFilename() const { return this->getOption(explicitOptionName).getArgumentByName("labeling filename").getValueAsString(); } @@ -154,15 +135,15 @@ namespace storm { bool IOSettings::isPrismInputSet() const { return this->getOption(prismInputOptionName).getHasOptionBeenSet(); } - + bool IOSettings::isPrismOrJaniInputSet() const { return isJaniInputSet() || isPrismInputSet(); } - + bool IOSettings::isPrismToJaniSet() const { return this->getOption(prismToJaniOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getPrismInputFilename() const { return this->getOption(prismInputOptionName).getArgumentByName("filename").getValueAsString(); } @@ -174,93 +155,48 @@ namespace storm { std::string IOSettings::getJaniInputFilename() const { return this->getOption(janiInputOptionName).getArgumentByName("filename").getValueAsString(); } - - bool IOSettings::isJitSet() const { - return this->getOption(jitOptionName).getHasOptionBeenSet(); - } - bool IOSettings::isExplorationOrderSet() const { - return this->getOption(explorationOrderOptionName).getHasOptionBeenSet(); - } - - storm::builder::ExplorationOrder IOSettings::getExplorationOrder() const { - std::string explorationOrderAsString = this->getOption(explorationOrderOptionName).getArgumentByName("name").getValueAsString(); - if (explorationOrderAsString == "dfs") { - return storm::builder::ExplorationOrder::Dfs; - } else if (explorationOrderAsString == "bfs") { - return storm::builder::ExplorationOrder::Bfs; - } - STORM_LOG_THROW(false, storm::exceptions::IllegalArgumentValueException, "Unknown exploration order '" << explorationOrderAsString << "'."); - } - - bool IOSettings::isExplorationChecksSet() const { - return this->getOption(explorationChecksOptionName).getHasOptionBeenSet(); - } - + bool IOSettings::isTransitionRewardsSet() const { return this->getOption(transitionRewardsOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getTransitionRewardsFilename() const { return this->getOption(transitionRewardsOptionName).getArgumentByName("filename").getValueAsString(); } - + bool IOSettings::isStateRewardsSet() const { return this->getOption(stateRewardsOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getStateRewardsFilename() const { return this->getOption(stateRewardsOptionName).getArgumentByName("filename").getValueAsString(); } - + bool IOSettings::isChoiceLabelingSet() const { return this->getOption(choiceLabelingOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getChoiceLabelingFilename() const { return this->getOption(choiceLabelingOptionName).getArgumentByName("filename").getValueAsString(); } - - std::unique_ptr IOSettings::overridePrismCompatibilityMode(bool stateToSet) { - return this->overrideOption(prismCompatibilityOptionName, stateToSet); - } - + bool IOSettings::isConstantsSet() const { return this->getOption(constantsOptionName).getHasOptionBeenSet(); } - + std::string IOSettings::getConstantDefinitionString() const { return this->getOption(constantsOptionName).getArgumentByName("values").getValueAsString(); } - + bool IOSettings::isJaniPropertiesSet() const { return this->getOption(janiPropertyOptionName).getHasOptionBeenSet(); } - + std::vector IOSettings::getJaniProperties() const { return storm::parser::parseCommaSeperatedValues(this->getOption(janiPropertyOptionName).getArgumentByName("values").getValueAsString()); } - bool IOSettings::isPrismCompatibilityEnabled() const { - return this->getOption(prismCompatibilityOptionName).getHasOptionBeenSet(); - } - - bool IOSettings::isBuildFullModelSet() const { - return this->getOption(fullModelBuildOptionName).getHasOptionBeenSet(); - } - - bool IOSettings::isNoBuildModelSet() const { - return this->getOption(noBuildOptionName).getHasOptionBeenSet(); - } - - bool IOSettings::isBuildChoiceLabelsSet() const { - return this->getOption(buildChoiceLabelOptionName).getHasOptionBeenSet(); - } - - bool IOSettings::isBuildStateValuationsSet() const { - return this->getOption(buildStateValuationsOptionName).getHasOptionBeenSet(); - } - bool IOSettings::isPropertySet() const { return this->getOption(propertyOptionName).getHasOptionBeenSet(); } diff --git a/src/storm/settings/modules/IOSettings.h b/src/storm/settings/modules/IOSettings.h index 53216e240..f0a90ad27 100644 --- a/src/storm/settings/modules/IOSettings.h +++ b/src/storm/settings/modules/IOSettings.h @@ -158,34 +158,6 @@ namespace storm { */ std::string getJaniInputFilename() const; - /*! - * Retrieves whether the option to use the JIT builder is set. - * - * @return True iff the JIT builder is to be used. - */ - bool isJitSet() const; - - /*! - * Retrieves whether the model exploration order was set. - * - * @return True if the model exploration option was set. - */ - bool isExplorationOrderSet() const; - - /*! - * Retrieves whether to perform additional checks during model exploration (e.g. out-of-bounds, etc.). - * - * @return True if additional checks are to be performed. - */ - bool isExplorationChecksSet() const; - - /*! - * Retrieves the exploration order if it was set. - * - * @return The chosen exploration order. - */ - storm::builder::ExplorationOrder getExplorationOrder() const; - /*! * Retrieves whether the transition reward option was set. * @@ -218,7 +190,7 @@ namespace storm { /*! * Retrieves whether the choice labeling option was set. - * + * * @return True iff the choice labeling option was set. */ bool isChoiceLabelingSet() const; @@ -231,15 +203,7 @@ namespace storm { */ std::string getChoiceLabelingFilename() const; - /*! - * Overrides the option to enable the PRISM compatibility mode by setting it to the specified value. As - * soon as the returned memento goes out of scope, the original value is restored. - * - * @param stateToSet The value that is to be set for the option. - * @return The memento that will eventually restore the original value. - */ - std::unique_ptr overridePrismCompatibilityMode(bool stateToSet); - + /*! * Retrieves whether the export-to-dot option was set. * @@ -286,36 +250,6 @@ namespace storm { */ std::string getPropertyFilter() const; - /*! - * Retrieves whether the PRISM compatibility mode was enabled. - * - * @return True iff the PRISM compatibility mode was enabled. - */ - bool isPrismCompatibilityEnabled() const; - - /** - * Retrieves whether no model should be build at all, in case one just want to translate models or parse a file. - */ - bool isNoBuildModelSet() const; - - /*! - * Retrieves whether the full model should be build, that is, the model including all labels and rewards. - * - * @return true iff the full model should be build. - */ - bool isBuildFullModelSet() const; - - /*! - * Retrieves whether the choice labels should be build - * @return - */ - bool isBuildChoiceLabelsSet() const; - - /*! - * Retrieves whether the choice labels should be build - * @return - */ - bool isBuildStateValuationsSet() const; bool check() const override; void finalize() override; @@ -337,22 +271,11 @@ namespace storm { static const std::string prismInputOptionName; static const std::string janiInputOptionName; static const std::string prismToJaniOptionName; - static const std::string jitOptionName; - static const std::string explorationChecksOptionName; - static const std::string explorationChecksOptionShortName; - static const std::string explorationOrderOptionName; - static const std::string explorationOrderOptionShortName; static const std::string transitionRewardsOptionName; static const std::string stateRewardsOptionName; static const std::string choiceLabelingOptionName; static const std::string constantsOptionName; static const std::string constantsOptionShortName; - static const std::string prismCompatibilityOptionName; - static const std::string prismCompatibilityOptionShortName; - static const std::string fullModelBuildOptionName; - static const std::string noBuildOptionName; - static const std::string buildChoiceLabelOptionName; - static const std::string buildStateValuationsOptionName; static const std::string janiPropertyOptionName; static const std::string janiPropertyOptionShortName; static const std::string propertyOptionName; diff --git a/src/storm/solver/AbstractEquationSolver.cpp b/src/storm/solver/AbstractEquationSolver.cpp index c7fe0bd01..1a32c610b 100644 --- a/src/storm/solver/AbstractEquationSolver.cpp +++ b/src/storm/solver/AbstractEquationSolver.cpp @@ -4,7 +4,6 @@ #include "storm/adapters/RationalFunctionAdapter.h" #include "storm/settings/SettingsManager.h" -#include "storm/settings/modules/IOSettings.h" #include "storm/settings/modules/GeneralSettings.h" #include "storm/utility/constants.h" diff --git a/src/storm/storage/prism/Program.cpp b/src/storm/storage/prism/Program.cpp index 387423066..9a4132420 100644 --- a/src/storm/storage/prism/Program.cpp +++ b/src/storm/storage/prism/Program.cpp @@ -8,8 +8,6 @@ #include "storm/storage/jani/Property.h" #include "storm/storage/expressions/ExpressionManager.h" -#include "storm/settings/SettingsManager.h" -#include "storm/settings/modules/IOSettings.h" #include "storm/utility/macros.h" #include "storm/utility/solver.h" #include "storm/utility/vector.h" @@ -138,7 +136,7 @@ namespace storm { std::set appearingModules; }; - Program::Program(std::shared_ptr manager, ModelType modelType, std::vector const& constants, std::vector const& globalBooleanVariables, std::vector const& globalIntegerVariables, std::vector const& formulas, std::vector const& modules, std::map const& actionToIndexMap, std::vector const& rewardModels, std::vector