From 7cad9f4566e6e0237526fd14158832af2a05bcf3 Mon Sep 17 00:00:00 2001 From: Ishant Thakare Date: Thu, 12 Dec 2024 12:52:53 +0530 Subject: [PATCH] Incorporated review comment Signed-off-by: Ishant Thakare --- .../1001_Workspace_Creation_from_JupyterNotebook.ipynb | 4 ++-- .../workflow/Vertical_FL/TwoPartyWorkspaceCreation.ipynb | 4 ++-- openfl/experimental/workflow/workspace_export/export.py | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/openfl-tutorials/experimental/workflow/1001_Workspace_Creation_from_JupyterNotebook.ipynb b/openfl-tutorials/experimental/workflow/1001_Workspace_Creation_from_JupyterNotebook.ipynb index 6cd4059e3c..ab31b26d50 100644 --- a/openfl-tutorials/experimental/workflow/1001_Workspace_Creation_from_JupyterNotebook.ipynb +++ b/openfl-tutorials/experimental/workflow/1001_Workspace_Creation_from_JupyterNotebook.ipynb @@ -946,7 +946,7 @@ "The following cells convert the Jupyter notebook into a Python script and create a Template Workspace that can be utilized by Aggregator based Workflow\n", "> NOTE: Only Notebook cells that were marked with `#| export` directive shall be included in this Python script\n", "\n", - "We first import `WorkspaceExport` module and execute `WorkspaceExport.export_agg_based_workspace()` that converts the notebook and generates the template workspace. User is required to specify: \n", + "We first import `WorkspaceExport` module and execute `WorkspaceExport.export()` that converts the notebook and generates the template workspace. User is required to specify: \n", "1. `notebook_path`: path of the Jupyter notebook that is required to be converted\n", "2. `output_workspace`: path where the converted workspace is stored" ] @@ -961,7 +961,7 @@ "import os\n", "from openfl.experimental.workflow.workspace_export import WorkspaceExport\n", "\n", - "WorkspaceExport.export_agg_based_workspace(\n", + "WorkspaceExport.export(\n", " notebook_path='./1001_Workspace_Creation_from_JupyterNotebook.ipynb',\n", " output_workspace=f\"/home/{os.environ['USER']}/generated-workspace\"\n", ")" diff --git a/openfl-tutorials/experimental/workflow/Vertical_FL/TwoPartyWorkspaceCreation.ipynb b/openfl-tutorials/experimental/workflow/Vertical_FL/TwoPartyWorkspaceCreation.ipynb index 36afd9a53c..1395a5095a 100644 --- a/openfl-tutorials/experimental/workflow/Vertical_FL/TwoPartyWorkspaceCreation.ipynb +++ b/openfl-tutorials/experimental/workflow/Vertical_FL/TwoPartyWorkspaceCreation.ipynb @@ -340,7 +340,7 @@ "The following cells convert the Jupyter notebook into a Python script and create a Template Workspace that can be utilized by Aggregator based Workflow\n", "> NOTE: Only Notebook cells that were marked with `#| export` directive shall be included in this Python script\n", "\n", - "We first import `WorkspaceExport` module and execute `WorkspaceExport.export_agg_based_workspace()` that converts the notebook and generates the template workspace. User is required to specify: \n", + "We first import `WorkspaceExport` module and execute `WorkspaceExport.export()` that converts the notebook and generates the template workspace. User is required to specify: \n", "1. `notebook_path`: path of the Jupyter notebook that is required to be converted\n", "2. `output_workspace`: path where the converted workspace is stored" ] @@ -355,7 +355,7 @@ "import os\n", "from openfl.experimental.workflow.workspace_export import WorkspaceExport\n", "\n", - "WorkspaceExport.export_agg_based_workspace(\n", + "WorkspaceExport.export(\n", " notebook_path='./TwoPartyWorkspaceCreation.ipynb',\n", " output_workspace=f\"/home/{os.environ['USER']}/generated-workspace\"\n", ")" diff --git a/openfl/experimental/workflow/workspace_export/export.py b/openfl/experimental/workflow/workspace_export/export.py index 115f1b794f..3975e83e44 100644 --- a/openfl/experimental/workflow/workspace_export/export.py +++ b/openfl/experimental/workflow/workspace_export/export.py @@ -293,8 +293,8 @@ def export_federated(cls, notebook_path: str, output_workspace: str) -> Tuple[st return instance.generate_experiment_archive() @classmethod - def export_agg_based_workspace(cls, notebook_path: str, output_workspace: str) -> None: - """Exports workspace for Aggregator based workflow. + def export(cls, notebook_path: str, output_workspace: str) -> None: + """Exports workspace to output_workspace. Args: notebook_path (str): Path to the Jupyter notebook.