forked from ecmwf/anemoi-training
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Graph config for stretched grid graph (ecmwf#133)
* Added stretched grid graph config * Fix data nodebuilder * Fix typo * Running pre-commit hooks * Updated changelog
- Loading branch information
1 parent
58dad76
commit 7cb7680
Showing
2 changed files
with
64 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
# Stretched grid graph config intended to be used with a cutout dataset. | ||
# The stretched mesh resolution used here is intended for o96 global resolution with 10km | ||
# limited area resolution. | ||
overwrite: False | ||
|
||
data: "data" | ||
hidden: "hidden" | ||
|
||
nodes: | ||
data: | ||
node_builder: | ||
_target_: anemoi.graphs.nodes.ZarrDatasetNodes | ||
dataset: ${dataloader.dataset} | ||
attributes: | ||
area_weight: | ||
_target_: anemoi.graphs.nodes.attributes.AreaWeights | ||
norm: unit-max | ||
cutout: | ||
_target_: anemoi.graphs.nodes.attributes.CutOutMask | ||
hidden: | ||
node_builder: | ||
_target_: anemoi.graphs.nodes.StretchedTriNodes | ||
lam_resolution: 8 | ||
global_resolution: 5 | ||
reference_node_name: ${graph.data} | ||
mask_attr_name: cutout | ||
margin_radius_km: 11 | ||
attributes: | ||
area_weights: | ||
_target_: anemoi.graphs.nodes.attributes.AreaWeights | ||
norm: unit-max | ||
|
||
edges: | ||
# Encoder | ||
- source_name: ${graph.data} | ||
target_name: ${graph.hidden} | ||
edge_builder: | ||
_target_: anemoi.graphs.edges.KNNEdges | ||
num_nearest_neighbours: 12 | ||
attributes: ${graph.attributes.edges} | ||
# Processor | ||
- source_name: ${graph.hidden} | ||
target_name: ${graph.hidden} | ||
edge_builder: | ||
_target_: anemoi.graphs.edges.MultiScaleEdges | ||
x_hops: 1 | ||
attributes: ${graph.attributes.edges} | ||
# Decoder | ||
- source_name: ${graph.hidden} | ||
target_name: ${graph.data} | ||
edge_builder: | ||
_target_: anemoi.graphs.edges.KNNEdges | ||
num_nearest_neighbours: 3 | ||
attributes: ${graph.attributes.edges} | ||
|
||
attributes: | ||
edges: | ||
edge_length: | ||
_target_: anemoi.graphs.edges.attributes.EdgeLength | ||
norm: unit-max | ||
edge_dirs: | ||
_target_: anemoi.graphs.edges.attributes.EdgeDirection | ||
norm: unit-std |