Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix typo #242

Merged
merged 2 commits into from
Oct 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions examples/auxo/aggregator.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,9 @@ def event_monitor(self):
break

# Handle events queued on the aggregator
elif len(self.sever_events_queue) > 0:
elif len(self.server_events_queue) > 0:

client_id, current_event, meta, data = self.sever_events_queue.popleft()
client_id, current_event, meta, data = self.server_events_queue.popleft()
logging.info(f"Event {current_event} is received from client {client_id}")
event_type, cohort_id = decode_msg(current_event)

Expand Down
10 changes: 5 additions & 5 deletions fedscale/cloud/aggregation/aggregator.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def __init__(self, args):

# ======== Event Queue =======
self.individual_client_events = {} # Unicast
self.sever_events_queue = collections.deque()
self.server_events_queue = collections.deque()
self.broadcast_events_queue = collections.deque() # Broadcast

# ======== runtime information ========
Expand Down Expand Up @@ -177,7 +177,7 @@ def init_control_communication(self):
self, self.grpc_server)
port = '[::]:{}'.format(self.args.ps_port)

logging.info(f'%%%%%%%%%% Opening aggregator sever using port {port} %%%%%%%%%%')
logging.info(f'%%%%%%%%%% Opening aggregator server using port {port} %%%%%%%%%%')

self.grpc_server.add_insecure_port(port)
self.grpc_server.start()
Expand Down Expand Up @@ -750,7 +750,7 @@ def add_event_handler(self, client_id, event, meta, data):
data (dictionary): Data transferred in grpc communication, could be model parameters, test result.

"""
self.sever_events_queue.append((client_id, event, meta, data))
self.server_events_queue.append((client_id, event, meta, data))

def CLIENT_REGISTER(self, request, context):
"""FL TorchClient register to the aggregator
Expand Down Expand Up @@ -885,8 +885,8 @@ def event_monitor(self):
break

# Handle events queued on the aggregator
elif len(self.sever_events_queue) > 0:
client_id, current_event, meta, data = self.sever_events_queue.popleft()
elif len(self.server_events_queue) > 0:
client_id, current_event, meta, data = self.server_events_queue.popleft()

if current_event == commons.UPLOAD_MODEL:
self.client_completion_handler(
Expand Down
Loading