Answers for "pool does not print process id"

0

pool does not print process id

import multiprocessing

def f(x):
    print multiprocessing.current_process()
    return x * x

p = multiprocessing.Pool()
print p.map(f, range(6))
Posted by: Guest on October-18-2021

Python Answers by Framework

Browse Popular Code Answers by Language