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

Add Driver class #2531

Merged
merged 11 commits into from
Oct 24, 2023
Merged

Add Driver class #2531

merged 11 commits into from
Oct 24, 2023

Conversation

panh99
Copy link
Contributor

@panh99 panh99 commented Oct 19, 2023

Add Driver class in driver/driver.py.

Add unit tests for Driver in driver/driver_test.py

src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
)
return list(res.nodes)

def push_task_ins(self, task_ins_list: Iterable[TaskIns]) -> List[str]:
Copy link
Member

Choose a reason for hiding this comment

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

Let's use List here to be consistent with the argument name (we can generalize to Iterable later):

Suggested change
def push_task_ins(self, task_ins_list: Iterable[TaskIns]) -> List[str]:
def push_task_ins(self, task_ins_list: List[TaskIns]) -> List[str]:

Comment on lines 187 to 189
# Check if task_ids is None
if task_ids is None:
task_ids = list(self.task_id_pool)
Copy link
Member

Choose a reason for hiding this comment

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

Let's remove this utility for now, and leave it up to the user to keep track of task_ids.

src/py/flwr/driver/driver.py Outdated Show resolved Hide resolved
@danieljanes danieljanes enabled auto-merge (squash) October 24, 2023 20:59
@danieljanes danieljanes merged commit dd4779f into main Oct 24, 2023
26 checks passed
@danieljanes danieljanes deleted the add-driver branch October 24, 2023 21:04
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