[GRASS-user] d.polar strange behavior when using MASK

Stefano Costa steko at iosa.it
Fri Oct 5 06:21:51 EDT 2007


> Due to g.parser, you have to actually edit the d.polar script and add -x
> to the first line (in GRASS: edit $GISBASE/scripts/d.polar).
> 
> change:
> #!/bin/sh
> 
> to:
> #!/bin/sh -x

Hi Markus,
sorry I didn't notice your message before.

The complete output is:

[Raster MASK present]
GRASS 6.2.1 (donetta):~ > d.polar map=aspect.5m at PERMANENT undef=0 
eps=built.eps+ '[' -z /usr/lib/grass ']'
+ '[' map=aspect.5m at PERMANENT '!=' @ARGS_PARSED@ ']'
+ exec g.parser /usr/lib/grass/scripts/d.polar map=aspect.5m at PERMANENT 
undef=0 eps=built.eps
+ '[' -z /usr/lib/grass ']'
+ '[' @ARGS_PARSED@ '!=' @ARGS_PARSED@ ']'
++ basename /usr/lib/grass/scripts/d.polar
+ PROG=d.polar
++ which awk
+ '[' '!' -x /usr/bin/awk ']'
+ '[' -n built.eps ']'
+ '[' 0 -eq 1 ']'
+ '[' 0 -eq 1 ']'
+ unset LC_ALL
+ LC_NUMERIC=C
+ export LC_NUMERIC
++ g.tempfile pid=27616
+ TMP=/home/steko/grassdata/donetta/steko/.tmp/cycnus/27616.0
+ '[' 0 -ne 0 ']'
+ '[' -z /home/steko/grassdata/donetta/steko/.tmp/cycnus/27616.0 ']'
+ r.stats -1 aspect.5m at PERMANENT
r.stats:  100%
++ wc -l /home/steko/grassdata/donetta/steko/.tmp/cycnus/27616.0_raw
++ awk '{print $1}'
+ TOTALNUMBER=3354642
+ echo 'Calculating statistics for polar diagram... (be patient)'
Calculating statistics for polar diagram... (be patient)
+ cat /home/steko/grassdata/donetta/steko/.tmp/cycnus/27616.0_raw
+ grep -v '^*$'
+ grep -v '^0$'
+ awk '{printf "%d\n", int($1 + .5)}'
+ sed 's+^360+0+g'

... and it hangs at this point.

Best,
Stefano




More information about the grass-user mailing list