postgkyl.GData.load¶
- GData.load(file_name, *, tag=None, label=None, ctx=None, value_form=None, basis_type=None, poly_order=None, **read_kwargs)¶
Load one file into this dataset in place and return
self.This is the two-step counterpart of constructing
GData(file_name):data = GData() data.load(file_name).local_poly().plot()
The read is atomic with respect to this object: if it fails, the current grid, values, context, and filename are left unchanged. A pristine empty dataset’s existing
ctxseeds the read unlessctxis supplied explicitly; reloading an already populated dataset starts from a fresh context so metadata from the previous file cannot leak into the new one. The dataset’s existing tag and custom label are preserved unlesstagorlabelis passed.This method accepts one literal filename. Use
postgkyl.load()for shell-style glob patterns, which produce aGDataGrouprather than one dataset.