[Qgis-user] Running script from Sextante toolbox

Victor Olaya volayaf at gmail.com
Fri Jan 11 01:58:45 PST 2013


a few things:

1)SEXTANTE will add the imports it needs, so if you are just calling
another algorithm (a model in this case), there is no need to import
anything

2) if you are using 1.0.8, then that syntax is ok. If you are using
the current development version of SEXTANTE from the Github repo
(along with QGIS 1.9), you should use the new syntax, a bit more
pythonic one (see [1])

4) can you share you model so we can try to reproduce the problem and fix it?

3) Your script just calls your model with a fixed value, right? You
can do that with another model, calling the first model but
hard-coding a value. Maybe you find that easier to do.

Hope this helps

Thanks for using SEXTANTE.
Victor


[1]http://docs.qgis.org/html/en/docs/user_manual/sextante/console.html


2013/1/11 G. Allegri <giohappy at gmail.com>:
> Hi Jonas,
> could you share your model?
> Regarding not having imports inside scripts, it's because Sextante will do
> it for you. A script is "expanded" by Sextante on the fly, it will push more
> lines of code (e.g. imports) and then execute it.
>
> giovanni
>
> 2013/1/11 Jonas Sjögren <jonas.sjo at gmail.com>
>>
>> Modeler:CalculateFloodedAreas
>
>
>
>
>
> --
> --
> Giovanni Allegri
> website: http://giovanniallegri.it
> GEO+ geomatica in Italia http://bit.ly/GEOplus
>
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-user
>



More information about the Qgis-user mailing list