def __init__(self, threads_num, max_tasks=<NUM_LIT:0>, collect_results=False):
self.tasks = Queue(max_tasks)<EOL>self.collect_results = collect_results<EOL>self.results = []<EOL>self.threads = []<EOL>for _ in range(threads_num):<EOL><INDENT>self.threads.append(ThreadWorker(self))<EOL><DEDENT>
create a pool of workers, run tasks, collect results
        :param threads_num: number of workers
        :param max_tasks: limit the tasks queue
        :param collect_results: you can collect results from your workers

        :type threads_num: int
        :type max_tasks: int
        :type collect_results: bool