Belle II Software  light-2212-foldex
mdst_compatibility-v02-01-00.py
1 #!/usr/bin/env python3
2 
3 
10 
11 """
12 Test backwards compatibility for an mdst file produced with release-02-01-00.
13 
14 See https://confluence.desy.de/display/BI/Backward+Compatibility if this test fails.
15 
16 CHANGES since release-02-01-00:
17 - EventMetaData:
18  + isEndOfRun
19 - EventLevelTrackingInfo:
20  + hasSVDCKFAbortionFlag/setSVDCKFAbortionFlag
21  + hasPXDCKFAbortionFlag/setPXDCKFAbortionFlag
22  + hasSVDSpacePointCreatorAbortionFlag/setSVDSpacePointCreatorAbortionFlag
23 - ECLCluster:
24  + getMinTrkDistanceID
25  + getPulseShapeDiscriminationMVA added
26  + hasFailedFitTime
27  + hasFailedTimeResolution
28  - getCovarianceMatrixAsArray removed
29 - TRGSummary:
30  + getTimQuality added
31  + isPoissonInInjectionVeto
32  * added getters to map bit names to numbers (getInputBitNumber, getOutputBitNumber)
33  The mapping is from the database and doesn't affect mdst content and is thus not tested here.
34 - SoftwareTriggerResult:
35  * non-prescaled results added
36 - TrackFitResult:
37  + ndf
38  + chi2
39  + remove the const classifier of TrackFitResults and add a function to update the contents
40  + updateTrackFitResult
41  + mask
42 - Particle masses:
43  * The particle masses have been updated to PDG 2020. As a result, the
44  energies corresponding to the measured momenta became slightly different.
45 - EventLevelTriggerTimeInfo
46  * added new storage element for information from the Trigger Timing Distribution (TTD)
47 - Track:
48  + statusBitmap and getStatusBit
49  + getTrackTime added
50  + wasRefined
51  + isFlippedAndRefitted
52  + getTrackFitResultByName
53  + getTrackFitResultsByName
54  + getTrackFitResultWithClosestMassByName
55 """
56 
57 from basf2 import create_path, process, set_random_seed, find_file
58 from b2test_utils import configure_logging_for_tests
59 from mdst import add_mdst_dump
60 
61 if __name__ == "__main__":
62  configure_logging_for_tests()
63  set_random_seed(1)
64  main = create_path()
65  main.add_module("RootInput", inputFileName=find_file("mdst/tests/mdst-v02-01-00.root"))
66  main.add_module("EventInfoPrinter")
67  add_mdst_dump(main, True)
68  process(main, 3)