Download presentation
Presentation is loading. Please wait.
Published byRandell Hampton Modified over 9 years ago
1
OSCAR 2 (for the Tracker) (Adattamento della presentazione di T. Boccali al Tracker Tutorial 3/3/2003)
2
Torino, 14-16 Aprile 20032 CMSIM
3
Torino, 14-16 Aprile 20033 Geant4
4
Torino, 14-16 Aprile 20034 OSCAR OSCAR is the implementation of a simulation program based upon Geant4 libraries We are at the second Major release (OSCAR2), which differs quite a lot from the previous release.
5
Torino, 14-16 Aprile 20035 OSCAR Major Versions OSCAR 1: A Geant 4 program which uses some features of our framework (COBRA) OSCAR 2: A COBRA application which uses Geant 4 libraries This implies we have for free persistency, observer mechanism, profiling and so on.
6
Torino, 14-16 Aprile 20036 Modus operandi
7
Torino, 14-16 Aprile 20037 The User and OSCAR As for Cmsim, the standard user should not need to write any code, but simply interact with OSCAR via data cards and other sorts of input. Only if the user needs to access something which cannot be seen from data in ORCA, he will really have to look inside OSCAR
8
Torino, 14-16 Aprile 20038 OSCAR for you... Cmsim/OSCAR Pythia Particle Gun ORCA
9
Torino, 14-16 Aprile 20039 Interact with OSCAR Interactions with OSCAR: we need to specify a (some) DDD geometry file(s) we might need to specify a special set of production cuts we might want to specify a Pythia ntuple as input we might want to use the internal particle guns to generate simple test events we have to decide what to really do (how many events, which detectors are switched on...) G4 macro.orcarc
10
Torino, 14-16 Aprile 200310 Running OSCAR scram project OSCAR OSCAR_2_2_0_pre2b This version uses gcc 2.95.2, i.e.: check that SCRAM_ARCH is NOT set cd OSCAR_2_2_0_pre2b/src cmscvsroot OSCAR; cvs login Password is “98passwd” cvs co –r OSCAR_2_2_0_pre2b OscarApplication/G4SimApplication cd OscarApplication/G4SimApplication/test See the file test/README!
11
Torino, 14-16 Aprile 200311 The.orcarc Copy the.orcarc: cp ~namapane/public/Tutorial/day3/hitsOscar/.orcarc. Let’s have a look to it: Specify XML geometry file: Geometry:ConfigurationFileName = […]/configuration.xml
12
Torino, 14-16 Aprile 200312.orcarc: Production cuts The standard particle production cuts are being tuned right now by the PRS, but Physics:FileNameForPhysicsRangeCuts = PhysicsRangeCuts-127.data specifies a different file if needed Please note G4 default: cuts are in Range! Thick_Stand.Concrete gamma 470.107*mm Thick_Stand.Concrete e- 972.332*mm Thick_Stand.Concrete e+ 24.6053*mm
13
Torino, 14-16 Aprile 200313.orcarc: reading Pythia ntuples As usually done with Cmsim! Module MantisNtplReader must be linked via BuildFile, or directly at runtime with ExternalPackages = MantisNtplReader Specify the input file with: EventNtplReader:NtplFileName = w_enu.ntpl EventNtplReader:NtplID = 101
14
Torino, 14-16 Aprile 200314.orcarc: using the Particle gun Instead of MantisNtplReader, link MantisGunReader ParticleGun:PID = 13 ParticleGun:MinEta = -2.5 ParticleGun:MaxEta = 2.5 Then, you choose a Gun ParticleGun:Gun = FlatRandomPtGun ParticleGun:MinPt = 19.8 ParticleGun:MaxPt = 20.2 ParticleGun:Gun = FlatRandomEGun ParticleGun:MinE = 10 ParticleGun:MaxE = 10
15
Torino, 14-16 Aprile 200315.orcarc: Vertex Smearing Smear the 0 th vertex ParticleGun:VertexGenerator = FlatEventVertexGenerator VertexGenerator:MinX = 0. VertexGenerator:MinY = 0. VertexGenerator:MinZ = 0. VertexGenerator:MaxX = 0. VertexGenerator:MaxY = 0. VertexGenerator:MaxZ = 0. EventNtplReader:VertexGenerator = GaussianEventVertexGenerator VertexGenerator:MeanX = 0. VertexGenerator:MeanY = 0. VertexGenerator:MeanZ = 0. VertexGenerator:SigmaX = 0.015 VertexGenerator:SigmaY = 0.015 VertexGenerator:SigmaZ = 53.
16
Torino, 14-16 Aprile 200316.orcarc: Macro file Either run interactively, or specify a G4 macro file G4InputFile = hit-writing.macro
17
Torino, 14-16 Aprile 200317 The macro file Minimal: /load MantisSetupBuilder /load BaseMagneticField /load MantisMagneticField /run/initialize /run/beamOn 2 loads the geometry Magnetic field Initialization of xsec Fire 2 events but in this way we have no sensitive detector!
18
Torino, 14-16 Aprile 200318 Sensitive detectors For the Tracker, you have to load SensDet libraries before the instantiation of the geometry /load MantisSensitiveDetector /load PersistentTrackingHits /load TrackingHitsWriter /load TkNumbering /load TrackerNumberingScheme /load TkSensitiveDetector MantisFramework COBRA/Tracker stuff Tracker numbering Concrete sensitive detectors
19
Torino, 14-16 Aprile 200319 Let’s go! Go to OscarApplication/G4SimApplication/test eval `scram runtime –csh` scram b source writeTrigger.csh oscar After some time (!) a set of database files is created (*.TestG4) in the current dir! They contain SimHits
20
Torino, 14-16 Aprile 200320 Digitising (tracker only) Go to ORCA_7_2_0_pre13/src Must use gcc 2.95.2: SCRAM_ARCH is NOT set! Retrieve the code and compile: cmscvsroot ORCA; cvs login cvs co -r ORCA_7_2_0_pre13 Tracker/TkDDDInterface cd Tracker/TkDDDInterface/test scram b Only a demonstration – final product will be different!
21
Torino, 14-16 Aprile 200321 Digitising: settings Geometry must be the same used by OSCAR setenv DDCONFIG ~namapane/public/Tutorial/day3/hitsOscar/configuration.xml Cards cp ~namapane/public/Tutorial/day3/digiFromOscar/.orcarc. Have a look! TkDDDInterface:UseDDD = 1 FilePath = directory where we ran oscar InputCollections = /System/TestG4/testOSCAR/testOSCAR OutputDataSet = /System/NoPu/testOSCAR GoPersistent = 1 …
22
Torino, 14-16 Aprile 200322 Digitising: run Execute testBuilding The digis are added to the database!!!
23
Torino, 14-16 Aprile 200323 Reading Back! For example, reconstruct tracks! cvs co -r ORCA_7_2_0_pre13 TrackerReco/GtfPattern cd TrackerReco/GtfPattern/test The BuildFile: add cp ~namapane/public/Tutorial/day3/tracks/BuildFile. scram b The cards cp ~namapane/public/Tutorial/day3/tracks/.orcarc.
24
Torino, 14-16 Aprile 200324 And Finally… Run! Tracks Tracks are reconstructed!
25
Torino, 14-16 Aprile 200325 How to “program” OSCAR? Mechanism very close to the one you are used in ORCA: “observe” something class MyActions : private Observer, private Observer { “upDated” at each new event “upDated” at each step (= interaction) “upDated” at each end of event
26
Torino, 14-16 Aprile 200326 and then implement the methods void upDate(const BeginOfEvent * evt); void upDate(const G4Step * step); void upDate(const EndOfEvent * evt);
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.