ATLASSimulationCSCWalkThrough
Walkthrough: ATLAS simulation using the CSC scripts
If you follow the AthenaKlientDriftWalkThrough you can run the examples in this guide.
Various file types of are mentioned in this text:
- Ntuple
- flat ntuples (usable directly in =root=)
- RDO Raw Data Object
- What comes out of the simulation
- ESD Event Summary Data
- Reconstructed RDO file, used to make AOD and for
- AOD Analysis Object Data
- Summary of an 'ESD file
- DPD Derived Physics Data
- Analysis specific processed AOD
In general the files are root files, but not directly usable in root.
Event generation
To generate events use the script csc_evgen_trf.py that generates events for a physics process defined in one of the jobOptions files located in $INSTALL/AtlasOffline/13.0.40/Generators/EvgenJobOptions/share. The script takes the following arguments
- runNumber (int)
- each run number corresponds to one physics process
- firstEvent (int)
- number of the first event in the output data file
- maxEvents (int)
- Maximum number of events to process
- randomSeed (int)
- random seed for physics generators
- jobConfig (list)
- jobOptions fragment containing the physics and the configuration settings
- outputEvgenFile (str)
- Output file that contains generated events
- [ histogramFile ] (str) default='NONE'
- Output file that contains histograms.
- [ ntupleFile ] (str) default='NONE'
- Output file that contains ntuples.
- [ inputGeneratorFile ] (str) default='NONE'
- Input file used by the particle generator to generate events
The following call generates a run with 5000 events for the process Z->tau,tau and will save the file 005188.evgen.pool.root.
csc_evgen_trf.py\ 005188 1 5000 1231243\ 'CSC.005188.A3_Ztautau_filter.py'\ '005188.evgen.pool.root'
Note that the run-number must match the =jobOptions= file given.
Atlfast AOD generation
The script csc_atlfast_trf.py truns Atlfast and produces AODs directly from the generated events. It takes the following arguments
- inputEvgenFile (list)
- Input file that contains generated events
- outputAODFile (str)
- Output file that contains AODs
- ntupleFile (str)
- Output file that contains ntuples.
- maxEvents (int)
- Maximum number of events to process
- skipEvents (int)
- Number of events to skip
To run on the file with generated events from the previous section run
csc_atlfast_trf.py\ '005188.evgen.pool.root'\ '005188.atlfast.aod.pool.root'\ '005188.atlfast.nt.root'\ -1 0
The -1 includes all events in the input file
Script that makes several runs of atlfast aod
The following bash script generates nruns of nevts events of the type specified in 'jobops.
nruns=10 nevts="10000" run="005188" jobops=CSC.005188.A3_Ztautau_filter.py for (( i=0; i<nruns; ++i)); do evgen=${nevts}.${i}.${run}.evgen.pool.root atlfast_aod=`echo ${evgen} | sed 's,evgen,atlfast.aod,'` atlfast_nt=`echo ${evgen} | sed 's,evgen,atlfast.nt,'` csc_evgen_trf.py ${run} 1 ${nevts} ${RANDOM} ${jobops} ${evgen} csc_atlfast_trf.py ${evgen} ${atlfast_aod} ${atlfast_nt} -1 0 done
Making ESDs AODs using full ATLAS simulation
In these examples use the geometry definition ATLAS-CSC-01-02-00 and the DEFAULT trigger. Remember that the Geant4 step is very slow, run in a few events only until you know what you are doing.
GEANT4 simulation and digitization
The script csc_simul_trf.py runs the GEANT4 and digitization on the generated events and produces a HITS and a RDO file. It has the following options
- inputEvgenFile (list)
- Input file that contains generated events
- outputHitsFile (str)
- Output file that contains hits
- outputRDOFile (str)
- Output file that contains RDO's
- maxEvents (int)
- Maximum number of events to process
- skipEvents (int)
- Number of events to skip
- randomSeed (int)
- random seed for simulation
- geometryVersion (str)
- Geometry Version
- digiSeedOffset1 (int)
- random seed offset for digitization
- digiSeedOffset2 (int)
- random seed offset for digitization
- [ physicsList ] (str) default='QGSP_EMV'
- physics list to be used
- [ jobConfig ] (list) default='NONE'
- Joboptions file with user settings, in particular the configuration settings. Default packages: .,SimuJobTransforms,PyJobTransforms
- [ DBRelease ] (str) default='NONE'
- Tarball containing the DBRelease to use
- [ triggerConfig ] (str) default='DEFAULT'
- Configuration string to use for =TrigT1= and =HLT=. Set to 'NONE' to switch off trigger, and set to 'DEFAULT' to use the default of the used release.
Run the full detector simulation:
csc_simul_trf.py\ '005188.evgen.pool.root'\ '005188.hits.pool.root'\ '005188.rdo.pool.root'\ -1 0 123\ 'ATLAS-CSC-01-02-00'\ 12 23
Reconstruction - create an ESD
The reconstruction can be run using the following script csc_recoESD_trf.py which takes the RDO file from the simulation and produces an ESD file. The scripts has the following options
- inputRDOFile (list)
- Input file that contains RDOs
- outputESDFile (str)
- Output file that contains ESDs
- ntupleFile (str)
- Output file that contains ntuples.
- maxEvents (int)
- Maximum number of events to process
- skipEvents (int)
- Number of events to skip
- geometryVersion (str)
- Geometry Version
- triggerConfig (str)
- Configuration string to use for TrigT1 and HLT. Set to 'NONE' to switch off trigger, and set to 'DEFAULT' to use the default of the used release.
- [ jobConfig ] (list) default='NONE'
- Joboptions file with user settings, in particular the configuration settings. Default packages: RecJobTransforms, PyJobTransforms
- [ DBRelease ] (str) default='NONE'
- Tarball containing the DBRelease to use
To run on the simulated RDO file run
csc_recoESD_trf.py\ '005188.rdo.pool.root'\ '005188.esd.pool.root'\ '005188.rdo.ntuple.pool.root'\ -1 0\ 'ATLAS-CSC-01-02-00'\ 'DEFAULT'
Create AOD from an ESD
The script csc_recoAOD_trf.py makes an AOD file from an ESD file.
- inputESDFile (list)
- Input file that contains ESDs
- outputAODFile (str)
- Output file that contains AODs
- maxEvents (int)
- Maximum number of events to process
- skipEvents (int)
- Number of events to skip
- geometryVersion (str)
- Geometry Version
- triggerConfig (str)
- Configuration string to use for TrigT1 and HLT. Set to 'NONE' to switch off trigger, and set to 'DEFAULT' to use the default of the used release.
- [ jobConfig ] (list) default='NONE'
- Joboptions file with user settings, in particular the configuration settings. Default packages: RecJobTransforms , PyJobTransforms
- [ DBRelease ] (str) default='NONE'
- Tarball containing the DBRelease to use
Run like this
csc_recoAOD_trf.py\ '005188.esd.pool.root'\ '005188.aod.pool.root'\ -1 0\ 'ATLAS-CSC-01-02-00'\ 'DEFAULT'
Kka054 13:37, 11 March 2009 (CET)