mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-13 00:03:09 -04:00
added SAGA watershed segmentation execution test
This commit is contained in:
parent
ad96be96a9
commit
819a82ad54
41
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.mgrd
vendored
Normal file
41
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.mgrd
vendored
Normal file
@ -0,0 +1,41 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<SAGA_METADATA>
|
||||
<HISTORY saga-version="2.3.1">
|
||||
<MODULE library="imagery_segmentation" id="0" name="Watershed Segmentation">
|
||||
<OPTION type="grid_system" id="PARAMETERS_GRID_SYSTEM" name="Grid system">
|
||||
<CELLSIZE>0.0001</CELLSIZE>
|
||||
<XMIN>18.666347944200002</XMIN>
|
||||
<XMAX>18.7035479442</XMAX>
|
||||
<YMIN>45.7767514376</YMIN>
|
||||
<YMAX>45.8116514376</YMAX>
|
||||
</OPTION>
|
||||
<OPTION type="choice" id="OUTPUT" name="Output" index="0">Seed Value</OPTION>
|
||||
<OPTION type="choice" id="DOWN" name="Method" index="0">Minima</OPTION>
|
||||
<OPTION type="choice" id="JOIN" name="Join Segments based on Threshold Value" index="0">do not join</OPTION>
|
||||
<OPTION type="double" id="THRESHOLD" name="Threshold">0.500000</OPTION>
|
||||
<OPTION type="boolean" id="EDGE" name="Allow Edge Pixels to be Seeds">TRUE</OPTION>
|
||||
<OPTION type="boolean" id="BBORDERS" name="Borders">TRUE</OPTION>
|
||||
<INPUT type="grid" id="GRID" name="Grid" system="PARAMETERS_GRID_SYSTEM">
|
||||
<MODULE library="io_gdal" id="0" name="Import Raster">
|
||||
<OPTION type="file" id="FILES" name="Files">"/home/ginetto/PROGRAMMING/QGIS/QGIS-master/python/plugins/processing/tests/testdata/dem.tif"</OPTION>
|
||||
<OPTION type="text" id="SELECTION" name="Select from Multiple Bands"/>
|
||||
<OPTION type="boolean" id="SELECT_SORT" name="Alphanumeric Sorting">TRUE</OPTION>
|
||||
<OPTION type="boolean" id="TRANSFORM" name="Transformation">TRUE</OPTION>
|
||||
<OPTION type="choice" id="RESAMPLING" name="Resampling" index="3">B-Spline Interpolation</OPTION>
|
||||
<OUTPUT type="grid_list" id="GRIDS" name="Grids">dem</OUTPUT>
|
||||
</MODULE>
|
||||
</INPUT>
|
||||
<OUTPUT type="data_object" id="BORDERS" name="Borders"/>
|
||||
</MODULE>
|
||||
</HISTORY>
|
||||
<SOURCE>
|
||||
<FILE>/home/ginetto/PROGRAMMING/QGIS/QGIS-master/python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.sgrd</FILE>
|
||||
<DATABASE></DATABASE>
|
||||
<PROJECTION>
|
||||
<OGC_WKT>GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]</OGC_WKT>
|
||||
<PROJ4>+init=epsg:4326 +proj=longlat +a=6378137.000000 +b=6356752.314245 +no_defs</PROJ4>
|
||||
<EPSG>-1</EPSG>
|
||||
</PROJECTION>
|
||||
</SOURCE>
|
||||
<DESCRIPTION></DESCRIPTION>
|
||||
</SAGA_METADATA>
|
1
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.prj
vendored
Normal file
1
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.prj
vendored
Normal file
@ -0,0 +1 @@
|
||||
GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]
|
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.sdat
vendored
Normal file
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.sdat
vendored
Normal file
Binary file not shown.
@ -0,0 +1,3 @@
|
||||
<PAMDataset>
|
||||
<SRS>GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]</SRS>
|
||||
</PAMDataset>
|
15
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.sgrd
vendored
Normal file
15
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_borders.sgrd
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
NAME =
|
||||
DESCRIPTION =
|
||||
UNIT =
|
||||
DATAFORMAT = BYTE_UNSIGNED
|
||||
DATAFILE_OFFSET = 0
|
||||
BYTEORDER_BIG = FALSE
|
||||
TOPTOBOTTOM = FALSE
|
||||
POSITION_XMIN = 18.6662979442
|
||||
POSITION_YMIN = 45.7767014376
|
||||
CELLCOUNT_X = 375
|
||||
CELLCOUNT_Y = 352
|
||||
CELLSIZE = 0.0001000000
|
||||
Z_FACTOR = 1.000000
|
||||
Z_OFFSET = 0.000000
|
||||
NODATA_VALUE = 0.000000
|
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.dbf
vendored
Normal file
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.dbf
vendored
Normal file
Binary file not shown.
49
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.mshp
vendored
Normal file
49
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.mshp
vendored
Normal file
@ -0,0 +1,49 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<SAGA_METADATA>
|
||||
<HISTORY saga-version="2.3.1">
|
||||
<MODULE library="imagery_segmentation" id="0" name="Watershed Segmentation">
|
||||
<OPTION type="grid_system" id="PARAMETERS_GRID_SYSTEM" name="Grid system">
|
||||
<CELLSIZE>0.0001</CELLSIZE>
|
||||
<XMIN>18.666347944200002</XMIN>
|
||||
<XMAX>18.7035479442</XMAX>
|
||||
<YMIN>45.7767514376</YMIN>
|
||||
<YMAX>45.8116514376</YMAX>
|
||||
</OPTION>
|
||||
<OPTION type="choice" id="OUTPUT" name="Output" index="0">Seed Value</OPTION>
|
||||
<OPTION type="choice" id="DOWN" name="Method" index="0">Minima</OPTION>
|
||||
<OPTION type="choice" id="JOIN" name="Join Segments based on Threshold Value" index="0">do not join</OPTION>
|
||||
<OPTION type="double" id="THRESHOLD" name="Threshold">0.500000</OPTION>
|
||||
<OPTION type="boolean" id="EDGE" name="Allow Edge Pixels to be Seeds">TRUE</OPTION>
|
||||
<OPTION type="boolean" id="BBORDERS" name="Borders">TRUE</OPTION>
|
||||
<INPUT type="grid" id="GRID" name="Grid" system="PARAMETERS_GRID_SYSTEM">
|
||||
<MODULE library="io_gdal" id="0" name="Import Raster">
|
||||
<OPTION type="file" id="FILES" name="Files">"/home/ginetto/PROGRAMMING/QGIS/QGIS-master/python/plugins/processing/tests/testdata/dem.tif"</OPTION>
|
||||
<OPTION type="text" id="SELECTION" name="Select from Multiple Bands"/>
|
||||
<OPTION type="boolean" id="SELECT_SORT" name="Alphanumeric Sorting">TRUE</OPTION>
|
||||
<OPTION type="boolean" id="TRANSFORM" name="Transformation">TRUE</OPTION>
|
||||
<OPTION type="choice" id="RESAMPLING" name="Resampling" index="3">B-Spline Interpolation</OPTION>
|
||||
<OUTPUT type="grid_list" id="GRIDS" name="Grids">dem</OUTPUT>
|
||||
</MODULE>
|
||||
</INPUT>
|
||||
<OUTPUT type="shapes" id="SEEDS" name="Seed Points">dem [Seeds]</OUTPUT>
|
||||
</MODULE>
|
||||
</HISTORY>
|
||||
<SOURCE>
|
||||
<FILE></FILE>
|
||||
<DATABASE>
|
||||
<FIELDS>
|
||||
<FIELD TYPE="INTEGER">XCELL</FIELD>
|
||||
<FIELD TYPE="INTEGER">YCELL</FIELD>
|
||||
<FIELD TYPE="DOUBLE">VALUE</FIELD>
|
||||
<FIELD TYPE="INTEGER">ID</FIELD>
|
||||
<FIELD TYPE="INTEGER">ID_JOIN</FIELD>
|
||||
</FIELDS>
|
||||
</DATABASE>
|
||||
<PROJECTION>
|
||||
<OGC_WKT>GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]</OGC_WKT>
|
||||
<PROJ4>+init=epsg:4326 +proj=longlat +a=6378137.000000 +b=6356752.314245 +no_defs</PROJ4>
|
||||
<EPSG>-1</EPSG>
|
||||
</PROJECTION>
|
||||
</SOURCE>
|
||||
<DESCRIPTION></DESCRIPTION>
|
||||
</SAGA_METADATA>
|
1
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.prj
vendored
Normal file
1
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.prj
vendored
Normal file
@ -0,0 +1 @@
|
||||
GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]
|
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.shp
vendored
Normal file
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.shp
vendored
Normal file
Binary file not shown.
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.shx
vendored
Normal file
BIN
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_seeds.shx
vendored
Normal file
Binary file not shown.
41
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.mgrd
vendored
Normal file
41
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.mgrd
vendored
Normal file
@ -0,0 +1,41 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<SAGA_METADATA>
|
||||
<HISTORY saga-version="2.3.1">
|
||||
<MODULE library="imagery_segmentation" id="0" name="Watershed Segmentation">
|
||||
<OPTION type="grid_system" id="PARAMETERS_GRID_SYSTEM" name="Grid system">
|
||||
<CELLSIZE>0.0001</CELLSIZE>
|
||||
<XMIN>18.666347944200002</XMIN>
|
||||
<XMAX>18.7035479442</XMAX>
|
||||
<YMIN>45.7767514376</YMIN>
|
||||
<YMAX>45.8116514376</YMAX>
|
||||
</OPTION>
|
||||
<OPTION type="choice" id="OUTPUT" name="Output" index="0">Seed Value</OPTION>
|
||||
<OPTION type="choice" id="DOWN" name="Method" index="0">Minima</OPTION>
|
||||
<OPTION type="choice" id="JOIN" name="Join Segments based on Threshold Value" index="0">do not join</OPTION>
|
||||
<OPTION type="double" id="THRESHOLD" name="Threshold">0.500000</OPTION>
|
||||
<OPTION type="boolean" id="EDGE" name="Allow Edge Pixels to be Seeds">TRUE</OPTION>
|
||||
<OPTION type="boolean" id="BBORDERS" name="Borders">TRUE</OPTION>
|
||||
<INPUT type="grid" id="GRID" name="Grid" system="PARAMETERS_GRID_SYSTEM">
|
||||
<MODULE library="io_gdal" id="0" name="Import Raster">
|
||||
<OPTION type="file" id="FILES" name="Files">"/home/ginetto/PROGRAMMING/QGIS/QGIS-master/python/plugins/processing/tests/testdata/dem.tif"</OPTION>
|
||||
<OPTION type="text" id="SELECTION" name="Select from Multiple Bands"/>
|
||||
<OPTION type="boolean" id="SELECT_SORT" name="Alphanumeric Sorting">TRUE</OPTION>
|
||||
<OPTION type="boolean" id="TRANSFORM" name="Transformation">TRUE</OPTION>
|
||||
<OPTION type="choice" id="RESAMPLING" name="Resampling" index="3">B-Spline Interpolation</OPTION>
|
||||
<OUTPUT type="grid_list" id="GRIDS" name="Grids">dem</OUTPUT>
|
||||
</MODULE>
|
||||
</INPUT>
|
||||
<OUTPUT type="grid" id="SEGMENTS" name="Segments">dem [Segments]</OUTPUT>
|
||||
</MODULE>
|
||||
</HISTORY>
|
||||
<SOURCE>
|
||||
<FILE>/home/ginetto/PROGRAMMING/QGIS/QGIS-master/python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.sgrd</FILE>
|
||||
<DATABASE></DATABASE>
|
||||
<PROJECTION>
|
||||
<OGC_WKT>GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]</OGC_WKT>
|
||||
<PROJ4>+init=epsg:4326 +proj=longlat +a=6378137.000000 +b=6356752.314245 +no_defs</PROJ4>
|
||||
<EPSG>-1</EPSG>
|
||||
</PROJECTION>
|
||||
</SOURCE>
|
||||
<DESCRIPTION></DESCRIPTION>
|
||||
</SAGA_METADATA>
|
1
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.prj
vendored
Normal file
1
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.prj
vendored
Normal file
@ -0,0 +1 @@
|
||||
GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]
|
433
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.sdat
vendored
Normal file
433
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.sdat
vendored
Normal file
File diff suppressed because one or more lines are too long
@ -0,0 +1,3 @@
|
||||
<PAMDataset>
|
||||
<SRS>GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]]</SRS>
|
||||
</PAMDataset>
|
15
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.sgrd
vendored
Normal file
15
python/plugins/processing/tests/testdata/expected/saga/watershed_segmentation_segments.sgrd
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
NAME = dem [Segments]
|
||||
DESCRIPTION =
|
||||
UNIT =
|
||||
DATAFORMAT = FLOAT
|
||||
DATAFILE_OFFSET = 0
|
||||
BYTEORDER_BIG = FALSE
|
||||
TOPTOBOTTOM = FALSE
|
||||
POSITION_XMIN = 18.6663479442
|
||||
POSITION_YMIN = 45.7767514376
|
||||
CELLCOUNT_X = 373
|
||||
CELLCOUNT_Y = 350
|
||||
CELLSIZE = 0.0001000000
|
||||
Z_FACTOR = 1.000000
|
||||
Z_OFFSET = 0.000000
|
||||
NODATA_VALUE = -999999.000000
|
@ -429,3 +429,26 @@ tests:
|
||||
hash: f4ac677152697773262aa1e5f69146a475139014ace77149966ec045
|
||||
type: rasterhash
|
||||
|
||||
- algorithm: saga:watershedsegmentation
|
||||
name: Test (saga:watershedsegmentation)
|
||||
params:
|
||||
'BBORDERS ': true
|
||||
DOWN: 0
|
||||
'EDGE ': true
|
||||
GRID:
|
||||
name: dem.tif
|
||||
type: raster
|
||||
JOIN: 0
|
||||
OUTPUT: 0
|
||||
THRESHOLD: 0.5
|
||||
results:
|
||||
BORDERS:
|
||||
hash: d0cd8bdc7c8400bedb2b5c1edc4a64b4c9b7c14692a4f30fbf3c5f2d
|
||||
type: rasterhash
|
||||
SEEDS:
|
||||
name: expected/saga/watershed_segmentation_seeds.shp
|
||||
type: vector
|
||||
SEGMENTS:
|
||||
hash: f2e71e3374eb229d387db8f87bc24d09b86ffc23d9fca85f324b566b
|
||||
type: rasterhash
|
||||
|
Loading…
x
Reference in New Issue
Block a user