[GRASS-SVN] r72071 - grass/branches/releasebranch_7_4/scripts/r.fillnulls
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Jan 11 06:25:42 PST 2018
Author: marisn
Date: 2018-01-11 06:25:42 -0800 (Thu, 11 Jan 2018)
New Revision: 72071
Modified:
grass/branches/releasebranch_7_4/scripts/r.fillnulls/r.fillnulls.py
Log:
r.fillnulls: Fix RST segmax/npmin logic. (backport of r72029)
Modified: grass/branches/releasebranch_7_4/scripts/r.fillnulls/r.fillnulls.py
===================================================================
--- grass/branches/releasebranch_7_4/scripts/r.fillnulls/r.fillnulls.py 2018-01-11 13:29:13 UTC (rev 72070)
+++ grass/branches/releasebranch_7_4/scripts/r.fillnulls/r.fillnulls.py 2018-01-11 14:25:42 UTC (rev 72071)
@@ -340,8 +340,11 @@
# Avoid v.surf.rst warnings
if pointsnumber < segmax:
- npmin = pointsnumber + 1
- segmax = pointsnumber
+ use_npmin = pointsnumber
+ use_segmax = pointsnumber * 2
+ else:
+ use_npmin = npmin
+ use_segmax = segmax
# launch v.surf.rst
tmp_rmaps.append(holename + '_dem')
@@ -349,7 +352,7 @@
grass.run_command('v.surf.rst', quiet=quiet,
input=holename, elev=holename + '_dem',
tension=tension, smooth=smooth,
- segmax=segmax, npmin=npmin)
+ segmax=use_segmax, npmin=use_npmin)
except CalledModuleError:
# GTC Hole is NULL area in a raster map
grass.fatal(_("Failed to fill hole %s") % cat)
More information about the grass-commit
mailing list