7

I am running QGIS 3.4.14 on Ubuntu Linux 18.02. I cannot see the SAGA tool in the QGIS Processing window. I can confirm that I have SAGA 7.3 installed and working as a stand-alone GUI application. I have gone into the processing options in QGIS and enabled SAGA as a provider.

This QGIS website states if you are running Linux, SAGA binaries are not included with Processing, so you have to download and install the software yourself. Please check the SAGA website for more information. In this case, there is no need to configure the path to the SAGA executable, and you will not see those folder entries. Instead, you must make sure that SAGA is properly installed and its folder is added to the PATH environment variable. Just open a console and type saga_cmd to check that the system can find where the SAGA binaries are located.

I can confirm sage_cmd will open the command line version of SAGA. I have added PATH="$HOME/bin:$PATH:/opt/saga-7.4.0" to ~/.profile.

Still, I do not see SAGA in the processing window. How do I get the SAGA tool available in QGIS 3.4?

enter image description here

  • as far as I know SAGA is not properly supported at the moment. The version jumps from SAGA make it hard for maintainers to follow. There are at the moment two plugins: Processing SAGA Nextgen Provider and SAGA for Processing from this repository plugins.bruy.me/plugins/plugins.xml but both do not work out of the box due to shifted SAGA versions. Maybe you find a way to couple the stuff, would be also interested in a solution. – Bernd V. Dec 18 '19 at 8:42
  • @Bernd V. Can I install an earlier version of SAGA to work with QGIS 3.4? – GBG Dec 18 '19 at 16:11
2

In QGIS 3.4, the SAGA provider is already a core plugin. Therefore, you can also change the SagaAlgorithmProvider.py file directly, by:

sudo nano /usr/share/qgis/python/plugins/processing/algs/saga/SagaAlgorithmProvider.py

then change the REQUIRED VERSION from 2.3. to 7.3.

This worked for me.

| improve this answer | |
  • Thanks! That worked perfectly. I now have access to the SAGA tools in the Processing Toolbox. – GBG Jan 20 at 23:28
3
+50

I had faced a similar issue but resolved it with saga install. You need to install proper version of SAGA. I installed saga via apt install. SAGA version in Ubuntu 18.04.3 repository work very well with QGIS 3.10

sudo apt install saga

Please confirm that saga_cmd is installed and you get following output enter image description here

Restart QGIS [3.10 in my case] and you should see SAGA installed as shown below. enter image description here

| improve this answer | |
  • Why would you even want to post this as a comment? This is a (possible) solution/answer, and so posting it as an answer is exactly the right thing to do :) . – Senshi Dec 19 '19 at 11:00
  • Thanks for suggestion. I will update it. – programmer punk Dec 19 '19 at 16:55
3

One solution (and far from optimal) working for me is to install Processing from SAGA Nextgen Provider.

At the time this SAGA next gen plugin works only with SAGA 7.2 and won't launch in QGIS if SAGA is the newest version (7.3). But when you unzip the plugin, change the version form '7.2' to '7.3' in provider.py and then reinstall the plugin it works with SAGA 7.3 as well.

I couldn't find a better solution and I haven't tested if everything works (but at least the functions I need are there and working).

| improve this answer | |
  • The trick seems to work, though your guidelines are a bit misleading: You refer to unzipping the plugin, so this implies downloading the source zip, but there is no provider.py. to manipulate. The workflow should be:Install the SAGA Nextgen Provider and then deactivate it by unchecking the checkbox. Then change the version number to 7.3. in provider.py under /.local/share/QGIS/QGIS3/profiles/default/python/plugins/processing_saga_nextgen/processing . Then reactivate the plugin in the plugin manager. Reinstalling as you propose will download a new copy and delete the changes. – Bernd V. Jan 6 at 10:23
  • I download it from Github, then unzipped it, changed it and then zipped it again and installed in GIS as a plugin from zip source. Not the best solution, but it was the way I did it. But I agree I'm not good at explaining things in English and your workflow is much more understandable (and proper I guess). – Eva M. Jan 7 at 10:06
0

I have the same problem and cannot figure out how to fix it. I followed the same small trick with SAGA next gen plugin as proposed by Eva (REQUIRED_VERSION = '7.5.': see also the fundamental Bernd's remark) but without luck. It should be better to say that Saga appears into the QGis Processing Toolbox, I can choose among the plenty of algorithms it offers but no one really works. All of them that I tried, invariably the following message appear:

Execution completed in 0.46 seconds
Results:
{'RESULT': '/tmp/processing_ElfyfX/f77e934e78d54fd6bc26c263f4908282/RESULT.sdat'}

Loading resulting layers
The following layers were not correctly generated.<ul><li>/tmp/processing_ElfyfX/e21085af420a4fdba785ee2fd5df085f/RESULT.sdat</li><li>/tmp/processing_ElfyfX/f77e934e78d54fd6bc26c263f4908282/RESULT.sdat</li></ul>You can check the 'Log Messages Panel' in QGIS main window to find more information about the execution of the algorithm.

Whereas into the QGis Logs nothing relevant (to me) is reported:

2020-03-24T18:11:55     INFO    SAGA execution commands
             grid_filter "Gaussian Filter" -INPUT "/tmp/processing_RVKNkf/2cec97ed5bd742b78f0cb5f513df75d6/base.sgrd" -SIGMA 1 -MODE 1 -RADIUS 3 -RESULT "/tmp/processing_RVKNkf/f934a3c27ab644a18864166d38ce547f/RESULT.sdat"
2020-03-24T18:11:55     INFO    SAGA execution console output
             ____________________________

             ##### ## ##### ##
             ### ### ## ###
             ### # ## ## #### # ##
             ### ##### ## # #####
             ##### # ## ##### # ##
             ____________________________

             SAGA Version: 7.5.0

             Unknown option 'MODE'
             ____________________________
             library path: /usr/lib/saga/
             library name: libgrid_filter
             library : grid_filter
             tool : Gaussian Filter
             identifier : 1
             author : A.Ringeler (c) 2003
             processors : 8 [8]
             ____________________________


             Usage: saga_cmd grid_filter 1 [-INPUT ] [-RESULT ] [-SIGMA ] [-KERNEL_TYPE ] [-KERNEL_RADIUS ]
             -INPUT: Grid
             Grid (input)
             -RESULT: Filtered Grid
             Grid (optional output)
             -SIGMA: Standard Deviation
             Floating point
             Minimum: 0.000100
             Default: 50.000000
             -KERNEL_TYPE: Kernel Type
             Choice
             Available Choices:
             [0] Square
             [1] Circle
             Default: 1
             -KERNEL_RADIUS: Radius
             Integer
             Minimum: 0
             Default: 2
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.