Commit ff22691f authored by Cédric Traizet's avatar Cédric Traizet

ENH: added test for extractROI with valid parameters

parent 3b00396a
Pipeline #2828 canceled with stages
in 14 minutes and 15 seconds
PROJCS["WGS_1984_UTM_Zone_31N",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137,298.257223563]],PRIMEM["Greenwich",0],UNIT["Degree",0.017453292519943295]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",3],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["Meter",1]]
\ No newline at end of file
PROJCS["WGS 84 / UTM zone 31N",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",3],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","32631"]]
......@@ -95,6 +95,126 @@ otb_test_application(NAME apTvUtDynamicConvertMask
#----------- PixelInfo TESTS ----------------
#----------- ExtractROI TESTS ----------------
# ---------- Valid configuration tests -------
otb_test_application(NAME apTvUtExtractROIStandard
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIStandard.tif
-mode standard
-startx 29
-starty 14
-sizex 5
-sizey 5
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIStandard.tif)
otb_test_application(NAME apTvUtExtractROIRadiusPxl
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIRadiusPxl.tif
-mode radius
-mode.radius.cx 31
-mode.radius.cy 16
-mode.radius.r 2
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIRadiusPxl.tif)
otb_test_application(NAME apTvUtExtractROIRadiusPhy
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIRadiusPhy.tif
-mode radius
-mode.radius.unitr phy
-mode.radius.r 1.2
-mode.radius.unitc phy
-mode.radius.cx 374169.881
-mode.radius.cy 4829174.094
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIRadiusPhy.tif)
otb_test_application(NAME apTvUtExtractROIRadiusLonLat
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIRadiusLonLat.tif
-mode radius
-mode.radius.unitr pxl
-mode.radius.r 2
-mode.radius.unitc lonlat
-mode.radius.cx 1.4408488
-mode.radius.cy 43.6049153
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIRadiusLonLat.tif)
otb_test_application(NAME apTvUtExtractROIExtentPix
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIExtentPix.tif
-mode extent
-mode.extent.ulx 29
-mode.extent.uly 14
-mode.extent.lrx 33
-mode.extent.lry 18
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIExtentPix.tif)
otb_test_application(NAME apTvUtExtractROIExtentPhy
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIExtentPhy.tif
-mode extent
-mode.extent.unit phy
-mode.extent.ulx 374167.881
-mode.extent.uly 4829172.8
-mode.extent.lrx 374170
-mode.extent.lry 4829175
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIExtentPhy.tif)
otb_test_application(NAME apTvUtExtractROIExtentLonLat
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIExtentLonLat.tif
-mode extent
-mode.extent.unit lonlat
-mode.extent.ulx 1.4408328
-mode.extent.uly 43.6049036
-mode.extent.lrx 1.4408596
-mode.extent.lry 43.6049231
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIExtentLonLat.tif)
otb_test_application(NAME apTvUtExtractROIExtentFitIm
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIExtentFitIm.tif
-mode fit
-mode.fit.im ${OTBAPP_BASELINE}/apTvUtExtractROI.tif
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIExtentFitIm.tif)
otb_test_application(NAME apTvUtExtractROIExtentFitVect
APP ExtractROI
OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
-out ${TEMP}/apTvUtExtractROIExtentFitVect.tif
-mode fit
-mode.fit.vect ${INPUTDATA}/apTvUtExtractROIExtentFitVect.shp
VALID --compare-image ${NOTOL}
${OTBAPP_BASELINE}/apTvUtExtractROI.tif
${TEMP}/apTvUtExtractROIExtentFitVect.tif)
# ---------- Invalid configuration tests ----------------
otb_test_application(NAME apTvUtExtractROISizeTooBig
APP ExtractROI
OPTIONS -in ${INPUTDATA}/couleurs_extrait.png
......@@ -149,7 +269,6 @@ otb_test_application(NAME apTvUtExtractROIComplexInputFile
${INPUTDATA}/complexInputCfloat.tif
${TEMP}/apTvUtExtractROIComplexInputFile.tif)
#----------- Rescale TESTS ----------------
otb_test_application(NAME apTvUtRescaleTest
APP Rescale
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment