From 438247c52f9229267fa92d336584dd9089a0fbd7 Mon Sep 17 00:00:00 2001 From: lzhu <linxuan.zhu@cern.ch> Date: Mon, 10 Jul 2023 12:04:03 +0200 Subject: [PATCH] Add multiple lines by Linxuan --- .../StrippingB2OC/Beauty2Charm_B2DXBuilder.py | 134 +++++++++ .../Beauty2Charm_Bc2DXBuilder.py | 41 ++- .../StrippingB2OC/Beauty2Charm_DBuilder.py | 259 +++++++++++++++++ .../StrippingB2OC/Beauty2Charm_Lb2XBuilder.py | 263 +++++++++++++++++- .../StrippingB2OC/Beauty2Charm_Utils.py | 9 + .../StrippingB2OC/StrippingBeauty2Charm.py | 77 ++++- 6 files changed, 773 insertions(+), 10 deletions(-) diff --git a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_B2DXBuilder.py b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_B2DXBuilder.py index 095429650..e09eee02a 100644 --- a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_B2DXBuilder.py +++ b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_B2DXBuilder.py @@ -25,11 +25,13 @@ class B2DXBuilder(object): '''Makes all B->DX decays for the Beauty2Charm module.''' def __init__(self, d, dst, topoPions, topoPionsLoose, topoKaons, + topoKaonsLoose, topoKaons_PID, topoPions_PID, topoProtons_PID, muons, ks, pi0, hh, hhh, config): self.config = config self.topoPions = [topoPions] self.topoPionsLoose = [topoPionsLoose] + self.topoKaonsLoose = [topoKaonsLoose] self.topoKaons = [topoKaons] self.topoKaons_PID = [topoKaons_PID] self.topoPions_PID = [topoPions_PID] @@ -243,6 +245,10 @@ class B2DXBuilder(object): self._makeB2D0ppbarH('D2HH', self.d.hh_pid) self._makeB02DppbarH('D2HHH', self.d.hhh) + #B+ -> D0 phi K+ + self._makeB2D0phiK('D2HHPID', self.d.hh_pid) + self._makeB2D0phiK('D2HHHHPID', self.d.hhhh_pid) + # B+- -> D0(HH) H+H-H+ self._makeB02DstHHH('Dstar2D0PiPID', self.dst.d0pi_pid) @@ -338,6 +344,14 @@ class B2DXBuilder(object): self._makeB02D0D0KS('LL') self._makeB2DstD0KS('LL') self._makeB02DstDstKS('LL') + # B->D Ds pi pi + self._makeB02DDspipi() + self._makeB2D0Dspipi() + self._makeB02DstDspipi() + # B->D Ds1(2460) + self._makeB02DDs2460() + self._makeB2D0Ds2460() + self._makeB02DstDs2460() # B->DDKK self._makeB2D0DKK() self._makeB2D0DKPi() @@ -426,12 +440,16 @@ class B2DXBuilder(object): 'B2D0PiPi0Resolved': ["B+ -> D0 pi+ pi0", "B- -> D0 pi- pi0"], 'B2D0KsPiDD': ["B+ -> D0 pi+ KS0", "B- -> D0 pi- KS0"], 'B2D0KsPiLL': ["B+ -> D0 pi+ KS0", "B- -> D0 pi- KS0"], + 'B2D0KsKDD': ["B+ -> D0 K+ KS0", "B- -> D0 K- KS0"], + 'B2D0KsKLL': ["B+ -> D0 K+ KS0", "B- -> D0 K- KS0"], 'B2D0KPi0Resolved': ["B+ -> D0 K+ pi0", "B- -> D0 K- pi0"] } inputs = { 'B2D0PiPi0Resolved': d2x + self.topoPions + self.pi0['Resolved'], 'B2D0KsPiDD': d2x + self.topoPionsLoose + self.ks['DD'], 'B2D0KsPiLL': d2x + self.topoPionsLoose + self.ks['LL'], + 'B2D0KsKDD': d2x + self.topoKaonsLoose + self.ks['DD'], + 'B2D0KsKLL': d2x + self.topoKaonsLoose + self.ks['LL'], 'B2D0KPi0Resolved': d2x + self.topoKaons + self.pi0['Resolved'] } b2d0hh = makeB2XSels(decays, dname, inputs, config) @@ -833,6 +851,12 @@ class B2DXBuilder(object): self.lines.append(ProtoLine(b02dhhh_rs, 1.0)) self.lines.append(ProtoLine(b02dhhh_ws, 0.1)) + def _makeB2D0phiK(self, dname, d2x): + decays = {'B2D0phiK': ["B+ -> D0 phi(1020) K+", "B- -> D0 phi(1020) K-"]} + inputs = {'B2D0phiK': d2x + self.hh.kk_pid + self.topoKaons_PID} + b2d0phik = makeB2XSels(decays, dname, inputs, self.config) + self.lines.append(ProtoLine(b2d0phik, 1.0)) + def _makeB02DHHH_FULLDST(self, dname, d2x): '''Makes RS and WS B0 -> D + h- + c.c. (Tighter selection for Full DST)''' config = deepcopy(self.config) @@ -1665,6 +1689,116 @@ class B2DXBuilder(object): self.config) self.lines.append(ProtoLine(b2dstdstks_ws, 0.1)) + def _makeB02DDspipi(self): + '''Makes B0 -> D- D_s+ pi+ pi- + cc''' + decays = { + 'B02DDspipi': [ + "[B0 -> D- D+ pi+ pi-]cc" + ] + } + inputs = { + 'B02DDspipi': + self.d.d_and_ds_cf_pid + self.topoPionsLoose + } + b02ddspipi = makeB2XSels(decays, '', inputs, self.config) + self.lines.append(ProtoLine(b02ddspipi, 1.0)) + + def _makeB2D0Dspipi(self): + '''Makes B+ -> D0 D_s+ pi+ pi-, B- -> D0 D_s- pi- pi+''' + decays = { + 'B2D0Dspipi': [ + "B+ -> D0 D+ pi+ pi-", "B- -> D0 D- pi- pi+" + ] + } + inputs = { + 'B2D0Dspipi': + self.d.kpi_pid + self.d.d_and_ds_cf_pid + self.topoPionsLoose + } + b2d0dspipi = makeB2XSels(decays, '', inputs, self.config) + self.lines.append(ProtoLine(b2d0dspipi, 1.0)) + inputs = { + 'B2D0Dspipi': + self.d.k3pi_pid_tight + self.d.d_and_ds_cf_pid + self.topoPionsLoose + } + b2d0dspipi = makeB2XSels(decays, 'D02K3Pi', inputs, self.config) + self.lines.append(ProtoLine(b2d0dspipi, 1.0)) + + def _makeB02DstDspipi(self): + '''Makes B0 -> D*(2010)- D_s+ pi+ pi- + cc''' + decays = { + 'B02DstDspipi': [ + "[B0 -> D*(2010)- D+ pi+ pi-]cc" + ] + } + inputs = { + 'B02DstDspipi': + self.dst.d0pi_pid + self.d.d_and_ds_cf_pid + self.topoPionsLoose + } + b02dstdspipi = makeB2XSels(decays, '', inputs, self.config) + self.lines.append(ProtoLine(b02dstdspipi, 1.0)) + inputs = { + 'B02DstDspipi': + self.dst.d0pi_k3pi_pid + self.d.d_and_ds_cf_pid + self.topoPionsLoose + } + b02dstdspipi = makeB2XSels(decays, 'DstarD02K3Pi', inputs, self.config) + self.lines.append(ProtoLine(b02dstdspipi, 1.0)) + + def _makeB02DDs2460(self): + '''Makes B0 -> D- D_s1(2460)+ + cc''' + decays = { + 'B02DDs2460': [ + "[B0 -> D- D_s1(2460)+]cc" + ] + } + inputs = { + 'B02DDs2460': + self.d.d_and_ds_cf_loose_pid + self.dst.ds1_dspipi + } + b02dds2460 = makeB2XSels(decays, '', inputs, self.config) + self.lines.append(ProtoLine(b02dds2460, 1.0)) + + def _makeB2D0Ds2460(self): + '''Makes B+ -> D0 D_s1(2460)+, B- -> D0 D_s1(2460)-''' + decays = { + 'B2D0Ds2460': [ + "B+ -> D0 D_s1(2460)+", "B- -> D0 D_s1(2460)-" + ] + } + inputs = { + 'B2D0Ds2460': + self.d.kpi_loose_pid + self.dst.ds1_dspipi + } + b2d0ds2460 = makeB2XSels(decays, '', inputs, self.config) + self.lines.append(ProtoLine(b2d0ds2460, 1.0)) + inputs = { + 'B2D0Ds2460': + self.d.k3pi_loose_pid + self.dst.ds1_dspipi + } + b2d0ds2460 = makeB2XSels(decays, 'D02K3Pi', inputs, self.config) + self.lines.append(ProtoLine(b2d0ds2460, 1.0)) + + def _makeB02DstDs2460(self): + '''Makes B0 -> D*(2010)- D_s1(2460)+ + cc''' + decays = { + 'B02DstDs2460': [ + "[B0 -> D*(2010)- D_s1(2460)+]cc" + ] + } + inputs = { + 'B02DstDs2460': + self.dst.d0pi_loose_pid + self.dst.ds1_dspipi + } + b02dstds2460 = makeB2XSels(decays, '', inputs, self.config) + self.lines.append(ProtoLine(b02dstds2460, 1.0)) + inputs = { + 'B02DstDs2460': + self.dst.d0pi_k3pi_loose_pid + self.dst.ds1_dspipi + } + b02dstds2460 = makeB2XSels(decays, 'DstarD02K3Pi', inputs, self.config) + self.lines.append(ProtoLine(b02dstds2460, 1.0)) + + + def _makeB2D0DKK(self): '''Makes RS B- -> D0D-K+K- + c.c. B- ->Ds- D0 K+ K+ + cc''' decays = { diff --git a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Bc2DXBuilder.py b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Bc2DXBuilder.py index af663b759..fa4393f43 100644 --- a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Bc2DXBuilder.py +++ b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Bc2DXBuilder.py @@ -17,14 +17,19 @@ from Beauty2Charm_Utils import * class Bc2DXBuilder(object): - def __init__(self, d, dst, hh, pions, kaons, config): + def __init__(self, lc, protons, + d, dst, hh, pions, pions_pid, kaons, kaons_pid, config): self.config = config + self.lc = lc.pkpi + self.protons = [protons] self.d = d self.dst = dst self.hh = hh self.pions = [pions] + self.pions_pid = [pions_pid] self.kaons = [kaons] + self.kaons_pid = [kaons_pid] self.lines = [] d_hh_pid = self.d.hh_pid @@ -41,6 +46,10 @@ class Bc2DXBuilder(object): self._makeBc2DX("D2HHHPID", d_hhh_pid_tight, self.config) self._makeBc2DstX("Dstar2D0PiD02HHPID", dst_hh_pid, self.config) self._makeBc2DstX("Dstar2D0PiD02HHHHPID", dst_hhhh_pid, self.config) + self._makeBc2Dsppbar("", self.d.d_and_ds_cf_pid, self.config) + self._makeBc2D0Kpipi("D02KPIPID", self.d.kpi_pid, self.config) + self._makeBc2D0Kpipi("D02K3PIPID", self.d.k3pi_pid, self.config) + self._makeBc2LcKpbar("LC2PKPI", self.lc, self.config) def _makeBc2D0X(self, bname, d, config): decays = { @@ -103,3 +112,33 @@ class Bc2DXBuilder(object): } bc2dstx = makeBc2DstXSels(decays, bname, inputs, config) self.lines.append(ProtoLine(bc2dstx, 1.0)) + + def _makeBc2Dsppbar(self, bname, d, config): + decays = { + 'Bc2Dsppbar': ["[B_c+ -> D- p+ p~-]cc"], + } + inputs = { + 'Bc2Dsppbar': d + self.protons, + } + bc2dsppbar = makeBc2DXSels(decays, bname, inputs, config) + self.lines.append(ProtoLine(bc2dsppbar, 1.0)) + + def _makeBc2D0Kpipi(self, bname, d, config): + decays = { + 'Bc2D0Kpipi': ["B_c+ -> D0 K+ pi+ pi-", "B_c- -> D0 K- pi- pi+"], + } + inputs = { + 'Bc2D0Kpipi': d + self.kaons_pid + self.pions_pid, + } + bc2d0kpipi = makeBc2DXSels(decays, bname, inputs, config) + self.lines.append(ProtoLine(bc2d0kpipi, 1.0)) + + def _makeBc2LcKpbar(self, bname, lc, config): + decays = { + 'Bc2LcKpbar': ["[B_c+ -> Lambda_c+ K+ p~-]cc"], + } + inputs = { + 'Bc2LcKpbar': lc + self.kaons + self.protons, + } + bc2lckpbar = makeBc2DXSels(decays, bname, inputs, config) + self.lines.append(ProtoLine(bc2lckpbar, 1.0)) diff --git a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_DBuilder.py b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_DBuilder.py index f64abfc36..ddf8f1925 100644 --- a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_DBuilder.py +++ b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_DBuilder.py @@ -105,6 +105,10 @@ class DBuilder(object): self.hhh = self._makeD2hhh() self.hhhh = self._makeD2hhhh() + self.hhLoose = self._makeD2hhLoose() + self.hhhLoose = self._makeD2hhhLoose() + self.hhhhLoose = self._makeD2hhhhLoose() + self.ksh_ll = self._makeD2KSh("LL") self.ksh_dd = self._makeD2KSh("DD") self.kshh_ll = self._makeD2KShh("LL") @@ -273,10 +277,12 @@ class DBuilder(object): oneK = "NINTREE(ABSID=='K+') == 1" self.kpi = [filterSelection('D2KPi', oneK, self.hh)] + self.kpi_loose = [filterSelection('D2KPiLoose', oneK, self.hhLoose)] d_cf = "(((ID=='D+') & (NINTREE(ID=='K-')==1) & (%s)) | "\ "((ID=='D-') & (NINTREE(ID=='K+')==1) & (%s)))" % (oneK,oneK) ds_cf = "((NINTREE(ID=='K-')==1) & (NINTREE(ID=='K+')==1))" self.kpi_pid = [filterSelection('D2KPIPID', oneK, self.hh_pid)] + self.kpi_loose_pid = [filterSelection('D2KPILoosePID', oneK, self.hhLoose)] self.kpi_pid_tight = [ filterSelection('D2KPITIGHTPID', oneK, self.hh_pid_tight) ] @@ -307,6 +313,24 @@ class DBuilder(object): RequiredSelections=self.kpkmpip_cc_pid + self.kmpippip_cc_pid) ] + self.kpkmpip_cc_loose = [ + filterSelection('D2KpKmPip_cc_loose', loki_kpkmpip_cc, self.hhhLoose) + ] + self.kmpippip_cc_loose = [ + filterSelection('D2KmPipPip_cc_loose', loki_kmpippip_cc, self.hhhLoose) + ] + self.kpkmpip_cc_loose_pid = [ + filterPID('D2KpKmPip_cc_loose_PID', self.kpkmpip_cc_loose, config_pid) + ] + self.kmpippip_cc_loose_pid = [ + filterPID('D2KmPipPip_cc_loose_PID', self.kmpippip_cc_loose, config_pid) + ] + self.d_and_ds_cf_loose_pid = [ + MergedSelection( + 'DANDDSCFLoosePIDBeauty2Charm', + RequiredSelections=self.kpkmpip_cc_loose_pid + self.kmpippip_cc_loose_pid) + ] + atLeastOneK = "NINTREE(ABSID=='K+') > 0" self.k2h = [filterSelection('D2K2H', atLeastOneK, self.hhh)] self.k3h = [filterSelection('D2K3H', atLeastOneK, self.hhhh)] @@ -343,8 +367,10 @@ class DBuilder(object): filterSelection('D2KPITIGHTPIDUP', oneK, self.hh_pid_tight_up) ] self.k3pi = [filterSelection('D2K3PI', oneK, self.hhhh)] + self.k3pi_loose = [filterSelection('D2K3PILoose', oneK, self.hhhhLoose)] self.k3pi_up = [filterSelection('D2K3PIUP', oneK, self.hhhh_up)] self.k3pi_pid = [filterPID('D2K3PIPID', self.k3pi, config_pid)] + self.k3pi_loose_pid = [filterPID('D2K3PILoosePID', self.k3pi_loose, config_pid)] self.k3pi_pid_tight = [ filterPID('D2K3PIPIDTIGHT', self.k3pi, config_pid['TIGHT']) ] @@ -567,6 +593,24 @@ class DBuilder(object): Algorithm=cp, RequiredSelections=inputs) + def _makeD2TwoBodyLoose(self, name, decays, wm, up, config, inputs): + ''' Makes all D -> HH selections.''' + if up: + wm += '& (ANUM(ISUP)==1)' + name += 'UP' + comboCuts = [LoKiCuts(['ASUMPT'], config).code(), wm, hasTopoChild_Loose()] + comboCuts.append(LoKiCuts(['ADOCA12'], config).code()) + comboCuts = LoKiCuts.combine(comboCuts) + momCuts = LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], config).code() + cp = CombineParticles( + CombinationCut=comboCuts, + MotherCut=momCuts, + DecayDescriptors=decays) + return Selection( + 'Proto_Loose' + name + 'Beauty2Charm', + Algorithm=cp, + RequiredSelections=inputs) + def _makeD2ThreeBody(self, name, decays, wm, up, config, inputs): ''' Makes all D -> HHH selections.''' if up: @@ -589,6 +633,28 @@ class DBuilder(object): Algorithm=cp, RequiredSelections=inputs) + def _makeD2ThreeBodyLoose(self, name, decays, wm, up, config, inputs): + ''' Makes all D -> HHH selections.''' + if up: + wm += '& (ANUM(ISUP)==1)' + name += 'UP' + comboCuts = [LoKiCuts(['ASUMPT'], config).code(), wm, hasTopoChild_UltraLoose()] + comboCuts12 = [LoKiCuts(['ADOCA12'], config).code()] + comboCuts.append(LoKiCuts(['ADOCA13'], config).code()) + comboCuts.append(LoKiCuts(['ADOCA23'], config).code()) + comboCuts = LoKiCuts.combine(comboCuts) + comboCuts12 = LoKiCuts.combine(comboCuts12) + momCuts = LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], config).code() + cp = DaVinci__N3BodyDecays( + Combination12Cut=comboCuts12, + CombinationCut=comboCuts, + MotherCut=momCuts, + DecayDescriptors=decays) + return Selection( + 'Proto_Loose' + name + 'Beauty2Charm', + Algorithm=cp, + RequiredSelections=inputs) + def _makeD2FourBody(self, name, decays, wm, up, config, inputs): ''' Makes all D -> HHHH selections.''' if up: @@ -617,6 +683,34 @@ class DBuilder(object): Algorithm=cp, RequiredSelections=inputs) + def _makeD2FourBodyLoose(self, name, decays, wm, up, config, inputs): + ''' Makes all D -> HHHH selections.''' + if up: + wm += '& (ANUM(ISUP)==1)' + name += 'UP' + comboCuts = [LoKiCuts(['ASUMPT'], config).code(), wm, hasTopoChild_Loose()] + comboCuts12 = [LoKiCuts(['ADOCA12'], config).code()] + comboCuts123 = ["AALL"] + comboCuts123.append(LoKiCuts(['ADOCA13'], config).code()) + comboCuts123.append(LoKiCuts(['ADOCA23'], config).code()) + comboCuts.append(LoKiCuts(['ADOCA14'], config).code()) + comboCuts.append(LoKiCuts(['ADOCA24'], config).code()) + comboCuts.append(LoKiCuts(['ADOCA34'], config).code()) + comboCuts = LoKiCuts.combine(comboCuts) + comboCuts12 = LoKiCuts.combine(comboCuts12) + comboCuts123 = LoKiCuts.combine(comboCuts123) + momCuts = LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], config).code() + cp = DaVinci__N4BodyDecays( + Combination12Cut=comboCuts12, + Combination123Cut=comboCuts123, + CombinationCut=comboCuts, + MotherCut=momCuts, + DecayDescriptors=decays) + return Selection( + 'Proto_Loose' + name + 'Beauty2Charm', + Algorithm=cp, + RequiredSelections=inputs) + def _makeD2FiveBody(self, name, decays, wm, up, config, inputs): ''' Makes all D -> HHHHH selections.''' if up: @@ -741,6 +835,32 @@ class DBuilder(object): 'D2HH' + tag + 'Beauty2Charm', RequiredSelections=sels) ] + def _makeD2hhLoose(self, up=False): + '''Makes D->hh''' + + tag = '' + if up: tag = 'UP' + + min, max = self._massWindow('D0') + + decays = [['pi+', 'pi-'], ['K+', 'pi-'], ['K+', 'K-'], ['K-', 'pi+']] + + sels = [] + + for dec in decays: + name = makeSelName('D', dec) + sel = makeSel('D0', dec) + inputs = self.getInputs(dec, up, []) + sels += [ + self._makeD2TwoBodyLoose(name, [sel], awmFunctor([dec], min, max), + up, self.config, inputs) + ] + + return [ + MergedSelection( + 'D2HHLoose' + tag + 'Beauty2Charm', RequiredSelections=sels) + ] + ## # Implementation using SubPID ## def _makeD2hhWS(self,up=False): ## '''Makes D->hh WS''' @@ -890,6 +1010,43 @@ class DBuilder(object): 'D2HHH' + tag + 'Beauty2Charm', RequiredSelections=sels) ] + def _makeD2hhhLoose(self, up=False): + '''Makes D->hhh''' + + tag = '' + if up: tag = 'UP' + + min, max = self._massWindow('D+') + + decaysp = [['pi+', 'pi+', 'pi-'], ['pi+', 'pi+', 'K-'], + ['K+', 'pi+', 'pi-'], ['K+', 'pi+', 'K-'], + ['K+', 'K+', 'pi-'], ['K+', 'K+', 'K-']] + decaysm = getCCs(decaysp) + + sels = [] + + for dec in decaysp: + name = makeSelName('D+', dec, tag) + sel = makeSel('D+', dec) + inputs = self.getInputs(dec, up, []) + sels += [ + self._makeD2ThreeBodyLoose(name, [sel], awmFunctor([dec], min, max), + up, self.config, inputs) + ] + for dec in decaysm: + name = makeSelName('D-', dec, tag) + sel = makeSel('D-', dec) + inputs = self.getInputs(dec, up, []) + sels += [ + self._makeD2ThreeBodyLoose(name, [sel], awmFunctor([dec], min, max), + up, self.config, inputs) + ] + + return [ + MergedSelection( + 'D2HHHLoose' + tag + 'Beauty2Charm', RequiredSelections=sels) + ] + ## # Implementation using SubPID ## def _makeD2KSh(self,which,up=False): ## '''Makes D->Ksh''' @@ -1993,6 +2150,47 @@ class DBuilder(object): ## return [MergedSelection('D2HHHH'+tag+'WSBeauty2Charm',RequiredSelections=sels)] + def _makeD2hhhhLoose(self, up=False): + '''Makes D->hhhh''' + + tag = '' + if up: tag = 'UP' + + min, max = self._massWindow('D0') + + decays = [ + # 4pi + ['pi+', 'pi+', 'pi-', 'pi-'], + # K3pi + ['pi+', 'pi+', 'K-', 'pi-'], + ['K+', 'pi+', 'pi-', 'pi-'], + # 2K2pi + ['K+', 'K+', 'pi-', 'pi-'], + ['pi+', 'K+', 'K-', 'pi-'], + ['pi+', 'pi+', 'K-', 'K-'], + # 3Kpi + ['K+', 'K+', 'K-', 'pi-'], + ['K+', 'pi+', 'K-', 'K-'], + # 4K + ['K+', 'K+', 'K-', 'K-'] + ] + + sels = [] + + for dec in decays: + name = makeSelName('D', dec) + sel = makeSel('D0', dec) + inputs = self.getInputs(dec, up, []) + sels += [ + self._makeD2FourBodyLoose(name, [sel], awmFunctor([dec], min, max), + up, self.config, inputs) + ] + + return [ + MergedSelection( + 'D2HHHHLoose' + tag + 'Beauty2Charm', RequiredSelections=sels) + ] + # Implementation not using SubPID at all def _makeD2hhhhWS(self, up=False): '''Makes D->hhhh WS''' @@ -2077,7 +2275,9 @@ class DstarBuilder(object): self.config = config #self.d0pi = self._makeDstar2D0pi('',self.d.hh) self.d0pi = self._makeDstar2D0pi('D2HHPID', self.d.hh_pid) + self.d0pi_loose = self._makeDstar2D0pi('D2KPiLoosePID', self.d.kpi_loose_pid) self.d0pi_k3pi = self._makeDstar2D0pi('D2K3Pi', self.d.k3pi) + self.d0pi_k3pi_loose = self._makeDstar2D0pi('D2K3PiLoosePID', self.d.k3pi_loose_pid) self.d0pi_hhhh = self._makeDstar2D0pi('D2HHHH', self.d.hhhh) self.d0pi_hhhh_pid = self._makeDstar2D0pi('D2HHHHPID', self.d.hhhh_pid) self.d0pi_k3h = self._makeDstar2D0pi('D2K3H', self.d.k3h) @@ -2090,9 +2290,13 @@ class DstarBuilder(object): self.d0pi_kshh_dd_pid = self._makeDstar2D0pi('D2KSHHDDPID', self.d.kshh_dd_pid) self.d0pi_pid = [filterPID('Dstar2D0PiPID', self.d0pi, config_pid, 2)] + self.d0pi_loose_pid = [filterPID('Dstar2D0PiLoosePID', self.d0pi_loose, config_pid, 2)] self.d0pi_k3pi_pid = [ filterPID('Dstar2D0PiK3PiPID', self.d0pi_k3pi, config_pid, 2) ] + self.d0pi_k3pi_loose_pid = [ + filterPID('Dstar2D0PiK3PiLoosePID', self.d0pi_k3pi_loose, config_pid, 2) + ] self.d0pi_kspi0hh_ll_merged = self._makeDstar2D0pi( 'D2KSLLPI0MERGEDHH', self.d.kspi0hh_ll_merged) @@ -2421,6 +2625,15 @@ class DstarBuilder(object): self.dsgammacpv_hhh = self._makeDsst2DGammaCPV( 'D2HHH', ds4dsgammacpv) # self.d.hhh_pid + # Linxuan Zhu: Ds1(2460) Ds pi pi + ds_ds1 = [ + filterSelection('ds_ds1', + "(MM > 1910*MeV) & (MM < 2030*MeV)", + self.d.d_and_ds_cf_loose_pid) + ] + self.ds1_dspipi = self._makeDs12Dspipi( + 'Ds12Dspipi', ds_ds1) + def _makeHc2Dpi(self, name, massCut, momCut, decays, inputs): comboCuts = [massCut, LoKiCuts(['ADOCA12'], self.config).code()] comboCuts = LoKiCuts.combine(comboCuts) @@ -2604,5 +2817,51 @@ class DstarBuilder(object): RequiredSelections=d2x + [self.vlaphotons]) ] + def _makeDs12ThreeBody(self, name, decays, wm, config, inputs): + ''' Makes Ds1 -> Ds pi pi selections.''' + comboCuts = [LoKiCuts(['ASUMPT'], config).code(), wm] + comboCuts12 = [LoKiCuts(['ADOCA12'], config).code()] + comboCuts.append(LoKiCuts(['ADOCA13'], config).code()) + comboCuts.append(LoKiCuts(['ADOCA23'], config).code()) + comboCuts = LoKiCuts.combine(comboCuts) + comboCuts12 = LoKiCuts.combine(comboCuts12) + momCuts = LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], config).code() + cp = DaVinci__N3BodyDecays( + Combination12Cut=comboCuts12, + CombinationCut=comboCuts, + MotherCut=momCuts, + DecayDescriptors=decays) + return Selection( + 'Proto' + name + 'Beauty2Charm', + Algorithm=cp, + RequiredSelections=inputs) + + + + #Linxuan Zhu for Ds1(2460) + def _makeDs12Dspipi(self, name, ds_ds1): + decayp = ["D_s1(2460)+ -> D+ pi+ pi-"] + decp = ["D+", "pi+", "pi-"] + decaym = ["D_s1(2460)- -> D- pi- pi+"] + decm = ["D-", "pi-", "pi+"] + + sels = [] + name = makeSelName("D_s1(2460)+", decp, "") + sel = makeSel("D_s1(2460)+", decp) + sels += [ + self._makeDs12ThreeBody(name, [sel], awmFunctor([decp], 1800., 2700.), self.config, ds_ds1+[self.pions]) + ] + name = makeSelName("D_s1(2460)-", decm, "") + sel = makeSel("D_s1(2460)-", decm) + sels += [ + self._makeDs12ThreeBody(name, [sel], awmFunctor([decm], 1800., 2700.), self.config, ds_ds1+[self.pions]) + ] + + return [ + MergedSelection( + "Ds12Dspipi" + "Beauty2Charm", RequiredSelections = sels + ) + ] + #\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\# diff --git a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Lb2XBuilder.py b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Lb2XBuilder.py index 9be95907f..5ef04fce1 100644 --- a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Lb2XBuilder.py +++ b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Lb2XBuilder.py @@ -24,14 +24,17 @@ from Beauty2Charm_Utils import * class LcBuilder(object): '''Produces all Lambda_c baryons for the Beauty2Charm module.''' - def __init__(self, pions, kaons, protons, config, config_pid): + def __init__(self, pions, kaons, protons, lambda0, config, config_pid): self.pions = pions self.kaons = kaons self.protons = protons + self.lambda0 = lambda0 self.config = config self.pkpi = [self._makeLc2phh()] self.pkk = [self._makeLc2phh("PKK")] self.ppipi = [self._makeLc2phh("PPiPi")] + self.lambdapiLL = [self._makeLc2Lambdapi("LL")] + self.lambdapiDD = [self._makeLc2Lambdapi("DD")] self.xic_pkpi = [self._makeXic2pKpi()] self.xic0_pkkpi = [self._makeXic02pKKpi()] self.omegac0_pkkpi = [self._makeOmegac02pKKpi()] @@ -113,6 +116,36 @@ class LcBuilder(object): Algorithm=cp, RequiredSelections=inputs[mode]) + def _makeLc2Lambdapi(self, lambda0): + '''Makes Lambda_c+ -> Lambda0 pi+''' + dm, units = LoKiCuts.cutValue(self.config['MASS_WINDOW']) + comboCuts = [ + LoKiCuts(['ASUMPT'], self.config).code(), + "(ADAMASS('Lambda_c+') < %s*%s) " % (dm + 10, units), + ] + comboCuts.append(LoKiCuts(['ADOCA12'], self.config).code()) + comboCuts = LoKiCuts.combine(comboCuts) + momCuts = [ + "(ADMASS('Lambda_c+') < %s*%s) " % (dm, units), + LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], self.config).code() + ] + momCuts = LoKiCuts.combine(momCuts) + + decays = {'Lc2Lambdapi' + lambda0: ["[Lambda_c+ -> Lambda0 pi+]cc"]} + inputs = { + 'Lc2Lambdapi' + lambda0: + self.lambda0[lambda0] + [self.pions], + } + mode = 'Lc2Lambdapi' + lambda0 + cp = CombineParticles( + CombinationCut=comboCuts, + MotherCut=momCuts, + DecayDescriptors=decays[mode]) + return Selection( + "%sBeauty2Charm" % mode, + Algorithm=cp, + RequiredSelections=inputs[mode]) + def _makeXic2pKpi(self): '''Makes Xic -> p K pi + cc''' dm, units = LoKiCuts.cutValue(self.config['MASS_WINDOW']) @@ -352,6 +385,60 @@ class LooseLcBuilder(object): #\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\# +class LcstarBuilder(object): + '''Produces Lambda_c star baryons for the Beauty2Charm module''' + def __init__(self, lc, pions, config): + self.lc = lc.pkpi + self.pions = pions + self.config = config + self.lcstar2595 = [self._makeLcstar2Lcpipi("Lcstar2595")] + self.lcstar2625 = [self._makeLcstar2Lcpipi("Lcstar2625")] + + def _makeLcstar2Lcpipi(self, mode): + '''Makes Lambda_c(2595)+ -> Lambda_c+ pi+ pi-''' + '''Makes Lambda_c(2625)+ -> Lambda_c+ pi+ pi-''' + decays = { + "Lcstar2595" : "[Lambda_c(2595)+ -> Lambda_c+ pi+ pi-]cc", + "Lcstar2625" : "[Lambda_c(2625)+ -> Lambda_c+ pi+ pi-]cc", + } + inputs = { + "Lcstar2595" : self.lc+[self.pions], + "Lcstar2625" : self.lc+[self.pions], + } + dm, units = LoKiCuts.cutValue(self.config['MASS_WINDOW']) + comboCuts = { + "Lcstar2595":[ + LoKiCuts(['ASUMPT'], self.config).code(), + "(ADAMASS('Lambda_c(2595)+') < %s*%s) " % (dm + 10, units),], + "Lcstar2625":[ + LoKiCuts(['ASUMPT'], self.config).code(), + "(ADAMASS('Lambda_c(2625)+') < %s*%s) " % (dm + 10, units),], + } + comboCuts12 = [LoKiCuts(['ADOCA12'], self.config).code()] + comboCuts[mode].append(LoKiCuts(['ADOCA13'], self.config).code()) + comboCuts[mode].append(LoKiCuts(['ADOCA23'], self.config).code()) + comboCuts12 = LoKiCuts.combine(comboCuts12) + comboCuts[mode] = LoKiCuts.combine(comboCuts[mode]) + momCuts = { + "Lcstar2595": [ + "(ADMASS('Lambda_c(2595)+') < %s*%s) " % (dm, units), + LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], self.config).code()], + "Lcstar2625": [ + "(ADMASS('Lambda_c(2625)+') < %s*%s) " % (dm, units), + LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], self.config).code()], + } + momCuts[mode] = LoKiCuts.combine(momCuts[mode]) + cp = DaVinci__N3BodyDecays( + Combination12Cut=comboCuts12, + CombinationCut=comboCuts[mode], + MotherCut=momCuts[mode], + DecayDescriptors=[decays[mode]]) + return Selection( + "Lc2%sBeauty2Charm" % mode, + Algorithm=cp, + RequiredSelections=inputs[mode]) + + class XiccBuilder(object): @@ -762,13 +849,17 @@ class XibcBuilder(object): class Lb2XBuilder(object): '''Makes all Lambda_b -> X lines.''' - def __init__(self, lc, xicc, d, hh, topoPions, topoPions_PID, topoKaons, + def __init__(self, lc, lcstar, xicc, d, hh, topoPions, topoPions_PID, topoKaons, topoKaons_PID, topoProtons, topoProtons_PID, pions, kaons, ks, hhh, dst, lambda0, config): self.lc = lc.pkpi self.lc_pkk = lc.pkk self.lc_ppipi = lc.ppipi + self.lc_lambdapiLL = lc.lambdapiLL + self.lc_lambdapiDD = lc.lambdapiDD + self.lcstar2595 = lcstar.lcstar2595 + self.lcstar2625 = lcstar.lcstar2625 self.xic = lc.xic_pkpi self.xic0 = lc.xic0_pkkpi self.omegac0 = lc.omegac0_pkkpi @@ -805,6 +896,10 @@ class Lb2XBuilder(object): self.lines = [] # Lb -> Lc+- H-+ (+WS) self._makeLb2LcH() + # Lb -> Lc+ D-/D_s-/D*-/D_s*- + self._makeLb2LcDm() + # Lb -> Lc+/Lc(2595)+/Lc(2625)+ D_s- + self._makeLb2LcDs() # Lb -> Xic+- H-+ (+WS) self._makeLb2XicH() @@ -911,8 +1006,15 @@ class Lb2XBuilder(object): # Lb -> D0 p h (D02K3Pi/D02KsDDHH/D02KsLLHH) self._makeLb2D0ph('D02K3Pi', self.d.k3pi_pid) + self._makeLb2D0ph('D02HHHHPID', self.d.hhhh_pid) self._makeLb2D0ph('D02KsDDHH', self.d.kshh_dd_pid) self._makeLb2D0ph('D02KsLLHH', self.d.kshh_ll_pid) + # Lb -> D0 p h WS + self._makeLb2D0phWS('D02K3PiWS', self.d.k3pi_pid) + self._makeLb2D0phWS('D02HHHHPIDWS', self.d.hhhh_pid) + self._makeLb2D0phWS('D02KsDDHHWS', self.d.kshh_dd_pid) + self._makeLb2D0phWS('D02KsLLHHWS', self.d.kshh_ll_pid) + # Lb -> D(s)- D0(K3Pi/HH) p self._makeLb2DD0p('D02K3Pi', self.d.k3pi_pid) self._makeLb2DD0p('D2HH', self.d.hh_pid) @@ -1031,6 +1133,143 @@ class Lb2XBuilder(object): self.lines.append(ProtoLine(rs_ppipi, 1.0)) self.lines.append(ProtoLine(ws_ppipi, 0.1)) + def _makeLb2LcDm(self): + '''Make Lb0 -> Lc+ D-/D_s- + cc.''' + '''Make Lb0 -> Lc+ D*- + cc.''' + '''Make Lb0 -> Lc+ D_s*- + cc.''' + lcLL = self.lc_lambdapiLL + lcDD = self.lc_lambdapiDD + d2x = self.d.hhh_pid + decays = { + 'Lb2LcDLc2Lambda0LLPi': ["[Lambda_b0 -> Lambda_c+ D-]cc"], + 'Lb2LcDLc2Lambda0DDPi': ["[Lambda_b0 -> Lambda_c+ D-]cc"], + } + inputs = { + 'Lb2LcDLc2Lambda0LLPi': lcLL + d2x, + 'Lb2LcDLc2Lambda0DDPi': lcDD + d2x, + } + dname = "D2HHHPID" + rs = makeB2XSels(decays, dname, inputs, self.config) + self.lines.append(ProtoLine(rs, 1.0)) + + #comboCuts = [ + # LoKiCuts(['AM'], self.config).code(), + #] + #comboCuts = LoKiCuts.combine(comboCuts) + #momCuts = [ + # #LoKiCuts(['VCHI2DOF', 'BPVVDCHI2', 'BPVDIRA'], self.config).code() + # 'ALL', + #] + #momCuts = LoKiCuts.combine(momCuts) + + d2x = self.dst.d0pi_pid + decays = { + 'Lb2LcDstLc2Lambda0LLPi': ["[Lambda_b0 -> Lambda_c+ D*(2010)-]cc"], + 'Lb2LcDstLc2Lambda0DDPi': ["[Lambda_b0 -> Lambda_c+ D*(2010)-]cc"], + } + inputs = { + 'Lb2LcDstLc2Lambda0LLPi': lcLL + d2x, + 'Lb2LcDstLc2Lambda0DDPi': lcDD + d2x, + } + + dname = "" + #names = list(decays.keys()) + #rs = [] + #sname = names[0] + dname + 'Beauty2Charm' + #cp = CombineParticles( + # CombinationCut=comboCuts, + # MotherCut=momCuts, + # DecayDescriptors=decays[names[0]]) + #r = Selection( + # sname, + # Algorithm=cp, + # RequiredSelections=inputs[names[0]]) + #rs.append(r) + #sname = names[1] + dname + 'Beauty2Charm' + #cp = CombineParticles( + # CombinationCut=comboCuts, + # MotherCut=momCuts, + # DecayDescriptors=decays[names[1]]) + #r = Selection( + # sname, + # Algorithm=cp, + # RequiredSelections=inputs[names[1]]) + #rs.append(r) + #self.lines.append(ProtoLine(rs, 1.0)) + rs = makeB2XSels(decays, dname, inputs, self.config) + self.lines.append(ProtoLine(rs, 1.0)) + + d2x = self.dst.d0pi_k3pi_pid + decays = { + 'Lb2LcDstLc2Lambda0LLPi': ["[Lambda_b0 -> Lambda_c+ D*(2010)-]cc"], + 'Lb2LcDstLc2Lambda0DDPi': ["[Lambda_b0 -> Lambda_c+ D*(2010)-]cc"], + } + inputs = { + 'Lb2LcDstLc2Lambda0LLPi': lcLL + d2x, + 'Lb2LcDstLc2Lambda0DDPi': lcDD + d2x, + } + dname = "DstarD02K3Pi" + #names = list(decays.keys()) + #rs = [] + #sname = names[0] + dname + 'Beauty2Charm' + #cp = CombineParticles( + # CombinationCut=comboCuts, + # MotherCut=momCuts, + # DecayDescriptors=decays[names[0]]) + #r = Selection( + # sname, + # Algorithm=cp, + # RequiredSelections=inputs[names[0]]) + #rs.append(r) + #sname = names[1] + dname + 'Beauty2Charm' + #cp = CombineParticles( + # CombinationCut=comboCuts, + # MotherCut=momCuts, + # DecayDescriptors=decays[names[1]]) + #r = Selection( + # sname, + # Algorithm=cp, + # RequiredSelections=inputs[names[1]]) + #rs.append(r) + #self.lines.append(ProtoLine(rs, 1.0)) + rs = makeB2XSels(decays, dname, inputs, self.config) + self.lines.append(ProtoLine(rs, 1.0)) + + d2x = self.dst.dgamma_hhh_pid + decays = { + 'Lb2LcDsstarLc2Lambda0LLPi': ["[Lambda_b0 -> Lambda_c+ D*_s-]cc"], + 'Lb2LcDsstarLc2Lambda0DDPi': ["[Lambda_b0 -> Lambda_c+ D*_s-]cc"], + } + inputs = { + 'Lb2LcDsstarLc2Lambda0LLPi': lcLL + d2x, + 'Lb2LcDsstarLc2Lambda0DDPi': lcDD + d2x, + } + dname = "DsstarD02HHHPID" + rs = makeB2XSels(decays, dname, inputs, self.config) + self.lines.append(ProtoLine(rs, 1.0)) + + def _makeLb2LcDs(self): + '''Make Lambda_b0 -> Lambda_c+ D_s-''' + '''Make Lambda_b0 -> Lambda_c(2595)+ D_s-''' + '''Make Lambda_b0 -> Lambda_c(2625)+ D_s-''' + lc = self.lc + lcstar2595 = self.lcstar2595 + lcstar2625 = self.lcstar2625 + d2x = self.d.hhh_pid + decays = { + 'Lb2LcDs': ["[Lambda_b0 -> Lambda_c+ D-]cc"], + 'Lb2Lc2595Ds': ["[Lambda_b0 -> Lambda_c(2595)+ D-]cc"], + 'Lb2Lc2625Ds': ["[Lambda_b0 -> Lambda_c(2625)+ D-]cc"], + } + inputs = { + 'Lb2LcDs': lc + d2x, + 'Lb2Lc2595Ds': lcstar2595 + d2x, + 'Lb2Lc2625Ds': lcstar2625 + d2x, + } + dname = "D2HHHPID" + rs = makeB2XSels(decays, dname, inputs, self.config) + self.lines.append(ProtoLine(rs, 1.0)) + def _makeB2Lcpbar(self): '''Make RS and WS B -> Lc pbar + cc.''' protons = self.protons @@ -1927,18 +2166,32 @@ class Lb2XBuilder(object): protons_pid = self.protons_pid kaons_pid = self.topoKaons_pid pions_pid = self.topoPions_pid - decays_k = {'Lb2D0pK': ["Lambda_b0 -> D0 p+ K-", "Lambda_b0 -> D0 p~- K+"]} + decays_k = {'Lb2D0pK': ["Lambda_b0 -> D0 p+ K-", "Lambda_b~0 -> D0 p~- K+"]} + inputs_k = {'Lb2D0pK': d2x + protons_pid + kaons_pid} + rs_k = makeB2XSels(decays_k, dname, inputs_k, self.config) + self.lines.append(ProtoLine(rs_k, 1.0)) + decays_pi = {'Lb2D0pPi': ["Lambda_b0 -> D0 p+ pi-", "Lambda_b~0 -> D0 p~- pi+"]} + inputs_pi = {'Lb2D0pPi': d2x + protons_pid + pions_pid} + rs_pi = makeB2XSels(decays_pi, dname, inputs_pi, self.config) + self.lines.append(ProtoLine(rs_pi, 1.0)) + + def _makeLb2D0phWS(self, dname, d2x): + '''Make RS Lb -> D0(K3pi) p h + cc.''' + protons_pid = self.protons_pid + kaons_pid = self.topoKaons_pid + pions_pid = self.topoPions_pid + decays_k = {'Lb2D0pK': ["Lambda_b0 -> D0 p+ K+", "Lambda_b~0 -> D0 p~- K-"]} inputs_k = {'Lb2D0pK': d2x + protons_pid + kaons_pid} rs_k = makeB2XSels(decays_k, dname, inputs_k, self.config) self.lines.append(ProtoLine(rs_k, 1.0)) - decays_pi = {'Lb2D0pPi': ["Lambda_b0 -> D0 p+ pi-", "Lambda_b0 -> D0 p~- pi+"]} + decays_pi = {'Lb2D0pPi': ["Lambda_b0 -> D0 p+ pi+", "Lambda_b~0 -> D0 p~- pi-"]} inputs_pi = {'Lb2D0pPi': d2x + protons_pid + pions_pid} rs_pi = makeB2XSels(decays_pi, dname, inputs_pi, self.config) self.lines.append(ProtoLine(rs_pi, 1.0)) def _makeLb2DD0p(self, dname, d2x): '''Make Lb -> D(s)- D0(K3pi) p + cc.''' - decays = {'Lb2DD0pD2HHH': ["Lambda_b0 -> D- D0 p+", "Lambda_b0 -> D+ D0 p~-"]} + decays = {'Lb2DD0pD2HHH': ["Lambda_b0 -> D- D0 p+", "Lambda_b~0 -> D+ D0 p~-"]} inputs = {'Lb2DD0pD2HHH': self.d.hhh_cf_pid + d2x + self.protons_pid} rs = makeB2XSels(decays, dname, inputs, self.config) self.lines.append(ProtoLine(rs, 1.0)) diff --git a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Utils.py b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Utils.py index 67273aefd..93cbd1703 100644 --- a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Utils.py +++ b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/Beauty2Charm_Utils.py @@ -72,6 +72,8 @@ def topoInputsCuts(): # Don't need IP chi2 cut b/c is in 1st filter def topoInputsLooseCuts(): return "HASTRACK & (TRCHI2DOF<4.) & (PT > 250*MeV) & (P > 2500*MeV)" +def topoInputsUltraLooseCuts(): + return "HASTRACK & (TRCHI2DOF<4.) & (PT > 100*MeV) & (P > 1000*MeV)" def topoKSInputsCuts(): # Don't need IP chi2 cut b/c is in 1st filter return "(PT > 500*MeV) & (P > 5000*MeV) & (BPVVDCHI2 > 1000)" @@ -87,6 +89,10 @@ def topoInputsLoose(tag, inputs): return filterSelection(tag + 'TopoInputsLoose', topoInputsLooseCuts(), inputs) +def topoInputsUltraLoose(tag, inputs): + '''Selects tracks that could have been used by the Topo.''' + return filterSelection(tag + 'TopoInputsLoose', topoInputsUltraLooseCuts(), + inputs) def hasTopoChild(): return "AHASCHILD((ISBASIC & "+topoInputsCuts()+")|((ABSID=='KS0') & "\ @@ -97,6 +103,9 @@ def hasTopoChild_Loose(): return "AHASCHILD((ISBASIC & "+topoInputsLooseCuts()+")|((ABSID=='KS0') & "\ +topoKSInputsCuts() +"))" +def hasTopoChild_UltraLoose(): + return "AHASCHILD((ISBASIC & "+topoInputsUltraLooseCuts()+")|((ABSID=='KS0') & "\ + +topoKSInputsCuts() +"))" def hasTopoChildren(): return "NINTREE((ISBASIC & "+topoInputsCuts()+")|((ABSID=='KS0') & "\ diff --git a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/StrippingBeauty2Charm.py b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/StrippingBeauty2Charm.py index c79a0a343..d90c20952 100644 --- a/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/StrippingBeauty2Charm.py +++ b/Phys/StrippingSelections/python/StrippingSelections/StrippingB2OC/StrippingBeauty2Charm.py @@ -186,6 +186,23 @@ default_config = { 'BPVDIRA_MIN': 0, 'MASS_WINDOW': '100*MeV' }, + "Lcstar": { # Cuts made on all Lcstar's used in all 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': 10, + 'BPVVDCHI2_MIN': 36, + 'BPVDIRA_MIN': 0, + 'MASS_WINDOW': '200*MeV' + }, "LC_FOR_XIBC": { # Cuts made on Lc's/Xic(0) used in Xibc lines 'ASUMPT_MIN': '1800*MeV', 'ADOCA12_MAX': '0.5*mm', @@ -919,6 +936,10 @@ default_config = { 'StrippingB2D0KPi0ResolvedD2HHHHWSBeauty2CharmLine', 'StrippingB2D0KsPiLLD2HHHHWSBeauty2CharmLine', 'StrippingB2D0PiPi0ResolvedD2HHHHWSBeauty2CharmLine', + 'StrippingB2D0KsKDDD2HHBeauty2CharmLine', + 'StrippingB2D0KsKLLD2HHBeauty2CharmLine', + 'StrippingB2D0KsKDDD2HHHHBeauty2CharmLine', + 'StrippingB2D0KsKLLD2HHHHBeauty2CharmLine', 'StrippingB02DKD2PhiMuNuBeauty2CharmLine', 'StrippingB02DPiD2PhiMuNuBeauty2CharmLine', 'StrippingB02DKWSD2PhiMuNuBeauty2CharmLine', @@ -1113,6 +1134,8 @@ default_config = { 'StrippingB2D0ppbarPiD2HHBeauty2CharmLine', 'StrippingB02DppbarKD2HHHBeauty2CharmLine', 'StrippingB02DppbarPiD2HHHBeauty2CharmLine', + 'StrippingB2D0phiKD2HHPIDBeauty2CharmLine', + 'StrippingB2D0phiKD2HHHHPIDBeauty2CharmLine', 'StrippingB02DstKKPiDstar2D0PiPIDBeauty2CharmLine', 'StrippingB02DstKPiPiDstar2D0PiPIDBeauty2CharmLine', 'StrippingB02DstPiPiPiDstar2D0PiPIDBeauty2CharmLine', @@ -1310,6 +1333,18 @@ default_config = { 'StrippingB02DstDstKKBeauty2CharmLine', 'StrippingB02DstDstKKDstarD02K3PiBeauty2CharmLine', 'StrippingB02DstDstKKDstarD02K3PiDstarD02K3PiBeauty2CharmLine', + ##### DDspipi lines ### + 'StrippingB02DDspipiBeauty2CharmLine', + 'StrippingB2D0DspipiBeauty2CharmLine', + 'StrippingB2D0DspipiD02K3PiBeauty2CharmLine', + 'StrippingB02DstDspipiBeauty2CharmLine', + 'StrippingB02DstDspipiDstarD02K3PiBeauty2CharmLine', + ##### DDs2460 lines ### + 'StrippingB02DDs2460Beauty2CharmLine', + 'StrippingB2D0Ds2460Beauty2CharmLine', + 'StrippingB2D0Ds2460D02K3PiBeauty2CharmLine', + 'StrippingB02DstDs2460Beauty2CharmLine', + 'StrippingB02DstDs2460DstarD02K3PiBeauty2CharmLine', #### DDPi lines ### 'StrippingB2DDPiBeauty2CharmLine', 'StrippingB2DDPiWSBeauty2CharmLine', @@ -1354,6 +1389,17 @@ default_config = { 'StrippingLb2LcPiWSLc2PKKBeauty2CharmLine', 'StrippingLb2LcPiWSLc2PPiPiBeauty2CharmLine', 'StrippingLb2LcPiNoIPWSLc2PKPiBeauty2CharmLine', + 'StrippingLb2LcDLc2Lambda0LLPiD2HHHPIDBeauty2CharmLine', + 'StrippingLb2LcDLc2Lambda0DDPiD2HHHPIDBeauty2CharmLine', + 'StrippingLb2LcDstLc2Lambda0LLPiBeauty2CharmLine', + 'StrippingLb2LcDstLc2Lambda0DDPiBeauty2CharmLine', + 'StrippingLb2LcDstLc2Lambda0LLPiDstarD02K3PiBeauty2CharmLine', + 'StrippingLb2LcDstLc2Lambda0DDPiDstarD02K3PiBeauty2CharmLine', + 'StrippingLb2LcDsstarLc2Lambda0LLPiDsstarD02HHHPIDBeauty2CharmLine', + 'StrippingLb2LcDsstarLc2Lambda0DDPiDsstarD02HHHPIDBeauty2CharmLine', + 'StrippingLb2LcDsD2HHHPIDBeauty2CharmLine', + 'StrippingLb2Lc2595DsD2HHHPIDBeauty2CharmLine', + 'StrippingLb2Lc2625DsD2HHHPIDBeauty2CharmLine', 'StrippingLb2XicPiXic2PKPiBeauty2CharmLine', 'StrippingLb2XicKXic2PKPiBeauty2CharmLine', 'StrippingLb2XicKWSXic2PKPiBeauty2CharmLine', @@ -1398,6 +1444,22 @@ default_config = { 'StrippingLb2D0PHNoPIDWSD02HHBeauty2CharmLine', 'StrippingLb2D0PHD02K3PiBeauty2CharmLine', 'StrippingLb2D0PHWSD02K3PiBeauty2CharmLine', + 'StrippingLb2D0pKD02K3PiBeauty2CharmLine', + 'StrippingLb2D0pKD02HHHHPIDBeauty2CharmLine', + 'StrippingLb2D0pKD02KsDDHHBeauty2CharmLine', + 'StrippingLb2D0pKD02KsLLHHBeauty2CharmLine', + 'StrippingLb2D0pKD02K3PiWSBeauty2CharmLine', + 'StrippingLb2D0pKD02HHHHPIDWSBeauty2CharmLine', + 'StrippingLb2D0pKD02KsDDHHWSBeauty2CharmLine', + 'StrippingLb2D0pKD02KsLLHHWSBeauty2CharmLine', + 'StrippingLb2D0pPiD02K3PiBeauty2CharmLine', + 'StrippingLb2D0pPiD02HHHHPIDBeauty2CharmLine', + 'StrippingLb2D0pPiD02KsDDHHBeauty2CharmLine', + 'StrippingLb2D0pPiD02KsLLHHBeauty2CharmLine', + 'StrippingLb2D0pPiD02K3PiWSBeauty2CharmLine', + 'StrippingLb2D0pPiD02HHHHPIDWSBeauty2CharmLine', + 'StrippingLb2D0pPiD02KsDDHHWSBeauty2CharmLine', + 'StrippingLb2D0pPiD02KsLLHHWSBeauty2CharmLine', 'StrippingLb2D0PPbarD02HHBeauty2CharmLine', 'StrippingLb2D0PPbarWSD02HHBeauty2CharmLine', 'StrippingLb2LcKSKLLLc2PKPiBeauty2CharmLine', @@ -1646,6 +1708,12 @@ default_config = { 'StrippingBc2DstDst0Dst2DPI0D2KSHDst02D0PI0D02KSHHBeauty2CharmLine', 'StrippingBc2DstDst0Dst2DPI0D2KSHDst02D0GammaD02HHBeauty2CharmLine', + ##B_c+ + 'StrippingBc2DsppbarBeauty2CharmLine', + 'StrippingBc2D0KpipiD02KPIPIDBeauty2CharmLine', + 'StrippingBc2D0KpipiD02K3PIPIDBeauty2CharmLine', + 'StrippingBc2LcKpbarLC2PKPIBeauty2CharmLine', + #Xibc 'StrippingXibc2LcD0D02KPiBeauty2CharmLine', 'StrippingXibc2LcD0PiD02KPiBeauty2CharmLine', @@ -1814,8 +1882,9 @@ class Beauty2CharmConf(LineBuilder): config['Dstar'], config['PID']) # Lc -> X - lc = LcBuilder(pions_pid, kaons_pid, protons_pid, config['D2X'], + lc = LcBuilder(pions_pid, kaons_pid, protons_pid, lambda0, config['D2X'], config['PID']) + lcstar = LcstarBuilder(lc, pions_pid, config['Lcstar']) xicc = XiccBuilder(lc, pions_pid, config['D2X']) # Loose Lc, for Xibc lcLoose = LooseLcBuilder(pions_Xc_Xibc, kaons_Xc_Xibc, protons_Xc_Xibc, @@ -1824,7 +1893,7 @@ class Beauty2CharmConf(LineBuilder): config['LC_FOR_XIBC']) # make B->DX - b2dx = B2DXBuilder(d, dst, topoPions, topoPionsLoose, topoKaons, + b2dx = B2DXBuilder(d, dst, topoPions, topoPionsLoose, topoKaons, topoKaonsLoose, topoKaons_PID, topoPions_PID, topoProtons_PID, muons, ks, pi0_fromB, hh, hhh, config['B2X']) self._makeLines(b2dx.lines, config) @@ -1839,12 +1908,12 @@ class Beauty2CharmConf(LineBuilder): self._makeLines(bc2bx.lines, config) #Bc -> DX lines - bc2dx = Bc2DXBuilder(d, dst, hh, topoPionsLoose, topoKaonsLoose, + bc2dx = Bc2DXBuilder(lc, topoProtons_PID, d, dst, hh, topoPionsLoose, topoPions_PID, topoKaonsLoose, topoKaons_PID, config['Bc2DX']) self._makeLines(bc2dx.lines, config) # Lb -> X - lb2x = Lb2XBuilder(lc, xicc, d, hh, topoPions, topoPions_PID, + lb2x = Lb2XBuilder(lc, lcstar, xicc, d, hh, topoPions, topoPions_PID, topoKaons, topoKaons_PID, topoProtons, topoProtons_PID, pions, kaons, ks, hhh, dst, lambda0, config['B2X']) -- GitLab