CMSSW_6_2_0 part
Use a SLC6 machine (for instance lxplus.cern.ch) for this part.
Get TOTEM version of CMSSW_6_2_0:
Getting started 6_2_0
Run generator and smearing generator part, saving to both ROOT and
HepMC-format. [Gen.py.txt is attached to this TWiki, download and rename to Gen.py]
cmsRun Gen.py
Creates
Gen.root
and
GenEvent_ASCII.dat
.
Run TOTEM simulation and reconstruction. [TOTEM.py.txt is attached to this TWiki, download and rename to TOTEM.py]
cmsRun TOTEM.py
Creates
TOTEM.root
.
CMSSW_5_3_7_patch5 part
NOTE! Due to the coming shutdown of SLC 5 based LXPLUS and LXBATCH the SLC 5 resources are limited. The following part can be done in SLC 6 by using CMSSW version 5_3_11 and replacing the global tag with START53_V27::All.
Use a SLC5 machine (for instance lxplus5.cern.ch) for this part.
Get CMSSW version 5_3_7_patch5.
cmsrel CMSSW_5_3_7_patch5
cd CMSSW_5_3_7_patch5
scram b
cmsenv
Create
CMS_GEN.py
(we are using a non-existing file CMS_cff.py for the generator part, this way cmsDriver doesn't produce any generator part in the configuration file):
In CMSSW_5_3_11:
cmsDriver.py Pythia8_PhotonJetpt15_20_10TeV_8TeV_cff.py --step GEN --beamspot Realistic8TeVCollision --conditions START53_V27::All --pileup NoPileUp --datamix NODATAMIXER --eventcontent FEVTSIM --fileout CMS_GEN.root --no_exec -n 10
(In CMSSW_5_3_7:
cmsDriver.py CMS --step GEN --beamspot Realistic8TeVCollision --conditions START53_V26::All --pileup NoPileUp --datamix NODATAMIXER --eventcontent FEVTSIM --fileout CMS_GEN.root --no_exec -n 10
)
Modify it:
Remove vertex smearing (already done in TOTEM SW): comment
process.load('IOMC.EventVertexGenerators.VtxSmearedRealistic8TeVCollision_cfi')
and add
process.VertexSmearing = cms.Sequence()
Replace
process.source = cms.Source("EmptySource")
with
process.source = cms.Source("MCFileSource",
noEventSort = cms.untracked.bool(True),
duplicateCheckMode = cms.untracked.string('noDuplicateCheck'),
fileNames = cms.untracked.vstring('file:GenEvent_ASCII.dat'),
skipEvents = cms.untracked.uint32(0)
)
Add following line to tell genParticles what our generator product is called (normally "generator", but
HepMC Reader calls it "source"!)
process.genParticles.src = "source"
Now run with
cmsRun CMS_GEN.py
and this will create CMS_GEN.root.
Now do the CMS simulation:
cmsDriver.py CMS_GEN.py --step SIM,DIGI,L1,DIGI2RAW --beamspot Realistic8TeVCollision --conditions START53_V26::All --pileup NoPileUp --datamix NODATAMIXER --eventcontent FEVTSIM --no_exec --filein file:CMS_GEN.root --fileout CMS_SIM.root -n 10
Add this line to CMS_GEN_py_SIM_DIGI_L1_DIGI2RAW.py: process.g4SimHits.Generator.HepMCProductLabel = "source"
cmsRun CMS_GEN_py_SIM_DIGI_L1_DIGI2RAW.py
And CMS reco:
cmsDriver.py CMS_SIM --mc --step RAW2DIGI,L1Reco,RECO --beamspot Realistic8TeVCollision --conditions START53_V26::All --pileup NoPileUp --datamix NODATAMIXER --filein file:CMS_SIM.root --fileout CMS_REC.root --eventcontent FEVTSIM -n 10
Produce Ntuples and combine
Produce CMS UATree Ntuples and TOTEM Ntuples separately. Make sure that the reco files you include were succesfully simulated and reconstructed in both CMS and TOTEM. The numbers of events in each sub sample to be combined
MUST match.
Instructions for producing the CMS Ntuples can be found at
FwdPhysicsCMSTOTEMAnalysis.
TOTEM Ntuples are produced with the
TotemNtuplizer, which is found as part of the TOTEM CMSSW_6_2_0 version. An example configuration is attached as "totem_ntuple_cfg_py". Filenames need to be added there and then it can be run with" cmsRun".
Once both Ntuples are done, use the modified merging tool (for simulations only!), which can be checked out from SVN:
svn co svn+ssh://svn.cern.ch/reps/totem/trunk/user/jwelti/cmstotem-V00-02-00
Follow the same instructions as for the data on the
FwdPhysicsCMSTOTEMAnalysis page, but use "mergeMCNtuples" instead of "mergeNtuples".