ERF
Energy Research and Forecasting: An Atmospheric Modeling Code
WriteBndryPlanes Class Reference

#include <ERF_WriteBndryPlanes.H>

Collaboration diagram for WriteBndryPlanes:

Public Member Functions

 WriteBndryPlanes (amrex::Vector< amrex::BoxArray > &grids, amrex::Vector< amrex::Geometry > &geom)
 
void write_planes (int t_step, double time, amrex::Vector< amrex::Vector< amrex::MultiFab >> &vars_new, bool is_moist)
 
bool start_series (int start_step, double start_time, bool restarting)
 

Static Public Member Functions

static int get_bndry_lev ()
 Level the planes are taken from. More...
 
static int rows_to_keep (const amrex::Vector< int > &steps, const amrex::Vector< double > &times, int start_step, double start_time, bool restarting)
 

Private Attributes

amrex::Box target_box
 IO output box region. More...
 
amrex::Vector< amrex::Geometry > & m_geom
 Geometry objects for all levels. More...
 
std::string m_filename {""}
 File name for IO. More...
 
std::string m_time_file {""}
 File name for Native time file. More...
 
amrex::Vector< std::string > m_var_names
 Variables for IO. More...
 
amrex::Vector< std::string > m_kept_rows
 Rows of time.dat the run continues from, written back before its first plane (I/O rank) More...
 
bool m_rewrite_time_file = false
 Whether time.dat still has to be rewritten to m_kept_rows (I/O rank) More...
 
amrex::Vector< double > m_in_times
 Timestep and times to be stored in time.dat. More...
 
amrex::Vector< int > m_in_timesteps
 
int m_in_rad = 1
 controls extents on native bndry output More...
 
const int m_out_rad = 1
 
const int m_extent_rad = 0
 

Static Private Attributes

static int bndry_lev = 0
 

Detailed Description

Interface for writing boundary planes

This class performs the necessary file operations to write boundary planes

Constructor & Destructor Documentation

◆ WriteBndryPlanes()

WriteBndryPlanes::WriteBndryPlanes ( amrex::Vector< amrex::BoxArray > &  grids,
amrex::Vector< amrex::Geometry > &  geom 
)
explicit

Constructor for the WriteBndryPlanes class for writing the contents of boundary planes to an output file

Parameters
gridsVector of BoxArrays containing the grids at each level in the AMR
geomVector of Geometry containing the geometry at each level in the AMR
66  : m_geom(geom)
67 {
68  ParmParse pp("erf");
69 
70  // Get the radius inside the domain
71  pp.queryAdd("in_rad",m_in_rad);
72 
73  // User-specified region is given in physical coordinates, not index space
74  std::vector<Real> box_lo(3), box_hi(3);
75  pp.getarr("bndry_output_box_lo",box_lo,0,2);
76  pp.getarr("bndry_output_box_hi",box_hi,0,2);
77 
78  // If the target area is contained at a finer level, use the finest data possible.
79  // target_box is expressed in the index space of bndry_lev, so it must only be set
80  // together with bndry_lev; each level's candidate box is kept in a local variable.
81  for (int ilev = 0; ilev < grids.size(); ilev++) {
82 
83  const Real* xLo = m_geom[ilev].ProbLo();
84  auto const dxi = geom[ilev].InvCellSizeArray();
85  const Box& domain = m_geom[ilev].Domain();
86 
87  // We create the smallest box that contains all of the cell centers
88  // in the physical region specified
89  int ilo = static_cast<int>(Math::floor((box_lo[0] - xLo[0]) * dxi[0] + Real(.5)));
90  int jlo = static_cast<int>(Math::floor((box_lo[1] - xLo[1]) * dxi[1] + Real(.5)));
91  int ihi = static_cast<int>(Math::floor((box_hi[0] - xLo[0]) * dxi[0] + Real(.5)))-1;
92  int jhi = static_cast<int>(Math::floor((box_hi[1] - xLo[1]) * dxi[1] + Real(.5)))-1;
93 
94  // Map this to index space -- for now we do no interpolation
95  Box box_this_lev(IntVect(ilo,jlo,0),
96  IntVect(ihi,jhi,domain.bigEnd(2)));
97 
98  // The boundary register reaches m_out_rad cells outside the box in x and y. Those cells
99  // may lie outside the domain: write_planes reads them from the ghost cells, which
100  // ERF::write_bndry_planes fills first. Only the part inside the domain has to be
101  // covered by the grids at this level.
102  Box gbx = box_this_lev; gbx.grow(IntVect(m_out_rad,m_out_rad,0));
103  gbx &= domain;
104 
105  // The box itself has to lie inside the domain: past the m_out_rad ghost cells there
106  // is no data to copy from
107  if (ilev == 0) {
108  if (!box_this_lev.ok()) {
109  Abort("WriteBndryPlanes: erf.bndry_output_box_lo/hi do not contain any cell centers");
110  }
111  if (!domain.contains(box_this_lev)) {
112  Abort("WriteBndryPlanes: the box given by erf.bndry_output_box_lo/hi must lie"
113  " inside the domain");
114  }
115 
116  // Default to level 0
117  target_box = box_this_lev;
118  }
119 
120  // Use this level's data only if its grids fully contain the requested region
121  if (grids[ilev].contains(gbx)) {
122  bndry_lev = ilev;
123  target_box = box_this_lev;
124  }
125  }
126 
127  // The folder "m_filename" will contain the time series of data and the time.dat file
128  pp.get("bndry_output_planes_file", m_filename);
129 
130  m_time_file = m_filename + "/time.dat";
131 
132  if (pp.contains("bndry_output_var_names"))
133  {
134  int num_vars = pp.countval("bndry_output_var_names");
135  m_var_names.resize(num_vars);
136  pp.queryarr("bndry_output_var_names",m_var_names,0,num_vars);
137  }
138 }
ParmParse pp("prob")
amrex::Real Real
Definition: ERF_ShocInterface.H:19
amrex::Vector< amrex::Geometry > & m_geom
Geometry objects for all levels.
Definition: ERF_WriteBndryPlanes.H:51
int m_in_rad
controls extents on native bndry output
Definition: ERF_WriteBndryPlanes.H:77
static int bndry_lev
Definition: ERF_WriteBndryPlanes.H:74
const int m_out_rad
Definition: ERF_WriteBndryPlanes.H:78
amrex::Box target_box
IO output box region.
Definition: ERF_WriteBndryPlanes.H:48
amrex::Vector< std::string > m_var_names
Variables for IO.
Definition: ERF_WriteBndryPlanes.H:60
std::string m_time_file
File name for Native time file.
Definition: ERF_WriteBndryPlanes.H:57
std::string m_filename
File name for IO.
Definition: ERF_WriteBndryPlanes.H:54
Here is the call graph for this function:

Member Function Documentation

◆ get_bndry_lev()

static int WriteBndryPlanes::get_bndry_lev ( )
inlinestatic

Level the planes are taken from.

36 { return bndry_lev; }

Referenced by ERF::write_bndry_planes().

Here is the caller graph for this function:

◆ rows_to_keep()

int WriteBndryPlanes::rows_to_keep ( const amrex::Vector< int > &  steps,
const amrex::Vector< double > &  times,
int  start_step,
double  start_time,
bool  restarting 
)
static

How many leading rows of a time.dat with these steps and times a run starting at start_step and start_time keeps: on a restart the rows up to and including the restart that increase in step and time and are not later than the restart; on a fresh start none.

Number of leading rows of time.dat that a run starting at step start_step keeps.

A restart replays the steps after its checkpoint, so the rows for those steps – written by a run that went on past the checkpoint – are dropped and written again. Rows also stop being kept at the first one whose step or time does not increase, or that is later than the restart, or that is at the restart step but not at the restart time: those were not written by the run being continued. A fresh start begins a new series.

Parameters
stepsStep column of time.dat, in file order
timesTime column of time.dat, in file order
start_stepStep the run starts at
start_timeTime the run starts at, as written in time.dat
restartingWhether the run starts from a checkpoint
158 {
159  if (!restarting) { return 0; }
160  // The times of the run being continued are the restart's own to the last bit (time.dat and
161  // the checkpoint both hold 17 digits); a few units in the last place only allow for a
162  // time.dat written by hand, and stay far below any plane spacing also at a calendar clock
163  const double tol = 16.0 * std::numeric_limits<double>::epsilon() * std::max(1.0, std::abs(start_time));
164  int nkeep = 0;
165  for (int i = 0; i < steps.size(); ++i) {
166  if (steps[i] > start_step || times[i] > start_time + tol) { break; }
167  if (i > 0 && (steps[i] <= steps[i-1] || times[i] <= times[i-1])) { break; }
168  if (steps[i] == start_step && std::abs(times[i] - start_time) > tol) { break; }
169  ++nkeep;
170  }
171  return nkeep;
172 }
real(c_double), parameter epsilon
Definition: ERF_module_model_constants.F90:12

Referenced by start_series().

Here is the caller graph for this function:

◆ start_series()

bool WriteBndryPlanes::start_series ( int  start_step,
double  start_time,
bool  restarting 
)

Decide which rows of time.dat a run starting at step start_step (at time start_time, with start_time the absolute time written in time.dat) continues from: a restart keeps the rows the run before it wrote up to that step, a fresh start keeps none. The file is rewritten only when the run writes its first plane, so a run that stops before then leaves it as it was. Returns whether the kept rows end with a plane at start_step itself.

Decide which rows of time.dat a run starting at step start_step continues from, and say whether the series already holds the plane at that step. Only the I/O rank reads the file; every rank gets the answer. The file itself is rewritten by write_planes, just before the run's first row, so a run that stops before its first plane leaves the series as it found it.

Parameters
start_stepStep the run starts at (the restart step, or 0)
start_timeTime the run starts at, as written in time.dat
restartingWhether the run starts from a checkpoint
186 {
187  int has_start_plane = 0;
188  if (ParallelDescriptor::IOProcessor()) {
189  std::ifstream in(m_time_file);
190  if (in.good()) {
191  // Every line counts, so that a line that does not parse -- a partial last row left
192  // by a run that stopped while writing it, say -- is dropped with the rows after it
193  Vector<std::string> rows;
194  Vector<int> steps;
195  Vector<double> times;
196  int nlines = 0;
197  std::string line;
198  while (std::getline(in, line)) {
199  ++nlines;
200  std::istringstream row(line);
201  int step;
202  double time;
203  if (static_cast<int>(rows.size()) + 1 < nlines || !(row >> step >> time)) { continue; }
204  rows.push_back(line);
205  steps.push_back(step);
206  times.push_back(time);
207  }
208  in.close();
209 
210  const int nkeep = rows_to_keep(steps, times, start_step, start_time, restarting);
211  has_start_plane = (nkeep > 0 && steps[nkeep-1] == start_step) ? 1 : 0;
212 
213  // A row whose step or time does not increase, anywhere in the file, or a row at or
214  // before the restart that does not continue the kept rows, cannot come from one run
215  bool broken = false;
216  for (int i = 1; i < rows.size(); ++i) {
217  if (steps[i] <= steps[i-1] || times[i] <= times[i-1]) { broken = true; }
218  }
219  if (restarting && nkeep < rows.size() && steps[nkeep] <= start_step) { broken = true; }
220 
221  if (restarting && broken) {
222  Warning("WriteBndryPlanes: " + m_time_file + " does not hold one run's series: a step "
223  "or time does not increase, or a row at or before the restart step " +
224  std::to_string(start_step) + " is not at a time of this run. Only its first " +
225  std::to_string(nkeep) + " rows are kept. A series that an earlier ERF version "
226  "wrote across a restart has such a row, and its step-0 plane holds the "
227  "restart state; write that series again.");
228  } else if (nkeep < nlines) {
229  if (restarting) {
230  Print() << "WriteBndryPlanes: keeping " << nkeep << " of the " << nlines
231  << " rows of " << m_time_file << " up to the restart step "
232  << start_step << ", from this run's first plane on" << std::endl;
233  } else {
234  Print() << "WriteBndryPlanes: a fresh start begins a new series; the "
235  << nlines << " rows of " << m_time_file
236  << " are dropped with this run's first plane" << std::endl;
237  }
238  }
239 
240  // Rewrite even when every row is kept: a last row without its newline would
241  // otherwise run into the next row written
242  m_kept_rows.clear();
243  for (int i = 0; i < nkeep; ++i) {
244  m_kept_rows.push_back(rows[i]);
245  }
246  m_rewrite_time_file = true;
247  }
248  }
249  ParallelDescriptor::Bcast(&has_start_plane, 1, ParallelDescriptor::IOProcessorNumber(),
250  ParallelDescriptor::Communicator());
251  return has_start_plane == 1;
252 }
static int rows_to_keep(const amrex::Vector< int > &steps, const amrex::Vector< double > &times, int start_step, double start_time, bool restarting)
Definition: ERF_WriteBndryPlanes.cpp:155
bool m_rewrite_time_file
Whether time.dat still has to be rewritten to m_kept_rows (I/O rank)
Definition: ERF_WriteBndryPlanes.H:66
amrex::Vector< std::string > m_kept_rows
Rows of time.dat the run continues from, written back before its first plane (I/O rank)
Definition: ERF_WriteBndryPlanes.H:63
Here is the call graph for this function:

◆ write_planes()

void WriteBndryPlanes::write_planes ( int  t_step,
double  time,
amrex::Vector< amrex::Vector< amrex::MultiFab >> &  vars_new,
bool  is_moist 
)

Function to write the specified grid data to an output file

Parameters
t_stepTimestep number
timeCurrent time
vars_newGrid data for all variables across the AMR hierarchy
is_moistWhether moist state components are included in the output
265 {
266  BL_PROFILE("ERF::WriteBndryPlanes::write_planes");
267 
268  MultiFab& S = vars_new[bndry_lev][Vars::cons];
269  MultiFab& xvel = vars_new[bndry_lev][Vars::xvel];
270  MultiFab& yvel = vars_new[bndry_lev][Vars::yvel];
271  MultiFab& zvel = vars_new[bndry_lev][Vars::zvel];
272 
273  // A moist temperature plane is computed with qv (erf_dermoisttemp), and the reader needs that
274  // qv to convert it back to theta: without a qv plane it cannot be read correctly
275  if (is_moist) {
276  bool writes_temperature = false;
277  bool writes_qv = false;
278  for (const auto& name : m_var_names) {
279  if (name == "temperature") { writes_temperature = true; }
280  if (name == "qv") { writes_qv = true; }
281  }
282  if (writes_temperature && !writes_qv) {
283  Abort("erf.bndry_output_var_names writes temperature but not qv in a moist run: the"
284  " temperature includes qv, and the reader needs the qv planes to convert it back"
285  " to theta. Add qv to erf.bndry_output_var_names, or write theta instead of"
286  " temperature");
287  }
288  }
289 
290  const std::string chkname =
291  m_filename + Concatenate("/bndry_output", t_step);
292 
293  //Print() << "Writing boundary planes at time " << time_d << std::endl;
294 
295  const std::string level_prefix = "Level_";
296  PreBuildDirectorHierarchy(chkname, level_prefix, 1, true);
297 
298  // note: by using the entire domain box we end up using 1 processor
299  // to hold all boundaries
300  BoxArray ba(target_box);
301  DistributionMapping dm{ba};
302 
303  IntVect new_hi = target_box.bigEnd() - target_box.smallEnd();
304  Box target_box_shifted(IntVect(0,0,0),new_hi);
305  BoxArray ba_shifted(target_box_shifted);
306 
307  for (int i = 0; i < m_var_names.size(); i++)
308  {
309  std::string var_name = m_var_names[i];
310  std::string filename = MultiFabFileFullPrefix(bndry_lev, chkname, level_prefix, var_name);
311 
312  int ncomp;
313  if (var_name == "velocity") {
314  ncomp = AMREX_SPACEDIM;
315  } else {
316  ncomp = 1;
317  }
318 
319  BndryRegister bndry (ba , dm, m_in_rad, m_out_rad, m_extent_rad, ncomp);
320  BndryRegister bndry_shifted(ba_shifted, dm, m_in_rad, m_out_rad, m_extent_rad, ncomp);
321 
322  // Read the cells around the box from the ghost cells where they lie outside the grids
323  int nghost = m_out_rad;
324  if (var_name == "density")
325  {
326  bndry.copyFrom(S, nghost, Rho_comp, 0, ncomp, m_geom[bndry_lev].periodicity());
327 
328  } else if (var_name == "temperature") {
329  MultiFab Temp(S.boxArray(),S.DistributionMap(),ncomp,m_out_rad);
330  for (MFIter mfi(Temp, TilingIfNotGPU()); mfi.isValid(); ++mfi)
331  {
332  const Box& bx = mfi.growntilebox(m_out_rad);
333  Real time = static_cast<Real>(time_d);
334  if (is_moist) {
335  // NOTE: we send in S[mfi] where we should send in (*z_phys_cc[lev])[mfi] because we know this routine doesn't use it
336  derived::erf_dermoisttemp(bx, Temp[mfi], 0, 1, S[mfi], S[mfi], m_geom[bndry_lev], time, nullptr, bndry_lev);
337  } else {
338  // NOTE: we send in S[mfi] where we should send in (*z_phys_cc[lev])[mfi] because we know this routine doesn't use it
339  derived::erf_dertemp(bx, Temp[mfi], 0, 1, S[mfi], S[mfi], m_geom[bndry_lev], time, nullptr, bndry_lev);
340  }
341  }
342  bndry.copyFrom(Temp, nghost, 0, 0, ncomp, m_geom[bndry_lev].periodicity());
343  } else if (var_name == "theta") {
344  MultiFab Temp(S.boxArray(),S.DistributionMap(),ncomp,m_out_rad);
345  for (MFIter mfi(Temp, TilingIfNotGPU()); mfi.isValid(); ++mfi)
346  {
347  const Box& bx = mfi.growntilebox(m_out_rad);
348  derived::erf_derrhodivide(bx, Temp[mfi], S[mfi], RhoTheta_comp);
349  }
350  bndry.copyFrom(Temp, nghost, 0, 0, ncomp, m_geom[bndry_lev].periodicity());
351  } else if (var_name == "scalar") {
352  MultiFab Temp(S.boxArray(),S.DistributionMap(),ncomp,m_out_rad);
353  for (MFIter mfi(Temp, TilingIfNotGPU()); mfi.isValid(); ++mfi)
354  {
355  const Box& bx = mfi.growntilebox(m_out_rad);
356  derived::erf_derrhodivide(bx, Temp[mfi], S[mfi], RhoScalar_comp);
357  }
358  bndry.copyFrom(Temp, nghost, 0, 0, ncomp, m_geom[bndry_lev].periodicity());
359  } else if (var_name == "ke") {
360  MultiFab Temp(S.boxArray(),S.DistributionMap(),ncomp,m_out_rad);
361  for (MFIter mfi(Temp, TilingIfNotGPU()); mfi.isValid(); ++mfi)
362  {
363  const Box& bx = mfi.growntilebox(m_out_rad);
364  derived::erf_derrhodivide(bx, Temp[mfi], S[mfi], RhoKE_comp);
365  }
366  bndry.copyFrom(Temp, nghost, 0, 0, ncomp, m_geom[bndry_lev].periodicity());
367  } else if (var_name == "qv") {
368  MultiFab Temp(S.boxArray(),S.DistributionMap(),ncomp,m_out_rad);
369  if (S.nComp() > RhoQ2_comp) {
370  for (MFIter mfi(Temp, TilingIfNotGPU()); mfi.isValid(); ++mfi)
371  {
372  const Box& bx = mfi.growntilebox(m_out_rad);
373  derived::erf_derrhodivide(bx, Temp[mfi], S[mfi], RhoQ1_comp);
374  }
375  } else {
376  Temp.setVal(0.);
377  }
378  bndry.copyFrom(Temp, nghost, 0, 0, ncomp, m_geom[bndry_lev].periodicity());
379  } else if (var_name == "qc") {
380  MultiFab Temp(S.boxArray(),S.DistributionMap(),ncomp,m_out_rad);
381  if (S.nComp() > RhoQ2_comp) {
382  for (MFIter mfi(Temp, TilingIfNotGPU()); mfi.isValid(); ++mfi)
383  {
384  const Box& bx = mfi.growntilebox(m_out_rad);
385  derived::erf_derrhodivide(bx, Temp[mfi], S[mfi], RhoQ2_comp);
386  }
387  } else {
388  Temp.setVal(0.);
389  }
390  bndry.copyFrom(Temp, nghost, 0, 0, ncomp, m_geom[bndry_lev].periodicity());
391  } else if (var_name == "velocity") {
392  MultiFab Vel(S.boxArray(), S.DistributionMap(), 3, m_out_rad);
393  average_face_to_cellcenter(Vel,0,Array<const MultiFab*,3>{&xvel,&yvel,&zvel},m_out_rad);
394  bndry.copyFrom(Vel, nghost, 0, 0, ncomp, m_geom[bndry_lev].periodicity());
395  } else {
396  //Print() << "Trying to write planar output for " << var_name << std::endl;
397  Error("Don't know how to output this variable");
398  }
399 
400  for (OrientationIter oit; oit != nullptr; ++oit) {
401  auto ori = oit();
402  if (ori.coordDir() < 2) {
403  std::string facename = Concatenate(filename + '_', ori, 1);
404  br_shift(oit, bndry, bndry_shifted);
405  bndry_shifted[ori].write(facename);
406  }
407  }
408 
409  } // loop over num_vars
410 
411  // Writing time.dat
412  if (ParallelDescriptor::IOProcessor()) {
413  // The rows this run continues from replace the file before its first row, through a
414  // temporary file so that a crash leaves either the old file or the new one
415  if (m_rewrite_time_file) {
416  const std::string tmp_file = m_time_file + ".tmp";
417  std::ofstream out(tmp_file, std::ios::out | std::ios::trunc);
418  for (const auto& row : m_kept_rows) {
419  out << row << '\n';
420  }
421  out.close();
422  if (out.fail()) {
423  Abort("WriteBndryPlanes: cannot write " + tmp_file);
424  }
425  std::error_code ec;
426  std::filesystem::rename(tmp_file, m_time_file, ec);
427  if (ec) {
428  Abort("WriteBndryPlanes: cannot replace " + m_time_file + " with " + tmp_file + ": " + ec.message());
429  }
430  m_rewrite_time_file = false;
431  m_kept_rows.clear();
432  }
433  std::ofstream oftime(m_time_file, std::ios::out | std::ios::app);
434  oftime << std::setprecision(17) << t_step << ' ' << time_d << '\n';
435  oftime.close();
436  }
437 }
#define RhoScalar_comp
Definition: ERF_IndexDefines.H:57
#define Rho_comp
Definition: ERF_IndexDefines.H:53
#define RhoTheta_comp
Definition: ERF_IndexDefines.H:54
#define RhoQ2_comp
Definition: ERF_IndexDefines.H:67
#define RhoQ1_comp
Definition: ERF_IndexDefines.H:66
#define RhoKE_comp
Definition: ERF_IndexDefines.H:55
std::string name
Definition: ERF_Plotfile2DCatalog.cpp:116
void br_shift(OrientationIter oit, const BndryRegister &b1, BndryRegister &b2)
Definition: ERF_WriteBndryPlanes.cpp:29
const int m_extent_rad
Definition: ERF_WriteBndryPlanes.H:79
constexpr int S
Definition: ERF_TwoStreamColumn.H:604
@ xvel
Definition: ERF_IndexDefines.H:255
@ cons
Definition: ERF_IndexDefines.H:254
@ zvel
Definition: ERF_IndexDefines.H:257
@ yvel
Definition: ERF_IndexDefines.H:256
void erf_derrhodivide(const Box &bx, FArrayBox &derfab, const FArrayBox &datfab, const int scalar_index)
Definition: ERF_Derive.cpp:183
void erf_dermoisttemp(const Box &bx, FArrayBox &derfab, int, int, const FArrayBox &datfab, const FArrayBox &, const Geometry &, Real, const int *, const int)
Definition: ERF_Derive.cpp:281
void erf_dertemp(const Box &bx, FArrayBox &derfab, int, int, const FArrayBox &datfab, const FArrayBox &, const Geometry &, Real, const int *, const int)
Definition: ERF_Derive.cpp:258
Here is the call graph for this function:

Member Data Documentation

◆ bndry_lev

int WriteBndryPlanes::bndry_lev = 0
staticprivate

◆ m_extent_rad

const int WriteBndryPlanes::m_extent_rad = 0
private

Referenced by write_planes().

◆ m_filename

std::string WriteBndryPlanes::m_filename {""}
private

File name for IO.

Referenced by write_planes(), and WriteBndryPlanes().

◆ m_geom

amrex::Vector<amrex::Geometry>& WriteBndryPlanes::m_geom
private

Geometry objects for all levels.

Referenced by write_planes(), and WriteBndryPlanes().

◆ m_in_rad

int WriteBndryPlanes::m_in_rad = 1
private

controls extents on native bndry output

Referenced by write_planes(), and WriteBndryPlanes().

◆ m_in_times

amrex::Vector<double> WriteBndryPlanes::m_in_times
private

Timestep and times to be stored in time.dat.

◆ m_in_timesteps

amrex::Vector<int> WriteBndryPlanes::m_in_timesteps
private

◆ m_kept_rows

amrex::Vector<std::string> WriteBndryPlanes::m_kept_rows
private

Rows of time.dat the run continues from, written back before its first plane (I/O rank)

Referenced by start_series(), and write_planes().

◆ m_out_rad

const int WriteBndryPlanes::m_out_rad = 1
private

Referenced by write_planes(), and WriteBndryPlanes().

◆ m_rewrite_time_file

bool WriteBndryPlanes::m_rewrite_time_file = false
private

Whether time.dat still has to be rewritten to m_kept_rows (I/O rank)

Referenced by start_series(), and write_planes().

◆ m_time_file

std::string WriteBndryPlanes::m_time_file {""}
private

File name for Native time file.

Referenced by start_series(), write_planes(), and WriteBndryPlanes().

◆ m_var_names

amrex::Vector<std::string> WriteBndryPlanes::m_var_names
private

Variables for IO.

Referenced by write_planes(), and WriteBndryPlanes().

◆ target_box

amrex::Box WriteBndryPlanes::target_box
private

IO output box region.

Referenced by write_planes(), and WriteBndryPlanes().


The documentation for this class was generated from the following files: