Skip to content

Commit c3436fe

Browse files
authored
Merge pull request #2101 from FedML-AI/alexleung/dev_branch_latest
[CoreEngine] make the cloud server id work.
2 parents 02c9187 + 162f759 commit c3436fe

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

python/fedml/computing/scheduler/scheduler_core/account_manager.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def build_agent_args(self, user_id, api_key=None, device_id=None, os_name=None,
138138
device_id_suffix = FedMLAccountManager.DEVICE_ID_SUFFIX_CLOUD_AGENT
139139
is_master = True
140140
elif role == FedMLAccountManager.ROLE_CLOUD_SERVER:
141-
device_id_suffix = FedMLAccountManager.DEVICE_ID_SUFFIX_CLOUD_SERVER
141+
device_id_suffix = ""
142142
is_master = True
143143
elif role == FedMLAccountManager.ROLE_EDGE_DEVICE:
144144
device_id_suffix = FedMLAccountManager.DEVICE_ID_SUFFIX_EDGE_DEVICE
@@ -193,6 +193,8 @@ def build_agent_args(self, user_id, api_key=None, device_id=None, os_name=None,
193193
docker_tag = FedMLAccountManager.DEVICE_ID_DOCKER_HUB_TAG if is_from_fedml_docker_hub else docker_tag
194194
unique_device_id = f"{self.agent_args.current_device_id}@{self.agent_args.os_name}" \
195195
f"{docker_tag}{device_id_suffix}"
196+
if role == FedMLAccountManager.ROLE_CLOUD_SERVER:
197+
unique_device_id = self.agent_args.current_device_id
196198

197199
# Set the unique device id
198200
self.agent_args.is_from_docker = is_from_docker or is_from_fedml_docker_hub

0 commit comments

Comments
 (0)