176 def reconstruct(self) -> pybasf2.Path:
177 """
178 Returns pybasf2.Path which loads the FSP Particles
179 """
180 path = basf2.create_path()
181
183 ma.fillParticleLists([('K+:FSP', ''), ('pi+:FSP', ''), ('e+:FSP', ''),
184 ('mu+:FSP', ''), ('p+:FSP', '')], writeOut=True, path=path)
185 for outputList, inputList in [('gamma:FSP', 'gamma:mdst'), ('K_S0:V0', 'K_S0:mdst'),
186 ('Lambda0:V0', 'Lambda0:mdst'), ('K_L0:FSP', 'K_L0:mdst'),
187 ('pi0:FSP', 'pi0:mdst'), ('gamma:V0', 'gamma:v0mdst')]:
188 ma.copyParticles(outputList, inputList, writeOut=True, path=path)
189 else:
190 ma.fillParticleLists([('K+:FSP', ''), ('pi+:FSP', ''), ('e+:FSP', ''),
191 ('mu+:FSP', ''), ('gamma:FSP', ''),
192 ('p+:FSP', ''), ('K_L0:FSP', '')], writeOut=True, path=path)
193 ma.fillParticleList('K_S0:V0 -> pi+ pi-', '', writeOut=True, path=path)
194 ma.fillParticleList('Lambda0:V0 -> p+ pi-', '', writeOut=True, path=path)
195 ma.fillConvertedPhotonsList('gamma:V0 -> e+ e-', '', writeOut=True, path=path)
196
197 if self.config.monitor:
198 names = ['e+', 'K+', 'pi+', 'mu+', 'gamma', 'K_S0', 'p+', 'K_L0', 'Lambda0', 'pi0']
199 filename = os.path.join(self.config.monitoring_path, 'Monitor_FSPLoader.root')
201 variables = [(f'NumberOfMCParticlesInEvent({pdg})', 100, -0.5, 99.5) for pdg in pdgs]
202 ma.variablesToHistogram('', variables=variables, filename=filename, ignoreCommandLineOverride=True, path=path)
203 return path
204
205