15 import modularAnalysis
as ma
17 import b2biiConversion
20 os.environ[
'PGUSER'] =
'g0db'
22 b2.conditions.prepend_globaltag(ma.getAnalysisGlobaltag())
23 b2.conditions.append_globaltag(
'Legacy_CollisionAxisCMS_Belle')
26 path = b2.create_path()
31 'analysis/mdstBelle1_exp65_charged.root',
37 enableNisKsFinder=
False,
42 ma.setAnalysisConfigParams({
'mcMatchingVersion':
'Belle'}, path)
46 particles = fei.get_default_channels()
49 configuration = fei.config.FeiConfiguration(prefix=
'FEI_B2BII_light-2012-minos',
50 training=
False, monitor=
False, cache=0)
53 feistate = fei.get_path(particles, configuration)
56 path.add_path(feistate.path)
59 path.add_module(
'MCMatcherParticles', listName=
'B+:generic', looseMCMatching=
True)
60 path.add_module(
'MCMatcherParticles', listName=
'B+:semileptonic', looseMCMatching=
True)
61 path.add_module(
'MCMatcherParticles', listName=
'B0:generic', looseMCMatching=
True)
62 path.add_module(
'MCMatcherParticles', listName=
'B0:semileptonic', looseMCMatching=
True)
65 ma.variablesToNtuple(
'B+:generic',
69 'extraInfo(decayModeID)',
70 'extraInfo(uniqueSignal)',
71 'extraInfo(SignalProbability)',
73 filename=
'B_charged_hadronic.root',
75 ma.variablesToNtuple(
'B+:semileptonic',
76 [
'cosThetaBetweenParticleAndNominalB',
78 'extraInfo(decayModeID)',
79 'extraInfo(uniqueSignal)',
80 'extraInfo(SignalProbability)',
81 'isSignalAcceptMissingNeutrino'],
82 filename=
'B_charged_semileptonic.root',
85 ma.variablesToNtuple(
'B0:generic',
89 'extraInfo(decayModeID)',
90 'extraInfo(uniqueSignal)',
91 'extraInfo(SignalProbability)',
93 filename=
'B_mixed_hadronic.root',
95 ma.variablesToNtuple(
'B0:semileptonic',
96 [
'cosThetaBetweenParticleAndNominalB',
98 'extraInfo(decayModeID)',
99 'extraInfo(uniqueSignal)',
100 'extraInfo(SignalProbability)',
101 'isSignalAcceptMissingNeutrino'],
102 filename=
'B_mixed_semileptonic.root',
106 b2.process(path, max_event=100)
def convertBelleMdstToBelleIIMdst(inputBelleMDSTFile, applySkim=True, saveResultExtraInfo=False, useBelleDBServer=None, convertBeamParameters=True, generatorLevelReconstruction=False, generatorLevelMCMatching=False, path=None, entrySequences=None, matchType2E9oE25Threshold=-1.1, enableNisKsFinder=True, HadronA=True, HadronB=True, enableRecTrg=False, enableEvtcls=True, SmearTrack=2, enableLocalDB=True, convertNbar=False)