From 938bdd8995a860702c6600d1c41c9336c25e47a1 Mon Sep 17 00:00:00 2001 From: Antonello Pellecchia Date: Sat, 19 Feb 2022 11:59:24 +0100 Subject: [PATCH 1/2] Analyze GBT phase scan with GBT and elink as keys --- gemos/analysis/gbt_phase_scan.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gemos/analysis/gbt_phase_scan.py b/gemos/analysis/gbt_phase_scan.py index e7c4a4e..b12ac3d 100644 --- a/gemos/analysis/gbt_phase_scan.py +++ b/gemos/analysis/gbt_phase_scan.py @@ -24,7 +24,7 @@ def create_configuration(input_filenames, output_directory): df = pd.concat((pd.read_csv(f, sep=";") for f in input_filenames), ignore_index=True) # Create a new column with the configuration name - df["config-name"] = "PHASE_VFAT" + df["vfat"].astype(str) + df["config-name"] = "PHASE_GBT" + df["gbt"].astype(str) + "_ELINK" + df["elink"].astype(str) # Create one file per OptoHybrid groups = df.groupby(["fed", "slot", "oh"]) -- GitLab From c42e8b0af032d59fa624c6d0cfce358eaaa5d8b8 Mon Sep 17 00:00:00 2001 From: Antonello Pellecchia Date: Thu, 17 Mar 2022 17:15:33 +0100 Subject: [PATCH 2/2] Create one configuration file per each GBT --- gemos/analysis/gbt_phase_scan.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gemos/analysis/gbt_phase_scan.py b/gemos/analysis/gbt_phase_scan.py index b12ac3d..51d3ebf 100644 --- a/gemos/analysis/gbt_phase_scan.py +++ b/gemos/analysis/gbt_phase_scan.py @@ -11,9 +11,10 @@ def create_configuration(input_filenames, output_directory): fed = df.iloc[0]["fed"] slot = df.iloc[0]["slot"] oh = df.iloc[0]["oh"] + gbt = df.iloc[0]["gbt"] - output_filename = "{}/fed{}-slot{}/config-oh{}-gbt.cfg".format( - output_directory, fed, slot, oh + output_filename = "{}/fed{}-slot{}/gbt/config-oh{}-gbt{}.cfg".format( + output_directory, fed, slot, oh, gbt ) os.makedirs(os.path.dirname(output_filename), exist_ok=True) @@ -27,5 +28,5 @@ def create_configuration(input_filenames, output_directory): df["config-name"] = "PHASE_GBT" + df["gbt"].astype(str) + "_ELINK" + df["elink"].astype(str) # Create one file per OptoHybrid - groups = df.groupby(["fed", "slot", "oh"]) + groups = df.groupby(["fed", "slot", "oh", "gbt"]) groups.apply(write_configuration) -- GitLab