diff --git a/.flake8 b/.flake8 index d9b24d51..8521cd87 100644 --- a/.flake8 +++ b/.flake8 @@ -1,3 +1,5 @@ [flake8] ignore = W391, W503 -max-line-length = 79 +max-line-length = 88 +extend-ignore = E203, E704, E266 +exclude = menu_tools/object_performance/quality_obj.py,menu_tools/**/test_*.py diff --git a/.github/workflows/action.yml b/.github/workflows/action.yml deleted file mode 100644 index cd6a33e8..00000000 --- a/.github/workflows/action.yml +++ /dev/null @@ -1,25 +0,0 @@ -name: Python Tests -on: [push] - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - name: Set up Python 3.10 - uses: actions/setup-python@v4 - with: - python-version: '3.10' - architecture: 'x64' - - name: Install dependencies - run: | - python -m pip install --upgrade pip wheel setuptools==65.5.1 - pip install flake8 pytest - if [ -f objectPerformance/requirements.txt ]; then pip install -r objectPerformance/requirements.txt; fi - - name: Run Flake8 - run: flake8 objectPerformance - - name: Run Tests - run: | - cd objectPerformance - python -m pytest - diff --git a/.github/workflows/code_quality.yml b/.github/workflows/code_quality.yml new file mode 100644 index 00000000..87d97b29 --- /dev/null +++ b/.github/workflows/code_quality.yml @@ -0,0 +1,41 @@ +name: Code quality +on: [push, pull_request, workflow_dispatch] + +jobs: + black-lint: + runs-on: ubuntu-latest + name: black + steps: + - uses: actions/checkout@v3 + - uses: psf/black@stable + with: + options: "--check --verbose" + src: "./menu_tools" + version: "~= 23.12" + flake8-lint: + runs-on: ubuntu-latest + name: flake8 + steps: + - name: Check out source repository + uses: actions/checkout@v3 + - name: Set up Python environment + uses: actions/setup-python@v4 + with: + python-version: "3.11" + - name: flake8 Lint + uses: py-actions/flake8@v2 + with: + path: "./menu_tools" + mypy-type-check: + runs-on: ubuntu-latest + name: mypy + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + with: + python-version: '3.11' + architecture: 'x64' + - run: | + python -m pip install --upgrade pip poetry + poetry install + poetry run mypy diff --git a/.gitignore b/.gitignore index 1d9df5e1..0c32cf82 100644 --- a/.gitignore +++ b/.gitignore @@ -1,11 +1,16 @@ **/__pycache__/* +*.pyc +pyenv/* **/*.png +**/*.pdf **/.DS_Store **/*.parquet -**/rates.py -objectPerformance/**/*.root -objectPerformance/outputs/**/* +**/*.root rates/table/out/* rates/table/cache/**/* rates/table/lib/* +rates/table/rates_tables/* **/tmp/* +outputs +menu_tools.egg-info +dist diff --git a/README.md b/README.md index c5e9cf8e..3fcbdf68 100644 --- a/README.md +++ b/README.md @@ -13,20 +13,24 @@ Detailed instructions on how to run each step of the workflow are provided in each folder. -## Setup of Python environment - **Note:** The code should run without any setup on `lxplus`. +## Setup A standard venv with Python3.11 can be created on lxplus via `python3.11 -m venv ` and all necessary - dependencies installed via `pip install -r requirements.txt`. + dependencies installed via `pip install .`: - You can then execute the scripts either with `python .py` - or by modifying the [shebang](https://en.wikipedia.org/wiki/Shebang_%28Unix%29). - (the very first line of the executable `.py` files which starts - with `#!`) to point - to your newly set up Python installation. To find the path run + ```bash + python3.11 -m venv pyenv + source /bin/activate + pip install . + ``` - source /bin/activate - which python + **ATTENTION:** Whenever you pull changes you need to `pip install . --upgrade` - and replace the current path in the shebang with the output. + You can then execute the tools via + + ```python + cach_objects + object_performance + rate_plots + ``` diff --git a/cache b/cache new file mode 120000 index 00000000..5a2aa4fe --- /dev/null +++ b/cache @@ -0,0 +1 @@ +/eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/cache \ No newline at end of file diff --git a/objectPerformance/cfg_caching/V29.yaml b/configs/V29/caching.yaml similarity index 99% rename from objectPerformance/cfg_caching/V29.yaml rename to configs/V29/caching.yaml index ab927ad5..0bb97970 100644 --- a/objectPerformance/cfg_caching/V29.yaml +++ b/configs/V29/caching.yaml @@ -68,7 +68,6 @@ V29: phase1PuppiHT: "all" seededConePuppiJet: [Pt, Et, Eta, Phi] seededConeExtendedPuppiJet: [Pt, Et, Eta, Phi, BJetNN] - seededConeExtendedPuppiHT: "all" seededConePuppiHT: "all" seededConePuppiMHT: "all" tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, HGC, PassesEleID, PassesPhoID] diff --git a/objectPerformance/cfg_plots/V29/bJetEff.yaml b/configs/V29/object_performance/bJetEff.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/bJetEff.yaml rename to configs/V29/object_performance/bJetEff.yaml diff --git a/objectPerformance/cfg_plots/V27/electron_iso.yaml b/configs/V29/object_performance/electron_iso.yaml similarity index 66% rename from objectPerformance/cfg_plots/V27/electron_iso.yaml rename to configs/V29/object_performance/electron_iso.yaml index 2e276ef0..771386f3 100644 --- a/objectPerformance/cfg_plots/V27/electron_iso.yaml +++ b/configs/V29/object_performance/electron_iso.yaml @@ -1,10 +1,11 @@ ElectronsIsolation_Barrel: sample: DYLL_M50 - default_version: V27 + version: V29 + match_test_to_ref: True iso_vs_efficiency: True reference_object: object: "part_e" - suffix: "Pt" + x_arg: "Pt" label: "Gen Electrons" cuts: event: @@ -13,13 +14,7 @@ ElectronsIsolation_Barrel: object: - "abs({eta}) < 1.479" test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" + tkElectron:NoIso: "trkiso" xlabel: "Isolation" ylabel: "Efficiency (Barrel)" binning: @@ -29,11 +24,12 @@ ElectronsIsolation_Barrel: ElectronsIsolation_Endcap: sample: DYLL_M50 - default_version: V27 + version: V29 + match_test_to_ref: True iso_vs_efficiency: True reference_object: object: "part_e" - suffix: "Pt" + x_arg: "Pt" label: "Gen Electrons" cuts: event: @@ -42,13 +38,7 @@ ElectronsIsolation_Endcap: object: - "abs({eta}) < 2.4" test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - #- "{passeseleid} == 1" + tkElectron:NoIsoForIso: "trkiso" xlabel: "Isolation" ylabel: "Efficiency (Endcap)" binning: diff --git a/configs/V29/object_performance/electron_matching.yaml b/configs/V29/object_performance/electron_matching.yaml new file mode 100644 index 00000000..68ed26f2 --- /dev/null +++ b/configs/V29/object_performance/electron_matching.yaml @@ -0,0 +1,51 @@ +ElectronsMatchingBarrel: + sample: DYLL_M50 + version: V29 + match_test_to_ref: True + reference_object: + object: "part_e" + x_arg: "Pt" + label: "Gen Electrons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "abs({eta}) < 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + EG:default: "Pt" + tkElectron:NoIso: "Pt" + tkElectron:NoIsoLowPt: "Pt" + tkElectron:Iso: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Matching Efficiency (Barrel)" + binning: + min: 0 + max: 100 + step: 3 + +ElectronsMatchingEndcap: + sample: DYLL_M50 + version: V29 + match_test_to_ref: True + reference_object: + object: "part_e" + x_arg: "Pt" + label: "Gen Electrons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "abs({eta}) > 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + EG:default: "Pt" + tkElectron:NoIso: "Pt" + tkElectron:NoIsoLowPt: "Pt" + tkElectron:Iso: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Matching Efficiency (Endcap)" + binning: + min: 0 + max: 100 + step: 3 diff --git a/configs/V29/object_performance/electron_matching_eta.yaml b/configs/V29/object_performance/electron_matching_eta.yaml new file mode 100644 index 00000000..4e470d51 --- /dev/null +++ b/configs/V29/object_performance/electron_matching_eta.yaml @@ -0,0 +1,52 @@ +ElectronsMatching_Eta_Pt10to25: + sample: DYLL_M50 + version: V29 + match_test_to_ref: True + reference_object: + object: "part_e" + x_arg: "Eta" + label: "Gen Electrons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "{pt} < 25" + - "{pt} > 10" + object: + - "abs({eta}) < 3.0" + test_objects: + EG:default: "Eta" + tkElectron:NoIso: "Eta" + tkElectron:NoIsoLowPt: "Eta" + tkElectron:Iso: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" + binning: + min: -3 + max: 3 + step: 0.2 + +ElectronsMatching_Eta_Pt25toInf: + sample: DYLL_M50 + version: V29 + match_test_to_ref: True + reference_object: + object: "part_e" + x_arg: "Eta" + label: "Gen Electrons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "{pt} > 25" + object: + - "abs({eta}) < 3.0" + test_objects: + EG:default: "Eta" + tkElectron:NoIso: "Eta" + tkElectron:NoIsoLowPt: "Eta" + tkElectron:Iso: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency ($p_T > 25$ GeV)" + binning: + min: -3 + max: 3 + step: 0.2 diff --git a/objectPerformance/cfg_plots/V26/electron_trigger.yaml b/configs/V29/object_performance/electron_trigger.yaml similarity index 52% rename from objectPerformance/cfg_plots/V26/electron_trigger.yaml rename to configs/V29/object_performance/electron_trigger.yaml index 5cd2a8f1..18bc8f3d 100644 --- a/objectPerformance/cfg_plots/V26/electron_trigger.yaml +++ b/configs/V29/object_performance/electron_trigger.yaml @@ -1,9 +1,10 @@ ElectronsTriggerBarrel: - sample: Zee - default_version: V26 + sample: DYLL_M50 + version: V29 + match_test_to_ref: True reference_object: object: "part_e" - suffix: "Pt" + x_arg: "Pt" label: "Gen Electrons" cuts: event: @@ -12,21 +13,10 @@ ElectronsTriggerBarrel: object: - "abs({eta}) < 2.8" test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - # - "{passeseleid} == 1" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" + EG:default:barrel: "Pt" + tkElectron:NoIso:barrel: "Pt" + tkElectron:NoIsoLowPt:barrel: "Pt" + tkElectron:Iso:barrel: "Pt" thresholds: [10, 20, 30, 40] scalings: method: "naive" @@ -35,15 +25,16 @@ ElectronsTriggerBarrel: ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" binning: min: 0 - max: 150 + max: 100 step: 1.5 ElectronsTriggerEndcap: - sample: Zee - default_version: V26 + sample: DYLL_M50 + version: V29 + match_test_to_ref: True reference_object: object: "part_e" - suffix: "Pt" + x_arg: "Pt" label: "Gen Electrons" cuts: event: @@ -52,21 +43,10 @@ ElectronsTriggerEndcap: object: - "abs({eta}) < 2.8" test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - # - "{passessaid} == 1" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" + EG:default:endcap: "Pt" + tkElectron:NoIso:endcap: "Pt" + tkElectron:NoIsoLowPt:endcap: "Pt" + tkElectron:Iso:endcap: "Pt" thresholds: [10, 20, 30, 40] scalings: method: "naive" @@ -75,5 +55,5 @@ ElectronsTriggerEndcap: ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" binning: min: 0 - max: 150 + max: 100 step: 1.5 diff --git a/configs/V29/object_performance/jets_matching.yaml b/configs/V29/object_performance/jets_matching.yaml new file mode 100644 index 00000000..c6cecbaf --- /dev/null +++ b/configs/V29/object_performance/jets_matching.yaml @@ -0,0 +1,92 @@ +JetMatchingForward_3p7to7: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) > 3.7" + object: + - "abs({eta}) < 5" + test_objects: + caloJet:default: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Trigger Efficiency ( GeV, forward)" + binning: + min: 0 + max: 300 + step: 5 + +JetMatchingBarrel: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) < 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + phase1PuppiJet:default: "Pt" + seededConePuppiJet:default: "Pt" + trackerJet:default: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Trigger Efficiency ( GeV, barrel)" + binning: + min: 0 + max: 500 + step: 10 + +JetMatchingEndcap: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) > 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + phase1PuppiJet:default: "Pt" + seededConePuppiJet:default: "Pt" + trackerJet:default: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Trigger Efficiency ( GeV, endcap)" + binning: + min: 0 + max: 500 + step: 10 + +JetMatchingForward: + version: V29 + sample: TT + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) > 2.4" + object: + - "abs({eta}) < 5" + test_objects: + phase1PuppiJet:default: "Pt" + seededConePuppiJet:default: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Trigger Efficiency ( GeV, forward)" + binning: + min: 0 + max: 500 + step: 10 diff --git a/configs/V29/object_performance/jets_matching_eta.yaml b/configs/V29/object_performance/jets_matching_eta.yaml new file mode 100644 index 00000000..cad33a1e --- /dev/null +++ b/configs/V29/object_performance/jets_matching_eta.yaml @@ -0,0 +1,92 @@ +JetMatching_Eta_Pt40To100: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Eta" + label: "Gen Jets" + cuts: + event: + - "{pt} > 40" + - "{pt} < 100" + object: + - "abs({eta}) < 5" + test_objects: + phase1PuppiJet:default: "Eta" + seededConePuppiJet:default: "Eta" + trackerJet:default: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency (40-100 GeV)" + binning: + min: -5 + max: 5 + step: 0.25 + +JetMatching_Eta_Pt100ToInf: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Eta" + label: "Gen Jets" + cuts: + event: + - "{pt} > 100" + object: + - "abs({eta}) < 5" + test_objects: + phase1PuppiJet:default: "Eta" + seededConePuppiJet:default: "Eta" + trackerJet:default: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency (>100 GeV)" + binning: + min: -5 + max: 5 + step: 0.25 + +JetMatching_Eta_Pt100ToInf_extEta: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Eta" + label: "Gen Jets" + cuts: + event: + - "{pt} > 100" + object: + - "abs({eta}) < 7" + test_objects: + caloJet:default: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency (>100 GeV)" + binning: + min: -5.5 + max: 5.5 + step: 0.25 + +JetMatching_Eta_Pt100ToInf_extEta: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Eta" + label: "Gen Jets" + cuts: + event: + - "{pt} > 100" + object: + - "abs({eta}) < 7" + test_objects: + caloJet:default: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency (>100 GeV)" + binning: + min: -7 + max: 7 + step: 0.25 diff --git a/objectPerformance/cfg_plots/V29/jets_matching_wBTag.yaml b/configs/V29/object_performance/jets_matching_wBTag.yaml similarity index 54% rename from objectPerformance/cfg_plots/V29/jets_matching_wBTag.yaml rename to configs/V29/object_performance/jets_matching_wBTag.yaml index 34a1d08f..e8a35ec5 100644 --- a/objectPerformance/cfg_plots/V29/jets_matching_wBTag.yaml +++ b/configs/V29/object_performance/jets_matching_wBTag.yaml @@ -1,9 +1,10 @@ JetMatching_Eta_Pt40To100_ExtendedVsRegular: sample: TT - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "jet" - suffix: "Eta" + x_arg: "Eta" label: "Gen Jets" cuts: event: @@ -12,18 +13,8 @@ JetMatching_Eta_Pt40To100_ExtendedVsRegular: object: - "abs({eta}) < 5" test_objects: - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConeExtendedPuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone Extended PuppiJet" - cuts: - - "abs({eta}) < 5" + seededConePuppiJet:default: "Eta" + seededConeExtendedPuppiJet:default: "Eta" xlabel: "Gen. $\\eta$" ylabel: "Matching Efficiency (40-100 GeV)" binning: @@ -33,10 +24,11 @@ JetMatching_Eta_Pt40To100_ExtendedVsRegular: JetMatching_Eta_Pt100ToInf_ExtendedVsRegular: sample: TT - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "jet" - suffix: "Eta" + x_arg: "Eta" label: "Gen Jets" cuts: event: @@ -44,18 +36,8 @@ JetMatching_Eta_Pt100ToInf_ExtendedVsRegular: object: - "abs({eta}) < 5" test_objects: - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConeExtendedPuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone Extended PuppiJet" - cuts: - - "abs({eta}) < 5" + seededConePuppiJet:default: "Eta" + seededConeExtendedPuppiJet:default: "Eta" xlabel: "Gen. $\\eta$" ylabel: "Matching Efficiency (>100 GeV)" binning: @@ -65,10 +47,11 @@ JetMatching_Eta_Pt100ToInf_ExtendedVsRegular: JetMatching_Eta_Pt30ToInf_genBJets: sample: TT - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "jet" - suffix: "Eta" + x_arg: "Eta" label: "Gen Jets" cuts: event: @@ -77,16 +60,9 @@ JetMatching_Eta_Pt30ToInf_genBJets: object: - "abs({eta}) < 2.4" test_objects: - seededConeExtendedPuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone Extended PuppiJet" - cuts: - - "abs({eta}) < 5" - - "{bjetnn}>0.71" + seededConeExtendedPuppiJet:bjetnn: "Eta" xlabel: "Gen. $\\eta$" ylabel: "Matching Efficiency (>30 GeV)" - # thresholds: [0.0,0.5,0.7,0.71,0.72] binning: min: -2.4 max: 2.4 @@ -94,10 +70,11 @@ JetMatching_Eta_Pt30ToInf_genBJets: JetMatching_Eta_Pt30ToInf_genNotBJets: sample: TT - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "jet" - suffix: "Eta" + x_arg: "Eta" label: "Gen Jets" cuts: event: @@ -106,16 +83,9 @@ JetMatching_Eta_Pt30ToInf_genNotBJets: object: - "abs({eta}) < 2.4" test_objects: - seededConeExtendedPuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone Extended PuppiJet" - cuts: - - "abs({eta}) < 5" - - "{bjetnn}>0.71" + seededConeExtendedPuppiJet:bjetnn: "Eta" xlabel: "Gen. $\\eta$" ylabel: "Matching Efficiency (>30 GeV)" - # thresholds: [0.0,0.5,0.7,0.71,0.72] binning: min: -2.4 max: 2.4 @@ -123,10 +93,11 @@ JetMatching_Eta_Pt30ToInf_genNotBJets: JetMatching_Pt_Pt30ToInf_genBJets: sample: TT - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen Jets" cuts: event: @@ -134,17 +105,9 @@ JetMatching_Pt_Pt30ToInf_genBJets: object: - "abs({eta}) < 2.4" test_objects: - seededConeExtendedPuppiJet: - match_dR: 0.4 - suffix: "Pt" - label: "Seeded Cone Extended PuppiJet" - cuts: - - "abs({eta}) < 5" - - "{bjetnn}>0.71" + seededConeExtendedPuppiJet:bjetnn: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency" - # thresholds: [-999,0,0.5,0.68,0.71,0.74,0.9] - # thresholds: [0.0,0.5,0.7,0.71,0.72] binning: min: 30 max: 200 @@ -152,10 +115,11 @@ JetMatching_Pt_Pt30ToInf_genBJets: JetMatching_Pt_Pt30ToInf_genNotBJets: sample: TT - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen Jets" cuts: event: @@ -163,16 +127,9 @@ JetMatching_Pt_Pt30ToInf_genNotBJets: object: - "abs({eta}) < 2.4" test_objects: - seededConeExtendedPuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone Extended PuppiJet" - cuts: - - "abs({eta}) < 5" - - "{bjetnn}>0.71" + seededConeExtendedPuppiJet:bjetnn: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency" - # thresholds: [0.0,0.5,0.7,0.71,0.72] binning: min: 30 max: 200 diff --git a/configs/V29/object_performance/jets_trigger.yaml b/configs/V29/object_performance/jets_trigger.yaml new file mode 100644 index 00000000..feb5d7c6 --- /dev/null +++ b/configs/V29/object_performance/jets_trigger.yaml @@ -0,0 +1,82 @@ +JetTurnonBarrel: + version: V29 + sample: TT + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) < 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + phase1PuppiJet:default:barrel: "Pt" + seededConePuppiJet:default:barrel: "Pt" + trackerJet:default:barrel: "Pt" + thresholds: [50, 100] + scalings: + method: "naive" + threshold: 0.95 + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Trigger Efficiency ( GeV, barrel)" + binning: + min: 0 + max: 500 + step: 10 + +JetTurnonEndcap: + version: V29 + sample: TT + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) > 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + phase1PuppiJet:default:endcap: "Pt" + seededConePuppiJet:default:endcap: "Pt" + trackerJet:default:endcap: "Pt" + thresholds: [50] + scalings: + method: "naive" + threshold: 0.95 + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Trigger Efficiency ( GeV, endcap)" + binning: + min: 0 + max: 500 + step: 10 + +JetTurnonForward: + version: V29 + sample: TT + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) > 2.4" + object: + - "abs({eta}) < 5" + test_objects: + phase1PuppiJet:default:forward: "Pt" + seededConePuppiJet:default:forward: "Pt" + thresholds: [50, 100] + scalings: + method: "naive" + threshold: 0.95 + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Trigger Efficiency ( GeV, forward)" + binning: + min: 0 + max: 500 + step: 10 diff --git a/configs/V29/object_performance/jets_trigger_fwd.yaml b/configs/V29/object_performance/jets_trigger_fwd.yaml new file mode 100644 index 00000000..5533a9ba --- /dev/null +++ b/configs/V29/object_performance/jets_trigger_fwd.yaml @@ -0,0 +1,26 @@ +JetTurnonFwd_3p7to7: + sample: TT + version: V29 + match_test_to_ref: True + reference_object: + object: "jet" + x_arg: "Pt" + label: "Gen Jets" + cuts: + event: + - "abs({eta}) > 3.7" + object: + - "abs({eta}) < 7" + test_objects: + phase1PuppiJet:default:forward: "Pt" + seededConePuppiJet:default:forward: "Pt" + thresholds: [50,100] + scalings: + method: "naive" + threshold: 0.95 + xlabel: "Gen. $p_T$ (GeV)" + ylabel: r'Trigger Efficiency ( GeV, $3.6<\eta<6$)' + binning: + min: 0 + max: 300 + step: 10 diff --git a/objectPerformance/cfg_plots/V22/met_ht_mht.yaml b/configs/V29/object_performance/met_ht_mht.yaml similarity index 68% rename from objectPerformance/cfg_plots/V22/met_ht_mht.yaml rename to configs/V29/object_performance/met_ht_mht.yaml index 0b44e045..709bebb4 100644 --- a/objectPerformance/cfg_plots/V22/met_ht_mht.yaml +++ b/configs/V29/object_performance/met_ht_mht.yaml @@ -1,9 +1,9 @@ HT_90perc: sample: TT - default_version: V22 + version: V29 reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen HT" trafo: "HT" cuts: @@ -11,12 +11,9 @@ HT_90perc: - "abs({eta}) < 2.4" - "{pt} > 30" test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" + trackerHT:default: "" + phase1PuppiHT:default: "" + seededConePuppiHT:default: "" thresholds: [350] scalings: method: "naive" @@ -30,10 +27,10 @@ HT_90perc: HT_50perc: sample: TT - default_version: V22 + version: V29 reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen HT" trafo: "HT" cuts: @@ -41,12 +38,9 @@ HT_50perc: - "abs({eta}) < 2.4" - "{pt} > 30" test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" + trackerHT:default: "" + phase1PuppiHT:default: "" + seededConePuppiHT:default: "" thresholds: [350] scalings: method: "naive" @@ -58,12 +52,12 @@ HT_50perc: max: 750 step: 20 -MHT_50perc: +MHT_90perc: sample: TT - default_version: V22 + version: V29 reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen MHT" cuts: object: @@ -71,16 +65,13 @@ MHT_50perc: - "{pt} > 30" trafo: "MHT" test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" + trackerMHT:default: "" + phase1PuppiMHT:default: "et" + seededConePuppiMHT:default: "et" thresholds: [70, 150] scalings: method: "naive" - threshold: 0.50 + threshold: 0.90 xlabel: "Gen. MHT30 (GeV)" ylabel: "Trigger Efficiency ( GeV)" binning: @@ -88,12 +79,12 @@ MHT_50perc: max: 500 step: 20 -MHT_90perc: +MHT_50perc: sample: TT - default_version: V22 + version: V29 reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen MHT" cuts: object: @@ -101,16 +92,13 @@ MHT_90perc: - "{pt} > 30" trafo: "MHT" test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" + trackerMHT:default: "" + phase1PuppiMHT:default: "et" + seededConePuppiMHT:default: "et" thresholds: [70, 150] scalings: method: "naive" - threshold: 0.90 + threshold: 0.50 xlabel: "Gen. MHT30 (GeV)" ylabel: "Trigger Efficiency ( GeV)" binning: @@ -120,18 +108,14 @@ MHT_90perc: MET_90perc: sample: TT - default_version: V22 + version: V29 reference_object: object: "genMetTrue" - suffix: "" + x_arg: "" label: "Gen MET" test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" + trackerMET:default: "" + puppiMET:default: "et" thresholds: [150] xlabel: "Gen. MET (GeV)" ylabel: "Trigger Efficiency ( GeV)" @@ -145,18 +129,14 @@ MET_90perc: MET_50perc: sample: TT - default_version: V22 + version: V29 reference_object: object: "genMetTrue" - suffix: "" + x_arg: "" label: "Gen MET" test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" + trackerMET:default: "" + puppiMET:default: "et" thresholds: [150] xlabel: "Gen. MET (GeV)" ylabel: "Trigger Efficiency ( GeV)" diff --git a/objectPerformance/cfg_plots/V29/mht.yaml b/configs/V29/object_performance/mht.yaml similarity index 64% rename from objectPerformance/cfg_plots/V29/mht.yaml rename to configs/V29/object_performance/mht.yaml index 65ff7df2..a85d166b 100644 --- a/objectPerformance/cfg_plots/V29/mht.yaml +++ b/configs/V29/object_performance/mht.yaml @@ -1,9 +1,9 @@ MHT30_90perc: sample: TT - default_version: V29 + version: V29 reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen MHT" cuts: object: @@ -11,12 +11,8 @@ MHT30_90perc: - "{pt} > 30" trafo: "MHT" test_objects: - phase1PuppiMHT: - suffix: "et" - label: "Phase1 Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" + phase1PuppiMHT:default: "et" + seededConePuppiMHT:default: "et" thresholds: [70, 150] scalings: method: "naive" @@ -30,10 +26,10 @@ MHT30_90perc: MHT30_50perc: sample: TT - default_version: V29 + version: V29 reference_object: object: "jet" - suffix: "Pt" + x_arg: "Pt" label: "Gen MHT" cuts: object: @@ -41,15 +37,9 @@ MHT30_50perc: - "{pt} > 30" trafo: "MHT" test_objects: - phase1PuppiMHT: - suffix: "et" - label: "Phase1 Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" - trackerMHT: - suffix: "" - label: "Tracker MHT" + phase1PuppiMHT:default: "et" + seededConePuppiMHT:default: "et" + trackerMHT:default: "" thresholds: [70, 150] scalings: method: "naive" diff --git a/objectPerformance/cfg_plots/V29/muon_matching.yaml b/configs/V29/object_performance/muon_matching.yaml similarity index 50% rename from objectPerformance/cfg_plots/V29/muon_matching.yaml rename to configs/V29/object_performance/muon_matching.yaml index 3a70ec76..67e974bb 100644 --- a/objectPerformance/cfg_plots/V29/muon_matching.yaml +++ b/configs/V29/object_performance/muon_matching.yaml @@ -1,9 +1,10 @@ MuonsMatchingBarrel: sample: DYLL_M50 - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "part_mu" - suffix: "Pt" + x_arg: "Pt" label: "Gen Muons" cuts: event: @@ -11,19 +12,8 @@ MuonsMatchingBarrel: object: - "abs({eta}) < 0.83" test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) < 0.83" - - "({quality}) > 0" + gmtMuon:default:barrel: "Pt" + gmtTkMuon:default:barrel: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency (barrel)" binning: @@ -33,10 +23,11 @@ MuonsMatchingBarrel: MuonsMatchingOverlap: sample: DYLL_M50 - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "part_mu" - suffix: "Pt" + x_arg: "Pt" label: "Gen Muons" cuts: event: @@ -45,21 +36,8 @@ MuonsMatchingOverlap: - "abs({eta}) > 0.83" - "abs({eta}) < 1.24" test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "({quality}) > 0" - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" + gmtMuon:default:overlap: "Pt" + gmtTkMuon:default:overlap: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency (overlap)" binning: @@ -69,10 +47,11 @@ MuonsMatchingOverlap: MuonsMatchingEndcap: sample: DYLL_M50 - default_version: V29 + version: V29 + match_test_to_ref: True reference_object: object: "part_mu" - suffix: "Pt" + x_arg: "Pt" label: "Gen Muons" cuts: event: @@ -81,21 +60,8 @@ MuonsMatchingEndcap: - "abs({eta}) > 1.24" - "abs({eta}) < 2.4" test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - - "({quality}) > 0" + gmtMuon:default:endcap: "Pt" + gmtTkMuon:default:endcap: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency (endcap)" binning: diff --git a/objectPerformance/cfg_plots/V26/muon_matching_eta.yaml b/configs/V29/object_performance/muon_matching_eta.yaml similarity index 72% rename from objectPerformance/cfg_plots/V26/muon_matching_eta.yaml rename to configs/V29/object_performance/muon_matching_eta.yaml index cb34ec16..8940c722 100644 --- a/objectPerformance/cfg_plots/V26/muon_matching_eta.yaml +++ b/configs/V29/object_performance/muon_matching_eta.yaml @@ -1,9 +1,10 @@ MuonsMatching_Eta_Pt2to5: - sample: Zmm - default_version: V26 + sample: DYLL_M50 + version: V29 + match_test_to_ref: True reference_object: object: "part_mu" - suffix: "Eta" + x_arg: "Eta" label: "Gen Muons" cuts: event: @@ -13,10 +14,8 @@ MuonsMatching_Eta_Pt2to5: object: - "abs({eta}) < 2.4" test_objects: - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 + gmtMuon:default: "Eta" + gmtTkMuon:default: "Eta" xlabel: "Gen. $\\eta$" ylabel: "Matching Efficiency (2-5 GeV)" binning: @@ -25,11 +24,12 @@ MuonsMatching_Eta_Pt2to5: step: 0.2 MuonsMatching_Eta_Pt15toInf: - sample: Zmm - default_version: V26 + sample: DYLL_M50 + version: V29 + match_test_to_ref: True reference_object: object: "part_mu" - suffix: "Eta" + x_arg: "Eta" label: "Gen Muons" cuts: event: @@ -38,10 +38,8 @@ MuonsMatching_Eta_Pt15toInf: object: - "abs({eta}) < 2.4" test_objects: - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 + gmtMuon:default: "Eta" + gmtTkMuon:default: "Eta" xlabel: "Gen. $\\eta$" ylabel: "Matching Efficiency (>15 GeV)" binning: diff --git a/configs/V29/object_performance/muon_trigger.yaml b/configs/V29/object_performance/muon_trigger.yaml new file mode 100644 index 00000000..e111b854 --- /dev/null +++ b/configs/V29/object_performance/muon_trigger.yaml @@ -0,0 +1,81 @@ +MuonsTrigger_Barrel: + sample: DYLL_M50 + version: V29 + match_test_to_ref: True + reference_object: + object: "part_mu" + x_arg: "Pt" + label: "Gen Muons" + cuts: + event: + - "{dr_0.3} < 0.15" + object: + - "abs({eta}) < 0.83" + test_objects: + gmtMuon:default:barrel: "Pt" + gmtTkMuon:default:barrel: "Pt" + xlabel: "Gen. pT (GeV)" + ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" + thresholds: [20, 25] + scalings: + method: "naive" + threshold: 0.95 + binning: + min: 0 + max: 50 + step: 1.5 + +MuonsTrigger_Overlap: + sample: DYLL_M50 + version: V29 + match_test_to_ref: True + reference_object: + object: "part_mu" + x_arg: "Pt" + label: "Gen Muons" + cuts: + event: + - "{dr_0.3} < 0.15" + object: + - "abs({eta}) > 0.83" + - "abs({eta}) < 1.24" + test_objects: + gmtMuon:default:overlap: "Pt" + gmtTkMuon:default:overlap: "Pt" + xlabel: "Gen. pT (GeV)" + ylabel: "Trigger Efficiency (overlap, L1 $p_T > 20$ GeV)" + thresholds: [20, 25] + scalings: + method: "naive" + threshold: 0.95 + binning: + min: 0 + max: 50 + step: 1.5 + +MuonsTrigger_Endcap: + sample: DYLL_M50 + version: V29 + match_test_to_ref: True + reference_object: + object: "part_mu" + x_arg: "Pt" + label: "Gen Muons" + cuts: + event: + - "{dr_0.3} < 0.15" + object: + - "abs({eta}) > 1.24" + test_objects: + gmtMuon:default:endcap: "Pt" + gmtTkMuon:default:endcap: "Pt" + xlabel: "Gen. pT (GeV)" + ylabel: "Trigger Efficiency (endcap, L1 $p_T > 20$ GeV)" + thresholds: [20, 25] + scalings: + method: "naive" + threshold: 0.95 + binning: + min: 0 + max: 50 + step: 1.5 diff --git a/objectPerformance/cfg_plots/V29/photon_iso.yaml b/configs/V29/object_performance/photon_iso.yaml similarity index 65% rename from objectPerformance/cfg_plots/V29/photon_iso.yaml rename to configs/V29/object_performance/photon_iso.yaml index 9d9aa4e6..e4e9e1bd 100644 --- a/objectPerformance/cfg_plots/V29/photon_iso.yaml +++ b/configs/V29/object_performance/photon_iso.yaml @@ -1,10 +1,11 @@ PhotonIsolation_Barrel: sample: Hgg - default_version: V29 + version: V29 iso_vs_efficiency: True + match_test_to_ref: True reference_object: object: "part_gamma" - suffix: "Pt" + x_arg: "Pt" label: "Gen Photons" cuts: event: @@ -13,13 +14,7 @@ PhotonIsolation_Barrel: object: - "abs({eta}) < 1.479" test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) < 1.479" - - "{passeseleid} == 1" + tkPhoton:NoIso:barrel: "trkiso" xlabel: "Isolation" ylabel: "Efficiency (Barrel)" binning: @@ -29,11 +24,12 @@ PhotonIsolation_Barrel: PhotonIsolation_Endcap: sample: Hgg - default_version: V29 + version: V29 iso_vs_efficiency: True + match_test_to_ref: True reference_object: object: "part_gamma" - suffix: "Pt" + x_arg: "Pt" label: "Gen Photons" cuts: event: @@ -43,14 +39,7 @@ PhotonIsolation_Endcap: object: - "abs({eta}) > 1.479" test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) > 1.479" - - "abs({eta}) < 2.4" - - "{passesphoid} == 1" + tkPhoton:NoIso:endcap: "trkiso" xlabel: "Isolation" ylabel: "Efficiency (Endcap)" binning: diff --git a/configs/V29/object_performance/photons_matching.yaml b/configs/V29/object_performance/photons_matching.yaml new file mode 100644 index 00000000..2d203b6a --- /dev/null +++ b/configs/V29/object_performance/photons_matching.yaml @@ -0,0 +1,49 @@ +PhotonsMatching_Barrel: + sample: Hgg + version: V29 + match_test_to_ref: True + reference_object: + object: "part_gamma" + x_arg: "Pt" + label: "Gen Photons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "abs({eta}) < 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + EG:default: "Pt" + tkPhoton:NoIso: "Pt" + tkPhoton:Iso: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Matching Efficiency (Barrel)" + binning: + min: 0 + max: 100 + step: 3 + +PhotonsMatching_Endcap: + sample: Hgg + version: V29 + match_test_to_ref: True + reference_object: + object: "part_gamma" + x_arg: "Pt" + label: "Gen Photons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "abs({eta}) > 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + EG:default: "Pt" + tkPhoton:NoIso: "Pt" + tkPhoton:Iso: "Pt" + xlabel: "Gen. $p_T$ (GeV)" + ylabel: "Matching Efficiency (Endcap)" + binning: + min: 0 + max: 100 + step: 3 diff --git a/configs/V29/object_performance/photons_matching_eta.yaml b/configs/V29/object_performance/photons_matching_eta.yaml new file mode 100644 index 00000000..cda31e40 --- /dev/null +++ b/configs/V29/object_performance/photons_matching_eta.yaml @@ -0,0 +1,50 @@ +PhotonsMatching_Eta_Pt10to25: + sample: Hgg + version: V29 + match_test_to_ref: True + reference_object: + object: "part_gamma" + x_arg: "Eta" + label: "Gen Photons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "{pt} < 25" + - "{pt} > 10" + object: + - "abs({eta}) < 3.0" + test_objects: + EG:default: "Eta" + tkPhoton:NoIso: "Eta" + tkPhoton:Iso: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" + binning: + min: -3 + max: 3 + step: 0.2 + +PhotonsMatching_Eta_Pt25toInf: + sample: Hgg + version: V29 + match_test_to_ref: True + reference_object: + object: "part_gamma" + x_arg: "Eta" + label: "Gen Photons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "{pt} >= 25" + object: + - "abs({eta}) < 3.0" + test_objects: + EG:default: "Eta" + tkPhoton:NoIso: "Eta" + tkPhoton:Iso: "Eta" + xlabel: "Gen. $\\eta$" + ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" + binning: + min: -3 + max: 3 + step: 0.2 diff --git a/configs/V29/object_performance/photons_trigger.yaml b/configs/V29/object_performance/photons_trigger.yaml new file mode 100644 index 00000000..26d94e67 --- /dev/null +++ b/configs/V29/object_performance/photons_trigger.yaml @@ -0,0 +1,57 @@ +PhotonsTrigger_Barrel: + sample: Hgg + version: V29 + match_test_to_ref: True + reference_object: + object: "part_gamma" + x_arg: "Pt" + label: "Gen Photons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "abs({eta}) < 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + EG:default:barrel: "Pt" + tkPhoton:NoIso:barrel: "Pt" + tkPhoton:Iso:barrel: "Pt" + thresholds: [10, 20, 30, 40] + scalings: + method: "naive" + threshold: 0.95 + xlabel: "Gen. pT (GeV)" + ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" + binning: + min: 0 + max: 100 + step: 1.5 + +PhotonsTrigger_Endcap: + sample: Hgg + version: V29 + match_test_to_ref: True + reference_object: + object: "part_gamma" + x_arg: "Pt" + label: "Gen Photons" + cuts: + event: + - "{dr_0.3} < 0.15" + - "abs({eta}) > 1.5" + object: + - "abs({eta}) < 2.4" + test_objects: + EG:default:endcap: "Pt" + tkPhoton:NoIso:endcap: "Pt" + tkPhoton:Iso:endcap: "Pt" + thresholds: [10, 20, 30, 40] + scalings: + method: "naive" + threshold: 0.95 + xlabel: "Gen. pT (GeV)" + ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" + binning: + min: 0 + max: 100 + step: 1.5 diff --git a/objectPerformance/cfg_plots/V29/slim/.backups/.cele.yaml~ b/configs/V29/object_performance/slim/.backups/.cele.yaml~ similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/.backups/.cele.yaml~ rename to configs/V29/object_performance/slim/.backups/.cele.yaml~ diff --git a/objectPerformance/cfg_plots/V29/slim/cele.yaml b/configs/V29/object_performance/slim/cele.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/cele.yaml rename to configs/V29/object_performance/slim/cele.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/cjet.yaml b/configs/V29/object_performance/slim/cjet.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/cjet.yaml rename to configs/V29/object_performance/slim/cjet.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/compare_gammas.yaml b/configs/V29/object_performance/slim/compare_gammas.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/compare_gammas.yaml rename to configs/V29/object_performance/slim/compare_gammas.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/compare_jets.yaml b/configs/V29/object_performance/slim/compare_jets.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/compare_jets.yaml rename to configs/V29/object_performance/slim/compare_jets.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/compare_mus.yaml b/configs/V29/object_performance/slim/compare_mus.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/compare_mus.yaml rename to configs/V29/object_performance/slim/compare_mus.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/comparisons.yaml b/configs/V29/object_performance/slim/comparisons.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/comparisons.yaml rename to configs/V29/object_performance/slim/comparisons.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/egamma_trigger_inclusive.yaml b/configs/V29/object_performance/slim/egamma_trigger_inclusive.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/egamma_trigger_inclusive.yaml rename to configs/V29/object_performance/slim/egamma_trigger_inclusive.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/egamma_trigger_tkiso_inclusive.yaml b/configs/V29/object_performance/slim/egamma_trigger_tkiso_inclusive.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/egamma_trigger_tkiso_inclusive.yaml rename to configs/V29/object_performance/slim/egamma_trigger_tkiso_inclusive.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/ele_test.yaml b/configs/V29/object_performance/slim/ele_test.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/ele_test.yaml rename to configs/V29/object_performance/slim/ele_test.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/electron_matching.yaml b/configs/V29/object_performance/slim/electron_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/electron_matching.yaml rename to configs/V29/object_performance/slim/electron_matching.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/electrons_comparisons.yaml b/configs/V29/object_performance/slim/electrons_comparisons.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/electrons_comparisons.yaml rename to configs/V29/object_performance/slim/electrons_comparisons.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/jets_matching.yaml b/configs/V29/object_performance/slim/jets_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/jets_matching.yaml rename to configs/V29/object_performance/slim/jets_matching.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/jets_matching_eta.yaml b/configs/V29/object_performance/slim/jets_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/jets_matching_eta.yaml rename to configs/V29/object_performance/slim/jets_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/jets_trigger_inclusive.yaml b/configs/V29/object_performance/slim/jets_trigger_inclusive.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/jets_trigger_inclusive.yaml rename to configs/V29/object_performance/slim/jets_trigger_inclusive.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/jets_trigger_sc_inclusive.yaml b/configs/V29/object_performance/slim/jets_trigger_sc_inclusive.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/jets_trigger_sc_inclusive.yaml rename to configs/V29/object_performance/slim/jets_trigger_sc_inclusive.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/met.yaml b/configs/V29/object_performance/slim/met.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/met.yaml rename to configs/V29/object_performance/slim/met.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/muon_matching.yaml b/configs/V29/object_performance/slim/muon_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/muon_matching.yaml rename to configs/V29/object_performance/slim/muon_matching.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/muon_trigger_gmtTK_inclusive.yaml b/configs/V29/object_performance/slim/muon_trigger_gmtTK_inclusive.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/muon_trigger_gmtTK_inclusive.yaml rename to configs/V29/object_performance/slim/muon_trigger_gmtTK_inclusive.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/muon_trigger_inclusive.yaml b/configs/V29/object_performance/slim/muon_trigger_inclusive.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/muon_trigger_inclusive.yaml rename to configs/V29/object_performance/slim/muon_trigger_inclusive.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/pho_test.yaml b/configs/V29/object_performance/slim/pho_test.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/pho_test.yaml rename to configs/V29/object_performance/slim/pho_test.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/photons_matching.yaml b/configs/V29/object_performance/slim/photons_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/photons_matching.yaml rename to configs/V29/object_performance/slim/photons_matching.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/tau_matching.yaml b/configs/V29/object_performance/slim/tau_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/tau_matching.yaml rename to configs/V29/object_performance/slim/tau_matching.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/tau_matching_eta.yaml b/configs/V29/object_performance/slim/tau_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/tau_matching_eta.yaml rename to configs/V29/object_performance/slim/tau_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V29/slim/tau_trigger_inclusive.yaml b/configs/V29/object_performance/slim/tau_trigger_inclusive.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/slim/tau_trigger_inclusive.yaml rename to configs/V29/object_performance/slim/tau_trigger_inclusive.yaml diff --git a/objectPerformance/cfg_plots/V27/tau_matching.yaml b/configs/V29/object_performance/tau_matching.yaml similarity index 54% rename from objectPerformance/cfg_plots/V27/tau_matching.yaml rename to configs/V29/object_performance/tau_matching.yaml index cad1e11a..f0468abd 100644 --- a/objectPerformance/cfg_plots/V27/tau_matching.yaml +++ b/configs/V29/object_performance/tau_matching.yaml @@ -1,9 +1,10 @@ TausMatchingBarrel: sample: VBFHToTauTau - default_version: V27 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -12,19 +13,8 @@ TausMatchingBarrel: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default: "Pt" + caloTau:default: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency (Barrel)" binning: @@ -34,10 +24,11 @@ TausMatchingBarrel: TausMatchingEndcap: sample: VBFHToTauTau - default_version: V27 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -46,19 +37,8 @@ TausMatchingEndcap: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default: "Pt" + caloTau:default: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency (Endcap)" binning: diff --git a/objectPerformance/cfg_plots/V28/tau_matching_wHH.yaml b/configs/V29/object_performance/tau_matching_wHH.yaml similarity index 54% rename from objectPerformance/cfg_plots/V28/tau_matching_wHH.yaml rename to configs/V29/object_performance/tau_matching_wHH.yaml index 93508232..5f9f7aa4 100644 --- a/objectPerformance/cfg_plots/V28/tau_matching_wHH.yaml +++ b/configs/V29/object_performance/tau_matching_wHH.yaml @@ -1,9 +1,10 @@ HHTausMatchingBarrel: sample: HHToTauTau - default_version: V28 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -12,19 +13,8 @@ HHTausMatchingBarrel: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default: "Pt" + caloTau:default: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency (Barrel)" binning: @@ -34,10 +24,11 @@ HHTausMatchingBarrel: HHTausMatchingEndcap: sample: HHToTauTau - default_version: V28 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -46,19 +37,8 @@ HHTausMatchingEndcap: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default: "Pt" + caloTau:default: "Pt" xlabel: "Gen. $p_T$ (GeV)" ylabel: "Matching Efficiency (Endcap)" binning: diff --git a/objectPerformance/cfg_plots/V27/tau_trigger.yaml b/configs/V29/object_performance/tau_trigger.yaml similarity index 61% rename from objectPerformance/cfg_plots/V27/tau_trigger.yaml rename to configs/V29/object_performance/tau_trigger.yaml index 16634a8f..2bd6456d 100644 --- a/objectPerformance/cfg_plots/V27/tau_trigger.yaml +++ b/configs/V29/object_performance/tau_trigger.yaml @@ -1,9 +1,10 @@ TauTriggerBarrel_90perc: sample: VBFHToTauTau - default_version: V27 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -12,19 +13,8 @@ TauTriggerBarrel_90perc: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default:barrel: "Pt" + caloTau:default:barrel: "Pt" xlabel: "Gen. pT (GeV)" ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" thresholds: [20, 30] @@ -38,10 +28,11 @@ TauTriggerBarrel_90perc: TauTriggerEndcap_90perc: sample: VBFHToTauTau - default_version: V27 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -50,19 +41,8 @@ TauTriggerEndcap_90perc: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default:endcap: "Pt" + caloTau:default:endcap: "Pt" xlabel: "Gen. pT (GeV)" ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" thresholds: [20, 30] @@ -74,12 +54,17 @@ TauTriggerEndcap_90perc: max: 150 step: 6 +# ATTENTION: The scalings from this config are in conflict with the 90prec +# configurations above and will be written to a file with the plot name as +# prefix. To use these scalings in the rate plots/table, overwrite the standard +# scalings yaml files in outputs! TauTriggerBarrel_50perc: sample: VBFHToTauTau - default_version: V27 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -88,19 +73,8 @@ TauTriggerBarrel_50perc: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default:barrel: "Pt" + caloTau:default:barrel: "Pt" xlabel: "Gen. pT (GeV)" ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" thresholds: [20, 30] @@ -112,12 +86,17 @@ TauTriggerBarrel_50perc: max: 150 step: 6 +# ATTENTION: The scalings from this config are in conflict with the 90prec +# configurations above and will be written to a file with the plot name as +# prefix. To use these scalings in the rate plots/table, overwrite the standard +# scalings yaml files in outputs! TauTriggerEndcap_50perc: sample: VBFHToTauTau - default_version: V27 + version: V29 + match_test_to_ref: True reference_object: object: "part_tau" - suffix: "Pt" + x_arg: "Pt" label: "Gen Taus" cuts: event: @@ -126,19 +105,8 @@ TauTriggerEndcap_50perc: object: - "abs({eta}) < 2.4" test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 + nnTau:default:endcap: "Pt" + caloTau:default:endcap: "Pt" xlabel: "Gen. pT (GeV)" ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" thresholds: [20, 30] diff --git a/objectPerformance/cfg_plots/V29/version_comparison.yaml b/configs/V29/object_performance/version_comparison.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29/version_comparison.yaml rename to configs/V29/object_performance/version_comparison.yaml diff --git a/configs/V29/objects/electrons.yaml b/configs/V29/objects/electrons.yaml new file mode 100644 index 00000000..efb65634 --- /dev/null +++ b/configs/V29/objects/electrons.yaml @@ -0,0 +1,65 @@ +part_e: + label: "Gen Electron" + eta_ranges: + inclusive: [0, 7] + ids: + gen_electron_default: + cuts: + inclusive: + - "{dr_0.3} < 0.15" + +tkElectron: + match_dR: 0.15 + eta_ranges: + inclusive: [0, 7] + barrel: [0, 1.479] + endcap: [1.479, 5] + ids: + NoIso: + label: "TkElectron" + cuts: + inclusive: + - "abs({eta}) < 2.4" + - "({passeseleid} == 1)" + NoIsoForIso: + # This id is exclusively used for the + # isoloation wp derivation + label: "TkElectron id in barrel" + cuts: + inclusive: + - "abs({eta}) < 2.7" + barrel: + - "({passeseleid} == 1)" + Iso: + label: "TkIsoElectron" + cuts: + inclusive: + - "abs({eta}) < 2.4" + barrel: + - "abs({trkiso}) < 0.13" + - "({passeseleid} == 1)" + endcap: + - "abs({trkiso}) < 0.28" + NoIsoLowPt: + label: "TkElectron, no ID for $p_T<25$" + cuts: + inclusive: + - "abs({eta}) < 2.4" + - "({passeseleid} == 1) | ({pt} < 25)" + +EG: + match_dR: 0.2 + eta_ranges: + inclusive: [0, 7] + barrel: [0, 1.479] + endcap: [1.479, 3.0] + label: "EG" + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 3.0" + barrel: + - "{passeseleid} == 1" + endcap: + - "{passessaid} == 1" diff --git a/configs/V29/objects/jets.yaml b/configs/V29/objects/jets.yaml new file mode 100644 index 00000000..b2128853 --- /dev/null +++ b/configs/V29/objects/jets.yaml @@ -0,0 +1,70 @@ +caloJet: + match_dR: 0.3 + label: "Calo Jet" + eta_ranges: + inclusive: [0, 7] + cuts: + inclusive: + - "abs({eta}) < 7" + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 7" + +seededConeExtendedPuppiJet: + match_dR: 0.35 + label: "Seeded Cone Extended PuppiJet" + eta_ranges: + inclusive: [0, 7] + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 5" + bjetnn: + cuts: + inclusive: + - "abs({eta}) < 2.4" + - "{bjetnn} > 0.71" + +phase1PuppiJet: + match_dR: 0.3 + label: "Histogrammed PuppiJet" + eta_ranges: + inclusive: [0, 7] + barrel: [0, 1.5] + endcap: [1.5, 2.4] + forward: [2.4, 5] + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 7" + +seededConePuppiJet: + match_dR: 0.35 + label: "Seeded Cone PuppiJet" + eta_ranges: + inclusive: [0, 7] + barrel: [0, 1.5] + endcap: [1.5, 2.4] + forward: [2.4, 5] + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 7" + +trackerJet: + match_dR: 0.4 + label: "Tracker Jet" + eta_ranges: + inclusive: [0, 7] + barrel: [0, 1.5] + endcap: [1.5, 2.4] + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 7" diff --git a/configs/V29/objects/met_ht_mht.yaml b/configs/V29/objects/met_ht_mht.yaml new file mode 100644 index 00000000..8e0a6e45 --- /dev/null +++ b/configs/V29/objects/met_ht_mht.yaml @@ -0,0 +1,39 @@ +phase1PuppiHT: + label: "Histogrammed Puppi HT" + ids: + default: {} + +phase1PuppiMHT: + label: "Phase1 Puppi MHT" + ids: + default: {} + +puppiMET: + label: "Puppi MET" + ids: + default: {} + +seededConePuppiHT: + label: "SeededCone HT" + ids: + default: {} + +seededConePuppiMHT: + label: "SeededCone MHT" + ids: + default: {} + +trackerHT: + label: "Tracker HT" + ids: + default: {} + +trackerMET: + label: "Tracker MET" + ids: + default: {} + +trackerMHT: + label: "Tracker MHT" + ids: + default: {} diff --git a/configs/V29/objects/muons.yaml b/configs/V29/objects/muons.yaml new file mode 100644 index 00000000..77a8fe31 --- /dev/null +++ b/configs/V29/objects/muons.yaml @@ -0,0 +1,27 @@ +gmtMuon: + label: "GMT Muon" + match_dR: 0.3 + eta_ranges: + inclusive: [0, 7] + barrel: [0, 0.83] + overlap: [0.83, 1.24] + endcap: [1.24, 2.4] + ids: + default: + cuts: + overlap: + - "{quality} >= 12" + +gmtTkMuon: + label: "GMT TkMuon" + match_dR: 0.1 + eta_ranges: + inclusive: [0, 7] + barrel: [0, 0.83] + overlap: [0.83, 1.24] + endcap: [1.24, 2.4] + ids: + default: + cuts: + inclusive: + - "({quality} > 0) | ({pt} > 8)" # quality criterion only to be appied for p_T < 8 GeV diff --git a/configs/V29/objects/photons.yaml b/configs/V29/objects/photons.yaml new file mode 100644 index 00000000..c2075e19 --- /dev/null +++ b/configs/V29/objects/photons.yaml @@ -0,0 +1,27 @@ +tkPhoton: + match_dR: 0.15 + eta_ranges: + inclusive: [0, 5] + barrel: [0, 1.479] + endcap: [1.479, 2.4] + ids: + NoIso: + label: "tkPhoton" + cuts: + inclusive: + - "abs({eta}) < 2.4" + barrel: + - "{passeseleid} == 1" + endcap: + - "{passesphoid} == 1" + Iso: + label: "tkIsoPhoton" + cuts: + inclusive: + - "abs({eta}) < 2.4" + barrel: + - "abs({trkiso}) < 0.2" + - "{passeseleid} == 1" + endcap: + - "abs({trkiso}) < 0.2" + - "{passesphoid} == 1" diff --git a/configs/V29/objects/taus.yaml b/configs/V29/objects/taus.yaml new file mode 100644 index 00000000..2f1bf535 --- /dev/null +++ b/configs/V29/objects/taus.yaml @@ -0,0 +1,29 @@ +nnTau: + label: "NN Tau" + match_dR: 0.1 + eta_ranges: + inclusive: [0, 7] + barrel: [0, 1.5] + endcap: [1.5, 2.4] + cuts: + inclusive: + - "{passloosenn}==1" + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 2.4" + - "{passloosenn}==1" + +caloTau: + label: "Calo Tau" + match_dR: 0.3 + eta_ranges: + inclusive: [0, 7] + barrel: [0, 1.5] + endcap: [1.5, 2.4] + ids: + default: + cuts: + inclusive: + - "abs({eta}) < 2.4" diff --git a/configs/V29/rate_plots/eg.yaml b/configs/V29/rate_plots/eg.yaml new file mode 100644 index 00000000..4c1a38e8 --- /dev/null +++ b/configs/V29/rate_plots/eg.yaml @@ -0,0 +1,12 @@ +EGRates: + sample: MinBias + version: V29 + test_objects: + - EG:default + - tkElectron:NoIso + - tkElectron:Iso + - tkPhoton:Iso + binning: + min: 10 + max: 97 + step: 3 diff --git a/configs/V29/rate_plots/ht.yaml b/configs/V29/rate_plots/ht.yaml new file mode 100644 index 00000000..c855e7f9 --- /dev/null +++ b/configs/V29/rate_plots/ht.yaml @@ -0,0 +1,11 @@ +HTRates: + sample: MinBias + version: V29 + test_objects: + - phase1PuppiHT:default + - seededConePuppiHT:default + - trackerHT:default + binning: + min: 50 + max: 975 + step: 25 diff --git a/configs/V29/rate_plots/jets.yaml b/configs/V29/rate_plots/jets.yaml new file mode 100644 index 00000000..738c05ca --- /dev/null +++ b/configs/V29/rate_plots/jets.yaml @@ -0,0 +1,27 @@ +JetDefaultRates: + sample: MinBias + version: V29 + test_objects: + - phase1PuppiJet:default + - seededConePuppiJet:default + # - seededConeExtendedPuppiJet:default + - trackerJet:default + # - caloJet:default + binning: + min: 40 + max: 420 + step: 20 + +JetsByRegion: + sample: MinBias + version: V29 + test_objects: + - phase1PuppiJet:default:barrel + - phase1PuppiJet:default:endcap + - seededConePuppiJet:default:barrel + - seededConePuppiJet:default:endcap + binning: + min: 40 + max: 420 + step: 20 + diff --git a/configs/V29/rate_plots/met.yaml b/configs/V29/rate_plots/met.yaml new file mode 100644 index 00000000..7e527eaa --- /dev/null +++ b/configs/V29/rate_plots/met.yaml @@ -0,0 +1,10 @@ +METRates: + sample: MinBias + version: V29 + test_objects: + - puppiMET:default + - trackerMET:default + binning: + min: 50 + max: 500 + step: 25 diff --git a/configs/V29/rate_plots/muons.yaml b/configs/V29/rate_plots/muons.yaml new file mode 100644 index 00000000..74c911b0 --- /dev/null +++ b/configs/V29/rate_plots/muons.yaml @@ -0,0 +1,22 @@ +gmtMuonByRegion: + sample: MinBias + version: V29 + test_objects: + - gmtMuon:default:barrel + - gmtMuon:default:overlap + - gmtMuon:default:endcap + binning: + min: 0 + max: 75 + step: 3 + +MuonRates: + sample: MinBias + version: V29 + test_objects: + - gmtMuon:default + - gmtTkMuon:default + binning: + min: 0 + max: 75 + step: 3 diff --git a/configs/V29/rate_plots/taus.yaml b/configs/V29/rate_plots/taus.yaml new file mode 100644 index 00000000..16ba3066 --- /dev/null +++ b/configs/V29/rate_plots/taus.yaml @@ -0,0 +1,23 @@ +TauRates: + sample: MinBias + version: V29 + test_objects: + - nnTau:default + - caloTau:default + binning: + min: 10 + max: 155 + step: 5 + +TauRatesByRegion: + sample: MinBias + version: V29 + test_objects: + - caloTau:default:barrel + - caloTau:default:endcap + - nnTau:default:barrel + - nnTau:default:endcap + binning: + min: 10 + max: 155 + step: 5 diff --git a/objectPerformance/cfg_caching/V29_13X.yaml b/configs/V29_13X/caching.yaml similarity index 100% rename from objectPerformance/cfg_caching/V29_13X.yaml rename to configs/V29_13X/caching.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/bJetEff.yaml b/configs/V29_13X/object_performance/bJetEff.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/bJetEff.yaml rename to configs/V29_13X/object_performance/bJetEff.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/electron_iso.yaml b/configs/V29_13X/object_performance/electron_iso.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/electron_iso.yaml rename to configs/V29_13X/object_performance/electron_iso.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/electron_matching.yaml b/configs/V29_13X/object_performance/electron_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/electron_matching.yaml rename to configs/V29_13X/object_performance/electron_matching.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/electron_matching_eta.yaml b/configs/V29_13X/object_performance/electron_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/electron_matching_eta.yaml rename to configs/V29_13X/object_performance/electron_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/electron_trigger.yaml b/configs/V29_13X/object_performance/electron_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/electron_trigger.yaml rename to configs/V29_13X/object_performance/electron_trigger.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/ht_test.yaml b/configs/V29_13X/object_performance/ht_test.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/ht_test.yaml rename to configs/V29_13X/object_performance/ht_test.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/jets_matching.yaml b/configs/V29_13X/object_performance/jets_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/jets_matching.yaml rename to configs/V29_13X/object_performance/jets_matching.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/jets_matching_eta.yaml b/configs/V29_13X/object_performance/jets_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/jets_matching_eta.yaml rename to configs/V29_13X/object_performance/jets_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/jets_trigger.yaml b/configs/V29_13X/object_performance/jets_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/jets_trigger.yaml rename to configs/V29_13X/object_performance/jets_trigger.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/jets_trigger_fwd.yaml b/configs/V29_13X/object_performance/jets_trigger_fwd.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/jets_trigger_fwd.yaml rename to configs/V29_13X/object_performance/jets_trigger_fwd.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/met_ht_mht.yaml b/configs/V29_13X/object_performance/met_ht_mht.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/met_ht_mht.yaml rename to configs/V29_13X/object_performance/met_ht_mht.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/mht.yaml b/configs/V29_13X/object_performance/mht.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/mht.yaml rename to configs/V29_13X/object_performance/mht.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/muon_matching.yaml b/configs/V29_13X/object_performance/muon_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/muon_matching.yaml rename to configs/V29_13X/object_performance/muon_matching.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/muon_matching_eta.yaml b/configs/V29_13X/object_performance/muon_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/muon_matching_eta.yaml rename to configs/V29_13X/object_performance/muon_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/muon_trigger.yaml b/configs/V29_13X/object_performance/muon_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/muon_trigger.yaml rename to configs/V29_13X/object_performance/muon_trigger.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/photon_iso.yaml b/configs/V29_13X/object_performance/photon_iso.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/photon_iso.yaml rename to configs/V29_13X/object_performance/photon_iso.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/photons_matching.yaml b/configs/V29_13X/object_performance/photons_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/photons_matching.yaml rename to configs/V29_13X/object_performance/photons_matching.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/photons_matching_eta.yaml b/configs/V29_13X/object_performance/photons_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/photons_matching_eta.yaml rename to configs/V29_13X/object_performance/photons_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/photons_trigger.yaml b/configs/V29_13X/object_performance/photons_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/photons_trigger.yaml rename to configs/V29_13X/object_performance/photons_trigger.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/tau_matching.yaml b/configs/V29_13X/object_performance/tau_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/tau_matching.yaml rename to configs/V29_13X/object_performance/tau_matching.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/tau_trigger.yaml b/configs/V29_13X/object_performance/tau_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/tau_trigger.yaml rename to configs/V29_13X/object_performance/tau_trigger.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/tests/electron_iso_Hgg.yaml b/configs/V29_13X/object_performance/tests/electron_iso_Hgg.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/tests/electron_iso_Hgg.yaml rename to configs/V29_13X/object_performance/tests/electron_iso_Hgg.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/tests/tau_matching_TT.yaml b/configs/V29_13X/object_performance/tests/tau_matching_TT.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/tests/tau_matching_TT.yaml rename to configs/V29_13X/object_performance/tests/tau_matching_TT.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/tests/tau_trigger_TT.yaml b/configs/V29_13X/object_performance/tests/tau_trigger_TT.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/tests/tau_trigger_TT.yaml rename to configs/V29_13X/object_performance/tests/tau_trigger_TT.yaml diff --git a/objectPerformance/cfg_plots/V29_13X/version_comparison.yaml b/configs/V29_13X/object_performance/version_comparison.yaml similarity index 100% rename from objectPerformance/cfg_plots/V29_13X/version_comparison.yaml rename to configs/V29_13X/object_performance/version_comparison.yaml diff --git a/objectPerformance/cfg_caching/V30.yaml b/configs/V30/caching.yaml similarity index 100% rename from objectPerformance/cfg_caching/V30.yaml rename to configs/V30/caching.yaml diff --git a/objectPerformance/cfg_plots/V30/bJetEff.yaml b/configs/V30/object_performance/bJetEff.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/bJetEff.yaml rename to configs/V30/object_performance/bJetEff.yaml diff --git a/objectPerformance/cfg_plots/V30/electron_iso.yaml b/configs/V30/object_performance/electron_iso.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/electron_iso.yaml rename to configs/V30/object_performance/electron_iso.yaml diff --git a/objectPerformance/cfg_plots/V30/electron_matching.yaml b/configs/V30/object_performance/electron_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/electron_matching.yaml rename to configs/V30/object_performance/electron_matching.yaml diff --git a/objectPerformance/cfg_plots/V30/electron_matching_eta.yaml b/configs/V30/object_performance/electron_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/electron_matching_eta.yaml rename to configs/V30/object_performance/electron_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V30/electron_trigger.yaml b/configs/V30/object_performance/electron_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/electron_trigger.yaml rename to configs/V30/object_performance/electron_trigger.yaml diff --git a/objectPerformance/cfg_plots/V30/ht_test.yaml b/configs/V30/object_performance/ht_test.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/ht_test.yaml rename to configs/V30/object_performance/ht_test.yaml diff --git a/objectPerformance/cfg_plots/V30/jets_matching.yaml b/configs/V30/object_performance/jets_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/jets_matching.yaml rename to configs/V30/object_performance/jets_matching.yaml diff --git a/objectPerformance/cfg_plots/V30/jets_matching_eta.yaml b/configs/V30/object_performance/jets_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/jets_matching_eta.yaml rename to configs/V30/object_performance/jets_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V30/jets_matching_wBTag.yaml b/configs/V30/object_performance/jets_matching_wBTag.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/jets_matching_wBTag.yaml rename to configs/V30/object_performance/jets_matching_wBTag.yaml diff --git a/objectPerformance/cfg_plots/V30/jets_trigger.yaml b/configs/V30/object_performance/jets_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/jets_trigger.yaml rename to configs/V30/object_performance/jets_trigger.yaml diff --git a/objectPerformance/cfg_plots/V30/jets_trigger_fwd.yaml b/configs/V30/object_performance/jets_trigger_fwd.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/jets_trigger_fwd.yaml rename to configs/V30/object_performance/jets_trigger_fwd.yaml diff --git a/objectPerformance/cfg_plots/V30/met_ht_mht.yaml b/configs/V30/object_performance/met_ht_mht.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/met_ht_mht.yaml rename to configs/V30/object_performance/met_ht_mht.yaml diff --git a/objectPerformance/cfg_plots/V30/mht.yaml b/configs/V30/object_performance/mht.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/mht.yaml rename to configs/V30/object_performance/mht.yaml diff --git a/objectPerformance/cfg_plots/V30/muon_matching.yaml b/configs/V30/object_performance/muon_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/muon_matching.yaml rename to configs/V30/object_performance/muon_matching.yaml diff --git a/objectPerformance/cfg_plots/V30/muon_matching_eta.yaml b/configs/V30/object_performance/muon_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/muon_matching_eta.yaml rename to configs/V30/object_performance/muon_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V30/muon_trigger.yaml b/configs/V30/object_performance/muon_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/muon_trigger.yaml rename to configs/V30/object_performance/muon_trigger.yaml diff --git a/objectPerformance/cfg_plots/V30/photon_iso.yaml b/configs/V30/object_performance/photon_iso.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/photon_iso.yaml rename to configs/V30/object_performance/photon_iso.yaml diff --git a/objectPerformance/cfg_plots/V30/photons_matching.yaml b/configs/V30/object_performance/photons_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/photons_matching.yaml rename to configs/V30/object_performance/photons_matching.yaml diff --git a/objectPerformance/cfg_plots/V30/photons_matching_eta.yaml b/configs/V30/object_performance/photons_matching_eta.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/photons_matching_eta.yaml rename to configs/V30/object_performance/photons_matching_eta.yaml diff --git a/objectPerformance/cfg_plots/V30/photons_trigger.yaml b/configs/V30/object_performance/photons_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/photons_trigger.yaml rename to configs/V30/object_performance/photons_trigger.yaml diff --git a/objectPerformance/cfg_plots/V30/tau_matching.yaml b/configs/V30/object_performance/tau_matching.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/tau_matching.yaml rename to configs/V30/object_performance/tau_matching.yaml diff --git a/objectPerformance/cfg_plots/V30/tau_matching_wHH.yaml b/configs/V30/object_performance/tau_matching_wHH.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/tau_matching_wHH.yaml rename to configs/V30/object_performance/tau_matching_wHH.yaml diff --git a/objectPerformance/cfg_plots/V30/tau_trigger.yaml b/configs/V30/object_performance/tau_trigger.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/tau_trigger.yaml rename to configs/V30/object_performance/tau_trigger.yaml diff --git a/objectPerformance/cfg_plots/V30/version_comparison.yaml b/configs/V30/object_performance/version_comparison.yaml similarity index 100% rename from objectPerformance/cfg_plots/V30/version_comparison.yaml rename to configs/V30/object_performance/version_comparison.yaml diff --git a/objectPerformance/cfg_plots/scaling_thresholds.yaml b/configs/scaling_thresholds.yaml similarity index 100% rename from objectPerformance/cfg_plots/scaling_thresholds.yaml rename to configs/scaling_thresholds.yaml diff --git a/docs/development.md b/docs/development.md new file mode 100644 index 00000000..f0533378 --- /dev/null +++ b/docs/development.md @@ -0,0 +1,47 @@ +# Instructions for development + +## Dependency management and dev environment +Poetry is used as a backend for packaging and for dependency +management. To set up a working development environment, create +a virtual environment and install the `poetry` python package. +Then install all develpoment dependencies: + +```bash +python@3.11 -m venv +source /bin/activate +pip install poetry +poetry install +``` + +## Testing +The tests are maintained in the subpackages under `tests`, e.g. +`menu_tools/object_performance/tests`. After properly setting up +a development environment as described [above](#dependency-management-and-dev-environment) +you can simply run + +```bash +pytest -vv +``` + +to run all tests. The `-vv` option is optional and can be omitted. +For some of the tests the presence of the V29 caching files is required. + + +## Code Formatting and Linting +`black` is used for code formatting and `flake8` for linting. +These tools are helpful to have consistent formatting through +the codebase even with multiple developers working on the code. +To run `black`, set up the development environment as described +[above](#dependency-management-and-dev-environment) and run + +```bash +black menu_tools +``` + +If you want to dry-run, add the `--check` flag to see which files would +be modified. +Similarlly `flake8` can be run by simply typing + +```bash +flake8 menu_tools +``` diff --git a/objectPerformance/Details.md b/docs/object-performance-details.md similarity index 100% rename from objectPerformance/Details.md rename to docs/object-performance-details.md diff --git a/objectPerformance/README.md b/docs/object-performance.md similarity index 97% rename from objectPerformance/README.md rename to docs/object-performance.md index 005462fe..eb202bff 100644 --- a/objectPerformance/README.md +++ b/docs/object-performance.md @@ -6,7 +6,7 @@ The definition of each object to be tested is detailed in this [TWiki page](https://twiki.cern.ch/twiki/bin/view/CMS/PhaseIIL1TriggerMenuTools). - A detailed description of each step, together with instructions on how to set up the configuration files for the cache and plotting steps, is given in [the Wiki pages](https://github.com/bonanomi/Phase2-L1MenuTools/wiki/Cache-objects-and-performance-plots). + A detailed description of each step, together with instructions on how to set up the configuration files for the cache and plotting steps, is given in [the Wiki pages](https://github.com/cms-l1-dpg/Phase2-L1MenuTools/wiki). The following presents the minimal set of commands to be run to produce the standard set of validation plots (cf. [these slides](https://twiki.cern.ch/twiki/pub/CMS/PhaseIIL1TriggerMenuTools/Phase2Menu_validation123x-3.pdf)). @@ -71,4 +71,4 @@ * `turnons`: plots of the matching efficiencies and L1 turn-on efficiency curves. - * `scalings`: plots of the scalings, i.e. position of the turnon point (often 95% location) as a function of different threshold cuts on L1 objects. \ No newline at end of file + * `scalings`: plots of the scalings, i.e. position of the turnon point (often 95% location) as a function of different threshold cuts on L1 objects. diff --git a/objectPerformance/src/__init__.py b/menu_tools/caching/__init__.py similarity index 100% rename from objectPerformance/src/__init__.py rename to menu_tools/caching/__init__.py diff --git a/objectPerformance/src/cache_objects.py b/menu_tools/caching/cache_objects.py similarity index 77% rename from objectPerformance/src/cache_objects.py rename to menu_tools/caching/cache_objects.py index 07ce9ebf..4c304755 100755 --- a/objectPerformance/src/cache_objects.py +++ b/menu_tools/caching/cache_objects.py @@ -1,44 +1,37 @@ -#!/afs/cern.ch/user/d/dhundhau/Phase2-L1MenuTools/pyenv-ak2.0/bin/python import argparse import glob import os import awkward as ak -from progress.bar import IncrementalBar +from tqdm import tqdm import uproot import vector import yaml -from utils import get_pdg_id -from utils import get_branches -from utils import timer +from menu_tools.utils import utils vector.register_awkward() -class ObjectCacher(): - - def __init__(self, version, sample, obj, tree, branches, cfg_file, - dryrun=False): +class ObjectCacher: + def __init__(self, version, sample, obj, tree, branches, cfg_file, dryrun=False): self._version = version self._sample = sample self._cfg_file = cfg_file - self._object = obj.split('_')[0] + self._object = obj.split("_")[0] self._tree = tree self._final_ak_array = None self._ref_part_iso_dR_vals = [0.1, 0.15, 0.2, 0.3, 1.5] - self._ref_part_iso = { - f"dr_{dR}": [] for dR in self._ref_part_iso_dR_vals - } + self._ref_part_iso = {f"dr_{dR}": [] for dR in self._ref_part_iso_dR_vals} try: - self._part_type = obj.split('_')[1] + self._part_type = obj.split("_")[1] except IndexError: self._part_type = "" self._dryrun = dryrun # Get Branches if not isinstance(branches, list): - self._branches = get_branches(self._ntuple_path, tree, obj) + self._branches = utils.get_branches(self._ntuple_path, tree, obj) else: self._branches = branches self.cache_out_path = f"cache/{version}/" @@ -50,11 +43,7 @@ def parquet_fname(self): Returns the name of the output file that the object will produce. """ - fname = ( - self._version - + '_' + self._sample - + "_" + self._object - ) + fname = self._version + "_" + self._sample + "_" + self._object if self._part_type: fname += "_" + self._part_type return fname @@ -68,7 +57,7 @@ def _ntuple_path(self): if glob.glob(local_ntuple_path): return local_ntuple_path - with open(self._cfg_file, 'r') as f: + with open(self._cfg_file, "r") as f: cfg = yaml.safe_load(f)[self._version][self._sample] return cfg["ntuple_path"] @@ -89,10 +78,10 @@ def _p4_sum(self, array, axis=-1): "E": ak.sum(array.E, axis=axis, keepdims=True), }, with_name="Momentum4D", - behavior=array.behavior + behavior=array.behavior, ) - def _get_visible_taus(self, all_parts, status_check = True): + def _get_visible_taus(self, all_parts, status_check=True): """ Create a collection of gen-level taus. Leptonic taus are discarded. @@ -102,15 +91,17 @@ def _get_visible_taus(self, all_parts, status_check = True): all_parts = ak.zip({k.lower(): all_parts[k] for k in all_parts.keys()}) if status_check: - - sel = ( (all_parts.id == 15) & - (all_parts.stat == 2) - ) + sel = (all_parts.id == 15) & (all_parts.stat == 2) is_tau = ak.any(sel, axis=-1) all_parts = ak.where(is_tau, all_parts, ak.full_like(all_parts, -1000)) - all_parts = {f: field for f, field in zip(['Id','Stat','Pt','Eta','Phi','Parent','E'],ak.unzip(all_parts))} + all_parts = { + f: field + for f, field in zip( + ["Id", "Stat", "Pt", "Eta", "Phi", "Parent", "E"], ak.unzip(all_parts) + ) + } sel_no_nu_e = abs(all_parts["Id"]) != 12 sel_no_nu_mu = abs(all_parts["Id"]) != 14 @@ -123,11 +114,11 @@ def _get_visible_taus(self, all_parts, status_check = True): all_tau_p = all_parts.copy() all_tau_m = all_parts.copy() - sel = all_tau_p['Parent'] == 15 + sel = all_tau_p["Parent"] == 15 for branch in all_tau_p: all_tau_p[branch] = all_tau_p[branch][sel] - sel = all_tau_m['Parent'] == -15 + sel = all_tau_m["Parent"] == -15 for branch in all_tau_m: all_tau_m[branch] = all_tau_m[branch][sel] @@ -137,13 +128,13 @@ def _get_visible_taus(self, all_parts, status_check = True): all_tau_p = ak.zip({k.lower(): all_tau_p[k] for k in all_tau_p.keys()}) all_tau_p = ak.with_name(all_tau_p, "Momentum4D") - sel_ele = ak.any(abs(all_tau_p['id']) == 11, axis=-1) - sel_mu = ak.any(abs(all_tau_p['id']) == 13, axis=-1) + sel_ele = ak.any(abs(all_tau_p["id"]) == 11, axis=-1) + sel_mu = ak.any(abs(all_tau_p["id"]) == 13, axis=-1) sel_lep = sel_ele | sel_mu all_tau_p = ak.mask(all_tau_p, sel_lep, valid_when=False) - sel_ele = ak.any(abs(all_tau_m['id']) == 11, axis=-1) - sel_mu = ak.any(abs(all_tau_m['id']) == 13, axis=-1) + sel_ele = ak.any(abs(all_tau_m["id"]) == 11, axis=-1) + sel_mu = ak.any(abs(all_tau_m["id"]) == 13, axis=-1) sel_lep = sel_ele | sel_mu all_tau_m = ak.mask(all_tau_m, sel_lep, valid_when=False) @@ -153,13 +144,13 @@ def _get_visible_taus(self, all_parts, status_check = True): # Parent, Id and Stat are dummy branches, only needed # for technical consistency. final_taus = { - 'Pt': ak.concatenate([fs_tau_p.pt, fs_tau_m.pt], axis=-1), - 'Eta': ak.concatenate([fs_tau_p.eta, fs_tau_m.eta], axis=-1), - 'Phi': ak.concatenate([fs_tau_p.phi, fs_tau_m.phi], axis=-1), - 'E': ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1), - 'Parent': ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1), - 'Id': ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1), - 'Stat': ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1) + "Pt": ak.concatenate([fs_tau_p.pt, fs_tau_m.pt], axis=-1), + "Eta": ak.concatenate([fs_tau_p.eta, fs_tau_m.eta], axis=-1), + "Phi": ak.concatenate([fs_tau_p.phi, fs_tau_m.phi], axis=-1), + "E": ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1), + "Parent": ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1), + "Id": ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1), + "Stat": ak.concatenate([fs_tau_p.E, fs_tau_m.E], axis=-1), } return final_taus @@ -169,14 +160,14 @@ def _filter_genpart_branches(self, all_arrays): Filter genparticle branches by Id. """ partId = abs(all_arrays["Id"]) - sel_id = (partId == get_pdg_id(self._part_type)) + sel_id = partId == utils.get_pdg_id(self._part_type) for branch in all_arrays: all_arrays[branch] = all_arrays[branch][sel_id] all_arrays[branch] = ak.fill_none(all_arrays[branch], -999) return all_arrays - def _filter_fspart_branches(self, all_parts, status_check = True): + def _filter_fspart_branches(self, all_parts, status_check=True): """ Select all the final state particles. This collection is used only for dR matching @@ -186,15 +177,17 @@ def _filter_fspart_branches(self, all_parts, status_check = True): all_parts = ak.zip({k.lower(): all_parts[k] for k in all_parts.keys()}) if status_check: - - sel = ( (all_parts.id == 15) & - (all_parts.stat == 2) - ) + sel = (all_parts.id == 15) & (all_parts.stat == 2) is_tau = ak.any(sel, axis=-1) all_parts = ak.where(is_tau, all_parts, ak.full_like(all_parts, -1000)) - all_parts = {f: field for f, field in zip(['Id','Stat','Pt','Eta','Phi','Parent','E'],ak.unzip(all_parts))} + all_parts = { + f: field + for f, field in zip( + ["Id", "Stat", "Pt", "Eta", "Phi", "Parent", "E"], ak.unzip(all_parts) + ) + } sel_no_nu_e = abs(all_parts["Id"]) != 12 sel_no_nu_mu = abs(all_parts["Id"]) != 14 @@ -258,42 +251,34 @@ def _load_branches_from_ntuple(self, chunk_array, arr, branches): def _ak_array_in_chunk(self, arr, chunk_array, branches): for branch in branches: branch_key = branch.removeprefix("part") - arr[branch_key] = ak.concatenate( - [arr[branch_key], chunk_array[branch_key]] - ) + arr[branch_key] = ak.concatenate([arr[branch_key], chunk_array[branch_key]]) return arr - @timer("Loading objects files") + @utils.timer("Loading objects files") def _concat_array_from_ntuples(self): fnames = glob.glob(self._ntuple_path)[:] - bar = IncrementalBar("Progress", max=len(fnames)) branches = [self._object + x for x in self._branches] all_arrays = {x.removeprefix("part"): [] for x in branches} - for fname in fnames: - bar.next() + for fname in tqdm(fnames): new_array = {x.removeprefix("part"): [] for x in branches} # Read files in chunks to avoid issues with large size files chunk_name = f"{fname}:{self._tree}" - for array in uproot.iterate(chunk_name, filter_name = branches, step_size="100 MB"): + for array in uproot.iterate( + chunk_name, filter_name=branches, step_size="100 MB" + ): chunk_array = {x.removeprefix("part"): [] for x in branches} chunk_array = self._load_branches_from_ntuple( chunk_array, array, branches ) chunk_array = self._postprocess_branches(chunk_array) - new_array = self._ak_array_in_chunk( - new_array, chunk_array, branches - ) + new_array = self._ak_array_in_chunk(new_array, chunk_array, branches) # Concatenate array from "fname file" to all_arrays - all_arrays = self._ak_array_in_chunk( - all_arrays, new_array, branches - ) - - bar.finish() + all_arrays = self._ak_array_in_chunk(all_arrays, new_array, branches) if self._object.startswith("part"): all_arrays = {**all_arrays, **self._ref_part_iso} @@ -317,11 +302,11 @@ def _save_array_to_parquet(self): """ ak.to_parquet( self._final_ak_array, - destination=self.cache_out_path + f"{self.parquet_fname}.parquet" + destination=self.cache_out_path + f"{self.parquet_fname}.parquet", ) def load(self): - #print(f"Process {self._object + self._part_type} object...") + # print(f"Process {self._object + self._part_type} object...") if self._cache_file_exists(): return @@ -338,23 +323,26 @@ def load(self): self._save_array_to_parquet() -if __name__ == "__main__": - +def parse_args(): parser = argparse.ArgumentParser() parser.add_argument( "cfg", - default="cfg_caching/V22.yaml", - help="" + help="Path to the config file in yaml format. Defaults in `configs/caching`.", ) parser.add_argument( "--dry-run", "-d", action="store_true", - help="Only do print-out of objects and branches to be loaded." + help="Only do print-out of objects and branches to be loaded.", ) args = parser.parse_args() + return args - with open(args.cfg, 'r') as f: + +def main(): + args = parse_args() + + with open(args.cfg, "r") as f: cfg = yaml.safe_load(f) for version, samples in cfg.items(): print("Processing: version", version) @@ -372,6 +360,10 @@ def load(self): obj=obj, branches=branches, cfg_file=args.cfg, - dryrun=args.dry_run + dryrun=args.dry_run, ) loader.load() + + +if __name__ == "__main__": + main() diff --git a/objectPerformance/tests/__init__.py b/menu_tools/object_performance/__init__.py similarity index 100% rename from objectPerformance/tests/__init__.py rename to menu_tools/object_performance/__init__.py diff --git a/objectPerformance/src/compare_json.ipynb b/menu_tools/object_performance/compare_json.ipynb similarity index 100% rename from objectPerformance/src/compare_json.ipynb rename to menu_tools/object_performance/compare_json.ipynb diff --git a/objectPerformance/src/compare_plots.py b/menu_tools/object_performance/compare_plots.py similarity index 67% rename from objectPerformance/src/compare_plots.py rename to menu_tools/object_performance/compare_plots.py index 54f69f6e..06f8d3a0 100755 --- a/objectPerformance/src/compare_plots.py +++ b/menu_tools/object_performance/compare_plots.py @@ -1,40 +1,34 @@ -#!/afs/cern.ch/user/d/dhundhau/Phase2-L1MenuTools/pyenv-ak2.0/bin/python import argparse import os import matplotlib.pyplot as plt import mplhep as hep -import numpy as np -from progress.bar import IncrementalBar import yaml import json -from turnon_collection import TurnOnCollection -from scaling_collection import ScalingCollection -from plotter import Plotter -import utils +from menu_tools.object_performance.plotter import Plotter plt.style.use(hep.style.CMS) class ComparisonCentral(Plotter): - def __init__(self, cfg_plots_path): - with open(cfg_plots_path, 'r') as f: + with open(cfg_plots_path, "r") as f: self.cfg_plots = yaml.safe_load(f) for plot_name, cfg_plot in self.cfg_plots.items(): self.plot_name = plot_name self.cfg = self.cfg_plots[self.plot_name] self.save_dir = self.cfg["save_dir"] - if not os.path.exists(self.save_dir): os.makedirs(self.save_dir) + if not os.path.exists(self.save_dir): + os.makedirs(self.save_dir) @property def _get_watermark(self): - try: - return self.cfg["watermark"] - except KeyError: - return " " + try: + return self.cfg["watermark"] + except KeyError: + return " " @property def _get_files(self): @@ -56,15 +50,20 @@ def _style_plot(self, fig, ax, legend_loc="lower right"): ax.set_ylabel(rf"{ylabel}") ax.set_ylim(0.0, 1) ax.tick_params(direction="in") - ax.text(0, -0.1, self._get_watermark, - color="grey", alpha=0.2, - fontsize=20, - transform=ax.transAxes) + ax.text( + 0, + -0.1, + self._get_watermark, + color="grey", + alpha=0.2, + fontsize=20, + transform=ax.transAxes, + ) fig.tight_layout() def run(self): files = self._get_files - fig, ax = self._create_new_plot() + fig, ax = self._create_new_plot() for file in files: fname = os.path.join(files[file]["dir"], file) test_object = files[file]["object"] @@ -76,24 +75,27 @@ def run(self): err_kwargs = dict_to_plot[test_object]["err_kwargs"] - ax.errorbar(dict_to_plot[test_object]["xbins"], - dict_to_plot[test_object]["efficiency"], - yerr = dict_to_plot[test_object]["efficiency_err"], - label = label, **err_kwargs) + ax.errorbar( + dict_to_plot[test_object]["xbins"], + dict_to_plot[test_object]["efficiency"], + yerr=dict_to_plot[test_object]["efficiency_err"], + label=label, + **err_kwargs, + ) self._style_plot(fig, ax) plt.savefig(f"{self.save_dir}/{self.plot_name}.png") plt.savefig(f"{self.save_dir}/{self.plot_name}.pdf") + if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument( "cfg_plots", default="cfg_plots/version_comparison.yaml", - help="Path of YAML file specifying the desired plots." + help="Path of YAML file specifying the desired plots.", ) args = parser.parse_args() plotter = ComparisonCentral(args.cfg_plots) plotter.run() - diff --git a/menu_tools/object_performance/config.py b/menu_tools/object_performance/config.py new file mode 100644 index 00000000..a51dd89e --- /dev/null +++ b/menu_tools/object_performance/config.py @@ -0,0 +1,103 @@ +from typing import Any, Optional + +from menu_tools.utils.config import BasePlotConfig +from menu_tools.utils.objects import Object + + +class PerformancePlotConfig(BasePlotConfig): + def __init__(self, cfg: dict[str, Any], name: Optional[str] = None) -> None: + super().__init__(cfg, name) + + @property + def iso_vs_eff_plot(self): + try: + return self._cfg["iso_vs_efficiency"] + except KeyError: + return False + + @property + def reference_object(self): + return self._cfg["reference_object"]["object"] + + @property + def reference_event_cuts(self): + try: + return self._cfg["reference_object"]["cuts"]["event"] + except KeyError: + return [] + + @property + def reference_object_cuts(self): + try: + return self._cfg["reference_object"]["cuts"]["object"] + except KeyError: + return [] + + @property + def reference_trafo(self) -> Optional[str]: + try: + return self._cfg["reference_object"]["trafo"] + except KeyError: + return None + + @property + def reference_label(self) -> str: + try: + return self._cfg["reference_object"]["label"] + except KeyError: + raise KeyError("No label defined for reference object in {self.plot_name}!") + + @property + def test_objects(self) -> dict[str, Any]: + # Parse to detect faulty config + if not all([":" in x for x in self._cfg["test_objects"]]): + raise ValueError(f"Misconfigured obj:id key in {self.plot_name}!") + + return self._cfg["test_objects"] + + # DEPRECATED + # test_obj = { + # x: {"base_obj": x.split(":")[0], "id": x.split(":")[1], "x_arg": x_arg} + # for x, x_arg in self._cfg["test_objects"].items() + # } + + # return test_obj + + @property + def matching(self): + try: + return self._cfg["match_test_to_ref"] + except KeyError: + return False + + @property + def reference_field(self): + field = self._cfg["reference_object"]["x_arg"] + return field.lower() + + @property + def compute_scalings(self) -> bool: + return "scalings" in self._cfg.keys() + + @property + def scaling_pct(self): + return self._cfg["scalings"]["threshold"] + + @property + def scaling_method(self): + return self._cfg["scalings"]["method"] + + @property + def xlabel(self): + return self._cfg["xlabel"] + + @property + def ylabel(self): + return self._cfg["ylabel"] + + @property + def test_object_instances(self) -> list: + test_objects = [] + for obj_key in self._cfg["test_objects"]: + test_objects.append(Object(obj_key, self.version)) + return test_objects diff --git a/objectPerformance/src/plotBTagEfficiency.py b/menu_tools/object_performance/plotBTagEfficiency.py similarity index 64% rename from objectPerformance/src/plotBTagEfficiency.py rename to menu_tools/object_performance/plotBTagEfficiency.py index 6123c22a..2b4e6160 100755 --- a/objectPerformance/src/plotBTagEfficiency.py +++ b/menu_tools/object_performance/plotBTagEfficiency.py @@ -1,36 +1,34 @@ -#!/afs/cern.ch/user/d/dhundhau/Phase2-L1MenuTools/pyenv-ak2.0/bin/python import argparse import os import matplotlib.pyplot as plt import mplhep as hep -import numpy as np import yaml import json -from plotter import Plotter +from menu_tools.object_performance.plotter import Plotter plt.style.use(hep.style.CMS) class ComparisonCentral(Plotter): - def __init__(self, cfg_plots_path): - with open(cfg_plots_path, 'r') as f: + with open(cfg_plots_path, "r") as f: self.cfg_plots = yaml.safe_load(f) self.cfgs = {} for plot_name, cfg_plot in self.cfg_plots.items(): - print (plot_name) + print(plot_name) self.cfgs[plot_name] = cfg_plot - if not os.path.exists(cfg_plot['save_dir']): os.makedirs(cfg_plot['save_dir']) + if not os.path.exists(cfg_plot["save_dir"]): + os.makedirs(cfg_plot["save_dir"]) - def _get_watermark(self,cfg): - try: - return cfg["watermark"] - except KeyError: - return " " + def _get_watermark(self, cfg): + try: + return cfg["watermark"] + except KeyError: + return " " - def _get_files(self,cfg): + def _get_files(self, cfg): try: return cfg["files"] except KeyError: @@ -49,16 +47,21 @@ def _style_plot(self, cfg, fig, ax, legend_loc="upper right"): ax.set_ylabel(rf"{ylabel}") ax.set_ylim(0.0, 1) ax.tick_params(direction="in") - ax.text(0, -0.1, self._get_watermark(cfg), - color="grey", alpha=0.2, - fontsize=20, - transform=ax.transAxes) + ax.text( + 0, + -0.1, + self._get_watermark(cfg), + color="grey", + alpha=0.2, + fontsize=20, + transform=ax.transAxes, + ) fig.tight_layout() def run(self): for plot_name, cfg in self.cfgs.items(): files = self._get_files(cfg) - fig, ax = self._create_new_plot() + fig, ax = self._create_new_plot() for file in files: fname = os.path.join(files[file]["dir"], file) test_object = files[file]["object"] @@ -70,25 +73,28 @@ def run(self): err_kwargs = dict_to_plot[test_object]["err_kwargs"] - ax.errorbar(dict_to_plot[test_object]["xbins"], - dict_to_plot[test_object]["efficiency"], - yerr = dict_to_plot[test_object]["efficiency_err"], - label = label, **err_kwargs) + ax.errorbar( + dict_to_plot[test_object]["xbins"], + dict_to_plot[test_object]["efficiency"], + yerr=dict_to_plot[test_object]["efficiency_err"], + label=label, + **err_kwargs, + ) self._style_plot(cfg, fig, ax) - print ("Saving plot to : ",plot_name) + print("Saving plot to : ", plot_name) plt.savefig(f"{cfg['save_dir']}/{plot_name}.png") plt.savefig(f"{cfg['save_dir']}/{plot_name}.pdf") + if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument( "cfg_plots", default="cfg_plots/bJetEff.yaml", - help="Path of YAML file specifying the desired plots." + help="Path of YAML file specifying the desired plots.", ) args = parser.parse_args() plotter = ComparisonCentral(args.cfg_plots) plotter.run() - diff --git a/menu_tools/object_performance/plotter.py b/menu_tools/object_performance/plotter.py new file mode 100755 index 00000000..955f559a --- /dev/null +++ b/menu_tools/object_performance/plotter.py @@ -0,0 +1,545 @@ +import argparse +import json +import os +from typing import Any +import warnings +import yaml + +import matplotlib.pyplot as plt +import mplhep as hep +import numpy as np +from tqdm import tqdm + +from menu_tools.object_performance.turnon_collection import TurnOnCollection +from menu_tools.object_performance.config import PerformancePlotConfig +from menu_tools.object_performance.scaling_collection import ScalingCollection +from menu_tools.utils import utils +from menu_tools.utils.objects import Object + + +plt.style.use(hep.style.CMS) + + +class Plotter: + def _make_output_dirs(self, version: str) -> None: + os.makedirs(f"outputs/{version}/object_performance/turnons", exist_ok=True) + os.makedirs( + f"outputs/{version}/object_performance/distributions", exist_ok=True + ) + os.makedirs(f"outputs/{version}/object_performance/scalings", exist_ok=True) + + def _create_new_plot(self) -> tuple[plt.Figure, plt.Axes]: + fig, ax = plt.subplots(figsize=(10, 10)) + hep.cms.label(ax=ax, llabel="Phase-2 Simulation", com=14) + return fig, ax + + +class EfficiencyPlotter(Plotter): + def __init__(self, name, cfg, turnon_collection): + self.plot_name = name + self.cfg = PerformancePlotConfig(cfg, name) + self.turnon_collection = turnon_collection + self.version = self.turnon_collection.version + self.threshold = self.turnon_collection.threshold + self.bin_width = turnon_collection.cfg_plot.bin_width + + @property + def _outdir_turnons(self) -> str: + return os.path.join("outputs", self.version, "object_performance", "turnons") + + @property + def _outdir_distributions(self) -> str: + return os.path.join( + "outputs", self.version, "object_performance", "distributions" + ) + + def _style_plot(self, fig, ax, legend_loc="lower right"): + ax.axvline(self.threshold, ls=":", c="k") + ax.axhline(1, ls=":", c="k") + ax.legend(loc=legend_loc, frameon=False) + ax.set_xlabel(rf"{self.cfg.xlabel}") + ylabel = self.cfg.ylabel.replace("", str(self.threshold)) + ax.set_ylabel(rf"{ylabel}") + ax.set_xlim(self.cfg.bin_min, self.cfg.bin_max) + ax.tick_params(direction="in") + watermark = f"{self.version}_{self.plot_name}_" f"{self.threshold}" + ax.text( + 0, + -0.1, + watermark, + color="grey", + alpha=0.2, + fontsize=20, + transform=ax.transAxes, + ) + fig.tight_layout() + + def _save_json(self, file_name): + plot = {} + plot["xlabel"] = self.cfg.xlabel + plot["ylabel"] = self.cfg.ylabel.replace("", str(self.threshold)) + plot["watermark"] = f"{self.version}_{self.plot_name}_" f"{self.threshold}" + + for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): + if obj_key == "ref": + continue + obj = Object( + obj_key, + version=self.version, + ) + + xbins = self.turnon_collection.bins + xbins = 0.5 * (xbins[1:] + xbins[:-1]) + + if self.cfg.iso_vs_eff_plot: + efficiency = self._get_iso_vs_eff_hist(gen_hist_trig[0]) + yerr = np.zeros((2, len(efficiency))) + xerr = np.zeros(len(efficiency)) + else: + efficiency, yerr = self.turnon_collection.get_efficiency(obj_key) + xerr = self.turnon_collection.xerr(obj_key) + + yerr = np.array( + [yerr[0][~np.isnan(efficiency)], yerr[1][~np.isnan(efficiency)]] + ) + xerr = xerr[np.isfinite(efficiency)] + xbins = xbins[np.isfinite(efficiency)] + efficiency = efficiency[np.isfinite(efficiency)] + + xerr = xerr.tolist() + yerr = yerr.tolist() + xbins = xbins.tolist() + efficiency = efficiency.tolist() + + plot[obj_key] = {} + plot[obj_key]["label"] = obj.plot_label + plot[obj_key]["efficiency"] = efficiency + plot[obj_key]["efficiency_err"] = yerr + plot[obj_key]["xbins"] = xbins + plot[obj_key]["err_kwargs"] = { + "xerr": xerr, + "capsize": 3, + "marker": "o", + "markersize": 8, + } + + with open(f"{file_name}", "w") as outfile: + outfile.write(json.dumps(plot, indent=4)) + + def _get_iso_vs_eff_hist(self, test_hist): + """ + Cumulative ratio of efficiency vs L1 Iso histogram. + """ + + l1_isolation_histogram = np.sum(test_hist) + l1_cumulative_sum = np.cumsum(test_hist) / l1_isolation_histogram + + return l1_cumulative_sum + + @utils.ignore_warnings + def _plot_efficiency_curve(self): + """ + Efficiency / turn-on plots. + """ + fig, ax = self._create_new_plot() + xbins = self.turnon_collection.bins + xbins = 0.5 * (xbins[1:] + xbins[:-1]) + + for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): + if obj_key == "ref": + continue + efficiency, yerr = self.turnon_collection.get_efficiency(obj_key) + + obj = Object( + obj_key, + version=self.version, + ) + + err_kwargs = { + # "xerr": self.turnon_collection.xerr(obj_key), + "capsize": 3, + "marker": "o", + "markersize": 8, + } + ax.errorbar( + xbins, efficiency, yerr=yerr, label=obj.plot_label, **err_kwargs + ) + + self._style_plot(fig, ax) + ax.set_ylim(0, 1.1) + + # Save figure + plot_fname = f"{self.plot_name}_{self.threshold}_{self.version}" + plt.savefig(os.path.join(self._outdir_turnons, f"{plot_fname}.png")) + plt.savefig(os.path.join(self._outdir_turnons, f"{plot_fname}.pdf")) + self._save_json(os.path.join(self._outdir_turnons, f"{plot_fname}.json")) + + # Save config + with open(os.path.join(self._outdir_turnons, f"{plot_fname}.yaml"), "w") as f: + yaml.dump( + {self.plot_name: self.cfg.config_dict}, f, default_flow_style=False + ) + + plt.close() + + @utils.ignore_warnings + def _plot_iso_vs_efficiency_curve(self): + """ + Efficiency vs L1 Iso plots. + """ + fig, ax = self._create_new_plot() + xbins = self.turnon_collection.bins + xbins = 0.5 * (xbins[1:] + xbins[:-1]) + + for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): + if obj_key == "ref": + continue + iso_vs_eff_hist = self._get_iso_vs_eff_hist(gen_hist_trig[0]) + + obj = Object( + obj_key, + version=self.version, + ) + + # yerr = np.sqrt(iso_vs_eff_hist) # TODO: Possibly introduce errors + err_kwargs = {"capsize": 3, "marker": "o", "markersize": 8} + ax.errorbar(xbins, iso_vs_eff_hist, label=obj.plot_label, **err_kwargs) + + self._style_plot(fig, ax) + + # Save figure + plot_fname = f"{self.plot_name}_{self.threshold}_{self.version}" + plt.savefig(os.path.join(self._outdir_turnons, f"{plot_fname}.png")) + plt.savefig(os.path.join(self._outdir_turnons, f"{plot_fname}.pdf")) + self._save_json(os.path.join(self._outdir_turnons, f"{plot_fname}.json")) + + # Save config + with open(os.path.join(self._outdir_turnons, f"{plot_fname}.yaml"), "w") as f: + yaml.dump( + {self.plot_name: self.cfg.config_dict}, f, default_flow_style=False + ) + + plt.close() + + def _plot_raw_counts(self): + """ + Raw counts of objects in bins + of the efficiency plots. + """ + fig, ax = self._create_new_plot() + xbins = self.turnon_collection.bins + xbins = 0.5 * (xbins[1:] + xbins[:-1]) + + for obj_key, ref_hist in self.turnon_collection.hists["ref"].items(): + err_kwargs = { + "xerr": self.turnon_collection.xerr(obj_key), + "capsize": 1, + "marker": "o", + "markersize": 2, + "linestyle": "None", + } + + ref_hist = ax.step( + xbins, + ref_hist[0], + where="mid", + label="ref: " + obj_key, + ls="--", + color="k", + ) + + for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): + if obj_key == "ref": + continue + yerr = np.sqrt(gen_hist_trig[0]) + label = obj_key + test_hist = ax.step(xbins, gen_hist_trig[0], where="mid") + ax.errorbar( + xbins, + gen_hist_trig[0], + yerr=yerr, + label=label, + color=test_hist[0].get_color(), + **err_kwargs, + ) + + self._style_plot(fig, ax) + # Save figure + plot_fname = f"{self.plot_name}_{self.threshold}_dist_{self.version}" + plt.savefig(os.path.join(self._outdir_distributions, f"{plot_fname}.png")) + plt.savefig(os.path.join(self._outdir_distributions, f"{plot_fname}.pdf")) + + plt.close() + + def plot(self): + self._make_output_dirs(self.version) + if self.cfg.iso_vs_eff_plot: + self._plot_iso_vs_efficiency_curve() + else: + self._plot_efficiency_curve() + self._plot_raw_counts() + + +class EfficiencyCentral: + """ + Class that orchestrates the plotting of + """ + + def __init__(self, cfg_plots_path): + with open(cfg_plots_path, "r") as f: + self.cfg_plots = yaml.safe_load(f) + + def get_thresholds(self, cfg_plot: dict): + """ + Function that returns the threholds for which + efficiency plots are to be produced. If the + thresholds are given in the config, these + values are returned in a list. If the + threshold configuration is missing, a single + threshold of -999 is returned. + """ + try: + return cfg_plot["thresholds"] + except KeyError: + return [-999] + + def run(self): + """ + This function iterates over all plots defined + in the configuration file, creates a turnon_collection + for it and passes it to the EfficiencyPlotter for + plotting. + """ + for plot_name, cfg_plot in self.cfg_plots.items(): + for threshold in self.get_thresholds(cfg_plot): + print(f">>> Turn On {plot_name} ({threshold} GeV) <<<") + turnon_collection = TurnOnCollection(cfg_plot, threshold, plot_name) + turnon_collection.create_hists() + + plotter = EfficiencyPlotter(plot_name, cfg_plot, turnon_collection) + plotter.plot() + + +class ScalingPlotter(Plotter): + def __init__( + self, + plot_name: str, + cfg_plot: dict, + scalings: dict, + scaling_pct: float, + version: str, + params: dict[str, np.ndarray], + ): + self.plot_name = plot_name + self.cfg_plot = cfg_plot + self.scalings = scalings + self.params = params + self.version = version + self.scaling_pct = scaling_pct + + def _params_to_func_str(self, obj_key: str): + a = round(self.params[obj_key][0], 3) + b = round(self.params[obj_key][1], 3) + pm = "+" if b > 0 else "-" + return f"y = {a} x {pm} {abs(b)}" + + def _save_json(self, fpath: str) -> None: + plot: dict[str, Any] = {"watermark": f"{self.version}_{self.plot_name}"} + + for obj, points in self.scalings.items(): + _object = {} + x_points = list(points.keys()) + y_points = list(points.values()) + + label = obj + ", " + self._params_to_func_str(obj) + + _object["xvals"] = x_points + _object["yvals"] = y_points + _object["label"] = label + + plot[obj] = _object + + with open(fpath, "w") as outfile: + outfile.write(json.dumps(plot, indent=4)) + + def plot(self): + self._make_output_dirs(self.version) + + fig, ax = self._create_new_plot() + for obj_key, points in self.scalings.items(): + obj = Object(obj_key, self.version) + x_points = np.array(list(points.keys())) + y_points = np.array(list(points.values())) + pts = ax.plot(x_points, y_points, "o") + + label = obj.plot_label + ", " + self._params_to_func_str(obj_key) + a, b = self.params[obj_key] + x = np.linspace(0, 2500, 20) + y = utils.scaling_func(x, a, b) + ax.plot(x, y, color=pts[0].get_color(), label=label) + + ax.legend(loc="lower right") + ax.set_xlabel("L1 threshold [GeV]") + ax.set_ylabel(f"{int(self.scaling_pct * 100)}% Location (gen, GeV)") + watermark = f"{self.version}_{self.plot_name}" + ax.text( + 0, + -0.1, + watermark, + color="grey", + alpha=0.2, + fontsize=20, + transform=ax.transAxes, + ) + fig.tight_layout() + ax.set_xlim(0, np.max(x_points)) + ax.set_ylim(0, np.max(y_points)) + + plot_fname = os.path.join( + "outputs", + self.version, + "object_performance", + "scalings", + f"{self.plot_name}_{self.version}", + ) + plt.savefig(f"{plot_fname}.png") + plt.savefig(f"{plot_fname}.pdf") + self._save_json(f"{plot_fname}.json") + + ## save config + with open(f"{plot_fname}.yaml", "w") as outfile: + yaml.dump( + {self.plot_name: self.cfg_plot}, outfile, default_flow_style=False + ) + + plt.close() + + +class ScalingCentral: + def __init__(self, cfg_plots_path: str) -> None: + with open(cfg_plots_path, "r") as f: + self.cfg_plots = yaml.safe_load(f) + with open("./configs/scaling_thresholds.yaml", "r") as f: + self.scaling_thresholds = yaml.safe_load(f) + + def _get_scaling_thresholds(self, cfg_plot, test_obj) -> list[int]: + if test_obj in self.scaling_thresholds: + return self.scaling_thresholds[test_obj] + if any("Muon" in x for x in cfg_plot["test_objects"]): + return self.scaling_thresholds["Muon"] + if any( + any([y in x for x in cfg_plot["test_objects"]]) + for y in ["Ele", "EG", "Photon"] + ): + return self.scaling_thresholds["EG"] + if any("MHT" in x for x in cfg_plot["test_objects"]): + return self.scaling_thresholds["MHT"] + if any("MET" in x for x in cfg_plot["test_objects"]): + return self.scaling_thresholds["MET"] + if any(("HT" in x) and ("MHT" not in x) for x in cfg_plot["test_objects"]): + return self.scaling_thresholds["HT"] + if any("Tau" in x for x in cfg_plot["test_objects"]): + return self.scaling_thresholds["Tau"] + if any("Jet" in x for x in cfg_plot["test_objects"]): + return self.scaling_thresholds["Jet"] + raise RuntimeError("Failed to find thresholds in cfg_scaling_thresholds!") + + def _write_scalings_to_file( + self, obj: Object, params: np.ndarray, plot_name: str + ) -> None: + """Dumps the scaling parameters to a file. + + Writes the offset and slope params of the linear scaling function to + a yaml file for usage in the offline rate computation. + + Retruns: + None + """ + fpath = os.path.join( + "outputs", + obj.version, + "object_performance", + "scalings", + ) + os.makedirs(fpath, exist_ok=True) + a, b = params + + out_path = os.path.join(fpath, str(obj) + ".yaml") + if os.path.exists(out_path): + warnings.warn( + ( + f"A file already exists at the scaling destination `{out_path}`." + f"Will dump the scalings with `{plot_name}` prefix." + ), + UserWarning, + ) + out_path = out_path.replace(str(obj), plot_name + "_" + str(obj)) + with open(out_path, "w") as f: + yaml.dump({"slope": float(a), "offset": float(b)}, f) + + def run(self): + for plot_name, cfg_plot in self.cfg_plots.items(): + plot_config = PerformancePlotConfig(cfg_plot, plot_name) + if not plot_config.compute_scalings: + continue + print(f">>> Scalings {plot_name} <<<") + + scalings = {} + scaling_function_params = {} + + pbar = tqdm(total=len(plot_config.test_object_instances), desc="Objects") + for test_obj in plot_config.test_object_instances: + pbar.write(str(test_obj)) + pbar.update(1) + scalings[str(test_obj)] = {} + thds = self._get_scaling_thresholds(cfg_plot, test_obj) + for threshold in tqdm(thds, leave=False, desc="Thresholds"): + turnon_collection = TurnOnCollection(cfg_plot, threshold) + turnon_collection.create_hists() + scaling_pct = turnon_collection.cfg_plot.scaling_pct + method = turnon_collection.cfg_plot.scaling_method + scaling_collection = ScalingCollection( + cfg_plot, method, scaling_pct + ) + scalings[str(test_obj)][ + threshold + ] = scaling_collection._compute_scalings( + turnon_collection, test_obj, scaling_pct, method + ) + # Fit parameters of scaling function + params = scaling_collection.fit_linear_function(scalings[str(test_obj)]) + scaling_function_params[str(test_obj)] = params + # Write scalings for test_obj to file for usage in rate part + self._write_scalings_to_file(test_obj, params, plot_name) + + plotter = ScalingPlotter( + plot_name, + cfg_plot, + scalings, + scaling_pct, + turnon_collection.version, + scaling_function_params, + ) + plotter.plot() + + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument( + "cfg_plots", + nargs="+", + type=str, + help="Path of YAML configuration file specifying the desired plots.", + ) + args = parser.parse_args() + + for path_cfg_plot in args.cfg_plots: + plotter = EfficiencyCentral(path_cfg_plot) + plotter.run() + + scalings = ScalingCentral(path_cfg_plot) + scalings.run() + + +if __name__ == "__main__": + main() diff --git a/menu_tools/object_performance/scaling_collection.py b/menu_tools/object_performance/scaling_collection.py new file mode 100644 index 00000000..93b4bd13 --- /dev/null +++ b/menu_tools/object_performance/scaling_collection.py @@ -0,0 +1,224 @@ +from scipy.optimize import curve_fit +import numpy as np + +from menu_tools.object_performance.config import PerformancePlotConfig +from menu_tools.object_performance.turnon_collection import TurnOnCollection +from menu_tools.utils import utils +from menu_tools.utils.objects import Object + + +class ScalingCollection: + """ + Collection of scaling values corresponding to one + scaling plot. This requires the input of multiple + turnon_collections, i.e. a single threshold but multiple + objects. + """ + + def __init__( + self, cfg: PerformancePlotConfig, method: str, plateau_pct: float = 0.95 + ): + self.cfg = cfg + self.method = method + self.plateau_pct = plateau_pct + self.scalings: dict[str, dict] = {x: {} for x in self.cfg["test_objects"]} + self.fit_function_params = None + + def _find_percentage_point(self, hist, bins, scaling_pct): + for i, eff in enumerate(hist[:-2]): + is_point = ( + eff < scaling_pct + and hist[i + 1] > scaling_pct + and hist[i + 2] > scaling_pct + ) + if is_point: + return bins[i + 1] + + def _find_turnon_cut(self, graph_x, graph_y, Target) -> float: + L = 0 + R = np.max(graph_x) + + while R - L > 0.0001: + C = (L + R) / 2 + V = self._get_point_on_curve(C, graph_x, graph_y) + + if V < Target: + L = C + else: + R = C + + return (R + L) / 2.0 + + def _find_turnon_fit(self, function, popt, _min, _max, target): + if (function(_min, *popt) > target) | (function(_max, *popt) < target): + return -1000 + + L = _min + R = _max + + while R - L > 0.0001: + C = (L + R) / 2 + V = function(C, *popt) + + if V < target: + L = C + else: + R = C + + return (R + L) / 2 + + @utils.ignore_warnings + def _compute_value_of_tanh_at_threshold(self, efficiency, bins, threshold): + xvals = np.array(bins) + efficiency = np.array(efficiency) + + xvals = xvals[~np.isnan(efficiency)] + efficiency = efficiency[~np.isnan(efficiency)] + + popt, pcov = curve_fit(utils.tanh, xvals, efficiency, p0=[1, 0]) + if np.inf in pcov: + return None + + s_val = utils.arctanh(threshold, *list(popt)) + + return s_val + + @utils.ignore_warnings + def _compute_value_of_errf_at_threshold(self, efficiency, bins, scaling_pct): + xvals = np.array(bins) + efficiency = np.array(efficiency) + + xvals = xvals[~np.isnan(efficiency)] + efficiency = efficiency[~np.isnan(efficiency)] + + popt, pcov = curve_fit( + utils.errf, xvals, efficiency, p0=[0.02, 80, 20, 1, np.min(efficiency)] + ) + + s_val = self._find_turnon_fit( + utils.errf, + popt, + np.min(xvals), + np.max(xvals) * 10, + scaling_pct * utils.errf(10000, *popt), + ) + + return s_val + + def _interpolate(self, H, K1, K2): + A = np.ones(len(K1)) * (-K2) + B = [k1i + 2 * K2 for k1i in K1] + C = np.ones(len(K1)) * (-K2) + D = [] + + A[0] = 0 + C[-1] = 0 + + D = [k1i * h1i for k1i, h1i in zip(K1, H)] + + D[0] = D[0] + K2 * 0 + D[-1] = D[-1] + K2 * 1 + + for i in range(1, len(K1)): + F = A[i] / B[i - 1] + + A[i] = A[i] - B[i - 1] * F + B[i] = B[i] - C[i - 1] * F + C[i] = C[i] + D[i] = D[i] - D[i - 1] * F + + Y = np.ones(len(K1)) + Y[-1] = D[-1] / B[-1] + + for i in reversed(range(len(K1) - 2)): + Y[i] = (D[i] - C[i] * Y[i + 1]) / B[i] + + return Y + + def _get_point_on_curve(self, x, graph_x, graph_y): + if x < graph_x[0]: + return 0 + + if x >= graph_x[len(graph_x) - 1]: + return 1 + + xr = graph_x[0] + yr = graph_y[0] + for i in range(len(graph_x) - 1): + xl = xr + yl = yr + xr = graph_x[i + 1] + yr = graph_y[i + 1] + if (x < xr) & (x >= xl): + return yl + (yr - yl) / (xr - xl) * (x - xl) + + return -1 + + def _compute_scalings_naive( + self, turnon_collection: TurnOnCollection, test_obj: Object, scaling_pct: float + ) -> float: + bins = turnon_collection.bins + bins = 0.5 * (bins[1:] + bins[:-1]) + + efficiency, yerr = turnon_collection.get_efficiency(test_obj) + + xbins = bins + xbins = xbins[~np.isnan(efficiency)] + er_dn = yerr[0] + er_up = yerr[1] + er_dn = er_dn[~np.isnan(efficiency)] + er_up = er_up[~np.isnan(efficiency)] + efficiency = efficiency[~np.isnan(efficiency)] + + K1 = [] + for i in range(len(efficiency)): + K1.append(1 / (er_dn[i] + er_up[i]) / (er_up[i] + er_dn[i])) + + percentage_point = self._find_turnon_cut( + xbins, self._interpolate(efficiency, K1, 100), scaling_pct + ) + return percentage_point + + def _compute_scalings_tanh(self, turnon_collection, test_obj, scaling_pct) -> float: + bins = turnon_collection.bins + bins = 0.5 * (bins[1:] + bins[:-1]) + + efficiency, _ = turnon_collection.get_efficiency(test_obj) + percentage_point = self._compute_value_of_tanh_at_threshold( + efficiency, bins, scaling_pct + ) + return percentage_point + + def _compute_scalings_errf(self, turnon_collection, test_obj, scaling_pct) -> float: + bins = turnon_collection.bins + bins = 0.5 * (bins[1:] + bins[:-1]) + + efficiency, _ = turnon_collection.get_efficiency(test_obj) + percentage_point = self._compute_value_of_errf_at_threshold( + efficiency, bins, scaling_pct + ) + return percentage_point + + def _compute_scalings( + self, + turnon_collection: TurnOnCollection, + test_obj: Object, + scaling_pct: float, + method: str = "tanh", + ) -> float: + if method == "tanh": + return self._compute_scalings_tanh(turnon_collection, test_obj, scaling_pct) + if method == "errf": + return self._compute_scalings_errf(turnon_collection, test_obj, scaling_pct) + if method == "naive": + return self._compute_scalings_naive( + turnon_collection, test_obj, scaling_pct + ) + else: + raise ValueError(f"`{method}` is not a valid scaling method!") + + def fit_linear_function(self, scaling_values: dict[float, float]) -> np.ndarray: + xdata = [th for th, val in scaling_values.items() if val] + ydata = [scaling_values[x] for x in xdata] + popt, pcov = curve_fit(utils.scaling_func, xdata, ydata) + return popt diff --git a/rates/table/lib/__init__.py b/menu_tools/object_performance/tests/__init__.py similarity index 100% rename from rates/table/lib/__init__.py rename to menu_tools/object_performance/tests/__init__.py diff --git a/menu_tools/object_performance/tests/reference_data/ElectronsIsolation_Barrel_-999_V29.json b/menu_tools/object_performance/tests/reference_data/ElectronsIsolation_Barrel_-999_V29.json new file mode 100644 index 00000000..fe51f03f --- /dev/null +++ b/menu_tools/object_performance/tests/reference_data/ElectronsIsolation_Barrel_-999_V29.json @@ -0,0 +1,525 @@ +{ + "xlabel": "Isolation", + "ylabel": "Efficiency (Barrel)", + "watermark": "V29_ElectronsIsolation_Barrel_-999", + "tkElectron:NoIsoLowPt:inclusive": { + "label": "TkElectron, no ID for $p_T<25$", + "efficiency": [ + 0.9455413650661311, + 0.9455413650661311, + 0.9455413650661311, + 0.9456929548641376, + 0.9458445446621443, + 0.9464888013036723, + 0.9474362375412134, + 0.9485731610262629, + 0.9509607003448668, + 0.9538030090574904, + 0.9572895744116421, + 0.9601697805737673, + 0.9636184484784174, + 0.966574449539546, + 0.9691514761056581, + 0.9713874256262554, + 0.9734338878993444, + 0.9752908629249252, + 0.9766930685564862, + 0.9779815818395422, + 0.9798006594156213, + 0.981240762496684, + 0.982415583431235, + 0.9836661992647895, + 0.984575738052829, + 0.9854852768408686, + 0.986091636032895, + 0.9868116875734263, + 0.9878349187099709, + 0.9884791753514989, + 0.9889339447455187, + 0.9893508166900368, + 0.9899192784325614, + 0.9904119452760829, + 0.9907909197710995, + 0.9913214840641225, + 0.9917762534581422, + 0.9922689203016637, + 0.9927994845946868, + 0.9931026641906999, + 0.993746920832228, + 0.9938606131807329, + 0.9942395876757494, + 0.9945048698222609, + 0.9947322545192708, + 0.9950354341152841, + 0.9951870239132906, + 0.9954144086103005, + 0.9955281009588055, + 0.9955659984083072, + 0.9957175882063137, + 0.9959828703528253, + 0.9961723576003335, + 0.9962481524993368, + 0.9963239473983401, + 0.996665024443855, + 0.9967408193428582, + 0.9968166142418615, + 0.9970439989388714, + 0.9971576912873764, + 0.9972334861863796, + 0.9972713836358813, + 0.9974229734338879, + 0.9974987683328912, + 0.9976882555803994, + 0.9978398453784061, + 0.9978777428279076, + 0.9980293326259143, + 0.9981430249744192, + 0.9982188198734225, + 0.9982567173229242, + 0.9983704096714291, + 0.9984462045704324, + 0.9985219994694358, + 0.9986356918179407, + 0.9987872816159472, + 0.9989388714139539, + 0.9989767688634555, + 0.9990525637624588, + 0.9991283586614621, + 0.9992041535604654, + 0.999355743358472, + 0.9994694357069769, + 0.9994694357069769, + 0.9995452306059802, + 0.9995831280554819, + 0.9996589229544852, + 0.9996589229544852, + 0.9996968204039868, + 0.9996968204039868, + 0.9996968204039868, + 0.9997347178534884, + 0.9997347178534884, + 0.9998105127524918, + 0.9998105127524918, + 0.9998863076514951, + 0.9998863076514951, + 0.9999621025504983, + 0.9999621025504983, + 1.0 + ], + "efficiency_err": [ + [ + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0 + ], + [ + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0 + ] + ], + "xbins": [ + 0.0025, + 0.0075, + 0.0125, + 0.0175, + 0.0225, + 0.0275, + 0.0325, + 0.037500000000000006, + 0.042499999999999996, + 0.0475, + 0.052500000000000005, + 0.057499999999999996, + 0.0625, + 0.0675, + 0.07250000000000001, + 0.0775, + 0.0825, + 0.0875, + 0.0925, + 0.0975, + 0.10250000000000001, + 0.1075, + 0.1125, + 0.1175, + 0.1225, + 0.1275, + 0.1325, + 0.1375, + 0.14250000000000002, + 0.1475, + 0.1525, + 0.1575, + 0.1625, + 0.1675, + 0.17250000000000001, + 0.1775, + 0.1825, + 0.1875, + 0.1925, + 0.1975, + 0.2025, + 0.20750000000000002, + 0.2125, + 0.2175, + 0.2225, + 0.2275, + 0.2325, + 0.2375, + 0.2425, + 0.2475, + 0.2525, + 0.2575, + 0.2625, + 0.2675, + 0.2725, + 0.2775, + 0.28250000000000003, + 0.2875, + 0.2925, + 0.2975, + 0.3025, + 0.3075, + 0.3125, + 0.3175, + 0.3225, + 0.3275, + 0.3325, + 0.3375, + 0.3425, + 0.34750000000000003, + 0.35250000000000004, + 0.3575, + 0.3625, + 0.3675, + 0.3725, + 0.3775, + 0.3825, + 0.3875, + 0.3925, + 0.3975, + 0.4025, + 0.40750000000000003, + 0.41250000000000003, + 0.4175, + 0.4225, + 0.4275, + 0.4325, + 0.4375, + 0.4425, + 0.4475, + 0.4525, + 0.4575, + 0.4625, + 0.4675, + 0.47250000000000003, + 0.47750000000000004, + 0.4825, + 0.4875, + 0.4925, + 0.4975 + ], + "err_kwargs": { + "xerr": [ + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0 + ], + "capsize": 3, + "marker": "o", + "markersize": 8 + } + } +} \ No newline at end of file diff --git a/menu_tools/object_performance/tests/reference_data/ElectronsIsolation_Barrel_-999_V29.yaml b/menu_tools/object_performance/tests/reference_data/ElectronsIsolation_Barrel_-999_V29.yaml new file mode 100644 index 00000000..bf6e1ea4 --- /dev/null +++ b/menu_tools/object_performance/tests/reference_data/ElectronsIsolation_Barrel_-999_V29.yaml @@ -0,0 +1,23 @@ +ElectronsIsolation_Barrel: + binning: + max: 0.5 + min: 0 + step: 0.005 + iso_vs_efficiency: true + match_test_to_ref: true + reference_object: + cuts: + event: + - '{dr_0.3} < 0.15' + - abs({eta}) < 1.479 + object: + - abs({eta}) < 1.479 + label: Gen Electrons + object: part_e + x_arg: Pt + sample: DYLL_M50 + test_objects: + tkElectron:NoIsoLowPt: trkiso + version: V29 + xlabel: Isolation + ylabel: Efficiency (Barrel) diff --git a/menu_tools/object_performance/tests/reference_data/HT_50perc_350_V29.json b/menu_tools/object_performance/tests/reference_data/HT_50perc_350_V29.json new file mode 100644 index 00000000..1189c8fb --- /dev/null +++ b/menu_tools/object_performance/tests/reference_data/HT_50perc_350_V29.json @@ -0,0 +1,620 @@ +{ + "xlabel": "Gen. HT (GeV)", + "ylabel": "Trigger Efficiency (350 GeV)", + "watermark": "V29_HT_50perc_350", + "trackerHT:default:inclusive": { + "label": "Tracker HT", + "efficiency": [ + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.00013333333333333334, + 0.0, + 0.0, + 0.0002831657935721365, + 0.00015202189115232594, + 0.00017137960582690659, + 0.0005751533742331289, + 0.0013259668508287293, + 0.0010070493454179255, + 0.0011458034947006588, + 0.0047169811320754715, + 0.0065334358186010764, + 0.009683098591549295, + 0.020813623462630087, + 0.02336448598130841, + 0.048731642189586116, + 0.05747126436781609, + 0.061837455830388695, + 0.09765625, + 0.10372040586245772, + 0.12862547288776796, + 0.1485148514851485, + 0.22085889570552147, + 0.26119402985074625, + 0.23586744639376217, + 0.288135593220339 + ], + "efficiency_err": [ + [ + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.00011008648525952339, + 0.0, + 0.0, + 0.0001823513829141161, + 0.0001255167107782635, + 0.0001414994374845714, + 0.00031192164388792805, + 0.0005236922261730564, + 0.00048009876080158523, + 0.0005462387052469576, + 0.001238184873004851, + 0.0015586180038634307, + 0.002032740516790456, + 0.003086696109909668, + 0.0036299344476051904, + 0.005552239303424154, + 0.006436728922849196, + 0.007156409074103788, + 0.009303555410625802, + 0.010276833295418189, + 0.011961828411951522, + 0.0134836778358714, + 0.016468200979164654, + 0.01932259798778216, + 0.01906225933597891, + 0.022810750520902534 + ], + [ + 0.0046879041451349576, + 0.004073155301754859, + 0.002224231670144308, + 0.0017487856735373052, + 0.0009992720608026564, + 0.0007243644346267765, + 0.0005336709648947606, + 0.00040679589146676575, + 0.00033362631974555594, + 0.0002866581334490885, + 0.0002579314630318181, + 0.0003050696561426725, + 0.00023905576131004127, + 0.00024195956021445879, + 0.00037153169312786834, + 0.0003478188064797919, + 0.0003920958493622838, + 0.0005563888435802931, + 0.0007871342825670361, + 0.0007915796948517353, + 0.0009005340889981848, + 0.0016139392292979912, + 0.001981014480253805, + 0.0025071376227297996, + 0.003570982617458661, + 0.004226832816821902, + 0.006186050147179441, + 0.007149778995645256, + 0.007971980522778178, + 0.01012428693723158, + 0.011212116822432228, + 0.012940250496853822, + 0.014522080708850332, + 0.01735752730139206, + 0.020249609977856187, + 0.02013640533025912, + 0.02388299640520314 + ] + ], + "xbins": [ + 10.0, + 30.0, + 50.0, + 70.0, + 90.0, + 110.0, + 130.0, + 150.0, + 170.0, + 190.0, + 210.0, + 230.0, + 250.0, + 270.0, + 290.0, + 310.0, + 330.0, + 350.0, + 370.0, + 390.0, + 410.0, + 430.0, + 450.0, + 470.0, + 490.0, + 510.0, + 530.0, + 550.0, + 570.0, + 590.0, + 610.0, + 630.0, + 650.0, + 670.0, + 690.0, + 710.0, + 730.0 + ], + "err_kwargs": { + "xerr": [ + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0 + ], + "capsize": 3, + "marker": "o", + "markersize": 8 + } + }, + "phase1PuppiHT:default:inclusive": { + "label": "Histogrammed Puppi HT", + "efficiency": [ + 0.0, + 0.0022271714922048997, + 0.002430133657351154, + 0.0009551098376313276, + 0.0016366612111292963, + 0.0019770660340055358, + 0.0029129041654529565, + 0.005772646536412078, + 0.008011653313911144, + 0.0172090112640801, + 0.029842342342342343, + 0.06066666666666667, + 0.09575994781474234, + 0.1526475637131916, + 0.21959507291519184, + 0.31529340224992397, + 0.4281062553556127, + 0.5433282208588958, + 0.6651933701657459, + 0.7595669687814703, + 0.8427384703523346, + 0.8800539083557951, + 0.9362029208301307, + 0.9617077464788732, + 0.9744560075685903, + 0.9853971962616822, + 0.985981308411215, + 0.9846743295019157, + 0.9973498233215548, + 1.0, + 0.9977452085682075, + 1.0, + 1.0, + 1.0, + 0.9981343283582089, + 0.9980506822612085, + 0.9975786924939467 + ], + "efficiency_err": [ + [ + 0.0, + 0.0018389319832569585, + 0.0015648087797643124, + 0.0007885970671355072, + 0.0008875236458577121, + 0.0008503624538187063, + 0.0009009377552959101, + 0.001117258583657704, + 0.0011937195600976802, + 0.0016182739735769065, + 0.0020105396509121944, + 0.0027485350801974145, + 0.003354359186525241, + 0.004129541396414388, + 0.0049290698539978806, + 0.005744412295983381, + 0.006514426960063269, + 0.006962391845237836, + 0.007123242155422038, + 0.006934412945263868, + 0.006369835376131561, + 0.006229648041136793, + 0.005130677874428113, + 0.00443887806185439, + 0.0038909454852842362, + 0.003492967407424552, + 0.003721998685895622, + 0.004186612456707484, + 0.0025584787506947038, + 0.0017880299021929558, + 0.002951688848833567, + 0.0023082794376581006, + 0.0025886965210667467, + 0.0028067614256136464, + 0.004256551066554315, + 0.004446778399965989, + 0.005519190778433658 + ], + [ + 0.0046879041451349576, + 0.005078294715424368, + 0.0031805789145277334, + 0.0021823611280588733, + 0.001581610553844316, + 0.0013285594214324592, + 0.0012339867559877774, + 0.0013565887776518116, + 0.0013850621382176243, + 0.0017754451527456604, + 0.0021465129005511577, + 0.0028676381984171703, + 0.003461087503886115, + 0.004222050485594181, + 0.005009014088096453, + 0.005800893257580153, + 0.006539209238764998, + 0.0069456729954276986, + 0.007049632644374859, + 0.006802284247529711, + 0.0061704198638199426, + 0.005968287652665327, + 0.004784555424000914, + 0.004013419733016055, + 0.0034146848995719736, + 0.0028733743898573527, + 0.003007174042333638, + 0.0033662712202982004, + 0.0014370010235984498, + 0.0, + 0.0014519127770952212, + 0.0, + 0.0, + 0.0, + 0.0015404383715550418, + 0.001609505337728745, + 0.0019992334393843514 + ] + ], + "xbins": [ + 10.0, + 30.0, + 50.0, + 70.0, + 90.0, + 110.0, + 130.0, + 150.0, + 170.0, + 190.0, + 210.0, + 230.0, + 250.0, + 270.0, + 290.0, + 310.0, + 330.0, + 350.0, + 370.0, + 390.0, + 410.0, + 430.0, + 450.0, + 470.0, + 490.0, + 510.0, + 530.0, + 550.0, + 570.0, + 590.0, + 610.0, + 630.0, + 650.0, + 670.0, + 690.0, + 710.0, + 730.0 + ], + "err_kwargs": { + "xerr": [ + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0 + ], + "capsize": 3, + "marker": "o", + "markersize": 8 + } + }, + "seededConePuppiHT:default:inclusive": { + "label": "SeededCone HT", + "efficiency": [ + 0.0, + 0.0022271714922048997, + 0.002430133657351154, + 0.0009551098376313276, + 0.0005455537370430987, + 0.0019770660340055358, + 0.0037867754150888435, + 0.005772646536412078, + 0.010742898761835398, + 0.01955569461827284, + 0.03420608108108108, + 0.0672, + 0.10437051532941943, + 0.16255116862537963, + 0.23148803624522157, + 0.3339920948616601, + 0.4481576692373608, + 0.5648006134969326, + 0.6846408839779006, + 0.7779456193353474, + 0.8607848753938699, + 0.8982479784366577, + 0.9465795541890853, + 0.9691901408450704, + 0.9796594134342479, + 0.9877336448598131, + 0.9919893190921228, + 0.9877394636015325, + 0.9964664310954063, + 1.0, + 0.9988726042841037, + 1.0, + 1.0, + 1.0, + 1.0, + 1.0, + 1.0 + ], + "efficiency_err": [ + [ + 0.0, + 0.0018389319832569585, + 0.0015648087797643124, + 0.0007885970671355072, + 0.0004504391188022924, + 0.0008503624538187063, + 0.0010308807980181803, + 0.001117258583657704, + 0.0013819069127093287, + 0.0017234954877210357, + 0.0021481838905352754, + 0.0028832249924839876, + 0.0034858887659411225, + 0.004237227675487343, + 0.005023187390551687, + 0.005833142665312374, + 0.00655043422376117, + 0.006934376650048257, + 0.007020225149216741, + 0.006754273421534895, + 0.006074460092601042, + 0.00582430916443577, + 0.0047551672768813, + 0.004045688680966553, + 0.0035369437733976383, + 0.0032604119472066095, + 0.0030115358616300547, + 0.0038435540182472083, + 0.0027712486786956037, + 0.0017880299021929558, + 0.002575292661612605, + 0.0023082794376581006, + 0.0025886965210667467, + 0.0028067614256136464, + 0.0034131571592493914, + 0.003565910541162176, + 0.004427413234551869 + ], + [ + 0.0046879041451349576, + 0.005078294715424368, + 0.0031805789145277334, + 0.0021823611280588733, + 0.001247393278627939, + 0.0013285594214324592, + 0.0013577907768089897, + 0.0013565887776518116, + 0.0015703676556506358, + 0.0018794641871793562, + 0.0022826039655549704, + 0.00300042747386578, + 0.003590268761640189, + 0.004327063398556902, + 0.005099720754426218, + 0.0058838958976762945, + 0.006568303462218095, + 0.00690937073223985, + 0.006937929890030614, + 0.006612716368271099, + 0.005864297382878636, + 0.005549872504061137, + 0.004399618977669162, + 0.0036108457836996344, + 0.003051788994082316, + 0.0026327050815019293, + 0.002265023346719186, + 0.003008289686007304, + 0.0016840561707416324, + 0.0, + 0.0009308497718625297, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0 + ] + ], + "xbins": [ + 10.0, + 30.0, + 50.0, + 70.0, + 90.0, + 110.0, + 130.0, + 150.0, + 170.0, + 190.0, + 210.0, + 230.0, + 250.0, + 270.0, + 290.0, + 310.0, + 330.0, + 350.0, + 370.0, + 390.0, + 410.0, + 430.0, + 450.0, + 470.0, + 490.0, + 510.0, + 530.0, + 550.0, + 570.0, + 590.0, + 610.0, + 630.0, + 650.0, + 670.0, + 690.0, + 710.0, + 730.0 + ], + "err_kwargs": { + "xerr": [ + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0 + ], + "capsize": 3, + "marker": "o", + "markersize": 8 + } + } +} diff --git a/menu_tools/object_performance/tests/reference_data/HT_50perc_350_V29.yaml b/menu_tools/object_performance/tests/reference_data/HT_50perc_350_V29.yaml new file mode 100644 index 00000000..224160bf --- /dev/null +++ b/menu_tools/object_performance/tests/reference_data/HT_50perc_350_V29.yaml @@ -0,0 +1,27 @@ +HT_50perc: + binning: + max: 750 + min: 0 + step: 20 + version: V29 + reference_object: + cuts: + object: + - abs({eta}) < 2.4 + - '{pt} > 30' + label: Gen HT + object: jet + x_arg: Pt + trafo: HT + sample: TT + scalings: + method: naive + threshold: 0.5 + test_objects: + phase1PuppiHT:default: "" + seededConePuppiHT:default: "" + trackerHT:default: "" + thresholds: + - 350 + xlabel: Gen. HT (GeV) + ylabel: Trigger Efficiency ( GeV) diff --git a/menu_tools/object_performance/tests/reference_data/HT_90perc_350_V29.json b/menu_tools/object_performance/tests/reference_data/HT_90perc_350_V29.json new file mode 100644 index 00000000..136fafdb --- /dev/null +++ b/menu_tools/object_performance/tests/reference_data/HT_90perc_350_V29.json @@ -0,0 +1,620 @@ +{ + "xlabel": "Gen. HT (GeV)", + "ylabel": "Trigger Efficiency (350 GeV)", + "watermark": "V29_HT_90perc_350", + "trackerHT:default:inclusive": { + "label": "Tracker HT", + "efficiency": [ + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.00013333333333333334, + 0.0, + 0.0, + 0.0002831657935721365, + 0.00015202189115232594, + 0.00017137960582690659, + 0.0005751533742331289, + 0.0013259668508287293, + 0.0010070493454179255, + 0.0011458034947006588, + 0.0047169811320754715, + 0.0065334358186010764, + 0.009683098591549295, + 0.020813623462630087, + 0.02336448598130841, + 0.048731642189586116, + 0.05747126436781609, + 0.061837455830388695, + 0.09765625, + 0.10372040586245772, + 0.12862547288776796, + 0.1485148514851485, + 0.22085889570552147, + 0.26119402985074625, + 0.23586744639376217, + 0.288135593220339 + ], + "efficiency_err": [ + [ + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.00011008648525952339, + 0.0, + 0.0, + 0.0001823513829141161, + 0.0001255167107782635, + 0.0001414994374845714, + 0.00031192164388792805, + 0.0005236922261730564, + 0.00048009876080158523, + 0.0005462387052469576, + 0.001238184873004851, + 0.0015586180038634307, + 0.002032740516790456, + 0.003086696109909668, + 0.0036299344476051904, + 0.005552239303424154, + 0.006436728922849196, + 0.007156409074103788, + 0.009303555410625802, + 0.010276833295418189, + 0.011961828411951522, + 0.0134836778358714, + 0.016468200979164654, + 0.01932259798778216, + 0.01906225933597891, + 0.022810750520902534 + ], + [ + 0.0046879041451349576, + 0.004073155301754859, + 0.002224231670144308, + 0.0017487856735373052, + 0.0009992720608026564, + 0.0007243644346267765, + 0.0005336709648947606, + 0.00040679589146676575, + 0.00033362631974555594, + 0.0002866581334490885, + 0.0002579314630318181, + 0.0003050696561426725, + 0.00023905576131004127, + 0.00024195956021445879, + 0.00037153169312786834, + 0.0003478188064797919, + 0.0003920958493622838, + 0.0005563888435802931, + 0.0007871342825670361, + 0.0007915796948517353, + 0.0009005340889981848, + 0.0016139392292979912, + 0.001981014480253805, + 0.0025071376227297996, + 0.003570982617458661, + 0.004226832816821902, + 0.006186050147179441, + 0.007149778995645256, + 0.007971980522778178, + 0.01012428693723158, + 0.011212116822432228, + 0.012940250496853822, + 0.014522080708850332, + 0.01735752730139206, + 0.020249609977856187, + 0.02013640533025912, + 0.02388299640520314 + ] + ], + "xbins": [ + 10.0, + 30.0, + 50.0, + 70.0, + 90.0, + 110.0, + 130.0, + 150.0, + 170.0, + 190.0, + 210.0, + 230.0, + 250.0, + 270.0, + 290.0, + 310.0, + 330.0, + 350.0, + 370.0, + 390.0, + 410.0, + 430.0, + 450.0, + 470.0, + 490.0, + 510.0, + 530.0, + 550.0, + 570.0, + 590.0, + 610.0, + 630.0, + 650.0, + 670.0, + 690.0, + 710.0, + 730.0 + ], + "err_kwargs": { + "xerr": [ + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0 + ], + "capsize": 3, + "marker": "o", + "markersize": 8 + } + }, + "phase1PuppiHT:default:inclusive": { + "label": "Histogrammed Puppi HT", + "efficiency": [ + 0.0, + 0.0022271714922048997, + 0.002430133657351154, + 0.0009551098376313276, + 0.0016366612111292963, + 0.0019770660340055358, + 0.0029129041654529565, + 0.005772646536412078, + 0.008011653313911144, + 0.0172090112640801, + 0.029842342342342343, + 0.06066666666666667, + 0.09575994781474234, + 0.1526475637131916, + 0.21959507291519184, + 0.31529340224992397, + 0.4281062553556127, + 0.5433282208588958, + 0.6651933701657459, + 0.7595669687814703, + 0.8427384703523346, + 0.8800539083557951, + 0.9362029208301307, + 0.9617077464788732, + 0.9744560075685903, + 0.9853971962616822, + 0.985981308411215, + 0.9846743295019157, + 0.9973498233215548, + 1.0, + 0.9977452085682075, + 1.0, + 1.0, + 1.0, + 0.9981343283582089, + 0.9980506822612085, + 0.9975786924939467 + ], + "efficiency_err": [ + [ + 0.0, + 0.0018389319832569585, + 0.0015648087797643124, + 0.0007885970671355072, + 0.0008875236458577121, + 0.0008503624538187063, + 0.0009009377552959101, + 0.001117258583657704, + 0.0011937195600976802, + 0.0016182739735769065, + 0.0020105396509121944, + 0.0027485350801974145, + 0.003354359186525241, + 0.004129541396414388, + 0.0049290698539978806, + 0.005744412295983381, + 0.006514426960063269, + 0.006962391845237836, + 0.007123242155422038, + 0.006934412945263868, + 0.006369835376131561, + 0.006229648041136793, + 0.005130677874428113, + 0.00443887806185439, + 0.0038909454852842362, + 0.003492967407424552, + 0.003721998685895622, + 0.004186612456707484, + 0.0025584787506947038, + 0.0017880299021929558, + 0.002951688848833567, + 0.0023082794376581006, + 0.0025886965210667467, + 0.0028067614256136464, + 0.004256551066554315, + 0.004446778399965989, + 0.005519190778433658 + ], + [ + 0.0046879041451349576, + 0.005078294715424368, + 0.0031805789145277334, + 0.0021823611280588733, + 0.001581610553844316, + 0.0013285594214324592, + 0.0012339867559877774, + 0.0013565887776518116, + 0.0013850621382176243, + 0.0017754451527456604, + 0.0021465129005511577, + 0.0028676381984171703, + 0.003461087503886115, + 0.004222050485594181, + 0.005009014088096453, + 0.005800893257580153, + 0.006539209238764998, + 0.0069456729954276986, + 0.007049632644374859, + 0.006802284247529711, + 0.0061704198638199426, + 0.005968287652665327, + 0.004784555424000914, + 0.004013419733016055, + 0.0034146848995719736, + 0.0028733743898573527, + 0.003007174042333638, + 0.0033662712202982004, + 0.0014370010235984498, + 0.0, + 0.0014519127770952212, + 0.0, + 0.0, + 0.0, + 0.0015404383715550418, + 0.001609505337728745, + 0.0019992334393843514 + ] + ], + "xbins": [ + 10.0, + 30.0, + 50.0, + 70.0, + 90.0, + 110.0, + 130.0, + 150.0, + 170.0, + 190.0, + 210.0, + 230.0, + 250.0, + 270.0, + 290.0, + 310.0, + 330.0, + 350.0, + 370.0, + 390.0, + 410.0, + 430.0, + 450.0, + 470.0, + 490.0, + 510.0, + 530.0, + 550.0, + 570.0, + 590.0, + 610.0, + 630.0, + 650.0, + 670.0, + 690.0, + 710.0, + 730.0 + ], + "err_kwargs": { + "xerr": [ + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0 + ], + "capsize": 3, + "marker": "o", + "markersize": 8 + } + }, + "seededConePuppiHT:default:inclusive": { + "label": "SeededCone HT", + "efficiency": [ + 0.0, + 0.0022271714922048997, + 0.002430133657351154, + 0.0009551098376313276, + 0.0005455537370430987, + 0.0019770660340055358, + 0.0037867754150888435, + 0.005772646536412078, + 0.010742898761835398, + 0.01955569461827284, + 0.03420608108108108, + 0.0672, + 0.10437051532941943, + 0.16255116862537963, + 0.23148803624522157, + 0.3339920948616601, + 0.4481576692373608, + 0.5648006134969326, + 0.6846408839779006, + 0.7779456193353474, + 0.8607848753938699, + 0.8982479784366577, + 0.9465795541890853, + 0.9691901408450704, + 0.9796594134342479, + 0.9877336448598131, + 0.9919893190921228, + 0.9877394636015325, + 0.9964664310954063, + 1.0, + 0.9988726042841037, + 1.0, + 1.0, + 1.0, + 1.0, + 1.0, + 1.0 + ], + "efficiency_err": [ + [ + 0.0, + 0.0018389319832569585, + 0.0015648087797643124, + 0.0007885970671355072, + 0.0004504391188022924, + 0.0008503624538187063, + 0.0010308807980181803, + 0.001117258583657704, + 0.0013819069127093287, + 0.0017234954877210357, + 0.0021481838905352754, + 0.0028832249924839876, + 0.0034858887659411225, + 0.004237227675487343, + 0.005023187390551687, + 0.005833142665312374, + 0.00655043422376117, + 0.006934376650048257, + 0.007020225149216741, + 0.006754273421534895, + 0.006074460092601042, + 0.00582430916443577, + 0.0047551672768813, + 0.004045688680966553, + 0.0035369437733976383, + 0.0032604119472066095, + 0.0030115358616300547, + 0.0038435540182472083, + 0.0027712486786956037, + 0.0017880299021929558, + 0.002575292661612605, + 0.0023082794376581006, + 0.0025886965210667467, + 0.0028067614256136464, + 0.0034131571592493914, + 0.003565910541162176, + 0.004427413234551869 + ], + [ + 0.0046879041451349576, + 0.005078294715424368, + 0.0031805789145277334, + 0.0021823611280588733, + 0.001247393278627939, + 0.0013285594214324592, + 0.0013577907768089897, + 0.0013565887776518116, + 0.0015703676556506358, + 0.0018794641871793562, + 0.0022826039655549704, + 0.00300042747386578, + 0.003590268761640189, + 0.004327063398556902, + 0.005099720754426218, + 0.0058838958976762945, + 0.006568303462218095, + 0.00690937073223985, + 0.006937929890030614, + 0.006612716368271099, + 0.005864297382878636, + 0.005549872504061137, + 0.004399618977669162, + 0.0036108457836996344, + 0.003051788994082316, + 0.0026327050815019293, + 0.002265023346719186, + 0.003008289686007304, + 0.0016840561707416324, + 0.0, + 0.0009308497718625297, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0, + 0.0 + ] + ], + "xbins": [ + 10.0, + 30.0, + 50.0, + 70.0, + 90.0, + 110.0, + 130.0, + 150.0, + 170.0, + 190.0, + 210.0, + 230.0, + 250.0, + 270.0, + 290.0, + 310.0, + 330.0, + 350.0, + 370.0, + 390.0, + 410.0, + 430.0, + 450.0, + 470.0, + 490.0, + 510.0, + 530.0, + 550.0, + 570.0, + 590.0, + 610.0, + 630.0, + 650.0, + 670.0, + 690.0, + 710.0, + 730.0 + ], + "err_kwargs": { + "xerr": [ + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0, + 10.0 + ], + "capsize": 3, + "marker": "o", + "markersize": 8 + } + } +} diff --git a/menu_tools/object_performance/tests/reference_data/HT_90perc_350_V29.yaml b/menu_tools/object_performance/tests/reference_data/HT_90perc_350_V29.yaml new file mode 100644 index 00000000..969165bf --- /dev/null +++ b/menu_tools/object_performance/tests/reference_data/HT_90perc_350_V29.yaml @@ -0,0 +1,27 @@ +HT_90perc: + binning: + max: 750 + min: 0 + step: 20 + version: V29 + reference_object: + cuts: + object: + - abs({eta}) < 2.4 + - '{pt} > 30' + label: Gen HT + object: jet + x_arg: Pt + trafo: HT + sample: TT + scalings: + method: naive + threshold: 0.9 + test_objects: + phase1PuppiHT:default: "" + seededConePuppiHT:default: "" + trackerHT:default: "" + thresholds: + - 350 + xlabel: Gen. HT (GeV) + ylabel: Trigger Efficiency ( GeV) diff --git a/menu_tools/object_performance/tests/test_turnons_v29.py b/menu_tools/object_performance/tests/test_turnons_v29.py new file mode 100644 index 00000000..9bea1fea --- /dev/null +++ b/menu_tools/object_performance/tests/test_turnons_v29.py @@ -0,0 +1,55 @@ +""" +These tests check if V29 electron object performance plots can be reproduced. +""" +import json +from unittest.mock import patch +import sys + +import numpy as np +import pytest + +from menu_tools.object_performance import plotter + + +testdata = [ + "HT_50perc_350_V29", + "HT_90perc_350_V29", + "ElectronsIsolation_Barrel_-999_V29", +] + + +@pytest.mark.parametrize("test_name", testdata) +def test_matching_plots_reproduced(test_name): + # Prepare patching of the command line arguments for argparse + testargs = [ + "foo", + f"menu_tools/object_performance/tests/reference_data/{test_name}.yaml", + ] + + # Run Plotting + with patch.object(sys, "argv", testargs): + plotter.main() + + # Load result and assert correct outcome + with open( + f"outputs/V29/object_performance/turnons/{test_name}.json", + "r", + ) as f: + test_result = json.load(f) + with open( + f"menu_tools/object_performance/tests/reference_data/{test_name}.json", + "r", + ) as f: + reference_data = json.load(f) + + for key, val in reference_data.items(): + if isinstance(val, dict): + efficiencies_test = np.array( + test_result[key]["efficiency"], dtype=np.float64 + ) + efficiencies_reference = np.array(val["efficiency"], dtype=np.float64) + print(efficiencies_reference) + differences = efficiencies_test - efficiencies_reference + assert not np.any(abs(differences) > 1e-4) + else: + assert val == test_result[key] diff --git a/objectPerformance/src/turnon_collection.py b/menu_tools/object_performance/turnon_collection.py similarity index 50% rename from objectPerformance/src/turnon_collection.py rename to menu_tools/object_performance/turnon_collection.py index 4741e37f..50e13556 100644 --- a/objectPerformance/src/turnon_collection.py +++ b/menu_tools/object_performance/turnon_collection.py @@ -1,21 +1,22 @@ +from typing import Any, Optional import re import awkward as ak import numpy as np import vector -from plot_config import PlotConfig -from quality_obj import Quality, L1IsoCut -import utils +from menu_tools.object_performance.config import PerformancePlotConfig +from menu_tools.utils import utils +from menu_tools.utils.objects import Object vector.register_awkward() -class ArrayLoader(): - - def __init__(self, turnon_collection): +class ArrayLoader: + def __init__(self, turnon_collection, cfg_plot: PerformancePlotConfig): self.turnon_collection = turnon_collection + self.cfg_plot = cfg_plot def _transform_key(self, raw_key: str, obj: str): """ @@ -29,18 +30,6 @@ def _transform_key(self, raw_key: str, obj: str): else: return key - def _map_region(self, test_array, obj: str): - """ - This method serves to map a 'region' branch - to the correct eta region in the detector. - Needed from V25 after the barrel and endcap - collections have been merged. - """ - if 'hgc' in test_array.fields: - test_array["region"] = (ak.where(abs(test_array["eta"]) > 1.479, 1, 0)) - - return test_array - def _load_array_from_parquet(self, obj: str): """ Loads the specified parquet file @@ -49,45 +38,37 @@ def _load_array_from_parquet(self, obj: str): in self._transform_key(). """ fname = ( - f"cache/{self.turnon_collection.cfg_plot.version_ref_object}/" - f"{self.turnon_collection.cfg_plot.version_ref_object}_" - f"{self.turnon_collection.cfg_plot.sample}_" + f"cache/{self.cfg_plot.version}/" + f"{self.cfg_plot.version}_" + f"{self.cfg_plot.sample}_" f"{obj}.parquet" ) array = ak.from_parquet(fname) - array_dict = { - self._transform_key(key, obj): array[key] - for key in array.fields - } - if self.turnon_collection.cfg_plot.reference_trafo: + array_dict = {self._transform_key(key, obj): array[key] for key in array.fields} + if self.cfg_plot.reference_trafo: array = ak.Array(array_dict) else: array = ak.zip(array_dict) return array - def _load_ref_branches(self): + def _load_ref_branches(self) -> None: """ Load reference object. """ - ref_array = self._load_array_from_parquet( - self.turnon_collection.cfg_plot.reference_object - ) + ref_array = self._load_array_from_parquet(self.cfg_plot.reference_object) ref_array = ak.with_name(ref_array, "Momentum4D") self.turnon_collection.ak_arrays["ref"] = ref_array - def _load_test_branches(self): + def _load_test_branches(self) -> None: """ Load test objects. """ - test_objects = self.turnon_collection.cfg_plot.test_objects - for test_obj, obj_cfg in test_objects.items(): - obj_name = self.turnon_collection.cfg_plot.get_base_obj(test_obj) - test_array = self._load_array_from_parquet(obj_name) + for obj in self.cfg_plot.test_object_instances: + test_array = self._load_array_from_parquet(obj.nano_obj_name) test_array = ak.with_name(test_array, "Momentum4D") - test_array = self._map_region(test_array, test_obj) - self.turnon_collection.ak_arrays[test_obj] = test_array + self.turnon_collection.ak_arrays[str(obj)] = test_array - def load_arrays(self): + def load_arrays(self) -> None: """ Load ak arrays from cache (parquet) files. """ @@ -95,18 +76,35 @@ def load_arrays(self): self._load_test_branches() -class TurnOnCollection(): - - def __init__(self, cfg_plot, threshold): - self.cfg_plot = PlotConfig(cfg_plot) - self.version = self.cfg_plot.version_ref_object +class TurnOnCollection: + def __init__( + self, cfg_plot: dict, threshold: float, plot_name: Optional[str] = None + ): + self.cfg_plot = PerformancePlotConfig(cfg_plot, plot_name) + self.version = self.cfg_plot.version self.threshold = threshold - self.ak_arrays = {} - self.numerators = {"ref": {}, "test": {}} - self.hists = {"ref": {}} + self.ak_arrays: dict[str, Any] = {} + self.numerators: dict[str, Any] = {"ref": {}, "test": {}} + self.hists: dict[str, Any] = {"ref": {}} @property - def bins(self): + def test_objects(self) -> list[tuple[Object, str]]: + """Instantiates all test objects. + + Returns: + obj_args: list containig tuples of test objects and their x_args. + """ + obj_args = [] + + test_objects = self.cfg_plot.test_objects + for obj_key, x_arg in test_objects.items(): + obj = Object(obj_key, self.cfg_plot.version) + obj_args.append((obj, x_arg.lower())) + + return obj_args + + @property + def bins(self) -> np.ndarray: """ Set bins according to configuration. """ @@ -115,11 +113,11 @@ def bins(self): xmin = self.cfg_plot.bin_min return np.arange(xmin, xmax, bin_width) - def _load_arrays(self): + def _load_arrays(self) -> None: """ Load ak arrays from cache (parquet) files. """ - loader = ArrayLoader(self) + loader = ArrayLoader(self, self.cfg_plot) loader.load_arrays() def _match_test_to_ref(self): @@ -128,22 +126,23 @@ def _match_test_to_ref(self): to reference objects. Selects highest pT deltaR-matched reco lepton. """ - for test_obj, obj_cfg in self.cfg_plot.test_objects.items(): - suffix = obj_cfg["suffix"].lower() + for test_obj, x_arg in self.test_objects: ref_test = ak.cartesian( - {"ref": self.ak_arrays["ref"], - "test": self.ak_arrays[test_obj]}, - nested=True + {"ref": self.ak_arrays["ref"], "test": self.ak_arrays[str(test_obj)]}, + nested=True, ) js, gs = ak.unzip(ref_test) dR = gs.deltaR(js) - pass_dR = dR < self.cfg_plot.get_match_dR(test_obj) - pt_max = ak.argmax(ref_test["test"]["pt"][pass_dR], axis=-1, - keepdims=True) - if ("iso" not in suffix): - self.numerators["ref"][test_obj] = ref_test["ref"][suffix][pass_dR][pt_max][:, :, 0] # noqa - self.numerators["test"][test_obj] = ref_test["test"][suffix][pass_dR][pt_max][:, :, 0] # noqa + pass_dR = dR < test_obj.match_dR + pt_max = ak.argmax(ref_test["test"]["pt"][pass_dR], axis=-1, keepdims=True) + if "iso" not in x_arg: + self.numerators["ref"][str(test_obj)] = ref_test["ref"][x_arg][pass_dR][ + pt_max + ][:, :, 0] + self.numerators["test"][str(test_obj)] = ref_test["test"][x_arg][pass_dR][ + pt_max + ][:, :, 0] def _flatten_array(self, ak_array, ak_to_np=False): """ @@ -170,8 +169,8 @@ def _compute_MHT(self): _px = self.ak_arrays["ref"].px _py = self.ak_arrays["ref"].py _mht = np.sqrt( - ak.sum(_px[:, :], axis=-1, keepdims=True)**2 - + ak.sum(_py[:, :], axis=-1, keepdims=True)**2 + ak.sum(_px[:, :], axis=-1, keepdims=True) ** 2 + + ak.sum(_py[:, :], axis=-1, keepdims=True) ** 2 ) return _mht @@ -182,12 +181,10 @@ def _reduce_to_per_event(self): for some of which one number per event is stored in the branches and for some of which one number per jet is stored. """ - for test_obj, cfg in self.cfg_plot.test_objects.items(): - field = cfg["suffix"].lower() + for test_obj, x_arg in self.test_objects: try: - self.ak_arrays[test_obj][field] = ak.max( - self.ak_arrays[test_obj][field], - axis=1 + self.ak_arrays[str(test_obj)][x_arg] = ak.max( + self.ak_arrays[str(test_obj)][x_arg], axis=1 ) except ValueError: pass @@ -202,10 +199,7 @@ def _apply_reference_trafo(self): return if trafo == "HT": - self.ak_arrays["ref"]["HT"] = ak.sum( - self.ak_arrays["ref"]["pt"], - axis=-1 - ) + self.ak_arrays["ref"]["HT"] = ak.sum(self.ak_arrays["ref"]["pt"], axis=-1) if trafo == "MHT": gen_mht = self._compute_MHT() @@ -214,42 +208,6 @@ def _apply_reference_trafo(self): if trafo: self._reduce_to_per_event() - def _apply_quality_cuts(self): - """ - Function to implement quality criteria. - Events not fulfilling L1 hardware quality - criteria are filtered out. - """ - for test_obj in self.cfg_plot.test_objects: - if not (quality_id := self.cfg_plot.get_quality_id(test_obj)): - return - - ## force quality bit to be int! - self.ak_arrays[test_obj]["quality"] = ak.values_astype(self.ak_arrays[test_obj]["quality"], np.int32) - - quality = Quality(self.ak_arrays, test_obj) - sel = ~getattr(quality, quality_id) - self.ak_arrays[test_obj] = self.ak_arrays[test_obj][sel] - - def _apply_L1_isolation_cuts(self): - """ - Function to implement isolation criteria. - Events not fulfilling L1 Iso EE/BB quality - criteria are filtered out. - """ - for test_obj in self.cfg_plot.test_objects: - iso_BB = self.cfg_plot.get_iso_BB(test_obj) - iso_EE = self.cfg_plot.get_iso_EE(test_obj) - l1_iso = self.cfg_plot.get_l1_iso(test_obj) - - if ((iso_BB == -1) & (iso_EE == -1)): - continue - - isolation = L1IsoCut(self.ak_arrays, test_obj, - iso_BB, iso_EE, l1_iso) - sel = ~getattr(isolation, "ISO_EEBB") - self.ak_arrays[test_obj] = self.ak_arrays[test_obj][sel] - def _select_highest_pt_ref_object(self): """ The raw cached arrays of the reference still contain @@ -262,67 +220,77 @@ def _select_highest_pt_ref_object(self): def _apply_list_of_reference_cuts(self, cut_list): for cut in cut_list: - cut = re.sub(r"{([^&|]*)}", - r"self.ak_arrays['ref']['\1']", - cut) + cut = re.sub(r"{([^&|]*)}", r"self.ak_arrays['ref']['\1']", cut) sel = eval(cut) self.ak_arrays["ref"] = self.ak_arrays["ref"][sel] + if not isinstance( + self.ak_arrays["ref"], vector.backends.awkward.MomentumArray4D + ): + self.ak_arrays["ref"] = ak.with_name(self.ak_arrays["ref"], "Momentum4D") - def _apply_reference_cuts(self): - """ - Applies configured cuts on reference objects. Should be - applied before any matching and before the selection of - the highest pT object. - """ - if self.cfg_plot.reference_trafo: - ref_object_cuts = self.cfg_plot.reference_object_cuts - ref_event_cuts = self.cfg_plot.reference_event_cuts + def _apply_reference_cuts(self) -> None: + """Applies configured cuts on reference objects. - self._apply_list_of_reference_cuts(ref_object_cuts) - return + Should be applied before any matching and before the + selection of the highest pT object. + """ if "met" in self.cfg_plot.reference_object.lower(): # TODO: Maybe we want to modify it and allow possible cuts on MET return ref_object_cuts = self.cfg_plot.reference_object_cuts - ref_event_cuts = self.cfg_plot.reference_event_cuts - self._apply_list_of_reference_cuts(ref_object_cuts) + + if self.cfg_plot.reference_trafo: + # In this case each event is reduced to a single value already + return None + self._select_highest_pt_ref_object() + ref_event_cuts = self.cfg_plot.reference_event_cuts self._apply_list_of_reference_cuts(ref_event_cuts) def _apply_test_obj_cuts(self): - """ - Applies configured cuts on all configured - test objects. + """Applies configured cuts on all configured test objects. + Should be applied before any matching. """ - for test_obj in self.cfg_plot.test_objects: - if not (cuts := self.cfg_plot.get_object_cuts(test_obj)): + for test_obj, _ in self.test_objects: + if not test_obj.cuts: continue - for cut in cuts: - cut = re.sub(r"{([^&|]*)}", - r"self.ak_arrays[test_obj]['\1']", - cut) - sel = eval(cut) - self.ak_arrays[test_obj] = self.ak_arrays[test_obj][sel] - - def _skim_to_hists(self): + for ( + range_i, + range_cuts, + ) in test_obj.cuts.items(): # TODO: use the version from utils + for cut in range_cuts: + cut = re.sub( + r"{([^&|]*)}", r"self.ak_arrays[str(test_obj)]['\1']", cut + ) + eta_sel = ( + abs(self.ak_arrays[str(test_obj)]["eta"]) + > test_obj.eta_ranges[range_i][0] + ) & ( + abs(self.ak_arrays[str(test_obj)]["eta"]) + < test_obj.eta_ranges[range_i][1] + ) + + sel = eval(cut) + ~eta_sel + self.ak_arrays[str(test_obj)] = self.ak_arrays[str(test_obj)][sel] + + def _skim_to_hists(self) -> None: + """ + TODO! + """ ref_field = self.cfg_plot.reference_field - if (trafo := self.cfg_plot.reference_trafo): + if trafo := self.cfg_plot.reference_trafo: ref_field = trafo - for test_obj, cfg in self.cfg_plot.test_objects.items(): - field = cfg["suffix"].lower() - sel = self.ak_arrays[test_obj][field] > self.threshold - ak_array = self._flatten_array( - self.ak_arrays["ref"][sel][ref_field] - ) - self.hists[test_obj] = np.histogram(ak_array, bins=self.bins) + for test_obj, x_arg in self.test_objects: + sel = self.ak_arrays[str(test_obj)][x_arg] > self.threshold + ak_array = self._flatten_array(self.ak_arrays["ref"][ref_field][sel]) + self.hists[str(test_obj)] = np.histogram(ak_array, bins=self.bins) - self.hists["ref"][test_obj] = np.histogram( - self._flatten_array(self.ak_arrays["ref"][ref_field]), - bins=self.bins + self.hists["ref"][str(test_obj)] = np.histogram( + self._flatten_array(self.ak_arrays["ref"][ref_field]), bins=self.bins ) def _remove_inner_nones_zeros(self, arr): @@ -334,45 +302,42 @@ def _remove_inner_nones_zeros(self, arr): def _skim_to_hists_dR_matched(self): ref_field = self.cfg_plot.reference_field - ref_obj = self._remove_inner_nones_zeros( - self.ak_arrays["ref"][ref_field] - ) + ref_obj = self._remove_inner_nones_zeros(self.ak_arrays["ref"][ref_field]) - for test_obj, cfg in self.cfg_plot.test_objects.items(): - sel_threshold = self.numerators["test"][test_obj] >= self.threshold - numerator = self.numerators["ref"][test_obj][sel_threshold] + for test_obj, _ in self.test_objects: + sel_threshold = self.numerators["test"][str(test_obj)] >= self.threshold + numerator = self.numerators["ref"][str(test_obj)][sel_threshold] numerator = self._remove_inner_nones_zeros(numerator) numerator = self._flatten_array(numerator, ak_to_np=True) # Create Test Object(s) Numpy Histogram - self.hists[test_obj] = np.histogram(numerator, bins=self.bins) + self.hists[str(test_obj)] = np.histogram(numerator, bins=self.bins) # Create Reference Numpy Histogram if self.threshold >= 0: - ref_obj = self.numerators["ref"][test_obj] + ref_obj = self.numerators["ref"][str(test_obj)] ref_obj = self._remove_inner_nones_zeros(ref_obj) ref_flat_np = self._flatten_array(ref_obj, ak_to_np=True) - self.hists["ref"][test_obj] = np.histogram(ref_flat_np, - bins=self.bins) + self.hists["ref"][str(test_obj)] = np.histogram(ref_flat_np, bins=self.bins) def _skim_to_hists_dR_matched_Iso(self): - for test_obj, cfg in self.cfg_plot.test_objects.items(): - numerator = self.numerators["test"][test_obj] + for test_obj, _ in self.test_objects: + numerator = self.numerators["test"][str(test_obj)] numerator = self._remove_inner_nones_zeros(numerator) numerator = self._flatten_array(numerator, ak_to_np=True) # Create Test Object(s) Numpy Histogram - self.hists[test_obj] = np.histogram(numerator, bins=self.bins) + self.hists[str(test_obj)] = np.histogram(numerator, bins=self.bins) - def xerr(self, obj_key: str): - ref_vals = self.hists["ref"][obj_key][0] + def xerr(self, obj: Object): + ref_vals = self.hists["ref"][str(obj)][0] bin_width = self.cfg_plot.bin_width return np.ones_like(ref_vals) * bin_width / 2 @utils.ignore_warnings - def get_efficiency(self, obj_key: str): - ref_vals = self.hists["ref"][obj_key][0] - test_vals = self.hists[obj_key][0] + def get_efficiency(self, obj: Object): + ref_vals = self.hists["ref"][str(obj)][0] + test_vals = self.hists[str(obj)][0] eff = test_vals / ref_vals assert all(0 <= i <= 1 or str(i) == "nan" for i in eff) @@ -386,14 +351,12 @@ def _apply_cuts(self): self._apply_reference_cuts() self._apply_reference_trafo() # Apply cuts on test objects - self._apply_quality_cuts() - self._apply_L1_isolation_cuts() self._apply_test_obj_cuts() def create_hists(self): self._load_arrays() self._apply_cuts() - if not self.cfg_plot.matching_configured: + if not self.cfg_plot.matching: self._skim_to_hists() else: self._match_test_to_ref() diff --git a/menu_tools/rate_plots/__init__.py b/menu_tools/rate_plots/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/menu_tools/rate_plots/config.py b/menu_tools/rate_plots/config.py new file mode 100644 index 00000000..461336ab --- /dev/null +++ b/menu_tools/rate_plots/config.py @@ -0,0 +1,51 @@ +from menu_tools.utils.config import BasePlotConfig +from menu_tools.utils.objects import Object + + +class RatePlotConfig(BasePlotConfig): + def __init__(self, cfg: dict, name: str): + super().__init__(cfg, name) + + @property + def compare_versions(self) -> bool: + """ + Returns a boolean specifying if a plot comparing two versions + is to be produced. If a list of two versions is given this is true. + """ + return len(self.versions) == 2 + + @property + def versions(self) -> list[str]: + if "version" in self._cfg.keys(): + version = self._cfg["version"] + if isinstance(version, str): + return [version] + try: + versions = self._cfg["versions"] + except KeyError: + raise ValueError( + "`version(s)` must be specified as either a single" + "version (e.g. `V30`) or a list of exactly two versions" + "(e.g. [`V29`, `V30`])." + ) + if isinstance(versions, str): + return [versions] + if isinstance(versions, list): + assert ( + len(versions) == 2 + ), "To compare versions, exactly two must be specified." + return versions + raise RuntimeError("Somthing is wrong with the version config!") + + @property + def test_objects(self) -> list: + return self._cfg["test_objects"] + + @property + def test_object_instances(self) -> dict[str, dict[str, Object]]: + test_objects: dict[str, dict[str, Object]] = {} + for obj_key in self._cfg["test_objects"]: + test_objects[obj_key] = {} + for version in self.versions: + test_objects[obj_key][version] = Object(obj_key, version) + return test_objects diff --git a/menu_tools/rate_plots/plotter.py b/menu_tools/rate_plots/plotter.py new file mode 100644 index 00000000..106851f7 --- /dev/null +++ b/menu_tools/rate_plots/plotter.py @@ -0,0 +1,343 @@ +import argparse +import os +import json + +import awkward as ak +import matplotlib.pyplot as plt +import mplhep as hep +import numpy as np +import yaml + +from menu_tools.utils import constants +from menu_tools.utils import objects +from menu_tools.utils import scalings +from menu_tools.utils.objects import Object +from menu_tools.rate_plots.config import RatePlotConfig + +plt.style.use(hep.style.CMS) + + +class RatePlotter: + # Common plot properties + _figsize = (10, 10) + _llabel = "Phase-2 Simulation" + _com = 14 + _outdir = "outputs/rate_plots/" + + def __init__(self, cfg, data, offline_pt: bool): + self.cfg = cfg + self.data = data + self.offline_pt = offline_pt + + @property + def _online_offline(self): + if self.offline_pt: + return "Offline" + return "Online" + + def _style_plot(self, fig, ax0, ax1=None, legend_loc="upper right"): + ax0.legend(loc=legend_loc, frameon=False) + ax0.set_ylabel("Rate [kHz]") + ax0.set_yscale("log") + ax0.grid() + ax0.tick_params(direction="in") + if ax1: + ax1.set_xlabel(rf"{self._online_offline} $p_T$ [GeV]") + ax1.grid() + else: + ax0.set_xlabel(rf"{self._online_offline} $p_T$ [GeV]") + fig.tight_layout() + + def _plot_single_version_rate_curves(self): + """ + TODO: Write description! + """ + version = self.cfg.version + fig, ax = plt.subplots(figsize=self._figsize) + hep.cms.label(ax=ax, llabel=self._llabel, com=self._com) + + plot_dict = {} + + for obj_specifier, obj_instances in self.cfg.test_object_instances.items(): + if obj_specifier not in self.data.keys(): + continue + rate_values = self.data[obj_specifier][version] + + xvals = list(rate_values.keys()) + yvals = list(rate_values.values()) + label = f"{obj_instances[version].plot_label} @ {version}" + + plot_dict[obj_specifier] = { + "x_values": xvals, + "y_values": yvals, + "object": obj_instances[version].plot_label, + "label": label, + "version": version, + } + + ax.plot( + xvals, + yvals, + marker="o", + label=label, + ) + + self._style_plot(fig, ax) + + # Save plot + fname = os.path.join( + self._outdir, + f"{version}_{self._online_offline}_{self.cfg.plot_name}", + ) + plt.savefig(fname + ".png") + plt.savefig(fname + ".pdf") + + with open(fname + ".json", "w") as outfile: + outfile.write(json.dumps(plot_dict, indent=4)) + + # TODO: Add styling + plt.close() + + def _plot_version_comparsion_rate_curves(self): + """ + TODO: Write description! + """ + v1, v2 = self.cfg.versions + fig, axs = plt.subplots( + 2, + 1, + figsize=self._figsize, + sharex=True, + gridspec_kw={"height_ratios": [3, 1]}, + ) + hep.cms.label(ax=axs[0], llabel=self._llabel, com=self._com) + + for obj_key, rate_values in self.data.items(): + xvalues = np.fromiter(rate_values[v1].keys(), dtype=float) + v1_values = np.fromiter(rate_values[v1].values(), dtype=float) + v2_values = np.fromiter(rate_values[v2].values(), dtype=float) + p = axs[0].plot( + xvalues, + v1_values, + marker="o", + linestyle="solid", + label=f"{obj_key} @ {v1}", + ) + axs[0].plot( + xvalues, + v2_values, + marker="o", + linestyle="dashed", + label=f"{obj_key} @ {v2}", + color=p[0].get_color(), + ) + axs[1].plot( + xvalues, + v1_values / v2_values, + marker="o", + linestyle="dotted", + label=f"({obj_key} @ {v1}) / ({obj_key} @ {v2})", + ) + axs[1].axhline(1, alpha=0.6, color="black") + + self._style_plot(fig, axs[0], axs[1]) + fname = os.path.join( + self._outdir, f"{v1}-vs-{v2}_{self._online_offline}_{self.cfg.plot_name}" + ) + plt.savefig(fname + ".png") + plt.savefig(fname + ".pdf") + + plt.close() + + def plot(self): + os.makedirs(self._outdir, exist_ok=True) + if self.cfg.compare_versions: + self._plot_version_comparsion_rate_curves() + else: + self._plot_single_version_rate_curves() + + # Dump plot conifg + with open(os.path.join(self._outdir, f"{self.cfg.plot_name}.yaml"), "w") as f: + yaml.dump( + {self.cfg.plot_name: self.cfg.config_dict}, f, default_flow_style=False + ) + + +class RateComputer: + def __init__( + self, + obj: Object, + sample: str, + version: str, + apply_offline_conversion: bool, + ): + self.object = obj + self.sample = sample + self.version = version + self.apply_offline_conversion = apply_offline_conversion + self.arrays = self._load_cached_arrays() + + def _transform_key(self, raw_key: str) -> str: + """Maps to . + + Returns: + key: string of with the l1 object name prefix removed, qual + transformed to quality + """ + key = raw_key.removeprefix(self.object.nano_obj_name).lower() + if "qual" in key: + return "quality" + return key + + def _load_cached_arrays(self): + """ + Loads array for specified object/version combination + from the cached parquet file. + """ + fpath = os.path.join( + "cache", + self.version, + f"{self.version}_{self.sample}_{self.object.nano_obj_name}.parquet", + ) + arr = ak.from_parquet(fpath) + + # Remove object name prefix from array fields + arr = ak.zip({self._transform_key(var): arr[var] for var in arr.fields}) + + # Apply scalings if so configured + if self.apply_offline_conversion: + arr = scalings.add_offline_pt(arr, self.object) + arr["pt"] = scalings.get_pt_branch(arr) + + return arr + + def compute_rate(self, thresholds: np.ndarray) -> dict: + """Computes rate at threholds after application of all object cuts. + + threshold: pt threshold for which to compute rate + + Returns: + rate: rate computed after all object cuts are applied + """ + obj_mask = objects.compute_selection_mask_for_object_cuts( + self.object, self.arrays + ) + + pt_field = "offline_pt" if self.apply_offline_conversion else "pt" + + if (max_pt_obj := self.arrays[obj_mask][pt_field]).ndim > 1: + max_pt_obj = ak.max(max_pt_obj, axis=1) + + cumsum = np.cumsum( + np.histogram(max_pt_obj, bins=[-1] + list(thresholds) + [1e5])[0] + ) + rate = (cumsum[-1] - cumsum) / len(obj_mask) * constants.RATE_NORM_FACTOR + + return dict(zip(thresholds, rate)) + + +class RatePlotCentral: + """ + Class that orchestrates the creation of the rate plots + (pt thresholds vs. rate). + """ + + def __init__(self, cfg_plots_path: str): + with open(cfg_plots_path, "r") as f: + self.cfg_plots = yaml.safe_load(f) + + def get_bins(self, plot_config: RatePlotConfig) -> np.ndarray: + """ + Set bins according to configuration. + """ + bin_width = plot_config.bin_width + xmax = plot_config.bin_max + 1e-5 + xmin = plot_config.bin_min + return np.arange(xmin, xmax, bin_width) + + def _compute_rates( + self, + plot_config: RatePlotConfig, + obj_specifier: str, + obj_instances: dict[str, Object], + apply_offline_conversion: bool, + ) -> dict: + """ + This function orchestrates the computations of + the rates at the different thresholds that are + to be plotted. Instances of RateComputer are created + and called for this purpose. + """ + rate_data: dict[str, dict] = {} + + # Iterate over version(s) + for version in plot_config.versions: + rate_data[version] = {} + rate_computer = RateComputer( + obj_instances[version], + plot_config.sample, + version, + apply_offline_conversion, + ) + + rate_data[version] = rate_computer.compute_rate(self.get_bins(plot_config)) + + return rate_data + + def run(self, apply_offline_conversion: bool = False) -> None: + """ + This function iterates over all plots defined + in the configuration file, computes the rates + at the configured thresholds and passes it to + the RatePlotter for plotting. + """ + # Iterate over plots + for plot_name, cfg_plot in self.cfg_plots.items(): + print( + "Plotting ", + plot_name, + " Offline" if apply_offline_conversion else " Online", + ) + plot_config = RatePlotConfig(cfg_plot, plot_name) + rate_plot_data = {} + + # Iterate over test objects in plot + for ( + obj_specifier, + obj_instances, + ) in plot_config.test_object_instances.items(): + try: + rate_plot_data[obj_specifier] = self._compute_rates( + plot_config, + obj_specifier, + obj_instances, + apply_offline_conversion, + ) + scalings_found = True + except UserWarning: + # Continue without creating a plot if a warning was raised. + # This applies to no scalings being found for an object. + scalings_found = False + continue + if not scalings_found: + continue + + # Plot Rate vs. Threshold after all data has been aggregated + plotter = RatePlotter(plot_config, rate_plot_data, apply_offline_conversion) + plotter.plot() + + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument( + "cfg_plots", help="Path of YAML file specifying the desired plots." + ) + args = parser.parse_args() + + plotter = RatePlotCentral(args.cfg_plots) + plotter.run(apply_offline_conversion=True) + plotter.run() + + +if __name__ == "__main__": + main() diff --git a/menu_tools/rate_plots/tests/reference_data/HTRates.yaml b/menu_tools/rate_plots/tests/reference_data/HTRates.yaml new file mode 100644 index 00000000..85f7aa7e --- /dev/null +++ b/menu_tools/rate_plots/tests/reference_data/HTRates.yaml @@ -0,0 +1,10 @@ +HTRates: + binning: + max: 420 + min: 40 + step: 20 + sample: MinBias + test_objects: + - phase1PuppiHT:default + - seededConePuppiHT:default + version: V29 diff --git a/menu_tools/rate_plots/tests/reference_data/V29_Offline_HTRates.json b/menu_tools/rate_plots/tests/reference_data/V29_Offline_HTRates.json new file mode 100644 index 00000000..b4cfa778 --- /dev/null +++ b/menu_tools/rate_plots/tests/reference_data/V29_Offline_HTRates.json @@ -0,0 +1,100 @@ +{ + "phase1PuppiHT:default": { + "x_values": [ + 40.0, + 60.0, + 80.0, + 100.0, + 120.0, + 140.0, + 160.0, + 180.0, + 200.0, + 220.0, + 240.0, + 260.0, + 280.0, + 300.0, + 320.0, + 340.0, + 360.0, + 380.0, + 400.0, + 420.0 + ], + "y_values": [ + 31038.96, + 6515.021489281441, + 6515.021489281441, + 3321.78311602815, + 1973.7157652260328, + 1320.8727725069464, + 856.6764291074289, + 573.4939974851442, + 389.77321796093855, + 272.7326631107145, + 193.69841994037355, + 138.77418484190886, + 102.54622232137424, + 76.02836096294642, + 59.44092721114649, + 46.520355000304214, + 36.57418979049628, + 28.610962581377894, + 22.850999817470136, + 18.003818038006774 + ], + "object": "Histogrammed Puppi HT", + "label": "Histogrammed Puppi HT @ V29", + "version": "V29" + }, + "seededConePuppiHT:default": { + "x_values": [ + 40.0, + 60.0, + 80.0, + 100.0, + 120.0, + 140.0, + 160.0, + 180.0, + 200.0, + 220.0, + 240.0, + 260.0, + 280.0, + 300.0, + 320.0, + 340.0, + 360.0, + 380.0, + 400.0, + 420.0 + ], + "y_values": [ + 31038.96, + 8214.792795951893, + 8214.792795951893, + 2991.718364532419, + 2138.315356886446, + 1259.2443184537692, + 824.4615553978138, + 541.0430597278277, + 367.86647433427305, + 256.1609669620946, + 180.73063491999108, + 130.03981507696676, + 95.55872650942057, + 72.12543537428762, + 56.05734252743018, + 43.8607000628714, + 34.6699398057071, + 26.942776644289857, + 21.403140324903156, + 16.94939862494169 + ], + "object": "SeededCone HT", + "label": "SeededCone HT @ V29", + "version": "V29" + } +} \ No newline at end of file diff --git a/menu_tools/rate_plots/tests/reference_data/V29_Online_HTRates.json b/menu_tools/rate_plots/tests/reference_data/V29_Online_HTRates.json new file mode 100644 index 00000000..5f30cc52 --- /dev/null +++ b/menu_tools/rate_plots/tests/reference_data/V29_Online_HTRates.json @@ -0,0 +1,100 @@ +{ + "phase1PuppiHT:default": { + "x_values": [ + 40.0, + 60.0, + 80.0, + 100.0, + 120.0, + 140.0, + 160.0, + 180.0, + 200.0, + 220.0, + 240.0, + 260.0, + 280.0, + 300.0, + 320.0, + 340.0, + 360.0, + 380.0, + 400.0, + 420.0 + ], + "y_values": [ + 3669.442507879206, + 1985.5347052142697, + 1275.2179856815462, + 802.3659605329872, + 520.0963098951468, + 345.81809227898674, + 235.56044439937534, + 163.45074662826778, + 115.86023461171843, + 82.90569355263958, + 62.619923053521816, + 48.172803334212176, + 37.12500590179893, + 28.406373740036912, + 22.441822134788165, + 17.169725069462753, + 13.361225099884399, + 10.607144543371124, + 8.41961770134058, + 6.279303668850265 + ], + "object": "Histogrammed Puppi HT", + "label": "Histogrammed Puppi HT @ V29", + "version": "V29" + }, + "seededConePuppiHT:default": { + "x_values": [ + 40.0, + 60.0, + 80.0, + 100.0, + 120.0, + 140.0, + 160.0, + 180.0, + 200.0, + 220.0, + 240.0, + 260.0, + 280.0, + 300.0, + 320.0, + 340.0, + 360.0, + 380.0, + 400.0, + 420.0 + ], + "y_values": [ + 4042.156163992942, + 2461.5027757924836, + 1437.173660007707, + 891.8814474212586, + 565.4678198633054, + 370.0067883667633, + 249.8659256900643, + 172.20085399638995, + 121.36839572474497, + 86.4151790617965, + 64.68154907011176, + 49.4003363822581, + 38.33680134666477, + 29.27194191494108, + 22.976900642910742, + 17.67332837122518, + 13.864828401646825, + 11.252386273754233, + 8.765844971302249, + 6.436679700651023 + ], + "object": "SeededCone HT", + "label": "SeededCone HT @ V29", + "version": "V29" + } +} \ No newline at end of file diff --git a/menu_tools/rate_plots/tests/test_rate_plots_v29.py b/menu_tools/rate_plots/tests/test_rate_plots_v29.py new file mode 100644 index 00000000..bc6d920d --- /dev/null +++ b/menu_tools/rate_plots/tests/test_rate_plots_v29.py @@ -0,0 +1,63 @@ +""" +These tests check if V29 electron object performance plots can be reproduced. +""" +import json +from unittest.mock import patch +import re +import sys + +import numpy as np +import pytest + +from menu_tools.rate_plots import plotter + + +testdata = [ + "HTRates", +] + + +@pytest.mark.parametrize("test_name", testdata) +def test_matching_plots_reproduced(test_name): + # Prepare patching of the command line arguments for argparse + testargs = [ + "foo", + f"menu_tools/rate_plots/tests/reference_data/{test_name}.yaml", + ] + + # Run Plotting + with patch.object(sys, "argv", testargs): + plotter.main() + pass + + # Load result and assert correct outcome (Offline) + for online_offline in ["Online", "Offline"]: + with open( + f"outputs/rate_plots/V29_{online_offline}_{test_name}.json", + "r", + ) as f: + test_result = json.load(f) + with open( + f"menu_tools/rate_plots/tests/reference_data/V29_{online_offline}_{test_name}.json", + "r", + ) as f: + reference_data = json.load(f) + + for key, val in reference_data.items(): + print(key) + if isinstance(val, dict): + efficiencies_test = np.array( + test_result[key]["y_values"], dtype=np.float64 + ) + efficiencies_reference = np.array(val["y_values"], dtype=np.float64) + differences = efficiencies_test - efficiencies_reference + print(differences) + try: + assert not np.any(abs(differences) > 1e-4) + except Exception as e: + print(online_offline) + print(efficiencies_test) + print(efficiencies_reference) + raise e + else: + assert val == test_result[key] diff --git a/menu_tools/utils/config.py b/menu_tools/utils/config.py new file mode 100644 index 00000000..05419827 --- /dev/null +++ b/menu_tools/utils/config.py @@ -0,0 +1,46 @@ +from typing import Any, Optional + + +class BasePlotConfig: + """Base class for yaml/dict style plot config + + Includes abstractions for test_objects and creation of Object instances. + """ + + def __init__(self, cfg: dict[str, Any], name: Optional[str] = None) -> None: + self._cfg = cfg + self._name = name + + @property + def plot_name(self) -> Optional[str]: + return self._name + + @property + def config_dict(self) -> dict[str, Any]: + return self._cfg + + @property + def sample(self): + try: + return self._cfg["sample"] + except KeyError: + raise KeyError(f"No sample configured for {self.plot_name}!") + + @property + def version(self) -> str: + try: + return self._cfg["version"] + except KeyError: + raise KeyError(f"No version configured for {self.plot_name}!") + + @property + def bin_width(self) -> float: + return float(self._cfg["binning"]["step"]) + + @property + def bin_min(self) -> float: + return float(self._cfg["binning"]["min"]) + + @property + def bin_max(self) -> float: + return float(self._cfg["binning"]["max"]) diff --git a/menu_tools/utils/constants.py b/menu_tools/utils/constants.py new file mode 100644 index 00000000..d17d803f --- /dev/null +++ b/menu_tools/utils/constants.py @@ -0,0 +1,3 @@ +N_BUNCHES = 2760 +REVOLUTION_FREQUENCY = 11246 +RATE_NORM_FACTOR = N_BUNCHES * REVOLUTION_FREQUENCY / 1000 # in kHz diff --git a/menu_tools/utils/objects.py b/menu_tools/utils/objects.py new file mode 100644 index 00000000..16d02ad6 --- /dev/null +++ b/menu_tools/utils/objects.py @@ -0,0 +1,196 @@ +import glob +import re +from typing import Optional +import yaml + +import awkward as ak + + +class Object: + """This class represents a physics object. + + The objects are configurable under `configs//objects`. + + Attributes: + eta_ranges: ranges with different cuts/quality criteria + cuts: the cuts to be applied in the different eta ranges + version: version of the menu + """ + + def __init__( + self, + object_key: str, + version: str, + ) -> None: + """Initializes an Object loading the parameters from the + corresponding config file. + + Args: + object_key: object/id specifier of the form l1_object:id[:eta_range] + version: version of the menu + """ + self.object_key = object_key + self.version = version + self._nano_obj # fail early if no config can be found + + def __str__(self) -> str: + return f"{self.nano_obj_name}:{self.obj_id_name}:{self.eta_range}" + + @property + def nano_obj_name(self) -> str: + return self.object_key.split(":")[0] + + @property + def obj_id_name(self) -> str: + return self.object_key.split(":")[1] + + @property + def eta_range(self) -> str: + """If an eta range other than "inclusive" is specified, a cut to that + range is added to `cuts`. + + Returns: + eta_range_key: `barrel`/`endcap`/`overlap`/`forward`/`inclusive` + """ + try: + eta_range_key = self.object_key.split(":")[2] + except IndexError: + eta_range_key = "inclusive" + if eta_range_key not in self.eta_ranges.keys(): + raise ValueError( + f"`eta` range specifier `{eta_range_key}` not " + f"found in object definition of {self.nano_obj_name}!" + ) + return eta_range_key + + @property + def _nano_obj(self) -> dict[str, dict]: + """ + Loads all object configuration files from self.version, + merges them and returns the configuration of self.nano_obj_name. + + Returns: + nano_obj_configs: dictionary containing the object parameters and ids + or None if no configuration is found. + """ + nano_obj_configs: dict[str, dict] = {} + config_path = f"configs/{self.version}/objects/*.y*ml" + config_files = glob.glob(config_path) + + for config in config_files: + with open(config, "r") as f: + _conf_dict = yaml.safe_load(f) + nano_obj_configs = nano_obj_configs | _conf_dict + + try: + return nano_obj_configs[self.nano_obj_name] + except KeyError: + raise FileNotFoundError( + f"No config file found for {self.nano_obj_name}:{self.obj_id_name}!" + ) + + def _get_object_default_params(self) -> dict: + """Get default paramters of the object. + + Returns: + default_object_params: dict contianing all parameters of the nano + object except ids. + """ + default_object_params = {x: y for x, y in self._nano_obj.items() if x != "ids"} + return default_object_params + + def _get_object_id_params(self) -> dict: + """Get the specific parameters specified in the object id. + + Returns: + id_params: parameters specifically definied for the object id. + """ + id_params = self._nano_obj["ids"][self.obj_id_name] + return id_params + + @property + def _object_params(self) -> dict: + """ + Returns: + object_parameters: Parameters of the objects as a dict where + defaults are overwritten if id specific params are configured. + """ + defaults = self._get_object_default_params() + id_specific = self._get_object_id_params() + object_parameters = defaults | id_specific + return object_parameters + + @property + def match_dR(self) -> float: + return self._object_params["match_dR"] + + @property + def plot_label(self) -> str: + return self._object_params["label"] + + @property + def eta_ranges(self) -> dict[str, tuple[float, float]]: + _eta_ranges = {} + if "eta_ranges" in self._object_params.keys(): + _eta_ranges = self._object_params["eta_ranges"] + if "inclusive" not in _eta_ranges: + _eta_ranges["inclusive"] = [0, 7] + return _eta_ranges + + @property + def cuts(self) -> Optional[dict[str, list[str]]]: + _cuts = {} + if "cuts" in self._object_params.keys(): + _cuts = self._object_params["cuts"] + if self.eta_range != "inclusive": + # if a region other than inclusive is specified an eta cut + eta_min = self.eta_ranges[self.eta_range][0] + eta_max = self.eta_ranges[self.eta_range][1] + global_eta_cut = ( + f"((abs({{eta}}) > {eta_min}) & (abs({{eta}}) < {eta_max}))" + ) + try: + _cuts["inclusive"].append(global_eta_cut) + except KeyError: + _cuts["inclusive"] = [global_eta_cut] + return _cuts + + +def compute_selection_mask_for_object_cuts(obj: Object, ak_array: ak.Array) -> ak.Array: + """Compute selection mask for object cuts on array + + obj: Object that specifies the cuts to be applied + ak_array: array on which the selection is evaluated + + Returns: + sel: boolean selection mask for entries passing all cuts form obj + """ + # Initialize mask with True everywhere + sel = ak.ones_like(ak_array[ak_array.fields[0]]) > 0 + + # If no cut are specified in object return true everywhere + if not obj.cuts: + return sel + + for range_i, range_cuts in obj.cuts.items(): + # Initialize temporary mask (for rangei) with True everywhere + _sel = ak.ones_like(ak_array[ak_array.fields[0]]) > 0 + for cut in range_cuts: + cut = re.sub(r"{([^&|]*)}", r"ak_array['\1']", cut) + eta_sel = (abs(ak_array["eta"]) > obj.eta_ranges[range_i][0]) & ( + abs(ak_array["eta"]) < obj.eta_ranges[range_i][1] + ) + _sel = _sel & (eval(cut) + ~eta_sel) + # apply OR logic + sel = sel & _sel + return sel + + +if __name__ == "__main__": + x = Object("tkElectron:Iso", "V29") + x = Object("caloJet:default", "V29") + print(x) + print(x.match_dR) + print(x.plot_label) + print(x.eta_ranges) + print(x.cuts) diff --git a/menu_tools/utils/scalings.py b/menu_tools/utils/scalings.py new file mode 100644 index 00000000..a4b5a941 --- /dev/null +++ b/menu_tools/utils/scalings.py @@ -0,0 +1,73 @@ +import os +import warnings + +import awkward as ak +import yaml + +from menu_tools.utils.objects import Object + + +def load_scaling_params(obj: Object, eta_range: str) -> tuple[float, float]: + """Retrieves scalings for object+id from `outputs` + + obj: Object for which to retrive scaling parameters + eta_range: specifier of the range for which scalings are to be retrieved + + Returns: + scaling_params: parameters computed in object_performance + for the online-offline scaling + """ + fname = str(obj).replace("inclusive", eta_range) + fpath = os.path.join( + "outputs", obj.version, "object_performance", "scalings", fname + ".yaml" + ) + try: + with open(fpath, "r") as f: + scaling_params = yaml.safe_load(f) + except FileNotFoundError: + warnings.warn_explicit( + (f"No file was found at `{fpath}`"), + UserWarning, + filename="utils/scalings.py", + lineno=26, + ) + raise UserWarning + return scaling_params["slope"], scaling_params["offset"] + + +def get_pt_branch(arr: ak.Array) -> ak.Array: + if "pt" in arr.fields: + pt_orig = arr.pt + elif "et" in arr.fields: + pt_orig = arr.et + elif "" in arr.fields: + pt_orig = arr[""] + else: + raise RuntimeError("Unknown pt branch!") + return pt_orig + + +def add_offline_pt(arr: ak.Array, obj: Object) -> ak.Array: + """ + Add offline pt to filed called `offline_pt` and return array + """ + pt_orig = get_pt_branch(arr) + new_pt = ak.zeros_like(pt_orig) + + if len(obj.eta_ranges) == 1 and list(obj.eta_ranges)[0] == "inclusive": + # if only a single eta range is configured, the scalings are applied + # inclusively on that region + slope, offset = load_scaling_params(obj, "inclusive") + new_pt = new_pt + (pt_orig * slope + offset) + else: + # if multiple eta ranges are found, the "inclusive" range is skipped + # and all other ranges are applied + for eta_range, eta_min_max in obj.eta_ranges.items(): + if eta_range == "inclusive": + continue + slope, offset = load_scaling_params(obj, eta_range) + eta_mask = (abs(arr.eta) >= eta_min_max[0]) & ( + abs(arr.eta) < eta_min_max[1] + ) + new_pt = new_pt + eta_mask * (pt_orig * slope + offset) + return ak.with_field(arr, new_pt, "offline_pt") diff --git a/objectPerformance/tests/test_utils.py b/menu_tools/utils/tests/test_utils.py similarity index 67% rename from objectPerformance/tests/test_utils.py rename to menu_tools/utils/tests/test_utils.py index 80c39253..e4fdb1b2 100644 --- a/objectPerformance/tests/test_utils.py +++ b/menu_tools/utils/tests/test_utils.py @@ -1,11 +1,11 @@ -import utils +from menu_tools.utils import utils def test_get_pdg_id(): - electrons = ['e', 'ele', 'electron'] - muons = ['mu', 'muon'] - taus = ['tau'] - photons = ['photon', 'gamma'] + electrons = ["e", "ele", "electron"] + muons = ["mu", "muon"] + taus = ["tau"] + photons = ["photon", "gamma"] for particle in electrons: assert utils.get_pdg_id(particle) == 11 @@ -21,12 +21,12 @@ def test_get_pdg_id(): def test_str_to_op(): - op_less_than = utils.str_to_op('<') - op_less_equal = utils.str_to_op('<=') - op_equal = utils.str_to_op('==') - op_unequal = utils.str_to_op('!=') - op_greater_than = utils.str_to_op('>') - op_greater_equal = utils.str_to_op('>=') + op_less_than = utils.str_to_op("<") + op_less_equal = utils.str_to_op("<=") + op_equal = utils.str_to_op("==") + op_unequal = utils.str_to_op("!=") + op_greater_than = utils.str_to_op(">") + op_greater_equal = utils.str_to_op(">=") assert op_less_than(2, 5) assert not op_less_than(5, 2) diff --git a/objectPerformance/src/utils.py b/menu_tools/utils/utils.py similarity index 82% rename from objectPerformance/src/utils.py rename to menu_tools/utils/utils.py index 8459458f..576cf067 100644 --- a/objectPerformance/src/utils.py +++ b/menu_tools/utils/utils.py @@ -12,12 +12,12 @@ def str_to_op(x: str): op_map = { - '<': operator.lt, - '<=': operator.le, - '==': operator.eq, - '!=': operator.ne, - '>=': operator.ge, - '>': operator.gt, + "<": operator.lt, + "<=": operator.le, + "==": operator.eq, + "!=": operator.ne, + ">=": operator.ge, + ">": operator.gt, } return op_map[x] @@ -38,14 +38,14 @@ def clopper_pearson_err(x_hist, n_hist, alpha=1 - 0.68, warn="ignore"): def get_pdg_id(particle: str): id_map = { - 'e': 11, - 'ele': 11, - 'electron': 11, - 'mu': 13, - 'muon': 13, - 'tau': 15, - 'photon': 22, - 'gamma': 22, + "e": 11, + "ele": 11, + "electron": 11, + "mu": 13, + "muon": 13, + "tau": 15, + "photon": 22, + "gamma": 22, } return id_map[particle.lower()] @@ -63,9 +63,7 @@ def get_branches(ntuple_path: str, tree: str, obj: str): else: prefix = "L1PhaseII/" - obj_branches = [ - x.removeprefix(prefix + obj) for x in all_branches if obj in x - ] + obj_branches = [x.removeprefix(prefix + obj) for x in all_branches if obj in x] return obj_branches @@ -90,6 +88,7 @@ def errf(x: float, a: float, b: float, c: float, d: float, e: float): _cdf_back = norm.cdf(a * (x - b), a * a * c * c, a * c) * (d - e) + e return _cdf_front - _exp_turnon * _cdf_back + ############## # Decorators # ############## @@ -100,6 +99,7 @@ def wrapper(*args, **kwargs): with warnings.catch_warnings(): warnings.simplefilter("ignore") return func(*args, **kwargs) + return wrapper @@ -110,9 +110,9 @@ def wrapper(*args, **kwargs): t0 = time.time() result = func(*args, **kwargs) t1 = time.time() - print(f"{task} completed in " - f"{timedelta(seconds=round(t1 - t0, 0))}s") + print(f"{task} completed in " f"{timedelta(seconds=round(t1 - t0, 0))}s") return result + return wrapper - return decorator + return decorator diff --git a/objectPerformance/cfg_caching/V22.yaml b/objectPerformance/cfg_caching/V22.yaml deleted file mode 100644 index 6340be58..00000000 --- a/objectPerformance/cfg_caching/V22.yaml +++ /dev/null @@ -1,75 +0,0 @@ -V22: - DY: - ntuple_path: /eos/cms/store/cmst3/group/l1tr/phase2Menu/EmuDev/DYToLL_M-50_TuneCP5_14TeV-pythia8/DY_PU200_v22/220407_094155/0000//L1NtuplePhaseII_Step1_*.root - trees_branches: - genTree/L1GenTree: - part_e: [Id, Stat, Pt, Eta, Phi] - part_mu: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkMuon: [Pt, Eta, Phi, Chg, TrkIso, Bx, Qual, zVtx, MuRefPt, MuRefPhi, MuRefEta, DRMuTrack, NMatchedTracks, MuRefChg, Region] - globalMuon: [Pt, Eta, Phi, EtaAtVtx, PhiAtVtx, IEt, IEta, IPhi, IEtaAtVtx, IPhiAtVtx, IDEta, IDPhi, Chg, Iso, Qual, TfMuonIdx, Bx] - tkGlbMuon: [Pt, Eta, Phi, Chg, TrkIso, Bx, Qual, zVtx, MuRefPt, MuRefPhi, MuRefEta, DRMuTrack, NMatchedTracks] - gmtMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, Bx] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, EGRefPt, EGRefEta, EGRefPhi, HGC, PassesLooseTrackID, PassesPhotonID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesPhotonID, PassesLooseTrackID] - TT: - ntuple_path: /eos/cms/store/cmst3/group/l1tr/phase2Menu/EmuDev/TT_TuneCP5_14TeV-powheg-pythia8/TT_PU200_v22/220407_094308/0000//L1NtuplePhaseII_Step1_*.root - trees_branches: - genTree/L1GenTree: - genMetTrue: "all" - jet: "all" - l1PhaseIITree/L1PhaseIITree: - trackerMET: "all" - puppiMET: "all" - phase1PuppiMHT: "all" - trackerHT: "all" - phase1PuppiHT: "all" - phase1PuppiJet: "all" - seededConePuppiHT: "all" - seededConePuppiMHT: "all" - seededConePuppiJet: [Pt, Et, Eta, Phi] - trackerJet: [Pt, Eta, Phi] - caloJet: [Et, Pt, Eta, Phi] - VBFHToTauTau: - ntuple_path: /eos/cms/store/cmst3/group/l1tr/phase2Menu/EmuDev/VBFHToTauTau_M125_14TeV_powheg_pythia8_correctedGridpack_tuneCP5/VBFToTauTau_PU200_v22/220407_095503/0000//L1NtuplePhaseII_Step1_*.root - trees_branches: - genTree/L1GenTree: - part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - l1PhaseIITree/L1PhaseIITree: - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - caloTau: [Et, Eta, Pt, Phi, Iso, HwQual, Bx] - GluGluToGG: - ntuple_path: /eos/cms/store/cmst3/group/l1tr/phase2Menu/EmuDev/GluGluHToGG_M125_14TeV_powheg_pythia8_TuneCP5/HGG_PU200_v22/220407_094856/0000//L1NtuplePhaseII_Step1_*.root - trees_branches: - genTree/L1GenTree: - part_gamma: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkPhoton: [Pt, Et, Eta, Phi, Bx, TrkIso, HwQual, HGC, PassesPhotonID] - GluGluToHHTo2B2Tau: - ntuple_path: /eos/cms/store/cmst3/group/l1tr/phase2Menu/EmuDev/GluGluToHHTo2B2Tau_node_SM_TuneCP5_14TeV-madgraph-pythia8/GGToHHTo2B2Tau_PU200_v22/220408_073133/0000//L1NtuplePhaseII_Step1_*.root - trees_branches: - genTree/L1GenTree: - part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - l1PhaseIITree/L1PhaseIITree: - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - caloTau: [Et, Eta, Pt, Phi, Iso, HwQual, Bx] - MinBias: - ntuple_path: /eos/cms/store/cmst3/group/l1tr/phase2Menu/EmuDev/minbias_merged_nTuplesEmu_v22_2.root - trees_branches: - l1PhaseIITree/L1PhaseIITree: - # trackerMET: "all" - puppiMET: "all" - phase1PuppiMHT: "all" - # trackerHT: "all" - phase1PuppiHT: "all" - phase1PuppiJet: "all" - seededConePuppiJet: [Pt, Et, Eta, Phi] - trackerJet: [Pt, Eta, Phi] - caloJet: [Et, Pt, Eta, Phi] - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - caloTau: [Et, Eta, Pt, Phi, Iso, HwQual, Bx] - tkPhoton: [Pt, Et, Eta, Phi, Bx, TrkIso, HwQual, HGC, PassesPhotonID] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, EGRefPt, EGRefEta, EGRefPhi, HGC, PassesLooseTrackID, PassesPhotonID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesPhotonID, PassesLooseTrackID] diff --git a/objectPerformance/cfg_caching/V26.yaml b/objectPerformance/cfg_caching/V26.yaml deleted file mode 100644 index eb6b7c17..00000000 --- a/objectPerformance/cfg_caching/V26.yaml +++ /dev/null @@ -1,53 +0,0 @@ -V26: - Zmm: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/RelVal/CMSSW_12_5_1/Zmm_1251_200PU_condor/NTP/v26_PU200_fixGenMET_EGID/*.root - trees_branches: - genTree/L1GenTree: - part_mu: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - #tkMuon: [Pt, Eta, Phi, Chg, TrkIso, Bx, Qual, zVtx, MuRefPt, MuRefPhi, MuRefEta, DRMuTrack, NMatchedTracks, MuRefChg, Region] - #globalMuon: [Pt, Eta, Phi, EtaAtVtx, PhiAtVtx, IEt, IEta, IPhi, IEtaAtVtx, IPhiAtVtx, IDEta, IDPhi, Chg, Iso, Qual, TfMuonIdx, Bx] - #tkGlbMuon: [Pt, Eta, Phi, Chg, TrkIso, Bx, Qual, zVtx, MuRefPt, MuRefPhi, MuRefEta, DRMuTrack, NMatchedTracks] - gmtMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, Bx] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - Zee: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/RelVal/CMSSW_12_5_1/Zee_1251_200PU_condor/NTP/v26_PU200_fixGenMET_EGID/*.root - trees_branches: - genTree/L1GenTree: - part_e: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, EGRefPt, EGRefEta, EGRefPhi, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - TT: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/RelVal/CMSSW_12_5_1/TTbar_1251_200PU_condor/NTP/v26_PU200_fixGenMET_EGID/*.root - trees_branches: - genTree/L1GenTree: - genMetTrue: "all" - jet: "all" - l1PhaseIITree/L1PhaseIITree: - trackerMET: "all" - trackerMHT: "all" - puppiMET: "all" - phase1PuppiMHT: "all" - trackerHT: "all" - phase1PuppiHT: "all" - seededConePuppiJet: [Pt, Et, Eta, Phi] - trackerJet: [Pt, Eta, Phi] - phase1PuppiJet: "all" - # caloJet: "all" - Ztt: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/RelVal/CMSSW_12_5_1/Ztt_1251_200PU_condor/NTP/v26_PU200_fixGenMET_EGID/*.root - trees_branches: - genTree/L1GenTree: - part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - l1PhaseIITree/L1PhaseIITree: - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - caloTau: [Et, Eta, Pt, Phi, Iso, HwQual, Bx] - Hgg: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/RelVal/CMSSW_12_5_1/Hgg_1251_200PU_condor/NTP/v26_PU200_fixGenMET_EGID/*.root - trees_branches: - genTree/L1GenTree: - part_gamma: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkPhoton: [Pt, Et, Eta, Phi, Bx, TrkIso, HwQual, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] diff --git a/objectPerformance/cfg_caching/V27.yaml b/objectPerformance/cfg_caching/V27.yaml deleted file mode 100644 index d8d03eb2..00000000 --- a/objectPerformance/cfg_caching/V27.yaml +++ /dev/null @@ -1,89 +0,0 @@ -V27: - DYLL_M10to50: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/DY_M10to50_1252_200PU_condor/NTP/v27_PU200/*.root - trees_branches: - genTree/L1GenTree: - part_mu: [Id, Stat, Pt, Eta, Phi] - part_e: [Id, Stat, Pt, Eta, Phi] - part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - l1PhaseIITree/L1PhaseIITree: - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, EGRefPt, EGRefEta, EGRefPhi, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - gmtMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, Bx] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - caloTau: [Et, Eta, Pt, Phi, Iso, HwQual, Bx] - DYLL_M50: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/DY_M50_1252_200PU/NTP/v27_PU200/*.root - trees_branches: - genTree/L1GenTree: - part_mu: [Id, Stat, Pt, Eta, Phi] - part_e: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, EGRefPt, EGRefEta, EGRefPhi, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - gmtMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, Bx] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - TT: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/TT_1252_200PU/NTP/v27_PU200/*.root - trees_branches: - genTree/L1GenTree: - genMetTrue: "all" - jet: "all" - l1PhaseIITree/L1PhaseIITree: - trackerMET: "all" - trackerMHT: "all" - puppiMET: "all" - phase1PuppiMHT: "all" - trackerHT: "all" - phase1PuppiHT: "all" - seededConePuppiJet: [Pt, Et, Eta, Phi] - seededConePuppiHT: "all" - seededConePuppiMHT: "all" - trackerJet: [Pt, Eta, Phi] - phase1PuppiJet: "all" - # caloJet: "all" - caloJet: [Et, Pt, Eta, Phi] - VBFHToTauTau: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/VBFHToTauTau_1252_200PU/NTP/v27_PU200/*.root - trees_branches: - genTree/L1GenTree: - part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - l1PhaseIITree/L1PhaseIITree: - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - caloTau: [Et, Eta, Pt, Phi, Iso, HwQual, Bx] - HHToTauTau: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/GluGluToHHTo2B2Tau_node_SM_TuneCP5_14TeV-madgraph-pythia8/HHToTauTau_1252_200PU_crab_v27_PU200_fixHwQual/230320_095340/0000/L1NtuplePhaseII_Step1_1.root - trees_branches: - genTree/L1GenTree: - part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - l1PhaseIITree/L1PhaseIITree: - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - caloTau: [Et, Eta, Pt, Phi, Iso, HwQual] - Hgg: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/GluGluHToGG_1252_200PU/NTP/v27_PU200/*.root - trees_branches: - genTree/L1GenTree: - part_gamma: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkPhoton: [Pt, Et, Eta, Phi, Bx, TrkIso, HwQual, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - MinBias: - #ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/MinBias_TuneCP5_14TeV-pythia8/MinBias_1252_200PU_crb_v27_PU200/230213_192753/0000/L1NtuplePhaseII_Step1*.root - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/MinBias_TuneCP5_14TeV-pythia8/MinBias_1252_200PU_crb_v27_PU200/230213_192753/L1NtuplePhaseII_Step1.root - trees_branches: - l1PhaseIITree/L1PhaseIITree: - puppiMET: "all" - phase1PuppiJet: "all" - phase1PuppiMHT: "all" - phase1PuppiHT: "all" - seededConePuppiJet: [Pt, Et, Eta, Phi] - seededConePuppiHT: "all" - seededConePuppiMHT: "all" - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - tkPhoton: [Pt, Et, Eta, Phi, Bx, TrkIso, HwQual, HGC, PassesEleID, PassesPhoID] - z0L1TkPV: "all" - diff --git a/objectPerformance/cfg_caching/V27_bTagNN.yaml b/objectPerformance/cfg_caching/V27_bTagNN.yaml deleted file mode 100644 index 7e6aea5a..00000000 --- a/objectPerformance/cfg_caching/V27_bTagNN.yaml +++ /dev/null @@ -1,10 +0,0 @@ -V27: - TT: - ntuple_path: /afs/cern.ch/work/e/ejclemen/TJM/BJetNN/Phase2-L1MenuTools/ntuples_dr4.root - trees_branches: - genTree/L1GenTree: - genMetTrue: "all" - jet: "all" - l1PhaseIITree/L1PhaseIITree: - seededConeExtendedPuppiJet: [Pt, Et, Eta, Phi, BJetNN] - seededConePuppiJet: [Pt, Et, Eta, Phi] diff --git a/objectPerformance/cfg_caching/V28.yaml b/objectPerformance/cfg_caching/V28.yaml deleted file mode 100644 index 69c40fe1..00000000 --- a/objectPerformance/cfg_caching/V28.yaml +++ /dev/null @@ -1,75 +0,0 @@ -V28: - DYLL_M50: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/v28/DYToLL_M-50_TuneCP5_14TeV-pythia8/DY_M50_1252_crab_v28_v0/230412_202821/0000/*.root - trees_branches: - genTree/L1GenTree: - part_mu: [Id, Stat, Pt, Eta, Phi] - part_e: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, EGRefPt, EGRefEta, EGRefPhi, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - gmtMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, Bx] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - TT: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/v28/TT_TuneCP5_14TeV-powheg-pythia8/TT_1252_crab_v28_v0/230412_194315/0000/*.root - trees_branches: - genTree/L1GenTree: - genMetTrue: "all" - jet: "all" - l1PhaseIITree/L1PhaseIITree: - trackerMET: "all" - trackerMHT: "all" - puppiMET: "all" - phase1PuppiMHT: "all" - trackerHT: "all" - phase1PuppiHT: "all" - seededConePuppiJet: [Pt, Et, Eta, Phi] - seededConeExtendedPuppiJet: [Pt, Et, Eta, Phi, BJetNN] - seededConePuppiHT: "all" - seededConePuppiMHT: "all" - trackerJet: [Pt, Eta, Phi] - phase1PuppiJet: "all" - # caloJet: "all" - caloJet: [Et, Pt, Eta, Phi] - # VBFHToTauTau: - # ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/VBFHToTauTau_1252_200PU/NTP/v27_PU200/*.root - # trees_branches: - # genTree/L1GenTree: - # part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - # l1PhaseIITree/L1PhaseIITree: - # nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - # caloTau: [Et, Eta, Pt, Phi, Iso, HwQual, Bx] - # HHToTauTau: - # ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/GluGluToHHTo2B2Tau_node_SM_TuneCP5_14TeV-madgraph-pythia8/HHToTauTau_1252_200PU_crab_v27_PU200_fixHwQual/230320_095340/0000/L1NtuplePhaseII_Step1_1.root - # trees_branches: - # genTree/L1GenTree: - # part_tau: [Id, Stat, Pt, Eta, Phi, Parent, E] - # l1PhaseIITree/L1PhaseIITree: - # nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - # caloTau: [Et, Eta, Pt, Phi, Iso, HwQual] - Hgg: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/v28/GluGluHToGG_M-125_TuneCP5_14TeV-powheg-pythia8/GluGluHToGG_1252_crab_v28_v0/230412_202835/0000/*.root - trees_branches: - genTree/L1GenTree: - part_gamma: [Id, Stat, Pt, Eta, Phi] - l1PhaseIITree/L1PhaseIITree: - tkPhoton: [Pt, Et, Eta, Phi, Bx, TrkIso, HwQual, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - MinBias: - ntuple_path: /eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/v28/MinBias_TuneCP5_14TeV-pythia8/MinBias_1252_crb_v28_v0/230412_203649/*/*.root - trees_branches: - l1PhaseIITree/L1PhaseIITree: - puppiMET: "all" - phase1PuppiJet: "all" - phase1PuppiMHT: "all" - phase1PuppiHT: "all" - seededConePuppiJet: [Pt, Et, Eta, Phi] - seededConePuppiHT: "all" - seededConePuppiMHT: "all" - tkElectron: [Pt, Et, Eta, Phi, Chg, Bx, TrkIso, PfIso, PuppiIso, zVtx, HwQual, HGC, PassesEleID, PassesPhoID] - EG: [Pt, Et, Eta, Phi, Bx, Iso, HwQual, HGC, PassesEleID, PassesSaID] - gmtTkMuon: [Pt, Eta, Phi, Z0, D0, IPt, IEta, IPhi, IZ0, ID0, Chg, Iso, Qual, Beta, NStubs, Bx] - nnTau: [Et, Eta, Pt, Phi, FullIso, Z0, PassTightNN, Chg, DXY, PassLooseNN] - tkPhoton: [Pt, Et, Eta, Phi, Bx, TrkIso, HwQual, HGC, PassesEleID, PassesPhoID] - z0L1TkPV: "all" - diff --git a/objectPerformance/cfg_plots/V22/electron_iso.yaml b/objectPerformance/cfg_plots/V22/electron_iso.yaml deleted file mode 100644 index 1814c1c4..00000000 --- a/objectPerformance/cfg_plots/V22/electron_iso.yaml +++ /dev/null @@ -1,58 +0,0 @@ -ElectronsIsolation_Barrel: - sample: DY - default_version: V22 - iso_vs_efficiency: True - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.479" - object: - - "abs({eta}) < 1.479" - test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Isolation" - ylabel: "Efficiency (Barrel)" - binning: - min: 0 - max: 0.5 - step: 0.005 - -ElectronsIsolation_Endcap: - sample: DY - default_version: V22 - iso_vs_efficiency: True - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.479" - object: - - "abs({eta}) < 2.4" - test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Isolation" - ylabel: "Efficiency (Endcap)" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V22/electron_matching.yaml b/objectPerformance/cfg_plots/V22/electron_matching.yaml deleted file mode 100644 index 92a9df39..00000000 --- a/objectPerformance/cfg_plots/V22/electron_matching.yaml +++ /dev/null @@ -1,94 +0,0 @@ -ElectronsMatchingBarrel: - sample: DY - default_version: V22 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - # - "{passesloosetrackid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -ElectronsMatchingEndcap: - sample: DY - default_version: V22 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 - diff --git a/objectPerformance/cfg_plots/V22/electron_matching_eta.yaml b/objectPerformance/cfg_plots/V22/electron_matching_eta.yaml deleted file mode 100644 index 1b1f28a2..00000000 --- a/objectPerformance/cfg_plots/V22/electron_matching_eta.yaml +++ /dev/null @@ -1,96 +0,0 @@ -ElectronsMatching_Eta_Pt10to25: - sample: DY - default_version: V22 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - cuts: - - "abs({eta}) < 3.0" - - "{passesloosetrackid} == 1" - tkElectron: - match_dR: 0.15 - suffix: "Eta" - label: "TkElectron" - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 3.0" - - "{passesloosetrackid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -ElectronsMatching_Eta_Pt25toInf: - sample: DY - default_version: V22 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - cuts: - - "abs({eta}) < 3.0" - - "{passesloosetrackid} == 1" - tkElectron: - suffix: "Eta" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 3.0" - - "{passesloosetrackid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - diff --git a/objectPerformance/cfg_plots/V22/electron_trigger.yaml b/objectPerformance/cfg_plots/V22/electron_trigger.yaml deleted file mode 100644 index 904e5b2a..00000000 --- a/objectPerformance/cfg_plots/V22/electron_trigger.yaml +++ /dev/null @@ -1,100 +0,0 @@ -ElectronsTriggerBarrel: - sample: DY - default_version: V22 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - cuts: - - "abs({eta}) < 2.8" - - "{passesloosetrackid} == 1" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - thresholds: [30] #10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 - -ElectronsTriggerEndcap: - sample: DY - default_version: V22 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - cuts: - - "abs({eta}) < 2.8" - - "{passesloosetrackid} == 1" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passesloosetrackid} == 1" - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - quality_id: "QUAL_BarrelNoneEndcap3" - cuts: - - "abs({eta}) < 2.4" - - "{passesloosetrackid} == 1" - thresholds: [30] #10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V22/jets_matching_eta.yaml b/objectPerformance/cfg_plots/V22/jets_matching_eta.yaml deleted file mode 100644 index b0ea9071..00000000 --- a/objectPerformance/cfg_plots/V22/jets_matching_eta.yaml +++ /dev/null @@ -1,88 +0,0 @@ -JetMatching_Eta_Pt40To100: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 40" - - "{pt} < 100" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (40-100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 diff --git a/objectPerformance/cfg_plots/V22/jets_trigger.yaml b/objectPerformance/cfg_plots/V22/jets_trigger.yaml deleted file mode 100644 index a3eba075..00000000 --- a/objectPerformance/cfg_plots/V22/jets_trigger.yaml +++ /dev/null @@ -1,137 +0,0 @@ -JetTurnonBarrel: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 2.4" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 700 - step: 10 - -JetTurnonEndcap: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 2.4" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 900 - step: 20 - -JetTurnonForward: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 700 - step: 10 diff --git a/objectPerformance/cfg_plots/V22/met_ht_mht_trigger.yaml b/objectPerformance/cfg_plots/V22/met_ht_mht_trigger.yaml deleted file mode 100644 index af00c209..00000000 --- a/objectPerformance/cfg_plots/V22/met_ht_mht_trigger.yaml +++ /dev/null @@ -1,114 +0,0 @@ -HT: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen HT" - trafo: "HT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" - seededConePuppiHT: - suffix: "" - label: "SeededCone HT" - thresholds: [350] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 750 - step: 20 - -MHT30: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 - -MHT15: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 15" - trafo: "MHT" - test_objects: - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 12 - -MET: - sample: TT - default_version: V22 - reference_object: - object: "genMetTrue" - suffix: "" - label: "Gen MET" - test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" - thresholds: [150] - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 500 - step: 20 diff --git a/objectPerformance/cfg_plots/V22/mht.yaml b/objectPerformance/cfg_plots/V22/mht.yaml deleted file mode 100644 index 4eacd1bf..00000000 --- a/objectPerformance/cfg_plots/V22/mht.yaml +++ /dev/null @@ -1,32 +0,0 @@ -MHT30: - sample: TT - default_version: V22 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" - trackerMHT: - suffix: "" - label: "Tracker MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MHT30 (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 diff --git a/objectPerformance/cfg_plots/V22/mht_comparison.yaml b/objectPerformance/cfg_plots/V22/mht_comparison.yaml deleted file mode 100644 index b4f2c2ea..00000000 --- a/objectPerformance/cfg_plots/V22/mht_comparison.yaml +++ /dev/null @@ -1,12 +0,0 @@ -MHT_150_V22: - files: - MHT30_150: - object: trackerMHT - dir: outputs/V22/turnons/ - MHT15_150: - object: phase1PuppiMHT - dir: outputs/V22/turnons/ - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_MHTBarrel" - save_dir: "outputs/V22/turnons" \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V22/muon_matching.yaml b/objectPerformance/cfg_plots/V22/muon_matching.yaml deleted file mode 100644 index 755b08e2..00000000 --- a/objectPerformance/cfg_plots/V22/muon_matching.yaml +++ /dev/null @@ -1,101 +0,0 @@ -MuonsMatchingBarrel: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (barrel)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingOverlap: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (overlap)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingEndcap: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (endcap)" - binning: - min: 0 - max: 150 - step: 3 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V22/muon_matching_eta.yaml b/objectPerformance/cfg_plots/V22/muon_matching_eta.yaml deleted file mode 100644 index 29637b1d..00000000 --- a/objectPerformance/cfg_plots/V22/muon_matching_eta.yaml +++ /dev/null @@ -1,58 +0,0 @@ -MuonsMatching_Eta_Pt2to5: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 2" - - "{pt} < 5" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (2-5 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -MuonsMatching_Eta_Pt15toInf: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 15" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>15 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V22/muon_trigger.yaml b/objectPerformance/cfg_plots/V22/muon_trigger.yaml deleted file mode 100644 index ac707213..00000000 --- a/objectPerformance/cfg_plots/V22/muon_trigger.yaml +++ /dev/null @@ -1,140 +0,0 @@ -MuonsTrigger: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Barrel: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Overlap: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (overlap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Endcap: - sample: DY - default_version: V22 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V22/photon_iso.yaml b/objectPerformance/cfg_plots/V22/photon_iso.yaml deleted file mode 100644 index fdd1d2ef..00000000 --- a/objectPerformance/cfg_plots/V22/photon_iso.yaml +++ /dev/null @@ -1,60 +0,0 @@ -PhotonIsolation_Barrel: - sample: GluGluToGG - default_version: V22 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.479" - object: - - "abs({eta}) < 1.479" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - quality_id: "QUAL_123x_tkPhoID" - cuts: - - "abs({eta}) < 1.479" - xlabel: "Isolation" - ylabel: "Efficiency (Barrel)" - binning: - min: 0 - max: 0.5 - step: 0.005 - -PhotonIsolation_Endcap: - sample: GluGluToGG - default_version: V22 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.479" - - "abs({eta}) < 2.4" - object: - - "abs({eta}) > 1.479" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - quality_id: "QUAL_123x_tkPhoID" - cuts: - - "abs({eta}) > 1.479" - - "abs({eta}) < 2.4" - xlabel: "Isolation" - ylabel: "Efficiency (Endcap)" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V22/tau_matching.yaml b/objectPerformance/cfg_plots/V22/tau_matching.yaml deleted file mode 100644 index 11bc09e0..00000000 --- a/objectPerformance/cfg_plots/V22/tau_matching.yaml +++ /dev/null @@ -1,67 +0,0 @@ -TausMatchingBarrel: - sample: GluGluToHHTo2B2Tau - default_version: V22 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 - -TausMatchingEndcap: - sample: GluGluToHHTo2B2Tau - default_version: V22 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V22/tau_matching_GG_VBF.yaml b/objectPerformance/cfg_plots/V22/tau_matching_GG_VBF.yaml deleted file mode 100644 index 146c767d..00000000 --- a/objectPerformance/cfg_plots/V22/tau_matching_GG_VBF.yaml +++ /dev/null @@ -1,55 +0,0 @@ -TausMatchingBarrel_HH: - sample: GluGluToHHTo2B2Tau - default_version: V22 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau (HH)" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 - -TausMatchingBarrel_H: - sample: VBFHToTauTau - default_version: V22 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau (H)" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V22/tau_trigger.yaml b/objectPerformance/cfg_plots/V22/tau_trigger.yaml deleted file mode 100644 index 0f143826..00000000 --- a/objectPerformance/cfg_plots/V22/tau_trigger.yaml +++ /dev/null @@ -1,75 +0,0 @@ -TauTriggerBarrel: - sample: GluGluToHHTo2B2Tau - default_version: V22 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 - -TauTriggerEndcap: - sample: GluGluToHHTo2B2Tau - default_version: V22 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V22/version_comparison.yaml b/objectPerformance/cfg_plots/V22/version_comparison.yaml deleted file mode 100644 index 26147cca..00000000 --- a/objectPerformance/cfg_plots/V22/version_comparison.yaml +++ /dev/null @@ -1,14 +0,0 @@ -V22_V26_ElectronsBarrel_Comparison: - files: - ElectronsTriggerBarrel_30_V22: - object: tkElectron - dir: outputs/V22/turnons/ - label: "tkElectron (V22)" - ElectronsTriggerBarrel_30_V26: - object: tkElectron - dir: outputs/V26/turnons/ - label: "tkElectron (V26)" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_V26_EGBarrel_Comp" - save_dir: "outputs/V22/turnons" \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V26/electron_iso.yaml b/objectPerformance/cfg_plots/V26/electron_iso.yaml deleted file mode 100644 index e66f0572..00000000 --- a/objectPerformance/cfg_plots/V26/electron_iso.yaml +++ /dev/null @@ -1,29 +0,0 @@ -ElectronsIsolation: - sample: Zee - default_version: V26 - iso_vs_efficiency: True - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V26/electron_matching.yaml b/objectPerformance/cfg_plots/V26/electron_matching.yaml deleted file mode 100644 index 28fa6ed3..00000000 --- a/objectPerformance/cfg_plots/V26/electron_matching.yaml +++ /dev/null @@ -1,80 +0,0 @@ -ElectronsMatchingBarrel: - sample: Zee - default_version: V26 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - # - "{passeseleid} == 1" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - #tkElectronIso: - # suffix: "Pt" - # label: "TkElectron Iso" - # iso_BB: 0.13 - # iso_EE: 0.28 - # iso_branch: "trkiso" - # quality_id: "QUAL_BarrelNoneEndcap3" - # cuts: - # - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -ElectronsMatchingEndcap: - sample: Zee - default_version: V26 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - # - "{passessaid} == 1" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 diff --git a/objectPerformance/cfg_plots/V26/electron_matching_eta.yaml b/objectPerformance/cfg_plots/V26/electron_matching_eta.yaml deleted file mode 100644 index 75dc9f6b..00000000 --- a/objectPerformance/cfg_plots/V26/electron_matching_eta.yaml +++ /dev/null @@ -1,72 +0,0 @@ -ElectronsMatching_Eta_Pt10to25: - sample: Zee - default_version: V26 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" -# - "{passeseleid} == 1" - tkElectron: - match_dR: 0.15 - suffix: "Eta" - label: "TkElectron" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -ElectronsMatching_Eta_Pt25toInf: - sample: Zee - default_version: V26 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" -# - "{passeseleid} == 1" - tkElectron: - suffix: "Eta" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V26/electron_matching_eta_test.yaml b/objectPerformance/cfg_plots/V26/electron_matching_eta_test.yaml deleted file mode 100644 index 82be91b1..00000000 --- a/objectPerformance/cfg_plots/V26/electron_matching_eta_test.yaml +++ /dev/null @@ -1,36 +0,0 @@ -ElectronsMatching_Eta_Pt10to25: - sample: Zee - default_version: V26 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - # - "{passeseleid} == 1" - tkElectron: - match_dR: 0.15 - suffix: "Eta" - label: "TkElectron" - cuts: - - "abs({eta}) < 2.8" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V26/jets_matching_eta.yaml b/objectPerformance/cfg_plots/V26/jets_matching_eta.yaml deleted file mode 100644 index de51ebd9..00000000 --- a/objectPerformance/cfg_plots/V26/jets_matching_eta.yaml +++ /dev/null @@ -1,76 +0,0 @@ -JetMatching_Eta_Pt40To100: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 40" - - "{pt} < 100" - object: - - "abs({eta}) < 5" - test_objects: - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (40-100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 2.5" - test_objects: - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 diff --git a/objectPerformance/cfg_plots/V26/jets_trigger.yaml b/objectPerformance/cfg_plots/V26/jets_trigger.yaml deleted file mode 100644 index 7037b7a1..00000000 --- a/objectPerformance/cfg_plots/V26/jets_trigger.yaml +++ /dev/null @@ -1,113 +0,0 @@ -JetTurnonBarrel: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 700 - step: 10 - -JetTurnonEndcap: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 900 - step: 20 - -JetTurnonForward: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 700 - step: 10 diff --git a/objectPerformance/cfg_plots/V26/met_ht_mht.yaml b/objectPerformance/cfg_plots/V26/met_ht_mht.yaml deleted file mode 100644 index 9de0740f..00000000 --- a/objectPerformance/cfg_plots/V26/met_ht_mht.yaml +++ /dev/null @@ -1,108 +0,0 @@ -HT: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen HT" - trafo: "HT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" - thresholds: [350] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 750 - step: 20 - -MHT30: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 500 - step: 20 - -MHT15: - sample: TT - default_version: V26 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 15" - trafo: "MHT" - test_objects: - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 500 - step: 12 - -MET: - sample: TT - default_version: V26 - reference_object: - object: "genMetTrue" - suffix: "" - label: "Gen MET" - test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" - thresholds: [150] - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 500 - step: 20 diff --git a/objectPerformance/cfg_plots/V26/muon_matching.yaml b/objectPerformance/cfg_plots/V26/muon_matching.yaml deleted file mode 100644 index de945fe3..00000000 --- a/objectPerformance/cfg_plots/V26/muon_matching.yaml +++ /dev/null @@ -1,101 +0,0 @@ -MuonsMatchingBarrel: - sample: Zmm - default_version: V26 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (barrel)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingOverlap: - sample: Zmm - default_version: V26 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (overlap)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingEndcap: - sample: Zmm - default_version: V26 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (endcap)" - binning: - min: 0 - max: 150 - step: 3 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V26/muon_trigger.yaml b/objectPerformance/cfg_plots/V26/muon_trigger.yaml deleted file mode 100644 index b5dc8678..00000000 --- a/objectPerformance/cfg_plots/V26/muon_trigger.yaml +++ /dev/null @@ -1,35 +0,0 @@ -MuonsTrigger: - sample: Zmm - default_version: V26 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V26/photon_iso.yaml b/objectPerformance/cfg_plots/V26/photon_iso.yaml deleted file mode 100644 index da1f8aab..00000000 --- a/objectPerformance/cfg_plots/V26/photon_iso.yaml +++ /dev/null @@ -1,58 +0,0 @@ -PhotonIsolation_Barrel: - sample: Hgg - default_version: V26 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 1.5" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) < 1.5" - - "{passesphoid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency" - binning: - min: 0 - max: 0.5 - step: 0.005 - -PhotonIsolation_Endcap: - sample: Hgg - default_version: V26 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) > 1.5" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) > 1.5" - - "{passesphoid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V26/photons_matching_eta.yaml b/objectPerformance/cfg_plots/V26/photons_matching_eta.yaml deleted file mode 100644 index 5670e196..00000000 --- a/objectPerformance/cfg_plots/V26/photons_matching_eta.yaml +++ /dev/null @@ -1,145 +0,0 @@ -PhotonsMatching_Eta_Pt10to25_PassEleID: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt10to25_PassSa_PhoID: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton PhoID" - cuts: - - "abs({eta}) < 3.0" - - "{passesphoid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassEleID: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassSa_PhoID: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton PhoID" - cuts: - - "abs({eta}) < 3.0" - - "{passesphoid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V26/photons_matching_eta_iso.yaml b/objectPerformance/cfg_plots/V26/photons_matching_eta_iso.yaml deleted file mode 100644 index f6bb7503..00000000 --- a/objectPerformance/cfg_plots/V26/photons_matching_eta_iso.yaml +++ /dev/null @@ -1,161 +0,0 @@ -PhotonsMatching_Eta_Pt25_PassSa_NOPhoID_iso0p2: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton NO PhoID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - # - "{passesphoid} == 1" - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt15to25_PassEleID_iso0p2: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 15" - - "{pt} < 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($15 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassEleID_iso0p2: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassSa_PhoID_iso0p2: - sample: Hgg - default_version: V26 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton PhoID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passesphoid} == 1" - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - diff --git a/objectPerformance/cfg_plots/V26/scaling_thresholds.yaml b/objectPerformance/cfg_plots/V26/scaling_thresholds.yaml deleted file mode 100644 index 838980ea..00000000 --- a/objectPerformance/cfg_plots/V26/scaling_thresholds.yaml +++ /dev/null @@ -1,5 +0,0 @@ -Jet: {25, 30, 35, 40, 45, 50, 55, 60, 70, 75, 80, 85, 90, 100, 120, 125, 130, 140, 150, 175} -Muon: {7, 9, 10, 12, 14, 15, 17, 20, 26, 25, 27, 30} -Tau: {27, 30, 40, 50, 60, 70} -EG: {7, 9, 12, 14, 15, 17, 20, 26, 25, 27, 30, 40, 50} -HT: {70, 80, 90, 100, 125, 150, 175} diff --git a/objectPerformance/cfg_plots/V26/tau_matching.yaml b/objectPerformance/cfg_plots/V26/tau_matching.yaml deleted file mode 100644 index f71ece7a..00000000 --- a/objectPerformance/cfg_plots/V26/tau_matching.yaml +++ /dev/null @@ -1,67 +0,0 @@ -TausMatchingBarrel: - sample: Ztt - default_version: V26 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 - -TausMatchingEndcap: - sample: Ztt - default_version: V26 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V26/tau_trigger.yaml b/objectPerformance/cfg_plots/V26/tau_trigger.yaml deleted file mode 100644 index a1d59a92..00000000 --- a/objectPerformance/cfg_plots/V26/tau_trigger.yaml +++ /dev/null @@ -1,75 +0,0 @@ -TauTriggerBarrel: - sample: Ztt - default_version: V26 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 - -TauTriggerEndcap: - sample: Ztt - default_version: V26 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V27/electron_matching.yaml b/objectPerformance/cfg_plots/V27/electron_matching.yaml deleted file mode 100644 index 35b9d2c6..00000000 --- a/objectPerformance/cfg_plots/V27/electron_matching.yaml +++ /dev/null @@ -1,92 +0,0 @@ -ElectronsMatchingBarrel: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -ElectronsMatchingEndcap: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 - diff --git a/objectPerformance/cfg_plots/V27/electron_matching_eta.yaml b/objectPerformance/cfg_plots/V27/electron_matching_eta.yaml deleted file mode 100644 index ec66ff33..00000000 --- a/objectPerformance/cfg_plots/V27/electron_matching_eta.yaml +++ /dev/null @@ -1,92 +0,0 @@ -ElectronsMatching_Eta_Pt10to25: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - match_dR: 0.15 - suffix: "Eta" - label: "TkElectron" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -ElectronsMatching_Eta_Pt25toInf: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - suffix: "Eta" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V27/electron_matching_eta_test.yaml b/objectPerformance/cfg_plots/V27/electron_matching_eta_test.yaml deleted file mode 100644 index 6d23f019..00000000 --- a/objectPerformance/cfg_plots/V27/electron_matching_eta_test.yaml +++ /dev/null @@ -1,34 +0,0 @@ -ElectronsMatching_Eta_Pt25toInf_fixEGID: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - suffix: "Eta" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V27/electron_trigger.yaml b/objectPerformance/cfg_plots/V27/electron_trigger.yaml deleted file mode 100644 index 22846aa0..00000000 --- a/objectPerformance/cfg_plots/V27/electron_trigger.yaml +++ /dev/null @@ -1,99 +0,0 @@ -ElectronsTriggerBarrel: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.8" - - "{passeseleid} == 1" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 - -ElectronsTriggerEndcap: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.8" - - "{passeseleid} == 1" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V27/jets_matching.yaml b/objectPerformance/cfg_plots/V27/jets_matching.yaml deleted file mode 100644 index 1b53f5b8..00000000 --- a/objectPerformance/cfg_plots/V27/jets_matching.yaml +++ /dev/null @@ -1,164 +0,0 @@ -JetMatchingForward_3p7to7: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 3.7" - object: - - "abs({eta}) < 5" - test_objects: - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Pt" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 300 - step: 5 - -JetMatchingBarrel: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 2.5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 700 - step: 10 - -JetMatchingEndcap: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 900 - step: 20 - -JetMatchingForward: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 700 - step: 10 - diff --git a/objectPerformance/cfg_plots/V27/jets_matching_eta.yaml b/objectPerformance/cfg_plots/V27/jets_matching_eta.yaml deleted file mode 100644 index cdc1749b..00000000 --- a/objectPerformance/cfg_plots/V27/jets_matching_eta.yaml +++ /dev/null @@ -1,163 +0,0 @@ -JetMatching_Eta_Pt40To100: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 40" - - "{pt} < 100" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (40-100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf_extEta: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Eta" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5.5 - max: 5.5 - step: 0.25 -JetMatching_Eta_Pt100ToInf_extEta: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Eta" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -7 - max: 7 - step: 0.25 diff --git a/objectPerformance/cfg_plots/V27/jets_trigger.yaml b/objectPerformance/cfg_plots/V27/jets_trigger.yaml deleted file mode 100644 index cc1665c4..00000000 --- a/objectPerformance/cfg_plots/V27/jets_trigger.yaml +++ /dev/null @@ -1,137 +0,0 @@ -JetTurnonBarrel: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 2.5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 700 - step: 10 - -JetTurnonEndcap: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 900 - step: 20 - -JetTurnonForward: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 700 - step: 10 diff --git a/objectPerformance/cfg_plots/V27/jets_trigger_fwd.yaml b/objectPerformance/cfg_plots/V27/jets_trigger_fwd.yaml deleted file mode 100644 index cdf184c6..00000000 --- a/objectPerformance/cfg_plots/V27/jets_trigger_fwd.yaml +++ /dev/null @@ -1,41 +0,0 @@ -JetTurnonFwd_3p7to7: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 3.7" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 7" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 7" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: r'Trigger Efficiency ( GeV, $3.6<\eta<6$)' - binning: - min: 0 - max: 300 - step: 10 diff --git a/objectPerformance/cfg_plots/V27/met_ht_mht.yaml b/objectPerformance/cfg_plots/V27/met_ht_mht.yaml deleted file mode 100644 index cca4063d..00000000 --- a/objectPerformance/cfg_plots/V27/met_ht_mht.yaml +++ /dev/null @@ -1,169 +0,0 @@ -HT_90perc: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen HT" - trafo: "HT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" - thresholds: [350] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. HT (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 750 - step: 20 - -HT_50perc: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen HT" - trafo: "HT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" - thresholds: [350] - scalings: - method: "naive" - threshold: 0.50 - xlabel: "Gen. HT (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 750 - step: 20 - -MHT_50perc: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.50 - xlabel: "Gen. MHT30 (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 - -MHT_90perc: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MHT30 (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 - -MET_90perc: - sample: TT - default_version: V27 - reference_object: - object: "genMetTrue" - suffix: "" - label: "Gen MET" - test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" - thresholds: [150] - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 500 - step: 20 - -MET_50perc: - sample: TT - default_version: V27 - reference_object: - object: "genMetTrue" - suffix: "" - label: "Gen MET" - test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" - thresholds: [150] - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - scalings: - method: "naive" - threshold: 0.50 - binning: - min: 0 - max: 500 - step: 20 diff --git a/objectPerformance/cfg_plots/V27/mht.yaml b/objectPerformance/cfg_plots/V27/mht.yaml deleted file mode 100644 index 61b7f512..00000000 --- a/objectPerformance/cfg_plots/V27/mht.yaml +++ /dev/null @@ -1,32 +0,0 @@ -MHT30: - sample: TT - default_version: V27 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" - trackerMHT: - suffix: "" - label: "Tracker MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MHT30 (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 diff --git a/objectPerformance/cfg_plots/V27/muon_matching.yaml b/objectPerformance/cfg_plots/V27/muon_matching.yaml deleted file mode 100644 index 6297051f..00000000 --- a/objectPerformance/cfg_plots/V27/muon_matching.yaml +++ /dev/null @@ -1,101 +0,0 @@ -MuonsMatchingBarrel: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (barrel)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingOverlap: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (overlap)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingEndcap: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (endcap)" - binning: - min: 0 - max: 150 - step: 3 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V27/muon_matching_eta.yaml b/objectPerformance/cfg_plots/V27/muon_matching_eta.yaml deleted file mode 100644 index 911d057e..00000000 --- a/objectPerformance/cfg_plots/V27/muon_matching_eta.yaml +++ /dev/null @@ -1,58 +0,0 @@ -MuonsMatching_Eta_Pt2to5: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 2" - - "{pt} < 5" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (2-5 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -MuonsMatching_Eta_Pt15toInf: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 15" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>15 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V27/muon_trigger.yaml b/objectPerformance/cfg_plots/V27/muon_trigger.yaml deleted file mode 100644 index 8290ea61..00000000 --- a/objectPerformance/cfg_plots/V27/muon_trigger.yaml +++ /dev/null @@ -1,140 +0,0 @@ -# MuonsTrigger: -# sample: DYLL_M50 -# default_version: V27 -# reference_object: -# object: "part_mu" -# suffix: "Pt" -# label: "Gen Muons" -# cuts: -# event: -# - "{dr_0.3} < 0.15" -# test_objects: -# gmtMuon: -# suffix: "Pt" -# label: "GMT Muon" -# match_dR: 0.3 -# gmtTkMuon: -# suffix: "Pt" -# label: "GMT TkMuon" -# match_dR: 0.3 -# xlabel: "Gen. pT (GeV)" -# ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" -# thresholds: [20, 25] -# scalings: -# method: "naive" -# threshold: 0.95 -# binning: -# min: 0 -# max: 50 -# step: 1.5 - -MuonsTrigger_Barrel: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Overlap: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (overlap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Endcap: - sample: DYLL_M50 - default_version: V27 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V27/photon_iso.yaml b/objectPerformance/cfg_plots/V27/photon_iso.yaml deleted file mode 100644 index 498abd0c..00000000 --- a/objectPerformance/cfg_plots/V27/photon_iso.yaml +++ /dev/null @@ -1,60 +0,0 @@ -PhotonIsolation_Barrel: - sample: Hgg - default_version: V27 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.479" - object: - - "abs({eta}) < 1.479" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) < 1.479" - - "{passeseleid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency (Barrel)" - binning: - min: 0 - max: 0.5 - step: 0.005 - -PhotonIsolation_Endcap: - sample: Hgg - default_version: V27 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.479" - object: - - "abs({eta}) < 2.4" - - "abs({eta}) > 1.479" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) > 1.479" - - "abs({eta}) < 2.4" - - "{passesphoid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency (Endcap)" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V27/photons_matching.yaml b/objectPerformance/cfg_plots/V27/photons_matching.yaml deleted file mode 100644 index 756f3654..00000000 --- a/objectPerformance/cfg_plots/V27/photons_matching.yaml +++ /dev/null @@ -1,92 +0,0 @@ -PhotonsMatching_Barrel: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -PhotonsMatching_Endcap: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 diff --git a/objectPerformance/cfg_plots/V27/photons_matching_eta.yaml b/objectPerformance/cfg_plots/V27/photons_matching_eta.yaml deleted file mode 100644 index 792cecc4..00000000 --- a/objectPerformance/cfg_plots/V27/photons_matching_eta.yaml +++ /dev/null @@ -1,99 +0,0 @@ -PhotonsMatching_Eta_Pt10to25: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - #- "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "({quality} // 4) == 1" - #- "{passeseleid} == 1" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Eta" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} >= 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Eta" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V27/photons_matching_eta_iso.yaml b/objectPerformance/cfg_plots/V27/photons_matching_eta_iso.yaml deleted file mode 100644 index 0e9940a1..00000000 --- a/objectPerformance/cfg_plots/V27/photons_matching_eta_iso.yaml +++ /dev/null @@ -1,161 +0,0 @@ -PhotonsMatching_Eta_Pt25_PassSa_NOPhoID_iso0p2: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton NO PhoID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - # - "{passesphoid} == 1" - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt15to25_PassEleID_iso0p2: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 15" - - "{pt} < 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($15 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassEleID_iso0p2: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassSa_PhoID_iso0p2: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton PhoID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passesphoid} == 1" - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - diff --git a/objectPerformance/cfg_plots/V27/photons_trigger.yaml b/objectPerformance/cfg_plots/V27/photons_trigger.yaml deleted file mode 100644 index b2eb22a9..00000000 --- a/objectPerformance/cfg_plots/V27/photons_trigger.yaml +++ /dev/null @@ -1,100 +0,0 @@ -PhotonsTrigger_Barrel: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 - -PhotonsTrigger_Endcap: - sample: Hgg - default_version: V27 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V27/scaling_thresholds.yaml b/objectPerformance/cfg_plots/V27/scaling_thresholds.yaml deleted file mode 100644 index 838980ea..00000000 --- a/objectPerformance/cfg_plots/V27/scaling_thresholds.yaml +++ /dev/null @@ -1,5 +0,0 @@ -Jet: {25, 30, 35, 40, 45, 50, 55, 60, 70, 75, 80, 85, 90, 100, 120, 125, 130, 140, 150, 175} -Muon: {7, 9, 10, 12, 14, 15, 17, 20, 26, 25, 27, 30} -Tau: {27, 30, 40, 50, 60, 70} -EG: {7, 9, 12, 14, 15, 17, 20, 26, 25, 27, 30, 40, 50} -HT: {70, 80, 90, 100, 125, 150, 175} diff --git a/objectPerformance/cfg_plots/V27/tau_matching_wHH.yaml b/objectPerformance/cfg_plots/V27/tau_matching_wHH.yaml deleted file mode 100644 index 3868ee93..00000000 --- a/objectPerformance/cfg_plots/V27/tau_matching_wHH.yaml +++ /dev/null @@ -1,67 +0,0 @@ -HHTausMatchingBarrel: - sample: HHToTauTau - default_version: V27 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 - -HHTausMatchingEndcap: - sample: HHToTauTau - default_version: V27 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V27/version_comparison.yaml b/objectPerformance/cfg_plots/V27/version_comparison.yaml deleted file mode 100644 index 3aeeab6e..00000000 --- a/objectPerformance/cfg_plots/V27/version_comparison.yaml +++ /dev/null @@ -1,44 +0,0 @@ -V22_V27_GMTMuonsBarrel_Comparison: - files: - MuonsTrigger_20_V22: - object: gmtMuon - dir: outputs/V22/turnons/ - label: "GMT Muon (V22)" - MuonsTrigger_20_V27: - object: gmtMuon - dir: outputs/V27/turnons/ - label: "GMT Muon (V27)" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_V27_gmtMuonBarrel_Comp" - save_dir: "outputs/V22vs27/turnons" - -V22_V27_ElectronsBarrel_Comparison: - files: - ElectronsTriggerBarrel_30_V22: - object: tkElectron - dir: outputs/V22/turnons/ - label: "tkElectron (V22)" - ElectronsTriggerBarrel_30_V27: - object: tkElectron - dir: outputs/V27/turnons/ - label: "tkElectron (V27)" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_V27_EGBarrel_Comp" - save_dir: "outputs/V22vs27/turnons" - -V22_V27_GMTtkMuonsBarrel_Comparison: - files: - MuonsTrigger_20_V22: - object: gmtMuon - dir: outputs/V22/turnons/ - label: "GMT tkMuon (V22)" - MuonsTrigger_20_V27: - object: gmtMuon - dir: outputs/V27/turnons/ - label: "GMT tkMuon (V27)" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_V27_gmtTkMuonBarrel_Comp" - save_dir: "outputs/V22vs27/turnons" diff --git a/objectPerformance/cfg_plots/V28/electron_iso.yaml b/objectPerformance/cfg_plots/V28/electron_iso.yaml deleted file mode 100644 index 5f2a9c69..00000000 --- a/objectPerformance/cfg_plots/V28/electron_iso.yaml +++ /dev/null @@ -1,29 +0,0 @@ -ElectronsIsolation: - sample: DYLL_M50 - default_version: V28 - iso_vs_efficiency: True - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V28/electron_matching.yaml b/objectPerformance/cfg_plots/V28/electron_matching.yaml deleted file mode 100644 index 897ff250..00000000 --- a/objectPerformance/cfg_plots/V28/electron_matching.yaml +++ /dev/null @@ -1,92 +0,0 @@ -ElectronsMatchingBarrel: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -ElectronsMatchingEndcap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 - diff --git a/objectPerformance/cfg_plots/V28/electron_matching_eta b/objectPerformance/cfg_plots/V28/electron_matching_eta deleted file mode 100644 index be17de22..00000000 --- a/objectPerformance/cfg_plots/V28/electron_matching_eta +++ /dev/null @@ -1,88 +0,0 @@ -ElectronsMatchingBarrel: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkElectronIso: - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -ElectronsMatchingEndcap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkElectronIso: - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 - diff --git a/objectPerformance/cfg_plots/V28/electron_matching_eta.yaml b/objectPerformance/cfg_plots/V28/electron_matching_eta.yaml deleted file mode 100644 index 7cb7753e..00000000 --- a/objectPerformance/cfg_plots/V28/electron_matching_eta.yaml +++ /dev/null @@ -1,92 +0,0 @@ -ElectronsMatching_Eta_Pt10to25: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - match_dR: 0.15 - suffix: "Eta" - label: "TkElectron" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -ElectronsMatching_Eta_Pt25toInf: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - suffix: "Eta" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V28/electron_matching_eta_test.yaml b/objectPerformance/cfg_plots/V28/electron_matching_eta_test.yaml deleted file mode 100644 index d2122814..00000000 --- a/objectPerformance/cfg_plots/V28/electron_matching_eta_test.yaml +++ /dev/null @@ -1,34 +0,0 @@ -ElectronsMatching_Eta_Pt25toInf_fixEGID: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - suffix: "Eta" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V28/electron_matching_new.yaml b/objectPerformance/cfg_plots/V28/electron_matching_new.yaml deleted file mode 100644 index b54780c2..00000000 --- a/objectPerformance/cfg_plots/V28/electron_matching_new.yaml +++ /dev/null @@ -1,87 +0,0 @@ -ElectronsMatchingBarrel: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkElectronIso: - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -ElectronsMatchingEndcap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkElectronIso: - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 diff --git a/objectPerformance/cfg_plots/V28/electron_trigger.yaml b/objectPerformance/cfg_plots/V28/electron_trigger.yaml deleted file mode 100644 index 2d2a48ba..00000000 --- a/objectPerformance/cfg_plots/V28/electron_trigger.yaml +++ /dev/null @@ -1,99 +0,0 @@ -ElectronsTriggerBarrel: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.8" - - "{passeseleid} == 1" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 - -ElectronsTriggerEndcap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG Electron" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.8" - - "{passeseleid} == 1" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V28/jets_matching.yaml b/objectPerformance/cfg_plots/V28/jets_matching.yaml deleted file mode 100644 index f41f1b01..00000000 --- a/objectPerformance/cfg_plots/V28/jets_matching.yaml +++ /dev/null @@ -1,164 +0,0 @@ -JetMatchingForward_3p7to7: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 3.7" - object: - - "abs({eta}) < 5" - test_objects: - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Pt" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 300 - step: 5 - -JetMatchingBarrel: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 2.5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 700 - step: 10 - -JetMatchingEndcap: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 900 - step: 20 - -JetMatchingForward: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 700 - step: 10 - diff --git a/objectPerformance/cfg_plots/V28/jets_matching_eta.yaml b/objectPerformance/cfg_plots/V28/jets_matching_eta.yaml deleted file mode 100644 index 5ed773e9..00000000 --- a/objectPerformance/cfg_plots/V28/jets_matching_eta.yaml +++ /dev/null @@ -1,163 +0,0 @@ -JetMatching_Eta_Pt40To100: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 40" - - "{pt} < 100" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (40-100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf_extEta: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Eta" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5.5 - max: 5.5 - step: 0.25 -JetMatching_Eta_Pt100ToInf_extEta: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Eta" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -7 - max: 7 - step: 0.25 diff --git a/objectPerformance/cfg_plots/V28/jets_trigger.yaml b/objectPerformance/cfg_plots/V28/jets_trigger.yaml deleted file mode 100644 index 8b85e29f..00000000 --- a/objectPerformance/cfg_plots/V28/jets_trigger.yaml +++ /dev/null @@ -1,137 +0,0 @@ -JetTurnonBarrel: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 2.5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 700 - step: 10 - -JetTurnonEndcap: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 900 - step: 20 - -JetTurnonForward: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 700 - step: 10 diff --git a/objectPerformance/cfg_plots/V28/jets_trigger_fwd.yaml b/objectPerformance/cfg_plots/V28/jets_trigger_fwd.yaml deleted file mode 100644 index e568ed61..00000000 --- a/objectPerformance/cfg_plots/V28/jets_trigger_fwd.yaml +++ /dev/null @@ -1,41 +0,0 @@ -JetTurnonFwd_3p7to7: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 3.7" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 7" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 7" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: r'Trigger Efficiency ( GeV, $3.6<\eta<6$)' - binning: - min: 0 - max: 300 - step: 10 diff --git a/objectPerformance/cfg_plots/V28/met_ht_mht.yaml b/objectPerformance/cfg_plots/V28/met_ht_mht.yaml deleted file mode 100644 index 49a68cfa..00000000 --- a/objectPerformance/cfg_plots/V28/met_ht_mht.yaml +++ /dev/null @@ -1,114 +0,0 @@ -HT: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen HT" - trafo: "HT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" - seededConePuppiHT: - suffix: "" - label: "SeededCone HT" - thresholds: [350] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 750 - step: 20 - -MHT30: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 - -MHT15: - sample: TT - default_version: V28 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 15" - trafo: "MHT" - test_objects: - phase1PuppiMHT: - suffix: "et" - label: "Histogrammed Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 12 - -MET: - sample: TT - default_version: V28 - reference_object: - object: "genMetTrue" - suffix: "" - label: "Gen MET" - test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" - thresholds: [150] - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 500 - step: 20 diff --git a/objectPerformance/cfg_plots/V28/muon_matching.yaml b/objectPerformance/cfg_plots/V28/muon_matching.yaml deleted file mode 100644 index 5513e074..00000000 --- a/objectPerformance/cfg_plots/V28/muon_matching.yaml +++ /dev/null @@ -1,101 +0,0 @@ -MuonsMatchingBarrel: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (barrel)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingOverlap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (overlap)" - binning: - min: 0 - max: 150 - step: 3 - -MuonsMatchingEndcap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "abs({eta}) > 1.24" - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (endcap)" - binning: - min: 0 - max: 150 - step: 3 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V28/muon_matching_eta.yaml b/objectPerformance/cfg_plots/V28/muon_matching_eta.yaml deleted file mode 100644 index 7f2f2b38..00000000 --- a/objectPerformance/cfg_plots/V28/muon_matching_eta.yaml +++ /dev/null @@ -1,58 +0,0 @@ -MuonsMatching_Eta_Pt2to5: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 2" - - "{pt} < 5" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (2-5 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -MuonsMatching_Eta_Pt15toInf: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 15" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>15 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V28/muon_trigger.yaml b/objectPerformance/cfg_plots/V28/muon_trigger.yaml deleted file mode 100644 index 513d3566..00000000 --- a/objectPerformance/cfg_plots/V28/muon_trigger.yaml +++ /dev/null @@ -1,140 +0,0 @@ -# MuonsTrigger: -# sample: DYLL_M50 -# default_version: V28 -# reference_object: -# object: "part_mu" -# suffix: "Pt" -# label: "Gen Muons" -# cuts: -# event: -# - "{dr_0.3} < 0.15" -# test_objects: -# gmtMuon: -# suffix: "Pt" -# label: "GMT Muon" -# match_dR: 0.3 -# gmtTkMuon: -# suffix: "Pt" -# label: "GMT TkMuon" -# match_dR: 0.3 -# xlabel: "Gen. pT (GeV)" -# ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" -# thresholds: [20, 25] -# scalings: -# method: "naive" -# threshold: 0.95 -# binning: -# min: 0 -# max: 50 -# step: 1.5 - -MuonsTrigger_Barrel: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Overlap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (overlap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Endcap: - sample: DYLL_M50 - default_version: V28 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V28/photon_iso.yaml b/objectPerformance/cfg_plots/V28/photon_iso.yaml deleted file mode 100644 index bed6af45..00000000 --- a/objectPerformance/cfg_plots/V28/photon_iso.yaml +++ /dev/null @@ -1,58 +0,0 @@ -PhotonIsolation_Barrel: - sample: Hgg - default_version: V28 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 1.5" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) < 1.5" - - "{passesphoid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency" - binning: - min: 0 - max: 0.5 - step: 0.005 - -PhotonIsolation_Endcap: - sample: Hgg - default_version: V28 - iso_vs_efficiency: True - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) > 1.5" - test_objects: - tkPhoton: - suffix: "trkiso" - label: "TkPhoton" - match_dR: 0.15 - cuts: - - "abs({eta}) > 1.5" - - "{passesphoid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V28/photons_matching.yaml b/objectPerformance/cfg_plots/V28/photons_matching.yaml deleted file mode 100644 index 5c95d869..00000000 --- a/objectPerformance/cfg_plots/V28/photons_matching.yaml +++ /dev/null @@ -1,92 +0,0 @@ -PhotonsMatching_Barrel: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 3 - -PhotonsMatching_Endcap: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 3 diff --git a/objectPerformance/cfg_plots/V28/photons_matching_eta.yaml b/objectPerformance/cfg_plots/V28/photons_matching_eta.yaml deleted file mode 100644 index bd7fa469..00000000 --- a/objectPerformance/cfg_plots/V28/photons_matching_eta.yaml +++ /dev/null @@ -1,99 +0,0 @@ -PhotonsMatching_Eta_Pt10to25: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - #- "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "({quality} // 4) == 1" - #- "{passeseleid} == 1" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Eta" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} >= 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Eta" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V28/photons_matching_eta_IDtest.yaml b/objectPerformance/cfg_plots/V28/photons_matching_eta_IDtest.yaml deleted file mode 100644 index 69f8f06d..00000000 --- a/objectPerformance/cfg_plots/V28/photons_matching_eta_IDtest.yaml +++ /dev/null @@ -1,156 +0,0 @@ -PhotonsMatching_Eta_Pt10to25_PassEleID: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Eta" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt10to25_PassSa_PhoID: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton PhoID" - cuts: - - "abs({eta}) < 3.0" - - "{passesphoid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassEleID: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassSa_PhoID: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton PhoID" - cuts: - - "abs({eta}) < 3.0" - - "{passesphoid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V28/photons_matching_eta_iso.yaml b/objectPerformance/cfg_plots/V28/photons_matching_eta_iso.yaml deleted file mode 100644 index 09ed7b18..00000000 --- a/objectPerformance/cfg_plots/V28/photons_matching_eta_iso.yaml +++ /dev/null @@ -1,161 +0,0 @@ -PhotonsMatching_Eta_Pt25_PassSa_NOPhoID_iso0p2: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton NO PhoID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - # - "{passesphoid} == 1" - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt15to25_PassEleID_iso0p2: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 15" - - "{pt} < 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($15 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassEleID_iso0p2: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton EleID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - EG: - suffix: "Eta" - label: "EG EleID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25_PassSa_PhoID_iso0p2: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "TkPhoton PhoID" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - #quality_id: "QUAL_TkPho" - cuts: - - "abs({eta}) < 3.0" - - "{passesphoid} == 1" - EG: - suffix: "Eta" - label: "EG SaID" - match_dR: 0.2 - #quality_id: "QUAL_EG" - cuts: - - "abs({eta}) < 3" - - "{passessaid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - diff --git a/objectPerformance/cfg_plots/V28/photons_trigger.yaml b/objectPerformance/cfg_plots/V28/photons_trigger.yaml deleted file mode 100644 index 3403aeb5..00000000 --- a/objectPerformance/cfg_plots/V28/photons_trigger.yaml +++ /dev/null @@ -1,100 +0,0 @@ -PhotonsTrigger_Barrel: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 - -PhotonsTrigger_Endcap: - sample: Hgg - default_version: V28 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG Photon" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 150 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V28/scaling_thresholds.yaml b/objectPerformance/cfg_plots/V28/scaling_thresholds.yaml deleted file mode 100644 index 838980ea..00000000 --- a/objectPerformance/cfg_plots/V28/scaling_thresholds.yaml +++ /dev/null @@ -1,5 +0,0 @@ -Jet: {25, 30, 35, 40, 45, 50, 55, 60, 70, 75, 80, 85, 90, 100, 120, 125, 130, 140, 150, 175} -Muon: {7, 9, 10, 12, 14, 15, 17, 20, 26, 25, 27, 30} -Tau: {27, 30, 40, 50, 60, 70} -EG: {7, 9, 12, 14, 15, 17, 20, 26, 25, 27, 30, 40, 50} -HT: {70, 80, 90, 100, 125, 150, 175} diff --git a/objectPerformance/cfg_plots/V28/tau_matching.yaml b/objectPerformance/cfg_plots/V28/tau_matching.yaml deleted file mode 100644 index 081bdf31..00000000 --- a/objectPerformance/cfg_plots/V28/tau_matching.yaml +++ /dev/null @@ -1,67 +0,0 @@ -TausMatchingBarrel: - sample: VBFHToTauTau - default_version: V28 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 - -TausMatchingEndcap: - sample: VBFHToTauTau - default_version: V28 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V28/tau_trigger.yaml b/objectPerformance/cfg_plots/V28/tau_trigger.yaml deleted file mode 100644 index c5ac4e62..00000000 --- a/objectPerformance/cfg_plots/V28/tau_trigger.yaml +++ /dev/null @@ -1,75 +0,0 @@ -TauTriggerBarrel: - sample: VBFHToTauTau - default_version: V28 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 - -TauTriggerEndcap: - sample: VBFHToTauTau - default_version: V28 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V28/version_comparison.yaml b/objectPerformance/cfg_plots/V28/version_comparison.yaml deleted file mode 100644 index 9ad12bd4..00000000 --- a/objectPerformance/cfg_plots/V28/version_comparison.yaml +++ /dev/null @@ -1,44 +0,0 @@ -V22_V28_GMTMuonsBarrel_Comparison: - files: - MuonsTrigger_20_V22: - object: gmtMuon - dir: outputs/V22/turnons/ - label: "GMT Muon (V22)" - MuonsTrigger_20_V28: - object: gmtMuon - dir: outputs/V28/turnons/ - label: "GMT Muon (V28)" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_V28_gmtMuonBarrel_Comp" - save_dir: "outputs/V22vs27/turnons" - -V22_V28_ElectronsBarrel_Comparison: - files: - ElectronsTriggerBarrel_30_V22: - object: tkElectron - dir: outputs/V22/turnons/ - label: "tkElectron (V22)" - ElectronsTriggerBarrel_30_V28: - object: tkElectron - dir: outputs/V28/turnons/ - label: "tkElectron (V28)" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_V28_EGBarrel_Comp" - save_dir: "outputs/V22vs27/turnons" - -V22_V28_GMTtkMuonsBarrel_Comparison: - files: - MuonsTrigger_20_V22: - object: gmtMuon - dir: outputs/V22/turnons/ - label: "GMT tkMuon (V22)" - MuonsTrigger_20_V28: - object: gmtMuon - dir: outputs/V28/turnons/ - label: "GMT tkMuon (V28)" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - watermark: "V22_V28_gmtTkMuonBarrel_Comp" - save_dir: "outputs/V22vs27/turnons" diff --git a/objectPerformance/cfg_plots/V29/electron_iso.yaml b/objectPerformance/cfg_plots/V29/electron_iso.yaml deleted file mode 100644 index d87d8937..00000000 --- a/objectPerformance/cfg_plots/V29/electron_iso.yaml +++ /dev/null @@ -1,58 +0,0 @@ -ElectronsIsolation_Barrel: - sample: DYLL_M50 - default_version: V29 - iso_vs_efficiency: True - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.479" - object: - - "abs({eta}) < 1.479" - test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency (Barrel)" - binning: - min: 0 - max: 0.5 - step: 0.005 - -ElectronsIsolation_Endcap: - sample: DYLL_M50 - default_version: V29 - iso_vs_efficiency: True - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.479" - object: - - "abs({eta}) < 2.4" - test_objects: - tkElectron: - suffix: "trkiso" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - #- "{passeseleid} == 1" - xlabel: "Isolation" - ylabel: "Efficiency (Endcap)" - binning: - min: 0 - max: 0.5 - step: 0.005 - diff --git a/objectPerformance/cfg_plots/V29/electron_matching.yaml b/objectPerformance/cfg_plots/V29/electron_matching.yaml deleted file mode 100644 index 7ca9cf12..00000000 --- a/objectPerformance/cfg_plots/V29/electron_matching.yaml +++ /dev/null @@ -1,91 +0,0 @@ -ElectronsMatchingBarrel: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 100 - step: 3 - -ElectronsMatchingEndcap: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.4" - tkElectron: - suffix: "Pt" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 100 - step: 3 diff --git a/objectPerformance/cfg_plots/V29/electron_matching_eta.yaml b/objectPerformance/cfg_plots/V29/electron_matching_eta.yaml deleted file mode 100644 index d2c46d18..00000000 --- a/objectPerformance/cfg_plots/V29/electron_matching_eta.yaml +++ /dev/null @@ -1,92 +0,0 @@ -ElectronsMatching_Eta_Pt10to25: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - match_dR: 0.15 - suffix: "Eta" - label: "TkElectron" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - #- "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -ElectronsMatching_Eta_Pt25toInf: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_e" - suffix: "Eta" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3.0" - tkElectron: - suffix: "Eta" - label: "TkElectron" - match_dR: 0.15 - cuts: - - "abs({eta}) < 3.0" - - "{passeseleid} == 1" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Eta" - label: "TkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.4" - - "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($p_T > 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V29/electron_trigger.yaml b/objectPerformance/cfg_plots/V29/electron_trigger.yaml deleted file mode 100644 index 2e615595..00000000 --- a/objectPerformance/cfg_plots/V29/electron_trigger.yaml +++ /dev/null @@ -1,99 +0,0 @@ -ElectronsTriggerBarrel: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.8" - - "{passeseleid} == 1" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 100 - step: 1.5 - -ElectronsTriggerEndcap: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_e" - suffix: "Pt" - label: "Gen Electrons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.8" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 2.8" - tkElectron: - suffix: "Pt" - label: "tkElectron" - match_dR: 0.15 - cuts: - - "{passeseleid} == 1" - - "abs({eta}) < 2.8" - tkIsoElectron: - base_obj: "tkElectron" - suffix: "Pt" - label: "tkIsoElectron" - iso_BB: 0.13 - iso_EE: 0.28 - iso_branch: "trkiso" - match_dR: 0.15 - cuts: - - "abs({eta}) < 2.8" - - "{passeseleid} == 1" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 100 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V29/jets_matching.yaml b/objectPerformance/cfg_plots/V29/jets_matching.yaml deleted file mode 100644 index b979ebdb..00000000 --- a/objectPerformance/cfg_plots/V29/jets_matching.yaml +++ /dev/null @@ -1,164 +0,0 @@ -JetMatchingForward_3p7to7: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 3.7" - object: - - "abs({eta}) < 5" - test_objects: - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Pt" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - caloJet: - match_dR: 0.3 - suffix: "Pt" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 300 - step: 5 - -JetMatchingBarrel: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 2.5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 500 - step: 10 - -JetMatchingEndcap: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 500 - step: 10 - -JetMatchingForward: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 500 - step: 10 - diff --git a/objectPerformance/cfg_plots/V29/jets_matching_eta.yaml b/objectPerformance/cfg_plots/V29/jets_matching_eta.yaml deleted file mode 100644 index a0bf6e5d..00000000 --- a/objectPerformance/cfg_plots/V29/jets_matching_eta.yaml +++ /dev/null @@ -1,163 +0,0 @@ -JetMatching_Eta_Pt40To100: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 40" - - "{pt} < 100" - object: - - "abs({eta}) < 5" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (40-100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 5" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Eta" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Eta" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - trackerJet: - match_dR: 0.4 - suffix: "Eta" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5 - max: 5 - step: 0.25 - -JetMatching_Eta_Pt100ToInf_extEta: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Eta" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -5.5 - max: 5.5 - step: 0.25 -JetMatching_Eta_Pt100ToInf_extEta: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Eta" - label: "Gen Jets" - cuts: - event: - - "{pt} > 100" - object: - - "abs({eta}) < 7" - test_objects: - caloJet: - match_dR: 0.3 - suffix: "Eta" - label: "Calo Jet" - cuts: - - "abs({eta}) < 7" - # phase1PuppiJet: - # match_dR: 0.3 - # suffix: "Eta" - # label: "Histogrammed PuppiJet" - # cuts: - # - "abs({eta}) < 7" - # seededConePuppiJet: - # match_dR: 0.35 - # suffix: "Eta" - # label: "Seeded Cone PuppiJet" - # cuts: - # - "abs({eta}) < 7" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>100 GeV)" - binning: - min: -7 - max: 7 - step: 0.25 diff --git a/objectPerformance/cfg_plots/V29/jets_trigger.yaml b/objectPerformance/cfg_plots/V29/jets_trigger.yaml deleted file mode 100644 index 73bdfb45..00000000 --- a/objectPerformance/cfg_plots/V29/jets_trigger.yaml +++ /dev/null @@ -1,137 +0,0 @@ -JetTurnonBarrel: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 2.5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, barrel)" - binning: - min: 0 - max: 500 - step: 10 - -JetTurnonEndcap: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 2.4" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 2.4" - trackerJet: - match_dR: 0.4 - suffix: "Pt" - label: "Tracker Jet" - cuts: - - "abs({eta}) < 2.4" - thresholds: [50] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, endcap)" - binning: - min: 0 - max: 500 - step: 10 - -JetTurnonForward: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 2.4" - object: - - "abs({eta}) < 5" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 5" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 5" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 5" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Trigger Efficiency ( GeV, forward)" - binning: - min: 0 - max: 500 - step: 10 diff --git a/objectPerformance/cfg_plots/V29/jets_trigger_fwd.yaml b/objectPerformance/cfg_plots/V29/jets_trigger_fwd.yaml deleted file mode 100644 index bfc26425..00000000 --- a/objectPerformance/cfg_plots/V29/jets_trigger_fwd.yaml +++ /dev/null @@ -1,41 +0,0 @@ -JetTurnonFwd_3p7to7: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen Jets" - cuts: - event: - - "abs({eta}) > 3.7" - object: - - "abs({eta}) < 7" - test_objects: - # caloJet: - # match_dR: 0.3 - # suffix: "Pt" - # label: "Calo Jet" - # cuts: - # - "abs({eta}) < 7" - phase1PuppiJet: - match_dR: 0.3 - suffix: "Pt" - label: "Histogrammed PuppiJet" - cuts: - - "abs({eta}) < 7" - seededConePuppiJet: - match_dR: 0.35 - suffix: "Pt" - label: "Seeded Cone PuppiJet" - cuts: - - "abs({eta}) < 7" - thresholds: [50,100] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: r'Trigger Efficiency ( GeV, $3.6<\eta<6$)' - binning: - min: 0 - max: 300 - step: 10 diff --git a/objectPerformance/cfg_plots/V29/met_ht_mht.yaml b/objectPerformance/cfg_plots/V29/met_ht_mht.yaml deleted file mode 100644 index 06653174..00000000 --- a/objectPerformance/cfg_plots/V29/met_ht_mht.yaml +++ /dev/null @@ -1,181 +0,0 @@ -HT_90perc: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen HT" - trafo: "HT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" - seededConePuppiHT: - suffix: "" - label: "SeededCone HT" - thresholds: [350] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. HT (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 750 - step: 20 - -HT_50perc: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen HT" - trafo: "HT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - test_objects: - trackerHT: - suffix: "" - label: "Tracker HT" - phase1PuppiHT: - suffix: "" - label: "Histogrammed Puppi HT" - seededConePuppiHT: - suffix: "" - label: "SeededCone HT" - thresholds: [350] - scalings: - method: "naive" - threshold: 0.50 - xlabel: "Gen. HT (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 750 - step: 20 - -MHT_50perc: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - phase1PuppiMHT: - suffix: "et" - label: "Phase1 Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.50 - xlabel: "Gen. MHT30 (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 - -MHT_90perc: - sample: TT - default_version: V29 - reference_object: - object: "jet" - suffix: "Pt" - label: "Gen MHT" - cuts: - object: - - "abs({eta}) < 2.4" - - "{pt} > 30" - trafo: "MHT" - test_objects: - trackerMHT: - suffix: "" - label: "Tracker MHT" - phase1PuppiMHT: - suffix: "et" - label: "Phase1 Puppi MHT" - seededConePuppiMHT: - suffix: "et" - label: "SeededCone MHT" - thresholds: [70, 150] - scalings: - method: "naive" - threshold: 0.90 - xlabel: "Gen. MHT30 (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - binning: - min: 0 - max: 500 - step: 20 - -MET_90perc: - sample: TT - default_version: V29 - reference_object: - object: "genMetTrue" - suffix: "" - label: "Gen MET" - test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" - thresholds: [150] - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 500 - step: 20 - -MET_50perc: - sample: TT - default_version: V29 - reference_object: - object: "genMetTrue" - suffix: "" - label: "Gen MET" - test_objects: - trackerMET: - suffix: "" - label: "Tracker MET" - puppiMET: - suffix: "et" - label: "Puppi MET" - thresholds: [150] - xlabel: "Gen. MET (GeV)" - ylabel: "Trigger Efficiency ( GeV)" - scalings: - method: "naive" - threshold: 0.50 - binning: - min: 0 - max: 500 - step: 20 diff --git a/objectPerformance/cfg_plots/V29/muon_matching_eta.yaml b/objectPerformance/cfg_plots/V29/muon_matching_eta.yaml deleted file mode 100644 index 1ac547d8..00000000 --- a/objectPerformance/cfg_plots/V29/muon_matching_eta.yaml +++ /dev/null @@ -1,62 +0,0 @@ -MuonsMatching_Eta_Pt2to5: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 2" - - "{pt} < 5" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "({quality}) > 0" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (2-5 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -MuonsMatching_Eta_Pt15toInf: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_mu" - suffix: "Eta" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} > 15" - object: - - "abs({eta}) < 2.4" - test_objects: - gmtMuon: - suffix: "Eta" - label: "GMT Muon" - match_dR: 0.3 - gmtTkMuon: - suffix: "Eta" - label: "GMT TkMuon" - match_dR: 0.1 - cuts: - - "({quality}) > 0" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency (>15 GeV)" - binning: - min: -3 - max: 3 - step: 0.2 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V29/muon_trigger.yaml b/objectPerformance/cfg_plots/V29/muon_trigger.yaml deleted file mode 100644 index 8e55207d..00000000 --- a/objectPerformance/cfg_plots/V29/muon_trigger.yaml +++ /dev/null @@ -1,143 +0,0 @@ -# MuonsTrigger: -# sample: DYLL_M50 -# default_version: V29 -# reference_object: -# object: "part_mu" -# suffix: "Pt" -# label: "Gen Muons" -# cuts: -# event: -# - "{dr_0.3} < 0.15" -# test_objects: -# gmtMuon: -# suffix: "Pt" -# label: "GMT Muon" -# match_dR: 0.3 -# gmtTkMuon: -# suffix: "Pt" -# label: "GMT TkMuon" -# match_dR: 0.3 -# xlabel: "Gen. pT (GeV)" -# ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" -# thresholds: [20, 25] -# scalings: -# method: "naive" -# threshold: 0.95 -# binning: -# min: 0 -# max: 50 -# step: 1.5 - -MuonsTrigger_Barrel: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) < 0.83" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) < 0.83" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "({quality}) > 0" - - "abs({eta}) < 0.83" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Overlap: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "({quality}) > 0" - - "abs({eta}) > 0.83" - - "abs({eta}) < 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (overlap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 - -MuonsTrigger_Endcap: - sample: DYLL_M50 - default_version: V29 - reference_object: - object: "part_mu" - suffix: "Pt" - label: "Gen Muons" - cuts: - event: - - "{dr_0.3} < 0.15" - object: - - "abs({eta}) > 1.24" - test_objects: - gmtMuon: - suffix: "Pt" - label: "GMT Muon" - match_dR: 0.3 - cuts: - - "abs({eta}) > 1.24" - gmtTkMuon: - suffix: "Pt" - label: "GMT TkMuon" - match_dR: 0.3 - cuts: - - "({quality}) > 0" - - "abs({eta}) > 1.24" - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > 20$ GeV)" - thresholds: [20, 25] - scalings: - method: "naive" - threshold: 0.95 - binning: - min: 0 - max: 50 - step: 1.5 \ No newline at end of file diff --git a/objectPerformance/cfg_plots/V29/photons_matching.yaml b/objectPerformance/cfg_plots/V29/photons_matching.yaml deleted file mode 100644 index 2fa9e3bc..00000000 --- a/objectPerformance/cfg_plots/V29/photons_matching.yaml +++ /dev/null @@ -1,92 +0,0 @@ -PhotonsMatching_Barrel: - sample: Hgg - default_version: V29 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 100 - step: 3 - -PhotonsMatching_Endcap: - sample: Hgg - default_version: V29 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 100 - step: 3 diff --git a/objectPerformance/cfg_plots/V29/photons_matching_eta.yaml b/objectPerformance/cfg_plots/V29/photons_matching_eta.yaml deleted file mode 100644 index aa067474..00000000 --- a/objectPerformance/cfg_plots/V29/photons_matching_eta.yaml +++ /dev/null @@ -1,99 +0,0 @@ -PhotonsMatching_Eta_Pt10to25: - sample: Hgg - default_version: V29 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} < 25" - - "{pt} > 10" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - #- "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "({quality} // 4) == 1" - #- "{passeseleid} == 1" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Eta" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 - -PhotonsMatching_Eta_Pt25toInf: - sample: Hgg - default_version: V29 - reference_object: - object: "part_gamma" - suffix: "Eta" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "{pt} >= 25" - object: - - "abs({eta}) < 3.0" - test_objects: - EG: - suffix: "Eta" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - #- "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Eta" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Eta" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - #- "{passeseleid} == 1" - xlabel: "Gen. $\\eta$" - ylabel: "Matching Efficiency ($10 < p_T < 25$ GeV)" - binning: - min: -3 - max: 3 - step: 0.2 diff --git a/objectPerformance/cfg_plots/V29/photons_trigger.yaml b/objectPerformance/cfg_plots/V29/photons_trigger.yaml deleted file mode 100644 index 65cc3b0e..00000000 --- a/objectPerformance/cfg_plots/V29/photons_trigger.yaml +++ /dev/null @@ -1,100 +0,0 @@ -PhotonsTrigger_Barrel: - sample: Hgg - default_version: V29 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 100 - step: 1.5 - -PhotonsTrigger_Endcap: - sample: Hgg - default_version: V29 - reference_object: - object: "part_gamma" - suffix: "Pt" - label: "Gen Photons" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - EG: - suffix: "Pt" - label: "EG" - match_dR: 0.2 - quality_id: "QUAL_125x_EGID" - cuts: - - "abs({eta}) < 3" - - "{passeseleid} == 1" - tkPhoton: - match_dR: 0.15 - suffix: "Pt" - label: "tkPhoton" - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - tkIsoPhoton: - base_obj: "tkPhoton" - match_dR: 0.15 - suffix: "Pt" - label: "tkIsoPhoton" - iso_EE: 0.2 - iso_BB: 0.2 - iso_branch: trkiso - quality_id: "QUAL_125x_tkPhoID" - cuts: - - "abs({eta}) < 3.0" - thresholds: [10, 20, 30, 40] - scalings: - method: "naive" - threshold: 0.95 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - binning: - min: 0 - max: 100 - step: 1.5 diff --git a/objectPerformance/cfg_plots/V29/tau_matching.yaml b/objectPerformance/cfg_plots/V29/tau_matching.yaml deleted file mode 100644 index a35e41e6..00000000 --- a/objectPerformance/cfg_plots/V29/tau_matching.yaml +++ /dev/null @@ -1,67 +0,0 @@ -TausMatchingBarrel: - sample: VBFHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 - -TausMatchingEndcap: - sample: VBFHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V29/tau_matching_wHH.yaml b/objectPerformance/cfg_plots/V29/tau_matching_wHH.yaml deleted file mode 100644 index fc60c249..00000000 --- a/objectPerformance/cfg_plots/V29/tau_matching_wHH.yaml +++ /dev/null @@ -1,67 +0,0 @@ -HHTausMatchingBarrel: - sample: HHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Barrel)" - binning: - min: 0 - max: 150 - step: 6 - -HHTausMatchingEndcap: - sample: HHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. $p_T$ (GeV)" - ylabel: "Matching Efficiency (Endcap)" - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/cfg_plots/V29/tau_trigger.yaml b/objectPerformance/cfg_plots/V29/tau_trigger.yaml deleted file mode 100644 index a89c2bcb..00000000 --- a/objectPerformance/cfg_plots/V29/tau_trigger.yaml +++ /dev/null @@ -1,151 +0,0 @@ -TauTriggerBarrel_90perc: - sample: VBFHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 - -TauTriggerEndcap_90perc: - sample: VBFHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.90 - binning: - min: 0 - max: 150 - step: 6 - -TauTriggerBarrel_50perc: - sample: VBFHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) < 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (barrel, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.50 - binning: - min: 0 - max: 150 - step: 6 - -TauTriggerEndcap_50perc: - sample: VBFHToTauTau - default_version: V29 - reference_object: - object: "part_tau" - suffix: "Pt" - label: "Gen Taus" - cuts: - event: - - "{dr_0.3} < 0.15" - - "abs({eta}) > 1.5" - object: - - "abs({eta}) < 2.4" - test_objects: - nnTau: - suffix: "Pt" - label: "NN Tau" - cuts: - - "abs({eta}) < 2.4" - - "{passloosenn}==1" - match_dR: 0.1 - caloTau: - suffix: "Pt" - label: "Calo Tau" - cuts: - - "abs({eta}) < 2.4" - match_dR: 0.3 - xlabel: "Gen. pT (GeV)" - ylabel: "Trigger Efficiency (endcap, L1 $p_T > $ GeV)" - thresholds: [20, 30] - scalings: - method: "naive" - threshold: 0.50 - binning: - min: 0 - max: 150 - step: 6 diff --git a/objectPerformance/pyproject.toml b/objectPerformance/pyproject.toml deleted file mode 100644 index 54fecf98..00000000 --- a/objectPerformance/pyproject.toml +++ /dev/null @@ -1,22 +0,0 @@ -# pyproject.toml -[tool.poetry] -name = "object-performance" -version = "0.0.1" -description = "" -authors = [ - "Matteo Bonanomi ", - "Daniel Hundhausen ", -] - -[tool.pytest.ini_options] -filterwarnings = [ - "error", - "ignore::UserWarning", - 'ignore:A NumPy version', -] -pythonpath = [ - "src" -] -testpaths = [ - "tests", -] diff --git a/objectPerformance/src/plot_config.py b/objectPerformance/src/plot_config.py deleted file mode 100644 index 4f30ce3c..00000000 --- a/objectPerformance/src/plot_config.py +++ /dev/null @@ -1,153 +0,0 @@ -class PlotConfig(): - - def __init__(self, cfg: dict): - self._cfg = cfg - - @property - def sample(self): - return self._cfg["sample"] - - @property - def version_ref_object(self): - try: - return self._cfg["reference_object"]["version"] - except KeyError: - return self._cfg["default_version"] - except TypeError: - return None - - @property - def iso_vs_eff_plot(self): - try: - return self._cfg["iso_vs_efficiency"] - except KeyError: - return False - - @property - def reference_object(self): - return self._cfg["reference_object"]["object"] - - @property - def reference_event_cuts(self): - try: - return self._cfg["reference_object"]["cuts"]["event"] - except KeyError: - return [] - - @property - def reference_object_cuts(self): - try: - return self._cfg["reference_object"]["cuts"]["object"] - except KeyError: - return [] - - @property - def reference_trafo(self): - try: - return self._cfg["reference_object"]["trafo"] - except KeyError: - return None - - @property - def test_objects(self): - return self._cfg["test_objects"] - - def get_match_dR(self, test_obj): - try: - return self._cfg["test_objects"][test_obj]["match_dR"] - except KeyError: - return self._cfg["match_dR"] - - @property - def matching_configured(self): - if "match_dR" in self._cfg.keys(): - return True - for test_obj in self._cfg["test_objects"].values(): - test_keys = test_obj.keys() - if "match_dR" not in test_keys: - return False - return True - - @property - def reference_object_field(self): - ref_obj = self._cfg["reference_object"]["object"] - field = self._cfg["reference_object"]["suffix"] - return ref_obj + field - - @property - def reference_field(self): - field = self._cfg["reference_object"]["suffix"] - return field.lower() - - @property - def reference_iso_threshold(self): - try: - return self._cfg["reference_object"]["iso_threshold"] - except KeyError: - return None - - @property - def bin_width(self): - return self._cfg["binning"]["step"] - - @property - def bin_min(self): - return self._cfg["binning"]["min"] - - @property - def bin_max(self): - return self._cfg["binning"]["max"] - - @property - def scaling_pct(self): - return self._cfg["scalings"]["threshold"] - - @property - def scaling_method(self): - return self._cfg["scalings"]["method"] - - def get_object_cuts(self, obj): - obj_cfg = self._cfg["test_objects"][obj] - try: - return obj_cfg["cuts"] - except KeyError: - return None - - def get_test_object_version(self, obj): - obj_cfg = self._cfg["test_objects"][obj] - - try: - return obj_cfg["version"] - except KeyError: - return self._cfg["default_version"] - - def get_quality_id(self, obj): - try: - return self._cfg["test_objects"][obj]["quality_id"] - except KeyError: - return None - - def get_base_obj(self, obj): - try: - return self._cfg["test_objects"][obj]["base_obj"] - except KeyError: - return obj - - def get_iso_BB(self, obj): - try: - return self._cfg["test_objects"][obj]["iso_BB"] - except KeyError: - return -1 - - def get_iso_EE(self, obj): - try: - return self._cfg["test_objects"][obj]["iso_EE"] - except KeyError: - return -1 - - def get_l1_iso(self, obj): - try: - return self._cfg["test_objects"][obj]["iso_branch"] - except KeyError: - return None - diff --git a/objectPerformance/src/plotter.py b/objectPerformance/src/plotter.py deleted file mode 100755 index c08a09ef..00000000 --- a/objectPerformance/src/plotter.py +++ /dev/null @@ -1,474 +0,0 @@ -#!/afs/cern.ch/user/d/dhundhau/Phase2-L1MenuTools/pyenv-ak2.0/bin/python -import argparse -import os - -import matplotlib.pyplot as plt -import mplhep as hep -import numpy as np -from progress.bar import IncrementalBar -import yaml -import json - -from turnon_collection import TurnOnCollection -from scaling_collection import ScalingCollection -import utils - - -plt.style.use(hep.style.CMS) - - -class Plotter(): - - def _make_output_dirs(self, version: str): - os.makedirs(f"outputs/{version}/turnons", exist_ok=True) - os.makedirs(f"outputs/{version}/distributions", exist_ok=True) - os.makedirs(f"outputs/{version}/scalings", exist_ok=True) - - def _create_new_plot(self): - fig, ax = plt.subplots(figsize=(10, 10)) - hep.cms.label(ax=ax, llabel="Phase-2 Simulation", com=14) - return fig, ax - - -class EfficiencyPlotter(Plotter): - - def __init__(self, name, cfg, turnon_collection): - self.plot_name = name - self.cfg = cfg - self.turnon_collection = turnon_collection - self.version = self.turnon_collection.version - self.bin_width = turnon_collection.cfg_plot.bin_width - - def _style_plot(self, fig, ax, legend_loc="lower right"): - ax.axvline(self.turnon_collection.threshold, ls=":", c="k") - ax.axhline(1, ls=":", c="k") - ax.legend(loc=legend_loc, frameon=False) - ax.set_xlabel(rf"{self.cfg['xlabel']}") - ylabel = self.cfg["ylabel"].replace( - "", - str(self.turnon_collection.threshold) - ) - ax.set_ylabel(rf"{ylabel}") - ax.set_xlim(self.cfg["binning"]["min"], self.cfg["binning"]["max"]) - ax.tick_params(direction="in") - watermark = f"{self.version}_{self.plot_name}_"\ - f"{self.turnon_collection.threshold}" - ax.text(0, -0.1, watermark, - color="grey", alpha=0.2, - fontsize=20, - transform=ax.transAxes) - fig.tight_layout() - - def _save_json(self, file_name): - plot = {} - - xlabel = self.cfg["xlabel"] - ylabel = self.cfg["ylabel"].replace( - "", - str(self.turnon_collection.threshold) - ) - watermark = f"{self.version}_{self.plot_name}_"\ - f"{self.turnon_collection.threshold}" - - plot["xlabel"] = xlabel - plot["ylabel"] = ylabel - plot["watermark"] = watermark - - for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): - if obj_key == "ref": - continue - - _object = {} - - xbins = self.turnon_collection.bins - xbins = 0.5 * (xbins[1:] + xbins[:-1]) - - if "Iso" in self.cfg["xlabel"]: - efficiency = self._get_iso_vs_eff_hist(gen_hist_trig[0]) - yerr = np.zeros((2, len(efficiency))) - xerr = np.zeros(len(efficiency)) - else: - efficiency, yerr = self.turnon_collection.get_efficiency(obj_key) - xerr = self.turnon_collection.xerr(obj_key) - - yerr = np.array([yerr[0][~np.isnan(efficiency)], - yerr[1][~np.isnan(efficiency)]]) - xerr = xerr[~np.isnan(efficiency)] - xbins = xbins[~np.isnan(efficiency)] - efficiency = efficiency[~np.isnan(efficiency)] - - xerr = xerr.tolist() - yerr = yerr.tolist() - xbins = xbins.tolist() - efficiency = efficiency.tolist() - - label = self.cfg["test_objects"][obj_key]["label"] - - err_kwargs = {"xerr": xerr, - "capsize": 3, "marker": 'o', "markersize": 8} - - _object["label"] = label - _object["efficiency"] = efficiency - _object["efficiency_err"] = yerr - _object["xbins"] = xbins - _object["err_kwargs"] = err_kwargs - - plot[obj_key] = _object - - with open(f"{file_name}", "w") as outfile: - outfile.write(json.dumps(plot, indent=4)) - - def _get_iso_vs_eff_hist(self, test_hist): - """ - Cumulative ratio of efficiency vs L1 Iso histogram. - """ - - l1_isolation_histogram = sum(test_hist) - l1_cumulative_sum = np.cumsum(test_hist) / l1_isolation_histogram - - return l1_cumulative_sum - - @utils.ignore_warnings - def _plot_efficiency_curve(self): - """ - Efficiency / turn-on plots. - """ - fig, ax = self._create_new_plot() - xbins = self.turnon_collection.bins - xbins = 0.5 * (xbins[1:] + xbins[:-1]) - - for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): - if obj_key == "ref": - continue - efficiency, yerr = self.turnon_collection.get_efficiency(obj_key) - - label = self.cfg["test_objects"][obj_key]["label"] - - err_kwargs = {"xerr": self.turnon_collection.xerr(obj_key), - "capsize": 3, "marker": 'o', "markersize": 8} - ax.errorbar(xbins, efficiency, yerr=yerr, label=label, - **err_kwargs) - - self._style_plot(fig, ax) - ax.set_ylim(0, 1.1) - plot_fname = f"outputs/{self.version}/turnons/{self.plot_name}_{self.turnon_collection.threshold}_{self.version}" - for ext in [".png",".pdf"]: - plt.savefig(f"{plot_fname}{ext}") - self._save_json(f"{plot_fname}.json") - - ## save config - with open(f"{plot_fname}.yaml", "w") as outfile: - yaml.dump({self.plot_name:self.cfg}, outfile, default_flow_style=False) - - plt.close() - - @utils.ignore_warnings - def _plot_iso_vs_efficiency_curve(self): - """ - Efficiency vs L1 Iso plots. - """ - fig, ax = self._create_new_plot() - xbins = self.turnon_collection.bins - xbins = 0.5 * (xbins[1:] + xbins[:-1]) - - for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): - if obj_key == "ref": - continue - iso_vs_eff_hist = self._get_iso_vs_eff_hist(gen_hist_trig[0]) - - # yerr = np.sqrt(iso_vs_eff_hist) # TODO: Possibly introduce errors - label = self.cfg["test_objects"][obj_key]["label"] - err_kwargs = {"capsize": 3, "marker": 'o', "markersize": 8} - ax.errorbar(xbins, iso_vs_eff_hist, label=label, **err_kwargs) - - self._style_plot(fig, ax) - - - plot_fname = f"outputs/{self.version}/turnons/{self.plot_name}_{self.turnon_collection.threshold}_{self.version}" - for ext in [".png",".pdf"]: - plt.savefig(f"{plot_fname}{ext}") - self._save_json(f"{plot_fname}.json") - - ## save config - with open(f"{plot_fname}.yaml", "w") as outfile: - yaml.dump({self.plot_name:self.cfg}, outfile, default_flow_style=False) - - plt.close() - - def _plot_raw_counts(self): - """ - Raw counts of objects in bins - of the efficiency plots. - """ - fig, ax = self._create_new_plot() - xbins = self.turnon_collection.bins - xbins = 0.5 * (xbins[1:] + xbins[:-1]) - - for obj_key, ref_hist in self.turnon_collection.hists["ref"].items(): - err_kwargs = {"xerr": self.turnon_collection.xerr(obj_key), - "capsize": 1, "marker": 'o', "markersize": 2, - "linestyle": "None"} - - ref_hist = ax.step(xbins, ref_hist[0], where="mid", label = "ref: " + obj_key , ls = "--", color = "k") - label = self.cfg["reference_object"]["label"] - - for obj_key, gen_hist_trig in self.turnon_collection.hists.items(): - if obj_key == "ref": - continue - yerr = np.sqrt(gen_hist_trig[0]) - label = self.cfg["test_objects"][obj_key]["label"] - test_hist = ax.step(xbins, gen_hist_trig[0], where="mid") - ax.errorbar(xbins, gen_hist_trig[0], yerr=yerr, label=label, - color=test_hist[0].get_color(), **err_kwargs) - - self._style_plot(fig, ax) - plot_fname = f"outputs/{self.version}/distributions/{self.plot_name}_{self.turnon_collection.threshold}_dist_{self.version}" - for ext in [".png",".pdf"]: - plt.savefig(f"{plot_fname}{ext}") - #self._save_json(f"{plot_fname}.json") - - plt.close() - - def plot(self): - self._make_output_dirs(self.version) - if "Iso" in self.cfg["xlabel"]: - self._plot_iso_vs_efficiency_curve() - else: - self._plot_efficiency_curve() - self._plot_raw_counts() - - -class EfficiencyCentral(): - """ - Class that orchestrates the plotting of - """ - - def __init__(self, cfg_plots_path): - with open(cfg_plots_path, 'r') as f: - self.cfg_plots = yaml.safe_load(f) - - def get_thresholds(self, cfg_plot: dict): - """ - Function that returns the threholds for which - efficiency plots are to be produced. If the - thresholds are given in the config, these - values are returned in a list. If the - threshold configuration is missing, a single - threshold of -999 is returned. - """ - try: - return cfg_plot["thresholds"] - except KeyError: - return [-999] - - def run(self): - """ - This function iterates over all plots defined - in the configuration file, creates a turnon_collection - for it and passes it to the EfficiencyPlotter for - plotting. - """ - for plot_name, cfg_plot in self.cfg_plots.items(): - for threshold in self.get_thresholds(cfg_plot): - print(f">>> Turn On {plot_name} ({threshold} GeV) <<<") - turnon_collection = TurnOnCollection(cfg_plot, threshold) - turnon_collection.create_hists() - - plotter = EfficiencyPlotter(plot_name, cfg_plot, - turnon_collection) - plotter.plot() - - -class ScalingPlotter(Plotter): - - def __init__(self, plot_name: str, cfg_plot: dict, scalings: dict, - scaling_pct: float, version: str, params: dict): - self.plot_name = plot_name - self.cfg_plot = cfg_plot - self.scalings = scalings - self.params = params - self.version = version - self.scaling_pct = scaling_pct - - def _params_to_func_str(self, obj): - a = round(self.params[obj][0], 3) - b = round(self.params[obj][1], 3) - pm = '+' if b > 0 else '-' - return f"y = {a} x {pm} {abs(b)}" - - def _set_plot_ranges(self, ax): - xmax = 0 - ymax = 0 - for points in self.scalings.values(): - x_points = np.array(list(points.keys()) + [xmax]) - y_points = np.array(list(points.values()) + [ymax]) - xmax = np.max(x_points) - ymax = np.max(y_points) - ax.set_xlim(0, xmax) - ax.set_ylim(0, ymax) - - def _save_json(self, file_name): - # file_name = = f"outputs/{self.version}/scalings/{self.plot_name}.json" - plot = {} - - watermark = f"{self.version}_{self.plot_name}" - plot["watermark"] = watermark - - for obj, points in self.scalings.items(): - _object = {} - x_points = list(points.keys()) - y_points = list(points.values()) - - label = (self.cfg_plot["test_objects"][obj]["label"] - + ", " - + self._params_to_func_str(obj)) - - _object["xvals"] = x_points - _object["yvals"] = y_points - _object["label"] = label - - plot[obj] = _object - - with open(f"{file_name}", "w") as outfile: - outfile.write(json.dumps(plot, indent=4)) - - def plot(self): - self._make_output_dirs(self.version) - - fig, ax = self._create_new_plot() - for obj, points in self.scalings.items(): - x_points = np.array(list(points.keys())) - y_points = np.array(list(points.values())) - pts = ax.plot(x_points, y_points, 'o') - - label = (self.cfg_plot["test_objects"][obj]["label"] - + ", " - + self._params_to_func_str(obj)) - a, b = self.params[obj] - x = np.linspace(0, 2500, 20) - y = utils.scaling_func(x, a, b) - ax.plot(x, y, color=pts[0].get_color(), label=label) - - ax.legend(loc="lower right") - ax.set_xlabel("L1 threshold [GeV]") - ax.set_ylabel(f"{int(self.scaling_pct*100)}% Location (gen, GeV)") - watermark = f"{self.version}_{self.plot_name}" - ax.text(0, -0.1, watermark, - color="grey", alpha=0.2, - fontsize=20, - transform=ax.transAxes) - self._set_plot_ranges(ax) - fig.tight_layout() - - plot_fname = f"outputs/{self.version}/scalings/{self.plot_name}_{self.version}" - for ext in [".png",".pdf"]: - plt.savefig(f"{plot_fname}{ext}") - self._save_json(f"{plot_fname}.json") - - ## save config - with open(f"{plot_fname}.yaml", "w") as outfile: - yaml.dump({self.plot_name:self.cfg_plot}, outfile, default_flow_style=False) - - plt.close() - - -class ScalingCentral(): - - def __init__(self, cfg_plots_path): - with open(cfg_plots_path, 'r') as f: - self.cfg_plots = yaml.safe_load(f) - with open("./cfg_plots/scaling_thresholds.yaml", 'r') as f: - self.scaling_thresholds = yaml.safe_load(f) - - def _get_scaling_thresholds(self, cfg_plot, test_obj): - if test_obj in self.scaling_thresholds: - return self.scaling_thresholds[test_obj] - if any("Muon" in x for x in cfg_plot["test_objects"]): - return self.scaling_thresholds["Muon"] - if any("Elec" in x or "Photon" in x for x in cfg_plot["test_objects"]): - return self.scaling_thresholds["EG"] - if any("MHT" in x for x in cfg_plot["test_objects"]): - return self.scaling_thresholds["MHT"] - if any("MET" in x for x in cfg_plot["test_objects"]): - return self.scaling_thresholds["MET"] - if any(("HT" in x) and ("MHT" not in x) for x in cfg_plot["test_objects"]): - return self.scaling_thresholds["HT"] - if any("Tau" in x for x in cfg_plot["test_objects"]): - return self.scaling_thresholds["Tau"] - if any("Jet" in x for x in cfg_plot["test_objects"]): - return self.scaling_thresholds["Jet"] - raise RuntimeError( - "Failed to find thresholds in cfg_scaling_thresholds!" - ) - - def _rate_config_function(self, name: str, a: float, b: float): - pm = '+' if b < 0 else '' - f_string = (f"function :: {name}OfflineEtCut :: " - f"args:=(offline); lambda:=(offline{pm}{-b:.3f})/{a:.3f}") - return f_string - - def _write_scalings_to_file(self, - plot_name: str, - version: str, - params: dict): - with open(f"outputs/{version}/scalings/{plot_name}_scalings_{version}.txt", 'w+') as f: - f.write('') - - with open(f"outputs/{version}/scalings/{plot_name}_scalings_{version}.txt", 'a') as f: - for obj, obj_params in params.items(): - a, b = obj_params - f.write(self._rate_config_function(obj, a, b) + "\n") - - def run(self): - for plot_name, cfg_plot in self.cfg_plots.items(): - if "scalings" not in cfg_plot: - continue - print(f">>> Scalings {plot_name} <<<") - - scalings = {x: {} for x in cfg_plot["test_objects"]} - - for test_obj in cfg_plot["test_objects"]: - scal = {test_obj: {}} - thds = self._get_scaling_thresholds(cfg_plot, test_obj) - bar = IncrementalBar("Progress", max=len(thds)) - for threshold in thds: - bar.next() - turnon_collection = TurnOnCollection(cfg_plot, threshold) - turnon_collection.create_hists() - scaling_pct = turnon_collection.cfg_plot.scaling_pct - method = turnon_collection.cfg_plot.scaling_method - scaling_collect = ScalingCollection(cfg_plot, - method, - scaling_pct) - version = turnon_collection.version - scal = scaling_collect._compute_scalings(turnon_collection, - test_obj, - scal, - scaling_pct, - method) - bar.finish() - scalings[test_obj] = scal[test_obj] - - params = scaling_collect._fit_linear_functions(scalings) - if params: - plotter = ScalingPlotter(plot_name, cfg_plot, scalings, - scaling_pct, version, params) - plotter.plot() - self._write_scalings_to_file(plot_name, version, params) - - -if __name__ == "__main__": - parser = argparse.ArgumentParser() - parser.add_argument( - "cfg_plots", - default="cfg_plots/muons.yaml", - help="Path of YAML file specifying the desired plots." - ) - args = parser.parse_args() - - plotter = EfficiencyCentral(args.cfg_plots) - plotter.run() - - scalings = ScalingCentral(args.cfg_plots) - scalings.run() - diff --git a/objectPerformance/src/quality_obj.py b/objectPerformance/src/quality_obj.py deleted file mode 100644 index 8d256b68..00000000 --- a/objectPerformance/src/quality_obj.py +++ /dev/null @@ -1,185 +0,0 @@ -class L1IsoCut(): - - def __init__(self, ak_arrays, obj: str, IsoBB=-1, IsoEE=-1, l1_iso="iso"): - ak_arrays = ak_arrays[obj] # TODO: remove obj arg - self.IsoBB = IsoBB - self.IsoEE = IsoEE - self.l1_iso = l1_iso - - self.sel_iso_BB = ak_arrays['eta'] > -100 - self.sel_iso_EE = ak_arrays['eta'] > -100 - - if self.IsoBB >= 0: - self.sel_iso_BB = ((abs(ak_arrays['eta']) < 1.479) - & (ak_arrays[self.l1_iso] > self.IsoBB)) - if self.IsoEE >= 0: - self.sel_iso_EE = ((abs(ak_arrays['eta']) > 1.479) - & (ak_arrays[self.l1_iso] > self.IsoEE)) - - @property - def ISO_EEBB(self): - return self.sel_iso_EE | self.sel_iso_BB - - -class Quality(): - """ - Class implementing the L1 quality criteria. - Hardware criteria to be decide with Menu team. - """ - - def __init__(self, ak_arrays, obj: str): - ak_arrays = ak_arrays[obj] # TODO: remove obj arg - #print("Computing quality for ", obj) - - self.sel_lowEta = ((abs(ak_arrays['eta']) < 0.9) - & (ak_arrays['region'] != 1)) - self.sel_midEta = ((abs(ak_arrays['eta']) > 0.9) - & (abs(ak_arrays['eta']) < 1.2) - & (ak_arrays['region'] != 2)) - self.sel_highEta = ((abs(ak_arrays['eta']) > 1.2) - & (ak_arrays['region'] != 3)) - - self.sel_qualities = ((ak_arrays['quality'] != 11) - & (ak_arrays['quality'] != 13) - & (ak_arrays['quality'] != 14) - & (ak_arrays['quality'] != 15) - & (ak_arrays['region'] == 3)) - self.sel_qual_12 = ((ak_arrays['quality'] < 12) - & (ak_arrays['region'] == 2)) - self.sel_qual_0 = ((ak_arrays['quality'] == 0) - & (ak_arrays['region'] == 3)) - self.sel_qual_1 = ((ak_arrays['quality'] < 2) - & (ak_arrays['region'] == 1)) - self.sel_qual_3 = ((ak_arrays['quality'] != 3) - & (ak_arrays['region'] == 1)) - self.sel_qual_5 = ((ak_arrays['quality'] != 5) - & (ak_arrays['region'] == 1)) - self.sel_qualOnly_12 = (ak_arrays['quality'] < 12) - - self.sel_midEta_qual = ((abs(ak_arrays['eta']) > 0.9) - & (abs(ak_arrays['eta']) < 1.2) - & (ak_arrays['region'] == 3)) - - self.sel_odd = (ak_arrays['quality'] % 2 == 0) - self.sel_odd_type = ((ak_arrays['quality'] % 2 == 0) - & (ak_arrays['region'] == 1)) - self.sel_not_4 = (ak_arrays['region'] == 4) - - - ### EG IDs from 123x - self.sel_tkIsoPho_123 = ((ak_arrays['quality'] > 0 ) & (abs(ak_arrays['eta']) < 1.479)) | ((ak_arrays['quality'] == 3 ) & (abs(ak_arrays['eta']) >= 1.479)) - - - ## EG IDs from 125x - # for EG: region == HGC - if "passeseleid" in ak_arrays.fields: - self.sel_EG_barrelID = (ak_arrays['region'] == 0) & (ak_arrays['passeseleid'] == 1) - else: - self.sel_EG_barrelID = (ak_arrays['region'] == 0) & (((ak_arrays['quality'] >> 1)&1) > 0) - - if "passessaid" in ak_arrays.fields: - self.sel_EG_endcapID = (ak_arrays['region'] == 1) & (ak_arrays['passessaid'] == 1) - else: - self.sel_EG_endcapID = (ak_arrays['region'] == 1) & (((ak_arrays['quality'] >> 0)&1) > 0) - - # for EG: quality = HwQual, alt approach: use HW qual bits directly instead of the menu ntuple variables: bit0: SA, 1: Ele, 2: Pho - #self.sel_EG_barrelID = (ak_arrays['region'] == 0) & (((ak_arrays['quality'] >> 1)&1) > 0) - #self.sel_EG_endcapID = (ak_arrays['region'] == 1) & (((ak_arrays['quality'] >> 0)&1) > 0) - - ## tkPhoton from 125x - #self.sel_tkPho_barrelID = (ak_arrays['region'] == 0) & (ak_arrays['passeseleid'] == 1) - #self.sel_tkPho_endcapID = (ak_arrays['region'] == 1) & (ak_arrays['passesphoid'] == 1) - if "passesphoid" in ak_arrays.fields: - self.sel_tkPho_endcapID = (ak_arrays['region'] == 1) & (ak_arrays['passesphoid'] == 1) - else: - self.sel_tkPho_endcapID = (ak_arrays['region'] == 1) & (((ak_arrays['quality'] >> 2)&1) > 0) - - #self.sel_tkPho_barrelID = (ak_arrays['region'] == 0) & (((ak_arrays['quality'] >> 1)&1) > 0) - #self.sel_tkPho_endcapID = (ak_arrays['region'] == 1) & (((ak_arrays['quality'] >> 2)&1) > 0) - - @property - def QUAL_125x_EGID(self): - return ~(self.sel_EG_barrelID | self.sel_EG_endcapID) - - @property - def QUAL_125x_tkPhoID(self): - #return ~(self.sel_tkPho_barrelID | self.sel_tkPho_endcapID) - return ~(self.sel_EG_barrelID | self.sel_tkPho_endcapID) - - @property - def QUAL_123x_tkPhoID(self): - return ~(self.sel_tkIsoPho_123) - - @property - def QUAL_Overlap12EndcapJaana1345(self): - return self.sel_qual_12 | self.sel_qualities - - @property - def QUAL_OverlapNotRegion3(self): - return self.sel_midEta_qual - - @property - def QUAL_Endcap1OverlapNotRegion3(self): - return self.sel_midEta_qual | self.sel_qual_0 - - @property - def QUAL_Overlap12(self): - return self.sel_qual_12 - - @property - def QUAL_BarrelNoneEndcap3(self): - return self.sel_qual_3 - - @property - def QUAL_CorrectRegion(self): - return self.sel_lowEta | self.sel_midEta | self.sel_highEta - - @property - def QUAL_Endcap1CorrectRegion(self): - return (self.sel_lowEta | self.sel_midEta | self.sel_highEta - | self.sel_qual_0) - - @property - def QUAL_BarrelOddEndcap2(self): - return self.sel_odd_type | self.sel_qual_1 - - @property - def QUAL_BarrelNoneEndcap5(self): - return self.sel_qual_5 - - @property - def QUAL_Overlap12Endcap1(self): - return self.sel_qual_12 | self.sel_qual_0 - - @property - def QUAL_Endcap1(self): - return self.sel_qual_0 - - @property - def QUAL_Odd(self): - return self.sel_odd - - @property - def QUAL_Overlap12Endcap1CorrectRegion(self): - return (self.sel_lowEta | self.sel_midEta | self.sel_highEta - | self.sel_qual_12 | self.sel_qual_0) - - @property - def QUAL_12(self): - return self.sel_qualOnly_12 - - @property - def QUAL_RegionNotFour(self): - return self.sel_not_4 - - @property - def QUAL_Overlap12Endcap1OverlapNotRegion3(self): - return self.sel_midEta_qual | self.sel_qual_12 | self.sel_qual_0 - - @property - def QUAL_BarrelNoneEndcap2(self): - return self.sel_qual_1 - - @property - def QUAL_EndcapJaana1345(self): - return self.sel_qualities diff --git a/objectPerformance/src/scaling_collection.py b/objectPerformance/src/scaling_collection.py deleted file mode 100644 index a3f3cee0..00000000 --- a/objectPerformance/src/scaling_collection.py +++ /dev/null @@ -1,283 +0,0 @@ -#!/afs/cern.ch/user/d/dhundhau/public/miniconda3/envs/py310/bin/python -from scipy.optimize import curve_fit -import numpy as np - -from plot_config import PlotConfig -import utils - - -class ScalingCollection(): - """ - Collection of scaling values corresponding to one - scaling plot. This requires the input of multiple - turnon_collections, i.e. a single threshold but multiple - objects. - """ - - def __init__(self, - cfg: PlotConfig, - method: str, - plateau_pct: float = 0.95): - self.cfg = cfg - self.method = method - self.plateau_pct = plateau_pct - self.scalings = {x: {} for x in self.cfg["test_objects"]} - self.fit_function_params = None - - def _find_percentage_point(self, hist, bins, scaling_pct): - for i, eff in enumerate(hist[:-2]): - is_point = ( - eff < scaling_pct - and hist[i + 1] > scaling_pct - and hist[i + 2] > scaling_pct - ) - if is_point: - return bins[i + 1] - - def _find_turnon_cut(self, graph_x, graph_y, Target): - L = 0 - R = np.max(graph_x) - - while (R - L > 0.0001): - C = (L + R) / 2 - V = self._get_point_on_curve(C, graph_x, graph_y) - - if (V < Target): - L = C - else: - R = C - - return (R + L) / 2. - - def _find_turnon_fit(self, function, popt, _min, _max, target): - if ((function(_min, *popt) > target) - | (function(_max, *popt) < target)): - return -1000 - - L = _min - R = _max - - while (R - L > 0.0001): - C = (L + R) / 2 - V = function(C, *popt) - - if (V < target): - L = C - else: - R = C - - return (R + L) / 2 - - @utils.ignore_warnings - def _compute_value_of_tanh_at_threshold(self, - efficiency, - bins, - threshold): - xvals = np.array(bins) - efficiency = np.array(efficiency) - - xvals = xvals[~np.isnan(efficiency)] - efficiency = efficiency[~np.isnan(efficiency)] - - popt, pcov = curve_fit(utils.tanh, xvals, efficiency, p0=[1, 0]) - if np.inf in pcov: - return None - - s_val = utils.arctanh(threshold, *list(popt)) - - return s_val - - @utils.ignore_warnings - def _compute_value_of_errf_at_threshold(self, - efficiency, - bins, - scaling_pct): - xvals = np.array(bins) - efficiency = np.array(efficiency) - - xvals = xvals[~np.isnan(efficiency)] - efficiency = efficiency[~np.isnan(efficiency)] - - popt, pcov = curve_fit(utils.errf, xvals, efficiency, - p0=[0.02, 80, 20, 1, np.min(efficiency)] - ) - - s_val = self._find_turnon_fit(utils.errf, popt, - np.min(xvals), np.max(xvals) * 10, - scaling_pct * utils.errf(10000, *popt) - ) - - return s_val - - def _interpolate(self, H, K1, K2): - - A = np.ones(len(K1)) * (-K2) - B = [k1i + 2 * K2 for k1i in K1] - C = np.ones(len(K1)) * (-K2) - D = [] - - A[0] = 0 - C[-1] = 0 - - D = [k1i * h1i for k1i, h1i in zip(K1, H)] - - D[0] = D[0] + K2 * 0 - D[-1] = D[-1] + K2 * 1 - - for i in range(1, len(K1)): - F = A[i] / B[i - 1] - - A[i] = A[i] - B[i - 1] * F - B[i] = B[i] - C[i - 1] * F - C[i] = C[i] - D[i] = D[i] - D[i - 1] * F - - Y = np.ones(len(K1)) - Y[-1] = D[-1] / B[-1] - - for i in reversed(range(len(K1) - 2)): - Y[i] = (D[i] - C[i] * Y[i + 1]) / B[i] - - return Y - - def _get_point_on_curve(self, x, graph_x, graph_y): - - if (x < graph_x[0]): - return 0 - - if (x >= graph_x[len(graph_x) - 1]): - return 1 - - xr = graph_x[0] - yr = graph_y[0] - for i in range(len(graph_x) - 1): - xl = xr - yl = yr - xr = graph_x[i + 1] - yr = graph_y[i + 1] - if ((x < xr) & (x >= xl)): - return yl + (yr - yl) / (xr - xl) * (x - xl) - - return -1 - - def _compute_scalings_naive(self, - turnon_collection, - test_obj, - scalings, - scaling_pct): - bins = turnon_collection.bins - bins = 0.5 * (bins[1:] + bins[:-1]) - threshold = turnon_collection.threshold - - for obj_key, gen_hist_trig in turnon_collection.hists.items(): - if ((obj_key == "ref") | (obj_key != test_obj)): - continue - efficiency, yerr = turnon_collection.get_efficiency(obj_key) - - xbins = bins - xbins = xbins[~np.isnan(efficiency)] - er_dn = yerr[0] - er_up = yerr[1] - er_dn = er_dn[~np.isnan(efficiency)] - er_up = er_up[~np.isnan(efficiency)] - efficiency = efficiency[~np.isnan(efficiency)] - - K1 = [] - for i in range(len(efficiency)): - K1.append(1 / (er_dn[i] + er_up[i]) / (er_up[i] + er_dn[i])) - - percentage_point = self._find_turnon_cut( - xbins, - self._interpolate(efficiency, K1, 100), - scaling_pct - ) - if percentage_point: - scalings[obj_key][threshold] = percentage_point - - return scalings - - def _compute_scalings_tanh(self, - turnon_collection, - test_obj, - scalings, - scaling_pct): - bins = turnon_collection.bins - bins = 0.5 * (bins[1:] + bins[:-1]) - threshold = turnon_collection.threshold - - for obj_key, gen_hist_trig in turnon_collection.hists.items(): - if ((obj_key == "ref") | (obj_key != test_obj)): - continue - efficiency, _ = turnon_collection.get_efficiency(obj_key) - percentage_point = self._compute_value_of_tanh_at_threshold( - efficiency, - bins, - scaling_pct - ) - if percentage_point: - scalings[obj_key][threshold] = percentage_point - - return scalings - - def _compute_scalings_errf(self, - turnon_collection, - test_obj, - scalings, - scaling_pct): - bins = turnon_collection.bins - bins = 0.5 * (bins[1:] + bins[:-1]) - threshold = turnon_collection.threshold - - for obj_key, gen_hist_trig in turnon_collection.hists.items(): - if ((obj_key == "ref") | (obj_key != test_obj)): - continue - efficiency, _ = turnon_collection.get_efficiency(obj_key) - percentage_point = self._compute_value_of_errf_at_threshold( - efficiency, - bins, - scaling_pct - ) - if percentage_point: - scalings[obj_key][threshold] = percentage_point - - return scalings - - def _compute_scalings(self, turnon_collection, test_obj, scalings, - scaling_pct, method="tanh") -> dict: - if method == "tanh": - return self._compute_scalings_tanh( - turnon_collection, - test_obj, - scalings, - scaling_pct - ) - if method == "errf": - return self._compute_scalings_errf( - turnon_collection, - test_obj, - scalings, - scaling_pct - ) - if method == "naive": - return self._compute_scalings_naive( - turnon_collection, - test_obj, - scalings, - scaling_pct - ) - - def _fit_linear_functions(self, scalings): - params = {} - for obj, thresh_points in scalings.items(): - xdata = [th for th, val in thresh_points.items() if val] - ydata = [thresh_points[x] for x in xdata] - if not ydata: - return None - popt, pcov = curve_fit(utils.scaling_func, xdata, ydata) - params[obj] = popt - return params - - -if __name__ == "__main__": - pass - diff --git a/objectPerformance/tests/conftest.py b/objectPerformance/tests/conftest.py deleted file mode 100644 index 620881ce..00000000 --- a/objectPerformance/tests/conftest.py +++ /dev/null @@ -1,35 +0,0 @@ -import pytest - - -@pytest.fixture -def met_config(): - cfg_plot = { - "sample": "TT", - "default_version": "V22", - "reference_object": { - "object": "genMetTrue", - "suffix": "", - "label": "Gen MET" - }, - "test_objects": { - "trackerMET": { - "suffix": "", - "label": "Tracker MET" - }, - "puppiMET": { - "suffix": "Et", - "label": "Puppi MET" - }, - }, - "binning": {"min": 0, "max": 500, "step": 20}, - "trackerMETTruth": [17671, 8214, 6463, 5321, 4212, 3308, 2453, 1811, - 1146, 759, 482, 307, 261, 154, 93, 73, 61, 32, 22, - 18, 20, 14, 8, 7], - "puppiMETTruth": [31222, 14025, 13874, 13621, 11387, 8429, 5670, 3644, - 2133, 1306, 766, 460, 352, 222, 145, 98, 81, 45, 29, - 21, 24, 15, 9, 7], - "genMETTruth": [130238, 51518, 40197, 29181, 18620, 11269, 6729, 3975, - 2255, 1353, 791, 470, 355, 225, 148, 98, 81, 45, 30, - 21, 25, 15, 9, 7], - } - return cfg_plot diff --git a/objectPerformance/tests/test_integration.py b/objectPerformance/tests/test_integration.py deleted file mode 100644 index e2c04709..00000000 --- a/objectPerformance/tests/test_integration.py +++ /dev/null @@ -1,28 +0,0 @@ -from turnon_collection import TurnOnCollection - - -def off_test_turnon_collection_met(met_config): - """ - This integration test tests whether the MET histograms for the - MET plots for V22 are produced as expected. The cache files - included in the test directory should lead to the bin values - specified below. - """ - turnon_collection = TurnOnCollection(met_config, 70) - turnon_collection.create_hists() - - assert all([x == y for x, y in zip( - list(turnon_collection.hists["trackerMET"][0]), - met_config["trackerMETTruth"] - )]) - - assert all([x == y for x, y in zip( - list(turnon_collection.hists["puppiMET"][0]), - met_config["puppiMETTruth"] - )]) - - assert all([x == y for x, y in zip( - list(turnon_collection.hists["ref"][0]), - met_config["genMETTruth"] - )]) - diff --git a/objectPerformance/tests/test_turnon_collection.py b/objectPerformance/tests/test_turnon_collection.py deleted file mode 100644 index b887d795..00000000 --- a/objectPerformance/tests/test_turnon_collection.py +++ /dev/null @@ -1,43 +0,0 @@ -from unittest.mock import MagicMock - -import awkward as ak - -from turnon_collection import TurnOnCollection - - -def test_select_highest_pt_ref_object(): - """ - Tests that no more than one reference object per event is - selected. If there are multiple reference objects in the event - the highest pt one should be selected. If there are no reference - objects in the event, the selection should yield an empty array - element. - """ - # Set up mock TurnOnCollection object - TurnOnCollection._set_bins = MagicMock() - turnon_collection = TurnOnCollection(None, None) - arr_content = [[], [None]] + [ - [float(f"{i}.{k}") for k in range(3)] - for i in range(5) - ] - idx_empty = [i for i, x in enumerate(arr_content) - if len(x) == 0 or x[0] is None] - turnon_collection.ak_arrays = {} - turnon_collection.ak_arrays["ref"] = ak.Array({ - "pt": arr_content, - "other": arr_content - }) - - # Execute selection of highest pt reference object - turnon_collection._select_highest_pt_ref_object() - ref_objects = turnon_collection.ak_arrays["ref"] - - # Assert outcome of selection as expected - # The number of events should remain unchanged in all variables - assert len(arr_content) == len(ref_objects["pt"]) - assert len(arr_content) == len(ref_objects["other"]) - # Each event should contain exactly one refernce object or a None entry - assert all(ak.num(ref_objects["pt"], axis=-1) == 1) - assert all(ak.num(ref_objects["other"], axis=-1) == 1) - # Events without reference objects should contain a None entry - assert all([not ref_objects["pt"][i] for i in idx_empty]) diff --git a/poetry.lock b/poetry.lock new file mode 100644 index 00000000..41c933fc --- /dev/null +++ b/poetry.lock @@ -0,0 +1,1239 @@ +# This file is automatically @generated by Poetry 1.7.1 and should not be changed by hand. + +[[package]] +name = "awkward" +version = "2.5.2" +description = "Manipulate JSON-like data with NumPy-like idioms." +optional = false +python-versions = ">=3.8" +files = [ + {file = "awkward-2.5.2-py3-none-any.whl", hash = "sha256:6b6cbb62cdafb65457c4672980735a2b2e635a5eda5570a51459b4e42359ceb5"}, + {file = "awkward-2.5.2.tar.gz", hash = "sha256:34f4b440684b2e20f23b1a406aa3da4ecdf4fdb5fa0e076d5d337e955dee8ab6"}, +] + +[package.dependencies] +awkward-cpp = "28" +importlib-metadata = {version = ">=4.13.0", markers = "python_version < \"3.12\""} +numpy = ">=1.18.0" +packaging = "*" + +[[package]] +name = "awkward-cpp" +version = "28" +description = "CPU kernels and compiled extensions for Awkward Array" +optional = false +python-versions = ">=3.8" +files = [ + {file = "awkward-cpp-28.tar.gz", hash = "sha256:304ebbf900c577368fd3c491a4ddfe6a5790bdec76a2b06bdcc4728176264592"}, + {file = "awkward_cpp-28-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:d7f995056387fb3d004d45012fd15eccdedee5613a331c18941caf9c2670353d"}, + {file = "awkward_cpp-28-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d8540242144067b2ef76eae0bcfa4ae7ac188f3b6160c815ce8cb95ef5fdad32"}, + {file = "awkward_cpp-28-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:45b0cff5955e78f4208735e95c9f6ef5c79f9c0df857baa418ff9f0386c71af6"}, + {file = "awkward_cpp-28-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9c7c726430b328aa1e3d82af5fbf25e78ab1088f3ea9cfb752efffa4ca812496"}, + {file = "awkward_cpp-28-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:31069d5d0c26be0086a5b37c9c4212b9d232c9d54a16ec4b47292bd0ebd085df"}, + {file = "awkward_cpp-28-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:8f2136fa34837632ecc4d68bae41d2518bb92b60ca52aa2f5d3f3a7c0017c6a2"}, + {file = "awkward_cpp-28-cp310-cp310-win_amd64.whl", hash = "sha256:312360d76888b5114a38bcbd9ad5179e939acc0873033cf08cb8c272a15fa6e9"}, + {file = "awkward_cpp-28-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:ff429cc7fedc1fddbe9726256ea03265c0ab14fb200ae5d787bb2bed149cf592"}, + {file = "awkward_cpp-28-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:14ed98a25528e2517ca660638ca72217441b3817d59cf78ea10ccac9230f3749"}, + {file = "awkward_cpp-28-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:26d21c444e5a83c0e4fa74f1cf1505f7c4083e23be1af2cd8191b9e181b181b4"}, + {file = "awkward_cpp-28-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8cbc55e27117bf5ab26b514ddd11a0cadd847eec50dd4b8833fd65be126f46d5"}, + {file = "awkward_cpp-28-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:4737ea0c337b35ee586078bc2ba41eb2f4b771108f551bc63fab6c73d2a9fc5e"}, + {file = "awkward_cpp-28-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:286f5288ad21f0296a8c4182a360c141c8dd000b6eb2fa03696ba5f2c632bd95"}, + {file = "awkward_cpp-28-cp311-cp311-win_amd64.whl", hash = "sha256:0be97d9ca36068878b18a307f919e55bb4e9538fb46432c7492bab3e64bc8251"}, + {file = "awkward_cpp-28-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:d5cc1a7a6871dcaba33986bb634c9d4e6e58c6f3324f58db1884a171d1b74d11"}, + {file = "awkward_cpp-28-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:4ce8def0cd6df1507876664a1714242016e52265fd715eaba57b8fe9dd978e40"}, + {file = "awkward_cpp-28-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e4419c82cdd6095471334b0bdb197c507598ffdb89b01e0bae2f04077a77b1b"}, + {file = "awkward_cpp-28-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f38e6198a9dcc4693b347c035db996f89d4407a3f6cf4cbae7d00aa8eedf8f57"}, + {file = "awkward_cpp-28-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:facc2c40ed566fe25f376eae9743ad147d900c1beb7d3dc3f592669907314a1f"}, + {file = "awkward_cpp-28-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:9f0cceb35aeee70f53f03814c3a3dac06c3514eec3149e09dbd0b9e723215145"}, + {file = "awkward_cpp-28-cp312-cp312-win_amd64.whl", hash = "sha256:59ec43807b8f999c855250f464316e4ecb2e3737feb26bd996df281032c7eabc"}, + {file = "awkward_cpp-28-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:cc28f0a4528ac722979efcf970ff82fd2bcf9fa74ea70b9e3797de9182f2cd6b"}, + {file = "awkward_cpp-28-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:2991ca89342e1b7ff1a803335506ead04fc83232bb1610de5321823158b18792"}, + {file = "awkward_cpp-28-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c8d4f7da0d48a8e612b43b14f679a5546b758e2fea66bbb2fd515c410055c9be"}, + {file = "awkward_cpp-28-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ccfc10ee04d29de244a76b9cc5f2855a1a1aa73aba1a60ab68279fa085fae583"}, + {file = "awkward_cpp-28-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:cb6e81d67f40bac7d2335e6169f1065bd53af055f952347428ea7470b08f32ec"}, + {file = "awkward_cpp-28-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:17074f0354faa956aab651b578658e2d988a3974a7b0b57c54a377451240cf25"}, + {file = "awkward_cpp-28-cp38-cp38-win32.whl", hash = "sha256:2d4d40d8656f93d9df388c98083f135764bea66f7501ecf4b674427a17625aae"}, + {file = "awkward_cpp-28-cp38-cp38-win_amd64.whl", hash = "sha256:f7ce31e9c46f50adf534ca8c95a2fc97dd4e2409a95047785c84558a35996208"}, + {file = "awkward_cpp-28-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:504c1827dc301b43e80fa2223f22c7c4a30d45799fe07a5f921858d78081fd2f"}, + {file = "awkward_cpp-28-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:dba4f11f362ace07820ad0340a4d94a8a08aad9b57e44839dd6ba76761e90bab"}, + {file = "awkward_cpp-28-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a787dbd2882c232cf61c76caf13610334de5d5badff269fc49c4f6a7e13a87cd"}, + {file = "awkward_cpp-28-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9eaf046c3ea8b65e9340e88483271c8540e1d3c76d41afa495574e2b47117cc6"}, + {file = "awkward_cpp-28-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:22ce5406055bcc73720f76ae0dc1a12fbaaa22b00ca924688478d413a3ebfa7f"}, + {file = "awkward_cpp-28-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:7d9407d051272c020c6ffea0a51a062bc44c8b5fda6e911f38faee0126d9e624"}, + {file = "awkward_cpp-28-cp39-cp39-win32.whl", hash = "sha256:26afc25e86c3631999f4188d5e173ce60ffc0125d1c69b17136d1fade3748fdf"}, + {file = "awkward_cpp-28-cp39-cp39-win_amd64.whl", hash = "sha256:4098c799897a94fdf26224a8e57064096e5918c44a2c33f280641970a595186c"}, + {file = "awkward_cpp-28-pp310-pypy310_pp73-macosx_10_9_x86_64.whl", hash = "sha256:b16a452644db24544403cb8a9fe4f47a63841f7625b9febf021a70f2331dd12e"}, + {file = "awkward_cpp-28-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:abb01c5abc00cb77225f64c205da5b05a1a9a7544c388c0d3a1c811e0d1dfe18"}, + {file = "awkward_cpp-28-pp38-pypy38_pp73-macosx_10_9_x86_64.whl", hash = "sha256:9dc49bffe7f096708b3e2b1455df1d1ba3e999c6bcd3b186873d13fb015fc090"}, + {file = "awkward_cpp-28-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:66d3171519caab2b10161b682839b59155b7001b1d1199230d9e137b309e5caa"}, + {file = "awkward_cpp-28-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:240479e25e83f08fe6cf93e6abb6eed1b83bf6cbf1a8ed894b2b4568ba17250f"}, + {file = "awkward_cpp-28-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dda7cebbafa71742d65f9ad10f4820ec12c257cb3ac3e250698d8b2e4acb9491"}, +] + +[package.dependencies] +numpy = ">=1.18.0" + +[[package]] +name = "black" +version = "23.12.1" +description = "The uncompromising code formatter." +optional = false +python-versions = ">=3.8" +files = [ + {file = "black-23.12.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:e0aaf6041986767a5e0ce663c7a2f0e9eaf21e6ff87a5f95cbf3675bfd4c41d2"}, + {file = "black-23.12.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:c88b3711d12905b74206227109272673edce0cb29f27e1385f33b0163c414bba"}, + {file = "black-23.12.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a920b569dc6b3472513ba6ddea21f440d4b4c699494d2e972a1753cdc25df7b0"}, + {file = "black-23.12.1-cp310-cp310-win_amd64.whl", hash = "sha256:3fa4be75ef2a6b96ea8d92b1587dd8cb3a35c7e3d51f0738ced0781c3aa3a5a3"}, + {file = "black-23.12.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:8d4df77958a622f9b5a4c96edb4b8c0034f8434032ab11077ec6c56ae9f384ba"}, + {file = "black-23.12.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:602cfb1196dc692424c70b6507593a2b29aac0547c1be9a1d1365f0d964c353b"}, + {file = "black-23.12.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9c4352800f14be5b4864016882cdba10755bd50805c95f728011bcb47a4afd59"}, + {file = "black-23.12.1-cp311-cp311-win_amd64.whl", hash = "sha256:0808494f2b2df923ffc5723ed3c7b096bd76341f6213989759287611e9837d50"}, + {file = "black-23.12.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:25e57fd232a6d6ff3f4478a6fd0580838e47c93c83eaf1ccc92d4faf27112c4e"}, + {file = "black-23.12.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:2d9e13db441c509a3763a7a3d9a49ccc1b4e974a47be4e08ade2a228876500ec"}, + {file = "black-23.12.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6d1bd9c210f8b109b1762ec9fd36592fdd528485aadb3f5849b2740ef17e674e"}, + {file = "black-23.12.1-cp312-cp312-win_amd64.whl", hash = "sha256:ae76c22bde5cbb6bfd211ec343ded2163bba7883c7bc77f6b756a1049436fbb9"}, + {file = "black-23.12.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:1fa88a0f74e50e4487477bc0bb900c6781dbddfdfa32691e780bf854c3b4a47f"}, + {file = "black-23.12.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:a4d6a9668e45ad99d2f8ec70d5c8c04ef4f32f648ef39048d010b0689832ec6d"}, + {file = "black-23.12.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b18fb2ae6c4bb63eebe5be6bd869ba2f14fd0259bda7d18a46b764d8fb86298a"}, + {file = "black-23.12.1-cp38-cp38-win_amd64.whl", hash = "sha256:c04b6d9d20e9c13f43eee8ea87d44156b8505ca8a3c878773f68b4e4812a421e"}, + {file = "black-23.12.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:3e1b38b3135fd4c025c28c55ddfc236b05af657828a8a6abe5deec419a0b7055"}, + {file = "black-23.12.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4f0031eaa7b921db76decd73636ef3a12c942ed367d8c3841a0739412b260a54"}, + {file = "black-23.12.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:97e56155c6b737854e60a9ab1c598ff2533d57e7506d97af5481141671abf3ea"}, + {file = "black-23.12.1-cp39-cp39-win_amd64.whl", hash = "sha256:dd15245c8b68fe2b6bd0f32c1556509d11bb33aec9b5d0866dd8e2ed3dba09c2"}, + {file = "black-23.12.1-py3-none-any.whl", hash = "sha256:78baad24af0f033958cad29731e27363183e140962595def56423e626f4bee3e"}, + {file = "black-23.12.1.tar.gz", hash = "sha256:4ce3ef14ebe8d9509188014d96af1c456a910d5b5cbf434a09fef7e024b3d0d5"}, +] + +[package.dependencies] +click = ">=8.0.0" +mypy-extensions = ">=0.4.3" +packaging = ">=22.0" +pathspec = ">=0.9.0" +platformdirs = ">=2" + +[package.extras] +colorama = ["colorama (>=0.4.3)"] +d = ["aiohttp (>=3.7.4)", "aiohttp (>=3.7.4,!=3.9.0)"] +jupyter = ["ipython (>=7.8.0)", "tokenize-rt (>=3.2.0)"] +uvloop = ["uvloop (>=0.15.2)"] + +[[package]] +name = "click" +version = "8.1.7" +description = "Composable command line interface toolkit" +optional = false +python-versions = ">=3.7" +files = [ + {file = "click-8.1.7-py3-none-any.whl", hash = "sha256:ae74fb96c20a0277a1d615f1e4d73c8414f5a98db8b799a7931d1582f3390c28"}, + {file = "click-8.1.7.tar.gz", hash = "sha256:ca9853ad459e787e2192211578cc907e7594e294c7ccc834310722b41b9ca6de"}, +] + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + +[[package]] +name = "colorama" +version = "0.4.6" +description = "Cross-platform colored terminal text." +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=2.7" +files = [ + {file = "colorama-0.4.6-py2.py3-none-any.whl", hash = "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6"}, + {file = "colorama-0.4.6.tar.gz", hash = "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44"}, +] + +[[package]] +name = "contourpy" +version = "1.2.0" +description = "Python library for calculating contours of 2D quadrilateral grids" +optional = false +python-versions = ">=3.9" +files = [ + {file = "contourpy-1.2.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:0274c1cb63625972c0c007ab14dd9ba9e199c36ae1a231ce45d725cbcbfd10a8"}, + {file = "contourpy-1.2.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:ab459a1cbbf18e8698399c595a01f6dcc5c138220ca3ea9e7e6126232d102bb4"}, + {file = "contourpy-1.2.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6fdd887f17c2f4572ce548461e4f96396681212d858cae7bd52ba3310bc6f00f"}, + {file = "contourpy-1.2.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5d16edfc3fc09968e09ddffada434b3bf989bf4911535e04eada58469873e28e"}, + {file = "contourpy-1.2.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1c203f617abc0dde5792beb586f827021069fb6d403d7f4d5c2b543d87edceb9"}, + {file = "contourpy-1.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b69303ceb2e4d4f146bf82fda78891ef7bcd80c41bf16bfca3d0d7eb545448aa"}, + {file = "contourpy-1.2.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:884c3f9d42d7218304bc74a8a7693d172685c84bd7ab2bab1ee567b769696df9"}, + {file = "contourpy-1.2.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:4a1b1208102be6e851f20066bf0e7a96b7d48a07c9b0cfe6d0d4545c2f6cadab"}, + {file = "contourpy-1.2.0-cp310-cp310-win32.whl", hash = "sha256:34b9071c040d6fe45d9826cbbe3727d20d83f1b6110d219b83eb0e2a01d79488"}, + {file = "contourpy-1.2.0-cp310-cp310-win_amd64.whl", hash = "sha256:bd2f1ae63998da104f16a8b788f685e55d65760cd1929518fd94cd682bf03e41"}, + {file = "contourpy-1.2.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:dd10c26b4eadae44783c45ad6655220426f971c61d9b239e6f7b16d5cdaaa727"}, + {file = "contourpy-1.2.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:5c6b28956b7b232ae801406e529ad7b350d3f09a4fde958dfdf3c0520cdde0dd"}, + {file = "contourpy-1.2.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ebeac59e9e1eb4b84940d076d9f9a6cec0064e241818bcb6e32124cc5c3e377a"}, + {file = "contourpy-1.2.0-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:139d8d2e1c1dd52d78682f505e980f592ba53c9f73bd6be102233e358b401063"}, + {file = "contourpy-1.2.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1e9dc350fb4c58adc64df3e0703ab076f60aac06e67d48b3848c23647ae4310e"}, + {file = "contourpy-1.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18fc2b4ed8e4a8fe849d18dce4bd3c7ea637758c6343a1f2bae1e9bd4c9f4686"}, + {file = "contourpy-1.2.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:16a7380e943a6d52472096cb7ad5264ecee36ed60888e2a3d3814991a0107286"}, + {file = "contourpy-1.2.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:8d8faf05be5ec8e02a4d86f616fc2a0322ff4a4ce26c0f09d9f7fb5330a35c95"}, + {file = "contourpy-1.2.0-cp311-cp311-win32.whl", hash = "sha256:67b7f17679fa62ec82b7e3e611c43a016b887bd64fb933b3ae8638583006c6d6"}, + {file = "contourpy-1.2.0-cp311-cp311-win_amd64.whl", hash = "sha256:99ad97258985328b4f207a5e777c1b44a83bfe7cf1f87b99f9c11d4ee477c4de"}, + {file = "contourpy-1.2.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:575bcaf957a25d1194903a10bc9f316c136c19f24e0985a2b9b5608bdf5dbfe0"}, + {file = "contourpy-1.2.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:9e6c93b5b2dbcedad20a2f18ec22cae47da0d705d454308063421a3b290d9ea4"}, + {file = "contourpy-1.2.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:464b423bc2a009088f19bdf1f232299e8b6917963e2b7e1d277da5041f33a779"}, + {file = "contourpy-1.2.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:68ce4788b7d93e47f84edd3f1f95acdcd142ae60bc0e5493bfd120683d2d4316"}, + {file = "contourpy-1.2.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3d7d1f8871998cdff5d2ff6a087e5e1780139abe2838e85b0b46b7ae6cc25399"}, + {file = "contourpy-1.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6e739530c662a8d6d42c37c2ed52a6f0932c2d4a3e8c1f90692ad0ce1274abe0"}, + {file = "contourpy-1.2.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:247b9d16535acaa766d03037d8e8fb20866d054d3c7fbf6fd1f993f11fc60ca0"}, + {file = "contourpy-1.2.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:461e3ae84cd90b30f8d533f07d87c00379644205b1d33a5ea03381edc4b69431"}, + {file = "contourpy-1.2.0-cp312-cp312-win32.whl", hash = "sha256:1c2559d6cffc94890b0529ea7eeecc20d6fadc1539273aa27faf503eb4656d8f"}, + {file = "contourpy-1.2.0-cp312-cp312-win_amd64.whl", hash = "sha256:491b1917afdd8638a05b611a56d46587d5a632cabead889a5440f7c638bc6ed9"}, + {file = "contourpy-1.2.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:5fd1810973a375ca0e097dee059c407913ba35723b111df75671a1976efa04bc"}, + {file = "contourpy-1.2.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:999c71939aad2780f003979b25ac5b8f2df651dac7b38fb8ce6c46ba5abe6ae9"}, + {file = "contourpy-1.2.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b7caf9b241464c404613512d5594a6e2ff0cc9cb5615c9475cc1d9b514218ae8"}, + {file = "contourpy-1.2.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:266270c6f6608340f6c9836a0fb9b367be61dde0c9a9a18d5ece97774105ff3e"}, + {file = "contourpy-1.2.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbd50d0a0539ae2e96e537553aff6d02c10ed165ef40c65b0e27e744a0f10af8"}, + {file = "contourpy-1.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:11f8d2554e52f459918f7b8e6aa20ec2a3bce35ce95c1f0ef4ba36fbda306df5"}, + {file = "contourpy-1.2.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:ce96dd400486e80ac7d195b2d800b03e3e6a787e2a522bfb83755938465a819e"}, + {file = "contourpy-1.2.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:6d3364b999c62f539cd403f8123ae426da946e142312a514162adb2addd8d808"}, + {file = "contourpy-1.2.0-cp39-cp39-win32.whl", hash = "sha256:1c88dfb9e0c77612febebb6ac69d44a8d81e3dc60f993215425b62c1161353f4"}, + {file = "contourpy-1.2.0-cp39-cp39-win_amd64.whl", hash = "sha256:78e6ad33cf2e2e80c5dfaaa0beec3d61face0fb650557100ee36db808bfa6843"}, + {file = "contourpy-1.2.0-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:be16975d94c320432657ad2402f6760990cb640c161ae6da1363051805fa8108"}, + {file = "contourpy-1.2.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b95a225d4948b26a28c08307a60ac00fb8671b14f2047fc5476613252a129776"}, + {file = "contourpy-1.2.0-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:0d7e03c0f9a4f90dc18d4e77e9ef4ec7b7bbb437f7f675be8e530d65ae6ef956"}, + {file = "contourpy-1.2.0.tar.gz", hash = "sha256:171f311cb758de7da13fc53af221ae47a5877be5a0843a9fe150818c51ed276a"}, +] + +[package.dependencies] +numpy = ">=1.20,<2.0" + +[package.extras] +bokeh = ["bokeh", "selenium"] +docs = ["furo", "sphinx (>=7.2)", "sphinx-copybutton"] +mypy = ["contourpy[bokeh,docs]", "docutils-stubs", "mypy (==1.6.1)", "types-Pillow"] +test = ["Pillow", "contourpy[test-no-images]", "matplotlib"] +test-no-images = ["pytest", "pytest-cov", "pytest-xdist", "wurlitzer"] + +[[package]] +name = "cycler" +version = "0.12.1" +description = "Composable style cycles" +optional = false +python-versions = ">=3.8" +files = [ + {file = "cycler-0.12.1-py3-none-any.whl", hash = "sha256:85cef7cff222d8644161529808465972e51340599459b8ac3ccbac5a854e0d30"}, + {file = "cycler-0.12.1.tar.gz", hash = "sha256:88bb128f02ba341da8ef447245a9e138fae777f6a23943da4540077d3601eb1c"}, +] + +[package.extras] +docs = ["ipython", "matplotlib", "numpydoc", "sphinx"] +tests = ["pytest", "pytest-cov", "pytest-xdist"] + +[[package]] +name = "flake8" +version = "7.0.0" +description = "the modular source code checker: pep8 pyflakes and co" +optional = false +python-versions = ">=3.8.1" +files = [ + {file = "flake8-7.0.0-py2.py3-none-any.whl", hash = "sha256:a6dfbb75e03252917f2473ea9653f7cd799c3064e54d4c8140044c5c065f53c3"}, + {file = "flake8-7.0.0.tar.gz", hash = "sha256:33f96621059e65eec474169085dc92bf26e7b2d47366b70be2f67ab80dc25132"}, +] + +[package.dependencies] +mccabe = ">=0.7.0,<0.8.0" +pycodestyle = ">=2.11.0,<2.12.0" +pyflakes = ">=3.2.0,<3.3.0" + +[[package]] +name = "fonttools" +version = "4.47.2" +description = "Tools to manipulate font files" +optional = false +python-versions = ">=3.8" +files = [ + {file = "fonttools-4.47.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:3b629108351d25512d4ea1a8393a2dba325b7b7d7308116b605ea3f8e1be88df"}, + {file = "fonttools-4.47.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:c19044256c44fe299d9a73456aabee4b4d06c6b930287be93b533b4737d70aa1"}, + {file = "fonttools-4.47.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b8be28c036b9f186e8c7eaf8a11b42373e7e4949f9e9f370202b9da4c4c3f56c"}, + {file = "fonttools-4.47.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f83a4daef6d2a202acb9bf572958f91cfde5b10c8ee7fb1d09a4c81e5d851fd8"}, + {file = "fonttools-4.47.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:4a5a5318ba5365d992666ac4fe35365f93004109d18858a3e18ae46f67907670"}, + {file = "fonttools-4.47.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:8f57ecd742545362a0f7186774b2d1c53423ed9ece67689c93a1055b236f638c"}, + {file = "fonttools-4.47.2-cp310-cp310-win32.whl", hash = "sha256:a1c154bb85dc9a4cf145250c88d112d88eb414bad81d4cb524d06258dea1bdc0"}, + {file = "fonttools-4.47.2-cp310-cp310-win_amd64.whl", hash = "sha256:3e2b95dce2ead58fb12524d0ca7d63a63459dd489e7e5838c3cd53557f8933e1"}, + {file = "fonttools-4.47.2-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:29495d6d109cdbabe73cfb6f419ce67080c3ef9ea1e08d5750240fd4b0c4763b"}, + {file = "fonttools-4.47.2-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:0a1d313a415eaaba2b35d6cd33536560deeebd2ed758b9bfb89ab5d97dc5deac"}, + {file = "fonttools-4.47.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:90f898cdd67f52f18049250a6474185ef6544c91f27a7bee70d87d77a8daf89c"}, + {file = "fonttools-4.47.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3480eeb52770ff75140fe7d9a2ec33fb67b07efea0ab5129c7e0c6a639c40c70"}, + {file = "fonttools-4.47.2-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:0255dbc128fee75fb9be364806b940ed450dd6838672a150d501ee86523ac61e"}, + {file = "fonttools-4.47.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:f791446ff297fd5f1e2247c188de53c1bfb9dd7f0549eba55b73a3c2087a2703"}, + {file = "fonttools-4.47.2-cp311-cp311-win32.whl", hash = "sha256:740947906590a878a4bde7dd748e85fefa4d470a268b964748403b3ab2aeed6c"}, + {file = "fonttools-4.47.2-cp311-cp311-win_amd64.whl", hash = "sha256:63fbed184979f09a65aa9c88b395ca539c94287ba3a364517698462e13e457c9"}, + {file = "fonttools-4.47.2-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:4ec558c543609e71b2275c4894e93493f65d2f41c15fe1d089080c1d0bb4d635"}, + {file = "fonttools-4.47.2-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:e040f905d542362e07e72e03612a6270c33d38281fd573160e1003e43718d68d"}, + {file = "fonttools-4.47.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6dd58cc03016b281bd2c74c84cdaa6bd3ce54c5a7f47478b7657b930ac3ed8eb"}, + {file = "fonttools-4.47.2-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:32ab2e9702dff0dd4510c7bb958f265a8d3dd5c0e2547e7b5f7a3df4979abb07"}, + {file = "fonttools-4.47.2-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:3a808f3c1d1df1f5bf39be869b6e0c263570cdafb5bdb2df66087733f566ea71"}, + {file = "fonttools-4.47.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:ac71e2e201df041a2891067dc36256755b1229ae167edbdc419b16da78732c2f"}, + {file = "fonttools-4.47.2-cp312-cp312-win32.whl", hash = "sha256:69731e8bea0578b3c28fdb43dbf95b9386e2d49a399e9a4ad736b8e479b08085"}, + {file = "fonttools-4.47.2-cp312-cp312-win_amd64.whl", hash = "sha256:b3e1304e5f19ca861d86a72218ecce68f391646d85c851742d265787f55457a4"}, + {file = "fonttools-4.47.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:254d9a6f7be00212bf0c3159e0a420eb19c63793b2c05e049eb337f3023c5ecc"}, + {file = "fonttools-4.47.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:eabae77a07c41ae0b35184894202305c3ad211a93b2eb53837c2a1143c8bc952"}, + {file = "fonttools-4.47.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a86a5ab2873ed2575d0fcdf1828143cfc6b977ac448e3dc616bb1e3d20efbafa"}, + {file = "fonttools-4.47.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:13819db8445a0cec8c3ff5f243af6418ab19175072a9a92f6cc8ca7d1452754b"}, + {file = "fonttools-4.47.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:4e743935139aa485fe3253fc33fe467eab6ea42583fa681223ea3f1a93dd01e6"}, + {file = "fonttools-4.47.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:d49ce3ea7b7173faebc5664872243b40cf88814ca3eb135c4a3cdff66af71946"}, + {file = "fonttools-4.47.2-cp38-cp38-win32.whl", hash = "sha256:94208ea750e3f96e267f394d5588579bb64cc628e321dbb1d4243ffbc291b18b"}, + {file = "fonttools-4.47.2-cp38-cp38-win_amd64.whl", hash = "sha256:0f750037e02beb8b3569fbff701a572e62a685d2a0e840d75816592280e5feae"}, + {file = "fonttools-4.47.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:3d71606c9321f6701642bd4746f99b6089e53d7e9817fc6b964e90d9c5f0ecc6"}, + {file = "fonttools-4.47.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:86e0427864c6c91cf77f16d1fb9bf1bbf7453e824589e8fb8461b6ee1144f506"}, + {file = "fonttools-4.47.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0a00bd0e68e88987dcc047ea31c26d40a3c61185153b03457956a87e39d43c37"}, + {file = "fonttools-4.47.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a5d77479fb885ef38a16a253a2f4096bc3d14e63a56d6246bfdb56365a12b20c"}, + {file = "fonttools-4.47.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:5465df494f20a7d01712b072ae3ee9ad2887004701b95cb2cc6dcb9c2c97a899"}, + {file = "fonttools-4.47.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:4c811d3c73b6abac275babb8aa439206288f56fdb2c6f8835e3d7b70de8937a7"}, + {file = "fonttools-4.47.2-cp39-cp39-win32.whl", hash = "sha256:5b60e3afa9635e3dfd3ace2757039593e3bd3cf128be0ddb7a1ff4ac45fa5a50"}, + {file = "fonttools-4.47.2-cp39-cp39-win_amd64.whl", hash = "sha256:7ee48bd9d6b7e8f66866c9090807e3a4a56cf43ffad48962725a190e0dd774c8"}, + {file = "fonttools-4.47.2-py3-none-any.whl", hash = "sha256:7eb7ad665258fba68fd22228a09f347469d95a97fb88198e133595947a20a184"}, + {file = "fonttools-4.47.2.tar.gz", hash = "sha256:7df26dd3650e98ca45f1e29883c96a0b9f5bb6af8d632a6a108bc744fa0bd9b3"}, +] + +[package.extras] +all = ["brotli (>=1.0.1)", "brotlicffi (>=0.8.0)", "fs (>=2.2.0,<3)", "lxml (>=4.0,<5)", "lz4 (>=1.7.4.2)", "matplotlib", "munkres", "pycairo", "scipy", "skia-pathops (>=0.5.0)", "sympy", "uharfbuzz (>=0.23.0)", "unicodedata2 (>=15.1.0)", "xattr", "zopfli (>=0.1.4)"] +graphite = ["lz4 (>=1.7.4.2)"] +interpolatable = ["munkres", "pycairo", "scipy"] +lxml = ["lxml (>=4.0,<5)"] +pathops = ["skia-pathops (>=0.5.0)"] +plot = ["matplotlib"] +repacker = ["uharfbuzz (>=0.23.0)"] +symfont = ["sympy"] +type1 = ["xattr"] +ufo = ["fs (>=2.2.0,<3)"] +unicode = ["unicodedata2 (>=15.1.0)"] +woff = ["brotli (>=1.0.1)", "brotlicffi (>=0.8.0)", "zopfli (>=0.1.4)"] + +[[package]] +name = "fsspec" +version = "2023.12.2" +description = "File-system specification" +optional = false +python-versions = ">=3.8" +files = [ + {file = "fsspec-2023.12.2-py3-none-any.whl", hash = "sha256:d800d87f72189a745fa3d6b033b9dc4a34ad069f60ca60b943a63599f5501960"}, + {file = "fsspec-2023.12.2.tar.gz", hash = "sha256:8548d39e8810b59c38014934f6b31e57f40c1b20f911f4cc2b85389c7e9bf0cb"}, +] + +[package.extras] +abfs = ["adlfs"] +adl = ["adlfs"] +arrow = ["pyarrow (>=1)"] +dask = ["dask", "distributed"] +devel = ["pytest", "pytest-cov"] +dropbox = ["dropbox", "dropboxdrivefs", "requests"] +full = ["adlfs", "aiohttp (!=4.0.0a0,!=4.0.0a1)", "dask", "distributed", "dropbox", "dropboxdrivefs", "fusepy", "gcsfs", "libarchive-c", "ocifs", "panel", "paramiko", "pyarrow (>=1)", "pygit2", "requests", "s3fs", "smbprotocol", "tqdm"] +fuse = ["fusepy"] +gcs = ["gcsfs"] +git = ["pygit2"] +github = ["requests"] +gs = ["gcsfs"] +gui = ["panel"] +hdfs = ["pyarrow (>=1)"] +http = ["aiohttp (!=4.0.0a0,!=4.0.0a1)", "requests"] +libarchive = ["libarchive-c"] +oci = ["ocifs"] +s3 = ["s3fs"] +sftp = ["paramiko"] +smb = ["smbprotocol"] +ssh = ["paramiko"] +tqdm = ["tqdm"] + +[[package]] +name = "importlib-metadata" +version = "7.0.1" +description = "Read metadata from Python packages" +optional = false +python-versions = ">=3.8" +files = [ + {file = "importlib_metadata-7.0.1-py3-none-any.whl", hash = "sha256:4805911c3a4ec7c3966410053e9ec6a1fecd629117df5adee56dfc9432a1081e"}, + {file = "importlib_metadata-7.0.1.tar.gz", hash = "sha256:f238736bb06590ae52ac1fab06a3a9ef1d8dce2b7a35b5ab329371d6c8f5d2cc"}, +] + +[package.dependencies] +zipp = ">=0.5" + +[package.extras] +docs = ["furo", "jaraco.packaging (>=9.3)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (<7.2.5)", "sphinx (>=3.5)", "sphinx-lint"] +perf = ["ipython"] +testing = ["flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=2.2)", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)", "pytest-ruff"] + +[[package]] +name = "iniconfig" +version = "2.0.0" +description = "brain-dead simple config-ini parsing" +optional = false +python-versions = ">=3.7" +files = [ + {file = "iniconfig-2.0.0-py3-none-any.whl", hash = "sha256:b6a85871a79d2e3b22d2d1b94ac2824226a63c6b741c88f7ae975f18b6778374"}, + {file = "iniconfig-2.0.0.tar.gz", hash = "sha256:2d91e135bf72d31a410b17c16da610a82cb55f6b0477d1a902134b24a455b8b3"}, +] + +[[package]] +name = "kiwisolver" +version = "1.4.5" +description = "A fast implementation of the Cassowary constraint solver" +optional = false +python-versions = ">=3.7" +files = [ + {file = "kiwisolver-1.4.5-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:05703cf211d585109fcd72207a31bb170a0f22144d68298dc5e61b3c946518af"}, + {file = "kiwisolver-1.4.5-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:146d14bebb7f1dc4d5fbf74f8a6cb15ac42baadee8912eb84ac0b3b2a3dc6ac3"}, + {file = "kiwisolver-1.4.5-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:6ef7afcd2d281494c0a9101d5c571970708ad911d028137cd558f02b851c08b4"}, + {file = "kiwisolver-1.4.5-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:9eaa8b117dc8337728e834b9c6e2611f10c79e38f65157c4c38e9400286f5cb1"}, + {file = "kiwisolver-1.4.5-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:ec20916e7b4cbfb1f12380e46486ec4bcbaa91a9c448b97023fde0d5bbf9e4ff"}, + {file = "kiwisolver-1.4.5-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:39b42c68602539407884cf70d6a480a469b93b81b7701378ba5e2328660c847a"}, + {file = "kiwisolver-1.4.5-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:aa12042de0171fad672b6c59df69106d20d5596e4f87b5e8f76df757a7c399aa"}, + {file = "kiwisolver-1.4.5-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2a40773c71d7ccdd3798f6489aaac9eee213d566850a9533f8d26332d626b82c"}, + {file = "kiwisolver-1.4.5-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:19df6e621f6d8b4b9c4d45f40a66839294ff2bb235e64d2178f7522d9170ac5b"}, + {file = "kiwisolver-1.4.5-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:83d78376d0d4fd884e2c114d0621624b73d2aba4e2788182d286309ebdeed770"}, + {file = "kiwisolver-1.4.5-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:e391b1f0a8a5a10ab3b9bb6afcfd74f2175f24f8975fb87ecae700d1503cdee0"}, + {file = "kiwisolver-1.4.5-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:852542f9481f4a62dbb5dd99e8ab7aedfeb8fb6342349a181d4036877410f525"}, + {file = "kiwisolver-1.4.5-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:59edc41b24031bc25108e210c0def6f6c2191210492a972d585a06ff246bb79b"}, + {file = "kiwisolver-1.4.5-cp310-cp310-win32.whl", hash = "sha256:a6aa6315319a052b4ee378aa171959c898a6183f15c1e541821c5c59beaa0238"}, + {file = "kiwisolver-1.4.5-cp310-cp310-win_amd64.whl", hash = "sha256:d0ef46024e6a3d79c01ff13801cb19d0cad7fd859b15037aec74315540acc276"}, + {file = "kiwisolver-1.4.5-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:11863aa14a51fd6ec28688d76f1735f8f69ab1fabf388851a595d0721af042f5"}, + {file = "kiwisolver-1.4.5-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:8ab3919a9997ab7ef2fbbed0cc99bb28d3c13e6d4b1ad36e97e482558a91be90"}, + {file = "kiwisolver-1.4.5-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:fcc700eadbbccbf6bc1bcb9dbe0786b4b1cb91ca0dcda336eef5c2beed37b797"}, + {file = "kiwisolver-1.4.5-cp311-cp311-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dfdd7c0b105af050eb3d64997809dc21da247cf44e63dc73ff0fd20b96be55a9"}, + {file = "kiwisolver-1.4.5-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:76c6a5964640638cdeaa0c359382e5703e9293030fe730018ca06bc2010c4437"}, + {file = "kiwisolver-1.4.5-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bbea0db94288e29afcc4c28afbf3a7ccaf2d7e027489c449cf7e8f83c6346eb9"}, + {file = "kiwisolver-1.4.5-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:ceec1a6bc6cab1d6ff5d06592a91a692f90ec7505d6463a88a52cc0eb58545da"}, + {file = "kiwisolver-1.4.5-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:040c1aebeda72197ef477a906782b5ab0d387642e93bda547336b8957c61022e"}, + {file = "kiwisolver-1.4.5-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:f91de7223d4c7b793867797bacd1ee53bfe7359bd70d27b7b58a04efbb9436c8"}, + {file = "kiwisolver-1.4.5-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:faae4860798c31530dd184046a900e652c95513796ef51a12bc086710c2eec4d"}, + {file = "kiwisolver-1.4.5-cp311-cp311-musllinux_1_1_ppc64le.whl", hash = "sha256:b0157420efcb803e71d1b28e2c287518b8808b7cf1ab8af36718fd0a2c453eb0"}, + {file = "kiwisolver-1.4.5-cp311-cp311-musllinux_1_1_s390x.whl", hash = "sha256:06f54715b7737c2fecdbf140d1afb11a33d59508a47bf11bb38ecf21dc9ab79f"}, + {file = "kiwisolver-1.4.5-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:fdb7adb641a0d13bdcd4ef48e062363d8a9ad4a182ac7647ec88f695e719ae9f"}, + {file = "kiwisolver-1.4.5-cp311-cp311-win32.whl", hash = "sha256:bb86433b1cfe686da83ce32a9d3a8dd308e85c76b60896d58f082136f10bffac"}, + {file = "kiwisolver-1.4.5-cp311-cp311-win_amd64.whl", hash = "sha256:6c08e1312a9cf1074d17b17728d3dfce2a5125b2d791527f33ffbe805200a355"}, + {file = "kiwisolver-1.4.5-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:32d5cf40c4f7c7b3ca500f8985eb3fb3a7dfc023215e876f207956b5ea26632a"}, + {file = "kiwisolver-1.4.5-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:f846c260f483d1fd217fe5ed7c173fb109efa6b1fc8381c8b7552c5781756192"}, + {file = "kiwisolver-1.4.5-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:5ff5cf3571589b6d13bfbfd6bcd7a3f659e42f96b5fd1c4830c4cf21d4f5ef45"}, + {file = "kiwisolver-1.4.5-cp312-cp312-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7269d9e5f1084a653d575c7ec012ff57f0c042258bf5db0954bf551c158466e7"}, + {file = "kiwisolver-1.4.5-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:da802a19d6e15dffe4b0c24b38b3af68e6c1a68e6e1d8f30148c83864f3881db"}, + {file = "kiwisolver-1.4.5-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3aba7311af82e335dd1e36ffff68aaca609ca6290c2cb6d821a39aa075d8e3ff"}, + {file = "kiwisolver-1.4.5-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:763773d53f07244148ccac5b084da5adb90bfaee39c197554f01b286cf869228"}, + {file = "kiwisolver-1.4.5-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2270953c0d8cdab5d422bee7d2007f043473f9d2999631c86a223c9db56cbd16"}, + {file = "kiwisolver-1.4.5-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:d099e745a512f7e3bbe7249ca835f4d357c586d78d79ae8f1dcd4d8adeb9bda9"}, + {file = "kiwisolver-1.4.5-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:74db36e14a7d1ce0986fa104f7d5637aea5c82ca6326ed0ec5694280942d1162"}, + {file = "kiwisolver-1.4.5-cp312-cp312-musllinux_1_1_ppc64le.whl", hash = "sha256:7e5bab140c309cb3a6ce373a9e71eb7e4873c70c2dda01df6820474f9889d6d4"}, + {file = "kiwisolver-1.4.5-cp312-cp312-musllinux_1_1_s390x.whl", hash = "sha256:0f114aa76dc1b8f636d077979c0ac22e7cd8f3493abbab152f20eb8d3cda71f3"}, + {file = "kiwisolver-1.4.5-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:88a2df29d4724b9237fc0c6eaf2a1adae0cdc0b3e9f4d8e7dc54b16812d2d81a"}, + {file = "kiwisolver-1.4.5-cp312-cp312-win32.whl", hash = "sha256:72d40b33e834371fd330fb1472ca19d9b8327acb79a5821d4008391db8e29f20"}, + {file = "kiwisolver-1.4.5-cp312-cp312-win_amd64.whl", hash = "sha256:2c5674c4e74d939b9d91dda0fae10597ac7521768fec9e399c70a1f27e2ea2d9"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:3a2b053a0ab7a3960c98725cfb0bf5b48ba82f64ec95fe06f1d06c99b552e130"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3cd32d6c13807e5c66a7cbb79f90b553642f296ae4518a60d8d76243b0ad2898"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:59ec7b7c7e1a61061850d53aaf8e93db63dce0c936db1fda2658b70e4a1be709"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:da4cfb373035def307905d05041c1d06d8936452fe89d464743ae7fb8371078b"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2400873bccc260b6ae184b2b8a4fec0e4082d30648eadb7c3d9a13405d861e89"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:1b04139c4236a0f3aff534479b58f6f849a8b351e1314826c2d230849ed48985"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:4e66e81a5779b65ac21764c295087de82235597a2293d18d943f8e9e32746265"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:7931d8f1f67c4be9ba1dd9c451fb0eeca1a25b89e4d3f89e828fe12a519b782a"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:b3f7e75f3015df442238cca659f8baa5f42ce2a8582727981cbfa15fee0ee205"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:bbf1d63eef84b2e8c89011b7f2235b1e0bf7dacc11cac9431fc6468e99ac77fb"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:4c380469bd3f970ef677bf2bcba2b6b0b4d5c75e7a020fb863ef75084efad66f"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-win32.whl", hash = "sha256:9408acf3270c4b6baad483865191e3e582b638b1654a007c62e3efe96f09a9a3"}, + {file = "kiwisolver-1.4.5-cp37-cp37m-win_amd64.whl", hash = "sha256:5b94529f9b2591b7af5f3e0e730a4e0a41ea174af35a4fd067775f9bdfeee01a"}, + {file = "kiwisolver-1.4.5-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:11c7de8f692fc99816e8ac50d1d1aef4f75126eefc33ac79aac02c099fd3db71"}, + {file = "kiwisolver-1.4.5-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:53abb58632235cd154176ced1ae8f0d29a6657aa1aa9decf50b899b755bc2b93"}, + {file = "kiwisolver-1.4.5-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:88b9f257ca61b838b6f8094a62418421f87ac2a1069f7e896c36a7d86b5d4c29"}, + {file = "kiwisolver-1.4.5-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3195782b26fc03aa9c6913d5bad5aeb864bdc372924c093b0f1cebad603dd712"}, + {file = "kiwisolver-1.4.5-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fc579bf0f502e54926519451b920e875f433aceb4624a3646b3252b5caa9e0b6"}, + {file = "kiwisolver-1.4.5-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5a580c91d686376f0f7c295357595c5a026e6cbc3d77b7c36e290201e7c11ecb"}, + {file = "kiwisolver-1.4.5-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:cfe6ab8da05c01ba6fbea630377b5da2cd9bcbc6338510116b01c1bc939a2c18"}, + {file = "kiwisolver-1.4.5-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:d2e5a98f0ec99beb3c10e13b387f8db39106d53993f498b295f0c914328b1333"}, + {file = "kiwisolver-1.4.5-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:a51a263952b1429e429ff236d2f5a21c5125437861baeed77f5e1cc2d2c7c6da"}, + {file = "kiwisolver-1.4.5-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:3edd2fa14e68c9be82c5b16689e8d63d89fe927e56debd6e1dbce7a26a17f81b"}, + {file = "kiwisolver-1.4.5-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:74d1b44c6cfc897df648cc9fdaa09bc3e7679926e6f96df05775d4fb3946571c"}, + {file = "kiwisolver-1.4.5-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:76d9289ed3f7501012e05abb8358bbb129149dbd173f1f57a1bf1c22d19ab7cc"}, + {file = "kiwisolver-1.4.5-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:92dea1ffe3714fa8eb6a314d2b3c773208d865a0e0d35e713ec54eea08a66250"}, + {file = "kiwisolver-1.4.5-cp38-cp38-win32.whl", hash = "sha256:5c90ae8c8d32e472be041e76f9d2f2dbff4d0b0be8bd4041770eddb18cf49a4e"}, + {file = "kiwisolver-1.4.5-cp38-cp38-win_amd64.whl", hash = "sha256:c7940c1dc63eb37a67721b10d703247552416f719c4188c54e04334321351ced"}, + {file = "kiwisolver-1.4.5-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:9407b6a5f0d675e8a827ad8742e1d6b49d9c1a1da5d952a67d50ef5f4170b18d"}, + {file = "kiwisolver-1.4.5-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:15568384086b6df3c65353820a4473575dbad192e35010f622c6ce3eebd57af9"}, + {file = "kiwisolver-1.4.5-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:0dc9db8e79f0036e8173c466d21ef18e1befc02de8bf8aa8dc0813a6dc8a7046"}, + {file = "kiwisolver-1.4.5-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:cdc8a402aaee9a798b50d8b827d7ecf75edc5fb35ea0f91f213ff927c15f4ff0"}, + {file = "kiwisolver-1.4.5-cp39-cp39-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:6c3bd3cde54cafb87d74d8db50b909705c62b17c2099b8f2e25b461882e544ff"}, + {file = "kiwisolver-1.4.5-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:955e8513d07a283056b1396e9a57ceddbd272d9252c14f154d450d227606eb54"}, + {file = "kiwisolver-1.4.5-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:346f5343b9e3f00b8db8ba359350eb124b98c99efd0b408728ac6ebf38173958"}, + {file = "kiwisolver-1.4.5-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b9098e0049e88c6a24ff64545cdfc50807818ba6c1b739cae221bbbcbc58aad3"}, + {file = "kiwisolver-1.4.5-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:00bd361b903dc4bbf4eb165f24d1acbee754fce22ded24c3d56eec268658a5cf"}, + {file = "kiwisolver-1.4.5-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:7b8b454bac16428b22560d0a1cf0a09875339cab69df61d7805bf48919415901"}, + {file = "kiwisolver-1.4.5-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:f1d072c2eb0ad60d4c183f3fb44ac6f73fb7a8f16a2694a91f988275cbf352f9"}, + {file = "kiwisolver-1.4.5-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:31a82d498054cac9f6d0b53d02bb85811185bcb477d4b60144f915f3b3126342"}, + {file = "kiwisolver-1.4.5-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:6512cb89e334e4700febbffaaa52761b65b4f5a3cf33f960213d5656cea36a77"}, + {file = "kiwisolver-1.4.5-cp39-cp39-win32.whl", hash = "sha256:9db8ea4c388fdb0f780fe91346fd438657ea602d58348753d9fb265ce1bca67f"}, + {file = "kiwisolver-1.4.5-cp39-cp39-win_amd64.whl", hash = "sha256:59415f46a37f7f2efeec758353dd2eae1b07640d8ca0f0c42548ec4125492635"}, + {file = "kiwisolver-1.4.5-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:5c7b3b3a728dc6faf3fc372ef24f21d1e3cee2ac3e9596691d746e5a536de920"}, + {file = "kiwisolver-1.4.5-pp37-pypy37_pp73-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:620ced262a86244e2be10a676b646f29c34537d0d9cc8eb26c08f53d98013390"}, + {file = "kiwisolver-1.4.5-pp37-pypy37_pp73-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:378a214a1e3bbf5ac4a8708304318b4f890da88c9e6a07699c4ae7174c09a68d"}, + {file = "kiwisolver-1.4.5-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:aaf7be1207676ac608a50cd08f102f6742dbfc70e8d60c4db1c6897f62f71523"}, + {file = "kiwisolver-1.4.5-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:ba55dce0a9b8ff59495ddd050a0225d58bd0983d09f87cfe2b6aec4f2c1234e4"}, + {file = "kiwisolver-1.4.5-pp38-pypy38_pp73-macosx_10_9_x86_64.whl", hash = "sha256:fd32ea360bcbb92d28933fc05ed09bffcb1704ba3fc7942e81db0fd4f81a7892"}, + {file = "kiwisolver-1.4.5-pp38-pypy38_pp73-manylinux_2_12_i686.manylinux2010_i686.whl", hash = "sha256:5e7139af55d1688f8b960ee9ad5adafc4ac17c1c473fe07133ac092310d76544"}, + {file = "kiwisolver-1.4.5-pp38-pypy38_pp73-manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:dced8146011d2bc2e883f9bd68618b8247387f4bbec46d7392b3c3b032640126"}, + {file = "kiwisolver-1.4.5-pp38-pypy38_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c9bf3325c47b11b2e51bca0824ea217c7cd84491d8ac4eefd1e409705ef092bd"}, + {file = "kiwisolver-1.4.5-pp38-pypy38_pp73-win_amd64.whl", hash = "sha256:5794cf59533bc3f1b1c821f7206a3617999db9fbefc345360aafe2e067514929"}, + {file = "kiwisolver-1.4.5-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:e368f200bbc2e4f905b8e71eb38b3c04333bddaa6a2464a6355487b02bb7fb09"}, + {file = "kiwisolver-1.4.5-pp39-pypy39_pp73-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:e5d706eba36b4c4d5bc6c6377bb6568098765e990cfc21ee16d13963fab7b3e7"}, + {file = "kiwisolver-1.4.5-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:85267bd1aa8880a9c88a8cb71e18d3d64d2751a790e6ca6c27b8ccc724bcd5ad"}, + {file = "kiwisolver-1.4.5-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:210ef2c3a1f03272649aff1ef992df2e724748918c4bc2d5a90352849eb40bea"}, + {file = "kiwisolver-1.4.5-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:11d011a7574eb3b82bcc9c1a1d35c1d7075677fdd15de527d91b46bd35e935ee"}, + {file = "kiwisolver-1.4.5.tar.gz", hash = "sha256:e57e563a57fb22a142da34f38acc2fc1a5c864bc29ca1517a88abc963e60d6ec"}, +] + +[[package]] +name = "matplotlib" +version = "3.8.2" +description = "Python plotting package" +optional = false +python-versions = ">=3.9" +files = [ + {file = "matplotlib-3.8.2-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:09796f89fb71a0c0e1e2f4bdaf63fb2cefc84446bb963ecdeb40dfee7dfa98c7"}, + {file = "matplotlib-3.8.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:6f9c6976748a25e8b9be51ea028df49b8e561eed7809146da7a47dbecebab367"}, + {file = "matplotlib-3.8.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b78e4f2cedf303869b782071b55fdde5987fda3038e9d09e58c91cc261b5ad18"}, + {file = "matplotlib-3.8.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4e208f46cf6576a7624195aa047cb344a7f802e113bb1a06cfd4bee431de5e31"}, + {file = "matplotlib-3.8.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:46a569130ff53798ea5f50afce7406e91fdc471ca1e0e26ba976a8c734c9427a"}, + {file = "matplotlib-3.8.2-cp310-cp310-win_amd64.whl", hash = "sha256:830f00640c965c5b7f6bc32f0d4ce0c36dfe0379f7dd65b07a00c801713ec40a"}, + {file = "matplotlib-3.8.2-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:d86593ccf546223eb75a39b44c32788e6f6440d13cfc4750c1c15d0fcb850b63"}, + {file = "matplotlib-3.8.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:9a5430836811b7652991939012f43d2808a2db9b64ee240387e8c43e2e5578c8"}, + {file = "matplotlib-3.8.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b9576723858a78751d5aacd2497b8aef29ffea6d1c95981505877f7ac28215c6"}, + {file = "matplotlib-3.8.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5ba9cbd8ac6cf422f3102622b20f8552d601bf8837e49a3afed188d560152788"}, + {file = "matplotlib-3.8.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:03f9d160a29e0b65c0790bb07f4f45d6a181b1ac33eb1bb0dd225986450148f0"}, + {file = "matplotlib-3.8.2-cp311-cp311-win_amd64.whl", hash = "sha256:3773002da767f0a9323ba1a9b9b5d00d6257dbd2a93107233167cfb581f64717"}, + {file = "matplotlib-3.8.2-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:4c318c1e95e2f5926fba326f68177dee364aa791d6df022ceb91b8221bd0a627"}, + {file = "matplotlib-3.8.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:091275d18d942cf1ee9609c830a1bc36610607d8223b1b981c37d5c9fc3e46a4"}, + {file = "matplotlib-3.8.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1b0f3b8ea0e99e233a4bcc44590f01604840d833c280ebb8fe5554fd3e6cfe8d"}, + {file = "matplotlib-3.8.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d7b1704a530395aaf73912be741c04d181f82ca78084fbd80bc737be04848331"}, + {file = "matplotlib-3.8.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:533b0e3b0c6768eef8cbe4b583731ce25a91ab54a22f830db2b031e83cca9213"}, + {file = "matplotlib-3.8.2-cp312-cp312-win_amd64.whl", hash = "sha256:0f4fc5d72b75e2c18e55eb32292659cf731d9d5b312a6eb036506304f4675630"}, + {file = "matplotlib-3.8.2-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:deaed9ad4da0b1aea77fe0aa0cebb9ef611c70b3177be936a95e5d01fa05094f"}, + {file = "matplotlib-3.8.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:172f4d0fbac3383d39164c6caafd3255ce6fa58f08fc392513a0b1d3b89c4f89"}, + {file = "matplotlib-3.8.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c7d36c2209d9136cd8e02fab1c0ddc185ce79bc914c45054a9f514e44c787917"}, + {file = "matplotlib-3.8.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5864bdd7da445e4e5e011b199bb67168cdad10b501750367c496420f2ad00843"}, + {file = "matplotlib-3.8.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:ef8345b48e95cee45ff25192ed1f4857273117917a4dcd48e3905619bcd9c9b8"}, + {file = "matplotlib-3.8.2-cp39-cp39-win_amd64.whl", hash = "sha256:7c48d9e221b637c017232e3760ed30b4e8d5dfd081daf327e829bf2a72c731b4"}, + {file = "matplotlib-3.8.2-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:aa11b3c6928a1e496c1a79917d51d4cd5d04f8a2e75f21df4949eeefdf697f4b"}, + {file = "matplotlib-3.8.2-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d1095fecf99eeb7384dabad4bf44b965f929a5f6079654b681193edf7169ec20"}, + {file = "matplotlib-3.8.2-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:bddfb1db89bfaa855912261c805bd0e10218923cc262b9159a49c29a7a1c1afa"}, + {file = "matplotlib-3.8.2.tar.gz", hash = "sha256:01a978b871b881ee76017152f1f1a0cbf6bd5f7b8ff8c96df0df1bd57d8755a1"}, +] + +[package.dependencies] +contourpy = ">=1.0.1" +cycler = ">=0.10" +fonttools = ">=4.22.0" +kiwisolver = ">=1.3.1" +numpy = ">=1.21,<2" +packaging = ">=20.0" +pillow = ">=8" +pyparsing = ">=2.3.1" +python-dateutil = ">=2.7" + +[[package]] +name = "mccabe" +version = "0.7.0" +description = "McCabe checker, plugin for flake8" +optional = false +python-versions = ">=3.6" +files = [ + {file = "mccabe-0.7.0-py2.py3-none-any.whl", hash = "sha256:6c2d30ab6be0e4a46919781807b4f0d834ebdd6c6e3dca0bda5a15f863427b6e"}, + {file = "mccabe-0.7.0.tar.gz", hash = "sha256:348e0240c33b60bbdf4e523192ef919f28cb2c3d7d5c7794f74009290f236325"}, +] + +[[package]] +name = "mplhep" +version = "0.3.31" +description = "Matplotlib styles for HEP" +optional = false +python-versions = ">=3.8" +files = [ + {file = "mplhep-0.3.31-py3-none-any.whl", hash = "sha256:60511b210051d389fbce47ecb10737f09d4c5ba1deb588366c440e536240b74c"}, + {file = "mplhep-0.3.31.tar.gz", hash = "sha256:699c1acdb0e58d19dc076a7ba83f790a6b34b90054f2d72252b5dc2a9b325533"}, +] + +[package.dependencies] +matplotlib = ">=3.4" +mplhep-data = "*" +numpy = ">=1.16.0" +packaging = "*" +uhi = ">=0.2.0" + +[package.extras] +all = ["black", "boost-histogram", "bumpversion", "flake8", "hist", "jupyter", "nteract-scrapbook (>=0.3,<1.0)", "papermill (>=1.0,<2.0)", "pre-commit", "pytest (>=6.0)", "pytest-mock", "pytest-mpl", "scikit-hep-testdata", "scipy (>=1.1.0)", "twine", "uproot", "uproot4"] +dev = ["black", "bumpversion", "flake8", "jupyter", "pre-commit", "twine"] +test = ["boost-histogram", "hist", "nteract-scrapbook (>=0.3,<1.0)", "papermill (>=1.0,<2.0)", "pytest (>=6.0)", "pytest-mock", "pytest-mpl", "scikit-hep-testdata", "scipy (>=1.1.0)", "uproot", "uproot4"] + +[[package]] +name = "mplhep-data" +version = "0.0.3" +description = "Font (Data) sub-package for mplhep" +optional = false +python-versions = ">=3.7" +files = [ + {file = "mplhep_data-0.0.3-py3-none-any.whl", hash = "sha256:a1eba7727fab31902e6fcd113c8f4b12ff3fb0666781e7514f8b79093cdc1c65"}, + {file = "mplhep_data-0.0.3.tar.gz", hash = "sha256:b54d257f3f53c93a442cda7a6681ce267277e09173c0b41fd78820f78321772f"}, +] + +[package.extras] +dev = ["pytest (>=4.6)"] +test = ["pytest (>=4.6)"] + +[[package]] +name = "mypy" +version = "1.8.0" +description = "Optional static typing for Python" +optional = false +python-versions = ">=3.8" +files = [ + {file = "mypy-1.8.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:485a8942f671120f76afffff70f259e1cd0f0cfe08f81c05d8816d958d4577d3"}, + {file = "mypy-1.8.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:df9824ac11deaf007443e7ed2a4a26bebff98d2bc43c6da21b2b64185da011c4"}, + {file = "mypy-1.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2afecd6354bbfb6e0160f4e4ad9ba6e4e003b767dd80d85516e71f2e955ab50d"}, + {file = "mypy-1.8.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:8963b83d53ee733a6e4196954502b33567ad07dfd74851f32be18eb932fb1cb9"}, + {file = "mypy-1.8.0-cp310-cp310-win_amd64.whl", hash = "sha256:e46f44b54ebddbeedbd3d5b289a893219065ef805d95094d16a0af6630f5d410"}, + {file = "mypy-1.8.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:855fe27b80375e5c5878492f0729540db47b186509c98dae341254c8f45f42ae"}, + {file = "mypy-1.8.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:4c886c6cce2d070bd7df4ec4a05a13ee20c0aa60cb587e8d1265b6c03cf91da3"}, + {file = "mypy-1.8.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d19c413b3c07cbecf1f991e2221746b0d2a9410b59cb3f4fb9557f0365a1a817"}, + {file = "mypy-1.8.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:9261ed810972061388918c83c3f5cd46079d875026ba97380f3e3978a72f503d"}, + {file = "mypy-1.8.0-cp311-cp311-win_amd64.whl", hash = "sha256:51720c776d148bad2372ca21ca29256ed483aa9a4cdefefcef49006dff2a6835"}, + {file = "mypy-1.8.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:52825b01f5c4c1c4eb0db253ec09c7aa17e1a7304d247c48b6f3599ef40db8bd"}, + {file = "mypy-1.8.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:f5ac9a4eeb1ec0f1ccdc6f326bcdb464de5f80eb07fb38b5ddd7b0de6bc61e55"}, + {file = "mypy-1.8.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:afe3fe972c645b4632c563d3f3eff1cdca2fa058f730df2b93a35e3b0c538218"}, + {file = "mypy-1.8.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:42c6680d256ab35637ef88891c6bd02514ccb7e1122133ac96055ff458f93fc3"}, + {file = "mypy-1.8.0-cp312-cp312-win_amd64.whl", hash = "sha256:720a5ca70e136b675af3af63db533c1c8c9181314d207568bbe79051f122669e"}, + {file = "mypy-1.8.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:028cf9f2cae89e202d7b6593cd98db6759379f17a319b5faf4f9978d7084cdc6"}, + {file = "mypy-1.8.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:4e6d97288757e1ddba10dd9549ac27982e3e74a49d8d0179fc14d4365c7add66"}, + {file = "mypy-1.8.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7f1478736fcebb90f97e40aff11a5f253af890c845ee0c850fe80aa060a267c6"}, + {file = "mypy-1.8.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:42419861b43e6962a649068a61f4a4839205a3ef525b858377a960b9e2de6e0d"}, + {file = "mypy-1.8.0-cp38-cp38-win_amd64.whl", hash = "sha256:2b5b6c721bd4aabaadead3a5e6fa85c11c6c795e0c81a7215776ef8afc66de02"}, + {file = "mypy-1.8.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:5c1538c38584029352878a0466f03a8ee7547d7bd9f641f57a0f3017a7c905b8"}, + {file = "mypy-1.8.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4ef4be7baf08a203170f29e89d79064463b7fc7a0908b9d0d5114e8009c3a259"}, + {file = "mypy-1.8.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7178def594014aa6c35a8ff411cf37d682f428b3b5617ca79029d8ae72f5402b"}, + {file = "mypy-1.8.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:ab3c84fa13c04aeeeabb2a7f67a25ef5d77ac9d6486ff33ded762ef353aa5592"}, + {file = "mypy-1.8.0-cp39-cp39-win_amd64.whl", hash = "sha256:99b00bc72855812a60d253420d8a2eae839b0afa4938f09f4d2aa9bb4654263a"}, + {file = "mypy-1.8.0-py3-none-any.whl", hash = "sha256:538fd81bb5e430cc1381a443971c0475582ff9f434c16cd46d2c66763ce85d9d"}, + {file = "mypy-1.8.0.tar.gz", hash = "sha256:6ff8b244d7085a0b425b56d327b480c3b29cafbd2eff27316a004f9a7391ae07"}, +] + +[package.dependencies] +mypy-extensions = ">=1.0.0" +typing-extensions = ">=4.1.0" + +[package.extras] +dmypy = ["psutil (>=4.0)"] +install-types = ["pip"] +mypyc = ["setuptools (>=50)"] +reports = ["lxml"] + +[[package]] +name = "mypy-extensions" +version = "1.0.0" +description = "Type system extensions for programs checked with the mypy type checker." +optional = false +python-versions = ">=3.5" +files = [ + {file = "mypy_extensions-1.0.0-py3-none-any.whl", hash = "sha256:4392f6c0eb8a5668a69e23d168ffa70f0be9ccfd32b5cc2d26a34ae5b844552d"}, + {file = "mypy_extensions-1.0.0.tar.gz", hash = "sha256:75dbf8955dc00442a438fc4d0666508a9a97b6bd41aa2f0ffe9d2f2725af0782"}, +] + +[[package]] +name = "numpy" +version = "1.26.3" +description = "Fundamental package for array computing in Python" +optional = false +python-versions = ">=3.9" +files = [ + {file = "numpy-1.26.3-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:806dd64230dbbfaca8a27faa64e2f414bf1c6622ab78cc4264f7f5f028fee3bf"}, + {file = "numpy-1.26.3-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:02f98011ba4ab17f46f80f7f8f1c291ee7d855fcef0a5a98db80767a468c85cd"}, + {file = "numpy-1.26.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6d45b3ec2faed4baca41c76617fcdcfa4f684ff7a151ce6fc78ad3b6e85af0a6"}, + {file = "numpy-1.26.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bdd2b45bf079d9ad90377048e2747a0c82351989a2165821f0c96831b4a2a54b"}, + {file = "numpy-1.26.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:211ddd1e94817ed2d175b60b6374120244a4dd2287f4ece45d49228b4d529178"}, + {file = "numpy-1.26.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:b1240f767f69d7c4c8a29adde2310b871153df9b26b5cb2b54a561ac85146485"}, + {file = "numpy-1.26.3-cp310-cp310-win32.whl", hash = "sha256:21a9484e75ad018974a2fdaa216524d64ed4212e418e0a551a2d83403b0531d3"}, + {file = "numpy-1.26.3-cp310-cp310-win_amd64.whl", hash = "sha256:9e1591f6ae98bcfac2a4bbf9221c0b92ab49762228f38287f6eeb5f3f55905ce"}, + {file = "numpy-1.26.3-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:b831295e5472954104ecb46cd98c08b98b49c69fdb7040483aff799a755a7374"}, + {file = "numpy-1.26.3-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:9e87562b91f68dd8b1c39149d0323b42e0082db7ddb8e934ab4c292094d575d6"}, + {file = "numpy-1.26.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8c66d6fec467e8c0f975818c1796d25c53521124b7cfb760114be0abad53a0a2"}, + {file = "numpy-1.26.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f25e2811a9c932e43943a2615e65fc487a0b6b49218899e62e426e7f0a57eeda"}, + {file = "numpy-1.26.3-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:af36e0aa45e25c9f57bf684b1175e59ea05d9a7d3e8e87b7ae1a1da246f2767e"}, + {file = "numpy-1.26.3-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:51c7f1b344f302067b02e0f5b5d2daa9ed4a721cf49f070280ac202738ea7f00"}, + {file = "numpy-1.26.3-cp311-cp311-win32.whl", hash = "sha256:7ca4f24341df071877849eb2034948459ce3a07915c2734f1abb4018d9c49d7b"}, + {file = "numpy-1.26.3-cp311-cp311-win_amd64.whl", hash = "sha256:39763aee6dfdd4878032361b30b2b12593fb445ddb66bbac802e2113eb8a6ac4"}, + {file = "numpy-1.26.3-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:a7081fd19a6d573e1a05e600c82a1c421011db7935ed0d5c483e9dd96b99cf13"}, + {file = "numpy-1.26.3-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:12c70ac274b32bc00c7f61b515126c9205323703abb99cd41836e8125ea0043e"}, + {file = "numpy-1.26.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7f784e13e598e9594750b2ef6729bcd5a47f6cfe4a12cca13def35e06d8163e3"}, + {file = "numpy-1.26.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5f24750ef94d56ce6e33e4019a8a4d68cfdb1ef661a52cdaee628a56d2437419"}, + {file = "numpy-1.26.3-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:77810ef29e0fb1d289d225cabb9ee6cf4d11978a00bb99f7f8ec2132a84e0166"}, + {file = "numpy-1.26.3-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8ed07a90f5450d99dad60d3799f9c03c6566709bd53b497eb9ccad9a55867f36"}, + {file = "numpy-1.26.3-cp312-cp312-win32.whl", hash = "sha256:f73497e8c38295aaa4741bdfa4fda1a5aedda5473074369eca10626835445511"}, + {file = "numpy-1.26.3-cp312-cp312-win_amd64.whl", hash = "sha256:da4b0c6c699a0ad73c810736303f7fbae483bcb012e38d7eb06a5e3b432c981b"}, + {file = "numpy-1.26.3-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:1666f634cb3c80ccbd77ec97bc17337718f56d6658acf5d3b906ca03e90ce87f"}, + {file = "numpy-1.26.3-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:18c3319a7d39b2c6a9e3bb75aab2304ab79a811ac0168a671a62e6346c29b03f"}, + {file = "numpy-1.26.3-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0b7e807d6888da0db6e7e75838444d62495e2b588b99e90dd80c3459594e857b"}, + {file = "numpy-1.26.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b4d362e17bcb0011738c2d83e0a65ea8ce627057b2fdda37678f4374a382a137"}, + {file = "numpy-1.26.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:b8c275f0ae90069496068c714387b4a0eba5d531aace269559ff2b43655edd58"}, + {file = "numpy-1.26.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:cc0743f0302b94f397a4a65a660d4cd24267439eb16493fb3caad2e4389bccbb"}, + {file = "numpy-1.26.3-cp39-cp39-win32.whl", hash = "sha256:9bc6d1a7f8cedd519c4b7b1156d98e051b726bf160715b769106661d567b3f03"}, + {file = "numpy-1.26.3-cp39-cp39-win_amd64.whl", hash = "sha256:867e3644e208c8922a3be26fc6bbf112a035f50f0a86497f98f228c50c607bb2"}, + {file = "numpy-1.26.3-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:3c67423b3703f8fbd90f5adaa37f85b5794d3366948efe9a5190a5f3a83fc34e"}, + {file = "numpy-1.26.3-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:46f47ee566d98849323f01b349d58f2557f02167ee301e5e28809a8c0e27a2d0"}, + {file = "numpy-1.26.3-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:a8474703bffc65ca15853d5fd4d06b18138ae90c17c8d12169968e998e448bb5"}, + {file = "numpy-1.26.3.tar.gz", hash = "sha256:697df43e2b6310ecc9d95f05d5ef20eacc09c7c4ecc9da3f235d39e71b7da1e4"}, +] + +[[package]] +name = "packaging" +version = "23.2" +description = "Core utilities for Python packages" +optional = false +python-versions = ">=3.7" +files = [ + {file = "packaging-23.2-py3-none-any.whl", hash = "sha256:8c491190033a9af7e1d931d0b5dacc2ef47509b34dd0de67ed209b5203fc88c7"}, + {file = "packaging-23.2.tar.gz", hash = "sha256:048fb0e9405036518eaaf48a55953c750c11e1a1b68e0dd1a9d62ed0c092cfc5"}, +] + +[[package]] +name = "pandas" +version = "2.1.4" +description = "Powerful data structures for data analysis, time series, and statistics" +optional = false +python-versions = ">=3.9" +files = [ + {file = "pandas-2.1.4-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:bdec823dc6ec53f7a6339a0e34c68b144a7a1fd28d80c260534c39c62c5bf8c9"}, + {file = "pandas-2.1.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:294d96cfaf28d688f30c918a765ea2ae2e0e71d3536754f4b6de0ea4a496d034"}, + {file = "pandas-2.1.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6b728fb8deba8905b319f96447a27033969f3ea1fea09d07d296c9030ab2ed1d"}, + {file = "pandas-2.1.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:00028e6737c594feac3c2df15636d73ace46b8314d236100b57ed7e4b9ebe8d9"}, + {file = "pandas-2.1.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:426dc0f1b187523c4db06f96fb5c8d1a845e259c99bda74f7de97bd8a3bb3139"}, + {file = "pandas-2.1.4-cp310-cp310-win_amd64.whl", hash = "sha256:f237e6ca6421265643608813ce9793610ad09b40154a3344a088159590469e46"}, + {file = "pandas-2.1.4-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:b7d852d16c270e4331f6f59b3e9aa23f935f5c4b0ed2d0bc77637a8890a5d092"}, + {file = "pandas-2.1.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:bd7d5f2f54f78164b3d7a40f33bf79a74cdee72c31affec86bfcabe7e0789821"}, + {file = "pandas-2.1.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0aa6e92e639da0d6e2017d9ccff563222f4eb31e4b2c3cf32a2a392fc3103c0d"}, + {file = "pandas-2.1.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d797591b6846b9db79e65dc2d0d48e61f7db8d10b2a9480b4e3faaddc421a171"}, + {file = "pandas-2.1.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:d2d3e7b00f703aea3945995ee63375c61b2e6aa5aa7871c5d622870e5e137623"}, + {file = "pandas-2.1.4-cp311-cp311-win_amd64.whl", hash = "sha256:dc9bf7ade01143cddc0074aa6995edd05323974e6e40d9dbde081021ded8510e"}, + {file = "pandas-2.1.4-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:482d5076e1791777e1571f2e2d789e940dedd927325cc3cb6d0800c6304082f6"}, + {file = "pandas-2.1.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:8a706cfe7955c4ca59af8c7a0517370eafbd98593155b48f10f9811da440248b"}, + {file = "pandas-2.1.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b0513a132a15977b4a5b89aabd304647919bc2169eac4c8536afb29c07c23540"}, + {file = "pandas-2.1.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e9f17f2b6fc076b2a0078862547595d66244db0f41bf79fc5f64a5c4d635bead"}, + {file = "pandas-2.1.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:45d63d2a9b1b37fa6c84a68ba2422dc9ed018bdaa668c7f47566a01188ceeec1"}, + {file = "pandas-2.1.4-cp312-cp312-win_amd64.whl", hash = "sha256:f69b0c9bb174a2342818d3e2778584e18c740d56857fc5cdb944ec8bbe4082cf"}, + {file = "pandas-2.1.4-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:3f06bda01a143020bad20f7a85dd5f4a1600112145f126bc9e3e42077c24ef34"}, + {file = "pandas-2.1.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:ab5796839eb1fd62a39eec2916d3e979ec3130509930fea17fe6f81e18108f6a"}, + {file = "pandas-2.1.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:edbaf9e8d3a63a9276d707b4d25930a262341bca9874fcb22eff5e3da5394732"}, + {file = "pandas-2.1.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1ebfd771110b50055712b3b711b51bee5d50135429364d0498e1213a7adc2be8"}, + {file = "pandas-2.1.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8ea107e0be2aba1da619cc6ba3f999b2bfc9669a83554b1904ce3dd9507f0860"}, + {file = "pandas-2.1.4-cp39-cp39-win_amd64.whl", hash = "sha256:d65148b14788b3758daf57bf42725caa536575da2b64df9964c563b015230984"}, + {file = "pandas-2.1.4.tar.gz", hash = "sha256:fcb68203c833cc735321512e13861358079a96c174a61f5116a1de89c58c0ef7"}, +] + +[package.dependencies] +numpy = {version = ">=1.23.2,<2", markers = "python_version == \"3.11\""} +python-dateutil = ">=2.8.2" +pytz = ">=2020.1" +tzdata = ">=2022.1" + +[package.extras] +all = ["PyQt5 (>=5.15.6)", "SQLAlchemy (>=1.4.36)", "beautifulsoup4 (>=4.11.1)", "bottleneck (>=1.3.4)", "dataframe-api-compat (>=0.1.7)", "fastparquet (>=0.8.1)", "fsspec (>=2022.05.0)", "gcsfs (>=2022.05.0)", "html5lib (>=1.1)", "hypothesis (>=6.46.1)", "jinja2 (>=3.1.2)", "lxml (>=4.8.0)", "matplotlib (>=3.6.1)", "numba (>=0.55.2)", "numexpr (>=2.8.0)", "odfpy (>=1.4.1)", "openpyxl (>=3.0.10)", "pandas-gbq (>=0.17.5)", "psycopg2 (>=2.9.3)", "pyarrow (>=7.0.0)", "pymysql (>=1.0.2)", "pyreadstat (>=1.1.5)", "pytest (>=7.3.2)", "pytest-xdist (>=2.2.0)", "pyxlsb (>=1.0.9)", "qtpy (>=2.2.0)", "s3fs (>=2022.05.0)", "scipy (>=1.8.1)", "tables (>=3.7.0)", "tabulate (>=0.8.10)", "xarray (>=2022.03.0)", "xlrd (>=2.0.1)", "xlsxwriter (>=3.0.3)", "zstandard (>=0.17.0)"] +aws = ["s3fs (>=2022.05.0)"] +clipboard = ["PyQt5 (>=5.15.6)", "qtpy (>=2.2.0)"] +compression = ["zstandard (>=0.17.0)"] +computation = ["scipy (>=1.8.1)", "xarray (>=2022.03.0)"] +consortium-standard = ["dataframe-api-compat (>=0.1.7)"] +excel = ["odfpy (>=1.4.1)", "openpyxl (>=3.0.10)", "pyxlsb (>=1.0.9)", "xlrd (>=2.0.1)", "xlsxwriter (>=3.0.3)"] +feather = ["pyarrow (>=7.0.0)"] +fss = ["fsspec (>=2022.05.0)"] +gcp = ["gcsfs (>=2022.05.0)", "pandas-gbq (>=0.17.5)"] +hdf5 = ["tables (>=3.7.0)"] +html = ["beautifulsoup4 (>=4.11.1)", "html5lib (>=1.1)", "lxml (>=4.8.0)"] +mysql = ["SQLAlchemy (>=1.4.36)", "pymysql (>=1.0.2)"] +output-formatting = ["jinja2 (>=3.1.2)", "tabulate (>=0.8.10)"] +parquet = ["pyarrow (>=7.0.0)"] +performance = ["bottleneck (>=1.3.4)", "numba (>=0.55.2)", "numexpr (>=2.8.0)"] +plot = ["matplotlib (>=3.6.1)"] +postgresql = ["SQLAlchemy (>=1.4.36)", "psycopg2 (>=2.9.3)"] +spss = ["pyreadstat (>=1.1.5)"] +sql-other = ["SQLAlchemy (>=1.4.36)"] +test = ["hypothesis (>=6.46.1)", "pytest (>=7.3.2)", "pytest-xdist (>=2.2.0)"] +xml = ["lxml (>=4.8.0)"] + +[[package]] +name = "pathspec" +version = "0.12.1" +description = "Utility library for gitignore style pattern matching of file paths." +optional = false +python-versions = ">=3.8" +files = [ + {file = "pathspec-0.12.1-py3-none-any.whl", hash = "sha256:a0d503e138a4c123b27490a4f7beda6a01c6f288df0e4a8b79c7eb0dc7b4cc08"}, + {file = "pathspec-0.12.1.tar.gz", hash = "sha256:a482d51503a1ab33b1c67a6c3813a26953dbdc71c31dacaef9a838c4e29f5712"}, +] + +[[package]] +name = "pillow" +version = "10.2.0" +description = "Python Imaging Library (Fork)" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pillow-10.2.0-cp310-cp310-macosx_10_10_x86_64.whl", hash = "sha256:7823bdd049099efa16e4246bdf15e5a13dbb18a51b68fa06d6c1d4d8b99a796e"}, + {file = "pillow-10.2.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:83b2021f2ade7d1ed556bc50a399127d7fb245e725aa0113ebd05cfe88aaf588"}, + {file = "pillow-10.2.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6fad5ff2f13d69b7e74ce5b4ecd12cc0ec530fcee76356cac6742785ff71c452"}, + {file = "pillow-10.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:da2b52b37dad6d9ec64e653637a096905b258d2fc2b984c41ae7d08b938a67e4"}, + {file = "pillow-10.2.0-cp310-cp310-manylinux_2_28_aarch64.whl", hash = "sha256:47c0995fc4e7f79b5cfcab1fc437ff2890b770440f7696a3ba065ee0fd496563"}, + {file = "pillow-10.2.0-cp310-cp310-manylinux_2_28_x86_64.whl", hash = "sha256:322bdf3c9b556e9ffb18f93462e5f749d3444ce081290352c6070d014c93feb2"}, + {file = "pillow-10.2.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:51f1a1bffc50e2e9492e87d8e09a17c5eea8409cda8d3f277eb6edc82813c17c"}, + {file = "pillow-10.2.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:69ffdd6120a4737710a9eee73e1d2e37db89b620f702754b8f6e62594471dee0"}, + {file = "pillow-10.2.0-cp310-cp310-win32.whl", hash = "sha256:c6dafac9e0f2b3c78df97e79af707cdc5ef8e88208d686a4847bab8266870023"}, + {file = "pillow-10.2.0-cp310-cp310-win_amd64.whl", hash = "sha256:aebb6044806f2e16ecc07b2a2637ee1ef67a11840a66752751714a0d924adf72"}, + {file = "pillow-10.2.0-cp310-cp310-win_arm64.whl", hash = "sha256:7049e301399273a0136ff39b84c3678e314f2158f50f517bc50285fb5ec847ad"}, + {file = "pillow-10.2.0-cp311-cp311-macosx_10_10_x86_64.whl", hash = "sha256:35bb52c37f256f662abdfa49d2dfa6ce5d93281d323a9af377a120e89a9eafb5"}, + {file = "pillow-10.2.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:9c23f307202661071d94b5e384e1e1dc7dfb972a28a2310e4ee16103e66ddb67"}, + {file = "pillow-10.2.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:773efe0603db30c281521a7c0214cad7836c03b8ccff897beae9b47c0b657d61"}, + {file = "pillow-10.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:11fa2e5984b949b0dd6d7a94d967743d87c577ff0b83392f17cb3990d0d2fd6e"}, + {file = "pillow-10.2.0-cp311-cp311-manylinux_2_28_aarch64.whl", hash = "sha256:716d30ed977be8b37d3ef185fecb9e5a1d62d110dfbdcd1e2a122ab46fddb03f"}, + {file = "pillow-10.2.0-cp311-cp311-manylinux_2_28_x86_64.whl", hash = "sha256:a086c2af425c5f62a65e12fbf385f7c9fcb8f107d0849dba5839461a129cf311"}, + {file = "pillow-10.2.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:c8de2789052ed501dd829e9cae8d3dcce7acb4777ea4a479c14521c942d395b1"}, + {file = "pillow-10.2.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:609448742444d9290fd687940ac0b57fb35e6fd92bdb65386e08e99af60bf757"}, + {file = "pillow-10.2.0-cp311-cp311-win32.whl", hash = "sha256:823ef7a27cf86df6597fa0671066c1b596f69eba53efa3d1e1cb8b30f3533068"}, + {file = "pillow-10.2.0-cp311-cp311-win_amd64.whl", hash = "sha256:1da3b2703afd040cf65ec97efea81cfba59cdbed9c11d8efc5ab09df9509fc56"}, + {file = "pillow-10.2.0-cp311-cp311-win_arm64.whl", hash = "sha256:edca80cbfb2b68d7b56930b84a0e45ae1694aeba0541f798e908a49d66b837f1"}, + {file = "pillow-10.2.0-cp312-cp312-macosx_10_10_x86_64.whl", hash = "sha256:1b5e1b74d1bd1b78bc3477528919414874748dd363e6272efd5abf7654e68bef"}, + {file = "pillow-10.2.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:0eae2073305f451d8ecacb5474997c08569fb4eb4ac231ffa4ad7d342fdc25ac"}, + {file = "pillow-10.2.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b7c2286c23cd350b80d2fc9d424fc797575fb16f854b831d16fd47ceec078f2c"}, + {file = "pillow-10.2.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1e23412b5c41e58cec602f1135c57dfcf15482013ce6e5f093a86db69646a5aa"}, + {file = "pillow-10.2.0-cp312-cp312-manylinux_2_28_aarch64.whl", hash = "sha256:52a50aa3fb3acb9cf7213573ef55d31d6eca37f5709c69e6858fe3bc04a5c2a2"}, + {file = "pillow-10.2.0-cp312-cp312-manylinux_2_28_x86_64.whl", hash = "sha256:127cee571038f252a552760076407f9cff79761c3d436a12af6000cd182a9d04"}, + {file = "pillow-10.2.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:8d12251f02d69d8310b046e82572ed486685c38f02176bd08baf216746eb947f"}, + {file = "pillow-10.2.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:54f1852cd531aa981bc0965b7d609f5f6cc8ce8c41b1139f6ed6b3c54ab82bfb"}, + {file = "pillow-10.2.0-cp312-cp312-win32.whl", hash = "sha256:257d8788df5ca62c980314053197f4d46eefedf4e6175bc9412f14412ec4ea2f"}, + {file = "pillow-10.2.0-cp312-cp312-win_amd64.whl", hash = "sha256:154e939c5f0053a383de4fd3d3da48d9427a7e985f58af8e94d0b3c9fcfcf4f9"}, + {file = "pillow-10.2.0-cp312-cp312-win_arm64.whl", hash = "sha256:f379abd2f1e3dddb2b61bc67977a6b5a0a3f7485538bcc6f39ec76163891ee48"}, + {file = "pillow-10.2.0-cp38-cp38-macosx_10_10_x86_64.whl", hash = "sha256:8373c6c251f7ef8bda6675dd6d2b3a0fcc31edf1201266b5cf608b62a37407f9"}, + {file = "pillow-10.2.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:870ea1ada0899fd0b79643990809323b389d4d1d46c192f97342eeb6ee0b8483"}, + {file = "pillow-10.2.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b4b6b1e20608493548b1f32bce8cca185bf0480983890403d3b8753e44077129"}, + {file = "pillow-10.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3031709084b6e7852d00479fd1d310b07d0ba82765f973b543c8af5061cf990e"}, + {file = "pillow-10.2.0-cp38-cp38-manylinux_2_28_aarch64.whl", hash = "sha256:3ff074fc97dd4e80543a3e91f69d58889baf2002b6be64347ea8cf5533188213"}, + {file = "pillow-10.2.0-cp38-cp38-manylinux_2_28_x86_64.whl", hash = "sha256:cb4c38abeef13c61d6916f264d4845fab99d7b711be96c326b84df9e3e0ff62d"}, + {file = "pillow-10.2.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:b1b3020d90c2d8e1dae29cf3ce54f8094f7938460fb5ce8bc5c01450b01fbaf6"}, + {file = "pillow-10.2.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:170aeb00224ab3dc54230c797f8404507240dd868cf52066f66a41b33169bdbe"}, + {file = "pillow-10.2.0-cp38-cp38-win32.whl", hash = "sha256:c4225f5220f46b2fde568c74fca27ae9771536c2e29d7c04f4fb62c83275ac4e"}, + {file = "pillow-10.2.0-cp38-cp38-win_amd64.whl", hash = "sha256:0689b5a8c5288bc0504d9fcee48f61a6a586b9b98514d7d29b840143d6734f39"}, + {file = "pillow-10.2.0-cp39-cp39-macosx_10_10_x86_64.whl", hash = "sha256:b792a349405fbc0163190fde0dc7b3fef3c9268292586cf5645598b48e63dc67"}, + {file = "pillow-10.2.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:c570f24be1e468e3f0ce7ef56a89a60f0e05b30a3669a459e419c6eac2c35364"}, + {file = "pillow-10.2.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d8ecd059fdaf60c1963c58ceb8997b32e9dc1b911f5da5307aab614f1ce5c2fb"}, + {file = "pillow-10.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c365fd1703040de1ec284b176d6af5abe21b427cb3a5ff68e0759e1e313a5e7e"}, + {file = "pillow-10.2.0-cp39-cp39-manylinux_2_28_aarch64.whl", hash = "sha256:70c61d4c475835a19b3a5aa42492409878bbca7438554a1f89d20d58a7c75c01"}, + {file = "pillow-10.2.0-cp39-cp39-manylinux_2_28_x86_64.whl", hash = "sha256:b6f491cdf80ae540738859d9766783e3b3c8e5bd37f5dfa0b76abdecc5081f13"}, + {file = "pillow-10.2.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:9d189550615b4948f45252d7f005e53c2040cea1af5b60d6f79491a6e147eef7"}, + {file = "pillow-10.2.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:49d9ba1ed0ef3e061088cd1e7538a0759aab559e2e0a80a36f9fd9d8c0c21591"}, + {file = "pillow-10.2.0-cp39-cp39-win32.whl", hash = "sha256:babf5acfede515f176833ed6028754cbcd0d206f7f614ea3447d67c33be12516"}, + {file = "pillow-10.2.0-cp39-cp39-win_amd64.whl", hash = "sha256:0304004f8067386b477d20a518b50f3fa658a28d44e4116970abfcd94fac34a8"}, + {file = "pillow-10.2.0-cp39-cp39-win_arm64.whl", hash = "sha256:0fb3e7fc88a14eacd303e90481ad983fd5b69c761e9e6ef94c983f91025da869"}, + {file = "pillow-10.2.0-pp310-pypy310_pp73-macosx_10_10_x86_64.whl", hash = "sha256:322209c642aabdd6207517e9739c704dc9f9db943015535783239022002f054a"}, + {file = "pillow-10.2.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3eedd52442c0a5ff4f887fab0c1c0bb164d8635b32c894bc1faf4c618dd89df2"}, + {file = "pillow-10.2.0-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:cb28c753fd5eb3dd859b4ee95de66cc62af91bcff5db5f2571d32a520baf1f04"}, + {file = "pillow-10.2.0-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:33870dc4653c5017bf4c8873e5488d8f8d5f8935e2f1fb9a2208c47cdd66efd2"}, + {file = "pillow-10.2.0-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:3c31822339516fb3c82d03f30e22b1d038da87ef27b6a78c9549888f8ceda39a"}, + {file = "pillow-10.2.0-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:a2b56ba36e05f973d450582fb015594aaa78834fefe8dfb8fcd79b93e64ba4c6"}, + {file = "pillow-10.2.0-pp38-pypy38_pp73-win_amd64.whl", hash = "sha256:d8e6aeb9201e655354b3ad049cb77d19813ad4ece0df1249d3c793de3774f8c7"}, + {file = "pillow-10.2.0-pp39-pypy39_pp73-macosx_10_10_x86_64.whl", hash = "sha256:2247178effb34a77c11c0e8ac355c7a741ceca0a732b27bf11e747bbc950722f"}, + {file = "pillow-10.2.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:15587643b9e5eb26c48e49a7b33659790d28f190fc514a322d55da2fb5c2950e"}, + {file = "pillow-10.2.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:753cd8f2086b2b80180d9b3010dd4ed147efc167c90d3bf593fe2af21265e5a5"}, + {file = "pillow-10.2.0-pp39-pypy39_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:7c8f97e8e7a9009bcacbe3766a36175056c12f9a44e6e6f2d5caad06dcfbf03b"}, + {file = "pillow-10.2.0-pp39-pypy39_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:d1b35bcd6c5543b9cb547dee3150c93008f8dd0f1fef78fc0cd2b141c5baf58a"}, + {file = "pillow-10.2.0-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:fe4c15f6c9285dc54ce6553a3ce908ed37c8f3825b5a51a15c91442bb955b868"}, + {file = "pillow-10.2.0.tar.gz", hash = "sha256:e87f0b2c78157e12d7686b27d63c070fd65d994e8ddae6f328e0dcf4a0cd007e"}, +] + +[package.extras] +docs = ["furo", "olefile", "sphinx (>=2.4)", "sphinx-copybutton", "sphinx-inline-tabs", "sphinx-removed-in", "sphinxext-opengraph"] +fpx = ["olefile"] +mic = ["olefile"] +tests = ["check-manifest", "coverage", "defusedxml", "markdown2", "olefile", "packaging", "pyroma", "pytest", "pytest-cov", "pytest-timeout"] +typing = ["typing-extensions"] +xmp = ["defusedxml"] + +[[package]] +name = "platformdirs" +version = "4.2.0" +description = "A small Python package for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." +optional = false +python-versions = ">=3.8" +files = [ + {file = "platformdirs-4.2.0-py3-none-any.whl", hash = "sha256:0614df2a2f37e1a662acbd8e2b25b92ccf8632929bc6d43467e17fe89c75e068"}, + {file = "platformdirs-4.2.0.tar.gz", hash = "sha256:ef0cc731df711022c174543cb70a9b5bd22e5a9337c8624ef2c2ceb8ddad8768"}, +] + +[package.extras] +docs = ["furo (>=2023.9.10)", "proselint (>=0.13)", "sphinx (>=7.2.6)", "sphinx-autodoc-typehints (>=1.25.2)"] +test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=7.4.3)", "pytest-cov (>=4.1)", "pytest-mock (>=3.12)"] + +[[package]] +name = "pluggy" +version = "1.4.0" +description = "plugin and hook calling mechanisms for python" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pluggy-1.4.0-py3-none-any.whl", hash = "sha256:7db9f7b503d67d1c5b95f59773ebb58a8c1c288129a88665838012cfb07b8981"}, + {file = "pluggy-1.4.0.tar.gz", hash = "sha256:8c85c2876142a764e5b7548e7d9a0e0ddb46f5185161049a79b7e974454223be"}, +] + +[package.extras] +dev = ["pre-commit", "tox"] +testing = ["pytest", "pytest-benchmark"] + +[[package]] +name = "pyarrow" +version = "14.0.2" +description = "Python library for Apache Arrow" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pyarrow-14.0.2-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:ba9fe808596c5dbd08b3aeffe901e5f81095baaa28e7d5118e01354c64f22807"}, + {file = "pyarrow-14.0.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:22a768987a16bb46220cef490c56c671993fbee8fd0475febac0b3e16b00a10e"}, + {file = "pyarrow-14.0.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2dbba05e98f247f17e64303eb876f4a80fcd32f73c7e9ad975a83834d81f3fda"}, + {file = "pyarrow-14.0.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a898d134d00b1eca04998e9d286e19653f9d0fcb99587310cd10270907452a6b"}, + {file = "pyarrow-14.0.2-cp310-cp310-manylinux_2_28_aarch64.whl", hash = "sha256:87e879323f256cb04267bb365add7208f302df942eb943c93a9dfeb8f44840b1"}, + {file = "pyarrow-14.0.2-cp310-cp310-manylinux_2_28_x86_64.whl", hash = "sha256:76fc257559404ea5f1306ea9a3ff0541bf996ff3f7b9209fc517b5e83811fa8e"}, + {file = "pyarrow-14.0.2-cp310-cp310-win_amd64.whl", hash = "sha256:b0c4a18e00f3a32398a7f31da47fefcd7a927545b396e1f15d0c85c2f2c778cd"}, + {file = "pyarrow-14.0.2-cp311-cp311-macosx_10_14_x86_64.whl", hash = "sha256:87482af32e5a0c0cce2d12eb3c039dd1d853bd905b04f3f953f147c7a196915b"}, + {file = "pyarrow-14.0.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:059bd8f12a70519e46cd64e1ba40e97eae55e0cbe1695edd95384653d7626b23"}, + {file = "pyarrow-14.0.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3f16111f9ab27e60b391c5f6d197510e3ad6654e73857b4e394861fc79c37200"}, + {file = "pyarrow-14.0.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:06ff1264fe4448e8d02073f5ce45a9f934c0f3db0a04460d0b01ff28befc3696"}, + {file = "pyarrow-14.0.2-cp311-cp311-manylinux_2_28_aarch64.whl", hash = "sha256:6dd4f4b472ccf4042f1eab77e6c8bce574543f54d2135c7e396f413046397d5a"}, + {file = "pyarrow-14.0.2-cp311-cp311-manylinux_2_28_x86_64.whl", hash = "sha256:32356bfb58b36059773f49e4e214996888eeea3a08893e7dbde44753799b2a02"}, + {file = "pyarrow-14.0.2-cp311-cp311-win_amd64.whl", hash = "sha256:52809ee69d4dbf2241c0e4366d949ba035cbcf48409bf404f071f624ed313a2b"}, + {file = "pyarrow-14.0.2-cp312-cp312-macosx_10_14_x86_64.whl", hash = "sha256:c87824a5ac52be210d32906c715f4ed7053d0180c1060ae3ff9b7e560f53f944"}, + {file = "pyarrow-14.0.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:a25eb2421a58e861f6ca91f43339d215476f4fe159eca603c55950c14f378cc5"}, + {file = "pyarrow-14.0.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5c1da70d668af5620b8ba0a23f229030a4cd6c5f24a616a146f30d2386fec422"}, + {file = "pyarrow-14.0.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2cc61593c8e66194c7cdfae594503e91b926a228fba40b5cf25cc593563bcd07"}, + {file = "pyarrow-14.0.2-cp312-cp312-manylinux_2_28_aarch64.whl", hash = "sha256:78ea56f62fb7c0ae8ecb9afdd7893e3a7dbeb0b04106f5c08dbb23f9c0157591"}, + {file = "pyarrow-14.0.2-cp312-cp312-manylinux_2_28_x86_64.whl", hash = "sha256:37c233ddbce0c67a76c0985612fef27c0c92aef9413cf5aa56952f359fcb7379"}, + {file = "pyarrow-14.0.2-cp312-cp312-win_amd64.whl", hash = "sha256:e4b123ad0f6add92de898214d404e488167b87b5dd86e9a434126bc2b7a5578d"}, + {file = "pyarrow-14.0.2-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:e354fba8490de258be7687f341bc04aba181fc8aa1f71e4584f9890d9cb2dec2"}, + {file = "pyarrow-14.0.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:20e003a23a13da963f43e2b432483fdd8c38dc8882cd145f09f21792e1cf22a1"}, + {file = "pyarrow-14.0.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:fc0de7575e841f1595ac07e5bc631084fd06ca8b03c0f2ecece733d23cd5102a"}, + {file = "pyarrow-14.0.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:66e986dc859712acb0bd45601229021f3ffcdfc49044b64c6d071aaf4fa49e98"}, + {file = "pyarrow-14.0.2-cp38-cp38-manylinux_2_28_aarch64.whl", hash = "sha256:f7d029f20ef56673a9730766023459ece397a05001f4e4d13805111d7c2108c0"}, + {file = "pyarrow-14.0.2-cp38-cp38-manylinux_2_28_x86_64.whl", hash = "sha256:209bac546942b0d8edc8debda248364f7f668e4aad4741bae58e67d40e5fcf75"}, + {file = "pyarrow-14.0.2-cp38-cp38-win_amd64.whl", hash = "sha256:1e6987c5274fb87d66bb36816afb6f65707546b3c45c44c28e3c4133c010a881"}, + {file = "pyarrow-14.0.2-cp39-cp39-macosx_10_14_x86_64.whl", hash = "sha256:a01d0052d2a294a5f56cc1862933014e696aa08cc7b620e8c0cce5a5d362e976"}, + {file = "pyarrow-14.0.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:a51fee3a7db4d37f8cda3ea96f32530620d43b0489d169b285d774da48ca9785"}, + {file = "pyarrow-14.0.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:64df2bf1ef2ef14cee531e2dfe03dd924017650ffaa6f9513d7a1bb291e59c15"}, + {file = "pyarrow-14.0.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3c0fa3bfdb0305ffe09810f9d3e2e50a2787e3a07063001dcd7adae0cee3601a"}, + {file = "pyarrow-14.0.2-cp39-cp39-manylinux_2_28_aarch64.whl", hash = "sha256:c65bf4fd06584f058420238bc47a316e80dda01ec0dfb3044594128a6c2db794"}, + {file = "pyarrow-14.0.2-cp39-cp39-manylinux_2_28_x86_64.whl", hash = "sha256:63ac901baec9369d6aae1cbe6cca11178fb018a8d45068aaf5bb54f94804a866"}, + {file = "pyarrow-14.0.2-cp39-cp39-win_amd64.whl", hash = "sha256:75ee0efe7a87a687ae303d63037d08a48ef9ea0127064df18267252cfe2e9541"}, + {file = "pyarrow-14.0.2.tar.gz", hash = "sha256:36cef6ba12b499d864d1def3e990f97949e0b79400d08b7cf74504ffbd3eb025"}, +] + +[package.dependencies] +numpy = ">=1.16.6" + +[[package]] +name = "pycodestyle" +version = "2.11.1" +description = "Python style guide checker" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pycodestyle-2.11.1-py2.py3-none-any.whl", hash = "sha256:44fe31000b2d866f2e41841b18528a505fbd7fef9017b04eff4e2648a0fadc67"}, + {file = "pycodestyle-2.11.1.tar.gz", hash = "sha256:41ba0e7afc9752dfb53ced5489e89f8186be00e599e712660695b7a75ff2663f"}, +] + +[[package]] +name = "pyflakes" +version = "3.2.0" +description = "passive checker of Python programs" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pyflakes-3.2.0-py2.py3-none-any.whl", hash = "sha256:84b5be138a2dfbb40689ca07e2152deb896a65c3a3e24c251c5c62489568074a"}, + {file = "pyflakes-3.2.0.tar.gz", hash = "sha256:1c61603ff154621fb2a9172037d84dca3500def8c8b630657d1701f026f8af3f"}, +] + +[[package]] +name = "pyparsing" +version = "3.1.1" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" +optional = false +python-versions = ">=3.6.8" +files = [ + {file = "pyparsing-3.1.1-py3-none-any.whl", hash = "sha256:32c7c0b711493c72ff18a981d24f28aaf9c1fb7ed5e9667c9e84e3db623bdbfb"}, + {file = "pyparsing-3.1.1.tar.gz", hash = "sha256:ede28a1a32462f5a9705e07aea48001a08f7cf81a021585011deba701581a0db"}, +] + +[package.extras] +diagrams = ["jinja2", "railroad-diagrams"] + +[[package]] +name = "pytest" +version = "7.4.3" +description = "pytest: simple powerful testing with Python" +optional = false +python-versions = ">=3.7" +files = [ + {file = "pytest-7.4.3-py3-none-any.whl", hash = "sha256:0d009c083ea859a71b76adf7c1d502e4bc170b80a8ef002da5806527b9591fac"}, + {file = "pytest-7.4.3.tar.gz", hash = "sha256:d989d136982de4e3b29dabcc838ad581c64e8ed52c11fbe86ddebd9da0818cd5"}, +] + +[package.dependencies] +colorama = {version = "*", markers = "sys_platform == \"win32\""} +iniconfig = "*" +packaging = "*" +pluggy = ">=0.12,<2.0" + +[package.extras] +testing = ["argcomplete", "attrs (>=19.2.0)", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "setuptools", "xmlschema"] + +[[package]] +name = "python-dateutil" +version = "2.8.2" +description = "Extensions to the standard Python datetime module" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" +files = [ + {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, + {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, +] + +[package.dependencies] +six = ">=1.5" + +[[package]] +name = "pytz" +version = "2023.4" +description = "World timezone definitions, modern and historical" +optional = false +python-versions = "*" +files = [ + {file = "pytz-2023.4-py2.py3-none-any.whl", hash = "sha256:f90ef520d95e7c46951105338d918664ebfd6f1d995bd7d153127ce90efafa6a"}, + {file = "pytz-2023.4.tar.gz", hash = "sha256:31d4583c4ed539cd037956140d695e42c033a19e984bfce9964a3f7d59bc2b40"}, +] + +[[package]] +name = "pyyaml" +version = "6.0.1" +description = "YAML parser and emitter for Python" +optional = false +python-versions = ">=3.6" +files = [ + {file = "PyYAML-6.0.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d858aa552c999bc8a8d57426ed01e40bef403cd8ccdd0fc5f6f04a00414cac2a"}, + {file = "PyYAML-6.0.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:fd66fc5d0da6d9815ba2cebeb4205f95818ff4b79c3ebe268e75d961704af52f"}, + {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:69b023b2b4daa7548bcfbd4aa3da05b3a74b772db9e23b982788168117739938"}, + {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:81e0b275a9ecc9c0c0c07b4b90ba548307583c125f54d5b6946cfee6360c733d"}, + {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ba336e390cd8e4d1739f42dfe9bb83a3cc2e80f567d8805e11b46f4a943f5515"}, + {file = "PyYAML-6.0.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:326c013efe8048858a6d312ddd31d56e468118ad4cdeda36c719bf5bb6192290"}, + {file = "PyYAML-6.0.1-cp310-cp310-win32.whl", hash = "sha256:bd4af7373a854424dabd882decdc5579653d7868b8fb26dc7d0e99f823aa5924"}, + {file = "PyYAML-6.0.1-cp310-cp310-win_amd64.whl", hash = "sha256:fd1592b3fdf65fff2ad0004b5e363300ef59ced41c2e6b3a99d4089fa8c5435d"}, + {file = "PyYAML-6.0.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:6965a7bc3cf88e5a1c3bd2e0b5c22f8d677dc88a455344035f03399034eb3007"}, + {file = "PyYAML-6.0.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:f003ed9ad21d6a4713f0a9b5a7a0a79e08dd0f221aff4525a2be4c346ee60aab"}, + {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:42f8152b8dbc4fe7d96729ec2b99c7097d656dc1213a3229ca5383f973a5ed6d"}, + {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:062582fca9fabdd2c8b54a3ef1c978d786e0f6b3a1510e0ac93ef59e0ddae2bc"}, + {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d2b04aac4d386b172d5b9692e2d2da8de7bfb6c387fa4f801fbf6fb2e6ba4673"}, + {file = "PyYAML-6.0.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:e7d73685e87afe9f3b36c799222440d6cf362062f78be1013661b00c5c6f678b"}, + {file = "PyYAML-6.0.1-cp311-cp311-win32.whl", hash = "sha256:1635fd110e8d85d55237ab316b5b011de701ea0f29d07611174a1b42f1444741"}, + {file = "PyYAML-6.0.1-cp311-cp311-win_amd64.whl", hash = "sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34"}, + {file = "PyYAML-6.0.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:855fb52b0dc35af121542a76b9a84f8d1cd886ea97c84703eaa6d88e37a2ad28"}, + {file = "PyYAML-6.0.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:40df9b996c2b73138957fe23a16a4f0ba614f4c0efce1e9406a184b6d07fa3a9"}, + {file = "PyYAML-6.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6c22bec3fbe2524cde73d7ada88f6566758a8f7227bfbf93a408a9d86bcc12a0"}, + {file = "PyYAML-6.0.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8d4e9c88387b0f5c7d5f281e55304de64cf7f9c0021a3525bd3b1c542da3b0e4"}, + {file = "PyYAML-6.0.1-cp312-cp312-win32.whl", hash = "sha256:d483d2cdf104e7c9fa60c544d92981f12ad66a457afae824d146093b8c294c54"}, + {file = "PyYAML-6.0.1-cp312-cp312-win_amd64.whl", hash = "sha256:0d3304d8c0adc42be59c5f8a4d9e3d7379e6955ad754aa9d6ab7a398b59dd1df"}, + {file = "PyYAML-6.0.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:50550eb667afee136e9a77d6dc71ae76a44df8b3e51e41b77f6de2932bfe0f47"}, + {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1fe35611261b29bd1de0070f0b2f47cb6ff71fa6595c077e42bd0c419fa27b98"}, + {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:704219a11b772aea0d8ecd7058d0082713c3562b4e271b849ad7dc4a5c90c13c"}, + {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:afd7e57eddb1a54f0f1a974bc4391af8bcce0b444685d936840f125cf046d5bd"}, + {file = "PyYAML-6.0.1-cp36-cp36m-win32.whl", hash = "sha256:fca0e3a251908a499833aa292323f32437106001d436eca0e6e7833256674585"}, + {file = "PyYAML-6.0.1-cp36-cp36m-win_amd64.whl", hash = "sha256:f22ac1c3cac4dbc50079e965eba2c1058622631e526bd9afd45fedd49ba781fa"}, + {file = "PyYAML-6.0.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b1275ad35a5d18c62a7220633c913e1b42d44b46ee12554e5fd39c70a243d6a3"}, + {file = "PyYAML-6.0.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:18aeb1bf9a78867dc38b259769503436b7c72f7a1f1f4c93ff9a17de54319b27"}, + {file = "PyYAML-6.0.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:596106435fa6ad000c2991a98fa58eeb8656ef2325d7e158344fb33864ed87e3"}, + {file = "PyYAML-6.0.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:baa90d3f661d43131ca170712d903e6295d1f7a0f595074f151c0aed377c9b9c"}, + {file = "PyYAML-6.0.1-cp37-cp37m-win32.whl", hash = "sha256:9046c58c4395dff28dd494285c82ba00b546adfc7ef001486fbf0324bc174fba"}, + {file = "PyYAML-6.0.1-cp37-cp37m-win_amd64.whl", hash = "sha256:4fb147e7a67ef577a588a0e2c17b6db51dda102c71de36f8549b6816a96e1867"}, + {file = "PyYAML-6.0.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:1d4c7e777c441b20e32f52bd377e0c409713e8bb1386e1099c2415f26e479595"}, + {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a0cd17c15d3bb3fa06978b4e8958dcdc6e0174ccea823003a106c7d4d7899ac5"}, + {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:28c119d996beec18c05208a8bd78cbe4007878c6dd15091efb73a30e90539696"}, + {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7e07cbde391ba96ab58e532ff4803f79c4129397514e1413a7dc761ccd755735"}, + {file = "PyYAML-6.0.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:49a183be227561de579b4a36efbb21b3eab9651dd81b1858589f796549873dd6"}, + {file = "PyYAML-6.0.1-cp38-cp38-win32.whl", hash = "sha256:184c5108a2aca3c5b3d3bf9395d50893a7ab82a38004c8f61c258d4428e80206"}, + {file = "PyYAML-6.0.1-cp38-cp38-win_amd64.whl", hash = "sha256:1e2722cc9fbb45d9b87631ac70924c11d3a401b2d7f410cc0e3bbf249f2dca62"}, + {file = "PyYAML-6.0.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:9eb6caa9a297fc2c2fb8862bc5370d0303ddba53ba97e71f08023b6cd73d16a8"}, + {file = "PyYAML-6.0.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:c8098ddcc2a85b61647b2590f825f3db38891662cfc2fc776415143f599bb859"}, + {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5773183b6446b2c99bb77e77595dd486303b4faab2b086e7b17bc6bef28865f6"}, + {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b786eecbdf8499b9ca1d697215862083bd6d2a99965554781d0d8d1ad31e13a0"}, + {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bc1bf2925a1ecd43da378f4db9e4f799775d6367bdb94671027b73b393a7c42c"}, + {file = "PyYAML-6.0.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:04ac92ad1925b2cff1db0cfebffb6ffc43457495c9b3c39d3fcae417d7125dc5"}, + {file = "PyYAML-6.0.1-cp39-cp39-win32.whl", hash = "sha256:faca3bdcf85b2fc05d06ff3fbc1f83e1391b3e724afa3feba7d13eeab355484c"}, + {file = "PyYAML-6.0.1-cp39-cp39-win_amd64.whl", hash = "sha256:510c9deebc5c0225e8c96813043e62b680ba2f9c50a08d3724c7f28a747d1486"}, + {file = "PyYAML-6.0.1.tar.gz", hash = "sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43"}, +] + +[[package]] +name = "scipy" +version = "1.10.1" +description = "Fundamental algorithms for scientific computing in Python" +optional = false +python-versions = "<3.12,>=3.8" +files = [ + {file = "scipy-1.10.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:e7354fd7527a4b0377ce55f286805b34e8c54b91be865bac273f527e1b839019"}, + {file = "scipy-1.10.1-cp310-cp310-macosx_12_0_arm64.whl", hash = "sha256:4b3f429188c66603a1a5c549fb414e4d3bdc2a24792e061ffbd607d3d75fd84e"}, + {file = "scipy-1.10.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1553b5dcddd64ba9a0d95355e63fe6c3fc303a8fd77c7bc91e77d61363f7433f"}, + {file = "scipy-1.10.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4c0ff64b06b10e35215abce517252b375e580a6125fd5fdf6421b98efbefb2d2"}, + {file = "scipy-1.10.1-cp310-cp310-win_amd64.whl", hash = "sha256:fae8a7b898c42dffe3f7361c40d5952b6bf32d10c4569098d276b4c547905ee1"}, + {file = "scipy-1.10.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:0f1564ea217e82c1bbe75ddf7285ba0709ecd503f048cb1236ae9995f64217bd"}, + {file = "scipy-1.10.1-cp311-cp311-macosx_12_0_arm64.whl", hash = "sha256:d925fa1c81b772882aa55bcc10bf88324dadb66ff85d548c71515f6689c6dac5"}, + {file = "scipy-1.10.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:aaea0a6be54462ec027de54fca511540980d1e9eea68b2d5c1dbfe084797be35"}, + {file = "scipy-1.10.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:15a35c4242ec5f292c3dd364a7c71a61be87a3d4ddcc693372813c0b73c9af1d"}, + {file = "scipy-1.10.1-cp311-cp311-win_amd64.whl", hash = "sha256:43b8e0bcb877faf0abfb613d51026cd5cc78918e9530e375727bf0625c82788f"}, + {file = "scipy-1.10.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:5678f88c68ea866ed9ebe3a989091088553ba12c6090244fdae3e467b1139c35"}, + {file = "scipy-1.10.1-cp38-cp38-macosx_12_0_arm64.whl", hash = "sha256:39becb03541f9e58243f4197584286e339029e8908c46f7221abeea4b749fa88"}, + {file = "scipy-1.10.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:bce5869c8d68cf383ce240e44c1d9ae7c06078a9396df68ce88a1230f93a30c1"}, + {file = "scipy-1.10.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:07c3457ce0b3ad5124f98a86533106b643dd811dd61b548e78cf4c8786652f6f"}, + {file = "scipy-1.10.1-cp38-cp38-win_amd64.whl", hash = "sha256:049a8bbf0ad95277ffba9b3b7d23e5369cc39e66406d60422c8cfef40ccc8415"}, + {file = "scipy-1.10.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:cd9f1027ff30d90618914a64ca9b1a77a431159df0e2a195d8a9e8a04c78abf9"}, + {file = "scipy-1.10.1-cp39-cp39-macosx_12_0_arm64.whl", hash = "sha256:79c8e5a6c6ffaf3a2262ef1be1e108a035cf4f05c14df56057b64acc5bebffb6"}, + {file = "scipy-1.10.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:51af417a000d2dbe1ec6c372dfe688e041a7084da4fdd350aeb139bd3fb55353"}, + {file = "scipy-1.10.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1b4735d6c28aad3cdcf52117e0e91d6b39acd4272f3f5cd9907c24ee931ad601"}, + {file = "scipy-1.10.1-cp39-cp39-win_amd64.whl", hash = "sha256:7ff7f37b1bf4417baca958d254e8e2875d0cc23aaadbe65b3d5b3077b0eb23ea"}, + {file = "scipy-1.10.1.tar.gz", hash = "sha256:2cf9dfb80a7b4589ba4c40ce7588986d6d5cebc5457cad2c2880f6bc2d42f3a5"}, +] + +[package.dependencies] +numpy = ">=1.19.5,<1.27.0" + +[package.extras] +dev = ["click", "doit (>=0.36.0)", "flake8", "mypy", "pycodestyle", "pydevtool", "rich-click", "typing_extensions"] +doc = ["matplotlib (>2)", "numpydoc", "pydata-sphinx-theme (==0.9.0)", "sphinx (!=4.1.0)", "sphinx-design (>=0.2.0)"] +test = ["asv", "gmpy2", "mpmath", "pooch", "pytest", "pytest-cov", "pytest-timeout", "pytest-xdist", "scikit-umfpack", "threadpoolctl"] + +[[package]] +name = "six" +version = "1.16.0" +description = "Python 2 and 3 compatibility utilities" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" +files = [ + {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, + {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, +] + +[[package]] +name = "tqdm" +version = "4.66.1" +description = "Fast, Extensible Progress Meter" +optional = false +python-versions = ">=3.7" +files = [ + {file = "tqdm-4.66.1-py3-none-any.whl", hash = "sha256:d302b3c5b53d47bce91fea46679d9c3c6508cf6332229aa1e7d8653723793386"}, + {file = "tqdm-4.66.1.tar.gz", hash = "sha256:d88e651f9db8d8551a62556d3cff9e3034274ca5d66e93197cf2490e2dcb69c7"}, +] + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + +[package.extras] +dev = ["pytest (>=6)", "pytest-cov", "pytest-timeout", "pytest-xdist"] +notebook = ["ipywidgets (>=6)"] +slack = ["slack-sdk"] +telegram = ["requests"] + +[[package]] +name = "typing-extensions" +version = "4.9.0" +description = "Backported and Experimental Type Hints for Python 3.8+" +optional = false +python-versions = ">=3.8" +files = [ + {file = "typing_extensions-4.9.0-py3-none-any.whl", hash = "sha256:af72aea155e91adfc61c3ae9e0e342dbc0cba726d6cba4b6c72c1f34e47291cd"}, + {file = "typing_extensions-4.9.0.tar.gz", hash = "sha256:23478f88c37f27d76ac8aee6c905017a143b0b1b886c3c9f66bc2fd94f9f5783"}, +] + +[[package]] +name = "tzdata" +version = "2023.4" +description = "Provider of IANA time zone data" +optional = false +python-versions = ">=2" +files = [ + {file = "tzdata-2023.4-py2.py3-none-any.whl", hash = "sha256:aa3ace4329eeacda5b7beb7ea08ece826c28d761cda36e747cfbf97996d39bf3"}, + {file = "tzdata-2023.4.tar.gz", hash = "sha256:dd54c94f294765522c77399649b4fefd95522479a664a0cec87f41bebc6148c9"}, +] + +[[package]] +name = "uhi" +version = "0.4.0" +description = "Unified Histogram Interface: tools to help library authors work with histograms" +optional = false +python-versions = ">=3.7" +files = [ + {file = "uhi-0.4.0-py3-none-any.whl", hash = "sha256:c7e82826314c66b8e7fee7869b75eb038f500b034f5371ef928def41c8db70bc"}, + {file = "uhi-0.4.0.tar.gz", hash = "sha256:0dcb6b19775087d38a31ee388cb2c70f2ecfe04c4ffe2ca63223410cae5beefa"}, +] + +[package.dependencies] +numpy = ">=1.13.3" + +[package.extras] +docs = ["furo", "myst-parser", "sphinx (>=4.0)", "sphinx-copybutton (>=0.3.1)", "sphinx-github-changelog"] +test = ["boost-histogram (>=1.0)", "importlib-metadata (>=1.0)", "pytest (>=6)"] + +[[package]] +name = "uproot" +version = "5.0.4" +description = "ROOT I/O in pure Python and NumPy." +optional = false +python-versions = ">=3.7" +files = [ + {file = "uproot-5.0.4-py3-none-any.whl", hash = "sha256:5a4a526fbec5d5bb3c439dcee0876bc689d42a36627a4a89105924afc3b3ec24"}, + {file = "uproot-5.0.4.tar.gz", hash = "sha256:c4ea1af198e3292a4649e3fe789d11b038c1ed57c10f167fc3f52100300c2eea"}, +] + +[package.dependencies] +awkward = ">=2.0.0" +numpy = "*" +packaging = "*" + +[package.extras] +dev = ["awkward (>=2.0.0)", "awkward-pandas", "boost-histogram (>=0.13)", "dask-awkward (>=2022.12a3)", "dask[array]", "hist (>=1.2)", "pandas"] +test = ["awkward (>=2.0.0)", "lz4", "pytest (>=6)", "pytest-rerunfailures", "pytest-timeout", "requests", "scikit-hep-testdata", "xxhash"] + +[[package]] +name = "vector" +version = "1.1.1.post1" +description = "Vector classes and utilities" +optional = false +python-versions = ">=3.8" +files = [ + {file = "vector-1.1.1.post1-py3-none-any.whl", hash = "sha256:f7683f9fb14be481ea9b562180fbc4cfe09e61168511e05646c2047f4f458282"}, + {file = "vector-1.1.1.post1.tar.gz", hash = "sha256:7a55ae549816e5fca0e52fab8cc66d4b0e4bb3b7753933e85b4167657940372b"}, +] + +[package.dependencies] +numpy = ">=1.13.3" +packaging = ">=19" + +[package.extras] +awkward = ["awkward (>=1.2)"] +dev = ["awkward (>=1.2)", "numba (>=0.57)", "papermill (>=2.4)", "pytest (>=6)", "pytest-cov (>=3)", "xdoctest (>=1)"] +docs = ["awkward (>=1.2)", "ipykernel", "myst-parser (>0.13)", "nbsphinx", "sphinx (>=4)", "sphinx-book-theme (>=0.0.42)", "sphinx-copybutton", "sphinx-math-dollar"] +test = ["papermill (>=2.4)", "pytest (>=6)", "pytest-cov (>=3)", "xdoctest (>=1)"] +test-extras = ["spark-parser", "uncompyle6"] + +[[package]] +name = "zipp" +version = "3.17.0" +description = "Backport of pathlib-compatible object wrapper for zip files" +optional = false +python-versions = ">=3.8" +files = [ + {file = "zipp-3.17.0-py3-none-any.whl", hash = "sha256:0e923e726174922dce09c53c59ad483ff7bbb8e572e00c7f7c46b88556409f31"}, + {file = "zipp-3.17.0.tar.gz", hash = "sha256:84e64a1c28cf7e91ed2078bb8cc8c259cb19b76942096c8d7b84947690cabaf0"}, +] + +[package.extras] +docs = ["furo", "jaraco.packaging (>=9.3)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (<7.2.5)", "sphinx (>=3.5)", "sphinx-lint"] +testing = ["big-O", "jaraco.functools", "jaraco.itertools", "more-itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=2.2)", "pytest-ignore-flaky", "pytest-mypy (>=0.9.1)", "pytest-ruff"] + +[metadata] +lock-version = "2.0" +python-versions = "~3.11.0" +content-hash = "f72223b97aac082185750f37fdad2c15f69643014250fb8e9bb04b268fcdd11a" diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 00000000..33356ede --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,71 @@ +# pyproject.toml +[build-system] +build-backend = 'poetry.core.masonry.api' +requires = [ + "poetry-core~=1.0" +] + +[tool.poetry] +name = "menu-tools" +version = "0.1.0" +description = "Tools to evaluate performance of L1 objects and triggers in the menu for Phase-II." +license = "MIT" +authors = [ + "Matteo Bonanomi ", + "Daniel Hundhausen ", + "Artur Lobanov ", +] +readme = "README.md" +packages = [ + { include = "menu_tools" }, +] + +[tool.poetry.dependencies] +python = "~3.11.0" +awkward = "2.5.2" +fsspec = "2023.12.2" +pyyaml = "6.0.1" +matplotlib = "3.8.2" +mplhep = "0.3.31" +numpy = "^1.23.0" +pandas = "2.1.4" +tqdm = "4.66.1" +pyarrow = "14.0.2" +scipy = "1.10.1" +uproot = "5.0.4" +vector = "1.1.1.post1" + +[tool.poetry.group.dev.dependencies] +black = "23.12.1" +mypy = "1.8.0" +flake8 = "^7.0.0" + +[tool.poetry.group.test.dependencies] +pytest = "7.4.3" + +[tool.poetry.scripts] +cache_objects = "menu_tools.caching.cache_objects:main" +object_performance = "menu_tools.object_performance.plotter:main" +rate_plots = "menu_tools.rate_plots.plotter:main" + +[tool.pytest.ini_options] +filterwarnings = [ + "error", + "ignore::UserWarning", + 'ignore:A NumPy version', +] +pythonpath = [ + "src" +] +testpaths = [ + "tests", +] +[tool.mypy] +files = [ + "menu_tools" +] +disable_error_code = [ + "import-untyped", + "index" +] +explicit_package_bases = true diff --git a/rates/table/README.md b/rates/table/README.md index afdd252c..f6e8bb2e 100644 --- a/rates/table/README.md +++ b/rates/table/README.md @@ -1,16 +1,35 @@ -# Rate table for the Phase-2 L1 Trigger Menu -To run the rate table, for example for the L1 TDR results, do -``` -python run.py cfg/v10_TRIDAS_newThresholds_LHCCReview -``` +# L1 Phase2 Menu Tools: Rate Table -For the firmware-based emulators under 123x, utilise `FBE_noMu_L1TDRMET_mhtSeed_123x` (`FBE_noMu_L1TDRMET_mhtSeed_123x_singleJetEta5` only includes forward region for the singleJet seed). - -To display the rates in an easy-to-read format, run -``` -python3 printRateTable.py -c cfg/v10_TRIDAS_newThresholds_LHCCReview -r out/2020-05-26-MENU-LHCCReview-BugFix_v10_TRIDAS_newThresholds_LHCCReview/thresholds/menu.csv -``` -You can also edit the `CFG_RATE_COMBOS` dictionary at the top of -the file and run the script without any arguments `python3 printRateTable.py`. -This way multiple rate tables can be compared quickly. +The rates table can be produced using the following command: + ./rate_table.py cfg/v29/v29_cfg.yml + +where the `cfg` argument specifies the structure of the config file to be used. + +An example of config can be found in `./cfg/v29_cfg.yml` and it is a `yaml` file +with the following structure: + + MenuV29: + version: "V29" + sample: "/eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/13X/v29_RelVal/RelValTTbar_14TeV/RelVal_13X_TT_200PU_crab_v29_13X_RelVal_FixGenTree/230710_081407/L1NtuplePhaseII_Step1_hadd.root" + menu_config: "cfg/v29/v29_16Seeds_Final_clean_cfg.yml" + scalings: + scalings_path: "/eos/user/m/mbonanom/www/Postdoc/L1PhaseII/V29/scalings/" + collect_scalings: False + scalings_outdir: "scalings_input/V29/" + scalings_file: "scalings.yml" + table: + table_fname: "rates_16Seeds_Final" + table_outdir: "rates_tables/V29" + +The block above defines entirely a menu table (`MenuV29` in the example above). +Several blocks (with a different title) can be specified in the config if one wants to produce +rate tables for different menu configurations. + +The other fields that can be specified are: +* `version`: specifies the version of the ntuples used; +* `sample`: specifies the sample to be used; +* `menu_config`: user-defined config of the menu seeds. See `cfg/v29/v29_16Seeds_Final_clean_cfg.yml` for an example. The current example replicates the menu config implemented in `cfg/v29/v29_16Seeds_Final`; +* `scalings`: this block defines the properties of the scalings file to be used. If `collect_scalings` is `False`, +the scalings file in `scalings_outdir` will be used (`scalings.yml` in the example above corresponds to the `v29` scalings used for AR). If `collect_scalings` is `True`, then the `Scaler` (cf `scaler.py`) class is used to create a new scalings file, with the name specified in `scalings_file` (which will be located in `scalings_outdir`), starting from the per-object `.txt` scalings saved under `scalings_path` (i.e. the output of the `objectPerformance` code); +* `table`: this block defines the properties of the rates table that will be dumped to a `.csv` file. The table will be saved under `table_outdir` with `table_fname` as name. diff --git a/rates/table/cfg/v29/v29_16Seeds_Final_clean_cfg.yml b/rates/table/cfg/v29/v29_16Seeds_Final_clean_cfg.yml new file mode 100644 index 00000000..79bdd1b7 --- /dev/null +++ b/rates/table/cfg/v29/v29_16Seeds_Final_clean_cfg.yml @@ -0,0 +1,208 @@ +L1_DoubleEGEle: + cross_masks: + - ak.where(abs(leg2.phi-leg1.phi) 0.1 + leg1: + leg_mask: + - leg1.offline_pt >= 37 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.5) + leg1.passessaid * (abs(leg1.eta) >= 1.5) + # - ak.where(abs(leg1.eta)<1.5, leg1.passeseleid, leg1.passessaid) + obj: EG + leg2: + leg_mask: + - leg2.offline_pt >= 24 + - abs(leg2.eta)<2.4 + - leg2.passeseleid * (abs(leg2.eta)<1.5) + leg2.passessaid * (abs(leg2.eta) >= 1.5) + # - ak.where(abs(leg2.eta)<1.5, leg2.passeseleid, leg2.passessaid) + obj: EG +L1_SingleEGEle: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 51.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.5) + leg1.passessaid * (abs(leg1.eta) >= 1.5) + obj: EG +L1_SinglePfJet: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt > 230.0 + - leg1.et>25 + - abs(leg1.eta)<2.4 + obj: seededConePuppiJet +L1_SingleTkEle: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 36.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid + # - leg1.passeseleid > 0 + obj: tkElectron +L1_SingleTkEleIso: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 28.0 + - leg1.passeseleid>=0 + - ak.where(abs(leg1.eta)<1.479, leg1.trkiso<0.13, leg1.trkiso<0.28) + obj: tkIsoElectron +L1_SingleTkMu: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt > 22.0 + - abs(leg1.eta)<2.4 + obj: gmtTkMuon +L1_SingleTkPhoIso: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 36.0 + - abs(leg1.eta)<2.4 + - ak.where(abs(leg1.eta)<1.5, leg1.passeseleid, leg1.passesphoid) + - ak.where(abs(leg1.eta)<1.479, leg1.trkiso<0.25, leg1.trkiso<0.205) + obj: tkPhoton +L1_TkEleIso_EG: + cross_masks: + - leg2.deltaR(leg1) > 0.1 + leg1: + leg_mask: + - leg1.offline_pt > 22.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid >= 0 + - ak.where(abs(leg1.eta)<1.479, leg1.trkiso<0.13, leg1.trkiso<0.28) + obj: tkIsoElectron + leg2: + leg_mask: + - leg2.offline_pt > 12.0 + - abs(leg2.eta)<2.4 + - ak.where(abs(leg2.eta)<1.5, leg2.passeseleid, leg2.passessaid) + obj: EG +L1_TripleTkMu: + cross_masks: + - abs(leg2.z0-leg1.z0)<1 + - abs(leg3.z0-leg1.z0)<1 + leg1: + leg_mask: + - leg1.pt>5 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>3 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.pt>3 + - abs(leg3.eta)<2.4 + - leg3.qual>0 + obj: gmtTkMuon +L1_DoubleTkEle: + cross_masks: + - abs(leg2.zvtx-leg1.zvtx)<1 + leg1: + leg_mask: + - leg1.offline_pt >= 25.0 + - abs(leg1.eta)<2.4 + - (((leg1.passeseleid) * (abs(leg1.eta)<1.479)) + ((abs(leg1.eta)>1.479))) + obj: tkElectron + leg2: + leg_mask: + - leg2.offline_pt >= 12.0 + - abs(leg2.eta)<2.4 + - (((leg2.passeseleid) * (abs(leg2.eta)<1.479)) + ((abs(leg2.eta)>1.479))) + obj: tkElectron +L1_DoubleTkMu: + cross_masks: + - abs(leg1.z0-leg2.z0)<1 + leg1: + leg_mask: + - leg1.offline_pt > 15.0 + - abs(leg1.eta)<2.4 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt > 7.0 + - abs(leg2.eta)<2.4 + - leg2.qual > 0 + obj: gmtTkMuon +L1_DoubleTkPhoIso: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt > 22.0 + - abs(leg1.eta)<2.4 + - ak.where(abs(leg1.eta)<1.5, leg1.passeseleid, leg1.passesphoid) + - ak.where(abs(leg1.eta)<1.479, leg1.trkiso<0.25, leg1.trkiso<0.205) + obj: tkPhoton + leg2: + leg_mask: + - leg2.offline_pt > 12.0 + - abs(leg2.eta)<2.4 + - ak.where(abs(leg2.eta)<1.5, leg2.passeseleid, leg2.passesphoid) + - ak.where(abs(leg2.eta)<1.479, leg2.trkiso<0.25, leg2.trkiso<0.205) + obj: tkPhoton +L1_PFHTT: + cross_masks: [] + leg1: + leg_mask: + # - leg1.pt > 372.9 + - leg1.offline_pt > 450 + obj: seededConePuppiHT +L1_PFHTT_QuadJet: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt > 400.0 + obj: seededConePuppiHT + leg2: + leg_mask: + - leg2.offline_pt > 70.0 + - leg2.et>25.0 + - abs(leg2.eta)<2.4 + obj: seededConePuppiJet + leg3: + leg_mask: + - leg3.offline_pt > 55.0 + - leg3.et>25.0 + - abs(leg3.eta)<2.4 + obj: seededConePuppiJet + leg4: + leg_mask: + - leg4.offline_pt > 40.0 + - leg4.et>25.0 + - abs(leg4.eta)<2.4 + obj: seededConePuppiJet + leg5: + leg_mask: + - leg5.offline_pt > 40.0 + - leg5.et>25.0 + - abs(leg5.eta)<2.4 + obj: seededConePuppiJet +L1_PFIsoTau_PFIsoTau: + cross_masks: + # - ak.where(abs(leg2.phi-leg1.phi) 0.5 + - leg1.deltaR(leg2) > 0.5 + leg1: + leg_mask: + - leg1.offline_pt > 52.0 + - abs(leg1.eta)<2.172 + - leg1.passloosenn>0 + obj: nnTau + leg2: + leg_mask: + - leg2.offline_pt > 52.0 + - abs(leg2.eta)<2.172 + - leg2.passloosenn>0 + obj: nnTau +L1_PFMet: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt > 200.0 + obj: puppiMET diff --git a/rates/table/cfg/v29/v29_16seed_cfg.yml b/rates/table/cfg/v29/v29_16seed_cfg.yml new file mode 100644 index 00000000..2d70e325 --- /dev/null +++ b/rates/table/cfg/v29/v29_16seed_cfg.yml @@ -0,0 +1,12 @@ +MenuV29: + version: "V29" + sample: "/eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/13X/v29_RelVal/RelValTTbar_14TeV/RelVal_13X_TT_200PU_crab_v29_13X_RelVal_FixGenTree/230710_081407/L1NtuplePhaseII_Step1_hadd.root" + menu_config: "cfg/v29/v29_16Seeds_Final_clean_cfg.yml" + scalings: + scalings_path: "/eos/user/m/mbonanom/www/Postdoc/L1PhaseII/V29/scalings/" + collect_scalings: False + scalings_outdir: "scalings_input/V29/" + scalings_file: "scalings.yml" + table: + table_fname: "rates_16Seeds_Final" + table_outdir: "rates_tables/V29" \ No newline at end of file diff --git a/rates/table/cfg/v29/v29_WITHMUONS_Final_clean_cfg.yml b/rates/table/cfg/v29/v29_WITHMUONS_Final_clean_cfg.yml new file mode 100644 index 00000000..1ea8b405 --- /dev/null +++ b/rates/table/cfg/v29/v29_WITHMUONS_Final_clean_cfg.yml @@ -0,0 +1,686 @@ +L1_DoubleEGEle: + cross_masks: + - leg1.deltaR(leg2) > 0.1 + leg1: + leg_mask: + - leg1.offline_pt >= 37.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.5) + leg1.passessaid * (abs(leg1.eta) >= 1.5) + obj: EG + leg2: + leg_mask: + - leg2.offline_pt >= 24.0 + - abs(leg2.eta)<2.4 + - leg2.passeseleid * (abs(leg2.eta)<1.5) + leg2.passessaid * (abs(leg2.eta) >= 1.5) + obj: EG +L1_DoublePFJet_MassMin: + cross_masks: + - (leg1+leg2).mass>620 + leg1: + leg_mask: + - leg1.offline_pt >= 160.0 + obj: seededConePuppiJet + leg2: + leg_mask: + - leg2.offline_pt >= 35.0 + - leg2.et>25 + obj: seededConePuppiJet +L1_DoublePFJet_dEtaMax: + cross_masks: + - abs(leg2.eta-leg1.eta)<1.6 + leg1: + leg_mask: + - leg1.offline_pt >= 112.0 + - leg1.et>25 + - abs(leg1.eta)<2.4 + obj: seededConePuppiJet + leg2: + leg_mask: + - leg2.offline_pt >= 112.0 + - leg2.et>25 + - abs(leg2.eta)<2.4 + obj: seededConePuppiJet +L1_DoubleTkEle: + cross_masks: + - abs(leg2.zvtx-leg1.zvtx)<1 + leg1: + leg_mask: + - leg1.offline_pt >= 25.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.479) + (abs(leg1.eta)>1.479) + obj: tkElectron + leg2: + leg_mask: + - leg2.offline_pt >= 12.0 + - abs(leg2.eta)<2.4 + - leg2.passeseleid * (abs(leg2.eta)<1.479) + (abs(leg2.eta)>1.479) + obj: tkElectron +L1_DoubleTkEle_PFHTT: + cross_masks: + - (abs(leg2.zvtx-leg1.et)<1 & (leg2.deltaR(leg3)>0)) + - (abs(leg3.zvtx-leg1.et)<1 & (leg2.deltaR(leg3)>0)) + - (leg3.deltaR(leg2)>0) + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.offline_pt > 8.0 + - abs(leg2.eta)<2.5 + - leg2.passeseleid * (abs(leg2.eta)<1.479) + (abs(leg2.eta)>1.479) + obj: tkElectron + leg3: + leg_mask: + - leg3.offline_pt > 8.0 + - abs(leg3.eta)<2.5 + - leg3.passeseleid * (abs(leg3.eta)<1.479) + (abs(leg3.eta)>1.479) + obj: tkElectron + leg4: + leg_mask: + - leg4.offline_pt > 390.0 + obj: seededConePuppiHT +L1_DoubleTkMu: + cross_masks: + - ((abs(leg1.z0-leg2.z0)<1) & (leg1.deltaR(leg2)>0)) + leg1: + leg_mask: + - leg1.offline_pt > 15.0 + - abs(leg1.eta)<2.4 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>7 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon +L1_DoubleTkMu0er1p5_SQ_OS_dR_Max1p4: + cross_masks: + - ((leg1.deltaR(leg2)<1.4)) + - ((leg1.chg*leg2.chg<0.0)) + - ((abs(leg2.z0-leg1.z0)<1)) + - ((leg1.deltaR(leg2)>0)) + leg1: + leg_mask: + - abs(leg1.eta)<1.5 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - abs(leg2.eta)<1.5 + - leg2.qual>0 + obj: gmtTkMuon +L1_DoubleTkMu4_SQ_OS_dR_Max1p2: + cross_masks: + - ((leg1.deltaR(leg2)<1.2) & (leg1.deltaR(leg2)>0)) + - ((leg1.chg*leg2.chg<0.0) & (leg1.deltaR(leg2)>0)) + - ((abs(leg2.z0-leg1.z0)<1) & (leg1.deltaR(leg2)>0)) + leg1: + leg_mask: + - leg1.pt>4 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>4 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon +L1_DoubleTkMu4p5er2p0_SQ_OS_Mass7to18: + cross_masks: + - (((leg1+leg2).mass>7.0) & (leg1.deltaR(leg2)>0)) + - (((leg1+leg2).mass<18.0) & (leg1.deltaR(leg2)>0)) + - ((leg1.chg*leg2.chg<0.0) & (leg1.deltaR(leg2)>0)) + - ((abs(leg2.z0-leg1.z0)<1) & (leg1.deltaR(leg2)>0)) + leg1: + leg_mask: + - leg1.pt>4.5 + - abs(leg1.eta)<2.0 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>4.5 + - abs(leg2.eta)<2.0 + - leg2.qual>0 + obj: gmtTkMuon +L1_DoubleTkMu_PfHTT: + cross_masks: + - (abs(leg2.z0-leg1.et)<1 & (leg3.deltaR(leg2)>0)) + - (abs(leg3.z0-leg1.et)<1 & (leg3.deltaR(leg2)>0)) + - (leg3.deltaR(leg2)>0) + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.pt>3 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.pt>3 + - abs(leg3.eta)<2.4 + - leg3.qual>0 + obj: gmtTkMuon + leg4: + leg_mask: + - leg4.offline_pt >= 300.0 + obj: seededConePuppiHT +L1_DoubleTkMu_PfJet_PfMet: + cross_masks: + - abs(leg2.z0-leg1.et)<1 + - abs(leg3.z0-leg1.et)<1 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.pt>3 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.pt>3 + - abs(leg3.eta)<2.4 + - leg3.qual>0 + obj: gmtTkMuon + leg4: + leg_mask: + - leg4.offline_pt >= 60.0 + - leg4.et>25 + - abs(leg4.eta)<2.4 + obj: seededConePuppiJet + leg5: + leg_mask: + - leg5.offline_pt >= 130.0 + obj: puppiMET +L1_DoubleTkMu_TkEle: + cross_masks: + - abs(leg2.z0-leg1.z0)<1 + - abs(leg3.zvtx-leg1.z0)<1 + leg1: + leg_mask: + - leg1.pt>5 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>5 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.offline_pt >= 9.0 + - abs(leg3.eta)<2.4 + - leg3.passeseleid * (abs(leg3.eta)<1.479) + (abs(leg3.eta)>1.479) + obj: tkElectron +L1_DoubleTkPhoIso: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 22.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.5) + leg1.passesphoid * (abs(leg1.eta) >= 1.5) + - (leg1.trkiso<0.25) * (abs(leg1.eta)<1.479) + (leg1.trkiso<0.205) * (abs(leg1.eta)>=1.479) + obj: tkPhoton + leg2: + leg_mask: + - leg2.offline_pt >= 12.0 + - abs(leg2.eta)<2.4 + - leg2.passeseleid * (abs(leg2.eta)<1.5) + leg2.passesphoid * (abs(leg2.eta) >= 1.5) + - (leg2.trkiso<0.25) * (abs(leg2.eta)<1.479) + (leg2.trkiso<0.205) * (abs(leg2.eta)>=1.479) + obj: tkPhoton +L1_PFHTT: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 450.0 + obj: seededConePuppiHT +L1_PFHTT_QuadJet: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 400.0 + obj: seededConePuppiHT + leg2: + leg_mask: + - leg2.offline_pt >= 70.0 + - leg2.et>25.0 + - abs(leg2.eta)<2.4 + obj: seededConePuppiJet + leg3: + leg_mask: + - leg3.offline_pt >= 55.0 + - leg3.et>25.0 + - abs(leg3.eta)<2.4 + obj: seededConePuppiJet + leg4: + leg_mask: + - leg4.offline_pt >= 40.0 + - leg4.et>25.0 + - abs(leg4.eta)<2.4 + obj: seededConePuppiJet + leg5: + leg_mask: + - leg5.offline_pt >= 40.0 + - leg5.et>25.0 + - abs(leg5.eta)<2.4 + obj: seededConePuppiJet +L1_PFIsoTau_PFIsoTau: + cross_masks: + - leg1.deltaR(leg2)>0.5 + leg1: + leg_mask: + - leg1.offline_pt >= 52.0 + - abs(leg1.eta)<2.172 + - leg1.passloosenn>0 + obj: nnTau + leg2: + leg_mask: + - leg2.offline_pt >= 52.0 + - abs(leg2.eta)<2.172 + - leg2.passloosenn>0 + obj: nnTau +L1_PFIsoTau_PFMet: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 55.0 + - abs(leg1.eta)<2.172 + - leg1.passloosenn>0 + obj: nnTau + leg2: + leg_mask: + - leg2.offline_pt >= 190.0 + obj: puppiMET +L1_PFIsoTau_TkMu: + cross_masks: + - abs(leg3.z0-leg1.et)<1 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.offline_pt >= 42.0 + - abs(leg2.eta)<2.172 + - leg2.passloosenn>0 + obj: nnTau + leg3: + leg_mask: + - leg3.offline_pt >= 18.0 + - abs(leg3.eta)<2.1 + obj: gmtTkMuon +L1_PFMHTT: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 135.5 + obj: seededConePuppiMHT +L1_PFMet: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 200.0 + obj: puppiMET +L1_PFTau_PFTau: + cross_masks: + - leg1.deltaR(leg2)>0.5 + leg1: + leg_mask: + - leg1.offline_pt > 90.0 + - abs(leg1.eta)<2.172 + obj: caloTau + leg2: + leg_mask: + - leg2.offline_pt > 90.0 + - abs(leg2.eta)<2.172 + obj: caloTau +L1_SingleEGEle: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 51.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.5) + leg1.passessaid * (abs(leg1.eta) >= 1.5) + obj: EG +L1_SinglePFTau: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt > 150.0 + - abs(leg1.eta)<2.172 + obj: caloTau +L1_SinglePfJet: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 230.0 + - leg1.et>25 + - abs(leg1.eta)<2.4 + obj: seededConePuppiJet +L1_SingleTkEle: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 36.0 + - abs(leg1.eta)<2.4 + - tkelequalhigh(leg1.et,leg1.eta,leg1.passeseleid) + obj: tkElectron +L1_SingleTkEleIso: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt > 28.0 + - leg1.passeseleid >= 0 + - (leg1.trkiso<0.13) * (abs(leg1.eta)<1.479) + (leg1.trkiso<0.28) * (abs(leg1.eta)>=1.479) + obj: tkIsoElectron +L1_SingleTkMu: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 22.0 + - abs(leg1.eta)<2.4 + obj: gmtTkMuon +L1_SingleTkPhoIso: + cross_masks: [] + leg1: + leg_mask: + - leg1.offline_pt >= 36.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.5) + leg1.passesphoid * (abs(leg1.eta) >= 1.5) + - (leg1.trkiso<0.25) * (abs(leg1.eta)<1.479) + (leg1.trkiso<0.205) * (abs(leg1.eta)>=1.479) + obj: tkPhoton +L1_TkEleIso_EG: + cross_masks: + - leg1.deltaR(leg2) > 0.1 + leg1: + leg_mask: + - leg1.offline_pt >= 22.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid >= 0 + - (leg1.trkiso<0.13) * (abs(leg1.eta)<1.479) + (leg1.trkiso<0.28) * (abs(leg1.eta)>=1.479) + obj: tkIsoElectron + leg2: + leg_mask: + - leg2.offline_pt >= 12.0 + - abs(leg2.eta)<2.4 + - leg2.passeseleid * (abs(leg2.eta)<1.5) + leg2.passessaid * (abs(leg2.eta) >= 1.5) + obj: EG +L1_TkEleIso_PFHTT: + cross_masks: + - abs(leg2.zvtx-leg1.et)<1 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.offline_pt >= 26.0 + - abs(leg2.eta)<2.1 + - leg2.passeseleid >= 0 + - (leg2.trkiso<0.13) * (abs(leg2.eta)<1.479) + (leg2.trkiso<0.28) * (abs(leg2.eta)>=1.479) + obj: tkIsoElectron + leg3: + leg_mask: + - leg3.offline_pt >= 190.0 + obj: seededConePuppiHT +L1_TkEleIso_PFIsoTau: + cross_masks: + - abs(leg2.zvtx-leg1.et)<1 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.offline_pt >= 22.0 + - abs(leg2.eta)<2.1 + - leg2.passeseleid >= 0 + - (leg2.trkiso<0.13) * (abs(leg2.eta)<1.479) + (leg2.trkiso<0.28) * (abs(leg2.eta)>=1.479) + obj: tkIsoElectron + leg3: + leg_mask: + - leg3.offline_pt >= 45.0 + - abs(leg3.eta)<2.172 + - leg3.passloosenn>0 + obj: nnTau +L1_TkEle_PFJet_dRMin: + cross_masks: + - abs(leg2.zvtx-leg1.et)<1 + - leg2.deltaR(leg3)>0.3 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.offline_pt >= 28.0 + - abs(leg2.eta)<2.1 + - leg2.passeseleid * (abs(leg2.eta)<1.479) + (abs(leg2.eta)>1.479) + obj: tkElectron + leg3: + leg_mask: + - leg3.offline_pt >= 40.0 + - leg3.et>25 + - abs(leg3.eta)<2.4 + obj: seededConePuppiJet +L1_TkEle_TkMu: + cross_masks: + - abs(leg2.z0-leg1.zvtx)<1 + leg1: + leg_mask: + - leg1.offline_pt >= 10.0 + - abs(leg1.eta)<2.4 + - leg1.passeseleid * (abs(leg1.eta)<1.479) + (abs(leg1.eta)>1.479) + obj: tkElectron + leg2: + leg_mask: + - leg2.offline_pt >= 20.0 + - abs(leg2.eta)<2.4 + obj: gmtTkMuon +L1_TkMu_DoubleTkEle: + cross_masks: + - abs(leg2.zvtx-leg1.z0)<1 + - abs(leg3.zvtx-leg1.z0)<1 + leg1: + leg_mask: + - leg1.pt>6 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.offline_pt >= 17.0 + - abs(leg2.eta)<2.4 + - leg2.passeseleid * (abs(leg2.eta)<1.479) + (abs(leg2.eta)>1.479) + obj: tkElectron + leg3: + leg_mask: + - leg3.offline_pt >= 17.0 + - abs(leg3.eta)<2.4 + - leg3.passeseleid * (abs(leg3.eta)<1.479) + (abs(leg3.eta)>1.479) + obj: tkElectron +L1_TkMu_PfHTT: + cross_masks: + - abs(leg2.z0-leg1.et)<1 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.pt>6 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.offline_pt >= 320.0 + obj: seededConePuppiHT +L1_TkMu_PfJet_PfMet: + cross_masks: + - abs(leg2.z0-leg1.et)<1 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.pt>3 + - abs(leg2.eta)<2.1 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.offline_pt >= 110.0 + - leg3.et>25 + - abs(leg3.eta)<2.5 + obj: seededConePuppiJet + leg4: + leg_mask: + - leg4.offline_pt >= 120.0 + obj: puppiMET +L1_TkMu_PfJet_dRMax_DoubleJet_dEtaMax: + cross_masks: + - abs(leg2.z0-leg1.et)<1 + - leg2.deltaR(leg3)<0.4 + - abs(leg5.eta-leg4.eta)<1.6 + leg1: + leg_mask: + - leg1.et>-99999.0 + obj: z0L1TkPV + leg2: + leg_mask: + - leg2.offline_pt >= 12.0 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.offline_pt >= 40.0 + - leg3.et>25 + - abs(leg3.eta)<2.4 + obj: seededConePuppiJet + leg4: + leg_mask: + - leg4.offline_pt >= 40.0 + - leg4.et>25 + - abs(leg4.eta)<2.4 + obj: seededConePuppiJet + leg5: + leg_mask: + - leg5.offline_pt >= 40.0 + - leg5.et>25 + - abs(leg5.eta)<2.4 + obj: seededConePuppiJet +L1_TkMu_TkEle: + cross_masks: + - abs(leg2.zvtx-leg1.z0)<1 + leg1: + leg_mask: + #- leg1.offline_pt >= 7.0 + - leg1.pt>7 + - abs(leg1.eta)<2.4 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.offline_pt >= 23.0 + - abs(leg2.eta)<2.4 + - leg2.passeseleid * (abs(leg2.eta)<1.479) + (abs(leg2.eta)>1.479) + obj: tkElectron +L1_TkMu_TkEleIso: + cross_masks: + - abs(leg2.zvtx-leg1.z0)<1 + leg1: + leg_mask: + - leg1.pt>7 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.offline_pt >= 20.0 + - abs(leg2.eta)<2.4 + - leg2.passeseleid >= 0 + - (leg2.trkiso<0.13) * (abs(leg2.eta)<1.479) + (leg2.trkiso<0.28) * (abs(leg2.eta)>=1.479) + obj: tkIsoElectron +L1_TripleTkMu: + cross_masks: + - abs(leg2.z0-leg1.z0)<1 + - abs(leg3.z0-leg1.z0)<1 + leg1: + leg_mask: + - leg1.pt>5 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>3 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.pt>3 + - abs(leg3.eta)<2.4 + - leg3.qual>0 + obj: gmtTkMuon +L1_TripleTkMu_5SQ_3SQ_0OQ_DoubleMu_5_3_SQ_OS_Mass_Max9: + cross_masks: + - (leg1+leg2).mass<9.0 + - leg1.chg*leg2.chg<0.0 + - abs(leg2.z0-leg1.z0)<1 + - abs(leg3.z0-leg1.z0)<1 + leg1: + leg_mask: + - leg1.pt>5 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>3 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.pt>0 + - abs(leg3.eta)<2.4 + - leg3.qual>0 + obj: gmtTkMuon +L1_TripleTkMu_5_3p5_2p5_OS_Mass_5to17: + cross_masks: + - abs(leg2.z0-leg1.z0)<1 + - leg1.chg*leg3.chg<0.0 + - (leg1+leg3).mass>5.0 + - (leg1+leg3).mass<17.0 + - abs(leg3.z0-leg1.z0)<1 + leg1: + leg_mask: + - leg1.pt>5 + - abs(leg1.eta)<2.4 + - leg1.qual>0 + obj: gmtTkMuon + leg2: + leg_mask: + - leg2.pt>3.5 + - abs(leg2.eta)<2.4 + - leg2.qual>0 + obj: gmtTkMuon + leg3: + leg_mask: + - leg3.pt>2.5 + - abs(leg3.eta)<2.4 + - leg3.qual>0 + obj: gmtTkMuon diff --git a/rates/table/cfg/v29/v29_cfg.yml b/rates/table/cfg/v29/v29_cfg.yml new file mode 100644 index 00000000..ed20e206 --- /dev/null +++ b/rates/table/cfg/v29/v29_cfg.yml @@ -0,0 +1,13 @@ +MenuV29: + version: "V29" + sample: "/eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/CMSSW_12_5_2p1/v29/MinBias_1.root" + menu_config: "cfg/v29/v29_WITHMUONS_Final_clean_cfg.yml" + scalings: + scalings_path: "/eos/user/m/mbonanom/www/Postdoc/L1PhaseII/V29/scalings/" + collect_scalings: False + scalings_outdir: "scalings_input/V29/" + scalings_file: "scalings.yml" + table: + table_fname: "rates_full_Final" + table_outdir: "rates_tables/V29" + diff --git a/rates/table/menu_config.py b/rates/table/menu_config.py new file mode 100644 index 00000000..2a60c3dd --- /dev/null +++ b/rates/table/menu_config.py @@ -0,0 +1,44 @@ +class MenuConfig: + + def __init__(self, cfg: dict): + self._cfg = cfg + + @property + def sample(self): + return self._cfg["sample"] + + @property + def scalings_path(self): + return self._cfg["scalings"]["scalings_path"] + + @property + def do_scalings(self): + return self._cfg["scalings"]["collect_scalings"] + + @property + def scalings_file(self): + return self._cfg["scalings"]["scalings_file"] + + @property + def scalings_outdir(self): + return self._cfg["scalings"]["scalings_outdir"] + + @property + def menu_cfg(self): + return self._cfg["menu_config"] + + @property + def menu_objects(self): + return self._cfg["menu_objects"] + + @property + def version(self): + return self._cfg["version"] + + @property + def table_outdir(self): + return self._cfg["table"]["table_outdir"] + + @property + def table_fname(self): + return self._cfg["table"]["table_fname"] \ No newline at end of file diff --git a/rates/table/menu_table.py b/rates/table/menu_table.py new file mode 100644 index 00000000..da198b55 --- /dev/null +++ b/rates/table/menu_table.py @@ -0,0 +1,405 @@ +import numpy as np + +from glob import glob + +import yaml, re, os, math + +from utils import * +from menu_config import MenuConfig + +import uproot +import awkward as ak +import vector + +vector.register_awkward() + +class MenuTable: + ''' + Base class that defines the rates table. + This class contains method to read the minbias sample, + convert online to offline pT, and compute the trigger rates. + All the relevant information is dumped to a csv table. + ''' + def __init__(self, cfg): + self.cfg = MenuConfig(cfg) + self.version = self.cfg.version + self.fname = self.cfg.sample + self.table_outdir = self.cfg.table_outdir + self.table_fname = self.cfg.table_fname + self.cfg_fname = self.cfg.menu_cfg + self.scalings = self.get_scalings(os.path.join(self.cfg.scalings_outdir, + self.cfg.scalings_file)) + self.trig_seeds = self.get_trig_seeds() + + def load_minbias(self, obj): + ''' + Function to load the minbias sample to be used for the rates computation. + The name of the file is specified in the config used for the MenuTable init. + ''' + with uproot.open(self.fname) as f: + arr = f["l1PhaseIITree/L1PhaseIITree"].arrays( + filter_name = f"{obj}*", + how = "zip" + ) + return arr + + def get_scalings(self, scalings): + ''' + Get the list of scalings for all the L1 objects. + Scalings are collected by the Scaler() class and + saved to a yaml file. + The inputs used are the files created in `objectPerformance` + and saved in `objectPerformance/output/VX/scalings/*.txt` + ''' + with open(f'{scalings}', 'r') as infile: + scalings_eta = yaml.safe_load(infile.read()) + return scalings_eta + + def get_trig_seeds(self): + ''' + Get the menu definition. + Load a yaml file containing the definition of the objects + and the cuts of each leg for the different trigger paths. + ''' + with open(self.cfg_fname, 'r') as infile: + test_trig_seeds = yaml.safe_load(infile.read()) + + return test_trig_seeds + + def add_offline_pt(self, arr, obj_scalings, pt_var = None): + ''' + Use the scalings to convert online pT to offline pT. + The `pt_var` argument can be used to specify which observables + should be used as "pT" for a given object. + If `pt_var` is not specified, `pt` or `et` are used. + For each object, a dedicated scaling in the barrel/endcap regions + is applied to the online pT. + ''' + # initialise array of zeros identical to the original pt + if pt_var is not None: pt_orig = arr[pt_var] + elif "et" in arr.fields: pt_orig = arr.et + elif "pt" in arr.fields: pt_orig = arr.pt + elif "" in arr.fields: pt_orig = arr[""][:,0] + else: + print("Error! Unknown pt branch") + return 0 + + if None in obj_scalings: + values = obj_scalings[None] + new_pt = pt_orig * values["slope"] + values["offset"] * (pt_orig > 0) + else: + new_pt = ak.zeros_like(pt_orig) + + # loop through eta regions with it's scaling parameters + for region, values in obj_scalings.items(): + # create eta mask for this eta region + eta_mask = (abs(arr.eta) >= values["eta_min"]) & (abs(arr.eta) < values["eta_max"]) + # scale pt for non-masked elements of this eta region + new_pt = new_pt + eta_mask * (pt_orig * values["slope"] + values["offset"]) + + return ak.with_field(arr, new_pt, "offline_pt") + + def scale_pt(self, obj, arr): + ''' + Wrapper function that calls `add_offline_pt` if the scaling is defined. + If the scaling for a given object is not found, `offline_pt` is set to + be equal to the online pt. + ''' + + if obj in self.scalings: + # print(self.scalings[obj]) + arr = self.add_offline_pt(arr, self.scalings[obj]) + else: + print("No scalings found for " + obj) + if "" in arr.fields: + arr["et"] = arr[""] + arr["pt"] = arr[""] + arr["offline_pt"] = arr.pt + + if "eta" in arr.fields: + arr["mass"] = 0.0*ak.ones_like(arr["eta"]) + arr = ak.with_name(arr, "Momentum4D") + + arr["idx"] = ak.local_index(arr) + return arr + + def format_values(self, arr): + ''' + Function to format values in the array. + The `et` branch is converted to `pt`, if no `pt` is found in the array. + If neither `pt` nor `et` are found in the array, the corresponding + entries will be left empty or filled with the unique field of the array. + The ID branches (`["passeseleid","passessaid","passesphoid"]`) are + converted into boolean variables for easier usage in the triggers definition. + ''' + if "et" not in arr.fields: + if "pt" in arr.fields: + arr["et"] = arr.pt + elif "" in arr.fields: + arr["pt"] = arr[""] + arr["et"] = arr[""] + elif "pt" not in arr.fields: + if "et" in arr.fields: + arr["pt"] = arr.et + + for x in ["passeseleid","passessaid","passesphoid"]: + if x in arr.fields: + arr[x] = ak.values_astype(arr[x], bool) + + return arr + + def get_obj_arr(self, obj): + ''' + Function that loads the minbias sample and gets the relevant object from the TTree. + The TBranches are loaded in an awkward array, `format_values` is used to parse the + `pt`, `et`, and ID branches. + The `scale_pt` function is used to convert the online pT into offline using the scalings. + ''' + # TODO: Implement reading from parquet + # vers = self.version + # fname = f"/eos/cms/store/group/dpg_trigger/comm_trigger/L1Trigger/alobanov/phase2/menu/ntuples/cache/{vers}/{vers}_MinBias_{obj}.parquet" + # arr = ak.from_parquet(fname) + + load_obj = obj + + if obj == "tkIsoElectron": load_obj = "tkElectron" + + arr = self.load_minbias(load_obj) + if "jagged0" in arr.fields: + arr = arr["jagged0"] + + arr = ak.zip({f.replace(load_obj,"").lower():arr[f] for f in arr.fields}) + arr = self.format_values(arr) + + arr = self.scale_pt(obj, arr) + + return arr + + def get_legs(self, seed_legs): + ''' + Function that parses the config file (menu definition) + to get the cuts to be used for the definition of each trigger leg + and the L1 object used. + The function returns the awkard array after the application of the cuts. + ''' + all_arrs = {} + leg_arrs = {} + + for leg, items in seed_legs.items(): + obj = items["obj"] + + if obj not in all_arrs: all_arrs[obj] = self.get_obj_arr(obj) + + leg_mask_str = items["leg_mask"] + + leg_mask_str = "&".join([f"({s})" for s in leg_mask_str]).replace(leg,"leg_arr") + leg_arr = all_arrs[obj] + + # get masked array + leg_mask = eval(leg_mask_str) + + ## apply mask if regular (non-jagged) array, e.g. MET/HT etc + if "var" in str(leg_arr.type): + leg_arrs[leg] = leg_arr[leg_mask] + else: + leg_arrs[leg] = ak.mask(leg_arr, leg_mask) + + return leg_arrs + + def get_combos(self, leg_arrs, seed_legs): + ''' + For multi-leg triggers, this function creates the combination of the legs. + After the trigger legs are combined, the resulting array corresponding to the + AND of all the conditions on each leg is returned. + ''' + if len(leg_arrs) > 1: + combos = ak.cartesian(leg_arrs) + else: + combos = leg_arrs + + ## duplicate handling (exclude combinations) + ## first check whether objects are repeating + objs = [o["obj"] for o in seed_legs.values()] + obj_cnts = {i: objs.count(i) for i in objs} + + if np.max(list(obj_cnts.values())) > 1: + nodup_masks = [] + + for i,l1 in enumerate(leg_arrs.keys()): + for j,l2 in enumerate(leg_arrs.keys()): + if i>=j: continue + ## check that the legs are the same type object, skip otherwise + if seed_legs[l1]["obj"] != seed_legs[l2]["obj"]: continue + nodup_masks.append(combos[l1].idx != combos[l2].idx) + + if len(nodup_masks) > 0: + eval_str = " & ".join([f"nodup_masks[{i}]" for i in range(len(nodup_masks))]) + nodup_mask = eval(eval_str) + combos = combos[nodup_mask] + + return combos + + def get_legs_and_masks(self, seed_legs): + ''' + Wrapper function that calls `get_legs` and `get_combos`. + This function returns the awkward arrays with the legs definition + and the definition of the combinations in case of multi-leg triggers. + ''' + ### load all legs + leg_arrs = self.get_legs(seed_legs) + + ### leg duplicate removal + combos = self.get_combos(leg_arrs, seed_legs) + + return leg_arrs, combos + + def get_eval_string(self, leg_arrs): + ''' + Function that selects only relevant entries in the arrays and returns the + awkward array corresponding to events which satisfy the cuts on the trigger legs. + ''' + eval_str = [] + for leg, leg_arr in leg_arrs.items(): + if "var" in str(leg_arr.type): + eval_str.append(f"(ak.num({leg}) > 0)") + else: + eval_str.append(f"(ak.is_none({leg}) == False)") + eval_str = " & ".join(eval_str) + + return eval_str + + def seeds_from_cfg(self, seed): + ''' + Function that loads the information from the menu config. + Returns the legs, cross_masks, and cross-triggers (if present). + ''' + seed_legs = {l: self.trig_seeds[seed][l] for l in self.trig_seeds[seed] if "leg" in l} + cross_masks_str = self.trig_seeds[seed]["cross_masks"] + if len(cross_masks_str)>0: cross_masks_str = [cross_masks_str] + cross_seeds = [] + for leg, items in self.trig_seeds[seed].items(): + if leg == "x-seeds": + if isinstance(items, list): cross_seeds+=items + else: cross_seeds.append(items) + return seed_legs, cross_masks_str, cross_seeds + + def get_npass(self, seed, trig_seed): + ''' + Main function that computes the nr of events passing each trigger. + After loading the minbias sample and the menu definition, + each leg is selected and the masks are applied (together with cross-masks/seeds). + The function returns the total mask that defines the trigger. + ''' + seed_legs, cross_masks_str, cross_seeds = self.seeds_from_cfg(seed) + leg_arrs, combos = self.get_legs_and_masks(seed_legs) + + ## define leg arrays + for leg in leg_arrs: exec(f"{leg} = combos['{leg}']") + + ## require presence of legs + eval_str = self.get_eval_string(leg_arrs) + nleg_mask = eval(eval_str) + + ## create event mask + total_mask = nleg_mask + + ## add cross_conditions + if len(cross_masks_str) > 0: + cross_mask = [] + + for cross_mask_str in [item for sublist in cross_masks_str for item in sublist]: + cross_mask.append(eval(cross_mask_str)) + + ## combine cross_masks + eval_str = " & ".join([f"cross_mask[{i}]" for i in range(len(cross_mask))]) + cross_mask_all = eval(f"ak.any({eval_str}, axis = 1)") + + total_mask = total_mask & cross_mask_all + + ## Add cross-seeds: + for xseed in cross_seeds: + xseed_mask = self.get_npass(self.trig_seeds[xseed]) + total_mask = total_mask & xseed_mask + + total_mask = ak.fill_none(total_mask, False) + return total_mask + + def prepare_masks(self): + ''' + Wrapper function that calls `get_npass` + for each object defined in the menu. + The function returns the masks for each object. + ''' + trig_masks = {} + + seeds = self.trig_seeds + + for seed in sorted(seeds): + + print(seed) + + mask = self.get_npass(seed, self.trig_seeds[seed]) + npass = np.sum(mask) + print("##### Npasses:", npass,"\n") + + trig_masks[seed] = mask.to_numpy() + + return trig_masks + + def make_table(self): + ''' + Function that prints to screen the rates table. + Returns a list containing the csv-compatible table. + ''' + table = [] + table.append("Seed,NPass,Eff,Rate\n") + total_mask = 0 + trig_masks = self.prepare_masks() + self.trig_masks = trig_masks + + for seed, mask in trig_masks.items(): + + total_mask = total_mask | mask + npass = np.sum(mask) + eff = npass/len(mask) + rate = eff * 2760*11246 / 1e3 + table.append(f"{seed},{npass},{eff},{rate}\n") + print(seed.ljust(50), ":\t%8i\t%.5f\t%.1f" %(npass, eff, rate)) + + ## total + npass = np.sum(total_mask) + eff = npass/len(total_mask) + rate = eff * 2760*11246 / 1e3 + + tot_str = "Total:".ljust(50)+ "\t%8i\t%.5f\t%.1f" %(npass, eff, rate) + table.append(f"Total,{npass},{eff},{rate}\n") + table.append(f"Total nev,{len(total_mask)},,\n") + print((len(tot_str)+5)*"-") + print(tot_str) + + print("Total nev: %i" % len(total_mask)) + + return table + + def dump_masks(self): + ''' + Function that dumps to file the masks produced by `prepare_masks`. + ''' + if hasattr(self, "trig_masks"): + os.makedirs(f"{self.table_outdir}", exist_ok=True) + fname = f"{self.table_outdir}/{self.table_fname}_{self.version}_masks.parquet" + print(f"Dumping masks to parquet in: {fname}") + + ak.to_parquet(ak.zip(self.trig_masks), fname) + else: + print("No masks created! Run `prepare_masks` first.") + + def dump_table(self, table): + ''' + Function that dumps to file the table produced by `make_table`. + ''' + os.makedirs(f"{self.table_outdir}", exist_ok=True) + f = open(f"{self.table_outdir}/{self.table_fname}_{self.version}.csv", "w") + for line in table: + f.write(line) + f.close() diff --git a/rates/table/old_tool/README.md b/rates/table/old_tool/README.md new file mode 100644 index 00000000..bd5e82e4 --- /dev/null +++ b/rates/table/old_tool/README.md @@ -0,0 +1,18 @@ +# L1 Phase2 Menu Tools: Rate Table + +## Old fwk: Rate table for the Phase-2 L1 Trigger Menu +To run the rate table, for example for the L1 TDR results, do +``` +python run.py cfg/v10_TRIDAS_newThresholds_LHCCReview +``` + +For the firmware-based emulators under 123x, utilise `FBE_noMu_L1TDRMET_mhtSeed_123x` (`FBE_noMu_L1TDRMET_mhtSeed_123x_singleJetEta5` only includes forward region for the singleJet seed). + +To display the rates in an easy-to-read format, run +``` +python3 printRateTable.py -c cfg/v10_TRIDAS_newThresholds_LHCCReview -r out/2020-05-26-MENU-LHCCReview-BugFix_v10_TRIDAS_newThresholds_LHCCReview/thresholds/menu.csv +``` +You can also edit the `CFG_RATE_COMBOS` dictionary at the top of +the file and run the script without any arguments `python3 printRateTable.py`. +This way multiple rate tables can be compared quickly. + diff --git a/rates/table/cfg/v10/v10_TRIDAS_newThresholds_LHCCReview b/rates/table/old_tool/cfg/v10/v10_TRIDAS_newThresholds_LHCCReview similarity index 100% rename from rates/table/cfg/v10/v10_TRIDAS_newThresholds_LHCCReview rename to rates/table/old_tool/cfg/v10/v10_TRIDAS_newThresholds_LHCCReview diff --git a/rates/table/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x b/rates/table/old_tool/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x similarity index 100% rename from rates/table/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x rename to rates/table/old_tool/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x diff --git a/rates/table/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x_singleJetEta5 b/rates/table/old_tool/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x_singleJetEta5 similarity index 100% rename from rates/table/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x_singleJetEta5 rename to rates/table/old_tool/cfg/v22/FBE_noMu_L1TDRMET_mhtSeed_123x_singleJetEta5 diff --git a/rates/table/cfg/v27/v27_1252_noSoftMu b/rates/table/old_tool/cfg/v27/v27_1252_noSoftMu similarity index 100% rename from rates/table/cfg/v27/v27_1252_noSoftMu rename to rates/table/old_tool/cfg/v27/v27_1252_noSoftMu diff --git a/rates/table/cfg/v29/v29_16Seeds_Final b/rates/table/old_tool/cfg/v29/v29_16Seeds_Final similarity index 100% rename from rates/table/cfg/v29/v29_16Seeds_Final rename to rates/table/old_tool/cfg/v29/v29_16Seeds_Final diff --git a/rates/table/cfg/v29/v29_NOMUONS_Final b/rates/table/old_tool/cfg/v29/v29_NOMUONS_Final similarity index 100% rename from rates/table/cfg/v29/v29_NOMUONS_Final rename to rates/table/old_tool/cfg/v29/v29_NOMUONS_Final diff --git a/rates/table/cfg/v29/v29_WITHMUONS_Final b/rates/table/old_tool/cfg/v29/v29_WITHMUONS_Final similarity index 100% rename from rates/table/cfg/v29/v29_WITHMUONS_Final rename to rates/table/old_tool/cfg/v29/v29_WITHMUONS_Final diff --git a/rates/table/old_tool/lib/__init__.py b/rates/table/old_tool/lib/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/rates/table/lib/cfg.py b/rates/table/old_tool/lib/cfg.py similarity index 100% rename from rates/table/lib/cfg.py rename to rates/table/old_tool/lib/cfg.py diff --git a/rates/table/lib/functions.py b/rates/table/old_tool/lib/functions.py similarity index 100% rename from rates/table/lib/functions.py rename to rates/table/old_tool/lib/functions.py diff --git a/rates/table/lib/functionsTreeReader.py b/rates/table/old_tool/lib/functionsTreeReader.py similarity index 100% rename from rates/table/lib/functionsTreeReader.py rename to rates/table/old_tool/lib/functionsTreeReader.py diff --git a/rates/table/lib/master.py b/rates/table/old_tool/lib/master.py similarity index 100% rename from rates/table/lib/master.py rename to rates/table/old_tool/lib/master.py diff --git a/rates/table/lib/menu.py b/rates/table/old_tool/lib/menu.py similarity index 99% rename from rates/table/lib/menu.py rename to rates/table/old_tool/lib/menu.py index e68e70d9..5094e1ae 100644 --- a/rates/table/lib/menu.py +++ b/rates/table/old_tool/lib/menu.py @@ -69,8 +69,8 @@ def dump(self, outdir): print refs names = refs.keys()[:] names.sort() - fs = "%-"+str(maxlength)+"s: %9.2f" - fss = fs + " %1.5f %3.3f" + fs = "%-"+str(maxlength)+"s\t%9.2f" + fss = fs + " \t%1.5f \t%3.3f" print print "MENU RESULT:" for tname in names: diff --git a/rates/table/lib/object.py b/rates/table/old_tool/lib/object.py similarity index 100% rename from rates/table/lib/object.py rename to rates/table/old_tool/lib/object.py diff --git a/rates/table/lib/sample.py b/rates/table/old_tool/lib/sample.py similarity index 100% rename from rates/table/lib/sample.py rename to rates/table/old_tool/lib/sample.py diff --git a/rates/table/lib/samplemanager.py b/rates/table/old_tool/lib/samplemanager.py similarity index 100% rename from rates/table/lib/samplemanager.py rename to rates/table/old_tool/lib/samplemanager.py diff --git a/rates/table/lib/trigger.py b/rates/table/old_tool/lib/trigger.py similarity index 100% rename from rates/table/lib/trigger.py rename to rates/table/old_tool/lib/trigger.py diff --git a/rates/table/lib/vb.py b/rates/table/old_tool/lib/vb.py similarity index 100% rename from rates/table/lib/vb.py rename to rates/table/old_tool/lib/vb.py diff --git a/rates/table/printRateTable.py b/rates/table/old_tool/printRateTable.py similarity index 100% rename from rates/table/printRateTable.py rename to rates/table/old_tool/printRateTable.py diff --git a/rates/table/run.py b/rates/table/old_tool/run.py similarity index 100% rename from rates/table/run.py rename to rates/table/old_tool/run.py diff --git a/rates/table/rate_table.py b/rates/table/rate_table.py new file mode 100755 index 00000000..0d6801d8 --- /dev/null +++ b/rates/table/rate_table.py @@ -0,0 +1,30 @@ +import argparse +import yaml + +from scaler import Scaler +from menu_table import MenuTable +from menu_config import MenuConfig + +if __name__ == "__main__": + + parser = argparse.ArgumentParser() + parser.add_argument( + "cfg", + default="cfg/v29/v29_cfg.yml", + help="" + ) + args = parser.parse_args() + + with open(args.cfg, 'r') as f: + cfg = yaml.safe_load(f) + + for menu_title, menu_cfg in cfg.items(): + scaler = Scaler(menu_cfg) + scaler.collect_scalings + scaler.dump_scalings + + menu_config = MenuTable(menu_cfg) + table = menu_config.make_table() + menu_config.dump_table(table) + + menu_config.dump_masks() diff --git a/rates/table/scaler.py b/rates/table/scaler.py new file mode 100644 index 00000000..cf7aa4fb --- /dev/null +++ b/rates/table/scaler.py @@ -0,0 +1,150 @@ +import os, yaml +from glob import glob +from menu_config import MenuConfig + +class Scaler: + ''' + Base class that takes as input the scalings computed + in `objectPerformance` and aggregates all of them together + to be used for the rates computation. + ''' + def __init__(self, cfg): + self.cfg = MenuConfig(cfg) + self.scalings_path = self.cfg.scalings_path + self.scalings_file = self.cfg.scalings_file + self.scalings_outdir = self.cfg.scalings_outdir + self.do_scalings = self.cfg.do_scalings + self.fnames = glob(f"{self.scalings_path}/*.txt") + self.scaling_dict = {} + self.init_log + + @property + def init_log(self): + print(f"::: The scalings file used is: {self.scalings_outdir}/{self.scalings_file} :::") + if (not os.path.isfile(f"{self.scalings_outdir}/{self.scalings_file}")) and (not self.do_scalings): + print(f"::: WARNING!! You are trying to use {self.scalings_outdir}/{self.scalings_file}, but the file does not exist! :::") + print("::: WARNING!! Set do_scalings to True in config or specify a different location for the scalings file! :::") + if self.do_scalings: + print(f"::: Will collect scalings from scratch and recreate {self.scalings_file} :::") + print(f"::: Will load scalings from {self.scalings_path} :::") + print(f"::: Will dump scalings into {self.scalings_outdir} :::") + + def get_lines(self, fname): + with open(fname) as f: + lines = f.readlines() + + return lines + + def get_basename(self, fname): + # TODO: Harmonize the naming of the scaligns in `objectPerformance` + # so that we can drop this function. + basename = os.path.basename(fname).replace(".txt","") + basename = basename.replace( + "Turnon","").replace( + "Trigger","").replace( + "_","") + + return basename + + def eta_ranges(self, obj, suffix): + ''' + Wrapper function that defines the Barrel/Overlap/Endcap + range definitions for different objects. + ''' + eta_range = None + if obj == "Muons": + if suffix == "Barrel": + eta_range = (0,0.83) + elif suffix == "Overlap": + eta_range = (0.83,1.24) + elif suffix == "Endcap": + eta_range = (1.24,2.5) + else: + if suffix == "Barrel": + eta_range = (0,1.5) + elif suffix == "Endcap": + eta_range = (1.5,2.5) + elif suffix == "Forward": + eta_range = (2.5,5) + + return eta_range + + def get_eta_range(self, fname): + ''' + Wrapper function that calls `eta_ranges` + and returns the object and the relevant eta ranges + for the various detector regions. + ''' + basename = self.get_basename(fname) + + for suffix in ["Barrel","Endcap","Overlap"]: + if suffix in basename: + obj = basename.split(suffix)[0] + eta_range = self.eta_ranges(obj, suffix) + + if eta_range is None: + print("Not found! ", basename, obj) + else: + return obj, suffix, eta_range + + return None + + def decode_scaling(self, line): + ''' + Function that parses the syntax used in the scaling.txt files + and returns the slope and offset of the scaling law for each object. + ''' + line = line.replace(" ","") + items = line.split("::") + + obj = items[1][:-len("Scaling")] + slope = float(items[2][len("args:=(offline);lambda:="):items[2].find("*off")-10]) + offset = float(items[2][items[2].find("*off")+len("*offline"):-10]) + + return obj,slope,offset + + @property + def collect_scalings(self): + ''' + Property that collects the scalings for all the objects available + and saves them to `self.scaling_dict`. + This function works only if `do_scalings` is set to True in the config. + ''' + if not self.do_scalings: return + for fname in self.fnames: + r = self.get_eta_range(os.path.basename(fname)) + + if r is None: + objcat = None + region = None + eta_range = (None,None) + else: + objcat,region,eta_range = r + + lines = self.get_lines(fname) + + for line in lines: + obj,slope,offset = self.decode_scaling(line) + d = { region : { + "eta_min" : eta_range[0], + "eta_max" : eta_range[1], + "offset" : offset, + "slope" : slope + } + } + + if obj in self.scaling_dict: self.scaling_dict[obj].update(d) + else: self.scaling_dict[obj] = d + + @property + def dump_scalings(self): + ''' + Property that dumps to file the content of `self.scaling_dict`. + This function works only if `do_scalings` is set to True in the config. + ''' + if not self.do_scalings: return + os.makedirs(f"{self.scalings_outdir}", exist_ok=True) + with open(f'{self.scalings_outdir}/{self.scalings_file}', 'w') as outfile: + yaml.dump(self.scaling_dict, + outfile, + default_flow_style=False) diff --git a/rates/table/scalings_input/V29/scalings.yml b/rates/table/scalings_input/V29/scalings.yml new file mode 100644 index 00000000..ba55c642 --- /dev/null +++ b/rates/table/scalings_input/V29/scalings.yml @@ -0,0 +1,198 @@ +EG: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 2.707 + slope: 1.188 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 1.572 + slope: 1.249 +caloTau: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: -2.553 + slope: 1.525 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: -1.273 + slope: 1.968 +gmtMuon: + Barrel: + eta_max: 0.83 + eta_min: 0 + offset: -0.2379695 + slope: 1.13674 + Endcap: + eta_max: 2.5 + eta_min: 1.24 + offset: 11.219282 + slope: 1.5027 + Overlap: + eta_max: 1.24 + eta_min: 0.83 + offset: -2.5687838 + slope: 1.34598 +gmtTkMuon: + Barrel: + eta_max: 0.83 + eta_min: 0 + offset: 0.986 + slope: 1.049 + Endcap: + eta_max: 2.5 + eta_min: 1.24 + offset: 0.792 #1.075 + slope: 1.054 # 1.052 + Overlap: + eta_max: 1.24 + eta_min: 0.83 + offset: 1.075 # 0.792 + slope: 1.052 # 1.054 +nnTau: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: -2.065 + slope: 1.899 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 19.596 + slope: 1.584 +phase1PuppiHT: + null: + eta_max: null + eta_min: null + offset: 54.550 + slope: 1.087 +phase1PuppiJet: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 15.497 + slope: 1.383 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 9.362 + slope: 1.959 + null: + eta_max: null + eta_min: null + offset: 75.5 + slope: 1.41 +phase1PuppiMHT: + null: + eta_max: null + eta_min: null + offset: 49.175 + slope: 1.321 +puppiMET: + null: + eta_max: null + eta_min: null + offset: 63.781 + slope: 1.465 +seededConePuppiHT: + null: + eta_max: null + eta_min: null + offset: 47.986 + slope: 1.084 +seededConePuppiJet: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 20.10841 + slope: 1.30781 + Endcap: + eta_max: 2.4 + eta_min: 1.5 + offset: 7.971 + slope: 2.05 + Forward: + eta_max: 6 + eta_min: 2.4 + offset: 72.567 + slope: 1.418 +seededConePuppiMHT: + null: + offset: -20.499 + slope: 1.170 +tkElectron: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 1.441 + slope: 1.159 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 1.256 + slope: 1.217 +tkIsoElectron: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 1.638 + slope: 1.144 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 1.219 + slope: 1.214 +tkIsoPhoton: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 2.697 + slope: 1.096 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 5.038 + slope: 1.067 +tkPhoton: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 2.697 + slope: 1.096 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 5.038 + slope: 1.067 +trackerHT: + null: + eta_max: null + eta_min: null + offset: -25.35696 + slope: 3.622799 +trackerJet: + Barrel: + eta_max: 1.5 + eta_min: 0 + offset: 446.22001 + slope: 0.341314 + Endcap: + eta_max: 2.5 + eta_min: 1.5 + offset: 477.198 + slope: 0.04346206 +trackerMET: + null: + eta_max: null + eta_min: null + offset: 417.67308 + slope: 0.2483366 +trackerMHT: + null: + eta_max: null + eta_min: null + offset: 410.9299 + slope: 0.295772 diff --git a/rates/table/utils.py b/rates/table/utils.py new file mode 100644 index 00000000..6bf8511d --- /dev/null +++ b/rates/table/utils.py @@ -0,0 +1,33 @@ +import numpy as np + +def dr(leg1,leg2): + return leg1.deltaR(leg2) + +def deltar(eta1,eta2,phi1,phi2): + return np.sqrt(np.power(abs(eta1-eta2),2) + np.power(abs(phi1-phi2) if abs(phi1-phi2)<=np.pi else 2*np.pi-abs(phi1-phi2),2)) + #return np.sqrt(np.power(abs(eta1-eta2),2) + np.power(abs(phi1-phi2) * abs(phi1-phi2)<=np.pi else 2*np.pi-abs(phi1-phi2),2)) + +def notmatched(eta1,eta2,phi1,phi2): + return deltar(eta1,eta2,phi1,phi2) > 0.1 + +def pairinvmass(pt1,pt2,eta1,eta2,phi1,phi2): + return np.sqrt(2.0*pt1*pt2*(np.cosh(eta1-eta2)-np.cos(phi1-phi2))) + +def phoid(EleID, PhoID, Eta): + return (EleID * (abs(Eta)<1.5)) + (PhoID * (abs(Eta)>=1.5)) + +def egid(EleID, SaID, Eta): + return (EleID * (abs(Eta)<1.5)) + (SaID * (abs(Eta)>=1.5)) + +def TkEleQualHIGH(Et,Eta,PassesEleID): return PassesEleID +def TkEleQualLOW(Et,Eta,PassesEleID): return PassesEleID * (abs(Eta)<1.479) + (abs(Eta)>1.479) +def TkEleIsoQualHIGH(Et,Eta,PassesEleID): return PassesEleID * (abs(Eta)>1.479) + (abs(Eta)<1.479) +def TkEleIsoQualLOW(Et,Eta,PassesEleID): return (PassesEleID>=0) # this should be always true: we can remove this condition from the menu + +def tkelequalhigh(et,eta,passeseleid): return passeseleid +def tkelequallow(et,eta,passeseleid): return passeseleid * (abs(eta)<1.479) + (abs(eta)>1.479) +def tkeleisoqualhigh(et,eta,passeseleid): return passeseleid * (abs(eta)>1.479) + (abs(eta)<1.479) +def tkeleisoquallow(et,eta,passeseleid): return (passeseleid>=0) # this should be always true: we can remove this condition from the menu + +def rangecutless(x,eta,etaRange,cutInRange,cutOutRange): + return (x=etaRange) diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index 5690dcf2..00000000 --- a/requirements.txt +++ /dev/null @@ -1,46 +0,0 @@ -awkward==2.1.0 -awkward-cpp==12 -black==23.12.1 -certifi==2023.11.17 -charset-normalizer==3.3.2 -click==8.1.7 -contourpy==1.2.0 -cycler==0.12.1 -docopt==0.6.2 -fonttools==4.47.0 -fsspec==2023.12.2 -idna==3.6 -importlib-metadata==7.0.1 -iniconfig==2.0.0 -kiwisolver==1.4.5 -matplotlib==3.8.2 -mplhep==0.3.31 -mplhep-data==0.0.3 -mypy==1.8.0 -mypy-extensions==1.0.0 -numpy==1.23.5 -packaging==23.2 -pandas==2.1.4 -pathspec==0.12.1 -Pillow==10.1.0 -pipreqs==0.4.13 -platformdirs==4.1.0 -pluggy==1.3.0 -progress==1.6 -pyarrow==14.0.2 -pyparsing==3.1.1 -pytest==7.4.3 -python-dateutil==2.8.2 -pytz==2023.3.post1 -PyYAML==6.0.1 -requests==2.31.0 -scipy==1.10.1 -six==1.16.0 -typing_extensions==4.9.0 -tzdata==2023.4 -uhi==0.4.0 -uproot==5.0.4 -urllib3==2.1.0 -vector==1.1.1.post1 -yarg==0.1.9 -zipp==3.17.0