I am trying to build a parallelized task where aset of calculations happen in paraller with different set o parameters. Then in each of these independent tasks there are some while loops that for each of these tasks run through a lit of parameters.
The result of each parallelized task is saved in a csv file. However the while loops seem to not progress each parallelized task stops at the first iteration of the while loop.
Any possible explanations for that?
The actual code is way to big to post here but an abstraction could be this:
def inner_func(a,b):
while a<b:
write_to_file(a)
a++
if __name__ == '__main__':
arguments=[(a,b),(b,c)]
with multiprocessing.Pool(processes=6) as pool:
pool.map(inner_func, arguments)
