[Task Runner API] [Flower Interoperability] Pull ConnectorFlower, FlowerTaskRunner/FlowerDataLoader, and FlowerInteropServer/FlowerInteropClient into core OpenFL#1633
Merged
teoparvanov merged 33 commits intosecurefederatedai:developfrom May 22, 2025
Conversation
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
… local_grpc_server to interop_server Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
3 tasks
Signed-off-by: kta-intel <kevin.ta@intel.com>
… default location and use openfl's directory traversal check Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
ConnectorFlower, FlowerTaskRunner/FlowerDataLoader, and FlowerInteropServer/FlowerInteropClient into core OpenFLConnectorFlower, FlowerTaskRunner/FlowerDataLoader, and FlowerInteropServer/FlowerInteropClient into core OpenFL
Signed-off-by: kta-intel <kevin.ta@intel.com>
Signed-off-by: kta-intel <kevin.ta@intel.com>
teoparvanov
approved these changes
May 21, 2025
Collaborator
teoparvanov
left a comment
There was a problem hiding this comment.
This is great, thanks @kta-intel !
ishaileshpant
pushed a commit
to ishaileshpant/openfl
that referenced
this pull request
May 29, 2025
…FlowerTaskRunner`/`FlowerDataLoader`, and `FlowerInteropServer`/`FlowerInteropClient` into core OpenFL (securefederatedai#1633) * integrate flower collaborator into core collaborator Signed-off-by: kta-intel <kevin.ta@intel.com> * formatting Signed-off-by: kta-intel <kevin.ta@intel.com> * change task name interop -> prepare_for_interop, change references to local_grpc_server to interop_server Signed-off-by: kta-intel <kevin.ta@intel.com> * add prepare_interop_server as callback to run on_experiment_begin Signed-off-by: kta-intel <kevin.ta@intel.com> * fix typo Signed-off-by: kta-intel <kevin.ta@intel.com> * change to on_round_begin() Signed-off-by: kta-intel <kevin.ta@intel.com> * return empty dict Signed-off-by: kta-intel <kevin.ta@intel.com> * set self.prepare_interop_server() to run on experiment begin Signed-off-by: kta-intel <kevin.ta@intel.com> * remove self-explanatory comment, added another comment for clarity Signed-off-by: kta-intel <kevin.ta@intel.com> * fix plan parsing and automatic assignment of grpc ports Signed-off-by: kta-intel <kevin.ta@intel.com> * move taskrunner and dataloader to core openfl.federated Signed-off-by: kta-intel <kevin.ta@intel.com> * move connector and interop components to core openfl Signed-off-by: kta-intel <kevin.ta@intel.com> * remove comments about patch Signed-off-by: kta-intel <kevin.ta@intel.com> * remove collaborator number setting, it is not being used Signed-off-by: kta-intel <kevin.ta@intel.com> * adjust handling of flower directory. enabling user configuration with default location and use openfl's directory traversal check Signed-off-by: kta-intel <kevin.ta@intel.com> * exit system if error Signed-off-by: kta-intel <kevin.ta@intel.com> * update REAMDE.md Signed-off-by: kta-intel <kevin.ta@intel.com> * update docstring Signed-off-by: kta-intel <kevin.ta@intel.com> * override self.port Signed-off-by: kta-intel <kevin.ta@intel.com> * remove tasks_connector.yaml Signed-off-by: kta-intel <kevin.ta@intel.com> * updates Signed-off-by: kta-intel <kevin.ta@intel.com> * pin flwr Signed-off-by: kta-intel <kevin.ta@intel.com> * remove time Signed-off-by: kta-intel <kevin.ta@intel.com> * formatting Signed-off-by: kta-intel <kevin.ta@intel.com> * formatting Signed-off-by: kta-intel <kevin.ta@intel.com> * formatting Signed-off-by: kta-intel <kevin.ta@intel.com> * copyright Signed-off-by: kta-intel <kevin.ta@intel.com> --------- Signed-off-by: kta-intel <kevin.ta@intel.com> Co-authored-by: teoparvanov <teodor.parvanov@intel.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note: This PR is a branch from #1598 so it includes
Collaboratorrelated commits that'll be mostly discarded once that PR is pulled and this one is rebased. The reason for the relatively large PR compared to the aggregator and collaborator PRs is because these had some interdependencies that was easier to handle at once.flower-app-pytorchworkspace's customAggregatorinto core component #1585Summary
This PR pulls in the
ConnectorFlower, related interop components (FlowerInteropServer&FlowerInteropClient), and theFlowerTaskRunner&FlowerDataLoaderback into core OpenFL as well as provides consistency in how gRPC ports are handled using theautokey and a hash of the plan (ref: #1433 (comment))Type of Change (Mandatory)
Specify the type of change being made.
Description (Mandatory)
ConnectorFlowerconnector.yaml->connector_flower.yamlplan.yamlintoconnector_flower.yamland set some of the ports toautoConnectorFlowerto reflect the new yaml key hierarchy (no longer embedded undersuperlink_paramsandflwr_run_params- this was necessary to be able to modify a subset of the default values without needing to include all the values inplan.yamlflwr_dirto the plan, which sets theFLWR_HOMEdirectory (important for SGX and general security or else flower will build their app outside the workspace inside of /.flwr)FlowerInteropServer/FlowerInteropClientFlowerInteropServerto add the automatically set port instead of dynamically adjust it itselfFlowerTaskRunner/FlowerDataLoadertask_connector.yaml->task_flower.yamlfrom openfl.utilities.utils import generate_portflwr_dirto the Task Runner plan, which sets theFLWR_HOMEdirectory (important for SGX and general security or else flower will build their app outside the workspace inside of /.flwr)install_flower_FABto reflect new handling offlwr_dirand to minimize directory traversalgenerate_port()which uses the same logic when getting theagg_portduring the plan resolve in order to also auto generate gRPC ports for the connector/interop components. Updates openfl/federated/plan/plan.py to reflect this when initially resolving the plan<workspace>/src/util/is_safe_path()and using OpenFL's built-inis_directory_traversal()Testing
Manual in non-SGX and SGX