File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1616from sourcefinder .utility import containers
1717from sourcefinder .utility .uncertain import Uncertain
1818import psutil
19- from multiprocessing import Pool
19+ import multiprocessing
2020from functools import cached_property
2121from functools import partial
2222
2323from scipy import ndimage
2424from numba import guvectorize , float32 , int32
2525import os
2626
27+ multiprocessing .set_start_method ("forkserver" , force = True )
28+
2729logger = logging .getLogger (__name__ )
2830
2931
@@ -1205,7 +1207,7 @@ def _pyse(
12051207 )
12061208
12071209 if self .conf .image .allow_multiprocessing :
1208- with Pool (psutil .cpu_count ()) as p :
1210+ with multiprocessing . Pool (psutil .cpu_count ()) as p :
12091211 fit_results = p .map (fit_islands_partial , island_list )
12101212 else :
12111213 fit_results = [fit_islands_partial (island ) for island in
Original file line number Diff line number Diff line change 11import os
22from pathlib import Path
33import warnings
4- import multiprocessing
54
65DEFAULT = str ((Path (__file__ ).parent / "data" ).absolute ())
76DATAPATH = os .environ .get ("TKP_TESTPATH" , DEFAULT )
87
9- multiprocessing .set_start_method ("forkserver" , force = True )
10-
118if not os .access (DATAPATH , os .X_OK ):
129 warnings .warn (f"can't access { DATAPATH } " )
You can’t perform that action at this time.
0 commit comments