MCPcopy Create free account
hub / github.com/deepspeedai/DeepSpeed / _close_pool

Method _close_pool

tests/unit/common.py:361–365  ·  view source on GitHub ↗
(self, pool, num_procs, force=False)

Source from the content-addressed store, hash-verified

359 dist.destroy_process_group()
360
361 def _close_pool(self, pool, num_procs, force=False):
362 if force or not self.reuse_dist_env:
363 pool.starmap(self._dist_destroy, [() for _ in range(num_procs)])
364 pool.close()
365 pool.join()
366
367
368class DistributedFixture(DistributedExec):

Callers 2

pytest_runtest_teardownFunction · 0.80

Calls 1

closeMethod · 0.45

Tested by 1

pytest_runtest_teardownFunction · 0.64