Ejemplo n.º 1
0
    def __init__(self, *args, **kwargs):
        """Constructor

        Warn if the user specified multiprocessing.
        """
        TaskRunner.__init__(self, *args, **kwargs)
        if self.numProcesses > 1:
            self.log.warn("Multiprocessing arguments (-j %d) ignored since using batch processing" %
                          self.numProcesses)
            self.numProcesses = 1
Ejemplo n.º 2
0
    def __init__(self, *args, **kwargs):
        """Constructor

        Warn if the user specified multiprocessing.
        """
        TaskRunner.__init__(self, *args, **kwargs)
        if self.numProcesses > 1:
            self.log.warn("Multiprocessing arguments (-j %d) ignored since using batch processing" %
                          self.numProcesses)
            self.numProcesses = 1
Ejemplo n.º 3
0
    def __call__(self, cache, args):
        """Run the Task on a single target

        Strips out the process pool 'cache' argument.

        'args' are those arguments provided by the getTargetList method.

        Brings down the entire job if an exception is not caught (i.e., --doraise).
        """
        return TaskRunner.__call__(self, args)
Ejemplo n.º 4
0
    def __call__(self, cache, args):
        """Run the Task on a single target

        Strips out the process pool 'cache' argument.

        'args' are those arguments provided by the getTargetList method.

        Brings down the entire job if an exception is not caught (i.e., --doraise).
        """
        return TaskRunner.__call__(self, args)
Ejemplo n.º 5
0
 def __init__(self, TaskClass, parsedCmd, doReturnResults=False):
     TaskRunner.__init__(self, TaskClass, parsedCmd, doReturnResults)
Ejemplo n.º 6
0
 def getTargetList(parsedCmd, **kwargs):
     """Task.runDataRef should receive a butler in the kwargs"""
     return TaskRunner.getTargetList(parsedCmd,
                                     butler=parsedCmd.butler,
                                     **kwargs)
Ejemplo n.º 7
0
 def getTargetList(parsedCmd, **kwargs):
     return TaskRunner.getTargetList(
         parsedCmd, selectDataList=parsedCmd.selectId.dataList, **kwargs)
Ejemplo n.º 8
0
 def getTargetList(parsedCmd, **kwargs):
     return TaskRunner.getTargetList(parsedCmd,
                                     calibType=parsedCmd.calibToTest,
                                     **kwargs)
Ejemplo n.º 9
0
 def __init__(self, TaskClass, parsedCmd, doReturnResults=True):
     TaskRunner.__init__(self, TaskClass, parsedCmd, doReturnResults)
     self.butler = parsedCmd.butler
Ejemplo n.º 10
0
 def getTargetList(parsedCmd, **kwargs):
     """Task.run should receive a butler in the kwargs"""
     return TaskRunner.getTargetList(parsedCmd, butler=parsedCmd.butler, **kwargs)