foua-pps / level1c4pps

module to create level1c input files to PPS using satpy
GNU General Public License v3.0
3 stars 11 forks source link

Update MSG-4 visible calibration coefficients #81

Closed sfinkens closed 10 months ago

sfinkens commented 1 year ago

Update MSG-4 visible calibration coefficients to latest version from May 2023: https://msgcpp.knmi.nl/solar-channel-calibration.html

Edit 1

For some reason creating the conda environment on macos failed (see https://github.com/foua-pps/level1c4pps/actions/runs/5785938956):

ImportError: dlopen(...libmambapy/bindings.cpython-311-darwin.so, 0x0002): Library not loaded:
...
Error: The process '/Users/runner/miniconda3/condabin/mamba' failed with exit code 1

Switching to mambaforge seems to solve the problem.

Edit 2

Now creating the conda env with Python-3.8 takes forever...

I noticed some warnings about deprecated node 12 (https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/) so I updated actions/checkout and codecov/codecov-action to version 3. But that doesn't speed things up...

codecov-commenter commented 1 year ago

Codecov Report

Merging #81 (1c8cc0f) into main (1ed7063) will not change coverage. The diff coverage is n/a.

@@           Coverage Diff           @@
##             main      #81   +/-   ##
=======================================
  Coverage   77.61%   77.61%           
=======================================
  Files          21       21           
  Lines        1452     1452           
  Branches      107      120   +13     
=======================================
  Hits         1127     1127           
  Misses        301      301           
  Partials       24       24           
Flag Coverage Δ
unittests 77.61% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
level1c4pps/calibration_coefs.py 100.00% <ø> (ø)
level1c4pps/tests/test_seviri2pps.py 96.76% <ø> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

ninahakansson commented 1 year ago

Can we just remove support for python 3.8? Or do you still need to run level1c4pps for python-3.8?

sfinkens commented 1 year ago

Can we just remove support for python 3.8? Or do you still need to run level1c4pps for python-3.8?

Forwarding this to @yeigenbrodt :slightly_smiling_face:

yeigenbrodt commented 1 year ago

Can we just remove support for python 3.8? Or do you still need to run level1c4pps for python-3.8?

I see no reason to support 3.8.

sfinkens commented 1 year ago

I simplified the satpy version requirement a little (> 0.41), which speeds up the build a bit:

OS Python Build time old [min] Build time new [min]
ubuntu 3.9 inf 22
ubuntu 3.10 116 11
ubuntu 3.11 13 3
macos 3.9 inf 46
macos 3.10 37 22
macos 3.11 14 8

So at least from the Python-3.11 jobs you get a quick feedback. But 46 minutes for Python-3.9 is way too long... Any idea how to speed this up?

mraspaud commented 1 year ago

I see this is already using mamba, which I was going to suggest. I'm very surprised it takes such a long time with mamba though... As for ways to improve this, maybe the requirements file should be trimmed down? Satpy has hard requirements on pyresample, dask and xarray at least, so these can go.

sfinkens commented 1 year ago

As for ways to improve this, maybe the requirements file should be trimmed down?

That helped a lot! Now at 6 minutes max :slightly_smiling_face:

@ninahakansson From my point of view this is ready to merge now.