[refactoring] change name of cons rule to coarse_step

This commit is contained in:
Noe Brucy
2021-01-28 11:56:28 +01:00
parent 6f69470440
commit 9f8da0a8db
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -271,7 +271,7 @@ class Comparator(Aggregator, HDF5Container):
series["mempc2"][run].append(mempc2)
return series
def _extract_cons_from_log(self, series, log_filename, run):
def _extract_coarse_step_from_log(self, series, log_filename, run):
rism = self.pp_params.input.ramses_ism
nlines = 2 + int(rism) # Number of useful lines
cmd_grep = "grep 'Main step' {} -A {}".format(log_filename, nlines - 1)
@@ -576,12 +576,12 @@ class Comparator(Aggregator, HDF5Container):
"turb_energy": "Injected turbulent energy",
},
),
"cons_from_log": Rule(
"coarse_step_from_log": Rule(
self,
partial(
self._from_log,
["time", "step", "mcons", "econs", "epot", "ekin", "eint", "emag"],
self._extract_cons_from_log,
self._extract_coarse_step_from_log,
),
group="/series",
unit={