From e43dbf8e5f2f53763960b09b5f3b6a8b9d178176 Mon Sep 17 00:00:00 2001 From: Tooba Ali <alit1@myumanitoba.ca> Date: Mon, 7 Nov 2022 22:49:23 +0000 Subject: [PATCH] Update benchmarks/dis/analysis/truth_reconstruction.py --- benchmarks/dis/analysis/truth_reconstruction.py | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/benchmarks/dis/analysis/truth_reconstruction.py b/benchmarks/dis/analysis/truth_reconstruction.py index 3221cebe..5f2003d5 100644 --- a/benchmarks/dis/analysis/truth_reconstruction.py +++ b/benchmarks/dis/analysis/truth_reconstruction.py @@ -173,17 +173,9 @@ for i in range(len(MC_list)): #Repeat the following steps for each variable (mom ################################################################################################### if i > 0: #for each variable theta, phi, and eta - for j in range(len(X_list)): #Repeat the following steps for each particle (pions,protons,electrons,neutrons,photons) - X = X_list[j] - Y = Y_list[j] - M_mc = M_list[j] - boolean_M = np.ones_like(M_mc) == 1 - X_s = np.array(ak.flatten(X[boolean_M])) - Y_s = np.array(ak.flatten(Y[boolean_M])) - M_s = np.array(ak.flatten(M_mc)) - ratio = np.array((ak.Array(Y_s)-(ak.Array(X_s)))) + for j in range(len(M_list)): #Repeat the following steps for each particle (pions,protons,electrons,neutrons,photons) + M_s = np.array(ak.flatten(M_list[j])) X_plot[j] = M_s - Y_plot[j] = ratio fig = plt.figure() gs = fig.add_gridspec(3, 2, wspace=0) -- GitLab