mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
remove old serialization support for RestartConfig
This commit is contained in:
parent
f0bc3e3815
commit
6d74eb8e88
@ -24,7 +24,6 @@
|
||||
#include "ParallelRestart.hpp"
|
||||
#include <opm/common/OpmLog/Location.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Grid/FaceDir.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/IOConfig/RestartConfig.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Action/ActionAST.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Action/Actions.hpp>
|
||||
#include <opm/parser/eclipse/EclipseState/Schedule/Action/ActionX.hpp>
|
||||
@ -341,16 +340,6 @@ std::size_t packSize(const TimeMap& data, Dune::MPIHelper::MPICommunicator comm)
|
||||
return packSize(data.timeList(), comm);
|
||||
}
|
||||
|
||||
std::size_t packSize(const RestartConfig& data, Dune::MPIHelper::MPICommunicator comm)
|
||||
{
|
||||
return packSize(data.timeMap(), comm) +
|
||||
packSize(data.getFirstRestartStep(), comm) +
|
||||
packSize(data.writeInitialRst(), comm) +
|
||||
packSize(data.restartSchedule(), comm) +
|
||||
packSize(data.restartKeywords(), comm) +
|
||||
packSize(data.saveKeywords(), comm);
|
||||
}
|
||||
|
||||
template
|
||||
std::size_t packSize(const std::map<Phase,Group::GroupInjectionProperties>& data,
|
||||
Dune::MPIHelper::MPICommunicator comm);
|
||||
@ -904,16 +893,6 @@ std::size_t packSize(const Action::Actions& data,
|
||||
return packSize(data.getActions(), comm);
|
||||
}
|
||||
|
||||
std::size_t packSize(const RestartSchedule& data,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
{
|
||||
return packSize(data.timestep, comm) +
|
||||
packSize(data.basic, comm) +
|
||||
packSize(data.frequency, comm) +
|
||||
packSize(data.rptsched_restart_set, comm) +
|
||||
packSize(data.rptsched_restart, comm);
|
||||
}
|
||||
|
||||
std::size_t packSize(const WellPolymerProperties& data,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
{
|
||||
@ -1221,17 +1200,6 @@ void pack(const TimeMap& data, std::vector<char>& buffer, int& position,
|
||||
pack(data.timeList(), buffer, position, comm);
|
||||
}
|
||||
|
||||
void pack(const RestartConfig& data, std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
{
|
||||
pack(data.timeMap(), buffer, position, comm);
|
||||
pack(data.getFirstRestartStep(), buffer, position, comm);
|
||||
pack(data.writeInitialRst(), buffer, position, comm);
|
||||
pack(data.restartSchedule(), buffer, position, comm);
|
||||
pack(data.restartKeywords(), buffer, position, comm);
|
||||
pack(data.saveKeywords(), buffer, position, comm);
|
||||
}
|
||||
|
||||
void pack(const OilVaporizationProperties& data,
|
||||
std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
@ -1820,17 +1788,6 @@ void pack(const Action::Actions& data,
|
||||
pack(data.getActions(), buffer, position, comm);
|
||||
}
|
||||
|
||||
void pack(const RestartSchedule& data,
|
||||
std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
{
|
||||
pack(data.timestep, buffer, position, comm);
|
||||
pack(data.basic, buffer, position, comm);
|
||||
pack(data.frequency, buffer, position, comm);
|
||||
pack(data.rptsched_restart_set, buffer, position, comm);
|
||||
pack(data.rptsched_restart, buffer, position, comm);
|
||||
}
|
||||
|
||||
void pack(const WellPolymerProperties& data,
|
||||
std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
@ -2165,25 +2122,6 @@ void unpack(TimeMap& data, std::vector<char>& buffer, int& position,
|
||||
data = TimeMap(timeList);
|
||||
}
|
||||
|
||||
void unpack(RestartConfig& data, std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
{
|
||||
TimeMap timemap;
|
||||
int firstRstStep;
|
||||
bool writeInitialRst;
|
||||
DynamicState<RestartSchedule> restart_sched;
|
||||
DynamicState<std::map<std::string,int>> restart_keyw;
|
||||
std::vector<bool> save_keyw;
|
||||
unpack(timemap, buffer, position, comm);
|
||||
unpack(firstRstStep, buffer, position, comm);
|
||||
unpack(writeInitialRst, buffer, position, comm);
|
||||
unpack(restart_sched, buffer, position, comm);
|
||||
unpack(restart_keyw, buffer, position, comm);
|
||||
unpack(save_keyw, buffer, position, comm);
|
||||
data = RestartConfig(timemap, firstRstStep, writeInitialRst, restart_sched,
|
||||
restart_keyw, save_keyw);
|
||||
}
|
||||
|
||||
void unpack(OilVaporizationProperties& data,
|
||||
std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
@ -3072,17 +3010,6 @@ void unpack(Action::Actions& data, std::vector<char>& buffer, int& position,
|
||||
data = Action::Actions(actions);
|
||||
}
|
||||
|
||||
void unpack(RestartSchedule& data,
|
||||
std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
{
|
||||
unpack(data.timestep, buffer, position, comm);
|
||||
unpack(data.basic, buffer, position, comm);
|
||||
unpack(data.frequency, buffer, position, comm);
|
||||
unpack(data.rptsched_restart_set, buffer, position, comm);
|
||||
unpack(data.rptsched_restart, buffer, position, comm);
|
||||
}
|
||||
|
||||
void unpack(WellPolymerProperties& data,
|
||||
std::vector<char>& buffer, int& position,
|
||||
Dune::MPIHelper::MPICommunicator comm)
|
||||
|
@ -67,8 +67,6 @@ class Location;
|
||||
class MessageLimits;
|
||||
class MLimits;
|
||||
class OilVaporizationProperties;
|
||||
class RestartConfig;
|
||||
class RestartSchedule;
|
||||
class RFTConfig;
|
||||
class Segment;
|
||||
class SpiralICD;
|
||||
@ -442,9 +440,7 @@ ADD_PACK_PROTOTYPES(Location)
|
||||
ADD_PACK_PROTOTYPES(MessageLimits)
|
||||
ADD_PACK_PROTOTYPES(MLimits)
|
||||
ADD_PACK_PROTOTYPES(OilVaporizationProperties)
|
||||
ADD_PACK_PROTOTYPES(RestartConfig)
|
||||
ADD_PACK_PROTOTYPES(RestartKey)
|
||||
ADD_PACK_PROTOTYPES(RestartSchedule)
|
||||
ADD_PACK_PROTOTYPES(RestartValue)
|
||||
ADD_PACK_PROTOTYPES(RFTConfig)
|
||||
ADD_PACK_PROTOTYPES(Segment)
|
||||
|
@ -866,7 +866,7 @@ BOOST_AUTO_TEST_CASE(RestartSchedule)
|
||||
{
|
||||
#if HAVE_MPI
|
||||
Opm::RestartSchedule val1(1, 2, 3);
|
||||
auto val2 = PackUnpack(val1);
|
||||
auto val2 = PackUnpack2(val1);
|
||||
DO_CHECKS(RestartSchedule)
|
||||
#endif
|
||||
}
|
||||
@ -891,7 +891,7 @@ BOOST_AUTO_TEST_CASE(RestartConfig)
|
||||
Opm::IOConfig io(true, false, true, false, false, true, "test1", true,
|
||||
"test2", true, "test3", false);
|
||||
Opm::RestartConfig val1(getTimeMap(), 1, true, rsched, rkw, {false, true});
|
||||
auto val2 = PackUnpack(val1);
|
||||
auto val2 = PackUnpack2(val1);
|
||||
DO_CHECKS(RestartConfig)
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user