earth2mip
A python framework that enables climate researchers and scientists to explore and experiment with AI models for weather and climate.
https://github.com/NVIDIA/earth2mip
Category: Climate Change
Sub Category: Earth and Climate Modeling
Keywords
climate deep-learning weather
Keywords from Contributors
transformer climate-modeling
Last synced: about 20 hours ago
JSON representation
Repository metadata
Earth-2 Model Intercomparison Project (MIP) is a python framework that enables climate researchers and scientists to inter-compare AI models for weather and climate.
- Host: GitHub
- URL: https://github.com/NVIDIA/earth2mip
- Owner: NVIDIA
- License: apache-2.0
- Created: 2023-08-25T20:22:59.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-06T05:49:20.000Z (5 months ago)
- Last Synced: 2025-04-21T04:04:14.760Z (6 days ago)
- Topics: climate, deep-learning, weather
- Language: Python
- Homepage: https://nvidia.github.io/earth2mip/
- Size: 16.4 MB
- Stars: 225
- Watchers: 4
- Forks: 50
- Open Issues: 27
- Releases: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE.txt
README.md
Earth-2 MIP (Beta)
Earth-2 Model Intercomparison Project (MIP) is a Python based AI framework that
enables climate researchers and scientists to explore and experiment with the use of AI
models for weather and climate.
It provides reference workflows for understanding how AI models capture the physics of
the Earth's atmosphere and how they can work with traditional numerical weather
forecasting models.
For instance, the repo provides a uniform interface for running inference using
pre-trained model checkpoints and scoring the skill of such models using certain
standard metrics.
This repository is meant to facilitate the weather and climate community to come up with
good reference baseline of events to test the models against and to use with a variety
of data sources.
Installation
Earth-2 MIP will be installable on PyPi upon general release.
In the mean time, one can install from source:
git clone [email protected]:NVIDIA/earth2mip.git
cd earth2mip && pip install .
See installation documentation
for more details and other options.
Getting Started
Earth-2 MIP provides a set of examples which can be viewed on the examples documentation
page which can be used to get started with various workflows.
These examples can be downloaded both as Jupyer Notebooks and Python scripts.
The source Python scripts can be found in the examples folders.
Basic Inference
Earth-2 MIP provides high-level APIs for running inference with AI models.
For example, the following can be used to run Pangu weather using an initial state from
the climate data store (CDS):
python
>>> import datetime
>>> from earth2mip.networks import get_model
>>> from earth2mip.initial_conditions import cds
>>> from earth2mip.inference_ensemble import run_basic_inference
>>> time_loop = get_model("e2mip://dlwp", device="cuda:0")
>>> data_source = cds.DataSource(time_loop.in_channel_names)
>>> ds = run_basic_inference(time_loop, n=10, data_source=data_source, time=datetime.datetime(2018, 1, 1))
>>> ds.chunk()
<xarray.DataArray (time: 11, history: 1, channel: 69, lat: 721, lon: 1440)>
dask.array<xarray-<this-array>, shape=(11, 1, 69, 721, 1440), dtype=float32, chunksize=(11, 1, 69, 721, 1440), chunktype=numpy.ndarray>
Coordinates:
* lon (lon) float32 0.0 0.25 0.5 0.75 1.0 ... 359.0 359.2 359.5 359.8
* lat (lat) float32 90.0 89.75 89.5 89.25 ... -89.25 -89.5 -89.75 -90.0
* time (time) datetime64[ns] 2018-01-01 ... 2018-01-03T12:00:00
* channel (channel) <U5 'z1000' 'z925' 'z850' 'z700' ... 'u10m' 'v10m' 't2m'
Dimensions without coordinates: history
And you can get ACC/RMSE like this:
>>> from earth2mip.inference_medium_range import score_deterministic
>>> import numpy as np
>>> scores = score_deterministic(time_loop,
data_source=data_source,
n=10,
initial_times=[datetime.datetime(2018, 1, 1)],
# fill in zeros for time-mean, will typically be grabbed from data.
time_mean=np.zeros((7, 721, 1440))
)
>>> scores
<xarray.Dataset>
Dimensions: (lead_time: 11, channel: 7, initial_time: 1)
Coordinates:
* lead_time (lead_time) timedelta64[ns] 0 days 00:00:00 ... 5 days 00:...
* channel (channel) <U5 't850' 'z1000' 'z700' ... 'z300' 'tcwv' 't2m'
Dimensions without coordinates: initial_time
Data variables:
acc (lead_time, channel) float64 1.0 1.0 1.0 ... 0.9686 0.9999
rmse (lead_time, channel) float64 0.0 2.469e-05 0.0 ... 7.07 2.998
initial_times (initial_time) datetime64[ns] 2018-01-01
>>> scores.rmse.sel(channel='z500')
<xarray.DataArray 'rmse' (lead_time: 11)>
array([ 0. , 150.83014446, 212.07880612, 304.98592282,
381.36510987, 453.31516952, 506.01464974, 537.11092269,
564.79603347, 557.22871627, 586.44691243])
Coordinates:
* lead_time (lead_time) timedelta64[ns] 0 days 00:00:00 ... 5 days 00:00:00
channel <U5 'z500'
Supported Models
These notebooks illustrate how-to-use with a few models and this can serve as reference
to bring in your own checkpoint as long as it's compatible. There may be additional work
to make it compatible with Earth-2 MIP.
Earth-2 MIP leverages the model zoo in Modulus to
provide a reference set of base-line models.
The goal is to enable to community to grow this collection of models as shown in the
table below.
ID | Model | Architecture | Type | Reference | Source | Size |
---|---|---|---|---|---|---|
fcn | FourCastNet | Adaptive Fourier Neural Operator | global weather | Arxiv | modulus | 300Mb |
dlwp | Deep Learning Weather Prediction | Convolutional Encoder-Decoder | global weather | AGU | modulus | 50Mb |
pangu | Pangu Weather (Hierarchical 6 + 24 hr) | Vision Transformer | global weather | Nature | onnx | 2Gb |
pangu_6 | Pangu Weather 6hr Model | Vision Transformer | global weather | Nature | onnx | 1Gb |
pangu_24 | Pangu Weather 24hr Model | Vision Transformer | global weather | Nature | onnx | 1Gb |
fcnv2_sm | FourCastNet v2 | Spherical Harmonics Fourier Neural Operator | global weather | Arxiv | modulus | 3.5Gb |
graphcast | Graphcast, 37 levels, 0.25 deg | Graph neural network | global weather | Science | github | 145MB |
graphcast_small | Graphcast, 13 levels, 1 deg | Graph neural network | global weather | Science | github | 144MB |
graphcast_operational | Graphcast, 13 levels, 0.25 deg | Graph neural network | global weather | Science | github | 144MB |
precipitation_afno | FourCastNet Precipitation | Adaptive Fourier Neural Operator | diagnostic | Arxiv | modulus | 300Mb |
climatenet | ClimateNet Segmentation Model | Convolutional Neural Network | diagnostic | GMD | modulus | 2Mb |
* = coming soon
Some models require additional dependencies not installed by default.
Refer to the installation instructions
for details.
Note : Each model checkpoint may have its own unique license. We encourage users to
familiarize themselves with each to understand implications for their particular use
case.
We want to integrate your model into the scoreboard to show the community!
The best way to do this is via NVIDIA Modulus.
You can contribute your model (both the training code as well as model checkpoint) and
we can ensure that it is maintained as part of the reference set.
Contributing
Earth-2 MIP is an open source collaboration and its success is rooted in community
contribution to further the field.
Thank you for contributing to the project so others can build on your contribution.
For guidance on making a contribution to Earth-2 MIP, please refer to the
contributing guidelines.
More About Earth-2 MIP
This work is inspired to facilitate similar engagements between teams here at
NVIDIA - the ML experts developing new models and the domain experts in Climate science
evaluating the skill of such models.
For instance, often necessary input data such as normalization constants and
hyperparameter values are not packaged alongside the model weights.
Every model typically implements a slightly different interface. Scoring routines are
specific to the model being scored and may not be consistent across groups.
Earth-2 MIP addresses these challenges and bridges the gap between the domain experts
who most often are assessing ML models, and the ML experts producing them.
Compared to other projects in this space, Earth-2 MIP focuses on scoring models
on-the-fly.
It has python APIs suitable for rapid iteration in a jupyter book, CLIs for scoring
models distributed over many GPUs, and a flexible
plugin framework that allows anyone to use their own ML models.
More importantly Earth-2 MIP aspires to facilitate exploration and collaboration within
the climate research community to evaluate the potential of AI models in climate and
weather simulations.
Please see the documentation page for in depth
information about Earth-2 MIP, functionality, APIs, etc.
Communication
- Github Discussions: Discuss new ideas, model integration, support etc.
- GitHub Issues: Bug reports, feature requests, install issues, etc.
License
Earth-2 MIP is provided under the Apache License 2.0, please see
LICENSE.txt for full license text.
Additional Resources
Owner metadata
- Name: NVIDIA Corporation
- Login: NVIDIA
- Email:
- Kind: organization
- Description:
- Website: https://nvidia.com
- Location: 2788 San Tomas Expressway, Santa Clara, CA, 95051
- Twitter:
- Company:
- Icon url: https://avatars.githubusercontent.com/u/1728152?v=4
- Repositories: 342
- Last ynced at: 2025-03-21T18:01:39.515Z
- Profile URL: https://github.com/NVIDIA
GitHub Events
Total
- Issues event: 7
- Watch event: 31
- Issue comment event: 6
- Push event: 3
- Pull request review event: 4
- Pull request review comment event: 5
- Pull request event: 4
- Fork event: 6
Last Year
- Issues event: 7
- Watch event: 31
- Issue comment event: 6
- Push event: 3
- Pull request review event: 4
- Pull request review comment event: 5
- Pull request event: 4
- Fork event: 6
Committers metadata
Last synced: 5 days ago
Total Commits: 225
Total Committers: 8
Avg Commits per committer: 28.125
Development Distribution Score (DDS): 0.516
Commits in past year: 39
Committers in past year: 7
Avg Commits per committer in past year: 5.571
Development Distribution Score (DDS) in past year: 0.385
Name | Commits | |
---|---|---|
Noah D. Brenowitz | n****2@g****m | 109 |
Nicholas Geneva | 5****a | 72 |
Yair Cohen | y****n@n****m | 35 |
Chenggong Wang | c****0@g****m | 3 |
ankurmahesh | a****h | 3 |
omahs | 7****s | 1 |
Alejandro Betancur Quiroz | 5****2 | 1 |
sashaphmn | s****n@g****m | 1 |
Committer domains:
- nvidia.com: 1
Issue and Pull Request metadata
Last synced: 2 days ago
Total issues: 117
Total pull requests: 95
Average time to close issues: 20 days
Average time to close pull requests: 4 days
Total issue authors: 21
Total pull request authors: 13
Average comments per issue: 0.89
Average comments per pull request: 2.97
Merged pull request: 80
Bot issues: 0
Bot pull requests: 0
Past year issues: 15
Past year pull requests: 4
Past year average time to close issues: 29 days
Past year average time to close pull requests: about 1 month
Past year issue authors: 9
Past year pull request authors: 4
Past year average comments per issue: 1.87
Past year average comments per pull request: 0.75
Past year merged pull request: 1
Past year bot issues: 0
Past year bot pull requests: 0
Top Issue Authors
- NickGeneva (56)
- nbren12 (26)
- yairchn (5)
- david5010 (5)
- ankurmahesh (3)
- ChenggongWang (3)
- manmeet3591 (3)
- dallasfoster (2)
- adamjstewart (2)
- ktangsali (1)
- MarsuPila (1)
- albetancurqu42 (1)
- ThomasMGeo (1)
- Joshua-Elms (1)
- YichengDWu (1)
Top Pull Request Authors
- NickGeneva (48)
- nbren12 (17)
- yairchn (14)
- ChenggongWang (4)
- ankurmahesh (4)
- albetancurqu42 (1)
- ktangsali (1)
- sashaphmn (1)
- georg198 (1)
- timkpaine (1)
- dallasfoster (1)
- pgarg7 (1)
- omahs (1)
Top Issue Labels
- bug (49)
- enhancement (34)
- ? - Needs Triage (30)
- documentation (21)
- 2 - In Progress (20)
- 1 - On Deck (16)
- 0 - Backlog (16)
- 4 - In Review (2)
- 3 - Ready for Review (2)
- external (2)
- question (2)
- ci (1)
Top Pull Request Labels
- 4 - In Review (7)
- 3 - Ready for Review (6)
- 2 - In Progress (6)
- bug (5)
- documentation (5)
- enhancement (3)
- 5 - DO NOT MERGE (2)
- cleanup (2)
- external (1)
- ! - Release (1)
Package metadata
- Total packages: 2
- Total downloads: unknown
- Total dependent packages: 0 (may contain duplicates)
- Total dependent repositories: 0 (may contain duplicates)
- Total versions: 1
- Total maintainers: 1
proxy.golang.org: github.com/nvidia/earth2mip
- Homepage:
- Documentation: https://pkg.go.dev/github.com/nvidia/earth2mip#section-documentation
- Licenses: apache-2.0
- Latest release: v0.1.0 (published over 1 year ago)
- Last Synced: 2025-04-25T05:31:16.626Z (2 days ago)
- Versions: 1
- Dependent Packages: 0
- Dependent Repositories: 0
-
Rankings:
- Dependent packages count: 6.518%
- Average: 6.736%
- Dependent repos count: 6.955%
spack.io: py-earth2mip
Earth-2 Model Intercomparison Project (MIP). A python framework that enables climate researchers and scientists to explore and experiment with AI models for weather and climate.
- Homepage: https://github.com/NVIDIA/earth2mip
- Licenses: []
- Latest release: (published 6 months ago)
- Last Synced: 2024-10-29T08:32:02.817Z (6 months ago)
- Versions: 0
- Dependent Packages: 0
- Dependent Repositories: 0
-
Rankings:
- Dependent repos count: 0.0%
- Average: 27.807%
- Dependent packages count: 55.613%
- Maintainers (1)
Dependencies
- NVIDIA/blossom-action main composite
- actions/checkout v2 composite
Score: 7.608870629191259