anemoi-training 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- anemoi_training-0.1.0/.github/ci-config.yml +9 -0
- anemoi_training-0.1.0/.github/workflows/changelog-pr-update.yml +15 -0
- anemoi_training-0.1.0/.github/workflows/changelog-release-update.yml +35 -0
- anemoi_training-0.1.0/.github/workflows/ci.yml +52 -0
- anemoi_training-0.1.0/.github/workflows/label-public-pr.yml +10 -0
- anemoi_training-0.1.0/.github/workflows/python-publish.yml +23 -0
- anemoi_training-0.1.0/.github/workflows/python-pull-request.yml +19 -0
- anemoi_training-0.1.0/.github/workflows/readtthedocs-pr-update.yml +22 -0
- anemoi_training-0.1.0/.gitignore +188 -0
- anemoi_training-0.1.0/.pre-commit-config.yaml +89 -0
- anemoi_training-0.1.0/.readthedocs.yaml +17 -0
- anemoi_training-0.1.0/CHANGELOG.md +86 -0
- anemoi_training-0.1.0/LICENSE +201 -0
- anemoi_training-0.1.0/PKG-INFO +257 -0
- anemoi_training-0.1.0/README.md +42 -0
- anemoi_training-0.1.0/docs/Makefile +22 -0
- anemoi_training-0.1.0/docs/_static/logo.png +0 -0
- anemoi_training-0.1.0/docs/_static/style.css +48 -0
- anemoi_training-0.1.0/docs/_templates/.gitkeep +0 -0
- anemoi_training-0.1.0/docs/conf.py +121 -0
- anemoi_training-0.1.0/docs/dev/code-structure.rst +77 -0
- anemoi_training-0.1.0/docs/dev/contributing.rst +149 -0
- anemoi_training-0.1.0/docs/dev/hydra.rst +146 -0
- anemoi_training-0.1.0/docs/dev/testing.rst +190 -0
- anemoi_training-0.1.0/docs/images/global-sliding-window-attention.png +0 -0
- anemoi_training-0.1.0/docs/images/gnn-encoder-decoder-multimesh.jpg +0 -0
- anemoi_training-0.1.0/docs/images/mlflow/mlflow_compare.png +0 -0
- anemoi_training-0.1.0/docs/images/mlflow/mlflow_constant.png +0 -0
- anemoi_training-0.1.0/docs/images/mlflow/mlflow_resumed_run.png +0 -0
- anemoi_training-0.1.0/docs/images/mlflow/mlflow_run.png +0 -0
- anemoi_training-0.1.0/docs/images/mlflow/mlflow_server.png +0 -0
- anemoi_training-0.1.0/docs/images/model_sharding.png +0 -0
- anemoi_training-0.1.0/docs/images/transformer-block.png +0 -0
- anemoi_training-0.1.0/docs/index.rst +83 -0
- anemoi_training-0.1.0/docs/installing.rst +26 -0
- anemoi_training-0.1.0/docs/modules/data.rst +22 -0
- anemoi_training-0.1.0/docs/modules/diagnostics.rst +43 -0
- anemoi_training-0.1.0/docs/modules/losses.rst +24 -0
- anemoi_training-0.1.0/docs/modules/strategy.rst +16 -0
- anemoi_training-0.1.0/docs/modules/train.rst +27 -0
- anemoi_training-0.1.0/docs/overview.rst +159 -0
- anemoi_training-0.1.0/docs/requirements.txt +10 -0
- anemoi_training-0.1.0/docs/start/hydra-intro.rst +86 -0
- anemoi_training-0.1.0/docs/start/installing.rst +9 -0
- anemoi_training-0.1.0/docs/start/training-your-first-model.rst +75 -0
- anemoi_training-0.1.0/docs/user-guide/configuring.rst +132 -0
- anemoi_training-0.1.0/docs/user-guide/debugging.rst +249 -0
- anemoi_training-0.1.0/docs/user-guide/distributed.rst +56 -0
- anemoi_training-0.1.0/docs/user-guide/introduction.rst +50 -0
- anemoi_training-0.1.0/docs/user-guide/models.rst +83 -0
- anemoi_training-0.1.0/docs/user-guide/tracking.rst +148 -0
- anemoi_training-0.1.0/docs/user-guide/training.rst +255 -0
- anemoi_training-0.1.0/pyproject.toml +174 -0
- anemoi_training-0.1.0/pytest.ini +7 -0
- anemoi_training-0.1.0/setup.cfg +4 -0
- anemoi_training-0.1.0/src/anemoi/training/__init__.py +9 -0
- anemoi_training-0.1.0/src/anemoi/training/__main__.py +27 -0
- anemoi_training-0.1.0/src/anemoi/training/_version.py +16 -0
- anemoi_training-0.1.0/src/anemoi/training/commands/__init__.py +23 -0
- anemoi_training-0.1.0/src/anemoi/training/commands/checkpoint.py +47 -0
- anemoi_training-0.1.0/src/anemoi/training/commands/config.py +98 -0
- anemoi_training-0.1.0/src/anemoi/training/commands/mlflow.py +106 -0
- anemoi_training-0.1.0/src/anemoi/training/commands/train.py +47 -0
- anemoi_training-0.1.0/src/anemoi/training/config/__init__.py +6 -0
- anemoi_training-0.1.0/src/anemoi/training/config/config.yaml +9 -0
- anemoi_training-0.1.0/src/anemoi/training/config/data/zarr.yaml +64 -0
- anemoi_training-0.1.0/src/anemoi/training/config/dataloader/native_grid.yaml +58 -0
- anemoi_training-0.1.0/src/anemoi/training/config/debug.yaml +32 -0
- anemoi_training-0.1.0/src/anemoi/training/config/diagnostics/eval_rollout.yaml +95 -0
- anemoi_training-0.1.0/src/anemoi/training/config/graph/encoder_decoder_only.yaml +49 -0
- anemoi_training-0.1.0/src/anemoi/training/config/graph/multi_scale.yaml +56 -0
- anemoi_training-0.1.0/src/anemoi/training/config/hardware/example.yaml +10 -0
- anemoi_training-0.1.0/src/anemoi/training/config/hardware/files/example.yaml +7 -0
- anemoi_training-0.1.0/src/anemoi/training/config/hardware/paths/example.yaml +12 -0
- anemoi_training-0.1.0/src/anemoi/training/config/hardware/slurm.yaml +10 -0
- anemoi_training-0.1.0/src/anemoi/training/config/model/gnn.yaml +45 -0
- anemoi_training-0.1.0/src/anemoi/training/config/model/graphtransformer.yaml +50 -0
- anemoi_training-0.1.0/src/anemoi/training/config/model/transformer.yaml +49 -0
- anemoi_training-0.1.0/src/anemoi/training/config/training/default.yaml +85 -0
- anemoi_training-0.1.0/src/anemoi/training/data/__init__.py +6 -0
- anemoi_training-0.1.0/src/anemoi/training/data/datamodule.py +201 -0
- anemoi_training-0.1.0/src/anemoi/training/data/dataset.py +261 -0
- anemoi_training-0.1.0/src/anemoi/training/data/scaling.py +76 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/__init__.py +6 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/callbacks/__init__.py +984 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/continents.json +50 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/logger.py +158 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/maps.py +99 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/mlflow/__init__.py +6 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/mlflow/auth.py +237 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/mlflow/logger.py +487 -0
- anemoi_training-0.1.0/src/anemoi/training/diagnostics/plots.py +566 -0
- anemoi_training-0.1.0/src/anemoi/training/distributed/__init__.py +6 -0
- anemoi_training-0.1.0/src/anemoi/training/distributed/strategy.py +162 -0
- anemoi_training-0.1.0/src/anemoi/training/losses/__init__.py +8 -0
- anemoi_training-0.1.0/src/anemoi/training/losses/mse.py +91 -0
- anemoi_training-0.1.0/src/anemoi/training/losses/utils.py +53 -0
- anemoi_training-0.1.0/src/anemoi/training/train/__init__.py +6 -0
- anemoi_training-0.1.0/src/anemoi/training/train/forecaster.py +345 -0
- anemoi_training-0.1.0/src/anemoi/training/train/train.py +359 -0
- anemoi_training-0.1.0/src/anemoi/training/utils/__init__.py +8 -0
- anemoi_training-0.1.0/src/anemoi/training/utils/checkpoint.py +64 -0
- anemoi_training-0.1.0/src/anemoi/training/utils/jsonify.py +61 -0
- anemoi_training-0.1.0/src/anemoi/training/utils/mlflow_sync.py +273 -0
- anemoi_training-0.1.0/src/anemoi/training/utils/seeding.py +47 -0
- anemoi_training-0.1.0/src/anemoi_training.egg-info/PKG-INFO +257 -0
- anemoi_training-0.1.0/src/anemoi_training.egg-info/SOURCES.txt +117 -0
- anemoi_training-0.1.0/src/anemoi_training.egg-info/dependency_links.txt +1 -0
- anemoi_training-0.1.0/src/anemoi_training.egg-info/entry_points.txt +2 -0
- anemoi_training-0.1.0/src/anemoi_training.egg-info/requires.txt +35 -0
- anemoi_training-0.1.0/src/anemoi_training.egg-info/top_level.txt +2 -0
- anemoi_training-0.1.0/src/hydra_plugins/anemoi_searchpath/__init__.py +8 -0
- anemoi_training-0.1.0/src/hydra_plugins/anemoi_searchpath/anemoi_searchpath_plugin.py +69 -0
- anemoi_training-0.1.0/tests/conftest.py +32 -0
- anemoi_training-0.1.0/tests/diagnostics/mlflow/test_auth.py +155 -0
- anemoi_training-0.1.0/tests/diagnostics/test_checkpoint.py +139 -0
- anemoi_training-0.1.0/tests/hydra/test_search_path_plugins.py +25 -0
- anemoi_training-0.1.0/tests/requirements.txt +1 -0
- anemoi_training-0.1.0/tests/train/test_loss_scaling.py +144 -0
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
name: Check Changelog Update on PR
|
|
2
|
+
on:
|
|
3
|
+
pull_request:
|
|
4
|
+
types: [assigned, opened, synchronize, reopened, labeled, unlabeled]
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
- develop
|
|
8
|
+
jobs:
|
|
9
|
+
Check-Changelog:
|
|
10
|
+
name: Check Changelog Action
|
|
11
|
+
runs-on: ubuntu-20.04
|
|
12
|
+
steps:
|
|
13
|
+
- uses: tarides/changelog-check-action@v2
|
|
14
|
+
with:
|
|
15
|
+
changelog: CHANGELOG.md
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
# .github/workflows/update-changelog.yaml
|
|
3
|
+
name: "Update Changelog"
|
|
4
|
+
|
|
5
|
+
on:
|
|
6
|
+
release:
|
|
7
|
+
types: [released]
|
|
8
|
+
|
|
9
|
+
permissions:
|
|
10
|
+
pull-requests: write
|
|
11
|
+
contents: write
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
update:
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
|
|
17
|
+
steps:
|
|
18
|
+
- name: Checkout code
|
|
19
|
+
uses: actions/checkout@v4
|
|
20
|
+
with:
|
|
21
|
+
ref: ${{ github.event.release.target_commitish }}
|
|
22
|
+
|
|
23
|
+
- name: Update Changelog
|
|
24
|
+
uses: stefanzweifel/changelog-updater-action@v1
|
|
25
|
+
with:
|
|
26
|
+
latest-version: ${{ github.event.release.tag_name }}
|
|
27
|
+
heading-text: ${{ github.event.release.name }}
|
|
28
|
+
|
|
29
|
+
- name: Create Pull Request
|
|
30
|
+
uses: peter-evans/create-pull-request@v6
|
|
31
|
+
with:
|
|
32
|
+
branch: docs/changelog-update-${{ github.event.release.tag_name }}
|
|
33
|
+
title: '[Changelog] Update to ${{ github.event.release.tag_name }}'
|
|
34
|
+
add-paths: |
|
|
35
|
+
CHANGELOG.md
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
name: ci
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
# Trigger the workflow on push to main or develop, except tag creation
|
|
5
|
+
push:
|
|
6
|
+
branches:
|
|
7
|
+
- 'main'
|
|
8
|
+
- 'develop'
|
|
9
|
+
tags-ignore:
|
|
10
|
+
- '**'
|
|
11
|
+
paths-ignore:
|
|
12
|
+
- "docs/**"
|
|
13
|
+
- "CHANGELOG.md"
|
|
14
|
+
- "README.md"
|
|
15
|
+
|
|
16
|
+
# Trigger the workflow on pull request
|
|
17
|
+
pull_request:
|
|
18
|
+
paths-ignore:
|
|
19
|
+
- "docs/**"
|
|
20
|
+
- "CHANGELOG.md"
|
|
21
|
+
- "README.md"
|
|
22
|
+
|
|
23
|
+
# Trigger the workflow manually
|
|
24
|
+
workflow_dispatch: ~
|
|
25
|
+
|
|
26
|
+
# Trigger after public PR approved for CI
|
|
27
|
+
pull_request_target:
|
|
28
|
+
types: [labeled]
|
|
29
|
+
paths-ignore:
|
|
30
|
+
- "docs/**"
|
|
31
|
+
- "CHANGELOG.md"
|
|
32
|
+
- "README.md"
|
|
33
|
+
|
|
34
|
+
jobs:
|
|
35
|
+
# Run CI including downstream packages on self-hosted runners
|
|
36
|
+
downstream-ci:
|
|
37
|
+
name: downstream-ci
|
|
38
|
+
if: ${{ !github.event.pull_request.head.repo.fork && github.event.action != 'labeled' || github.event.label.name == 'approved-for-ci' }}
|
|
39
|
+
uses: ecmwf-actions/downstream-ci/.github/workflows/downstream-ci.yml@main
|
|
40
|
+
with:
|
|
41
|
+
anemoi-training: ecmwf/anemoi-training@${{ github.event.pull_request.head.sha || github.sha }}
|
|
42
|
+
codecov_upload: true
|
|
43
|
+
secrets: inherit
|
|
44
|
+
|
|
45
|
+
# Build downstream packages on HPC
|
|
46
|
+
downstream-ci-hpc:
|
|
47
|
+
name: downstream-ci-hpc
|
|
48
|
+
if: ${{ !github.event.pull_request.head.repo.fork && github.event.action != 'labeled' || github.event.label.name == 'approved-for-ci' }}
|
|
49
|
+
uses: ecmwf-actions/downstream-ci/.github/workflows/downstream-ci.yml@main
|
|
50
|
+
with:
|
|
51
|
+
anemoi-training: ecmwf/anemoi-training@${{ github.event.pull_request.head.sha || github.sha }}
|
|
52
|
+
secrets: inherit
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
---
|
|
2
|
+
# This workflow will upload a Python Package using Twine when a release is created
|
|
3
|
+
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
|
|
4
|
+
|
|
5
|
+
name: Upload Python Package
|
|
6
|
+
|
|
7
|
+
on:
|
|
8
|
+
release:
|
|
9
|
+
types: [created]
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
quality:
|
|
13
|
+
uses: ecmwf-actions/reusable-workflows/.github/workflows/qa-precommit-run.yml@v2
|
|
14
|
+
with:
|
|
15
|
+
skip-hooks: "no-commit-to-branch"
|
|
16
|
+
|
|
17
|
+
checks:
|
|
18
|
+
uses: ecmwf-actions/reusable-workflows/.github/workflows/qa-pytest-pyproject.yml@v2
|
|
19
|
+
|
|
20
|
+
deploy:
|
|
21
|
+
needs: [checks, quality]
|
|
22
|
+
uses: ecmwf-actions/reusable-workflows/.github/workflows/cd-pypi.yml@v2
|
|
23
|
+
secrets: inherit
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
---
|
|
2
|
+
# This workflow will upload a Python Package using Twine when a release is created
|
|
3
|
+
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
|
|
4
|
+
|
|
5
|
+
name: Code Quality checks for PRs
|
|
6
|
+
|
|
7
|
+
on:
|
|
8
|
+
push:
|
|
9
|
+
pull_request_target:
|
|
10
|
+
types: [opened, synchronize, reopened]
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
quality:
|
|
14
|
+
uses: ecmwf-actions/reusable-workflows/.github/workflows/qa-precommit-run.yml@v2
|
|
15
|
+
with:
|
|
16
|
+
skip-hooks: "no-commit-to-branch"
|
|
17
|
+
|
|
18
|
+
checks:
|
|
19
|
+
uses: ecmwf-actions/reusable-workflows/.github/workflows/qa-pytest-pyproject.yml@v2
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
name: Read the Docs PR Preview
|
|
2
|
+
on:
|
|
3
|
+
pull_request_target:
|
|
4
|
+
types:
|
|
5
|
+
- opened
|
|
6
|
+
- synchronize
|
|
7
|
+
- reopened
|
|
8
|
+
# Execute this action only on PRs that touch
|
|
9
|
+
# documentation files.
|
|
10
|
+
paths:
|
|
11
|
+
- "docs/**"
|
|
12
|
+
|
|
13
|
+
permissions:
|
|
14
|
+
pull-requests: write
|
|
15
|
+
|
|
16
|
+
jobs:
|
|
17
|
+
documentation-links:
|
|
18
|
+
runs-on: ubuntu-latest
|
|
19
|
+
steps:
|
|
20
|
+
- uses: readthedocs/actions/preview@v1
|
|
21
|
+
with:
|
|
22
|
+
project-slug: "anemoi-training"
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py,cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
#Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# poetry
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
102
|
+
#poetry.lock
|
|
103
|
+
|
|
104
|
+
# pdm
|
|
105
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
106
|
+
#pdm.lock
|
|
107
|
+
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
|
108
|
+
# in version control.
|
|
109
|
+
# https://pdm.fming.dev/#use-with-ide
|
|
110
|
+
.pdm.toml
|
|
111
|
+
|
|
112
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
113
|
+
__pypackages__/
|
|
114
|
+
|
|
115
|
+
# Celery stuff
|
|
116
|
+
celerybeat-schedule
|
|
117
|
+
celerybeat.pid
|
|
118
|
+
|
|
119
|
+
# SageMath parsed files
|
|
120
|
+
*.sage.py
|
|
121
|
+
|
|
122
|
+
# Environments
|
|
123
|
+
.env
|
|
124
|
+
.venv
|
|
125
|
+
env/
|
|
126
|
+
venv/
|
|
127
|
+
ENV/
|
|
128
|
+
env.bak/
|
|
129
|
+
venv.bak/
|
|
130
|
+
|
|
131
|
+
# Spyder project settings
|
|
132
|
+
.spyderproject
|
|
133
|
+
.spyproject
|
|
134
|
+
|
|
135
|
+
# Rope project settings
|
|
136
|
+
.ropeproject
|
|
137
|
+
|
|
138
|
+
# mkdocs documentation
|
|
139
|
+
/site
|
|
140
|
+
|
|
141
|
+
# mypy
|
|
142
|
+
.mypy_cache/
|
|
143
|
+
.dmypy.json
|
|
144
|
+
dmypy.json
|
|
145
|
+
|
|
146
|
+
# Pyre type checker
|
|
147
|
+
.pyre/
|
|
148
|
+
|
|
149
|
+
# pytype static type analyzer
|
|
150
|
+
.pytype/
|
|
151
|
+
|
|
152
|
+
# Cython debug symbols
|
|
153
|
+
cython_debug/
|
|
154
|
+
|
|
155
|
+
# PyCharm
|
|
156
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
157
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
158
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
159
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
160
|
+
#.idea/
|
|
161
|
+
|
|
162
|
+
*.grib
|
|
163
|
+
*.onnx
|
|
164
|
+
*.ckpt
|
|
165
|
+
*.swp
|
|
166
|
+
*.npy
|
|
167
|
+
*.download
|
|
168
|
+
?
|
|
169
|
+
?.*
|
|
170
|
+
foo
|
|
171
|
+
bar
|
|
172
|
+
*.grib
|
|
173
|
+
*.nc
|
|
174
|
+
*.npz
|
|
175
|
+
*.json
|
|
176
|
+
*.zarr/
|
|
177
|
+
~$images.pptx
|
|
178
|
+
test.py
|
|
179
|
+
cutout.png
|
|
180
|
+
*.out
|
|
181
|
+
|
|
182
|
+
_build/
|
|
183
|
+
?
|
|
184
|
+
?.*
|
|
185
|
+
~*
|
|
186
|
+
*.sync
|
|
187
|
+
_version.py
|
|
188
|
+
outputs/
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
# Empty notebookds
|
|
3
|
+
- repo: local
|
|
4
|
+
hooks:
|
|
5
|
+
- id: clear-notebooks-output
|
|
6
|
+
name: clear-notebooks-output
|
|
7
|
+
files: tools/.*\.ipynb$
|
|
8
|
+
stages: [commit]
|
|
9
|
+
language: python
|
|
10
|
+
entry: jupyter nbconvert --ClearOutputPreprocessor.enabled=True --inplace
|
|
11
|
+
additional_dependencies: [jupyter]
|
|
12
|
+
- repo: https://github.com/compilerla/conventional-pre-commit
|
|
13
|
+
rev: v3.4.0
|
|
14
|
+
hooks:
|
|
15
|
+
- id: conventional-pre-commit
|
|
16
|
+
stages: [commit-msg]
|
|
17
|
+
args: []
|
|
18
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
19
|
+
rev: v4.6.0
|
|
20
|
+
hooks:
|
|
21
|
+
- id: check-yaml # Check YAML files for syntax errors only
|
|
22
|
+
args: [--unsafe, --allow-multiple-documents]
|
|
23
|
+
- id: debug-statements # Check for debugger imports and py37+ breakpoint()
|
|
24
|
+
- id: end-of-file-fixer # Ensure files end in a newline
|
|
25
|
+
- id: trailing-whitespace # Trailing whitespace checker
|
|
26
|
+
- id: no-commit-to-branch # Prevent committing to main / master
|
|
27
|
+
- id: check-added-large-files # Check for large files added to git
|
|
28
|
+
- id: check-merge-conflict # Check for files that contain merge conflict
|
|
29
|
+
- repo: https://github.com/pre-commit/pygrep-hooks
|
|
30
|
+
rev: v1.10.0 # Use the ref you want to point at
|
|
31
|
+
hooks:
|
|
32
|
+
- id: python-use-type-annotations # Check for missing type annotations
|
|
33
|
+
- id: python-check-blanket-noqa # Check for # noqa: all
|
|
34
|
+
- id: python-no-log-warn # Check for log.warn
|
|
35
|
+
- repo: https://github.com/psf/black-pre-commit-mirror
|
|
36
|
+
rev: 24.8.0
|
|
37
|
+
hooks:
|
|
38
|
+
- id: black
|
|
39
|
+
args: [--line-length=120]
|
|
40
|
+
- repo: https://github.com/pycqa/isort
|
|
41
|
+
rev: 5.13.2
|
|
42
|
+
hooks:
|
|
43
|
+
- id: isort
|
|
44
|
+
args:
|
|
45
|
+
- -l 120
|
|
46
|
+
- --force-single-line-imports
|
|
47
|
+
- --profile black
|
|
48
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
49
|
+
rev: v0.5.6
|
|
50
|
+
hooks:
|
|
51
|
+
- id: ruff
|
|
52
|
+
# Next line if for documenation cod snippets
|
|
53
|
+
exclude: '^[^_].*_\.py$'
|
|
54
|
+
args:
|
|
55
|
+
- --line-length=120
|
|
56
|
+
- --fix
|
|
57
|
+
- --exit-non-zero-on-fix
|
|
58
|
+
- --preview
|
|
59
|
+
- repo: https://github.com/sphinx-contrib/sphinx-lint
|
|
60
|
+
rev: v0.9.1
|
|
61
|
+
hooks:
|
|
62
|
+
- id: sphinx-lint
|
|
63
|
+
# For now, we use it. But it does not support a lot of sphinx features
|
|
64
|
+
- repo: https://github.com/dzhu/rstfmt
|
|
65
|
+
rev: v0.0.14
|
|
66
|
+
hooks:
|
|
67
|
+
- id: rstfmt
|
|
68
|
+
exclude: 'cli/.*' # Because we use argparse
|
|
69
|
+
- repo: https://github.com/b8raoult/pre-commit-docconvert
|
|
70
|
+
rev: "0.1.5"
|
|
71
|
+
hooks:
|
|
72
|
+
- id: docconvert
|
|
73
|
+
args: ["numpy"]
|
|
74
|
+
- repo: https://github.com/tox-dev/pyproject-fmt
|
|
75
|
+
rev: "2.2.1"
|
|
76
|
+
hooks:
|
|
77
|
+
- id: pyproject-fmt
|
|
78
|
+
- repo: https://github.com/jshwi/docsig # Check docstrings against function sig
|
|
79
|
+
rev: v0.60.0
|
|
80
|
+
hooks:
|
|
81
|
+
- id: docsig
|
|
82
|
+
args:
|
|
83
|
+
- --ignore-no-params # Allow docstrings without parameters
|
|
84
|
+
- --check-dunders # Check dunder methods
|
|
85
|
+
- --check-overridden # Check overridden methods
|
|
86
|
+
- --check-protected # Check protected methods
|
|
87
|
+
- --check-class # Check class docstrings
|
|
88
|
+
- --disable=E113 # Disable empty docstrings
|
|
89
|
+
- --summary # Print a summary
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
Please add your functional changes to the appropriate section in the PR.
|
|
9
|
+
Keep it human-readable, your future self will thank you!
|
|
10
|
+
|
|
11
|
+
## [Unreleased]
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
#### Subcommands
|
|
16
|
+
|
|
17
|
+
- Subcommand for training `anemoi-training train`
|
|
18
|
+
- Subcommand for config generation of configs
|
|
19
|
+
- Subcommand for mlflow: login and sync
|
|
20
|
+
- Subcommand for checkpoint handling
|
|
21
|
+
|
|
22
|
+
#### Functionality
|
|
23
|
+
|
|
24
|
+
- Searchpaths for Hydra configs, to enable configs in CWD, `ANEMOI_CONFIG_PATH` env, and `.config/anemoi/training` in addition to package defaults
|
|
25
|
+
- MlFlow token authentication
|
|
26
|
+
- Configurable pressure level scaling
|
|
27
|
+
|
|
28
|
+
#### Continuous Integration / Deployment
|
|
29
|
+
|
|
30
|
+
- Downstream CI to test all dependencies with changes
|
|
31
|
+
- Changelog Status check
|
|
32
|
+
- Readthedocs PR builder
|
|
33
|
+
- Changelog Release Updater Workflow
|
|
34
|
+
|
|
35
|
+
#### Miscellaneous
|
|
36
|
+
|
|
37
|
+
- Extended ruff Ruleset
|
|
38
|
+
- Added Docsig pre-commit hook
|
|
39
|
+
- `__future__` annotations for typehints
|
|
40
|
+
- Added Typehints where missing
|
|
41
|
+
- Added Changelog
|
|
42
|
+
- Correct errors in callback plots
|
|
43
|
+
- fix error in the default config
|
|
44
|
+
- example slurm config
|
|
45
|
+
|
|
46
|
+
### Changed
|
|
47
|
+
|
|
48
|
+
#### Move to Anemoi Ecosystem
|
|
49
|
+
|
|
50
|
+
- Fixed PyPI packaging
|
|
51
|
+
- Use of Anemoi models
|
|
52
|
+
- Use of Anemoi graphs
|
|
53
|
+
- Adjusted tests to work with new Anemoi ecosystem
|
|
54
|
+
- Adjusted configs to reasonable common defaults
|
|
55
|
+
|
|
56
|
+
#### Functionality
|
|
57
|
+
|
|
58
|
+
- Changed hardware-specific keys from configs to `???` to trigger "missing"
|
|
59
|
+
- `__len__` of NativeGridDataset
|
|
60
|
+
- Configurable dropout in attention layer
|
|
61
|
+
|
|
62
|
+
#### Docs
|
|
63
|
+
- First draft on Read the Docs
|
|
64
|
+
- Fixed docstrings
|
|
65
|
+
|
|
66
|
+
#### Miscellaneous
|
|
67
|
+
- Moved callbacks into folder to fascilitate future refactor
|
|
68
|
+
- Adjusted PyPI release infrastructure to common ECMWF workflow
|
|
69
|
+
- Bumped versions in Pre-commit hooks
|
|
70
|
+
- Fix crash when logging hyperparameters with missing values in the config
|
|
71
|
+
- Fixed "null" tracker metadata when tracking is disabled, now returns an empty dict
|
|
72
|
+
- Pinned numpy<2 until we can test all migration
|
|
73
|
+
- (ci): path ignore of docs for downstream ci
|
|
74
|
+
- (ci): remove yaml anchor, unsupported by Github
|
|
75
|
+
- ci: make python QA reusable
|
|
76
|
+
- ci: permissions on changelog updater
|
|
77
|
+
|
|
78
|
+
### Removed
|
|
79
|
+
|
|
80
|
+
- Dependency on mlflow-export-import
|
|
81
|
+
- Specific user configs
|
|
82
|
+
- **len** function of NativeGridDataset as it lead to bugs
|
|
83
|
+
|
|
84
|
+
<!-- Add Git Diffs for Links above -->
|
|
85
|
+
|
|
86
|
+
[unreleased]: https://github.com/ecmwf/anemoi-training/compare/x.x.x...HEAD
|