pencil.read.grids
Contains classes and methods to read the grid data.
Classes
Grid -- holds pencil code time grid data. |
Functions
|
Wrapper for |
Module Contents
- class pencil.read.grids.Grid
Bases:
objectGrid – holds pencil code time grid data.
Fill members with default values.
- t = 0
- keys()
- read(datadir='data', proc=-1, quiet=True, precision='f', trim=False, param=None)
read(datadir=’data’, proc=-1, quiet=True, trim=False)
Read the grid data from the pencil code simulation. If proc < 0, then load all data and assemble. Otherwise, load grid from specified processor.
- Parameters:
datadir (string) – Directory where the data is stored.
proc (int) – Processor to be read. If proc is -1, then read the ‘global’ grid. If proc is >=0, then read the grid.dat in the corresponding processor directory.
quiet (bool) – Flag for switching of output.
trim (bool) – Cuts off the ghost points.
- Return type:
Class containing the grid information.
- restrict(irange_x, irange_y, irange_z)
Restrict the grid arrays according to the index ranges irange_[xyz]
- pencil.read.grids.grid(*args, **kwargs)
Wrapper for
Grid.read()