From 7eb3c2599d8a9d19f577df393f97aa1fe8a9bf84 Mon Sep 17 00:00:00 2001 From: ahmedk <karim.ahmed@xfel.eu> Date: Mon, 9 Oct 2023 11:47:31 +0200 Subject: [PATCH] fix spelling mistakes and remove unused imports --- .../AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb b/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb index 0d113f7b3..3af27abfd 100644 --- a/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb +++ b/notebooks/AGIPD/Characterize_AGIPD_Gain_Darks_NBC.ipynb @@ -50,7 +50,7 @@ "interlaced = False # assume interlaced data format, for data prior to Dec. 2017\n", "\n", "thresholds_offset_sigma = 3. # offset sigma thresholds for offset deduced bad pixels\n", - "thresholds_offset_hard = [0, 0] # For setting the same threshold offset for the 3 gains. Left for backcompatability. Default [0, 0] to take the following parameters.\n", + "thresholds_offset_hard = [0, 0] # For setting the same threshold offset for the 3 gains. Left for backward compatibility. Default [0, 0] to take the following parameters.\n", "thresholds_offset_hard_hg = [3000, 7000] # High-gain thresholds in absolute ADU terms for offset deduced bad pixels\n", "thresholds_offset_hard_mg = [6000, 10000] # Medium-gain thresholds in absolute ADU terms for offset deduced bad pixels\n", "thresholds_offset_hard_lg = [6000, 10000] # Low-gain thresholds in absolute ADU terms for offset deduced bad pixels\n", @@ -59,14 +59,14 @@ "thresholds_offset_hard_lg_fixed = [3500, 6500] # Same as thresholds_offset_hard_lg, but for fixed gain operation\n", "\n", "thresholds_noise_sigma = 5. # noise sigma thresholds for offset deduced bad pixels\n", - "thresholds_noise_hard = [0, 0] # For setting the same threshold noise for the 3 gains. Left for backcompatability. Default [0, 0] to take the following parameters.\n", + "thresholds_noise_hard = [0, 0] # For setting the same threshold noise for the 3 gains. Left for backward compatibility. Default [0, 0] to take the following parameters.\n", "thresholds_noise_hard_hg = [4, 20] # High-gain thresholds in absolute ADU terms for offset deduced bad pixels\n", "thresholds_noise_hard_mg = [4, 20] # Medium-gain thresholds in absolute ADU terms for offset deduced bad pixels\n", "thresholds_noise_hard_lg = [4, 20] # Low-gain thresholds in absolute ADU terms for offset deduced bad pixels\n", "\n", "thresholds_gain_sigma = 5. # Gain separation sigma threshold\n", - "max_trains = 550 # Maximum number of trains to use for processing dark. Set to 0 to process all available trains. 550 added for ~500GB nodes to temporarely avoid memory issues.\n", - "min_trains = 1 # Miniumum number of trains for processing dark. If run folder has less than minimum trains, processing is stopped.\n", + "max_trains = 550 # Maximum number of trains to use for processing dark. Set to 0 to process all available trains. 550 added for ~500GB nodes to temporarily avoid memory issues.\n", + "min_trains = 1 # Minimum number of trains for processing dark. If run folder has less than minimum trains, processing is stopped.\n", "high_res_badpix_3d = False # set this to True if you need high-resolution 3d bad pixel plots. ~7mins extra time for 64 memory cells\n", "\n", "# This is used if modules is not specified:\n", @@ -97,7 +97,6 @@ "from pathlib import Path\n", "from typing import List, Tuple\n", "\n", - "import dateutil.parser\n", "import matplotlib\n", "import numpy as np\n", "import pasha as psh\n", @@ -110,8 +109,8 @@ "\n", "import iCalibrationDB\n", "import matplotlib.pyplot as plt\n", - "from cal_tools.agipdlib import AgipdCtrl\n", - "from cal_tools.enums import AgipdGainMode, BadPixels\n", + "from cal_tools.agipdlib import AgipdCtrl, AgipdCtrlDark\n", + "from cal_tools.enums import BadPixels\n", "from cal_tools.plotting import (\n", " create_constant_overview,\n", " plot_badpix_3d,\n", @@ -124,7 +123,6 @@ " get_pdu_from_db,\n", " get_random_db_interface,\n", " get_report,\n", - " map_gain_stages,\n", " module_index_to_qm,\n", " run_prop_seq_from_path,\n", " save_const_to_h5,\n", -- GitLab