Skip to content
Permalink
Browse files
Update SAGA ParameterSelection parameters
  • Loading branch information
nyalldawson authored and alexbruy committed Nov 9, 2017
1 parent ca0b7a2 commit 6ef4557b2b0d4e9ef6cab0f158c57694aae58f9c
Show file tree
Hide file tree
Showing 208 changed files with 402 additions and 402 deletions.
@@ -33,15 +33,15 @@
QgsMessageLog,
QgsProcessingParameterRasterLayer,
QgsProcessingParameterBoolean,
QgsProcessingParameterNumber)
QgsProcessingParameterNumber,
QgsProcessingParameterEnum)
from processing.core.ProcessingConfig import ProcessingConfig
from processing.core.parameters import (getParameterFromString,
ParameterExtent,
ParameterVector,
ParameterTable,
ParameterMultipleInput,
ParameterFixedTable,
ParameterSelection)
ParameterFixedTable)
from processing.core.outputs import (getOutputFromString,
OutputVector,
OutputRaster)
@@ -249,7 +249,7 @@ def processAlgorithm(self, parameters, context, feedback):
for i in range(4):
command += ' -' + self.extentParamNames[i] + ' ' \
+ str(float(values[i]) + offset[i])
elif isinstance(param, (QgsProcessingParameterNumber, ParameterSelection)):
elif isinstance(param, (QgsProcessingParameterNumber, QgsProcessingParameterEnum)):
command += ' -' + param.name() + ' ' + str(param.value)
else:
command += ' -' + param.name() + ' "' + str(param.value) + '"'
@@ -1,11 +1,11 @@
Accumulated Cost
grid_analysis
ParameterSelection|DEST_TYPE|Input Type of Destinations|[0] Point;[1] Grid| 0
QgsProcessingParameterEnum|DEST_TYPE|Input Type of Destinations|[0] Point;[1] Grid|False|0
ParameterVector|DEST_POINTS|Destinations|-1|False
QgsProcessingParameterRasterLayer|DEST_GRID|Destinations|None|False
QgsProcessingParameterRasterLayer|COST|Local Cost|None|False
QgsProcessingParameterRasterLayer|DIR_MAXCOST|Direction of Maximum Cost|None|True
ParameterSelection|DIR_UNIT|Units of Direction|[0] radians;[1] degree| 0
QgsProcessingParameterEnum|DIR_UNIT|Units of Direction|[0] radians;[1] degree|False|0
QgsProcessingParameterNumber|DIR_K|K Factor|QgsProcessingParameterNumber.Double|2.000000|False|None|None
QgsProcessingParameterRasterDestination|ACCUMULATED|Accumulated Cost
QgsProcessingParameterRasterDestination|ALLOCATION|Allocation
@@ -7,6 +7,6 @@ QgsProcessingParameterRasterLayer|CONTROL|Operation Control|None|True
QgsProcessingParameterRasterLayer|CTRL_LINEAR|Linear Flow Control Grid|None|True
QgsProcessingParameterRasterDestination|FLUX|Flux
QgsProcessingParameterRasterDestination|STATE_OUT|State t + 1
ParameterSelection|OPERATION|Operation|[0] accuflux;[1] accucapacityflux / state;[2] accufractionflux / state;[3] accuthresholdflux / state;[4] accutriggerflux / state| 0
QgsProcessingParameterEnum|OPERATION|Operation|[0] accuflux;[1] accucapacityflux / state;[2] accufractionflux / state;[3] accuthresholdflux / state;[4] accutriggerflux / state|False|0
QgsProcessingParameterBoolean|LINEAR|Switch to Linear Flow|True
QgsProcessingParameterNumber|THRES_LINEAR|Threshold Linear Flow|QgsProcessingParameterNumber.Double|0.000000|False|None|None
@@ -2,6 +2,6 @@ Add Grid Values to Points
shapes_grid
ParameterVector|SHAPES|Points|0|False
ParameterMultipleInput|GRIDS|Grids|3|False
ParameterSelection|INTERPOL|Interpolation|[0] Nearest Neighbor;[1] Bilinear Interpolation;[2] Inverse Distance Interpolation;[3] Bicubic Spline Interpolation;[4] B-Spline Interpolation
QgsProcessingParameterEnum|INTERPOL|Interpolation|[0] Nearest Neighbor;[1] Bilinear Interpolation;[2] Inverse Distance Interpolation;[3] Bicubic Spline Interpolation;[4] B-Spline Interpolation
OutputVector|RESULT|Result
AllowUnmatching
@@ -2,6 +2,6 @@ Add Grid Values to Shapes
shapes_grid
ParameterVector|SHAPES|Shapes|-1|False
ParameterMultipleInput|GRIDS|Grids|3|False
ParameterSelection|INTERPOL|Interpolation|[0] Nearest Neighbor;[1] Bilinear Interpolation;[2] Inverse Distance Interpolation;[3] Bicubic Spline Interpolation;[4] B-Spline Interpolation
QgsProcessingParameterEnum|INTERPOL|Interpolation|[0] Nearest Neighbor;[1] Bilinear Interpolation;[2] Inverse Distance Interpolation;[3] Bicubic Spline Interpolation;[4] B-Spline Interpolation
OutputVector|RESULT|Result
AllowUnmatching
@@ -2,4 +2,4 @@ Aggregate
grid_tools
QgsProcessingParameterRasterLayer|INPUT|Grid|None|False
QgsProcessingParameterNumber|SIZE|Aggregation Size|QgsProcessingParameterNumber.Integer|3|False|None|None
ParameterSelection|METHOD|Method|[0] Sum;[1] Min;[2] Max
QgsProcessingParameterEnum|METHOD|Method|[0] Sum;[1] Min;[2] Max
@@ -1,7 +1,7 @@
Analytical Hillshading
ta_lighting
QgsProcessingParameterRasterLayer|ELEVATION|Elevation|None|False
ParameterSelection|METHOD|Shading Method|[0] Standard;[1] Standard (max. 90Degree);[2] Combined Shading;[3] Ray Tracing
QgsProcessingParameterEnum|METHOD|Shading Method|[0] Standard;[1] Standard (max. 90Degree);[2] Combined Shading;[3] Ray Tracing
QgsProcessingParameterNumber|AZIMUTH|Azimuth [Degree]|QgsProcessingParameterNumber.Double|315.0|False|None|None
QgsProcessingParameterNumber|DECLINATION|Declination [Degree]|QgsProcessingParameterNumber.Double|45.0|False|None|None
QgsProcessingParameterNumber|EXAGGERATION|Exaggeration|QgsProcessingParameterNumber.Double|4.0|False|None|None
@@ -2,22 +2,22 @@ Angular Distance Weighted
grid_gridding
ParameterVector|SHAPES|Points|-1|False
ParameterTable|FIELD|Attribute|False
ParameterSelection|TARGET_DEFINITION|Target Grid System|[0] user defined;[1] grid or grid system| 0
QgsProcessingParameterEnum|TARGET_DEFINITION|Target Grid System|[0] user defined;[1] grid or grid system|False|0
QgsProcessingParameterNumber|TARGET_USER_SIZE|Cellsize|QgsProcessingParameterNumber.Double|1.000000|False| 0.000000|None
QgsProcessingParameterNumber|TARGET_USER_XMIN|Left|QgsProcessingParameterNumber.Double|0.000000|False|None|None
QgsProcessingParameterNumber|TARGET_USER_XMAX|Right|QgsProcessingParameterNumber.Double|100.000000|False|None|None
QgsProcessingParameterNumber|TARGET_USER_YMIN|Bottom|QgsProcessingParameterNumber.Double|0.000000|False|None|None
QgsProcessingParameterNumber|TARGET_USER_YMAX|Top|QgsProcessingParameterNumber.Double|100.000000|False|None|None
ParameterSelection|TARGET_USER_FITS|Fit|[0] nodes;[1] cells| 0
QgsProcessingParameterEnum|TARGET_USER_FITS|Fit|[0] nodes;[1] cells|False|0
QgsProcessingParameterRasterLayer|TARGET_TEMPLATE|Target System|None|True
QgsProcessingParameterRasterDestination|TARGET_OUT_GRID|Target Grid
ParameterSelection|SEARCH_RANGE|Search Range|[0] local;[1] global| 0
QgsProcessingParameterEnum|SEARCH_RANGE|Search Range|[0] local;[1] global|False|0
QgsProcessingParameterNumber|SEARCH_RADIUS|Maximum Search Distance|QgsProcessingParameterNumber.Double|1000.000000|False| 0.000000|None
ParameterSelection|SEARCH_POINTS_ALL|Number of Points|[0] maximum number of nearest points;[1] all points within search distance| 0
QgsProcessingParameterEnum|SEARCH_POINTS_ALL|Number of Points|[0] maximum number of nearest points;[1] all points within search distance|False|0
QgsProcessingParameterNumber|SEARCH_POINTS_MIN|Minimum|QgsProcessingParameterNumber.Integer|-1|False| 1|None
QgsProcessingParameterNumber|SEARCH_POINTS_MAX|Maximum|QgsProcessingParameterNumber.Integer|20|False| 1|None
ParameterSelection|SEARCH_DIRECTION|Direction|[0] all directions;[1] quadrants| 0
ParameterSelection|DW_WEIGHTING|Weighting Function|[0] no distance weighting;[1] inverse distance to a power;[2] exponential;[3] gaussian weighting| 1
QgsProcessingParameterEnum|SEARCH_DIRECTION|Direction|[0] all directions;[1] quadrants|False|0
QgsProcessingParameterEnum|DW_WEIGHTING|Weighting Function|[0] no distance weighting;[1] inverse distance to a power;[2] exponential;[3] gaussian weighting|False|1
QgsProcessingParameterNumber|DW_IDW_POWER|Inverse Distance Weighting Power|QgsProcessingParameterNumber.Double|2.000000|False| 0.000000|None
QgsProcessingParameterBoolean|DW_IDW_OFFSET|Inverse Distance Offset|False
QgsProcessingParameterNumber|DW_BANDWIDTH|Gaussian and Exponential Weighting Bandwidth|QgsProcessingParameterNumber.Double|1.000000|False| 0.000000|None
@@ -9,10 +9,10 @@ QgsProcessingParameterNumber|ANN_LAYERS|Number of Layers|QgsProcessingParameterN
QgsProcessingParameterNumber|ANN_NEURONS|Number of Neurons|QgsProcessingParameterNumber.Integer|3|False|1|None
QgsProcessingParameterNumber|ANN_MAXITER|Maximum Number of Iterations|QgsProcessingParameterNumber.Integer|300|False|1|None
QgsProcessingParameterNumber|ANN_EPSILON|Error Change (Epsilon)|QgsProcessingParameterNumber.Double|0.000000|False|0.000000|None
ParameterSelection|ANN_ACTIVATION|Activation Function|[0] Identity;[1] Sigmoid;[2] Gaussian| 1
QgsProcessingParameterEnum|ANN_ACTIVATION|Activation Function|[0] Identity;[1] Sigmoid;[2] Gaussian|False|1
QgsProcessingParameterNumber|ANN_ACT_ALPHA|Function's Alpha|QgsProcessingParameterNumber.Double|1.000000|False|None|None
QgsProcessingParameterNumber|ANN_ACT_BETA|Function's Beta|QgsProcessingParameterNumber.Double|1.000000|False|None|None
ParameterSelection|ANN_PROPAGATION|Training Method|[0] resilient propagation;[1] back propagation| 1
QgsProcessingParameterEnum|ANN_PROPAGATION|Training Method|[0] resilient propagation;[1] back propagation|False|1
QgsProcessingParameterNumber|ANN_RP_DW0|Initial Update Value|QgsProcessingParameterNumber.Double|0.000000|False|None|None
QgsProcessingParameterNumber|ANN_RP_DW_PLUS|Increase Factor|QgsProcessingParameterNumber.Double|1.200000|False|1.010000|None
QgsProcessingParameterNumber|ANN_RP_DW_MINUS|Decrease Factor|QgsProcessingParameterNumber.Double|0.500000|False|0.010000|0.990000
@@ -6,5 +6,5 @@ Hardcoded|-TARGET_DEFINITION 0
QgsProcessingParameterNumber|LEVEL|Resolution|QgsProcessingParameterNumber.Double|1.0|False|0.001|None
Extent TARGET_USER_XMIN TARGET_USER_XMAX TARGET_USER_YMIN TARGET_USER_YMAX
QgsProcessingParameterNumber|TARGET_USER_SIZE|Cellsize|QgsProcessingParameterNumber.Double|100.0|False|None|None
ParameterSelection|TARGET_USER_FITS|Fit|[0] nodes;[1] cells
QgsProcessingParameterEnum|TARGET_USER_FITS|Fit|[0] nodes;[1] cells
QgsProcessingParameterRasterDestination|TARGET_OUT_GRID|Grid
@@ -23,4 +23,4 @@ QgsProcessingParameterRasterDestination|BIO_16|Precipitation of Wettest Quarter
QgsProcessingParameterRasterDestination|BIO_17|Precipitation of Driest Quarter
QgsProcessingParameterRasterDestination|BIO_18|Precipitation of Warmest Quarter
QgsProcessingParameterRasterDestination|BIO_19|Precipitation of Coldest Quarter
ParameterSelection|SEASONALITY|Temperature Seasonality|[0] Coefficient of Variation;[1] Standard Deviation| 1
QgsProcessingParameterEnum|SEASONALITY|Temperature Seasonality|[0] Coefficient of Variation;[1] Standard Deviation|False|1
@@ -13,4 +13,4 @@ QgsProcessingParameterBoolean|TRUNC_PRUNED|Truncate Pruned Trees|True
QgsProcessingParameterNumber|REG_ACCURACY|Regression Accuracy|QgsProcessingParameterNumber.Double|0.010000|False| 0.000000|None
QgsProcessingParameterNumber|WEAK_COUNT|Weak Count|QgsProcessingParameterNumber.Integer|100|False| 0|None
QgsProcessingParameterNumber|WGT_TRIM_RATE|Weight Trim Rate|QgsProcessingParameterNumber.Double|0.950000|False| 0.000000| 1.000000
ParameterSelection|BOOST_TYPE|Boost Type|[0] Discrete AdaBoost;[1] Real AdaBoost;[2] LogitBoost;[3] Gentle AdaBoost| 1
QgsProcessingParameterEnum|BOOST_TYPE|Boost Type|[0] Discrete AdaBoost;[1] Real AdaBoost;[2] LogitBoost;[3] Gentle AdaBoost|False|1
@@ -3,6 +3,6 @@ ta_preprocessor
QgsProcessingParameterRasterLayer|DEM|DEM|None|False
QgsProcessingParameterRasterLayer|STREAM|Streams|None|False
QgsProcessingParameterRasterLayer|FLOWDIR|Flow direction|None|False
ParameterSelection|METHOD|Method|[0] simply decrease cell's value by epsilon;[1] lower cell's value to neighbours minimum value minus epsilon;[2] trace stream network downstream
QgsProcessingParameterEnum|METHOD|Method|[0] simply decrease cell's value by epsilon;[1] lower cell's value to neighbours minimum value minus epsilon;[2] trace stream network downstream
QgsProcessingParameterNumber|EPSILON|Epsilon|QgsProcessingParameterNumber.Double|1.0|False|0.0|None
QgsProcessingParameterRasterDestination|BURN|Processed DEM
@@ -3,5 +3,5 @@ ta_hydrology
QgsProcessingParameterRasterLayer|DEM|Elevation|None|False
QgsProcessingParameterRasterLayer|WEIGHTS|Parameter|None|True
QgsProcessingParameterNumber|WEIGHTS_DEFAULT|Default Weight|QgsProcessingParameterNumber.Double|1.0|False|0.0|None
ParameterSelection|METHOD|Method|[0] Deterministic 8;[1] Multiple Flow Direction
QgsProcessingParameterEnum|METHOD|Method|[0] Deterministic 8;[1] Multiple Flow Direction
QgsProcessingParameterRasterDestination|BALANCE|Cell Balance
@@ -2,6 +2,6 @@ Change Data Storage
grid_tools
QgsProcessingParameterRasterLayer|INPUT|Grid|None|False
QgsProcessingParameterRasterDestination|OUTPUT|Converted Grid
ParameterSelection|TYPE|Data storage type|[0] bit;[1] unsigned 1 byte integer;[2] signed 1 byte integer;[3] unsigned 2 byte integer;[4] signed 2 byte integer;[5] unsigned 4 byte integer;[6] signed 4 byte integer;[7] 4 byte floating point number;[8] 8 byte floating point number| 7
QgsProcessingParameterEnum|TYPE|Data storage type|[0] bit;[1] unsigned 1 byte integer;[2] signed 1 byte integer;[3] unsigned 2 byte integer;[4] signed 2 byte integer;[5] unsigned 4 byte integer;[6] signed 4 byte integer;[7] 4 byte floating point number;[8] 8 byte floating point number|False|7
QgsProcessingParameterNumber|OFFSET|Offset|QgsProcessingParameterNumber.Double|0.000000|False|None|None
QgsProcessingParameterNumber|SCALE|Scale|QgsProcessingParameterNumber.Double|1.000000|False|None|None
@@ -2,6 +2,6 @@ Change Date Format
table_tools
ParameterTable|TABLE|Table|False
ParameterTableField|FIELD|Date Field|TABLE|-1|False
ParameterSelection|FMT_IN|Input Format|[0] dd.mm.yy;[1] yy.mm.dd;[2] dd:mm:yy;[3] yy:mm:dd;[4] ddmmyyyy, fix size;[5] yyyymmdd, fix size;[6] ddmmyy, fix size;[7] yymmdd, fix size;[8] Julian Day
ParameterSelection|FMT_OUT|Output Format|[0] dd.mm.yy;[1] yy.mm.dd;[2] dd:mm:yy;[3] yy:mm:dd;[4] ddmmyyyy, fix size;[5] yyyymmdd, fix size;[6] ddmmyy, fix size;[7] yymmdd, fix size;[8] Julian Day
QgsProcessingParameterEnum|FMT_IN|Input Format|[0] dd.mm.yy;[1] yy.mm.dd;[2] dd:mm:yy;[3] yy:mm:dd;[4] ddmmyyyy, fix size;[5] yyyymmdd, fix size;[6] ddmmyy, fix size;[7] yymmdd, fix size;[8] Julian Day
QgsProcessingParameterEnum|FMT_OUT|Output Format|[0] dd.mm.yy;[1] yy.mm.dd;[2] dd:mm:yy;[3] yy:mm:dd;[4] ddmmyyyy, fix size;[5] yyyymmdd, fix size;[6] ddmmyy, fix size;[7] yymmdd, fix size;[8] Julian Day
OutputTable|OUTPUT|Output
@@ -11,6 +11,6 @@ ParameterTableField|FIN_LUT_MIN|Value|FIN_LUT|-1|False
ParameterTableField|FIN_LUT_MAX|Value (Maximum)|FIN_LUT|-1|False
ParameterTableField|FIN_LUT_NAM|Name|FIN_LUT|-1|False
QgsProcessingParameterBoolean|NOCHANGE |Report Unchanged Classes|True
ParameterSelection|OUTPUT|Output as...|[0] cells;[1] percent;[2] area
QgsProcessingParameterEnum|OUTPUT|Output as...|[0] cells;[1] percent;[2] area
QgsProcessingParameterRasterDestination|CHANGE|Changes
OutputTable|CHANGES|Changes
@@ -1,6 +1,6 @@
Change Grid Values
grid_tools
QgsProcessingParameterRasterLayer|GRID_IN|Grid|None|False
ParameterSelection|METHOD|Replace Condition|[0] Grid value equals low value;[1] Low value < grid value < high value;[2] Low value <= grid value < high value
QgsProcessingParameterEnum|METHOD|Replace Condition|[0] Grid value equals low value;[1] Low value < grid value < high value;[2] Low value <= grid value < high value
ParameterFixedTable|LOOKUP|Lookup Table|3|Low Value;High Value;Replace with|False
QgsProcessingParameterRasterDestination|GRID_OUT|Changed Grid
@@ -2,6 +2,6 @@ Change Time Format
table_tools
ParameterTable|TABLE|Table|False
ParameterTableField|FIELD|Time Field|TABLE|-1|False
ParameterSelection|FMT_IN|Input Format|[0] hh.mm.ss;[1] hh:mm:ss;[2] hhmmss, fix size;[3] hours;[4] minutes;[5] seconds
ParameterSelection|FMT_OUT|Output Format|[0] hh.mm.ss;[1] hh:mm:ss;[2] hhmmss, fix size;[3] hours;[4] minutes;[5] seconds
QgsProcessingParameterEnum|FMT_IN|Input Format|[0] hh.mm.ss;[1] hh:mm:ss;[2] hhmmss, fix size;[3] hours;[4] minutes;[5] seconds
QgsProcessingParameterEnum|FMT_OUT|Output Format|[0] hh.mm.ss;[1] hh:mm:ss;[2] hhmmss, fix size;[3] hours;[4] minutes;[5] seconds
OutputTable|OUTPUT|Output
@@ -3,7 +3,7 @@ ta_channels
QgsProcessingParameterRasterLayer|ELEVATION|Elevation|None|False
QgsProcessingParameterRasterLayer|SINKROUTE|Flow Direction|None|True
QgsProcessingParameterRasterLayer|INIT_GRID|Initiation Grid|None|False
ParameterSelection|INIT_METHOD|Initiation Type|[0] Less than;[1] Equals;[2] Greater than
QgsProcessingParameterEnum|INIT_METHOD|Initiation Type|[0] Less than;[1] Equals;[2] Greater than
QgsProcessingParameterNumber|INIT_VALUE|Initiation Threshold|QgsProcessingParameterNumber.Double|0.0|False|None|None
QgsProcessingParameterRasterLayer|DIV_GRID|Divergence|None|True
QgsProcessingParameterNumber|DIV_CELLS|Tracing: Max. Divergence|QgsProcessingParameterNumber.Integer|10|False|None|None