From 6fba1a95c97af1ccb4c524461b068ac507fa1285 Mon Sep 17 00:00:00 2001 From: Arne Morten Kvarving Date: Thu, 4 Apr 2024 09:51:37 +0200 Subject: [PATCH] adjust to removal of EWOMS_REGISTER_PARAM --- .../flow/BlackoilModelParameters.hpp | 173 ++++++++++++------ opm/simulators/flow/DamarisWriter.hpp | 88 +++++---- opm/simulators/flow/EclWriter.hpp | 11 +- opm/simulators/flow/FlowBaseVanguard.hpp | 85 ++++----- opm/simulators/flow/FlowMain.hpp | 13 +- opm/simulators/flow/FlowProblem.hpp | 42 +++-- opm/simulators/flow/NonlinearSolver.hpp | 12 +- opm/simulators/flow/OutputBlackoilModule.hpp | 16 +- .../flow/SimulatorFullyImplicitBlackoil.hpp | 60 +++--- opm/simulators/flow/VtkTracerModule.hpp | 5 +- .../linalg/FlowLinearSolverParameters.hpp | 88 ++++++--- .../timestepping/AdaptiveTimeStepping.hpp | 83 +++++---- .../timestepping/EclTimeSteppingParams.hpp | 31 ++-- tests/test_RestartSerialization.cpp | 2 +- tests/test_equil.cpp | 14 +- tests/test_glift1.cpp | 2 +- 16 files changed, 435 insertions(+), 290 deletions(-) diff --git a/opm/simulators/flow/BlackoilModelParameters.hpp b/opm/simulators/flow/BlackoilModelParameters.hpp index 8504214b8..8f3f4f2f9 100644 --- a/opm/simulators/flow/BlackoilModelParameters.hpp +++ b/opm/simulators/flow/BlackoilModelParameters.hpp @@ -681,61 +681,124 @@ namespace Opm static void registerParameters() { - EWOMS_REGISTER_PARAM(TypeTag, Scalar, DbhpMaxRel, "Maximum relative change of the bottom-hole pressure in a single iteration"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, DwellFractionMax, "Maximum absolute change of a well's volume fraction in a single iteration"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, MaxResidualAllowed, "Absolute maximum tolerated for residuals without cutting the time step size"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, RelaxedMaxPvFraction, "The fraction of the pore volume of the reservoir " - "where the volumetric error (CNV) may be voilated during strict Newton iterations."); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, ToleranceMb, "Tolerated mass balance error relative to total mass present"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, ToleranceMbRelaxed, "Relaxed tolerated mass balance error that applies for iterations after the iterations with the strict tolerance"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, ToleranceCnv, "Local convergence tolerance (Maximum of local saturation errors)"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, ToleranceCnvRelaxed, "Relaxed local convergence tolerance that applies for iterations after the iterations with the strict tolerance"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, ToleranceWells, "Well convergence tolerance"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, ToleranceWellControl, "Tolerance for the well control equations"); - EWOMS_REGISTER_PARAM(TypeTag, int, MaxWelleqIter, "Maximum number of iterations to determine solution the well equations"); - EWOMS_REGISTER_PARAM(TypeTag, bool, UseMultisegmentWell, "Use the well model for multi-segment wells instead of the one for single-segment wells"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, TolerancePressureMsWells, "Tolerance for the pressure equations for multi-segment wells"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, RelaxedWellFlowTol, "Relaxed tolerance for the well flow residual"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, RelaxedPressureTolMsw, "Relaxed tolerance for the MSW pressure solution"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, MaxPressureChangeMsWells, "Maximum relative pressure change for a single iteration of the multi-segment well model"); - EWOMS_REGISTER_PARAM(TypeTag, int, MaxInnerIterMsWells, "Maximum number of inner iterations for multi-segment wells"); - EWOMS_REGISTER_PARAM(TypeTag, int, StrictInnerIterWells, "Number of inner well iterations with strict tolerance"); - EWOMS_REGISTER_PARAM(TypeTag, int, StrictOuterIterWells, "Number of newton iterations for which wells are checked with strict tolerance"); - EWOMS_REGISTER_PARAM(TypeTag, int, MaxNewtonIterationsWithInnerWellIterations, "Maximum newton iterations with inner well iterations"); - EWOMS_REGISTER_PARAM(TypeTag, bool, ShutUnsolvableWells, "Shut unsolvable wells"); - EWOMS_REGISTER_PARAM(TypeTag, int, MaxInnerIterWells, "Maximum number of inner iterations for standard wells"); - EWOMS_REGISTER_PARAM(TypeTag, bool, AlternativeWellRateInit, "Use alternative well rate initialization procedure"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, RegularizationFactorWells, "Regularization factor for wells"); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, MaxSinglePrecisionDays, "Maximum time step size where single precision floating point arithmetic can be used solving for the linear systems of equations"); - EWOMS_REGISTER_PARAM(TypeTag, int, MinStrictCnvIter, "Minimum number of Newton iterations before relaxed tolerances can be used for the CNV convergence criterion"); - EWOMS_REGISTER_PARAM(TypeTag, int, MinStrictMbIter, "Minimum number of Newton iterations before relaxed tolerances can be used for the MB convergence criterion. " - "Default -1 means that the relaxed tolerance is used when maximum number of Newton iterations are reached."); - EWOMS_REGISTER_PARAM(TypeTag, bool, SolveWelleqInitially, "Fully solve the well equations before each iteration of the reservoir model"); - EWOMS_REGISTER_PARAM(TypeTag, bool, UpdateEquationsScaling, "Update scaling factors for mass balance equations during the run"); - EWOMS_REGISTER_PARAM(TypeTag, bool, UseUpdateStabilization, "Try to detect and correct oscillations or stagnation during the Newton method"); - EWOMS_REGISTER_PARAM(TypeTag, bool, MatrixAddWellContributions, "Explicitly specify the influences of wells between cells in the Jacobian and preconditioner matrices"); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableWellOperabilityCheck, "Enable the well operability checking"); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableWellOperabilityCheckIter, "Enable the well operability checking during iterations"); - EWOMS_REGISTER_PARAM(TypeTag, int, MaximumNumberOfWellSwitches, "Maximum number of times a well can switch to the same control"); - EWOMS_REGISTER_PARAM(TypeTag, bool, UseAverageDensityMsWells, "Approximate segment densitities by averaging over segment and its outlet"); - EWOMS_REGISTER_PARAM(TypeTag, bool, LocalWellSolveControlSwitching, "Allow control switching during local well solutions"); - EWOMS_REGISTER_PARAM(TypeTag, bool, UseImplicitIpr, "Compute implict IPR for stability checks and stable solution search"); - EWOMS_REGISTER_PARAM(TypeTag, int, NetworkMaxStrictIterations, "Maximum iterations in network solver before relaxing tolerance"); - EWOMS_REGISTER_PARAM(TypeTag, int, NetworkMaxIterations, "Maximum number of iterations in the network solver before giving up"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, NonlinearSolver, "Choose nonlinear solver. Valid choices are newton or nldd."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, LocalSolveApproach, "Choose local solve approach. Valid choices are jacobi and gauss-seidel"); - EWOMS_REGISTER_PARAM(TypeTag, int, MaxLocalSolveIterations, "Max iterations for local solves with NLDD nonlinear solver."); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, LocalToleranceScalingMb, "Set lower than 1.0 to use stricter convergence tolerance for local solves."); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, LocalToleranceScalingCnv, "Set lower than 1.0 to use stricter convergence tolerance for local solves."); - EWOMS_REGISTER_PARAM(TypeTag, int, NlddNumInitialNewtonIter, "Number of initial global Newton iterations when running the NLDD nonlinear solver."); - EWOMS_REGISTER_PARAM(TypeTag, int, NumLocalDomains, "Number of local domains for NLDD nonlinear solver."); - EWOMS_REGISTER_PARAM(TypeTag, Scalar, LocalDomainsPartitioningImbalance, "Subdomain partitioning imbalance tolerance. 1.03 is 3 percent imbalance."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, LocalDomainsPartitioningMethod, "Subdomain partitioning method. " - "Allowed values are 'zoltan', 'simple', and the name of a partition file ending with '.partition'."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, LocalDomainsOrderingMeasure, "Subdomain ordering measure. " - "Allowed values are 'maxpressure', 'averagepressure' and 'residual'."); - - EWOMS_REGISTER_PARAM(TypeTag, bool, DebugEmitCellPartition, "Whether or not to emit cell partitions as a debugging aid."); + Parameters::registerParam + ("Maximum relative change of the bottom-hole pressure in a single iteration"); + Parameters::registerParam + ("Maximum absolute change of a well's volume fraction in a single iteration"); + Parameters::registerParam + ("Absolute maximum tolerated for residuals without cutting the time step size"); + Parameters::registerParam + ("The fraction of the pore volume of the reservoir " + "where the volumetric error (CNV) may be voilated " + "during strict Newton iterations."); + Parameters::registerParam + ("Tolerated mass balance error relative to total mass present"); + Parameters::registerParam + ("Relaxed tolerated mass balance error that applies for iterations " + "after the iterations with the strict tolerance"); + Parameters::registerParam + ("Local convergence tolerance (Maximum of local saturation errors)"); + Parameters::registerParam + ("Relaxed local convergence tolerance that applies for iterations " + "after the iterations with the strict tolerance"); + Parameters::registerParam + ("Well convergence tolerance"); + Parameters::registerParam + ("Tolerance for the well control equations"); + Parameters::registerParam + ("Maximum number of iterations to determine solution the well equations"); + Parameters::registerParam + ("Use the well model for multi-segment wells instead of the " + "one for single-segment wells"); + Parameters::registerParam + ("Tolerance for the pressure equations for multi-segment wells"); + Parameters::registerParam + ("Relaxed tolerance for the well flow residual"); + Parameters::registerParam + ("Relaxed tolerance for the MSW pressure solution"); + Parameters::registerParam + ("Maximum relative pressure change for a single iteration " + "of the multi-segment well model"); + Parameters::registerParam + ("Maximum number of inner iterations for multi-segment wells"); + Parameters::registerParam + ("Number of inner well iterations with strict tolerance"); + Parameters::registerParam + ("Number of newton iterations for which wells are checked with strict tolerance"); + Parameters::registerParam + ("Maximum newton iterations with inner well iterations"); + Parameters::registerParam + ("Shut unsolvable wells"); + Parameters::registerParam + ("Maximum number of inner iterations for standard wells"); + Parameters::registerParam + ("Use alternative well rate initialization procedure"); + Parameters::registerParam + ("Regularization factor for wells"); + Parameters::registerParam + ("Maximum time step size where single precision floating point " + "arithmetic can be used solving for the linear systems of equations"); + Parameters::registerParam + ("Minimum number of Newton iterations before relaxed tolerances " + "can be used for the CNV convergence criterion"); + Parameters::registerParam + ("Minimum number of Newton iterations before relaxed tolerances " + "can be used for the MB convergence criterion. " + "Default -1 means that the relaxed tolerance is used when maximum " + "number of Newton iterations are reached."); + Parameters::registerParam + ("Fully solve the well equations before each iteration of the reservoir model"); + Parameters::registerParam + ("Update scaling factors for mass balance equations during the run"); + Parameters::registerParam + ("Try to detect and correct oscillations or stagnation during the Newton method"); + Parameters::registerParam + ("Explicitly specify the influences of wells between cells in " + "the Jacobian and preconditioner matrices"); + Parameters::registerParam + ("Enable the well operability checking"); + Parameters::registerParam + ("Enable the well operability checking during iterations"); + Parameters::registerParam + ("Maximum number of times a well can switch to the same control"); + Parameters::registerParam + ("Approximate segment densitities by averaging over segment and its outlet"); + Parameters::registerParam + ("Allow control switching during local well solutions"); + Parameters::registerParam + ("Compute implict IPR for stability checks and stable solution search"); + Parameters::registerParam + ("Maximum iterations in network solver before relaxing tolerance"); + Parameters::registerParam + ("Maximum number of iterations in the network solver before giving up"); + Parameters::registerParam + ("Choose nonlinear solver. Valid choices are newton or nldd."); + Parameters::registerParam + ("Choose local solve approach. Valid choices are jacobi and gauss-seidel"); + Parameters::registerParam + ("Max iterations for local solves with NLDD nonlinear solver."); + Parameters::registerParam + ("Set lower than 1.0 to use stricter convergence tolerance for local solves."); + Parameters::registerParam + ("Set lower than 1.0 to use stricter convergence tolerance for local solves."); + Parameters::registerParam + ("Number of initial global Newton iterations when running the NLDD nonlinear solver."); + Parameters::registerParam + ("Number of local domains for NLDD nonlinear solver."); + Parameters::registerParam + ("Subdomain partitioning imbalance tolerance. 1.03 is 3 percent imbalance."); + Parameters::registerParam + ("Subdomain partitioning method. Allowed values are " + "'zoltan', " + "'simple', " + "and the name of a partition file ending with '.partition'."); + Parameters::registerParam + ("Subdomain ordering measure. Allowed values are " + "'maxpressure', " + "'averagepressure' " + "and 'residual'."); + Parameters::registerParam + ("Whether or not to emit cell partitions as a debugging aid."); Parameters::hideParam("DebugEmitCellPartition"); } diff --git a/opm/simulators/flow/DamarisWriter.hpp b/opm/simulators/flow/DamarisWriter.hpp index 775fe4c6d..a09670426 100644 --- a/opm/simulators/flow/DamarisWriter.hpp +++ b/opm/simulators/flow/DamarisWriter.hpp @@ -103,43 +103,57 @@ class DamarisWriter : public EclGenericWriter\". \n \ - This name is used for the Damaris HDF5 file name prefix. Make unique if writing to the same output directory."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, DamarisLogLevel, - "The log level for the Damaris logging system (boost log based). \n \ - Levels are: [trace, debug, info, warning, error, fatal]. Currently debug and info are useful. "); - EWOMS_REGISTER_PARAM(TypeTag, std::string, DamarisDaskFile, - "The name of a Dask json configuration file (if using Dask for processing)."); - - EWOMS_REGISTER_PARAM(TypeTag, int, DamarisDedicatedCores, - "Set the number of dedicated cores (MPI processes) that should be used for Damaris processing (per node). \n \ - Must divide evenly into the number of simulation ranks (client ranks)."); - EWOMS_REGISTER_PARAM(TypeTag, int, DamarisDedicatedNodes, - "Set the number of dedicated nodes (full nodes) that should be used for Damaris processing (per simulation). \n \ - Must divide evenly into the number of simulation nodes."); - EWOMS_REGISTER_PARAM(TypeTag, long, DamarisSharedMemorySizeBytes, - "Set the size of the shared memory buffer used for IPC between the simulation and the Damaris resources. \n \ - Needs to hold all the variables published, possibly over multiple simulation iterations."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, DamarisSharedMemoryName, - "The name of the shared memory area to be used by Damaris for the current. If empty (the default) then Damaris uses \"opm-damaris-\". \n \ - This name should be unique if multiple simulations are running on the same node/server as it is used for the Damaris shmem name and by the Python Dask \n \ - library to locate sections of variables."); + Parameters::registerParam + ("Write output via Damaris using parallel HDF5 to " + "get single file and dataset per timestep instead " + "of one per Damaris core with multiple datasets."); + Parameters::registerParam + ("Set to false to prevent output to HDF5. " + "Uses collective output by default or " + "set --enable-damaris-collective=false to" + "use file per core (file per Damaris server)."); + Parameters::registerParam + ("Saves the mesh data to the HDF5 file (1st iteration only). " + "Will set --damaris-output-hdf-collective to false " + "so will use file per core (file per Damaris server) output " + "(global sizes and offset values of mesh variables are not being provided as yet)."); + Parameters::registerParam + ("Set to the path and filename of a Python script to run on " + "Damaris server resources with access to OPM flow data."); + Parameters::registerParam + ("Set to the path and filename of a Paraview Python script " + "to run on Paraview Catalyst (1 or 2) on Damaris server " + "resources with access to OPM flow data."); + Parameters::registerParam + ("The name of the simulation to be used by Damaris. " + "If empty (the default) then Damaris uses \"opm-sim-\". " + "This name is used for the Damaris HDF5 file name prefix. " + "Make unique if writing to the same output directory."); + Parameters::registerParam + ("The log level for the Damaris logging system (boost log based). " + "Levels are: [trace, debug, info, warning, error, fatal]. " + "Currently debug and info are useful. "); + Parameters::registerParam + ("The name of a Dask json configuration file (if using Dask for processing)."); + Parameters::registerParam + ("Set the number of dedicated cores (MPI processes) " + "that should be used for Damaris processing (per node). " + "Must divide evenly into the number of simulation ranks (client ranks)."); + Parameters::registerParam + ("Set the number of dedicated nodes (full nodes) " + "that should be used for Damaris processing (per simulation). " + "Must divide evenly into the number of simulation nodes."); + Parameters::registerParam + ("Set the size of the shared memory buffer used for IPC " + "between the simulation and the Damaris resources. " + "Needs to hold all the variables published, possibly over " + "multiple simulation iterations."); + Parameters::registerParam + ("The name of the shared memory area to be used by Damaris for the current. " + "If empty (the default) then Damaris uses \"opm-damaris-\". " + "This name should be unique if multiple simulations are running on " + "the same node/server as it is used for the Damaris shmem name and by " + "the Python Dask library to locate sections of variables."); } // The Simulator object should preferably have been const - the diff --git a/opm/simulators/flow/EclWriter.hpp b/opm/simulators/flow/EclWriter.hpp index 7f2104078..3a1b6d3e2 100644 --- a/opm/simulators/flow/EclWriter.hpp +++ b/opm/simulators/flow/EclWriter.hpp @@ -124,12 +124,11 @@ public: { OutputBlackOilModule::registerParameters(); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableAsyncEclOutput, - "Write the ECL-formated results in a non-blocking way (i.e., using a separate thread)."); - - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableEsmry, - "Write ESMRY file for fast loading of summary data."); - + Parameters::registerParam + ("Write the ECL-formated results in a non-blocking way " + "(i.e., using a separate thread)."); + Parameters::registerParam + ("Write ESMRY file for fast loading of summary data."); } // The Simulator object should preferably have been const - the diff --git a/opm/simulators/flow/FlowBaseVanguard.hpp b/opm/simulators/flow/FlowBaseVanguard.hpp index e6b7b4a12..91c2a2713 100644 --- a/opm/simulators/flow/FlowBaseVanguard.hpp +++ b/opm/simulators/flow/FlowBaseVanguard.hpp @@ -238,56 +238,59 @@ public: */ static void registerParameters() { - EWOMS_REGISTER_PARAM(TypeTag, std::string, EclDeckFileName, - "The name of the file which contains the ECL deck to be simulated"); - EWOMS_REGISTER_PARAM(TypeTag, int, EclOutputInterval, - "The number of report steps that ought to be skipped between two writes of ECL results"); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableOpmRstFile, - "Include OPM-specific keywords in the ECL restart file to enable restart of OPM simulators from these files"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, IgnoreKeywords, - "List of Eclipse keywords which should be ignored. As a ':' separated string."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, ParsingStrictness, - "Set strictness of parsing process. Available options are " - "normal (stop for critical errors), " - "high (stop for all errors) and " - "low (as normal, except do not stop due to unsupported keywords even if marked critical"); - EWOMS_REGISTER_PARAM(TypeTag, bool, SchedRestart, - "When restarting: should we try to initialize wells and groups from historical SCHEDULE section."); - EWOMS_REGISTER_PARAM(TypeTag, int, EdgeWeightsMethod, - "Choose edge-weighing strategy: 0=uniform, 1=trans, 2=log(trans)."); + Parameters::registerParam + ("The name of the file which contains the ECL deck to be simulated"); + Parameters::registerParam + ("The number of report steps that ought to be skipped between two writes of ECL results"); + Parameters::registerParam + ("Include OPM-specific keywords in the ECL restart file to " + "enable restart of OPM simulators from these files"); + Parameters::registerParam + ("List of Eclipse keywords which should be ignored. As a ':' separated string."); + Parameters::registerParam + ("Set strictness of parsing process. Available options are " + "normal (stop for critical errors), " + "high (stop for all errors) and " + "low (as normal, except do not stop due to unsupported " + "keywords even if marked critical"); + Parameters::registerParam + ("When restarting: should we try to initialize wells and " + "groups from historical SCHEDULE section."); + Parameters::registerParam + ("Choose edge-weighing strategy: 0=uniform, 1=trans, 2=log(trans)."); #if HAVE_OPENCL || HAVE_ROCSPARSE || HAVE_CUDA - EWOMS_REGISTER_PARAM(TypeTag, int, NumJacobiBlocks, - "Number of blocks to be created for the Block-Jacobi preconditioner."); + Parameters::registerParam + ("Number of blocks to be created for the Block-Jacobi preconditioner."); #endif - EWOMS_REGISTER_PARAM(TypeTag, bool, OwnerCellsFirst, - "Order cells owned by rank before ghost/overlap cells."); + Parameters::registerParam + ("Order cells owned by rank before ghost/overlap cells."); #if HAVE_MPI - EWOMS_REGISTER_PARAM(TypeTag, bool, SerialPartitioning, - "Perform partitioning for parallel runs on a single process."); - EWOMS_REGISTER_PARAM(TypeTag, double, ZoltanImbalanceTol, - "Tolerable imbalance of the loadbalancing provided by Zoltan (default: 1.1)."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, ZoltanParams, - "Configuration of Zoltan partitioner. " - "Valid options are: graph, hypergraph or scotch. " - "Alternatively, you can request a configuration to be read " - "from a JSON file by giving the filename here, ending with '.json.' " - "See https://sandialabs.github.io/Zoltan/ug_html/ug.html " - "for available Zoltan options."); + Parameters::registerParam + ("Perform partitioning for parallel runs on a single process."); + Parameters::registerParam + ("Tolerable imbalance of the loadbalancing provided by Zoltan (default: 1.1)."); + Parameters::registerParam + ("Configuration of Zoltan partitioner. " + "Valid options are: graph, hypergraph or scotch. " + "Alternatively, you can request a configuration to be read " + "from a JSON file by giving the filename here, ending with '.json.' " + "See https://sandialabs.github.io/Zoltan/ug_html/ug.html " + "for available Zoltan options."); Parameters::hideParam("ZoltanParams"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, ExternalPartition, - "Name of file from which to load an externally generated " - "partitioning of the model's active cells for MPI " - "distribution purposes. If empty, the built-in partitioning " - "method will be employed."); + Parameters::registerParam + ("Name of file from which to load an externally generated " + "partitioning of the model's active cells for MPI " + "distribution purposes. If empty, the built-in partitioning " + "method will be employed."); Parameters::hideParam("ExternalPartition"); #endif - EWOMS_REGISTER_PARAM(TypeTag, bool, AllowDistributedWells, - "Allow the perforations of a well to be distributed to interior of multiple processes"); + Parameters::registerParam + ("Allow the perforations of a well to be distributed to interior of multiple processes"); // register here for the use in the tests without BlackoilModelParameters - EWOMS_REGISTER_PARAM(TypeTag, bool, UseMultisegmentWell, "Use the well model for multi-segment wells instead of the one for single-segment wells"); - + Parameters::registerParam + ("Use the well model for multi-segment wells instead of the one for single-segment wells"); } /*! diff --git a/opm/simulators/flow/FlowMain.hpp b/opm/simulators/flow/FlowMain.hpp index 00a80d055..15617e22b 100644 --- a/opm/simulators/flow/FlowMain.hpp +++ b/opm/simulators/flow/FlowMain.hpp @@ -114,12 +114,13 @@ namespace Opm { return EXIT_SUCCESS; } // register the flow specific parameters - EWOMS_REGISTER_PARAM(TypeTag, std::string, EnableDryRun, - "Specify if the simulation ought to be actually run, or just pretended to be"); - EWOMS_REGISTER_PARAM(TypeTag, int, OutputInterval, - "Specify the number of report steps between two consecutive writes of restart data"); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableLoggingFalloutWarning, - "Developer option to see whether logging was on non-root processors. In that case it will be appended to the *.DBG or *.PRT files"); + Parameters::registerParam + ("Specify if the simulation ought to be actually run, or just pretended to be"); + Parameters::registerParam + ("Specify the number of report steps between two consecutive writes of restart data"); + Parameters::registerParam + ("Developer option to see whether logging was on non-root processors. " + "In that case it will be appended to the *.DBG or *.PRT files"); Simulator::registerParameters(); diff --git a/opm/simulators/flow/FlowProblem.hpp b/opm/simulators/flow/FlowProblem.hpp index d951f1254..8b0ba5a2c 100644 --- a/opm/simulators/flow/FlowProblem.hpp +++ b/opm/simulators/flow/FlowProblem.hpp @@ -216,29 +216,31 @@ public: VtkTracerModule::registerParameters(); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableWriteAllSolutions, - "Write all solutions to disk instead of only the ones for the " - "report steps"); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableEclOutput, - "Write binary output which is compatible with the commercial " - "Eclipse simulator"); + Parameters::registerParam + ("Write all solutions to disk instead of only the ones for the " + "report steps"); + Parameters::registerParam + ("Write binary output which is compatible with the commercial " + "Eclipse simulator"); #if HAVE_DAMARIS - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableDamarisOutput, - "Write a specific variable using Damaris in a separate core"); + Parameters::registerParam + ("Write a specific variable using Damaris in a separate core"); #endif - EWOMS_REGISTER_PARAM(TypeTag, bool, EclOutputDoublePrecision, - "Tell the output writer to use double precision. Useful for 'perfect' restarts"); - EWOMS_REGISTER_PARAM(TypeTag, unsigned, RestartWritingInterval, - "The frequencies of which time steps are serialized to disk"); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableDriftCompensation, - "Enable partial compensation of systematic mass losses via the source term of the next time step"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, OutputMode, - "Specify which messages are going to be printed. Valid values are: none, log, all (default)"); - EWOMS_REGISTER_PARAM(TypeTag, int, NumPressurePointsEquil, - "Number of pressure points (in each direction) in tables used for equilibration"); + Parameters::registerParam + ("Tell the output writer to use double precision. Useful for 'perfect' restarts"); + Parameters::registerParam + ("The frequencies of which time steps are serialized to disk"); + Parameters::registerParam + ("Enable partial compensation of systematic mass losses via " + "the source term of the next time step"); + Parameters::registerParam + ("Specify which messages are going to be printed. " + "Valid values are: none, log, all (default)"); + Parameters::registerParam + ("Number of pressure points (in each direction) in tables used for equilibration"); Parameters::hideParam("NumPressurePointsEquil"); // Users will typically not need to modify this parameter.. - EWOMS_REGISTER_PARAM(TypeTag, bool, ExplicitRockCompaction, - "Use pressure from end of the last time step when evaluating rock compaction"); + Parameters::registerParam + ("Use pressure from end of the last time step when evaluating rock compaction"); Parameters::hideParam("ExplicitRockCompaction"); // Users will typically not need to modify this parameter.. } diff --git a/opm/simulators/flow/NonlinearSolver.hpp b/opm/simulators/flow/NonlinearSolver.hpp index 81b11fa2c..a13bb7203 100644 --- a/opm/simulators/flow/NonlinearSolver.hpp +++ b/opm/simulators/flow/NonlinearSolver.hpp @@ -144,10 +144,14 @@ void stabilizeNonlinearUpdate(BVector& dx, BVector& dxOld, static void registerParameters() { - EWOMS_REGISTER_PARAM(TypeTag, Scalar, NewtonMaxRelax, "The maximum relaxation factor of a Newton iteration"); - EWOMS_REGISTER_PARAM(TypeTag, int, NewtonMaxIterations, "The maximum number of Newton iterations per time step"); - EWOMS_REGISTER_PARAM(TypeTag, int, NewtonMinIterations, "The minimum number of Newton iterations per time step"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, NewtonRelaxationType, "The type of relaxation used by Newton method"); + Parameters::registerParam + ("The maximum relaxation factor of a Newton iteration"); + Parameters::registerParam + ("The maximum number of Newton iterations per time step"); + Parameters::registerParam + ("The minimum number of Newton iterations per time step"); + Parameters::registerParam + ("The type of relaxation used by Newton method"); } void reset() diff --git a/opm/simulators/flow/OutputBlackoilModule.hpp b/opm/simulators/flow/OutputBlackoilModule.hpp index f25c783fc..61edaf7a6 100644 --- a/opm/simulators/flow/OutputBlackoilModule.hpp +++ b/opm/simulators/flow/OutputBlackoilModule.hpp @@ -207,16 +207,12 @@ public: */ static void registerParameters() { - EWOMS_REGISTER_PARAM( - TypeTag, - bool, - ForceDisableFluidInPlaceOutput, - "Do not print fluid-in-place values after each report step even if requested by the deck."); - EWOMS_REGISTER_PARAM( - TypeTag, - bool, - ForceDisableResvFluidInPlaceOutput, - "Do not print reservoir volumes values after each report step even if requested by the deck."); + Parameters::registerParam + ("Do not print fluid-in-place values after each report step " + "even if requested by the deck."); + Parameters::registerParam + ("Do not print reservoir volumes values after each report step " + "even if requested by the deck."); } /*! diff --git a/opm/simulators/flow/SimulatorFullyImplicitBlackoil.hpp b/opm/simulators/flow/SimulatorFullyImplicitBlackoil.hpp index 5c7cc2736..c271a781b 100644 --- a/opm/simulators/flow/SimulatorFullyImplicitBlackoil.hpp +++ b/opm/simulators/flow/SimulatorFullyImplicitBlackoil.hpp @@ -219,37 +219,37 @@ public: SolverParameters::registerParameters(); TimeStepper::registerParameters(); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableTerminalOutput, - "Print high-level information about the simulation's progress to the terminal"); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableAdaptiveTimeStepping, - "Use adaptive time stepping between report steps"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, OutputExtraConvergenceInfo, - "Provide additional convergence output " - "files for diagnostic purposes. " - "\"none\" gives no extra output and " - "overrides all other options, " - "\"steps\" generates an INFOSTEP file, " - "\"iterations\" generates an INFOITER file. " - "Combine options with commas, e.g., " - "\"steps,iterations\" for multiple outputs."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, SaveStep, - "Save serialized state to .OPMRST file. " - "Either a specific report step, \"all\" to save " - "all report steps or \":x\" to save every x'th step." - "Use negative values of \"x\" to keep only the last " - "written step, or \"last\" to save every step, keeping " - "only the last."); - EWOMS_REGISTER_PARAM(TypeTag, int, LoadStep, - "Load serialized state from .OPMRST file. " - "Either a specific report step, or 0 to load last " - "stored report step."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, SaveFile, - "FileName for .OPMRST file used for saving serialized state. " - "If empty, CASENAME.OPMRST is used."); + Parameters::registerParam + ("Print high-level information about the simulation's progress to the terminal"); + Parameters::registerParam + ("Use adaptive time stepping between report steps"); + Parameters::registerParam + ("Provide additional convergence output " + "files for diagnostic purposes. " + "\"none\" gives no extra output and " + "overrides all other options, " + "\"steps\" generates an INFOSTEP file, " + "\"iterations\" generates an INFOITER file. " + "Combine options with commas, e.g., " + "\"steps,iterations\" for multiple outputs."); + Parameters::registerParam + ("Save serialized state to .OPMRST file. " + "Either a specific report step, \"all\" to save " + "all report steps or \":x\" to save every x'th step." + "Use negative values of \"x\" to keep only the last " + "written step, or \"last\" to save every step, keeping " + "only the last."); + Parameters::registerParam + ("Load serialized state from .OPMRST file. " + "Either a specific report step, or 0 to load last " + "stored report step."); + Parameters::registerParam + ("FileName for .OPMRST file used for saving serialized state. " + "If empty, CASENAME.OPMRST is used."); Parameters::hideParam("SaveFile"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, LoadFile, - "FileName for .OPMRST file used to load serialized state. " - "If empty, CASENAME.OPMRST is used."); + Parameters::registerParam + ("FileName for .OPMRST file used to load serialized state. " + "If empty, CASENAME.OPMRST is used."); Parameters::hideParam("LoadFile"); } diff --git a/opm/simulators/flow/VtkTracerModule.hpp b/opm/simulators/flow/VtkTracerModule.hpp index 57263b5cb..fe3f3f18f 100644 --- a/opm/simulators/flow/VtkTracerModule.hpp +++ b/opm/simulators/flow/VtkTracerModule.hpp @@ -95,9 +95,8 @@ namespace Opm { */ static void registerParameters() { - EWOMS_REGISTER_PARAM(TypeTag, bool, VtkWriteTracerConcentration, - "Include the tracer concentration " - "in the VTK output files"); + Parameters::registerParam + ("Include the tracer concentration in the VTK output files"); } /*! diff --git a/opm/simulators/linalg/FlowLinearSolverParameters.hpp b/opm/simulators/linalg/FlowLinearSolverParameters.hpp index 70cc956cb..4af576e89 100644 --- a/opm/simulators/linalg/FlowLinearSolverParameters.hpp +++ b/opm/simulators/linalg/FlowLinearSolverParameters.hpp @@ -294,27 +294,73 @@ namespace Opm template static void registerParameters() { - EWOMS_REGISTER_PARAM(TypeTag, double, LinearSolverReduction, "The minimum reduction of the residual which the linear solver must achieve"); - EWOMS_REGISTER_PARAM(TypeTag, double, RelaxedLinearSolverReduction, "The minimum reduction of the residual which the linear solver need to achieve for the solution to be accepted"); - EWOMS_REGISTER_PARAM(TypeTag, int, LinearSolverMaxIter, "The maximum number of iterations of the linear solver"); - EWOMS_REGISTER_PARAM(TypeTag, int, LinearSolverRestart, "The number of iterations after which GMRES is restarted"); - EWOMS_REGISTER_PARAM(TypeTag, int, LinearSolverVerbosity, "The verbosity level of the linear solver (0: off, 2: all)"); - EWOMS_REGISTER_PARAM(TypeTag, double, IluRelaxation, "The relaxation factor of the linear solver's ILU preconditioner"); - EWOMS_REGISTER_PARAM(TypeTag, int, IluFillinLevel, "The fill-in level of the linear solver's ILU preconditioner"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, MiluVariant, "Specify which variant of the modified-ILU preconditioner ought to be used. Possible variants are: ILU (default, plain ILU), MILU_1 (lump diagonal with dropped row entries), MILU_2 (lump diagonal with the sum of the absolute values of the dropped row entries), MILU_3 (if diagonal is positive add sum of dropped row entrires. Otherwise subtract them), MILU_4 (if diagonal is positive add sum of dropped row entrires. Otherwise do nothing"); - EWOMS_REGISTER_PARAM(TypeTag, bool, IluRedblack, "Use red-black partitioning for the ILU preconditioner"); - EWOMS_REGISTER_PARAM(TypeTag, bool, IluReorderSpheres, "Whether to reorder the entries of the matrix in the red-black ILU preconditioner in spheres starting at an edge. If false the original ordering is preserved in each color. Otherwise why try to ensure D4 ordering (in a 2D structured grid, the diagonal elements are consecutive)."); - EWOMS_REGISTER_PARAM(TypeTag, bool, UseGmres, "Use GMRES as the linear solver"); - EWOMS_REGISTER_PARAM(TypeTag, bool, LinearSolverIgnoreConvergenceFailure, "Continue with the simulation like nothing happened after the linear solver did not converge"); - EWOMS_REGISTER_PARAM(TypeTag, bool, ScaleLinearSystem, "Scale linear system according to equation scale and primary variable types"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, LinearSolver, "Configuration of solver. Valid options are: ilu0 (default), dilu, cprw, cpr (an alias for cprw), cpr_quasiimpes, cpr_trueimpes, cpr_trueimpesanalytic, amg or hybrid (experimental). Alternatively, you can request a configuration to be read from a JSON file by giving the filename here, ending with '.json.'"); - EWOMS_REGISTER_PARAM(TypeTag, bool, LinearSolverPrintJsonDefinition, "Write the JSON definition of the linear solver setup to the DBG file."); - EWOMS_REGISTER_PARAM(TypeTag, int, CprReuseSetup, "Reuse preconditioner setup. Valid options are 0: recreate the preconditioner for every linear solve, 1: recreate once every timestep, 2: recreate if last linear solve took more than 10 iterations, 3: never recreate, 4: recreated every CprReuseInterval"); - EWOMS_REGISTER_PARAM(TypeTag, int, CprReuseInterval, "Reuse preconditioner interval. Used when CprReuseSetup is set to 4, then the preconditioner will be fully recreated instead of reused every N linear solve, where N is this parameter."); - EWOMS_REGISTER_PARAM(TypeTag, std::string, AcceleratorMode, "Choose a linear solver, usage: '--accelerator-mode=[none|cusparse|opencl|amgcl|rocalution|rocsparse]'"); - EWOMS_REGISTER_PARAM(TypeTag, int, BdaDeviceId, "Choose device ID for cusparseSolver or openclSolver, use 'nvidia-smi' or 'clinfo' to determine valid IDs"); - EWOMS_REGISTER_PARAM(TypeTag, int, OpenclPlatformId, "Choose platform ID for openclSolver, use 'clinfo' to determine valid platform IDs"); - EWOMS_REGISTER_PARAM(TypeTag, bool, OpenclIluParallel, "Parallelize ILU decomposition and application on GPU"); + Parameters::registerParam + ("The minimum reduction of the residual which the linear solver must achieve"); + Parameters::registerParam + ("The minimum reduction of the residual which the linear solver need to " + "achieve for the solution to be accepted"); + Parameters::registerParam + ("The maximum number of iterations of the linear solver"); + Parameters::registerParam + ("The number of iterations after which GMRES is restarted"); + Parameters::registerParam + ("The verbosity level of the linear solver (0: off, 2: all)"); + Parameters::registerParam + ("The relaxation factor of the linear solver's ILU preconditioner"); + Parameters::registerParam + ("The fill-in level of the linear solver's ILU preconditioner"); + Parameters::registerParam + ("Specify which variant of the modified-ILU preconditioner ought to be used. " + "Possible variants are: ILU (default, plain ILU), " + "MILU_1 (lump diagonal with dropped row entries), " + "MILU_2 (lump diagonal with the sum of the absolute values of the dropped row entries), " + "MILU_3 (if diagonal is positive add sum of dropped row entries, otherwise subtract them), " + "MILU_4 (if diagonal is positive add sum of dropped row entries, otherwise do nothing"); + Parameters::registerParam + ("Use red-black partitioning for the ILU preconditioner"); + Parameters::registerParam + ("Whether to reorder the entries of the matrix in the red-black " + "ILU preconditioner in spheres starting at an edge. " + "If false the original ordering is preserved in each color. " + "Otherwise why try to ensure D4 ordering (in a 2D structured grid, " + "the diagonal elements are consecutive)."); + Parameters::registerParam + ("Use GMRES as the linear solver"); + Parameters::registerParam + ("Continue with the simulation like nothing happened " + "after the linear solver did not converge"); + Parameters::registerParam + ("Scale linear system according to equation scale and primary variable types"); + Parameters::registerParam + ("Configuration of solver. Valid options are: ilu0 (default), " + "dilu, cprw, cpr (an alias for cprw), cpr_quasiimpes, " + "cpr_trueimpes, cpr_trueimpesanalytic, amg or hybrid (experimental). " + "Alternatively, you can request a configuration to be read from a " + "JSON file by giving the filename here, ending with '.json.'"); + Parameters::registerParam + ("Write the JSON definition of the linear solver setup to the DBG file."); + Parameters::registerParam + ("Reuse preconditioner setup. Valid options are " + "0: recreate the preconditioner for every linear solve, " + "1: recreate once every timestep, " + "2: recreate if last linear solve took more than 10 iterations, " + "3: never recreate, " + "4: recreated every CprReuseInterval"); + Parameters::registerParam + ("Reuse preconditioner interval. Used when CprReuseSetup is set to 4, " + "then the preconditioner will be fully recreated instead of reused " + "every N linear solve, where N is this parameter."); + Parameters::registerParam + ("Choose a linear solver, usage: " + "'--accelerator-mode=[none|cusparse|opencl|amgcl|rocalution|rocsparse]'"); + Parameters::registerParam + ("Choose device ID for cusparseSolver or openclSolver, " + "use 'nvidia-smi' or 'clinfo' to determine valid IDs"); + Parameters::registerParam + ("Choose platform ID for openclSolver, use 'clinfo' " + "to determine valid platform IDs"); + Parameters::registerParam + ("Parallelize ILU decomposition and application on GPU"); } FlowLinearSolverParameters() { reset(); } diff --git a/opm/simulators/timestepping/AdaptiveTimeStepping.hpp b/opm/simulators/timestepping/AdaptiveTimeStepping.hpp index ed3a1e424..ff1ae6700 100644 --- a/opm/simulators/timestepping/AdaptiveTimeStepping.hpp +++ b/opm/simulators/timestepping/AdaptiveTimeStepping.hpp @@ -305,40 +305,55 @@ std::set consistentlyFailingWells(const std::vector& sr { registerEclTimeSteppingParameters(); // TODO: make sure the help messages are correct (and useful) - EWOMS_REGISTER_PARAM(TypeTag, bool, SolverContinueOnConvergenceFailure, - "Continue instead of stop when minimum solver time step is reached"); - EWOMS_REGISTER_PARAM(TypeTag, int, SolverMaxRestarts, - "The maximum number of breakdowns before a substep is given up and the simulator is terminated"); - EWOMS_REGISTER_PARAM(TypeTag, int, SolverVerbosity, - "Specify the \"chattiness\" of the non-linear solver itself"); - EWOMS_REGISTER_PARAM(TypeTag, int, TimeStepVerbosity, - "Specify the \"chattiness\" during the time integration"); - EWOMS_REGISTER_PARAM(TypeTag, double, InitialTimeStepInDays, - "The size of the initial time step in days"); - EWOMS_REGISTER_PARAM(TypeTag, bool, FullTimeStepInitially, - "Always attempt to finish a report step using a single substep"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, TimeStepControl, - "The algorithm used to determine time-step sizes. valid options are: 'pid' (default), 'pid+iteration', 'pid+newtoniteration', 'iterationcount', 'newtoniterationcount' and 'hardcoded'"); - EWOMS_REGISTER_PARAM(TypeTag, double, TimeStepControlTolerance, - "The tolerance used by the time step size control algorithm"); - EWOMS_REGISTER_PARAM(TypeTag, int, TimeStepControlTargetIterations, - "The number of linear iterations which the time step control scheme should aim for (if applicable)"); - EWOMS_REGISTER_PARAM(TypeTag, int, TimeStepControlTargetNewtonIterations, - "The number of Newton iterations which the time step control scheme should aim for (if applicable)"); - EWOMS_REGISTER_PARAM(TypeTag, double, TimeStepControlDecayRate, - "The decay rate of the time step size of the number of target iterations is exceeded"); - EWOMS_REGISTER_PARAM(TypeTag, double, TimeStepControlGrowthRate, - "The growth rate of the time step size of the number of target iterations is undercut"); - EWOMS_REGISTER_PARAM(TypeTag, double, TimeStepControlDecayDampingFactor, - "The decay rate of the time step decrease when the target iterations is exceeded"); - EWOMS_REGISTER_PARAM(TypeTag, double, TimeStepControlGrowthDampingFactor, - "The growth rate of the time step increase when the target iterations is undercut"); - EWOMS_REGISTER_PARAM(TypeTag, std::string, TimeStepControlFileName, - "The name of the file which contains the hardcoded time steps sizes"); - EWOMS_REGISTER_PARAM(TypeTag, double, MinTimeStepBeforeShuttingProblematicWellsInDays, - "The minimum time step size in days for which problematic wells are not shut"); - EWOMS_REGISTER_PARAM(TypeTag, double, MinTimeStepBasedOnNewtonIterations, - "The minimum time step size (in days for field and metric unit and hours for lab unit) can be reduced to based on newton iteration counts"); + Parameters::registerParam + ("Continue instead of stop when minimum solver time step is reached"); + Parameters::registerParam + ("The maximum number of breakdowns before a substep is given up and " + "the simulator is terminated"); + Parameters::registerParam + ("Specify the \"chattiness\" of the non-linear solver itself"); + Parameters::registerParam + ("Specify the \"chattiness\" during the time integration"); + Parameters::registerParam + ("The size of the initial time step in days"); + Parameters::registerParam + ("Always attempt to finish a report step using a single substep"); + Parameters::registerParam + ("The algorithm used to determine time-step sizes. " + "Valid options are: " + "'pid' (default), " + "'pid+iteration', " + "'pid+newtoniteration', " + "'iterationcount', " + "'newtoniterationcount' " + "and 'hardcoded'"); + Parameters::registerParam + ("The tolerance used by the time step size control algorithm"); + Parameters::registerParam + ("The number of linear iterations which the time step control scheme " + "should aim for (if applicable)"); + Parameters::registerParam + ("The number of Newton iterations which the time step control scheme " + "should aim for (if applicable)"); + Parameters::registerParam + ("The decay rate of the time step size of the number of " + "target iterations is exceeded"); + Parameters::registerParam + ("The growth rate of the time step size of the number of " + "target iterations is undercut"); + Parameters::registerParam + ("The decay rate of the time step decrease when the " + "target iterations is exceeded"); + Parameters::registerParam + ("The growth rate of the time step increase when the " + "target iterations is undercut"); + Parameters::registerParam + ("The name of the file which contains the hardcoded time steps sizes"); + Parameters::registerParam + ("The minimum time step size in days for which problematic wells are not shut"); + Parameters::registerParam + ("The minimum time step size (in days for field and metric unit and hours for lab unit) " + "can be reduced to based on newton iteration counts"); } /** \brief step method that acts like the solver::step method diff --git a/opm/simulators/timestepping/EclTimeSteppingParams.hpp b/opm/simulators/timestepping/EclTimeSteppingParams.hpp index 36389c8b5..3639906bd 100644 --- a/opm/simulators/timestepping/EclTimeSteppingParams.hpp +++ b/opm/simulators/timestepping/EclTimeSteppingParams.hpp @@ -115,20 +115,23 @@ namespace Opm { template void registerEclTimeSteppingParameters() { - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableTuning, - "Honor some aspects of the TUNING keyword."); - EWOMS_REGISTER_PARAM(TypeTag, double, SolverGrowthFactor, - "The factor time steps are elongated after a successful substep"); - EWOMS_REGISTER_PARAM(TypeTag, double, SolverMaxGrowth, - "The maximum factor time steps are elongated after a report step"); - EWOMS_REGISTER_PARAM(TypeTag, double, SolverMaxTimeStepInDays, - "The maximum size of a time step in days"); - EWOMS_REGISTER_PARAM(TypeTag, double, SolverMinTimeStep, - "The minimum size of a time step in days for field and metric and hours for lab. If a step cannot converge without getting cut below this step size the simulator will stop"); - EWOMS_REGISTER_PARAM(TypeTag, double, SolverRestartFactor, - "The factor time steps are elongated after restarts"); - EWOMS_REGISTER_PARAM(TypeTag, double, TimeStepAfterEventInDays, - "Time step size of the first time step after an event occurs during the simulation in days"); + Parameters::registerParam + ("Honor some aspects of the TUNING keyword."); + Parameters::registerParam + ("The factor time steps are elongated after a successful substep"); + Parameters::registerParam + ("The maximum factor time steps are elongated after a report step"); + Parameters::registerParam + ("The maximum size of a time step in days"); + Parameters::registerParam + ("The minimum size of a time step in days for field and " + "metric and hours for lab. If a step cannot converge without " + "getting cut below this step size the simulator will stop"); + Parameters::registerParam + ("The factor time steps are elongated after restarts"); + Parameters::registerParam + ("Time step size of the first time step after an event " + "occurs during the simulation in days"); } } // namespace Opm diff --git a/tests/test_RestartSerialization.cpp b/tests/test_RestartSerialization.cpp index 852935ac4..91f3afacb 100644 --- a/tests/test_RestartSerialization.cpp +++ b/tests/test_RestartSerialization.cpp @@ -451,7 +451,7 @@ struct AquiferFixture { }; AdaptiveTimeStepping::registerParameters(); BlackoilModelParameters::registerParameters(); - EWOMS_REGISTER_PARAM(TT, bool, EnableTerminalOutput, "Do *NOT* use!"); + Parameters::registerParam("Do *NOT* use!"); setupParameters_(2, argv, /*registerParams=*/true); FlowGenericVanguard::setCommunication(std::make_unique()); } diff --git a/tests/test_equil.cpp b/tests/test_equil.cpp index 7d47711c5..1da423494 100644 --- a/tests/test_equil.cpp +++ b/tests/test_equil.cpp @@ -232,13 +232,13 @@ struct EquilFixture { #else Dune::MPIHelper::instance(argc, argv); #endif - Opm::FlowGenericVanguard::setCommunication(std::make_unique()); - Opm::BlackoilModelParameters::registerParameters(); - Opm::AdaptiveTimeStepping::registerParameters(); - Opm::Parameters::registerParam("EnableTerminalOutput", - Opm::getPropValue(), - "Dummy added for the well model to compile."); - Opm::registerAllParameters_(); + using namespace Opm; + FlowGenericVanguard::setCommunication(std::make_unique()); + BlackoilModelParameters::registerParameters(); + AdaptiveTimeStepping::registerParameters(); + Parameters::registerParam("Dummy added for the well model to compile."); + registerAllParameters_(); } using TypeTag = Opm::Properties::TTag::TestEquilTypeTag; diff --git a/tests/test_glift1.cpp b/tests/test_glift1.cpp index b690a28b5..ce86958e3 100644 --- a/tests/test_glift1.cpp +++ b/tests/test_glift1.cpp @@ -87,7 +87,7 @@ initSimulator(const char *filename) registerEclTimeSteppingParameters(); BlackoilModelParameters::registerParameters(); - EWOMS_REGISTER_PARAM(TypeTag, bool, EnableTerminalOutput, "Do *NOT* use!"); + Parameters::registerParam("Do *NOT* use!"); setupParameters_(/*argc=*/sizeof(argv)/sizeof(argv[0]), argv, /*registerParams=*/true); FlowGenericVanguard::readDeck(filename);