Replies: 1 comment
-
Additional contextThis enhancement shall be based on following Requirements & Guidelines:
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe.
The issue related to , where the User encountered a problem while importing user-defined modules in Jupyter notebooks while running a
FederatedRuntimeexperimentIn the current implementation of Workflow API, jupyter notebook is expected to define the Federated Learning experiment in it's entirety. If the user attempts to import a user defined module from a different python script it will fail due to following reasons:
generated_workspacedoes not contain the user defined codeModuleNotFoundErrorfailure during execution on participants in a distributed infrastructureDescribe the solution you'd like
Enable users to import helper functions from a separate python script. For e.g. FL experiment tutorial:
crowd_guard.ipynbis importing some helper functions / classes from user-defined scriptvalidation.pyin a folderworkspacevalidation.py (contains helper class)
CrowdGuard.ipynb (Jupyter notebook for Workflow API experiment)
To support this use case, existing export process in
notebook_toolsneeds to be enhanced togenerated_workpaceThis shall ensure that
generated_workspace(shown below) includes all user-defined code and ensure that it works on the distributed infrastructureDescribe alternatives you've considered
N.A.
Additional context
This enhancement shall be based on following Requirements & Guidelines:
Export Directives
#| exportdirective as the first line#| exportdirectives are required to export the user-defined imports to exported script and further processingUser-defined scripts should not install any packages:
requirements.txtfor the FL experiment, User-defined scripts are not analyzed by the infrastructure to identify dependenciesLocation of User defined python scripts:
generate_workspacesys.path, which is not recommended and can lead to inconsistency across distributed systemsys.pathExample:
Restrictions on User-defined imports
sys.pathto enable python to find the scripts to import. For e.g.User-defined imports should be self-contained:
User defined code should not import other user-defined code from different python scripts. For e.g.
utils.py (contains additional helper functions)
validation.py (contains helper functions)
Beta Was this translation helpful? Give feedback.
All reactions