Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JOSS paper #387

Merged
merged 96 commits into from
Jun 4, 2024
Merged
Show file tree
Hide file tree
Changes from 20 commits
Commits
Show all changes
96 commits
Select commit Hold shift + click to select a range
3e4167e
Create draft-pdf.yml
milankl Sep 14, 2023
10a2701
paper template, first paragraphs, bib
milankl Sep 14, 2023
de7c467
paper.pdf and paper.jats removed
milankl Sep 14, 2023
bb4b899
github action: save pdf to repo
milankl Sep 15, 2023
9bfea3d
first paper draft finished
milankl Sep 15, 2023
c526171
Saved new PDF of paper
milankl Sep 15, 2023
fd58298
joss paper: affiliations updated
milankl Sep 16, 2023
2c59a8b
Saved new PDF of paper
milankl Sep 16, 2023
cd11fd4
JOSS paper: further comments accepted
milankl Sep 16, 2023
4049518
Saved new PDF of paper
milankl Sep 16, 2023
553bcc6
joss paper: sentence after monolithic added
milankl Sep 16, 2023
0ebc3aa
Saved new PDF of paper
milankl Sep 16, 2023
e6d56b6
joss paper: Sam's suggestions accepted
milankl Sep 18, 2023
7ef34ce
Saved new PDF of paper
milankl Sep 18, 2023
c6e659a
joss paper: Max, Navid suggestions added
milankl Sep 19, 2023
41cc8ae
Saved new PDF of paper
milankl Sep 19, 2023
e954def
joss paper: max easy running
milankl Sep 19, 2023
2f61224
Saved new PDF of paper
milankl Sep 19, 2023
e9ac229
joss paper: fix some citations
milankl Sep 19, 2023
8e27e26
Saved new PDF of paper
milankl Sep 19, 2023
ce36c82
joss paper: index 2 added for Oxford
milankl Sep 21, 2023
66b7b88
Saved new PDF of paper
milankl Sep 21, 2023
afe4feb
Add Justin's orcid
milankl Sep 25, 2023
1e636df
Saved new PDF of paper
milankl Sep 25, 2023
dc0f903
JOSS paper: Alistair's suggestions
milankl Sep 26, 2023
ba2244c
Saved new PDF of paper
milankl Sep 26, 2023
453a8c1
JOSS paper: affils updated
milankl Sep 26, 2023
78d3a46
Saved new PDF of paper
milankl Sep 26, 2023
783522b
Update docs/joss/paper.md
milankl Oct 16, 2023
8c99caf
Saved new PDF of paper
milankl Oct 16, 2023
6bf1982
JOSS paper: Alistair's and David's comments.
milankl Oct 16, 2023
9857a80
Saved new PDF of paper
milankl Oct 16, 2023
794ae95
joss paper: spaces for list
milankl Oct 16, 2023
559ca64
Saved new PDF of paper
milankl Oct 16, 2023
61f4850
JOSS paper: slight tweaks
milankl Oct 16, 2023
fc75789
Saved new PDF of paper
milankl Oct 16, 2023
02fe3a0
JOSS paper: David's paper added
milankl Oct 16, 2023
8615235
JOSS paper: citation typo
milankl Oct 16, 2023
f2b6f7d
JOSS paper: David's paper key changed
milankl Oct 16, 2023
40887ef
Saved new PDF of paper
milankl Oct 16, 2023
039d756
JOSS paper: Add Justin's citations
milankl Oct 16, 2023
9000d60
Saved new PDF of paper
milankl Oct 16, 2023
707053b
JOSS paper: Alistair's next comments
milankl Oct 17, 2023
5e57d9e
Saved new PDF of paper
milankl Oct 17, 2023
30b51ea
JOSS Paper: remove David and tweaks
milankl Oct 20, 2023
2d599b5
Saved new PDF of paper
milankl Oct 20, 2023
767b785
JOSS paper: Simone's comments
milankl Oct 25, 2023
9bde536
Saved new PDF of paper
milankl Oct 25, 2023
71a9355
JOSS paper: Alistair not MIT
milankl Oct 25, 2023
4ede4da
Saved new PDF of paper
milankl Oct 25, 2023
9fe4f94
JOSS paper: Simone's restructure suggestions
milankl Oct 25, 2023
7cb917c
Saved new PDF of paper
milankl Oct 25, 2023
4d7702f
JOSS paper: more tweaks following restructure
milankl Oct 25, 2023
f083a9a
Saved new PDF of paper
milankl Oct 25, 2023
2ef9b0f
joss paper: with new figure, incl precip
milankl Nov 30, 2023
84239c8
Saved new PDF of paper
milankl Nov 30, 2023
66cf01c
joss paper: figures moved upwards
milankl Nov 30, 2023
aedac51
Merge branch 'mk/josspaper' of https://github.com/SpeedyWeather/Speed…
milankl Nov 30, 2023
465edc7
Saved new PDF of paper
milankl Nov 30, 2023
fd03c79
josspaper: doi corrected
milankl Dec 6, 2023
a8235e1
Saved new PDF of paper
milankl Dec 6, 2023
752e001
use initials for first/middle names
navidcy Feb 22, 2024
5d9c304
Saved new PDF of paper
navidcy Feb 22, 2024
c63b33b
Navid's affiliation
milankl Feb 22, 2024
19168b6
Saved new PDF of paper
milankl Feb 22, 2024
bcb8df9
combine affiliations
navidcy Feb 22, 2024
5672dd8
Saved new PDF of paper
navidcy Feb 22, 2024
684eb5a
add simone's orcid
navidcy Feb 22, 2024
d9004fe
Merge branch 'mk/josspaper' of github.com:SpeedyWeather/SpeedyWeather…
navidcy Feb 22, 2024
5a4e5a4
Saved new PDF of paper
navidcy Feb 22, 2024
d4e5125
Merge branch 'main' into mk/josspaper
milankl Mar 3, 2024
b1c1062
Saved new PDF of paper
milankl Mar 3, 2024
e81500e
Merge branch 'main' into mk/josspaper
milankl Mar 20, 2024
f7e864e
Saved new PDF of paper
milankl Mar 20, 2024
f09bab1
First points of slayoo addressed
milankl Mar 27, 2024
aa93655
Saved new PDF of paper
milankl Mar 27, 2024
eee6555
More slayoo's review comments
milankl Mar 29, 2024
75e72ce
Merge branch 'main' into mk/josspaper
milankl Mar 29, 2024
0018b19
Merge branch 'mk/josspaper' of https://github.com/SpeedyWeather/Speed…
milankl Mar 29, 2024
67eddb7
Saved new PDF of paper
milankl Mar 29, 2024
579c490
Particle figure for barotropic vorticity equations
milankl Apr 2, 2024
04a9378
Merge branch 'mk/josspaper' of https://github.com/SpeedyWeather/Speed…
milankl Apr 2, 2024
4dc8fa9
Saved new PDF of paper
milankl Apr 2, 2024
81eedda
particles.jpg with white background
milankl Apr 2, 2024
3e863bc
Merge branch 'mk/josspaper' of https://github.com/SpeedyWeather/Speed…
milankl Apr 2, 2024
65c3259
Saved new PDF of paper
milankl Apr 2, 2024
d76df12
Higher resolution figure for primitive equation showcase
milankl Apr 2, 2024
a88f020
Merge branch 'mk/josspaper' of https://github.com/SpeedyWeather/Speed…
milankl Apr 2, 2024
58d582b
Saved new PDF of paper
milankl Apr 2, 2024
f40d6ce
Merge branch 'main' into mk/josspaper
milankl May 20, 2024
99e1e26
Saved new PDF of paper
milankl May 20, 2024
cc28a4a
Update docs/joss/paper.bib
milankl May 20, 2024
f54e7d4
Saved new PDF of paper
milankl May 20, 2024
9813e99
Capitalization in the references
milankl Jun 4, 2024
000c992
Space before reference
milankl Jun 4, 2024
a71fa34
Saved new PDF of paper
milankl Jun 4, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/draft-pdf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
on: [push]

jobs:
paper:
runs-on: ubuntu-latest
name: Paper Draft
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Build draft PDF
uses: openjournals/openjournals-draft-action@master
with:
journal: joss
# This should be the path to the paper within your repo.
paper-path: docs/joss/paper.md
- name: Upload
uses: actions/upload-artifact@v1
with:
name: paper
# This is the output path where Pandoc will write the compiled
# PDF. Note, this should be the same directory as the input
# paper.md
path: docs/joss/paper.pdf
# These lines have been added following
# https://github.com/openjournals/openjournals-draft-action/issues/15
- name: save pdf to repo
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Saved new PDF of paper
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,8 @@ Manifest.toml
run_*/

# no video outputs
*.mp4
*.mp4

# JOSS paper
docs/joss/media
docs/joss/paper.jats
Binary file removed docs/img/barotropic_vorticity.jpg
Binary file not shown.
Binary file removed docs/img/galewsky.jpg
Binary file not shown.
Binary file removed docs/img/galewsky_nc_12days.png
Binary file not shown.
Binary file removed docs/img/galewsky_nc_12days_mountains.png
Binary file not shown.
Binary file removed docs/img/galewsky_nc_6days.png
Binary file not shown.
452 changes: 452 additions & 0 deletions docs/joss/paper.bib

Large diffs are not rendered by default.

201 changes: 201 additions & 0 deletions docs/joss/paper.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,201 @@
---
title: 'SpeedyWeather.jl: Reinventing atmospheric general circulation models towards interactivity, extensibility and composability'
milankl marked this conversation as resolved.
Show resolved Hide resolved

tags:
- Julia
- weather
- climate
- general circulation model
- spectral
- spherical harmonic transform

authors:
- name: Milan Klöwer
orcid: 0000-0002-3920-4356
email: [email protected]
corresponding: true # (This is how to denote the corresponding author)
affiliation: "1, 2" # (Multiple affiliations must be quoted)

- name: Maximilian Gelbrecht
orcid: 0000-0002-0729-6671
affiliation: "3,4"
milankl marked this conversation as resolved.
Show resolved Hide resolved

- name: Daisuke Hotta
orcid: 0000-0003-2287-0608
affiliation: "5,6"

- name: Justin Willmert
affiliation: 7
milankl marked this conversation as resolved.
Show resolved Hide resolved

- name: Simone Silvestri
affiliation: 1

- name: Gregory L Wagner
milankl marked this conversation as resolved.
Show resolved Hide resolved
orcid: 0000-0001-5317-2445
affiliation: 1

- name: Alistair White
milankl marked this conversation as resolved.
Show resolved Hide resolved
affiliation: "3,4"

- name: Sam Hatfield
affiliation: 6

- name: David Meyer
affiliation: 6
milankl marked this conversation as resolved.
Show resolved Hide resolved

- name: Tom Kimpson
affiliation: "2,8"

- name: Navid C Constantinou
milankl marked this conversation as resolved.
Show resolved Hide resolved
orcid: 0000-0002-8149-4094
affiliation: 9

- name: Chris Hill
affiliation: 1

affiliations:
- name: Massachusetts Institute of Technology, Cambridge, MA, USA
index: 1
- name: University of Oxford, UK
milankl marked this conversation as resolved.
Show resolved Hide resolved
- name: Technical University of Munich, Germany
index: 3
- name: Potsdam Institute for Climate Impact Research, Germany
index: 4
- name: Japan Meteorological Agency, Tsukuba, Japan
index: 5
- name: European Centre for Medium-Range Weather Forecasts, Reading, UK
index: 6
- name: University of Minnesota, Minneapolis, MN, USA
index: 7
milankl marked this conversation as resolved.
Show resolved Hide resolved
- name: University of Melbourne, Australia
index: 8
- name: Australian National University, Canberra, Australia
milankl marked this conversation as resolved.
Show resolved Hide resolved
index: 9

date: 14 September 2023
bibliography: paper.bib

---


# Summary

SpeedyWeather.jl is a library to simulate and analyse the global atmospheric
milankl marked this conversation as resolved.
Show resolved Hide resolved
circulation on the sphere. It implements several 2D and 3D
models to solve the primitive equations with and without humidity (\autoref{fig:primitive}),
the shallow water equations (\autoref{fig:swm}), or the barotropic vorticity equations
with spherical harmonics. Several simple parameterizations for unresolved physical processes
milankl marked this conversation as resolved.
Show resolved Hide resolved
such as precipitation or the boundary layer are implemented, and new ones can
milankl marked this conversation as resolved.
Show resolved Hide resolved
be externally defined and passed as an argument to the model constructor.
milankl marked this conversation as resolved.
Show resolved Hide resolved
SpeedyWeather.jl is an intermediate-complexity general circulation model [@Kucharski2013]
and research playground with an (almost) everything-flexible attitude.
It can be thought of as a conceptual reinvention of the Fortran SPEEDY model [@Molteni2003]
in the Julia programming language [@Bezanson2017].
milankl marked this conversation as resolved.
Show resolved Hide resolved

SpeedyWeather.jl internally uses three sub-modules `SpeedyTransforms`, `RingGrids`, and
`LowerTriangularMatrices` to perform spherical harmonic transforms and interpolations
between various grids and the spectral space. `RingGrids` discretize the sphere
on iso-latitude rings and the spectral space is defined by the `LowerTriangularMatrices`
of the spherical harmonic coefficients. These three modules are independently usable
milankl marked this conversation as resolved.
Show resolved Hide resolved
and therefore make SpeedyWeather.jl, beyond its main purpose of simulating the weather,
also a library for the analysis of gridded data on the sphere.
navidcy marked this conversation as resolved.
Show resolved Hide resolved
Running and analysing simulations can be interactively combined, enhancing user
milankl marked this conversation as resolved.
Show resolved Hide resolved
experience and productivity.
milankl marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
SpeedyWeather.jl internally uses three sub-modules `SpeedyTransforms`, `RingGrids`, and
`LowerTriangularMatrices` to perform spherical harmonic transforms and interpolations
between various grids and the spectral space. `RingGrids` discretize the sphere
on iso-latitude rings and the spectral space is defined by the `LowerTriangularMatrices`
of the spherical harmonic coefficients. These three modules are independently usable
and therefore make SpeedyWeather.jl, beyond its main purpose of simulating the weather,
also a library for the analysis of gridded data on the sphere.
Running and analysing simulations can be interactively combined, enhancing user
experience and productivity.
SpeedyWeather.jl incorporates three distinct sub-modules: `SpeedyTransforms`, `RingGrids`, and `LowerTriangularMatrices`. These enable spherical harmonic transformations and grid-to-spectral space interpolations. Specifically, `RingGrids` discretises the sphere on iso-latitude rings, while `LowerTriangularMatrices` defines the spherical space through spherical harmonic coefficients. Beyond, weather simulations, these modular components facilitate analysis of gridded data on the sphere. Running and analysing simulations can be interactively combined, enhancing user experience and productivity.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to above, what is the need here to reword the entire paragraph? Especially because you introduced some wordings that aren't as concise as before. "grid-to-spectral space interpolations", a spectral transform is strictly speaking not an interpolation. We do have interpolations between various RingGrids, but they are distinct. "spherical space" isn't a commonly used term, neither does it include the notion of spectral that "spectral space" would have or "spherical harmonic space". Please try to avoid introducing these inconcise terms.


The user interface of SpeedyWeather.jl is heavily influenced by
the Julia ocean model Oceananigans.jl [@Ramadhan2020].
A monolithic interface based on parameter files is avoided in favor of a
library-style interface in which users write code to run models rather than
merely supplying parameters and input arrays.
milankl marked this conversation as resolved.
Show resolved Hide resolved
A model is created bottom-up by first defining the discretization
milankl marked this conversation as resolved.
Show resolved Hide resolved
and any non-default model components with its respective parameters.
milankl marked this conversation as resolved.
Show resolved Hide resolved
All components are then collected into a single model object, which, once
milankl marked this conversation as resolved.
Show resolved Hide resolved
initialized, returns a simulation object that contains the entire model state,
work arrays and parameters, that can be run, analysed or changed.
milankl marked this conversation as resolved.
Show resolved Hide resolved
While these steps can be written into a script for reproducibility,
milankl marked this conversation as resolved.
Show resolved Hide resolved
the same steps can be executed and interacted with one-by-one in
Julia's read-evaluate-print loop (REPL). We thereby reach an interactivity
milankl marked this conversation as resolved.
Show resolved Hide resolved
far beyond a monolithic interface that is limited to the options provided.
milankl marked this conversation as resolved.
Show resolved Hide resolved
At the same time, sensible default arguments enable even inexperienced users
to run simulations in just a few lines of code.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The user interface of SpeedyWeather.jl is heavily influenced by
the Julia ocean model Oceananigans.jl [@Ramadhan2020].
A monolithic interface based on parameter files is avoided in favor of a
library-style interface in which users write code to run models rather than
merely supplying parameters and input arrays.
A model is created bottom-up by first defining the discretization
and any non-default model components with its respective parameters.
All components are then collected into a single model object, which, once
initialized, returns a simulation object that contains the entire model state,
work arrays and parameters, that can be run, analysed or changed.
While these steps can be written into a script for reproducibility,
the same steps can be executed and interacted with one-by-one in
Julia's read-evaluate-print loop (REPL). We thereby reach an interactivity
far beyond a monolithic interface that is limited to the options provided.
At the same time, sensible default arguments enable even inexperienced users
to run simulations in just a few lines of code.
SpeedyWeather.jl's user interface draws inspiration from Julia's ocean model Oceananigans.jl [@Ramadhan2020]. Instead of a monolithic parameter-file interface, it adopts a library-style approach. In this, users write code to run models rather than providing parameters and input arrays. Models are built from the ground up—first by defining the discretization method, then adding any non-standard components and their parameters which are then collected into a single model object. Once initialized, the model object produces a simulation with the model’s state, work arrays, and parameters—ready to be run, analysed or modified. Although these steps can be scripted for consistency, they can also be executed in Julia's read-evaluate-print loop (REPL), offering enhanced interactivity. At the same time, sensible default arguments enable even inexperienced users to run simulations in just a few lines of code.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to my review comment from above. Why did you rewrite the entire paragraph? If there's need for it I'd be happy to accept your suggestions, but I cannot see what was wrong with the previous version. "draws inspiration from" is less correct than the previous "heavily influenced"; I don't know what "library-style approach" is, but the previous "library-style interface" is clearer as it refers to the model being used as a software library, which various functions that can be interactively combined. Also "models are built from ground up" is not correct, as it's not the ground where one has to start from, it's the library level that we provide. "bottom-up" is more relative and a known term in constrast to "top-down". "the model object produces a simulation" is also not correct, there's a reason why I wrote "initialize" before. And you removed the important point of "interactivity
far beyond a monolithic interface", that should remain.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Careful, garbage in, garbage out. What is sensible?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The initial conditions for the shallow water model and the primitive equations by default are the Galewsky et al, 2004 and the Jablonowksi and Williamson 2006 test cases, respectively. "sensible" means that inexperienced users are not confronted with simulations that blow up by default etc. So I don't know what your concern is here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added that defaults are well-established test cases


To be extensible and composable with new
model components, SpeedyWeather.jl relies on Julia's multiple dispatch
programming paradigm [@Bezanson2017]. Every model component
is defined as a new type. For example, to define a new way how to calculate
milankl marked this conversation as resolved.
Show resolved Hide resolved
the precipitation due to the physical process of large-scale condensation,
one would define `MyCondensation` as a new subtype of `AbstractCondensation`.
One then only needs to extend the `initialize!` and `condensation!`
functions for this new type. Passing on `condensation = MyCondensation()`
to the model constructor then implements this new model component without
the need to branch off or overwrite existing model components.
Conceptually similar scientific modelling paradigms have been very successful
in the Python-based generic partial differential equation solver Dedalus [@Burns2020]
and the Julia ocean model Oceananigans.jl [@Ramadhan2020].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
To be extensible and composable with new
model components, SpeedyWeather.jl relies on Julia's multiple dispatch
programming paradigm [@Bezanson2017]. Every model component
is defined as a new type. For example, to define a new way how to calculate
the precipitation due to the physical process of large-scale condensation,
one would define `MyCondensation` as a new subtype of `AbstractCondensation`.
One then only needs to extend the `initialize!` and `condensation!`
functions for this new type. Passing on `condensation = MyCondensation()`
to the model constructor then implements this new model component without
the need to branch off or overwrite existing model components.
Conceptually similar scientific modelling paradigms have been very successful
in the Python-based generic partial differential equation solver Dedalus [@Burns2020]
and the Julia ocean model Oceananigans.jl [@Ramadhan2020].
SpeedyWeather.jl uses Julia's multiple dispatch programming approach for flexibility and component integration [@Bezanson2017]. Each model component is a distinct type. For example, a new precipitation parametrization from the large-scale condensation could be defined as `MyCondensation`, a subtype of `AbstractCondensation`. Only the `initialize!` and `condensation!` functions need modification for this type. By simply passing `condensation = MyCondensation()` to the model constructor, this component is seamlessly integrated without altering existing components. This modular design mirrors successful practices in Python’s Dedalus solver [@Burns2020] and Julia’s Oceananigans.jl model [@Ramadhan2020].

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to my comments from above. Please justify why there is a need to reword the entire paragraph, especially because you introduced several points that are less correct, less concise as they were before. You write "distinct type", which I'd like to avoid because these types are sub and supertypes of each other, so they have a relation and depending on the type tree aren't always distinguished and can be subtyped. You write "functions need modification for this type" no, that's not how multiple dispatch works. There's a reason I wrote "extend" rather than "modify" because with multiple dispatch you don't have to modify or overwrite the previous definition of a function, rather you extend it by defining a new method, that's very different and in fact our entire approach wouldn't work if it wasn't for that!


![Surface temperature simulated with the primitive equation model in SpeedyWeather.jl.
milankl marked this conversation as resolved.
Show resolved Hide resolved
(Figure will be updated) \label{fig:primitive}](primitive.jpg)

The dynamical core of SpeedyWeather.jl uses established numerics
[@Bourke1972; @Hoskins1975; @Simmons1978; @Simmons1981],
widely adopted in numerical weather prediction. It is based on the spherical
harmonic transform with a leapfrog-based semi-implicit time integration [@Hoskins1975]
and a Robert-Asselin-Williams filter [@Williams2011; @Amezcua2011].
The spherical harmonic transform is grid-flexible. Any iso-latitude ring-based
grid can be used and new grids can be externally defined and passed in
as an argument. Many grids are already implemented: the conventional
Gaussian grid, a regular longitude-latitude grid,
the octahedral Gaussian grid [@Malardel2016], the octahedral
Clenshaw-Curtis grid [@Hotta2018], and the HEALPix grid [@Gorski2005].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The dynamical core of SpeedyWeather.jl uses established numerics
[@Bourke1972; @Hoskins1975; @Simmons1978; @Simmons1981],
widely adopted in numerical weather prediction. It is based on the spherical
harmonic transform with a leapfrog-based semi-implicit time integration [@Hoskins1975]
and a Robert-Asselin-Williams filter [@Williams2011; @Amezcua2011].
The spherical harmonic transform is grid-flexible. Any iso-latitude ring-based
grid can be used and new grids can be externally defined and passed in
as an argument. Many grids are already implemented: the conventional
Gaussian grid, a regular longitude-latitude grid,
the octahedral Gaussian grid [@Malardel2016], the octahedral
Clenshaw-Curtis grid [@Hotta2018], and the HEALPix grid [@Gorski2005].
SpeedyWeather.jl's dynamical core employs grid-flexible spherical harmonic transform and integrates a leapfrog-based semi-implicit time technique [@Hoskins1975] with a Robert-Asselin-Williams filter [@Williams2011; @Amezcua2011]---well-accepted in numerical weather prediction [@Bourke1972; @Hoskins1975; @Simmons1978; @Simmons1981]. Multiple grid types, such as Gaussian, longitude-latitude, octahedral Gaussian [@Malardel2016], octahedral Clenshaw-Curtis [@Hotta2018], and HEALPix [@Gorski2005], are supported. Additionally, users can define new ones.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar as before, I don't see the win over the new paragraph compared to the old, especially because we now have two very long sentences, whereas the previous version had a clear summary sentence to start with before going into the details.

Both SpeedyWeather.jl and its spherical harmonic transform SpeedyTransforms are also
number format-flexible. 32-bit single-precision floating-point numbers
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tautology

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, no. SpeedyWeather could be number format flexible without its transform and vice versa. I've been playing with the idea to use one format for the dynamical core exclusive the transform, but always Float32 for the transform as FFTW only supports Float32/64

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think what @dmey means here is that 32-bit implies single precision and vice versa, hence stating both is tautological.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah okay. Yeah, sure happy to write just single precision.

(Float32) are the default as adopted by other modelling efforts [@Vana2017; @Nakano2018],
but Float64 and other custom number formats can be used with a single
code basis [@Klower2022; @Klower2020].
Julia will compile to the choice of the number format, the grid,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought you had problem with half precision etc. Is this actually working? Else rephrase

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where do I say this is running in half precision? The FFT will switch between FFTW and GenericFFT depending on the format, using half precision is a precision issue not a compiler issue anymore. Other formats like posits may require certain methods that I haven't defined yet, but that's not a problem of SpeedyWeather.

milankl marked this conversation as resolved.
Show resolved Hide resolved
and and other model components just-in-time. A simple parallelisation
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
and and other model components just-in-time. A simple parallelisation
and other model components just-in-time. A simple parallelization

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still an extra and

across vertical layers is supported with Julia's multi threading.
milankl marked this conversation as resolved.
Show resolved Hide resolved
milankl marked this conversation as resolved.
Show resolved Hide resolved
Output is stored as NetCDF files using
[NCDatasets.jl](https://github.com/Alexander-Barth/NCDatasets.jl).
milankl marked this conversation as resolved.
Show resolved Hide resolved
milankl marked this conversation as resolved.
Show resolved Hide resolved
milankl marked this conversation as resolved.
Show resolved Hide resolved

# Statement of need
milankl marked this conversation as resolved.
Show resolved Hide resolved

SpeedyWeather.jl is a fresh approach to atmospheric
milankl marked this conversation as resolved.
Show resolved Hide resolved
models that have been very influential in many areas of scientific
milankl marked this conversation as resolved.
Show resolved Hide resolved
and high-performance computing as well as climate change mitigation and adaptation.
Most weather, ocean and climate models are written in Fortran and have been developed over
decades. From this tradition follows a specific programming style and
associated user interface. Running a simulation in Fortran and analysing the
data in Python makes it virtually impossible to interact with various model
components interactively. Furthermore, data-driven climate modelling
milankl marked this conversation as resolved.
Show resolved Hide resolved
[@Rasp2018; @Schneider2023], which replaces existing model components with machine learning
milankl marked this conversation as resolved.
Show resolved Hide resolved
is difficult due to the lack of established deep learning frameworks in Fortran [@Innes2019].
Let alone online learning, which trains a neural network-based component together
milankl marked this conversation as resolved.
Show resolved Hide resolved
with the rest of the model, accounting for interactions between components.
Gradients, necessary to optimize training, can be computed
milankl marked this conversation as resolved.
Show resolved Hide resolved
with automatic differentiation [@Moses2020], but only if differentiable functions
in a coherent language framework are provided.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
SpeedyWeather.jl is a fresh approach to atmospheric
models that have been very influential in many areas of scientific
and high-performance computing as well as climate change mitigation and adaptation.
Most weather, ocean and climate models are written in Fortran and have been developed over
decades. From this tradition follows a specific programming style and
associated user interface. Running a simulation in Fortran and analysing the
data in Python makes it virtually impossible to interact with various model
components interactively. Furthermore, data-driven climate modelling
[@Rasp2018; @Schneider2023], which replaces existing model components with machine learning
is difficult due to the lack of established deep learning frameworks in Fortran [@Innes2019].
Let alone online learning, which trains a neural network-based component together
with the rest of the model, accounting for interactions between components.
Gradients, necessary to optimize training, can be computed
with automatic differentiation [@Moses2020], but only if differentiable functions
in a coherent language framework are provided.
SpeedyWeather.jl aims to overcome the constraints of traditional Fortran-based models. Historically, Fortran’s efficiency in numerical computations led to its widespread use in weather and climate modelling. The modern trend sees simulations in Fortran and data analysis in Python, potentially limited interactive engagement with model components. While there have been successful attempts to integrate machine learning into Fortran-based weather and climate models using existing frameworks[@Meyer_2022; Meyer_et_al_2022], challenging persist [@Rasp2018; @Schneider2023; @Innes2019]. Online learning, which involves training a neural network alongside the primary model, introduces complexities. Furthermore, training optimization necessitates gradients from automatic differentiation [@Moses2020], contingent on the availability of differentiable functions in a consistent language framework.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the first sentences you wrote and will incorporate them in the next days. Can you clarify whether there's a difference between your paper and your thesis, or whether for the sake of this citation they actually refer to the same piece of work. Very happy to cite your paper!


milankl marked this conversation as resolved.
Show resolved Hide resolved
We hope to provide with SpeedyWeather.jl a first test platform for data-driven
milankl marked this conversation as resolved.
Show resolved Hide resolved
atmospheric modelling and in general an interactive model that makes difficult
problems easy to simulate. Climate models that are user-friendly, trainable,
but also easily extensible will suddenly make many complex
research ideas possible.
milankl marked this conversation as resolved.
Show resolved Hide resolved

![Relative vorticity simulated with the shallow water model in SpeedyWeather.jl.
The simulation used a spectral resolution of T1023 (about 20km) and Float32
milankl marked this conversation as resolved.
Show resolved Hide resolved
arithmetic on an octahedral Clenshaw-Curtis grid [@Hotta2018]. Relative vorticity
is visualised with Matplotlib [@Hunter2007] and Cartopy [@Cartopy] using a
milankl marked this conversation as resolved.
Show resolved Hide resolved
transparent-to-white colormap to mimic the appearance of clouds. Underlain is
milankl marked this conversation as resolved.
Show resolved Hide resolved
NASA's blue marble from June 2004. \label{fig:swm}](swm.png)

# Acknowledgements

We acknowledge contributions from Mosè Giordano, Valentin Churavy, and Pietro Monticone
who have also committed to the SpeedyWeather.jl repository, and the wider Julia community
for help and support. MK acknowledges funding from the
National Science Foundation (Chris please add). MK and TK acknowledge funding from the European Research Council
under the European Union’s Horizon 2020 research and innovation programme for the ITHACA grant (no. 741112).
NCC acknowledges support by the Australian Research Council DECRA Fellowship DE210100749.

# References
Binary file added docs/joss/paper.pdf
Binary file not shown.
Binary file added docs/joss/primitive.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/joss/swm.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.