The listed notebooks highlight JuliaClimate packages used within the broader Julia package ecosystem.
Let's start by plotting important aspects of climate change like global warming and sea level rise. The notebooks use model projections and data stored in various file formats.
climate models (notebook url) : access climate model output from CMIP6 to compute temperature time series and maps.
climate report (notebook url) : reproduce figures from Climate Change 2021, The Physical Science Basis, Summary for Policymakers (IPCC).
mean sea level (notebook url) : explore changes in sea level over the Globe using NASA data and estimates.
Gridded data can be read from files and written to files in various file formats. NetCDF and GeoTIFF are two common examples. Gridded data may include climatologies, reanalyses, or gridded satellite data products.
Earth observation (multiple notebooks) : popular data sources and use cases covered in JuliaEO23
sea surface temperature (notebook url coming soon) : visualize global warming at the sea surface
regional sea level (notebook url) : visualize regional sea level anomalies as mapped out by satellites
Ocean color (multiple notebooks) : notebooks focused on satellite data that characterize marine ecosystems
The OceanStateEstimation.jl and MeshArrays.jl packages can deal with gridded model output.
physical oceanography (notebook url) : visualize and compare ocean reanalyses from (ECCO project)
marine ecosystems (notebook url) : climatology maps that describe marine ecosystems (CBIOMES program)
For both land and ocean areas, data collected locally in the field is often sparse. The examples below cover common file formats and various access protocols (http, ftp, opendap, thredds). OceanRobots.jl and ArgoData.jl deal with such data collected in the Ocean.
OceanOPS.jl (➭ notebook url) : explore global ocean observing systems.
Buoy_NWP_NOAA.jl (➭ notebook url) : NOAA station displays NOAA station data.
Mooring_WHOTS.jl (➭ notebook url) displays WHOTS mooring data.
Drifter_GDP.jl (➭ notebook url) displays a drifter time series.
Float_Argo.jl (➭ notebook url) shows data from an Argo profiling float.
Glider_Spray.jl (➭ notebook url) : underwater glider data.
ClimateModels.jl provides a uniform interface to climate models of varying complexity and completeness (up to whole Earth System models). The examples also illustrate cloud computing workflows that replay
model output accessed from the web. Common file formats are supported. Version control, using git, is included to allow for workflow documentation and reproducibility.
Random walk model (0D) ➭ notebook url : two-dimensional random walk
ShallowWaters.jl model (2D) ➭ notebook url : shallow water equations
Oceananigans.jl model (3D) ➭ notebook url : non-hydrostatic model
Hector climate model (global) ➭ notebook url : simple global climate carbon-cycle model
FaIR climate model (global) ➭ notebook url : simple global climate carbon-cycle model
SPEEDY atmosphere model (3D) ➭ notebook url : fast, simplified, atmospheric model
MITgcm general circulation model (3D) ➭ notebook url : general circulation model
IndividualDisplacements.jl supports the modeling of geophysical fluids at moving point locations. It computes single point displacements within a flow field, and follow individual fluid parcels as they move over time.
IndividualDisplacements.jl is geared towards the analysis of Climate, Ocean, etc model output over a gridded domain. It can simulate material transports within the Earth System (e.g., for plastics or planktons in the Ocean; dusts or chemicals in the Atmosphere).
Simple Two-Dimensional Flow (notebook url) : simulate particle trajectories in 2D
Simple Three-Dimensional Flow (notebook url) : rotate, converge, and sink in 3D
Global Ocean Circulation (2D) (notebook url) : monthly flow climatology in 2D
Global Ocean Circulation (3D) (notebook url) : mean flow climatology in 3D
MITgcmTools.jl is a set of tools for running MITgcm, and analyzing its output.
MITgcm_configurations.jl (notebook url); explore MITgcm configurations and their parameters.
MITgcm_scan_output.jl (notebook url) : scan run directory, standard output, read grid files, and visualize.
MITgcm_run.jl (notebook url) : a detailed look into compiling and running the model.
MITgcm_worklow.jl (notebook url): build, setup, run, and plot for a chosen standard MITgcm configuration.
The examples run MITgcm
interactively via ClimateModels.jl
, use MeshArrays.jl
for visualizing outputs, and exploit IndividualDisplacements.jl
to derive material pathways.
HS94_animation.jl (notebook url) : run simple Atmosphere configuration, read output, interpolate, and plot maps.
HS94_particles.jl (notebook url) : compute particle trajectories from model output generated in HS94_animation.jl
.
HS94_Makie.jl (notebook url) : using Makie.jl
instead of Plots.jl
The JuliaCon 2021 Workshop on Modeling Marine Ecosystems was based on notebooks listed below. Additional detail is available in this repository.
AIBECS (notebook url) : global steady-state biogeochemistry and gridded transport models that run fast for long time scales (centuries or even millennia).
PlanktonIndividuals (notebook url) local to global agent-based model, particularly suited to study microbial communities, plankton physiology, and nutrient cycles.
MITgcm global biogeo (notebook url) : interface to full-featured, Fortran-based, general circulation model and its output (transports, chemistry, ecology, ocean, sea-ice, atmosphere, and more).
IndividualDisplacements (notebook url) : local to global particle tracking, for simulating dispersion, connectivity, transports in the ocean or atmosphere, etc.
MeshArrays.jl defines an array type that can contain / organize / distribute collections of inter-connected arrays as generally done in climate models. These data structures can be used to simulate variables of the climate system such as particles and transports.
Geography (notebook url) tutorial : deals with interpolation, projection, and visualization of gridded fields in geographic coordinates.
Vector Fields (notebook url) tutorial : covers the computation of global transports, streamfunctions, potentials, gradients, curls, and more.
Basics (notebook url) tutorial : illustrates how the MeshArrays.jl data structures let us write generic code readily applicable to whole families of grids.
The examples below use NCDatasets.jl and NetCDF.jl.
NetCDF_basics.jl (notebook url) is a brief tutorial that opens a netCDF file using NCDatasets.jl and plots a 2D slice as a heatmap using Makie.jl.
NetCDF_packages.jl (notebook url) reviews packages for ingesting NetCDF into various data structures; including ClimateBase.jl and ClimateTools.jl.
NetCDF_advanced.jl (notebook url) uses a large file to look at performance.
Data structures from YAXArrays.jl, Rasters.jl, ClimateTools.jl, and ClimateBase.jl also support NetCDF.
YAXArrays_demo.jl (notebook url) uses a data cube approach.
xarray_climarray_etc.jl (notebook url) uses Python's xarray and related Julia packages.
Here we look at vector and raster data. These notebooks illustrate several packages from the JuliaGeo organization.
GeoTIFF_demo.jl (notebook url) reads and plots a GeoTIFF file content using ArchGDAL.jl.
GeoJSON_demo.jl (notebook url) reads and plots a GeoJSON file content using GeoJSON.jl.
Shapefile_demo.jl (notebook url) reads and plots a Shapefile file content using Shapefile.jl.
The Data Sets section provides examples also for file formats like CSV
, JLD2
, and binary files.
The Grids and Geography section looks at gridded output from a climate model more closely.
Zarr.jl supports reading and writing Zarr
Datasets from Julia.
NCTiles.jl converts binary data into meta-data-rich NetCDF files for (1) a simple rectangular grid; (2) a tiled domain distributed over multiple files.
Get in Touch
Please use the repository issue tracker (this one) for feedback, bug reports, queries, new contribution ideas, etc.
Run Notebooks
The Pluto notebook server can be used directly from your familiar Julia environment. Alternatively, you should be able use the computer configuration that we provide on any platform (cloud, laptop, or cluster) as explained below.
To start an interactive version of a notebook, you then launch Pluto
and proceed as follows :
copy notebook url
from webpage
paste notebook url
into Pluto
click open
and wait for notebook to boot up
interact with the reactive notebook
shut down or restart notebooks as needed
You can specify the notebook URL or file path directly via Pluto.run
.
using Pluto, Downloads
path="examples/IPCC.jl"
Pluto.run(notebook=path)
Additionally, the ClimateModels.jl package provides methods to gather and open any of the notebooks found in this page.
using Pluto, ClimateModels
Pluto.run()
pluto_url="http://localhost:1234/"
nbs=notebooks.list()
notebooks.open(pluto_url,notebook_url=nbs.url[1])
Computer Configuration
Anyone should be able to run the provided computer configuration on a commercial cloud, a laptop, or a cluster from the Docker image using this command for example:
docker run -p 8888:8888 gaelforget/notebooks:latest
A bit more explanation is provided here in text and here in video.
We are very grateful to the BinderHub Federation for deploying public BinderHubs to serve the community at no cost to the user.
The notebooks mostly come from the examples
section of various Julia packages.
Data Products / ClimateModels.jl examples
Data Products / OceanStateEstimation.jl examples
Data Products / OceanRobots.jl examples
Models / ClimateModels.jl examples
Models / MITgcmTools.jl examples
Arrays / MeshArrays.jl examples
Points / IndividualDisplacements.jl examples
Examples that use gridded data sets include the OceanStateEstimation.jl
notebooks. OceanRobots.jl
in turn deals with sparse data collected in situ by diverse methods. The examples cover common file formats and protocols for accessing data.
The ClimateModels.jl
package provides an interface to models often used in climate science. The examples either run models and generate new output, or replay model output generated earlier (e.g. from CMIP6 or the 2021 IPCC report). Additional examples for the MIT general circulation model are provided in MITgcmTools.jl
.
An important requirement in climate science is to derive transports using native model grid output to e.g. precisely close energy budgets. This is one of the applications of MeshArrays.jl
– the analysis of global transports derived from gridded model output. Topics covered via MeshArrays.jl
also include interpolation and geography.
IndividualDisplacements.jl
extends this approach by providing a particle tracking framework that readily operates on climate model C-grids
using MeshArrays.jl
. Examples that let you access and explore ocean data products are provided in OceanRobots.jl
and OceanStateEstimation.jl
.
The maps, histograms, and other graphs found in the notebooks are generally created with Makie.jl.
Other popular plotting libraries include Plots.jl, Gnuplot.jl, PyPlot.jl, PlotlyJS.jl, GR.jl, and UnicodePlots.jl.