changes to enable the retraining multiple times 50/13950/1
authorrajdeep11 <rajdeep.sin@samsung.com>
Fri, 20 Dec 2024 12:10:22 +0000 (17:40 +0530)
committerrajdeep11 <rajdeep.sin@samsung.com>
Fri, 20 Dec 2024 12:10:22 +0000 (17:40 +0530)
the error was that if the model is retrained the pipeline saves the
model in retrain folder

Change-Id: I16cbb6e93d30b88f75a307219d24d79b03bf7cfd
Signed-off-by: rajdeep11 <rajdeep.sin@samsung.com>
kf-pipelines/qoe-pipeline-retrain-2.ipynb

index 5bfcf92..f933c35 100644 (file)
     "        print(f'Zip file not found: {zip_file_path}')\n",
     "\n",
     "    # Load the model in SavedModel format\n",
-    "    model_path = \"./Model/1\"  # Path to the directory containing the saved model\n",
+    "    # Path to the directory containing the saved model\n",
+    "    if artifactversion ==\"1.0.0\":\n",
+    "        model_path = \"./Model/1\"\n",
+    "    else:\n",
+    "        model_path= \"./Model/1/retrain\"\n",
+    "        \n",
     "    model = tf.keras.models.load_model(model_path)\n",
     "    model.compile(loss='mse', optimizer='adam', metrics=['mse'])\n",
     "    model.summary()\n",