Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/ecmwf/anemoi-datasets in…
Browse files Browse the repository at this point in the history
…to develop
  • Loading branch information
floriankrb committed Apr 25, 2024
2 parents 8c51582 + ed6184a commit 8d7f328
Show file tree
Hide file tree
Showing 6 changed files with 73 additions and 40 deletions.
34 changes: 17 additions & 17 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,23 +51,23 @@ repos:
- --exit-non-zero-on-fix
- --preview

- repo: https://github.com/thclark/pre-commit-sphinx
rev: 0.0.1
hooks:
- id: build-docs
additional_dependencies:
- sphinx
- sphinx_rtd_theme
- nbsphinx
- pandoc
args:
- --cache-dir
- docs/_build/doctrees
- --html-dir
- docs/_build/html
- --source-dir
- docs
language_version: python3
# - repo: https://github.com/thclark/pre-commit-sphinx
# rev: 0.0.1
# hooks:
# - id: build-docs
# additional_dependencies:
# - sphinx
# - sphinx_rtd_theme
# - nbsphinx
# - pandoc
# args:
# - --cache-dir
# - docs/_build/doctrees
# - --html-dir
# - docs/_build/html
# - --source-dir
# - docs
# language_version: python3

- repo: https://github.com/sphinx-contrib/sphinx-lint
rev: v0.9.1
Expand Down
3 changes: 0 additions & 3 deletions anemoi/datasets/create/functions/actions/accumulations.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,9 +264,6 @@ def compute_accumulations(
if not isinstance(param, (list, tuple)):
param = [param]

for p in param:
assert p in ["cp", "lsp", "tp", "sf", "lsf", "csf"], p

number = request.get("number", [0])
assert isinstance(number, (list, tuple))

Expand Down
4 changes: 3 additions & 1 deletion docs/building/sources/perturbations.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,14 @@ positive when using the `perturbations` function :

It uses the following arguments:

ensembles
members
A :ref:`reference <yaml-reference>` to the ensemble members.

center
A :ref:`reference <yaml-reference>` to the new center requested.

Examples

.. literalinclude:: yaml/perturbations.yaml
:language: yaml

Expand Down
40 changes: 21 additions & 19 deletions docs/building/sources/yaml/perturbations.yaml
Original file line number Diff line number Diff line change
@@ -1,24 +1,26 @@
data_sources:
members:
class: ea
expver: "0001"
grid: 20.0/20.0
levtype: sfc
param: [10u, 10v, 2t]
type: an
stream: enda
number: [1, 2, 3, 4, 5, 6, 7, 8, 9]
members_source:
mars:
class: ea
expver: "0001"
grid: 20.0/20.0
levtype: sfc
param: [10u, 10v, 2t]
type: an
stream: enda
number: [1, 2, 3, 4, 5, 6, 7, 8, 9]

center:
class: ea
expver: "0001"
grid: 20.0/20.0
levtype: sfc
param: [10u, 10v, 2t]
type: an
stream: oper
center_source:
mars:
class: ea
expver: "0001"
grid: 20.0/20.0
levtype: sfc
param: [10u, 10v, 2t]
type: an
stream: oper

input:
perturbations:
center: ${data_sources.center}
members: ${data_sources.members}
center: ${data_sources.center_source}
members: ${data_sources.members_source}
20 changes: 20 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,26 @@

intersphinx_mapping = {
"python": ("https://python.readthedocs.io/en/latest", None),
"anemoi-utils": (
"https://anemoi-utils.readthedocs.io/en/latest/",
("../../anemoi-utils/docs/_build/html/objects.inv", None),
),
"anemoi-datasets": (
"https://anemoi-datasets.readthedocs.io/en/latest/",
("../../anemoi-datasets/docs/_build/html/objects.inv", None),
),
"anemoi-models": (
"https://anemoi-models.readthedocs.io/en/latest/",
("../../anemoi-models/docs/_build/html/objects.inv", None),
),
"anemoi-training": (
"https://anemoi-training.readthedocs.io/en/latest/",
("../../anemoi-training/docs/_build/html/objects.inv", None),
),
"anemoi-inference": (
"https://anemoi-inference.readthedocs.io/en/latest/",
("../../anemoi-inference/docs/_build/html/objects.inv", None),
),
}


Expand Down
12 changes: 12 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
.. _index-page:

####################################
Welcome to Anemoi's documentation!
####################################
Expand Down Expand Up @@ -107,6 +109,16 @@ datasets <building-introduction>`.
cli/compare
cli/copy

*****************
Anemoi packages
*****************

- :ref:`anemoi-utils <anemoi-utils:index-page>`
- :ref:`anemoi-datasets <anemoi-datasets:index-page>`
- :ref:`anemoi-models <anemoi-models:index-page>`
- :ref:`anemoi-training <anemoi-training:index-page>`
- :ref:`anemoi-inference <anemoi-inference:index-page>`

*********
License
*********
Expand Down

0 comments on commit 8d7f328

Please sign in to comment.