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

feat(framework) Add template to create a Flower Baseline #3979

Merged
merged 29 commits into from
Aug 28, 2024

Conversation

jafermarq
Copy link
Contributor

@jafermarq jafermarq commented Aug 8, 2024

Adds template creation logic for a new Flower Baseline.

Screenshot 2024-08-08 at 16 51 00

It reutilises components from the PoTorch template. It will generate the following directory structure:

.
├── LICENSE
├── README.md
├── mycoolbaseline # name given during `flwr new`
│   ├── __init__.py
│   ├── client_app.py
│   ├── dataset.py
│   ├── model.py
│   ├── models.py
│   ├── strategy.py
│   └── utils.py
└── pyproject.toml

@jafermarq jafermarq changed the title feat(framework) Add template to create a Flower Basline feat(framework) Add template to create a Flower Baseline Aug 12, 2024
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.

Lgtm! I only made one small suggestion for a typo.

Comment on lines 35 to 40
line_length = 88
indent = " "
multi_line_output = 3
include_trailing_comma = true
force_grid_wrap = 0
use_parentheses = true
Copy link
Member

Choose a reason for hiding this comment

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

Isn't there a newer version of this where isort supports a black profile?

Comment on lines +124 to +142
[tool.flwr.app]
publisher = "$username"

[tool.flwr.app.components]
serverapp = "$import_name.server_app:app"
clientapp = "$import_name.client_app:app"

[tool.flwr.app.config]
num-server-rounds = 3
fraction-fit = 0.5
local-epochs = 1

[tool.flwr.federations]
default = "local-simulation"

[tool.flwr.federations.local-simulation]
options.num-supernodes = 10
options.backend.client-resources.num-cpus = 2
options.backend.client-resources.num-gpus = 0.0
Copy link
Member

Choose a reason for hiding this comment

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

Should we perhaps move tool.flwr ahead of all the other configs (the ones we expect users not to edit)?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I thought of keeping it as in the rest of templates and (migrated) examples

@danieljanes danieljanes merged commit d02b81a into main Aug 28, 2024
33 checks passed
@danieljanes danieljanes deleted the add-baselines-template branch August 28, 2024 12:00
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