I have some code in python 3.6 which is like this:
from multiprocessing import Pool
with Pool(processes=4) as p:
p.starmap(parallel_function, list(dict_variables.items()))
Here dict_variables looks like this:
[('aa', ['ab', 'ab', 'ad']), ('aa1', ['a1b', 'a1b', 'a2d'])]
This code only works in python 3.6. How can I make it work in 2.7?