Bugfixes;
Restarts now reproduce longer Sims
This commit is contained in:
@@ -34,8 +34,9 @@ std::shared_ptr<Injector> buildInjector(
|
||||
json_path_append(path_to_injector, {"CreatedSpecies", std::string(key),
|
||||
"CreationVelocityDistribution"}));
|
||||
|
||||
// missing a check if the value is positive
|
||||
info.multiplicity = json_int(json_object_by_path(value, {"Multiplicity"}), 1);
|
||||
ASSERT_POSITIVE(&info.multiplicity, "The multiplicity has to be positive. " +
|
||||
specie_name + " multiplicity: " + std::to_string(info.multiplicity));
|
||||
injector_infos.push_back(info);
|
||||
}
|
||||
|
||||
|
||||
@@ -7,11 +7,12 @@ namespace generator {
|
||||
DEBUG_LEVEL_3("Build Restart.");
|
||||
bool do_restart = json_bool(json_object_by_path(object, {"Do"}));
|
||||
if (!do_restart) {
|
||||
DEBUG_LEVEL_3("No Restart desired");
|
||||
DEBUG_LEVEL_0("No Restart desired.");
|
||||
return Restart(false, "", "");
|
||||
}
|
||||
|
||||
std::string filepath = readAbsoluteFilename(json_object_by_path(object, {"PathToH5"}));
|
||||
std::string filepath = readAbsoluteFilename(json_object_by_path(object, {"PathToH5"}))
|
||||
+ ".h5";
|
||||
DEBUG_LEVEL_3("Restart: file path:" + filepath);
|
||||
|
||||
std::string identifier;
|
||||
|
||||
Reference in New Issue
Block a user