Changes in / [4a0d9d5:4406bf8] in git
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
Makefile
r4a0d9d5 r4406bf8 1362 1362 modules/RunPUPPI.$(SrcSuf) \ 1363 1363 modules/RunPUPPI.h \ 1364 external/PUPPI/RecoObj2.hh \ 1365 external/PUPPI/AlgoObj.hh \ 1364 external/PUPPI/puppiCleanContainer.hh \ 1365 external/PUPPI/RecoObj.hh \ 1366 external/PUPPI/puppiParticle.hh \ 1367 external/PUPPI/puppiAlgoBin.hh \ 1366 1368 classes/DelphesClasses.h \ 1367 1369 classes/DelphesFactory.h \ … … 1799 1801 1800 1802 modules/RunPUPPI.h: \ 1801 classes/DelphesModule.h \ 1802 external/PUPPI/PuppiContainer.hh 1803 classes/DelphesModule.h 1803 1804 @touch $@ 1804 1805 … … 1932 1933 external/fastjet/AreaDefinition.hh \ 1933 1934 external/fastjet/ClusterSequenceAreaBase.hh 1935 @touch $@ 1936 1937 external/PUPPI/puppiCleanContainer.hh: \ 1938 external/PUPPI/RecoObj.hh \ 1939 external/PUPPI/puppiParticle.hh \ 1940 external/PUPPI/puppiAlgoBin.hh \ 1941 external/fastjet/internal/base.hh \ 1942 external/fastjet/PseudoJet.hh 1934 1943 @touch $@ 1935 1944 -
cards/CMS_PhaseII/CMS_PhaseII_200PU.tcl
r4a0d9d5 r4406bf8 1 set MaxEvents 102 3 1 # 4 2 # Phase II - Pile-Up 5 3 # 6 4 # Main authors: Michele Selvaggi (UCL) 7 # 8 # Released on: 5 # 6 # Released on: 9 7 # 10 8 # Version: v01 … … 16 14 17 15 set ExecutionPath { 18 19 PileUpMerger 16 17 PileUpMerger 18 20 19 ParticlePropagator 21 20 … … 29 28 30 29 TrackMerger 31 30 32 31 ECal 33 32 HCal … … 35 34 ElectronFilter 36 35 TrackPileUpSubtractor 37 36 38 37 TowerMerger 39 38 NeutralEFlowMerger … … 41 40 EFlowMerger 42 41 43 LeptonFilterNoLep44 LeptonFilterLep45 RunPUPPIBase46 42 RunPUPPI 47 48 PhotonFilter49 43 50 44 PhotonIsolation 51 45 PhotonEfficiency 52 46 53 47 ElectronIsolation 54 48 ElectronEfficiency 55 49 56 50 MuonIsolation 57 51 MuonLooseIdEfficiency 58 52 MuonTightIdEfficiency 59 53 60 54 NeutrinoFilter 61 55 62 56 MissingET 63 PuppiMissingET64 57 GenMissingET 65 58 GenPileUpMissingET … … 69 62 70 63 ScalarHT 71 64 72 65 JetEnergyScale 73 66 … … 79 72 80 73 TauTagging 81 74 82 75 GenParticleFilter 83 76 84 77 TreeWriter 85 78 } … … 98 91 99 92 # pre-generated minbias input file 100 set PileUpFile ../eos/cms/store/group/upgrade/delphes/PhaseII/MinBias_100k.pileup 93 set PileUpFile ../eos/cms/store/group/upgrade/delphes/PhaseII/MinBias_100k.pileup 101 94 102 95 # average expected pile up 103 96 set MeanPileUp 200 104 97 105 98 # maximum spread in the beam direction in m 106 set ZVertexSpread 0. 2599 set ZVertexSpread 0.15 107 100 108 101 # maximum spread in time in s 109 set TVertexSpread 800E-12102 set TVertexSpread 1.5E-09 110 103 111 104 # vertex smearing formula f(z,t) (z,t need to be respectively given in m,s) 112 set VertexDistributionFormula {exp(-(t^2/160e-12^2/2))*exp(-(z^2/0.053^2/2))} 105 106 #set VertexDistributionFormula {exp(-(t^2/(2*(0.05/2.99792458E8*exp(-(z^2/(2*(0.05)^2))))^2)))} 107 108 109 set VertexDistributionFormula { (abs(t) <= 1.0e-09) * (abs(z) <= 0.15) * (1.00) + 110 (abs(t) > 1.0e-09) * (abs(z) <= 0.15) * (0.00) + 111 (abs(t) <= 1.0e-09) * (abs(z) > 0.15) * (0.00) + 112 (abs(t) > 1.0e-09) * (abs(z) > 0.15) * (0.00)} 113 113 114 114 } … … 167 167 set OutputArray electrons 168 168 # tracking efficiency formula for electrons 169 set EfficiencyFormula { 169 set EfficiencyFormula { 170 170 (pt <= 0.2) * (0.00) + \ 171 171 (abs(eta) <= 1.2) * (pt > 0.2 && pt <= 1.0) * (pt * 0.96) + \ … … 199 199 (abs(eta) > 2.8 && abs(eta) <= 4.0) * (pt > 1.0) * (0.95) + \ 200 200 (abs(eta) > 4.0) * (0.00) 201 201 202 202 } 203 203 } … … 212 212 set InputArray ChargedHadronTrackingEfficiency/chargedHadrons 213 213 set OutputArray chargedHadrons 214 # resolution formula for charged hadrons , 215 214 # resolution formula for charged hadrons , 215 216 216 # from http://mersi.web.cern.ch/mersi/layouts/.private/Baseline_tilted_200_Pixel_1_1_1/index.html 217 217 source trackMomentumResolution.tcl … … 229 229 230 230 # resolution formula for electrons 231 231 232 232 # taking something flat in energy for now, ECAL will take over at high energy anyway. 233 233 # inferred from hep-ex/1306.2016 and 1502.02701 234 set ResolutionFormula { 235 234 set ResolutionFormula { 235 236 236 (abs(eta) <= 1.5) * (1+0.64*abs(eta)^2)*(energy*0.028) + 237 237 (abs(eta) > 1.5 && abs(eta) <= 1.75) * (energy*0.037) + 238 238 (abs(eta) > 1.75 && abs(eta) <= 2.15) * (energy*0.038) + 239 239 (abs(eta) > 2.15 && abs(eta) <= 3.00) * (energy*0.044) + 240 (abs(eta) > 3.00 && abs(eta) <= 4.00) * (energy*0.10)} 240 (abs(eta) > 3.00 && abs(eta) <= 4.00) * (energy*0.10)} 241 241 242 242 } … … 250 250 set OutputArray muons 251 251 # resolution formula for muons 252 253 # up to |eta| < 2.8 take measurement from tracking + muon chambers 254 # for |eta| > 2.8 and pT < 5.0 take measurement from tracking alone taken from 252 253 # up to |eta| < 2.8 take measurement from tracking + muon chambers 254 # for |eta| > 2.8 and pT < 5.0 take measurement from tracking alone taken from 255 255 # http://mersi.web.cern.ch/mersi/layouts/.private/Baseline_tilted_200_Pixel_1_1_1/index.html 256 source muonMomentumResolution.tcl 256 source muonMomentumResolution.tcl 257 257 } 258 258 … … 284 284 set EFlowTowerOutputArray eflowPhotons 285 285 286 set IsEcal true 287 286 set IsEcal true 287 288 288 set EnergyMin 0.5 289 289 set EnergySignificanceMin 1.0 … … 298 298 299 299 # assume 0.02 x 0.02 resolution in eta,phi in the barrel |eta| < 1.5 300 300 301 301 set PhiBins {} 302 302 for {set i -180} {$i <= 180} {incr i} { … … 311 311 312 312 # assume 0.02 x 0.02 resolution in eta,phi in the endcaps 1.5 < |eta| < 3.0 (HGCAL- ECAL) 313 313 314 314 set PhiBins {} 315 315 for {set i -180} {$i <= 180} {incr i} { … … 328 328 } 329 329 330 # take present CMS granularity for HF 331 330 # take present CMS granularity for HF 331 332 332 # 0.175 x (0.175 - 0.35) resolution in eta,phi in the HF 3.0 < |eta| < 5.0 333 333 set PhiBins {} … … 335 335 add PhiBins [expr {$i * $pi/18.0}] 336 336 } 337 337 338 338 foreach eta {-5 -4.7 -4.525 -4.35 -4.175 -4 -3.825 -3.65 -3.475 -3.3 -3.125 -2.958 3.125 3.3 3.475 3.65 3.825 4 4.175 4.35 4.525 4.7 5} { 339 339 add EtaPhiBins $eta $PhiBins … … 361 361 362 362 # set ResolutionFormula {resolution formula as a function of eta and energy} 363 363 364 364 # for the ECAL barrel (|eta| < 1.5), see hep-ex/1306.2016 and 1502.02701 365 365 # for the endcaps (1.5 < |eta| < 3.0), we take HGCAL see LHCC-P-008, Fig. 3.39, p.117 366 366 367 set ResolutionFormula { (abs(eta) <= 1.50) * (1+0.64*abs(eta)^2)*sqrt(energy^2*0.009^2 + energy*0.12^2 + 0.45^2) + 367 set ResolutionFormula { (abs(eta) <= 1.50) * (1+0.64*abs(eta)^2)*sqrt(energy^2*0.009^2 + energy*0.12^2 + 0.45^2) + 368 368 (abs(eta) > 1.50 && abs(eta) <= 1.75) * sqrt(energy^2*0.006^2 + energy*0.20^2) + \ 369 369 (abs(eta) > 1.75 && abs(eta) <= 2.15) * sqrt(energy^2*0.007^2 + energy*0.21^2) + \ … … 385 385 set EFlowTowerOutputArray eflowNeutralHadrons 386 386 387 set IsEcal false 388 387 set IsEcal false 388 389 389 set EnergyMin 1.0 390 390 set EnergySignificanceMin 1.0 … … 397 397 # each list starts with the lower edge of the first tower 398 398 # the list ends with the higher edged of the last tower 399 399 400 400 # assume 0.087 x 0.087 resolution in eta,phi in the barrel |eta| < 1.5 401 401 … … 409 409 410 410 # assume 0.02 x 0.02 resolution in eta,phi in the endcaps 1.5 < |eta| < 3.0 (HGCAL- HCAL) 411 411 412 412 set PhiBins {} 413 413 for {set i -180} {$i <= 180} {incr i} { … … 426 426 } 427 427 428 # take present CMS granularity for HF 429 428 # take present CMS granularity for HF 429 430 430 # 0.175 x (0.175 - 0.35) resolution in eta,phi in the HF 3.0 < |eta| < 5.0 431 431 set PhiBins {} … … 433 433 add PhiBins [expr {$i * $pi/18.0}] 434 434 } 435 435 436 436 foreach eta {-5 -4.7 -4.525 -4.35 -4.175 -4 -3.825 -3.65 -3.475 -3.3 -3.125 -2.958 3.125 3.3 3.475 3.65 3.825 4 4.175 4.35 4.525 4.7 5} { 437 437 add EtaPhiBins $eta $PhiBins … … 478 478 } 479 479 480 481 480 ########################## 482 481 # Track pile-up subtractor … … 548 547 ######################################### 549 548 550 module PdgCodeFilter LeptonFilterNoLep { 551 set InputArray HCal/eflowTracks 552 set OutputArray eflowTracksNoLeptons 553 set Invert false 554 add PdgCode {13} 555 add PdgCode {-13} 556 add PdgCode {11} 557 add PdgCode {-11} 558 } 559 560 module PdgCodeFilter LeptonFilterLep { 561 set InputArray HCal/eflowTracks 562 set OutputArray eflowTracksLeptons 563 set Invert true 564 add PdgCode {11} 565 add PdgCode {-11} 566 add PdgCode {13} 567 add PdgCode {-13} 568 } 569 570 module RunPUPPI RunPUPPIBase { 549 module RunPUPPI RunPUPPI { 571 550 ## input information 572 set TrackInputArray LeptonFilterNoLep/eflowTracksNoLeptons551 set TrackInputArray TrackMerger/tracks 573 552 set NeutralInputArray NeutralEFlowMerger/eflowTowers 574 553 set PVInputArray PileUpMerger/vertices 575 554 set MinPuppiWeight 0.05 576 555 set UseExp false 577 set UseNoLep false 578 579 ## define puppi algorithm parameters (more than one for the same eta region is possible) 580 add EtaMinBin 0.0 1.5 4.0 581 add EtaMaxBin 1.5 4.0 10.0 582 add PtMinBin 0.0 0.0 0.0 583 add ConeSizeBin 0.2 0.2 0.2 584 add RMSPtMinBin 0.1 0.5 0.5 585 add RMSScaleFactorBin 1.0 1.0 1.0 586 add NeutralMinEBin 0.2 0.2 0.5 587 add NeutralPtSlope 0.006 0.013 0.067 588 add ApplyCHS true true true 589 add UseCharged true true false 590 add ApplyLowPUCorr true true true 591 add MetricId 5 5 5 592 add CombId 0 0 0 556 557 ## define puppi algorithm parameters (more than one for the same eta region is possible) 558 add EtaMinBin 0. 2.5 2.5 3.0 3.0 559 add EtaMaxBin 2.5 3.0 3.0 10.0 10.0 560 add PtMinBin 0. 0.5 0.5 0.5 0.5 561 add ConeSizeBin 0.25 0.25 0.25 0.25 0.25 562 add RMSPtMinBin 0.1 0.5 0.5 0.5 0.5 563 add RMSScaleFactorBin 1.0 1.0 1.0 1.0 1.0 564 add NeutralMinEBin 0.2 1.0 1.0 1.5 1.5 565 add NeutralPtSlope 0.02 0.02 0.02 0.02 0.02 566 add ApplyCHS true true true true true 567 add UseCharged true false false false false 568 add ApplyLowPUCorr true true true true true 569 add MetricId 5 5 1 5 1 593 570 594 571 ## output name … … 596 573 set OutputArrayTracks puppiTracks 597 574 set OutputArrayNeutrals puppiNeutrals 598 } 599 600 module Merger RunPUPPI { 601 add InputArray RunPUPPIBase/PuppiParticles 602 add InputArray LeptonFilterLep/eflowTracksLeptons 603 set OutputArray PuppiParticles 604 } 575 } 576 577 605 578 606 579 ################### … … 615 588 } 616 589 617 module Merger PuppiMissingET {618 #add InputArray InputArray619 add InputArray RunPUPPI/PuppiParticles620 #add InputArray EFlowMerger/eflow621 set MomentumOutputArray momentum622 }623 624 590 ################### 625 # Ger PileUp Missing ET 591 # Ger PileUp Missing ET 626 592 ################### 627 593 … … 670 636 module FastJetFinder GenJetFinder { 671 637 set InputArray NeutrinoFilter/filteredParticles 672 638 673 639 set OutputArray jets 674 640 … … 723 689 724 690 725 #################726 # Photon filter727 #################728 729 module PdgCodeFilter PhotonFilter {730 set InputArray ECal/eflowPhotons731 set OutputArray photons732 set Invert true733 set PTMin 5.0734 add PdgCode {22}735 }736 737 738 691 #################### 739 692 # Photon isolation # … … 741 694 742 695 module Isolation PhotonIsolation { 743 696 744 697 # particle for which calculate the isolation 745 set CandidateInputArray PhotonFilter/photons746 698 set CandidateInputArray ECal/eflowPhotons 699 747 700 # isolation collection 748 set IsolationInputArray RunPUPPI/PuppiParticles749 701 set IsolationInputArray EFlowMerger/eflow 702 750 703 # output array 751 704 set OutputArray photons 752 753 # veto isolation cand. based on proximity to input cand. 754 set DeltaRMin 0.01 755 set UseMiniCone true 756 705 757 706 # isolation cone 758 707 set DeltaRMax 0.3 759 760 # minimum pT 708 709 # minimum pT 761 710 set PTMin 1.0 762 711 763 712 # iso ratio to cut 764 713 set PTRatioMax 9999. 765 766 714 } 767 715 … … 773 721 774 722 module Efficiency PhotonEfficiency { 775 723 776 724 ## input particles 777 set InputArray PhotonIsolation/photons 725 set InputArray PhotonIsolation/photons 778 726 ## output particles 779 727 set OutputArray photons … … 793 741 794 742 module Isolation ElectronIsolation { 795 743 796 744 set CandidateInputArray ElectronFilter/electrons 797 745 798 746 # isolation collection 799 set IsolationInputArray RunPUPPI/PuppiParticles 800 #set IsolationInputArray EFlowMerger/eflow 801 747 set IsolationInputArray EFlowMerger/eflow 748 802 749 set OutputArray electrons 803 750 804 751 set DeltaRMax 0.3 805 752 set PTMin 1.0 … … 815 762 816 763 module Efficiency ElectronEfficiency { 817 764 818 765 set InputArray ElectronIsolation/electrons 819 766 set OutputArray electrons 820 767 821 768 # set EfficiencyFormula {efficiency formula as a function of eta and pt} 822 769 # efficiency formula for electrons … … 826 773 (abs(eta) <= 1.45 ) * (pt > 6.0 && pt <= 8.0) * (0.70) + \ 827 774 (abs(eta) <= 1.45 ) * (pt > 8.0 && pt <= 10.0) * (0.85) + \ 828 (abs(eta) <= 1.45 ) * (pt > 10.0 && pt <= 30.0) * (0.94) + \ 829 (abs(eta) <= 1.45 ) * (pt > 30.0 && pt <= 50.0) * (0.97) + \ 830 (abs(eta) <= 1.45 ) * (pt > 50.0 && pt <= 70.0) * (0.98) + \ 831 (abs(eta) <= 1.45 ) * (pt > 70.0 ) * (1.0) + \ 775 (abs(eta) <= 1.45 ) * (pt > 10.0 && pt <= 30.0) * (0.94) + \ 776 (abs(eta) <= 1.45 ) * (pt > 30.0 && pt <= 50.0) * (0.97) + \ 777 (abs(eta) <= 1.45 ) * (pt > 50.0 && pt <= 70.0) * (0.98) + \ 778 (abs(eta) <= 1.45 ) * (pt > 70.0 ) * (1.0) + \ 832 779 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 4.0 && pt <= 10.0) * (0.35) + \ 833 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 10.0 && pt <= 30.0) * (0.40) + \ 834 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 30.0 && pt <= 70.0) * (0.45) + \ 835 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 70.0 ) * (0.55) + \ 780 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 10.0 && pt <= 30.0) * (0.40) + \ 781 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 30.0 && pt <= 70.0) * (0.45) + \ 782 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 70.0 ) * (0.55) + \ 836 783 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 4.0 && pt <= 10.0) * (0.75) + \ 837 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 10.0 && pt <= 30.0) * (0.85) + \ 838 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 30.0 && pt <= 50.0) * (0.95) + \ 839 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 50.0 && pt <= 70.0) * (0.95) + \ 840 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 70.0 ) * (1.0) + \ 784 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 10.0 && pt <= 30.0) * (0.85) + \ 785 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 30.0 && pt <= 50.0) * (0.95) + \ 786 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 50.0 && pt <= 70.0) * (0.95) + \ 787 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 70.0 ) * (1.0) + \ 841 788 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 4.0 && pt <= 10.0) * (0.65) + \ 842 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 10.0 && pt <= 30.0) * (0.75) + \ 843 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 30.0 && pt <= 50.0) * (0.90) + \ 844 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 50.0 && pt <= 70.0) * (0.90) + \ 845 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 70.0 ) * (0.90) + \ 789 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 10.0 && pt <= 30.0) * (0.75) + \ 790 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 30.0 && pt <= 50.0) * (0.90) + \ 791 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 50.0 && pt <= 70.0) * (0.90) + \ 792 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 70.0 ) * (0.90) + \ 846 793 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 4.0 && pt <= 10.0) * (0.65) + \ 847 794 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 10.0 && pt <= 30.0) * (0.75) + \ … … 850 797 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 70.0 ) * (0.90) + \ 851 798 (abs(eta) > 4.0) * (0.00) 852 799 853 800 } 854 801 } … … 860 807 module Isolation MuonIsolation { 861 808 set CandidateInputArray MuonMomentumSmearing/muons 862 809 863 810 # isolation collection 864 set IsolationInputArray RunPUPPI/PuppiParticles865 811 set IsolationInputArray EFlowMerger/eflow 812 866 813 set OutputArray muons 867 814 868 815 set DeltaRMax 0.3 869 816 set PTMin 1.0 … … 938 885 939 886 set BitNumber 1 940 887 941 888 source btagMedium.tcl 942 889 } 943 890 891 944 892 945 893 ############# … … 952 900 set BitNumber 2 953 901 954 source btagTight.tcl 955 } 902 source btagTight.tcl 903 } 904 905 906 956 907 957 908 … … 979 930 add EfficiencyFormula {15} { (abs(eta) < 2.3) * 0.97*0.77*( (0.32 + 0.01*pt - 0.000054*pt*pt )*(pt<100)+0.78*(pt>100) ) + \ 980 931 (abs(eta) > 2.3) * (0.000) 981 } 932 } 982 933 } 983 934 … … 988 939 989 940 module StatusPidFilter GenParticleFilter { 990 941 991 942 set InputArray Delphes/allParticles 992 943 set OutputArray filteredParticles 993 944 set PTMin 5.0 994 945 995 946 } 996 947 … … 1004 955 add Branch GenParticleFilter/filteredParticles Particle GenParticle 1005 956 add Branch PileUpMerger/vertices Vertex Vertex 1006 957 1007 958 add Branch GenJetFinder/jets GenJet Jet 1008 959 add Branch GenMissingET/momentum GenMissingET MissingET … … 1011 962 # add Branch ECal/eflowPhotons EFlowPhoton Tower 1012 963 # add Branch HCal/eflowNeutralHadrons EFlowNeutralHadron Tower 1013 964 1014 965 add Branch PhotonEfficiency/photons Photon Photon 1015 966 add Branch ElectronEfficiency/electrons Electron Electron 1016 967 add Branch MuonLooseIdEfficiency/muons MuonLoose Muon 1017 968 add Branch MuonTightIdEfficiency/muons MuonTight Muon 1018 969 1019 970 add Branch JetEnergyScale/jets Jet Jet 1020 971 1021 972 add Branch MissingET/momentum MissingET MissingET 1022 add Branch PuppiMissingET/momentum PuppiMissingET MissingET1023 973 add Branch GenPileUpMissingET/momentum GenPileUpMissingET MissingET 1024 974 add Branch ScalarHT/energy ScalarHT ScalarHT -
cards/delphes_card_CMS.tcl
r4a0d9d5 r4406bf8 271 271 # Eta shape from arXiv:1306.2016, Energy shape from arXiv:1502.02701 272 272 set ECalResolutionFormula { (abs(eta) <= 1.5) * (1+0.64*eta^2) * sqrt(energy^2*0.008^2 + energy*0.11^2 + 0.40^2) + 273 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (2.16 + 5.6*( abs(eta)-2)^2) * sqrt(energy^2*0.008^2 + energy*0.11^2 + 0.40^2) +273 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (2.16 + 5.6*(eta-2)^2) * sqrt(energy^2*0.008^2 + energy*0.11^2 + 0.40^2) + 274 274 (abs(eta) > 2.5 && abs(eta) <= 5.0) * sqrt(energy^2*0.107^2 + energy*2.08^2)} 275 275 -
modules/Calorimeter.cc
r4a0d9d5 r4406bf8 625 625 tower->Eem = ecalEnergy; 626 626 tower->Ehad = 0.0; 627 tower->PID = 22;628 627 629 628 fEFlowPhotonOutputArray->Add(tower); -
modules/Isolation.cc
r4a0d9d5 r4406bf8 110 110 111 111 fUseRhoCorrection = GetBool("UseRhoCorrection", true); 112 113 fDeltaRMin = GetDouble("DeltaRMin", 0.01);114 fUseMiniCone = GetBool("UseMiniCone", false);115 112 116 113 fClassifier->fPTMin = GetDouble("PTMin", 0.5); … … 160 157 Double_t sumChargedNoPU, sumChargedPU, sumNeutral, sumAllParticles; 161 158 Double_t sumDBeta, ratioDBeta, sumRhoCorr, ratioRhoCorr, sum, ratio; 162 Bool_t pass = kFALSE;159 Int_t counter; 163 160 Double_t eta = 0.0; 164 161 Double_t rho = 0.0; … … 200 197 sumAllParticles = 0.0; 201 198 199 counter = 0; 202 200 itIsolationArray.Reset(); 201 203 202 while((isolation = static_cast<Candidate*>(itIsolationArray.Next()))) 204 203 { 205 204 const TLorentzVector &isolationMomentum = isolation->Momentum; 206 205 207 if(fUseMiniCone) 206 if(candidateMomentum.DeltaR(isolationMomentum) <= fDeltaRMax && 207 candidate->GetUniqueID() != isolation->GetUniqueID()) 208 208 { 209 pass = candidateMomentum.DeltaR(isolationMomentum) <= fDeltaRMax &&210 candidateMomentum.DeltaR(isolationMomentum) > fDeltaRMin;211 }212 else213 {214 pass = candidateMomentum.DeltaR(isolationMomentum) <= fDeltaRMax &&215 candidate->GetUniqueID() != isolation->GetUniqueID();216 }217 218 if(pass)219 {220 221 209 sumAllParticles += isolationMomentum.Pt(); 222 210 if(isolation->Charge != 0) … … 235 223 sumNeutral += isolationMomentum.Pt(); 236 224 } 225 ++counter; 237 226 } 238 239 227 } 240 228 241 // find rho229 // find rho 242 230 rho = 0.0; 243 231 if(fRhoInputArray) … … 253 241 } 254 242 255 256 257 243 // correct sum for pile-up contamination 258 244 sumDBeta = sumChargedNoPU + TMath::Max(sumNeutral - 0.5*sumChargedPU, 0.0); -
modules/Isolation.h
r4a0d9d5 r4406bf8 57 57 Double_t fPTSumMax; 58 58 59 Double_t fDeltaRMin;60 61 59 Bool_t fUsePTSum; 62 60 63 61 Bool_t fUseRhoCorrection; 64 65 Bool_t fUseMiniCone;66 62 67 63 IsolationClassifier *fClassifier; //! -
modules/RunPUPPI.cc
r4a0d9d5 r4406bf8 1 1 #include "modules/RunPUPPI.h" 2 2 3 #include "PUPPI/ RecoObj2.hh"4 #include "PUPPI/ AlgoObj.hh"5 //#include "PUPPI/puppiParticle.hh"6 //#include "PUPPI/puppiAlgoBin.hh"3 #include "PUPPI/puppiCleanContainer.hh" 4 #include "PUPPI/RecoObj.hh" 5 #include "PUPPI/puppiParticle.hh" 6 #include "PUPPI/puppiAlgoBin.hh" 7 7 8 8 #include "classes/DelphesClasses.h" … … 30 30 31 31 void RunPUPPI::Init(){ 32 32 33 // input collection 33 34 fTrackInputArray = ImportArray(GetString("TrackInputArray", "Calorimeter/towers")); … … 37 38 fPVInputArray = ImportArray(GetString("PVInputArray", "PV")); 38 39 fPVItInputArray = fPVInputArray->MakeIterator(); 39 // puppi parameters 40 fApplyNoLep = GetBool("UseNoLep", true); 40 41 42 // puppi parameters 41 43 fMinPuppiWeight = GetDouble("MinPuppiWeight", 0.01); 42 44 fUseExp = GetBool("UseExp", false); 43 // read eta min ranges 45 46 // read eta min ranges 44 47 ExRootConfParam param = GetParam("EtaMinBin"); 45 48 fEtaMinBin.clear(); 46 49 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fEtaMinBin.push_back(param[iMap].GetDouble()); 47 // read eta max ranges 50 51 // read eta max ranges 48 52 param = GetParam("EtaMaxBin"); 49 53 fEtaMaxBin.clear(); 50 54 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fEtaMaxBin.push_back(param[iMap].GetDouble()); 51 // read pt min value 55 56 // read pt min value 52 57 param = GetParam("PtMinBin"); 53 58 fPtMinBin.clear(); 54 59 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fPtMinBin.push_back(param[iMap].GetDouble()); 60 55 61 // read cone size 56 62 param = GetParam("ConeSizeBin"); 57 63 fConeSizeBin.clear(); 58 64 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fConeSizeBin.push_back(param[iMap].GetDouble()); 65 59 66 // read RMS min pt 60 67 param = GetParam("RMSPtMinBin"); 61 68 fRMSPtMinBin.clear(); 62 69 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fRMSPtMinBin.push_back(param[iMap].GetDouble()); 63 // read RMS scale factor 70 71 // read RMS scale factor 64 72 param = GetParam("RMSScaleFactorBin"); 65 73 fRMSScaleFactorBin.clear(); 66 74 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fRMSScaleFactorBin.push_back(param[iMap].GetDouble()); 67 // read neutral pt min cut 75 76 // read neutral pt min cut 68 77 param = GetParam("NeutralMinEBin"); 69 78 fNeutralMinEBin.clear(); 70 79 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fNeutralMinEBin.push_back(param[iMap].GetDouble()); 71 // read neutral pt min slope 80 81 // read neutral pt min slope 72 82 param = GetParam("NeutralPtSlope"); 73 83 fNeutralPtSlope.clear(); 74 84 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fNeutralPtSlope.push_back(param[iMap].GetDouble()); 85 75 86 // read apply chs 76 //param = GetParam("ApplyCHS"); 77 //fApplyCHS.clear(); 78 //for(int iMap = 0; iMap < param.GetSize(); ++iMap) fApplyCHS.push_back(param[iMap].GetBool()); 79 // read use charged 87 param = GetParam("ApplyCHS"); 88 fApplyCHS.clear(); 89 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fApplyCHS.push_back(param[iMap].GetBool()); 90 91 // read use charged 80 92 param = GetParam("UseCharged"); 81 93 fUseCharged.clear(); 82 94 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fUseCharged.push_back(param[iMap].GetBool()); 83 // read apply chs correction 95 96 // read apply chs correction 84 97 param = GetParam("ApplyLowPUCorr"); 85 98 fApplyLowPUCorr.clear(); 86 99 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fApplyLowPUCorr.push_back(param[iMap].GetBool()); 100 87 101 // read metric id 88 102 param = GetParam("MetricId"); 89 103 fMetricId.clear(); 90 104 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fMetricId.push_back(param[iMap].GetInt()); 91 // scheme for combining 92 param = GetParam("CombId"); 93 fCombId.clear(); 94 for(int iMap = 0; iMap < param.GetSize(); ++iMap) fCombId.push_back(param[iMap].GetInt()); 105 95 106 // create output array 96 107 fOutputArray = ExportArray(GetString("OutputArray", "puppiParticles")); 97 108 fOutputTrackArray = ExportArray(GetString("OutputArrayTracks", "puppiTracks")); 98 109 fOutputNeutralArray = ExportArray(GetString("OutputArrayNeutrals", "puppiNeutrals")); 99 // Create algorithm list for puppi100 std::vector<AlgoObj> puppiAlgo;101 if(puppiAlgo.empty()){102 if(!(fEtaMinBin.size() == fEtaMaxBin.size() and fEtaMinBin.size() == fPtMinBin.size() and fEtaMinBin.size() == fConeSizeBin.size() and fEtaMinBin.size() == fRMSPtMinBin.size()103 and fEtaMinBin.size() == fRMSScaleFactorBin.size() and fEtaMinBin.size() == fNeutralMinEBin.size() and fEtaMinBin.size() == fNeutralPtSlope.size()104 and fEtaMinBin.size() == fUseCharged.size()105 and fEtaMinBin.size() == fApplyLowPUCorr.size() and fEtaMinBin.size() == fMetricId.size())) {106 std::cerr<<" Error in PUPPI configuration, algo info should have the same size --> exit from the code"<<std::endl;107 std::exit(EXIT_FAILURE);108 }109 }110 for( size_t iAlgo = 0 ; iAlgo < fEtaMinBin.size() ; iAlgo++){111 AlgoObj algoTmp ;112 algoTmp.etaMin = fEtaMinBin.at(iAlgo);113 algoTmp.etaMax = fEtaMaxBin.at(iAlgo);114 algoTmp.ptMin = fPtMinBin.at(iAlgo);115 algoTmp.minNeutralPt = fNeutralMinEBin.at(iAlgo);116 algoTmp.minNeutralPtSlope = fNeutralPtSlope.at(iAlgo);117 //Eta Extrapolation stuff is missing118 //Loop through file requiring algos for same bins to be adjacent119 while(iAlgo < fEtaMinBin.size() and algoTmp.etaMin == fEtaMinBin.at(iAlgo) and algoTmp.etaMax == fEtaMaxBin.at(iAlgo)) {120 AlgoSubObj algoSubTmp;121 algoSubTmp.metricId = fMetricId.at(iAlgo);122 algoSubTmp.useCharged = fUseCharged.at(iAlgo);123 algoSubTmp.applyLowPUCorr = fApplyLowPUCorr.at(iAlgo);124 algoSubTmp.combId = fCombId.at(iAlgo);125 algoSubTmp.coneSize = fConeSizeBin.at(iAlgo);126 algoSubTmp.rmsPtMin = fRMSPtMinBin.at(iAlgo);127 algoSubTmp.rmsScaleFactor = fRMSScaleFactorBin.at(iAlgo);128 algoTmp.subAlgos.push_back(algoSubTmp);129 iAlgo++;130 }131 iAlgo--;132 //if(std::find(puppiAlgo.begin(),puppiAlgo.end(),algoTmp) != puppiAlgo.end()) continue;133 puppiAlgo.push_back(algoTmp);134 }135 fPuppi = new PuppiContainer(true,fUseExp,fMinPuppiWeight,puppiAlgo);136 110 } 137 111 … … 150 124 TLorentzVector momentum; 151 125 152 //DelphesFactory *factory = GetFactory();126 DelphesFactory *factory = GetFactory(); 153 127 154 128 // loop over input objects 155 fItTrackInputArray 156 fItNeutralInputArray 157 fPVItInputArray 129 fItTrackInputArray->Reset(); 130 fItNeutralInputArray->Reset(); 131 fPVItInputArray->Reset(); 158 132 159 133 std::vector<Candidate *> InputParticles; … … 168 142 std::vector<RecoObj> puppiInputVector; 169 143 puppiInputVector.clear(); 170 int lNBad = 0; 144 171 145 // Loop on charge track candidate 172 146 while((candidate = static_cast<Candidate*>(fItTrackInputArray->Next()))){ 147 173 148 momentum = candidate->Momentum; 149 174 150 RecoObj curRecoObj; 175 151 curRecoObj.pt = momentum.Pt(); … … 178 154 curRecoObj.m = momentum.M(); 179 155 particle = static_cast<Candidate*>(candidate->GetCandidates()->Last()); 180 //if(fApplyNoLep && TMath::Abs(candidate->PID) == 11) continue; //Dumb cut to minimize the nolepton on electron181 //if(fApplyNoLep && TMath::Abs(candidate->PID) == 13) continue;182 156 if (candidate->IsRecoPU and candidate->Charge !=0) { // if it comes fromPU vertexes after the resolution smearing and the dZ matching within resolution 183 lNBad++;184 157 curRecoObj.id = 2; 185 curRecoObj.vtxId = 0.7*(fPVInputArray->GetEntries()); //Hack apply reco vtx efficiency of 70% for calibration158 curRecoObj.vtxId = candidate->IsPU; 186 159 if(TMath::Abs(candidate->PID) == 11) curRecoObj.pfType = 2; 187 160 else if(TMath::Abs(candidate->PID) == 13) curRecoObj.pfType = 3; … … 210 183 // Loop on neutral calo cells 211 184 while((candidate = static_cast<Candidate*>(fItNeutralInputArray->Next()))){ 185 212 186 momentum = candidate->Momentum; 187 213 188 RecoObj curRecoObj; 214 189 curRecoObj.pt = momentum.Pt(); … … 216 191 curRecoObj.phi = momentum.Phi(); 217 192 curRecoObj.m = momentum.M(); 218 curRecoObj.charge = 0;219 193 particle = static_cast<Candidate*>(candidate->GetCandidates()->Last()); 194 220 195 221 196 if(candidate->Charge == 0){ … … 235 210 InputParticles.push_back(candidate); 236 211 } 212 213 // Create algorithm list for puppi 214 std::vector<puppiAlgoBin> puppiAlgo; 215 if(puppiAlgo.empty()){ 216 if(!(fEtaMinBin.size() == fEtaMaxBin.size() and fEtaMinBin.size() == fPtMinBin.size() and fEtaMinBin.size() == fConeSizeBin.size() and fEtaMinBin.size() == fRMSPtMinBin.size() 217 and fEtaMinBin.size() == fRMSScaleFactorBin.size() and fEtaMinBin.size() == fNeutralMinEBin.size() and fEtaMinBin.size() == fNeutralPtSlope.size() 218 and fEtaMinBin.size() == fApplyCHS.size() and fEtaMinBin.size() == fUseCharged.size() 219 and fEtaMinBin.size() == fApplyLowPUCorr.size() and fEtaMinBin.size() == fMetricId.size())) { 220 std::cerr<<" Error in PUPPI configuration, algo info should have the same size --> exit from the code"<<std::endl; 221 std::exit(EXIT_FAILURE); 222 } 223 224 for( size_t iAlgo = 0 ; iAlgo < fEtaMinBin.size() ; iAlgo++){ 225 puppiAlgoBin algoTmp ; 226 algoTmp.fEtaMin_ = fEtaMinBin.at(iAlgo); 227 algoTmp.fEtaMax_ = fEtaMaxBin.at(iAlgo); 228 algoTmp.fPtMin_ = fPtMinBin.at(iAlgo); 229 algoTmp.fConeSize_ = fConeSizeBin.at(iAlgo); 230 algoTmp.fRMSPtMin_ = fRMSPtMinBin.at(iAlgo); 231 algoTmp.fRMSScaleFactor_ = fRMSScaleFactorBin.at(iAlgo); 232 algoTmp.fNeutralMinE_ = fNeutralMinEBin.at(iAlgo); 233 algoTmp.fNeutralPtSlope_ = fNeutralPtSlope.at(iAlgo); 234 algoTmp.fApplyCHS_ = fApplyCHS.at(iAlgo); 235 algoTmp.fUseCharged_ = fUseCharged.at(iAlgo); 236 algoTmp.fApplyLowPUCorr_ = fApplyLowPUCorr.at(iAlgo); 237 algoTmp.fMetricId_ = fMetricId.at(iAlgo); 238 if(std::find(puppiAlgo.begin(),puppiAlgo.end(),algoTmp) != puppiAlgo.end()) continue; 239 puppiAlgo.push_back(algoTmp); 240 } 241 } 242 237 243 // Create PUPPI container 238 fPuppi->initialize(puppiInputVector); 239 fPuppi->puppiWeights(); 240 std::vector<fastjet::PseudoJet> puppiParticles = fPuppi->puppiParticles(); 244 puppiCleanContainer curEvent(puppiInputVector,puppiAlgo,fMinPuppiWeight,fUseExp); 245 std::vector<fastjet::PseudoJet> puppiParticles = curEvent.puppiEvent(); 241 246 242 247 // Loop on final particles -
modules/RunPUPPI.h
r4a0d9d5 r4406bf8 3 3 4 4 #include "classes/DelphesModule.h" 5 #include "PUPPI/PuppiContainer.hh"6 5 #include <vector> 7 6 … … 30 29 const TObjArray *fNeutralInputArray; //! 31 30 const TObjArray *fPVInputArray; //! 32 PuppiContainer* fPuppi;31 33 32 // puppi parameters 34 bool fApplyNoLep; 35 double fMinPuppiWeight; 33 float fMinPuppiWeight; 36 34 bool fUseExp; 37 35 … … 48 46 std::vector<bool> fApplyLowPUCorr; 49 47 std::vector<int> fMetricId; 50 std::vector<int> fCombId;51 48 52 49 TObjArray *fOutputArray; -
modules/SimpleCalorimeter.cc
r4a0d9d5 r4406bf8 504 504 tower->Eem = (!fIsEcal) ? 0 : energy; 505 505 tower->Ehad = (fIsEcal) ? 0 : energy; 506 506 507 507 tower->Momentum.SetPtEtaPhiE(pt, eta, phi, energy); 508 509 tower->PID = (fIsEcal) ? 22 : 0;510 511 508 fEFlowTowerOutputArray->Add(tower); 512 509 }
Note:
See TracChangeset
for help on using the changeset viewer.