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

[WIP] Support hpo in distributed #524

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

rayrayraykk
Copy link
Collaborator

@rayrayraykk rayrayraykk commented Feb 15, 2023

I add a function of sending cfg before starting for run HPO in distributed mode. But it's not enough to change self._cfg when the client receives a new configuration because some instances are created based on old cfg, and we need to add a reset method for the worker to achieve this, just as the trainer does, see

And due to the limitations of gRPC, some vFL model and feature engineering methods can't work properly for the type of message might vary. In order to send such data, we may need a module for type conversion.

@xieyxclack @joneswong

@rayrayraykk rayrayraykk added the FedHPO FedHPO related label Feb 15, 2023
if sender == self.server_id and self._cfg.hpo.use:
logger.info("Receive a new `cfg`, and start to reinitialize.")
self._cfg.defrost()
# TODO: Some var might remain unchanged
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We should add a reset() function to solve this.

config=init_cfg.clone(),
client_configs=client_cfgs)
_ = runner.run()
if init_cfg.hpo.use:
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We'd better use a fake optimizer to wrap this runner in the client to avoid a mismatch in sampled configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FedHPO FedHPO related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant