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

Only 5 leading good jets information saved in ntuples #12

Closed
ram1123 opened this issue Jan 22, 2021 · 1 comment
Closed

Only 5 leading good jets information saved in ntuples #12

ram1123 opened this issue Jan 22, 2021 · 1 comment

Comments

@ram1123
Copy link

ram1123 commented Jan 22, 2021

The p4 variables are saved for only first 5 leading jets.

for v in p4_variables:
for i in range(checkN):
vtitle = "%s_%s_%s"%(objV,i,v)
vname = "? %s.size() >= %s ? %s[%s].p4().%s() : -99"%(objV,i+1,objV,i,v)
entry = "%s:=%s"%(vtitle,vname)
finalStateVars.append(entry)

Before this loop the variable checkN is set to 5. While for the b-discriminator variable it is set to 10.

if("Jets" in objV):
NtoCheck = 10 ##-- To almost always cover all Fully Hadronic signal information
# goodJetsToCheck = 10
# if(objV == "goodJets"): NtoCheck = 10 # want to save more good jet information for checking btags per event
bscores = ["bDiscriminator('mini_pfDeepFlavourJetTags:probb')","bDiscriminator('pfDeepCSVJetTags:probb')",
"bDiscriminator('mini_pfDeepFlavourJetTags:probbb')","bDiscriminator('pfDeepCSVJetTags:probbb')",
"bDiscriminator('mini_pfDeepFlavourJetTags:problepb')"
# "bDiscriminator('mini_pfDeepFlavourJetTags:probb') + bDiscriminator('mini_pfDeepFlavourJetTags:probbb') + bDiscriminator('mini_pfDeepFlavourJetTags:problepb')"
]
btitles = ["bDiscriminator_mini_pfDeepFlavourJetTags_probb","bDiscriminator_pfDeepCSVJetTags_probb",
"bDiscriminator_mini_pfDeepFlavourJetTags_probbb","bDiscriminator_pfDeepCSVJetTags_probbb",
"bDiscriminator_mini_pfDeepFlavourJetTags_problepb"
# "DeepFlavourScore"
]
##-- PUJetID Booleans
if(objV == "goodJets"):
for i in range(NtoCheck): ## -- only saved PUJetID for highest 4 pT jets (in FH) "? %s.size() >= %s ? %s[%s].%s() : -99"
for iID,PUID in enumerate(["Loose","Medium","Tight"]):
vtitle = "%s_%s_%s"%(objV,i,"Pass%sJetPUID"%(PUID))
vname = "? goodJets_passJetPUID.size() >= %s ? goodJets_passJetPUID.at(%s).at(%s) : -99"%(i+1,i,iID)
entry = "%s:=%s"%(vtitle,vname)
finalStateVars.append(entry)
for ib,bscore in enumerate(bscores):
btitle = btitles[ib]
for i in range(NtoCheck):
vtitle = "%s_%s_%s"%(objV,i,btitle)
vname = "? %s.size() >= %s ? %s[%s].%s : -99"%(objV,i+1,objV,i,bscore)
entry = "%s:=%s"%(vtitle,vname)
finalStateVars.append(entry)

We should make the two numbers consistent.

@atishelmanch
Copy link
Owner

Let's close this issue after the PR [1] is merged

[1] #16

@ram1123 ram1123 closed this as completed Jul 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants