From 48bdaee814b7c43b5755cabaceb69d499b0f6303 Mon Sep 17 00:00:00 2001
From: Jean-Luc Parouty <Jean-Luc.Parouty@simap.grenoble-inp.fr>
Date: Wed, 24 Jan 2024 11:58:35 +0100
Subject: [PATCH] Add tensorboard comments  (v3.0.5)

---
 GTSRB.Keras3/03-Better-convolutions.ipynb     | 19 +++++++---------
 MNIST.Lightning/01-DNN-MNIST_Lightning.ipynb  | 22 ++++++++-----------
 MNIST.Lightning/02-CNN-MNIST_Lightning.ipynb  | 21 +++++++-----------
 Misc/04-Using-Tensorboard.ipynb               | 21 +++++++++++++++---
 README.ipynb                                  | 16 +++++++-------
 README.md                                     |  4 ++--
 .../01-DNN-Wine-Regression-lightning.ipynb    | 21 ++++++++----------
 fidle/about.yml                               |  2 +-
 fidle/ci/default.yml                          |  2 +-
 9 files changed, 64 insertions(+), 64 deletions(-)

diff --git a/GTSRB.Keras3/03-Better-convolutions.ipynb b/GTSRB.Keras3/03-Better-convolutions.ipynb
index 2da7336..3716972 100644
--- a/GTSRB.Keras3/03-Better-convolutions.ipynb
+++ b/GTSRB.Keras3/03-Better-convolutions.ipynb
@@ -215,17 +215,14 @@
    "cell_type": "markdown",
    "metadata": {},
    "source": [
-    "## Step 6 - Train the model"
-   ]
-  },
-  {
-   "cell_type": "code",
-   "execution_count": null,
-   "metadata": {},
-   "outputs": [],
-   "source": [
-    "# %load_ext tensorboard\n",
-    "# %tensorboard --logdir ./run/K3GTSRB3/logs"
+    "## Step 6 - Train the model\n",
+    "To access logs with tensorboad :\n",
+    "- Under **Docker**, from a terminal launched via the jupyterlab launcher, use the following command:<br>\n",
+    "```tensorboard --logdir <path-to-logs> --host 0.0.0.0```\n",
+    "- If you're not using Docker, from a terminal :<br>\n",
+    "```tensorboard --logdir <path-to-logs>```  \n",
+    "\n",
+    "**Note:** One tensorboard instance can be used simultaneously."
    ]
   },
   {
diff --git a/MNIST.Lightning/01-DNN-MNIST_Lightning.ipynb b/MNIST.Lightning/01-DNN-MNIST_Lightning.ipynb
index f95529a..5e98df8 100644
--- a/MNIST.Lightning/01-DNN-MNIST_Lightning.ipynb
+++ b/MNIST.Lightning/01-DNN-MNIST_Lightning.ipynb
@@ -472,19 +472,15 @@
    "id": "e352e48d-b473-4162-a1aa-72d6d4f7aa38",
    "metadata": {},
    "source": [
-    "## 6.2 - Plot history"
-   ]
-  },
-  {
-   "cell_type": "code",
-   "execution_count": null,
-   "id": "5b1c6d11-b897-4e2b-8615-c207c8344d07",
-   "metadata": {},
-   "outputs": [],
-   "source": [
-    "# launch Tensorboard \n",
-    "%reload_ext tensorboard\n",
-    "%tensorboard --logdir=./run/logs/DNN_logs/ --bind_all"
+    "## 6.2 - Plot history\n",
+    "\n",
+    "To access logs with tensorboad :\n",
+    "- Under **Docker**, from a terminal launched via the jupyterlab launcher, use the following command:<br>\n",
+    "```tensorboard --logdir <path-to-logs> --host 0.0.0.0```\n",
+    "- If you're **not using Docker**, from a terminal :<br>\n",
+    "```tensorboard --logdir <path-to-logs>```  \n",
+    "\n",
+    "**Note:** One tensorboard instance can be used simultaneously."
    ]
   },
   {
diff --git a/MNIST.Lightning/02-CNN-MNIST_Lightning.ipynb b/MNIST.Lightning/02-CNN-MNIST_Lightning.ipynb
index c7b764c..f056cb5 100644
--- a/MNIST.Lightning/02-CNN-MNIST_Lightning.ipynb
+++ b/MNIST.Lightning/02-CNN-MNIST_Lightning.ipynb
@@ -482,19 +482,14 @@
    "id": "e352e48d-b473-4162-a1aa-72d6d4f7aa38",
    "metadata": {},
    "source": [
-    "## 6.2 - Plot history"
-   ]
-  },
-  {
-   "cell_type": "code",
-   "execution_count": null,
-   "id": "5b1c6d11-b897-4e2b-8615-c207c8344d07",
-   "metadata": {},
-   "outputs": [],
-   "source": [
-    "# launch Tensorboard \n",
-    "%reload_ext tensorboard\n",
-    "%tensorboard  --logdir=./run/logs/CNN_logs/ --bind_all"
+    "## 6.2 - Plot history\n",
+    "To access logs with tensorboad :\n",
+    "- Under **Docker**, from a terminal launched via the jupyterlab launcher, use the following command:<br>\n",
+    "```tensorboard --logdir <path-to-logs> --host 0.0.0.0```\n",
+    "- If you're **not using Docker**, from a terminal :<br>\n",
+    "```tensorboard --logdir <path-to-logs>```  \n",
+    "\n",
+    "**Note:** One tensorboard instance can be used simultaneously."
    ]
   },
   {
diff --git a/Misc/04-Using-Tensorboard.ipynb b/Misc/04-Using-Tensorboard.ipynb
index f6ef193..3e70191 100644
--- a/Misc/04-Using-Tensorboard.ipynb
+++ b/Misc/04-Using-Tensorboard.ipynb
@@ -21,7 +21,22 @@
    "cell_type": "markdown",
    "metadata": {},
    "source": [
-    "## Option 1  - From Jupyter (***)\n",
+    "## In the Fidle environment  :\n",
+    "\n",
+    "To access logs with tensorboad :\n",
+    "- Under **Docker**, from a terminal launched via the jupyterlab launcher, use the following command:<br>\n",
+    "```tensorboard --logdir <path-to-logs> --host 0.0.0.0```\n",
+    "- If you're **not using Docker**, from a terminal :<br>\n",
+    "```tensorboard --logdir <path-to-logs>```  \n",
+    "\n",
+    "**Note:** One tensorboard instance can be used simultaneously."
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "metadata": {},
+   "source": [
+    "## Otherwise, in the real world, from Jupyter (***)\n",
     "\n",
     "It's the easiest and the best way \\!  \n",
     "Launch Tensorboard directly from Jupiter.  \n",
@@ -33,7 +48,7 @@
    "cell_type": "markdown",
    "metadata": {},
    "source": [
-    "## Option 2 - Tensorboard as a magic command (**)\n",
+    "## Otherwise, in the real word, Tensorboard as a magic command (**)\n",
     "Tensorboard can be run from Jupiter with a magic command.  \n",
     "See [documentation](https://www.tensorflow.org/tensorboard/tensorboard_in_notebooks)  \n",
     "Load the extention : ```%load_ext tensorboard```  \n",
@@ -52,7 +67,7 @@
    "cell_type": "markdown",
    "metadata": {},
    "source": [
-    "## Option 2 - Shell command (*)\n",
+    "## Otherwise, in the real word,  Option 2 - Shell command (*)\n",
     "Basic way, from a shell  \n",
     "More about it : `# tensorboard --help`"
    ]
diff --git a/README.ipynb b/README.ipynb
index 71714c4..4533c22 100644
--- a/README.ipynb
+++ b/README.ipynb
@@ -3,13 +3,13 @@
   {
    "cell_type": "code",
    "execution_count": 1,
-   "id": "e6fc2701",
+   "id": "0fed9e24",
    "metadata": {
     "execution": {
-     "iopub.execute_input": "2024-01-24T08:27:28.475895Z",
-     "iopub.status.busy": "2024-01-24T08:27:28.475122Z",
-     "iopub.status.idle": "2024-01-24T08:27:28.485786Z",
-     "shell.execute_reply": "2024-01-24T08:27:28.484875Z"
+     "iopub.execute_input": "2024-01-24T10:57:35.316984Z",
+     "iopub.status.busy": "2024-01-24T10:57:35.316324Z",
+     "iopub.status.idle": "2024-01-24T10:57:35.326439Z",
+     "shell.execute_reply": "2024-01-24T10:57:35.325542Z"
     },
     "jupyter": {
      "source_hidden": true
@@ -53,7 +53,7 @@
        "For more information, you can contact us at :  \n",
        "[<img width=\"200px\" style=\"vertical-align:middle\" src=\"fidle/img/00-Mail_contact.svg\"></img>](#top)\n",
        "\n",
-       "Current Version : <!-- VERSION_BEGIN -->3.0.3<!-- VERSION_END -->\n",
+       "Current Version : <!-- VERSION_BEGIN -->3.0.5<!-- VERSION_END -->\n",
        "\n",
        "\n",
        "## Course materials\n",
@@ -68,7 +68,7 @@
        "## Jupyter notebooks\n",
        "\n",
        "<!-- TOC_BEGIN -->\n",
-       "<!-- Automatically generated on : 24/01/24 09:27:27 -->\n",
+       "<!-- Automatically generated on : 24/01/24 11:57:34 -->\n",
        "\n",
        "### Linear and logistic regression\n",
        "- **[LINR1](LinearReg/01-Linear-Regression.ipynb)** - [Linear regression with direct resolution](LinearReg/01-Linear-Regression.ipynb)  \n",
@@ -211,7 +211,7 @@
     "from IPython.display import display,Markdown\n",
     "display(Markdown(open('README.md', 'r').read()))\n",
     "#\n",
-    "# This README is visible under Jupiter Lab ;-)# Automatically generated on : 24/01/24 09:27:27"
+    "# This README is visible under Jupiter Lab ;-)# Automatically generated on : 24/01/24 11:57:34"
    ]
   }
  ],
diff --git a/README.md b/README.md
index f7f6529..6e0df3f 100644
--- a/README.md
+++ b/README.md
@@ -32,7 +32,7 @@ For more information, see **https://fidle.cnrs.fr** :
 For more information, you can contact us at :  
 [<img width="200px" style="vertical-align:middle" src="fidle/img/00-Mail_contact.svg"></img>](#top)
 
-Current Version : <!-- VERSION_BEGIN -->3.0.3<!-- VERSION_END -->
+Current Version : <!-- VERSION_BEGIN -->3.0.5<!-- VERSION_END -->
 
 
 ## Course materials
@@ -47,7 +47,7 @@ Have a look about **[How to get and install](https://fidle.cnrs.fr/installation)
 ## Jupyter notebooks
 
 <!-- TOC_BEGIN -->
-<!-- Automatically generated on : 24/01/24 09:27:27 -->
+<!-- Automatically generated on : 24/01/24 11:57:34 -->
 
 ### Linear and logistic regression
 - **[LINR1](LinearReg/01-Linear-Regression.ipynb)** - [Linear regression with direct resolution](LinearReg/01-Linear-Regression.ipynb)  
diff --git a/Wine.Lightning/01-DNN-Wine-Regression-lightning.ipynb b/Wine.Lightning/01-DNN-Wine-Regression-lightning.ipynb
index 6684b38..4680664 100644
--- a/Wine.Lightning/01-DNN-Wine-Regression-lightning.ipynb
+++ b/Wine.Lightning/01-DNN-Wine-Regression-lightning.ipynb
@@ -468,18 +468,15 @@
    "cell_type": "markdown",
    "metadata": {},
    "source": [
-    "### 6.2 - Training history"
-   ]
-  },
-  {
-   "cell_type": "code",
-   "execution_count": null,
-   "metadata": {},
-   "outputs": [],
-   "source": [
-    "# launch Tensorboard \n",
-    "%reload_ext tensorboard\n",
-    "%tensorboard --logdir=./run/LWINE1/reg_logs/ --bind_all"
+    "### 6.2 - Training history\n",
+    "\n",
+    "To access logs with tensorboad :\n",
+    "- Under **Docker**, from a terminal launched via the jupyterlab launcher, use the following command:<br>\n",
+    "```tensorboard --logdir <path-to-logs> --host 0.0.0.0```\n",
+    "- If you're **not using Docker**, from a terminal :<br>\n",
+    "```tensorboard --logdir <path-to-logs>```  \n",
+    "\n",
+    "**Note:** One tensorboard instance can be used simultaneously."
    ]
   },
   {
diff --git a/fidle/about.yml b/fidle/about.yml
index 158ee98..136af1c 100644
--- a/fidle/about.yml
+++ b/fidle/about.yml
@@ -13,7 +13,7 @@
 #
 # This file describes the notebooks used by the Fidle training.
 
-version:                  3.0.4
+version:                  3.0.5
 content:                  notebooks
 name:                     Notebooks Fidle
 description:              All notebooks used by the Fidle training
diff --git a/fidle/ci/default.yml b/fidle/ci/default.yml
index 2aff81f..921716b 100644
--- a/fidle/ci/default.yml
+++ b/fidle/ci/default.yml
@@ -1,6 +1,6 @@
 campain:
   version: '1.0'
-  description: Automatically generated ci profile (24/01/24 09:27:27)
+  description: Automatically generated ci profile (24/01/24 11:57:34)
   directory: ./campains/default
   existing_notebook: 'remove    # remove|skip'
   report_template: 'fidle     # fidle|default'
-- 
GitLab