Belle II Software development
ecltrigger.py
1#!/usr/bin/env python
2
3
10
11import basf2 as b2
12
13
14def add_ecl_trigger(path, SourceOfTC=3, ETMConditionDB=True):
15 """
16 add ecl trigger module to path
17 """
18 trgeclfam = b2.register_module("TRGECLFAM")
19 # Output TC Waveform (0 : no save, 1 : save)
20 trgeclfam.param('TCWaveform', 0)
21 # save only measured TC data(=0) or both measured and true TC data(=1)
22 trgeclfam.param('FAMAnaTable', 0)
23 # select source of TC data (1=ECLHit, 2=ECLSimHit, 3=ECLHit+TRGECLBGTCHit)
24 # ("1:=ECLHit" is used for signal w/o bkg, and real time background monitor)
25 trgeclfam.param('SourceOfTC', SourceOfTC)
26 #
27 path.add_module(trgeclfam)
28 #
29 trgecl = b2.register_module("TRGECL")
30 # trgecl.logging.log_level = LogLevel.DEBUG
31
32 # flag of ConditionDB (False:=not use ConditionDB, True:=use ConditionDB)
33 trgecl.param('ConditionDB', ETMConditionDB)
34
35 # Output Clustering method(0: Use only ICN, 1: ICN + Max TC)
36 trgecl.param('Clustering', 1)
37 # The limit # of cluster in clustering logic
38 trgecl.param('ClusterLimit', 6)
39
40 # Theta ID region(low and high) of 3DBhabhaVetoInTrack
41 trgecl.param('3DBhabhaVetoInTrackThetaRegion', [3, 15])
42 # taub2b two cluster angle selection in CM (degree)
43 # (phi low, phi high, theta low, theta high)
44 trgecl.param('Taub2bAngleCut', [110, 250, 130, 230])
45 # taub2b total energy cut in lab (GeV)
46 trgecl.param('Taub2bEtotCut', 7.0)
47 # taub2b cluster energy selection in lab (GeV)
48 trgecl.param('Taub2bCLELabCut', 1.9)
49
50 # taub2b2 two cluster angle selection in CM (degree)
51 # (phi low, phi high, theta low, theta high)
52 trgecl.param('Taub2b2AngleCut', [120, 240, 140, 220])
53 # taub2b2 total energy cut in lab (GeV)
54 trgecl.param('Taub2b2EtotCut', 7.0)
55 # taub2b2 cluster energy cut(low, high) in lab (GeV)
56 trgecl.param('Taub2b2CLELabCut', [0.162, 3.0])
57
58 # taub2b3 two cluster angle selection in CM (degree)
59 # (phi low, phi high, theta low, theta high)
60 trgecl.param('Taub2b3AngleCut', [120, 240, 140, 220])
61 # taub2b3 total energy cut in lab (GeV)
62 trgecl.param('Taub2b3EtotCut', 7.0)
63 # taub2b3 cluster energy cut in lab (GeV) for one of b2b cluseter
64 trgecl.param('Taub2b3CLEb2bLabCut', 0.14)
65 # taub2b3 cluster energy low selection(low, high) in lab (GeV) for all clusters
66 trgecl.param('Taub2b3CLELabCut', [0.12, 4.5])
67
68 # hie1 and hie2, angle selection for addition Bhabha veto
69 trgecl.param('hie12BhabhaVetoAngle', [150, 210, 160, 200])
70 #
71 path.add_module(trgecl)