def __init__(self, *args, **kwargs):
self._ctx = mp.get_context('spawn')
self._conn, child_conn = mp.Pipe()
self._lock = Lock()
args = (child_conn,) + args
self._process = self._ctx.Process(
target=self.processor_class, args=args, kwargs=kwargs)
self._process.start()
评论列表
文章目录