[GRASS-SVN] r38312 - grass-addons/raster/r.denoise

svn_grass at osgeo.org svn_grass at osgeo.org
Wed Jul 8 08:32:46 EDT 2009


Author: stevensj
Date: 2009-07-08 08:32:46 -0400 (Wed, 08 Jul 2009)
New Revision: 38312

Modified:
   grass-addons/raster/r.denoise/r.denoise
Log:
Minor error message and r.support sections changes

Modified: grass-addons/raster/r.denoise/r.denoise
===================================================================
--- grass-addons/raster/r.denoise/r.denoise	2009-07-08 12:05:47 UTC (rev 38311)
+++ grass-addons/raster/r.denoise/r.denoise	2009-07-08 12:32:46 UTC (rev 38312)
@@ -83,7 +83,7 @@
 # Test that mdenoise is present
 if [ ! -x "`which mdenoise`" ] ; then
 	echo
-	g.message -e "ERROR: mdenoise required.  Follow instructions in html manual page to install it (g.manual r.denoise)." 
+	g.message -e "mdenoise required.  Follow instructions in html manual page to install it (g.manual r.denoise)." 
 	exit 1
 fi
 
@@ -103,8 +103,8 @@
 		exit 1
 	else	# With EPSG code, check that it corresponds to a projected
 		# locality by converting null data in verbose mode.
-		if [ "`echo 0 0 | cs2cs -v +init=epsg:"$EPSG" | grep "+units=" | wc -l`" -eq "0" ] ; then
-			g.message -e "ERROR: EPSG code is not suitable.  A projected coordinate system is required"
+		if [ "`echo 0 0 | cs2cs -v +init=epsg:"$EPSG" | grep -c "+units="`" -eq "0" ] ; then
+			g.message -e "EPSG code is not suitable.  A projected coordinate system is required"
 			exit 1
 		else
 			REPROJECT=1	
@@ -164,7 +164,8 @@
 r.in.xyz "$temp".DN.xyz output="$OUTPUT" fs=space x=1 y=2 z=3 --q
 
 # Edit metadata to record denoising parameters
-r.support "$OUTPUT" title="A denoised version of <$INPUT>" source1="Generated by: r.denoise $INPUT iterations=$ITER threshold=$THRES"
+r.support "$OUTPUT" title="A denoised version of <$INPUT>"   history=""
+r.support "$OUTPUT" history="Generated by: r.denoise $INPUT iterations=$ITER threshold=$THRES"
 
 # Clean up
 \rm "$temp".*



More information about the grass-commit mailing list