A curated list of open technology projects to sustain a stable climate, energy supply, biodiversity and natural resources.

Oceananigans.jl

Fast and friendly fluid dynamics on CPUs and GPUs.
https://github.com/clima/oceananigans.jl

Category: Hydrosphere
Sub Category: Ocean Models

Keywords

climate climate-change data-assimilation fluid-dynamics gpu julia machine-learning ocean

Keywords from Contributors

ocean-modelling ode oceanography sciml differential-equations numerical partial-differential-equations pde neural-ode ocean-sciences

Last synced: about 11 hours ago
JSON representation

Repository metadata

๐ŸŒŠ Julia software for fast, friendly, flexible, ocean-flavored fluid dynamics on CPUs and GPUs

README.md

Oceananigans is a fast, friendly, flexible software package for finite volume simulations of the nonhydrostatic
and hydrostatic Boussinesq equations on CPUs and GPUs.
It runs on GPUs (wow, fast!), though we believe Oceananigans makes the biggest waves
with its ultra-flexible user interface that makes simple simulations easy, and complex, creative simulations possible.

Oceananigans.jl is developed by the Climate Modeling Alliance and heroic external collaborators.

Contents

Installation instructions

Oceananigans is a registered Julia package. So to install it,

  1. Download Julia (version 1.9 or later).

  2. Launch Julia and type

julia> using Pkg

julia> Pkg.add("Oceananigans")

This installs the latest version that's compatible with your current environment.
Don't forget to be careful ๐Ÿ„ and check which Oceananigans you installed:

julia> Pkg.status("Oceananigans")

Running your first model

Let's run a two-dimensional, horizontally-periodic simulation of turbulence using 128ยฒ finite volume cells for 4 non-dimensional time units:

using Oceananigans
grid = RectilinearGrid(CPU(), size=(128, 128), x=(0, 2ฯ€), y=(0, 2ฯ€), topology=(Periodic, Periodic, Flat))
model = NonhydrostaticModel(; grid, advection=WENO())
ฯต(x, y) = 2rand() - 1
set!(model, u=ฯต, v=ฯต)
simulation = Simulation(model; ฮ”t=0.01, stop_time=4)
run!(simulation)

But there's more: changing CPU() to GPU() makes this code run on a CUDA-enabled Nvidia GPU.

Dive into the documentation for more code examples and tutorials.
Below, you'll find movies from GPU simulations along with CPU and GPU performance benchmarks.

The Oceananigans knowledge base

It's deep and includes:

Citing and otherwise spreading the word

If you use Oceananigans for your research, teaching, or fun ๐Ÿคฉ, everyone in our community will be grateful
if you credit Oceananigans by name.

The community has published a number of articles describing the development of Oceananigans,
including a recent preprint submitted to the Journal of Advances in Modeling Earth Systems that presents an overview of all the things that make Oceananigans unique:

"High-level, high-resolution ocean modeling at all scales with Oceananigans"

by Gregory L. Wagner, Simone Silvestri, Navid C. Constantinou, Ali Ramadhan, Jean-Michel Campin,
Chris Hill, Tomas Chor, Jago Strong-Wright, Xin Kai Lee, Francis Poulin, Andre Souza, Keaton J. Burns,
John Marshall, Raffaele Ferrari

submitted to the Journal of Advances in Modeling Earth Systems, arXiv 2502.14148

Please cite this ๐Ÿ‘† overview paper if you use Oceananigans in published work.

We've also published/submitted several model development papers. Please cite these below ๐Ÿ‘‡ if you use
the features they describe! Also, if you have developed a new feature in Oceananigans and describe it in a paper, make sure to open a pull request to add it to this list:

We also maintain a list of publications using Oceananigans.jl.
If you have work using Oceananigans that you would like to have listed there, please open a pull request to add it or let us know!

Contributing

If you're interested in contributing to the development of Oceananigans we want your help no matter how big or small a contribution you make!
Cause we're all in this together.

If you'd like to work on a new feature, or if you're new to open source and want to crowd-source neat projects that fit your interests, you should start a discussion right away.

For more information check out our contributor's guide.

Movies

Deep convection

Watch deep convection in action

Free convection

Watch free convection in action

Winds blowing over the ocean

Watch winds blowing over the ocean

Free convection with wind stress

Watch free convection with wind stress in action

Performance benchmarks

We perform some performance benchmarks (see the performance benchmarks section of the documentation) by initializing models of various sizes and measuring the wall clock time taken per model iteration (or time step).

To make full use of or fully saturate the computing power of a GPU such as an Nvidia Tesla V100 or
a Titan V, the model should have around ~10 million grid points or more.

Sometimes counter-intuitively running with Float32 is slower than Float64. This is likely due
to type mismatches causing slowdowns as floats have to be converted between 32-bit and 64-bit, an
issue that needs to be addressed meticulously. Due to other bottlenecks such as memory accesses and
GPU register pressure, Float32 models may not provide much of a speedup so the main benefit becomes
lower memory costs (by around a factor of 2).

Performance benchmark plots

Citation (CITATION.cff)

cff-version: 1.2.0
preferred-citation:
  type: article
  authors:
  - family-names: "Ramadhan"
    given-names: "Ali"
    orcid: "https://orcid.org/0000-0003-1102-1520"
  - family-names: "Wagner"
    given-names: "Gregory LeClaire"
    orcid: "https://orcid.org/0000-0001-5317-2445"
  - family-names: "Hill"
    given-names: "Chris"
  - family-names: "Jean-Michel"
    given-names: "Campin"
  - family-names: "Churavy"
    given-names: "Valentin"
    orcid: "https://orcid.org/0000-0002-9033-165X"
  - family-names: "Souza"
    given-names: "Andre"
  - family-names: "Edelman"
    given-names: "Adam"
    orcid: "https://orcid.org/0000-0002-9033-165X"
  - family-names: "Ferrari"
    given-names: "Raffaele"
    orcid: "https://orcid.org/0000-0003-1895-4294"
  - family-names: "Marshall"
    given-names: "John"
  title: "Oceananigans.jl: Fast and friendly geophysical fluid dynamics on GPUs"
  journal: "Journal of Open Source Software"
  doi: "10.21105/joss.02018"
  volume: 5
  issue: 53
  start: 2018
  year: 2020

Owner metadata


GitHub Events

Total
Last Year

Committers metadata

Last synced: 3 days ago

Total Commits: 10,950
Total Committers: 76
Avg Commits per committer: 144.079
Development Distribution Score (DDS): 0.682

Commits in past year: 454
Committers in past year: 25
Avg Commits per committer in past year: 18.16
Development Distribution Score (DDS) in past year: 0.551

Name Email Commits
ali-ramadhan a****n@g****m 3487
Gregory Wagner w****g@g****m 2500
Simone Silvestri s****0@g****m 1830
Navid C. Constantinou n****y 1715
tomchor t****r@g****m 606
francispoulin f****n@u****a 267
Elise Palethorpe e****y@g****m 78
sandreza a****a@g****m 73
suyashbire1 s****9@g****m 45
hennyg888 h****2@h****m 38
Victoria Whitley w****v@a****t 37
Jago Strong-Wright j****w@p****m 33
christophernhill c****h@m****u 29
github-actions[bot] 4****] 25
William Moses gh@w****m 18
Valentin Churavy v****y@g****m 13
Jean-Michel Campin j****c@m****u 13
Josef Bisits j****s@g****m 10
CompatHelper Julia c****y@j****g 10
Simone Silvestri s****i@d****u 9
Alex Cavaliere a****e@s****m 5
Avik Pal a****l@m****u 5
Gabriele Bozzola g****a@c****u 5
iury simoes-sousa i****t@p****e 5
Kamontat Chantrachirathumrong g****b@k****t 4
Alexis Montoison 3****n 4
Keaton J. Burns k****s@g****m 4
Sid s****u@g****m 4
Tim Besard t****d@g****m 4
Xin Kai Lee 5****i 4
and 46 more...

Committer domains:


Issue and Pull Request metadata

Last synced: 1 day ago

Total issues: 1,684
Total pull requests: 2,667
Average time to close issues: 6 months
Average time to close pull requests: 24 days
Total issue authors: 114
Total pull request authors: 73
Average comments per issue: 5.21
Average comments per pull request: 4.28
Merged pull request: 2,094
Bot issues: 0
Bot pull requests: 99

Past year issues: 283
Past year pull requests: 711
Past year average time to close issues: 20 days
Past year average time to close pull requests: 11 days
Past year issue authors: 43
Past year pull request authors: 29
Past year average comments per issue: 5.7
Past year average comments per pull request: 3.4
Past year merged pull request: 486
Past year bot issues: 0
Past year bot pull requests: 21

More stats: https://issues.ecosyste.ms/repositories/lookup?url=https://github.com/clima/oceananigans.jl

Top Issue Authors

  • glwagner (455)
  • ali-ramadhan (447)
  • navidcy (224)
  • tomchor (145)
  • francispoulin (72)
  • simone-silvestri (63)
  • jagoosw (23)
  • iuryt (13)
  • xkykai (10)
  • Sumanshekhar17 (8)
  • liuchihl (8)
  • suyashbire1 (8)
  • mukund-gupta (8)
  • sandreza (7)
  • NoraLoose (7)

Top Pull Request Authors

  • glwagner (841)
  • navidcy (470)
  • ali-ramadhan (429)
  • simone-silvestri (321)
  • tomchor (157)
  • github-actions[bot] (92)
  • francispoulin (51)
  • jagoosw (45)
  • wsmoses (21)
  • siddharthabishnu (19)
  • christophernhill (16)
  • xkykai (11)
  • amontoison (11)
  • jlk9 (11)
  • jbisits (11)

Top Issue Labels

  • bug ๐Ÿž (246)
  • documentation ๐Ÿ“œ (189)
  • user interface/experience ๐Ÿ’ป (163)
  • cleanup ๐Ÿงน (161)
  • question ๐Ÿ’ญ (147)
  • feature ๐ŸŒŸ (139)
  • abstractions ๐ŸŽจ (118)
  • testing ๐Ÿงช (107)
  • numerics ๐Ÿงฎ (95)
  • performance ๐Ÿ๏ธ (94)
  • GPU ๐Ÿ‘พ (92)
  • output ๐Ÿ’พ (66)
  • science ๐ŸŒŠ (60)
  • package ๐Ÿ“ฆ (53)
  • grids ๐Ÿ—บ๏ธ (41)
  • good first issue ๐Ÿค (41)
  • help wanted ๐Ÿฆฎ (39)
  • distributed ๐Ÿ•ธ๏ธ (26)
  • immersed boundaries โ›ฐ๏ธ (21)
  • ๐Ÿšจ high priority ๐Ÿšจ (18)
  • turbulence closures ๐ŸŽ (17)
  • cubed sphere ๐ŸงŠ๐ŸŒŽ (14)
  • boundary conditions ๐Ÿ“ (13)
  • models ๐Ÿงซ (10)
  • duplicate ๐Ÿงฌ (9)
  • simulation ๐ŸŽฎ (8)
  • extensions ๐Ÿงฌ (6)
  • ๐Ÿšฒ bikeshedding (3)
  • multithreading ๐Ÿงต (2)
  • parameterizations (1)

Top Pull Request Labels

  • documentation ๐Ÿ“œ (269)
  • bug ๐Ÿž (148)
  • package ๐Ÿ“ฆ (113)
  • testing ๐Ÿงช (109)
  • cleanup ๐Ÿงน (106)
  • numerics ๐Ÿงฎ (94)
  • feature ๐ŸŒŸ (83)
  • user interface/experience ๐Ÿ’ป (81)
  • GPU ๐Ÿ‘พ (76)
  • performance ๐Ÿ๏ธ (58)
  • science ๐ŸŒŠ (51)
  • grids ๐Ÿ—บ๏ธ (45)
  • output ๐Ÿ’พ (42)
  • ๐Ÿšจ DO NOT MERGE ๐Ÿšจ (42)
  • turbulence closures ๐ŸŽ (39)
  • extensions ๐Ÿงฌ (38)
  • distributed ๐Ÿ•ธ๏ธ (30)
  • abstractions ๐ŸŽจ (29)
  • cubed sphere ๐ŸงŠ๐ŸŒŽ (27)
  • immersed boundaries โ›ฐ๏ธ (26)
  • boundary conditions ๐Ÿ“ (14)
  • benchmark performance (8)
  • dependencies (7)
  • models ๐Ÿงซ (6)
  • validation scripts ๐Ÿ’…๐Ÿผ (6)
  • ๐Ÿšฒ bikeshedding (4)
  • biogeochemistry ๐Ÿฆ  (4)
  • help wanted ๐Ÿฆฎ (4)
  • simulation ๐ŸŽฎ (4)
  • experimental feature ๐Ÿงช (3)

Package metadata

juliahub.com: Oceananigans

๐ŸŒŠ Julia software for fast, friendly, flexible, ocean-flavored fluid dynamics on CPUs and GPUs

  • Homepage: https://clima.github.io/OceananigansDocumentation/stable
  • Documentation: https://docs.juliahub.com/General/Oceananigans/stable/
  • Licenses: MIT
  • Latest release: 0.96.21 (published 26 days ago)
  • Last Synced: 2025-04-25T14:39:17.905Z (1 day ago)
  • Versions: 313
  • Dependent Packages: 9
  • Dependent Repositories: 0
  • Downloads: 2,022 Total
  • Rankings:
    • Stargazers count: 0.386%
    • Forks count: 0.421%
    • Average: 5.957%
    • Dependent repos count: 6.056%
    • Dependent packages count: 16.965%

Dependencies

.github/workflows/CompatHelper.yml actions
  • julia-actions/setup-julia v1 composite
.github/workflows/TagBot.yml actions
  • JuliaRegistries/TagBot v1 composite
Dockerfile docker
  • julia 1.9.3 build

Score: 19.213145681423168