|
PHYEX 0.9.5
PHYsique EXternalisée
|


Public Member Functions | |
| __init__ (self, inputfile, attrs=None) | |
| is_open (self) | |
| open (self) | |
| close (self) | |
| contains (self, varname) | |
| get (self, varname, slice_idx=None) | |
| duration (self) | |
| get_interpolator (self, varname, grid) | |
| description (self) | |
| Public Member Functions inherited from pyphyex.phyex1d.case.Case | |
| __enter__ (self) | |
| __exit__ (self, *args) | |
Public Attributes | |
| int | adv_ua = 0 |
| int | adv_va = 0 |
Static Public Attributes | |
| dict | nc_names |
Protected Attributes | |
| _inputfile = inputfile | |
| _nc = None | |
| dict | _interpolators = {} |
Case backed by a netCDF driver file in the DEPHY common format
| pyphyex.phyex1d.case.CaseCommonFormat.__init__ | ( | self, | |
| inputfile, | |||
| attrs = None ) |
| pyphyex.phyex1d.case.CaseCommonFormat.close | ( | self | ) |
Close the netCDF file if open
Reimplemented from pyphyex.phyex1d.case.Case.
Definition at line 158 of file case.py.


| pyphyex.phyex1d.case.CaseCommonFormat.contains | ( | self, | |
| varname ) |
Check if a variable exists in the netCDF file
Parameters
----------
varname : str
Variable name (translated via nc_names if present)
Returns
-------
bool
True if the variable exists
Reimplemented from pyphyex.phyex1d.case.Case.
Definition at line 164 of file case.py.

| pyphyex.phyex1d.case.CaseCommonFormat.description | ( | self | ) |
Case description
Returns
-------
str
Case description string (file path)
Reimplemented from pyphyex.phyex1d.case.Case.
| pyphyex.phyex1d.case.CaseCommonFormat.duration | ( | self | ) |
Simulation duration
Returns
-------
float
Duration in seconds (time[-1] - time[0])
Reimplemented from pyphyex.phyex1d.case.Case.
Definition at line 204 of file case.py.

| pyphyex.phyex1d.case.CaseCommonFormat.get | ( | self, | |
| varname, | |||
| slice_idx = None ) |
Read a variable from the netCDF file
Parameters
----------
varname : str
Variable name (translated via nc_names if present)
slice_idx : int or None, optional
Slice index to read. None returns the full array.
Returns
-------
numpy.ndarray
The data array
Reimplemented from pyphyex.phyex1d.case.Case.
Definition at line 182 of file case.py.


| pyphyex.phyex1d.case.CaseCommonFormat.get_interpolator | ( | self, | |
| varname, | |||
| grid ) |
Get from cache or build an interpolator for a forcing variable
Parameters
----------
varname : str
Variable name
grid : Grid
Grid instance for vertical coordinate
Returns
-------
RegularGridInterpolator
The interpolator
Reimplemented from pyphyex.phyex1d.case.Case.
Definition at line 217 of file case.py.

| pyphyex.phyex1d.case.CaseCommonFormat.is_open | ( | self | ) |
| pyphyex.phyex1d.case.CaseCommonFormat.open | ( | self | ) |
|
protected |
|
protected |