1 / 17

FULL CHAIN SIMULATION of CMS DETECTOR

FULL CHAIN SIMULATION of CMS DETECTOR. Ijaz Ahmed National centre for Physics, Islamabad. Simulation Components (OSCAR).

fisk
Download Presentation

FULL CHAIN SIMULATION of CMS DETECTOR

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. FULL CHAIN SIMULATIONof CMS DETECTOR Ijaz Ahmed National centre for Physics, Islamabad

  2. Simulation Components (OSCAR) • 􀂄 Primary Event • Physics event (e.g. H → ZZ → eemm for mH = 300 GeV/c2) • produced by an event generator: event production, decay tree, • kinematics • 􀂄 Detector Description • Materials, shapes, geometrical hierarchies and positions as well as • specific attributes (e.g. sensitive detector) of the CMS detectors; • description of the CMS magnetic field • 􀂄 Physics Processes • The physics interactions (transportation, decay, electromagnetic • and hadronic processes e.g. ionization, multiple scattering, • bremsstrahlung, inelastic processes etc) for all types of particles • (photons, electrons, muons, neutrinos, pions, kaons, protons, • neutrons etc) in the event • 􀂄 Particle tracking and propagation in the detector (in matter) and • magnetic field • 􀂄 User actions • Miscellaneous selection cuts, tracking parameters, specific actions • for tuning and monitoring a simulation application

  3. How to run OSCAR • OSCAR is managed by SCRAM; the current public OSCAR release • is OSCAR_3_3_0 • 􀂄 log on to a linux node • 􀂄 cd <a local scratch directory> • 􀂄 scram project OSCAR OSCAR_3_3_0 • to set up a local project area for OSCAR • 􀂄 cmscvsroot OSCAR • 􀂄 cvs login • password: 98passwd • 􀂄 cd OSCAR_3_3_0/src • 􀂄 cvs co –r OSCAR_3_3_0 Workspace • 􀂄 cd Workspace • 􀂄 eval `scram runtime –csh` • 􀂄 source writeTrigger.csh • 􀂄 oscar –c oscarrc Contains HEPEVT Ntuple address

  4. What is in a POOL File Catalog ?XML file that knows where all the data files are. PoolFileCatalog.xml needs to be in current directory (or have to specify location via InputFileCatalogURL parameter in orcarc)

  5. 1) Digitization: from Hits to Digis • 􀂾 Output of Simulation (OSCAR) are Hits • 􀂉 Position, where a particle entered a sensitive detector volume • 􀂉 Direction of the particle, Exit point of the particle • 􀂉 Energy deposited • 􀂉 (exact format depends on detector type) • 􀂾 ORCA simulates reaction of detectors to the passing particle • 􀂉 E.g. ionization of gas in drift tube muon chamber, drift of • particles to wire, avalanche, signal • 􀂉 Detector electronics (analog to digital conversion, data • compression, …) • 􀂉 Parameterizations of actual processes used • 􀂉 Also includes full emulation of Level-1 Trigger electronics • 􀂉 Result: Digis • 􀂃 Digis are like the raw data that will come out of the experiment!!!

  6. 1) Digitization: adding Pileup • At high LHC luminosity an average of 17 interactions • occur in the same bunch crossing • 􀂾 Detector response is slower than 25ns: also have to • consider interactions before and after • 􀃖 Overlay crossings -5 to +3 • 􀂾 ~200 “minimum bias” events added to • 1 signal event (before digitization) SimHits/Signal 1 ORCA Digitization Digis SimHits/minbias = 200

  7. 2) Reconstruction • 􀂾 ORCA does Reconstruction of Raw Detector Data (or the Digis) in • several steps • 1) Detector-specific processing • 􀂃 Data unpacking, cluster finding, hit reconstruction, tracking, • applying calibration constants • 2) Global Tracking • 􀂃 include hits from different subsystems, e.g. Tracker and Muon System for muons • 3) Vertex Finding • 􀂃 Bases on Tracks found in the previous step • 4) Particle Identification 􀃖 Physics Objects • 􀂃 Produce objects used in physics analyses: electrons, photons, muons, jets, … • 􀂾 Both Offline Reconstruction / and High-Level Trigger • reconstruction • 􀂉 Similar algorithms, but offline algorithms may consume more time, • may use more calibration constants, … • 􀂾 Can save output of reconstruction: DSTs (“Data Summary Tapes”)

  8. Creating a Working Area • 􀂾 login with your CMS account (group zh) • 􀂾 cd $SCRATCH • 􀂉 can also work on AFS workspace or AFS scratch • 􀂾 scram listcompact ORCA • […] • ORCA ORCA_8_2_0 /afs/cern.ch/cms/Releases/ORCA/ORCA_8_2_0 • 􀂾 scram project ORCA ORCA_8_2_0 • 􀂾 new directory ORCA_8_2_0 with subdirectories • src, config, tmp, logs • 􀂾 cd ORCA_8_2_0/src • 􀂾 eval `scram runtime –csh` • 􀂾 rehash • Ready to use pre-compiled executables • Set environment variables • Rebuild hash table of executables

  9. Standard Executables • ORCA can be used in many different ways • 􀂉 Data can be processed in steps ( Digitization, Reconstruction,… ) • 􀂉 Many different executables exist • 􀂃 Standard executables • 􀂃 Test executables • 􀂃 You can make your own executables (e.g. in Workspace) • 􀂾 Standard Executables from Examples/ExProduction • 􀂉 writeAllDigis (read hits, digitize, write digis) • 􀂉 writeDST (read digis, reconstruct, write DST)

  10. Example 1: from Hits to Digis • 􀂾 Log into CVS • 􀂉 cmscvsroot ORCA; cvs login (password: 98passwd) • 􀂾 Check out the code from CVS (in ORCA_8_2_0/src) • 􀂉 cvs co –r Summies04 Example/ExProduction • 􀂉 cd Examples/ExProduction • 􀂾 Set the parameters • 􀂉 writeAllDigis-Tutorial04.orcarc

  11. Setting Parameters: orcarc files writeAllDigis-Tutorial04.orcarc Attention: The file .orcarc in the current directory is always read and used. Specify any other orcarc file with the –c option.

  12. Analysis with ExRootAnalysis • This tutorial is dedicated to a ROOT-based analysis out of the CMS data samples stored in the POOL DB. • The tool is an ORCA application released under Examples/ExRootAnalysis. • The program can access any information stored in POOL (MC information, Digis and Reconstructed objects), process such information and store it in a ROOT tree. • The ROOT tree can then be analysed with ROOT • A number of examples will be carried out during the tutorial showing the main functionalities of the tool.

  13. >cd scratch0 >mkdir AnalysisTutorial >cd AnalysisTutorial Quick start with ExRootAnalysis To use ORCA under the SLC3 system we need to setup the SCRAM_ARCH environement variable: • for sh/ksh/bash >export SCRAM_ARCH=slc3_ia32_gcc323 • for csh/tcsh > setenv SCRAM_ARCH slc3_ia32_gcc323 • Setup a private ORCA project area: >scram project ORCA ORCA_8_7_2 • Configure CVS: >cmscvsroot ORCA >cvs login • Password for the anonymous CVS login: 98passwd • Now, we can get the code producing ROOT tree: >cd ORCA_8_7_2/src cvs co -rTutorial_872 Examples/ExRootAnalysis > cd Examples/ExRootAnalysis • Commands to compile the code: • for sh/ksh/bash >scram b; > eval `scram runtime -sh` • for csh/tcsh >scram b; >eval `scram runtime -csh` • Configure .orcarc (PoolCatalogFile, InputCollections, FirstEvent, MaxEvents): $EDITOR .orcarc

  14. Finally, we can run ExRootAnalysis: ExRootAnalysis • Finding DST samples • =================== ORCA test data samples: http://cmsdoc.cern.ch/orca/testdata.html • For example, here is one of those test samples: • InputFileCatalogURL = @{xmlcatalog_http://cmsdoc.cern.ch/orca/catalog/PoolFileCatalog_8_7_1.xml}@ InputCollections=/System/StW871DST2x1033/h300eemm/h300eemm • Script that lists all available DST samples and their location: >/afs/cern.ch/cms/oo/reconstruction/scripts/findDSTs • To find PoolCatalogFile and InputCollections run script with sample name as parameter: • /afs/cern.ch/cms/oo/reconstruction/scripts/findDSTs eg03c_HZZ4e_m150 • Create shared library for interactive ROOT session = • ================ Return back to ORCA_8_7_2/src and install Examples/ExRootAnalysisReader: >cd ../.. cvs co -rTutorial_872 Examples/ExRootAnalysisReader >cd Examples/ExRootAnalysisReader • Command to build shared library: > scram b • Simple analysis using TTree::Draw

  15. ========== Now we can start ROOT and look at the data stored on the tree Note 1: under SLC3 system use root.exe to run ROOT Note 2: ROOT automatically locates the shared library Start ROOT and load shared library: >cd ../../Examples/ExRootAnalysis >root.exe >gSystem->Load("libExRootAnalysisReader"); • Open ROOT tree file and do some basic analysis using Draw or TBrowser: >TFile::Open("test.root"); > Analysis->Draw("VtxPVF.Z"); >TBrowser browser; • Note 1: Analysis - tree name, it can be learnt e.g. from TBrowser • Note 2: VtxPVF - branch name; Z - variable (leaf) of this branch Complete description of all branches can be found in Examples/ExRootAnalysis/doc/RootTree.html • This file is also available via web based CVS interface: http://cmsdoc.cern.ch/swdev/viewcvs/viewcvs.cgi/*checkout*/ /ORCA/Examples/ExRootAnalysis/doc/RootTree.html Macro-based analysis

  16. ==================== Analysis macro consists of histogram booking, event loop (histogram filling), histogram display Basic analysis macro: • { // Load shared library >gSystem->Load("libExRootAnalysisReader"); // Create chain of root trees > TChain chain("Analysis"); > chain.Add("test.root"); // Create object of class ExRootTree > ExRootTree *tree = new ExRootTree(&chain); > Long64_t numberOfEntries = tree->GetEntries(); • // Get pointers to branches used in this analysis >TClonesArray *branchVtx = tree->UseBranch("VtxPVF", "TRootVertex"); >TClonesArray *branchJet = tree->UseBranch("JetIC5A", "TRootJet"); // Book histograms >TH1 *histVtxZ = new TH1F("histVtxZ", "vertex position", 50, -50.0, 50.0); // Loop over all events for(Int_t entry = 0; entry < numberOfEntries; ++entry) { // Load selected branches with data from specified event >tree->ReadEntry(entry); // If event contains at least 1 vertex > if(branchVtx->GetEntries() > 0) { // Take first vertex >TRootVertex *vtx = (TRootVertex*) branchVtx->At(0); // Plot vertex Z co-ordinate > histVtxZ->Fill(vtx->Z); > cout << vtx->Z << endl; } } // Show resulting histogram > histVtxZ->Draw(); } More advanced macro-based analysis ================================== ExRootAnalysisReader/test contains macro Example.C using class ExRootTree to access data and class ExRootResult to manage histograms booking and output Here are commands to run this macro: >cd ../../Examples/ExRootAnalysisReader/test • $EDITOR test.list >root.exe >gSystem->Load("libExRootAnalysisReader"); > .X Example.C("test.list") Note: file test.list should contain list of root files that you would like to analyse (one root file per line)

  17. 4 Vectors Produced by Monte Carlo and stored in Ntuple Produced by GEANT and stored in DB SimHits Include Pileup and stored in DB (Trk) Digis RecHits Reconstructed objects Tracks, clusters, jets, e/g RecObj

More Related