diff --git a/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb b/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb
index 51117e7c2873d48de364ec8b5430ba275b145aca..9005bf56f0286b70dec0803074baf065bc36d684 100644
--- a/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb
+++ b/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb
@@ -363,7 +363,9 @@
     "               }\n",
     "    \n",
     "if local_output:\n",
-    "    ofile = \"{}/agipd_offset_store_{}.h5\".format(out_folder, \"_\".join(offset_runs.values()))\n",
+    "    ofile = \"{}/agipd_offset_store_{}_{}.h5\".format(out_folder, \n",
+    "                                                    \"_\".join(offset_runs.values()),\n",
+    "                                                    qm)\n",
     "    store_file = h5py.File(ofile, \"w\")\n",
     "    for qm in offset_g.keys():\n",
     "        store_file[\"{}/Offset/0/data\".format(qm)] = offset_g[qm]\n",