[Qgis-developer] Re: QGIS Processing Framework

Camilo Polymeris cpolymeris at gmail.com
Mon Mar 26 14:49:26 EDT 2012

On Thu, Mar 22, 2012 at 5:31 AM, Martin Dobias <wonder.sk at gmail.com> wrote:
> On Wed, Mar 21, 2012 at 7:23 PM, CzendaZdenda <tramtara at seznam.cz> wrote:
>> If there is possibility that output parameter of the module can have any
>> type, how can I handle with modules' outputs? Or just raster/vector layers
>> are outputs?
>> I mean how can I keep outputs after execution of module (
>> processing.Framework['module'].execute() ). I am working on 'workflow
>> builder'. I can connect modules or set values by myself. Now I want execute
>> whole 'graph', so that's why I need to keep outputs.
>> I was looking at present modules and types of output are just raster/vector
>> layers or the basic type Parameter. So is there possibility that output type
>> could be something like string, bool, int...?
> Hi,
> in my view any parameter type that could be specified as an input
> should be allowed also for output - not just layers. For example: a
> module that does statistics on a layer and returns mean and standard
> deviation - these would be just two scalar output values and could be
> used by some other module. In general, both inputs and outputs should
> ideally be treated the same way: they are variables (parameters) of
> some type and with some value.

Sure, that is the intention and is reflected as such in the processing
framework. (Every  Parameter type can be a

The SAGA backend doesn't handle every possible combination, yet,
because either there is no need (not used by any modules) or because
there are outstanding issues (e.g. still don't know what to do if
running a module would overwrite a layer... ask the user? fail?
succeed, but create a backup?)

So, yes, you should be able to connect any output of compatible type
to any input in your module builder. E.g. the standard deviation in
Martin's example could be used as an input to some other module.

Perhaps we could at some point also create a control & arithmetics
module set to complement the module builder, I can imagine you'll
often want that stdev scaled by some amount, for example.


More information about the Qgis-developer mailing list