"...git@developer.sourcefind.cn:renzhc/diffusers_dcu.git" did not exist on "cf4227cd1e1a361aaf26109f2e970aa9abb620b7"
Commit 38958fcc authored by Yanghan Wang's avatar Yanghan Wang Committed by Facebook GitHub Bot
Browse files

fix DDP argument misalignment

Summary:
X-link: https://github.com/facebookresearch/mobile-vision/pull/83

Pull Request resolved: https://github.com/facebookresearch/d2go/pull/292

Reviewed By: tglik, newstzpz

Differential Revision: D37116726

fbshipit-source-id: 9956fe19916521b4fb512207512861afe4f09148
parent 0c08a245
...@@ -43,13 +43,13 @@ def distributed_worker( ...@@ -43,13 +43,13 @@ def distributed_worker(
args: Tuple[Any, ...], args: Tuple[Any, ...],
kwargs: Dict[str, Any], kwargs: Dict[str, Any],
backend: str, backend: str,
dist_url: Optional[str] = None, init_method: Optional[str] = None,
dist_params: Optional[DistributedParams] = None, dist_params: Optional[DistributedParams] = None,
return_save_file: Optional[str] = None, return_save_file: Optional[str] = None,
timeout: timedelta = DEFAULT_TIMEOUT, timeout: timedelta = DEFAULT_TIMEOUT,
): ):
dist_params = dist_params or DistributedParams.from_environ() dist_params = dist_params or DistributedParams.from_environ()
with enable_dist_process_groups(backend, dist_url, dist_params, timeout): with enable_dist_process_groups(backend, init_method, dist_params, timeout):
d2_comm._LOCAL_PROCESS_GROUP = mcv_comm._LOCAL_PROCESS_GROUP d2_comm._LOCAL_PROCESS_GROUP = mcv_comm._LOCAL_PROCESS_GROUP
# Now the D2's comm module should be fully functional # Now the D2's comm module should be fully functional
deco = save_return_deco(return_save_file, dist_params.global_rank) deco = save_return_deco(return_save_file, dist_params.global_rank)
......
...@@ -57,7 +57,7 @@ def enable_ddp_env(func): ...@@ -57,7 +57,7 @@ def enable_ddp_env(func):
args=args, args=args,
kwargs=kwargs, kwargs=kwargs,
backend="gloo", backend="gloo",
dist_url="file:///tmp/detectron2go_test_ddp_init_{}".format( init_method="file:///tmp/detectron2go_test_ddp_init_{}".format(
uuid.uuid4().hex uuid.uuid4().hex
), ),
dist_params=DistributedParams( dist_params=DistributedParams(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment