[GRASS-dev] [GRASS GIS] #2359: r.stream.distance with a large map

GRASS GIS trac at osgeo.org
Tue Jul 8 20:11:59 PDT 2014


#2359: r.stream.distance with a large map
-------------------------------+--------------------------------------------
 Reporter:  hcho               |       Owner:  grass-dev@…              
     Type:  defect             |      Status:  new                      
 Priority:  normal             |   Milestone:  7.1.0                    
Component:  Raster             |     Version:  svn-trunk                
 Keywords:  r.stream.distance  |    Platform:  All                      
      Cpu:  All                |  
-------------------------------+--------------------------------------------

Comment(by hcho):

 I took the liberty to change the type of output maps from FCELL to DCELL
 for a higher precision (r61206). The above code for calculating the
 longest flow path should work now.
 {{{
 r.stream.distance -o stream_rast=outlet direction=drain method=upstream
 distance=flus
 r.stream.distance -o stream_rast=outlet direction=drain method=downstream
 distance=flds
 r.mapcalc expression="flusds=flus+flds"
 eval `r.info -r flusds`
 r.mapcalc expression="lfp=if(flusds>=$max-0.1, flusds, null())"
 }}}

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/2359#comment:1>
GRASS GIS <http://grass.osgeo.org>



More information about the grass-dev mailing list