Skip to content

Commit

Permalink
Fixing distribute to send to Process. (#1475)
Browse files Browse the repository at this point in the history
  • Loading branch information
rohinb2 authored Nov 27, 2024
1 parent 7312a89 commit 9431ceb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions runhouse/resources/module.py
Original file line number Diff line number Diff line change
Expand Up @@ -811,15 +811,15 @@ def distribute(
name = name or f"distributed_{self.name}"
pooled_module = DistributedPool(
**distribution_kwargs, name=name, replicas=replicas
).to(self.system, env=self.env.name)
).to(self.system, process=self.env.name)
return pooled_module
elif distribution == "ray":
from runhouse.resources.distributed.ray_distributed import RayDistributed

name = name or f"ray_{self.name}"
ray_module = RayDistributed(
**distribution_kwargs, name=name, module=self
).to(self.system, self.env.name)
).to(system=self.system, process=self.env.name)
return ray_module
elif distribution == "dask":
from runhouse.resources.distributed.dask_distributed import DaskDistributed
Expand All @@ -831,7 +831,7 @@ def distribute(
num_replicas=num_replicas,
replicas_per_node=replicas_per_node,
**distribution_kwargs,
).to(self.system, self.env.name)
).to(system=self.system, process=self.env.name)
return dask_module
elif distribution == "pytorch":
from runhouse.resources.distributed.pytorch_distributed import (
Expand All @@ -846,7 +846,7 @@ def distribute(
name = name or f"pytorch_{self.local.name}"
ptd_module = PyTorchDistributed(
**distribution_kwargs, name=name, replicas=replicas
).to(self.system, env=self.env.name)
).to(system=self.system, process=self.env.name)
return ptd_module

@property
Expand Down

0 comments on commit 9431ceb

Please sign in to comment.