cms-sw/cmssw — pull request #3052 by giamman (2014-03-27 15:28:19+00:00)
Title: Preparation for new mixing part 9

This PR contains an important fix to a bug that had sneaked inside 710pre3, related to the "DigiRecoMixing" option (non-default yet).
However, that bug was masking another problem. We had been discussing exactly that problem with Chris Jones in the comments of PR 2016 ( https://github.com/cms-sw/cmssw/pull/2016 ), but we didn't converge on a solution.
What you find in FastSimulation/Tracking/plugins/RecoTrackAccumulator.cc now is what I understood that Chris was suggesting to do. However, if you test it you will get:

----- Begin Fatal Exception 27-Mar-2014 16:24:26 CET-----------------------
An exception of category 'InvalidReference' occurred while
[0] Processing run: 1 lumi: 1 event: 1
[1] Running path 'simulation_step'
[2] Calling event method for module MixingModule/'mix'
Exception Message:
Inconsistency RefCore::pushBackItem: Ref or Ptr is inconsistent with RefVector (PtrVector)id = (1:184) should be (1:165)
----- End Fatal Exception -------------------------------------------------

To do a test, you need to edit the last line in FastSimulation/Configuration/python/CommonInputs_cff.py from GenMixing to DigiRecoMixing, and then execute /afs/cern.ch/user/g/giamman/public/test.py (which includes a PU scenario that makes use of the new mixing).