Skip to content

Commit

Permalink
Remove sysout from 101_MNIST notebook (#1276)
Browse files Browse the repository at this point in the history
* 101 thru papermill

Signed-off-by: Chaurasiya, Payal <[email protected]>

* install kernel

Signed-off-by: Chaurasiya, Payal <[email protected]>

* change the workdir

Signed-off-by: Chaurasiya, Payal <[email protected]>

* change the workdir

Signed-off-by: Chaurasiya, Payal <[email protected]>

* change the workdir

Signed-off-by: Chaurasiya, Payal <[email protected]>

---------

Signed-off-by: Chaurasiya, Payal <[email protected]>
  • Loading branch information
payalcha authored Jan 16, 2025
1 parent ad43881 commit 49f8ca9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 9 deletions.
11 changes: 6 additions & 5 deletions .github/workflows/workflow_interface_101_mnist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ permissions:
contents: read

jobs:
run_notebook:
wf_local_101_mnist:
if: github.event.pull_request.draft == false
runs-on: ubuntu-22.04
timeout-minutes: 30
Expand All @@ -31,16 +31,17 @@ jobs:
with:
python-version: "3.10"

- name: Install Jupyter Lab Package
run: pip install jupyterlab
- name: Install Papermill Package
run: python -m pip install --upgrade pip ipython ipykernel papermill

- name: Run Notebook
run: |
jupyter nbconvert --execute --to notebook ./openfl-tutorials/experimental/workflow/101_MNIST.ipynb
cd openfl-tutorials/experimental/workflow
papermill 101_MNIST.ipynb 101_MNIST_output.ipynb --request-save-on-cell-execute --log-output --autosave-cell-every 30
echo "Notebook run completed"
- name: Tar files
run: tar -cvf notebook.tar ./openfl-tutorials/experimental/workflow/101_MNIST.nbconvert.ipynb
run: tar -cvf notebook.tar ./openfl-tutorials/experimental/workflow/101_MNIST_output.ipynb

- name: Upload Artifacts
uses: actions/upload-artifact@v4
Expand Down
4 changes: 0 additions & 4 deletions openfl-tutorials/experimental/workflow/101_MNIST.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,6 @@
"metadata": {},
"outputs": [],
"source": [
"# Below code will display the print statement output on screen as well\n",
"import sys\n",
"sys.stdout = open('/dev/stdout', 'w')\n",
"\n",
"!pip install git+https://github.com/securefederatedai/openfl.git\n",
"!pip install -r workflow_interface_requirements.txt\n",
"!pip install torch\n",
Expand Down

0 comments on commit 49f8ca9

Please sign in to comment.