[GRASS-user] r.resamp.* and CPU usage

Markus Metz markus.metz.giswork at gmail.com
Mon Jun 20 00:56:14 PDT 2016


On Tue, Jun 14, 2016 at 12:12 PM, Blumentrath, Stefan
<Stefan.Blumentrath at nina.no> wrote:
> Hi,
>
>
>
> I am trying to resample a DEM using either r.resamp.rst or r.resamp bspline
> on a server where I share resources with my colleagues.
>
> Both modules take almost 100% of the CPU (meaning all cores get busy).

When you use time, 100% of CPU means one core is fully used. Two fully
used cores would be reported by time as 200%. Both modules use only a
single core. lib/gmath used by r.resamp bspline might use more cores
if GRASS has been compiled with openmp, but for r.resamp.bspline you
would only see a marginal increase in CPU usage above 100%.

> Can I
> somehow control/limit the number of cores GRASS modules are allowed to use?

Only very few GRASS modules can use more than one core. For openmp,
you can control the number of cores with

setenv OMP_NUM_THREADS X

for pthread used with lib/gis

setenv WORKERS X

with X being the maximum number of allowed threads.

HTH,

Markus M


>
>
>
> Cheers
>
> Stefan
>
>
> _______________________________________________
> grass-user mailing list
> grass-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user


More information about the grass-user mailing list