[GRASS-dev] [GRASS-user] i.landsat.toar fails to convert DNs (bands 61 and 62) to temperature for Landsat 7 scene

Nikos Alexandris nik at nikosalexandris.net
Fri May 17 06:46:05 PDT 2013


Nikos wrote:

> > While  i.landsat.toar works just fine with all bands in converting DNs to
> > Radiance/Reflectance (with some method=dos?), it seems, at least in once
> > case (scene LE71840312002041SGS00), it fails to convert bands 61 and 62 in
> > temperature!

> > Same happens (as described below in both G64 and G70).
> > Can anyone confirm or reject?
 
> [deleted stuff]
> 
> Using the old metadata file (in this case: LE71840312002041SGS00_MTLold.txt)
> works fine.
> 
> GRASS 6.4.3svn (wgs84_utm_z34_test):~ > r.info -r B.DOS1.ToCR.61
> min=158.263805493393
> max=338.623091571347
> 
> GRASS 6.4.3svn (wgs84_utm_z34_test):~ > r.info -r B.DOS1.ToCR.62
> min=240.06999848884
> max=322.080084447704
 
> I guess it is a bug (something that got away in latest updates of
> i.landsat.toar towards the newer metadata file).  Will try to check
> further... not today though, deadlines approaching.

This post passed unnoticed.  Currently, newer MTL files contain for 
temperature data file names the following

    RADIANCE_MAXIMUM_BAND_6_VCID_1 = 17.040
    RADIANCE_MINIMUM_BAND_6_VCID_1 = 0.000
    RADIANCE_MAXIMUM_BAND_6_VCID_2 = 12.650
    RADIANCE_MINIMUM_BAND_6_VCID_2 = 3.200
..
    QUANTIZE_CAL_MAX_BAND_6_VCID_1 = 255
    QUANTIZE_CAL_MIN_BAND_6_VCID_1 = 1
    QUANTIZE_CAL_MAX_BAND_6_VCID_2 = 255
    QUANTIZE_CAL_MIN_BAND_6_VCID_2 = 1

as opposed to older MTL files which instruct

    LMAX_BAND61 = 17.040
    LMIN_BAND61 = 0.000
    LMAX_BAND62 = 12.650
    LMIN_BAND62 = 3.200
..
    QCALMAX_BAND61 = 255.0
    QCALMIN_BAND61 = 1.0
    QCALMAX_BAND62 = 255.0
    QCALMIN_BAND62 = 1.0

Can you give me a hint (I want to --at least-- try to understand and maybe fix 
this!) on how to adapt the landsat_met.c file so as to account for 

RADIANCE_MAXIMUM_BAND_6_VCID_%d
RADIANCE_MINIMUM_BAND_6_VCID_%d
QUANTIZE_CAL_MAX_BAND_6_VCID_%d
QUANTIZE_CAL_MIN_BAND_6_VCID_%d

which are in newer MTL files? Or is it to complex for C-ignorants like me?

Thanks, N


More information about the grass-dev mailing list