Skip to content

geoms

GEOMS Profile Reader. Deprecated wrapper — use monetio.load('geoms', ...) instead.

open_dataset(fp, *, rename_all=True, squeeze=True, **kwargs)

Open a file in GEOMS format, e.g. modern TOLNet files.

Parameters:

Name Type Description Default
fp str

File path.

required
rename_all bool

Rename all non-coordinate variables.

True
squeeze bool

Apply .squeeze() before returning the Dataset.

True
**kwargs dict

Additional arguments forwarded to GEOMSReader.open_dataset.

{}

Returns:

Type Description
Dataset
Source code in monetio/profile/geoms.py
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
@deprecated_wrapper(
    "monetio.profile.geoms.open_dataset",
    'monetio.load("geoms", files=...)',
)
def open_dataset(fp, *, rename_all=True, squeeze=True, **kwargs):
    """Open a file in GEOMS format, e.g. modern TOLNet files.

    Parameters
    ----------
    fp : str
        File path.
    rename_all : bool, default: True
        Rename all non-coordinate variables.
    squeeze : bool, default: True
        Apply ``.squeeze()`` before returning the Dataset.
    **kwargs : dict
        Additional arguments forwarded to ``GEOMSReader.open_dataset``.

    Returns
    -------
    xarray.Dataset
    """
    return GEOMSReader().open_dataset(files=fp, rename_all=rename_all, squeeze=squeeze, **kwargs)