File tree Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Expand file tree Collapse file tree 2 files changed +4
-6
lines changed Original file line number Diff line number Diff line change 27
27
handler = logging .StreamHandler ()
28
28
_log .addHandler (handler )
29
29
30
- # Set start method to forkserver for MacOS to enable multiprocessing
31
- # Closes issue https://github.com/pymc-devs/pymc3/issues/3849
32
- sys = platform .system ()
33
- if sys == "Darwin" :
34
- new_context = mp .get_context ("forkserver" )
35
-
36
30
37
31
def __set_compiler_flags ():
38
32
# Workarounds for Theano compiler problems on various platforms
Original file line number Diff line number Diff line change 20
20
import pickle
21
21
from collections import namedtuple
22
22
import traceback
23
+ import platform
23
24
from pymc3 .exceptions import SamplingError
24
25
25
26
import numpy as np
@@ -420,6 +421,9 @@ def __init__(
420
421
raise ValueError ("Number of seeds and start_points must be %s." % chains )
421
422
422
423
if mp_ctx is None or isinstance (mp_ctx , str ):
424
+ # Closes issue https://github.com/pymc-devs/pymc3/issues/3849
425
+ if platform .system () == 'Darwin' :
426
+ mp_ctx = "forkserver"
423
427
mp_ctx = multiprocessing .get_context (mp_ctx )
424
428
425
429
step_method_pickled = None
You can’t perform that action at this time.
0 commit comments