pytroll / pygac

A python package to read and calibrate NOAA and Metop AVHRR GAC and LAC data
https://pygac.readthedocs.org/
GNU General Public License v3.0
20 stars 27 forks source link

Typos in calibration coefficients #66

Closed carloshorn closed 4 years ago

carloshorn commented 4 years ago

I have written a script to convert PATMOS-x coefficients from tar balls as provided on their official website to PyGAC json files as introduced in #58. After testing the script with the coefficient version which should correspond to the current PyGAC coefficients, I noticed some typos which I would like to correct with a PR.

  1. MetOp-A, channel 3a, slope parameter s1 https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L56-L57 Last value should be 1.224 instead of -0.016 according to metopa coeffs

    0.030    1.224   -0.033      ! ch3a low gain S0,S1,S2
    0.213    1.224   -0.033     ! ch3a high gain S0,S1,S2
  2. NOAA-10, channel 4, non-linear correction parameter b2 https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L214 Second value should be 0.0005882 instead of 0.0005885 according to noaa10 coeffs

    -7.29 5.76 -0.1157  0.0005882  !ch4 nonlinear rad coef (Ns,b0,b1,b2)   (JT) 
  3. NOAA-10, channel 4, space radiance https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L207 Second value should be -7.29 instead of -7.27 according to noaa10 coeffs

    -7.29 5.76 -0.1157  0.0005882  !ch4 nonlinear rad coef (Ns,b0,b1,b2)   (JT) 
  4. NOAA-14, channel 5, measured to effective black body temperature intercept https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L278 Last value should be -0.022171 (negative) (beside the division by the slope, see #57 ) according to noaa14 coeffs

    0.022171    !a1_5
  5. NOAA-17, channel 3b, measured to effective black body temperature intercept https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L352 First value should be 1.7002941 instead of 1.70002941 (too many zeros) (beside the division by the slope, see #57 ) according to noaa17 coeffs

    -1.7002941  !a1_3b
  6. NOAA-6, channel 1, slope parameter s0 https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L101-L102 The first value in each array should be 0.113 instead of 0.133 according to noaa6 coeffs

    0.113    0.900    0.000       ! ch1 low gain S0,S1,S2
    0.113    0.900    0.000      ! ch1 high gain S0,S1,S2
  7. NOAA-6, thermometer 1, PRT parameter d0 https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L109-L113 The second row, first column in array should be 276.659 instead of 277.659 according to noaa6 coeffs

    276.659 0.051275 1.363e-06 0.0 0.0 !PRT1 coefficients 
  8. NOAA-8, channel 3b, measured to effective black body temperature intercept https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L162 First value should be 1.7002941 instead of 1.70002941 (too many zeros) (beside the division by the slope, see #57 ) according to noaa8 coeffs

    -1.7764105  !a1_3b  
  9. TIROS-N, channel 4 and 5, centroid wavenumber https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L92 Second and third value should be 913.05397 instead of 913.0537 according to tirosn coeffs

    913.05397   !nu_4
    ...
    913.05397   !nu_5
  10. TIROS-N, thermometer 1, PRT parameter d0 https://github.com/pytroll/pygac/blob/2d7fbafbf03ae59d14b1fffdd33154358faee139/pygac/calibration.py#L86-L90 The second row, first column in array should be 276.659 instead of 277.659 according to tirosn coeffs

    276.659 0.051275 1.363e-06 0.0 0.0 !PRT1 coefficients 

    I will create a PR, once #58 is merged into master, because I got these differences when comparing the current json files with the one that I produced from the tar ball on the PATMOS-x website.

sfinkens commented 4 years ago

:+1: Nice catches! And very tedious work... Thanks!

mraspaud commented 4 years ago

@abhaydd any comments?

abhaydd commented 4 years ago

Agree with @sfinkens Nice catches and fixes :) Thanks a lot @carloshorn and @mraspaud