Faster MuonIdProducer with deltaEta(track, muon segment) matching

MuonIdProducer timing can be reduced by requiring rough ∆eta between track momentum and muon segment's detector position before track extrapolations.
Track extrapolation have been performed even if there's no muon activities in the existing codes.
Usually particle's trajectory is bent only in phi direction by the magnetic field, so it is safe to assume a muon hits's eta coordinate are similar to the particle's pseudo rapidity in the momentum space within some tolerance.

https://indico.cern.ch/event/350139/contribution/2/material/slides/0.pdf
You have essentially the same code repeated for the three muon chambers. Could you try to factorize it better?