Skip to content

Latest commit

Β 

History

103 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

CODECHECK certificate 2026-022

This is the CODECHECK repository for the publication: Can we achieve significant climate mitigation by optimising only for contrails?. The code used to generate the figures of the publication is available via the Technische Universiteit Delft (TU Delft) GitLab with a DOI from the 4TU.ResearchData archive:

TU Delft GitLab Repository: https://gitlab.tudelft.nl/jsmretschnig/jecats-paper-climate-mitigation
4TU.ResearchData Repository: https://doi.org/10.4121/cbdafa47-709d-45da-86e1-7fed28ec3582 DOI not yet active

This CODECHECK repository is a clone of the author's TU Delft GitLab repository associated with the publication. The CODECHECK report is published in Zenodo (https://doi.org/10.5281/zenodo.21932994).

Summary

All figures of the related publication were reproduced. The figures are generated by Jupyter notebooks. In order to reproduce the figures, two datasets are necessary. One dataset has been published by the author (DOI not yet active, awaiting acceptance at the 4TU.ResearchData). The other dataset is already public data. Regarding the code, the notebooks require an extension that is available upon request (not distributed within the code repository) and a visualization code already open-source available via GitHub.

The repository contains 17 Jupyter notebooks, from which 16 reproduce the figures of the related publication. One Jupyter notebook corresponds to a pipeline users can adapt to perform the same processing pipeline on a high-performance-computer (HPC) with their own datasets. This CODECHECK refers only to the notebooks reproducing the figures of the related publication (incl. the appendixes).

Preparation steps

The codecheck was performed in Windows 11 Enterprise (OS: Windows 11 Enterprise 24H2 (x86_64)) and Git Bash (git version 2.49.0.windows.1), within VSCode (version 1.128.0 user setup) using python 3.11.15 and IPython 9.16.1. All notebooks were run with CPU Processor: Intel(R) Core(TM) i7-10610U @ 1.80 GHz.

The author provides detailed instructions for reproducing the figures, including a list of dependencies and guidance on how to install them (the repository provides a pyproject.toml).

The codechecker followed the directory structure suggested in the top-level README file, and placed the necessary datasets in a ./data/ directory and created a ./figures/ folder. Consequently, no modifications to the file paths in the notebooks were necessary. All figures generated during the codechecking procedure are stored in ./figures/.

In order to reproduce the figures, pycontrails-bada 0.7.7 and sankey.py are required. Both are not distributed in the code repository. Instructions on how to request access to pycontrails-bada 0.7.7 are specified in the README. In order to perform the CODECHECK, the codechecker got access to it. NOTE: The repository's pyproject.toml specifies pycontrails[complete]>=0.54.11. During the CODECHECK, this dependency was resolved to pycontrails 0.63.3. From pycontrails 0.63.3 changelog it is mentioned that DEFAULT_LOAD_FACTOR was removed. However pycontrails-bada 0.7.7 still imports it. As a result, running pycontrails-bada 0.7.7 with pycontrails 0.63.3 produces an import error. The codechecker then had to comment out line 22 of .venv/Lib/site-packages/pycontrails_bada/bada_model.py which imports DEFAULT_LOAD_FACTOR.

Regarding sankey.py, the author refers to the original repository where it can be downloaded from (pySankey) and specifies what needs to be commented out to reproduce Figure 9.

Reproducing Results

The notebooks have the instructions to print the figures in a ./figures/ directory. The figures themselves are not distributed in the repository, but are plotted within the Jupyter notebooks themselves.

In order to carry out the CODECHECK, the ./figures/ directory is distributed in this repository.

Default outputs

All figures were reproduced and can be found in ./figures/.

Only Figure 1 had issues when running the notebook. When running the notebook ./notebooks/figure-01.ipynb two issues appeared:

  1. The notebook displayed and printed only panels b and c. Not panel a.
  2. The numbers displayed at the top of the bars of panel b were different than in the related publication. It is important to note that the bar plot itself is identical to the one shown in the related publication; only the numerical labels above the bars differ.

After inspection:

  • point 1) ended up being an issue with CartoPy's interaction with matplotlib (not an issue with the calculations).
  • Point 2) resulted from a mistake in the logic of the instructions, and affected only the presentation of the figure (i.e. its graphical display), and not to its content (the values of the bar plots).

Hence after fixes (see the Zenodo report) Figure 1 was reproduced. The modified notebook is ./notebooks/[CODECHECK]figure-01.ipynb and the resulting figure is ./figures/[CODECHECK]fig01.png.

Codechecker

Contrail Avoidance Non-CO2 Evaluation (CANE)

This repository provides a Python pipeline for quantifying the net climate benefit of contrail avoidance accounting for the climate effects of CO${2}$, contrails, NO${x}$ and H$_{2}$O.

The pipeline is demonstrated through a real-world case study, analyzing 4112 flights traversing the Borealis region (Northern Europe) in 2023 published in Smretschnig et al. (2026) (see How to cite this repository). This repository contains Jupyter notebooks that reproduce the figures presented in Smretschnig et al. (2026). The data related to this case study has also been released publicly via the 4TU.ResearchData archive (see How to cite this repository).

Keywords: Sustainable aviation - Contrails - Contrail avoidance - Climate optimised trajectories - aCCF - CoCiP - pycontrails - Aerospace engineering

Funding: The project has been funded by CONCERTO under the SESAR 3 Joint Undertaking (Grant ID 101114785).

Author(s)

License

License: MIT

The contents of this repository are licensed under a MIT license (see ./LICENSE.txt file).

Copyright notice:

Technische Universiteit Delft hereby disclaims all copyright interest in the program "Contrail Avoidance Non-CO2 Evaluation CANE" written by the Author(s). Henri Werij, Faculty of Aerospace Engineering, Technische Universiteit Delft.

Β© 2026, J. Smretschnig

Requirements

πŸ“¦ Installation

Clone the repository:

git clone git@gitlab.tudelft.nl:jsmretschnig/jecats-paper-climate-mitigation.git
cd jecats-paper-climate-mitigation

Create a virtual environment and activate it:

uv venv --python 3.11
source .venv/bin/activate   # or .venv/Scripts/activate on Windows

Install in editable mode:

uv pip install -e .

Activate the environment again and check if pip and uv point to the same .venv directory:

source .venv/bin/activate # .venv/Scripts/activate on Windows
which pip  # should point to .venv/bin/pip (Unix) or .venv/Scripts/pip (Windows)

Install pycontrails-bada 0.7.7 with pip. Be aware this is a private extension for which access must be requested at info@contrails.org. Once access is provided, follow the instructions specified in its documentation.

Once the installation is complete, run the ./notebooks/figure-*.ipynbnotebooks in numerical order to reproduce the figures presented in the related article. In order to run the notebooks:

  • download the related data from the 4TU.ResearchData archive (see How to cite this repository) and store it in a data directory located at the root (top-level) directory of this repository.
  • Download ERA5 tropopause data from FZ JΓΌlich (https://doi.org/10.26165/JUELICH-DATA/UBNGI2 [3]) and store in a ./data/juelich directory. Keep in mind: this dataset is large in size (~1.4 GB per file). The notebook ./notebooks/Figure-06.ipynb uses only part of the dataset to reproduce the figure 6 of the related paper.
  • Modify the paths at the beginning of the notebooks accordingly if not using the default data locations suggested above (the default file paths are configured to look for data inside a folder named data located at the root (top-level) directory of the repository).
  • Create a ./figures folder which is where the plots generated by the notebooks will be saved as png files.
  • The notebook ./notebooks/figure-09.ipynb requires the sankey.py module, which is not included in this repository. To obtain it:
    • clone or download the pySankey repository.
    • Copy the pySankey/pysankey/sankey.py module (version commit 811a638) to your ./src/cane/ directory.
    • Apply the following modifications: comment out lines 123--126 (i.e. do not run the check_data_matches_labels() function for right labels)

To apply the pipeline to a different dataset, run ./notebooks/pipeline.ipynb.

Reminder: When using VS Code, make sure to select the venv's Python interpreter: Open the command palette (Cmd+Shift+P / Ctrl+Shift+P) β†’ Python: Select Interpreter β†’ choose the one pointing to .venv/bin/python (Unix) or .venv/Scripts/python (Windows).

File Overview

.
β”œβ”€β”€ CITATION.cff
β”œβ”€β”€ LICENSE.txt
β”œβ”€β”€ README.md
β”œβ”€β”€ notebooks
β”‚Β Β  β”œβ”€β”€ figure-*.ipynb  
β”‚Β Β  └── pipeline.ipynb
β”œβ”€β”€ pyproject.toml
β”œβ”€β”€ scripts
β”‚Β Β  β”œβ”€β”€ run_accfs.py
β”‚Β Β  └── run_cocip.py
└── src
    └── cane
        β”œβ”€β”€ airspaces
        β”‚Β Β  β”œβ”€β”€ borealis.py
        β”‚Β Β  └── static
        β”‚Β Β      └── Borealis_airspaces.json
        β”œβ”€β”€ colors.py
        β”œβ”€β”€ constants.py
        β”œβ”€β”€ labels.py
        β”œβ”€β”€ metrics
        β”‚Β Β  β”œβ”€β”€ __init__.py
        β”‚Β Β  β”œβ”€β”€ metrics.py
        β”‚Β Β  └── static
        β”‚Β Β      └── dahlmann-2025.csv
        β”œβ”€β”€ models
        β”‚Β Β  β”œβ”€β”€ accf.py
        β”‚Β Β  β”œβ”€β”€ aircraft_performance.py
        β”‚Β Β  β”œβ”€β”€ cocip.py
        β”‚Β Β  └── era5.py
        └── utils.py

The ./notebooks folder contains the Jupyter notebooks that reproduce the figures of Smretschnig et a. (2026). More specifically:

  • figure-*.ipynb: each notebook reproduces one figure of the related article.
  • pipeline.ipynb: notebook with the processing pipeline, from aircraft performance to climate models on a high-performance-computer (HPC).

The ./scripts folder contains Bash scripts to run aCCFs and CoCiP on a High-Performance-Computer (HPC), such as DelftBlue.

The ./src folder contains the functions used by the pipeline. More specifically:

  • ./cane/airspaces/*: functions to visualize the boundaries of the Borealis airspaces.
  • ./cane/metrics/*: computation of the climate effect using different climate metrics.
  • ./cane/models/accf.py: computation of algorithmic Climate Change Functions (aCCFs) for CO2, NOx, and H2O.
  • ./cane/models/aircraft_performance.py: computation of fuel consumption with BADA3.
  • ./cane/models/cocip.py: helper functionalities for the CoCiP configuration.
  • ./cane/models/era5.py: functionality to download meteorological data from ERA5.
  • ./cane/utils.py: helper functionalities regarding coloring, constants, friendly names, haul-type classification, etc.

How to cite this repository

When using this repository please cite this code repository, the related data repository and the related article. You can do so either using the ./CITATION.CFF file or by using the following information:

Code repository

J. Smretschnig, 2026, Contrail Avoidance Non-CO2 Evaluation (CANE). 4TU.ResearchData. Software. https://doi.org/10.4121/cbdafa47-709d-45da-86e1-7fed28ec3582

Data repository

Smretschnig, Jakob; ClΓ©ment, JoΓ«l; NΓΊΓ±ez Arribas, Sergio (2026): Filed and contrail-optimised flight trajectories in Northern Europe. Version 1. 4TU.ResearchData. Dataset. https://doi.org/10.4121/16ec2954-a493-41c8-b3f9-f17e9331c46b

Article

Smretschnig, J., Yin, F., Piontek, D., ClΓ©ment, J., NΓΊΓ±ez Arribas, S., Dahlmann, K., Castino, F., and Grewe, V.: Can we achieve significant climate mitigation by optimising only for contrails?, J. Env. Com. Air Transp. Sys. Discuss. [preprint], https://doi.org/10.5194/jecats-2026-13, in review, 2026.

References

Datasets

[1] Copernicus Climate Change Service, Climate Data Store, (2023): ERA5 hourly data on pressure levels from 1940 to present. Copernicus Climate Change Service (C3S) Climate Data Store (CDS). DOI: 10.24381/cds.bd0915c6

[2] Copernicus Climate Change Service, Climate Data Store, (2023): ERA5 hourly data on single levels from 1940 to present. Copernicus Climate Change Service (C3S) Climate Data Store (CDS). DOI: 10.24381/cds.adbb2d47

[3] Hoffmann, L. and R. Spang, Reanalysis Tropopause Data Repository, DOI: 10.26165/JUELICH-DATA/UBNGI2, JΓΌlich DATA, V1, 2021.

Other

algorithmic Climate Change Function (aCCF)

[4] Van Manen, J., and V. Grewe. β€œAlgorithmic Climate Change Functions for the Use in Eco-Efficient Flight Planning.” Transportation Research Part D: Transport and Environment 67 (February 2019): 388–405. https://doi.org/10.1016/j.trd.2018.12.016

[5] Yin, Feijia, Volker Grewe, Federica Castino, et al. β€œPredicting the Climate Impact of Aviation for En-Route Emissions: The Algorithmic Climate Change Function Submodel ACCF 1.0 of EMAC 2.53.” Geoscientific Model Development 16, no. 11 (2023): 3313–34. https://doi.org/10.5194/gmd-16-3313-2023

[6] DietmΓΌller, Simone, Sigrun Matthes, Katrin Dahlmann, et al. β€œA Python Library for Computing Individual and Merged Non-CO 2 Algorithmic Climate Change Functions: CLIMaCCF V1.0.” Geoscientific Model Development 16, no. 15 (2023): 4405–25. https://doi.org/10.5194/gmd-16-4405-2023

[7] Matthes, Sigrun, Simone DietmΓΌller, Katrin Dahlmann, et al. β€œUpdated Algorithmic Climate Change Functions (aCCF) V1.0A: Evaluation with the Climate-Response Model AirClim V2.0.” Preprint, Atmospheric sciences, 2023. https://doi.org/10.5194/gmd-2023-92

BADA3

[8] EUROCONTROL. User Manual for the Base of Aircraft Data (BADA) Revision 3.16. EIH Technical/Scientific Report No. 22/05/12-45. EUROCONTROL Experimental Centre (EEC), 2022.

CoCiP

[9] U. Schumann. β€œA Contrail Cirrus Prediction Model.” Geoscientific Model Development 5, no. 3 (2012): 543–80. https://doi.org/10.5194/gmd-5-543-2012.

Conversion factors

[10] Dahlmann, Katrin, Sigrun Matthes, and Volker Grewe. β€œConversion of Climate Metrics for Policy Applications.” Preprint, Zenodo, July 31, 2025. https://doi.org/10.5281/ZENODO.16355781.

FFM2

[11] DuBois, D. and Paynter*, G., "β€œFuel Flow Method2” for Estimating Aircraft Emissions," Non-Conference Specific Technical Papers - 2006, , https://doi.org/10.4271/2006-01-1987.

pyContrails

[12] Shapiro, Marc, Zeb Engberg, Roger Teoh, Marc Stettler, Tom Dean, and Tristan Abbott. Pycontrails: Python Library for Modeling Aviation Climate Impacts. V. v0.54.11. Zenodo, released July 2025. https://doi.org/10.5281/zenodo.16575452.

T4T2

[13] Teoh, Roger, Ulrich Schumann, Edward Gryspeerdt, et al. β€œAviation Contrail Climate Effects in the North Atlantic from 2016–2021.” Atmospheric Chemistry and Physics 22, no. 16 (2022): 10919--10935. https://doi.org/10.5194/acp-22-10919-2022.

[14] Teoh, Roger, Zebediah Engberg, Marc Shapiro, Lynnette Dray, and Marc E. J. Stettler. β€œThe High-Resolution Global Aviation Emissions Inventory Based on ADS-B (GAIA) for 2019–2021.” Atmospheric Chemistry and Physics 24, no. 1 (2024): 725–44. https://doi.org/10.5194/acp-24-725-2024.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages