Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
73 commits
Select commit Hold shift + click to select a range
bd52e61
Initial commit
grafrap Sep 25, 2025
ad47e47
Tracking function 3D first version
grafrap Sep 25, 2025
3413987
first 3d algorithm with data and output
grafrap Sep 29, 2025
9694ab2
Change of peak_local_maxima usage, now use the first slice (next idea…
grafrap Sep 30, 2025
ae06f30
Add of new label functions
grafrap Sep 30, 2025
ecda930
Better test for two clouds
grafrap Oct 1, 2025
a6a9c8a
Add some measurements for first 3d version vs 2d version for later re…
grafrap Oct 7, 2025
3edfdb3
Add of performance measurement. A big part is how functions are calle…
grafrap Oct 9, 2025
cc7b26d
New profiler measurements, we see a major bottleneck in watershed and…
grafrap Oct 9, 2025
1bb7f7d
Add of memory measurements
grafrap Oct 9, 2025
7fe3587
Add considerations for which watershed library to test and compare th…
grafrap Oct 9, 2025
7133814
Add some tries for a scipy and a parallelized algorithm
grafrap Oct 13, 2025
9a1fdbe
Add trys of functions with different algorithms to speed up the water…
grafrap Oct 14, 2025
951dbe1
Add imports and comments on why certain functions are so slow as they…
grafrap Oct 14, 2025
78071f0
Replace dask calls by original calls, here a proper version of the cu…
grafrap Oct 14, 2025
07c30fd
Add lineprof to the main file
grafrap Oct 14, 2025
368a54d
Working parallel version, the watershed method is now a lot faster. (…
grafrap Oct 14, 2025
a0231df
Add first time measurements to get some speedup. Next is to get memor…
grafrap Oct 16, 2025
b35b10e
Add memory profiling
grafrap Oct 16, 2025
dc8c9ca
Add sweeps and max_chunks to results to see which chunk distribution …
grafrap Oct 20, 2025
fbc22c5
Add new measurements for later being able to compare size vs optimal …
grafrap Oct 20, 2025
6c118e6
Add first measurements on Euler and the plots
grafrap Oct 21, 2025
9dc6b7c
Correct for outliers and change order of plots in figure
grafrap Oct 21, 2025
c783156
Add memory overhead plot
grafrap Oct 21, 2025
bb67a00
Add data and analysation of best chunking strategies. Generally if th…
grafrap Oct 21, 2025
795c2aa
Add results also in text
grafrap Oct 21, 2025
f5a998b
Add history calculation and plot of History
grafrap Oct 27, 2025
79a8303
Add idealized tests and outputs
grafrap Oct 29, 2025
07823b2
Add of if statement for analyze_history,
grafrap Oct 30, 2025
a4d5147
Add big dataset measurements and if makes sense.
Nov 10, 2025
aeec030
Add better merge based on around 5 idealized tests, to further test.
grafrap Dec 4, 2025
e796b6a
Tidy up whole repo, put stuff in own folders
grafrap Dec 4, 2025
b90d44f
Better merge logic:
grafrap Dec 4, 2025
66ec0ff
Now better version, which takes a volume to boundary ratio and decide…
grafrap Dec 4, 2025
0a19d75
Improve boundary merging using halo overlap, this is now qualitativel…
grafrap Dec 9, 2025
c4dde73
Remove unnecessary functions and add them to Tracking_Functions_old.py
grafrap Dec 9, 2025
1c01510
Add outputs for different phenomena and with more parallel chunks for…
grafrap Dec 9, 2025
726aca2
Add documentation of all functions
grafrap Dec 9, 2025
c924973
###Commit before refactoring###
grafrap Dec 9, 2025
94fe393
Split of the Tracking_Functions.py file in submodules and more files.
grafrap Dec 9, 2025
c04d1dc
update pyproject.toml for installation (pip error)
grafrap Dec 9, 2025
96ec12d
another update to pyproject.toml, now only add the folder moaap and a…
grafrap Dec 9, 2025
a7d369c
Update the imports and the autoreload
grafrap Dec 9, 2025
20ba00b
Add documentation workflow
grafrap Dec 10, 2025
75fa033
Add Sphinx documentation config
grafrap Dec 10, 2025
f13657a
Update of documentation for the main moaap file
grafrap Dec 10, 2025
a758ed9
Update of readme to include the documentation
grafrap Dec 10, 2025
3ee6bc7
Add tutorial notebook, also try to add to website, but not yet working.
grafrap Dec 11, 2025
4a5ee43
Add of tutorial notebook to the website
grafrap Dec 11, 2025
398af49
Update the workflow script
grafrap Dec 11, 2025
d643e61
Fix tutorial after removing unnecessary files.
grafrap Dec 11, 2025
96ba670
Add tutorial notebook to documentation
grafrap Dec 11, 2025
48962d5
Add new docs file
grafrap Dec 11, 2025
0ee79a4
Add other docs files
grafrap Dec 11, 2025
205e295
Hopefully now it works :)
grafrap Dec 11, 2025
6b0cdde
remove prebuilt files for the website, which were built locally
grafrap Dec 11, 2025
1b9aced
Checkout improved versions of the algorithm from the test branch. Int…
grafrap Jan 8, 2026
d460eeb
Add Documentation for new functions
grafrap Jan 8, 2026
ac8a48f
Update tutorial with new parallel method
grafrap Jan 8, 2026
4969b13
Add new Tracking_Functions file, that raises depricaiton warning and …
grafrap Jan 13, 2026
da0d592
Correct deprication warning in object_props wrt skimage.ndimage.measure
grafrap Jan 13, 2026
0e0b6d3
Tidy up code and remove double label methods. In cyclones.py, the cy_…
grafrap Jan 16, 2026
0386a71
Remove call to 1D version due to time and memory overhead. it Still c…
grafrap Jan 16, 2026
7995b42
Add faster clean_up_objects function
grafrap Jan 16, 2026
089fb8a
Add history analysis for all objects where we do watershedding.
grafrap Jan 19, 2026
ded3790
Update requirements to the newest version
grafrap Jan 19, 2026
32ed363
Update gitignore
grafrap Jan 19, 2026
5301915
Remove bug, now we also see the history for moisture streams
grafrap Jan 19, 2026
492f91b
Fix some bugs with the history analysis and fix bug with jets, remove…
grafrap Jan 20, 2026
1f71647
Minor update in documentation of the watershed method, to include aut…
grafrap Jan 28, 2026
b58319c
Merge remote-tracking branch 'student/main' into integrate-student
Feb 9, 2026
8f1d056
Build and deploy Sphinx docs to GitHub Pages
Feb 9, 2026
d63b875
Fix/update object properties
Feb 9, 2026
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
49 changes: 49 additions & 0 deletions .github/workflows/docs-pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Build & Deploy Docs (GitHub Pages)

on:
push:
branches: [ "main" ]
workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: "pages"
cancel-in-progress: true

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .
pip install sphinx sphinx-rtd-theme

- name: Build Sphinx HTML
run: |
sphinx-build -b html docs docs/_build/html

- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: docs/_build/html

deploy:
runs-on: ubuntu-latest
needs: build
environment:
name: github-pages
steps:
- name: Deploy to GitHub Pages
uses: actions/deploy-pages@v4
46 changes: 46 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Build and Deploy Docs

on:
push:
branches:
- main # Or 'master', depending on your default branch name

permissions:
contents: write

jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Install Pandoc # Required for nbsphinx
run: |
sudo apt-get update
sudo apt-get install -y pandoc libgeos-dev libproj-dev proj-data

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install sphinx sphinx-rtd-theme nbsphinx
pip install . # Installs your 'moaap' package so Sphinx can import it

- name: Build HTML
run: |
cd docs
make html

- name: Create .nojekyll to disable Jekyll processing
run: touch docs/build/html/.nojekyll

- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/build/html
61 changes: 61 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# Prerequisites
*.d

# Compiled Object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
*.gch
*.pch

# Linker files
*.ilk

# Debugger Files
*.pdb

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
*.mod
*.smod

# Compiled Static libraries
*.lai
*.la
*.a
*.lib

# Executables
*.exe
*.out
*.app

# debug information files
*.dwo

__pycache__/
*.pyc

20210701-04_MOAAP-Input_24h.nc
moaap_output/
images/
outputs/synthetic_cells.nc
data_cache/*

Tracking_Functions_old.py

docs/build/
watershed_history*
tracks/
run_3d.py
generate_shim.py
logs/
.vscode
moaap.egg-info
20 changes: 20 additions & 0 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Minimal makefile for Sphinx documentation
#

# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = source
BUILDDIR = build

# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

.PHONY: help Makefile

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
35 changes: 35 additions & 0 deletions docs/make.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
@ECHO OFF

pushd %~dp0

REM Command file for Sphinx documentation

if "%SPHINXBUILD%" == "" (
set SPHINXBUILD=sphinx-build
)
set SOURCEDIR=source
set BUILDDIR=build

%SPHINXBUILD% >NUL 2>NUL
if errorlevel 9009 (
echo.
echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
echo.installed, then set the SPHINXBUILD environment variable to point
echo.to the full path of the 'sphinx-build' executable. Alternatively you
echo.may add the Sphinx directory to PATH.
echo.
echo.If you don't have Sphinx installed, grab it from
echo.https://www.sphinx-doc.org/
exit /b 1
)

if "%1" == "" goto help

%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
goto end

:help
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%

:end
popd
52 changes: 52 additions & 0 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Configuration file for the Sphinx documentation builder.
#
# For the full list of built-in configuration values, see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html

# -- Project information -----------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information

import os
import sys
sys.path.insert(0, os.path.abspath('../../')) # Points to the project root

project = 'MOAAP'
copyright = '2025, Andreas F. Prein, Raphael Graf'
author = 'Andreas F. Prein, Raphael Graf'

# -- General configuration ---------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration

extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.napoleon', # Essential for specific docstring format!
'sphinx.ext.viewcode', # adds links to source code
'nbsphinx', # to include Jupyter Notebooks
]

templates_path = ['_templates']
exclude_patterns = []



# -- Options for HTML output -------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output

html_theme = 'sphinx_rtd_theme'
html_static_path = ['_static']

napoleon_custom_sections = [
('Precipitation objects', 'params_style'),
('Moisture streams', 'params_style'),
('Cyclones & anticyclones', 'params_style'),
('Frontal zones', 'params_style'),
('Cloud tracking', 'params_style'),
('Atmospheric rivers (AR)', 'params_style'),
('Tropical cyclone detection', 'params_style'),
('Mesoscale convective systems (MCS)', 'params_style'),
('Jet streams & tropical waves', 'params_style'),
('500 hPa cyclones/anticyclones', 'params_style'),
('Equatorial waves', 'params_style'),
]

nbsphinx_execute = 'never' # Do not execute notebooks during doc build
22 changes: 22 additions & 0 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
.. MOAAP documentation master file, created by
sphinx-quickstart on Wed Dec 10 11:20:05 2025.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.

Welcome to MOAAP's documentation!
=================================

.. toctree::
:maxdepth: 2
:caption: Contents:

modules
tutorial

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`

87 changes: 87 additions & 0 deletions docs/source/modules.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
MOAAP Reference
===============

Main Interface
--------------

.. automodule:: moaap.main
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.config
:members:
:undoc-members:
:show-inheritance:

Utils
-----
.. automodule:: moaap.utils.constants
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.utils.data_proc
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.utils.grid
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.utils.object_props
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.utils.profiling
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.utils.segmentation
:members:
:undoc-members:
:show-inheritance:


Trackers
--------

.. automodule:: moaap.trackers.atmospheric_rivers
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.trackers.clouds
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.trackers.cyclones
:members:
:undoc-members:
:show-inheritance:


.. automodule:: moaap.trackers.fronts
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.trackers.jets
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.trackers.tropical_cyclones
:members:
:undoc-members:
:show-inheritance:

.. automodule:: moaap.trackers.waves
:members:
:undoc-members:
:show-inheritance:
1 change: 1 addition & 0 deletions docs/source/tutorial.ipynb
6 changes: 6 additions & 0 deletions moaap/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# moaap/__init__.py

from .main import moaap

# Optional: Add version info
__version__ = "1.0.0"
Loading