Python Multiprocessing With Boolean And Multiple Arguments
I have a function that takes multiple arguments, some of which are boolean. I'm trying to pass this to the multiprocessing pool.apply_async and want to pass some args with the name
Solution 1:
apply_async has args
and kwds
keyword arguments which you could use like this:
res = p.apply_async(testFunc, args=(2, 4), kwds={'calcY': False})
Post a Comment for "Python Multiprocessing With Boolean And Multiple Arguments"