Commit 2abe4549 authored by Alessandro Bertolin's avatar Alessandro Bertolin
Browse files

PID vs topological cuts for StrippingB2OC

parent 32bd17e6
......@@ -62,7 +62,7 @@ def makeSel(parent,dec):
class DBuilder(object):
'''Produces all D mesons for the Beauty2Charm module.'''
def __init__(self,pions,kaons,ks,pi0,uppions,upkaons,muons,hh,config,config_pid,config_pi0):
def __init__(self,pions,kaons,ks,pi0,uppions,upkaons,muons,hh,config,config_for_ddx,config_pid,config_pi0):
self.pions = pions
self.kaons = kaons
......@@ -73,6 +73,7 @@ class DBuilder(object):
self.muons = muons
self.hhBuilder = hh
self.config = config
self.config_for_ddx = config_for_ddx
self.config_pid = config_pid
self.config_pi0 = config_pi0
self.hh = self._makeD2hh()
......@@ -221,6 +222,12 @@ class DBuilder(object):
self.pi0hh_resolved)]
d_min,d_max,ds_min,ds_max = self._massWindowD2HHHCF()
#tighter D selections for DDX
self.hh_ddx_pid = [filterSelection('D2hh_for_DDX',LoKiCuts(['VCHI2DOF','BPVVDCHI2'],config_for_ddx).code(),self.hh_pid)]
self.hhh_ddx_pid = [filterSelection('D2hhh_for_DDX',LoKiCuts(['VCHI2DOF','BPVVDCHI2'],config_for_ddx).code(),self.hhh_pid)]
self.hhhh_ddx_pid = [filterSelection('D2hhhh_for_DDX',LoKiCuts(['VCHI2DOF','BPVVDCHI2'],config_for_ddx).code(),self.hhhh_pid)]
self.k3pi_ddx_pid = [filterSelection('D2k3pi_for_DDX',LoKiCuts(['VCHI2DOF','BPVVDCHI2'],config_for_ddx).code(),self.k3pi_pid)]
#use this below
d_cf_noMassWin = d_cf
d_cf = LoKiCuts.combine([d_cf,"in_range(%s,MM,%s)"%(d_min,d_max)])
......
......@@ -49,6 +49,14 @@ default_config ={
'MIPCHI2DV_MIN' : 4.,
'TRGHP_MAX' : 0.4
},
"PIDKAON" : {
'TRCHI2DOF_MAX' : 3.,
'PT_MIN' : '100*MeV',
'P_MIN' : '1000*MeV',
'MIPCHI2DV_MIN' : 4.,
'PIDK_MIN' : 0.,
'TRGHP_MAX' : 0.4
},
"UPSTREAM" : { # Cuts made on all upstream particles
'TRCHI2DOF_MAX' : 4.,
'PT_MIN' : '100*MeV',
......@@ -98,6 +106,23 @@ default_config ={
'BPVDIRA_MIN' : 0,
'MASS_WINDOW' : '100*MeV'
},
"D2X_FOR_DDX" : { # Cuts made on all D's and Lc's used in B->DDX lines
'ASUMPT_MIN' : '1800*MeV',
'ADOCA12_MAX' : '0.5*mm',
'ADOCA13_MAX' : '0.5*mm',
'ADOCA23_MAX' : '0.5*mm',
'ADOCA14_MAX' : '0.5*mm',
'ADOCA24_MAX' : '0.5*mm',
'ADOCA34_MAX' : '0.5*mm',
'ADOCA15_MAX' : '0.5*mm',
'ADOCA25_MAX' : '0.5*mm',
'ADOCA35_MAX' : '0.5*mm',
'ADOCA45_MAX' : '0.5*mm',
'VCHI2DOF_MAX' : 8,
'BPVVDCHI2_MIN' : 50,
'BPVDIRA_MIN' : 0,
'MASS_WINDOW' : '100*MeV'
},
"B2X" : { # Cuts made on all B's and Lb's used in all lines
'SUMPT_MIN' : '5000*MeV',
'VCHI2DOF_MAX' : 10,
......@@ -1421,7 +1446,8 @@ default_config ={
class Beauty2CharmConf(LineBuilder):
__configuration_keys__ = ('ALL','UPSTREAM','KS0','Lambda0','Pi0','gamma','D2X','B2X','Bc2DD','Bc2BX',
__configuration_keys__ = ('ALL','PIDKAON','UPSTREAM','KS0','Lambda0','Pi0','gamma',
'D2X','D2X_FOR_DDX','B2X','Bc2DD','Bc2BX',
'Dstar','HH','HHH','PID','FlavourTagging','RelatedInfoTools',
'RawEvents','MDSTChannels','2TOPO','BB','D0INC','Prescales','GECNTrkMax')
......@@ -1430,11 +1456,14 @@ class Beauty2CharmConf(LineBuilder):
LineBuilder.__init__(self, moduleName, config)
# pre-filter inputs
pions = filterInputs('Pi', [StdAllNoPIDsPions],config['ALL'])
uppions = filterInputs('PiUP',[StdNoPIDsUpPions], config['UPSTREAM'])
kaons = filterInputs('K', [StdAllNoPIDsKaons],config['ALL'])
upkaons = filterInputs('KaUP',[StdNoPIDsUpKaons], config['UPSTREAM'])
protons = filterInputs('P', [StdAllNoPIDsProtons],config['ALL'])
pions = filterInputs('Pi',[StdAllNoPIDsPions],config['ALL'])
# pions_pid = filterInputs('Pi_PID', [pions],config['PID'])
pions_pid = filterInputs('Pi_PID',[StdAllNoPIDsPions],config['ALL'])
uppions = filterInputs('PiUP',[StdNoPIDsUpPions],config['UPSTREAM'])
kaons = filterInputs('K',[StdAllNoPIDsKaons],config['ALL'])
kaons_pid = filterInputs('K_PID',[StdAllNoPIDsKaons],config['PIDKAON'])
upkaons = filterInputs('KaUP',[StdNoPIDsUpKaons],config['UPSTREAM'])
protons = filterInputs('P',[StdAllNoPIDsProtons],config['ALL'])
ks_dd = filterInputs('KS0_DD',[dataOnDemand("StdLooseKsDD")],
config['KS0'])
ks_ll = filterInputs('KS0_LL',[dataOnDemand("StdLooseKsLL")],
......@@ -1471,8 +1500,10 @@ class Beauty2CharmConf(LineBuilder):
# pre-filter hard inputs (these could have been used in HLT2)
topoPions = topoInputs('Pi',[pions])
topoPions_PID = topoInputs('Pi_PID',[pions_pid])
topoPionsLoose = topoInputsLoose('PiLoose',[pions])
topoKaons = topoInputs('K',[kaons])
topoKaons_PID = topoInputs('K_PID',[kaons_pid])
topoKaonsLoose = topoInputsLoose('KLoose',[kaons])
topoProtons = topoInputs('P',[protons])
......@@ -1484,7 +1515,7 @@ class Beauty2CharmConf(LineBuilder):
hhh = HHHBuilder(pions,kaons,protons,config['HHH'], config['PID'])
# make D->X, etc. inputs
d = DBuilder(pions,kaons,ks,pi0,uppions,upkaons,muons,hh,config['D2X'],config['PID'],config['Pi0'])
d = DBuilder(pions,kaons,ks,pi0,uppions,upkaons,muons,hh,config['D2X'],config['D2X_FOR_DDX'],config['PID'],config['Pi0'])
dst = DstarBuilder(d,pions,uppions,pi0,photons,vlaphotons,config['Dstar'],config['PID'])
# Lc -> X
......@@ -1492,7 +1523,7 @@ class Beauty2CharmConf(LineBuilder):
xicc = XiccBuilder(lc,pions,config['D2X'])
# make B->DX
b2dx = B2DXBuilder(d,dst,topoPions,topoPionsLoose,topoKaons,muons,ks,pi0_fromB,hh,hhh,
b2dx = B2DXBuilder(d,dst,topoPions,topoPionsLoose,topoKaons,topoKaons_PID,topoPions_PID,muons,ks,pi0_fromB,hh,hhh,
config['B2X'])
self._makeLines(b2dx.lines,config)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment