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

FedGraphnn -- wandb utilization #2025

Open
pleonidou opened this issue Apr 8, 2024 · 2 comments
Open

FedGraphnn -- wandb utilization #2025

pleonidou opened this issue Apr 8, 2024 · 2 comments

Comments

@pleonidou
Copy link

Hi, I would like to ask if there is an option to use the fedgraphnn examples with ego networks for node classification without the wandb?

I would like to store the results per client and server aggregation locally.

I am referring to this example: https://github.com/FedML-AI/FedML/tree/master/python/examples/federate/prebuilt_jobs/fedgraphnn/ego_networks_node_clf

@fedml-dimitris
Copy link
Contributor

fedml-dimitris commented Apr 9, 2024

Hello @pleonidou thank you for reaching out. You can store any custom results you need either at the aggregator or the client side, by extending the following functions:

Aggregator: https://github.com/FedML-AI/FedML/blob/master/python/examples/federate/prebuilt_jobs/fedgraphnn/ego_networks_node_clf/trainer/federated_nc_aggregator.py#L25

The test_all() function in the aggregator is executed at the end of every federation round.

Client: https://github.com/FedML-AI/FedML/blob/master/python/examples/federate/prebuilt_jobs/fedgraphnn/ego_networks_node_clf/trainer/federated_nc_trainer.py#L22

The train() function at the client is executed at the beginning of the federation round and the test() function at the end of local training.

For overriding the wandb functionality you can refer to this line here: https://github.com/FedML-AI/FedML/blob/master/python/examples/federate/prebuilt_jobs/fedgraphnn/ego_networks_node_clf/trainer/federated_nc_aggregator.py#L43

In general, you can also use the fedml.log() functionality to record your custom metrics, but by extending the functionality as described above in both the aggregator and the client class you have more control on what is being recorded.

@pleonidou
Copy link
Author

pleonidou commented Apr 9, 2024 via email

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

No branches or pull requests

2 participants