+
+
+
+
+
NAME
-
NOTES
+
r.slopeunits is a GRASS GIS addon toolset that creates, cleans
+and calculate metrics for slope units. Additionally, optimal input values can
+be determined.
-
EXAMPLE
+
KEYWORDS
+
+
DESCRIPTION
+The
r.slopeunits toolset consists of currently four modules:
-
SEE ALSO
+
AUTHORS
+Main authors: Ivan Marchesini, Massimiliano Alvioli, CNR-IRPI
+
+Markus Metz (translation to python, refactoring), Carmen Tawalika (translation to python, refactoring),
+
mundialis
diff --git a/r.slopeunits.metrics/r.slopeunits.metrics.html b/r.slopeunits.metrics/r.slopeunits.metrics.html
index cd1e54e..705b6bf 100644
--- a/r.slopeunits.metrics/r.slopeunits.metrics.html
+++ b/r.slopeunits.metrics/r.slopeunits.metrics.html
@@ -1,9 +1,31 @@
DESCRIPTION
+
r.slopeunits.metrics creates metrics for slope units. Returns
+output "areamin, cvmin, v_fin and i_fin" to stdout, optionally writes to a file.
NOTES
EXAMPLE
+
+r.slopeunits.metrics \
+ basin=basin_chk \
+ demmap=dem_italia_isolegrandi@su_test \
+ slumapclean=su_tmp_cl \
+ cleansize=25000 \
+ areamin=50000.0 \
+ cvmin=0.05 \
+ resolution=625 \
+ outfile=objf_1.dat
+
+
SEE ALSO
+
+ r.slopeunits.create,
+ r.slopeunits.clean,
+ r.slopeunits.optimize
+
AUTHORS
+Main authors: Ivan Marchesini, Massimiliano Alvioli, CNR-IRPI
+
+Carmen Tawalika (translation to python),
mundialis
diff --git a/r.slopeunits.metrics/r.slopeunits.metrics.py b/r.slopeunits.metrics/r.slopeunits.metrics.py
index db5c675..1d6b34d 100644
--- a/r.slopeunits.metrics/r.slopeunits.metrics.py
+++ b/r.slopeunits.metrics/r.slopeunits.metrics.py
@@ -3,8 +3,9 @@
############################################################################
#
# MODULE: r.slopeunits.metrics for GRASS 8
-# AUTHOR(S): Ivan Marchesini, Massimiliano Alvioli
-# PURPOSE: To create a raster layer of slope units
+# AUTHOR(S): Ivan Marchesini, Massimiliano Alvioli, Carmen Tawalika
+# (Translation to python)
+# PURPOSE: Create metrics for slope units
# COPYRIGHT: (C) 2004-2024 by the GRASS Development Team
#
# This program is free software under the GNU General Public
@@ -29,13 +30,13 @@
# %option G_OPT_R_INPUT
# % key: demmap
# % description: Input digital elevation model
-# % required : yes
+# % required: yes
# %end
# %option G_OPT_R_OUTPUT
# % key: slumapclean
# % description: Output Slope Units layer, cleaned (the main output)
-# % required : yes
+# % required: yes
# %end
# %option
@@ -50,27 +51,27 @@
# % key: areamin
# % type: double
# % description: Minimum area (m^2) below which the slope unit is not further segmented
-# % required : yes
+# % required: yes
# %end
# %option
# % key: cvmin
# % type: double
# % description: Minimum value of the circular variance (0.0-1.0) below which the slope unit is not further segmented
-# % required : yes
+# % required: yes
# %end
# %option
# % key: resolution
# % type: double
# % description: Resolution
-# % required : yes
+# % required: yes
# %end
# %option G_OPT_F_OUTPUT
# % key: outfile
# % description: Output file with metrics
-# % required : no
+# % required: no
# %end
import atexit
diff --git a/r.slopeunits.optimize/r.slopeunits.optimize.html b/r.slopeunits.optimize/r.slopeunits.optimize.html
index cd1e54e..30fc193 100644
--- a/r.slopeunits.optimize/r.slopeunits.optimize.html
+++ b/r.slopeunits.optimize/r.slopeunits.optimize.html
@@ -1,9 +1,42 @@
DESCRIPTION
+
r.slopeunits.optimize determines optimal input values for slope units:
+
+-
+"areamin" - Minimum area (m^2) below which the slope unit is not further segmented
+
+-
+"cvmin" - Minimum value of the circular variance (0.0-1.0) below which the slope unit is not further segmented
+
+
+It calls
r.slopeunits.create,
r.slopeunits.clean and
r.slopeunits.metrics iteratively.
+Output is a file
opt.txt with optimal values in either specified folder or in folder
output/"
+in the current working directory. Also files
calcd.dat and
current.txt are created with
+all determined and examined values and the four latest examined values (combination of
areamin
+and cvmin minimum and maximum) and center respectively.
NOTES
EXAMPLE
+
+r.slopeunits.optimize \
+ basin=basin_chk \
+ demmap=dem_italia_isolegrandi@su_test \
+ plainsmap=flat \
+ thresh=250000 \
+ rf=2 \
+ maxiteration=50 \
+ cleansize=25000
+
+
SEE ALSO
+
+ r.slopeunits.create,
+ r.slopeunits.clean,
+ r.slopeunits.metrics
+
AUTHORS
+Main authors: Ivan Marchesini, Massimiliano Alvioli, CNR-IRPI
+
+Carmen Tawalika (translation to python, refactoring), mundialis
diff --git a/r.slopeunits.optimize/r.slopeunits.optimize.py b/r.slopeunits.optimize/r.slopeunits.optimize.py
index 9498e2c..cb3e846 100644
--- a/r.slopeunits.optimize/r.slopeunits.optimize.py
+++ b/r.slopeunits.optimize/r.slopeunits.optimize.py
@@ -4,7 +4,8 @@
#
# MODULE: r.slopeunits.optimize for GRASS 8
# AUTHOR(S): Ivan Marchesini, Massimiliano Alvioli, Carmen Tawalika
-# PURPOSE: Calculate metrics for slope units
+# (Translation to python, Refactoring)
+# PURPOSE: Optimize inputs for slope units
# COPYRIGHT: (C) 2004-2024 by the GRASS Development Team
#
# This program is free software under the GNU General Public
@@ -23,13 +24,13 @@
# %option G_OPT_R_INPUT
# % key: demmap
# % description: Input digital elevation model
-# % required : yes
+# % required: yes
# %end
# %option G_OPT_R_INPUT
# % key: plainsmap
# % description: Input raster map of alluvial plains
-# % required : yes
+# % required: yes
# %end
# %option G_OPT_V_INPUT
@@ -41,14 +42,14 @@
# %option G_OPT_R_OUTPUT
# % key: slumap
# % description: Slope Units layer (the main output of r.slopeunits.create)
-# % required : yes
+# % required: yes
# % answer: su_tmp
# %end
# %option G_OPT_R_OUTPUT
# % key: slumapclean
# % description: Slope Units layer, cleaned (the main output of r.slopeunits.clean)
-# % required : no
+# % required: no
# % answer: su_tmp_cl
# %end
@@ -56,21 +57,21 @@
# % key: thresh
# % type: double
# % description: Initial threshold (m^2)
-# % required : yes
+# % required: yes
# %end
# %option
# % key: rf
# % type: integer
# % description: Factor used to iterativelly reduce initial threshold
-# % required : yes
+# % required: yes
# %end
# %option
# % key: maxiteration
# % type: integer
# % description: maximum number of iteration to do before stopped
-# % required : yes
+# % required: yes
# %end
# %option
@@ -86,9 +87,9 @@
# % type: double
# % answer: 0.05,0.25
# % description: Start search with these initial minimum and maximum values of the circular variance (0.0-1.0) below which the slope unit is not further segmented
-# % multiple : no
-# % key_desc : min,max
-# % required : yes
+# % multiple: no
+# % key_desc: min,max
+# % required: yes
# %end
# %option
@@ -96,9 +97,9 @@
# % type: double
# % answer: 50000.0,200000.0
# % description: Start search with these initial minimum and maximum values of the area (m^2) below which the slope unit is not further segmented
-# % multiple : no
-# % key_desc : min,max
-# % required : yes
+# % multiple: no
+# % key_desc: min,max
+# % required: yes
# %end
# %option