[GRASS-user] Grass 7.0.0 problem with i.landsat.toar

Nikos Alexandris nik at nikosalexandris.net
Wed May 6 02:40:09 PDT 2015


* ΚΑΤΕΡΙΝΑ - ΚΑΡΟΛΙΝΑ ΚΑΡΑΠΑΝΟΥ <kk_karapanou at hotmail.com> [2015-05-06 11:41:52 +0300]:

> Hello, 

Welcome Karolina :-)


> I have a Landsat TM image (2007) and I work in Windows 7 using Grass 7.0.0.
> In my first preprocessing step, I decided to convert DN to Top-of-Atmosphere Radiance using the module from GUI i.landsat.toar.
> Beginning with band B3, I used in the Base name of input raster maps the band B3 from the mapset I work, and in the Prefix for output raster maps the same name with toar in the end.

One thing that deserves clarification is that the module i.landsat.toar
is not designed to work for individual bands. It will work for all bands
at once.  This is why the parameter "input=" accepts the "basename" of
Landsat bands.

If the Landsat bands in question are imported in a mapset properly, and
they are named like B1, B2, ..., B7, then, the basename is obviously the
character "B".

This is what needs to be fed into the "input" parameter.

> In the tab Matadata, I upload the MTL.txt, in the Spacecraft sector I chose tm5 and finally in the tab Optional I chose the -r flag in order to have radiance values.

That seems all right.

> I don't know if that helps, however the command that appears is:
> i.landsat.toar -r input=b3cc at tm2007 output=b3cctoar metfile=C:/Users/User/Desktop/thessaloniki/2007tm/thessaloniki2007tm/LT51840322007175MOR00_MTL.txt sensor=tm5
> Calculating....
> ERROR: Unable to open header file for raster map <b3cc at tm20071@>

Of course it helps.  In fact, it wouldn't be easy to understand what you
are trying to do and why it fails if the exact command in not known.

So, I would recommend to adjust your command so as to look like:

--%<---
i.landsat.toar input=B output=test
metfile=cell_misc/L5183033_03320070516_MTL.txt -r --o
--->%--

This is just a quick test I just ran locally.  For your data, maybe you
only need to correct the "input=" parameter, ie make it "input=b" if
this is the basename.  In any case, if you have names like b1cc, b2cc,
b3cc, etc., I think that the module will never work as expected.

Best of success, Nikos


More information about the grass-user mailing list