Re: [GRASS-dev] pyGRASS: ParallelModuleQueue

2016-11-30 Thread Sören Gebbert
2016-11-30 13:59 GMT+01:00 Martin Landa : > Hi, > > 2016-11-30 13:29 GMT+01:00 Martin Landa : > > Wouldn't make sense to add something like _progress=True. Then module > > could call msgr.percent() automatically when it finish. > > > >

Re: [GRASS-dev] pyGRASS: ParallelModuleQueue

2016-11-30 Thread Martin Landa
Hi, 2016-11-30 13:29 GMT+01:00 Martin Landa : > Wouldn't make sense to add something like _progress=True. Then module > could call msgr.percent() automatically when it finish. > > queue.percent(5, count) # print each 5% > module = Module(..., _run=False, _progress=5) > for

Re: [GRASS-dev] pyGRASS: ParallelModuleQueue

2016-11-30 Thread Martin Landa
Hi, 2016-11-30 13:00 GMT+01:00 Pietro : > Yes, I think so, if you pass the stderr_=subprocess.PIPE and > stdout_=subprocess.PIPE parameters to the module, then you should be > able to write the current percentage using grass.percent() or > msgr.percent(). yes, but then you

Re: [GRASS-dev] pyGRASS: ParallelModuleQueue

2016-11-30 Thread Pietro
Hi Martin, On Wed, Nov 30, 2016 at 12:25 PM, Martin Landa wrote: > is it possible to use progress info when using ParallelModuleQueue? > Something similar to grass.percent(). Eg. Yes, I think so, if you pass the stderr_=subprocess.PIPE and stdout_=subprocess.PIPE

[GRASS-dev] pyGRASS: ParallelModuleQueue

2016-11-30 Thread Martin Landa
Hi, is it possible to use progress info when using ParallelModuleQueue? Something similar to grass.percent(). Eg. """ grass.message("Clipping...") for name in maps: new_mapcalc = copy.deepcopy(mapcalc_module)