Skip to content

Comments

Refactor run_protocol#17

Open
nrsyed wants to merge 3 commits intodev/ondfrom
dev/refactor_run_protocol
Open

Refactor run_protocol#17
nrsyed wants to merge 3 commits intodev/ondfrom
dev/refactor_run_protocol

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 as6520, cfunk1210 and waxlamp and removed request for cfunk1210 May 6, 2021 16:42
Copy link
Contributor

@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