nnpdf-data 0.0.1__py3-none-any.whl → 0.0.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- nnpdf_data/__init__.py +11 -66
- nnpdf_data/_version.py +1 -1
- nnpdf_data/commondata/ATLAS_PH_13TEV/data_XSEC.yaml +54 -0
- nnpdf_data/commondata/ATLAS_PH_13TEV/kinematics_XSEC.yaml +251 -251
- nnpdf_data/commondata/ATLAS_PH_13TEV/metadata.yaml +28 -27
- nnpdf_data/commondata/ATLAS_PH_13TEV/uncertainties_XSEC.yaml +5246 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_13TEV/data_TCHANNEL-XSEC.yaml +2 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_13TEV/kinematics_TCHANNEL-XSEC.yaml +2 -10
- nnpdf_data/commondata/ATLAS_SINGLETOP_13TEV/metadata.yaml +14 -24
- nnpdf_data/commondata/ATLAS_SINGLETOP_13TEV/uncertainties_TCHANNEL-XSEC.yaml +107 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/data_T-Y-NORM.yaml +4 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/data_TBAR-Y-NORM.yaml +4 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/data_TCHANNEL-XSEC.yaml +2 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/kinematics_T-Y-NORM.yaml +19 -19
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/kinematics_TBAR-Y-NORM.yaml +19 -19
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/kinematics_TCHANNEL-XSEC.yaml +7 -7
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/metadata.yaml +70 -68
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/uncertainties_T-Y-NORM.yaml +72 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/uncertainties_TBAR-Y-NORM.yaml +65 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_7TEV/uncertainties_TCHANNEL-XSEC.yaml +147 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/data_T-RAP-NORM.yaml +4 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/data_TBAR-RAP-NORM.yaml +4 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/data_TCHANNEL-XSEC.yaml +2 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/kinematics_T-RAP-NORM.yaml +18 -18
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/kinematics_TBAR-RAP-NORM.yaml +18 -18
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/kinematics_TCHANNEL-XSEC.yaml +7 -7
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/metadata.yaml +69 -67
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/uncertainties_T-RAP-NORM.yaml +135 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/uncertainties_TBAR-RAP-NORM.yaml +135 -0
- nnpdf_data/commondata/ATLAS_SINGLETOP_8TEV/uncertainties_TCHANNEL-XSEC.yaml +12 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/data_d2Sig_dmttBar_dpTt.yaml +16 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/data_d2Sig_dmttBar_dpTt_norm.yaml +16 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/data_d2Sig_dpTt_dyt.yaml +14 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/data_d2Sig_dpTt_dyt_norm.yaml +14 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/kinematics_d2Sig_dmttBar_dpTt.yaml +181 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/kinematics_d2Sig_dmttBar_dpTt_norm.yaml +181 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/kinematics_d2Sig_dpTt_dyt.yaml +157 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/kinematics_d2Sig_dpTt_dyt_norm.yaml +157 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/metadata.yaml +120 -2
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/uncertainties_d2Sig_dmttBar_dpTt.yaml +287 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/uncertainties_d2Sig_dmttBar_dpTt_norm.yaml +287 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/uncertainties_d2Sig_dpTt_dyt.yaml +223 -0
- nnpdf_data/commondata/ATLAS_TTBAR_13TEV_LJ_DIF/uncertainties_d2Sig_dpTt_dyt_norm.yaml +223 -0
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/data_WM-YL.yaml +12 -0
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/data_WP-YL.yaml +12 -0
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/kinematics_WM-YL.yaml +56 -100
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/kinematics_WP-YL.yaml +56 -100
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/metadata.yaml +52 -62
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/uncertainties_WM-YL.yaml +1742 -0
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/uncertainties_WP-YL.yaml +1742 -0
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/uncertainties_legacy_WM-YL_sys_10.yaml +1772 -0
- nnpdf_data/commondata/ATLAS_WCHARM_7TEV/uncertainties_legacy_WP-YL_sys_10.yaml +1772 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/data_WM-PT.yaml +17 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/data_WP-PT.yaml +17 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/kinematics_WM-PT.yaml +80 -144
- nnpdf_data/commondata/ATLAS_WJ_8TEV/kinematics_WP-PT.yaml +80 -144
- nnpdf_data/commondata/ATLAS_WJ_8TEV/metadata.yaml +77 -70
- nnpdf_data/commondata/ATLAS_WJ_8TEV/uncertainties_WM-PT.yaml +1402 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/uncertainties_WP-PT.yaml +1402 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/uncertainties_legacy_WM-PT_sys_ATLAS.yaml +2502 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/uncertainties_legacy_WM-PT_sys_NP.yaml +2502 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/uncertainties_legacy_WP-PT_sys_ATLAS.yaml +2502 -0
- nnpdf_data/commondata/ATLAS_WJ_8TEV/uncertainties_legacy_WP-PT_sys_NP.yaml +2502 -0
- nnpdf_data/commondata/ATLAS_WPWM_13TEV/data.yaml +3 -0
- nnpdf_data/commondata/ATLAS_WPWM_13TEV/kinematics.yaml +17 -0
- nnpdf_data/commondata/ATLAS_WPWM_13TEV/metadata.yaml +22 -25
- nnpdf_data/commondata/ATLAS_WPWM_13TEV/uncertainties.yaml +32 -0
- nnpdf_data/commondata/ATLAS_WPWM_7TEV_46FB/data.yaml +23 -0
- nnpdf_data/commondata/ATLAS_WPWM_7TEV_46FB/kinematics.yaml +265 -0
- nnpdf_data/commondata/ATLAS_WPWM_7TEV_46FB/metadata.yaml +25 -24
- nnpdf_data/commondata/ATLAS_WPWM_7TEV_46FB/uncertainties.yaml +3486 -0
- nnpdf_data/commondata/ATLAS_Z0_13TEV/data.yaml +2 -0
- nnpdf_data/commondata/ATLAS_Z0_13TEV/kinematics.yaml +9 -0
- nnpdf_data/commondata/ATLAS_Z0_13TEV/metadata.yaml +18 -22
- nnpdf_data/commondata/ATLAS_Z0_13TEV/uncertainties.yaml +27 -0
- nnpdf_data/commondata/ATLAS_Z0_7TEV_49FB/data.yaml +14 -0
- nnpdf_data/commondata/ATLAS_Z0_7TEV_49FB/kinematics.yaml +53 -0
- nnpdf_data/commondata/ATLAS_Z0_7TEV_49FB/metadata.yaml +18 -27
- nnpdf_data/commondata/ATLAS_Z0_7TEV_49FB/uncertainties.yaml +206 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_D/data_rqcd.yaml +160 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_D/data_rzero.yaml +160 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_D/kinematics_EM-F2-HEPDATA.yaml +1273 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_D/kinematics_EM-F2.yaml +762 -762
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_D/metadata.yaml +79 -24
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_D/uncertainties_rqcd.yaml +491 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_D/uncertainties_rzero.yaml +491 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_P/data_rqcd.yaml +178 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_P/data_rzero.yaml +178 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_P/kinematics_EM-F2-HEPDATA.yaml +2125 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_P/kinematics_EM-F2.yaml +1053 -1053
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_P/metadata.yaml +85 -24
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_P/uncertainties_rqcd.yaml +545 -0
- nnpdf_data/commondata/BCDMS_NC_NOTFIXED_P/uncertainties_rzero.yaml +545 -0
- nnpdf_data/commondata/CDF_Z0_1P96TEV/data_ZRAP.yaml +29 -0
- nnpdf_data/commondata/CDF_Z0_1P96TEV/kinematics_ZRAP.yaml +174 -174
- nnpdf_data/commondata/CDF_Z0_1P96TEV/metadata.yaml +28 -28
- nnpdf_data/commondata/CDF_Z0_1P96TEV/uncertainties_ZRAP.yaml +386 -0
- nnpdf_data/commondata/CHORUS_CC_NOTFIXED_PB/data_nb.yaml +608 -0
- nnpdf_data/commondata/CHORUS_CC_NOTFIXED_PB/data_nu.yaml +608 -0
- nnpdf_data/commondata/CHORUS_CC_NOTFIXED_PB/kinematics.yaml +7285 -0
- nnpdf_data/commondata/CHORUS_CC_NOTFIXED_PB/metadata.yaml +57 -51
- nnpdf_data/commondata/CHORUS_CC_NOTFIXED_PB/uncertainties_nb_hepdata.yaml +2446 -0
- nnpdf_data/commondata/CHORUS_CC_NOTFIXED_PB/uncertainties_nu_hepdata.yaml +2446 -0
- nnpdf_data/commondata/CMS_SINGLETOP_13TEV/data_TCHANNEL-XSEC.yaml +2 -0
- nnpdf_data/commondata/CMS_SINGLETOP_13TEV/kinematics_TCHANNEL-XSEC.yaml +2 -10
- nnpdf_data/commondata/CMS_SINGLETOP_13TEV/metadata.yaml +12 -22
- nnpdf_data/commondata/CMS_SINGLETOP_13TEV/uncertainties_TCHANNEL-XSEC.yaml +12 -0
- nnpdf_data/commondata/CMS_SINGLETOP_7TEV/data_TCHANNEL-XSEC.yaml +2 -0
- nnpdf_data/commondata/CMS_SINGLETOP_7TEV/kinematics_TCHANNEL-XSEC.yaml +2 -10
- nnpdf_data/commondata/CMS_SINGLETOP_7TEV/metadata.yaml +12 -22
- nnpdf_data/commondata/CMS_SINGLETOP_7TEV/uncertainties_TCHANNEL-XSEC.yaml +22 -0
- nnpdf_data/commondata/CMS_SINGLETOP_8TEV/data_TCHANNEL-XSEC.yaml +2 -0
- nnpdf_data/commondata/CMS_SINGLETOP_8TEV/kinematics_TCHANNEL-XSEC.yaml +2 -10
- nnpdf_data/commondata/CMS_SINGLETOP_8TEV/metadata.yaml +15 -25
- nnpdf_data/commondata/CMS_SINGLETOP_8TEV/uncertainties_TCHANNEL-XSEC.yaml +12 -0
- nnpdf_data/commondata/CMS_WPWM_7TEV_ELECTRON/kinematics.yaml +11 -11
- nnpdf_data/commondata/CMS_WPWM_7TEV_ELECTRON/metadata.yaml +6 -6
- nnpdf_data/commondata/CMS_WPWM_7TEV_MUON/kinematics.yaml +11 -11
- nnpdf_data/commondata/CMS_WPWM_7TEV_MUON/metadata.yaml +7 -7
- nnpdf_data/commondata/CMS_WPWM_8TEV_MUON/kinematics.yaml +22 -22
- nnpdf_data/commondata/CMS_WPWM_8TEV_MUON/metadata.yaml +5 -5
- nnpdf_data/commondata/CMS_Z0J_8TEV/{data_legacy_PT-Y.yaml → data_PT-Y.yaml} +7 -7
- nnpdf_data/commondata/CMS_Z0J_8TEV/kinematics_PT-Y.yaml +560 -560
- nnpdf_data/commondata/CMS_Z0J_8TEV/metadata.yaml +44 -41
- nnpdf_data/commondata/CMS_Z0J_8TEV/uncertainties_PT-Y.yaml +2806 -0
- nnpdf_data/commondata/CMS_Z0J_8TEV/uncertainties_PT-Y_sys_10.yaml +2755 -2759
- nnpdf_data/commondata/CMS_Z0J_8TEV/uncertainties_legacy_PT-Y_sys_10.yaml +2864 -0
- nnpdf_data/commondata/CMS_Z0_7TEV_DIMUON/kinematics.yaml +132 -132
- nnpdf_data/commondata/CMS_Z0_7TEV_DIMUON/metadata.yaml +5 -5
- nnpdf_data/commondata/D0_WPWM_1P96TEV/data_ASY.yaml +11 -0
- nnpdf_data/commondata/D0_WPWM_1P96TEV/kinematics_ASY.yaml +68 -68
- nnpdf_data/commondata/D0_WPWM_1P96TEV/metadata.yaml +27 -26
- nnpdf_data/commondata/D0_WPWM_1P96TEV/uncertainties_ASY.yaml +114 -0
- nnpdf_data/commondata/D0_Z0_1P96TEV/data_ZRAP.yaml +29 -0
- nnpdf_data/commondata/D0_Z0_1P96TEV/kinematics_ZRAP.yaml +174 -174
- nnpdf_data/commondata/D0_Z0_1P96TEV/metadata.yaml +52 -51
- nnpdf_data/commondata/D0_Z0_1P96TEV/uncertainties_ZRAP.yaml +66 -0
- nnpdf_data/commondata/EMC_NC_250GEV/data_rzero.yaml +22 -0
- nnpdf_data/commondata/EMC_NC_250GEV/kinematics.yaml +253 -0
- nnpdf_data/commondata/EMC_NC_250GEV/metadata.yaml +30 -26
- nnpdf_data/commondata/EMC_NC_250GEV/uncertainties_rzero.yaml +77 -0
- nnpdf_data/commondata/HERA_CC_318GEV/kinematics_EM-SIGMARED.yaml +126 -126
- nnpdf_data/commondata/HERA_CC_318GEV/kinematics_EP-SIGMARED.yaml +117 -117
- nnpdf_data/commondata/HERA_CC_318GEV/metadata.yaml +42 -41
- nnpdf_data/commondata/HERA_CC_318GEV/uncertainties_EM-SIGMARED.yaml +7868 -0
- nnpdf_data/commondata/HERA_CC_318GEV/uncertainties_EP-SIGMARED.yaml +7355 -0
- nnpdf_data/commondata/HERA_NC_225GEV/kinematics_EP-SIGMARED.yaml +627 -627
- nnpdf_data/commondata/HERA_NC_225GEV/metadata.yaml +21 -21
- nnpdf_data/commondata/HERA_NC_225GEV/uncertainties_EP-SIGMARED.yaml +36425 -0
- nnpdf_data/commondata/HERA_NC_251GEV/kinematics_EP-SIGMARED.yaml +780 -780
- nnpdf_data/commondata/HERA_NC_251GEV/metadata.yaml +21 -21
- nnpdf_data/commondata/HERA_NC_251GEV/uncertainties_EP-SIGMARED.yaml +45146 -0
- nnpdf_data/commondata/HERA_NC_300GEV/kinematics_EP-SIGMARED.yaml +336 -336
- nnpdf_data/commondata/HERA_NC_300GEV/metadata.yaml +21 -21
- nnpdf_data/commondata/HERA_NC_300GEV/uncertainties_EP-SIGMARED.yaml +19838 -0
- nnpdf_data/commondata/HERA_NC_318GEV/kinematics_EM-SIGMARED.yaml +477 -477
- nnpdf_data/commondata/HERA_NC_318GEV/kinematics_EP-SIGMARED.yaml +1455 -1455
- nnpdf_data/commondata/HERA_NC_318GEV/metadata.yaml +41 -41
- nnpdf_data/commondata/HERA_NC_318GEV/uncertainties_EM-SIGMARED.yaml +27875 -0
- nnpdf_data/commondata/HERA_NC_318GEV/uncertainties_EP-SIGMARED.yaml +83621 -0
- nnpdf_data/commondata/HERA_NC_318GEV_EAVG/kinematics_BOTTOM-SIGMARED.yaml +108 -108
- nnpdf_data/commondata/HERA_NC_318GEV_EAVG/kinematics_CHARM-SIGMARED.yaml +208 -208
- nnpdf_data/commondata/HERA_NC_318GEV_EAVG/metadata.yaml +41 -41
- nnpdf_data/commondata/HERA_NC_318GEV_EAVG/uncertainties_BOTTOM-SIGMARED.yaml +5241 -0
- nnpdf_data/commondata/HERA_NC_318GEV_EAVG/uncertainties_CHARM-SIGMARED.yaml +9466 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED/data.yaml +261 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED/kinematics.yaml +3121 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED/metadata.yaml +30 -27
- nnpdf_data/commondata/NMC_NC_NOTFIXED/uncertainties_hepdata.yaml +530 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED_D/data_EM-F2-HEPDATA.yaml +159 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED_D/kinematics_EM-F2-HEPDATA.yaml +1265 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED_D/metadata.yaml +60 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED_D/uncertainties_EM-F2-HEPDATA.yaml +326 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED_P/data_EM-F2-HEPDATA.yaml +159 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED_P/kinematics_EM-F2-HEPDATA.yaml +1265 -0
- nnpdf_data/commondata/NMC_NC_NOTFIXED_P/kinematics_EM-SIGMARED.yaml +876 -876
- nnpdf_data/commondata/NMC_NC_NOTFIXED_P/metadata.yaml +67 -22
- nnpdf_data/commondata/NMC_NC_NOTFIXED_P/uncertainties_EM-F2-HEPDATA.yaml +326 -0
- nnpdf_data/commondata/NUTEV_CC_NOTFIXED_FE/data_NB.yaml +46 -0
- nnpdf_data/commondata/NUTEV_CC_NOTFIXED_FE/data_NU.yaml +46 -0
- nnpdf_data/commondata/NUTEV_CC_NOTFIXED_FE/kinematics_NB.yaml +541 -0
- nnpdf_data/commondata/NUTEV_CC_NOTFIXED_FE/kinematics_NU.yaml +541 -0
- nnpdf_data/commondata/NUTEV_CC_NOTFIXED_FE/metadata.yaml +53 -46
- nnpdf_data/commondata/NUTEV_CC_NOTFIXED_FE/uncertainties_NB_hepdata.yaml +198 -0
- nnpdf_data/commondata/NUTEV_CC_NOTFIXED_FE/uncertainties_NU_hepdata.yaml +198 -0
- nnpdf_data/commondata/SLAC_NC_NOTFIXED_D/kinematics_EM-F2.yaml +633 -633
- nnpdf_data/commondata/SLAC_NC_NOTFIXED_D/metadata.yaml +20 -19
- nnpdf_data/commondata/SLAC_NC_NOTFIXED_P/kinematics_EM-F2.yaml +633 -633
- nnpdf_data/commondata/SLAC_NC_NOTFIXED_P/metadata.yaml +20 -19
- nnpdf_data/commondata/update_all.py +35 -0
- nnpdf_data/commondataparser.py +30 -21
- nnpdf_data/coredata.py +1 -0
- nnpdf_data/filter_utils/hera_utils.py +105 -0
- nnpdf_data/filter_utils/nmc_hepdata_utils.py +59 -0
- nnpdf_data/filter_utils/utils.py +16 -4
- nnpdf_data/process_options.py +93 -7
- nnpdf_data/theory.py +0 -13
- nnpdf_data/theory_cards/40005000.yaml +48 -0
- nnpdf_data/theory_cards/40005001.yaml +48 -0
- nnpdf_data/theory_cards/40005002.yaml +48 -0
- nnpdf_data/theory_cards/40005003.yaml +48 -0
- nnpdf_data/theory_cards/40005004.yaml +48 -0
- nnpdf_data/theory_cards/40005005.yaml +48 -0
- nnpdf_data/theory_cards/40005006.yaml +48 -0
- nnpdf_data/theory_cards/40005007.yaml +48 -0
- nnpdf_data/theory_cards/40005008.yaml +48 -0
- nnpdf_data/theory_cards/40005009.yaml +48 -0
- nnpdf_data/theory_cards/40005010.yaml +48 -0
- nnpdf_data/theory_cards/40005011.yaml +48 -0
- nnpdf_data/theory_cards/40005012.yaml +48 -0
- nnpdf_data/theory_cards/40005013.yaml +48 -0
- nnpdf_data/theory_cards/40005014.yaml +48 -0
- nnpdf_data/theory_cards/40005015.yaml +48 -0
- nnpdf_data/theory_cards/40005016.yaml +48 -0
- nnpdf_data/theory_cards/40005017.yaml +48 -0
- nnpdf_data/theory_cards/40005018.yaml +48 -0
- nnpdf_data/theory_cards/40005019.yaml +48 -0
- nnpdf_data/theory_cards/40005020.yaml +48 -0
- nnpdf_data/theory_cards/40005021.yaml +48 -0
- nnpdf_data/theory_cards/40005022.yaml +48 -0
- nnpdf_data/theory_cards/40005023.yaml +48 -0
- nnpdf_data/theory_cards/40005024.yaml +48 -0
- nnpdf_data/theory_cards/40005025.yaml +48 -0
- nnpdf_data/theory_cards/40005026.yaml +48 -0
- nnpdf_data/theory_cards/40007000.yaml +47 -0
- nnpdf_data/theory_cards/40007001.yaml +47 -0
- nnpdf_data/theory_cards/40007002.yaml +47 -0
- nnpdf_data/theory_cards/40007003.yaml +47 -0
- nnpdf_data/theory_cards/40007004.yaml +47 -0
- nnpdf_data/theory_cards/40007005.yaml +47 -0
- nnpdf_data/theory_cards/40007006.yaml +47 -0
- nnpdf_data/theory_cards/40007007.yaml +47 -0
- nnpdf_data/theory_cards/40007008.yaml +47 -0
- nnpdf_data/theory_cards/40007009.yaml +47 -0
- nnpdf_data/theory_cards/40007010.yaml +47 -0
- nnpdf_data/theory_cards/40007011.yaml +47 -0
- nnpdf_data/theory_cards/40007012.yaml +47 -0
- nnpdf_data/theory_cards/40007013.yaml +47 -0
- nnpdf_data/theory_cards/40008000.yaml +48 -0
- nnpdf_data/theory_cards/40008001.yaml +48 -0
- nnpdf_data/theory_cards/40008002.yaml +48 -0
- nnpdf_data/theory_cards/40008003.yaml +48 -0
- nnpdf_data/theory_cards/40008004.yaml +48 -0
- nnpdf_data/theory_cards/40008005.yaml +48 -0
- nnpdf_data/theory_cards/40008006.yaml +48 -0
- nnpdf_data/theory_cards/40008007.yaml +48 -0
- nnpdf_data/theory_cards/40008008.yaml +48 -0
- nnpdf_data/theory_cards/40008009.yaml +48 -0
- nnpdf_data/theory_cards/40008010.yaml +48 -0
- nnpdf_data/theory_cards/40008011.yaml +48 -0
- nnpdf_data/theory_cards/40008012.yaml +48 -0
- nnpdf_data/theory_cards/40008013.yaml +48 -0
- nnpdf_data/theory_cards/40009000.yaml +41 -0
- nnpdf_data/theory_cards/40009001.yaml +41 -0
- nnpdf_data/theory_cards/40009002.yaml +41 -0
- nnpdf_data/theory_cards/40010000.yaml +41 -0
- nnpdf_data/theory_cards/40010001.yaml +41 -0
- nnpdf_data/theory_cards/40010002.yaml +41 -0
- nnpdf_data/theory_cards/40010003.yaml +41 -0
- nnpdf_data/theory_cards/40010004.yaml +41 -0
- nnpdf_data/theory_cards/40010005.yaml +41 -0
- nnpdf_data/theory_cards/40010006.yaml +41 -0
- nnpdf_data/theory_cards/40010007.yaml +41 -0
- nnpdf_data/theory_cards/40010008.yaml +41 -0
- nnpdf_data/theory_cards/40010009.yaml +41 -0
- nnpdf_data/theory_cards/40010010.yaml +41 -0
- nnpdf_data/theory_cards/40010011.yaml +41 -0
- nnpdf_data/theory_cards/40010012.yaml +41 -0
- nnpdf_data/theory_cards/40011000.yaml +41 -0
- nnpdf_data/theory_cards/40011001.yaml +41 -0
- nnpdf_data/theory_cards/40011002.yaml +41 -0
- nnpdf_data/theory_cards/40011003.yaml +41 -0
- nnpdf_data/theory_cards/40011004.yaml +41 -0
- nnpdf_data/theory_cards/40011005.yaml +41 -0
- nnpdf_data/theory_cards/40011006.yaml +41 -0
- nnpdf_data/theory_cards/40011007.yaml +41 -0
- nnpdf_data/theory_cards/40011008.yaml +41 -0
- nnpdf_data/theory_cards/40011009.yaml +41 -0
- nnpdf_data/theory_cards/40011010.yaml +41 -0
- nnpdf_data/theory_cards/40011011.yaml +41 -0
- nnpdf_data/theory_cards/40011012.yaml +41 -0
- nnpdf_data/theory_cards/40012000.yaml +41 -0
- nnpdf_data/theory_cards/40012001.yaml +41 -0
- nnpdf_data/theory_cards/40012002.yaml +41 -0
- nnpdf_data/theory_cards/40012003.yaml +41 -0
- nnpdf_data/theory_cards/40012004.yaml +41 -0
- nnpdf_data/theory_cards/40012005.yaml +41 -0
- nnpdf_data/theory_cards/40012006.yaml +41 -0
- nnpdf_data/theory_cards/40012007.yaml +41 -0
- nnpdf_data/theory_cards/40012008.yaml +41 -0
- nnpdf_data/theory_cards/40012009.yaml +41 -0
- nnpdf_data/theory_cards/40012010.yaml +41 -0
- nnpdf_data/theory_cards/40012011.yaml +41 -0
- nnpdf_data/theory_cards/40012012.yaml +41 -0
- nnpdf_data/theorydbutils.py +23 -24
- nnpdf_data/utils.py +6 -8
- nnpdf_data/validphys_compatibility.py +77 -0
- {nnpdf_data-0.0.1.dist-info → nnpdf_data-0.0.2.dist-info}/METADATA +4 -5
- {nnpdf_data-0.0.1.dist-info → nnpdf_data-0.0.2.dist-info}/RECORD +311 -100
- {nnpdf_data-0.0.1.dist-info → nnpdf_data-0.0.2.dist-info}/WHEEL +1 -1
- /nnpdf_data/commondata/CMS_Z0J_8TEV/{uncertainties_PT-Y_sys_10_NNPDF31.yaml → uncertainties_legacy_PT-Y_sys_10_NNPDF31.yaml} +0 -0
- /nnpdf_data/commondata/CMS_Z0J_8TEV/{uncertainties_PT-Y_sys_NNPDF31.yaml → uncertainties_legacy_PT-Y_sys_NNPDF31.yaml} +0 -0
- /nnpdf_data/commondata/HERA_CC_318GEV/{data_legacy_EM-SIGMARED.yaml → data_EM-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_CC_318GEV/{data_legacy_EP-SIGMARED.yaml → data_EP-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_NC_225GEV/{data_legacy_EP-SIGMARED.yaml → data_EP-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_NC_251GEV/{data_legacy_EP-SIGMARED.yaml → data_EP-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_NC_300GEV/{data_legacy_EP-SIGMARED.yaml → data_EP-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_NC_318GEV/{data_legacy_EM-SIGMARED.yaml → data_EM-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_NC_318GEV/{data_legacy_EP-SIGMARED.yaml → data_EP-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_NC_318GEV_EAVG/{data_legacy_BOTTOM-SIGMARED.yaml → data_BOTTOM-SIGMARED.yaml} +0 -0
- /nnpdf_data/commondata/HERA_NC_318GEV_EAVG/{data_legacy_CHARM-SIGMARED.yaml → data_CHARM-SIGMARED.yaml} +0 -0
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
setname: SLAC_NC_NOTFIXED_P
|
|
2
2
|
version: 2
|
|
3
|
-
version_comment: Port of old commondata
|
|
3
|
+
version_comment: Port of old commondata. Data are in agreement with Fig. 2 of the reference and corresponds to a re-analysis of the SLAC data of E49a, E49b, E61, E87, E89a, E89b, E139, E140. Source not available.
|
|
4
4
|
nnpdf_metadata:
|
|
5
5
|
nnpdf31_process: DIS NC
|
|
6
6
|
experiment: null
|
|
7
7
|
arXiv:
|
|
8
|
-
url: https://arxiv.org/abs/Phys. Lett. B282 (1992) 475
|
|
9
|
-
iNSPIRE:
|
|
10
8
|
url: ''
|
|
9
|
+
journal: Phys. Lett. B282 (1992) 475
|
|
10
|
+
iNSPIRE:
|
|
11
|
+
url: https://inspirehep.net/literature/319089
|
|
11
12
|
hepdata:
|
|
12
13
|
url: ''
|
|
13
14
|
version: -1
|
|
@@ -17,12 +18,12 @@ implemented_observables:
|
|
|
17
18
|
description: Deep Inelastic Scattering
|
|
18
19
|
label: SLAC $p$
|
|
19
20
|
units: ''
|
|
20
|
-
process_type:
|
|
21
|
+
process_type: DIS_NC
|
|
21
22
|
tables: []
|
|
22
23
|
npoints: []
|
|
23
24
|
ndata: 211
|
|
24
25
|
plotting:
|
|
25
|
-
kinematics_override:
|
|
26
|
+
kinematics_override: identity
|
|
26
27
|
theory_reference: Bertone:2013vaa
|
|
27
28
|
dataset_label: SLAC $p$
|
|
28
29
|
y_label: $10^{i}F_2(x,Q^2)$
|
|
@@ -30,25 +31,25 @@ implemented_observables:
|
|
|
30
31
|
data_reference: Whitlow:1991uw
|
|
31
32
|
y_scale: symlog
|
|
32
33
|
line_by:
|
|
33
|
-
-
|
|
34
|
-
plot_x:
|
|
34
|
+
- x
|
|
35
|
+
plot_x: Q2
|
|
35
36
|
kinematic_coverage:
|
|
36
|
-
-
|
|
37
|
-
-
|
|
38
|
-
-
|
|
37
|
+
- x
|
|
38
|
+
- Q2
|
|
39
|
+
- y
|
|
39
40
|
kinematics:
|
|
40
41
|
variables:
|
|
41
|
-
|
|
42
|
-
description:
|
|
43
|
-
label:
|
|
42
|
+
x:
|
|
43
|
+
description: Bjorken x
|
|
44
|
+
label: '$x$'
|
|
44
45
|
units: ''
|
|
45
|
-
|
|
46
|
-
description:
|
|
47
|
-
label:
|
|
46
|
+
Q2:
|
|
47
|
+
description: Momentum transfer
|
|
48
|
+
label: '$Q^2$'
|
|
48
49
|
units: ''
|
|
49
|
-
|
|
50
|
-
description:
|
|
51
|
-
label:
|
|
50
|
+
y:
|
|
51
|
+
description: Inelasticity
|
|
52
|
+
label: '$y$'
|
|
52
53
|
units: ''
|
|
53
54
|
file: kinematics_EM-F2.yaml
|
|
54
55
|
theory:
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
from ruamel.yaml import YAML
|
|
2
|
+
from glob import glob
|
|
3
|
+
from pathlib import Path
|
|
4
|
+
|
|
5
|
+
yaml = YAML()
|
|
6
|
+
yaml.preserve_quotes = True
|
|
7
|
+
yaml.width = 4096
|
|
8
|
+
|
|
9
|
+
changed_datasets = []
|
|
10
|
+
|
|
11
|
+
for metadata_file in glob("*/metadata.yaml"):
|
|
12
|
+
with open(metadata_file, "r") as f:
|
|
13
|
+
metadata = yaml.load(f)
|
|
14
|
+
|
|
15
|
+
for observable in metadata["implemented_observables"]:
|
|
16
|
+
variants = observable.get("variants", {})
|
|
17
|
+
legacy = variants.get("legacy", {})
|
|
18
|
+
if "theory" in legacy:
|
|
19
|
+
legacy_data = dict(legacy)
|
|
20
|
+
legacy_theory = {"theory": legacy_data.pop("theory")}
|
|
21
|
+
|
|
22
|
+
# Not all will have both legacy data and theory, in those cases skip
|
|
23
|
+
if not legacy_data:
|
|
24
|
+
continue
|
|
25
|
+
variants["legacy_data"] = legacy_data
|
|
26
|
+
variants["legacy_theory"] = legacy_theory
|
|
27
|
+
|
|
28
|
+
changed_datasets.append(
|
|
29
|
+
f"{Path(metadata_file).parent.name}_{observable['observable_name']}"
|
|
30
|
+
)
|
|
31
|
+
|
|
32
|
+
with open(metadata_file, "w") as f:
|
|
33
|
+
yaml.dump(metadata, f)
|
|
34
|
+
|
|
35
|
+
print("\n".join(changed_datasets))
|
nnpdf_data/commondataparser.py
CHANGED
|
@@ -37,22 +37,20 @@ by modifying the CommonMetaData using one of the loaded Variants one can change
|
|
|
37
37
|
"""
|
|
38
38
|
|
|
39
39
|
import dataclasses
|
|
40
|
-
from functools import
|
|
40
|
+
from functools import cache, cached_property
|
|
41
41
|
import logging
|
|
42
42
|
from pathlib import Path
|
|
43
|
-
from typing import Any,
|
|
43
|
+
from typing import Any, Optional
|
|
44
44
|
|
|
45
45
|
import numpy as np
|
|
46
46
|
import pandas as pd
|
|
47
47
|
from validobj import ValidationError, parse_input
|
|
48
48
|
from validobj.custom import Parser
|
|
49
49
|
|
|
50
|
-
# We cannot use ruamel directly due to the ambiguity ruamel.yaml / ruamel_yaml
|
|
51
|
-
# of some versions which are pinned in some of the conda packages we use...
|
|
52
|
-
from . import new_to_legacy_map, path_commondata
|
|
53
50
|
from .coredata import KIN_NAMES, CommonData
|
|
54
51
|
from .process_options import ValidProcess
|
|
55
52
|
from .utils import parse_yaml_inp, quick_yaml_load
|
|
53
|
+
from .validphys_compatibility import new_to_legacy_map, path_commondata
|
|
56
54
|
|
|
57
55
|
try:
|
|
58
56
|
from validphys.plotoptions.plottingoptions import PlottingOptions, labeler_functions
|
|
@@ -107,6 +105,10 @@ KINLABEL_LATEX = {
|
|
|
107
105
|
"SHP_ASY": ("$\\eta$", "$p_T (GeV)$", "$\\sqrt{s} (GeV)$"),
|
|
108
106
|
"JET_POL": ("$\\eta$", "$p_T^2 (GeV^2)$", "$\\sqrt{s} (GeV)$"),
|
|
109
107
|
"DIJET_POL": ("$\\m_{1,2} (GeV)", "$\\eta_1$", "$\\eta_2$"),
|
|
108
|
+
"DY_Z_Y": ("$y_Z$", "$\\M^2 (GeV^2)$", "$\\sqrt{s} (GeV)$"),
|
|
109
|
+
"SINGLETOP": ("$y$", "$m_t^2 (GeV^2)$", "$\\sqrt{s} (GeV)$"),
|
|
110
|
+
"DY_MLL": ("$M_{ll} (GeV)$", "$M_{ll}^2 (GeV^2)$", "$\\sqrt{s} (GeV)$"),
|
|
111
|
+
"DY_W_ETA": ("$abs_\\eta$", "$M_W^2 (GeV^2)$", "$\\sqrt{s} (GeV)$"),
|
|
110
112
|
}
|
|
111
113
|
|
|
112
114
|
PROCESS_DESCRIPTION_LABEL = {
|
|
@@ -134,6 +136,8 @@ PROCESS_DESCRIPTION_LABEL = {
|
|
|
134
136
|
"JET_POL": "Inclusive Jet longitudinal double-spin asymmetry",
|
|
135
137
|
"DIJET_POL": "Dijets longitudinal double-spin asymmetry",
|
|
136
138
|
"SHP_ASY": "double spin asymmetry in single hadron production",
|
|
139
|
+
"DY_MLL": "Drell-Yan Mass Distribution of Lepton Pairs",
|
|
140
|
+
"DY_W_ETA": "Drell-Yan W boson rapidity distribution",
|
|
137
141
|
}
|
|
138
142
|
|
|
139
143
|
|
|
@@ -226,9 +230,9 @@ class TheoryMeta:
|
|
|
226
230
|
|
|
227
231
|
Example
|
|
228
232
|
-------
|
|
229
|
-
>>> from
|
|
233
|
+
>>> from nnpdf_data.commondataparser import TheoryMeta
|
|
230
234
|
... from validobj import parse_input
|
|
231
|
-
... from
|
|
235
|
+
... from ruamel.yaml import YAML
|
|
232
236
|
... theory_raw = '''
|
|
233
237
|
... FK_tables:
|
|
234
238
|
... - - fk1
|
|
@@ -236,7 +240,7 @@ class TheoryMeta:
|
|
|
236
240
|
... - fk3
|
|
237
241
|
... operation: ratio
|
|
238
242
|
... '''
|
|
239
|
-
... theory =
|
|
243
|
+
... theory = YAML(typ='safe').load(theory_raw)
|
|
240
244
|
... parse_input(theory, TheoryMeta)
|
|
241
245
|
TheoryMeta(FK_tables=[['fk1'], ['fk2', 'fk3']], operation='RATIO', shifts = None, conversion_factor=1.0, comment=None, normalization=None))
|
|
242
246
|
"""
|
|
@@ -307,7 +311,7 @@ class Variant:
|
|
|
307
311
|
experiment: Optional[str] = None
|
|
308
312
|
|
|
309
313
|
|
|
310
|
-
ValidVariants =
|
|
314
|
+
ValidVariants = dict[str, Variant]
|
|
311
315
|
|
|
312
316
|
|
|
313
317
|
### Kinematic data
|
|
@@ -349,7 +353,7 @@ class ValidKinematics:
|
|
|
349
353
|
"""
|
|
350
354
|
|
|
351
355
|
file: ValidPath
|
|
352
|
-
variables:
|
|
356
|
+
variables: dict[str, ValidVariable]
|
|
353
357
|
|
|
354
358
|
def get_label(self, var):
|
|
355
359
|
"""For the given variable, return the label as label (unit)
|
|
@@ -439,10 +443,8 @@ class ObservableMetaData:
|
|
|
439
443
|
raise ValidationError(f"Missing `data_central` field for {self.name}")
|
|
440
444
|
|
|
441
445
|
if not self.data_uncertainties:
|
|
442
|
-
ermsg = f"Missing `data_uncertainties` for {self.name}.
|
|
443
|
-
|
|
444
|
-
if "legacy" in self.variants:
|
|
445
|
-
ermsg += " Maybe you intended to use `variant: legacy`?"
|
|
446
|
+
ermsg = f"""Missing `data_uncertainties` for {self.name}.
|
|
447
|
+
Select one of the variants: {list(self.variants.keys())}"""
|
|
446
448
|
raise ValidationError(ermsg)
|
|
447
449
|
|
|
448
450
|
# Check that plotting.plot_x is being filled
|
|
@@ -553,7 +555,6 @@ class ObservableMetaData:
|
|
|
553
555
|
all_df = []
|
|
554
556
|
for ufile in self.paths_uncertainties:
|
|
555
557
|
uncyaml = quick_yaml_load(ufile)
|
|
556
|
-
|
|
557
558
|
mindex = pd.MultiIndex.from_tuples(
|
|
558
559
|
[(k, v["treatment"], v["type"]) for k, v in uncyaml["definitions"].items()],
|
|
559
560
|
names=["name", "treatment", "type"],
|
|
@@ -652,10 +653,6 @@ class ObservableMetaData:
|
|
|
652
653
|
if self.ported_from is None:
|
|
653
654
|
return False
|
|
654
655
|
|
|
655
|
-
# If it is using a legacy variant and has a ported_from field, then it is a ported one
|
|
656
|
-
if self.applied_variant is not None and self.applied_variant.startswith("legacy"):
|
|
657
|
-
return True
|
|
658
|
-
|
|
659
656
|
# If not using a legacy variant, we consider it ported if the kin variables are still k1,k2,k3
|
|
660
657
|
return {"k1", "k2", "k3"} == set(self.kinematic_coverage)
|
|
661
658
|
|
|
@@ -745,6 +742,18 @@ class ObservableMetaData:
|
|
|
745
742
|
new_line_by.append(self.digest_plotting_variable(var))
|
|
746
743
|
self.plotting.line_by = new_line_by
|
|
747
744
|
|
|
745
|
+
# And do it also within the normalize dictionary
|
|
746
|
+
if self.plotting.normalize is not None:
|
|
747
|
+
# Copy the normalize dictionary and update the figure and line by
|
|
748
|
+
tmp = dict(self.plotting.normalize)
|
|
749
|
+
tmp["figure_by"] = []
|
|
750
|
+
tmp["line_by"] = []
|
|
751
|
+
for var in self.plotting.normalize.get("figure_by", []):
|
|
752
|
+
tmp["figure_by"].append(self.digest_plotting_variable(var))
|
|
753
|
+
for var in self.plotting.normalize.get("line_by", []):
|
|
754
|
+
tmp["line_by"].append(self.digest_plotting_variable(var))
|
|
755
|
+
self.plotting.normalize = tmp
|
|
756
|
+
|
|
748
757
|
self.plotting.already_digested = True
|
|
749
758
|
return self.plotting
|
|
750
759
|
|
|
@@ -827,13 +836,13 @@ class SetMetaData:
|
|
|
827
836
|
return observable
|
|
828
837
|
|
|
829
838
|
|
|
830
|
-
@
|
|
839
|
+
@cache
|
|
831
840
|
def parse_set_metadata(metadata_file):
|
|
832
841
|
"""Read the metadata file"""
|
|
833
842
|
return parse_yaml_inp(metadata_file, SetMetaData)
|
|
834
843
|
|
|
835
844
|
|
|
836
|
-
@
|
|
845
|
+
@cache
|
|
837
846
|
def parse_new_metadata(metadata_file, observable_name, variant=None):
|
|
838
847
|
"""Given a metadata file in the new format and the specific observable to be read
|
|
839
848
|
load and parse the metadata and select the observable. If any variants are selected, apply them.
|
nnpdf_data/coredata.py
CHANGED
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
from pathlib import Path
|
|
2
|
+
from dataclasses import dataclass
|
|
3
|
+
import typing
|
|
4
|
+
from typing import List
|
|
5
|
+
import numpy as np
|
|
6
|
+
import pandas as pd
|
|
7
|
+
from os import PathLike
|
|
8
|
+
import yaml
|
|
9
|
+
#from validphys.api import API
|
|
10
|
+
|
|
11
|
+
@dataclass
|
|
12
|
+
class commondata:
|
|
13
|
+
central_values: np.ndarray
|
|
14
|
+
kinematics: np.ndarray
|
|
15
|
+
statistical_uncertainties: np.ndarray
|
|
16
|
+
systematic_uncertainties: np.ndarray
|
|
17
|
+
systypes: List[tuple[str, str]]
|
|
18
|
+
process: str
|
|
19
|
+
dataset_name: str
|
|
20
|
+
kinematic_quantities: List[str]
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
# Procedure to create data_*.yaml, kinematics_*.yaml and uncertainties_*.yaml
|
|
24
|
+
def write_new_commondata(self, data_filename: str | PathLike,
|
|
25
|
+
kinematics_filename: str | PathLike,
|
|
26
|
+
uncertainties_filename: str | PathLike):
|
|
27
|
+
# central data values
|
|
28
|
+
data = {"data_central": self.central_values.tolist()}
|
|
29
|
+
with data_filename.open("w+") as f:
|
|
30
|
+
yaml.dump(data, f, default_flow_style=False, sort_keys=False)
|
|
31
|
+
|
|
32
|
+
# kinematic quantieties
|
|
33
|
+
# TODO add arrays for min and max values to derived type?
|
|
34
|
+
bins = []
|
|
35
|
+
for kin in self.kinematics.tolist():
|
|
36
|
+
bins.append(
|
|
37
|
+
{self.kinematic_quantities[0]:
|
|
38
|
+
{
|
|
39
|
+
"min": None,
|
|
40
|
+
"mid": kin[0],
|
|
41
|
+
"max": None
|
|
42
|
+
},
|
|
43
|
+
self.kinematic_quantities[1]:
|
|
44
|
+
{
|
|
45
|
+
"min": None,
|
|
46
|
+
"mid": kin[1],
|
|
47
|
+
"max": None
|
|
48
|
+
},
|
|
49
|
+
self.kinematic_quantities[2]:
|
|
50
|
+
{
|
|
51
|
+
"min": None,
|
|
52
|
+
"mid": kin[2],
|
|
53
|
+
"max": None
|
|
54
|
+
}
|
|
55
|
+
})
|
|
56
|
+
data = {"bins": bins}
|
|
57
|
+
with kinematics_filename.open("w+") as f:
|
|
58
|
+
yaml.dump(data, f, default_flow_style=False, sort_keys=False)
|
|
59
|
+
|
|
60
|
+
# uncertainties
|
|
61
|
+
# There is only one statistical uncertainty per datapoint.
|
|
62
|
+
definitions = {"stat":
|
|
63
|
+
{
|
|
64
|
+
"description": "Statistical uncertainty.",
|
|
65
|
+
"treatment": "ADD",
|
|
66
|
+
"type": "UNCORR"
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
for isys, sys in enumerate(self.systypes):
|
|
70
|
+
definitions.update(
|
|
71
|
+
{f"sys_corr_{isys}":
|
|
72
|
+
{
|
|
73
|
+
"description": f"Systematic uncertainty {isys}",
|
|
74
|
+
"treatment": sys[0],
|
|
75
|
+
"type": sys[1]
|
|
76
|
+
}
|
|
77
|
+
})
|
|
78
|
+
bins = {"bins": [] }
|
|
79
|
+
for i, _ in enumerate(self.central_values):
|
|
80
|
+
systematics = {"stat": self.statistical_uncertainties.tolist()[i]}
|
|
81
|
+
for isys, sys in enumerate(self.systematic_uncertainties[i].tolist()):
|
|
82
|
+
systematics.update({f"sys_corr_{isys}": sys})
|
|
83
|
+
bins["bins"].append(systematics)
|
|
84
|
+
data = {"definitions": definitions }
|
|
85
|
+
# TODO Notation of reals is inconsistent from yaml.safe_dump
|
|
86
|
+
# sometimes it is in scientific notation sometimes not...
|
|
87
|
+
with uncertainties_filename.open("w+") as f:
|
|
88
|
+
yaml.safe_dump(data, f, default_flow_style=False, sort_keys=False)
|
|
89
|
+
yaml.safe_dump(bins, f, default_flow_style=False, sort_keys=False)
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
# Subroutines for testing the implementation of the commondata.
|
|
93
|
+
|
|
94
|
+
## Obtain the covariance matrix for a given variant.
|
|
95
|
+
#def _covmat(name: str, var: str):
|
|
96
|
+
# inp = {"dataset_input": {"dataset": name, "variant": var}, "theoryid": 700, "use_cuts": "internal"}
|
|
97
|
+
# return API.covmat_from_systematics(**inp)
|
|
98
|
+
#
|
|
99
|
+
## Compare the covariance matrices of two different variants. True if close.
|
|
100
|
+
#def covmat_is_close(name: str, var1: str, var2: str) -> bool:
|
|
101
|
+
# return np.isclose(_covmat(name,var1),_covmat(name,var2)).all()
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
""""Common functions to parse NMC data from Hepdata."""
|
|
2
|
+
|
|
3
|
+
import pandas as pd
|
|
4
|
+
import yaml
|
|
5
|
+
|
|
6
|
+
from .utils import check_xq2_degenearcy
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def read_tables(store_path, header_line):
|
|
10
|
+
"""Parse Tables."""
|
|
11
|
+
dfs = pd.DataFrame()
|
|
12
|
+
for file in store_path.iterdir():
|
|
13
|
+
with open(file, "r", encoding="utf-8") as f:
|
|
14
|
+
lines = f.readlines()
|
|
15
|
+
df = pd.DataFrame(
|
|
16
|
+
[l.split(",") for l in lines[header_line:-1]],
|
|
17
|
+
columns=["Q2", "R", "F2", "stat+", "stat-", "sys+", "sys-"],
|
|
18
|
+
)
|
|
19
|
+
df["x"] = float(lines[header_line - 2].split(",")[1])
|
|
20
|
+
dfs = pd.concat([dfs, df], ignore_index=True) if not dfs.empty else df
|
|
21
|
+
|
|
22
|
+
dfs = dfs.astype(float)
|
|
23
|
+
check_xq2_degenearcy(dfs.Q2.values, dfs.x.values)
|
|
24
|
+
return dfs.sort_values(["x", "Q2"])
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def write_files(df, store_path):
|
|
28
|
+
"""Write kinematics, central value and uncertainties files."""
|
|
29
|
+
|
|
30
|
+
# Write central data
|
|
31
|
+
data_central_yaml = {"data_central": [float(x) for x in df["F2"]]}
|
|
32
|
+
with open(store_path / "data_EM-F2-HEPDATA.yaml", "w", encoding="utf-8") as file:
|
|
33
|
+
yaml.dump(data_central_yaml, file)
|
|
34
|
+
|
|
35
|
+
# Write kin file
|
|
36
|
+
kin = []
|
|
37
|
+
for _, row in df.iterrows():
|
|
38
|
+
kin_value = {
|
|
39
|
+
"x": {"min": None, "mid": float(row.x), "max": None},
|
|
40
|
+
"Q2": {"min": None, "mid": float(row.Q2), "max": None},
|
|
41
|
+
}
|
|
42
|
+
kin.append(kin_value)
|
|
43
|
+
kinematics_yaml = {"bins": kin}
|
|
44
|
+
with open(store_path / "kinematics_EM-F2-HEPDATA.yaml", "w", encoding="utf-8") as file:
|
|
45
|
+
yaml.dump(kinematics_yaml, file, sort_keys=False)
|
|
46
|
+
|
|
47
|
+
# loop on data points
|
|
48
|
+
error_definition = {
|
|
49
|
+
"stat": {"description": "statistical uncertainty", "treatment": "ADD", "type": "UNCORR"},
|
|
50
|
+
"sys": {"description": "systematical uncertainty", "treatment": "MULT", "type": "CORR"},
|
|
51
|
+
}
|
|
52
|
+
error = []
|
|
53
|
+
for _, row in df.iterrows():
|
|
54
|
+
e = {"stat": float(row["stat+"]), "sys": float(row["sys+"])}
|
|
55
|
+
error.append(e)
|
|
56
|
+
|
|
57
|
+
uncertainties_yaml = {"definitions": error_definition, "bins": error}
|
|
58
|
+
with open(store_path / "uncertainties_EM-F2-HEPDATA.yaml", "w", encoding="utf-8") as file:
|
|
59
|
+
yaml.dump(uncertainties_yaml, file, sort_keys=False)
|
nnpdf_data/filter_utils/utils.py
CHANGED
|
@@ -162,7 +162,7 @@ def covmat_to_artunc(ndata, covmat_list, no_of_norm_mat=0):
|
|
|
162
162
|
elif eigval[j] > 0:
|
|
163
163
|
continue
|
|
164
164
|
if not psd_check:
|
|
165
|
-
raise ValueError(
|
|
165
|
+
raise ValueError("The covariance matrix is not positive-semidefinite")
|
|
166
166
|
else:
|
|
167
167
|
for i in range(ndata):
|
|
168
168
|
for j in range(ndata):
|
|
@@ -244,7 +244,7 @@ def matlist_to_matrix(rows, columns, mat_list):
|
|
|
244
244
|
matrix = np.array(matrix)
|
|
245
245
|
return matrix
|
|
246
246
|
else:
|
|
247
|
-
raise Exception(
|
|
247
|
+
raise Exception("rows * columns != len(mat_list)")
|
|
248
248
|
|
|
249
249
|
|
|
250
250
|
def concat_matrices(rows, columns, list_of_matrices):
|
|
@@ -363,7 +363,7 @@ def trimat_to_fullmat(mode, tri_mat_list):
|
|
|
363
363
|
matrix[i][j] = tri_mat_list[list_el]
|
|
364
364
|
matrix[j][i] = tri_mat_list[list_el]
|
|
365
365
|
else:
|
|
366
|
-
raise Exception(
|
|
366
|
+
raise Exception("Mode should be 0 or 1, refer to the function for usage")
|
|
367
367
|
mat_list = []
|
|
368
368
|
for i in range(dim):
|
|
369
369
|
for j in range(dim):
|
|
@@ -422,10 +422,22 @@ def prettify_float(dumper, value):
|
|
|
422
422
|
ret = dumper.represent_float(value)
|
|
423
423
|
if len(ret.value) > 8:
|
|
424
424
|
ret_str = f"{value:.8e}"
|
|
425
|
-
ret = dumper.represent_scalar(
|
|
425
|
+
ret = dumper.represent_scalar("tag:yaml.org,2002:float", ret_str)
|
|
426
426
|
return ret
|
|
427
427
|
|
|
428
428
|
|
|
429
|
+
def check_xq2_degenearcy(Q2, x):
|
|
430
|
+
"""Check is the pair of (x,Q2) is unique."""
|
|
431
|
+
size = len(x)
|
|
432
|
+
unique_pairs = np.unique(np.array([Q2, x]), axis=1)
|
|
433
|
+
try:
|
|
434
|
+
assert unique_pairs.shape[1] == size
|
|
435
|
+
except AssertionError as exc:
|
|
436
|
+
raise ValueError(
|
|
437
|
+
f"""(x,Q2) kinematic is degenerate need to store 3rd kinematic variable as well.
|
|
438
|
+
unique kinematics are: {unique_pairs.shape[1]}, original size: {size}"""
|
|
439
|
+
) from exc
|
|
440
|
+
|
|
429
441
|
def uncert_skip_variant(source_file, skip_file, uncert_file, uncert_name, remove_source=True):
|
|
430
442
|
r"""
|
|
431
443
|
Create two new uncertainty files, one where the specified uncertainty
|
nnpdf_data/process_options.py
CHANGED
|
@@ -37,7 +37,9 @@ class _Vars:
|
|
|
37
37
|
abs_eta_2 = "abs_eta_2"
|
|
38
38
|
eta_1 = "eta_1"
|
|
39
39
|
eta_2 = "eta_2"
|
|
40
|
+
m_ll = "m_ll"
|
|
40
41
|
m_ll2 = "m_ll2"
|
|
42
|
+
abs_y = "abs_y"
|
|
41
43
|
|
|
42
44
|
|
|
43
45
|
class _KinematicsInformation:
|
|
@@ -164,6 +166,20 @@ def _shp_xq2map(kin_info):
|
|
|
164
166
|
return np.clip(x, a_min=None, a_max=1, out=x), np.concatenate((q2, q2))
|
|
165
167
|
|
|
166
168
|
|
|
169
|
+
def _pht_xq2map(kin_info):
|
|
170
|
+
# Then compute x, Q2
|
|
171
|
+
ET = kin_info.get_one_of(_Vars.ET)
|
|
172
|
+
ET2 = ET**2
|
|
173
|
+
eta = kin_info.get_one_of(_Vars.eta, _Vars.y)
|
|
174
|
+
sqrts = kin_info[_Vars.sqrts]
|
|
175
|
+
|
|
176
|
+
# eta = y for massless particles
|
|
177
|
+
x1 = ET / sqrts * np.exp(-eta)
|
|
178
|
+
x2 = ET / sqrts * np.exp(eta)
|
|
179
|
+
x = np.concatenate((x1, x2))
|
|
180
|
+
return np.clip(x, a_min=None, a_max=1, out=x), np.concatenate((ET2, ET2))
|
|
181
|
+
|
|
182
|
+
|
|
167
183
|
def _dijets_xq2map(kin_info):
|
|
168
184
|
# Here we can have either ystar or ydiff, but in either case we need to do the same
|
|
169
185
|
ylab_1 = kin_info.get_one_of(_Vars.ystar, _Vars.ydiff, _Vars.eta_1, _Vars.abs_eta_1)
|
|
@@ -213,7 +229,6 @@ def _inc_xq2map(kin_info):
|
|
|
213
229
|
# Compute x, Q2
|
|
214
230
|
# k2 necessary to take the mass for DY inclusive cross sections still not migrated
|
|
215
231
|
mass2 = kin_info.get_one_of(_Vars.m_W2, _Vars.m_Z2, _Vars.m_t2, "k2")
|
|
216
|
-
|
|
217
232
|
return np.sqrt(mass2) / kin_info[_Vars.sqrts], mass2
|
|
218
233
|
|
|
219
234
|
|
|
@@ -236,7 +251,7 @@ def _dyboson_xq2map(kin_info):
|
|
|
236
251
|
originating from a W boson DY process.
|
|
237
252
|
"""
|
|
238
253
|
mass2 = kin_info.get_one_of(_Vars.m_W2, _Vars.m_Z2, _Vars.m_V2)
|
|
239
|
-
eta = kin_info.get_one_of(_Vars.eta, _Vars.y)
|
|
254
|
+
eta = kin_info.get_one_of(_Vars.eta, _Vars.y, _Vars.abs_eta)
|
|
240
255
|
sqrts = kin_info[_Vars.sqrts]
|
|
241
256
|
|
|
242
257
|
# eta = y for massless particles
|
|
@@ -265,8 +280,8 @@ def _dybosonptrap_xq2map(kin_info):
|
|
|
265
280
|
using the rapidity of the final lepton pair.
|
|
266
281
|
"""
|
|
267
282
|
pT = kin_info[_Vars.pT]
|
|
268
|
-
eta = kin_info.get_one_of(_Vars.eta, _Vars.y)
|
|
269
|
-
m_ll2 = kin_info
|
|
283
|
+
eta = kin_info.get_one_of(_Vars.eta, _Vars.y, _Vars.abs_y)
|
|
284
|
+
m_ll2 = kin_info.get_one_of(_Vars.m_ll2, _Vars.m_Z2)
|
|
270
285
|
sqrts = kin_info[_Vars.sqrts]
|
|
271
286
|
ET2 = m_ll2 + pT * pT
|
|
272
287
|
x1 = (np.sqrt(ET2) + pT) / sqrts * np.exp(-eta)
|
|
@@ -275,6 +290,34 @@ def _dybosonptrap_xq2map(kin_info):
|
|
|
275
290
|
return x, np.concatenate((ET2, ET2))
|
|
276
291
|
|
|
277
292
|
|
|
293
|
+
def _singletop_xq2map(kin_dict):
|
|
294
|
+
|
|
295
|
+
y_t = kin_dict[_Vars.y_t]
|
|
296
|
+
sqrts = kin_dict[_Vars.sqrts]
|
|
297
|
+
m_t2 = kin_dict[_Vars.m_t2]
|
|
298
|
+
|
|
299
|
+
q2 = m_t2
|
|
300
|
+
ratio = np.sqrt(q2) / sqrts
|
|
301
|
+
x1 = ratio * np.exp(y_t)
|
|
302
|
+
x2 = ratio * np.exp(-y_t)
|
|
303
|
+
x = np.concatenate((x1, x2))
|
|
304
|
+
return np.clip(x, a_min=None, a_max=1, out=x), np.concatenate((q2, q2))
|
|
305
|
+
|
|
306
|
+
|
|
307
|
+
def _dymll_xq2map(kin_info):
|
|
308
|
+
"""
|
|
309
|
+
Computes x and q2 mapping for DY Z -> 2 leptons mass.
|
|
310
|
+
x is approximated as x = sqrt(x1*x2) with m_ll^2 = x1*x2*s
|
|
311
|
+
"""
|
|
312
|
+
|
|
313
|
+
m_ll = kin_info.get_one_of(_Vars.m_ll)
|
|
314
|
+
sqrts = kin_info.get_one_of(_Vars.sqrts)
|
|
315
|
+
m_ll2 = m_ll**2
|
|
316
|
+
x = m_ll / sqrts
|
|
317
|
+
|
|
318
|
+
return x, m_ll2
|
|
319
|
+
|
|
320
|
+
|
|
278
321
|
DIS = _Process(
|
|
279
322
|
"DIS",
|
|
280
323
|
"Deep Inelastic Scattering",
|
|
@@ -341,7 +384,14 @@ HQP_YQ = _Process(
|
|
|
341
384
|
HQP_PTQ = _Process(
|
|
342
385
|
"HQP_PTQ",
|
|
343
386
|
"Transverse momentum of top quark in top pair production",
|
|
344
|
-
accepted_variables=(
|
|
387
|
+
accepted_variables=(
|
|
388
|
+
_Vars.pT_t,
|
|
389
|
+
_Vars.m_ttBar,
|
|
390
|
+
_Vars.y_t,
|
|
391
|
+
_Vars.y_ttBar,
|
|
392
|
+
_Vars.sqrts,
|
|
393
|
+
_Vars.m_t2,
|
|
394
|
+
),
|
|
345
395
|
xq2map_function=_hqp_ptq_xq2map,
|
|
346
396
|
)
|
|
347
397
|
|
|
@@ -370,10 +420,24 @@ HERAJET = _Process(
|
|
|
370
420
|
DY_2L = _Process(
|
|
371
421
|
"DY_2L",
|
|
372
422
|
"DY W or Z -> 2 leptons ",
|
|
373
|
-
accepted_variables=(
|
|
423
|
+
accepted_variables=(
|
|
424
|
+
_Vars.y,
|
|
425
|
+
_Vars.eta,
|
|
426
|
+
_Vars.m_W2,
|
|
427
|
+
_Vars.m_Z2,
|
|
428
|
+
_Vars.m_V2,
|
|
429
|
+
_Vars.sqrts,
|
|
430
|
+
_Vars.abs_eta,
|
|
431
|
+
),
|
|
374
432
|
xq2map_function=_dyboson_xq2map,
|
|
375
433
|
)
|
|
376
434
|
|
|
435
|
+
DY_MLL = _Process(
|
|
436
|
+
"DY_MLL",
|
|
437
|
+
"DY Z -> ll mass of lepton pair",
|
|
438
|
+
accepted_variables=(_Vars.m_ll, _Vars.sqrts),
|
|
439
|
+
xq2map_function=_dymll_xq2map,
|
|
440
|
+
)
|
|
377
441
|
|
|
378
442
|
DY_PT = _Process(
|
|
379
443
|
"DY_PT",
|
|
@@ -391,6 +455,7 @@ DY_PT_RAP = _Process(
|
|
|
391
455
|
_Vars.m_Z2,
|
|
392
456
|
_Vars.sqrts,
|
|
393
457
|
_Vars.y,
|
|
458
|
+
_Vars.abs_y,
|
|
394
459
|
_Vars.eta,
|
|
395
460
|
_Vars.m_ll2,
|
|
396
461
|
),
|
|
@@ -404,12 +469,29 @@ POS_DIS = _Process(
|
|
|
404
469
|
"POS_DIS", "Positivity of F2 structure functions", accepted_variables=(_Vars.x, _Vars.Q2)
|
|
405
470
|
)
|
|
406
471
|
|
|
472
|
+
PHT = _Process(
|
|
473
|
+
"PHT",
|
|
474
|
+
"Photon production",
|
|
475
|
+
accepted_variables=(_Vars.eta, _Vars.ET, _Vars.sqrts),
|
|
476
|
+
xq2map_function=_pht_xq2map,
|
|
477
|
+
)
|
|
478
|
+
|
|
479
|
+
SINGLETOP = _Process(
|
|
480
|
+
"SINGLETOP",
|
|
481
|
+
"Single top production",
|
|
482
|
+
accepted_variables=(_Vars.m_t2, _Vars.sqrts, _Vars.y_t, _Vars.pT_t),
|
|
483
|
+
xq2map_function=_singletop_xq2map,
|
|
484
|
+
)
|
|
485
|
+
|
|
486
|
+
|
|
407
487
|
PROCESSES = {
|
|
408
488
|
"DIS": DIS,
|
|
409
489
|
"DIS_NC": dataclasses.replace(DIS, name="DIS_NC"),
|
|
410
490
|
"DIS_CC": dataclasses.replace(DIS, name="DIS_CC"),
|
|
411
491
|
"DIS_NCE": dataclasses.replace(DIS, name="DIS_NCE"),
|
|
412
492
|
"DIS_POL": dataclasses.replace(DIS, name="DIS_POL"),
|
|
493
|
+
"DIS_NC_CHARM": dataclasses.replace(DIS, name="DIS_NC_CHARM"),
|
|
494
|
+
"DIS_NC_BOTTOM": dataclasses.replace(DIS, name="DIS_NC_BOTTOM"),
|
|
413
495
|
"JET": JET,
|
|
414
496
|
"DIJET": DIJET,
|
|
415
497
|
"SHP_ASY": SHP,
|
|
@@ -422,7 +504,8 @@ PROCESSES = {
|
|
|
422
504
|
"HERADIJET": dataclasses.replace(HERAJET, name="HERADIJET", description="DIS + jj production"),
|
|
423
505
|
"JET_POL": JET_POL,
|
|
424
506
|
"DIJET_POL": DIJET_POL,
|
|
425
|
-
"DY_Z_Y": dataclasses.replace(DY_2L, name="DY_Z_Y", description="DY Z -> ll rapidity"),
|
|
507
|
+
"DY_Z_Y": dataclasses.replace(DY_2L, name="DY_Z_Y", description="DY Z -> ll (pseudo)rapidity"),
|
|
508
|
+
"DY_MLL": DY_MLL,
|
|
426
509
|
"DY_W_ETA": dataclasses.replace(
|
|
427
510
|
DY_2L, name="DY_W_ETA", description="DY W -> l nu pseudorapidity"
|
|
428
511
|
),
|
|
@@ -430,9 +513,12 @@ PROCESSES = {
|
|
|
430
513
|
DY_2L, name="DY_VB_ETA", description="DY Z/W -> ll pseudorapidity"
|
|
431
514
|
),
|
|
432
515
|
"DY_NC_PT": dataclasses.replace(DY_PT, name="DY_NC_PT", description="DY Z (ll) + j"),
|
|
516
|
+
"DY_CC_PT": dataclasses.replace(DY_PT, name="DY_CC_PT", description="DY W + j"),
|
|
433
517
|
"DY_NC_PTRAP": dataclasses.replace(DY_PT_RAP, name="DY_NC_PTRAP", description="DY Z (ll) + j"),
|
|
434
518
|
"POS_XPDF": POS_XPDF,
|
|
435
519
|
"POS_DIS": POS_DIS,
|
|
520
|
+
"PHT": PHT,
|
|
521
|
+
"SINGLETOP": SINGLETOP,
|
|
436
522
|
}
|
|
437
523
|
|
|
438
524
|
|