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

Refactor run_protocol #17

Open
wants to merge 3 commits into
base: dev/ond
Choose a base branch
from
Open

Refactor run_protocol #17

wants to merge 3 commits into from

Conversation

nrsyed
Copy link
Collaborator

@nrsyed nrsyed commented May 6, 2021

This PR aims to move the per-round logic to its own method outside of run_protocol to more clearly delineate what's happening within rounds (as opposed to within tests) and to improve readability of the run_protocol method. This refactoring should not change any of the core logic or functionality.

Depends on #14.

@nrsyed nrsyed requested review from waxlamp, cfunk1210 and as6520 and removed request for cfunk1210 May 6, 2021 16:42
Copy link
Member

@waxlamp waxlamp left a comment

Choose a reason for hiding this comment

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

I'm not really qualified to review this, but the code looks ok to me at a glance.

Is there some specific insight I can provide?

@nrsyed
Copy link
Collaborator Author

nrsyed commented May 25, 2021

@waxlamp

I'm not really qualified to review this, but the code looks ok to me at a glance.

Is there some specific insight I can provide?

Nothing specific, just wanted to check if this would make sense (or if it seems unnecessary) from a software engineering and code structure perspective.

if file_list is not None:
features_dict, logits_dict = algorithm.execute(
"FeatureExtraction", file_list
try:
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this be moved in round too? This would require changing the return type of _run_round to bool

pass
else:
(
algo_test_data["features_dict"],
Copy link
Contributor

Choose a reason for hiding this comment

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

I would recommend using update here rather than assigning since you would need to aggregate features across multiple rounds to save them

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.

3 participants