Belle II Software development
cdcFullTrackingValidation.py
1#!/usr/bin/env python3
2
3
10
11"""
12<header>
13 <contact>software-tracking@belle2.org</contact>
14 <input>EvtGenSimNoBkg.root</input>
15 <output>CDCFullTrackingValidation.root</output>
16 <description>This script validates the full CDC tracking chain with a legendre step first
17 and a cellular automaton step second in Y(4S) runs.</description>
18</header>
19"""
20
21from tracking.validation.run import TrackingValidationRun
22import tracking
23import logging
24import basf2
25VALIDATION_OUTPUT_FILE = 'CDCFullTrackingValidation.root'
26N_EVENTS = 1000
27ACTIVE = False
28
29
30class CDCFull(TrackingValidationRun):
31 """Validate the full CDC track-finding chain"""
32
33 n_events = N_EVENTS
34
35 generator_module = 'generic'
36
37 root_input_file = '../EvtGenSimNoBkg.root'
38
39 def finder_module(self, path):
40 """Add the CDC track-finding module to the basf2 path"""
41 tracking.add_cdc_track_finding(path)
42 # adjust_module(path, "TFCDC_WireHitPreparer",
43 # UseNLoops=1)
44
45
46 tracking_coverage = {
47 'WhichParticles': ['CDC'], # Include all particles seen in CDC, also secondaries
48 'UsePXDHits': False,
49 'UseSVDHits': False,
50 'UseCDCHits': True,
51 'UseOnlyAxialCDCHits': False,
52 "UseReassignedHits": True,
53 "UseNLoops": 1,
54 "UseOnlyBeforeTOP": True,
55 'MinCDCAxialHits': 8,
56 'MinCDCStereoHits': 6,
57 "AllowFirstCDCSuperLayerOnly": True,
58 'EnergyCut': 0,
59 }
60
61 pulls = True
62
63 output_file_name = VALIDATION_OUTPUT_FILE
64
65
66def main():
67 basf2.set_random_seed(1337)
68 validation_run = CDCFull()
69 validation_run.configure_and_execute_from_commandline()
70
71
72if __name__ == '__main__':
73 logging.basicConfig(level=logging.INFO)
74 if ACTIVE:
75 main()
76 else:
77 print("This validation deactivated and thus basf2 is not executed.\n"
78 "If you want to run this validation, please set the 'ACTIVE' flag above to 'True'.\n"
79 "Exiting.")
None finder_module
Name of the finder module to be used - can be everything that is accepted by tracking....
Definition: main.py:1