diff --git a/CHANGELOG.md b/CHANGELOG.md index 47c9c3c7..bc9d40f0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,7 @@ Keep it human-readable, your future self will thank you! - Sub-hour datasets [#63](https://github.com/ecmwf/anemoi-training/pull/63) - Add synchronisation workflow [#92](https://github.com/ecmwf/anemoi-training/pull/92) - Feat: Anemoi Profiler compatible with mlflow and using Pytorch (Kineto) Profiler for memory report [38](https://github.com/ecmwf/anemoi-training/pull/38/) +- New limited area config file added, limited_area.yaml. [#134](https://github.com/ecmwf/anemoi-training/pull/134/) - New stretched grid config added, stretched_grid.yaml [#133](https://github.com/ecmwf/anemoi-training/pull/133) ### Changed diff --git a/pyproject.toml b/pyproject.toml index 5f31c245..f3e730d3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ dynamic = [ "version" ] dependencies = [ "anemoi-datasets>=0.4", - "anemoi-graphs", + "anemoi-graphs>=0.4", "anemoi-models>=0.3", "anemoi-utils[provenance]>=0.4.4", "einops>=0.6.1", diff --git a/src/anemoi/training/config/graph/limited_area.yaml b/src/anemoi/training/config/graph/limited_area.yaml new file mode 100644 index 00000000..f17bc384 --- /dev/null +++ b/src/anemoi/training/config/graph/limited_area.yaml @@ -0,0 +1,60 @@ +--- +overwrite: True + +data: "data" +hidden: "hidden" + +nodes: + # Data nodes + data: + node_builder: + _target_: anemoi.graphs.nodes.ZarrDatasetNodes + dataset: ${dataloader.training.dataset} + attributes: ${graph.attributes.nodes} + # Hidden nodes + hidden: + node_builder: + _target_: anemoi.graphs.nodes.LimitedAreaTriNodes # options: ZarrDatasetNodes, NPZFileNodes, TriNodes + resolution: 5 # grid resolution for npz (o32, o48, ...) + reference_node_name: ${graph.data} + mask_attr_name: cutout + +edges: +# Encoder configuration +- source_name: ${graph.data} + target_name: ${graph.hidden} + edge_builder: + _target_: anemoi.graphs.edges.CutOffEdges # options: KNNEdges, CutOffEdges + cutoff_factor: 0.6 # only for cutoff method + attributes: ${graph.attributes.edges} +# Processor configuration +- source_name: ${graph.hidden} + target_name: ${graph.hidden} + edge_builder: + _target_: anemoi.graphs.edges.MultiScaleEdges + x_hops: 1 + attributes: ${graph.attributes.edges} +# Decoder configuration +- source_name: ${graph.hidden} + target_name: ${graph.data} + target_mask_attr_name: cutout + edge_builder: + _target_: anemoi.graphs.edges.KNNEdges # options: KNNEdges, CutOffEdges + num_nearest_neighbours: 3 # only for knn method + attributes: ${graph.attributes.edges} + + +attributes: + nodes: + area_weight: + _target_: anemoi.graphs.nodes.attributes.AreaWeights # options: Area, Uniform + norm: unit-max # options: l1, l2, unit-max, unit-sum, unit-std + cutout: + _target_: anemoi.graphs.nodes.attributes.CutOutMask + edges: + edge_length: + _target_: anemoi.graphs.edges.attributes.EdgeLength + norm: unit-std + edge_dirs: + _target_: anemoi.graphs.edges.attributes.EdgeDirection + norm: unit-std diff --git a/src/anemoi/training/config/graph/stretched_grid.yaml b/src/anemoi/training/config/graph/stretched_grid.yaml index be8d58ed..dad0172d 100644 --- a/src/anemoi/training/config/graph/stretched_grid.yaml +++ b/src/anemoi/training/config/graph/stretched_grid.yaml @@ -10,7 +10,7 @@ nodes: data: node_builder: _target_: anemoi.graphs.nodes.ZarrDatasetNodes - dataset: ${dataloader.dataset} + dataset: ${dataloader.training.dataset} attributes: area_weight: _target_: anemoi.graphs.nodes.attributes.AreaWeights