[GRASS5] d.what.rast & quantization

Markus Neteler neteler at itc.it
Sun Feb 27 17:18:32 EST 2005


On Sun, Feb 27, 2005 at 05:19:50PM -0500, Helena wrote:
> Markus,
> 
> is elev the result of v.surf.rst (or s.surf.rst)?
> If yes, this seems to be rst problem - Susane Rizzolli has already reported 
> it.

Ah, didn't know that. Yes, it's v.surf.rst from current CVS.
Thanks for your quick reply.

> If you multiply the result by 1.0 in r.mapcalc, the quant is recomputed
> and the result of query is correct.
> 
> rst calls quantize here - I did not have time to look at what quantize
> actually does  and why are the min and max values done like this,
> rst was updated for FP support while FP support was still under development
> so quant might have changed and this is now producing wrong result.
> G_quantize_fp_map_range (params->elev, mapset,
>                              (DCELL) zminac - 0.5, (DCELL) zmaxac + 0.5,
>                            (CELL) (zminac - 0.5), (CELL) (zmaxac + 0.5));
> It might have been there for years, but nobody is probably using the quant 
> result, so there were no compliants

Would be nice to get it fixed. Maybe Glynn with his insights has
a suggestion?

Markus


> Helena
> 
> 
> Markus Neteler wrote:
> >Hi,
> >
> >looking at d.what.rast, I see output like this:
> >
> >d.what.rast
> >
> >Buttons
> > Left:  what's here
> > Right: quit
> >
> >278786.03515625(E) 5232741.95078125(N)
> >elev in PERMANENT, quant   (447)
> >elev in PERMANENT, actual  (447.190521)
> >
> >279031.25390625(E) 5233060.73515625(N)
> >elev in 5(E) 5232741.95078125(N)
> >elev in PERMANENT, quant   (447)
> >elev in PERMANENT, actual  (447.190521)
> >
> >279031.25390625(E) 5233060.73515625(N)
> >elev in PERMANENT, quant   (539)
> >elev in PERMANENT, actual  (540.034363)
> >
> >278700.20859375(E) 5235660.05390625(N)
> >elev in PERMANENT, quant   (-557)
> >elev in PERMANENT, actual  (-558.007324)
> >
> >The quantization rule is not obvious to me, what's the
> >background to get such results?
> >
> >Thanks
> >




More information about the grass-dev mailing list