...
The current sim/reco consists of five steps
- Get Events
- SLIC for running events through GEANT4
- lcsim to run the digitzation and the tracking
- SlicPandora to do the ParticleFlowAnalysis
- LCFIPlus to do the Vertexing
- lcsim to make DST's
For various reasons, reco is split in three steps. We'd love to have it in one, so if you're keen mitigating this situation, please let us know
Prerequisite
Code Block | ||
---|---|---|
| ||
cd /scratch/sid_complete
cd v01-17-02-sid
source init_ilcsoft.sh |
so you have all pathes and libraries properly set
Step 1 Getting Events
there are two ways of getting events into SLIC, using the particle gun or by using a stdhep file as an input
Particle Gun
to be written
StDHEP
get an example stdhep file from the SLAC FTP server
and store it in a data folder /scratch/sid_complete/data
now get ready to run SLIC
Running SLIC
For all the following purposes, we're using the sidloi3 detector model, others can be used as well (or you can design your own)
Code Block |
---|
cd data
$SLIC/build/bin/slic -g ../lcsim/LCDetectors/detectors/sidloi3/sidloi3.lcdd -i pythiaZPolemumu.stdhep -O -p . -r 100
|
- -g denotes the location of the detector description
- -i the input file
- -O autonaming of the output file
- -p the path, here "."
- -r run for 100 events
it should produce an outputfile called
pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3.slcio
Running the reco
use the following Command line (all in one line!)
Code Block |
---|
java -jar ../lcsim/lcsim/target/lcsim-2.11-SNAPSHOT-bin.jar ../myscripts/sid_dbd_prePandora_noOverlay.xml
-DinputFile=pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3.slcio
-DtrackingStrategies=../myscripts/sidloi3_trackingStrategies_default.xml
-DoutputFile=pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_reco.slcio
|
- -jar ../lcsim/lcsim/target/lcsim-2.11-SNAPSHOT-bin.jar contains the reco code
- ../myscripts/sid_dbd_prePandora_noOverlay.xml is the steeringfile
- -DinputFile/-DoutputFile define the files to be used
- -DtrackingStrategies is a file with tracking strategies to be used
Running the PFA
create a macro file called mymacro.macro
Code Block |
---|
/lcio/PDGFlag true
/lcio/filename myparticlegun.slcio
/run/initialize
/generator/select gun
/gun/particle e-
/gun/position 0 0 0
/gun/direction 0. 1. 0
/gun/energy 10 GeV
/run/beamOn 100 |
StDHEP
get an example stdhep file from the SLAC FTP server
and store it in a data folder /scratch/sid_complete/data
now get ready to run SLIC
Step 2 Running SLIC
For all the following purposes, we're using the sidloi3 detector model, others can be used as well (or you can design your own)
for the particle gun do the following
the execute this with
Code Block | ||
---|---|---|
| ||
cd data
$SLIC/build/bin/slic -g ../lcsim/LCDetectors/detectors/sidloi3/sidloi3.lcdd -m mymacro.macro |
this will generate a file called myparticlegun.slcio with 100 10 GeV electrons fired at 90 degrees in the sidloi3 detector version
For the stdhep, use the following
Code Block | ||
---|---|---|
| ||
cd data
$SLIC/build/bin/slic -g ../lcsim/LCDetectors/detectors/sidloi3/sidloi3.lcdd -i pythiaZPolemumu.stdhep -O -p . -r 100
|
- -g denotes the location of the detector description
- -i the input file
- -O autonaming of the output file
- -p the path, here "."
- -r run for 100 events
it should produce an outputfile called
pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3.slcio
Step 3 Running the reco
Info |
---|
For the following we'll use the LCIO file made from the stdhep input, for the particle gun file, just replace the file names |
use the following Command line (all in one line!)
Code Block |
---|
java -jar ../lcsim/lcsim/target/lcsim-2.11-SNAPSHOT-bin.jar ../myscripts/sid_dbd_prePandora_noOverlay.xml -DinputFile=pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3.slcio -DtrackingStrategies=../myscripts/sidloi3_trackingStrategies_default.xml -DoutputFile=pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_reco.slcio
|
- -jar ../lcsim/lcsim/target/lcsim-2.11-SNAPSHOT-bin.jar contains the reco code
- ../myscripts/sid_dbd_prePandora_noOverlay.xml is the steeringfile
- -DinputFile/-DoutputFile define the files to be used
- -DtrackingStrategies is a file with tracking strategies to be used
Step 4 Running the PFA
Code Block | ||
---|---|---|
| ||
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:../slicPandora/lib/
../slicPandora/bin/PandoraFrontend -g ../myscripts/sidloi3_pandora.xml -c ../myscripts/sid_dbd_pandoraSettings.xml -i pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_reco.slcio -o pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_pandora.slcio
|
* -g Geometry file
- -c settings
- -i input -o outputfile
Step 5 Running the Vertexing
Code Block | ||
---|---|---|
| ||
cp ../myscripts/sid_dbd_vertexing.xml .
|
modify the filenames accordingly in an editor
Code Block | ||
---|---|---|
| ||
<global>
<parameter name="LCIOInputFiles"> pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_pandora.slcio</parameter>
<parameter name="GearXMLFile"> </parameter>
<parameter name="MaxRecordNumber" value="-1" />
<parameter name="SkipNEvents" value="0" />
<parameter name="SupressCheck" value="false" />
<parameter name="Verbosity" options="DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT">WARNING</parameter>
</global>
<processor name="MyLCIOOutputProcessor" type="LCIOOutputProcessor">
<parameter name="LCIOOutputFile" type="string">pythiaZPolemumu | ||
Code Block | ||
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:../slicPandora/lib/ ../slicPandora/bin/PandoraFrontend -g ../myscripts/sidloi3_pandora.xml -c ../myscripts/sid_dbd_pandoraSettings.xml -i pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_reco.slcio -o pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_pandora.slcio |
* -g Geometry file
- -c settings
- -i input -o outputfile
Running the Vertexing
Code Block |
---|
cp ~/myscripts/sid_dbd_vertexing.xml .
|
modify the filenames accordingly in an editor
lcfi.slcio </parameter>
<parameter name="LCIOWriteMode" type="string" value="WRITE_NEW"/>
</processor>
|
Code Block |
---|
Code Block |
$MARLIN/bin/Marlin sid_dbd_vertexing.xml
|
Step 6 Making the DST
This final step creates two lcio files, one DST and with all the collections. It also performs the truth-matching
Code Block |
---|
java -jar ../lcsim/lcsim/target/lcsim-2.11-SNAPSHOT-bin.jar ../myscripts/sid_dbd_postPandora.xml -DinputFile=pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_lcfi.slcio -DrecFile=pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_full.slcio -DdstFile=pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_dst.slcio |
...
use the anajob tool from the LCIO package
Code Block |
---|
anajob data/pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_full.slcio
|
it should yield
Code Block |
---|
EVENT: 9
RUN: 0
DETECTOR: sidloi3
COLLECTIONS: (see below)
///////////////////////////////////
---------------------------------------------------------------------------
COLLECTION NAME COLLECTION TYPE NUMBER OF ELEMENTS
===========================================================================
BeamCalHits SimCalorimeterHit 0
BuildUpVertex Vertex 0
BuildUpVertex_RP ReconstructedParticle 0
BuildUpVertex_V0 Vertex 0
BuildUpVertex_V0_RP ReconstructedParticle 0
CalorimeterHitRelations LCRelation 199
ClusterMCTruthLink LCRelation 2
EM_BARREL CalorimeterHit 64
EM_ENDCAP CalorimeterHit 0
EcalBarrelHits SimCalorimeterHit 64
EcalEndcapHits SimCalorimeterHit 0
HAD_BARREL CalorimeterHit 87
HAD_ENDCAP CalorimeterHit 0
HcalBarrelHits SimCalorimeterHit 87
HcalEndcapHits SimCalorimeterHit 0
HelicalTrackHitRelations LCRelation 22
HelicalTrackHits TrackerHit 22
HelicalTrackMCRelations LCRelation 22
LumiCalHits SimCalorimeterHit 0
MCParticle MCParticle 16
MCParticlesSkimmed MCParticle 16
MUON_BARREL CalorimeterHit 48
MUON_ENDCAP CalorimeterHit 0
MuonBarrelHits SimCalorimeterHit 48
MuonEndcapHits SimCalorimeterHit 0
PandoraPFOCollection ReconstructedParticle 2
PrimaryVertex Vertex 1
PrimaryVertex_RP ReconstructedParticle 1
RecoMCTruthLink LCRelation 2
ReconClusters Cluster 2
SiTrackerBarrelHits SimTrackerHit 13
SiTrackerEndcapHits SimTrackerHit 0
SiTrackerForwardHits SimTrackerHit 0
SiVertexBarrelHits SimTrackerHit 10
SiVertexEndcapHits SimTrackerHit 0
StateAtECal LCGenericObject 2
StateAtEnd LCGenericObject 2
StateAtStart LCGenericObject 2
TKR_RawTrackerHits TrackerRawData 20
TKR_TrackerHits TrackerHit 13
TrackMCTruthLink LCRelation 2
Tracks Track 2
VXD_RawTrackerHits TrackerRawData 16
VXD_TrackerHits TrackerHit 10
---------------------------------------------------------------------------
|
...
or use jas to look at the Events
Code Block |
---|
jas-assembly-3.0.3/jas3 data/pythiaZPolemumu_slic-3.1.0_geant4-v9r6p1_QGSP_BERT_sidloi3_full.slcio
|
...