[GRASS-SVN] r59333 - grass-addons/grass7/raster/r.basin
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Mar 25 08:30:21 PDT 2014
Author: madi
Date: 2014-03-25 08:30:21 -0700 (Tue, 25 Mar 2014)
New Revision: 59333
Modified:
grass-addons/grass7/raster/r.basin/r.basin.py
Log:
centroid-r.volume and main channel bugs fixed
Modified: grass-addons/grass7/raster/r.basin/r.basin.py
===================================================================
--- grass-addons/grass7/raster/r.basin/r.basin.py 2014-03-25 15:12:47 UTC (rev 59332)
+++ grass-addons/grass7/raster/r.basin/r.basin.py 2014-03-25 15:30:21 UTC (rev 59333)
@@ -110,7 +110,6 @@
r_outlet = prefix+'_r_outlet'
v_outlet = prefix+'_outlet'
v_basin = prefix+'_basin'
- v_centroid1 = prefix+'_centroid1'
v_mainchannel = prefix+'_mainchannel'
v_mainchannel_dim = prefix+'_mainchannel_dim'
v_network = prefix+'_network'
@@ -377,7 +376,6 @@
# Centroid and mean slope
baricenter_slope_baricenter = grass.read_command("r.volume", input = r_slope,
clump = r_basin,
- centroids = v_centroid1,
overwrite = True)
grass.message("r.volume done")
@@ -446,7 +444,7 @@
param_mainchannel = grass.read_command('v.what', map = v_mainchannel,
coordinates = '%s,%s' % (east,north),
distance = 5 )
- tmp = param_mainchannel.split('\n')[8]
+ tmp = param_mainchannel.split('\n')[7]
mainchannel = float(tmp.split()[1]) / 1000 # km
# Topological Diameter
@@ -592,7 +590,6 @@
grass.run_command('g.remove', rast = prefix+'_ord_1_thin', quiet = True)
grass.run_command('g.remove', rast = prefix+'_stream_e_thin', quiet = True)
grass.run_command('g.remove', vect = v_mainchannel_dim+'_point', quiet = True)
- grass.run_command('g.remove', vect = v_centroid1, quiet = True)
grass.run_command('g.remove', vect = v_mainchannel_dim, quiet = True)
grass.run_command('g.remove', vect = v_ord_1, quiet = True)
More information about the grass-commit
mailing list