[Git][debian-gis-team/saga][master] 5 commits: New upstream version 9.2.1+dfsg

Bas Couwenberg (@sebastic) gitlab at salsa.debian.org
Thu Dec 14 06:03:41 GMT 2023



Bas Couwenberg pushed to branch master at Debian GIS Project / saga


Commits:
1ec9a456 by Bas Couwenberg at 2023-12-14T06:48:51+01:00
New upstream version 9.2.1+dfsg
- - - - -
e8906df8 by Bas Couwenberg at 2023-12-14T06:49:04+01:00
Update upstream source from tag 'upstream/9.2.1+dfsg'

Update to upstream version '9.2.1+dfsg'
with Debian dir 62a461a564831973ea617105ce98ae5daa4b6581
- - - - -
d22953b4 by Bas Couwenberg at 2023-12-14T06:50:01+01:00
New upstream release.

- - - - -
29585bd3 by Bas Couwenberg at 2023-12-14T06:51:09+01:00
Drop spelling-errors.patch, applied upstream.

- - - - -
dd44eec8 by Bas Couwenberg at 2023-12-14T06:51:24+01:00
Set distribution to unstable.

- - - - -


25 changed files:

- debian/changelog
- − debian/patches/series
- − debian/patches/spelling-errors.patch
- saga-gis/src/accessories/helper/doxygen_saga_api_chm
- saga-gis/src/accessories/helper/doxygen_saga_api_html
- saga-gis/src/accessories/helper/make_saga_release.bat
- saga-gis/src/accessories/helper/saga_setup_x64.iss
- saga-gis/src/accessories/python/data/chelsa.py
- saga-gis/src/accessories/python/data/copernicus_dem.py
- saga-gis/src/accessories/python/data/srtm.py
- saga-gis/src/accessories/python/tools/climate_tools.py
- saga-gis/src/accessories/python/tools/ta_lighting.py
- saga-gis/src/accessories/python/tools/ta_morphometry.py
- + saga-gis/src/accessories/toolchains/climate_tools_temperature_downscaling.xml
- saga-gis/src/saga_core/saga_api/api_core.h
- saga-gis/src/saga_core/saga_api/kdtree.cpp
- saga-gis/src/saga_core/saga_api/saga_api.h
- saga-gis/src/saga_core/saga_api/tool_library.cpp
- saga-gis/src/saga_core/saga_api/tool_library_interface.cpp
- saga-gis/src/saga_core/saga_cmd/man/saga_cmd.1
- saga-gis/src/saga_core/saga_cmd/saga_cmd.cpp
- saga-gis/src/saga_core/saga_gdi/3d_view_canvas.cpp
- saga-gis/src/saga_core/saga_gui/man/saga_gui.1
- saga-gis/src/tools/terrain_analysis/ta_morphometry/top_hat.cpp
- saga-gis/version.cmake


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,11 @@
+saga (9.2.1+dfsg-1) unstable; urgency=medium
+
+  * Team upload.
+  * New upstream release.
+  * Drop spelling-errors.patch, applied upstream.
+
+ -- Bas Couwenberg <sebastic at debian.org>  Thu, 14 Dec 2023 06:51:14 +0100
+
 saga (9.2.0+dfsg-1) unstable; urgency=medium
 
   * Team upload.


=====================================
debian/patches/series deleted
=====================================
@@ -1 +0,0 @@
-spelling-errors.patch


=====================================
debian/patches/spelling-errors.patch deleted
=====================================
@@ -1,29 +0,0 @@
-Description: Fix spelling errors.
- * permit tot <verb> -> permit <verb>ing
-Author: Bas Couwenberg <sebastic at debian.org>
-Forwarded: https://sourceforge.net/p/saga-gis/bugs/306/
-
---- a/saga-gis/src/accessories/python/tools/ta_morphometry.py
-+++ b/saga-gis/src/accessories/python/tools/ta_morphometry.py
-@@ -887,7 +887,7 @@ def Run_Valley_and_Ridge_Detection_Top_H
-     WTH = DEM - Opening >= t\n
-     Valleys are extracted by the "Black Top Hat" (BTH) function:\n
-     BTH = Closing - DEM >= t\n
--    The threshold value "t" works as an additional cut-off to extract only the highest peaks and deepest valleys. This means that the functions permit to extract peaks and valleys based on width and height criterions. For details see the referenced paper.\n
-+    The threshold value "t" works as an additional cut-off to extract only the highest peaks and deepest valleys. This means that the functions permit extracting peaks and valleys based on width and height criterions. For details see the referenced paper.\n
-     The tool is based on the AML script 'tophat' by Jochen Schmidt, Landcare Research.\n
-     Arguments
-     ----------
---- a/saga-gis/src/tools/terrain_analysis/ta_morphometry/top_hat.cpp
-+++ b/saga-gis/src/tools/terrain_analysis/ta_morphometry/top_hat.cpp
-@@ -85,8 +85,8 @@ CTop_Hat::CTop_Hat(void)
- 		"Valleys are extracted by the \"Black Top Hat\" (BTH) function:\n\n"
- 		"BTH = Closing - DEM >= t\n\n"
- 		"The threshold value \"t\" works as an additional cut-off to extract "
--		"only the highest peaks and deepest valleys. This means that the functions permit to "
--		"extract peaks and valleys based on width and height criterions. For details "
-+		"only the highest peaks and deepest valleys. This means that the functions permit "
-+		"extracting peaks and valleys based on width and height criterions. For details "
- 		"see the referenced paper.\n"
- 		"The tool is based on the AML script \'tophat\' by Jochen Schmidt, Landcare Research."
- 	));


=====================================
saga-gis/src/accessories/helper/doxygen_saga_api_chm
=====================================
@@ -38,7 +38,7 @@ PROJECT_NAME           = "SAGA API"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-#PROJECT_NUMBER        = v9.2.0 # omit patch number
+#PROJECT_NUMBER        = v9.2.1 # omit patch number
 PROJECT_NUMBER         = v9.2
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
@@ -59,7 +59,7 @@ PROJECT_LOGO           = ../../../saga_core/saga_gui/res/saga_icon_64.png
 # entered, it will be relative to the location where doxygen was started. If
 # left blank the current directory will be used.
 
-OUTPUT_DIRECTORY       = saga-9.2.0_api_doc
+OUTPUT_DIRECTORY       = saga-9.2.1_api_doc
 
 # If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub-
 # directories (in 2 levels) under the output directory of each output format and
@@ -1372,7 +1372,7 @@ GENERATE_HTMLHELP      = YES
 # written to the html output directory.
 # This tag requires that the tag GENERATE_HTMLHELP is set to YES.
 
-CHM_FILE               = ../../saga-9.2.0_api.chm
+CHM_FILE               = ../../saga-9.2.1_api.chm
 
 # The HHC_LOCATION tag can be used to specify the location (absolute path
 # including file name) of the HTML help compiler (hhc.exe). If non-empty,


=====================================
saga-gis/src/accessories/helper/doxygen_saga_api_html
=====================================
@@ -38,7 +38,7 @@ PROJECT_NAME           = "SAGA API"
 # could be handy for archiving the generated documentation or if some version
 # control system is used.
 
-#PROJECT_NUMBER        = v9.2.0 # omit patch number
+#PROJECT_NUMBER        = v9.2.1 # omit patch number
 PROJECT_NUMBER         = v9.2
 
 # Using the PROJECT_BRIEF tag one can provide an optional one line description
@@ -59,7 +59,7 @@ PROJECT_LOGO           = ../../../saga_core/saga_gui/res/saga_icon_64.png
 # entered, it will be relative to the location where doxygen was started. If
 # left blank the current directory will be used.
 
-OUTPUT_DIRECTORY       = saga-9.2.0_api_doc
+OUTPUT_DIRECTORY       = saga-9.2.1_api_doc
 
 # If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub-
 # directories (in 2 levels) under the output directory of each output format and
@@ -1372,7 +1372,7 @@ GENERATE_HTMLHELP      = NO
 # written to the html output directory.
 # This tag requires that the tag GENERATE_HTMLHELP is set to YES.
 
-CHM_FILE               = ../../saga-9.2.0_api.chm
+CHM_FILE               = ../../saga-9.2.1_api.chm
 
 # The HHC_LOCATION tag can be used to specify the location (absolute path
 # including file name) of the HTML help compiler (hhc.exe). If non-empty,


=====================================
saga-gis/src/accessories/helper/make_saga_release.bat
=====================================
@@ -30,15 +30,15 @@ REM ___________________________________
 REM Version
 
 SET SAGA_VERSION=9.2
-SET SAGA_RELEASE=9.2.0
-SET SAGA_VERSION_NEXT=9.3
-SET SAGA_RELEASE_NEXT=9.3.0
+SET SAGA_RELEASE=9.2.1
+SET SAGA_VERSION_NEXT=9.2
+SET SAGA_RELEASE_NEXT=9.2.2
 SET SAGA_RELEASE_NAME=saga-%SAGA_RELEASE%
 
 REM !!! For all bug-fix-releases !!!
 REM Don't forget to activate the variable
 REM - SWITCH_TO_BRANCH -
-REM SET SWITCH_TO_BRANCH=saga-%SAGA_VERSION%
+SET SWITCH_TO_BRANCH=saga-%SAGA_VERSION%
 
 
 REM ___________________________________
@@ -239,13 +239,13 @@ ECHO.
 ECHO - Create new tag: saga-%SAGA_RELEASE%
 ECHO.
 ECHO - Update version numbers accordingly:
-ECHO.    ./saga_setup_x64.iss
 ECHO.    ./saga-gis/version.cmake
 ECHO.    ./saga-gis/src/saga_core/saga_api/saga_api.h
 ECHO.    ./saga-gis/src/saga_core/saga_cmd/man/saga_cmd.1
 ECHO.    ./saga-gis/src/saga_core/saga_gui/man/saga_gui.1
 ECHO.    ./saga-gis/src/accessories/helper/doxygen_saga_api_chm
 ECHO.    ./saga-gis/src/accessories/helper/doxygen_saga_api_html
+ECHO.    ./saga-gis/src/accessories/helper/saga_setup_x64.iss
 ECHO.    ./saga-gis/src/accessories/helper/make_saga_release.bat (this file!)
 ECHO.  and commit: SAGA version updated to next aspired version %SAGA_RELEASE_NEXT%
 ECHO.


=====================================
saga-gis/src/accessories/helper/saga_setup_x64.iss
=====================================
@@ -1,5 +1,5 @@
-; To build installer (for example, saga-9.2.0_setup.exe).
-; - Unzip the SAGA binary files in their own folder (for example, saga-9.2.0.zip).
+; To build installer (for example, saga-9.2.1_setup.exe).
+; - Unzip the SAGA binary files in their own folder (for example, saga-9.2.1.zip).
 ; - Place saga.iss and saga_readme.rtf in the SAGA folder (contains saga_gui.exe, etc.).
 ; - Open saga.iss in Inno Setup.
 ; - Choose Build | Compile.
@@ -7,7 +7,7 @@
 
 [Setup]
 AppName=SAGA - System for Automated Geoscientific Analyses
-AppVerName=SAGA 9.2.0
+AppVerName=SAGA 9.2.1
 
 ArchitecturesAllowed=x64
 ArchitecturesInstallIn64BitMode=x64
@@ -22,9 +22,9 @@ Compression=lzma
 SolidCompression=yes
 
 OutputDir=.
-OutputBaseFilename=saga-9.2.0_x64_setup
+OutputBaseFilename=saga-9.2.1_x64_setup
 
-VersionInfoVersion=9.2.0.0
+VersionInfoVersion=9.2.1.0
 VersionInfoCompany=SAGA User Group Association
 VersionInfoCopyright=(c) 2005-2023 by O. Conrad
 VersionInfoDescription=SAGA single-file installer
@@ -51,5 +51,5 @@ Name: "{commondesktop}\SAGA"; Filename: "{app}\saga_gui.exe"; WorkingDir: "{app}
 Root: HKLM; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\saga_gui.exe"; ValueType: string; ValueName: ""; ValueData: "{app}\saga_gui.exe"; Flags: uninsdeletekey
 Root: HKLM; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\saga_gui.exe"; ValueType: string; ValueName: "Path"; ValueData: "{app}"
 
-Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.2.0"; ValueType: string; ValueName: "InstallDir"; ValueData: "{app}"; Flags: uninsdeletekey
-Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.2.0"; ValueType: string; ValueName: "Version"; ValueData: "9.2.0.0"
+Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.2.1"; ValueType: string; ValueName: "InstallDir"; ValueData: "{app}"; Flags: uninsdeletekey
+Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.2.1"; ValueType: string; ValueName: "Version"; ValueData: "9.2.1.0"


=====================================
saga-gis/src/accessories/python/data/chelsa.py
=====================================
@@ -319,7 +319,7 @@ def Get_Variable(Global_File, Target_File, AOI, Scaling=1., Offset=0., Unit=None
         #________________________________________________________________________
         Tool = saga_api.SG_Get_Tool_Library_Manager().Get_Tool('io_gdal', '0')
         if not Tool:
-            saga_api.SG_UI_Msg_Add_Error('failed to request tool \{:s}\''.format('Import Raster'))
+            saga_api.SG_UI_Msg_Add_Error('failed to request tool \'{:s}\''.format('Import Raster'))
             return None
 
         Tool.Reset()
@@ -331,7 +331,7 @@ def Get_Variable(Global_File, Target_File, AOI, Scaling=1., Offset=0., Unit=None
         Tool.Set_Parameter('EXTENT_YMAX', Extent.Get_YMax())
 
         if not Tool.Execute():
-            saga_api.SG_UI_Msg_Add_Error('failed to execute tool \{:s}\''.format(Tool.Get_Name().c_str()))
+            saga_api.SG_UI_Msg_Add_Error('failed to execute tool \'{:s}\''.format(Tool.Get_Name().c_str()))
             return None
 
         Grid = Tool.Get_Parameter('GRIDS').asGridList().Get_Grid(0)
@@ -365,7 +365,7 @@ def Get_Variable(Global_File, Target_File, AOI, Scaling=1., Offset=0., Unit=None
         Tool.Set_Parameter('TARGET_USER_YMIN', Extent.yMin)
 
         if not Tool.Execute():
-            saga_api.SG_UI_Msg_Add_Error('failed to execute tool \{:s}\''.format(Tool.Get_Name().c_str()))
+            saga_api.SG_UI_Msg_Add_Error('failed to execute tool \'{:s}\''.format(Tool.Get_Name().c_str()))
             saga_api.SG_Get_Data_Manager().Delete(Grid)
             return None
 


=====================================
saga-gis/src/accessories/python/data/copernicus_dem.py
=====================================
@@ -304,7 +304,7 @@ def Get_AOI(AOI, Target_File, Target_Resolution=0, Round=True, SrcRes_1arcsec=Tr
         Tool.Set_Parameter('TARGET_USER_YMIN', Extent.yMin)
 
         if not Tool.Execute():
-            saga_api.SG_UI_Console_Print_StdErr('failed to execute tool \{:s}\''.format(Tool.Get_Name().c_str()))
+            saga_api.SG_UI_Console_Print_StdErr('failed to execute tool \'{:s}\''.format(Tool.Get_Name().c_str()))
             saga_api.SG_Get_Data_Manager().Delete(Grid)
             return None
 


=====================================
saga-gis/src/accessories/python/data/srtm.py
=====================================
@@ -262,7 +262,7 @@ def CGIAR_Get_AOI(AOI, Target_File, Target_Resolution=90., Round=True, DeleteZip
         Tool.Set_Parameter('TARGET_USER_YMIN', Extent.yMin)
 
         if not Tool.Execute():
-            saga_api.SG_UI_Console_Print_StdErr('failed to execute tool \{:s}\''.format(Tool.Get_Name().c_str()))
+            saga_api.SG_UI_Console_Print_StdErr('failed to execute tool \'{:s}\''.format(Tool.Get_Name().c_str()))
             saga_api.SG_Get_Data_Manager().Delete(Grid)
             return None
 


=====================================
saga-gis/src/accessories/python/tools/climate_tools.py
=====================================
@@ -233,8 +233,8 @@ def Run_Evapotranspiration_Grid(T=None, T_MIN=None, T_MAX=None, RH=None, SR=None
     - SR_EST [`boolean`] : Estimate Solar Radiation. Default: 0 Estimate solar radiation from date, latitudinal position and sunshine duration as percentage of its potential maximum.
     - SUNSHINE [`floating point number`] : Sunshine Duration. Minimum: 0.000000 Maximum: 100.000000 Default: 50.000000 Daily sunshine duration as percentage of its potential maximum.
     - TIME [`choice`] : Time. Available Choices: [0] day [1] month Default: 0
-    - MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 9
-    - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 5
+    - MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 11
+    - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 13
     - LAT [`floating point number`] : Latitude. Minimum: -90.000000 Maximum: 90.000000 Default: 53.000000 [Degree]
 
     - Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
@@ -281,7 +281,7 @@ def Run_Sunrise_and_Sunset(TARGET=None, SUNRISE=None, SUNSET=None, LENGTH=None,
     - SUNRISE [`output grid`] : Sunrise
     - SUNSET [`output grid`] : Sunset
     - LENGTH [`output grid`] : Day Length
-    - DAY [`date`] : Day of Month. Default: 2023-10-06
+    - DAY [`date`] : Day of Month. Default: 2023-12-13
     - TIME [`choice`] : Time. Available Choices: [0] local [1] world Default: 0
 
     - Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
@@ -862,7 +862,7 @@ def Run_PhenIps_Grids_Days(ATMEAN=None, ATMAX=None, SIREL=None, LAT_GRID=None, G
     - YD_END_ONSET [`date`] : End of Breeding. Default: 2023-08-31
     - YD_END [`date`] : End of Development. Default: 2023-10-31
     - RESET [`boolean`] : Reset. Default: 1
-    - DAY [`date`] : Start Day. Default: 2023-10-06
+    - DAY [`date`] : Start Day. Default: 2023-12-13
 
     - Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
     Returns
@@ -930,7 +930,7 @@ def Run_Soil_Water_Balance_Days(TAVG=None, TMIN=None, TMAX=None, PSUM=None, LAT_
     - SWC_SURFACE [`floating point number`] : Top Soil Water Capacity. Minimum: 0.000000 Default: 30.000000
     - SWT_RESIST [`floating point number`] : Transpiration Resistance. Minimum: 0.010000 Default: 0.500000
     - RESET [`boolean`] : Reset. Default: 1
-    - DAY [`date`] : Start Day. Default: 2023-10-06
+    - DAY [`date`] : Start Day. Default: 2023-12-13
 
     - Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
     Returns
@@ -1242,8 +1242,8 @@ def Run_Daily_Solar_Radiation(LATITUDE=None, SOLARRAD=None, MONTH=None, DAY=None
     ----------
     - LATITUDE [`input grid`] : Latitude. [Degree]
     - SOLARRAD [`output grid`] : Solar Radiation. [J/cm²]
-    - MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 9
-    - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 5
+    - MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 11
+    - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 13
     - SUNSHINE [`floating point number`] : Sunshine Duration. Minimum: 0.000000 Maximum: 100.000000 Default: 50.000000 Daily sunshine duration as percentage of its potential maximum.
 
     - Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n


=====================================
saga-gis/src/accessories/python/tools/ta_lighting.py
=====================================
@@ -28,7 +28,7 @@ def Run_Analytical_Hillshading(ELEVATION=None, SHADE=None, METHOD=None, POSITION
     - POSITION [`choice`] : Sun's Position. Available Choices: [0] azimuth and height [1] date and time Default: 0
     - AZIMUTH [`floating point number`] : Azimuth. Minimum: 0.000000 Maximum: 360.000000 Default: 315.000000 Direction of the light source, measured in degree clockwise from the North direction.
     - DECLINATION [`floating point number`] : Height. Minimum: 0.000000 Maximum: 90.000000 Default: 45.000000 Height of the light source, measured in degree above the horizon.
-    - DATE [`date`] : Day. Default: 2023-10-06
+    - DATE [`date`] : Day. Default: 2023-12-13
     - TIME [`floating point number`] : Hour. Minimum: 0.000000 Maximum: 24.000000 Default: 12.000000
     - EXAGGERATION [`floating point number`] : Exaggeration. Default: 1.000000 The terrain exaggeration factor allows one to increase the shading contrasts in flat areas.
     - UNIT [`choice`] : Unit. Available Choices: [0] radians [1] degree Default: 0
@@ -89,8 +89,8 @@ def Run_Potential_Incoming_Solar_Radiation(GRD_DEM=None, GRD_SVF=None, GRD_VAPOU
     - LOCATION [`choice`] : Location. Available Choices: [0] constant latitude [1] calculate from grid system Default: 0
     - LATITUDE [`degree`] : Latitude. Minimum: -90.000000 Maximum: 90.000000 Default: 53.000000
     - PERIOD [`choice`] : Time Period. Available Choices: [0] moment [1] day [2] range of days Default: 1
-    - DAY [`date`] : Day. Default: 2023-10-06
-    - DAY_STOP [`date`] : Last Day. Default: 2023-10-06
+    - DAY [`date`] : Day. Default: 2023-12-13
+    - DAY_STOP [`date`] : Last Day. Default: 2023-12-13
     - DAYS_STEP [`integer number`] : Resolution [d]. Minimum: 1 Default: 5 Time step size for a range of days calculation given in days.
     - MOMENT [`floating point number`] : Moment [h]. Minimum: 0.000000 Maximum: 24.000000 Default: 12.000000
     - HOUR_RANGE [`value range`] : Time Span [h]. Time span used for the calculation of daily radiation sums.


=====================================
saga-gis/src/accessories/python/tools/ta_morphometry.py
=====================================
@@ -887,7 +887,7 @@ def Run_Valley_and_Ridge_Detection_Top_Hat_Approach(DEM=None, VALLEY=None, HILL=
     WTH = DEM - Opening >= t\n
     Valleys are extracted by the "Black Top Hat" (BTH) function:\n
     BTH = Closing - DEM >= t\n
-    The threshold value "t" works as an additional cut-off to extract only the highest peaks and deepest valleys. This means that the functions permit to extract peaks and valleys based on width and height criterions. For details see the referenced paper.\n
+    The threshold value "t" works as an additional cut-off to extract only the highest peaks and deepest valleys. This means that the functions permit extracting peaks and valleys based on width and height criterions. For details see the referenced paper.\n
     The tool is based on the AML script 'tophat' by Jochen Schmidt, Landcare Research.\n
     Arguments
     ----------


=====================================
saga-gis/src/accessories/toolchains/climate_tools_temperature_downscaling.xml
=====================================
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<toolchain saga-version="4.1.0">
+	<group>climate_tools</group>
+	<identifier>temperature_downscaling</identifier>
+	<menu absolute="true">Climate and Weather|Temperature</menu>
+	<name>Lapse Rate Based Temperature Downscaling (Bulk Processing)</name>
+	<author>O.Conrad (c) 2017</author>
+	<description>
+		The [[i]]Lapse Rate Based Temperature Downscaling[[/i]] is quite simple, but might perform well for mountainous regions, where the altitudinal gradient is the main driver for local temperature variation. First, a given lapse rate is used to estimate sea level temperatures from elevation and temperature data at a coarse resolution. Second, the same lapse rate is used to estimate the terrain surface temperature using higher resoluted elevation data and the spline interpolated sea level temperatures from the previous step.
+	</description>
+	
+	<parameters>
+		<option varname="LORES_GRID_SYSTEM" type="grid_system">
+			<name>Coarse Resolution</name>
+		</option>
+		<input varname="LORES_DEM" type="grid" parent="LORES_GRID_SYSTEM">
+			<name>Elevation</name>
+		</input>
+		<input varname="LORES_LAPSE" type="grid" parent="LORES_GRID_SYSTEM">
+			<condition value="2" type="=">LAPSE_METHOD</condition>
+			<name>Lapse Rate</name>
+		</input>
+		<input varname="LORES_T" type="grid_list" parent="LORES_GRID_SYSTEM">
+			<name>Temperature</name>
+		</input>
+
+		<option varname="HIRES_GRID_SYSTEM" type="grid_system">
+			<name>High Resolution</name>
+		</option>
+		<input varname="HIRES_DEM" type="grid" parent="HIRES_GRID_SYSTEM">
+			<name>Elevation</name>
+		</input>
+		<output varname="HIRES_T" type="grid_list" parent="HIRES_GRID_SYSTEM">
+			<name>Temperature</name>
+		</output>
+
+		<option varname="LAPSE_METHOD" type="choice">
+			<name>Lapse Rate</name>
+			<value>1</value>
+			<choices>constant lapse rate|constant lapse rate from regression|varying lapse rate from grid</choices>
+		</option>
+		<option varname="CONST_LAPSE" type="double">
+			<condition type="=" value="0">LAPSE_METHOD</condition>
+			<name>Constant or Minimum Lapse Rate</name>
+			<value min="0.0">0.6</value>
+			<description>constant or minimum limit lapse rate in degree of temperature per 100 meter.</description>
+		</option>
+		<option varname="REGRS_LAPSE" type="choice">
+			<condition type="=" value="1">LAPSE_METHOD</condition>
+			<name>Regression</name>
+			<value>2</value>
+			<choices>elevation|elevation and position|elevation and position (2nd order polynom)</choices>
+		</option>
+		<option varname="LIMIT_LAPSE" type="boolean">
+			<condition type="=" value="1">LAPSE_METHOD</condition>
+			<name>Limit Minimum Lapse Rate</name>
+			<description>If set, lapse rates from regression are limited to a minimum.</description>
+			<value>false</value>
+		</option>
+		<option varname="MINIM_LAPSE" type="double">
+			<condition type="=" value="1">LAPSE_METHOD</condition>
+			<condition type="=" value="1">LIMIT_LAPSE</condition>
+			<name>Minimum Lapse Rate</name>
+			<value min="0.0">0.2</value>
+			<description>minimum lapse rate in degree of temperature per 100 meter.</description>
+		</option>
+	</parameters>
+
+	<tools history="false">
+		<condition value="0" type="=" variable="LAPSE_METHOD">
+			<foreach input="LORES_T">
+				<tool library="climate_tools" tool="30" name="Lapse Rate Based Temperature Downscaling (with options)">
+					<option varname="true" id="LAPSE_METHOD">LAPSE_METHOD</option>
+					<option varname="true" id="CONST_LAPSE" >CONST_LAPSE</option>
+					<input                 id="LORES_DEM"   >LORES_DEM</input>
+					<input                 id="LORES_T"     >LORES_T</input>
+					<input                 id="HIRES_DEM"   >HIRES_DEM</input>
+					<output                id="HIRES_T"     >HIRES_T</output>
+				</tool>
+			</foreach>
+		</condition>
+		<condition value="1" type="=" variable="LAPSE_METHOD">
+			<foreach input="LORES_T">
+				<tool library="climate_tools" tool="30" name="Lapse Rate Based Temperature Downscaling (with options)">
+					<option varname="true" id="LAPSE_METHOD">LAPSE_METHOD</option>
+					<option varname="true" id="REGRS_LAPSE" >REGRS_LAPSE</option>
+					<option varname="true" id="LIMIT_LAPSE" >LIMIT_LAPSE</option>
+					<option varname="true" id="CONST_LAPSE" >MINIM_LAPSE</option>
+					<input                 id="LORES_DEM"   >LORES_DEM</input>
+					<input                 id="LORES_T"     >LORES_T</input>
+					<input                 id="HIRES_DEM"   >HIRES_DEM</input>
+					<output                id="HIRES_T"     >HIRES_T</output>
+				</tool>
+			</foreach>
+		</condition>
+		<condition value="2" type="=" variable="LAPSE_METHOD">
+			<foreach input="LORES_T">
+				<tool library="climate_tools" tool="30" name="Lapse Rate Based Temperature Downscaling (with options)">
+					<option varname="true" id="LAPSE_METHOD">LAPSE_METHOD</option>
+					<input                 id="LORES_DEM"   >LORES_DEM</input>
+					<input                 id="LORES_LAPSE" >LORES_LAPSE</input>
+					<input                 id="LORES_T"     >LORES_T</input>
+					<input                 id="HIRES_DEM"   >HIRES_DEM</input>
+					<output                id="HIRES_T"     >HIRES_T</output>
+				</tool>
+			</foreach>
+		</condition>
+	</tools>
+</toolchain>


=====================================
saga-gis/src/saga_core/saga_api/api_core.h
=====================================
@@ -529,8 +529,8 @@ private:
 //---------------------------------------------------------
 #define SG_Char				wchar_t
 #define SG_T(s)				L ## s
-#define SG_PRINTF			SG_Printf
-#define SG_FPRINTF			SG_FPrintf
+#define SG_PRINTF			wprintf
+#define SG_FPRINTF			fwprintf
 #define SG_SSCANF			swscanf
 #define SG_STR_CPY			wcscpy
 #define SG_STR_LEN			wcslen


=====================================
saga-gis/src/saga_core/saga_api/kdtree.cpp
=====================================
@@ -995,7 +995,7 @@ size_t      CSG_KDTree_3D::Get_Duplicates(double Coordinate[3], CSG_Array_Int &I
 
 	std::vector<std::pair<size_t, double>> Matches;
 
-	((CSG_KDTree_Adaptor::kd_tree_2d *)m_pKDTree)->radiusSearch(Coordinate, 0.0000001, Matches, SearchParams);
+	((CSG_KDTree_Adaptor::kd_tree_3d *)m_pKDTree)->radiusSearch(Coordinate, 0.0000001, Matches, SearchParams);
 
 	Indices  .Create(Matches.size());
 	Distances.Create(Matches.size());


=====================================
saga-gis/src/saga_core/saga_api/saga_api.h
=====================================
@@ -86,8 +86,8 @@
 //---------------------------------------------------------
 #define SAGA_MAJOR_VERSION		9
 #define SAGA_MINOR_VERSION		2
-#define SAGA_RELEASE_NUMBER		0
-#define SAGA_VERSION			SG_T("9.2.0")
+#define SAGA_RELEASE_NUMBER		1
+#define SAGA_VERSION			SG_T("9.2.1")
 
 
 ///////////////////////////////////////////////////////////


=====================================
saga-gis/src/saga_core/saga_api/tool_library.cpp
=====================================
@@ -67,27 +67,27 @@
 //---------------------------------------------------------
 CSG_Tool_Library::CSG_Tool_Library(void)
 {
-	m_pInterface	= NULL;
-	m_pLibrary		= NULL;
+	m_pInterface = NULL;
+	m_pLibrary   = NULL;
 }
 
 //---------------------------------------------------------
 CSG_Tool_Library::CSG_Tool_Library(const CSG_String &File)
 {
-	m_pLibrary	= new wxDynamicLibrary(SG_File_Get_Path_Absolute(File).c_str(), wxDL_DEFAULT|wxDL_QUIET);
+	m_pLibrary = new wxDynamicLibrary(SG_File_Get_Path_Absolute(File).c_str(), wxDL_DEFAULT|wxDL_QUIET);
 
 	if(	m_pLibrary->IsLoaded()
-	&&	m_pLibrary->HasSymbol(SYMBOL_TLB_Get_Interface)
-	&&	m_pLibrary->HasSymbol(SYMBOL_TLB_Initialize)
-	&&	m_pLibrary->HasSymbol(SYMBOL_TLB_Finalize)
-	&&	((TSG_PFNC_TLB_Initialize)m_pLibrary->GetSymbol(SYMBOL_TLB_Initialize))(File) )
+	&&  m_pLibrary->HasSymbol(SYMBOL_TLB_Get_Interface)
+	&&  m_pLibrary->HasSymbol(SYMBOL_TLB_Initialize)
+	&&  m_pLibrary->HasSymbol(SYMBOL_TLB_Finalize)
+	&&  ((TSG_PFNC_TLB_Initialize)m_pLibrary->GetSymbol(SYMBOL_TLB_Initialize))(File) )
 	{
-		m_pInterface	= ((TSG_PFNC_TLB_Get_Interface)m_pLibrary->GetSymbol(SYMBOL_TLB_Get_Interface))();
+		m_pInterface = ((TSG_PFNC_TLB_Get_Interface)m_pLibrary->GetSymbol(SYMBOL_TLB_Get_Interface))();
 
 		if( m_pInterface->Get_Count() > 0 )
 		{
-			m_File_Name		= m_pInterface->Get_Info(TLB_INFO_File   );
-			m_Library_Name	= m_pInterface->Get_Info(TLB_INFO_Library);
+			m_File_Name    = m_pInterface->Get_Info(TLB_INFO_File   );
+			m_Library_Name = m_pInterface->Get_Info(TLB_INFO_Library);
 
 			return;	// success
 		}
@@ -348,7 +348,7 @@ CSG_Tool_Library * CSG_Tool_Library_Manager::Add_Library(const CSG_String &File)
 	//-----------------------------------------------------
 	SG_UI_Msg_Add(CSG_String::Format("%s: %s...", _TL("Loading library"), File.c_str()), true);
 
-	wxFileName	fn(File.c_str());
+	wxFileName fn(File.c_str());
 
 	for(int i=0; i<Get_Count(); i++)
 	{
@@ -361,12 +361,12 @@ CSG_Tool_Library * CSG_Tool_Library_Manager::Add_Library(const CSG_String &File)
 	}
 
 	//-----------------------------------------------------
-	CSG_Tool_Library	*pLibrary	= new CSG_Tool_Library(File);
+	CSG_Tool_Library *pLibrary = new CSG_Tool_Library(File);
 
 	if( pLibrary->is_Valid() )
 	{
-		m_pLibraries	= (CSG_Tool_Library **)SG_Realloc(m_pLibraries, (m_nLibraries + 1) * sizeof(CSG_Tool_Library *));
-		m_pLibraries[m_nLibraries++]	= pLibrary;
+		m_pLibraries = (CSG_Tool_Library **)SG_Realloc(m_pLibraries, (m_nLibraries + 1) * sizeof(CSG_Tool_Library *));
+		m_pLibraries[m_nLibraries++] = pLibrary;
 
 		SG_UI_Msg_Add(_TL("okay"), false, SG_UI_MSG_STYLE_SUCCESS);
 
@@ -393,12 +393,11 @@ CSG_Tool_Library * CSG_Tool_Library_Manager::Add_Library(const wchar_t    *File)
 //---------------------------------------------------------
 int CSG_Tool_Library_Manager::Add_Directory(const CSG_String &Directory, bool bOnlySubDirectories)
 {
-	int		nOpened	= 0;
-	wxDir	Dir;
+	int nOpened = 0; wxDir Dir;
 
 	if( Dir.Open(Directory.c_str()) )
 	{
-		wxString	FileName, DirName(Dir.GetName());
+		wxString FileName, DirName(Dir.GetName());
 
 		if( !bOnlySubDirectories && Dir.GetFirst(&FileName, wxEmptyString, wxDIR_FILES) )
 		{


=====================================
saga-gis/src/saga_core/saga_api/tool_library_interface.cpp
=====================================
@@ -62,7 +62,7 @@
 //---------------------------------------------------------
 CSG_Tool_Library_Interface::CSG_Tool_Library_Interface(void)
 {
-	m_Fnc_Create_Tool	= NULL;
+	m_Fnc_Create_Tool = NULL;
 }
 
 //---------------------------------------------------------
@@ -86,10 +86,10 @@ bool CSG_Tool_Library_Interface::Create(const CSG_String &Version, const CSG_Str
 
 	for(int i=0; i<TLB_INFO_User; i++)
 	{
-		m_Info[i]	= Fnc_Info(i);
+		m_Info[i] = Fnc_Info(i);
 	}
 
-	CSG_String	Library		= SG_File_Get_Name(TLB_Path, false);
+	CSG_String Library = SG_File_Get_Name(TLB_Path, false);
 
 	#if !defined(_SAGA_MSW)
 	if( Library.Find("lib") == 0 )
@@ -98,9 +98,9 @@ bool CSG_Tool_Library_Interface::Create(const CSG_String &Version, const CSG_Str
 	}
 	#endif
 
-	m_Info[TLB_INFO_Library     ]	= Library;
-	m_Info[TLB_INFO_SAGA_Version]	= Version;
-	m_Info[TLB_INFO_File        ]	= SG_File_Get_Path_Absolute(TLB_Path);
+	m_Info[TLB_INFO_Library     ] = Library;
+	m_Info[TLB_INFO_SAGA_Version] = Version;
+	m_Info[TLB_INFO_File        ] = SG_File_Get_Path_Absolute(TLB_Path);
 
 	if( Version.Cmp(SAGA_VERSION) )
 	{
@@ -112,20 +112,27 @@ bool CSG_Tool_Library_Interface::Create(const CSG_String &Version, const CSG_Str
 	}
 
 	//-----------------------------------------------------
-	m_Fnc_Create_Tool	= Fnc_Create_Tool;
+	m_Fnc_Create_Tool = Fnc_Create_Tool;
 
-	CSG_Tool	*pTool;
+	CSG_Tool *pTool;
 
 	for(int ID=0; (pTool = m_Fnc_Create_Tool(ID)) != NULL; ID++)
 	{
 		if( pTool != TLB_INTERFACE_SKIP_TOOL )
 		{
-			pTool->m_ID.Printf("%d", ID);
-			pTool->m_Library      = m_Info[TLB_INFO_Library  ];
-			pTool->m_Library_Menu = m_Info[TLB_INFO_Menu_Path];
-			pTool->m_File_Name    = m_Info[TLB_INFO_File     ];
-
-			m_Tools.Add(pTool);
+			if( SG_File_Get_Name(SG_UI_Get_Application_Path(), false).Cmp("saga_cmd") == 0 && pTool->is_Interactive() )
+			{
+				delete(pTool);
+			}
+			else
+			{
+				pTool->m_ID.Printf("%d", ID);
+				pTool->m_Library      = m_Info[TLB_INFO_Library  ];
+				pTool->m_Library_Menu = m_Info[TLB_INFO_Menu_Path];
+				pTool->m_File_Name    = m_Info[TLB_INFO_File     ];
+
+				m_Tools.Add(pTool);
+			}
 		}
 	}
 
@@ -188,7 +195,7 @@ CSG_Tool * CSG_Tool_Library_Interface::Get_Tool(int i)
 //---------------------------------------------------------
 CSG_Tool * CSG_Tool_Library_Interface::Create_Tool(int ID, bool bWithGUI)
 {
-	CSG_Tool	*pTool	= m_Fnc_Create_Tool ? m_Fnc_Create_Tool(ID) : NULL;
+	CSG_Tool *pTool = m_Fnc_Create_Tool ? m_Fnc_Create_Tool(ID) : NULL;
 
 	if( pTool && pTool != TLB_INTERFACE_SKIP_TOOL )
 	{


=====================================
saga-gis/src/saga_core/saga_cmd/man/saga_cmd.1
=====================================
@@ -133,7 +133,7 @@
 .\" ========================================================================
 .\"
 .IX Title "SAGA_CMD 1"
-.TH SAGA_CMD 1 "2021-07-07" "9.2.0" " "
+.TH SAGA_CMD 1 "2021-07-07" "9.2.1" " "
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l


=====================================
saga-gis/src/saga_core/saga_cmd/saga_cmd.cpp
=====================================
@@ -802,7 +802,7 @@ void		Print_Help		(void)
 		"\n"
 		"A more convenient way to set various saga_cmd options is to edit a\n"
 		"configuration file. The default configuration file \'saga_cmd.ini\' will be\n"
-		"loaded automatically, if present. You can specify a different configuration "
+		"loaded automatically, if present. You can specify a different configuration\n"
 		"file with the \'-C\' or \'--config\' option. Use \'--create-config\' to\n"
 		"generate such a file with default options and edit it to fit your purposes.\n"
 		"\n"


=====================================
saga-gis/src/saga_core/saga_gdi/3d_view_canvas.cpp
=====================================
@@ -736,7 +736,7 @@ double CSG_3DView_Canvas::Get_Dim(const CSG_Point_3D &p0, const CSG_Point_3D &p1
 //---------------------------------------------------------
 inline void CSG_3DView_Canvas::_Draw_Pixel(int x, int y, double z, int color)
 {
-	if( x >= 0 && x < m_Image_NX && y >= 0 && y < m_Image_NY && z < m_Image_zMax[y][x] )
+	if( x >= 0 && x < m_Image_NX && y >= 0 && y < m_Image_NY && z >= 0. && z < m_Image_zMax[y][x] )
 	{
 		BYTE *RGB = m_Image_pRGB + 3 * (y * m_Image_NX + x);
 
@@ -808,8 +808,8 @@ void CSG_3DView_Canvas::Draw_Point(int x, int y, double z, int Color, int Size)
 //---------------------------------------------------------
 void CSG_3DView_Canvas::Draw_Line(double ax, double ay, double az, double bx, double by, double bz, int aColor, int bColor)
 {
-	if(	(ax < 0 && bx < 0) || (ax >= m_Image_NX && bx >= m_Image_NX)
-	||	(ay < 0 && by < 0) || (ay >= m_Image_NY && by >= m_Image_NY) )
+	if(	(ax < 0. && bx < 0.) || ((int)ax >= m_Image_NX && (int)bx >= m_Image_NX)
+	||	(ay < 0. && by < 0.) || ((int)ay >= m_Image_NY && (int)by >= m_Image_NY) )
 	{
 		return; // completely out of area
 	}
@@ -819,30 +819,40 @@ void CSG_3DView_Canvas::Draw_Line(double ax, double ay, double az, double bx, do
 		return; // completely in front of screen
 	}
 
-	double n, dx = bx - ax, dy = by - ay, dz = bz - az;
+	double dx = bx - ax, dy = by - ay;
 
-	if( fabs(dx) > fabs(dy) && fabs(dx) > 0. )
-	{
-		n = fabs(dx); dx = dx < 0. ? -1. : 1.; dy /= n; dz /= n;
-	}
-	else if( fabs(dy) > 0. )
+	if( fabs(dx) < 1. && fabs(dy) < 1. ) // both end points fall into the same pixel
 	{
-		n = fabs(dy); dy = dy < 0. ? -1. : 1.; dx /= n; dz /= n;
+		_Draw_Pixel((int)ax, (int)ay, az < bz ? az : bz, az < bz ? aColor : bColor);
 	}
 	else
 	{
-		_Draw_Pixel((int)ax, (int)ay, az, aColor);
-		_Draw_Pixel((int)bx, (int)by, bz, bColor);
+		double dz = bz - az; CSG_Colors Colors(2); Colors[0] = aColor; Colors[1] = bColor;
 
-		return;
-	}
+		if( fabs(dx) > fabs(dy) )
+		{
+			dy /= fabs(dx); dz /= fabs(dx);
+			if( dx < 0. ) { dx = ax; ax = bx; bx = dx; } // ax < bx
+			if( ax < 0. ) { ay -= dy * ax; az -= dz * ax; ax = 0.; }
+			if( bx >= m_Image_NX ) { bx = m_Image_NX - 1; }
 
-	//-----------------------------------------------------
-	CSG_Colors Colors(2); Colors[0] = aColor; Colors[1] = bColor;
+			for(double i=0, d=1/(bx-ax); i>=0 &&i<=1; i+=d, ax++, ay+=dy, az+=dz)
+			{
+				_Draw_Pixel((int)ax, (int)ay, az, Colors.Get_Interpolated(i));
+			}
+		}
+		else
+		{
+			dx /= fabs(dy); dz /= fabs(dy);
+			if( dy < 0. ) { dy = ay; ay = by; by = dy; } // ay < by
+			if( ay < 0. ) { ax -= dx * ay; az -= dz * ay; ay = 0.; }
+			if( by >= m_Image_NY ) { by = m_Image_NY - 1; }
 
-	for(double i=0.; i<=n; i++, ax+=dx, ay+=dy, az+=dz)
-	{
-		_Draw_Pixel((int)ax, (int)ay, az, Colors.Get_Interpolated(i / n));
+			for(double i=0., d=1/(by-ay); i>=0 &&i<=1; i+=d, ax+=dx, ay++, az+=dz)
+			{
+				_Draw_Pixel((int)ax, (int)ay, az, Colors.Get_Interpolated(i));
+			}
+		}
 	}
 }
 


=====================================
saga-gis/src/saga_core/saga_gui/man/saga_gui.1
=====================================
@@ -124,7 +124,7 @@
 .\" ========================================================================
 .\"
 .IX Title "SAGA_GUI 1"
-.TH SAGA_GUI 1 "2021-07-07" "9.2.0" " "
+.TH SAGA_GUI 1 "2021-07-07" "9.2.1" " "
 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
 .\" way too many mistakes in technical documents.
 .if n .ad l


=====================================
saga-gis/src/tools/terrain_analysis/ta_morphometry/top_hat.cpp
=====================================
@@ -85,8 +85,8 @@ CTop_Hat::CTop_Hat(void)
 		"Valleys are extracted by the \"Black Top Hat\" (BTH) function:\n\n"
 		"BTH = Closing - DEM >= t\n\n"
 		"The threshold value \"t\" works as an additional cut-off to extract "
-		"only the highest peaks and deepest valleys. This means that the functions permit to "
-		"extract peaks and valleys based on width and height criterions. For details "
+		"only the highest peaks and deepest valleys. This means that the functions permit "
+		"extracting peaks and valleys based on width and height criterions. For details "
 		"see the referenced paper.\n"
 		"The tool is based on the AML script \'tophat\' by Jochen Schmidt, Landcare Research."
 	));


=====================================
saga-gis/version.cmake
=====================================
@@ -1,7 +1,7 @@
 # The version number.
 set (SAGA_VERSION_MAJOR 9)
 set (SAGA_VERSION_MINOR 2)
-set (SAGA_VERSION_PATCH 0)
+set (SAGA_VERSION_PATCH 1)
 
 # get git commit hash (or dirty if git is not installed)
 



View it on GitLab: https://salsa.debian.org/debian-gis-team/saga/-/compare/68831a1340740db9d29885c4409272702407ade2...dd44eec8cc5d0c6783ef1627442dc73044303858

-- 
View it on GitLab: https://salsa.debian.org/debian-gis-team/saga/-/compare/68831a1340740db9d29885c4409272702407ade2...dd44eec8cc5d0c6783ef1627442dc73044303858
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20231214/f1cd4a6d/attachment-0001.htm>


More information about the Pkg-grass-devel mailing list