[GRASS-user] Filtering high "outliers" in Landsat reflectance imagery?

Eric Goddard egoddard1010 at gmail.com
Thu Aug 1 08:13:56 PDT 2013

Hi, I need to do the same thing to some WV-2 imagery. I'm using the command

grass.mapcalc("$output = if($input_rast>1.0, 1.0, $input_rast)",
output=wv2_out, input_rast=wv2_in) from python (input and output names
changed for simplicity) but instead of replacing the values greater
than 1 with 1, it replaces them with NaNs.  Is there something wrong
with my mapcalc expession?

On Mon, Jul 29, 2013 at 5:55 PM, Nikos Alexandris
<nik at nikosalexandris.net> wrote:
> Nikos A wrote:
>> > >> Advanced users, may I seek for some recommendation on filtering Landsat
>> > >> reflectance outliers?
> Nikos A (replying to self):
>> > > (Thanks Yann)
>> > > Reflectance is a unit-less ratio, ranging from 0 to 1.0.  So I can
>> > > flatten everything >1.0 to 1.0.
> Markus N:
>> > I would run r.neighbors with a 3x3 or 5x5 moving window and averaging
>> > or likewise. The question is always: are they outliers or data?
>> Wild guessing: too high to be data!?
>> Nikos
> Coming back to this! I think that Markus' suggestion was/is "correct".
> However, at the time of having to decide what to do, I simply flattened them.
> They were only a few though, not a real issue.
> Anyhow, just for completeness an "official" definition of reflectance,  here
> is one copy-pasted from
> <http://landsat.gsfc.nasa.gov/references/glossary.html>:
> --%<---
> reflectance - A measure of the ratio of outgoing to incoming radiation
> calculated by converting a radiometrically calibrated image to an innate
> characteristic of the target being observed.  Calibrated at-satellite spectral
> radiance is converted to unitless reflectance by separating out the
> atmospheric component of the reflective band radiance and assuming that the
> target is a Lambertian reflector, re-radiating incident solar radiation
> equally in all directions. In general, reflectance is a function of incident
> angle of the energy, viewing angle of the sensor, spectral wavelength, and
> bandwidth, and the nature of the object. Also see planetary albedo,
> bidirectional reflectance and atmospheric correction. (Source: Dr. John
> Barker)
> --->%--
> Nikos
> _______________________________________________
> grass-user mailing list
> grass-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user

More information about the grass-user mailing list