Skip to content

Add electrons with brem

Carla Marin Benito requested to merge cmarinbe_ParticleWithBrem into master

The goal of this MR is to create electrons including brem recovery in the functional framework. This includes:

  • new FunctionalBremAdder: copy of BremAdder with minimal modifications to make it thread safe.

  • new ParticleWithBremMaker: takes a container of particles and one of photons as input and creates new particles for which the momentum has been corrected by matching brem photons using FunctionalBremAdder::addBrem

    • the choice is made to copy all the particles, including the ones for which a matching brem is not found. This means the output and input container of particles are of the same size. This is done so analysts can then run directly on the output and get all the electrons (no matter if a matching brem was found or not)
    • it checks that the input particles have tracks associated and don't have already brem added
  • new FunctionalDiElectronMaker: takes a container of particles and one of photons, builds pairs of particles, applies bremsstrahlung corrections ensuring that the same photon is not used to correct both electrons (using FunctionalBremAdder::addBrem2Pair), and builds a parent particle from the combination. This is based on the old DiElectronMaker but it has been made thread safe and simplified a lot by removing all the features that were never used. The major difference is that it takes particles instead of protoparticles as input. The current idea is that selections on the input particles are applied before and not inside the DiElectronMaker. Mass and PT cuts can be applied to the parent particle inside the DiElectronMaker.

    • if the standard vertex fit fails and for the case of converted photons, it uses ParticleTransporter to build the combined particle (inherited from the original code). The usage of this tool in a ToolHandle required to make all its methods const. All the methods have been marked as such but no check has been done that they are actually const.

This is needed for Moore!669 (merged)

Edited by Carla Marin Benito

Merge request reports

Loading