Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data filters #19

Merged
merged 3 commits into from
Oct 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions CommonSelectors.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
import awkward as ak
from pocket_coffea.lib.cut_definition import Cut

def CvsLsorted(jets, ctag):
# This returns Jets sorted by CvL score (or other tagger defined in params/ctagging.yaml )
return jets[ak.argsort(jets[ctag["tagger"]], axis=1, ascending=False)]


def diLepton(events, params, year, sample, **kwargs):

# Masks for same-flavor (SF) and opposite-sign (OS)
Expand Down
4 changes: 3 additions & 1 deletion cfg_VHcc_WLNu.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from pocket_coffea.utils.configurator import Configurator
from pocket_coffea.lib.cut_definition import Cut
from pocket_coffea.lib.cut_functions import get_nObj_min, get_HLTsel
from pocket_coffea.lib.cut_functions import get_nPVgood, goldenJson, eventFlags
from pocket_coffea.parameters.cuts import passthrough
from pocket_coffea.parameters.histograms import *
import workflow_VHcc
Expand Down Expand Up @@ -118,7 +119,8 @@
workflow = VHccBaseProcessor,

skim = [get_HLTsel(primaryDatasets=["SingleMuon","SingleEle"]),
get_nObj_min(3, 20., "Jet")], # in default jet collection there are leptons. So we ask for 1lep+2jets=3Jet objects
get_nObj_min(3, 20., "Jet"),
get_nPVgood(1), eventFlags, goldenJson], # in default jet collection there are leptons. So we ask for 1lep+2jets=3Jet objects

#preselections = [onelep_plus_met],
preselections = [lep_met_2jets],
Expand Down
4 changes: 3 additions & 1 deletion cfg_VHcc_ZLL.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from pocket_coffea.utils.configurator import Configurator
from pocket_coffea.lib.cut_definition import Cut
from pocket_coffea.lib.cut_functions import get_nObj_min, get_HLTsel
from pocket_coffea.lib.cut_functions import get_nPVgood, goldenJson, eventFlags
from pocket_coffea.parameters.cuts import passthrough
from pocket_coffea.parameters.histograms import *
from pocket_coffea.lib.weights.common.common import common_weights
Expand Down Expand Up @@ -110,7 +111,8 @@

#skim = [get_HLTsel(primaryDatasets=["SingleMuon","SingleEle"]),
skim = [get_HLTsel(primaryDatasets=["DoubleMuon","DoubleEle"]),
get_nObj_min(4, 18., "Jet")],
get_nObj_min(4, 18., "Jet"),
get_nPVgood(1), eventFlags, goldenJson],

preselections = [ll_2j],
categories = {
Expand Down
4 changes: 3 additions & 1 deletion cfg_VHcc_ZNuNu.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from pocket_coffea.utils.configurator import Configurator
from pocket_coffea.lib.cut_definition import Cut
from pocket_coffea.lib.cut_functions import get_nObj_min, get_HLTsel
from pocket_coffea.lib.cut_functions import get_nPVgood, goldenJson, eventFlags
from pocket_coffea.parameters.cuts import passthrough
from pocket_coffea.parameters.histograms import *
import workflow_VHcc
Expand Down Expand Up @@ -115,7 +116,8 @@
workflow = VHccBaseProcessor,

skim = [get_HLTsel(primaryDatasets=["MET"]),
get_nObj_min(2, 32., "Jet")],
get_nObj_min(2, 32., "Jet"),
get_nPVgood(1), eventFlags, goldenJson],

preselections = [met_2jets_0lep],

Expand Down