Beam Spot in the Fast Sim
Complete:
(Offline)Beam Spot and Fast Simulation
If you are reading this page, it means that you would like to change the collision point position, and you are probably wondering why it is not a trivial change in a config file.
Several reconstruction algorithms need an a-priori vertex position (usually in the transverse plane). The position of the beam is computed by the
offlineBeamSpot
on a few events before being stored in a database. Thus the beam position is available and can be used in the reconstruction (more information is available
here).
As a result, it is a three-step process. In the
Full Simulation, several vertex smearing scenarii are available and it is the user responsibility to check the consistency between the average vertex position used in the simulation and the offline beam spot used in the reconstruction. An inconsistency between the two leads to a loss of efficiency for many algorithms (b tagging, electron seeding...)
In the Fast Sim this consistency is built-in since the offlineBeamSpot is used to simulate the vertex position. This consistency between the simulation and the reconstruction is thus ensured.
Recipe to modify the beam spot in the Fast Sim
- Check the tag of the
RecoVertex/BeamSpotProducer
in the release you are currently using
addpkg --query RecoVertex/BeamSpotProducer
- If it is older than
V00-03-14
get this version and compile
addpkg RecoVertex/BeamSpotProducer V00-03-14
scram b
- Include in your fast sim config file the following lines to the fake BeamSpotProducer and configure it; the last three lines should be modified according to your needs.
process.load("RecoVertex.BeamSpotProducer.BeamSpotFakeParameters_cfi")
process.es_prefer_beamspot = cms.ESPrefer("BeamSpotFakeConditions","")
process.BeamSpotFakeConditions.X0=0
process.BeamSpotFakeConditions.Y0=0
process.BeamSpotFakeConditions.Z0=0
With the previous modifications, the vertex is going to smeared around (0,0,0) according to the parameters defined in
FastSimulation/EventProducer/python/FamosSimHits_cff.py
A trivial case: vertex in (0,0,0) with the default smearing
That's precisely what the previous example does
An other trivial case: vertex in (0,0,0) with no smearing at all
In this case, one should, in addition, tell the Fast Sim that the vertex should not be smeared. The easiest way is to use a simple Gaussian smearing with
SigmaX=SigmaY=SigmaZ=0.
To do so:
addpkg FastSimulation/EventProducer
- Edit
FastSimulation/EventProducer/python/FamosSimHits_cff.py
and change
from FastSimulation.Event.Early10TeVCollisionVertexGenerator_cfi import *
into
from FastSimulation.Event.GaussianVertexGenerator_cfi import *
- In case you are simulating pile-up, do not forget to do the same operation with
FastSimulation/PileUpProducer/python/PileUpProducer_cff.py
- Add the following lines in your top-level config file
process.load("RecoVertex.BeamSpotProducer.BeamSpotFakeParameters_cfi")
process.es_prefer_beamspot = cms.ESPrefer("BeamSpotFakeConditions","")
process.BeamSpotFakeConditions.X0=0
process.BeamSpotFakeConditions.Y0=0
process.BeamSpotFakeConditions.Z0=0
as seen previously as well as
process.famosSimHits.VertexGenerator.SigmaX=0
process.famosSimHits.VertexGenerator.SigmaY=0
process.famosSimHits.VertexGenerator.SigmaZ=0
and the equivalent for
process.famosPileUp.VertexGenerator
if needed.
Review Status
Responsible:
FlorianBeaudette
Last reviewed by:
--
FlorianBeaudette - 29 Sep 2008