是否可以将并发.futures(ProcessPoolExecutor)与pathos一起使用?
问这个是因为当我尝试使用时:
with concurrent.futures.ProcessPoolExecutor() as executor:
Run Code Online (Sandbox Code Playgroud)
... 执行器.map()
我会得到:
PicklingError:无法 pickle:属性查找 内置.function 失败
我知道我们可以使用 pathos.multiprocess 来代替默认的多进程,并解决像这样的一些问题,问题是当我尝试使用 futures 实现并行处理时,我无法设置解决方案来修复 pickle 错误感伤。
任何想法 ?
谢谢。