Skip to content

Conversation

@ryan-cocking-mo
Copy link
Contributor

@ryan-cocking-mo ryan-cocking-mo commented Oct 13, 2025

Ticket: https://metoffice.atlassian.net/browse/EPPT-2721

  • Output categorical cube from contrail class
  • Error checking of input cubes and arrays
  • Unit tests
  • Refactoring of contrails class

@codecov
Copy link

codecov bot commented Oct 13, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (EPPT_2072_contrails_design@862873d). Learn more about missing BASE report.

Additional details and impacted files
@@                      Coverage Diff                      @@
##             EPPT_2072_contrails_design    #2209   +/-   ##
=============================================================
  Coverage                              ?   98.46%           
=============================================================
  Files                                 ?      142           
  Lines                                 ?    14062           
  Branches                              ?        0           
=============================================================
  Hits                                  ?    13846           
  Misses                                ?      216           
  Partials                              ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ryan-cocking-mo ryan-cocking-mo force-pushed the EPPT-2721_contrails_output_categorical_data branch from 353e57a to f584bda Compare October 31, 2025 14:50
@ryan-cocking-mo
Copy link
Contributor Author

Rebased onto EPPT_2072_contrails_design following local vapour pressure calculation fix from ticket: https://metoffice.atlassian.net/browse/EPPT-2784

Copy link
Contributor

@mo-robertneal mo-robertneal left a comment

Choose a reason for hiding this comment

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

The CondensationTrailFormation class runs as expected and the output looks sensible. I plotted the formation cube for a few pressure levels and found a healthy number of 0s, 1s, and 2s. The unit tests all pass and the tests look sensible to me. The only to change suggestions I have are:

  1. Do we need to keep the inherited air_temperature status_flag within the auxiliary coordinate? If not, this could be deleted in the _create_contrail_formation_cube function.
  2. Change 273.15 on L292 to a constant imported from improver.constants.

@ryan-cocking-mo
Copy link
Contributor Author

ryan-cocking-mo commented Nov 4, 2025

The CondensationTrailFormation class runs as expected and the output looks sensible. I plotted the formation cube for a few pressure levels and found a healthy number of 0s, 1s, and 2s. The unit tests all pass and the tests look sensible to me. The only to change suggestions I have are:

1. Do we need to keep the inherited `air_temperature status_flag` within the auxiliary coordinate? If not, this could be deleted in the `_create_contrail_formation_cube` function.

2. Change 273.15 on L292 to a constant imported from `improver.constants`.

I have applied change 2. As for change 1, I do not think this is necessary, as epp_workflows already removes this flag in the temperature_on_pressure_levels diagnostic. See here (an identical diagnostic is present in eppgl_contrails).

Copy link
Contributor

@mo-robertneal mo-robertneal left a comment

Choose a reason for hiding this comment

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

Changes look good to me. Happy to approve.

Copy link
Contributor

@Katie-Howard Katie-Howard left a comment

Choose a reason for hiding this comment

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

I've looked through the code changes and they all look fine to me - there are unit tests which are sensible and they all pass. So I'm happy to approve 👍

@Katie-Howard Katie-Howard merged commit 0a2bc96 into metoppv:EPPT_2072_contrails_design Nov 5, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants