Skip to content

Commit

Permalink
Merge pull request #99 from lsst/tickets/DM-27631
Browse files Browse the repository at this point in the history
Use multiprocessing context with fork method
  • Loading branch information
brianv0 committed Nov 17, 2020
2 parents f820c27 + 7cb9bfc commit 420dc53
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion python/lsst/ctrl/mpexec/mpGraphExecutor.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,9 @@ def start(self, butler, quantumExecutor):
butler_pickle = pickle.dumps(butler)
taskDef = self.taskDef
quantum = self.qnode.quantum
self.process = multiprocessing.Process(
# Use fork for multiprocessing start method on all platforms
mp_ctx = multiprocessing.get_context("fork")
self.process = mp_ctx.Process(
target=self._executeJob,
args=(quantumExecutor, taskDef, quantum, butler_pickle),
name=f"task-{self.index}"
Expand Down

0 comments on commit 420dc53

Please sign in to comment.