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

Create experimental mt-pytorch code example #1446

Merged
merged 4 commits into from
Oct 6, 2022
Merged

Create experimental mt-pytorch code example #1446

merged 4 commits into from
Oct 6, 2022

Conversation

danieljanes
Copy link
Member

No description provided.

Copy link
Member

@tanertopal tanertopal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As all of this is experimental, I only left a note but apart from that lgtm.

Comment on lines +62 to +76
while True:
get_results_req = GetResultsRequest(task_ids=create_tasks_res.task_ids)

# ------------------------------------------------------------------ Driver SDK
get_results_res: GetResultsResponse = driver.get_results(
req=get_results_req
)
# ------------------------------------------------------------------ Driver SDK

results: List[Result] = get_results_res.results
print(f"Got {len(get_results_res.results)} results")

all_results += results
if len(all_results) == len(task_ids):
break
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@danieljanes We don't have an early stop here but as this is all experimental I am just noting my thoughts here :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, also would be cool to use tqdm here too.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that these things would be cool, but my goal was more to create a minimal example here, which is why I'd suggest to keep is focussed :) regarding the early stopping, my assumption was that the server would enforce a timeout on all tasks anyways, so the driver can just wait until it gets either a full result or something that tells it that a particular task did not finish in time.

@danieljanes danieljanes enabled auto-merge (squash) October 6, 2022 12:06
@danieljanes danieljanes merged commit 91d05d0 into main Oct 6, 2022
@danieljanes danieljanes deleted the mt-pytorch branch October 6, 2022 12:16
tanertopal added a commit that referenced this pull request Oct 30, 2022
* main: (21 commits)
  Create Flower tutorial part 3 (#1474)
  Update notebook tutorial (#1470)
  Fixed epoch_loss calculation in intro tutorial (#1472)
  Update notbook tutorials (#1468)
  Update README (#1465)
  Add DP docs to index (#1467)
  Support optional client methods in VCE (#1450)
  Implement Driver create_tasks and get_results (#1451)
  Update FED-0001 wording (#1464)
  Move client-side message handler into a separate package (#1462)
  Documentation for DP-FedAvg wrappers (#1460)
  Ray resources float (#1453)
  Slow down mt-pytorch code example, improve README (#1452)
  Update strategy sequence diagram (#1449)
  Update FedAvg documentation (#1417)
  Fix doc generation warnings (#1448)
  Create experimental mt-pytorch code example (#1446)
  Change case of file which was missed (#1447)
  Implement Driver get_clients (#1445)
  Implement Driver connect/disconnect (#1443)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants