Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/source/concepts/field.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ A :py:class:`~earthkit.data.core.fieldlist.FieldList` is a collection of :py:cla
How-tos:

- :ref:`/how-tos/field/field_overview.ipynb`
- :ref:`/how-tos/grib/grib_overview.ipynb``
- :ref:`/how-tos/grib/grib_overview.ipynb`
2 changes: 1 addition & 1 deletion docs/source/concepts/misc/grib_metadata.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.. _grib-metadata-cache
.. _grib-metadata-cache:

GRIB field metadata caching
//////////////////////////////
Expand Down
2 changes: 1 addition & 1 deletion docs/source/concepts/xarray/overview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ It is possible to directly write the Xarray dataset created with the earthkit en
Using to_fieldlist()
++++++++++++++++++++

We can also convert the Xarray dataset into a GRIB fieldlist by using :py:meth:`~earthkit.data.xr_engine.engine.XarrayEarthkit.to_fieldlist` on the ``earthkit`` accessor of the Xarray object. Please note that this will generate a fieldlist entirely stored in memory. This method only works if the Xarray dataset was generated with the earthkit engine from GRIB data.\
We can also convert the Xarray dataset into a GRIB fieldlist by using :py:meth:`~earthkit.data.xr_engine.engine.XarrayEarthkit.to_fieldlist` on the ``earthkit`` accessor of the Xarray object. Please note that this will generate a fieldlist entirely stored in memory. This method only works if the Xarray dataset was generated with the earthkit engine from GRIB data.

.. code-block:: python

Expand Down
2 changes: 1 addition & 1 deletion docs/source/experimental/grib_tensor.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -692,7 +692,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Repetaed sel()"
"#### Repeated sel()"
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion docs/source/how-tos/grib/grib_contents.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
"tags": []
},
"source": [
"py:meth:`~earthkit.data.core.fieldlist.FieldList.ls`) lists all the fields:"
":py:meth:`~earthkit.data.core.fieldlist.FieldList.ls`) lists all the fields:"
]
},
{
Expand Down
7 changes: 5 additions & 2 deletions docs/source/how-tos/misc/config.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,13 @@
"slideshow": {
"slide_type": ""
},
"tags": []
"tags": [],
"vscode": {
"languageId": "raw"
}
},
"source": [
"The :ref:`config` object is loaded from the ``~/.config/earthkit/data/config.yaml`` file. Changes are immediately saved back into this file unless we explicitly disable it with ``config.autosave` or use a :ref:`temporary configuration <config_temporary>`."
" \"The :ref:`config` object is loaded from the ``~/.config/earthkit/data/config.yaml`` file. Changes are immediately saved back into this file unless we explicitly disable it with ``config.autosave`` or use a :ref:`temporary configuration <config_temporary>`.\""
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion docs/source/how-tos/source/files.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
"tags": []
},
"source": [
"First, we ensure the example files used for this notebook are avaliable."
"First, we ensure the example files used for this notebook are available."
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion docs/source/how-tos/source/url_stream.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
"tags": []
},
"source": [
"The resulting object only supports one iteration. Having finsihed the iteration the stream is consumed and no more data is available."
" \"The resulting object only supports one iteration. Having finished the iteration the stream is consumed and no more data is available.\""
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion src/earthkit/data/core/field.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ def __init__(
labels=None,
):
"""
Cretae a Field object.
Create a Field object.

Do not use this constructor directly, but use the factory methods such as :meth:`from_dict`

Expand Down
2 changes: 1 addition & 1 deletion src/earthkit/data/data/grib.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ def to_numpy(self, *args, **kwargs) -> "numpy.ndarray":
def to_array(self, *args, **kwargs) -> ArrayLike:
"""Convert into an array of a given array-like type.

It is done by fist converting the GRIB data into a fieldlist and calling the fieldlist's
It is done by first converting the GRIB data into a fieldlist and calling the fieldlist's
:py:func:`to_array <earthkit.data.core.fieldlist.FieldList.to_array>` method.

Parameters
Expand Down
4 changes: 2 additions & 2 deletions src/earthkit/data/data/stream.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class StreamFeatureListData(SourceData):

- either by providing iteration through the stream of features once, which is more
efficient for larger datasets and allows for processing data in chunks without consuming
large amounts of memory. This is the default behavior when calling :py:func:`to_featurelist`
large amounts of memory. This is the default behaviour when calling :py:func:`to_featurelist`
without any arguments, or with ``read_all=False``.
- or by reading all features into memory, which may be suitable for smaller datasets or
when random access is needed. This can be achieved by calling :py:func:`to_featurelist`
Expand Down Expand Up @@ -110,7 +110,7 @@ class StreamFieldListData(SourceData):

- either by providing iteration through the stream of fields once, which is more
efficient for larger datasets and allows for processing data in chunks without consuming
large amounts of memory. This is the default behavior when calling :py:func:`to_fieldlist`
large amounts of memory. This is the default behaviour when calling :py:func:`to_fieldlist`
without any arguments, or with ``read_all=False``.
- or by reading all fields into memory, which may be suitable for smaller datasets or
when random access is needed. This can be achieved by calling :py:func:`to_fieldlist`
Expand Down
4 changes: 2 additions & 2 deletions src/earthkit/data/readers/xarray/grid.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ def latlons(self) -> Tuple[Any, Any]:
)

else:
raise NotImplementedError(f"MeshedGrid.grid_points: unrecognized variable_dims {self.variable_dims}")
raise NotImplementedError(f"MeshedGrid.grid_points: unrecognised variable_dims {self.variable_dims}")

return lat.flatten(), lon.flatten()

Expand Down Expand Up @@ -236,7 +236,7 @@ def xys(self) -> Tuple[Any, Any]:
)

else:
raise NotImplementedError(f"MeshedGrid.grid_points: unrecognized variable_dims {self.variable_dims}")
raise NotImplementedError(f"MeshedGrid.grid_points: unrecognised variable_dims {self.variable_dims}")

return x.flatten(), y.flatten()

Expand Down
4 changes: 2 additions & 2 deletions src/earthkit/data/readers/xarray/patch.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ def patch_analysis_lead_to_valid_time(
"""Convert analysis time and lead time coordinates to valid time.

This function creates a new valid time coordinate by adding the analysis time
and lead time coordinates, then stacks and reorganizes the dataset to use
and lead time coordinates, then stacks and reorganises the dataset to use
valid time as the primary time dimension.

Parameters
Expand All @@ -148,7 +148,7 @@ def patch_analysis_lead_to_valid_time(
Dictionary mapping required keys to coordinate names in the dataset:

- 'analysis_time_coordinate' : str
Name of the analysis/initialization time coordinate.
Name of the analysis/initialisation time coordinate.
- 'lead_time_coordinate' : str
Name of the forecast lead time coordinate.
- 'valid_time_coordinate' : str
Expand Down
6 changes: 3 additions & 3 deletions src/earthkit/data/sources/gribjump.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,8 @@ def from_mars_requests(
mask = None

if indices is not None:
# We do the same small optimization for indices. Optimally, we
# would do similar optimizations in pygribjump and remove this.
# We do the same small optimisation for indices. Optimally, we
# would do similar optimisations in pygribjump and remove this.
ranges = [(i, i + 1) for i in indices]
indices = None

Expand All @@ -251,7 +251,7 @@ class FieldExtractList(SimpleFieldListBase):

.. warning::
This implementation is **not thread-safe**. Concurrent access from multiple threads
may result in race conditions during lazy loading. Use appropriate synchronization
may result in race conditions during lazy loading. Use appropriate synchronisation
if accessing from multiple threads.

.. note::
Expand Down
2 changes: 1 addition & 1 deletion src/earthkit/data/utils/patterns.py
Original file line number Diff line number Diff line change
Expand Up @@ -716,7 +716,7 @@ def __init__(self, pattern: str, values: Optional[Dict[str, TypingAny]] = None)

pattern = pattern._subpattern(self.fixed_single_params)

# analyze path structure and turn each file path part into a
# analyse path structure and turn each file path part into a
# pattern
path = Path(pattern)
self.root = ""
Expand Down
Loading