diff --git a/CEP/Pipeline/recipes/sip/master/imager_awimager.py b/CEP/Pipeline/recipes/sip/master/imager_awimager.py index 90bda7e4d312b10136d0a7fa5329cde9043ce3e3..ef8c926e061adba69da1fb61d0318a057caec7d8 100644 --- a/CEP/Pipeline/recipes/sip/master/imager_awimager.py +++ b/CEP/Pipeline/recipes/sip/master/imager_awimager.py @@ -38,6 +38,11 @@ class imager_awimager(BaseRecipe, RemoteCommandRecipeMixIn): '-p', '--parset', help = "The full path to a awimager configuration parset." ), + 'nthreads': ingredient.IntField( + '--nthreads', + default=8, + help="Number of threads per process" + ), 'working_directory': ingredient.StringField( '-w', '--working-directory', help = "Working directory used on output nodes. Results location" @@ -144,7 +149,10 @@ class imager_awimager(BaseRecipe, RemoteCommandRecipeMixIn): self.inputs['fov'], ] - jobs.append(ComputeJob(host, node_command, arguments)) + jobs.append(ComputeJob(host, node_command, arguments, + resources={ + "cores": self.inputs['nthreads'] + })) self._schedule_jobs(jobs) # ********************************************************************* diff --git a/CEP/Pipeline/recipes/sip/tasks.cfg.in b/CEP/Pipeline/recipes/sip/tasks.cfg.in index 5d6d46b8fb8c76200b44616a2e79fd513bd9992b..0cb43042787da8558dc0a9b26b0ad7ae930bde1e 100644 --- a/CEP/Pipeline/recipes/sip/tasks.cfg.in +++ b/CEP/Pipeline/recipes/sip/tasks.cfg.in @@ -77,6 +77,7 @@ nthreads = 8 [imager_awimager] recipe = imager_awimager executable = %(lofarroot)s/bin/awimager +nthreads = 8 [imager_create_dbs] recipe = imager_create_dbs