'Run the iteration.'

def Run(self):

    count = 0
    for (count, input_data) in enumerate(self.GetInput()):
        if ((count % 2000) == 0):
            logging.debug('%d    processed.', count)
        args = (input_data, self.out_queue, self.token)
        self.thread_pool.AddTask(target=self.IterFunction, args=args, name=self.THREAD_POOL_NAME)
    while (count >= 0):
        try:
            out = self.out_queue.get(timeout=self.QUEUE_TIMEOUT, block=True)
            if out:
                (yield out)
                count -= 1
        except Queue.Empty:
            break
    self.thread_pool.Stop()
