From 89aa862f6e73df33f1aac0e6a34aa52cba5b1e2d Mon Sep 17 00:00:00 2001 From: achiefa Date: Wed, 17 Jul 2024 15:24:46 +0100 Subject: [PATCH] Correcting bug --- validphys2/src/validphys/theorycovariance/construction.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/validphys2/src/validphys/theorycovariance/construction.py b/validphys2/src/validphys/theorycovariance/construction.py index f07e12e2d4..0f4128e31f 100644 --- a/validphys2/src/validphys/theorycovariance/construction.py +++ b/validphys2/src/validphys/theorycovariance/construction.py @@ -175,7 +175,7 @@ def thcov_ht(combine_by_type_ht, H2_list, HL_list, groups_data_by_process, pdf, # Loop over the parameter for i in range(len(x_abmp)): - PC_2, PC_L = compute_ht_parametrisation(i, x_abmp, kin_dict, exp, H2_list, HL_list) + PC_2, PC_L = compute_ht_parametrisation(i, x_abmp, kin_dict, exp, H2_list, HL_list, reverse=reverse) if target == 'proton': deltas[f"p({i+1}+,0)"] += [PC_2] deltas[f"p(0,{i+1}+)"] += [PC_L] @@ -211,9 +211,9 @@ def thcov_ht(combine_by_type_ht, H2_list, HL_list, groups_data_by_process, pdf, def extract_target(dataset): if dataset.op == "NULL": if "_P_" in dataset.name or "HERA" in dataset.name: - return "proton" + return "proton" elif "_D_" in dataset.name: - return "deuteron" + return "deuteron" else: raise ValueError(f"No target detected for {dataset.name}") elif dataset.op == "RATIO": @@ -270,7 +270,7 @@ def compute_ht_parametrisation( N2, NL = compute_normalisation_by_experiment(exp, x, y, Q2) PC_2 = N2 * H_2(x) / Q2 - PC_L = NL * H_2(x) / Q2 + PC_L = NL * H_L(x) / Q2 return PC_2, PC_L