Closed yaojian95 closed 3 years ago
Dealing with what pools can and can't pass back is always a super pain. I notice that you are defining dynesty
as a function call within a class while also importing it. Could this be causing some of the issues?
I tried to change the function name in the class and the error remains...
I'm not an expert in dealing with pool pickling issues, unfortunately, so I don't have too much specific advice I can give here other than maybe trying to define your functions directly rather than as features of a class and/or just assigning the pool at a higher level. Sorry I can't provide more help!
Thanks for your reply anyway. I will try to do some research on this topic and let you know if I have some progress.
Hi, I recently wrap the dynesty functions, with
Pool
to get things parallelled, into a pipeline such asbut get the error.
I realized that the Pool from multiprocessing can only work for top-level functions and the error happens when I wrap the dynesty sampler into a class, could you give some suggestions on how to solve this?