Open vvoelz opened 3 years ago
Python 3.8 multiprocessing get_context() function Application for ctx = mp.get_context() I will make sure this is fixed for the "big merge" of most recent src code for biceps 2.0 manuscript. For now, we will have to assume version Python 3-3.7 for multiprocessing to work.
EDIT:
Fixed bug for Python 3.8 by satisfying positional argument: 'ctx'
Here's what I tried:
if version < 3.8: process = p.Process(target=function, args=(iter,))
## FIXME: Python >= 3.8: For some reason this isn't working anymore?!?!
if version >= 3.8: process = p.Process(target=function, args=(iter,), ctx=mp.get_context(method='fork'))
Still searching here for an alternate solution.
As a side note, there may be complications using multiprocessing between platforms.
In trying to run the example code for albocycline, I run into an error with the multiprocessing commands. My guess is that something must have changed with the classes used in
multiprocessing
in newer python versions. I'm using Python 3.8.3