From d6c8e68e7ae9d162adc5a2fc26d629be5f58bcf2 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 14 May 2014 12:04:15 +0200 Subject: [PATCH 001/252] first version, with vertex, TrkMET, TkEm and TkEleTracks (from latest 61X code) --- .../HiJetAlgos/python/HiRecoJets_TTI_cff.py | 113 +++++ .../plugins/L1CaloProtoClusterSharing.cc | 6 +- .../plugins/L1TkElectronTrackProducer.cc | 30 +- .../plugins/L1TkEtMissProducer.cc | 6 + .../plugins/L1TkFastVertexProducer.cc | 445 ++++++++++++++++++ .../plugins/L1TkPrimaryVertexProducer.cc | 9 + .../python/L1TkElectronTrackProducer_cfi.py | 10 +- .../python/L1TkEtMissProducer_cfi.py | 4 +- .../python/L1TkPrimaryVertexProducer_cfi.py | 13 +- .../src/L1TkElectronTrackMatchAlgo.cc | 11 +- .../L1TrackTrigger/test/ele.x | 99 ++++ .../L1TrackTrigger/test/test_L1TkEGamma.py | 79 ++-- .../L1TrackTrigger/test/test_L1TkEtMiss.py | 89 ++-- .../test/test_L1TkPrimaryVertex_cfg.py | 69 +++ 14 files changed, 892 insertions(+), 91 deletions(-) create mode 100644 RecoHI/HiJetAlgos/python/HiRecoJets_TTI_cff.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/ele.x create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkPrimaryVertex_cfg.py diff --git a/RecoHI/HiJetAlgos/python/HiRecoJets_TTI_cff.py b/RecoHI/HiJetAlgos/python/HiRecoJets_TTI_cff.py new file mode 100644 index 0000000000000..c1ed935c60014 --- /dev/null +++ b/RecoHI/HiJetAlgos/python/HiRecoJets_TTI_cff.py @@ -0,0 +1,113 @@ +import FWCore.ParameterSet.Config as cms + +from RecoJets.Configuration.CaloTowersRec_cff import * + +## Default Parameter Sets +from RecoJets.JetProducers.AnomalousCellParameters_cfi import * +from RecoHI.HiJetAlgos.HiCaloJetParameters_cff import * + +caloTowers = cms.EDProducer("CaloTowerCandidateCreator", + src = cms.InputTag("towerMaker"), + e = cms.double(0.0), + verbose = cms.untracked.int32(0), + pt = cms.double(0.0), + minimumE = cms.double(0.0), + minimumEt = cms.double(0.0), + et = cms.double(0.0) +) + +## Iterative Cone +iterativeConePu5CaloJets = cms.EDProducer( + "FastjetJetProducer", + HiCaloJetParameters, + AnomalousCellParameters, + MultipleAlgoIteratorBlock, + jetAlgorithm = cms.string("IterativeCone"), + rParam = cms.double(0.5) + ) +iterativeConePu5CaloJets.radiusPU = 0.5 + +iterativeConePu7CaloJets = cms.EDProducer( + "FastjetJetProducer", + HiCaloJetParameters, + AnomalousCellParameters, + MultipleAlgoIteratorBlock, + jetAlgorithm = cms.string("IterativeCone"), + rParam = cms.double(0.7) + ) +iterativeConePu7CaloJets.radiusPU = 0.7 + +## kT +ktPu4CaloJets = cms.EDProducer( + "FastjetJetProducer", + HiCaloJetParameters, + AnomalousCellParameters, + MultipleAlgoIteratorBlock, + jetAlgorithm = cms.string("Kt"), + rParam = cms.double(0.4) + ) +ktPu4CaloJets.radiusPU = 0.5 + +ktPu6CaloJets = cms.EDProducer( + "FastjetJetProducer", + HiCaloJetParameters, + AnomalousCellParameters, + MultipleAlgoIteratorBlock, + jetAlgorithm = cms.string("Kt"), + rParam = cms.double(0.6) + ) +ktPu6CaloJets.radiusPU = 0.7 + +## anti-kT +akPu5CaloJets = cms.EDProducer( + "FastjetJetProducer", + HiCaloJetParameters, + AnomalousCellParameters, + MultipleAlgoIteratorBlock, + jetAlgorithm = cms.string("AntiKt"), + rParam = cms.double(0.5) + ) +akPu5CaloJets.radiusPU = 0.5 + +akPu7CaloJets = cms.EDProducer( + "FastjetJetProducer", + HiCaloJetParameters, + AnomalousCellParameters, + MultipleAlgoIteratorBlock, + jetAlgorithm = cms.string("AntiKt"), + rParam = cms.double(0.7) + ) +akPu7CaloJets.radiusPU = 0.7 + +## Algos without offset pileup correction +ic5CaloJets = iterativeConePu5CaloJets.clone() +ic5CaloJets.doRhoFastjet = True +ic5CaloJets.doPUOffsetCorr = False + +ic7CaloJets = iterativeConePu7CaloJets.clone() +ic7CaloJets.doRhoFastjet = True +ic7CaloJets.doPUOffsetCorr = False + +#ak5CaloJets = akPu5CaloJets.clone() +#ak5CaloJets.doRhoFastjet = True +#ak5CaloJets.doPUOffsetCorr = False + +#ak7CaloJets = akPu7CaloJets.clone() +#ak7CaloJets.doRhoFastjet = True +#ak7CaloJets.doPUOffsetCorr = False + +#kt4CaloJets = ktPu4CaloJets.clone() +#kt4CaloJets.doRhoFastjet = True +#kt4CaloJets.doPUOffsetCorr = False + +#kt6CaloJets = ktPu6CaloJets.clone() +#kt6CaloJets.doRhoFastjet = True +#kt6CaloJets.doPUOffsetCorr = False + +## Default Sequence +hiRecoJets = cms.Sequence(caloTowersRec*caloTowers*iterativeConePu5CaloJets) + +## Extended Sequence +#hiRecoAllJets = cms.Sequence(caloTowersRec*caloTowers*iterativeConePu5CaloJets+iterativeConePu7CaloJets+ic5CaloJets+ic7CaloJets+akPu5CaloJets+akPu7CaloJets+ak5CaloJets+ak7CaloJets + ktPu4CaloJets + ktPu6CaloJets + kt4CaloJets + kt6CaloJets) + + diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CaloProtoClusterSharing.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CaloProtoClusterSharing.cc index 2f035b6c0ff4b..441d3b0887405 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CaloProtoClusterSharing.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CaloProtoClusterSharing.cc @@ -175,8 +175,10 @@ void L1CaloProtoClusterSharing::algorithm( const int &aEta, const int &aPhi ) // Calculate Electron Cut and Save it in the Cluster - //int lElectronValue = ( int )( 1000. * ( ( double )lSharedCluster.HadEt() ) / ( ( double )lSharedCluster.EmEt() ) ); - int lElectronValue = ( int )( 1000. * ( ( double )lSharedCluster.seedHadEt() ) / ( ( double )lSharedCluster.seedEmEt() ) ); + // OLD H/E : + int lElectronValue = ( int )( 1000. * ( ( double )lSharedCluster.HadEt() ) / ( ( double )lSharedCluster.EmEt() ) ); + // MANU NEW : + //int lElectronValue = ( int )( 1000. * ( ( double )lSharedCluster.seedHadEt() ) / ( ( double )lSharedCluster.seedEmEt() ) ); lSharedCluster.setEGammaValue( lElectronValue ); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc index 97ff518e91fd2..c005056064054 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc @@ -83,6 +83,7 @@ class L1TkElectronTrackProducer : public edm::EDProducer { //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); float isolation(const edm::Handle & trkHandle, int match_index); + double getPtScaledCut(double pt, std::vector& parameters); // ----------member data --------------------------- edm::InputTag L1EGammaInputTag; @@ -102,8 +103,8 @@ class L1TkElectronTrackProducer : public edm::EDProducer { float trkQualityChi2; float trkQualityPtMin; - float dPhiCutoff; - float dRCutoff; + std::vector dPhiCutoff; + std::vector dRCutoff; float dEtaCutoff; } ; @@ -138,8 +139,8 @@ L1TkElectronTrackProducer::L1TkElectronTrackProducer(const edm::ParameterSet& iC // parameters to select tracks to match with L1EG trkQualityChi2 = (float)iConfig.getParameter("TrackChi2"); trkQualityPtMin = (float)iConfig.getParameter("TrackMinPt"); - dPhiCutoff = (float)iConfig.getParameter("TrackEGammaDeltaPhi"); - dRCutoff = (float)iConfig.getParameter("TrackEGammaDeltaR"); + dPhiCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaPhi"); + dRCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaR"); dEtaCutoff = (float)iConfig.getParameter("TrackEGammaDeltaEta"); produces(label); @@ -190,7 +191,7 @@ L1TkElectronTrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iS float et_ele = 0; if (cosh(eta_ele) > 0.0) et_ele = e_ele/cosh(eta_ele); else et_ele = -1.0; - if (fabs(eta_ele) > 2.5) continue; + //if (fabs(eta_ele) > 2.5) continue; if (ETmin > 0.0 && et_ele <= ETmin) continue; // match the L1EG object with a L1Track float drmin = 999; @@ -198,13 +199,14 @@ L1TkElectronTrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iS int itrack = -1; for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { edm::Ptr< L1TkTrackType > L1TrackPtr( L1TkTrackHandle, itr) ; - if ( trackIter->getMomentum().perp() > trkQualityPtMin && trackIter->getChi2() < trkQualityChi2) { + double trkPt = trackIter->getMomentum().perp(); + if ( trkPt > trkQualityPtMin && trackIter->getChi2() < trkQualityChi2) { double dPhi = 99.; double dR = 99.; double dEta = 99.; L1TkElectronTrackMatchAlgo::doMatch(egIter, L1TrackPtr, dPhi, dR, dEta); - if (fabs(dPhi) < dPhiCutoff && dR < dRCutoff && fabs(dEta) < dEtaCutoff && dR < drmin) { + if (fabs(dPhi) < getPtScaledCut(trkPt, dPhiCutoff) && dR < getPtScaledCut(trkPt, dRCutoff) && dR < drmin) { drmin = dR; itrack = itr; } @@ -304,21 +306,27 @@ L1TkElectronTrackProducer::isolation(const edm::Handle float sumPt = 0.0; int itr = 0; for (trackIter = trkHandle->begin(); trackIter != trkHandle->end(); ++trackIter) { - if (itr == match_index) continue; + if (itr != match_index) { float dZ = fabs(trackIter->getPOCA().z() - matchedTrkPtr->getPOCA().z() ); float dPhi = reco::deltaPhi(trackIter->getMomentum().phi(), matchedTrkPtr->getMomentum().phi()); float dEta = (trackIter->getMomentum().eta() - matchedTrkPtr->getMomentum().eta()); float dR = sqrt(dPhi*dPhi + dEta*dEta); - if (dR > DRmin && dR < DRmax && dZ < DeltaZ && trackIter->getMomentum().perp() > PTMINTRA && itr != match_index) sumPt += trackIter->getMomentum().perp(); - + if (dR > DRmin && dR < DRmax && dZ < DeltaZ && trackIter->getMomentum().perp() > PTMINTRA) { + sumPt += trackIter->getMomentum().perp(); + } + } itr ++; - } return sumPt; } +double +L1TkElectronTrackProducer::getPtScaledCut(double pt, std::vector& parameters){ + return (parameters[0] + parameters[1] * exp(parameters[2] * pt)); +} + //define this as a plug-in DEFINE_FWK_MODULE(L1TkElectronTrackProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc index 3cd2ab5a02c54..9e8da6f579f75 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc @@ -90,6 +90,7 @@ class L1TkEtMissProducer : public edm::EDProducer { int nStubsmin; int nStubsPSmin ; // minimum number of stubs in PS modules + float PTMAX; // in GeV //const StackedTrackerGeometry* theStackedGeometry; @@ -132,6 +133,8 @@ L1TkEtMissProducer::L1TkEtMissProducer(const edm::ParameterSet& iConfig) nStubsmin = iConfig.getParameter("nStubsmin"); nStubsPSmin = iConfig.getParameter("nStubsPSmin"); + PTMAX = (float)iConfig.getParameter("PTMAX"); + produces("MET"); } @@ -224,6 +227,9 @@ L1TkEtMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) if (fabs(ztr) > ZMAX ) continue; if (chi2 > CHI2MAX) continue; + + if ( PTMAX > 0 && pt > PTMAX) continue; // ignore these very high PT tracks. + int nstubs = 0; float nPS = 0.; // number of stubs in PS modules diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc new file mode 100644 index 0000000000000..87c82eddef585 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc @@ -0,0 +1,445 @@ +// -*- C++ -*- +// +// +// Original Author: Emmanuelle Perez,40 1-A28,+41227671915, +// Created: Tue Nov 12 17:03:19 CET 2013 +// $Id$ +// +// + + +// system include files +#include +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + + +//////////////////////////// +// DETECTOR GEOMETRY HEADERS +#include "MagneticField/Engine/interface/MagneticField.h" +#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetType.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelTopologyBuilder.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/RectangularPixelTopology.h" +#include "Geometry/CommonDetUnit/interface/GeomDetType.h" +#include "Geometry/CommonDetUnit/interface/GeomDetUnit.h" + +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerDetUnit.h" +#include "DataFormats/SiPixelDetId/interface/StackedTrackerDetId.h" + + +//#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" + + +//////////////////////////// +// HepMC products +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "SimDataFormats/GeneratorProducts/interface/HepMCProduct.h" +#include "DataFormats/Candidate/interface/Candidate.h" + + +#include "TH1F.h" + + + +// +// class declaration +// + +class L1TkFastVertexProducer : public edm::EDProducer { + public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + explicit L1TkFastVertexProducer(const edm::ParameterSet&); + ~L1TkFastVertexProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + + private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + virtual void beginRun(edm::Run&, edm::EventSetup const&); + //virtual void endRun(edm::Run&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // ----------member data --------------------------- + + edm::InputTag L1TrackInputTag; + + float ZMAX; // in cm + float DeltaZ; // in cm + float CHI2MAX; + float PTMINTRA ; // in GeV + + float PTMAX; // in GeV, saturation / truncation value + int HighPtTracks; // saturate or truncate + + int nStubsmin ; // minimum number of stubs + int nStubsPSmin ; // minimum number of stubs in PS modules + + //const StackedTrackerGeometry* theStackedGeometry; + + TH1F* htmp; + TH1F* htmp_weight; + +}; + +// +// constants, enums and typedefs +// + + +// +// static data member definitions +// + +// +// constructors and destructor +// +L1TkFastVertexProducer::L1TkFastVertexProducer(const edm::ParameterSet& iConfig) +{ + //register your products +/* Examples + produces(); + + //if do put with a label + produces("label"); + + //if you want to put into the Run + produces(); +*/ + //now do what ever other initialization is needed + + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + + ZMAX = (float)iConfig.getParameter("ZMAX"); + CHI2MAX = (float)iConfig.getParameter("CHI2MAX"); + PTMINTRA = (float)iConfig.getParameter("PTMINTRA"); + + PTMAX = (float)iConfig.getParameter("PTMAX"); + HighPtTracks = iConfig.getParameter("HighPtTracks"); + + nStubsmin = iConfig.getParameter("nStubsmin"); + nStubsPSmin = iConfig.getParameter("nStubsPSmin"); + + + //int nbins = 300; + //float xmin = -15; + //float xmax = +15; + + //int nbins = 600; + //float xmin = -15; + //float xmax = +15; + + int nbins = 600; + float xmin = -30 + 0.05/2.; + float xmax = +30 + 0.05/2.; + + htmp = new TH1F("htmp",";z (cm); Tracks",nbins,xmin,xmax); + htmp_weight = new TH1F("htmp_weight",";z (cm); Tracks",nbins,xmin,xmax); + + produces(); + +} + + +L1TkFastVertexProducer::~L1TkFastVertexProducer() +{ + + // do anything here that needs to be done at desctruction time + // (e.g. close files, deallocate resources etc.) + +} + + +// +// member functions +// + +// ------------ method called to produce the data ------------ +void +L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + + std::auto_ptr result(new L1TkPrimaryVertexCollection); + + /// Geometry handles etc + edm::ESHandle geometryHandle; + edm::ESHandle stackedGeometryHandle; + /// Geometry setup + /// Set pointers to Geometry + iSetup.get().get(geometryHandle); + iSetup.get().get(stackedGeometryHandle); + const StackedTrackerGeometry* theStackedGeometry = stackedGeometryHandle.product(); /// Note this is different + /// from the "global" geometry + //if (theStackedGeometry == 0) cout << " theStackedGeometry = 0 " << endl; // for compil when not used... + + + htmp -> Reset(); + htmp_weight -> Reset(); + + + // ---------------------------------------------------------------------- + +/* + // MC info ... retrieve the zvertex + edm::Handle HepMCEvt; + iEvent.getByLabel("generator",HepMCEvt); + + const HepMC::GenEvent* MCEvt = HepMCEvt->GetEvent(); + const double mm=0.1; + + float zvtx_gen = -999; + + for ( HepMC::GenEvent::vertex_const_iterator ivertex = MCEvt->vertices_begin(); ivertex != MCEvt->vertices_end(); ++ivertex ) + { + bool hasParentVertex = false; + + // Loop over the parents looking to see if they are coming from a production vertex + for ( + HepMC::GenVertex::particle_iterator iparent = (*ivertex)->particles_begin(HepMC::parents); + iparent != (*ivertex)->particles_end(HepMC::parents); + ++iparent + ) + if ( (*iparent)->production_vertex() ) + { + hasParentVertex = true; + break; + } + + // Reject those vertices with parent vertices + if (hasParentVertex) continue; + // Get the position of the vertex + HepMC::FourVector pos = (*ivertex)->position(); + zvtx_gen = pos.z()*mm; + break; // there should be one single primary vertex + } // end loop over gen vertices +*/ + + + + edm::Handle L1TkTrackHandle; + iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); + + + if( !L1TkTrackHandle.isValid() ) + { + LogError("L1TkFastVertexProducer") + << "\nWarning: L1TkTrackCollection with " << L1TrackInputTag + << "\nrequested in configuration, but not found in the event. Exit" + << std::endl; + return; + } + + + + L1TkTrackCollectionType::const_iterator trackIter; + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { + + float z = trackIter->getPOCA().z(); + float chi2 = trackIter->getChi2(); + float pt = trackIter->getMomentum().perp(); + + if (fabs(z) > ZMAX ) continue; + if (chi2 > CHI2MAX) continue; + if (pt < PTMINTRA) continue; + + // saturation or truncation : + if ( PTMAX > 0 && pt > PTMAX ) { + if (HighPtTracks == 0) continue; // ignore this track + if (HighPtTracks == 1) pt = PTMAX; // saturate + } + + + // get the number of stubs and the number of stubs in PS layers + float nPS = 0.; // number of stubs in PS modules + float nstubs = 0; + + // get pointers to stubs associated to the L1 track + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubs = trackIter -> getStubRefs() ; + + int tmp_trk_nstub = (int) theStubs.size(); + if ( tmp_trk_nstub < 0) { + std::cout << " ... could not retrieve the vector of stubs in L1TkFastVertexProducer::SumPtVertex " << std::endl; + continue; + } + + + // loop over the stubs + for (unsigned int istub=0; istub<(unsigned int)theStubs.size(); istub++) { + nstubs ++; + StackedTrackerDetId detIdStub( theStubs.at(istub)->getDetId() ); + bool isPS = theStackedGeometry -> isPSModule( detIdStub ); + if (isPS) nPS ++; + } // end loop over stubs + if (nstubs < nStubsmin) continue; + if (nPS < nStubsPSmin) continue; + htmp -> Fill( z ); + htmp_weight -> Fill( z, pt ); + + } // end loop over tracks + + +/* + int binmax = htmp -> GetMaximumBin(); + float zvtx = htmp -> GetBinCenter( binmax ); + binmax = htmp_weight -> GetMaximumBin(); + float zvtx_weight = htmp_weight -> GetBinCenter( binmax ); + + L1TkPrimaryVertex vtx1( zvtx, zvtx_gen); + L1TkPrimaryVertex vtx2( zvtx_weight, zvtx_gen); +*/ + + + // sliding windows... maximize bin i + i-1 + i+1 + + float zvtx_sliding = -999; + float sigma_max = -999; + int nb = htmp -> GetNbinsX(); + for (int i=2; i <= nb-1; i++) { + float a0 = htmp -> GetBinContent(i-1); + float a1 = htmp -> GetBinContent(i); + float a2 = htmp -> GetBinContent(i+1); + float sigma = a0 + a1 + a2; + if (sigma > sigma_max) { + sigma_max = sigma; + float z0 = htmp -> GetBinCenter(i-1); + float z1 = htmp -> GetBinCenter(i); + float z2 = htmp -> GetBinCenter(i+1); + zvtx_sliding = ( a0 * z0 + a1 * z1 + a2 * z2 ) / sigma; + } + } + + //L1TkPrimaryVertex vtx3( zvtx_sliding, zvtx_gen); + + zvtx_sliding = -999; + sigma_max = -999; + for (int i=2; i <= nb-1; i++) { + float a0 = htmp_weight -> GetBinContent(i-1); + float a1 = htmp_weight -> GetBinContent(i); + float a2 = htmp_weight -> GetBinContent(i+1); + float sigma = a0 + a1 + a2; + if (sigma > sigma_max) { + sigma_max = sigma; + float z0 = htmp_weight -> GetBinCenter(i-1); + float z1 = htmp_weight -> GetBinCenter(i); + float z2 = htmp_weight -> GetBinCenter(i+1); + zvtx_sliding = ( a0 * z0 + a1 * z1 + a2 * z2 ) / sigma; + } + } + //L1TkPrimaryVertex vtx4( zvtx_sliding, zvtx_gen); + L1TkPrimaryVertex vtx4( zvtx_sliding, sigma_max); + + +/* + int NTRAMIN = 2; + TH1F* htmp_weight_cleaned = (TH1F*)htmp_weight -> Clone(); + for (int i=0; i<= nb; i++) { + float val = htmp_weight -> GetBinContent(i); + float Ntracks = htmp -> GetBinContent(i); + if ( Ntracks >= NTRAMIN) { + htmp_weight_cleaned -> SetBinContent(i, val); + } + else { + htmp_weight_cleaned -> SetBinContent(i, 0.); + } + } + + binmax = htmp_weight_cleaned -> GetMaximumBin(); + float zvtx_weight_cleaned = htmp_weight_cleaned -> GetBinCenter( binmax ); + L1TkPrimaryVertex vtx5( zvtx_weight_cleaned, zvtx_gen); +*/ + + result -> push_back( vtx4 ); + +/* + result -> push_back( vtx1 ); + result -> push_back( vtx2 ); + result -> push_back( vtx3 ); + result -> push_back( vtx5 ); +*/ + + iEvent.put( result); +} + + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TkFastVertexProducer::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TkFastVertexProducer::endJob() { +} + +// ------------ method called when starting to processes a run ------------ +void +L1TkFastVertexProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) +{ + +} + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1TkFastVertexProducer::endRun(edm::Run&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1TkFastVertexProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1TkFastVertexProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TkFastVertexProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TkFastVertexProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkPrimaryVertexProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkPrimaryVertexProducer.cc index acc6fa5f7057a..39599ac87cfd7 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkPrimaryVertexProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkPrimaryVertexProducer.cc @@ -7,6 +7,15 @@ // // +// ------------------------------------------------------------------------------------------------------- +// +// ******** OLD CODE ******** +// +// ******** The latest producer for the primary vertex is L1TkFastVertexProducer.cc ******** +// +// -------------------------------------------------------------------------------------------------------- + + // system include files #include diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py index 7f467b1fe62a7..8b2fa10c7977d 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py @@ -18,8 +18,8 @@ # Quality cuts on Track and Track L1EG matching criteria TrackChi2 = cms.double(100.0), # minimum Chi2 to select tracks TrackMinPt = cms.double(12.0), # minimum Pt to select tracks - TrackEGammaDeltaPhi = cms.double(0.05), # Delta Phi cutoff to match Track with L1EG objects - TrackEGammaDeltaR = cms.double(0.08), # Delta R cutoff to match Track with L1EG objects + TrackEGammaDeltaPhi = cms.vdouble(0.05, 0.0, 0.0), # functional Delta Phi cut parameters to match Track with L1EG objects + TrackEGammaDeltaR = cms.vdouble(0.08, 0.0, 0.0), # functional Delta R cut parameters to match Track with L1EG objects TrackEGammaDeltaEta = cms.double(0.08), # Delta Eta cutoff to match Track with L1EG objects # are considered. RelativeIsolation = cms.bool( True ), # default = True. The isolation variable is relative if True, @@ -34,3 +34,9 @@ DRmax = cms.double( 0.2 ), DeltaZ = cms.double( 0.6 ) # in cm. Used for tracks to be used isolation calculation ) + + +L1TkElectronsLoose = L1TkElectrons.clone() +L1TkElectronsLoose.TrackEGammaDeltaPhi = cms.vdouble(0.08, 0.0, 0.0) +L1TkElectronsLooseTrackEGammaDeltaR = cms.vdouble(0.12, 0.0, 0.0) +L1TkElectronsLoose.TrackMinPt = cms.double( 3.0 ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py index 7a699d68ea189..ad359c901c91d 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py @@ -8,7 +8,9 @@ PTMINTRA = cms.double( 2. ), # in GeV DeltaZ = cms.double( 1. ), # in cm nStubsmin = cms.int32( 4 ), # min number of stubs for the tracks to enter in TrkMET calculation - nStubsPSmin = cms.int32( 0) # min number of stubs in the PS Modules + nStubsPSmin = cms.int32( 0), # min number of stubs in the PS Modules + PTMAX = cms.double( 50. ) # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as + # mismeasured are are ignored in the calculation of TrkMET. ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py index 0d4f92340cdfd..d8c26b7504b4b 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py @@ -1,13 +1,16 @@ import FWCore.ParameterSet.Config as cms -L1TkPrimaryVertex = cms.EDProducer('L1TkPrimaryVertexProducer', +L1TkPrimaryVertex = cms.EDProducer('L1TkFastVertexProducer', L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), ZMAX = cms.double ( 25. ) , # in cm CHI2MAX = cms.double( 100. ), - DeltaZ = cms.double( 0.1 ), # in cm. PTMINTRA = cms.double( 2.), # PTMIN of L1Tracks, in GeV nStubsmin = cms.int32( 4 ) , # minimum number of stubs - nStubsPSmin = cms.int32( 3 ), # minimum number of stubs in PS modules - SumPtSquared = cms.bool( True ) # maximizes SumPT^2 or SumPT + nStubsPSmin = cms.int32( 3 ), # minimum number of stubs in PS modules + PTMAX = cms.double( 50. ), # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as + # mismeasured and are treated according to HighPtTracks below. + # When PTMAX < 0, no special treatment is done for high PT tracks. + # If PTMAX < 0, no saturation or truncation is done. + HighPtTracks = cms.int32( 1 ) # when = 0 : truncation. Tracks with PT above PTMAX are ignored + # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. ) - diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc index c75e154af87a0..4b2d6b966cb12 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc @@ -42,8 +42,14 @@ namespace L1TkElectronTrackMatchAlgo { double deltaPhi(const GlobalPoint& epos, const edm::Ptr< L1TkTrackType > & pTrk){ double er = epos.perp(); - // Using track fit curvature - // double curv = 0.003 * magnetStrength * trk->getCharge()/ trk->getMomentum().perp(); + double curv = pTrk->getRInv(); + double dphi_curv= (asin(er*curv/(2.0))); + double trk_phi_ecal = reco::deltaPhi(pTrk->getMomentum().phi(),dphi_curv); + + double dphi = reco::deltaPhi(trk_phi_ecal,epos.phi()); + return dphi; + +/* double curv = pTrk->getRInv(); double x1 = (asin(er*curv/(2.0))); double phi1 = reco::deltaPhi(pTrk->getMomentum().phi(), epos.phi()); @@ -53,6 +59,7 @@ namespace L1TkElectronTrackMatchAlgo { if (fabs(dif1) < fabs(dif2)) return dif1; else return dif2; +*/ } // --------------- calculate deltaPhi between Track and EGamma object diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/ele.x b/SLHCUpgradeSimulations/L1TrackTrigger/test/ele.x new file mode 100644 index 0000000000000..55fb9b382e82a --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/ele.x @@ -0,0 +1,99 @@ +{ + +gStyle->SetOptStat(0); + +int nbins = 50; +float x1 = 4.5 ; +float x2 = 54.5 ; + +TH1F* hEG = new TH1F("hEG",";ET threshold (GeV); Rate (kHz)",nbins,x1,x2); + +TH1F* hPho = new TH1F("hPho",";ET threshold (GeV); Rate (kHz)",nbins,x1,x2); +TH1F* hEle = new TH1F("hEle",";ET threshold (GeV); Rate (kHz)",nbins,x1,x2); +TH1F* hEleIso = new TH1F("hEleIso",";ET threshold (GeV); Rate (kHz)",nbins,x1,x2); +TH1F* hEleLoose = new TH1F("hEleLoose",";ET threshold (GeV); Rate (kHz)",nbins,x1,x2); // PTtrack = 3 GeV +TH1F* hEleLooseV2 = new TH1F("hEleLooseV2",";ET threshold (GeV); Rate (kHz)",nbins,x1,x2); // PTTrack cut = 2 GeV + + +Events -> Draw("Max$(l1extraL1EmParticles_SLHCL1ExtraParticlesNewClustering_EGamma_ALL.obj.pt_)>>hEG"); +Events -> Draw("Max$(l1extraL1TkEmParticles_L1TkPhotons_EG_ALL.obj.pt_)>>hPho"); + +Events -> Draw("Max$(l1extraL1TkElectronParticles_L1TkElectrons_EG_ALL.obj.pt_)>>hEle"); +Events -> Draw("Max$(l1extraL1TkElectronParticles_L1TkIsoElectrons_EG_ALL.obj.pt_)>>hEleIso"); +Events -> Draw("Max$(l1extraL1TkElectronParticles_L1TkElectronsLoose_EG_ALL.obj.pt_)>>hEleLoose"); +Events -> Draw("Max$(l1extraL1TkElectronParticles_L1TkElectronsLooseV2_EG_ALL.obj.pt_)>>hEleLooseV2"); + + +for (int i=0; i<= nbins+1; i++) { + hEG -> SetBinContent(i, hEG -> Integral(i, nbins+1) ); + hPho -> SetBinContent(i, hPho -> Integral(i, nbins+1) ); + hEle -> SetBinContent(i, hEle -> Integral(i, nbins+1) ); + hEleIso -> SetBinContent(i, hEleIso -> Integral(i, nbins+1) ); + hEleLoose -> SetBinContent(i, hEleLoose -> Integral(i, nbins+1) ); + hEleLooseV2 -> SetBinContent(i, hEleLooseV2 -> Integral(i, nbins+1) ); + + hEG -> SetBinError(i, sqrt( hEG -> GetBinContent(i) ) ); + hPho -> SetBinError(i, sqrt( hPho -> GetBinContent(i) ) ); + hEle -> SetBinError(i, sqrt( hEle -> GetBinContent(i) ) ); + hEleIso -> SetBinError(i, sqrt( hEleIso -> GetBinContent(i) ) ); + hEleLoose -> SetBinError(i, sqrt( hEleLoose -> GetBinContent(i) ) ); + hEleLooseV2 -> SetBinError(i, sqrt( hEleLooseV2 -> GetBinContent(i) ) ); + +} + +float nevts = Events->GetEntries(); + +hEG -> Scale(30000./nevts); +hPho -> Scale(30000./nevts); +hEle -> Scale(30000./nevts); +hEleIso -> Scale(30000./nevts); +hEleLoose -> Scale(30000./nevts); +hEleLooseV2 -> Scale(30000./nevts); + +hEG -> SetMaximum(50000.); +hEG -> SetMinimum(10.); +hEG -> SetLineColor(2); +hEG -> Draw("hist"); + +//hPho -> SetLineColor(2); +//hPho -> Draw("same,hist"); + +hEle -> SetLineColor(1); +hEle -> SetMarkerColor(1); +hEle -> Draw("same,pe"); + +hEleIso -> SetLineColor(6); +hEleIso -> SetMarkerColor(6); +hEleIso -> Draw("same,hist"); + +hEleLoose -> SetLineColor(4); +hEleLoose -> SetMarkerColor(4); +hEleLoose -> Draw("same,pe"); + +hEleLooseV2 -> SetLineColor(7); +hEleLooseV2 -> Draw("same,hist"); + +gPad -> SetLogy(1); +gPad -> SetGridx(1); +gPad -> SetGridy(1); + + TLegend *leg = new TLegend(0.5,0.75,0.93,0.92,NULL,"brNDC"); + leg->SetBorderSize(0); + leg->SetLineColor(1); + leg->SetLineStyle(1); + leg->SetLineWidth(1); + leg->SetFillColor(0); + leg->SetFillStyle(0); + leg->SetTextFont(42); + leg -> AddEntry(hEG,"L1EG","l"); + leg -> AddEntry(hEle,"L1TkElectrons","pe"); + leg -> AddEntry(hEleIso,"L1TkElectrons, TkIso","l"); + leg -> AddEntry(hEleLoose,"L1TkElectronsLoose, PT > 3 GeV","pe"); + leg -> AddEntry(hEleLooseV2,"L1TkElectronsLoose, PT > 2 GeV","l"); + + leg -> Draw(); + + +} + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma.py index 19b205079d4ef..286aa4d95e0f0 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma.py @@ -4,7 +4,7 @@ process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) # # This runs over a file that already contains the L1Tracks. @@ -22,7 +22,9 @@ process.source = cms.Source("PoolSource", fileNames = cms.untracked.vstring( - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC8/BE5D/SingleEle_NoPU.root' + # rate test sample: + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' ) ) @@ -30,7 +32,8 @@ # ---- Global Tag : process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + @@ -44,27 +47,12 @@ # objects (new clustering from JB Sauvan et al). Note that the # efficiency of the latter is currently poor at very high PU. -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5D_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5DReco_cff') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') process.load('Configuration/StandardSequences/L1HwVal_cff') process.load('Configuration.StandardSequences.RawToDigi_cff') process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") - - # The sequence SLHCCaloTrigger is broken in SLHC8 because of the - # L1Jets stuff (should be fixed in SLHC9). - # Hence, in the "remove" lines below, I hack the sequence such that - # we can run the L1EGamma stuff. - -process.SLHCCaloTrigger.remove( process.L1TowerJetProducer ) -process.SLHCCaloTrigger.remove( process.L1TowerJetFilter1D ) -process.SLHCCaloTrigger.remove( process.L1TowerJetFilter2D ) -process.SLHCCaloTrigger.remove( process.L1TowerJetPUEstimator ) -process.SLHCCaloTrigger.remove( process.L1TowerJetPUSubtractedProducer ) -process.SLHCCaloTrigger.remove( process.L1CalibFilterTowerJetProducer ) -process.SLHCCaloTrigger.remove( process.L1CaloJetExpander ) - # bug fix for missing HCAL TPs in MC RAW from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) @@ -78,6 +66,7 @@ # to the Run-1 L1EG algorithm, one just needs to run # L1Reco. The (Run-1) L1EG algorithm has already been # run in the DIGI step of the production. + process.load('Configuration.StandardSequences.L1Reco_cff') process.L1Reco = cms.Path( process.l1extraParticles ) @@ -107,6 +96,19 @@ process.L1TkIsoElectrons.IsoCut = cms.double(0.1) process.pElectronsTkIso = cms.Path( process.L1TkIsoElectrons ) +# ---- "electrons" from L1Tracks, Inclusive electrons : dedicated low PT sequence +process.pElectronsLoose = cms.Path( process.L1TkElectronsLoose) + +process.L1TkElectronsLooseV2 = process.L1TkElectronsLoose.clone() +process.L1TkElectronsLooseV2.TrackMinPt = cms.double( 2. ) +process.pElectronsLoose2 = cms.Path( process.L1TkElectronsLooseV2 ) + +# ---- L1TkElectrons that are isolated w.r.t. L1Tracks : dedicated low PT sequence +process.L1TkIsoElectronsLoose = process.L1TkElectronsLoose.clone() +process.L1TkIsoElectronsLoose.IsoCut = cms.double(0.1) +process.pElectronsTkIsoLoose = cms.Path( process.L1TkIsoElectronsLoose ) + + # ---- L1TkElectrons made from L1IsoEG objects, i.e. from L1EG objects that # are isolated in the calorimeter : @@ -136,7 +138,7 @@ L1TkHTMInputTag = cms.InputTag("L1TkHTMiss") ) -process.pAna = cms.Path( process.ana ) +#process.pAna = cms.Path( process.ana ) @@ -146,25 +148,30 @@ process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "test_L1TrackTriggerObjects.root" ), + fileName = cms.untracked.string( "example.root" ), fastCloning = cms.untracked.bool( False ), outputCommands = cms.untracked.vstring( 'drop *') ) + # raw data +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + + # gen-level information -process.Out.outputCommands.append('keep *_generator_*_*') -process.Out.outputCommands.append('keep *_*gen*_*_*') -process.Out.outputCommands.append('keep *_*Gen*_*_*') -process.Out.outputCommands.append('keep *_rawDataCollector_*_*') +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +#process.Out.outputCommands.append('keep *_genParticles_*_*') + # the L1Tracks, clusters and stubs -process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') -process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') -process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') -process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') -process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') -process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') # the L1EG objects process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_*_*' ) @@ -179,6 +186,16 @@ process.Out.outputCommands.append('keep *_L1TkElectronsIsoEG_*_*') process.Out.outputCommands.append('keep *_L1TkIsoElectrons_*_*') +process.Out.outputCommands.append('keep *_L1TkElectronsLoose_*_*') +process.Out.outputCommands.append('keep *_L1TkIsoElectronsLoose_*_*') +process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') + + +# --- to use the genParticles, one needs to keep the collections of associators below: +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + process.FEVToutput_step = cms.EndPath(process.Out) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss.py index b98a0f5a2377e..ccfe59335de10 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss.py @@ -1,58 +1,80 @@ import FWCore.ParameterSet.Config as cms -process = cms.Process("ALL") +process = cms.Process("MET") process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(5) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) # # This runs over a file that already contains the L1Tracks. # +# This runs over a file containing L1Tracks. # It produces the following objects : -# - L1TkPrimaryVertex - note that the clusters and stubs must -# have been kept on the event. See the event content of -# the example runL1Tracks.py -# - collection of L1TkEmParticles - produces Trk-based isolated "photons" -# - collection of L1TkElectrons from L1TkElectronTrackProducer +# - L1TkPrimaryVertex - running the L1TkFastVertexProducer # - L1TkEtMiss -# - collection of L1TkMuons - -# This runs the L1EG algorithms (stage-2 and new clustering), and -# creates L1TkEmParticles, L1TkElectrons, L1TrkMET. -# -# It also unpacks the L1Jets (Run-1 algorithm) that have been created -# during the centrakl production. They are used to create L1TkJets and -# L1TkHTMiss - these are just technical templates so far. # +# In the end, it also retrieves the calo-based L1MET corresponding +# to the Run-1 algorithm. For this, the file must contain the rawData +# or at least the GCT raw data. +# process.source = cms.Source("PoolSource", - fileNames = cms.untracked.vstring('file:/afs/cern.ch/user/e/eperez/public/step2.root') + fileNames = cms.untracked.vstring( + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + ) ) # ---- Global Tag : process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') # --- Produce the Primary Vertex -process.load('Configuration.StandardSequences.MagneticField_38T_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5DReco_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5D_cff') process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkPrimaryVertexProducer_cfi") process.pL1TkPrimaryVertex = cms.Path( process.L1TkPrimaryVertex ) # --- Produce the L1TrkMET + process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEtMissProducer_cfi") process.pL1TrkMET = cms.Path( process.L1TkEtMiss ) +process.L1TkEtMiss2 = process.L1TkEtMiss.clone(); +process.L1TkEtMiss2.DeltaZ = cms.double(0.2) +process.pL1TrkMET2 = cms.Path( process.L1TkEtMiss2 ) + +process.L1TkEtMiss3 = process.L1TkEtMiss.clone(); +process.L1TkEtMiss3.PTMAX = cms.double(-1) +process.pL1TrkMET3 = cms.Path( process.L1TkEtMiss3 ) + +process.L1TkEtMiss4 = process.L1TkEtMiss.clone() +process.L1TkEtMiss4.nStubsPSmin = cms.int32( 3 ) +process.pL1TrkMET4 = cms.Path( process.L1TkEtMiss4 ) + + + +# --- Retrieve the Calo-based L1MET corresponding to the Run-1 algorithm: + + # first, need to get the GCT digis +#process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load('L1Trigger.Configuration.L1RawToDigi_cff') +process.p0 = cms.Path( process.L1RawToDigi ) + + # second, run L1Reco to produce the L1ETM object corresponding + # to the current trigger +process.load('Configuration.StandardSequences.L1Reco_cff') +process.L1Reco = cms.Path( process.l1extraParticles ) + + # --------------------------------------------------------------------------- @@ -61,31 +83,24 @@ process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "test_L1TrackTriggerObjects.root" ), + fileName = cms.untracked.string( "example.root" ), fastCloning = cms.untracked.bool( False ), outputCommands = cms.untracked.vstring( 'drop *') ) - # genlevel information -process.Out.outputCommands.append('keep *_generator_*_*') -process.Out.outputCommands.append('keep *_*gen*_*_*') -process.Out.outputCommands.append('keep *_*Gen*_*_*') -process.Out.outputCommands.append('keep *_rawDataCollector_*_*') - # the L1Tracks, clusters and stubs -process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') -process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') -process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') -process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') -process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') -process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') - - # the L1TkPrimaryVertex + # the L1TkPrimaryVertex process.Out.outputCommands.append('keep *_L1TkPrimaryVertex_*_*') - # the TrkMET -process.Out.outputCommands.append('keep *_L1TkEtMiss_*_*') + # the TrkMET +process.Out.outputCommands.append('keep *_L1TkEtMiss*_*_*') + + # the calo-based L1MET +process.Out.outputCommands.append('keep *_l1extraParticles_MET_*') + + # the gen-level MET +process.Out.outputCommands.append('keep *_genMetTrue_*_*') diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkPrimaryVertex_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkPrimaryVertex_cfg.py new file mode 100644 index 0000000000000..c8ae71dc9b176 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkPrimaryVertex_cfg.py @@ -0,0 +1,69 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("VTX") + +# +# This runs over a file containing L1Tracks, and determines the +# event primary vertex by running the L1TkFastVertexProducer. +# + + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(100) ) + + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root' + # + # SingleElectron test file : + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root' + ) +) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +# --- Produce the L1TkPrimaryVertex + +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +#process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') + + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkPrimaryVertexProducer_cfi") +process.pL1TkPrimaryVertex = cms.Path( process.L1TkPrimaryVertex ) + + + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + +# --- Keep the object containing the L1 primary vertex : +process.Out.outputCommands.append('keep *_L1TkPrimaryVertex_*_*') + +# --- Keep the genParticles to allow a trivial access to the generated vertex in the ROOT file +process.Out.outputCommands.append('keep *_genParticles_*_*') +#process.Out.outputCommands.append('keep *_generator_*_*') + +# --- to use the genParticles, one needs to keep the collections of associators below: +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + From a2a37c848cbda25ddbf99d646b38e8fe8c50dc4d Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Fri, 16 May 2014 13:59:16 +0200 Subject: [PATCH 002/252] first version for distribution. Added jets and HT and EleStubs + cleanup --- .../interface/L1TkJetParticle.h | 72 +-- .../L1TrackTrigger/src/L1TkJetParticle.cc | 36 +- .../L1TrackTrigger/src/classes_def.xml | 4 +- .../interface/L1TkElectronStubMatchAlgo.h | 38 ++ .../plugins/L1TkElectronStubsProducer.cc | 155 +++++-- .../plugins/L1TkElectronTrackProducer.cc | 31 +- .../plugins/L1TkHTMissProducer.cc | 325 ++++++++------ .../L1TrackTrigger/plugins/L1TkJetProducer.cc | 423 ++++++++++++++---- .../python/L1TkCaloSequence_cff.py | 47 ++ .../python/L1TkElectronStubProducer_cfi.py | 42 ++ .../python/L1TkElectronTrackProducer_cfi.py | 7 +- .../python/L1TkHTMissProducer_cfi.py | 17 + .../python/L1TkJetProducer_cfi.py | 14 + .../src/L1TkElectronStubMatchAlgo.cc | 390 ++++++++++++++++ .../src/L1TkElectronTrackMatchAlgo.cc | 15 +- ...ObjectsAnalyzer.cc => PrintL1TkObjects.cc} | 72 +-- .../test/runL1Simulation_cfg.py | 132 ++++++ .../{runL1Tracks.py => runL1Tracks_cfg.py} | 74 +-- .../L1TrackTrigger/test/test_L1TkCalo_cfg.py | 140 ++++++ ...t_L1TkEGamma.py => test_L1TkEGamma_cfg.py} | 23 +- ...t_L1TkEtMiss.py => test_L1TkEtMiss_cfg.py} | 0 .../L1TrackTrigger/test/test_L1TkJets_cfg.py | 148 ++++++ 22 files changed, 1797 insertions(+), 408 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkElectronStubMatchAlgo.h create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkCaloSequence_cff.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronStubProducer_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkHTMissProducer_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronStubMatchAlgo.cc rename SLHCUpgradeSimulations/L1TrackTrigger/test/{L1TrackTriggerObjectsAnalyzer.cc => PrintL1TkObjects.cc} (86%) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py rename SLHCUpgradeSimulations/L1TrackTrigger/test/{runL1Tracks.py => runL1Tracks_cfg.py} (50%) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py rename SLHCUpgradeSimulations/L1TrackTrigger/test/{test_L1TkEGamma.py => test_L1TkEGamma_cfg.py} (89%) rename SLHCUpgradeSimulations/L1TrackTrigger/test/{test_L1TkEtMiss.py => test_L1TkEtMiss_cfg.py} (100%) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py diff --git a/DataFormats/L1TrackTrigger/interface/L1TkJetParticle.h b/DataFormats/L1TrackTrigger/interface/L1TkJetParticle.h index a6c49133e3190..f96ebb1da70f0 100644 --- a/DataFormats/L1TrackTrigger/interface/L1TkJetParticle.h +++ b/DataFormats/L1TrackTrigger/interface/L1TkJetParticle.h @@ -13,42 +13,50 @@ #include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" #include "DataFormats/L1Trigger/interface/L1JetParticle.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + //#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" namespace l1extra { - - class L1TkJetParticle : public reco::LeafCandidate - { - - public: - - L1TkJetParticle(); - - L1TkJetParticle( const LorentzVector& p4, - const edm::Ref< L1JetParticleCollection >& jetRef, - float jetvtx = -999. ); - - virtual ~L1TkJetParticle() {} - - // ---------- const member functions --------------------- - - const edm::Ref< L1JetParticleCollection >& getJetRef() const - { return jetRef_ ; } - - float getJetVtx() const { return JetVtx_ ; } - - - // ---------- member functions --------------------------- - - void setJetVtx(float JetVtx) { JetVtx_ = JetVtx ; } - - int bx() const; - - private: - edm::Ref< L1JetParticleCollection > jetRef_ ; - float JetVtx_ ; - + + class L1TkJetParticle : public reco::LeafCandidate + { + + public: + + //typedef L1TkTrack_PixelDigi_ L1TkTrackType; + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + + L1TkJetParticle(); + + L1TkJetParticle( const LorentzVector& p4, + const edm::Ref< L1JetParticleCollection >& jetRef, + const std::vector< edm::Ptr< L1TkTrackType > >& trkPtrs, + float jetvtx = -999. ); + + virtual ~L1TkJetParticle() {} + + // ---------- const member functions --------------------- + + const edm::Ref< L1JetParticleCollection >& getJetRef() const { return jetRef_ ; } + + const std::vector< edm::Ptr< L1TkTrackType > >& getTrkPtrs() const { return trkPtrs_; } + + float getJetVtx() const { return JetVtx_ ; } + + // ---------- member functions --------------------------- + + void setJetVtx(float JetVtx) { JetVtx_ = JetVtx ; } + + int bx() const; + + private: + edm::Ref< L1JetParticleCollection > jetRef_ ; + std::vector< edm::Ptr< L1TkTrackType > > trkPtrs_; + + float JetVtx_ ; + }; } diff --git a/DataFormats/L1TrackTrigger/src/L1TkJetParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkJetParticle.cc index 928c7a7adbdfc..79f2e3f84c9fb 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkJetParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkJetParticle.cc @@ -15,24 +15,32 @@ L1TkJetParticle::L1TkJetParticle() } L1TkJetParticle::L1TkJetParticle( const LorentzVector& p4, - const edm::Ref< L1JetParticleCollection >& jetRef, - float jetvtx ) - : LeafCandidate( ( char ) 0, p4 ), - jetRef_ ( jetRef ), - JetVtx_ ( jetvtx ) + const edm::Ref< L1JetParticleCollection >& jetRef, + const std::vector< edm::Ptr< L1TkTrackType > >& trkPtrs, + float jetvtx ) +: LeafCandidate( ( char ) 0, p4 ), + jetRef_ ( jetRef ), + trkPtrs_ ( trkPtrs ), + JetVtx_ ( jetvtx ) { - } int L1TkJetParticle::bx() const { - int dummy = -999; - if ( jetRef_.isNonnull() ) { - return (getJetRef() -> bx()) ; - } - else { - return dummy; - - } + + // in the producer L1TkJetProducer.cc, we keep only jets with bx = 0 + int dummy = 0; + return dummy; + + /* + int dummy = -999; + if ( jetRef_.isNonnull() ) { + return (getJetRef() -> bx()) ; + } + else { + return dummy; + + } + */ } diff --git a/DataFormats/L1TrackTrigger/src/classes_def.xml b/DataFormats/L1TrackTrigger/src/classes_def.xml index 30188be747562..72fed61e2bdaf 100644 --- a/DataFormats/L1TrackTrigger/src/classes_def.xml +++ b/DataFormats/L1TrackTrigger/src/classes_def.xml @@ -68,8 +68,8 @@ - - + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkElectronStubMatchAlgo.h b/SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkElectronStubMatchAlgo.h new file mode 100644 index 0000000000000..05f5867e46b26 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkElectronStubMatchAlgo.h @@ -0,0 +1,38 @@ +#ifndef L1TkElectronStubMatchAlgo_HH +#define L1TkElectronStubMatchAlgo_HH + +#include "DataFormats/L1Trigger/interface/L1EmParticle.h" +#include "DataFormats/L1Trigger/interface/L1EmParticleFwd.h" +#include "DataFormats/GeometryVector/interface/GlobalPoint.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" +#include "DataFormats/L1TrackTrigger/interface/TTStub.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/Framework/interface/Event.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerDetUnit.h" +#include "DataFormats/SiPixelDetId/interface/StackedTrackerDetId.h" + + +namespace L1TkElectronStubMatchAlgo { + typedef edm::Ref >, TTStub > stubRef; + typedef std::vector< stubRef > stubRefCollection; + + unsigned int doMatch(l1extra::L1EmParticleCollection::const_iterator egIter, const edm::ParameterSet& conf, + const edm::EventSetup& iSetup, edm::Event & iEvent, std::vector& zvals); + GlobalPoint calorimeterPosition(double phi, double eta, double e); + unsigned int getLayerId(StackedTrackerDetId id); + bool goodTwoPointZ(double innerR, double outerR, double innerZ, double outerZ ); + bool goodTwoPointPhi(double innerR, double outerR, double innerPhi, double outerPhi, double m_strength); + double getDPhi(GlobalPoint epos, double eet, double r, double phi, double m_strength); + double getZIntercept(GlobalPoint epos, double r, double z); + double getPhiMiss(double eet, GlobalPoint spos1, GlobalPoint spos2); + double getZMiss(GlobalPoint epos, double r1, double r2, double z1, double z2, bool bar); + double getScaledZInterceptCut(unsigned int layer, double cut, double cfac, double eta); + double getScaledZMissCut(int layer1, int layer2, double cut, double cfac, double eta); + bool compareStubLayer(const stubRef& s1, const stubRef& s2); + bool selectLayers(float eta, int l1, int l2); + double getCompatibleZPoint(double r1, double r2, double z1, double z2); +} +#endif diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronStubsProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronStubsProducer.cc index 9e7e4ebead3c8..f1af269c31542 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronStubsProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronStubsProducer.cc @@ -31,10 +31,16 @@ #include "DataFormats/Math/interface/LorentzVector.h" +#include "DataFormats/BeamSpot/interface/BeamSpot.h" // for L1Tracks: #include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" +// Matching Algorithm +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkElectronStubMatchAlgo.h" + +#include "DataFormats/Math/interface/deltaPhi.h" + #include #include "TMath.h" @@ -48,13 +54,13 @@ using namespace l1extra ; class L1TkElectronStubsProducer : public edm::EDProducer { public: - typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - explicit L1TkElectronStubsProducer(const edm::ParameterSet&); - ~L1TkElectronStubsProducer(); + explicit L1TkElectronStubsProducer(const edm::ParameterSet&); + ~L1TkElectronStubsProducer(); - static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); private: virtual void beginJob() ; @@ -66,26 +72,54 @@ class L1TkElectronStubsProducer : public edm::EDProducer { //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + float isolation(const edm::Handle & trkHandle, GlobalPoint ep, std::vector & zvals); + // ----------member data --------------------------- edm::InputTag L1EGammaInputTag; edm::InputTag L1TrackInputTag; + edm::InputTag L1StubInputTag; + edm::InputTag BeamSpotInputTag; + const edm::ParameterSet conf; std::string label; + float ETmin; // min ET in GeV of L1EG objects + + float DRmin; + float DRmax; + float PTMINTRA; + bool PrimaryVtxConstrain; // use the primary vertex (default = false) + float DeltaZ; // | z_track - z_ref_track | < DeltaZ in cm. + // Used only when PrimaryVtxConstrain = True. + float IsoCut; + bool RelativeIsolation; } ; // // constructors and destructor // -L1TkElectronStubsProducer::L1TkElectronStubsProducer(const edm::ParameterSet& iConfig) -{ - - L1EGammaInputTag = iConfig.getParameter("L1EGammaInputTag") ; - L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); - label = iConfig.getParameter("label"); - - - produces(label); +L1TkElectronStubsProducer::L1TkElectronStubsProducer(const edm::ParameterSet& iConfig) : + conf(iConfig) { + + L1EGammaInputTag = iConfig.getParameter("L1EGammaInputTag") ; + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + L1StubInputTag = iConfig.getParameter("L1StubInputTag"); + BeamSpotInputTag = iConfig.getParameter("BeamSpotInputTag"); + label = iConfig.getParameter("label"); + + ETmin = (float)iConfig.getParameter("ETmin"); + + // parameters for the calculation of the isolation : + PTMINTRA = (float)iConfig.getParameter("PTMINTRA"); + DRmin = (float)iConfig.getParameter("DRmin"); + DRmax = (float)iConfig.getParameter("DRmax"); + DeltaZ = (float)iConfig.getParameter("DeltaZ"); + + // cut applied on the isolation (if this number is <= 0, no cut is applied) + IsoCut = (float)iConfig.getParameter("IsoCut"); + RelativeIsolation = iConfig.getParameter("RelativeIsolation"); + + produces(label); } L1TkElectronStubsProducer::~L1TkElectronStubsProducer() { @@ -106,6 +140,8 @@ L1TkElectronStubsProducer::produce(edm::Event& iEvent, const edm::EventSetup& iS edm::Handle L1TkTrackHandle; iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); L1TkTrackCollectionType::const_iterator trackIter; + + if( !EGammaHandle.isValid() ) { LogError("L1TkElectronStubsProducer") @@ -117,37 +153,60 @@ L1TkElectronStubsProducer::produce(edm::Event& iEvent, const edm::EventSetup& iS int ieg = 0; for (egIter = EGammaHandle->begin(); egIter != EGammaHandle->end(); ++egIter) { - - edm::Ref< L1EmParticleCollection > EGammaRef( EGammaHandle, ieg ); + + edm::Ref< L1EmParticleCollection > EGammaRef( EGammaHandle, ieg ); ieg ++; int ibx = egIter -> bx(); if (ibx != 0) continue; - float trkisol = -999; // dummy - const math::XYZTLorentzVector P4 = egIter -> p4() ; - - edm::Ptr< L1TkTrackType > L1TrackPtrNull; // null pointer - L1TkElectronParticle trkEm( P4, - EGammaRef, - L1TrackPtrNull, - trkisol ); - - // then one can set the "z" of the electron, as determined by the - // algorithm, via : - float z = -999; // dummy - trkEm.setTrkzVtx( z ); - - result -> push_back( trkEm ); - + float e_ele = egIter->energy(); + float eta_ele = egIter->eta(); + float et_ele = 0; + if (cosh(eta_ele) > 0.0) et_ele = e_ele/cosh(eta_ele); + else et_ele = -1.0; + if (ETmin > 0.0 && et_ele <= ETmin) continue; - } // end loop over EGamma objects + std::vector compatibleZpoints; + unsigned int matchedStubs = L1TkElectronStubMatchAlgo::doMatch(egIter, conf, iSetup, iEvent, compatibleZpoints); + - iEvent.put( result, label ); + if (matchedStubs > 0) { + + const math::XYZTLorentzVector P4 = egIter -> p4() ; + GlobalPoint epos = L1TkElectronStubMatchAlgo::calorimeterPosition(egIter->phi(), egIter->eta(), egIter->energy()); + float trkisol = isolation(L1TkTrackHandle, epos, compatibleZpoints); + // std::cout << " Event # " << iEvent.id().event() << " EGamma Et " << et_ele << " Selected Tracklets " << matchedStubs << " Isolation " << trkisol/et_ele << std::endl; + if (RelativeIsolation && et_ele > 0.0) { // relative isolation + trkisol = trkisol / et_ele; + } + edm::Ptr< L1TkTrackType > L1TrackPtrNull; // null pointer + + L1TkElectronParticle trkEm( P4, + EGammaRef, + L1TrackPtrNull, + trkisol ); + + if (IsoCut <= 0) { + // write the L1TkEm particle to the collection, + // irrespective of its relative isolation + result -> push_back( trkEm ); + } else { + // the object is written to the collection only + // if it passes the isolation cut + if (trkisol <= IsoCut) result -> push_back( trkEm ); + } + + } + + } // end loop over EGamma objects + + iEvent.put( result, label ); } + // ------------ method called once each job just before starting event loop ------------ void L1TkElectronStubsProducer::beginJob() @@ -200,6 +259,36 @@ L1TkElectronStubsProducer::fillDescriptions(edm::ConfigurationDescriptions& desc desc.setUnknown(); descriptions.addDefault(desc); } +// method to calculate isolation +float + L1TkElectronStubsProducer::isolation(const edm::Handle & trkHandle, GlobalPoint ep, std::vector & zvals) { + L1TkTrackCollectionType::const_iterator trackIter; + + float er = ep.perp(); + float ez = ep.z(); + float minIso = 999.9; + + for (std::vector::iterator iz = zvals.begin(); iz != zvals.end(); iz++) { + float zcorr = ez - (*iz); + float theta = 0.0; + if (zcorr >= 0) theta = atan(er/fabs(zcorr)); + else theta = 3.14 - atan(er/fabs(zcorr)); + float etacorr = -1.0 * TMath::Log(TMath::Tan(theta/2.0)); + + float sumPt = 0.0; + for (trackIter = trkHandle->begin(); trackIter != trkHandle->end(); ++trackIter) { + float dZ = fabs(trackIter->getPOCA().z() - (*iz)); + float dPhi = reco::deltaPhi(trackIter->getMomentum().phi(), ep.phi()); + float dEta = (trackIter->getMomentum().eta() - etacorr); + float dR = sqrt(dPhi*dPhi + dEta*dEta); + if (dR > DRmin && dR < DRmax && dZ < DeltaZ && trackIter->getMomentum().perp() > PTMINTRA) { + sumPt += trackIter->getMomentum().perp(); + } + } + if (sumPt < minIso) minIso = sumPt; + } + return minIso; +} //define this as a plug-in DEFINE_FWK_MODULE(L1TkElectronStubsProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc index c005056064054..c228c49c75f81 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc @@ -83,7 +83,7 @@ class L1TkElectronTrackProducer : public edm::EDProducer { //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); float isolation(const edm::Handle & trkHandle, int match_index); - double getPtScaledCut(double pt, std::vector& parameters); + double getPtScaledCut(double pt, std::vector& parameters); // ----------member data --------------------------- edm::InputTag L1EGammaInputTag; @@ -103,8 +103,8 @@ class L1TkElectronTrackProducer : public edm::EDProducer { float trkQualityChi2; float trkQualityPtMin; - std::vector dPhiCutoff; - std::vector dRCutoff; + std::vector dPhiCutoff; + std::vector dRCutoff; float dEtaCutoff; } ; @@ -139,8 +139,8 @@ L1TkElectronTrackProducer::L1TkElectronTrackProducer(const edm::ParameterSet& iC // parameters to select tracks to match with L1EG trkQualityChi2 = (float)iConfig.getParameter("TrackChi2"); trkQualityPtMin = (float)iConfig.getParameter("TrackMinPt"); - dPhiCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaPhi"); - dRCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaR"); + dPhiCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaPhi"); + dRCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaR"); dEtaCutoff = (float)iConfig.getParameter("TrackEGammaDeltaEta"); produces(label); @@ -191,7 +191,6 @@ L1TkElectronTrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iS float et_ele = 0; if (cosh(eta_ele) > 0.0) et_ele = e_ele/cosh(eta_ele); else et_ele = -1.0; - //if (fabs(eta_ele) > 2.5) continue; if (ETmin > 0.0 && et_ele <= ETmin) continue; // match the L1EG object with a L1Track float drmin = 999; @@ -306,27 +305,25 @@ L1TkElectronTrackProducer::isolation(const edm::Handle float sumPt = 0.0; int itr = 0; for (trackIter = trkHandle->begin(); trackIter != trkHandle->end(); ++trackIter) { - if (itr != match_index) { - float dZ = fabs(trackIter->getPOCA().z() - matchedTrkPtr->getPOCA().z() ); + if (itr != match_index) { + float dZ = fabs(trackIter->getPOCA().z() - matchedTrkPtr->getPOCA().z() ); - float dPhi = reco::deltaPhi(trackIter->getMomentum().phi(), matchedTrkPtr->getMomentum().phi()); - float dEta = (trackIter->getMomentum().eta() - matchedTrkPtr->getMomentum().eta()); - float dR = sqrt(dPhi*dPhi + dEta*dEta); - - if (dR > DRmin && dR < DRmax && dZ < DeltaZ && trackIter->getMomentum().perp() > PTMINTRA) { + float dPhi = reco::deltaPhi(trackIter->getMomentum().phi(), matchedTrkPtr->getMomentum().phi()); + float dEta = (trackIter->getMomentum().eta() - matchedTrkPtr->getMomentum().eta()); + float dR = sqrt(dPhi*dPhi + dEta*dEta); + + if (dR > DRmin && dR < DRmax && dZ < DeltaZ && trackIter->getMomentum().perp() > PTMINTRA) { sumPt += trackIter->getMomentum().perp(); - } + } } - itr ++; + itr++; } return sumPt; } - double L1TkElectronTrackProducer::getPtScaledCut(double pt, std::vector& parameters){ return (parameters[0] + parameters[1] * exp(parameters[2] * pt)); } - //define this as a plug-in DEFINE_FWK_MODULE(L1TkElectronTrackProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkHTMissProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkHTMissProducer.cc index 67941a36d24b9..4136dfaf22729 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkHTMissProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkHTMissProducer.cc @@ -30,180 +30,237 @@ using namespace l1extra; -// -// class declaration -// +////////////////////////////// +// // +// CLASS DEFINITION // +// // +////////////////////////////// class L1TkHTMissProducer : public edm::EDProducer { - public: +public: + + explicit L1TkHTMissProducer(const edm::ParameterSet&); + ~L1TkHTMissProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + +private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + //virtual void beginRun(edm::Run&, edm::EventSetup const&); + //virtual void endRun(edm::Run&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + - explicit L1TkHTMissProducer(const edm::ParameterSet&); - ~L1TkHTMissProducer(); + // ---------- member data --------------------------- + edm::InputTag L1TkJetInputTag; - static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + float JET_PTMIN; // [GeV] + float JET_ETAMAX; // [rad] + bool DoVtxConstrain; // require vertex constraint + bool PrimaryVtxConstrain; // use event primary vertex instead of leading jet (if DoVtxConstrain) + edm::InputTag L1VertexInputTag; // used only when PrimaryVtxConstrain = True (if DoTvxConstrain) + float DeltaZ; // for jets [cm] (if DoTvxConstrain) + +}; - private: - virtual void beginJob() ; - virtual void produce(edm::Event&, const edm::EventSetup&); - virtual void endJob() ; - - virtual void beginRun(edm::Run&, edm::EventSetup const&); - //virtual void endRun(edm::Run&, edm::EventSetup const&); - //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); - //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); +////////////// +// constructor +L1TkHTMissProducer::L1TkHTMissProducer(const edm::ParameterSet& iConfig) +{ + L1TkJetInputTag = iConfig.getParameter("L1TkJetInputTag"); + + JET_PTMIN = (float)iConfig.getParameter("JET_PTMIN"); + JET_ETAMAX = (float)iConfig.getParameter("JET_ETAMAX"); - // ----------member data --------------------------- + DoVtxConstrain = iConfig.getParameter("DoVtxConstrain"); + PrimaryVtxConstrain = iConfig.getParameter("PrimaryVtxConstrain"); + L1VertexInputTag = iConfig.getParameter("L1VertexInputTag") ; + DeltaZ = (float)iConfig.getParameter("DeltaZ"); + + produces(); +} - edm::InputTag L1TkJetInputTag; +///////////// +// destructor +L1TkHTMissProducer::~L1TkHTMissProducer() +{ +} - bool PrimaryVtxConstrain; - edm::InputTag L1VertexInputTag; // used only when PrimaryVtxConstrain = True. - float DeltaZ; +/////////// +// producer +void L1TkHTMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + + // ---------------------------------------------------------------------------------------------- + // output container + // ---------------------------------------------------------------------------------------------- -}; + std::auto_ptr result(new L1TkHTMissParticleCollection); -// -// constants, enums and typedefs -// + // ---------------------------------------------------------------------------------------------- + // retrieve input containers + // ---------------------------------------------------------------------------------------------- -// -// static data member definitions -// + // L1 primary vertex + edm::Handle L1VertexHandle; + iEvent.getByLabel(L1VertexInputTag,L1VertexHandle); + std::vector::const_iterator vtxIter; + + // L1 track-trigger jets + edm::Handle L1TkJetsHandle; + iEvent.getByLabel(L1TkJetInputTag,L1TkJetsHandle); + std::vector::const_iterator jetIter; + -// -// constructors and destructor -// -L1TkHTMissProducer::L1TkHTMissProducer(const edm::ParameterSet& iConfig) -{ - //register your products - //now do what ever other initialization is needed + if ( ! L1TkJetsHandle.isValid() ) { + LogError("L1TkHTMissProducer") + << "\nWarning: L1TkJetParticleCollection with " << L1TkJetInputTag + << "\nrequested in configuration, but not found in the event. Exit" + << std::endl; + return; + } - L1TkJetInputTag = iConfig.getParameter("L1TkJetInputTag"); - DeltaZ = (float)iConfig.getParameter("DeltaZ"); - L1VertexInputTag = iConfig.getParameter("L1VertexInputTag") ; - PrimaryVtxConstrain = iConfig.getParameter("PrimaryVtxConstrain"); + // ---------------------------------------------------------------------------------------------- + // if PrimaryVtxConstrain, use the primary vertex instead of z position from leading jet + // ---------------------------------------------------------------------------------------------- - produces(); + float evt_zvtx = 999; + bool found_vtx = false; -} + edm::Ref< L1TkPrimaryVertexCollection > L1VtxRef; // null reference + if ( DoVtxConstrain && PrimaryVtxConstrain ) { + if( !L1VertexHandle.isValid() ) { + LogError("L1TkHTMissProducer") + << "\nWarning: L1TkPrimaryVertexCollection with " << L1VertexInputTag + << "\nrequested in configuration, but not found in the event. Exit." + << std::endl; + return ; + } + else { + std::vector::const_iterator vtxIter = L1VertexHandle->begin(); + // by convention, the first vertex in the collection is the one that should + // be used by default + evt_zvtx = vtxIter->getZvertex(); + found_vtx = true; + int ivtx = 0; + edm::Ref< L1TkPrimaryVertexCollection > vtxRef( L1VertexHandle, ivtx ); + L1VtxRef = vtxRef; + } + } //endif PrimaryVtxConstrain -L1TkHTMissProducer::~L1TkHTMissProducer() -{ - - // do anything here that needs to be done at desctruction time - // (e.g. close files, deallocate resources etc.) -} + // ---------------------------------------------------------------------------------------------- + // using z position of leading jet to define "event vertex" + // ---------------------------------------------------------------------------------------------- + float zvtx_jetpt = -1.0; //pt of jet determining the event vertex + float JET_VTXMAX = 99.; //find z position of leading jet that has a z vertex! -// -// member functions -// + if ( DoVtxConstrain && !PrimaryVtxConstrain ) { -// ------------ method called to produce the data ------------ -void -L1TkHTMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) -{ - using namespace edm; - - std::auto_ptr result(new L1TkHTMissParticleCollection); - - edm::Handle L1VertexHandle; - iEvent.getByLabel(L1VertexInputTag,L1VertexHandle); - std::vector::const_iterator vtxIter; - - edm::Handle L1TkJetsHandle; - iEvent.getByLabel(L1TkJetInputTag,L1TkJetsHandle); - std::vector::const_iterator jetIter; - - - if ( ! L1TkJetsHandle.isValid() ) { - LogError("L1TkHTMissProducer") - << "\nWarning: L1TkJetParticleCollection with " << L1TkJetInputTag - << "\nrequested in configuration, but not found in the event. Exit" - << std::endl; - return; - } - - float zvtx = -999; - - edm::Ref< L1TkPrimaryVertexCollection > L1VtxRef; // null reference - - if ( PrimaryVtxConstrain ) { - if( !L1VertexHandle.isValid() ) - { - LogError("L1TkHTMissProducer") - << "\nWarning: L1TkPrimaryVertexCollection with " << L1VertexInputTag - << "\nrequested in configuration, but not found in the event. Exit." - << std::endl; - return ; - } - else { - std::vector::const_iterator vtxIter = L1VertexHandle->begin(); - // by convention, the first vertex in the collection is the one that should - // be used by default - zvtx = vtxIter -> getZvertex(); - int ivtx = 0; - edm::Ref< L1TkPrimaryVertexCollection > vtxRef( L1VertexHandle, ivtx ); - L1VtxRef = vtxRef; + for (jetIter = L1TkJetsHandle->begin(); jetIter != L1TkJetsHandle->end(); ++jetIter) { + + // only consider jets from the central BX + int ibx = jetIter->bx(); + if (ibx != 0) continue; + + float tmp_jet_vtx = jetIter->getJetVtx(); + float tmp_jet_pt = jetIter->pt(); + float tmp_jet_eta = jetIter->eta(); + //float tmp_jet_phi = jetIter->phi(); + + if (tmp_jet_pt < JET_PTMIN) continue; + if (fabs(tmp_jet_eta) > JET_ETAMAX) continue; + if (fabs(tmp_jet_vtx) > JET_VTXMAX) continue; + + // find vertex position of leading jet + if (tmp_jet_pt > zvtx_jetpt) { + evt_zvtx = tmp_jet_vtx; + zvtx_jetpt = tmp_jet_pt; + found_vtx = true; } - } //endif PrimaryVtxConstrain + }//end loop over jets - float sumPx = 0; - float sumPy = 0; - float etTot = 0; // HT + }//endif z position from leading jet - for (jetIter = L1TkJetsHandle->begin(); jetIter != L1TkJetsHandle->end(); ++jetIter) { - int ibx = jetIter -> bx(); + float sumPx = 0; + float sumPy = 0; + float etTot = 0; //HT + + + if (DoVtxConstrain) { + if (!found_vtx) std::cout << "WARNING from L1TkHTMissProducer: didn't find any z vertex (based on jet vertices) for this event!" << std::endl; + } + + + + // ---------------------------------------------------------------------------------------------- + // loop over jets + // ---------------------------------------------------------------------------------------------- + + for (jetIter = L1TkJetsHandle->begin(); jetIter != L1TkJetsHandle->end(); ++jetIter) { + + // only consider jets from the central BX + int ibx = jetIter->bx(); if (ibx != 0) continue; + + float px = jetIter->px(); + float py = jetIter->py(); + float et = jetIter->et(); + float tmp_jet_vtx = jetIter->getJetVtx(); + float tmp_jet_pt = jetIter->pt(); + float tmp_jet_eta = jetIter->eta(); + //float tmp_jet_phi = jetIter->phi(); + + if (tmp_jet_pt < JET_PTMIN) continue; + if (fabs(tmp_jet_eta) > JET_ETAMAX) continue; - float px = jetIter -> px(); - float py = jetIter -> py(); - float et = jetIter -> et(); - float jetVtx = jetIter -> getJetVtx(); + + // vertex consistency requirement + bool VtxRequirement = false; + if (found_vtx) VtxRequirement = fabs(tmp_jet_vtx - evt_zvtx) < DeltaZ; - // vertex consistency requirement : - // here I use the zvtx from the primary vertex - bool VtxRequirement = fabs( jetVtx - zvtx ) < DeltaZ ; - - if (VtxRequirement) { - sumPx += px; - sumPy += py; - etTot += et; + if (!DoVtxConstrain || VtxRequirement) { + sumPx += px; + sumPy += py; + etTot += et; } - } // end loop over jets + + }//end loop over jets - float et = sqrt( sumPx*sumPx + sumPy*sumPy ); // HTM - math::XYZTLorentzVector missingEt( -sumPx, -sumPy, 0, et); - edm::RefProd jetCollRef(L1TkJetsHandle) ; + // ---------------------------------------------------------------------------------------------- + // define missing HT + // ---------------------------------------------------------------------------------------------- - L1TkHTMissParticle tkHTM( missingEt, - etTot, - jetCollRef, - L1VtxRef ); + float et = sqrt(sumPx*sumPx + sumPy*sumPy); + math::XYZTLorentzVector missingEt(-sumPx, -sumPy, 0, et); -/* - // in case no primary vtx is used, need to set the zvtx that was - // used in the consistency requirement (e.g. the zvtx of the - // leading jet) + edm::RefProd jetCollRef(L1TkJetsHandle); + L1TkHTMissParticle tkHTM(missingEt, etTot, jetCollRef, L1VtxRef); - if (! PrimaryVtxConstrain) { - tkHTM -> setVtx ( zvtx_used ); - } -*/ + if (DoVtxConstrain && !PrimaryVtxConstrain) { + tkHTM.setVtx(evt_zvtx); + } - result -> push_back( tkHTM ); + result->push_back(tkHTM); + iEvent.put(result); - iEvent.put( result); } @@ -219,12 +276,12 @@ L1TkHTMissProducer::endJob() { } // ------------ method called when starting to processes a run ------------ +/* void L1TkHTMissProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) { - - } +*/ // ------------ method called when ending the processing of a run ------------ /* diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc index 4c0e82df2cd55..2d482255d0d0f 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc @@ -1,9 +1,9 @@ -// -*- C++ -*- -// -// -// Producer of a L1TkJetParticle. -// Dummy code below. To be filled by Louise. -// +/////////////////////////////////////////////////////////////////////////// +// // +// Producer of L1TkJetParticle, // +// associating L1 jets to a z vertex using nearby L1 tracks // +// // +/////////////////////////////////////////////////////////////////////////// // system include files #include @@ -27,117 +27,376 @@ #include "DataFormats/Math/interface/LorentzVector.h" - -// for L1Tracks: +// L1 tracks //#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" #include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + +// geometry +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerDetUnit.h" +#include "DataFormats/SiPixelDetId/interface/StackedTrackerDetId.h" + + #include #include "TMath.h" +#include "TH1.h" +using namespace l1extra; +using namespace edm; +using namespace std; -using namespace l1extra ; -// -// class declaration -// - -class L1TkJetProducer : public edm::EDProducer { - public: +////////////////////////////// +// // +// CLASS DEFINITION // +// // +////////////////////////////// +class L1TkJetProducer : public edm::EDProducer +{ +public: + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - - explicit L1TkJetProducer(const edm::ParameterSet&); - ~L1TkJetProducer(); - - static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); - - private: - virtual void beginJob() ; - virtual void produce(edm::Event&, const edm::EventSetup&); - virtual void endJob() ; - - //virtual void beginRun(edm::Run&, edm::EventSetup const&); - //virtual void endRun(edm::Run&, edm::EventSetup const&); - //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); - //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); - - // ----------member data --------------------------- - edm::InputTag L1CentralJetInputTag; - edm::InputTag L1TrackInputTag; - -} ; - - -// -// constructors and destructor -// + + explicit L1TkJetProducer(const edm::ParameterSet&); + ~L1TkJetProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + +private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + //virtual void beginRun(edm::Run&, edm::EventSetup const&); + //virtual void endRun(edm::Run&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // member data + edm::InputTag L1CentralJetInputTag; + edm::InputTag L1TrackInputTag; + + // track selection criteria + float TRK_ZMAX; // [cm] + float TRK_CHI2MAX; // maximum track chi2 + float TRK_PTMIN; // [GeV] + float TRK_ETAMAX; // [rad] + int TRK_NSTUBMIN; // minimum number of stubs + int TRK_NSTUBPSMIN; // minimum number of stubs in PS modules + + // jet cut + //bool JET_HLTETA; // temporary hack to remove bad jets when using HI HLT jets! + + + // geometry for stub info + const StackedTrackerGeometry* theStackedGeometry; + +}; + +////////////// +// constructor L1TkJetProducer::L1TkJetProducer(const edm::ParameterSet& iConfig) { - - L1CentralJetInputTag = iConfig.getParameter("L1CentralJetInputTag") ; - L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); - - produces("Central"); - + + L1CentralJetInputTag = iConfig.getParameter("L1CentralJetInputTag"); + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + + produces("Central"); + + TRK_ZMAX = (float)iConfig.getParameter("TRK_ZMAX"); + TRK_CHI2MAX = (float)iConfig.getParameter("TRK_CHI2MAX"); + TRK_PTMIN = (float)iConfig.getParameter("TRK_PTMIN"); + TRK_ETAMAX = (float)iConfig.getParameter("TRK_ETAMAX"); + TRK_NSTUBMIN = (int)iConfig.getParameter("TRK_NSTUBMIN"); + TRK_NSTUBPSMIN = (int)iConfig.getParameter("TRK_NSTUBPSMIN"); + //JET_HLTETA = (bool)iConfig.getParameter("JET_HLTETA"); + } +///////////// +// destructor L1TkJetProducer::~L1TkJetProducer() { } -// ------------ method called to produce the data ------------ -void -L1TkJetProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +/////////// +// producer +void L1TkJetProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { - using namespace edm; - std::auto_ptr cenTkJets(new L1TkJetParticleCollection); + + // ---------------------------------------------------------------------------------------------- + // output container + // ---------------------------------------------------------------------------------------------- + + std::auto_ptr cenTkJets(new L1TkJetParticleCollection); + + + // ---------------------------------------------------------------------------------------------- + // retrieve input containers + // ---------------------------------------------------------------------------------------------- + + // L1 jets + edm::Handle CentralJetHandle; + iEvent.getByLabel(L1CentralJetInputTag,CentralJetHandle); + std::vector::const_iterator jetIter; + + // L1 tracks + edm::Handle L1TkTrackHandle; + iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); + L1TkTrackCollectionType::const_iterator trackIter; + + // geometry handles (for stub info) + edm::ESHandle StackedGeometryHandle; + iSetup.get< StackedTrackerGeometryRecord >().get(StackedGeometryHandle); + theStackedGeometry = StackedGeometryHandle.product(); + + + // ---------------------------------------------------------------------------------------------- + // central jets (i.e. |eta| < 3) + // ---------------------------------------------------------------------------------------------- + + if ( !CentralJetHandle.isValid() ) { + LogError("L1TkJetProducer") + << "\nWarning: L1JetParticleCollection with " << L1CentralJetInputTag + << "\nrequested in configuration, but not found in the event." + << std::endl; + } + else { + + // ---------------------------------------------------------------------------------------------- + // loop over jets + // ---------------------------------------------------------------------------------------------- + + // make these configurable ?? + float max_deltaR = 0.4; + float max_z0_outlier1 = 5; //cm + float max_z0_outlier2 = 2; //cm + //cout << "Using outlier removal (1) |dz| < " << max_z0_outlier1 << " cm, and (2) |dz| < " << max_z0_outlier2 << " cm..." << endl; + + float trk_sum_z0 = 0; + float trk_sum_pt = 0; + float jet_z0_v0 = 999; + float jet_z0_v1 = 999; + float jet_z0_v2 = 999; + + float sumTrk_pt = 0; - edm::Handle CentralJetHandle; - iEvent.getByLabel(L1CentralJetInputTag,CentralJetHandle); - std::vector::const_iterator jetIter ; + int ijet = 0; + for (jetIter = CentralJetHandle->begin(); jetIter != CentralJetHandle->end(); ++jetIter) { - edm::Handle L1TkTrackHandle; - iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); - L1TkTrackCollectionType::const_iterator trackIter; + edm::Ref< L1JetParticleCollection > jetRef(CentralJetHandle, ijet); + ijet++; + + // kinematics + //float tmp_jet_pt = jetIter->pt(); + float tmp_jet_eta = jetIter->eta(); + float tmp_jet_phi = jetIter->phi(); + + // for HI-HLT jets, remove jets from "hot spots" + //if (JET_HLTETA) { + //if ( (tmp_jet_eta > -2.0) && (tmp_jet_eta < -1.5) && (tmp_jet_phi > -1.7) && (tmp_jet_phi < -1.3) ) continue; + //if ( (tmp_jet_eta > 0.0) && (tmp_jet_eta < 1.4) && (tmp_jet_phi > -2.0) && (tmp_jet_phi < -1.6) ) continue; + //} + + // only consider jets from the central BX + int ibx = jetIter->bx(); + if (ibx != 0) continue; + + + // ---------------------------------------------------------------------------------------------- + // calculate the vertex of the jet + // ---------------------------------------------------------------------------------------------- + + float this_zpos = 999.; + bool this_continue = true; + + TH1F* h_start_trk = new TH1F("start_trk", "; z_{0} [cm]; # tracks / 2cm", 25,-25,25); + + sumTrk_pt = 0; + + std::vector v_trk_pt; + std::vector v_trk_z0; + + + // ---------------------------------------------------------------------------------------------------------------- + // track loop + // ---------------------------------------------------------------------------------------------------------------- + + std::vector< edm::Ptr< L1TkTrackType > > L1TrackPtrs; + int itrk = -1; + + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { + + itrk++; + + float tmp_trk_pt = trackIter->getMomentum().perp(); + float tmp_trk_eta = trackIter->getMomentum().eta(); + float tmp_trk_phi = trackIter->getMomentum().phi(); + float tmp_trk_z0 = trackIter->getPOCA().z(); + float tmp_trk_chi2 = trackIter->getChi2(); + + // get pointers to stubs associated to the L1 track + //std::vector< edm::Ptr< L1TkStub_PixelDigi_ > > theStubs = trackIter->getStubPtrs(); + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubs = trackIter -> getStubRefs() ; + + int tmp_trk_nstub = (int) theStubs.size(); + //int tmp_ndof = tmp_trk_nstub*2-4; + + // track selection + if (fabs(tmp_trk_eta) > TRK_ETAMAX) continue; + if (tmp_trk_pt < TRK_PTMIN) continue; + if (fabs(tmp_trk_z0) > TRK_ZMAX) continue; + if (tmp_trk_chi2 > TRK_CHI2MAX) continue; + if (tmp_trk_nstub < TRK_NSTUBMIN) continue; + + // loop over the stubs + int tmp_trk_nstubPS = 0; + for (unsigned int istub=0; istub<(unsigned int)theStubs.size(); istub++) { + StackedTrackerDetId detIdStub(theStubs.at(istub)->getDetId()); + bool tmp_isPS = theStackedGeometry->isPSModule(detIdStub); + if (tmp_isPS) tmp_trk_nstubPS++; + } - // central jets (i.e. |eta| < 3) + // more track selection + if (tmp_trk_nstubPS < TRK_NSTUBPSMIN) continue; + + + // deltaR + float deltaEta = fabs(tmp_jet_eta-tmp_trk_eta); + float deltaPhi = fabs(tmp_jet_phi-tmp_trk_phi); + while (deltaPhi > 3.14159) deltaPhi = fabs(2*3.14159 - deltaPhi); + float deltaR = sqrt( deltaEta*deltaEta + deltaPhi*deltaPhi ); + + if (deltaR < max_deltaR) { //use tracks within deltaR < max_deltaR of the jet + v_trk_z0.push_back(tmp_trk_z0); + v_trk_pt.push_back(tmp_trk_pt); + sumTrk_pt += tmp_trk_pt; + + edm::Ptr< L1TkTrackType > trkPtr( L1TkTrackHandle, itrk) ; + L1TrackPtrs.push_back(trkPtr); + + h_start_trk->Fill(tmp_trk_z0); + } - if( !CentralJetHandle.isValid() ) - { - LogError("L1TkJetProducer") - << "\nWarning: L1JetParticleCollection with " << L1CentralJetInputTag - << "\nrequested in configuration, but not found in the event." - << std::endl; + }//end track loop + // ---------------------------------------------------------------------------------------------------------------- + + jet_z0_v0 = 999; + jet_z0_v1 = 999; + jet_z0_v2 = 999; + + int ntrkCone = v_trk_z0.size(); + + // ---------------------------------------------------------------------------------------------------------------- + // STEP (0) + // ---------------------------------------------------------------------------------------------------------------- + if (ntrkCone < 1) { + this_zpos = 999.; + this_continue = false; + h_start_trk->Delete(); + } + + if (this_continue) { + + // ---------------------------------------------------------------------------------------------------------------- + // STEP (1) + // ---------------------------------------------------------------------------------------------------------------- + trk_sum_z0 = 0; + trk_sum_pt = 0; + for (int k=0; kGetBinCenter(h_start_trk->GetMaximumBin()); + h_start_trk->Delete(); + + + // ---------------------------------------------------------------------------------------------------------------- + // STEP (3) + // ---------------------------------------------------------------------------------------------------------------- + for (int k=0; k max_z0_outlier1) { + trk_sum_z0 -= v_trk_z0.at(k)*v_trk_pt.at(k); + trk_sum_pt -= v_trk_pt.at(k); + v_trk_z0.erase(v_trk_z0.begin()+k); + v_trk_pt.erase(v_trk_pt.begin()+k); + k--; + ntrkCone--; + } + } + + if (ntrkCone < 1) { + this_zpos = 999.; + this_continue = false; + } + } + + if (this_continue) { + + // ---------------------------------------------------------------------------------------------------------------- + // STEP (4) + // ---------------------------------------------------------------------------------------------------------------- + jet_z0_v1 = trk_sum_z0/trk_sum_pt; + + // ---------------------------------------------------------------------------------------------------------------- + // STEP (5) + // ---------------------------------------------------------------------------------------------------------------- + for (int k=0; k max_z0_outlier2) { + trk_sum_z0 -= v_trk_z0.at(k)*v_trk_pt.at(k); + trk_sum_pt -= v_trk_pt.at(k); + v_trk_z0.erase(v_trk_z0.begin()+k); + v_trk_pt.erase(v_trk_pt.begin()+k); + k--; + ntrkCone--; + } } - else { + + if (ntrkCone < 1) { + this_zpos = 999.; + this_continue = false; + } + } + + if (this_continue) { + + // ---------------------------------------------------------------------------------------------------------------- + // STEP (6) + // ---------------------------------------------------------------------------------------------------------------- + jet_z0_v2 = trk_sum_z0/trk_sum_pt; + this_zpos = jet_z0_v2; + + } + - int ijet = 0; - for (jetIter = CentralJetHandle->begin(); jetIter != CentralJetHandle->end(); ++jetIter) { - edm::Ref< L1JetParticleCollection > JetRef( CentralJetHandle, ijet ); - ijet ++; + // ---------------------------------------------------------------------------------------------- + // end of jet loop, create the L1TkJetParticle and push to collection + // ---------------------------------------------------------------------------------------------- - int ibx = jetIter -> bx(); - if (ibx != 0) continue; + const math::XYZTLorentzVector jetP4 = jetIter->p4(); + L1TkJetParticle trkJet(jetP4, jetRef, L1TrackPtrs, this_zpos); + + cenTkJets->push_back(trkJet); - // calculate the vertex of the jet. Here dummy. - float jetvtx = -999; - const math::XYZTLorentzVector P4 = jetIter -> p4() ; - L1TkJetParticle trkJet( P4, - JetRef, - jetvtx ); + } //end loop over jets + } //endif CentralJetHandle.isValid() - cenTkJets -> push_back( trkJet ); - } // end loop over Jet objects - } // endif CentralJetHandle.isValid() + iEvent.put(cenTkJets, "Central"); - iEvent.put( cenTkJets, "Central" ); } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkCaloSequence_cff.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkCaloSequence_cff.py new file mode 100644 index 0000000000000..08babaafee951 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkCaloSequence_cff.py @@ -0,0 +1,47 @@ +import FWCore.ParameterSet.Config as cms + + +# --- for the local calo reconstruction +from Configuration.StandardSequences.Reconstruction_cff import * +towerMaker.hbheInput = cms.InputTag("hbheprereco") +towerMakerWithHO.hbheInput = cms.InputTag("hbheprereco") + + +# --- to reconstruct the HLT HI jets +from RecoHI.HiJetAlgos.HiRecoJets_TTI_cff import * + + +# --- Put the HI HLT jets into "L1Jets" +L1JetsFromHIHLTJets = cms.EDProducer("L1JetsFromHIHLTJets", + ETAMIN = cms.double(0), + ETAMAX = cms.double(3.), + HIJetsInputTag = cms.InputTag("iterativeConePu5CaloJets") +) + +# --- Produce L1TkJets +from SLHCUpgradeSimulations.L1TrackTrigger.L1TkJetProducer_cfi import L1TkJets +L1TkJetsHI = L1TkJets.clone() +L1TkJetsHI.L1CentralJetInputTag = cms.InputTag("L1JetsFromHIHLTJets") +L1TkJetsHI.JET_HLTETA = cms.bool(True) + + +# --- Produce HT and MHT with and without the vertex constraint +from SLHCUpgradeSimulations.L1TrackTrigger.L1TkHTMissProducer_cfi import * + +L1TkHTMissCaloHI = L1TkHTMissCalo.clone() +L1TkHTMissCaloHI.L1TkJetInputTag = cms.InputTag("L1TkJetsHI","Central") + +L1TkHTMissVtxHI = L1TkHTMissVtx.clone() +L1TkHTMissVtxHI.L1TkJetInputTag = cms.InputTag("L1TkJetsHI","Central") + + +# --- the full sequence with the L1Jets : +L1TkCaloSequence = cms.Sequence( L1TkJets + L1TkHTMissCalo + L1TkHTMissVtx ) + +# --- the full sequence with the HLT HI jets : +L1TkCaloSequenceHI = cms.Sequence( calolocalreco + hiRecoJets + L1JetsFromHIHLTJets + L1TkJetsHI + L1TkHTMissCaloHI + L1TkHTMissVtxHI ) + +# --- a sequence to just reconstruct the HLT HI jets : +L1TkHIJets = cms.Sequence( calolocalreco + hiRecoJets + L1JetsFromHIHLTJets + L1TkJetsHI) + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronStubProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronStubProducer_cfi.py new file mode 100644 index 0000000000000..529d002acf2f1 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronStubProducer_cfi.py @@ -0,0 +1,42 @@ + +import FWCore.ParameterSet.Config as cms + +L1TkStubElectrons = cms.EDProducer("L1TkElectronStubsProducer", + label = cms.string("EG"), # labels the collection of L1TkEmParticleProducer that is produced. + # e.g. EG or IsoEG if all objects are kept, or + # EGIsoTrk or IsoEGIsoTrk if only the EG or IsoEG + # objects that pass a cut RelIso < RelIsoCut are written + # into the new collection. + L1EGammaInputTag = cms.InputTag("SLHCL1ExtraParticlesNewClustering","EGamma"), # input EGamma collection + # When the standard sequences are used : + # - for the Run-1 algo, use ("l1extraParticles","NonIsolated") + # or ("l1extraParticles","Isolated") + # - for the "old stage-2" algo (2x2 clustering), use + # ("SLHCL1ExtraParticles","EGamma") or ("SLHCL1ExtraParticles","IsoEGamma") + # - for the new clustering algorithm of Jean-Baptiste et al, + # use ("SLHCL1ExtraParticlesNewClustering","IsoEGamma") or + # ("SLHCL1ExtraParticlesNewClustering","EGamma"). + ETmin = cms.double( -1.0 ), # Only the L1EG objects that have ET > ETmin in GeV + # are considered. ETmin < 0 means that no cut is applied. + L1StubInputTag = cms.InputTag("TTStubsFromPixelDigis", "StubAccepted"), + MCTruthInputTag = cms.InputTag("TTStubAssociatorFromPixelDigis", "StubAccepted"), + StubMinPt = cms.double(5.0), # minimum Pt to select Stubs + StubEGammaDeltaPhi = cms.double(0.05), # delta Phi of stub and EG + StubEGammaDeltaZ = cms.double(15.0), # Z-intercept o + StubEGammaPhiMiss = cms.double(0.0015), # delta Phi between a stub-pair and EG + StubEGammaZMiss = cms.double(0.7), # Z difference between a stub-pair and EG + BeamSpotInputTag = cms.InputTag("BeamSpotFromSim", "BeamSpot"), # beam spot InputTag + + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis", "Level1TTTracks"), + RelativeIsolation = cms.bool( True ), # default = True. The isolation variable is relative if True, + # else absolute. + IsoCut = cms.double( -0.15 ), # Cut on the (Trk-based) isolation: only the L1TkEmParticle for which + # the isolation is below RelIsoCut are written into + # the output collection. When RelIsoCut < 0, no cut is applied. + # When RelativeIsolation = False, IsoCut is in GeV. + # Determination of the isolation w.r.t. L1Tracks : + PTMINTRA = cms.double( 2. ), # in GeV + DRmin = cms.double( 0.05), + DRmax = cms.double( 0.4 ), + DeltaZ = cms.double( 0.4 ) # in cm. Used for tracks to be used isolation calculation +) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py index 8b2fa10c7977d..6a7e7a0583676 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py @@ -19,7 +19,7 @@ TrackChi2 = cms.double(100.0), # minimum Chi2 to select tracks TrackMinPt = cms.double(12.0), # minimum Pt to select tracks TrackEGammaDeltaPhi = cms.vdouble(0.05, 0.0, 0.0), # functional Delta Phi cut parameters to match Track with L1EG objects - TrackEGammaDeltaR = cms.vdouble(0.08, 0.0, 0.0), # functional Delta R cut parameters to match Track with L1EG objects + TrackEGammaDeltaR = cms.vdouble(0.08, 0.0, 0.0), # functional Delta R cut parameters to match Track with L1EG objects TrackEGammaDeltaEta = cms.double(0.08), # Delta Eta cutoff to match Track with L1EG objects # are considered. RelativeIsolation = cms.bool( True ), # default = True. The isolation variable is relative if True, @@ -34,9 +34,8 @@ DRmax = cms.double( 0.2 ), DeltaZ = cms.double( 0.6 ) # in cm. Used for tracks to be used isolation calculation ) - - +# for LowPt Electron L1TkElectronsLoose = L1TkElectrons.clone() -L1TkElectronsLoose.TrackEGammaDeltaPhi = cms.vdouble(0.08, 0.0, 0.0) +L1TkElectronsLoose.TrackEGammaDeltaPhi = cms.vdouble(0.07, 0.0, 0.0) L1TkElectronsLooseTrackEGammaDeltaR = cms.vdouble(0.12, 0.0, 0.0) L1TkElectronsLoose.TrackMinPt = cms.double( 3.0 ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkHTMissProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkHTMissProducer_cfi.py new file mode 100644 index 0000000000000..c8c120f7b5dc4 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkHTMissProducer_cfi.py @@ -0,0 +1,17 @@ +import FWCore.ParameterSet.Config as cms + +L1TkHTMissCalo = cms.EDProducer("L1TkHTMissProducer", + L1TkJetInputTag = cms.InputTag("L1TkJets","Central"), + JET_ETAMAX = cms.double(2.2), # maximum eta of jets for HT + JET_PTMIN = cms.double(15.0), # minimum pt of jets for HT [GeV] + DoVtxConstrain = cms.bool(False), # turn on/off applying any vertex constraint + DeltaZ = cms.double(1.0), # require jets to have |z_jet - z_ref| below DeltaZ [cm] + PrimaryVtxConstrain = cms.bool(False), # use primary vertex instead of leading jet as reference z position + L1VertexInputTag = cms.InputTag("L1TkPrimaryVertex") +) + +L1TkHTMissVtx = L1TkHTMissCalo.clone() +L1TkHTMissVtx.DoVtxConstrain = cms.bool( True ) + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py new file mode 100644 index 0000000000000..0eee5fb668a1e --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py @@ -0,0 +1,14 @@ +import FWCore.ParameterSet.Config as cms + +L1TkJets = cms.EDProducer("L1TkJetProducer", + #L1CentralJetInputTag = cms.InputTag("L1TowerJetPUSubtractedProducer","PUSubCen8x8"), + L1CentralJetInputTag = cms.InputTag("L1CalibFilterTowerJetProducer","CalibratedTowerJets"), # new L1Jets + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + TRK_ZMAX = cms.double(25.), # max track z0 [cm] + TRK_CHI2MAX = cms.double(100.), # max track chi2 + TRK_PTMIN = cms.double(2.0), # minimum track pt [GeV] + TRK_ETAMAX = cms.double(2.5), # maximum track eta + TRK_NSTUBMIN = cms.int32(4), # minimum number of stubs on track + TRK_NSTUBPSMIN = cms.int32(2), # minimum number of stubs in PS modules on track + #JET_HLTETA = cms.bool(False) # temporary hack, for HLT jets remove jets from bad eta regions +) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronStubMatchAlgo.cc b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronStubMatchAlgo.cc new file mode 100644 index 0000000000000..e31be0cf87a56 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronStubMatchAlgo.cc @@ -0,0 +1,390 @@ +// -*- C++ -*- +// +// Package: L1TrackTrigger +// Class: L1TkElectronStubMatchAlgo +// +/**\class L1TkElectronStubMatchAlgo + + Description: Algorithm to match L1EGamma oject with L1Track candidates + + Implementation: + [Notes on implementation] +*/ +// +// Original Author: S. Dutta and A. Modak +// Created: Fri Feb 14 14:15:38 CET 2014 +// $Id$ +// +// + + +// system include files +#include +#include + + +#include "DataFormats/Math/interface/deltaPhi.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkElectronStubMatchAlgo.h" +#include "MagneticField/Engine/interface/MagneticField.h" +#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/Utilities/interface/InputTag.h" +#include "DataFormats/BeamSpot/interface/BeamSpot.h" + +#include "SimDataFormats/TrackingAnalysis/interface/TrackingParticle.h" +#include "SimTracker/TrackTriggerAssociation/interface/TTClusterAssociationMap.h" +#include "SimTracker/TrackTriggerAssociation/interface/TTStubAssociationMap.h" + +namespace L1TkElectronStubMatchAlgo { + const double rcal = 129.0; + double radii[7] = {0.0, 23.0, 35.7, 50.8, 68.6, 88.8, 108.0}; + // ------------ match EGamma and Track + unsigned int doMatch(l1extra::L1EmParticleCollection::const_iterator egIter, const edm::ParameterSet& conf, const edm::EventSetup& setup, edm::Event & iEvent, std::vector& zvals) { + + double ptMinCutoff = conf.getParameter("StubMinPt"); + double dPhiCutoff = conf.getParameter("StubEGammaDeltaPhi"); + double dZCutoff = conf.getParameter("StubEGammaDeltaZ"); + double phiMissCutoff = conf.getParameter("StubEGammaPhiMiss"); + double zMissCutoff = conf.getParameter("StubEGammaZMiss"); + + edm::InputTag L1StubInputTag = conf.getParameter("L1StubInputTag"); + edm::InputTag BeamSpotInputTag = conf.getParameter("BeamSpotInputTag"); + edm::InputTag MCTruthStubInputTag = conf.getParameter("MCTruthInputTag"); + + GlobalPoint egPos = L1TkElectronStubMatchAlgo::calorimeterPosition(egIter->phi(), egIter->eta(), egIter->energy()); + + edm::Handle< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > > > stubHandle; + iEvent.getByLabel(L1StubInputTag, stubHandle); + + edm::Handle BeamSpotHandle; + iEvent.getByLabel(BeamSpotInputTag, BeamSpotHandle); + const GlobalPoint bspot(BeamSpotHandle->x0(),BeamSpotHandle->y0(),BeamSpotHandle->z0()); + + // Magnetic Field + double magnetStrength; + edm::ESHandle theMagField; + setup.get().get(theMagField); + magnetStrength = theMagField.product()->inTesla(GlobalPoint(0,0,0)).z(); + + edm::ESHandle stackedGeometryHandle; + setup.get().get(stackedGeometryHandle); + + edm::Handle< TTStubAssociationMap< Ref_PixelDigi_ > > mcTruthTTStubHandle; + iEvent.getByLabel(MCTruthStubInputTag, mcTruthTTStubHandle ); + + stubRefCollection preSelectedStubs; + for (edmNew::DetSetVector< TTStub >::const_iterator it = stubHandle->begin(); + it != stubHandle->end();++it) { + for (edmNew::DetSet >::const_iterator jt = it->begin(); + jt != it->end(); ++jt) { + /// Make the reference + stubRef stub_ref = edmNew::makeRefTo(stubHandle, jt); + + StackedTrackerDetId stackedDetId(stub_ref->getDetId()); + + // Store Track information in maps, skip if the Cluster is not good + bool isGenuine = mcTruthTTStubHandle->isGenuine(stub_ref); + if (!isGenuine) continue; + float stub_pt = stackedGeometryHandle->findRoughPt(magnetStrength,&(*stub_ref)); + unsigned int ilayer = getLayerId(stackedDetId); + if ((ilayer%10) > 3) continue; + + double r = stackedGeometryHandle->findGlobalPosition(&(*stub_ref)).perp(); + double phi = stackedGeometryHandle->findGlobalPosition(&(*stub_ref)).phi(); + double z = stackedGeometryHandle->findGlobalPosition(&(*stub_ref)).z(); + + + double dPhi = getDPhi(egPos, egIter->et(), r, phi, magnetStrength); + double zIntercept = getZIntercept(egPos, r, z); + double scaledZInterceptCut; + double scaledDPhiCut; + double scaledPtMinCut; + if (fabs(egIter->eta()) < 1.1) { + // if (ilayer < 10) { + scaledZInterceptCut = getScaledZInterceptCut(ilayer,dZCutoff, 0.75, egPos.eta()); + scaledDPhiCut = dPhiCutoff; + scaledPtMinCut = ptMinCutoff; + } else { + scaledDPhiCut = 1.6* dPhiCutoff; + scaledZInterceptCut = dZCutoff; + scaledPtMinCut = ptMinCutoff; + } + if (scaledPtMinCut > 0.0 && stub_pt <= scaledPtMinCut) continue; + + if ( (fabs(dPhi) < scaledDPhiCut) && + (fabs(zIntercept)< scaledZInterceptCut) ) preSelectedStubs.push_back(stub_ref); + } + } + sort( preSelectedStubs.begin(), preSelectedStubs.end(), compareStubLayer); + int ncount = 0; + // Get two-point stubs + for (std::vector::const_iterator istub1 = preSelectedStubs.begin(); istub1 != preSelectedStubs.end(); istub1++) { + for (std::vector::const_iterator istub2 = istub1+1; istub2 != preSelectedStubs.end(); istub2++) { + + StackedTrackerDetId stackedDetId1((*istub1)->getDetId()); + StackedTrackerDetId stackedDetId2((*istub2)->getDetId()); + + unsigned layer1 = getLayerId(stackedDetId1); + unsigned layer2 = getLayerId(stackedDetId2); + + if (layer1 >= layer2) continue; + bool barrel = true; + if (layer2 > 10) barrel = false; + + double innerZ = stackedGeometryHandle->findGlobalPosition(&(*(*istub1))).z(); + double outerZ = stackedGeometryHandle->findGlobalPosition(&(*(*istub2))).z(); + double innerR = stackedGeometryHandle->findGlobalPosition(&(*(*istub1))).perp(); + double outerR = stackedGeometryHandle->findGlobalPosition(&(*(*istub2))).perp(); + double innerPhi = stackedGeometryHandle->findGlobalPosition(&(*(*istub1))).phi(); + double outerPhi = stackedGeometryHandle->findGlobalPosition(&(*(*istub2))).phi(); + + GlobalPoint s1pos(stackedGeometryHandle->findGlobalPosition(&(*(*istub1))).x()-bspot.x(), + stackedGeometryHandle->findGlobalPosition(&(*(*istub1))).y()-bspot.y(), + stackedGeometryHandle->findGlobalPosition(&(*(*istub1))).z()-bspot.z()); + + GlobalPoint s2pos(stackedGeometryHandle->findGlobalPosition(&(*(*istub2))).x()-bspot.x(), + stackedGeometryHandle->findGlobalPosition(&(*(*istub2))).y()-bspot.y(), + stackedGeometryHandle->findGlobalPosition(&(*(*istub2))).z()-bspot.z()); + + + // if (debugFlag_) cout<<"Found "<::const_iterator ip = twoPointCands.begin(); ip != twoPointCands.end(); ip++) { + + if (layer1 > 100 || layer2 > 100) std::cout << " Wrong Layers " << layer1 << " " << layer2 << std::endl; + + + if(!goodTwoPointPhi(innerR, outerR, innerPhi, outerPhi, magnetStrength)) continue; + if(!goodTwoPointZ(innerR, outerR, innerZ, outerZ)) continue; + + double zMiss = getZMiss(egPos, innerR, outerR, innerZ, outerZ, barrel); + double phiMiss = getPhiMiss(egIter->et(), s1pos, s2pos); + + double phiMissScaledCut = phiMissCutoff; + if (fabs(egPos.eta()) >= 1.1) { + if (layer1 <= 3 && layer2 <= 3) phiMissScaledCut *= 1.4; + else phiMissScaledCut *= 1.8; + } + double zMissScaledCut; + if (barrel) { + zMissScaledCut = getScaledZMissCut(layer1, layer2,zMissCutoff, 0.04, egPos.eta()); + } else { + zMissScaledCut = 2.0; + } + if(fabs(phiMiss)< phiMissScaledCut && fabs(zMiss) < zMissScaledCut) { + ncount++; + zvals.push_back(getCompatibleZPoint(innerR, outerR, innerZ, outerZ)); + } + } + } + return ncount; + } + + // -------------- get Calorimeter position + GlobalPoint calorimeterPosition(double phi, double eta, double e) { + double x = 0.; + double y = 0.; + double z = 0.; + double depth = 0.89*(7.7+ log(e) ); + double theta = 2*atan(exp(-1*eta)); + double r = 0; + if( fabs(eta) > 1.479 ) + { + double ecalZ = 315.4*fabs(eta)/eta; + + r = ecalZ / cos( 2*atan( exp( -1*eta ) ) ) + depth; + x = r * cos( phi ) * sin( theta ); + y = r * sin( phi ) * sin( theta ); + z = r * cos( theta ); + } + else + { + double rperp = 129.0; + double zface = sqrt( cos( theta ) * cos( theta ) / + ( 1 - cos( theta ) * cos( theta ) ) * + rperp * rperp ) * fabs( eta ) / eta; + r = sqrt( rperp * rperp + zface * zface ) + depth; + x = r * cos( phi ) * sin( theta ); + y = r * sin( phi ) * sin( theta ); + z = r * cos( theta ); + } + GlobalPoint pos(x,y,z); + return pos; + } + // get Layer of a Stub + unsigned int getLayerId(StackedTrackerDetId id) { + unsigned int layer = 999999; + if (id.isBarrel()) { + layer = id.iLayer(); + } else if (id.isEndcap()) { + layer = id.iSide() * 10 + id.iDisk(); + } else { + edm::LogError("L1TkElectronStubMatchAlgo") << "Neither Barrel nor Endcap " << layer << std::endl; + } + if (layer > 100) edm::LogError("L1TkElectronStubMatchAlgo") << " Wrong Layer " << layer << std::endl; + return layer; + } + + // Z-compatibility between two stubs + bool goodTwoPointZ(double innerR, double outerR, double innerZ, double outerZ ) { + + double mIPWidth = 200.0; + double positiveZBoundary = (mIPWidth - outerZ) * (outerR - innerR); + double negativeZBoundary = -(mIPWidth + outerZ) * (outerR - innerR); + double multipliedLocation = (innerZ - outerZ) * outerR; + + + if( multipliedLocation < positiveZBoundary && + multipliedLocation > negativeZBoundary ) + return true; + return false; + } + // Phi-compatibility between two stubs + bool goodTwoPointPhi(double innerR, double outerR, double innerPhi, double outerPhi, double m_strength) { + + // Rebase the angles in terms of 0-2PI, should + if ( innerPhi < 0.0 ) innerPhi += 2.0 * TMath::Pi(); + if ( outerPhi < 0.0 ) outerPhi += 2.0 * TMath::Pi(); + + // Check for seed compatibility given a pt cut + // Threshold computed from radial location of hits + double mCompatibilityScalingFactor = + (100.0 * 2.0e+9 * 2.0) / (TMath::C() * m_strength); + + mCompatibilityScalingFactor = 1.0 / mCompatibilityScalingFactor; + + double deltaPhiThreshold = + (outerR - innerR) * mCompatibilityScalingFactor; + + // Delta phi computed from hit phi locations + double deltaPhi = outerPhi - innerPhi; + if(deltaPhi<0) deltaPhi = -deltaPhi; + + if(deltaPhifabs(b + a)) phiMiss = b + a; + + return phiMiss; + + } + + // ZMiss + double getZMiss(GlobalPoint epos, double r1, double r2, double z1, double z2, bool bar) { + + double er = epos.perp(); + double ez = epos.z(); + + + double missVal ; + if (bar) { + missVal = z2 - (r2*(ez-z1)-r1*ez + + er*z1)/(er-r1); + } else { + missVal = r2 - er - (er-r1)*(z2-ez)/(ez-z1); + } + return missVal; + } + // Z-Intercept Cut + double getScaledZInterceptCut(unsigned int layer, double cut, double cfac, double eta) { + double mult = (rcal-radii[layer])/(rcal-radii[1]); + return (mult*(cut+cfac*(1.0/(1.0-cos(2*atan(exp(-1.0*fabs(eta)))))))); + } + // Z-issCut + double getScaledZMissCut(int layer1, int layer2, double cut, double cfac, double eta) { + double mult = ( (radii[layer2] - radii[layer1])/(rcal-radii[layer1]) )*( (rcal -radii[1])/(radii[2]-radii[1])); + return (mult*(cut+cfac*(1.0/(1.0-cos(2*atan(exp(-1.0*fabs(eta)))))))); + } + bool compareStubLayer(const stubRef& s1, const stubRef& s2) { + unsigned int l1 = 0; + unsigned int l2 = 0; + StackedTrackerDetId stackedDetId1(s1->getDetId()); + StackedTrackerDetId stackedDetId2(s2->getDetId()); + if (stackedDetId1.isBarrel()) { + l1 = stackedDetId1.iLayer(); + } else if (stackedDetId1.isEndcap()) { + l1 = stackedDetId1.iSide() * 10 + stackedDetId1.iDisk(); + } + if (stackedDetId2.isBarrel()) { + l2 = stackedDetId2.iLayer(); + } else if (stackedDetId2.isEndcap()) { + l2 = stackedDetId2.iSide() * 10 + stackedDetId2.iDisk(); + } + return l1 < l2; + } + + bool selectLayers(float eta, int l1, int l2) { + bool select = false; + if ((fabs(eta) < 1.3) && !(l1 < 4 && l2 < 4)) return select; + if ((fabs(eta) >= 1.3 && TMath::Abs(eta) < 1.7) && !( + (l1 == 1 && l2 == 2) || + (l1 == 1 && l2 == 11) || + (l1 == 1 && l2 == 21) || + (l1 == 2 && l2 == 11) || + (l1 == 2 && l2 == 21) || + (l1 == 11 && l2 == 12)|| + (l1 == 21 && l2 == 22))) return select; + if ((fabs(eta) >= 1.7 && TMath::Abs(eta) <= 2.3) && !( + (l1 == 1 && l2 == 11) || + (l1 == 1 && l2 == 12) || + (l1 == 1 && l2 == 21) || + (l1 == 1 && l2 == 22) || + (l1 == 11 && l2 == 12) || + (l1 == 21 && l2 == 22) || + (l1 == 12 && l2 == 13) || + (l1 == 22 && l2 == 23))) return select; + select = true; + return select; + } + double getCompatibleZPoint(double r1, double r2, double z1, double z2) { + return (z1 - r1*(z2-z1)/(r2-r1)); + } +} diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc index 4b2d6b966cb12..d9209b42006e9 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc @@ -41,26 +41,13 @@ namespace L1TkElectronTrackMatchAlgo { // --------------- calculate deltaR between Track and EGamma object double deltaPhi(const GlobalPoint& epos, const edm::Ptr< L1TkTrackType > & pTrk){ double er = epos.perp(); - double curv = pTrk->getRInv(); + double dphi_curv= (asin(er*curv/(2.0))); double trk_phi_ecal = reco::deltaPhi(pTrk->getMomentum().phi(),dphi_curv); double dphi = reco::deltaPhi(trk_phi_ecal,epos.phi()); return dphi; - -/* - double curv = pTrk->getRInv(); - double x1 = (asin(er*curv/(2.0))); - double phi1 = reco::deltaPhi(pTrk->getMomentum().phi(), epos.phi()); - - double dif1 = phi1 - x1; - double dif2 = phi1 + x1; - - if (fabs(dif1) < fabs(dif2)) return dif1; - else return dif2; -*/ - } // --------------- calculate deltaPhi between Track and EGamma object double deltaR(const GlobalPoint& epos, const edm::Ptr< L1TkTrackType > & pTrk){ diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackTriggerObjectsAnalyzer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc similarity index 86% rename from SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackTriggerObjectsAnalyzer.cc rename to SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc index 015aede99789d..bae7f8737d135 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackTriggerObjectsAnalyzer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc @@ -1,9 +1,9 @@ // -*- C++ -*- // -// Package: L1TrackTriggerObjectsAnalyzer -// Class: L1TrackTriggerObjectsAnalyzer +// Package: PrintL1TkObjects +// Class: PrintL1TkObjects // -/**\class L1TrackTriggerObjectsAnalyzer L1TrackTriggerObjectsAnalyzer.cc SLHCUpgradeSimulations/L1TrackTriggerObjectsAnalyzer/src/L1TrackTriggerObjectsAnalyzer.cc +/**\class PrintL1TkObjects PrintL1TkObjects.cc SLHCUpgradeSimulations/PrintL1TkObjects/src/PrintL1TkObjects.cc Description: [one line class summary] @@ -65,14 +65,14 @@ using namespace l1extra; // class declaration // -class L1TrackTriggerObjectsAnalyzer : public edm::EDAnalyzer { +class PrintL1TkObjects : public edm::EDAnalyzer { public: typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - explicit L1TrackTriggerObjectsAnalyzer(const edm::ParameterSet&); - ~L1TrackTriggerObjectsAnalyzer(); + explicit PrintL1TkObjects(const edm::ParameterSet&); + ~PrintL1TkObjects(); static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); @@ -97,6 +97,8 @@ class L1TrackTriggerObjectsAnalyzer : public edm::EDAnalyzer { // for L1TkEmParticles edm::InputTag L1TkPhotonsInputTag; + + // for L1TkElectrons edm::InputTag L1TkElectronsInputTag; // for L1TkJetParticles @@ -117,7 +119,7 @@ class L1TrackTriggerObjectsAnalyzer : public edm::EDAnalyzer { // // constructors and destructor // -L1TrackTriggerObjectsAnalyzer::L1TrackTriggerObjectsAnalyzer(const edm::ParameterSet& iConfig) +PrintL1TkObjects::PrintL1TkObjects(const edm::ParameterSet& iConfig) { //now do what ever initialization is needed @@ -131,7 +133,7 @@ L1TrackTriggerObjectsAnalyzer::L1TrackTriggerObjectsAnalyzer(const edm::Paramete } -L1TrackTriggerObjectsAnalyzer::~L1TrackTriggerObjectsAnalyzer() +PrintL1TkObjects::~PrintL1TkObjects() { // do anything here that needs to be done at desctruction time @@ -146,7 +148,7 @@ L1TrackTriggerObjectsAnalyzer::~L1TrackTriggerObjectsAnalyzer() // ------------ method called for each event ------------ void -L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup) +PrintL1TkObjects::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup) { using namespace edm; @@ -156,12 +158,17 @@ L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::Even edm::Handle HepMCEvt; +std::cout << " ici " << std::endl; iEvent.getByLabel("generator",HepMCEvt); +std::cout << " ici2 " << HepMCEvt.isValid() << std::endl; + + float zvtx_gen = -999; + + if (HepMCEvt.isValid() ) { const HepMC::GenEvent* MCEvt = HepMCEvt->GetEvent(); const double mm=0.1; - float zvtx_gen = -999; for ( HepMC::GenEvent::vertex_const_iterator ivertex = MCEvt->vertices_begin(); ivertex != MCEvt->vertices_end(); ++ivertex ) { bool hasParentVertex = false; @@ -190,7 +197,7 @@ L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::Even } // end loop over gen vertices std::cout << " Generated zvertex : " << zvtx_gen << std::endl; - + } // ---------------------------------------------------------------------- @@ -203,17 +210,11 @@ L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::Even if ( L1VertexHandle.isValid() ) { std::cout << " ----- L1TkPrimaryVertex objects ----- " << std::endl; - int ivtx = 0; - // several algorithms have been run in the L1TkPrimaryVertexProducer - // hence there is a collection of L1 primary vertices. - // the first one is probably the most reliable. - - for (vtxIter = L1VertexHandle->begin(); vtxIter != L1VertexHandle->end(); ++vtxIter) { + vtxIter = L1VertexHandle->begin(); // only one algorithm is run in the L1TkPrimaryVertexProducer + // (in contrast to earlier, under-dev, versions of the code) float z = vtxIter -> getZvertex(); float sum = vtxIter -> getSum(); - std::cout << " a vertex with z = sum " << z << " " << sum << std::endl; - ivtx ++; - } + std::cout << " a vertex with zvtx " << z << " (cm) and SumPT " << sum << " (GeV) " << std::endl; } // @@ -227,13 +228,12 @@ L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::Even if (L1TkEtMissHandle.isValid() ) { std::cout << " ----- L1TkEtMiss objects ----- " << std::endl; - for (etmIter = L1TkEtMissHandle -> begin(); etmIter != L1TkEtMissHandle->end(); ++etmIter) { + etmIter = L1TkEtMissHandle -> begin(); // idem: only one TrkMET now. float etmis = etmIter -> et(); const edm::Ref< L1TkPrimaryVertexCollection > vtxRef = etmIter -> getVtxRef(); float zvtx = vtxRef -> getZvertex(); float etMissPU = etmIter -> etMissPU(); std::cout << " ETmiss = " << etmis << " for zvtx = " << zvtx << " and ETmiss from PU = " << etMissPU << std::endl; - } } @@ -256,11 +256,19 @@ L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::Even float jetvtx = jetIter -> getJetVtx(); const edm::Ref< L1JetParticleCollection > Jetref = jetIter -> getJetRef(); float et_L1Jet = Jetref -> et(); + const std::vector< edm::Ptr< L1TkTrackType > > trkPtrs = jetIter -> getTrkPtrs() ; L1JetParticle::JetType type = Jetref -> type(); std::cout << " a Jet candidate ET eta phi zvertex " << et << " " << eta << " " << phi << " " << jetvtx << std::endl; std::cout << " Calo ET, typ " << et_L1Jet << " " << type << std::endl; std::cout << " bx = " << bx << std::endl; + std::cout << " Tracks associated with the jet : " << std::endl; + for (int it=0; it < (int)trkPtrs.size(); it++) { + edm::Ptr< L1TkTrackType > aTrack = trkPtrs.at( it ); + std::cout << " a track PT " << aTrack -> getMomentum().perp() << " eta " << + aTrack -> getMomentum().eta() << " phi " << aTrack -> getMomentum().phi() << std::endl; + } + } } @@ -288,9 +296,6 @@ L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::Even std::vector::const_iterator jet = jetCollRef -> begin(); std::cout << " ET of the first L1TkJet = " << jet -> et() << std::endl; } - else { - std::cout << L1TkHTMInputTag << " is non valid." << std::endl; - } // @@ -368,25 +373,26 @@ L1TrackTriggerObjectsAnalyzer::analyze(const edm::Event& iEvent, const edm::Even } + } // ------------ method called once each job just before starting event loop ------------ void -L1TrackTriggerObjectsAnalyzer::beginJob() +PrintL1TkObjects::beginJob() { } // ------------ method called once each job just after ending the event loop ------------ void -L1TrackTriggerObjectsAnalyzer::endJob() +PrintL1TkObjects::endJob() { } // ------------ method called when starting to processes a run ------------ /* void -L1TrackTriggerObjectsAnalyzer::beginRun(edm::Run const&, edm::EventSetup const&) +PrintL1TkObjects::beginRun(edm::Run const&, edm::EventSetup const&) { } */ @@ -394,7 +400,7 @@ L1TrackTriggerObjectsAnalyzer::beginRun(edm::Run const&, edm::EventSetup const&) // ------------ method called when ending the processing of a run ------------ /* void -L1TrackTriggerObjectsAnalyzer::endRun(edm::Run const&, edm::EventSetup const&) +PrintL1TkObjects::endRun(edm::Run const&, edm::EventSetup const&) { } */ @@ -402,7 +408,7 @@ L1TrackTriggerObjectsAnalyzer::endRun(edm::Run const&, edm::EventSetup const&) // ------------ method called when starting to processes a luminosity block ------------ /* void -L1TrackTriggerObjectsAnalyzer::beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +PrintL1TkObjects::beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) { } */ @@ -410,14 +416,14 @@ L1TrackTriggerObjectsAnalyzer::beginLuminosityBlock(edm::LuminosityBlock const&, // ------------ method called when ending the processing of a luminosity block ------------ /* void -L1TrackTriggerObjectsAnalyzer::endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +PrintL1TkObjects::endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) { } */ // ------------ method fills 'descriptions' with the allowed parameters for the module ------------ void -L1TrackTriggerObjectsAnalyzer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { +PrintL1TkObjects::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { //The following says we do not know what parameters are allowed so do no validation // Please change this to state exactly what you do use, even if it is no parameters edm::ParameterSetDescription desc; @@ -426,4 +432,4 @@ L1TrackTriggerObjectsAnalyzer::fillDescriptions(edm::ConfigurationDescriptions& } //define this as a plug-in -DEFINE_FWK_MODULE(L1TrackTriggerObjectsAnalyzer); +DEFINE_FWK_MODULE(PrintL1TkObjects); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py new file mode 100644 index 0000000000000..bbd7a399ef534 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py @@ -0,0 +1,132 @@ +# Import configurations +import FWCore.ParameterSet.Config as cms + +process = cms.Process("L1simulation") + +# +# This configuration runs the SLHCCalo sequence, i.e. it creates +# L1EG (and L1IsoEG) candidates, L1Taus and L1Jets. +# "l1extra" objects are also created, that correspond to the +# the Run-1 algorithms. +# + + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + # MinBias, new GT : + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root' + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + # + # old GT : + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140/m1_SingleNeutrino_E2023TTI_PU140.root' + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140/m2_SingleNeutrino_E2023TTI_PU140.root' + # + # SingleElectrons (old GT) + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SinglePositron_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SingleElectron_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SinglePositron_E2023TTI_PU140.root' + ) +) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) + + +# initialize MessageLogger and output report +process.load("FWCore.MessageLogger.MessageLogger_cfi") +process.MessageLogger.cerr.FwkReport = cms.untracked.PSet( + #reportEvery = cms.untracked.int32(500), + reportEvery = cms.untracked.int32(10), + limit = cms.untracked.int32(10000000) +) + +process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(False) ) + +# Load geometry +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') + +process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +process.load("Configuration.StandardSequences.Services_cff") +process.load('FWCore/MessageService/MessageLogger_cfi') +process.load('Configuration/StandardSequences/L1HwVal_cff') +process.load("Configuration.StandardSequences.RawToDigi_Data_cff") ###check this for MC! +process.load('Configuration.StandardSequences.L1Reco_cff') +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.load('Configuration/StandardSequences/EndOfProcess_cff') + + +# --------------------------------------------------------------------------- + +# --- Run the SLHCCaloSequence + +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets + +process.p = cms.Path( + process.RawToDigi+ + process.SLHCCaloTrigger + ) + +# bug fix for missing HCAL TPs in MC RAW +process.p.insert(1, process.valHcalTriggerPrimitiveDigis) +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + +# +# --------------------------------------------------------------------------- + + # run L1Reco to produce the L1 objects corresponding + # to the current trigger +#process.load('Configuration.StandardSequences.L1Reco_cff') +process.L1Reco = cms.Path( process.l1extraParticles ) + + + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example_L1simulation.root"), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + +# generator level information : +process.Out.outputCommands.append('keep *_generator_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') + +# Collections for L1EG objects : +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_EGamma_*') # old stage-2 algorithm, 2x2 clustering, inclusive EG +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_IsoEGamma_*') # old stage 2, Isolated EG +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticlesNewClustering_EGamma_*') # new stage-2 algo, dynamic clustering, inclusive EG +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticlesNewClustering_IsoEGamma_*') # new stage-2 algo, dynamic clustering, Isolated EG +process.Out.outputCommands.append('keep *_l1extraParticles_NonIsolated_*') # Run-1, NonIso EG (different from inclusive !) +process.Out.outputCommands.append('keep *_l1extraParticles_Isolated_*') # Run-1, Iso EG + +# Collections for L1Jets : +process.Out.outputCommands.append('keep *_L1CalibFilterTowerJetProducer_CalibratedTowerJets_*') # L1Jets +process.Out.outputCommands.append('keep *_L1CalibFilterTowerJetProducer_UncalibratedTowerJets_*') # L1Jets + +# Collections for L1CaloTau objects : +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_Taus_*') # old stage-2 algo, inclusive Taus +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_IsoTaus_*') # old stage-2 algo, isolated Taus + +# Collections for (Run-1 like) L1Muons : +process.Out.outputCommands.append('keep *L1Muon*_l1extraParticles__*') # Run-1 L1Muons + +# needed to be able to use the _genParticles_ ... +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py similarity index 50% rename from SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks.py rename to SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py index 215b8de88d61c..bfed0cf5b8885 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py @@ -4,17 +4,20 @@ # -# This runs over a DIGI file (that contains clusters and stubs) -# and runs the tracklet-based L1Tracking. -# Note that the tracklet-L1Tracks are already present on the -# DIGI produced in SLHC8 - but you may want to rerun it, to -# benefit from the latest updates of the L1Tracking code. -# -# For running over a SLHC6 DIGI file: the file must contain the -# tracker digis (they are present by default in SLHC6 DIGI files). -# If you run over the centrally produced files, you need to redo -# the stubs, see below and uncomment the corresponding lines. +# This runs over a file that contains stubs and the clusters +# that make the stubs. This is the default EventContent of our +# 620_SLHC samples. +# +# It runs the tracklet-based L1Tracking. Note that the tracklet-based +# L1Tracks are already present on our samples, but you may want to re-run +# the L1Tracking, for example to relax the extrapolation windows +# used in the algorithm, in order to recover a bit of efficiency +# over electrons that brem. Or simply to benefit from the latest +# updates of the L1Tracking code - like the possibility of +# fitting 5-parameters tracks, not constraining them to come from +# the beamspot. # +# process.load("FWCore.MessageService.MessageLogger_cfi") @@ -23,54 +26,59 @@ process.source = cms.Source("PoolSource", - #fileNames = singleElectronFiles - #fileNames = ttbarFiles_p1 - #fileNames = cms.untracked.vstring('/store/group/comm_trigger/L1TrackTrigger/BE5D_620_SLHC6/singleMu/PU140/SingleMuMinus_BE5D_PU140.root') - fileNames = cms.untracked.vstring('file:/afs/cern.ch/user/e/eperez/public/step2.root') + fileNames = cms.untracked.vstring( + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root' + ) ) # ---- Global Tag : process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + # --------------------------------------------------------------------------- # -# ---- Run the L1Tracking : -# ---- redo the stubs in case you run over a 620_SLHC6 file. -# Stubs were produced during the central production -# and are present on the DIGI files, but the "z-matching" condition -# was enforced. Here we redo the stubs without the z-matching. -# This leads to better tracking efficiencies. - -#process.load('Configuration.StandardSequences.L1TrackTrigger_cff') -#process.pStubs = cms.Path( process.L1TkStubsFromPixelDigis ) +# -- Run the L1Tracking : -# --- now we run the L1Track producer : - -process.load('Configuration.StandardSequences.MagneticField_38T_cff') +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') process.load('IOMC.EventVertexGenerators.VtxSmearedGauss_cfi') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5DReco_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5D_cff') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') process.BeamSpotFromSim =cms.EDProducer("BeamSpotFromSimProducer") -process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TTrack_cfi") -process.L1Tracks.geometry = cms.untracked.string('BE5D') +# --- In case one wants to reproduce everything (of course, the tracker +# digis must have been kept oh the file), one just needs : +# +# process.load('Configuration.StandardSequences.L1TrackTrigger_cff') +# process.pL1Tracks = cms.Path( process.L1TrackTrigger ) +# + +# --- But here, we run the L1Track producer starting from the existing stubs : + +process.load('Configuration.StandardSequences.L1TrackTrigger_cff') + +# process.TTTracksFromPixelDigis.geometry = cms.untracked.string('BE5D') # not needed (that's the default) + +# if one wants to change the extrapolation window : +process.TTTracksFromPixelDigis.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 + +process.TT_step = cms.Path(process.TrackTriggerTTTracks) +process.TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) + -process.pL1Tracks = cms.Path( process.BeamSpotFromSim*process.L1Tracks ) # # --------------------------------------------------------------------------- process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "example_w_Tracks.root" ), + fileName = cms.untracked.string( "example_L1Tracks.root" ), fastCloning = cms.untracked.bool( False ), outputCommands = cms.untracked.vstring( 'drop *') ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py new file mode 100644 index 0000000000000..ba62747271234 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py @@ -0,0 +1,140 @@ +# Import configurations +import FWCore.ParameterSet.Config as cms + +# set up process +process = cms.Process("L1TkCalo") + +# +# This configuration runs over a file that contains the L1Tracks +# and the tracker digis. +# It creates HT and MHT, from the L1Jets and from the HLT HI jets. +# +# so far, the creation of TkObjects from L1Jets is commented, as +# we don't have yet the "KIT version" of the L1Jets in 620_SLHC. +# + + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + ) +) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) + + +# initialize MessageLogger and output report +process.load("FWCore.MessageLogger.MessageLogger_cfi") +process.MessageLogger.cerr.FwkReport = cms.untracked.PSet( + #reportEvery = cms.untracked.int32(500), + reportEvery = cms.untracked.int32(10), + limit = cms.untracked.int32(10000000) +) + +process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(False) ) + +# Load geometry +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') + +# ---- Global Tag : +process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +process.load("Configuration.StandardSequences.Services_cff") +process.load('FWCore/MessageService/MessageLogger_cfi') +process.load('Configuration/StandardSequences/L1HwVal_cff') +process.load("Configuration.StandardSequences.RawToDigi_Data_cff") ###check this for MC! +process.load('Configuration.StandardSequences.L1Reco_cff') +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.load('Configuration/StandardSequences/EndOfProcess_cff') + + +# --------------------------------------------------------------------------- + +# --- Run the SLHCCaloSequence to produce the L1Jets + +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets + +process.p = cms.Path( + process.RawToDigi+ + process.SLHCCaloTrigger + ) + +# bug fix for missing HCAL TPs in MC RAW +process.p.insert(1, process.valHcalTriggerPrimitiveDigis) +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + +# +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- +# +# --- Load the L1TkCaloSequence : + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkCaloSequence_cff") + +# -- Produce L1TkJets, HT and MHT from the L1Jets : /// temporarily commented +#process.L1TkCaloL1Jets = cms.Path( process.L1TkCaloSequence ) + +# -- Produce the HLT JI Jets and L1TkJets, HT and MHT from these jets : +process.L1TkCaloHIJets = cms.Path( process.L1TkCaloSequenceHI ) + +# +# --------------------------------------------------------------------------- + + + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example_L1TkCalo.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + +# generator level information +process.Out.outputCommands.append('keep *_generator_*_*') + +#process.Out.outputCommands.append('keep *_l1extraParticles_*_*') # Run-1 like objects... better not use for HT and MHT. + +# intermediate products: +process.Out.outputCommands.append('keep *_iterativeConePu5CaloJets_*_*') # HLT HI jets +process.Out.outputCommands.append('keep *_L1CalibFilterTowerJetProducer_CalibratedTowerJets_*') # L1Jets +process.Out.outputCommands.append('keep *_L1CalibFilterTowerJetProducer_UncalibratedTowerJets_*') # L1Jets + +# Collections of L1TkJets : +process.Out.outputCommands.append('keep *_L1TkJets_*_*') # L1TkJets from the L1Jets +process.Out.outputCommands.append('keep *_L1TkJetsHI_*_*') # L1TkJets from the HLT Heavy Ion jets + +# Collections of HT and MHT variables : + + # -- made from the L1Jets : +process.Out.outputCommands.append('keep *_L1TkHTMissCalo_*_*') # from L1Jets, calo only +process.Out.outputCommands.append('keep *_L1TkHTMissVtx_*_*') # from L1Jets, with vertex constraint + + # -- made from the HLT HI jets: +process.Out.outputCommands.append('keep *_L1TkHTMissCaloHI_*_*') # from HLT HI jets, calo only +process.Out.outputCommands.append('keep *_L1TkHTMissVtxHI_*_*') # from HLT HI jets, with vertex constraint + +# keep the L1TkTracks if one needs the tracks associated with the jets +process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') + + +#process.Out.outputCommands.append('keep *') + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py similarity index 89% rename from SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma.py rename to SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py index 286aa4d95e0f0..97e51bd8490a0 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py @@ -22,6 +22,8 @@ process.source = cms.Source("PoolSource", fileNames = cms.untracked.vstring( + # electron file: + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root' # rate test sample: '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' @@ -99,9 +101,10 @@ # ---- "electrons" from L1Tracks, Inclusive electrons : dedicated low PT sequence process.pElectronsLoose = cms.Path( process.L1TkElectronsLoose) -process.L1TkElectronsLooseV2 = process.L1TkElectronsLoose.clone() -process.L1TkElectronsLooseV2.TrackMinPt = cms.double( 2. ) -process.pElectronsLoose2 = cms.Path( process.L1TkElectronsLooseV2 ) +# to test a lower PT cut : +#process.L1TkElectronsLooseV2 = process.L1TkElectronsLoose.clone() +#process.L1TkElectronsLooseV2.TrackMinPt = cms.double( 2. ) +#process.pElectronsLoose2 = cms.Path( process.L1TkElectronsLooseV2 ) # ---- L1TkElectrons that are isolated w.r.t. L1Tracks : dedicated low PT sequence process.L1TkIsoElectronsLoose = process.L1TkElectronsLoose.clone() @@ -129,13 +132,13 @@ # Run a trivial analyzer that prints the objects -process.ana = cms.EDAnalyzer( 'L1TrackTriggerObjectsAnalyzer' , - L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), - L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), - L1TkElectronsInputTag = cms.InputTag("L1TkElectronsTrack","EG"), +process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , + L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here + L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here + L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), - L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), - L1TkHTMInputTag = cms.InputTag("L1TkHTMiss") + L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here ) #process.pAna = cms.Path( process.ana ) @@ -188,7 +191,7 @@ process.Out.outputCommands.append('keep *_L1TkElectronsLoose_*_*') process.Out.outputCommands.append('keep *_L1TkIsoElectronsLoose_*_*') -process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') +#process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') # --- to use the genParticles, one needs to keep the collections of associators below: diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss_cfg.py similarity index 100% rename from SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss.py rename to SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss_cfg.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py new file mode 100644 index 0000000000000..1cf4e70a46ff4 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py @@ -0,0 +1,148 @@ +# Import configurations +import FWCore.ParameterSet.Config as cms + +process = cms.Process("L1TkJets") + +# +# This configuration runs over a file that contains the L1Tracks +# and the tracker digis. +# It creates L1TkJets from the L1Jets and from the HLT HI jets. +# +# so far, the creation of TkJets from L1Jets is commented, as +# we don't have yet the "KIT version" of the L1Jets in 620_SLHC. +# + + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + ) +) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) + + +# initialize MessageLogger and output report +process.load("FWCore.MessageLogger.MessageLogger_cfi") +process.MessageLogger.cerr.FwkReport = cms.untracked.PSet( + #reportEvery = cms.untracked.int32(500), + reportEvery = cms.untracked.int32(10), + limit = cms.untracked.int32(10000000) +) + +process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(False) ) + +# Load geometry +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') + +process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +process.load("Configuration.StandardSequences.Services_cff") +process.load('FWCore/MessageService/MessageLogger_cfi') +process.load('Configuration/StandardSequences/L1HwVal_cff') +process.load("Configuration.StandardSequences.RawToDigi_Data_cff") ###check this for MC! +process.load('Configuration.StandardSequences.L1Reco_cff') +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.load('Configuration/StandardSequences/EndOfProcess_cff') + + +# --------------------------------------------------------------------------- + +# --- Run the SLHCCaloSequence to produce the L1Jets + +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets + +process.p = cms.Path( + process.RawToDigi+ + process.SLHCCaloTrigger + ) + +# bug fix for missing HCAL TPs in MC RAW +process.p.insert(1, process.valHcalTriggerPrimitiveDigis) +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + +# +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# --- Produce L1TkJets from these L1Jets : + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkJetProducer_cfi") +process.L1TkJetsL1 = process.L1TkJets.clone() +#process.pL1TkJetsL1 = cms.Path( process.L1TkJetsL1 ) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# --- Run the HLT Heavy Ion jets : + +# +# The sequences in python/L1TkCaloSequence_cff.py allow to make this shorter. +# Here, things are spelled out, to show the various steps. +# See testL1TkCalo_cfg.py for a minimal, black-box like, configuration file. +# + +# --- Run the calo local reconstruction +process.towerMaker.hbheInput = cms.InputTag("hbheprereco") +process.towerMakerWithHO.hbheInput = cms.InputTag("hbheprereco") +process.reconstruction_step = cms.Path( process.calolocalreco ) + + +# --- Produce the HLT HeavyIon jets : +process.load("RecoHI.HiJetAlgos.HiRecoJets_TTI_cff") +process.hireco = cms.Path( process.hiRecoJets ) + +# --- Put them into "L1Jets" +process.L1JetsFromHIHLTJets = cms.EDProducer("L1JetsFromHIHLTJets", + ETAMIN = cms.double(0), + ETAMAX = cms.double(3.), + HIJetsInputTag = cms.InputTag("iterativeConePu5CaloJets") +) +process.pL1Jets = cms.Path( process.L1JetsFromHIHLTJets ) + +# --- Produce L1TkJets from the HeavyIon jets +process.L1TkJetsHI = process.L1TkJets.clone() +process.L1TkJetsHI.L1CentralJetInputTag = cms.InputTag("L1JetsFromHIHLTJets") +#process.L1TkJetsHI.JET_HLTETA = cms.bool(True) +process.pL1TkJetsHI = cms.Path( process.L1TkJetsHI ) + +# +# --------------------------------------------------------------------------- + + + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example_TkJets.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + +#process.Out.outputCommands.append( 'keep *_*_*_L1EG' ) +process.Out.outputCommands.append('keep *_generator_*_*') + +process.Out.outputCommands.append('keep *_L1TkJetsHI_*_*') # L1TkJets made from the HLT HeavyIon jets +process.Out.outputCommands.append('keep *_L1TkJetsL1_*_*') # L1TkJets made from the L1Jets + + + +#process.Out.outputCommands.append('keep *') + +process.FEVToutput_step = cms.EndPath(process.Out) + + + From 278bda3726071fa1cfc38277a03d00b829f8d4e3 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 22 May 2014 08:34:10 +0200 Subject: [PATCH 003/252] fixed bug in L1TkElectronTrackProducer_cfi.py (L1TkElectronsLooseTrackEGammaDeltaR) --- .../L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py index 6a7e7a0583676..9681fe4ed9923 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py @@ -37,5 +37,5 @@ # for LowPt Electron L1TkElectronsLoose = L1TkElectrons.clone() L1TkElectronsLoose.TrackEGammaDeltaPhi = cms.vdouble(0.07, 0.0, 0.0) -L1TkElectronsLooseTrackEGammaDeltaR = cms.vdouble(0.12, 0.0, 0.0) +L1TkElectronsLoose.TrackEGammaDeltaR = cms.vdouble(0.12, 0.0, 0.0) L1TkElectronsLoose.TrackMinPt = cms.double( 3.0 ) From ea4098ba02918695c6cb66ba4f15c24a5deb6a53 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sat, 24 May 2014 10:29:07 +0200 Subject: [PATCH 004/252] first version of Nicola's muons --- .../L1DTPlusTrackTrigger}/BuildFile.xml | 6 +- .../interface/DTBtiTrigger.h | 51 + .../L1DTPlusTrackTrigger/interface/DTMatch.h | 384 +++++ .../interface/DTMatchBase.h | 211 +++ .../interface/DTMatchBasePtMethods.h | 59 + .../interface/DTMatchPt.h | 92 ++ .../interface/DTTSPhiTrigger.h | 47 + .../interface/DTTSThetaTrigger.h | 10 + .../L1DTPlusTrackTrigger/src/DTBtiTrigger.cc | 56 + .../L1DTPlusTrackTrigger/src/DTMatch.cc | 1128 ++++++++++++++ .../L1DTPlusTrackTrigger/src/DTMatchBase.cc | 1338 +++++++++++++++++ .../src/DTMatchBasePtMethods.cc | 86 ++ .../L1DTPlusTrackTrigger/src/DTMatchPt.cc | 140 ++ .../src/DTMatch_extrapolations.cc | 359 +++++ .../src/DTTSPhiTrigger.cc | 53 + .../L1DTPlusTrackTrigger/src/classes.h | 43 + .../L1DTPlusTrackTrigger/src/classes_def.xml | 38 + .../interface/L1TkMuonParticle.h | 82 +- .../interface/L1TkMuonParticle.h.backup | 86 ++ .../L1TrackTrigger/src/L1TkMuonParticle.cc | 48 +- .../L1TrackTrigger/src/classes_def.xml | 4 +- .../plugins/L1TkMuonProducer.cc | 530 +++---- .../plugins/L1TkMuonProducer.cc.backup | 354 +++++ .../test/test_L1TkCentralMuons_cfg.py | 161 ++ SimDataFormats/SLHC/doc/html/index.html | 12 - SimDataFormats/SLHC/doc/html/overview.html | 13 - .../SLHC/interface/EtaPhiContainer.h | 177 --- SimDataFormats/SLHC/interface/L1CaloCluster.h | 204 --- .../SLHC/interface/L1CaloClusterFwd.h | 21 - .../SLHC/interface/L1CaloClusterWithSeed.h | 148 -- .../SLHC/interface/L1CaloClusterWithSeedFwd.h | 21 - SimDataFormats/SLHC/interface/L1CaloJet.h | 67 - SimDataFormats/SLHC/interface/L1CaloJetFwd.h | 22 - SimDataFormats/SLHC/interface/L1CaloRegion.h | 40 - .../SLHC/interface/L1CaloRegionFwd.h | 25 - SimDataFormats/SLHC/interface/L1CaloTower.h | 60 - .../SLHC/interface/L1CaloTowerFwd.h | 26 - .../SLHC/interface/L1CaloTriggerSetup.h | 291 ---- .../SLHC/interface/L1CaloTriggerSetupRcd.h | 11 - SimDataFormats/SLHC/interface/L1TBarrel.hh | 457 ------ SimDataFormats/SLHC/interface/L1TConstants.hh | 41 - SimDataFormats/SLHC/interface/L1TDisk.hh | 348 ----- SimDataFormats/SLHC/interface/L1TGeomBase.hh | 76 - SimDataFormats/SLHC/interface/L1TSector.hh | 927 ------------ SimDataFormats/SLHC/interface/L1TStub.hh | 203 --- SimDataFormats/SLHC/interface/L1TTrack.hh | 664 -------- SimDataFormats/SLHC/interface/L1TTracklet.hh | 96 -- SimDataFormats/SLHC/interface/L1TTracklets.hh | 58 - SimDataFormats/SLHC/interface/L1TTracks.hh | 139 -- SimDataFormats/SLHC/interface/L1TWord.hh | 228 --- SimDataFormats/SLHC/interface/L1TkBeam.h | 132 -- SimDataFormats/SLHC/interface/L1TkCluster.h | 389 ----- SimDataFormats/SLHC/interface/L1TkStub.h | 498 ------ SimDataFormats/SLHC/interface/L1TkTrack.h | 859 ----------- SimDataFormats/SLHC/interface/L1TowerJet.h | 131 -- SimDataFormats/SLHC/interface/L1TowerJetFwd.h | 21 - SimDataFormats/SLHC/interface/L1TowerNav.h | 24 - .../SLHC/interface/StackedTrackerTypes.h | 83 - SimDataFormats/SLHC/interface/slhcevent.hh | 643 -------- SimDataFormats/SLHC/src/L1CaloCluster.cc | 459 ------ .../SLHC/src/L1CaloClusterWithSeed.cc | 476 ------ SimDataFormats/SLHC/src/L1CaloJet.cc | 148 -- SimDataFormats/SLHC/src/L1CaloRegion.cc | 58 - SimDataFormats/SLHC/src/L1CaloTower.cc | 109 -- .../SLHC/src/L1CaloTriggerSetupRcd.cc | 4 - SimDataFormats/SLHC/src/L1TkCluster.cc | 48 - SimDataFormats/SLHC/src/L1TkStub.cc | 27 - SimDataFormats/SLHC/src/L1TkTrack.cc | 19 - SimDataFormats/SLHC/src/L1TowerJet.cc | 634 -------- SimDataFormats/SLHC/src/L1TowerNav.cc | 59 - .../src/T_EventSetup_L1CaloTriggerSetup.cc | 7 - SimDataFormats/SLHC/src/classes.h | 227 --- SimDataFormats/SLHC/src/classes_def.xml | 206 --- 73 files changed, 4975 insertions(+), 10027 deletions(-) rename {SimDataFormats/SLHC => DataFormats/L1DTPlusTrackTrigger}/BuildFile.xml (64%) create mode 100644 DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBase.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBasePtMethods.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/interface/DTMatchPt.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/DTBtiTrigger.cc create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/DTMatchBase.cc create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/DTMatchBasePtMethods.cc create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/DTMatchPt.cc create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/DTTSPhiTrigger.cc create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/classes.h create mode 100644 DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml create mode 100644 DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h.backup create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc.backup create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py delete mode 100644 SimDataFormats/SLHC/doc/html/index.html delete mode 100644 SimDataFormats/SLHC/doc/html/overview.html delete mode 100644 SimDataFormats/SLHC/interface/EtaPhiContainer.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloCluster.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloClusterFwd.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloJet.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloJetFwd.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloRegion.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloRegionFwd.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloTower.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloTowerFwd.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h delete mode 100644 SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h delete mode 100644 SimDataFormats/SLHC/interface/L1TBarrel.hh delete mode 100644 SimDataFormats/SLHC/interface/L1TConstants.hh delete mode 100644 SimDataFormats/SLHC/interface/L1TDisk.hh delete mode 100644 SimDataFormats/SLHC/interface/L1TGeomBase.hh delete mode 100755 SimDataFormats/SLHC/interface/L1TSector.hh delete mode 100755 SimDataFormats/SLHC/interface/L1TStub.hh delete mode 100644 SimDataFormats/SLHC/interface/L1TTrack.hh delete mode 100755 SimDataFormats/SLHC/interface/L1TTracklet.hh delete mode 100755 SimDataFormats/SLHC/interface/L1TTracklets.hh delete mode 100644 SimDataFormats/SLHC/interface/L1TTracks.hh delete mode 100755 SimDataFormats/SLHC/interface/L1TWord.hh delete mode 100644 SimDataFormats/SLHC/interface/L1TkBeam.h delete mode 100644 SimDataFormats/SLHC/interface/L1TkCluster.h delete mode 100644 SimDataFormats/SLHC/interface/L1TkStub.h delete mode 100644 SimDataFormats/SLHC/interface/L1TkTrack.h delete mode 100644 SimDataFormats/SLHC/interface/L1TowerJet.h delete mode 100644 SimDataFormats/SLHC/interface/L1TowerJetFwd.h delete mode 100644 SimDataFormats/SLHC/interface/L1TowerNav.h delete mode 100644 SimDataFormats/SLHC/interface/StackedTrackerTypes.h delete mode 100755 SimDataFormats/SLHC/interface/slhcevent.hh delete mode 100644 SimDataFormats/SLHC/src/L1CaloCluster.cc delete mode 100644 SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc delete mode 100644 SimDataFormats/SLHC/src/L1CaloJet.cc delete mode 100644 SimDataFormats/SLHC/src/L1CaloRegion.cc delete mode 100644 SimDataFormats/SLHC/src/L1CaloTower.cc delete mode 100644 SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc delete mode 100644 SimDataFormats/SLHC/src/L1TkCluster.cc delete mode 100644 SimDataFormats/SLHC/src/L1TkStub.cc delete mode 100644 SimDataFormats/SLHC/src/L1TkTrack.cc delete mode 100644 SimDataFormats/SLHC/src/L1TowerJet.cc delete mode 100644 SimDataFormats/SLHC/src/L1TowerNav.cc delete mode 100644 SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc delete mode 100644 SimDataFormats/SLHC/src/classes.h delete mode 100644 SimDataFormats/SLHC/src/classes_def.xml diff --git a/SimDataFormats/SLHC/BuildFile.xml b/DataFormats/L1DTPlusTrackTrigger/BuildFile.xml similarity index 64% rename from SimDataFormats/SLHC/BuildFile.xml rename to DataFormats/L1DTPlusTrackTrigger/BuildFile.xml index 2176dc6067ed1..5cd6261f0d6e1 100644 --- a/SimDataFormats/SLHC/BuildFile.xml +++ b/DataFormats/L1DTPlusTrackTrigger/BuildFile.xml @@ -3,12 +3,16 @@ + + + + + - diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h new file mode 100644 index 0000000000000..a0368320813a6 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h @@ -0,0 +1,51 @@ +/*! \class DTBtiTrigger + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \brief used to store BTI information within DT TP seed creation + * \date 2009, Feb 2 + */ + +#ifndef L1_DTTTI_BTI_h +#define L1_DTTTI_BTI_h + +#include + +#include "L1Trigger/DTBti/interface/DTBtiTrigData.h" +#include "DataFormats/GeometryVector/interface/LocalPoint.h" +#include "DataFormats/GeometryVector/interface/GlobalPoint.h" +#include "DataFormats/GeometryVector/interface/GlobalVector.h" + +/// Class implementation +class DTBtiTrigger : public DTBtiTrigData +{ + public: + /// Constructors + DTBtiTrigger(); + DTBtiTrigger( const DTBtiTrigData& bti ); + DTBtiTrigger( const DTBtiTrigData& bti, + Global3DPoint position, + Global3DVector direction ); + + /// Destructor + ~DTBtiTrigger(){} + + /// Position and direction + void setCMSPosition( const GlobalPoint pos ) { _position = pos; } + void setCMSDirection( const GlobalVector dir ) { _direction = dir; } + Global3DPoint cmsPosition() const { return _position; } + Global3DVector cmsDirection() const { return _direction; } + std::string sprint() const; + + private : + int _wheel; + int _station; + int _sector; + int _superLayer; + Global3DPoint _position; + Global3DVector _direction; +}; + +typedef std::vector< DTBtiTrigger > BtiTrigsCollection; + +#endif + diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h new file mode 100644 index 0000000000000..7fec05bc4e670 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h @@ -0,0 +1,384 @@ +#ifndef DTMatch_h +#define DTMatch_h + +/*! \class DTMatch + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Pierluigi Zotto + * \author Nicola Pozzobon + * \brief DT local triggers matched together. + * Objects of this class do correspond to DT muons that are then extrapolated + * to the stubs on the tracker layers, including a virtual one just enclosing + * the magnetic field volume. The main methods do aim at getting a tracker + * precision Pt. + * The matching stubs, mapped by tracker layer id, and tracker tracks are + * set as data members of the virtual base class DTMatchBase. + * Several objects of class DTMatchPt are built by methods defined in the + * base class DTMatchBasePtMethods. + * \date 2009, Feb 2 + */ + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBase.h" + +/// Pt bins +float const binPt[25] = { 0., /// Lower limit + 4., 5., 6., 7., 8., /// 1 GeV steps + 10., 12., 14., 16., 18., 20., /// 2 GeV steps + 25., 30., 35., 40., 45., 50., /// 5 GeV steps + 60., 70., 80., 90., 100., /// 10 GeV steps + 120., 140. }; /// 20 GeV steps + +/// Curvature thresholds to accept 90% of the muons with Pt larger than a given value +/// Let the Pt be 10 GeV. This is entry 7 of the binPt array. +/// The seventh value in the table below, i.e. entry 6, corresponds to the curvature +/// threshold that accepts 90% of the 10 GeV muons +/// There are two tables: one for DT seeds in station MB1, one for DT seeds +/// in station MB2 +float const cutPtInvMB1[15][24] = { + {0.3752,0.2424,0.1967,0.1660,0.1436,0.1136,0.0941,0.0802,0.0699,0.0621,0.0559,0.0446,0.0372,0.0319,0.0280,0.0250,0.0226,0.0189,0.0164,0.0145,0.0130,0.0118,0.0101,0.0088}, + {0.3853,0.2429,0.1974,0.1669,0.1443,0.1140,0.0945,0.0806,0.0702,0.0624,0.0561,0.0448,0.0373,0.0320,0.0280,0.0250,0.0226,0.0189,0.0164,0.0145,0.0129,0.0118,0.0100,0.0088}, + {0.4082,0.2436,0.1977,0.1672,0.1445,0.1142,0.0947,0.0807,0.0704,0.0625,0.0562,0.0449,0.0374,0.0320,0.0281,0.0251,0.0226,0.0190,0.0164,0.0145,0.0130,0.0118,0.0100,0.0088}, + {0.4074,0.2433,0.1976,0.1671,0.1444,0.1142,0.0946,0.0807,0.0703,0.0625,0.0562,0.0448,0.0373,0.0320,0.0281,0.0251,0.0226,0.0189,0.0164,0.0145,0.0129,0.0118,0.0100,0.0088}, + {0.4016,0.2444,0.1982,0.1674,0.1447,0.1144,0.0948,0.0808,0.0705,0.0625,0.0563,0.0449,0.0374,0.0321,0.0281,0.0251,0.0227,0.0190,0.0164,0.0145,0.0130,0.0118,0.0101,0.0088}, + {0.4523,0.2460,0.1996,0.1686,0.1457,0.1152,0.0954,0.0813,0.0709,0.0630,0.0567,0.0452,0.0377,0.0323,0.0283,0.0254,0.0229,0.0192,0.0167,0.0148,0.0132,0.0120,0.0103,0.0090}, + {0.4743,0.2464,0.2006,0.1699,0.1470,0.1162,0.0963,0.0821,0.0716,0.0636,0.0572,0.0457,0.0380,0.0326,0.0286,0.0256,0.0231,0.0193,0.0168,0.0148,0.0133,0.0121,0.0103,0.0091}, + {0.4410,0.2475,0.2010,0.1703,0.1473,0.1165,0.0966,0.0823,0.0717,0.0637,0.0573,0.0458,0.0381,0.0327,0.0286,0.0256,0.0231,0.0194,0.0168,0.0149,0.0133,0.0121,0.0104,0.0091}, + {0.7146,0.2499,0.2028,0.1717,0.1483,0.1173,0.0972,0.0828,0.0722,0.0642,0.0577,0.0461,0.0383,0.0329,0.0288,0.0258,0.0233,0.0195,0.0169,0.0150,0.0134,0.0122,0.0105,0.0092}, + {0.5429,0.2502,0.2032,0.1720,0.1485,0.1176,0.0974,0.0830,0.0724,0.0643,0.0578,0.0461,0.0384,0.0329,0.0289,0.0259,0.0234,0.0195,0.0170,0.0150,0.0135,0.0123,0.0105,0.0092}, + {0.5257,0.2464,0.2007,0.1705,0.1473,0.1166,0.0966,0.0823,0.0717,0.0638,0.0574,0.0457,0.0381,0.0327,0.0286,0.0256,0.0231,0.0194,0.0168,0.0149,0.0133,0.0121,0.0104,0.0091}, + {0.8706,0.2471,0.2014,0.1707,0.1476,0.1168,0.0968,0.0825,0.0719,0.0639,0.0574,0.0459,0.0382,0.0327,0.0287,0.0257,0.0232,0.0194,0.0169,0.0149,0.0134,0.0122,0.0104,0.0091}, + {1.0308,0.2499,0.2032,0.1721,0.1486,0.1176,0.0974,0.0831,0.0724,0.0643,0.0579,0.0462,0.0384,0.0329,0.0289,0.0259,0.0233,0.0196,0.0170,0.0150,0.0135,0.0123,0.0105,0.0092}, + {0.4280,0.2504,0.2037,0.1725,0.1489,0.1179,0.0976,0.0832,0.0725,0.0644,0.0580,0.0462,0.0385,0.0330,0.0289,0.0259,0.0234,0.0196,0.0170,0.0151,0.0135,0.0123,0.0106,0.0093}, + {0.3503,0.2596,0.2091,0.1769,0.1528,0.1209,0.1001,0.0852,0.0742,0.0660,0.0593,0.0474,0.0395,0.0339,0.0297,0.0267,0.0241,0.0202,0.0176,0.0157,0.0141,0.0129,0.0111,0.0098} }; + + +float const cutPtInvMB2[15][24] = { + {0.5051,0.2637,0.2073,0.1728,0.1488,0.1162,0.0955,0.0818,0.0712,0.0627,0.0567,0.0454,0.0379,0.0328,0.0288,0.0259,0.0235,0.0200,0.0175,0.0156,0.0141,0.0130,0.0113,0.0101}, + {0.4895,0.2653,0.2095,0.1735,0.1500,0.1168,0.0960,0.0822,0.0715,0.0631,0.0570,0.0456,0.0381,0.0330,0.0289,0.0260,0.0236,0.0201,0.0176,0.0157,0.0142,0.0131,0.0114,0.0102}, + {0.5166,0.2649,0.2100,0.1739,0.1499,0.1171,0.0960,0.0823,0.0715,0.0632,0.0571,0.0456,0.0381,0.0331,0.0290,0.0261,0.0237,0.0201,0.0176,0.0158,0.0142,0.0132,0.0114,0.0102}, + {0.5505,0.2656,0.2094,0.1739,0.1498,0.1169,0.0961,0.0823,0.0717,0.0632,0.0572,0.0457,0.0382,0.0330,0.0290,0.0261,0.0236,0.0202,0.0176,0.0158,0.0142,0.0132,0.0114,0.0103}, + {0.4948,0.2661,0.2097,0.1748,0.1504,0.1172,0.0963,0.0824,0.0717,0.0633,0.0572,0.0457,0.0382,0.0331,0.0291,0.0262,0.0237,0.0202,0.0177,0.0158,0.0143,0.0132,0.0115,0.0103}, + {0.8226,0.2697,0.2117,0.1758,0.1517,0.1178,0.0971,0.0831,0.0722,0.0637,0.0576,0.0461,0.0386,0.0333,0.0293,0.0264,0.0240,0.0205,0.0179,0.0161,0.0145,0.0135,0.0118,0.0105}, + {0.6968,0.2717,0.2147,0.1778,0.1533,0.1194,0.0983,0.0838,0.0731,0.0644,0.0583,0.0467,0.0389,0.0338,0.0296,0.0268,0.0243,0.0208,0.0182,0.0164,0.0147,0.0137,0.0119,0.0108}, + {0.4571,0.2766,0.2147,0.1784,0.1535,0.1199,0.0981,0.0841,0.0731,0.0645,0.0583,0.0468,0.0390,0.0339,0.0298,0.0268,0.0243,0.0209,0.0183,0.0164,0.0148,0.0138,0.0120,0.0108}, + {0.3605,0.2750,0.2168,0.1799,0.1550,0.1207,0.0989,0.0849,0.0736,0.0650,0.0588,0.0471,0.0394,0.0341,0.0300,0.0271,0.0246,0.0211,0.0185,0.0167,0.0150,0.0140,0.0122,0.0110}, + {0.9221,0.2797,0.2169,0.1810,0.1551,0.1208,0.0992,0.0850,0.0739,0.0652,0.0588,0.0472,0.0394,0.0342,0.0301,0.0271,0.0247,0.0211,0.0186,0.0167,0.0151,0.0140,0.0123,0.0111}, + {0.8316,0.2724,0.2148,0.1786,0.1535,0.1195,0.0985,0.0842,0.0733,0.0647,0.0585,0.0468,0.0390,0.0339,0.0298,0.0268,0.0244,0.0209,0.0183,0.0164,0.0148,0.0138,0.0120,0.0108}, + {0.9734,0.2732,0.2154,0.1792,0.1542,0.1203,0.0985,0.0845,0.0733,0.0648,0.0586,0.0469,0.0391,0.0340,0.0298,0.0269,0.0244,0.0210,0.0184,0.0165,0.0149,0.0138,0.0121,0.0109}, + {0.8544,0.2810,0.2171,0.1804,0.1555,0.1207,0.0993,0.0851,0.0738,0.0652,0.0590,0.0472,0.0394,0.0343,0.0301,0.0272,0.0247,0.0212,0.0186,0.0168,0.0151,0.0140,0.0123,0.0111}, + {0.8574,0.2799,0.2174,0.1813,0.1557,0.1212,0.0993,0.0851,0.0741,0.0653,0.0590,0.0473,0.0396,0.0344,0.0302,0.0273,0.0248,0.0213,0.0187,0.0168,0.0152,0.0141,0.0124,0.0112}, + {0.8574,0.6947,0.5410,0.4498,0.3875,0.3013,0.2474,0.2122,0.1840,0.1626,0.1470,0.1177,0.0983,0.0854,0.0749,0.0676,0.0614,0.0527,0.0463,0.0417,0.0376,0.0349,0.0305,0.0275} }; + +/// Class implementation +class DTMatch : public DTMatchBase +{ + public: + + /// Trivial default constructor + DTMatch(); + + /// Constructors + DTMatch( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + bool aFlagBXOK ); + + DTMatch( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + GlobalPoint aDTPosition, GlobalVector aDTDirection, + bool aFlagBXOK ); + + DTMatch( const DTMatch& aDTM ); + + /// Assignment operator + DTMatch& operator = ( const DTMatch& aDTM ); + + /// Destructor + ~DTMatch(){} + + /// Method with the only purpose of making this class non-abstract +// void toMakeThisAbstract(){} // NOTE: this overrides the method inherited from the parent class + // As the parent class needs to be an abstract class, this method + // is declared as purely virtual in the parent class, JUST for this + // purpose of making it abstract. + // On the other side, we want to create objects of this class, and + // this is the reason to make THIS class not abstract. + + /*** DT TRIGGER BASIC INFORMATION ***/ + /// Return functions for trigger order + inline int getDTTTrigOrder() const { return theDTTrigOrder; } + + /// Set phi-eta matching order flag + inline void setDTTrigOrder( unsigned int aDTTrigOrder ) + { + theDTTrigOrder = aDTTrigOrder; + return; + } + + /// Theta flag if position comes from BTI + inline void setThetaCorrection( float aDeltaTheta ) + { + theThetaFlag = false; /// Default value is true in constructor + theDeltaTheta = static_cast< int >( aDeltaTheta * 4096. / 3. ); + return; + } + + inline bool getThetaFlag() const { return theThetaFlag; } + inline int getDeltaTheta() const { return theDeltaTheta; } + + /// Flag if redundant and to be rejected + inline void setRejectionFlag( bool aFlag ) + { + theRejectionFlag = aFlag; + return; + } + + inline bool getRejectionFlag() const { return theRejectionFlag; } + + /*** DT TRIGGER MOMENTUM PARAMETERISATION ***/ + /// Return functions + int getDTPt(); + int getDTPtMin( float nSigmas ); + int getDTPtMax( float nSigmas ); + + /// Extrapolation of DT object to TK and Vtx + void extrapolateToTrackerLayer( unsigned int aLayer ); /// This runs from 1 to N, as the DetId index + void extrapolateToVertex(); + + /*** PROJECTION TO STUBS ***/ + /// Return functions for projected positions at specific layers (12 bits precision) + /// NOTE: also these run from 1 to N, as the DetId index + inline int getPredStubPhi( unsigned int aLayer ) const + { + if ( aLayer > 0 && aLayer <= numberOfTriggerLayers ) + { + return thePredPhi[ aLayer ]; + } + return -999999; + } + + inline int getPredStubSigmaPhi( unsigned int aLayer ) const + { + if ( aLayer > 0 && aLayer <= numberOfTriggerLayers ) + { + return thePredSigmaPhi[ aLayer ]; + } + return -999999; + } + + inline int getPredStubTheta( unsigned int aLayer ) const + { + if ( aLayer > 0 && aLayer <= numberOfTriggerLayers ) + { + return thePredTheta[ aLayer ]; + } + return -999999; + } + + inline int getPredStubSigmaTheta( unsigned int aLayer ) const + { + if ( aLayer > 0 && aLayer <= numberOfTriggerLayers ) + { + return thePredSigmaTheta[ aLayer ]; + } + return -999999; + } + + /// Set predicted tracker phi and theta in each layer + inline void setPredStubPhi( unsigned int aLayer, int aPhi, int aSigmaPhi ) + { + if ( aLayer > 0 && aLayer <= numberOfTriggerLayers ) + { + thePredPhi[ aLayer ] = aPhi; + thePredSigmaPhi[ aLayer ] = aSigmaPhi; + } + return; + } + + inline void setPredStubTheta( unsigned int aLayer, int aTheta, int aSigmaTheta ) + { + if ( aLayer > 0 && aLayer <= numberOfTriggerLayers ) + { + thePredTheta[ aLayer ] = aTheta; + thePredSigmaTheta[ aLayer ] = aSigmaTheta; + } + return; + } + + /*** PROJECTION TO VERTEX ***/ + /// Return functions at vertex + inline int getPredVtxPhi() const { return thePredPhi[ 0 ]; } + inline int getPredVtxSigmaPhi() const { return thePredSigmaPhi[ 0 ]; } + inline int getPredVtxTheta() const { return thePredTheta[ 0 ]; } + inline int getPredVtxSigmaTheta() const { return thePredSigmaTheta[ 0 ]; } + + /// Set predicted tracker phi and theta at vertex + inline void setPredVtxPhi( int aPhi, int aSigmaPhi ) + { + thePredPhi[ 0 ] = aPhi; + thePredSigmaPhi[ 0 ] = aSigmaPhi; + return; + } + + inline void setPredVtxTheta( int aTheta, int aSigmaTheta ) + { + thePredTheta[ 0 ] = aTheta; + thePredSigmaTheta[ 0 ] = aSigmaTheta; + return; + } + + /*** BENDING ANGLE ***/ + /// Return predicted error on bending angle inside the tracker + inline float getPredSigmaPhiB() const { return thePredSigmaPhiB; } + + /// Set predicted error on bending angle inside the tracker + inline void setPredSigmaPhiB( float aPredSigmaPhib ) + { + thePredSigmaPhiB = aPredSigmaPhib; + return; + } + + /*** CHECK THE MATCHES ***/ + /// Check the match with a stub + bool checkStubPhiMatch( int anotherPhi, unsigned int aLayer, float nSigmas ) const; + bool checkStubThetaMatch( int anotherTheta, unsigned int aLayer, float nSigmas ) const; + int findStubDeltaPhi( int anotherPhi, unsigned int aLayer ) const; + + /// Check the match with a track + bool checkVtxPhiMatch( int anotherPhi, float nSigmas ) const; + bool checkVtxThetaMatch( int anotherTheta, float nSigmas ) const; + int findVtxDeltaPhi( int anotherPhi ) const; + + /*** DIFFERENT PT ASSIGNMENT ***/ + /// Return functions for Pt information + inline float getPtPriority() const { return thePtPriority; } + inline float getPtAverage() const { return thePtAverage; } + inline float getPtPriorityFlag() const { return thePtPriorityFlag; } + inline float getPtAverageFlag() const { return thePtAverageFlag; } + inline float getPtPriorityBin() const { return thePtPriorityBin; } + inline float getPtAverageBin() const { return thePtAverageBin; } + inline float getPtTTTrackBin() const { return thePtTTTrackBin; } + inline float getPtMajorityFullTkBin() const { return thePtMajorityFullTkBin; } + inline float getPtMajorityBin() const { return thePtMajorityBin; } + inline float getPtMixedModeBin() const { return thePtMixedModeBin; } + + /// Operations with the huge tables + void findPtPriority(); + void findPtAverage(); + void findPtPriorityBin(); + void findPtAverageBin(); + void findPtTTTrackBin(); + void findPtMajorityFullTkBin(); + void findPtMajorityBin(); + void findPtMixedModeBin(); + + unsigned int findPtBin( float aPtInv, unsigned int aMethod ); + + /// These are to store the floating point values + inline void setPtPriority( float aPtInv ) + { + thePtPriority = 1./aPtInv; + thePtPriorityFlag = true; + return; + } + + inline void setPtAverage( float aPtInv ) + { + thePtAverage = 1./aPtInv; + thePtAverageFlag = true; + return; + } + + /// These are to store the Pt bins + inline void setPtPriorityBin( float aPtBin ) + { + thePtPriorityBin = aPtBin; + return; + } + + inline void setPtAverageBin( float aPtBin ) + { + thePtAverageBin = aPtBin; + return; + } + + inline void setPtTTTrackBin( float aPtBin ) + { + thePtTTTrackBin = aPtBin; + return; + } + + inline void setPtMajorityFullTkBin( float aPtBin ) + { + thePtMajorityFullTkBin = aPtBin; + return; + } + + inline void setPtMajorityBin( float aPtBin ) + { + thePtMajorityBin = aPtBin; + return; + } + + inline void setPtMixedModeBin( float aPtBin ) + { + thePtMixedModeBin = aPtBin; + return; + } + + /// Debug function + std::string print() const + { + std::stringstream output; + output << "DTMatch : wh " << this->getDTWheel() << ", st " << this->getDTStation() << ", se " << this->getDTSector() + << ", bx " << this->getDTBX() << ", code " << this->getDTCode() << " rejection " << this->getRejectionFlag() + << std::endl; + return output.str(); + } + + private : + + void init(); + + /// Data members + + /// DT Trigger order + unsigned int theDTTrigOrder; + + /// Flag if theta missing and BTI is used instead + bool theThetaFlag; + int theDeltaTheta; /// its correction + + /// Flag if redundant and to be rejected + bool theRejectionFlag; + + /// Predicted positions + /// NOTE: using arrays, overdimensioned to account for + /// DetId layer index ranging from 1 to numberOfTriggerLayers + /// Element [ 0 ] used to store prediction at vertex + int thePredPhi[ numberOfTriggerLayers + 1 ]; + int thePredSigmaPhi[ numberOfTriggerLayers + 1 ]; + int thePredTheta[ numberOfTriggerLayers + 1 ]; + int thePredSigmaTheta[ numberOfTriggerLayers + 1 ]; + + /// Predicted direction at vertex is stored in elements [0] of the previous arrays + + /// Predicted error on bending angle inside the tracker + float thePredSigmaPhiB; + + /// Pt information + float thePtPriority; /// The values + float thePtAverage; + bool thePtPriorityFlag; /// Flags to check that the values are actually set + bool thePtAverageFlag; + float thePtPriorityBin; /// The binned Pt + float thePtAverageBin; + float thePtTTTrackBin; + float thePtMajorityFullTkBin; + float thePtMajorityBin; + float thePtMixedModeBin; +}; + +typedef std::vector< DTMatch > DTMatchesCollection; + +#endif + diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBase.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBase.h new file mode 100644 index 0000000000000..d806ada81004d --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBase.h @@ -0,0 +1,211 @@ +#ifndef DTMatchBase_h +#define DTMatchBase_h + +/*! \class DTMatchBase + * \author Ignazio Lazzizzera + * \author Nicola Pozzobon + * \brief DT local triggers matched together, base class + * Used to store detector-related information and + * matched tracker objects + * \date 2010, Apr 10 + */ + +#include "DataFormats/MuonDetId/interface/DTBtiId.h" +#include "DataFormats/SiPixelDetId/interface/StackedTrackerDetId.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBasePtMethods.h" + +#include +#include + +unsigned int const numberOfTriggerLayers = 6; + +/// Class implementation +class DTMatchBase : public DTMatchBasePtMethods +{ + public : + + /// Method with the only purpose of making this class abstract +// virtual void toMakeThisAbstract() = 0; + + /// Trivial constructor + DTMatchBase(); + + /// Non-trivial constructors + DTMatchBase( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + bool aFlagBXOK ); + + DTMatchBase( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + GlobalPoint aDTPosition, GlobalVector aDTDirection, + bool aFlagBXOK ); + + /// Copy constructor + DTMatchBase( const DTMatchBase& aDTMB ); + + /// Assignment operator + DTMatchBase& operator = ( const DTMatchBase& aDTMB ); + + /// Destructor + virtual ~DTMatchBase(){}; + + /// Return functions for muon trigger information + inline int getDTWheel() const { return theDTWheel; } + inline int getDTStation() const { return theDTStation; } + inline int getDTSector() const { return theDTSector; } + inline int getDTBX() const { return theDTBX; } + inline bool getFlagBXOK() const { return theFlagBXOK; } + inline int getDTCode() const { return theDTCode; } + inline int getDTTSPhi() const { return theTSPhi; } + inline int getDTTSPhiB() const { return theTSPhiB; } + inline int getDTTSTheta() const { return theTSTheta; } + inline DTBtiId getInnerBtiId() const { return theInnerBti; } + inline DTBtiId getOuterBtiId() const { return theOuterBti; } + inline DTBtiId getMatchedBtiId() const { return theMatchedBti; } + + void setInnerBtiId( DTBtiId anId ) + { + theInnerBti = anId; + return; + } + + void setOuterBtiId( DTBtiId anId ) + { + theOuterBti = anId; + return; + } + + void setMatchedBtiId( DTBtiId anId ) + { + theMatchedBti = anId; + return; + } + + /// Return functions for muon trigger position and direction + inline GlobalPoint getDTPosition() const { return theDTPosition; } + inline GlobalVector getDTDirection() const { return theDTDirection; } + + /// Return function for other data members that are internally calculated + inline float getAlphaDT() const { return theAlphaDT; } + + /// Return functions for virtual Tracker layer +// inline double getInnerCoilR() const { return theInnerCoilR; } +// inline double getOuterCoilR() const { return theOuterCoilR; } +// inline double getCoilRTilde() const { return theCoilRTilde; } + + /**** STUBS ****/ + /// Store the stub + inline void addMatchedStubRef( edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > aStub, GlobalPoint aStubPos ) + { + StackedTrackerDetId thisId( aStub->getDetId() ); + theMatchedStubRef.insert( std::make_pair( thisId.iLayer(), aStub ) ); + theMatchedStubPos.insert( std::make_pair( thisId.iLayer(), aStubPos ) ); + return; + } + + /// Get all the stubs matched to the DT object + inline std::map< unsigned int, edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > getMatchedStubRefs() const + { + return theMatchedStubRef; + } + + /// Get the positions of all the stubs matched to the DT object + inline std::map< unsigned int, GlobalPoint > getMatchedStubPositions() const + { + return theMatchedStubPos; + } + + /**** TRACKS ****/ + /// Store a track matched in direction (in the window) + inline void addInWindowTrackPtr( edm::Ptr< TTTrack< Ref_PixelDigi_ > > aTrack ) + { + theTrackPtrInWindow.push_back( aTrack ); + return; + } + + /// Get all the track matched (in the window) to the DT object + inline std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > > getInWindowTrackPtrs() const + { + return theTrackPtrInWindow; + } + + /// Store the track matched (Pt) + inline void setPtMatchedTrackPtr( edm::Ptr< TTTrack< Ref_PixelDigi_ > > aTrack ) + { + theMatchedTrackPtr = aTrack; + return; + } + + /// Get the track matched (Pt) to the DT object + inline edm::Ptr< TTTrack< Ref_PixelDigi_ > > getPtMatchedTrackPtr() const + { + return theMatchedTrackPtr; + } + + /// Method to create all the DTMatchPt objects that + /// are stored in the DTMatchBasePtMethods (this class is + /// inheriting from that class) + /// For each method, it creates the object, calculates the Pt, + /// and stores it using DTMatchBasePtMethods::addPtMethod( ... ); + void setPtMethods( float station2Correction, bool thirdMethodAccurate, + float aMinRInvB, float aMaxRInvB ); + + + /// Methods that convert from integer values to + /// global CMS floating point numbers + inline float getGlobalTSPhi() const + { + float phiCMS = static_cast< float >( theTSPhi )/4096. + ( theDTSector - 1 ) * M_PI / 6.; + + /// Renormalize phi + if ( phiCMS <= 0. ) + { + phiCMS += 2. * M_PI; + } + if( phiCMS > 2. * M_PI ) + { + phiCMS -= 2. * M_PI; + } + + return phiCMS; + } + + inline float getGlobalTSPhiB() const + { + return static_cast< float >( theTSPhiB ) / 512.; /// 9 bits + } + + private : + + /// Data members + + /// The original DT trigger information + int theDTWheel, theDTStation, theDTSector, theDTBX, theDTCode; + int theTSPhi, theTSTheta, theTSPhiB; + bool theFlagBXOK; + + DTBtiId theInnerBti, theOuterBti; /// As all the matches start from a TSPhi + /// here we store the ID's of the two BTI's that fired the DTChambPhSegm + DTBtiId theMatchedBti; /// There are 3 possible matches: to a BTI, to a TSTheta (one BTI from the TSTheta) + /// and from nothing (in such a case, it is left to its default value = 0x0 + + /// The original DT trigger position and direction + GlobalPoint theDTPosition; + GlobalVector theDTDirection; + + /// Internally computed data members + float theAlphaDT; + + /// Virtual Tracker layer at solenoid + static const double theInnerCoilR, theOuterCoilR, theCoilRTilde; + + /// Matching TT objects + std::map< unsigned int, edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theMatchedStubRef; + std::map< unsigned int, GlobalPoint > theMatchedStubPos; + std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > > theTrackPtrInWindow; + edm::Ptr< TTTrack< Ref_PixelDigi_ > > theMatchedTrackPtr; +}; + +#endif + diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBasePtMethods.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBasePtMethods.h new file mode 100644 index 0000000000000..431ef47bb4f44 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBasePtMethods.h @@ -0,0 +1,59 @@ +#ifndef DTMatchBasePtMethods_h +#define DTMatchBasePtMethods_h + +/*! \class DTMatchBasePtMethods + * \author Ignazio Lazzizzera + * \author Nicola Pozzobon + * \brief DT local triggers matched together, base class + * for DTMatchBase, which is abstract base class for + * DTMatch. For a given object, several ways of getting its + * Pt are available. Each is accessed through a string. + * Various ways of obtaining muon Pt using stubs and tracks. + * NOTE: this is just a container class. Nothing else. + * \date 2010, Apr 10 + */ + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatchPt.h" + +#include +#include + +/// Class implementation +class DTMatchBasePtMethods +{ + public : + + /// Trivial default constructor + DTMatchBasePtMethods(); + + /// Copy constructor + DTMatchBasePtMethods( const DTMatchBasePtMethods& aDTMBPt ); + + /// Assignment operator + DTMatchBasePtMethods& operator = ( const DTMatchBasePtMethods& aDTMBPt ); + + /// Destructor + virtual ~DTMatchBasePtMethods(){}; + + /// Methods to get quantities + float const getPt( std::string const aLabel ) const; + float const getAlpha0( std::string const aLabel ) const; + float const getD( std::string const aLabel ) const; + + /// Method to retrieve the map + inline std::map< std::string, DTMatchPt* > getPtMethodsMap() const + { + return thePtMethodsMap; + } + + /// Method to assign the Pt Method to the map + void addPtMethod( std::string const aLabel, DTMatchPt* aDTMPt ); + + protected : + + /// Data members + std::map< std::string, DTMatchPt* > thePtMethodsMap; +}; + +#endif + diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchPt.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchPt.h new file mode 100644 index 0000000000000..0d84af75dbcaa --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatchPt.h @@ -0,0 +1,92 @@ +#ifndef DTMatchPt_h +#define DTMatchPt_h + +/*! \class DTBtiTrigger + * \author Ignazio Lazzizzera + * \brief container to store momentum information + * \date 2010, Apr 2 + */ + +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "DataFormats/GeometryVector/interface/GlobalPoint.h" + +#include + +/// Class implementation +class DTMatchPt +{ + public : + + /// Default trivial constructor + DTMatchPt() + { + theRB = NAN; + theRInvB = NAN; + thePt = NAN; + thePtInv = NAN; + theAlpha0 = NAN; + theD = NAN; + } + + /// Copy constructor + DTMatchPt( const DTMatchPt& aDTMPt ) + { + theRB = aDTMPt.getRB(); + theRInvB = aDTMPt.getRInvB(); + thePt = aDTMPt.getPt(); + thePtInv = aDTMPt.getPtInv(); + theAlpha0 = aDTMPt.getAlpha0(); + theD = aDTMPt.getD(); + } + + /// Assignment operator + DTMatchPt& operator = ( const DTMatchPt& aDTMPt ) + { + if ( this == &aDTMPt ) /// Same object? + { + return *this; + } + + theRB = aDTMPt.getRB(); + theRInvB = aDTMPt.getRInvB(); + thePt = aDTMPt.getPt(); + thePtInv = aDTMPt.getPtInv(); + theAlpha0 = aDTMPt.getAlpha0(); + theD = aDTMPt.getD(); + + return *this; + } + + /// Destructor + ~DTMatchPt(){} + + /// Methods to retrieve the data members + inline float const getRB() const { return theRB; } + inline float const getRInvB() const { return theRInvB; } + inline float const getPt() const { return thePt; } + inline float const getPtInv() const { return thePtInv; } + inline float const getAlpha0() const { return theAlpha0; } + inline float const getD() const { return theD; } + + /// Methods to find bending radius and Pt + void findCurvatureRadius( float aMinRInvB, float aMaxRInvB, + std::vector< GlobalPoint > aPosVec ); + + void findPt( float aMinRInvB, float aMaxRInvB, + std::vector< GlobalPoint > aPosVec, + float const aCorr ); + + void findPtAndParameters( float aMinRInvB, float aMaxRInvB, + std::vector< GlobalPoint > aPosVec, + float const aCorr ); + + private : + + /// Data members + float theRB, theRInvB; /// Bending radius + float thePt, thePtInv; + float theAlpha0, theD; +}; + +#endif + diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h new file mode 100644 index 0000000000000..2b087d2051985 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h @@ -0,0 +1,47 @@ +#ifndef L1_DTTTI_TSPHI_h +#define L1_DTTTI_TSPHI_h + +/*! \class DTBtiTrigger + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \brief used to store TSPhi information within DT TP seed creation + * \date 2009, Feb 2 + */ + +#include +#include "L1Trigger/DTTriggerServerPhi/interface/DTChambPhSegm.h" +#include "DataFormats/GeometryVector/interface/LocalPoint.h" +#include "DataFormats/GeometryVector/interface/GlobalPoint.h" +#include "DataFormats/GeometryVector/interface/GlobalVector.h" + +/// Class implementation +class DTTSPhiTrigger : public DTChambPhSegm +{ + public : + /// Constructors and destructors + DTTSPhiTrigger(); + DTTSPhiTrigger( const DTChambPhSegm& c, + Global3DPoint position, + Global3DVector direction ); + ~DTTSPhiTrigger(){} + + Global3DPoint cmsPosition() const { return _position; } + Global3DVector cmsDirection() const { return _direction; } + std::string sprint() const; + + private : + int _wheel; + int _station; + int _sector; + int _psi; + int _psiR; + int _DeltaPsiR; + float _phiB; + Global3DPoint _position; + Global3DVector _direction; +}; + +typedef std::vector< DTTSPhiTrigger > TSPhiTrigsCollection; + +#endif + diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h new file mode 100644 index 0000000000000..861aba08a9466 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h @@ -0,0 +1,10 @@ +#ifndef L1_DTTTI_TSTHETA_h +#define L1_DTTTI_TSTHETA_h + +#include "L1Trigger/DTTriggerServerTheta/interface/DTChambThSegm.h" +#include + +typedef std::vector< DTChambThSegm > TSThetaTrigsCollection; + +#endif + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTBtiTrigger.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTBtiTrigger.cc new file mode 100644 index 0000000000000..30f46ee8e3bf5 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTBtiTrigger.cc @@ -0,0 +1,56 @@ +/*! \class DTBtiTrigger + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \brief used to store BTI information within DT TP seed creation + * \date 2009, Feb 2 + */ + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h" +#include + +/// Constructors +DTBtiTrigger::DTBtiTrigger() : + DTBtiTrigData(){} + +DTBtiTrigger::DTBtiTrigger( const DTBtiTrigData& bti ) : + DTBtiTrigData(bti), + _position(Global3DPoint()), + _direction(Global3DVector()) +{ + _wheel = this->wheel(); + _station = this->station(); + _sector = this->sector(); + _superLayer = this->btiSL(); +} + +DTBtiTrigger::DTBtiTrigger( const DTBtiTrigData& bti, + Global3DPoint position, + Global3DVector direction ) : + DTBtiTrigData(bti), + _position(position), + _direction(direction) +{ + _wheel = this->wheel(); + _station = this->station(); + _sector = this->sector(); + _superLayer = this->btiSL(); +} + +/// Debug function +std::string DTBtiTrigger::sprint() const +{ + std::ostringstream outString; + outString << " wheel " << this->wheel() + << " station " << this->station() + << " sector " << this->sector() + << " SL " << this->btiSL() + << " Nr " << this->btiNumber() << std::endl; + outString << " step " << this->step() + << " code " << this->code() + << " K " << this->K() + << " X " << this->X() << std::endl; + outString << " position " << this->cmsPosition() << std::endl; + outString << " direction" << this->cmsDirection() << std::endl; + return outString.str(); +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc new file mode 100644 index 0000000000000..24454264165de --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc @@ -0,0 +1,1128 @@ +/*! \class DTMatch + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Pierluigi Zotto + * \author Nicola Pozzobon + * \brief DT local triggers matched together. + * Objects of this class do correspond to DT muons that are then extrapolated + * to the stubs on the tracker layers, including a virtual one just enclosing + * the magnetic field volume. The main methods do aim at getting a tracker + * precision Pt. + * The matching stubs, mapped by tracker layer id, and tracker tracks are + * set as data members of the virtual base class DTMatchBase. + * Several objects of class DTMatchPt are built by methods defined in the + * base class DTMatchBasePtMethods. + * \date 2009, Feb 2 + */ + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h" + +/// Initialization method used in constructors +void DTMatch::init() +{ + /// DT Trigger order + theDTTrigOrder = 9999999; /// unsigned int + + /// Flag if theta missing and BTI is used instead + theThetaFlag = true; + theDeltaTheta = -555555555; /// int + + /// Flag if redundant and to be rejected + theRejectionFlag = false; + + /// Predicted positions + /// NOTE: using arrays, overdimensioned to account for + /// DetId layer index ranging from 1 to numberOfTriggerLayers + /// Element [ 0 ] used to store prediction at vertex + for ( unsigned int iLayer = 0; iLayer <= numberOfTriggerLayers; iLayer++ ) + { + thePredPhi[ iLayer ] = -555555555; /// int + thePredSigmaPhi[ iLayer ] = -555555555; + thePredTheta[ iLayer ] = -555555555; + thePredSigmaTheta[ iLayer ] = -555555555; + } + + /// Predicted error on bending angle inside the tracker + thePredSigmaPhiB = NAN; /// float + + /// Pt information + thePtPriority = NAN; /// float + thePtAverage = NAN; + thePtPriorityFlag = false; + thePtAverageFlag = false; + thePtPriorityBin = NAN; + thePtAverageBin = NAN; + thePtTTTrackBin = NAN; + thePtMajorityFullTkBin = NAN; + thePtMajorityBin = NAN; + thePtMixedModeBin = NAN; +} + +/// Constructor +DTMatch::DTMatch() + : DTMatchBase() +{ + init(); +} + +/// Constructor +DTMatch::DTMatch( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + bool aFlagBXOK ) + : DTMatchBase( aDTWheel, aDTStation, aDTSector, + aDTBX, aDTCode, aTSPhi, aTSPhiB, aTSTheta, + aFlagBXOK ) +{ + init(); +} + +/// Constructor +DTMatch::DTMatch( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + GlobalPoint aDTPosition, GlobalVector aDTDirection, + bool aFlagBXOK ) + : DTMatchBase( aDTWheel, aDTStation, aDTSector, + aDTBX, aDTCode, aTSPhi, aTSPhiB, aTSTheta, + aDTPosition, aDTDirection, + aFlagBXOK ) +{ + init(); +} + +// Copy constructor +DTMatch::DTMatch( const DTMatch& aDTM ) + : DTMatchBase( aDTM ) +{ + theDTTrigOrder = aDTM.getDTTTrigOrder(); + + theThetaFlag = aDTM.getThetaFlag(); + theDeltaTheta = aDTM.getDeltaTheta(); + + theRejectionFlag = aDTM.getRejectionFlag(); + + thePredPhi[ 0 ] = aDTM.getPredVtxPhi(); + thePredSigmaPhi[ 0 ] = aDTM.getPredVtxSigmaPhi(); + thePredTheta[ 0 ] = aDTM.getPredVtxTheta(); + thePredSigmaTheta[ 0 ] = aDTM.getPredVtxSigmaTheta(); + + for ( unsigned int iLayer = 1; iLayer <= numberOfTriggerLayers; iLayer++ ) + { + thePredPhi[ iLayer ] = aDTM.getPredStubPhi( iLayer ); + thePredSigmaPhi[ iLayer ] = aDTM.getPredStubSigmaPhi( iLayer ); + thePredTheta[ iLayer ] = aDTM.getPredStubTheta( iLayer ); + thePredSigmaTheta[ iLayer ] = aDTM.getPredStubSigmaTheta( iLayer ); + } + + thePredSigmaPhiB = aDTM.getPredSigmaPhiB(); + + thePtPriority = aDTM.getPtPriority(); + thePtAverage = aDTM.getPtAverage(); + thePtPriorityFlag = aDTM.getPtPriorityFlag(); + thePtAverageFlag = aDTM.getPtAverageFlag(); + + thePtPriorityBin = aDTM.getPtPriorityBin(); + thePtAverageBin = aDTM.getPtAverageBin(); + thePtTTTrackBin = aDTM.getPtTTTrackBin(); + thePtMajorityFullTkBin = aDTM.getPtMajorityFullTkBin(); + thePtMajorityBin = aDTM.getPtMajorityBin(); + thePtMixedModeBin = aDTM.getPtMixedModeBin(); +} + +/// Assignment operator +DTMatch& DTMatch::operator = ( const DTMatch& aDTM ) +{ + if ( this == &aDTM ) /// Same object? + return *this; /// Yes, so skip assignment, and just return *this. + + this->DTMatchBase::operator = (aDTM); + + theDTTrigOrder = aDTM.getDTTTrigOrder(); + + theThetaFlag = aDTM.getThetaFlag(); + theDeltaTheta = aDTM.getDeltaTheta(); + + theRejectionFlag = aDTM.getRejectionFlag(); + + thePredPhi[ 0 ] = aDTM.getPredVtxPhi(); + thePredSigmaPhi[ 0 ] = aDTM.getPredVtxSigmaPhi(); + thePredTheta[ 0 ] = aDTM.getPredVtxTheta(); + thePredSigmaTheta[ 0 ] = aDTM.getPredVtxSigmaTheta(); + + for ( unsigned int iLayer = 1; iLayer <= numberOfTriggerLayers; iLayer++ ) + { + thePredPhi[ iLayer ] = aDTM.getPredStubPhi( iLayer ); + thePredSigmaPhi[ iLayer ] = aDTM.getPredStubSigmaPhi( iLayer ); + thePredTheta[ iLayer ] = aDTM.getPredStubTheta( iLayer ); + thePredSigmaTheta[ iLayer ] = aDTM.getPredStubSigmaTheta( iLayer ); + } + + thePredSigmaPhiB = aDTM.getPredSigmaPhiB(); + + thePtPriority = aDTM.getPtPriority(); + thePtAverage = aDTM.getPtAverage(); + thePtPriorityFlag = aDTM.getPtPriorityFlag(); + thePtAverageFlag = aDTM.getPtAverageFlag(); + + thePtPriorityBin = aDTM.getPtPriorityBin(); + thePtAverageBin = aDTM.getPtAverageBin(); + thePtTTTrackBin = aDTM.getPtTTTrackBin(); + thePtMajorityFullTkBin = aDTM.getPtMajorityFullTkBin(); + thePtMajorityBin = aDTM.getPtMajorityBin(); + thePtMixedModeBin = aDTM.getPtMixedModeBin(); + + return *this; +} + +/*** DT TRIGGER MOMENTUM PARAMETERISATION ***/ +/// Return function for the parameterised Pt +int DTMatch::getDTPt() +{ + /// For high quality seeds, it comes from a fit to PhiB [int] as a function of Pt [GeV/c] + /// PhiB [int] = A + B / Pt [GeV/c] + /// Pt [GeV/c] = B * 1/( PhiB [int] - A ) ~ B/PhiB [int] + /// Low quality seeds after correction: assumed to be the same as if it were a high + /// quality seed, as resolution is low enough to assume they are compatible + + int iSt = this->getDTStation() - 1; + int iWh = this->getDTWheel() + 2; + float thisPhiB = fabs( static_cast< float >(this->getDTTSPhiB()) ); + + /// By Station + 2*Wheel + float B_Pt[10] = {667.8, 433.9, 757.4, 525.1, 751.6, 539.8, 757.2, 525.5, 667.0, 435.0}; + + if ( thisPhiB > 0.0 ) + { + return static_cast< int >( B_Pt[iSt+2*iWh] / thisPhiB ); + } + + return 1000; +} + +/// Return function for the minimum allowed parameterised Pt +int DTMatch::getDTPtMin( float nSigmas ) +{ + /// For high quality seeds, it comes from a fit to PhiB [int] as a function of Pt [GeV/c] + /// PhiB [int] = A + B / Pt [GeV/c] + /// Pt [GeV/c] = B * 1/( PhiB [int] - A ) ~ B/PhiB [int] + /// Low quality seeds after correction: assumed to be the same as if it were a high + /// quality seed, as resolution is low enough to assume they are compatible + + int iSt = this->getDTStation() - 1; + int iWh = this->getDTWheel() + 2; + float thisPhiB = fabs( static_cast< float >(this->getDTTSPhiB()) ); + float thisSigmaPhiB = this->getPredSigmaPhiB(); + + /// By Station + 2*Wheel + float B_Pt[10] = {667.8, 433.9, 757.4, 525.1, 751.6, 539.8, 757.2, 525.5, 667.0, 435.0}; + + if ( thisPhiB > 0.0 ) + { + float thisPhiBMax = thisPhiB + nSigmas * thisSigmaPhiB; + return static_cast< int >( B_Pt[iSt+2*iWh] / thisPhiBMax - 1); + } + + return 0; +} + +/// Return function for the maximum allowed parameterised Pt +int DTMatch::getDTPtMax( float nSigmas ) +{ + /// For high quality seeds, it comes from a fit to PhiB [int] as a function of Pt [GeV/c] + /// PhiB [int] = A + B / Pt [GeV/c] + /// Pt [GeV/c] = B * 1/( PhiB [int] - A ) ~ B/PhiB [int] + /// Low quality seeds after correction: assumed to be the same as if it were a high + /// quality seed, as resolution is low enough to assume they are compatible + + int iSt = this->getDTStation() - 1; + int iWh = this->getDTWheel() + 2; + float thisPhiB = fabs( static_cast< float >(this->getDTTSPhiB()) ); + float thisSigmaPhiB = this->getPredSigmaPhiB(); + + /// By Station + 2*Wheel + float B_Pt[10] = {667.8, 433.9, 757.4, 525.1, 751.6, 539.8, 757.2, 525.5, 667.0, 435.0}; + + if ( thisPhiB > 0.0 ) + { + float thisPhiBMin = thisPhiB - nSigmas * thisSigmaPhiB; + return static_cast< int >( B_Pt[iSt+2*iWh] / thisPhiBMin + 1); + } + + return 1000; +} + +/*** CHECK THE MATCHES ***/ +/// Check the match with a stub in phi +bool DTMatch::checkStubPhiMatch( int anotherPhi, unsigned int aLayer, float nSigmas ) const +{ + int deltaPhi = this->findStubDeltaPhi( anotherPhi, aLayer ); + if ( deltaPhi < nSigmas * this->getPredStubSigmaPhi( aLayer ) ) + { + return true; + } + return false; +} + +/// Check the match with a stub in theta +bool DTMatch::checkStubThetaMatch( int anotherTheta, unsigned int aLayer, float nSigmas ) const +{ + int deltaTheta = abs( this->getPredStubTheta( aLayer ) - anotherTheta ); + if ( deltaTheta < nSigmas * this->getPredStubSigmaTheta( aLayer ) ) + { + return true; + } + return false; +} + +/// Find the phi difference between the projected position and the stub position +int DTMatch::findStubDeltaPhi( int anotherPhi, unsigned int aLayer ) const +{ + int IMPI = static_cast< int >( M_PI * 4096. ); + int tempPhi1 = this->getPredStubPhi( aLayer ); + int tempPhi2 = anotherPhi; + if ( tempPhi1 < 0 ) tempPhi1 += 2 * IMPI; + if ( tempPhi2 < 0 ) tempPhi2 += 2 * IMPI; + if ( tempPhi1 >= 2 * IMPI ) tempPhi1 -= 2 * IMPI; + if ( tempPhi2 >= 2 * IMPI ) tempPhi2 -= 2 * IMPI; + int tempDeltaPhi = abs( tempPhi1 - tempPhi2 ); + if ( tempDeltaPhi > IMPI ) + { + tempDeltaPhi = 2 * IMPI - tempDeltaPhi; + } + return tempDeltaPhi; +} + +/// Check the match with a track in phi +bool DTMatch::checkVtxPhiMatch( int anotherPhi, float nSigmas ) const +{ + int deltaPhi = this->findVtxDeltaPhi( anotherPhi ); + if ( deltaPhi < nSigmas * this->getPredVtxSigmaPhi() ) + { + return true; + } + return false; +} + +/// Check the match with a track in theta +bool DTMatch::checkVtxThetaMatch( int anotherTheta, float nSigmas ) const +{ + int deltaTheta = abs( this->getPredVtxTheta() - anotherTheta ); + int dtVtxSigmaTheta = this->getPredVtxSigmaTheta(); + + /// Check the theta flag (if false, rough theta is used, + /// and a wire-based correction has been set) + if ( !this->getThetaFlag() ) + { + dtVtxSigmaTheta += this->getDeltaTheta(); + } + + if ( deltaTheta < nSigmas * dtVtxSigmaTheta ) + { + return true; + } + return false; +} + +/// Find the phi difference between the projected direction +/// and the track direction at vertex +int DTMatch::findVtxDeltaPhi( int anotherPhi ) const +{ + int IMPI = static_cast< int >( M_PI * 4096. ); + int tempPhi1 = this->getPredVtxPhi(); + int tempPhi2 = anotherPhi; + if ( tempPhi1 < 0 ) tempPhi1 += 2 * IMPI; + if ( tempPhi2 < 0 ) tempPhi2 += 2 * IMPI; + if ( tempPhi1 >= 2 * IMPI ) tempPhi1 -= 2 * IMPI; + if ( tempPhi2 >= 2 * IMPI ) tempPhi2 -= 2 * IMPI; + int tempDeltaPhi = abs( tempPhi1 - tempPhi2 ); + if ( tempDeltaPhi > IMPI ) + { + tempDeltaPhi = 2 * IMPI - tempDeltaPhi; + } + return tempDeltaPhi; +} + +/* +int DTMatch::corrPhiBend1ToCh2(int phib2) { + // compatibility between primitives in different stations: used for ghost reduction + // correlation function parameters for each wheel + float a[5] = {5.E-5, 1.E-5, 2.E-5, 2.E-5, 5.E-5}; + float b[5] = {-0.0002, 6.E-5, -0.0001, -7.E-05, 2.E-6}; + float c[5] = {1.4886, 1.4084, 1.3694, 1.4039, 1.4871}; + float d[5] = {0.7017, 0.3776, 0.6627, 0.623, 0.5025}; + + // find phib in station 1 correlated with phib given for station 2 + int phib1 = 0; + int iwh = this->getDTWheel()+2; + + if(this->getDTStation()==1) + phib1 = static_cast< int >(a[iwh]*phib2*phib2*phib2 + + b[iwh]*phib2*phib2 + c[iwh]*phib2 + d[iwh]); + else //no correlation, return the value in input + phib1 = phib2; + + return phib1; +} + + +int DTMatch::corrSigmaPhiBend1ToCh2(int phib2, int sigma_phib2) { + // compatibility between primitives in different stations: used for ghost reduction + // correlation function parameters for each wheel + float a[5] = {5.E-5, 1.E-5, 2.E-5, 2.E-5, 5.E-5}; + float b[5] = {-0.0002, 6.E-5, -0.0001, -7.E-05, 2.E-6}; + float c[5] = {1.4886, 1.4084, 1.3694, 1.4039, 1.4871}; + //float d[5] = {0.7017, 0.3776, 0.6627, 0.623, 0.5025}; + + // find phib error in station 1 correlated with phib given for station 2 + int sigma_phib1 = 0; + int iwh = this->getDTWheel()+2; + + if(this->getDTStation()==1) + sigma_phib1 = static_cast< int >(fabs((3*a[iwh]*phib2*phib2 + + 2*b[iwh]*phib2 + c[iwh]*phib2) * sigma_phib2)); + else //no correlation, return the value in input + sigma_phib1 = sigma_phib2; + + return sigma_phib1; +} + +*/ + + +/// Method to set the priority encoding of the Pt +void DTMatch::findPtPriority() +{ + if( !this->getFlagBXOK() || + this->getRejectionFlag() ) + { + return; + } + + /// Prepare a vector to store the distance between the predicted + /// phi and the stub phi in units of sigmas + float nSigmaPhiDist[ numberOfTriggerLayers + 1 ] = { 9999. }; /// Size is made larger by 1 + /// to make the use of indices easier + + /// Compute phi distance between stubs and predicted position as number of + /// sigmas for each tracker layer and store it in nSigmaPhiDist[] + for ( unsigned int iLayer = 1; iLayer <= numberOfTriggerLayers; iLayer++ ) + { + /// Do this only if there is a matched stub! + if ( this->getMatchedStubRefs().find(iLayer) == this->getMatchedStubRefs().end() ) + { + continue; + } + + /// Here we do have the stub + int stubPhi = static_cast< int >( 4096. * this->getMatchedStubPositions().find(iLayer)->second.phi() ); + int dtStubDeltaPhi = this->findStubDeltaPhi( stubPhi, iLayer ); + int dtSigmaPhi = this->getPredStubSigmaPhi(iLayer); + nSigmaPhiDist[ iLayer ] = static_cast< float >( dtStubDeltaPhi )/static_cast< float >( dtSigmaPhi ); + + } /// End of loop over tracker layers + + /// Priority encoding: choose the closest stub and choose combination according to + /// some kind of priority rule as explained in the following "if-else" statements + float thisPtInv = 99999.; + + /// Availability of stubs is checked using Pt method strings from DTMatchBasePtMethods + std::map< std::string, DTMatchPt* > thisPtMethodMap = this->getPtMethodsMap(); + + if ( thisPtMethodMap.find(std::string("Mu_4_3")) != thisPtMethodMap.end() ) + { + /// Both L3 and L4 are matched + if ( nSigmaPhiDist[4] <= nSigmaPhiDist[3] ) + { + /// L4 is closer than L3 + if ( thisPtMethodMap.find(std::string("Mu_2_1")) != thisPtMethodMap.end() ) + { + /// Both L1 and L2 are matched + if ( nSigmaPhiDist[1] <= nSigmaPhiDist[2] ) + { + thisPtInv = 1./this->getPt(std::string("Mu_4_1")); + } + else + { + thisPtInv = 1./this->getPt(std::string("Mu_4_2")); + } + } + else + { + /// Only one out of L1 and L2 is matched (or none) + if ( thisPtMethodMap.find(std::string("Mu_2_V")) != thisPtMethodMap.end() ) + { + /// L2 is matched + thisPtInv = 1./this->getPt(std::string("Mu_4_2")); + } + else if ( thisPtMethodMap.find(std::string("Mu_1_V")) != thisPtMethodMap.end() ) + { + /// L1 is matched + thisPtInv = 1./this->getPt(std::string("Mu_4_1")); + } + else + { + /// None from L1 and L2 is matched + thisPtInv = 1./this->getPt(std::string("Mu_4_3")); + } + } + } + else + { + /// L3 is closer than L4 + if ( thisPtMethodMap.find(std::string("Mu_2_1")) != thisPtMethodMap.end() ) + { + /// Both L1 and L2 are matched + if ( nSigmaPhiDist[1] <= nSigmaPhiDist[2] ) + { + thisPtInv = 1./this->getPt(std::string("Mu_3_1")); + } + else + { + thisPtInv = 1./this->getPt(std::string("Mu_3_2")); + } + } + else + { + /// Only one out of L1 and L2 is matched (or none) + if ( thisPtMethodMap.find(std::string("Mu_2_V")) != thisPtMethodMap.end() ) + { + /// L2 is matched + thisPtInv = 1./this->getPt(std::string("Mu_3_2")); + } + else if ( thisPtMethodMap.find(std::string("Mu_1_V")) != thisPtMethodMap.end() ) + { + /// L1 is matched + thisPtInv = 1./this->getPt(std::string("Mu_3_1")); + } + else + { + /// None from L1 and L2 is matched + thisPtInv = 1./this->getPt(std::string("Mu_4_3")); + } + } + } + } + else + { + /// Only one out of L3 and L4 is matched (or none) + if ( thisPtMethodMap.find(std::string("Mu_4_V")) != thisPtMethodMap.end() ) + { + /// L4 is matched + if ( thisPtMethodMap.find(std::string("Mu_2_1")) != thisPtMethodMap.end() ) + { + /// Both L1 and L2 are matched + if ( nSigmaPhiDist[1] <= nSigmaPhiDist[2] ) + { + thisPtInv = 1./this->getPt(std::string("Mu_4_1")); + } + else + { + thisPtInv = 1./this->getPt(std::string("Mu_4_2")); + } + } + else + { + /// Only one out of L1 and L2 is matched (or none) + if ( thisPtMethodMap.find(std::string("Mu_2_V")) != thisPtMethodMap.end() ) + { + /// L2 is matched + thisPtInv = 1./this->getPt(std::string("Mu_4_2")); + } + else if ( thisPtMethodMap.find(std::string("Mu_1_V")) != thisPtMethodMap.end() ) + { + /// L1 is matched + thisPtInv = 1./this->getPt(std::string("Mu_4_1")); + } + } + } + else if ( thisPtMethodMap.find(std::string("Mu_3_V")) != thisPtMethodMap.end() ) + { + /// L3 is matched + if ( thisPtMethodMap.find(std::string("Mu_2_1")) != thisPtMethodMap.end() ) + { + /// Both L1 and L2 are matched + if ( nSigmaPhiDist[1] <= nSigmaPhiDist[2] ) + { + thisPtInv = 1./this->getPt(std::string("Mu_3_1")); + } + else + { + thisPtInv = 1./this->getPt(std::string("Mu_3_2")); + } + } + else + { + /// Only one out of L1 and L2 is matched (or none) + if ( thisPtMethodMap.find(std::string("Mu_2_V")) != thisPtMethodMap.end() ) + { + /// L2 is matched + thisPtInv = 1./this->getPt(std::string("Mu_3_2")); + } + else if ( thisPtMethodMap.find(std::string("Mu_1_V")) != thisPtMethodMap.end() ) + { + /// L1 is matched + thisPtInv = 1./this->getPt(std::string("Mu_3_1")); + } + } + } + else + { + /// None from L3 and L4 is matched + if ( thisPtMethodMap.find(std::string("Mu_2_1")) != thisPtMethodMap.end() ) + { + /// Both L1 and L2 are matched + thisPtInv = 1./this->getPt(std::string("Mu_2_1")); + } + } + } + + /// If we had a valid combination of stubs in Layers 1, 2, 3, 4 + /// then some value has been set and we can store it + if ( thisPtInv < 99999. ) + { + this->setPtPriority(thisPtInv); + } + return; +} + + +/// Method to set the average encoding of the Pt +void DTMatch::findPtAverage() +{ + if( !this->getFlagBXOK() || + this->getRejectionFlag() ) + { + return; + } + + float tempInvPt = 0.; + float thisInvPt = 0.; + unsigned int nInvPt = 0; + + /// Availability of stubs is checked using Pt method strings from DTMatchBasePtMethods + std::map< std::string, DTMatchPt* > thisPtMethodMap = this->getPtMethodsMap(); + + if ( thisPtMethodMap.find(std::string("Mu_4_3")) != thisPtMethodMap.end() ) + { + tempInvPt = 1./this->getPt(std::string("Mu_4_3")); + if ( tempInvPt < 0.25 ) + { + thisInvPt += tempInvPt; + nInvPt++; + } + } + if ( thisPtMethodMap.find(std::string("Mu_4_2")) != thisPtMethodMap.end() ) + { + tempInvPt = 1./this->getPt(std::string("Mu_4_2")); + if ( tempInvPt < 0.25 ) + { + thisInvPt += tempInvPt; + nInvPt++; + } + } + if ( thisPtMethodMap.find(std::string("Mu_4_1")) != thisPtMethodMap.end() ) + { + tempInvPt = 1./this->getPt(std::string("Mu_4_1")); + if ( tempInvPt < 0.25 ) + { + thisInvPt += tempInvPt; + nInvPt++; + } + } + if ( thisPtMethodMap.find(std::string("Mu_3_2")) != thisPtMethodMap.end() ) + { + tempInvPt = 1./this->getPt(std::string("Mu_3_2")); + if ( tempInvPt < 0.25 ) + { + thisInvPt += tempInvPt; + nInvPt++; + } + } + if ( thisPtMethodMap.find(std::string("Mu_3_1")) != thisPtMethodMap.end() ) + { + tempInvPt = 1./this->getPt(std::string("Mu_3_1")); + if ( tempInvPt < 0.25 ) + { + thisInvPt += tempInvPt; + nInvPt++; + } + } + if ( thisPtMethodMap.find(std::string("Mu_2_1")) != thisPtMethodMap.end() ) + { + tempInvPt = 1./this->getPt(std::string("Mu_2_1")); + if ( tempInvPt < 0.25 ) + { + thisInvPt += tempInvPt; + nInvPt++; + } + } + + if ( nInvPt > 0 ) + { + thisInvPt = thisInvPt / static_cast< float >(nInvPt); + } + + if ( fabs(thisInvPt) > 0 ) /// Check it is a number and not a NAN + { + this->setPtAverage(thisInvPt); + } + return; +} + +/// Method to assign the priority encoding of the Pt bin +void DTMatch::findPtPriorityBin() +{ + /// Start by setting 0 as default value + this->setPtPriorityBin(binPt[0]); + + /// Is the DT seed ok? Is the priority encoding Pt available? + if ( this->getFlagBXOK() && + !this->getRejectionFlag() && + this->getPtPriorityFlag() ) + { + /// Set a flag to escape once done + bool escapeFlag = false; + + /// Get the muon station and the Pt (curvature) + int stat = this->getDTStation(); + float thisPtInv = 1./this->getPtPriority(); + + /// Loop over all the Pt bins + /// Example of the loop: + /// iBin = 0: if the curvature is larger than the one of the 4 GeV muon, + /// this means Pt < 4 GeV, so the corresponding bin is the 0 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 1 + /// iBin = 1: if the curvature is larger than the one of the 5 GeV muon but smaller + /// than the one of the 4 GeV muon, this means 4 <= Pt < 5 GeV, so + /// the corresponding bin is the 4 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 2 + /// ... + /// iBin = 23: if the curvature is larger than the one of the 140 GeV muon this means + /// Pt < 140 but we already know Pt >= 120, so the 23rd Pt bins (120 GeV) is set + /// if none of the previous is set, then it is for sure larger than 140 GeV + for ( unsigned int iBin = 0; iBin < 24 && !escapeFlag ; iBin++ ) + { + if ( stat == 1 && thisPtInv > cutPtInvMB1[0][iBin] ) /// Use the same thresholds as as Mu_2_1 + { + this->setPtPriorityBin(binPt[iBin]); + escapeFlag = true; + } + else if ( stat == 2 && thisPtInv > cutPtInvMB2[0][iBin] ) /// Use the same thresholds as as Mu_2_1 + { + this->setPtPriorityBin(binPt[iBin]); + escapeFlag = true; + } + } + + /// Here's the Pt > 140 GeV case + if ( escapeFlag == false ) + { + this->setPtPriorityBin(binPt[24]); + } + } + return; +} + +/// Method to assign the average encoding of the Pt bin +void DTMatch::findPtAverageBin() +{ + /// Start by setting 0 as default value + this->setPtAverageBin(binPt[0]); + + /// Is the DT seed ok? Is the priority encoding Pt available? + if ( this->getFlagBXOK() && + !this->getRejectionFlag() && + this->getPtAverageFlag() ) + { + /// Set a flag to escape once done + bool escapeFlag = false; + + /// Get the muon station and the Pt (curvature) + int stat = this->getDTStation(); + float thisPtInv = 1./this->getPtAverage(); + + /// Loop over all the Pt bins + /// Example of the loop: + /// iBin = 0: if the curvature is larger than the one of the 4 GeV muon, + /// this means Pt < 4 GeV, so the corresponding bin is the 0 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 1 + /// iBin = 1: if the curvature is larger than the one of the 5 GeV muon but smaller + /// than the one of the 4 GeV muon, this means 4 <= Pt < 5 GeV, so + /// the corresponding bin is the 4 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 2 + /// ... + /// iBin = 23: if the curvature is larger than the one of the 140 GeV muon this means + /// Pt < 140 but we already know Pt >= 120, so the 23rd Pt bins (120 GeV) is set + /// if none of the previous is set, then it is for sure larger than 140 GeV + for ( unsigned int iBin = 0; iBin < 24 && !escapeFlag ; iBin++ ) + { + if ( stat == 1 && thisPtInv > cutPtInvMB1[0][iBin] ) /// Use the same thresholds as as Mu_2_1 + { + this->setPtAverageBin(binPt[iBin]); + escapeFlag = true; + } + else if ( stat == 2 && thisPtInv > cutPtInvMB2[0][iBin] ) /// Use the same thresholds as as Mu_2_1 + { + this->setPtAverageBin(binPt[iBin]); + escapeFlag = true; + } + } + + /// Here's the Pt > 140 GeV case + if ( escapeFlag == false ) + { + this->setPtAverageBin(binPt[24]); + } + } + return; +} + +/// Method to find a generic Pt bin in the table +unsigned int DTMatch::findPtBin( float aPtInv, unsigned int aMethod ) +{ + /// Prepare the output + unsigned int thisPtBin = 0; + + /// Is the DT seed ok? Is the priority encoding Pt available? + if ( this->getFlagBXOK() && + !this->getRejectionFlag() ) + { + /// Set a flag to escape once done + bool escapeFlag = false; + + /// Get the muon station and the Pt (curvature) + int stat = this->getDTStation(); + + /// Loop over all the Pt bins + /// Example of the loop: + /// iBin = 0: if the curvature is larger than the one of the 4 GeV muon, + /// this means Pt < 4 GeV, so the corresponding bin is the 0 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 1 + /// iBin = 1: if the curvature is larger than the one of the 5 GeV muon but smaller + /// than the one of the 4 GeV muon, this means 4 <= Pt < 5 GeV, so + /// the corresponding bin is the 4 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 2 + /// ... + /// iBin = 23: if the curvature is larger than the one of the 140 GeV muon this means + /// Pt < 140 but we already know Pt >= 120, so the 23rd Pt bins (120 GeV) is set + /// if none of the previous is set, then it is for sure larger than 140 GeV + for ( unsigned int iBin = 0; iBin < 24 && !escapeFlag ; iBin++ ) + { + if ( stat == 1 && aPtInv > cutPtInvMB1[aMethod][iBin] ) /// aMethod gives the line in the table + /// One line for each Mu_X_Y + { + thisPtBin = iBin; + escapeFlag = true; + } + else if ( stat == 2 && aPtInv > cutPtInvMB2[aMethod][iBin] ) /// Use the same thresholds as as Mu_2_1 + { + thisPtBin = iBin; + escapeFlag = true; + } + } + + /// Here's the Pt > 140 GeV case + if ( escapeFlag == false ) + { + thisPtBin = 24; + } + } + + return thisPtBin; +} + +/// Method to assign the Pt bin from a L1 Track +void DTMatch::findPtTTTrackBin() +{ + /// Here's the curvature table + float cutPtInvTK[24] = { 0.2533,0.2026,0.1689,0.1448,0.1266,0.1014, + 0.0845,0.0724,0.0634,0.0564,0.0508,0.0406,0.0339, + 0.0291,0.0255,0.0227,0.0204,0.0171,0.0147,0.0129, + 0.0115,0.0104,0.0087,0.0075 }; + + /// Start by setting 0 as default value + this->setPtTTTrackBin(binPt[0]); + + /// Is the DT seed ok? Is the priority encoding Pt available? + if ( this->getFlagBXOK() && + !this->getRejectionFlag() && + this->getPtMatchedTrackPtr().isNull() == false ) + { + /// Set a flag to escape once done + bool escapeFlag = false; + + /// Get the Pt (curvature) + float thisPtInv = 1./( this->getPtMatchedTrackPtr()->getMomentum().perp() ); + + /// Loop over all the Pt bins + /// Example of the loop: + /// iBin = 0: if the curvature is larger than the one of the 4 GeV muon, + /// this means Pt < 4 GeV, so the corresponding bin is the 0 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 1 + /// iBin = 1: if the curvature is larger than the one of the 5 GeV muon but smaller + /// than the one of the 4 GeV muon, this means 4 <= Pt < 5 GeV, so + /// the corresponding bin is the 4 GeV bin + /// if not, then lower the curvature threshold and go to iBin = 2 + /// ... + /// iBin = 23: if the curvature is larger than the one of the 140 GeV muon this means + /// Pt < 140 but we already know Pt >= 120, so the 23rd Pt bins (120 GeV) is set + /// if none of the previous is set, then it is for sure larger than 140 GeV + for ( unsigned int iBin = 0; iBin < 24 && !escapeFlag ; iBin++ ) + { + if ( thisPtInv > cutPtInvTK[iBin] ) + { + this->setPtTTTrackBin(binPt[iBin]); + escapeFlag = true; + } + } + + /// Here's the Pt > 140 GeV case + if ( escapeFlag == false ) + { + this->setPtTTTrackBin(binPt[24]); + } + } + return; +} + +/// Method to assign the majority encoding Pt bin +void DTMatch::findPtMajorityFullTkBin() +{ + /// Start by setting 0 as default value + unsigned int majorityPtBin = 0; + + /// Is the DT seed ok? + if ( this->getFlagBXOK() && + !this->getRejectionFlag() ) + { + /// Prepare the counters + unsigned int ptCounter[25] = { 0 }; /// One for each Pt bin + + /// Get the Pt range from DT at 3 sigma + int dtPtMin = this->getDTPtMin(3.); + int dtPtMax = this->getDTPtMax(3.); + + /// Availability of stubs is checked using Pt method strings from DTMatchBasePtMethods + std::map< std::string, DTMatchPt* > thisPtMethodMap = this->getPtMethodsMap(); + + /// Prepare also the string array + std::string theMethods[15] = { + std::string("Mu_2_1"), + std::string("Mu_3_1"), std::string("Mu_3_2"), + std::string("Mu_4_1"), std::string("Mu_4_2"), std::string("Mu_4_3"), + std::string("Mu_5_1"), std::string("Mu_5_2"), std::string("Mu_5_3"), std::string("Mu_5_4"), + std::string("Mu_6_1"), std::string("Mu_6_2"), std::string("Mu_6_3"), std::string("Mu_6_4"), std::string("Mu_6_5") }; + + /// Loop over the methods + for ( unsigned int iMethod = 0; iMethod < 15; iMethod++ ) + { + /// Check if the method is available + if ( thisPtMethodMap.find( theMethods[iMethod] ) != thisPtMethodMap.end() ) + { + float thisPt = this->getPt( theMethods[iMethod] ); + float thisPtInv = 1./thisPt; /// Sure it is not a NAN as the method has been found + /// hence all the needed points are available + + int thisPtInt = static_cast< int >(thisPt); + + /// Check if the Pt is in the allowed range + if ( thisPtInt >= dtPtMin && + thisPtInt <= dtPtMax ) + { + /// Find the Pt bin and increment its counter + ptCounter[ this->findPtBin( thisPtInv, iMethod ) ]++; + } + } /// End of availability of the Pt method + } /// End of loop over the Pt methods + + /// Loop over the bins + for ( unsigned int iBin = 0; iBin < 25; iBin++ ) + { + /// Is this a non-zero bin? + if ( ptCounter[iBin] == 0 ) + { + continue; + } + + /// Is this the bin with the highest population? + if ( ptCounter[iBin] >= ptCounter[majorityPtBin] ) + { + majorityPtBin = iBin; + } + } + } + + this->setPtMajorityFullTkBin(binPt[majorityPtBin]); + + return; +} + +/// Method to assign the majority encoding Pt bin (inner layers only) +void DTMatch::findPtMajorityBin() +{ + /// Start by setting 0 as default value + unsigned int majorityPtBin = 0; + + /// Is the DT seed ok? + if ( this->getFlagBXOK() && + !this->getRejectionFlag() ) + { + /// Prepare the counters + unsigned int ptCounter[25] = { 0 }; /// One for each Pt bin + + /// Get the Pt range from DT at 3 sigma + int dtPtMin = this->getDTPtMin(3.); + int dtPtMax = this->getDTPtMax(3.); + + /// Availability of stubs is checked using Pt method strings from DTMatchBasePtMethods + std::map< std::string, DTMatchPt* > thisPtMethodMap = this->getPtMethodsMap(); + + /// Prepare also the string array + std::string theMethods[6] = { + std::string("Mu_2_1"), + std::string("Mu_3_1"), std::string("Mu_3_2"), + std::string("Mu_4_1"), std::string("Mu_4_2"), std::string("Mu_4_3") }; + + /// Loop over the methods + for ( unsigned int iMethod = 0; iMethod < 6; iMethod++ ) + { + /// Check if the method is available + if ( thisPtMethodMap.find( theMethods[iMethod] ) != thisPtMethodMap.end() ) + { + float thisPt = this->getPt( theMethods[iMethod] ); + float thisPtInv = 1./thisPt; /// Sure it is not a NAN as the method has been found + /// hence all the needed points are available + + int thisPtInt = static_cast< int >(thisPt); + + /// Check if the Pt is in the allowed range + if ( thisPtInt >= dtPtMin && + thisPtInt <= dtPtMax ) + { + /// Find the Pt bin and increment its counter + ptCounter[ this->findPtBin( thisPtInv, iMethod ) ]++; + } + } /// End of availability of the Pt method + } /// End of loop over the Pt methods + + /// Loop over the bins + for ( unsigned int iBin = 0; iBin < 25; iBin++ ) + { + /// Is this a non-zero bin? + if ( ptCounter[iBin] == 0 ) + { + continue; + } + + /// Is this the bin with the highest population? + if ( ptCounter[iBin] >= ptCounter[majorityPtBin] ) + { + majorityPtBin = iBin; + } + } + } + + this->setPtMajorityBin(binPt[majorityPtBin]); + + return; +} + +/// Method to assign the mixed mode encoding Pt bin +void DTMatch::findPtMixedModeBin() +{ + /// This is based on findPtMajorityBin() but with a backup solution + /// in case the max count for the majority gives 1 + /// The backup is to average on the Pt bins: i.e. if bins 1, 3, 4, and 5 have count == 1 + /// and none else is != 0, then the average is (1+3+4+5)/4 = 13/4 = 3 (all integer operations) + + /// Start by setting 0 as default value + unsigned int majorityPtBin = 0; + + /// Use this vector to store the bins + std::vector< unsigned int > firedBins; + + /// Is the DT seed ok? + if ( this->getFlagBXOK() && + !this->getRejectionFlag() ) + { + /// Prepare the counters + unsigned int ptCounter[25] = { 0 }; /// One for each Pt bin + + /// Get the Pt range from DT at 3 sigma + int dtPtMin = this->getDTPtMin(3.); + int dtPtMax = this->getDTPtMax(3.); + + /// Availability of stubs is checked using Pt method strings from DTMatchBasePtMethods + std::map< std::string, DTMatchPt* > thisPtMethodMap = this->getPtMethodsMap(); + + /// Prepare also the string array + std::string theMethods[6] = { + std::string("Mu_2_1"), + std::string("Mu_3_1"), std::string("Mu_3_2"), + std::string("Mu_4_1"), std::string("Mu_4_2"), std::string("Mu_4_3") }; + + /// Loop over the methods + for ( unsigned int iMethod = 0; iMethod < 6; iMethod++ ) + { + /// Check if the method is available + if ( thisPtMethodMap.find( theMethods[iMethod] ) != thisPtMethodMap.end() ) + { + float thisPt = this->getPt( theMethods[iMethod] ); + + /// Set a cut at 4 GeV + if ( thisPt < 4. ) + { + continue; + } + + float thisPtInv = 1./thisPt; /// Sure it is not a NAN as the method has been found + /// hence all the needed points are available + + int thisPtInt = static_cast< int >(thisPt); + + /// Check if the Pt is in the allowed range + if ( thisPtInt >= dtPtMin && + thisPtInt <= dtPtMax ) + { + /// Find the Pt bin and increment its counter + ptCounter[ this->findPtBin( thisPtInv, iMethod ) ]++; + } + } /// End of availability of the Pt method + } /// End of loop over the Pt methods + + /// Loop over the bins + for ( unsigned int iBin = 0; iBin < 25; iBin++ ) + { + /// Is this a non-zero bin? + if ( ptCounter[iBin] == 0 ) + { + continue; + } + + /// Is this the bin with the highest population? + if ( ptCounter[iBin] >= ptCounter[majorityPtBin] ) + { + majorityPtBin = iBin; + if ( iBin != 0 ) + { + firedBins.push_back( iBin ); + } + } + } + + if ( ptCounter[majorityPtBin] == 1 ) + { + /// Backup solution! + unsigned int totBinCount = 0; + for ( unsigned int jBin = 0; jBin < firedBins.size(); jBin++ ) + { + totBinCount += firedBins.at(jBin); + } + majorityPtBin = static_cast< unsigned int >(static_cast< float >(totBinCount) / static_cast< float >(firedBins.size())); + } + } + + this->setPtMixedModeBin(binPt[majorityPtBin]); + + return; +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatchBase.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatchBase.cc new file mode 100644 index 0000000000000..70fd4fbccc254 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatchBase.cc @@ -0,0 +1,1338 @@ +/*! \class DTMatchBase + * \author Ignazio Lazzizzera + * \author Nicola Pozzobon + * \brief DT local triggers matched together, base class + * Used to store detector-related information and + * matched tracker objects + * \date 2010, Apr 10 + */ + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBase.h" + +/// Define constant data members +const double DTMatchBase::theInnerCoilR = 315.0; +const double DTMatchBase::theOuterCoilR = 340.0; +const double DTMatchBase::theCoilRTilde = + ( theInnerCoilR*theInnerCoilR + theInnerCoilR*theOuterCoilR + theOuterCoilR*theOuterCoilR ) / (3. * theOuterCoilR ); + +/// Constructor +DTMatchBase::DTMatchBase() + : DTMatchBasePtMethods() +{ + theDTWheel = -9999999; + theDTStation = -9999999; + theDTSector = -9999999; + theDTBX = -9999999; + theDTCode = -9999999; + + theTSPhi = -9999999; + theTSPhiB = -9999999; + theTSTheta = -9999999; + + theInnerBti = DTBtiId(); + theOuterBti = DTBtiId(); + theMatchedBti = DTBtiId(); + + theDTPosition = GlobalPoint(); + theDTDirection = GlobalVector(); + + theFlagBXOK = false; + + theAlphaDT = NAN; + + theMatchedStubRef = std::map< unsigned int, edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > >(); + theMatchedStubPos = std::map< unsigned int, GlobalPoint >(); + theTrackPtrInWindow = std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > >(); + theMatchedTrackPtr = edm::Ptr< TTTrack< Ref_PixelDigi_ > >(); +} + +/// Constructor +DTMatchBase::DTMatchBase( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + bool aFlagBXOK ) + : DTMatchBasePtMethods() +{ + theDTWheel = aDTWheel; + theDTStation = aDTStation; + theDTSector = aDTSector; + theDTBX = aDTBX; + theDTCode = aDTCode; + + theTSPhi = aTSPhi; + theTSPhiB = aTSPhiB; + theTSTheta = aTSTheta; + + theInnerBti = DTBtiId(); + theOuterBti = DTBtiId(); + theMatchedBti = DTBtiId(); + + theDTPosition = GlobalPoint(); + theDTDirection = GlobalVector(); + + theFlagBXOK = aFlagBXOK; + + theAlphaDT = NAN; + + theMatchedStubRef = std::map< unsigned int, edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > >(); + theMatchedStubPos = std::map< unsigned int, GlobalPoint >(); + theTrackPtrInWindow = std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > >(); + theMatchedTrackPtr = edm::Ptr< TTTrack< Ref_PixelDigi_ > >(); +} + +/// Constructor +DTMatchBase::DTMatchBase( int aDTWheel, int aDTStation, int aDTSector, + int aDTBX, int aDTCode, int aTSPhi, int aTSPhiB, int aTSTheta, + GlobalPoint aDTPosition, GlobalVector aDTDirection, + bool aFlagBXOK ) + : DTMatchBasePtMethods() +{ + theDTWheel = aDTWheel; + theDTStation = aDTStation; + theDTSector = aDTSector; + theDTBX = aDTBX; + theDTCode = aDTCode; + + theTSPhi = aTSPhi; + theTSPhiB = aTSPhiB; + theTSTheta = aTSTheta; + + theInnerBti = DTBtiId(); + theOuterBti = DTBtiId(); + theMatchedBti = DTBtiId(); + + theDTPosition = aDTPosition; + theDTDirection = aDTDirection; + + theFlagBXOK = aFlagBXOK; + + theAlphaDT = NAN; + + theMatchedStubRef = std::map< unsigned int, edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > >(); + theMatchedStubPos = std::map< unsigned int, GlobalPoint >(); + theTrackPtrInWindow = std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > >(); + theMatchedTrackPtr = edm::Ptr< TTTrack< Ref_PixelDigi_ > >(); +} + +/// Copy constructor +DTMatchBase::DTMatchBase( const DTMatchBase& aDTMB ) + : DTMatchBasePtMethods( aDTMB ) +{ + theDTWheel = aDTMB.getDTWheel(); + theDTStation = aDTMB.getDTStation(); + theDTSector = aDTMB.getDTSector(); + theDTBX = aDTMB.getDTBX(); + theDTCode = aDTMB.getDTCode(); + + theTSPhi = aDTMB.getDTTSPhi(); + theTSPhiB = aDTMB.getDTTSPhiB(); + theTSTheta = aDTMB.getDTTSTheta(); + + theInnerBti = aDTMB.getInnerBtiId(); + theOuterBti = aDTMB.getOuterBtiId(); + theMatchedBti = aDTMB.getMatchedBtiId(); + + theDTPosition = aDTMB.getDTPosition(); + theDTDirection = aDTMB.getDTDirection(); + + theFlagBXOK = aDTMB.getFlagBXOK(); + + theAlphaDT = aDTMB.getAlphaDT(); + + theMatchedStubRef = aDTMB.getMatchedStubRefs(); + theMatchedStubPos = aDTMB.getMatchedStubPositions(); + theTrackPtrInWindow = aDTMB.getInWindowTrackPtrs(); + theMatchedTrackPtr = aDTMB.getPtMatchedTrackPtr(); +} + +/// Assignment operator +DTMatchBase& DTMatchBase::operator = ( const DTMatchBase& aDTMB ) +{ + if ( this == &aDTMB ) /// Same object? + return *this; /// Yes, so skip assignment, and just return *this. + + this->DTMatchBase::operator = (aDTMB); + + theDTWheel = aDTMB.getDTWheel(); + theDTStation = aDTMB.getDTStation(); + theDTSector = aDTMB.getDTSector(); + theDTBX = aDTMB.getDTBX(); + theDTCode = aDTMB.getDTCode(); + + theTSPhi = aDTMB.getDTTSPhi(); + theTSPhiB = aDTMB.getDTTSPhiB(); + theTSTheta = aDTMB.getDTTSTheta(); + + theInnerBti = aDTMB.getInnerBtiId(); + theOuterBti = aDTMB.getOuterBtiId(); + theMatchedBti = aDTMB.getMatchedBtiId(); + + theDTPosition = aDTMB.getDTPosition(); + theDTDirection = aDTMB.getDTDirection(); + + theFlagBXOK = aDTMB.getFlagBXOK(); + + theAlphaDT = aDTMB.getAlphaDT(); + + theMatchedStubRef = aDTMB.getMatchedStubRefs(); + theMatchedStubPos = aDTMB.getMatchedStubPositions(); + theTrackPtrInWindow = aDTMB.getInWindowTrackPtrs(); + theMatchedTrackPtr = aDTMB.getPtMatchedTrackPtr(); + + return *this; +} + +/// Method that sets all the possible Pt methods envisaged +void DTMatchBase::setPtMethods( float station2Correction, bool thirdMethodAccurate, + float aMinRInvB, float aMaxRInvB ) +{ + /// First define the direction of assumed straight line trajectory + /// of the muon inside DT chambers + float bendingFromDT = this->getGlobalTSPhiB(); + + if ( theDTStation == 2 ) + { + bendingFromDT = bendingFromDT * station2Correction; + } + + float globalTSPhi = this->getGlobalTSPhi(); + + theAlphaDT = globalTSPhi + bendingFromDT; + + if ( theAlphaDT <= 0. ) + { + theAlphaDT += 2. * M_PI; + } + if ( theAlphaDT > 0. ) + { + theAlphaDT -= 2. * M_PI; + } + + /// Then get intercept of that straight line trajectory to the ideal cylindrical + /// boundary surface of the CMS magnetic field: this will be used as a point + /// belonging to the muon trajectory inside the magnetic field toghether with + /// already matched tracker stubs. + /// The idea is trying to avoid use of the outermost tracker layers, + /// stubs, however keeping comparable precision. + + /// Step 1 + float thisDTRho = static_cast< float >( theDTPosition.perp() ); + + float discriminator = 1. - thisDTRho * thisDTRho * sin( bendingFromDT ) * sin( bendingFromDT ) / ( theCoilRTilde * theCoilRTilde ); + + if( discriminator < 0.) + { + return; + } + + float sqrtDiscriminator = sqrt( discriminator ); + + float thisXR = theCoilRTilde * cos( theAlphaDT ) * sqrtDiscriminator + thisDTRho * sin( bendingFromDT ) * sin( theAlphaDT ); + float thisYR = theCoilRTilde * sin( theAlphaDT ) * sqrtDiscriminator - thisDTRho * sin( bendingFromDT ) * cos( theAlphaDT ); + + float thisPhiR = ( thisYR > 0. ) ? acos( thisXR / theCoilRTilde ) : ( 2. * M_PI - acos( thisXR / theCoilRTilde ) ); + + if ( thisPhiR <= 0. ) + { + thisPhiR += 2. * M_PI; + } + if ( thisPhiR > 2. * M_PI ) + { + thisPhiR -= 2. * M_PI; + } + +// float deltaPhiR = thisPhiR - globalTSPhi; + + /// Step 2, modify PhiR calculation to account for + /// systematics effects close to Rtilde + + float anotherXR = theCoilRTilde * cos( theAlphaDT ) + thisDTRho * sin( theAlphaDT ) * bendingFromDT; + float anotherYR = theCoilRTilde * sin( theAlphaDT ) - thisDTRho * cos( theAlphaDT ) * bendingFromDT; + + float thisPhiR1 = ( anotherYR > 0. ) ? acos( anotherXR / theCoilRTilde ) : ( 2. * M_PI - acos( anotherXR / theCoilRTilde ) ); + float thisPhiR2 = ( anotherXR > 0. ) ? abs( asin( anotherYR / theCoilRTilde ) ) : ( M_PI - abs( asin( anotherYR / theCoilRTilde ) ) ); + + if ( thisPhiR1 <= 0. ) + { + thisPhiR1 += 2. * M_PI; + } + if ( thisPhiR1 > 2. * M_PI ) + { + thisPhiR1 -= 2. * M_PI; + } + + if ( anotherYR < 0 ) + { + thisPhiR2 = 2. * M_PI - thisPhiR2; + } + + thisPhiR = ( thisPhiR1 + thisPhiR2 ) / 2; + + /// Step 3 + double auxVar = bendingFromDT * thisDTRho / theCoilRTilde; + float thisPhiRI = thirdMethodAccurate ? ( theAlphaDT - auxVar - 1./6. * auxVar * auxVar * auxVar ) : ( theAlphaDT - auxVar ); + + if ( thisPhiRI <= 0. ) + { + thisPhiRI += 2. * M_PI; + } + if ( thisPhiRI > 2. * M_PI ) + { + thisPhiRI -= 2. * M_PI; + } + + /// Now, all the possible methods for the pt + std::string methodName; + std::vector< GlobalPoint > positionVector; + + /// Extrapolation to virtual Tracker layer + GlobalPoint tempDTPosition( anotherXR, anotherYR, 0.0 ); + + /// Same as tempDTPosition, but with linear extrapolation + GlobalPoint lineDTPosition( theCoilRTilde*cos(thisPhiRI), theCoilRTilde*sin(thisPhiRI), 0.0 ); + + /// Same as tempDTPosition, but using the proper discriminator + GlobalPoint discDTPosition( thisXR, thisYR, 0.0 ); + + /// Set the relative correction for the Pt calculation + float thisCorrection = 0.; + + /// First bunch, stubs only + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_6_4_1"); /// Stubs from L1, 4, and 6 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[6] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_6_2_1"); /// Stubs from L1, 2, and 6 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[6] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_4_3_1"); /// Stubs from L1, 3, and 4 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_4_2_1"); /// Stubs from L1, 2, and 4 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Second bunch, two stubs and (0,0) + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_6_4_V"); /// Stubs from L4, and 6 + positionVector.push_back( GlobalPoint(0,0,0) ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[6] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_6_2_V"); /// Stubs from L2, and 6 + positionVector.push_back( GlobalPoint(0,0,0) ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[6] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_6_1_V"); /// Stubs from L1, and 6 + positionVector.push_back( GlobalPoint(0,0,0) ); + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[6] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_4_2_V"); /// Stubs from L2, and 4 + positionVector.push_back( GlobalPoint(0,0,0) ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Stubs_4_1_V"); /// Stubs from L1, and 4 + positionVector.push_back( GlobalPoint(0,0,0) ); + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Third bunch, DT and two stubs + if ( theMatchedStubPos.find(5) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_6_5"); /// Stubs from L5, and 6 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[5] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_6_4"); /// Stubs from L4, and 6 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_6_3"); /// Stubs from L3, and 6 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_6_2"); /// Stubs from L2, and 6 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_6_1"); /// Stubs from L1, and 6 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_5_4"); /// Stubs from L4, and 5 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_5_3"); /// Stubs from L3, and 5 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_5_2"); /// Stubs from L2, and 5 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_5_1"); /// Stubs from L1, and 5 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_4_3"); /// Stubs from L3, and 4 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_4_2"); /// Stubs from L2, and 4 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_4_1"); /// Stubs from L1, and 4 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_3_2"); /// Stubs from L2, and 3 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_3_1"); /// Stubs from L1, and 3 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(2) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_2_1"); /// Stubs from L1, and 2 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Fourth bunch, DT, one stub, and (0,0) + if ( theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_6_V"); /// Stub from L6 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_5_V"); /// Stub from L5 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_4_V"); /// Stub from L4 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_3_V"); /// Stub from L3 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_2_V"); /// Stub from L2 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("Mu_1_V"); /// Stub from L1 + positionVector.push_back( tempDTPosition ); + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Fifth bunch, DT and two stubs (linear extrapolation to virtual Tracker layer) + if ( theMatchedStubPos.find(5) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_6_5"); /// Stubs from L5, and 6 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[5] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_6_4"); /// Stubs from L4, and 6 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_6_3"); /// Stubs from L3, and 6 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_6_2"); /// Stubs from L2, and 6 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_6_1"); /// Stubs from L1, and 6 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_5_4"); /// Stubs from L4, and 5 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_5_3"); /// Stubs from L3, and 5 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_5_2"); /// Stubs from L2, and 5 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_5_1"); /// Stubs from L1, and 5 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_4_3"); /// Stubs from L3, and 4 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_4_2"); /// Stubs from L2, and 4 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_4_1"); /// Stubs from L1, and 4 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_3_2"); /// Stubs from L2, and 3 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_3_1"); /// Stubs from L1, and 3 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(2) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_2_1"); /// Stubs from L1, and 2 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Sixth bunch, DT, one stub, and (0,0)s (linear extrapolation to virtual Tracker layer) + if ( theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_6_V"); /// Stub from L6 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_5_V"); /// Stub from L5 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_4_V"); /// Stub from L4 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_3_V"); /// Stub from L3 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_2_V"); /// Stub from L2 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("IMu_1_V"); /// Stub from L1 + positionVector.push_back( lineDTPosition ); + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Seventh bunch, DT and two stubs (proper discriminator used) + if ( theMatchedStubPos.find(5) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_6_5"); /// Stubs from L5, and 6 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[5] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_6_4"); /// Stubs from L4, and 6 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_6_3"); /// Stubs from L3, and 6 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_6_2"); /// Stubs from L2, and 6 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_6_1"); /// Stubs from L1, and 6 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_5_4"); /// Stubs from L4, and 5 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_5_3"); /// Stubs from L3, and 5 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_5_2"); /// Stubs from L2, and 5 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_5_1"); /// Stubs from L1, and 5 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_4_3"); /// Stubs from L3, and 4 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[3] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_4_2"); /// Stubs from L2, and 4 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_4_1"); /// Stubs from L1, and 4 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_3_2"); /// Stubs from L2, and 3 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[2] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_3_1"); /// Stubs from L1, and 3 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(2) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_2_1"); /// Stubs from L1, and 2 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[1] ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Eight bunch, DT, one stub, and (0,0)s (proper discriminator used) + if ( theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_6_V"); /// Stub from L6 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[6] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(5) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_5_V"); /// Stub from L5 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[5] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_4_V"); /// Stub from L4 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(3) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_3_V"); /// Stub from L3 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(2) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_2_V"); /// Stub from L2 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("mu_1_V"); /// Stub from L1 + positionVector.push_back( discDTPosition ); + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( GlobalPoint(0,0,0) ); + thisDTMPt->findPt( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + /// Ninth bunch, stubs only but finding all parameters + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("LinStubs_6_4_1"); /// Stubs from L1, 4, and 6 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[4] ); + positionVector.push_back( theMatchedStubPos[6] ); + thisDTMPt->findPtAndParameters( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(6) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("LinStubs_6_2_1"); /// Stubs from L1, 2, and 6 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[6] ); + thisDTMPt->findPtAndParameters( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(3) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("LinStubs_4_3_1"); /// Stubs from L1, 3, and 4 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[3] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPtAndParameters( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + + if ( theMatchedStubPos.find(1) != theMatchedStubPos.end() && + theMatchedStubPos.find(2) != theMatchedStubPos.end() && + theMatchedStubPos.find(4) != theMatchedStubPos.end() ) + { + positionVector.clear(); + DTMatchPt* thisDTMPt = new DTMatchPt(); + methodName = std::string("LinStubs_4_2_1"); /// Stubs from L1, 2, and 4 + positionVector.push_back( theMatchedStubPos[1] ); + positionVector.push_back( theMatchedStubPos[2] ); + positionVector.push_back( theMatchedStubPos[4] ); + thisDTMPt->findPtAndParameters( aMinRInvB, aMaxRInvB, positionVector, thisCorrection ); + this->addPtMethod( methodName, thisDTMPt ); + } + +/* + + /// Tenth bunch, stubs with linear fit dephi vs invPt + +std::string("LinFit_3_1") +std::string("LinFit_3_2") +std::string("LinFit_4_1") +std::string("LinFit_4_2") +std::string("LinFit_5_1") +std::string("LinFit_5_2") +std::string("LinFit_5_3") +std::string("LinFit_5_4") +std::string("LinFit_6_1") +std::string("LinFit_6_2") +std::string("LinFit_6_3") +std::string("LinFit_6_4") + + + else if(theMethodLabels.at(s).find(string("LinFit")) != string::npos) { + // using linear fit of stub dephi vs invPt + const int I = tracker_lay_Id_to_our( atoi( &((theMethodLabels.at(s))[7]) ) ); + const int J = tracker_lay_Id_to_our( atoi( &((theMethodLabels.at(s))[9]) ) ); + const float dephi = fabs(stubstub_dephi(I, J)); + const float slope = slope_linearfit(I, J); + const float dephi_zero = y_intercept_linearfit(I, J); + aPt = new DTMatchPt(theMethodLabels.at(s), slope, dephi_zero, + I, J, dephi, pSet, _flagMatch); + + + +DTMatchPt::DTMatchPt(std::string const s, + const float slope, const float dephi_zero, + const int I, const int J, const float dephi, + const edm::ParameterSet& pSet, + bool const flagMatch[]): + _label(s) { + _Rb = _invRb = NAN; + _Pt = _invPt = NAN; + _alpha0 = _d = NAN; + if( isnan(dephi) || isnan(dephi_zero) ) //|| dephi < 0.0015 ) + return; + if( flagMatch[I] && flagMatch[J] && !isnan(slope) ) { + _invPt = (dephi - dephi_zero)/slope; + _Pt = slope/(dephi - dephi_zero); + } + return; +} + +*/ + +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatchBasePtMethods.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatchBasePtMethods.cc new file mode 100644 index 0000000000000..133c524c7c109 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatchBasePtMethods.cc @@ -0,0 +1,86 @@ +/*! \class DTMatchBasePtMethods + * \author Ignazio Lazzizzera + * \author Nicola Pozzobon + * \brief DT local triggers matched together, base class + * for DTMatchBase, which is abstract base class for + * DTMatch. For a given object, several ways of getting its + * Pt are available. Each is accessed through a string. + * Various ways of obtaining muon Pt using stubs and tracks. + * NOTE: this is just a container class. Nothing else. + * \date 2010, Apr 10 + */ + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatchBasePtMethods.h" + +/// Trivial constructor +DTMatchBasePtMethods::DTMatchBasePtMethods() +{ + thePtMethodsMap = std::map< std::string, DTMatchPt* >(); +} + +/// Copy constructor +DTMatchBasePtMethods::DTMatchBasePtMethods( const DTMatchBasePtMethods& aDTMBPt ) +{ + thePtMethodsMap = aDTMBPt.getPtMethodsMap(); +} + +/// Assignment operator +DTMatchBasePtMethods& DTMatchBasePtMethods::operator = ( const DTMatchBasePtMethods& aDTMBPt ) +{ + if ( this == &aDTMBPt ) /// Same object? + { + return *this; + } + thePtMethodsMap = aDTMBPt.getPtMethodsMap(); + return *this; +} + +/// Method to assign the Pt Method to the map +void DTMatchBasePtMethods::addPtMethod( std::string const aLabel, DTMatchPt* aDTMPt ) +{ + /// Store only non-NAN values of Pt + if ( isnan(aDTMPt->getPt()) ) + { + return; + } + + if ( thePtMethodsMap.find( aLabel ) == thePtMethodsMap.end() ) + { + thePtMethodsMap.insert( std::make_pair( aLabel, aDTMPt ) ); + } + else + { + thePtMethodsMap[ aLabel ] = aDTMPt; + } + return; +} + +/// Methods to get quantities +float const DTMatchBasePtMethods::getPt( std::string const aLabel ) const +{ + if ( thePtMethodsMap.find( aLabel ) != thePtMethodsMap.end() ) + { + return thePtMethodsMap.find( aLabel )->second->getPt(); + } + return NAN; +} + +float const DTMatchBasePtMethods::getAlpha0( std::string const aLabel ) const +{ + if ( thePtMethodsMap.find( aLabel ) != thePtMethodsMap.end() ) + { + return thePtMethodsMap.find( aLabel )->second->getAlpha0(); + } + return NAN; +} + +float const DTMatchBasePtMethods::getD( std::string const aLabel ) const +{ + if ( thePtMethodsMap.find( aLabel ) != thePtMethodsMap.end() ) + { + return thePtMethodsMap.find( aLabel )->second->getD(); + + } + return NAN; +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatchPt.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatchPt.cc new file mode 100644 index 0000000000000..487bccca76520 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatchPt.cc @@ -0,0 +1,140 @@ +/*! \class DTBtiTrigger + * \author Ignazio Lazzizzera + * \brief container to store momentum information + * \date 2010, Apr 2 + */ + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatchPt.h" + +/// Method to get the curvature radius +void DTMatchPt::findCurvatureRadius( float aMinRInvB, float aMaxRInvB, + std::vector< GlobalPoint > aPosVec ) +{ + if ( aPosVec.size() != 3 ) + { + theRB = NAN; + theRInvB = NAN; + return; + } + + /// Here the vector has the right size + double X0 = aPosVec.at(0).x(); + double X1 = aPosVec.at(1).x(); + double X2 = aPosVec.at(2).x(); + double Y0 = aPosVec.at(0).y(); + double Y1 = aPosVec.at(1).y(); + double Y2 = aPosVec.at(2).y(); + + double L1 = sqrt( (X0-X1)*(X0-X1) + (Y0-Y1)*(Y0-Y1) ); + double L2 = sqrt( (X1-X2)*(X1-X2) + (Y1-Y2)*(Y1-Y2) ); + double L1L2 = (X0-X1)*(X1-X2) + (Y0-Y1)*(Y1-Y2); + double bendingCos = L1L2 / (L1*L2); + double bending = acos( bendingCos ); + + theRInvB = 2. * static_cast< float >( bending / (L1+L2) ); + + if( theRInvB < aMinRInvB || + theRInvB > aMaxRInvB ) + { + theRB = NAN; + theRInvB = NAN; + return; + } + + theRB = static_cast< float >( 0.5 * (L1+L2) / bending ); +} + +/// Method to get the Pt +void DTMatchPt::findPt( float aMinRInvB, float aMaxRInvB, + std::vector< GlobalPoint > aPosVec, + float const aCorr ) +{ + this->findCurvatureRadius( aMinRInvB, aMaxRInvB, aPosVec ); + + if ( isnan( theRB ) ) + { + return; + } + + thePt = 0.003 * theRB * 3.8; + thePt += aCorr * thePt; + thePtInv = 1. / thePt; + + return; +} + +/// Method to get the Pt and not only the Pt +void DTMatchPt::findPtAndParameters( float aMinRInvB, float aMaxRInvB, + std::vector< GlobalPoint > aPosVec, + float const aCorr ) +{ + double r0 = aPosVec.at(0).perp(); + double phi0 = aPosVec.at(0).phi(); + double r1 = aPosVec.at(1).perp(); + double phi1 = aPosVec.at(1).phi(); + double r2 = aPosVec.at(2).perp(); + double phi2 = aPosVec.at(2).phi(); + + if ( phi0 < 0 ) + { + phi0 += 2. * M_PI; + } + if ( phi0 >= 2. * M_PI ) + { + phi0 -= 2. * M_PI; + } + + if ( phi1 < 0 ) + { + phi1 += 2. * M_PI; + } + if ( phi1 >= 2. * M_PI ) + { + phi1 -= 2. * M_PI; + } + + if ( phi2 < 0 ) + { + phi2 += 2. * M_PI; + } + if ( phi2 >= 2. * M_PI ) + { + phi2 -= 2. * M_PI; + } + + double Delta = r0*r0*(r1-r2) + r1*r1*(r2-r0) + r2*r2*(r0-r1); + if ( Delta == 0. || Delta == NAN ) + { + return; + } + double invDelta = 1/Delta; + + theRInvB = -2 * ( phi0*r0*(r1-r2) + phi1*r1*(r2-r0) + phi2*r2*(r0-r1) ) * invDelta; + + short charge = (theRInvB > 0.) - (theRInvB < 0.); + + theRInvB = fabs(theRInvB); + + if( theRInvB < aMinRInvB || + theRInvB > aMaxRInvB ) + { + theRB = NAN; + theRInvB = NAN; + theAlpha0 = NAN; + theD = NAN; + return; + } + + theRB = static_cast< float >( 1. / theRInvB ); + thePt = 0.003 * theRB * 3.8; + thePt += aCorr * thePt; + thePtInv = 1./thePt; + + theAlpha0 = charge * invDelta * + ( phi0*r0*(r1*r1-r2*r2) + phi1*r1*(r2*r2-r0*r0) + phi2*r2*(r0*r0-r1*r1) ); + + theD = charge * r0 * r1 * r2 * ( phi0*(r1-r2) + phi1*(r2-r0) + phi2*(r0-r1) ) * invDelta; + + return; +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc new file mode 100644 index 0000000000000..f1999ed6973af --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc @@ -0,0 +1,359 @@ +/*! \class DTMatch + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Pierluigi Zotto + * \author Nicola Pozzobon + * \brief DT local triggers matched together. + * Objects of this class do correspond to DT muons that are then extrapolated + * to the stubs on the tracker layers, including a virtual one just enclosing + * the magnetic field volume. The main methods do aim at getting a tracker + * precision Pt. + * The matching stubs, mapped by tracker layer id, and tracker tracks are + * set as data members of the virtual base class DTMatchBase. + * Several objects of class DTMatchPt are built by methods defined in the + * base class DTMatchBasePtMethods. + * \date 2009, Feb 2 + */ + +#include + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h" + +/// Extrapolation to a given Tk layer +/// parameter is the DetId-like index of the layer (form 1 to N) +void DTMatch::extrapolateToTrackerLayer( unsigned int aLayer ) +{ + if ( aLayer > numberOfTriggerLayers || + aLayer == 0 ) + { + return; + } + + unsigned int iTk = aLayer - 1; + + /// Compute DT predicted phi and theta on tracker layers (each wheel) from Ext + /// NOTE: needs to be extrapolated because of bending... + /// Ext = A*|Bending|*Bending + B*Bending = Bti - Predicted, where Bti = Trigger + sector + /// Predicted = Trigger - (A*|Bending|*Bending + B*Bending) + sector + /// The chosen function is an antisymmetric 2nd degree polynomial + /// For theta, it is a symmetric 2nd degree polynomial + + /// Correlated + float A_DeltaPhi_C[6][10] = { /// Layer, (2*Wheel + Station) + {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, + {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, + {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, + {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, + {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, + {0.016, 0.042, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.016, 0.042} }; + float B_DeltaPhi_C[6][10] = { /// Layer, (2*Wheel + Station) + {13.0, 21.8, 11.7, 18.6, 12.0, 18.2, 11.8, 18.5, 13.1, 21.8}, + {12.6, 21.1, 11.4, 18.0, 11.6, 17.6, 11.4, 18.0, 12.6, 21.1}, + {12.0, 20.3, 10.9, 17.3, 11.1, 17.0, 10.9, 17.3, 12.1, 20.3}, + {11.4, 19.4, 10.3, 16.5, 10.5, 16.2, 10.4, 16.5, 11.5, 19.3}, + {10.7, 18.3, 9.7, 15.6, 9.9, 15.4, 9.7, 15.6, 10.8, 18.2}, + {10.1, 17.3, 9.1, 14.8, 9.3, 14.5, 9.1, 14.8, 10.1, 17.3} }; + + /// Single + float A_DeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) + {0.016, 0.042, 0.014, 0.033, 0.014, 0.031, 0.013, 0.033, 0.016, 0.042}, + {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.014, 0.032, 0.016, 0.042}, + {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.013, 0.033, 0.016, 0.042}, + {0.016, 0.042, 0.014, 0.033, 0.014, 0.031, 0.013, 0.033, 0.016, 0.042}, + {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.014, 0.032, 0.016, 0.042}, + {0.016, 0.043, 0.014, 0.032, 0.014, 0.031, 0.013, 0.032, 0.016, 0.042} }; + float B_DeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) + {13.3, 22.1, 11.8, 18.5, 11.9, 18.1, 11.8, 18.5, 13.3, 22.0}, + {12.8, 21.4, 11.4, 18.0, 11.5, 17.6, 11.4, 18.0, 12.9, 21.3}, + {12.3, 20.6, 10.9, 17.3, 11.0, 16.9, 10.9, 17.3, 12.3, 20.5}, + {11.7, 19.6, 10.4, 16.5, 10.5, 16.2, 10.4, 16.5, 11.7, 19.6}, + {11.0, 18.5, 9.7, 15.6, 9.8, 15.3, 9.7, 15.6, 11.0, 18.5}, + {10.3, 17.6, 9.1, 14.8, 9.3, 14.5, 9.1, 14.8, 10.4, 17.5} }; + + /// Correlated + float A_DeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) + {0.007, 0.017, 0.004, 0.011, -0.000, -0.000, -0.004, -0.011, -0.006, -0.017}, + {0.006, 0.017, 0.004, 0.011, 0.000, 0.000, -0.004, -0.011, -0.006, -0.017}, + {0.006, 0.017, 0.004, 0.010, -0.000, -0.000, -0.004, -0.010, -0.006, -0.017}, + {0.005, 0.016, 0.004, 0.011, -0.000, 0.000, -0.004, -0.011, -0.006, -0.017}, + {0.006, 0.017, 0.004, 0.009, 0.000, 0.000, -0.004, -0.009, -0.007, -0.017}, + {0.007, 0.017, 0.004, 0.010, -0.000, -0.000, -0.004, -0.009, -0.006, -0.015} }; + float C_DeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) + {-0.8, 12.6, 23.1, 27.3, 3.2, 2.1, -23.8, -26.5, -1.6, -10.1}, + {8.5, 16.6, 21.6, 24.1, 1.1, 0.2, -21.8, -22.1, -10.1, -13.5}, + {11.3, 18.0, 21.1, 23.7, 0.9, 0.7, -21.3, -21.5, -13.2, -14.6}, + {14.4, 20.0, 26.6, 9.6, -27.5, -17.9, 16.8, 12.2, -28.1, -9.6}, + {22.2, 16.7, 14.0, 18.0, -5.1, 2.4, -20.3, -26.6, -1.5, -13.8}, + {26.8, 28.6, 15.7, 17.5, -2.9, -5.1, -14.7, -19.9, -38.2, -27.4} }; + + /// Single + float A_DeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) + {0.006, 0.018, 0.005, 0.011, -0.000, -0.000, -0.004, -0.011, -0.006, -0.017}, + {0.006, 0.017, 0.005, 0.011, 0.000, -0.000, -0.004, -0.010, -0.006, -0.017}, + {0.006, 0.017, 0.005, 0.010, 0.000, 0.000, -0.004, -0.010, -0.006, -0.017}, + {0.005, 0.015, 0.005, 0.011, -0.000, 0.000, -0.004, -0.012, -0.006, -0.016}, + {0.007, 0.019, 0.005, 0.010, 0.000, 0.000, -0.005, -0.010, -0.005, -0.016}, + {0.006, 0.017, 0.004, 0.010, 0.000, -0.000, -0.004, -0.010, -0.006, -0.015} }; + float C_DeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) + {44.7, 32.5, 40.6, 40.0, 3.3, -1.0, -38.9, -43.3, -49.5, -33.0}, + {48.5, 34.2, 37.5, 37.0, 1.2, -0.8, -34.7, -38.0, -51.1, -33.4}, + {47.9, 36.1, 37.1, 35.0, 1.7, -1.7, -34.6, -34.8, -50.9, -36.0}, + {52.1, 56.9, 38.6, 39.4, -27.8, -15.4, 3.9, -0.2, -33.2, -25.4}, + {54.7, 30.0, 30.0, 33.4, -8.3, 5.3, -40.3, -46.0, -53.1, -37.3}, + {59.4, 49.6, 32.1, 30.9, -6.0, -6.1, -26.6, -34.4, -75.7, -50.8} }; + + /// Functions to compute extrapolation windows + float A_SigmaDeltaPhi_C[6][10] = { /// Layer, (2*Wheel + Station) + {0.014, 0.078, 0.008, 0.038, 0.011, 0.040, 0.009, 0.038, 0.014, 0.077}, + {0.013, 0.075, 0.008, 0.038, 0.011, 0.039, 0.008, 0.037, 0.013, 0.075}, + {0.013, 0.072, 0.008, 0.036, 0.010, 0.038, 0.008, 0.036, 0.013, 0.072}, + {0.012, 0.069, 0.007, 0.035, 0.010, 0.036, 0.007, 0.035, 0.012, 0.069}, + {0.011, 0.066, 0.007, 0.033, 0.009, 0.035, 0.007, 0.033, 0.011, 0.065}, + {0.010, 0.061, 0.007, 0.031, 0.009, 0.033, 0.007, 0.031, 0.010, 0.061} }; + float C_SigmaDeltaPhi_C[6][10] = { /// Layer, (2*Wheel + Station) + {21.5, 39.7, 19.4, 33.1, 20.4, 32.2, 19.6, 32.8, 21.2, 39.6}, + {20.9, 38.2, 18.7, 32.0, 19.7, 31.2, 18.9, 31.8, 20.6, 38.1}, + {19.9, 36.9, 18.2, 31.0, 19.0, 30.3, 18.2, 30.8, 19.8, 36.8}, + {19.1, 35.1, 17.3, 29.8, 18.0, 29.0, 17.2, 29.4, 18.8, 34.9}, + {17.8, 33.0, 16.3, 28.4, 17.1, 27.4, 16.3, 27.9, 17.5, 32.7}, + {16.7, 31.0, 15.3, 26.9, 16.0, 25.9, 15.3, 26.6, 16.6, 30.9} }; + + float A_SigmaDeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) + {0.008, 0.048, 0.006, 0.025, 0.008, 0.026, 0.006, 0.024, 0.008, 0.047}, + {0.008, 0.047, 0.006, 0.025, 0.008, 0.025, 0.006, 0.023, 0.008, 0.046}, + {0.007, 0.046, 0.005, 0.024, 0.008, 0.025, 0.006, 0.023, 0.008, 0.045}, + {0.008, 0.044, 0.005, 0.023, 0.008, 0.024, 0.006, 0.022, 0.007, 0.045}, + {0.007, 0.043, 0.005, 0.022, 0.008, 0.023, 0.005, 0.022, 0.007, 0.042}, + {0.007, 0.041, 0.005, 0.022, 0.007, 0.022, 0.005, 0.021, 0.007, 0.040} }; + float C_SigmaDeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) + {162.7, 288.3, 159.5, 260.5, 168.9, 283.5, 137.6, 263.3, 146.3, 293.4}, + {156.5, 280.3, 156.3, 253.7, 164.2, 275.9, 133.4, 257.3, 140.5, 283.6}, + {152.2, 269.6, 149.1, 243.0, 157.2, 265.4, 127.2, 247.2, 135.2, 272.6}, + {143.8, 257.6, 141.3, 233.2, 150.4, 254.3, 121.3, 235.4, 129.2, 260.3}, + {136.2, 243.3, 132.6, 221.5, 141.5, 240.2, 113.8, 223.2, 121.3, 247.8}, + {127.5, 229.0, 124.9, 209.5, 134.2, 230.0, 107.5, 213.1, 114.4, 230.7} }; + + + float A_SigmaDeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) + {0.0098, 0.0412, 0.0037, 0.0185, 0.0004, 0.0023, 0.0036, 0.0195, 0.0090, 0.0401}, + {0.0078, 0.0409, 0.0040, 0.0176, 0.0006, 0.0026, 0.0042, 0.0180, 0.0079, 0.0419}, + {0.0098, 0.0432, 0.0040, 0.0173, 0.0008, 0.0027, 0.0042, 0.0177, 0.0079, 0.0434}, + {0.0099, 0.0442, 0.0063, 0.0184, 0.0003, 0.0063, 0.0059, 0.0223, 0.0087, 0.0455}, + {0.0096, 0.0469, 0.0061, 0.0191, 0.0005, 0.0032, 0.0053, 0.0178, 0.0089, 0.0519}, + {0.0124, 0.0451, 0.0054, 0.0175, 0.0009, 0.0032, 0.0056, 0.0211, 0.0100, 0.0434} }; + + float C_SigmaDeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) + {319.0, 351.6, 524.7, 571.8, 730.7, 739.3, 526.0, 569.6, 322.1, 355.0}, + {212.0, 226.9, 331.5, 363.0, 461.0, 464.1, 332.5, 360.9, 212.5, 227.3}, + {144.1, 153.9, 231.6, 249.4, 318.1, 322.6, 232.3, 247.7, 148.1, 155.2}, + {118.5, 122.4, 176.2, 209.0, 211.6, 233.2, 178.0, 186.8, 123.1, 124.3}, + {93.5, 91.5, 140.1, 142.3, 203.2, 198.2, 134.8, 148.0, 97.0, 91.5}, + {73.4, 80.8, 118.9, 124.7, 170.2, 165.9, 118.3, 117.8, 79.2, 84.4} }; + + float A_SigmaDeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) + {0.0109, 0.0345, 0.0059, 0.0186, 0.0011, 0.0016, 0.0054, 0.0205, 0.0047, 0.0360}, + {0.0118, 0.0416, 0.0065, 0.0201, 0.0009, 0.0021, 0.0047, 0.0187, 0.0067, 0.0447}, + {0.0098, 0.0430, 0.0075, 0.0207, 0.0010, 0.0029, 0.0047, 0.0203, 0.0089, 0.0576}, + {0.0098, 0.0351, 0.0100, 0.0259, 0.0001, 0.0027, 0.0090, 0.0257, 0.0093, 0.0506}, + {0.0126, 0.0564, 0.0084, 0.0222, 0.0001, 0.0023, 0.0055, 0.0211, 0.0102, 0.0497}, + {0.0136, 0.0675, 0.0072, 0.0251, 0.0009, 0.0033, 0.0086, 0.0237, 0.0125, 0.0441} }; + + float C_SigmaDeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) + {349.9, 381.4, 527.4, 581.6, 712.4, 725.4, 551.5, 585.6, 350.7, 392.2}, + {226.9, 250.8, 343.2, 373.4, 458.1, 460.3, 358.4, 375.3, 230.5, 258.0}, + {157.4, 169.9, 236.1, 255.5, 320.0, 315.9, 247.0, 260.3, 157.0, 174.2}, + {133.2, 146.5, 181.1, 226.3, 220.3, 237.4, 196.8, 205.4, 132.2, 149.3}, + {103.9, 108.0, 142.1, 162.0, 202.2, 191.0, 156.4, 161.3, 93.4, 116.1}, + {77.8, 90.2, 119.5, 128.7, 168.7, 167.2, 119.5, 134.1, 78.2, 85.1} }; + + int bitShift = 8; + + /// Compute predicted positions and search windows sizes + /// NOTE: phib > 0 negative muons; phib < 0 positive muons + /// code >= 16 High quality ; code < 16 low quality + + int iSt = this->getDTStation() - 1; + int iWh = this->getDTWheel() + 2; + + int thisPhiB = this->getDTTSPhiB(); + + /// Calculate deviation + int extPhi = 0; + int deltaTheta = 0; + + if ( this->getDTCode() >= 16 ) /// High quality muons + { + extPhi = static_cast< int >( A_DeltaPhi_C[iTk][2*iWh+iSt] * bitShift * fabs(static_cast< float >(thisPhiB)) * static_cast< float >(thisPhiB) ) + + static_cast< int >( B_DeltaPhi_C[iTk][2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) ); + + deltaTheta = static_cast< int >( A_DeltaTheta_C[iTk][2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_DeltaTheta_C[iTk][2*iWh+iSt] * bitShift ); + } + else /// Low quality muons + { + extPhi = static_cast< int >( A_DeltaPhi_S[iTk][2*iWh+iSt] * bitShift * fabs(static_cast< float >(thisPhiB)) * static_cast< float >(thisPhiB) ) + + static_cast< int >( B_DeltaPhi_S[iTk][2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) ); + + deltaTheta = static_cast< int >( A_DeltaTheta_S[iTk][2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_DeltaTheta_S[iTk][2*iWh+iSt] * bitShift ); + } + + /// The projected angles + int predPhi = this->getDTTSPhi() - extPhi/bitShift + + static_cast< int >( (this->getDTSector() - 1) * M_PI/6. * 4096. ); /// This brings local phi (getDTTSPhi) to global phi + + int predTheta = this->getDTTSTheta() - deltaTheta/bitShift; + + if ( predPhi < 0 ) + { + predPhi += static_cast< int >( 2. * M_PI * 4096. ); + } + + /// Calculate errors + int windowPhi = 0; + int windowTheta = 0; + + if ( this->getDTCode() >= 16 ) /// High quality muons + { + windowPhi = static_cast< int >( A_SigmaDeltaPhi_C[iTk][2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaPhi_C[iTk][2*iWh+iSt] ); + + windowTheta = static_cast< int >( A_SigmaDeltaTheta_C[iTk][2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaTheta_C[iTk][2*iWh+iSt] ); + } + else /// Low quality muons + { + windowPhi = static_cast< int >( A_SigmaDeltaPhi_S[iTk][2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaPhi_S[iTk][2*iWh+iSt] ); + + windowTheta = static_cast< int >( A_SigmaDeltaTheta_S[iTk][2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaTheta_S[iTk][2*iWh+iSt] ); + } + + this->setPredStubPhi( aLayer, predPhi, windowPhi ); + this->setPredStubTheta( aLayer, predTheta, windowTheta ); + + return; +} + +/// Extrapolation to the vertex +void DTMatch::extrapolateToVertex() +{ + /// Compute DT predicted phi and theta on tracker layers (each wheel) from Ext + /// NOTE: needs to be extrapolated because of bending... + /// Ext = A*|Bending|*Bending + B*Bending = Bti - Predicted, where Bti = Trigger + sector + /// Predicted = Trigger - (A*|Bending|*Bending + B*Bending) + sector + /// The chosen function is an antisymmetric 2nd degree polynomial + /// For theta, it is a symmetric 2nd degree polynomial + + /// By 2*Wheel+Station + float A_DeltaPhi_C[10] = {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}; + float B_DeltaPhi_C[10] = {13.8, 23.1, 12.5, 19.6, 12.7, 19.2, 12.5, 19.6, 13.9, 23.0}; + float A_DeltaPhi_S[10] = {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.014, 0.032, 0.016, 0.042}; + float B_DeltaPhi_S[10] = {14.1, 23.3, 12.5, 19.6, 12.6, 19.1, 12.5, 19.6, 14.1, 23.2}; + float A_DeltaTheta_C[10] = {0.006, 0.015, 0.004, 0.009, -0.000, -0.000, -0.004, -0.009, -0.006, -0.015}; + float C_DeltaTheta_C[10] = {23.3, 24.0, 22.0, 24.5, 0.8, 0.1, -21.9, -23.0, -25.1, -20.3}; + float A_DeltaTheta_S[10] = {0.006, 0.016, 0.005, 0.010, -0.000, -0.000, -0.004, -0.009, -0.006, -0.016}; + float C_DeltaTheta_S[10] = {51.3, 42.7, 42.9, 36.7, 1.5, -0.2, -38.9, -36.6, -52.4, -40.8}; + + /// Extrapolation windows + float A_SigmaDeltaPhi_C[10] = {0.015, 0.081, 0.009, 0.040, 0.012, 0.042, 0.009, 0.040, 0.015, 0.081}; + float C_SigmaDeltaPhi_C[10] = {23.0, 41.1, 20.7, 35.3, 21.8, 34.0, 20.9, 34.9, 22.7, 41.1}; + float A_SigmaDeltaPhi_S[10] = {0.008, 0.050, 0.006, 0.025, 0.009, 0.026, 0.006, 0.024, 0.009, 0.049}; + float C_SigmaDeltaPhi_S[10] = {172.0, 303.3, 168.2, 274.3, 177.8, 296.9, 144.8, 275.0, 153.2, 306.0}; + float A_SigmaDeltaTheta_C[10] = {0.0098, 0.0437, 0.0052, 0.0185, 0.0017, 0.0049, 0.0054, 0.0187, 0.0098, 0.0432}; + float C_SigmaDeltaTheta_C[10] = {55.4, 46.2, 79.8, 71.3, 103.4, 87.9, 79.5, 71.0, 55.2, 46.4}; + float A_SigmaDeltaTheta_S[10] = {0.0113, 0.0546, 0.0078, 0.0228, 0.0015, 0.0048, 0.0061, 0.0224, 0.0103, 0.0523}; + float C_SigmaDeltaTheta_S[10] = {55.0, 58.0, 92.2, 83.4, 110.6, 95.3, 93.5, 82.8, 53.8, 55.4}; + + /// Error on PhiB vs. PhiB + float A_SigmaPhiB_C[10] = {0.00069, 0.00219, 0.00050, 0.00132, 0.00058, 0.00146, 0.00050, 0.00130, 0.00068, 0.00219}; + float B_SigmaPhiB_C[10] = {0.046, 0.069, 0.034, 0.044, 0.035, 0.041, 0.034, 0.045, 0.046, 0.068}; + float C_SigmaPhiB_C[10] = {1.3, 1.5, 1.4, 1.5, 1.4, 1.5, 1.4, 1.5, 1.3, 1.5}; + float A_SigmaPhiB_S[10] = {0.00047, 0.00163, 0.00030, 0.00092, 0.00042, 0.00091, 0.00060, 0.00082, 0.00055, 0.00158}; + float B_SigmaPhiB_S[10] = {0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000}; + float C_SigmaPhiB_S[10] = {12.2, 12.7, 13.6, 13.5, 13.9, 14.7, 10.1, 13.6, 10.7, 12.9}; + + /// Integer calculations: shift by 3 bits to preserve resolution + int bitShift = 8; + + /// Calculate the error on PhiB + int iWh = this->getDTWheel() + 2; + int iSt = this->getDTStation() - 1; + int thisPhiB = this->getDTTSPhiB(); + float predSigmaPhiB = 0.; + + /// Parameterisation with a 2nd degree polynomial + if ( this->getDTCode() >= 16 ) + { + predSigmaPhiB = A_SigmaPhiB_C[iSt+2*iWh] * thisPhiB * thisPhiB + + B_SigmaPhiB_C[iSt+2*iWh] * abs(thisPhiB) + + C_SigmaPhiB_C[iSt+2*iWh]; + } + else + { + predSigmaPhiB = A_SigmaPhiB_S[iSt+2*iWh] * thisPhiB * thisPhiB + + B_SigmaPhiB_S[iSt+2*iWh] * abs(thisPhiB) + + C_SigmaPhiB_S[iSt+2*iWh]; + } + + this->setPredSigmaPhiB( predSigmaPhiB ); + + /// Calculate deviation + int extPhi = 0; + int deltaTheta = 0; + + if ( this->getDTCode() >= 16 ) /// High quality muons + { + extPhi = static_cast< int >( A_DeltaPhi_C[2*iWh+iSt] * bitShift * fabs(static_cast< float >(thisPhiB)) * static_cast< float >(thisPhiB) ) + + static_cast< int >( B_DeltaPhi_C[2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) ); + + deltaTheta = static_cast< int >( A_DeltaTheta_C[2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_DeltaTheta_C[2*iWh+iSt] * bitShift ); + } + else /// Low quality muons + { + extPhi = static_cast< int >( A_DeltaPhi_S[2*iWh+iSt] * bitShift * fabs(static_cast< float >(thisPhiB)) * static_cast< float >(thisPhiB) ) + + static_cast< int >( B_DeltaPhi_S[2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) ); + + deltaTheta = static_cast< int >( A_DeltaTheta_S[2*iWh+iSt] * bitShift * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_DeltaTheta_S[2*iWh+iSt] * bitShift ); + } + + /// The projected angles + int predPhi = this->getDTTSPhi() - extPhi/bitShift + + static_cast< int >( (this->getDTSector() - 1) * M_PI/6. * 4096. ); /// This brings local phi (getDTTSPhi) to global phi + + int predTheta = this->getDTTSTheta() - deltaTheta/bitShift; + + if ( predPhi < 0 ) + { + predPhi += static_cast< int >( 2. * M_PI * 4096. ); + } + + int windowPhi = 0; + int windowTheta = 0; + + if ( this->getDTCode() >= 16 ) /// High quality muons + { + windowPhi = static_cast< int >( A_SigmaDeltaPhi_C[2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaPhi_C[2*iWh+iSt] ); + + windowTheta = static_cast< int >( A_SigmaDeltaTheta_C[2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaTheta_C[2*iWh+iSt] ); + } + else /// Low quality muons + { + windowPhi = static_cast< int >( A_SigmaDeltaPhi_S[2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaPhi_S[2*iWh+iSt] ); + + windowTheta = static_cast< int >( A_SigmaDeltaTheta_S[2*iWh+iSt] * static_cast< float >(thisPhiB) * static_cast< float >(thisPhiB) ) + + static_cast< int >( C_SigmaDeltaTheta_S[2*iWh+iSt] ); + } + + this->setPredVtxPhi( predPhi, windowPhi ); + this->setPredVtxTheta( predTheta, windowTheta ); + + return; +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTTSPhiTrigger.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTTSPhiTrigger.cc new file mode 100644 index 0000000000000..23f89fa86ae55 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTTSPhiTrigger.cc @@ -0,0 +1,53 @@ +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h" +#include + +/// Constructors +DTTSPhiTrigger::DTTSPhiTrigger() : + DTChambPhSegm( DTChamberId(), 0 ) +{} + +DTTSPhiTrigger::DTTSPhiTrigger( const DTChambPhSegm& ChPhisegm, + Global3DPoint position, + Global3DVector direction ) : + DTChambPhSegm(ChPhisegm), + _position(position), + _direction(direction) +{ + _wheel = this->wheel(); + _station = this->station(); + _sector = this->sector(); + + /// trigger K parameter converted to angle (scaled bit pattern) + _psi = this->psi(); + + /// trigger X parameter converted to angle (scaled bit pattern) + _psiR = this->psiR(); + + /// bending angle (scaled bit pattern) + _DeltaPsiR = this->DeltaPsiR(); + + /// bending angle (unscaled float) + _phiB = this->phiB(); +} + +/// Debug function +std::string DTTSPhiTrigger::sprint() const +{ + std::ostringstream outString; + outString << " wheel " << this->wheel() + << " station " << this->station() + << " sector " << this->sector() + << " traco Nr " << this->tracoNumber() + << " at step " << this->step() + << " code " << this->code() << std::endl; + outString << " K " << this->K() + << " X " << this->X() + << " psi " << this->psi() + << " psiR " << this->psiR() + << " DeltaPsiR " << this->DeltaPsiR() + << " phiB " << this->phiB() << std::endl; + outString << " position " << this->cmsPosition() << std::endl; + outString << " direction" << this->cmsDirection() << std::endl; + return outString.str(); +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/classes.h b/DataFormats/L1DTPlusTrackTrigger/src/classes.h new file mode 100644 index 0000000000000..0f11756b356a8 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/classes.h @@ -0,0 +1,43 @@ +#include "DataFormats/Common/interface/Wrapper.h" + +#include "L1Trigger/DTTrackFinder/interface/L1MuDTTrack.h" +#include "L1Trigger/DTTrackFinder/src/L1MuDTAddressArray.h" +#include "L1Trigger/DTTrackFinder/src/L1MuDTSecProcId.h" +#include "L1Trigger/DTTrackFinder/src/L1MuDTTrackSegLoc.h" + +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h" + +#include +#include + +namespace +{ + namespace + { + edm::Wrapper< DTBtiTrigger > wBTI; + std::vector< DTBtiTrigger > vBTI; + edm::Wrapper< std::vector< DTBtiTrigger > > wvBTI; + + edm::Wrapper< DTTSPhiTrigger > wTSPhi; + std::vector< DTTSPhiTrigger > vTSPhi; + edm::Wrapper< std::vector< DTTSPhiTrigger > > wvTSPhi; + + edm::Wrapper< DTMatch > wDTM; + std::vector< DTMatch > vDTM; + edm::Wrapper< std::vector< DTMatch > > wVDTM; + edm::Ptr< DTMatch > ptrDTM; + + std::string STR; + edm::Wrapper wSTR; + + edm::Wrapper< DTMatchPt > wDTMPt; + std::pair< std::string, DTMatchPt > pDTMPt; + edm::Wrapper< std::pair< std::string, DTMatchPt > > wpDTMPt; + std::map< std::string, DTMatchPt > mDTMPt; + edm::Wrapper< std::map< std::string, DTMatchPt > > wmDTMPt; + } +} + diff --git a/DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml b/DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml new file mode 100644 index 0000000000000..fbddd6ee36587 --- /dev/null +++ b/DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h index 0afdc84357e36..0292cf096c986 100644 --- a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h +++ b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h @@ -4,83 +4,53 @@ // -*- C++ -*- // // Package: L1Trigger -// Class : L1TkEmParticle -// +// Class : L1TkMuonParticle #include "DataFormats/Candidate/interface/LeafCandidate.h" #include "DataFormats/Common/interface/Ref.h" #include "DataFormats/Common/interface/Ptr.h" #include "DataFormats/L1Trigger/interface/L1EmParticleFwd.h" - #include "DataFormats/L1TrackTrigger/interface/L1TkEmParticle.h" - #include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" + #include "DataFormats/L1TrackTrigger/interface/TTTypes.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h" #include "DataFormats/L1Trigger/interface/L1MuonParticle.h" #include "DataFormats/L1Trigger/interface/L1MuonParticleFwd.h" -// PL :include PierLuigi's class -// #include "....." - -namespace l1extra { - - class L1TkMuonParticle : public reco::LeafCandidate - { - - public: - - typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; - typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - - L1TkMuonParticle(); - - L1TkMuonParticle( const LorentzVector& p4, - // const edm::Ref< XXXCollection >& muRef, // reference to PL's object - const edm::Ref< L1MuonParticleCollection >& muRef, - const edm::Ptr< L1TkTrackType >& trkPtr, - float tkisol = -999. ); - - virtual ~L1TkMuonParticle() {} +namespace l1extra +{ + class L1TkMuonParticle : public reco::LeafCandidate + { + public: - // ---------- const member functions --------------------- + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - const edm::Ptr< L1TkTrackType >& getTrkPtr() const - { return trkPtr_ ; } + L1TkMuonParticle(); + L1TkMuonParticle( const LorentzVector& p4, + const edm::Ptr< DTMatch >& muRef, + float tkisol = -999. ); + virtual ~L1TkMuonParticle() {} - // PL : - // const edm::Ref< XXXCollection >& getMuRef() const - // { return muRef_ ; } + // const member functions + const edm::Ptr< DTMatch >& getDTMatchPtr() const { return theDTMatch; } + float getTrkIsol() const { return theIsolation; } - float getTrkzVtx() const { return TrkzVtx_ ; } - float getTrkIsol() const { return TrkIsol_ ; } + int bx() const { return theDTMatch->getDTBX(); } + private: - // ---------- member functions --------------------------- + edm::Ptr< DTMatch > theDTMatch; + float theIsolation; - void setTrkzVtx(float TrkzVtx) { TrkzVtx_ = TrkzVtx ; } - void setTrkIsol(float TrkIsol) { TrkIsol_ = TrkIsol ; } - int bx() const; - - //void setDeltaR(float dr) { DeltaR_ = dr ; } - - private: - - // PL - // edm::Ref< XXXCollection > muRef_ ; - edm::Ref< L1MuonParticleCollection > muRef_ ; - - edm::Ptr< L1TkTrackType > trkPtr_ ; - - float TrkIsol_; - float TrkzVtx_ ; - - //float DeltaR_ ; // temporary - - }; + }; } #endif - diff --git a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h.backup b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h.backup new file mode 100644 index 0000000000000..0afdc84357e36 --- /dev/null +++ b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h.backup @@ -0,0 +1,86 @@ +#ifndef L1TkTrigger_L1MuonParticle_h +#define L1TkTrigger_L1MuonParticle_h + +// -*- C++ -*- +// +// Package: L1Trigger +// Class : L1TkEmParticle +// + +#include "DataFormats/Candidate/interface/LeafCandidate.h" +#include "DataFormats/Common/interface/Ref.h" +#include "DataFormats/Common/interface/Ptr.h" + +#include "DataFormats/L1Trigger/interface/L1EmParticleFwd.h" + +#include "DataFormats/L1TrackTrigger/interface/L1TkEmParticle.h" + +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + +#include "DataFormats/L1Trigger/interface/L1MuonParticle.h" +#include "DataFormats/L1Trigger/interface/L1MuonParticleFwd.h" + +// PL :include PierLuigi's class +// #include "....." + +namespace l1extra { + + class L1TkMuonParticle : public reco::LeafCandidate + { + + public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + L1TkMuonParticle(); + + L1TkMuonParticle( const LorentzVector& p4, + // const edm::Ref< XXXCollection >& muRef, // reference to PL's object + const edm::Ref< L1MuonParticleCollection >& muRef, + const edm::Ptr< L1TkTrackType >& trkPtr, + float tkisol = -999. ); + + virtual ~L1TkMuonParticle() {} + + // ---------- const member functions --------------------- + + const edm::Ptr< L1TkTrackType >& getTrkPtr() const + { return trkPtr_ ; } + + // PL : + // const edm::Ref< XXXCollection >& getMuRef() const + // { return muRef_ ; } + + float getTrkzVtx() const { return TrkzVtx_ ; } + float getTrkIsol() const { return TrkIsol_ ; } + + + // ---------- member functions --------------------------- + + void setTrkzVtx(float TrkzVtx) { TrkzVtx_ = TrkzVtx ; } + void setTrkIsol(float TrkIsol) { TrkIsol_ = TrkIsol ; } + int bx() const; + + //void setDeltaR(float dr) { DeltaR_ = dr ; } + + private: + + // PL + // edm::Ref< XXXCollection > muRef_ ; + edm::Ref< L1MuonParticleCollection > muRef_ ; + + edm::Ptr< L1TkTrackType > trkPtr_ ; + + float TrkIsol_; + float TrkzVtx_ ; + + //float DeltaR_ ; // temporary + + }; +} + +#endif + + diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index 10be385fe906e..d7c77eddd0563 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -1,52 +1,22 @@ // -*- C++ -*- // // Package: L1Trigger -// Class : L1TkEmParticle -// +// Class : L1TkMuonParticle #include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h" +using namespace l1extra; -using namespace l1extra ; - - -L1TkMuonParticle::L1TkMuonParticle() -{ -} +L1TkMuonParticle::L1TkMuonParticle() {} L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, - // const edm::Ref< XXXCollection >& muRef, // PL - const edm::Ref< L1MuonParticleCollection > &muRef, - const edm::Ptr< L1TkTrackType >& trkPtr, - float tkisol ) - : LeafCandidate( ( char ) 0, p4 ), - muRef_ ( muRef ) , // PL uncomment - trkPtr_ ( trkPtr ) , - TrkIsol_ ( tkisol ) - + const edm::Ptr< DTMatch > &muRef, + float tkisol ) + : LeafCandidate( ( char ) 0, p4 ), + theDTMatch ( muRef ) , + theIsolation ( tkisol ) { + // other constructor operations if needed - if ( trkPtr_.isNonnull() ) { - float z = getTrkPtr() -> getPOCA().z(); - setTrkzVtx( z ); - } } -int L1TkMuonParticle::bx() const { - int dummy = -999; - // PL. In case Pierluigi's objects have a bx -/* - if ( muRef_.isNonnull() ) { - return (getMuRef() -> bx()) ; - } - else { - return dummy; - - } -*/ - return dummy; -} - - - - diff --git a/DataFormats/L1TrackTrigger/src/classes_def.xml b/DataFormats/L1TrackTrigger/src/classes_def.xml index 72fed61e2bdaf..e45542a4e2398 100644 --- a/DataFormats/L1TrackTrigger/src/classes_def.xml +++ b/DataFormats/L1TrackTrigger/src/classes_def.xml @@ -84,8 +84,8 @@ - - + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc index eaf692df19520..df94d341e65bc 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc @@ -1,11 +1,5 @@ // -*- C++ -*- // -// -// dummy producer for a L1TkMuonParticle -// This is just an interface, taking the muon objects created -// by PierLuigi's code, and putting them into a collection of -// L1TkMuonParticle. -// // system include files #include @@ -13,7 +7,6 @@ // user include files #include "FWCore/Framework/interface/Frameworkfwd.h" #include "FWCore/Framework/interface/EDProducer.h" - #include "FWCore/Framework/interface/Event.h" #include "FWCore/Framework/interface/MakerMacros.h" #include "FWCore/Framework/interface/ESHandle.h" @@ -24,318 +17,270 @@ #include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h" + #include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h" #include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticleFwd.h" - #include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" #include "DataFormats/Math/interface/LorentzVector.h" - -// for L1Tracks: -//#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" - #include "DataFormats/HepMCCandidate/interface/GenParticle.h" #include #include "TMath.h" +using namespace l1extra; -using namespace l1extra ; - -// // class declaration -// - -class L1TkMuonParticleProducer : public edm::EDProducer { - public: - - typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; - typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - - explicit L1TkMuonParticleProducer(const edm::ParameterSet&); - ~L1TkMuonParticleProducer(); - - static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); - - private: - virtual void beginJob() ; - virtual void produce(edm::Event&, const edm::EventSetup&); - virtual void endJob() ; - - //virtual void beginRun(edm::Run&, edm::EventSetup const&); - //virtual void endRun(edm::Run&, edm::EventSetup const&); - //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); - //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); - - // ----------member data --------------------------- - - //edm::InputTag L1PLInputTag; // inputTag for PierLuigi's objects - - edm::InputTag L1MuonsInputTag; - edm::InputTag L1TrackInputTag; - - float ETAMIN; - float ETAMAX; - float ZMAX; // |z_track| < ZMAX in cm - float CHI2MAX; - float PTMINTRA; - float DRmax; - - int nStubsmin ; // minimum number of stubs - - bool closest ; - - -} ; - - -// -// constructors and destructor -// -L1TkMuonParticleProducer::L1TkMuonParticleProducer(const edm::ParameterSet& iConfig) +class L1TkMuonParticleProducer : public edm::EDProducer { + public: + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - //L1PLInputTag = iConfig.getParameter("L1PLInputTag"); + explicit L1TkMuonParticleProducer( const edm::ParameterSet& ); + ~L1TkMuonParticleProducer(); - L1MuonsInputTag = iConfig.getParameter("L1MuonsInputTag"); - L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); - ETAMIN = (float)iConfig.getParameter("ETAMIN"); - ETAMAX = (float)iConfig.getParameter("ETAMAX"); - ZMAX = (float)iConfig.getParameter("ZMAX"); - CHI2MAX = (float)iConfig.getParameter("CHI2MAX"); - PTMINTRA = (float)iConfig.getParameter("PTMINTRA"); - DRmax = (float)iConfig.getParameter("DRmax"); - nStubsmin = iConfig.getParameter("nStubsmin"); - closest = iConfig.getParameter("closest"); + private: + virtual void beginJob(); + virtual void produce( edm::Event&, const edm::EventSetup& ); + virtual void endJob(); +}; - produces(); -} - -L1TkMuonParticleProducer::~L1TkMuonParticleProducer() { -} - -// ------------ method called to produce the data ------------ -void -L1TkMuonParticleProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +// constructors and destructor +L1TkMuonParticleProducer::L1TkMuonParticleProducer( const edm::ParameterSet& iConfig ) { - using namespace edm; - using namespace std; - - - std::auto_ptr result(new L1TkMuonParticleCollection); - - // dummy code. I loop over the L1Muons and pick up the L1Track that is closest - // in DeltaR. - - edm::Handle< vector > MuonHandle; - iEvent.getByLabel(L1MuonsInputTag,MuonHandle); - vector::const_iterator l1MuIter; - - edm::Handle L1TkTrackHandle; - iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); - L1TkTrackCollectionType::const_iterator trackIter; - - - int imu = 0; - for (l1MuIter = MuonHandle->begin(); l1MuIter != MuonHandle->end(); ++l1MuIter) { - - edm::Ref< L1MuonParticleCollection > MuRef( MuonHandle, imu ); - imu ++; - - float drmin = 999; - float ptmax = -1; - if (ptmax < 0) ptmax = -1; // dummy - - float eta = l1MuIter -> eta(); - float phi = l1MuIter -> phi(); - - float feta = fabs( eta ); - if (feta < ETAMIN) continue; - if (feta > ETAMAX) continue; - - L1MuGMTExtendedCand cand = l1MuIter -> gmtMuonCand(); - unsigned int quality = cand.quality(); - int bx = l1MuIter -> bx() ; - if (bx != 0 ) continue; - if (quality < 3) continue; - - // match the L1Muons with L1Tracks - - int itr = -1; - int itrack = -1; - for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { - itr ++ ; - float Pt = trackIter->getMomentum().perp(); - float z = trackIter->getPOCA().z(); - if (fabs(z) > ZMAX) continue; - if (Pt < PTMINTRA) continue; - float chi2 = trackIter->getChi2(); - if (chi2 > CHI2MAX) continue; - - std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubs = trackIter -> getStubRefs() ; - int tmp_trk_nstub = (int) theStubs.size(); - if ( tmp_trk_nstub < nStubsmin) continue; - - float Eta = trackIter->getMomentum().eta(); - float Phi = trackIter->getMomentum().phi(); - float deta = eta - Eta; - float dphi = phi - Phi; - if (dphi < 0) dphi = dphi + 2.*TMath::Pi(); - if (dphi > TMath::Pi()) dphi = 2.*TMath::Pi() - dphi; - float dR = sqrt( deta*deta + dphi*dphi ); - - if (closest) { - // take the closest track: - if (dR < drmin) { - drmin = dR; - itrack = itr; - } - } - else { - // or take the leading track within a cone - if (dR < DRmax) { - if (Pt > ptmax) { - ptmax = Pt; - itrack = itr; - drmin = dR; - } - } - } - - } // end loop over the tracks - - if (drmin < DRmax ) { // found a L1Track matched to the L1Muon object - - edm::Ptr< L1TkTrackType > L1TrackPtr( L1TkTrackHandle, itrack) ; - - float px = L1TrackPtr -> getMomentum().x(); - float py = L1TrackPtr -> getMomentum().y(); - float pz = L1TrackPtr -> getMomentum().z(); - float e = sqrt( px*px + py*py + pz*pz ); // massless particle - math::XYZTLorentzVector TrackP4(px,py,pz,e); - - float trkisol = -999; // dummy - - L1TkMuonParticle trkMu( TrackP4, - MuRef, - L1TrackPtr, - trkisol ); - - //trkMu.setDeltaR ( drmin ) ; - - result -> push_back( trkMu ); - - - } // endif drmin < DRmax - - - } // end loop over the L1Muons - - // PL: the muon objects from PierLuigi -/* - edm::Handle XXXHandle; - iEvent.getByLabel(L1PLInputTag,XXXHandle); - std::vector::const_iterator muIter ; - - if (!XXXHandle.isValid() ) { - LogError("L1TkMuonParticleProducer") - << "\nWarning: L1XXXCollectionType with " << L1PLInputTag - << "\nrequested in configuration, but not found in the event. Exit." - << std::endl; - return; - } - - // Now loop over the muons of Pierluigi - - int imu = 0; - for (muIter = XXXHandle->begin(); muIter != XXXHandle->end(); ++muIter) { - - edm::Ref< XXXCollection > muRef( XXXHandle, imu ); - imu ++; - - // int bx = egIter -> bx() ; // if PL's objects have a bx method - int bx = 0; // else... - - if (bx == 0) { - - edm::Ptr< L1TkTrackType > L1TrackPtr ; - - // PL : get the matched L1Track from PL's object - // L1TrackPtr = muRef -> getRefToTheL1Track() ; - - float px = L1TrackPtr -> getMomentum().x(); - float py = L1TrackPtr -> getMomentum().y(); - float pz = L1TrackPtr -> getMomentum().z(); - float e = sqrt( px*px + py*py + pz*pz ); // massless particle - math::XYZTLorentzVector TrackP4(px,py,pz,e); - - // the code may calculate a tracker-based isolation variable, - // or pick it up from PL's object if it is there. - // for the while, dummy. - float trkisol = -999; - - - L1TkMuonParticle trkMu( P4, - // muRef, - L1TrackPtr, - trkisol ); - - } // endif bx==0 - - } // end loop over Pierluigi's objects -*/ - - iEvent.put( result ); - + produces< L1TkMuonParticleCollection >("DTMatchInwardsPriority"); + produces< L1TkMuonParticleCollection >("DTMatchInwardsAverage"); + produces< L1TkMuonParticleCollection >("DTMatchInwardsMajorityFullTk"); + produces< L1TkMuonParticleCollection >("DTMatchInwardsMajority"); + produces< L1TkMuonParticleCollection >("DTMatchInwardsMixedMode"); + produces< L1TkMuonParticleCollection >("DTMatchInwardsTTTrack"); + produces< L1TkMuonParticleCollection >("DTMatchInwardsTTTrackFullReso"); } -// -------------------------------------------------------------------------------------- +L1TkMuonParticleProducer::~L1TkMuonParticleProducer() {} - -// ------------ method called once each job just before starting event loop ------------ -void -L1TkMuonParticleProducer::beginJob() +// method called to produce the data +void L1TkMuonParticleProducer::produce( edm::Event& iEvent, const edm::EventSetup& iSetup ) { -} + using namespace edm; + using namespace std; + +std::cout << " --- MANU enter in L1TkMuonParticleProducer " << std::endl; + + std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsPriority( new L1TkMuonParticleCollection ); + std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsAverage( new L1TkMuonParticleCollection ); + std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsMajorityFullTk( new L1TkMuonParticleCollection ); + std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsMajority( new L1TkMuonParticleCollection ); + std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsMixedMode( new L1TkMuonParticleCollection ); + std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsTTTrack( new L1TkMuonParticleCollection ); + std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsTTTrackFullReso( new L1TkMuonParticleCollection ); + + // input from DT+Tk trigger (Padova-Trento) + edm::Handle< std::vector< DTMatch > > DTMatchHandle; + iEvent.getByLabel( "DTPlusTrackProducer", DTMatchHandle ); + std::vector< DTMatch >::const_iterator iterDTMatch; + + int iMu = 0; + for ( iterDTMatch = DTMatchHandle->begin(); + iterDTMatch != DTMatchHandle->end(); + ++iterDTMatch ) + { + +std::cout << " here a DT match " << std::endl; + + // create the reference to DTMatch FIXME + edm::Ptr< DTMatch > dtMatchRef( DTMatchHandle, iMu++ ); + + // get the bx + int bx = iterDTMatch->getDTBX(); +std::cout << " bx = " << bx << std::endl; + +// MANU CHECK ! + //if ( bx != 0 ) continue; + +std::cout << " passes bx " << std::endl; + + // check the different options + +std::cout << " iterDTMatch->getPtPriorityBin() > 0. " << iterDTMatch->getPtPriorityBin() << std::endl; + + if ( iterDTMatch->getPtPriorityBin() > 0. ) + { + float tkIso = -999; // dummy + + // build momentum from PtBin + // no TTTrack used for this method: direction comes from + // the DT object (TSPhi and TSTheta) + float pt = iterDTMatch->getPtPriorityBin(); + float px = pt * cos( iterDTMatch->getDTDirection().phi() ); + float py = pt * sin( iterDTMatch->getDTDirection().phi() ); + float pz = pt * tan( iterDTMatch->getDTDirection().theta() ); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector candP4(px, py, pz, e); + + // create the candidate + L1TkMuonParticle candMu( candP4, dtMatchRef, tkIso ); + + // put it in the collection + outputDTMatchInwardsPriority->push_back( candMu ); + } + + if ( iterDTMatch->getPtAverageBin() > 0. ) + { + float tkIso = -999; // dummy + + // build momentum from PtBin + // no TTTrack used for this method: direction comes from + // the DT object (TSPhi and TSTheta) + float pt = iterDTMatch->getPtAverageBin(); + float px = pt * cos( iterDTMatch->getDTDirection().phi() ); + float py = pt * sin( iterDTMatch->getDTDirection().phi() ); + float pz = pt * tan( iterDTMatch->getDTDirection().theta() ); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector candP4(px, py, pz, e); + + // create the candidate + L1TkMuonParticle candMu( candP4, dtMatchRef, tkIso ); + + // put it in the collection + outputDTMatchInwardsAverage->push_back( candMu ); + } + + if ( iterDTMatch->getPtMajorityFullTkBin() > 0. ) + { + float tkIso = -999; // dummy + + // build momentum from PtBin + // no TTTrack used for this method: direction comes from + // the DT object (TSPhi and TSTheta) + float pt = iterDTMatch->getPtMajorityFullTkBin(); + float px = pt * cos( iterDTMatch->getDTDirection().phi() ); + float py = pt * sin( iterDTMatch->getDTDirection().phi() ); + float pz = pt * tan( iterDTMatch->getDTDirection().theta() ); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector candP4(px, py, pz, e); + + // create the candidate + L1TkMuonParticle candMu( candP4, dtMatchRef, tkIso ); + + // put it in the collection + outputDTMatchInwardsMajorityFullTk->push_back( candMu ); + } + + if ( iterDTMatch->getPtMajorityBin() > 0. ) + { + float tkIso = -999; // dummy + + // build momentum from PtBin + // no TTTrack used for this method: direction comes from + // the DT object (TSPhi and TSTheta) + float pt = iterDTMatch->getPtMajorityBin(); + float px = pt * cos( iterDTMatch->getDTDirection().phi() ); + float py = pt * sin( iterDTMatch->getDTDirection().phi() ); + float pz = pt * tan( iterDTMatch->getDTDirection().theta() ); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector candP4(px, py, pz, e); + + // create the candidate + L1TkMuonParticle candMu( candP4, dtMatchRef, tkIso ); + + // put it in the collection + outputDTMatchInwardsMajority->push_back( candMu ); + } + + if ( iterDTMatch->getPtMixedModeBin() > 0. ) + { + float tkIso = -999; // dummy + + // build momentum from PtBin + // no TTTrack used for this method: direction comes from + // the DT object (TSPhi and TSTheta) + float pt = iterDTMatch->getPtMixedModeBin(); + float px = pt * cos( iterDTMatch->getDTDirection().phi() ); + float py = pt * sin( iterDTMatch->getDTDirection().phi() ); + float pz = pt * tan( iterDTMatch->getDTDirection().theta() ); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector candP4(px, py, pz, e); + + // create the candidate + L1TkMuonParticle candMu( candP4, dtMatchRef, tkIso ); + + // put it in the collection + outputDTMatchInwardsMixedMode->push_back( candMu ); + } + +std::cout << " iterDTMatch->getPtTTTrackBin() > 0. " << iterDTMatch->getPtTTTrackBin() << std::endl; + + if ( iterDTMatch->getPtTTTrackBin() > 0. ) + { + float tkIso = -999; // dummy + + // build momentum from PtBin + // TTTrack used for this method: direction comes from the TTTrack + float pt = iterDTMatch->getPtTTTrackBin(); + GlobalVector tkMomentum = iterDTMatch->getPtMatchedTrackPtr()->getMomentum(); + float px = pt * cos( tkMomentum.phi() ); + float py = pt * sin( tkMomentum.phi() ); + float pz = pt * tan( tkMomentum.theta() ); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector candP4(px, py, pz, e); + + // create the candidate + L1TkMuonParticle candMu( candP4, dtMatchRef, tkIso ); + + // put it in the collection + outputDTMatchInwardsTTTrack->push_back( candMu ); + } + + if ( iterDTMatch->getPtMatchedTrackPtr().isNull() == false ) + { + float tkIso = -999; // dummy + + // build momentum from PtBin + // TTTrack used for this method: direction comes from the TTTrack + GlobalVector tkMomentum = iterDTMatch->getPtMatchedTrackPtr()->getMomentum(); + float px = tkMomentum.x(); + float py = tkMomentum.y(); + float pz = tkMomentum.z(); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector candP4(px, py, pz, e); + + // create the candidate + L1TkMuonParticle candMu( candP4, dtMatchRef, tkIso ); + + // put it in the collection + outputDTMatchInwardsTTTrackFullReso->push_back( candMu ); + } + + + } // end loop over Padova-Trento objects + + // store the collections + iEvent.put( outputDTMatchInwardsPriority , "DTMatchInwardsPriority"); + iEvent.put( outputDTMatchInwardsAverage , "DTMatchInwardsAverage"); + iEvent.put( outputDTMatchInwardsMajorityFullTk , "DTMatchInwardsMajorityFullTk"); + iEvent.put( outputDTMatchInwardsMajority , "DTMatchInwardsMajority"); + iEvent.put( outputDTMatchInwardsMixedMode , "DTMatchInwardsMixedMode"); + iEvent.put( outputDTMatchInwardsTTTrack , "DTMatchInwardsTTTrack" ); + iEvent.put( outputDTMatchInwardsTTTrackFullReso, "DTMatchInwardsTTTrackFullReso" ); -// ------------ method called once each job just after ending the event loop ------------ -void -L1TkMuonParticleProducer::endJob() { -} -// ------------ method called when starting to processes a run ------------ -/* -void -L1TkMuonParticleProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) -{ } -*/ -// ------------ method called when ending the processing of a run ------------ -/* -void -L1TkMuonParticleProducer::endRun(edm::Run&, edm::EventSetup const&) -{ -} -*/ +// method called once each job just before starting event loop +void L1TkMuonParticleProducer::beginJob() {} -// ------------ method called when starting to processes a luminosity block ------------ -/* -void -L1TkMuonParticleProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) -{ -} -*/ - -// ------------ method called when ending the processing of a luminosity block ------------ -/* -void -L1TkMuonParticleProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) -{ -} -*/ +// method called once each job just after ending the event loop +void L1TkMuonParticleProducer::endJob() {} // ------------ method fills 'descriptions' with the allowed parameters for the module ------------ void @@ -347,8 +292,7 @@ L1TkMuonParticleProducer::fillDescriptions(edm::ConfigurationDescriptions& descr descriptions.addDefault(desc); } + //define this as a plug-in DEFINE_FWK_MODULE(L1TkMuonParticleProducer); - - diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc.backup b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc.backup new file mode 100644 index 0000000000000..eaf692df19520 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc.backup @@ -0,0 +1,354 @@ +// -*- C++ -*- +// +// +// dummy producer for a L1TkMuonParticle +// This is just an interface, taking the muon objects created +// by PierLuigi's code, and putting them into a collection of +// L1TkMuonParticle. +// + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" + +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Utilities/interface/InputTag.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticleFwd.h" + +#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" + +#include "DataFormats/Math/interface/LorentzVector.h" + + +// for L1Tracks: +//#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" + +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +#include +#include "TMath.h" + + +using namespace l1extra ; + +// +// class declaration +// + +class L1TkMuonParticleProducer : public edm::EDProducer { + public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + explicit L1TkMuonParticleProducer(const edm::ParameterSet&); + ~L1TkMuonParticleProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + //virtual void beginRun(edm::Run&, edm::EventSetup const&); + //virtual void endRun(edm::Run&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // ----------member data --------------------------- + + //edm::InputTag L1PLInputTag; // inputTag for PierLuigi's objects + + edm::InputTag L1MuonsInputTag; + edm::InputTag L1TrackInputTag; + + float ETAMIN; + float ETAMAX; + float ZMAX; // |z_track| < ZMAX in cm + float CHI2MAX; + float PTMINTRA; + float DRmax; + + int nStubsmin ; // minimum number of stubs + + bool closest ; + + +} ; + + +// +// constructors and destructor +// +L1TkMuonParticleProducer::L1TkMuonParticleProducer(const edm::ParameterSet& iConfig) +{ + + //L1PLInputTag = iConfig.getParameter("L1PLInputTag"); + + L1MuonsInputTag = iConfig.getParameter("L1MuonsInputTag"); + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + + ETAMIN = (float)iConfig.getParameter("ETAMIN"); + ETAMAX = (float)iConfig.getParameter("ETAMAX"); + ZMAX = (float)iConfig.getParameter("ZMAX"); + CHI2MAX = (float)iConfig.getParameter("CHI2MAX"); + PTMINTRA = (float)iConfig.getParameter("PTMINTRA"); + DRmax = (float)iConfig.getParameter("DRmax"); + nStubsmin = iConfig.getParameter("nStubsmin"); + closest = iConfig.getParameter("closest"); + + produces(); +} + +L1TkMuonParticleProducer::~L1TkMuonParticleProducer() { +} + +// ------------ method called to produce the data ------------ +void +L1TkMuonParticleProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + using namespace std; + + + std::auto_ptr result(new L1TkMuonParticleCollection); + + // dummy code. I loop over the L1Muons and pick up the L1Track that is closest + // in DeltaR. + + edm::Handle< vector > MuonHandle; + iEvent.getByLabel(L1MuonsInputTag,MuonHandle); + vector::const_iterator l1MuIter; + + edm::Handle L1TkTrackHandle; + iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); + L1TkTrackCollectionType::const_iterator trackIter; + + + int imu = 0; + for (l1MuIter = MuonHandle->begin(); l1MuIter != MuonHandle->end(); ++l1MuIter) { + + edm::Ref< L1MuonParticleCollection > MuRef( MuonHandle, imu ); + imu ++; + + float drmin = 999; + float ptmax = -1; + if (ptmax < 0) ptmax = -1; // dummy + + float eta = l1MuIter -> eta(); + float phi = l1MuIter -> phi(); + + float feta = fabs( eta ); + if (feta < ETAMIN) continue; + if (feta > ETAMAX) continue; + + L1MuGMTExtendedCand cand = l1MuIter -> gmtMuonCand(); + unsigned int quality = cand.quality(); + int bx = l1MuIter -> bx() ; + if (bx != 0 ) continue; + if (quality < 3) continue; + + // match the L1Muons with L1Tracks + + int itr = -1; + int itrack = -1; + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { + itr ++ ; + float Pt = trackIter->getMomentum().perp(); + float z = trackIter->getPOCA().z(); + if (fabs(z) > ZMAX) continue; + if (Pt < PTMINTRA) continue; + float chi2 = trackIter->getChi2(); + if (chi2 > CHI2MAX) continue; + + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubs = trackIter -> getStubRefs() ; + int tmp_trk_nstub = (int) theStubs.size(); + if ( tmp_trk_nstub < nStubsmin) continue; + + float Eta = trackIter->getMomentum().eta(); + float Phi = trackIter->getMomentum().phi(); + float deta = eta - Eta; + float dphi = phi - Phi; + if (dphi < 0) dphi = dphi + 2.*TMath::Pi(); + if (dphi > TMath::Pi()) dphi = 2.*TMath::Pi() - dphi; + float dR = sqrt( deta*deta + dphi*dphi ); + + if (closest) { + // take the closest track: + if (dR < drmin) { + drmin = dR; + itrack = itr; + } + } + else { + // or take the leading track within a cone + if (dR < DRmax) { + if (Pt > ptmax) { + ptmax = Pt; + itrack = itr; + drmin = dR; + } + } + } + + } // end loop over the tracks + + if (drmin < DRmax ) { // found a L1Track matched to the L1Muon object + + edm::Ptr< L1TkTrackType > L1TrackPtr( L1TkTrackHandle, itrack) ; + + float px = L1TrackPtr -> getMomentum().x(); + float py = L1TrackPtr -> getMomentum().y(); + float pz = L1TrackPtr -> getMomentum().z(); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector TrackP4(px,py,pz,e); + + float trkisol = -999; // dummy + + L1TkMuonParticle trkMu( TrackP4, + MuRef, + L1TrackPtr, + trkisol ); + + //trkMu.setDeltaR ( drmin ) ; + + result -> push_back( trkMu ); + + + } // endif drmin < DRmax + + + } // end loop over the L1Muons + + // PL: the muon objects from PierLuigi +/* + edm::Handle XXXHandle; + iEvent.getByLabel(L1PLInputTag,XXXHandle); + std::vector::const_iterator muIter ; + + if (!XXXHandle.isValid() ) { + LogError("L1TkMuonParticleProducer") + << "\nWarning: L1XXXCollectionType with " << L1PLInputTag + << "\nrequested in configuration, but not found in the event. Exit." + << std::endl; + return; + } + + // Now loop over the muons of Pierluigi + + int imu = 0; + for (muIter = XXXHandle->begin(); muIter != XXXHandle->end(); ++muIter) { + + edm::Ref< XXXCollection > muRef( XXXHandle, imu ); + imu ++; + + // int bx = egIter -> bx() ; // if PL's objects have a bx method + int bx = 0; // else... + + if (bx == 0) { + + edm::Ptr< L1TkTrackType > L1TrackPtr ; + + // PL : get the matched L1Track from PL's object + // L1TrackPtr = muRef -> getRefToTheL1Track() ; + + float px = L1TrackPtr -> getMomentum().x(); + float py = L1TrackPtr -> getMomentum().y(); + float pz = L1TrackPtr -> getMomentum().z(); + float e = sqrt( px*px + py*py + pz*pz ); // massless particle + math::XYZTLorentzVector TrackP4(px,py,pz,e); + + // the code may calculate a tracker-based isolation variable, + // or pick it up from PL's object if it is there. + // for the while, dummy. + float trkisol = -999; + + + L1TkMuonParticle trkMu( P4, + // muRef, + L1TrackPtr, + trkisol ); + + } // endif bx==0 + + } // end loop over Pierluigi's objects +*/ + + iEvent.put( result ); + +} + +// -------------------------------------------------------------------------------------- + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TkMuonParticleProducer::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TkMuonParticleProducer::endJob() { +} + +// ------------ method called when starting to processes a run ------------ +/* +void +L1TkMuonParticleProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) +{ +} +*/ + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1TkMuonParticleProducer::endRun(edm::Run&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1TkMuonParticleProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1TkMuonParticleProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TkMuonParticleProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TkMuonParticleProducer); + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py new file mode 100644 index 0000000000000..e0ab617cc4608 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py @@ -0,0 +1,161 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(20) ) + +# +# This runs over a file that already contains the L1Tracks. +# +# +# It also runs a trivial analyzer than prints the objects +# that have been created. + + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + # single muons + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_53.root' + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Muons/PU140/m1_SingleMuon_E2023TTI_PU140.root' + ) +) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +#process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') +#process.GlobalTag = GlobalTag(process.GlobalTag, 'POSTLS261_V3::All', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') + + + + +# --------------------------------------------------------------------------- +# +# --- Produces the L1EG objects +# + # To produce L1EG objects corresponding to the "stage-2" algorithms: + # one runs the SLHCCaloTrigger sequence. This produces both the + # "old stage-2" objects (2x2 clustering) and the "new stage-2" + # objects (new clustering from JB Sauvan et al). Note that the + # efficiency of the latter is currently poor at very high PU. + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') + +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') + + +#process.load('Configuration/StandardSequences/L1HwVal_cff') +#process.load('Configuration.StandardSequences.RawToDigi_cff') +#process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +#process.load('Configuration.StandardSequences.L1Reco_cff') +#process.L1Reco = cms.Path( process.l1extraParticles ) + +# +# --------------------------------------------------------------------------- + + +################################################################################################# +# now, all the DT related stuff +################################################################################################# +# to produce, in case, collection of L1MuDTTrack objects: +#process.dttfDigis = cms.Path(process.simDttfDigis) + +# the DT geometry +process.load("Geometry.DTGeometry.dtGeometry_cfi") +process.load("Geometry.MuonNumbering.muonNumberingInitialization_cfi") +process.load("SimMuon/DTDigitizer/muonDTDigis_cfi") +##process.load("L1TriggerConfig.DTTPGConfigProducers.L1DTTPGConfig_cff") + +################################################################################################# +# define the producer of DT + TK objects +################################################################################################# +process.load("L1Trigger.DTPlusTrackTrigger.DTPlusTrackProducer_cfi") +process.DTPlusTk_step = cms.Path(process.DTPlusTrackProducer) + + + + + + +# --------------------------------------------------------------------------- + +# Now we produce L1TkEmParticles and L1TkElectrons + +process.L1TkMuons = cms.EDProducer("L1TkMuonParticleProducer" +) + +process.pMuons = cms.Path( process.L1TkMuons ) + +# --------------------------------------------------------------------------- + + +# Run a trivial analyzer that prints the objects + +process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , + L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here + L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here + L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), + L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), + L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here +) + +#process.pAna = cms.Path( process.ana ) + + + +# --------------------------------------------------------------------------- + +# --- Output module : + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + +process.Out.outputCommands.append('keep *_L1TkMuons_*_*') +#process.Out.outputCommands.append('keep *_DTPlusTrackProducer_*_*') + + # raw data +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + + + # gen-level information +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') + + + # the L1Tracks, clusters and stubs +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + +# --- to use the genParticles, one needs to keep the collections of associators below: +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + diff --git a/SimDataFormats/SLHC/doc/html/index.html b/SimDataFormats/SLHC/doc/html/index.html deleted file mode 100644 index 133483673c9e7..0000000000000 --- a/SimDataFormats/SLHC/doc/html/index.html +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - -This Text Inserted from File doc/html/index.html - - - diff --git a/SimDataFormats/SLHC/doc/html/overview.html b/SimDataFormats/SLHC/doc/html/overview.html deleted file mode 100644 index 3336bef2e166a..0000000000000 --- a/SimDataFormats/SLHC/doc/html/overview.html +++ /dev/null @@ -1,13 +0,0 @@ - - - -This Text Inserted from File doc/html/overview.html - - - - - -
Status : -Unknown -
- diff --git a/SimDataFormats/SLHC/interface/EtaPhiContainer.h b/SimDataFormats/SLHC/interface/EtaPhiContainer.h deleted file mode 100644 index 4dedb2b0b3c3a..0000000000000 --- a/SimDataFormats/SLHC/interface/EtaPhiContainer.h +++ /dev/null @@ -1,177 +0,0 @@ -#ifndef EtaPhiContainer_h -#define EtaPhiContainer_h - -#include -#include -#include - -#include "DataFormats/Common/interface/RefTraits.h" - - - - -template < typename T > class EtaPhiContainer -{ - friend std::ostream& operator<< ( std::ostream& aStream , const EtaPhiContainer& aContainer ){ - int i(0); - for( typename EtaPhiContainer::const_iterator lIt=aContainer.begin() ; lIt!=aContainer.end() ; ++lIt ){ - aStream << "Element " << (i++) << " :\n" << *lIt << "\n"; - } - return aStream; - } - - - public: - typedef typename std::vector < T >::iterator iterator; - typedef typename std::vector < T >::const_iterator const_iterator; - - typedef T value_type; - - public: - EtaPhiContainer( ): - mHash( std::vector < uint16_t > ( 16384, uint16_t( -1 ) ) ) - { - mContainer.reserve( 16384 ); - } - - - EtaPhiContainer( const EtaPhiContainer < T > &aEtaPhiContainer ): - mContainer( aEtaPhiContainer.mContainer ), - mHash( aEtaPhiContainer.mHash ) - { - mContainer.reserve( 16384 ); - } - - - virtual ~ EtaPhiContainer( ) - { - } - - T & at( const std::size_t & aIndex ) - { - return mContainer.at( aIndex ); - } - - const T & at( const std::size_t & aIndex ) const - { - return mContainer.at( aIndex ); - } - - - iterator find( const int &aEta, const int &aPhi ) - { - uint16_t lIndex = mHash.at( hash( aEta, aPhi ) ); - - if ( lIndex == uint16_t( -1 ) ){ - return mContainer.end( ); - } - return mContainer.begin( ) + lIndex; - } - - - const_iterator find( const int &aEta, const int &aPhi )const - { - uint16_t lIndex = mHash.at( hash( aEta, aPhi ) ); - - if ( lIndex == uint16_t( -1 ) ){ - return mContainer.end( ); - } - return mContainer.begin( ) + lIndex; - } - - -/* - std::vector< T >& operator->(){ return mContainer; } - std::vector< T >& operator*(){ return mContainer; } -*/ - - iterator begin( ) - { - return mContainer.begin( ); - } - - const_iterator begin( ) const - { - return mContainer.begin( ); - } - - iterator end( ) - { - return mContainer.end( ); - } - - const_iterator end( ) const - { - return mContainer.end( ); - } - - iterator insert( const int &aEta, const int &aPhi, const T & aT ) - { - mHash.at( hash( aEta, aPhi ) ) = mContainer.size( ); - mContainer.push_back( aT ); - return ( --mContainer.end( ) ); - } - - std::size_t size( )const - { - return mContainer.size( ); - } - - - void sort( ){ - std::multimap < T , uint16_t > lMap; - for( uint16_t lHash = 0 ; lHash != mHash.size( ) ; ++lHash ){ - uint16_t lIndex = mHash.at( lHash ); - if( lIndex != uint16_t( -1 ) ){ - lMap.insert ( std::make_pair( *(mContainer.begin( ) + lIndex) , lHash ) ); - mHash.at( lHash ) = uint16_t( -1 ); - } - } - - mContainer.clear(); - - for( typename std::multimap < T , uint16_t >::reverse_iterator lItr = lMap.rbegin(); lItr != lMap.rend(); ++lItr ){ - mHash.at( lItr->second ) = mContainer.size(); - mContainer.push_back( lItr->first ); - } - } - - - private: - inline uint16_t hash( const int &aEta, const int &aPhi )const - { - return uint16_t( ( ( aEta & 0x7f ) << 7 ) | ( aPhi & 0x7f ) ); - } - - - private: - std::vector < T > mContainer; - std::vector < uint16_t > mHash; -}; - - - - -template < typename T > class EtaPhiContainerLookUp:public std::binary_function < const EtaPhiContainer < T > &, int, const T *> -{ - public: - const T *operator( ) ( const EtaPhiContainer < T > &aContainer, int aIndex ) - { - return &aContainer.at( aIndex ); - } -}; - - -namespace edm -{ - namespace refhelper - { - template < typename T > class FindTrait < EtaPhiContainer < T >, T > - { - public: - typedef EtaPhiContainerLookUp < T > value; - }; - } -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloCluster.h b/SimDataFormats/SLHC/interface/L1CaloCluster.h deleted file mode 100644 index 78d9946daf682..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloCluster.h +++ /dev/null @@ -1,204 +0,0 @@ -#ifndef L1CaloCluster_h -#define L1CaloCluster_h - - -#include -/* This ClassDescribes the 2x2 cluster thing 0|1 - - The Cluster reference point is 0 (ieta,iphi)=0,0 2|3 - - M.Bachtis, S.Dasu University of Wisconsin-Madison */ - - -//S. Harper changes: -//WARNING: this class contains MANY SUPRISES -//okay this is a temporary solution as we need something to work right now (22/05) and it has been decided to rewrite this class new the near future for a better package -//it has been decided that e/gamma + taus will continue to share the same cluster class rather than having seperate classes -//however they have little incommon with each other than they are both calo objects -//interface changes -//1) need to store emEt and hadEt seperately -//2) need to store emIsolEt and hadIsolEt seperately (this may change but we study them seperately for now. Instead of repurposing the isolation variables, I just added them for now -//3) E is renamed Et() because thats what it is, it also takes an int telling you if its EmEt, HadEt or TotEt to return, this is really handy for the cluster producers and filtering and swapping between tau and e/gamma mode -//4) leadTowerE is always em+had because its a tau thing - - -#include "DataFormats/Math/interface/LorentzVector.h" -#include "SimDataFormats/SLHC/interface/L1CaloTower.h" -#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" - -namespace l1slhc -{ - - class L1CaloCluster - { - //SH: this operator does not have mIsoenergyeg or tau included for some reason, I have note updated it to have mIsoEmEtEG or mIsoHadEtEG either - friend bool operator==( const l1slhc::L1CaloCluster & a, const l1slhc::L1CaloCluster & b ) - { - if ( a.mIeta != b.mIeta ) - return false; - if ( a.mIphi != b.mIphi ) - return false; - if ( a.mFg != b.mFg ) - return false; - if ( a.mEgamma != b.mEgamma ) - return false; - if ( a.mLeadtowertau != b.mLeadtowertau ) - return false; - if ( a.mEgammavalue != b.mEgammavalue ) - return false; - if ( a.mInnereta != b.mInnereta ) - return false; - if ( a.mInnerphi != b.mInnerphi ) - return false; - if ( a.mIsoclusterseg != b.mIsoclusterseg ) - return false; - if ( a.mIsoclusterstau != b.mIsoclusterstau ) - return false; - if ( a.mIsoeg != b.mIsoeg ) - return false; - if ( a.mIsotau != b.mIsotau ) - return false; - if ( a.mCentral != b.mCentral ) - return false; - if ( a.mEmEt != b.mEmEt ) - return false; - if ( a.mHadEt != b.mHadEt ) - return false; - if ( a.mP4 != b.mP4 ) - return false; - return true; - } - - - public: - L1CaloCluster( ); - L1CaloCluster( const int &, const int & ); - ~L1CaloCluster( ); - - void setFg( const bool & ); // Set FG Bit - void setEGamma( const bool & ); // Set EGamma Bit - void setEGammaValue( const int & ); // Set EGamma Value E/E+H (%) - void setIsoClusters( const int &, const int & ); // Number of isolated objectsisolation Clusters - void setIsoEnergy( const int &, const int & ); // Energy of Isolation - void setIsoEmAndHadEtEG( const int &, const int & ); - void setIsoEG( const bool & ); // EG isolation - void setIsoTau( const bool & ); // Tau isolation - void setCentral( const bool & ); // Central Bit - void setLeadTower( const bool & ); // Lead Tower over threshold bit for taus - void setLorentzVector( const math::PtEtaPhiMLorentzVector & ); // Central Bit - void setPosBits( const int &, const int & ); - void setConstituents( const L1CaloTowerRefVector & ); - void setEmEt( const int & ); - void setHadEt( const int & ); - void setLeadTowerE( const int & ); - void setSecondTowerE( const int & ); - void setThirdTowerE( const int & ); - void setFourthTowerE( const int & ); - void setRing1E( const int & ); - void setRing2E( const int & ); - void setRing3E( const int & ); - void setRing4E( const int & ); - void addConstituent( const L1CaloTowerRef & ); - int hasConstituent( const int &, const int & )const; //SH change: should be const so adding const - void removeConstituent( const int &, const int & ); - - // Get Functions - const int &iEta( ) const; // Eta of origin in integer coordinates - const int &iPhi( ) const; // Phi of Origin in integer - const int Et(int mode=0x3) const; // Compressed Et SH: name change mode = bit 1 add EmEt, bit 2 add HadEt, I had to make this a non-reference variable as it returns the sum of mEmEt + mHadEt, leave as is for now - const int &EmEt()const; // SH: addition - const int &HadEt()const; // SH: addition - const int &LeadTowerE( ) const; // Lead Tower Et - const int &SecondTowerE( ) const; // Lead Tower Et - const int &ThirdTowerE( ) const; // Lead Tower Et - const int &FourthTowerE( ) const; // Lead Tower Et - const int &Ring1E( ) const; // Lead Tower Et - const int &Ring2E( ) const; // Lead Tower Et - const int &Ring3E( ) const; // Lead Tower Et - const int &Ring4E( ) const; // Lead Tower Et - const int &innerEta( ) const; // Weighted position eta - const int &innerPhi( ) const; // Weighted position phi - const L1CaloTowerRefVector & getConstituents( ) const; - L1CaloTowerRef getConstituent( const int & )const; //SH change: should be const so adding const - - - - - - // Electron Variables - const bool & fg( ) const; // Finegrain bit - const bool & eGamma( ) const; // Electron/Photon bit - const int &eGammaValue( ) const; // Electron/Photon bit - - // isolation Variables - const bool & isCentral( ) const; // Means that the cluster was not pruned during isolation - const bool & isoEG( ) const; // Egamma Isolatioon - const bool & isoTau( ) const; // Tau isolation - const int &isoClustersEG( ) const; // 2x2 isolation clusters for Egamma cuts - const int &isoClustersTau( ) const; // 2x2 isolation clusters for Tau Cut - const int &isoEnergyEG( ) const; // 2x2 isolation clusters for Egamma cuts - const int &isoEnergyTau( ) const; // 2x2 isolation clusters for Egamma cuts - const bool & hasLeadTower( ) const; - - const int &isoEmEtEG( ) const; - const int &isoHadEtEG( ) const; - - // Trigger Results - bool isEGamma( ) const; // Returns the EGAMMA decision - bool isIsoEGamma( ) const; // Returns the iso EGAMMA decision - bool isTau( ) const; // returns The Tau decison - bool isIsoTau( ) const; // returns The Tau decison - - const math::PtEtaPhiMLorentzVector & p4( ) const; // returns Physics wise LorentzVector in eta,phi continuous space - - - - private: - // Refs to teh caloTowwers - L1CaloTowerRefVector mConstituents; - - // Coordinates of the reference Point - int mIeta; - int mIphi; - int mEmEt; - int mHadEt; - int mLeadTowerE; //Lead Tower Energy - int mSecondTowerE; //Lead Tower Energy - int mThirdTowerE; //Lead Tower Energy - int mFourthTowerE; //Lead Tower Energy - int mRing1E; //Lead Tower Energy - int mRing2E; //Lead Tower Energy - int mRing3E; //Lead Tower Energy - int mRing4E; //Lead Tower Energy - // FineGrain / EGamma /Isolations - - bool mFg; - bool mEgamma; - bool mCentral; - bool mIsoeg; - bool mLeadtowertau; - bool mIsotau; - int mEgammavalue; - int mInnereta; - int mInnerphi; - int mIsoclusterseg; - int mIsoenergyeg; - int mIsoenergytau; - int mIsoclusterstau; - - math::PtEtaPhiMLorentzVector mP4; // Lorentz Vector of precise position - - int mIsoEmEtEG; // SH: addition - int mIsoHadEtEG; // SH: addition - - }; - -} - -// Sorting functor -namespace std{ - bool operator< ( const l1slhc::L1CaloCluster & aLeft, const l1slhc::L1CaloCluster & aRight ); -} - -std::ostream & operator<<( std::ostream & , const l1slhc::L1CaloCluster & ); - - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloClusterFwd.h b/SimDataFormats/SLHC/interface/L1CaloClusterFwd.h deleted file mode 100644 index 16b5162b7c908..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloClusterFwd.h +++ /dev/null @@ -1,21 +0,0 @@ -#ifndef L1CaloCluster_Fwd -#define L1CaloCluster_Fwd - - -#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" -#include "DataFormats/Common/interface/Ref.h" - -namespace l1slhc -{ - class L1CaloCluster; -} - -namespace l1slhc -{ - // typedef std::vector L1CaloClusterCollection; - typedef EtaPhiContainer < L1CaloCluster > L1CaloClusterCollection; - - typedef edm::Ref < L1CaloClusterCollection > L1CaloClusterRef; -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h b/SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h deleted file mode 100644 index 55c2e835869ef..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h +++ /dev/null @@ -1,148 +0,0 @@ -#ifndef L1CaloClusterWithSeed_h -#define L1CaloClusterWithSeed_h - - -#include - -#include "DataFormats/Math/interface/LorentzVector.h" -#include "SimDataFormats/SLHC/interface/L1CaloTower.h" -#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" - -namespace l1slhc -{ - - class L1CaloClusterWithSeed - { - - friend bool operator==( const l1slhc::L1CaloClusterWithSeed & a, const l1slhc::L1CaloClusterWithSeed & b ) - { - if ( a.mIeta != b.mIeta ) - return false; - if ( a.mIphi != b.mIphi ) - return false; - if ( a.mFg != b.mFg ) - return false; - if ( a.mEgamma != b.mEgamma ) - return false; - if ( a.mEgammavalue != b.mEgammavalue ) - return false; - if ( a.mIsoeg != b.mIsoeg ) - return false; - if ( a.mEmEt != b.mEmEt ) - return false; - if ( a.mHadEt != b.mHadEt ) - return false; - if ( a.mP4 != b.mP4 ) - return false; - return true; - } - - - public: - L1CaloClusterWithSeed( ); - L1CaloClusterWithSeed( const int &, const int & ); - L1CaloClusterWithSeed( const L1CaloTowerRef & seed, int seedThreshold=4, int emThreshold=2, int hadThreshold=2 ); - ~L1CaloClusterWithSeed( ); - - void setFg( bool ); // Set FG Bit - void setEGamma( bool ); // Set EGamma Bit - void setEGammaValue( int ); // Set EGamma Value E/E+H (%) - void setIsoEmAndHadEtEG( const int &, const int & ); - void setIsoEG( const bool & ); // EG isolation - void setLorentzVector( const math::PtEtaPhiMLorentzVector & ); - void setPosBits( int , int ); - void setConstituents( const L1CaloTowerRefVector & ); - void setEmEt( int ); - void setHadEt( int ); - void setTrimmedPlus( bool trimmed=true); - void setTrimmedMinus( bool trimmed=true); - void addConstituent( const L1CaloTowerRef & ); - int hasConstituent( int , int ) const; - void removeConstituent( int , int ); - void addFriend(const L1CaloTowerRef & ); - int hasFriend( int , int ); - void removeFriend( int , int ); - - // Get Functions - int iEta( ) const; // Eta of seed in integer coordinates - int iPhi( ) const; // Phi of seed in integer - int Et(int mode=0x3) const; // Compressed Et SH: name change mode = bit 1 add EmEt, bit 2 add HadEt, I had to make this a non-reference variable as it returns the sum of mEmEt + mHadEt, leave as is for now - int EmEt( ) const; // Compressed ECAL Et - int HadEt( ) const; // Compressed HCAL Et - bool trimmedPlus() const; - bool trimmedMinus() const; - int innerEta( ) const; // Weighted position eta - int innerPhi( ) const; // Weighted position phi - L1CaloTowerRef getSeedTower( ) const; - const L1CaloTowerRefVector & getConstituents( ) const; - L1CaloTowerRef getConstituent( int ); - int seedEmEt() const; - int seedHadEt() const; - int constituentEmEt(int , int ) const; - int constituentHadEt(int , int ) const; - void shareConstituent(int, int, int); - L1CaloTowerRef getFriend( int ); - - - - - - // Electron Variables - bool fg( ) const; // Finegrain bit - bool eGamma( ) const; // Electron/Photon bit - int eGammaValue( ) const; // Electron/Photon bit - const bool & isoEG( ) const; // Egamma Isolatioon - - // Trigger Results - bool isEGamma( ) const; // Returns the EGAMMA decision - bool isIsoEGamma( ) const; // Returns the iso EGAMMA decision - const int &isoEmEtEG( ) const; - const int &isoHadEtEG( ) const; - - const math::PtEtaPhiMLorentzVector & p4( ) const; // returns Physics wise LorentzVector in eta,phi continuous space - - - - private: - // Refs to the caloTowwers - L1CaloTowerRef mSeedTower; - L1CaloTowerRefVector mConstituents; - std::vector mConstituentSharing; - L1CaloTowerRefVector mFriends; - - int mSeedThreshold; - int mEmThreshold; - int mHadThreshold;// for H/E calculation - - // Coordinates of the reference Point - int mIeta; - int mIphi; - int mEmEt; - int mHadEt; - - bool mTrimmedPlus; - bool mTrimmedMinus; - bool mFg; - bool mEgamma; - int mEgammavalue; - bool mIsoeg; - int mIsoEmEtEG; // SH: addition - int mIsoHadEtEG; // SH: addition - int mInnereta; - int mInnerphi; - - math::PtEtaPhiMLorentzVector mP4; // Lorentz Vector of precise position - - }; - -} - -// Sorting functor -namespace std{ - bool operator< ( const l1slhc::L1CaloClusterWithSeed & aLeft, const l1slhc::L1CaloClusterWithSeed & aRight ); -} - -std::ostream & operator<<( std::ostream & , const l1slhc::L1CaloClusterWithSeed & ); - - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h b/SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h deleted file mode 100644 index 7fd19160ddaa0..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h +++ /dev/null @@ -1,21 +0,0 @@ -#ifndef L1CaloClusterWithSeed_Fwd -#define L1CaloClusterWithSeed_Fwd - - -#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" -#include "DataFormats/Common/interface/Ref.h" - -namespace l1slhc -{ - class L1CaloClusterWithSeed; -} - -namespace l1slhc -{ - // typedef std::vector L1CaloClusterWithSeedCollection; - typedef EtaPhiContainer < L1CaloClusterWithSeed > L1CaloClusterWithSeedCollection; - - typedef edm::Ref < L1CaloClusterWithSeedCollection > L1CaloClusterWithSeedRef; -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloJet.h b/SimDataFormats/SLHC/interface/L1CaloJet.h deleted file mode 100644 index d24c7b6b3fbc9..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloJet.h +++ /dev/null @@ -1,67 +0,0 @@ -#ifndef L1CaloJet_h -#define L1CaloJet_h - -/* - This class describves the L1 Reconstructed jet M.Bachtis,S.Dasu University of Wisconsin - Madison */ - -#include "DataFormats/Math/interface/LorentzVector.h" -#include -#include "SimDataFormats/SLHC/interface/L1CaloRegionFwd.h" -#include "SimDataFormats/SLHC/interface/L1CaloRegion.h" - -namespace l1slhc -{ - - class L1CaloJet - { - - public: - - L1CaloJet( ); - L1CaloJet( const int&, const int& ); - ~L1CaloJet( ); - - // getters - const int& iEta( ) const; - const int& iPhi( ) const; - const int& E( ) const; - const bool& central( ) const; - const math::PtEtaPhiMLorentzVector& p4( ) const; // returns LorentzVector in eta,phi space - - // Setters - void setP4( const math::PtEtaPhiMLorentzVector & ); - void setCentral( const bool& ); - void setE( const int& ); - - void addConstituent( const L1CaloRegionRef & ); - int hasConstituent( const int&, const int& ); - void removeConstituent( const int&, const int& ); - - const L1CaloRegionRefVector& getConstituents( ) const; - - - - private: - int mIeta; - int mIphi; - int mE; - bool mCentral; - - L1CaloRegionRefVector mConstituents; - math::PtEtaPhiMLorentzVector mP4; - - }; - - -} - - -// Sorting functor -namespace std{ - bool operator< ( const l1slhc::L1CaloJet & aLeft, const l1slhc::L1CaloJet & aRight ); -} - - -std::ostream & operator<<( std::ostream & , const l1slhc::L1CaloJet & ); - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloJetFwd.h b/SimDataFormats/SLHC/interface/L1CaloJetFwd.h deleted file mode 100644 index 95e331b3f4318..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloJetFwd.h +++ /dev/null @@ -1,22 +0,0 @@ -#ifndef L1CaloJet_Fwd -#define L1CaloJet_Fwd - - -#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" -#include "DataFormats/Common/interface/Ref.h" -#include - -namespace l1slhc -{ - class L1CaloJet; -} - -namespace l1slhc -{ - // typedef std::vector L1CaloJetCollection; - typedef EtaPhiContainer < L1CaloJet > L1CaloJetCollection; - - typedef edm::Ref < L1CaloJetCollection > L1CaloJetRef; -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloRegion.h b/SimDataFormats/SLHC/interface/L1CaloRegion.h deleted file mode 100644 index 0b555c4b89b5a..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloRegion.h +++ /dev/null @@ -1,40 +0,0 @@ -#ifndef L1CaloRegion_h -#define L1CaloRegion_h - -/* This ClassDescribes the 4x4 region - - M.Bachtis, S.Dasu University of Wisconsin-Madison */ - -namespace l1slhc -{ - - class L1CaloRegion - { - public: - L1CaloRegion( ); - L1CaloRegion( const int&, const int&, const int& ); - ~L1CaloRegion( ); - - // Get Functions - const int& iEta( ) const; // Eta of origin in integer coordinates - const int& iPhi( ) const; // Phi of Origin in integer - const int& E( ) const; // Compressed Et - - - - private: - int mIeta; - int mIphi; - int mE; - - }; - -} - - -// Sorting functor -namespace std{ - bool operator<( const l1slhc::L1CaloRegion & aLeft, const l1slhc::L1CaloRegion & aRight ); -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloRegionFwd.h b/SimDataFormats/SLHC/interface/L1CaloRegionFwd.h deleted file mode 100644 index 44bcfe8e68941..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloRegionFwd.h +++ /dev/null @@ -1,25 +0,0 @@ -#ifndef L1CaloRegion_Fwd -#define L1CaloRegion_Fwd - -#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" -#include "DataFormats/Common/interface/Ref.h" -#include - - -namespace l1slhc -{ - class L1CaloRegion; -} - -namespace l1slhc -{ - // typedef std::vector L1CaloRegionCollection; - typedef EtaPhiContainer < L1CaloRegion > L1CaloRegionCollection; - - - typedef edm::Ref < L1CaloRegionCollection > L1CaloRegionRef; - typedef std::vector < L1CaloRegionRef > L1CaloRegionRefVector; -} - - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTower.h b/SimDataFormats/SLHC/interface/L1CaloTower.h deleted file mode 100644 index 4b7038101befb..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloTower.h +++ /dev/null @@ -1,60 +0,0 @@ -/* L1CaloTower class Keeps both ECAL/HCAL Tower information . Used as input for Clustering - - M.Bachtis,S.Dasu University of Wisconsin-Madison - - Modified Andrew W. Rose Imperial College, London */ - - -#ifndef L1CaloTower_h -#define L1CaloTower_h - -#include - - -namespace l1slhc -{ - - class L1CaloTower - { - - public: - - L1CaloTower( ); - L1CaloTower( const int &, const int & ); // Set Tower position (iEta,iPhi) - ~L1CaloTower( ); - - - // Setters - void setPos( const int &, const int & ); // Set Tower position (iEta,iPhi) - // void setParams( const int& , const int& , const bool& ); //Set ECAL,HCAL Energy and finegrain - - void setEcal( const int &, const bool & ); - void setHcal( const int &, const bool & ); - - // getters - const int &E( ) const; - const int &H( ) const; - const int &iEta( ) const; - const int &iPhi( ) const; - const bool & EcalFG( ) const; - const bool & HcalFG( ) const; - - private: - int mEcal; - int mHcal; - int mIeta; - int mIphi; - bool mEcalFG; - bool mHcalFG; - - - }; - -} - -// Sorting functor -namespace std{ - bool operator< ( const l1slhc::L1CaloTower & aLeft, const l1slhc::L1CaloTower & aRight ); -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTowerFwd.h b/SimDataFormats/SLHC/interface/L1CaloTowerFwd.h deleted file mode 100644 index 2cac83f6c87d2..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloTowerFwd.h +++ /dev/null @@ -1,26 +0,0 @@ -#ifndef L1CaloTower_Fwd -#define L1CaloTower_Fwd - -#include "DataFormats/Common/interface/Ref.h" -#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" -#include "SimDataFormats/SLHC/interface/L1CaloTower.h" - -#include - -/* - namespace l1slhc { class L1CaloTower; } */ - - -namespace l1slhc -{ - - - // typedef std::vector L1CaloTowerCollection; - typedef EtaPhiContainer < L1CaloTower > L1CaloTowerCollection; - - typedef edm::Ref < L1CaloTowerCollection > L1CaloTowerRef; - - typedef std::vector < L1CaloTowerRef > L1CaloTowerRefVector; -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h b/SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h deleted file mode 100644 index 26f5121d439c9..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h +++ /dev/null @@ -1,291 +0,0 @@ -/* SLHC Calo Trigger Class for Trigger configuration...Contains wiring and Cuts M.Bachtis,S.Dasu. University of Wisconsin-Madison */ - - -#ifndef L1CaloTriggerSetup_h -#define L1CaloTriggerSetup_h - -#include -#include -#include - - -class L1CaloTriggerSetup -{ - private: - int mLatticedim; // Eta Dimension of the square lattice - int mLatticeeta0; // Eta of the Square Lattice - int mLatticephi0; // Phi of the Square Lattice - int mLatticeetam; // Eta of the Square Lattice - int mLatticephim; // Phi of the Square Lattice - int mEcalactivitycut; // Ecal Activity Cut - int mHcalactivitycut; // hcalActivity Cut -/* - int mElectroncuta; //Electron ID Cut - int mElectroncutb; //Electron ID Cut - int mElectroncutc; //Electron ID Cut -*/ - std::vector < int > mElectroncut; - int mTauseedtower; // Electron ID Cut - int mClustercut; // Cluster Threshold Cut - -/* - int mIsolationea; //Isolation ratio Electron; - int mIsolationeb; //Isolation ratio Electron; -*/ - std::vector < int > mIsolatione; -/* - int mIsolationta;//Isolation ratio Tau; - int mIsolationtb;//Isolation ratio Tau; -*/ - std::vector < int > mIsolationt; -/* - int mIsolationthreg; //Isolation threshold EG; - int mIsolationthrtau;//Isolation threshold Tau; -*/ - std::vector < int > mIsothr; - int mIsolationzone; // Number of towers that define the isolation zone; - // int mJetcenter ; //jet Center Deviation - int mJetet; // jet Center Deviation - int mFinegrainpass; // ignore fine grain bit (set it to 0) - - // Geometry Mapping between towers/lattice - std::map < int, std::pair < int, int > > mGeomap; - - - public: - - const std::pair < int, int > &getTowerEtaPhi( const int &bin ) const - { - return mGeomap.find( bin )->second; - } - - - // Lattice Navigation helper Functions - int getEta( const int &bin ) const // get the ieta of a specific Bin - { - return bin % mLatticedim; - - } - int getPhi( const int &bin ) const // get the iphi of a specific bin - { - return bin / mLatticedim; - } - - int getBin( const int &eta, const int &phi ) const // get the bin for a ieta,iphi pair - { - return phi * mLatticedim + eta; - } - - - - const int &etaMin( ) const - { - return mLatticeeta0; - } - - const int &etaMax( ) const - { - return mLatticeetam; - } - - const int &phiMin( ) const - { - return mLatticephi0; - } - - const int &phiMax( ) const - { - return mLatticephim; - } - - - const int &ecalActivityThr( ) const - { - return mEcalactivitycut; - } - - const int &hcalActivityThr( ) const - { - return mHcalactivitycut; - } - - const int &clusterThr( ) const - { - return mClustercut; - } - - const int &seedTowerThr( ) const - { - return mTauseedtower; - } - - - - - const int &nIsoTowers( ) const - { - return mIsolationzone; - } - -/* - const int& jetCenterDev() - { - return mJetcenter; - } -*/ - - const int &minJetET( ) const - { - return mJetet; - } - - const int &fineGrainPass( ) const - { - return mFinegrainpass; - } - - - - - -/* - std::vector electronThr() - { - std::vector a; - a.push_back(mElectroncuta); - a.push_back(mElectroncutb); - a.push_back(mElectroncutc); - return a; - } -*/ - const int &electronThr( const int &aIndex ) const - { - return mElectroncut.at( aIndex ); - } - - -/* - std::vector isoThr() - { - std::vector a; - a.push_back(mIsolationthreg); - a.push_back(mIsolationthrtau); - return a; - } - - std::vector isolationE() { - std::vector a; - a.push_back(mIsolationea); - a.push_back(mIsolationeb); - return a; - } - - std::vector isolationT() { - std::vector a; - a.push_back(mIsolationta); - a.push_back(mIsolationtb); - return a; - } -*/ - - const int &isoThr( const int &aIndex ) const - { - return mIsothr.at( aIndex ); - } - - const int &isolationE( const int &aIndex ) const - { - return mIsolatione.at( aIndex ); - } - - const int &isolationT( const int &aIndex ) const - { - return mIsolationt.at( aIndex ); - } - - - - L1CaloTriggerSetup( ): - mLatticedim( 1 ), - mLatticeeta0( 1 ), - mLatticephi0( 1 ), - mLatticeetam( -1000 ), - mLatticephim( -1111 ), - mEcalactivitycut( 2 ), - mHcalactivitycut( 6 ), -/* mElectroncuta(8), - mElectroncutb(0), - mElectroncutc(0), */ - mElectroncut( std::vector < int >( 3, 0 ) ), - mTauseedtower( 0 ), - mClustercut( 4 ), - mIsolatione( std::vector < int >( 2, 0 ) ), - mIsolationt( std::vector < int >( 2, 0 ) ), - mIsothr( std::vector < int >( 2, 0 ) ) - { - mElectroncut.at( 0 ) = 8; - } - - ~L1CaloTriggerSetup( ) - { - } - - void setGeometry( const int &eta0, const int &phi0, const int &etam, const int &phim, const int &dim ) - { - mLatticedim = dim; - mLatticeeta0 = eta0; - mLatticephi0 = phi0; - mLatticeetam = etam; - mLatticephim = phim; - } - - void addWire( const int &no, const int &eta, const int &phi ) // Configure Wire Connection - { - mGeomap[no] = std::make_pair( eta, phi ); - } - - - void setThresholds( const int &ecal_a_c, const int &hcal_a_c, const int &egammaA, const int &egammaB, const int &egammaC, const int &tauSeed, const int &clusterCut, const int &isoRatioEA, - const int &isoRatioEB, const int &isoRatioTA, const int &isoRatioTB, const int &isoZone, const int &isoThresEG, const int &isoThresTau, const int &jetet, const int &fgp ) - { - - mEcalactivitycut = ecal_a_c; - mHcalactivitycut = hcal_a_c; -/* - mElectroncuta = egammaA; - mElectroncutb = egammaB; - mElectroncutc = egammaC; -*/ - mElectroncut.at( 0 ) = egammaA; - mElectroncut.at( 1 ) = egammaB; - mElectroncut.at( 2 ) = egammaC; - mTauseedtower = tauSeed; - mClustercut = clusterCut; -/* - mIsolationea = isoRatioEA; - mIsolationeb = isoRatioEB; -*/ - mIsolatione.at( 0 ) = isoRatioEA; - mIsolatione.at( 1 ) = isoRatioEB; -/* - mIsolationta = isoRatioTA; - mIsolationtb = isoRatioTB; -*/ - mIsolationt.at( 0 ) = isoRatioTA; - mIsolationt.at( 1 ) = isoRatioTB; - mIsolationzone = isoZone; -/* - mIsolationthreg = isoThresEG; - mIsolationthrtau = isoThresTau; -*/ - mIsothr.at( 0 ) = isoThresEG; - mIsothr.at( 1 ) = isoThresTau; - // mJetcenter = jetc; - mJetet = jetet; - mFinegrainpass = fgp; - } - - -}; - -#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h b/SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h deleted file mode 100644 index 76756fcbe14bc..0000000000000 --- a/SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h +++ /dev/null @@ -1,11 +0,0 @@ -/* SLHC Calo Trigger Record defining the SLHC CaloTrigger Config parameters M.Bachtis,S.Dasu. University of Wisconsin-Madison */ - - -#ifndef L1CaloTriggerSetupRcd_h -#define L1CaloTriggerSetupRcd_h - -#include "FWCore/Framework/interface/EventSetupRecordImplementation.h" -class L1CaloTriggerSetupRcd:public edm::eventsetup::EventSetupRecordImplementation < L1CaloTriggerSetupRcd > -{ -}; -#endif diff --git a/SimDataFormats/SLHC/interface/L1TBarrel.hh b/SimDataFormats/SLHC/interface/L1TBarrel.hh deleted file mode 100644 index 372772ab964cc..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TBarrel.hh +++ /dev/null @@ -1,457 +0,0 @@ -#ifndef L1TBARREL_H -#define L1TBARREL_H - -#include -#include -#include -#include -#include -using namespace std; - -#include "L1TStub.hh" -#include "L1TTracklet.hh" -#include "L1TTrack.hh" -#include "L1TTracks.hh" -#include "L1TGeomBase.hh" -#include "L1TDisk.hh" - -class L1TBarrel:public L1TGeomBase { - -private: - L1TBarrel(){ - } - - -public: - - L1TBarrel(double rmin,double rmax,double zmax, int NSector){ - rmin_=rmin; - rmax_=rmax; - zmax_=zmax; - NSector_=NSector; - stubs_.resize(NSector); - tracklets_.resize(NSector); - tracks_.resize(NSector); - } - - bool addStub(const L1TStub& aStub){ - if (aStub.r()rmax_||fabs(aStub.z())>zmax_) return false; - double phi=aStub.phi(); - if (phi<0) phi+=two_pi; - int nSector=NSector_*phi/two_pi; - assert(nSector>=0); - assert(nSector=NSector_) jSector-=NSector_; - for (unsigned int i=0;istubs_[jSector].size();j++) { - double r2=L->stubs_[jSector][j].r(); - double z2=L->stubs_[jSector][j].z(); - - double zcrude=z1-(z2-z1)*r1/(r2-r1); - if (fabs(zcrude)>30) continue; - - double phi2=L->stubs_[jSector][j].phi(); - - double deltaphi=phi1-phi2; - - if (deltaphi>0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.5*two_pi); - - - double dist=sqrt(r2*r2+r1*r1-2*r1*r2*cos(deltaphi)); - - double rinv=2*sin(deltaphi)/dist; - - if (fabs(rinv)>0.0057) continue; - - double phi0=phi1+asin(0.5*r1*rinv); - - if (phi0>0.5*two_pi) phi0-=two_pi; - if (phi0<-0.5*two_pi) phi0+=two_pi; - assert(fabs(phi0)<0.5*two_pi); - - double rhopsi1=2*asin(0.5*r1*rinv)/rinv; - - double rhopsi2=2*asin(0.5*r2*rinv)/rinv; - - double t=(z1-z2)/(rhopsi1-rhopsi2); - - double z0=z1-t*rhopsi1; - - if (stubs_[iSector][i].sigmaz()>1.0) { - if (fabs(z1-z2)<10.0){ - z0=0.0; - t=z1/rhopsi1; - } - } - - if (fabs(z0)>15.0) continue; - double pt1=stubs_[iSector][i].pt(); - double pt2=L->stubs_[jSector][j].pt(); - double pttracklet=0.3*3.8/(rinv*100); - bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; - bool pass2=fabs(1.0/pt2-1.0/pttracklet)<0.5; - bool pass=pass1&&pass2; - - if (0) { - static ofstream out("ptmatch.txt"); - out << pt1<<" " - << pt2<<" " - << pttracklet<<" " - << pass - << endl; - } - - if (!pass) continue; - - L1TTracklet tracklet(rinv,phi0,t,z0); - tracklet.addStub(stubs_[iSector][i]); - tracklet.addStub(L->stubs_[jSector][j]); - - tracklets_[iSector].push_back(tracklet); - - if (0) { - static ofstream out("barreltracklets.txt"); - out << iSector<<" "<=NSector_) jSector-=NSector_; - for (unsigned int i=0;istubs_[jSector].size();j++) { - - double r2=D->stubs_[jSector][j].r(); - double z2=D->stubs_[jSector][j].z(); - double zcrude=z1-(z2-z1)*r1/(r2-r1); - if (fabs(zcrude)>30) continue; - - - double phi2=D->stubs_[jSector][j].phi(); - - if (r2>rmax) continue; - - if (r2>80.0) continue; - - double deltaphi=phi1-phi2; - - if (deltaphi>0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.5*two_pi); - - - double dist=sqrt(r2*r2+r1*r1-2*r1*r2*cos(deltaphi)); - - double rinv=2*sin(deltaphi)/dist; - - if (fabs(rinv)>0.0057) continue; - - double phi0=phi1+asin(0.5*r1*rinv); - - if (phi0>0.5*two_pi) phi0-=two_pi; - if (phi0<-0.5*two_pi) phi0+=two_pi; - if (!(fabs(phi0)<0.5*two_pi)) { - cout << "phi0 phi1 r1 rinv : "<1.0) { - if (fabs(z1-z2)<10.0){ - z0=0.0; - t=z1/rhopsi1; - } - } - - if (fabs(z0)>15.0) continue; - - - double pt1=stubs_[iSector][i].pt(); - double pt2=D->stubs_[jSector][j].pt(); - double pttracklet=0.3*3.8/(rinv*100); - bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; - bool pass2=fabs(1.0/pt2-1.0/pttracklet)<0.5; - bool pass=pass1&&pass2; - if (!pass) continue; - - L1TTracklet tracklet(rinv,phi0,t,z0); - tracklet.addStub(stubs_[iSector][i]); - tracklet.addStub(D->stubs_[jSector][j]); - - tracklets_[iSector].push_back(tracklet); - - //cout << "rinv phi0 t z0:"<< - // rinv<<" "<=NSector_) jSector-=NSector_; - if (L->stubs_[jSector].size()==0) continue; - - - double rapprox=L->stubs_[jSector][0].r(); - - double phiprojapprox=phi0-asin(0.5*rapprox*rinv); - double zprojapprox=z0+2*t*asin(0.5*rapprox*rinv)/rinv; - if (phiprojapprox-L->stubs_[jSector][0].phi()<-0.5*two_pi) phiprojapprox+=two_pi; - if (phiprojapprox-L->stubs_[jSector][0].phi()>0.5*two_pi) phiprojapprox-=two_pi; - - for (unsigned int j=0;jstubs_[jSector].size();j++) { - double z=L->stubs_[jSector][j].z(); - if (fabs(z-zprojapprox)>10.0) continue; - double phi=L->stubs_[jSector][j].phi(); - double deltaphiapprox=fabs(phi-phiprojapprox); - assert(deltaphiapprox<12.0); - if (deltaphiapprox*rapprox>1.0) continue; - double r=L->stubs_[jSector][j].r(); - //cout << "r1 phi1 r2 phi2:" - // <stubs_[jSector][j].r()<<" " - // <stubs_[jSector][j].phi()<0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.5*two_pi); - - double rdeltaphi=r*deltaphi; - double deltaz=z-zproj; - - if (0) { - static ofstream out("barrelmatch.txt"); - out << aTracklet.r()<<" "<cutrphi*phiSF) continue; - if (fabs(deltaz)>cutrz) continue; - - /* - double pt1=L->stubs_[jSector][j].pt(); - double pttracklet=aTracklet.pt(3.8); - bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; - if (!pass1) continue; - */ - - double dist=hypot(rdeltaphi/cutrphi,deltaz/cutrz); - - if (diststubs_[jSector][j]; - distbest=dist; - } - - //cout << "rdeltaphi deltaz:"<=NSector_) jSector-=NSector_; - if (D->stubs_[jSector].size()==0) continue; - - double zapprox=D->stubs_[jSector][0].z(); - - double r_track_approx=2.0*sin(0.5*rinv*(zapprox-z0)/t)/rinv; - double phi_track_approx=phi0-0.5*rinv*(zapprox-z0)/t; - if (phi_track_approx-D->stubs_[jSector][0].phi()<-0.5*two_pi) phi_track_approx+=two_pi; - if (phi_track_approx-D->stubs_[jSector][0].phi()>0.5*two_pi) phi_track_approx-=two_pi; - - - for (unsigned int j=0;jstubs_[jSector].size();j++) { - double r=D->stubs_[jSector][j].r(); - if (fabs(r-r_track_approx)>8.0) continue; - double phi=D->stubs_[jSector][j].phi(); - - if (fabs((phi-phi_track_approx)*r_track_approx)>1.0) continue; - double z=D->stubs_[jSector][j].z(); - //skip stub if on disk - if (fabs(z-aTracklet.getStubs()[1].z())<5.0) continue; - - //cout << "r1 phi1 r2 phi2:" - // <stubs_[jSector][j].r()<<" " - // <stubs_[jSector][j].phi()<stubs_[jSector][j].iphi(); - double width=4.608; - double nstrip=508.0; - if (r<60.0) { - width=4.8; - nstrip=480; - } - double Deltai=width*(iphi-nstrip)/nstrip; //A bit of a hack... - if (z>0.0) Deltai=-Deltai; - - - double theta0=asin(Deltai/r); - - double Delta=Deltai-r_track*sin(theta0-(phi_track-phi)); - - - - //double phiturn=0.5*(z-z0)*rinv/t; - //if (fabs(phiturn)>0.25*two_pi) continue; - - //double phiproj=phi0-phiturn; - double rproj=2.0*sin(0.5*(z-z0)*rinv/t)/rinv; - - //double deltaphi=phi-phiproj; - //cout << "deltaphi phi phiproj:"<0.5*two_pi) deltaphi-=two_pi; - //if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - //if (!(fabs(deltaphi)<0.5*two_pi)) { - // cout << "deltaphi: "<0.2*phiSF) continue; - if (fabs(deltar)>3.0) continue; - - double dist=hypot(rdeltaphi/0.2,deltar/3.0); - - if (diststubs_[jSector][j]; - distbest=dist; - } - - } - } - if (distbest<1e30) { - tracklets_[iSector][i].addStub(tmp); - } - } - } - } - - - -private: - - double rmin_; - double rmax_; - double zmax_; - -}; - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TConstants.hh b/SimDataFormats/SLHC/interface/L1TConstants.hh deleted file mode 100644 index 5e3726598134b..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TConstants.hh +++ /dev/null @@ -1,41 +0,0 @@ -#ifndef L1TCONSTANTS_H -#define L1TCONSTANTS_H - -//static double DZ=0.0125; -//static double DX=0.00125; - -//static int MAXZ=32768*2; -//static int MAXX=8192; - -//static int BASE=32768*4; -//static int BASE2=BASE*64; -//static int BASE3=1024*8; -//static int BASE4=8192; -//static int BASE5=32768; -//static int BASE6=32768; -//static int BASE7=32768*4; -//static int BASE8=1024*16; - -//static int BASE9=32768*4; - -//static int BASE10=32768*16; -//static int BASE11=8192*4; -//static int BASE12=65536; -//static int BASE13=4096; - -//static int BASE14=4; -//static int BASE15=8; -//static int BASE16=16; -//static int BASE17=1024; - -//static int BASE18=4096; -//static int BASE19=1024; - -//static int BASE20=512; - -//static long long int MAXINT=65535*32768; - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TDisk.hh b/SimDataFormats/SLHC/interface/L1TDisk.hh deleted file mode 100644 index 2a1c75798ba0c..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TDisk.hh +++ /dev/null @@ -1,348 +0,0 @@ -#ifndef L1TDISK_H -#define L1TDISK_H - -#include -#include -#include -#include -#include -using namespace std; - -#include "L1TStub.hh" -#include "L1TTracklet.hh" -#include "L1TGeomBase.hh" - -class L1TDisk: public L1TGeomBase{ - -private: - L1TDisk(){ - } - - -public: - - L1TDisk(double zmin,double zmax, int NSector){ - zmin_=zmin; - zmax_=zmax; - if (zmin<0.0) { - zmin_=zmax; - zmax_=zmin; - } - NSector_=NSector; - stubs_.resize(NSector); - tracklets_.resize(NSector); - tracks_.resize(NSector); - } - - bool addStub(const L1TStub& aStub){ - //cout << "z zmin zmax:"<zmax_) return false; - double phi=aStub.phi(); - if (phi<0) phi+=two_pi; - int nSector=NSector_*phi/two_pi; - assert(nSector>=0); - assert(nSector=NSector_) jSector-=NSector_; - for (unsigned int i=0;istubs_[jSector].size();j++) { - double r2=D->stubs_[jSector][j].r(); - double z2=D->stubs_[jSector][j].z(); - double zcrude=z1-(z2-z1)*r1/(r2-r1); - if (fabs(zcrude)>30) continue; - - - double phi2=D->stubs_[jSector][j].phi(); - - if (r1>60.0||r2>60.0) continue; - - double deltaphi=phi1-phi2; - - if (deltaphi>0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.5*two_pi); - - if (fabs(r1-r2)/fabs(z1-z2)<0.1) continue; - - double dist=sqrt(r2*r2+r1*r1-2*r1*r2*cos(deltaphi)); - - double rinv=2*sin(deltaphi)/dist; - - if (fabs(rinv)>0.0057) continue; - - double tmp=0.5*r1*rinv; - - if (fabs(tmp)>=1.0) continue; - - double phi0=phi1+asin(tmp); - - if (phi0>0.5*two_pi) phi0-=two_pi; - if (phi0<-0.5*two_pi) phi0+=two_pi; - if (!(fabs(phi0)<0.5*two_pi)) { - cout << "phi0 "<15.0) continue; - - double pt1=stubs_[iSector][i].pt(); - double pt2=D->stubs_[jSector][j].pt(); - double pttracklet=0.3*3.8/(rinv*100); - bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; - bool pass2=fabs(1.0/pt2-1.0/pttracklet)<0.5; - bool pass=pass1&&pass2; - if (!pass) continue; - - //cout << "L1TDisk found tracklet"<stubs_[jSector][j]); - - //cout << "L1TDisk tracklet z() "<=NSector_) jSector-=NSector_; - if (D->stubs_[jSector].size()==0) continue; - - double zapprox=D->stubs_[jSector][0].z(); - - double r_track_approx=2.0*sin(0.5*rinv*(zapprox-z0)/t)/rinv; - double phi_track_approx=phi0-0.5*rinv*(zapprox-z0)/t; - if (phi_track_approx-D->stubs_[jSector][0].phi()<-0.5*two_pi) phi_track_approx+=two_pi; - if (phi_track_approx-D->stubs_[jSector][0].phi()>0.5*two_pi) phi_track_approx-=two_pi; - - - for (unsigned int j=0;jstubs_[jSector].size();j++) { - double r=D->stubs_[jSector][j].r(); - if (fabs(r-r_track_approx)>10.0) continue; - double z=D->stubs_[jSector][j].z(); - double phi=D->stubs_[jSector][j].phi(); - - if (fabs((phi-phi_track_approx)*r_track_approx)>1.0) continue; - - double r_track=2.0*sin(0.5*rinv*(z-z0)/t)/rinv; - double phi_track=phi0-0.5*rinv*(z-z0)/t; - - int iphi=D->stubs_[jSector][j].iphi(); - double width=4.608; - double nstrip=508.0; - if (r<60.0) { - width=4.8; - nstrip=480; - } - double Deltai=width*(iphi-nstrip)/nstrip; //A bit of a hack... - if (z>0.0) Deltai=-Deltai; - - - double theta0=asin(Deltai/r); - - double Delta=Deltai-r_track*sin(theta0-(phi_track-phi)); - - - - if (Delta!=Delta) { - cout << "Error: "<0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.5*two_pi); - - double rdeltaphi=Delta; - double deltar=r-rproj; - - if (0&&fabs(Delta)<10.0&&fabs(deltar)<15.0) { - static ofstream out("diskmatch.txt"); - out << aTracklet.r()<<" "<rphicut1*phiSF) continue; - if (fabs(deltar)>rcut1) continue; - dist=hypot(rdeltaphi/rphicut1,deltar/rcut1); - } - else { - if (fabs(rdeltaphi)>rphicut2*phiSF) continue; - if (fabs(deltar)>rcut2) continue; - dist=hypot(rdeltaphi/rphicut2,deltar/rcut2); - } - - /* - double pt1=D->stubs_[jSector][j].pt(); - double pttracklet=aTracklet.pt(3.8); - bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; - if (!pass1) continue; - */ - - if (diststubs_[jSector][j]; - } - - //cout << "rdeltaphi deltar:"<=NSector_) jSector-=NSector_; - if (L->stubs_[jSector].size()==0) continue; - - - double rapprox=L->stubs_[jSector][0].r(); - - double phiprojapprox=phi0-asin(0.5*rapprox*rinv); - double zprojapprox=z0+2*t*asin(0.5*rapprox*rinv)/rinv; - if (phiprojapprox-L->stubs_[jSector][0].phi()<-0.5*two_pi) phiprojapprox+=two_pi; - if (phiprojapprox-L->stubs_[jSector][0].phi()>0.5*two_pi) phiprojapprox-=two_pi; - - - for (unsigned int j=0;jstubs_[jSector].size();j++) { - double r=L->stubs_[jSector][j].r(); - double z=L->stubs_[jSector][j].z(); - if (fabs(z-zprojapprox)>15.0) continue; - double phi=L->stubs_[jSector][j].phi(); - double deltaphiapprox=fabs(phi-phiprojapprox); - assert(deltaphiapprox<12.0); - if (deltaphiapprox*rapprox>2.0) continue; - //cout << "r1 phi1 r2 phi2:" - // <stubs_[jSector][j].r()<<" " - // <stubs_[jSector][j].phi()<0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.5*two_pi); - - double rdeltaphi=r*deltaphi; - double deltaz=z-zproj; - - if (fabs(rdeltaphi)>0.1*phiSF) continue; - if (fabs(deltaz)>5.0) continue; //LS modified from 0.5 to 5.0 - - double dist=hypot(rdeltaphi/0.1,deltaz/5.0); //LS modified from 0.5 to 5.0 - - if (diststubs_[jSector][j]; - } - - } - } - if (bestdist<1e30) { - tracklets_[iSector][i].addStub(tmp); - } - } - } - } - - - -private: - - double zmin_; - double zmax_; - -}; - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TGeomBase.hh b/SimDataFormats/SLHC/interface/L1TGeomBase.hh deleted file mode 100644 index 7cfed036ba979..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TGeomBase.hh +++ /dev/null @@ -1,76 +0,0 @@ -#ifndef L1TGEOMBASE_H -#define L1TGEOMBASE_H - -#include -#include -#include -#include -#include -using namespace std; - -#include "L1TStub.hh" -#include "L1TTracklet.hh" - -class L1TGeomBase{ - - friend class L1TDisk; - friend class L1TBarrel; - -private: - L1TGeomBase(){ - } - - -public: - - void fitTracks() { - for(int iSector=0;iSector3){ - L1TTrack aTrack(tracklets_[iSector][i]); - tracks_[iSector].addTrack(aTrack); - } - } - } - } - - unsigned int nTracks(int iSector) const {return tracks_[iSector].size();} - L1TTrack& track(int iSector, unsigned int i) {return tracks_[iSector].get(i);} - - unsigned int nTracklets(int iSector) const {return tracklets_[iSector].size();} - L1TTracklet& tracklet(int iSector, unsigned int i) {return tracklets_[iSector][i];} - - L1TTracks allTracks(){ - L1TTracks tracks=tracks_[0]; - for (int i=1;i > stubs_; - - vector > tracklets_; - - vector tracks_; - - -}; - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TSector.hh b/SimDataFormats/SLHC/interface/L1TSector.hh deleted file mode 100755 index 37aaac2410aa0..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TSector.hh +++ /dev/null @@ -1,927 +0,0 @@ -#ifndef L1TSECTOR_H -#define L1TSECTOR_H - -#include -#include -using namespace std; - -#include "L1TRod.hh" -#include "L1TTracklets.hh" -#include "L1TTracks.hh" - -//This is the number of strips in rphi and in z for a module. -//This should be in the header of the ASCII file, but for now -//just hardcoded here. - - - -class L1TSector{ - -private: - - L1TSector(): - L11I_(0,1,1), - L11O_(0,2,1), - L12I_(0,1,2), - L12O_(0,2,2), - L13I_(0,1,3), - L13O_(0,2,3), - - L31I_(0,3,1), - L31O_(0,4,1), - L32I_(0,3,2), - L32O_(0,4,2), - L33I_(0,3,3), - L33O_(0,4,3), - L34I_(0,3,4), - L34O_(0,4,4), - - L5a1I_(0,5,1), - L5a1O_(0,6,1), - L5a2I_(0,5,2), - L5a2O_(0,6,2), - L5a3I_(0,5,3), - L5a3O_(0,6,3), - L5a4I_(0,5,4), - L5a4O_(0,6,4), - - L5b1I_(0,7,1), - L5b1O_(0,8,1), - L5b2I_(0,7,2), - L5b2O_(0,8,2), - L5b3I_(0,7,3), - L5b3O_(0,8,3), - L5b4I_(0,7,4), - L5b4O_(0,8,4), - - - L51I_(0,9,1), - L51O_(0,10,1), - L52I_(0,9,2), - L52O_(0,10,2), - L53I_(0,9,3), - L53O_(0,10,3), - L54I_(0,9,4), - L54O_(0,10,4), - L55I_(0,9,5), - L55O_(0,10,5), - L56I_(0,9,6), - L56O_(0,10,6), - L57I_(0,9,7), - L57O_(0,10,7) - { - n_=0; - } - -public: - - L1TSector(int n): - L11I_(n,1,1), - L11O_(n,2,1), - L12I_(n,1,2), - L12O_(n,2,2), - L13I_(n,1,3), - L13O_(n,2,3), - - L31I_(n,3,1), - L31O_(n,4,1), - L32I_(n,3,2), - L32O_(n,4,2), - L33I_(n,3,3), - L33O_(n,4,3), - L34I_(n,3,4), - L34O_(n,4,4), - - L5a1I_(n,5,1), - L5a1O_(n,6,1), - L5a2I_(n,5,2), - L5a2O_(n,6,2), - L5a3I_(n,5,3), - L5a3O_(n,6,3), - L5a4I_(n,5,4), - L5a4O_(n,6,4), - - L5b1I_(n,7,1), - L5b1O_(n,8,1), - L5b2I_(n,7,2), - L5b2O_(n,8,2), - L5b3I_(n,7,3), - L5b3O_(n,8,3), - L5b4I_(n,7,4), - L5b4O_(n,8,4), - - - L51I_(n,9,1), - L51O_(n,10,1), - L52I_(n,9,2), - L52O_(n,10,2), - L53I_(n,9,3), - L53O_(n,10,3), - L54I_(n,9,4), - L54O_(n,10,4), - L55I_(n,9,5), - L55O_(n,10,5), - L56I_(n,9,6), - L56O_(n,10,6), - L57I_(n,9,7), - L57O_(n,10,7) - { - n_=n; - } - - - - //uggly helper function - void append(L1TTracklets& a,L1TTracklets b){ - for (unsigned int i=0;i1) { - L1TTrack aTrack(aTracklet); - L1Tracks_.addTrack(aTrack); - } - } - for (unsigned int i=0; i1) { - L1TTrack aTrack(aTracklet); - L1Tracks_.addTrack(aTrack); - } - } - for (unsigned int i=0; i1) { - L1TTrack aTrack(aTracklet); - L1Tracks_.addTrack(aTrack); - } - } - - } - - L1TTracks getTracks() { - return L1Tracks_; - } - - void print() { - - cout << "Sector:"<999 && z_>0.0) ptsgn=-ptsgn; //sign fix for forward endcap - return ptsgn; - } - - double diphi() { - if (!innerdigis_.size()>0) { - cout << "innerdigis_.size()="<0) { - cout << "outerdigis_.size()="<0) { - cout << "innerdigis_.size()="< > innerdigis() const { return innerdigis_; } - vector > outerdigis() const { return outerdigis_; } - vector > innerdigisladdermodule() const { return innerdigisladdermodule_; } - vector > outerdigisladdermodule() const { return outerdigisladdermodule_; } - double x() const { return x_; } - double y() const { return y_; } - double z() const { return z_; } - double r() const { return sqrt(x_*x_+y_*y_); } - double pt() const { return pt_; } - - double phi() const { return atan2(y_,x_); } - - unsigned int iphi() const { return iphi_; } - unsigned int iz() const { return iz_; } - - void setiphi(int iphi) {iphi_=iphi;} - void setiz(int iz) {iz_=iz;} - - double sigmax() const {return sigmax_;} - double sigmaz() const {return sigmaz_;} - - bool operator== (const L1TStub& other) const { - if (other.iphi()==iphi_ && - other.iz()==iz_ && - other.layer()==layer_ && - other.ladder()==ladder_ && - other.module()==module_) - return true; - - else - return false; - } - - void lorentzcor(double shift){ - double r=this->r(); - double phi=this->phi()-shift/r; - this->x_=r*cos(phi); - this->y_=r*sin(phi); - } - - int simtrackid() const { return simtrackid_;} - - -private: - - int simtrackid_; - unsigned int iphi_; - unsigned int iz_; - unsigned int layer_; - unsigned int ladder_; - unsigned int module_; - double x_; - double y_; - double z_; - double sigmax_; - double sigmaz_; - double pt_; - - vector > innerdigis_; - vector > innerdigisladdermodule_; - vector > outerdigis_; - vector > outerdigisladdermodule_; - - -}; - - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TTrack.hh b/SimDataFormats/SLHC/interface/L1TTrack.hh deleted file mode 100644 index f6e84b2252e86..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TTrack.hh +++ /dev/null @@ -1,664 +0,0 @@ -#ifndef L1TTRACK_H -#define L1TTRACK_H - -#include -#include - - -using namespace std; - -class L1TTrack{ - -public: - - L1TTrack() { }; - - L1TTrack(const L1TTracklet& seed) { - - seed_=seed; - rinv_=seed.rinv(); - phi0_=seed.phi0(); - z0_=seed.z0(); - t_=seed.t(); - stubs_=seed.getStubs(); - - double largestresid; - int ilargestresid; - - for (int i=0;i<1;i++){ - - if (i>0) { - rinv_=rinvfit_; - phi0_=phi0fit_; - z0_=z0fit_; - t_=tfit_; - } - - calculateDerivatives(); - - linearTrackFit(); - - - } - - largestresid=-1.0; - ilargestresid=-1; - - residuals(largestresid,ilargestresid); - - //cout << "Chisq largestresid: "<3&&chisq()>100.0&&largestresid>5.0) { - //cout << "Refitting track"<0.0) Deltai=-Deltai; - double theta0=asin(Deltai/ri); - - double rmultiplier=-sin(theta0-(phi_track-phii)); - double phimultiplier=r_track*cos(theta0-(phi_track-phii)); - - - double drdrinv=-2.0*sin(0.5*rinv_*(zi-z0_)/t_)/(rinv_*rinv_) - +(zi-z0_)*cos(0.5*rinv_*(zi-z0_)/t_)/(rinv_*t_); - double drdphi0=0; - double drdt=-(zi-z0_)*cos(0.5*rinv_*(zi-z0_)/t_)/(t_*t_); - double drdz0=-cos(0.5*rinv_*(zi-z0_)/t_)/t_; - - double dphidrinv=-0.5*(zi-z0_)/t_; - double dphidphi0=1.0; - double dphidt=0.5*rinv_*(zi-z0_)/(t_*t_); - double dphidz0=0.5*rinv_/t_; - - D_[0][j]=drdrinv/sigmaz; - D_[1][j]=drdphi0/sigmaz; - D_[2][j]=drdt/sigmaz; - D_[3][j]=drdz0/sigmaz; - j++; - //second the rphi position - D_[0][j]=(phimultiplier*dphidrinv+rmultiplier*drdrinv)/sigmax; - D_[1][j]=(phimultiplier*dphidphi0+rmultiplier*drdphi0)/sigmax; - D_[2][j]=(phimultiplier*dphidt+rmultiplier*drdt)/sigmax; - D_[3][j]=(phimultiplier*dphidz0+rmultiplier*drdz0)/sigmax; - //old calculation - //D_[0][j]=-0.5*(zi-z0_)/(t_*(sigmax/ri)); - //D_[1][j]=1.0/(sigmax/ri); - //D_[2][j]=-0.5*rinv_*(zi-z0_)/(t_*t_*(sigmax/ri)); - //D_[3][j]=0.5*rinv_/((sigmax/ri)*t_); - j++; - } - - //cout << "Exact rinv derivative: "<0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.1*two_pi); - - delta[j++]=ri*deltaphi/sigmax; - delta[j++]=(z0fit_+(2.0/rinvfit_)*tfit_*asin(0.5*ri*rinvfit_)-zi)/sigmaz; - - } - else { - //we are dealing with a disk hit - - double r_track=2.0*sin(0.5*rinvfit_*(zi-z0fit_)/tfit_)/rinvfit_; - double phi_track=phi0fit_-0.5*rinvfit_*(zi-z0fit_)/tfit_; - - int iphi=stubs_[i].iphi(); - - double width=4.608; - double nstrip=508.0; - if (ri<60.0) { - width=4.8; - nstrip=480; - } - double Deltai=width*(iphi-nstrip)/nstrip; //A bit of a hack... - - if (stubs_[i].z()>0.0) Deltai=-Deltai; - - double theta0=asin(Deltai/ri); - - double Delta=Deltai-r_track*sin(theta0-(phi_track-phii)); - - delta[j++]=(r_track-ri)/sigmaz; - delta[j++]=Delta/sigmax; - } - - if (fabs(delta[j-2])>largestresid) { - largestresid=fabs(delta[j-2]); - ilargestresid=i; - } - - if (fabs(delta[j-1])>largestresid) { - largestresid=fabs(delta[j-1]); - ilargestresid=i; - } - - if (print) cout << delta[j-2]<<" "<0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.1*two_pi); - - delta[j++]=ri*deltaphi/sigmax; - delta[j++]=(z0_+(2.0/rinv_)*t_*asin(0.5*ri*rinv_)-zi)/sigmaz; - - - //numerical derivative check - - for (int iii=0;iii<0;iii++){ - - double drinv=0.0; - double dphi0=0.0; - double dt=0.0; - double dz0=0.0; - - if (iii==0) drinv=0.001*fabs(rinv_); - if (iii==1) dphi0=0.001; - if (iii==2) dt=0.001; - if (iii==3) dz0=0.01; - - double deltaphi=phi0_+dphi0-asin(0.5*ri*(rinv_+drinv))-phii; - if (deltaphi>0.5*two_pi) deltaphi-=two_pi; - if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - assert(fabs(deltaphi)<0.1*two_pi); - - double delphi=ri*deltaphi/sigmax; - double deltaz=(z0_+dz0+(2.0/(rinv_+drinv))*(t_+dt)*asin(0.5*ri*(rinv_+drinv))-zi)/sigmaz; - - - if (iii==0) cout << "Numerical rinv derivative: "<0.0) Deltai=-Deltai; - - double theta0=asin(Deltai/ri); - - double Delta=Deltai-r_track*sin(theta0-(phi_track-phii)); - - delta[j++]=(r_track-ri)/sigmaz; - //double deltaphi=phi_track-phii; - //if (deltaphi>0.5*two_pi) deltaphi-=two_pi; - //if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; - //assert(fabs(deltaphi)<0.1*two_pi); - //delta[j++]=deltaphi/(sigmax/ri); - delta[j++]=Delta/sigmax; - - //numerical derivative check - - for (int iii=0;iii<0;iii++){ - - double drinv=0.0; - double dphi0=0.0; - double dt=0.0; - double dz0=0.0; - - if (iii==0) drinv=0.001*fabs(rinv_); - if (iii==1) dphi0=0.001; - if (iii==2) dt=0.001; - if (iii==3) dz0=0.01; - - r_track=2.0*sin(0.5*(rinv_+drinv)*(zi-(z0_+dz0))/(t_+dt))/(rinv_+drinv); - //cout <<"t_track 2: "<0.0) Deltai=-Deltai; - theta0=asin(Deltai/ri); - - Delta=Deltai-r_track*sin(theta0-(phi_track-phii)); - - if (iii==0) cout << "Numerical rinv derivative: "<=2); - - } - - - int simtrackid(double& fraction) const { - - //cout << "In L1TTrack::simtrackid"< simtrackids; - - for(unsigned int i=0;isecond<second>nsimtrack) { - nsimtrack=it->second; - simtrackid=it->first; - } - it++; - } - - //cout << "L1TTrack::simtrackid done"< getStubs() const { return stubs_; } - unsigned int nstub() const { return stubs_.size(); } - double rinv() const { return rinv_; } - double getPhi0() const { return phi0_; } - double getZ0() const { return z0_; } - double getT() const { return t_; } - bool isCombinatorics() const { return isCombinatorics_; } - double getSimTrackID() const { return SimTrackID_; } - - double pt(double bfield) const { return 0.00299792*bfield/rinvfit_; } - //double ipt(double bfield) const { return 0.00299792*bfield/irinvfit(); } - double ptseed(double bfield) const { return 0.00299792*bfield/rinv_; } - - double phi0() const { return phi0fit_;} - //double iphi0() const { return iphi0fit();} - double phi0seed() const { return phi0_;} - - double eta() const { static double two_pi=8*atan(1.0); - return -log(tan(0.5*(0.25*two_pi-atan(tfit_)))); } - //double ieta() const { static double two_pi=8*atan(1.0); - // return -log(tan(0.5*(0.25*two_pi-atan(itfit())))); } - double etaseed() const { static double two_pi=8*atan(1.0); - return -log(tan(0.5*(0.25*two_pi-atan(t_)))); } - - double z0() const { return z0fit_; } - //double iz0() const { return iz0fit(); } - double z0seed() const { return z0_; } - - double chisq1() const {return chisq1_;} - double chisq2() const {return chisq2_;} - - double chisq1dof() const {return chisq1_/(stubs_.size()-2);} - double chisq2dof() const {return chisq2_/(stubs_.size()-2);} - - double chisq() const {return chisq1_+chisq2_; } - double chisqdof() const {return (chisq1_+chisq2_)/(2*stubs_.size()-4); } - - -private: - - L1TTracklet seed_; - vector stubs_; - double rinv_; - double phi0_; - double z0_; - double t_; - bool isCombinatorics_; - int SimTrackID_; - double rinvfit_; - double phi0fit_; - double z0fit_; - double tfit_; - - int irinvfit_; - int iphi0fit_; - int iz0fit_; - int itfit_; - - double chisq1_; - double chisq2_; - - int ichisq1_; - int ichisq2_; - - double D_[4][40]; - - double M_[4][8]; - - double MinvDt_[4][40]; - - -}; - - -#endif diff --git a/SimDataFormats/SLHC/interface/L1TTracklet.hh b/SimDataFormats/SLHC/interface/L1TTracklet.hh deleted file mode 100755 index 1fd74853bab6b..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TTracklet.hh +++ /dev/null @@ -1,96 +0,0 @@ -#ifndef L1TTRACKLET_H -#define L1TTRACKLET_H - -#include -#include -#include -#include - -using namespace std; - - - -class L1TTracklet{ - -public: - - L1TTracklet(double rinv, double phi0, double t, double z0){ - - rinv_=rinv; - phi0_=phi0; - t_=t; - z0_=z0; - - } - - L1TTracklet(){ - } - - void addStub(const L1TStub& j){ - stubs_.push_back(j); - } - - vector getStubs() const { - return stubs_; - } - - int simtrackid(double& fraction) const { - - - map simtrackids; - - for(unsigned int i=0;isecond<second>nsimtrack) { - nsimtrack=it->second; - simtrackid=it->first; - } - it++; - } - - fraction=(1.0*nsimtrack)/stubs_.size(); - - return simtrackid; - - } - - double pt(double bfield) const { return 0.00299792*bfield/rinv_; } - - int nStubs() const {return stubs_.size();} - - double rinv() const {return rinv_;} - double phi0() const {return phi0_;} - double t() const {return t_;} - double z0() const {return z0_;} - - double r() const {return stubs_[0].r();} - double z() const {return stubs_[0].z();} - - -private: - - double rinv_; - double phi0_; - double t_; - double z0_; - - vector stubs_; - -}; - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TTracklets.hh b/SimDataFormats/SLHC/interface/L1TTracklets.hh deleted file mode 100755 index 18d4ca61c23ab..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TTracklets.hh +++ /dev/null @@ -1,58 +0,0 @@ -#ifndef L1TTRACKLETS_H -#define L1TTRACKLETS_H - -#include -#include - -#include "L1TTracklet.hh" - - -using namespace std; - -//This is the number of strips in rphi and in z for a module. -//This should be in the header of the ASCII file, but for now -//just hardcoded here. - - - -class L1TTracklets{ - -public: - - L1TTracklets(){ - - } - - void addTracklet(const L1TTracklet& aTracklet){ - tracklets_.push_back(aTracklet); - } - - void print() { - - for (unsigned int i=0;i tracklets_; - -}; - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TTracks.hh b/SimDataFormats/SLHC/interface/L1TTracks.hh deleted file mode 100644 index eaf085b8e2c70..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TTracks.hh +++ /dev/null @@ -1,139 +0,0 @@ -#ifndef L1TTRACKS_H -#define L1TTRACKS_H - -#include -#include - -#include "L1TTrack.hh" - - -using namespace std; - - -class L1TTracks{ - -public: - - L1TTracks(){ - - } - - void addTrack(const L1TTrack& aTrack){ - tracks_.push_back(aTrack); - } - - void addTracks(const L1TTracks& tracks){ - for(unsigned int i=0;i NduplicatesPerTrack() { - - vector NdupPerTrack; - vector Ndups((int)tracks_.size()); - - for (unsigned int i=0; i deleted(tracks_.size()); - for(unsigned int i=0;ifabs(tracks_[j].rinv())) { - //if (fractioni=2)){ - deleted[i]=true; - continue; - } - if ((tracks_[j].npixelstrip()<2)&&(tracks_[i].npixelstrip()>=2)){ - deleted[j]=true; - continue; - } - if ((tracks_[i].npixelstrip()<3)&&(tracks_[j].npixelstrip()>=3)){ - deleted[i]=true; - continue; - } - if ((tracks_[j].npixelstrip()<3)&&(tracks_[i].npixelstrip()>=3)){ - deleted[j]=true; - continue; - } - if ((tracks_[i].npixelstrip()<4)&&(tracks_[j].npixelstrip()>=4)){ - deleted[i]=true; - continue; - } - if ((tracks_[j].npixelstrip()<4)&&(tracks_[i].npixelstrip()>=4)){ - deleted[j]=true; - continue; - } - - - - if (tracks_[i].chisqdof()>tracks_[j].chisqdof()) { - deleted[i]=true; - } else { - deleted[j]=true; - } - continue; - } - } - if (deleted[i]) continue; - } - - L1TTracks tmp; - - for(unsigned int i=0;i tracks_; - -}; - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TWord.hh b/SimDataFormats/SLHC/interface/L1TWord.hh deleted file mode 100755 index 56738e068a772..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TWord.hh +++ /dev/null @@ -1,228 +0,0 @@ -#ifndef L1TWORD_H -#define L1TWORD_H - -#include -#include -using namespace std; - -//This is the number of strips in rphi and in z for a module. -//This should be in the header of the ASCII file, but for now -//just hardcoded here. - - - -class L1TWord{ - -public: - - explicit L1TWord(bool printstat=false){ - - //cout << "In constructor 1"<maxsize_){ - cout <<"operator= "<maxsize_){ - cout << "Adding "<tmp.maxsize_) { - cout << "operator*:"<tmp.maxsize_) { - cout << "operator*(int):"<<"("<maxvalue_) { - maxvalue_=value; - } - } - - - long long int value_; - long long int maxsize_; - - std::string name_; - - bool printstat_; - long long int maxvalue_; - -}; - - - -#endif - - - diff --git a/SimDataFormats/SLHC/interface/L1TkBeam.h b/SimDataFormats/SLHC/interface/L1TkBeam.h deleted file mode 100644 index fa5893cd8d3a1..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TkBeam.h +++ /dev/null @@ -1,132 +0,0 @@ -/// //////////////////////////////////////// -/// Stacked Tracker Simulations /// -/// Written by: /// -/// Nicola Pozzobon /// -/// UNIPD /// -/// 2011, Nov /// -/// /// -/// //////////////////////////////////////// - -#ifndef STACKED_TRACKER_L1TK_BEAM_FORMAT_H -#define STACKED_TRACKER_L1TK_BEAM_FORMAT_H - -#include "DataFormats/Common/interface/Ref.h" -#include "DataFormats/Common/interface/Ptr.h" - -#include "DataFormats/GeometryVector/interface/GlobalPoint.h" - -namespace cmsUpgrades{ - - /** ************************ **/ - /** **/ - /** DECLARATION OF CLASS **/ - /** **/ - /** ************************ **/ - - class L1TkBeam { - - public: - - private: - /// Data members - unsigned int theBeamType; /// 0 = Beta, 1 = Gauss, 2 = Flat - GlobalPoint theBeamPosition; - double theSizeX; - double theSizeY; - double theSizeZ; - - public: - /// Constructors - L1TkBeam() - { - /// Set default data members - theBeamType = 99; - theBeamPosition = GlobalPoint(0.0, 0.0, 0.0); - theSizeX = 0.0; - theSizeY = 0.0; - theSizeZ = 0.0; - } - - /// Destructor - ~L1TkBeam() - { - /// Nothing to be done - } - - /// //////////////////////// /// - /// METHODS FOR DATA MEMBERS /// - /// Beam position - GlobalPoint getBeamPosition() const - { - return theBeamPosition; - } - - void setBeamPosition( double aPosX, double aPosY, double aPosZ ) - { - theBeamPosition = GlobalPoint( aPosX, aPosY, aPosZ ); - } - - /// Beam size - double getSizeX() const - { - return theSizeX; - } - - double getSizeY() const - { - return theSizeY; - } - - double getSizeZ() const - { - return theSizeZ; - } - - void setBeamSize( double aSizeX, double aSizeY, double aSizeZ ) - { - theSizeX = aSizeX; - theSizeY = aSizeY; - theSizeZ = aSizeZ; - } - - - - /// Beam type - unsigned int getBeamType() const - { - return theBeamType; - } - - void setBeamType( unsigned int aBeamType ) - { - theBeamType = aBeamType; - } - - /// ////////////// /// - /// HELPER METHODS /// - - /// /////////////////// /// - /// INFORMATIVE METHODS /// - - }; /// Close class - - - /** ***************************** **/ - /** **/ - /** IMPLEMENTATION OF METHODS **/ - /** **/ - /** ***************************** **/ - - /// THIS IS NOT A TEMPLATE CLASS, - /// so the definition is typed within the first instance - /// found by the compiler, otherwise, to implement it - /// outside of the class implementation, you need the inline - /// keyword to be used - -} /// Close namespace - -#endif - - - - diff --git a/SimDataFormats/SLHC/interface/L1TkCluster.h b/SimDataFormats/SLHC/interface/L1TkCluster.h deleted file mode 100644 index e331bf3f52eb5..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TkCluster.h +++ /dev/null @@ -1,389 +0,0 @@ -/// //////////////////////////////////////// -/// Stacked Tracker Simulations /// -/// /// -/// Nicola Pozzobon, UNIPD /// -/// Emmanuele Salvati, Cornell /// -/// /// -/// 2011, June /// -/// 2011, October /// -/// 2012, August /// -/// 2013, January /// -/// //////////////////////////////////////// - -#ifndef STACKED_TRACKER_L1TK_CLUSTER_FORMAT_H -#define STACKED_TRACKER_L1TK_CLUSTER_FORMAT_H - -#include "DataFormats/DetId/interface/DetId.h" -#include "DataFormats/Common/interface/Ref.h" -#include "DataFormats/Common/interface/Ptr.h" -#include "DataFormats/Common/interface/DetSet.h" -#include "DataFormats/Common/interface/DetSetVector.h" -#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" -#include "DataFormats/GeometryVector/interface/GlobalPoint.h" -#include "DataFormats/GeometryCommonDetAlgo/interface/MeasurementPoint.h" - -#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" -#include "SimDataFormats/Track/interface/SimTrack.h" -#include "SimDataFormats/Track/interface/SimTrackContainer.h" -#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" - - - /** ************************ **/ - /** **/ - /** DECLARATION OF CLASS **/ - /** **/ - /** ************************ **/ - - template< typename T > - class L1TkCluster - { - public: - /// Constructors - L1TkCluster(); - L1TkCluster( std::vector< T > aHits, DetId aDetId, unsigned int aStackMember ); - - /// Destructor - ~L1TkCluster(); - - /// Data members: getABC( ... ) - /// Helper methods: findABC( ... ) - - /// Hits in the Cluster - std::vector< T > getHits() const; - void setHits( std::vector< T > aHits ); - - /// Detector element - DetId getDetId() const; - void setDetId( DetId aDetId ); - unsigned int getStackMember() const; - void setStackMember( unsigned int aStackMember ); - - /// MC Truth - std::vector< edm::Ptr< SimTrack > > getSimTrackPtrs() const; - std::vector< uint32_t > getEventIds() const; - void addSimTrack( const edm::Ptr< SimTrack > &trk) { theSimTracks.push_back(trk);} - void addEventId( const uint32_t anId ) { theEventIds.push_back(anId); } - bool isGenuine() const; - bool isCombinatoric() const; - bool isUnknown() const; - int findType() const; - unsigned int findSimTrackId() const; - - /// Cluster width - unsigned int findWidth() const; - - /// Single hit coordinates and position - MeasurementPoint findHitLocalCoordinates( unsigned int hitIdx ) const; - - /// Average cluster coordinates and position - MeasurementPoint findAverageLocalCoordinates() const; - - /// Information - std::string print( unsigned int i=0 ) const; - - private: - /// Data members - std::vector< T > theHits; - DetId theDetId; - unsigned int theStackMember; - std::vector< edm::Ptr< SimTrack > > theSimTracks; - std::vector< uint32_t > theEventIds; - - }; /// Close class - - /** ***************************** **/ - /** **/ - /** IMPLEMENTATION OF METHODS **/ - /** **/ - /** ***************************** **/ - - /// Default Constructor - /// NOTE: to be used with setSomething(...) methods - template< typename T > - L1TkCluster< T >::L1TkCluster() - { - /// Set default data members - theHits.clear(); - theDetId = 0; - theStackMember = 0; - theSimTracks.clear(); - } - - /// Another Constructor - template< typename T > - L1TkCluster< T >::L1TkCluster( std::vector< T > aHits, DetId aDetId, unsigned int aStackMember ) - { - /// Set default data members - theHits.clear(); - for ( unsigned int j = 0; j < aHits.size(); j++ ) - theHits.push_back( aHits.at(j) ); - theDetId = aDetId; - theStackMember = aStackMember; - theSimTracks.clear(); - } - - /// Destructor - template< typename T > - L1TkCluster< T >::~L1TkCluster(){} - - /// Hits composing the cluster - template< typename T > - std::vector< T > L1TkCluster< T >::getHits() const { return theHits; } - - template< typename T > - void L1TkCluster< T >::setHits( std::vector< T > aHits ) - { - for ( unsigned int j=0; j - DetId L1TkCluster< T >::getDetId() const { return theDetId; } - - template< typename T > - void L1TkCluster< T >::setDetId( DetId aDetId ) { theDetId = aDetId; } - - template< typename T > - unsigned int L1TkCluster< T >::getStackMember() const { return theStackMember; } - - template< typename T > - void L1TkCluster< T >::setStackMember( unsigned int aStackMember ) { theStackMember = aStackMember; } - - /// MC truth information - template< typename T > - std::vector< edm::Ptr< SimTrack > > L1TkCluster< T >::getSimTrackPtrs() const { return theSimTracks; } - - template< typename T > - std::vector< uint32_t > L1TkCluster< T >::getEventIds() const { return theEventIds; } - - template< typename T > - bool L1TkCluster< T >::isGenuine() const - { - /// Check how many event ID's - std::vector< uint32_t > tempVecEvId = theEventIds; - tempVecEvId.erase( std::unique( tempVecEvId.begin(), tempVecEvId.end() ), tempVecEvId.end() ); - if ( tempVecEvId.size() > 1 ) - return false; - - /// If all SimTracks are from the same event/BX ... - /// GENUINE means that ALL hits could be associated to a - /// SimTrack stored in the corresponding collection, AND - /// all of these SimTracks are actually the same - int prevTrack = -99999; // SimTrackId storage - if ( theSimTracks.size() == 0 ) return false; - for ( unsigned int k = 0; k < theSimTracks.size(); k++ ) - { - edm::Ptr< SimTrack > curSimTrackPtr = theSimTracks.at(k); - if ( curSimTrackPtr.isNull() ) - /// Unknown SimTrack means false - return false; - else - { - if ( theSimTracks.size() > 1 ) - { - if ( prevTrack < 0 ) - { - prevTrack = curSimTrackPtr->trackId(); - } - - if ( prevTrack != (int)curSimTrackPtr->trackId() ) - /// Two different known SimTracks means false - return false; - - prevTrack = curSimTrackPtr->trackId(); - } - } - } - /// If not false, then it is true - return true; - } - - template< typename T > - bool L1TkCluster< T >::isCombinatoric() const - { - /// Check how many event ID's - std::vector< uint32_t > tempVecEvId = theEventIds; - tempVecEvId.erase( std::unique( tempVecEvId.begin(), tempVecEvId.end() ), tempVecEvId.end() ); - if ( tempVecEvId.size() > 1 ) - return true; - - /// If all SimTracks are from the same event/BX ... - /// COMBINATORIC means that different SimTracks contribute - /// to the cluster, which means that both a mixture of NULL - /// pointers and good ones are present, or that all are - /// good but there are more SimTracks associated to the cluster - int prevTrack = -99999; // SimTrackId storage - unsigned int numberNulls = 0; // Number of non-found SimTracks - unsigned int numberGoods = 0; // Number of found SimTracks - for ( unsigned int k = 0; k < theSimTracks.size(); k++ ) - { - edm::Ptr< SimTrack > curSimTrackPtr = theSimTracks.at(k); - if ( curSimTrackPtr.isNull() ) - numberNulls++; - else - numberGoods++; - - if ( numberNulls > 0 && numberGoods > 0 ) - /// Mixture of known and unknown SimTracks means true - return true; - - if ( curSimTrackPtr.isNull() == false ) - { - if ( theSimTracks.size() > 1 ) - { - if ( prevTrack < 0 ) - prevTrack = curSimTrackPtr->trackId(); - - if ( prevTrack != (int)curSimTrackPtr->trackId() ) - /// Two different known SimTracks means true - return true; - - prevTrack = curSimTrackPtr->trackId(); - } - } - } - - if ( numberNulls > 0 && numberGoods == 0 ) - /// Only unknown SimTracks means unknown, hence false - return false; - - /// If not true, then it is false - /// This includes if ( theSimTracks.size() == 0 ) - return false; - } - - template< typename T > - bool L1TkCluster< T >::isUnknown() const - { - /// Check how many event ID's - std::vector< uint32_t > tempVecEvId = theEventIds; - tempVecEvId.erase( std::unique( tempVecEvId.begin(), tempVecEvId.end() ), tempVecEvId.end() ); - if ( tempVecEvId.size() > 1 ) - return false; - - /// If all SimTracks are from the same event/BX ... - /// UNKNOWN means that all SimTracks pointers are NULL - for ( unsigned int k = 0; k < theSimTracks.size(); k++ ) - { - edm::Ptr< SimTrack > curSimTrackPtr = theSimTracks.at(k); - if ( curSimTrackPtr.isNull() == false ) - /// A known SimTrack means false - return false; - } - - /// If not false, then it is true - /// This includes if ( theSimTracks.size() == 0 ) - return true; - } - - template< typename T > - int L1TkCluster< T >::findType() const - { - if ( this->isGenuine() && theSimTracks.size()>0 ) - return theSimTracks.at(0)->type(); - return 999999999; - } - - template< typename T > - unsigned int L1TkCluster< T >::findSimTrackId() const - { - if ( this->isGenuine() && theSimTracks.size()>0 ) - return theSimTracks.at(0)->trackId(); - return 0; - } - - /// Cluster width - /// Specialize the template for PSimHits in *cc - template<> - unsigned int L1TkCluster< edm::Ref >::findWidth() const; - - /// Cluster width - /// Default template for PixelDigis - template< typename T > - unsigned int L1TkCluster< T >::findWidth() const - { - int rowMin = 99999999; - int rowMax = 0; - /// For broadside Clusters this is equivalent to theHits.size() - /// but for 2d or neighbor Clusters this is only the actual size in RPhi - for ( unsigned int i=0; irow() < rowMin ) - rowMin = theHits.at(i)->row(); - if ( theHits.at(i)->row() > rowMax ) - rowMax = theHits.at(i)->row(); - } - return abs( rowMax - rowMin + 1 ); /// This takes care of 1-Pixel clusters - } - - /// Get hit local coordinates - /// Specialize the template for PSimHits in *cc - template<> - MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findHitLocalCoordinates( unsigned int hitIdx ) const; - - /// Get hit local coordinates - /// Default template for PixelDigis - template< typename T > - MeasurementPoint L1TkCluster< T >::findHitLocalCoordinates( unsigned int hitIdx ) const - { - /// NOTE in this case, DO NOT add 0.5 - /// to get the center of the pixel - MeasurementPoint mp( theHits.at(hitIdx)->row(), theHits.at(hitIdx)->column() ); - return mp; - } - - - /// Unweighted average local cluster coordinates - /// Specialize the template for PSimHits in *cc - template<> - MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findAverageLocalCoordinates() const; - - /// Unweighted average local cluster coordinates - /// Default template for PixelDigis - template< typename T > - MeasurementPoint L1TkCluster< T >::findAverageLocalCoordinates() const - { - double averageCol = 0.0; - double averageRow = 0.0; - - /// Loop over the hits and calculate the average coordinates - if ( theHits.size() != 0 ) - { - typename std::vector< T >::const_iterator hitIter; - for ( hitIter = theHits.begin(); - hitIter != theHits.end(); - hitIter++ ) - { - averageCol += (*hitIter)->column(); - averageRow += (*hitIter)->row(); - } - averageCol /= theHits.size(); - averageRow /= theHits.size(); - } - return MeasurementPoint( averageRow, averageCol ); - } - - - /// Information - template< typename T > - std::string L1TkCluster< T >::print( unsigned int i ) const - { - std::string padding(""); - for ( unsigned int j=0; j!=i; ++j ) - padding+="\t"; - std::stringstream output; - output< - std::ostream& operator << (std::ostream& os, const L1TkCluster< T >& aL1TkCluster) { return ( os< - class L1TkStub - { - public: - /// Constructors - L1TkStub(); - L1TkStub( DetId aDetId ); - - /// Destructor - ~L1TkStub(); - - /// Data members: getABC( ... ) - /// Helper methods: findABC( ... ) - - /// Clusters composing the Stub - std::vector< edm::Ptr< L1TkCluster< T > > > getClusterPtrs() const { return theClusters; } - const edm::Ptr< L1TkCluster< T > >& getClusterPtr( unsigned int hitIdentifier ) const; - void addClusterPtr( edm::Ptr< L1TkCluster< T > > aL1TkCluster ); - - /// NOTE they are added and stored as edm::Ptr< Cluster > but - /// returned as just Cluster for backward compatibility with - /// HitMatching Algorithms - - /// Detector element - DetId getDetId() const { return theDetId; } - void setDetId( DetId aDetId ); - - /// Trigger information - double getTriggerDisplacement() const; /// In FULL-STRIP units! (hence, not implemented herein) - void setTriggerDisplacement( int aDisplacement ); /// In HALF-STRIP units! - double getTriggerOffset() const; /// In FULL-STRIP units! (hence, not implemented herein) - void setTriggerOffset( int anOffset ); /// In HALF-STRIP units! - - /// MC truth - edm::Ptr< SimTrack > getSimTrackPtr() const { return theSimTrack; } - uint32_t getEventId() const { return theEventId; } - bool isGenuine() const; - bool isCombinatoric() const; - bool isUnknown() const; - int findType() const; - unsigned int findSimTrackId() const; - - /// Collect MC truth - void checkSimTrack(); - - /// Information - std::string print( unsigned int i=0 ) const; - - private: - /// Data members - DetId theDetId; - std::vector< edm::Ptr< L1TkCluster< T > > > theClusters; - edm::Ptr< SimTrack > theSimTrack; - uint32_t theEventId; - int theDisplacement; - int theOffset; - - }; /// Close class - - /** ***************************** **/ - /** **/ - /** IMPLEMENTATION OF METHODS **/ - /** **/ - /** ***************************** **/ - - /// Default Constructor - template< typename T > - L1TkStub< T >::L1TkStub() - { - /// Set default data members - theDetId = 0; - theClusters.clear(); - theDisplacement = 999999; - theOffset = 0; - /// theSimTrack is NULL by default - theEventId = 0xFFFF; - } - - /// Another Constructor - template< typename T > - L1TkStub< T >::L1TkStub( DetId aDetId ) - { - /// Set default data members - theDetId = aDetId; - theClusters.clear(); - theDisplacement = 999999; - theOffset = 0; - /// theSimTrack is NULL by default - theEventId = 0xFFFF; - } - - /// Destructor - template< typename T > - L1TkStub< T >::~L1TkStub(){} - - /// Get the Pointer to a Cluster - template< typename T > - const edm::Ptr< L1TkCluster< T > >& L1TkStub< T >::getClusterPtr( unsigned int hitIdentifier ) const - { - typename std::vector< edm::Ptr< L1TkCluster< T > > >::const_iterator clusIter; - for ( clusIter = theClusters.begin(); - clusIter != theClusters.end(); - ++clusIter ) - { - if ( (*clusIter)->getStackMember() == hitIdentifier ) - return *clusIter; - } - - //hopefully code doesnt reach this point- not sure who would delete this - edm::Ptr< L1TkCluster< T > >* tmpCluPtr = new edm::Ptr< L1TkCluster< T > >(); - return *tmpCluPtr; - - } - - /// Add the Clusters to the candidate Stub - template< typename T > - void L1TkStub< T >::addClusterPtr( edm::Ptr< L1TkCluster< T > > aL1TkCluster ) - { - /// NOTE: this must be used ONLY as it is used - /// within the L1TkStubBuilder! - /// So, pushing back in the right order!! - theClusters.push_back( aL1TkCluster ); - } - - /// Detector element - template< typename T > - void L1TkStub< T >::setDetId( DetId aDetId ) { theDetId = aDetId; } - - /// Trigger info - template< typename T > - double L1TkStub< T >::getTriggerDisplacement() const { return 0.5*theDisplacement; } - - template< typename T > - void L1TkStub< T >::setTriggerDisplacement( int aDisplacement ) { theDisplacement = aDisplacement; } - - template< typename T > - double L1TkStub< T >::getTriggerOffset() const { return 0.5*theOffset; } - - template< typename T > - void L1TkStub< T >::setTriggerOffset( int anOffset ) { theOffset = anOffset; } - - /// MC truth - template< typename T > - bool L1TkStub< T >::isGenuine() const - { - /* - /// GENUINE for clusters means not combinatoric and - /// not unknown: same MC truth content MUST be found - /// in both clusters composing the stub - if ( theClusters.at(0)->isUnknown() || theClusters.at(1)->isUnknown() ) - /// If at least one cluster is unknown, it means - /// either unknown, either combinatoric - return false; - - else - { - /// Here both are clusters are genuine/combinatoric - /// If both clusters have some known SimTrack content - /// they must be compared to each other - if ( theClusters.at(0)->isGenuine() && theClusters.at(1)->isGenuine() ) - { - if ( theClusters.at(0)->findSimTrackId() == theClusters.at(1)->findSimTrackId() ) - /// Two genuine clusters with same SimTrack content mean genuine - return true; - else - return false; - } - else - { - /// Here, at least one cluster is combinatoric - int prevTrack = -99999; // SimTrackId storage - std::vector< edm::Ptr< SimTrack > > innerSimTracks = theClusters.at(0)->getSimTrackPtrs(); - std::vector< edm::Ptr< SimTrack > > outerSimTracks = theClusters.at(1)->getSimTrackPtrs(); - for ( unsigned int i = 0; i < innerSimTracks.size(); i++ ) - { - /// Skip NULL pointers - if ( innerSimTracks.at(i).isNull() ) - continue; - for ( unsigned int j = 0; j < outerSimTracks.size(); j++ ) - { - /// Skip NULL pointers - if ( outerSimTracks.at(j).isNull() ) - continue; - - if ( innerSimTracks.at(i)->trackId() == outerSimTracks.at(j)->trackId() ) - { - /// Same SimTrack is present in both clusters - if ( prevTrack < 0 ) - prevTrack = outerSimTracks.at(j)->trackId(); - - if ( prevTrack != (int)outerSimTracks.at(j)->trackId() ) - /// If two different SimTracks are found in both clusters, - /// then the stub is for sure combinatoric - return false; - } - } - } - if ( prevTrack < 0 ) - /// No SimTracks were found to be in both clusters - return false; - else - /// Only one SimTrack was found to be present in both clusters - /// even if one of the clusters (or both) are combinatoric: - /// this means there is only one track that participates in - /// both clusters, hence the stub is genuine - return true; - } - } - /// Default - /// Should never get here - std::cerr << "W A R N I N G! L1TkStub::isGenuine() \t we should never get here" << std::endl; - return true; - */ - - if ( theSimTrack.isNull() ) - return false; - - return true; - } - - template< typename T > - bool L1TkStub< T >::isCombinatoric() const - { - if ( this->isGenuine() ) - return false; - - /* - /// COMBINATORIC means that the same MC truth content - /// cannot be found in the pair of clusters that compose - /// the stub, and at leask one of them is not unknown - if ( theClusters.at(0)->isUnknown() && theClusters.at(1)->isUnknown() ) - /// Two unknown clusters mean that the stub is unknown - return false; - - else if ( theClusters.at(0)->isUnknown() || theClusters.at(1)->isUnknown() ) - /// One unknown and one combinatoric mean the stub is combinatoric - /// One unknown and one genuine mean the stub is combinatoric - return true; - - else - { - /// Here both are clusters are genuine/combinatoric - /// If both clusters have some known SimTrack content - /// they must be compared to each other - if ( theClusters.at(0)->isGenuine() && theClusters.at(1)->isGenuine() ) - { - if ( theClusters.at(0)->findSimTrackId() == theClusters.at(1)->findSimTrackId() ) - /// Two genuine clusters with same SimTrack content mean genuine - return false; - else - return true; - } - else - { - /// Here, at least one cluster is combinatoric - int prevTrack = -99999; // SimTrackId storage - std::vector< edm::Ptr< SimTrack > > innerSimTracks = theClusters.at(0)->getSimTrackPtrs(); - std::vector< edm::Ptr< SimTrack > > outerSimTracks = theClusters.at(1)->getSimTrackPtrs(); - for ( unsigned int i = 0; i < innerSimTracks.size(); i++ ) - { - /// Skip NULL pointers - if ( innerSimTracks.at(i).isNull() ) - continue; - for ( unsigned int j = 0; j < outerSimTracks.size(); j++ ) - { - /// Skip NULL pointers - if ( outerSimTracks.at(j).isNull() ) - continue; - - if ( innerSimTracks.at(i)->trackId() == outerSimTracks.at(j)->trackId() ) - { - /// Same SimTrack is present in both clusters - if ( prevTrack < 0 ) - prevTrack = outerSimTracks.at(j)->trackId(); - - if ( prevTrack != (int)outerSimTracks.at(j)->trackId() ) - /// If two different SimTracks are found in both clusters, - /// then the stub is for sure combinatoric - return true; - } - } - } - if ( prevTrack < 0 ) - /// No common SimTracks were found to be in both clusters - return true; - else - /// Only one SimTrack was found to be present in both clusters - /// even if one of the clusters (or both) are combinatoric: - /// this means there is only one track that participates in - /// both clusters, hence the stub is genuine - return false; - } - } - /// Default - /// Should never get here - std::cerr << "W A R N I N G! L1TkStub::isCombinatoric() \t we should never get here" << std::endl; - return false; - */ - - if ( this->isUnknown() ) - return false; - - return true; - } - - template< typename T > - bool L1TkStub< T >::isUnknown() const - { - /// UNKNOWN means that both clusters are unknown - /// ... but if they are both unknown and from different EventId, this is COMBINATORIC! - if ( theClusters.at(0)->isUnknown() && theClusters.at(1)->isUnknown() ) - { - if ( theClusters.at(0)->getEventIds().at(0) == theClusters.at(1)->getEventIds().at(0) ) - return true; /// both UNKNOWN from the same EventId - } - - /// If either one is known OR both unknown from different Event Id's - return false; - } - - template< typename T > - int L1TkStub< T >::findType() const - { - if ( theSimTrack.isNull() ) - return 999999999; - return theSimTrack->type(); - } - - template< typename T > - unsigned int L1TkStub< T >::findSimTrackId() const - { - if ( theSimTrack.isNull() ) - return 0; - return theSimTrack->trackId(); - } - - /// Collect MC truth - template< typename T > - void L1TkStub< T >::checkSimTrack() - { - /// This method is based on the early version of - /// isGenuine >>> same approach to store the SimTrack - - /// GENUINE for clusters means not combinatoric and - /// not unknown: same MC truth content MUST be found - /// in both clusters composing the stub - if ( theClusters.at(0)->isUnknown() || theClusters.at(1)->isUnknown() ) - /// If at least one cluster is unknown, it means - /// either unknown, either combinatoric - /// Do nothing, leave the default NULL - return; - - else - { - /// Here both are clusters are genuine/combinatoric - /// If both clusters have some known SimTrack content - /// they must be compared to each other - if ( theClusters.at(0)->isGenuine() && theClusters.at(1)->isGenuine() ) - { - /// The clusters must be associated to the same event - if ( theClusters.at(0)->getEventIds().at(0) != theClusters.at(1)->getEventIds().at(0) ) - return; - - if ( theClusters.at(0)->findSimTrackId() == theClusters.at(1)->findSimTrackId() ) - { - /// Two genuine clusters with same SimTrack content mean genuine - std::vector< edm::Ptr< SimTrack > > curSimTracks = theClusters.at(0)->getSimTrackPtrs(); - for ( unsigned int k = 0; k < curSimTracks.size(); k++ ) - { - if ( curSimTracks.at(k).isNull() == false ) - { - theSimTrack = curSimTracks.at(k); - theEventId = theClusters.at(0)->getEventIds().at(0); - return; - } - } - } - else - return; - } - else - { - /// Here, at least one cluster is combinatoric - int prevTrack = -99999; // SimTrackId storage - unsigned int whichSimTrack = 0; - std::vector< edm::Ptr< SimTrack > > innerSimTracks = theClusters.at(0)->getSimTrackPtrs(); - std::vector< edm::Ptr< SimTrack > > outerSimTracks = theClusters.at(1)->getSimTrackPtrs(); - std::vector< uint32_t > innerEventIds = theClusters.at(0)->getEventIds(); - std::vector< uint32_t > outerEventIds = theClusters.at(1)->getEventIds(); - - for ( unsigned int i = 0; i < innerSimTracks.size(); i++ ) - { - /// Skip NULL pointers - if ( innerSimTracks.at(i).isNull() ) - continue; - - for ( unsigned int j = 0; j < outerSimTracks.size(); j++ ) - { - /// Skip NULL pointers - if ( outerSimTracks.at(j).isNull() ) - continue; - - /// Skip pairs from different EventId - if ( innerEventIds.at(i) != outerEventIds.at(j) ) - continue; - - if ( innerSimTracks.at(i)->trackId() == outerSimTracks.at(j)->trackId() ) - { - /// Same SimTrack is present in both clusters - if ( prevTrack < 0 ) - { - prevTrack = outerSimTracks.at(j)->trackId(); - whichSimTrack = j; - } - - if ( prevTrack != (int)outerSimTracks.at(j)->trackId() ) - /// If two different SimTracks are found in both clusters, - /// then the stub is for sure combinatoric - return; - } - } - } - if ( prevTrack < 0 ) - /// No SimTracks were found to be in both clusters - return; - else - /// Only one SimTrack was found to be present in both clusters - /// even if one of the clusters (or both) are combinatoric: - /// this means there is only one track that participates in - /// both clusters, hence the stub is genuine - theSimTrack = outerSimTracks.at(whichSimTrack); - theEventId = outerEventIds.at(whichSimTrack); /// Same indexing! - } - } - } - - - /// Information - template< typename T > - std::string L1TkStub< T >::print( unsigned int i ) const - { - std::string padding(""); - for ( unsigned int j=0; j!=i; ++j ) - padding+="\t"; - std::stringstream output; - output< > >::const_iterator clusIter; - for ( clusIter = theClusters.begin(); clusIter!= theClusters.end(); ++clusIter ) - output << padding << "cluster: " << iClu++ << ", member: " << (*clusIter)->getStackMember() << ", cluster size: " << (*clusIter)->getHits().size() << '\n'; - return output.str(); - } - - template< typename T > - std::ostream& operator << (std::ostream& os, const L1TkStub< T >& aL1TkStub) { return ( os< -class L1TkTrack -{ - private: - /// Data members - std::vector< edm::Ptr< L1TkStub< T > > > theStubPtrs; - GlobalVector theMomentum; - GlobalPoint theVertex; - double theRInv; - unsigned int theSector; - unsigned int theWedge; - double theChi2; - edm::Ptr< SimTrack > theSimTrack; - uint32_t theEventId; - - public: - /// Constructors - L1TkTrack(); - L1TkTrack( std::vector< edm::Ptr< L1TkStub< T > > > aStubs ); - - /// Destructor - ~L1TkTrack(); - - /// Track components - std::vector< edm::Ptr< L1TkStub< T > > > getStubPtrs() const { return theStubPtrs; } - void addStubPtr( edm::Ptr< L1TkStub< T > > aStub ); - - /// Track momentum - GlobalVector getMomentum() const { return theMomentum; } - void setMomentum( GlobalVector aMomentum ); - - /// Track parameters - double getRInv() const { return theRInv; } - void setRInv( double aRInv ); - - /// Vertex - GlobalPoint getVertex() const { return theVertex; } - void setVertex( GlobalPoint aVertex ); - - /// Sector - unsigned int getSector() const { return theSector; } - void setSector( unsigned int aSector ); - unsigned int getWedge() const { return theWedge; } - void setWedge( unsigned int aWedge ); - - /// Chi2 - double getChi2() const { return theChi2; } - double getChi2Red() const; - void setChi2( double aChi2 ); - - /// MC Truth - edm::Ptr< SimTrack > getSimTrackPtr() const { return theSimTrack; } - uint32_t getEventId() const { return theEventId; } - bool isGenuine() const; - bool isCombinatoric() const; - bool isUnknown() const; - int findType() const; - unsigned int findSimTrackId() const; - - /// Superstrip - /// Here to prepare inclusion of AM L1 Track finding - uint32_t getSuperStrip() const { return 0; } - - /// ////////////// /// - /// HELPER METHODS /// - bool isTheSameAs( L1TkTrack< T > aTrack ) const; - - /// Fake or not - void checkSimTrack(); - - /// Tricky Fit as suggested by Pierluigi, employing - /// a tracklet-style approach for triplets within - /// the chain of stubs composing the track -// void fitTrack( double aMagneticFieldStrength, bool useAlsoVtx, bool aDoHelixFit ); - - /// /////////////////// /// - /// INFORMATIVE METHODS /// -// std::string print( unsigned int i=0 ) const; - -}; /// Close class - -/** ***************************** **/ -/** **/ -/** IMPLEMENTATION OF METHODS **/ -/** **/ -/** ***************************** **/ - -/// Default Constructor -template< typename T > -L1TkTrack< T >::L1TkTrack() -{ - theStubPtrs.clear(); - theMomentum = GlobalVector(0.0,0.0,0.0); - theRInv = 0; - theVertex = GlobalPoint(0.0,0.0,0.0); - theSector = 0; - theWedge = 0; - theChi2 = 0; - /// theSimTrack is NULL by default - theEventId = 0xFFFF; -} - -/// Another Constructor -template< typename T > -L1TkTrack< T >::L1TkTrack( std::vector< edm::Ptr< L1TkStub< T > > > aStubs ) -{ - theStubPtrs = aStubs; - theMomentum = GlobalVector(0.0,0.0,0.0); - theVertex = GlobalPoint(0.0,0.0,0.0); - theRInv = 0; - theSector = 0; - theWedge = 0; - theChi2 = 0; - /// theSimTrack is NULL by default - theEventId = 0xFFFF; -} - -/// Destructor -template< typename T > -L1TkTrack< T >::~L1TkTrack(){} - -/// Track components -template< typename T > -void L1TkTrack< T >::addStubPtr( edm::Ptr< L1TkStub< T > > aStub ) -{ - theStubPtrs.push_back( aStub ); -} - -/// Track momentum -template< typename T > -void L1TkTrack< T >::setMomentum( GlobalVector aMomentum ) -{ - theMomentum = aMomentum; -} - -/// Vertex -template< typename T > -void L1TkTrack< T >::setVertex( GlobalPoint aVertex ) -{ - theVertex = aVertex; -} - -/// Track parameters -template< typename T > -void L1TkTrack< T >::setRInv( double aRInv ) -{ - theRInv = aRInv; -} - -/// Sector -template< typename T > -void L1TkTrack< T >::setSector( unsigned int aSector ) -{ - theSector = aSector; -} - -template< typename T > -void L1TkTrack< T >::setWedge( unsigned int aWedge ) -{ - theWedge = aWedge; -} - -/// Chi2 -template< typename T > -double L1TkTrack< T >::getChi2Red() const { return theChi2/( 2*theStubPtrs.size() - 4 ); } - -template< typename T > -void L1TkTrack< T >::setChi2( double aChi2 ) -{ - theChi2 = aChi2; -} - -// MC truth -template< typename T > -int L1TkTrack< T >::findType() const -{ - if ( theSimTrack.isNull() ) - return 999999999; - return theSimTrack->type(); -} - -template< typename T > -unsigned int L1TkTrack< T >::findSimTrackId() const -{ - if ( theSimTrack.isNull() ) - return 0; - return theSimTrack->trackId(); -} - -/// ////////////// /// -/// HELPER METHODS /// -/// ////////////// /// - -/// Check if two tracks are the same -template< typename T> -bool L1TkTrack< T >::isTheSameAs( L1TkTrack< T > aTrack ) const -{ - /// Take the other stubs - std::vector< edm::Ptr< L1TkStub< T > > > otherStubPtrs = aTrack.getStubPtrs(); - - /// Count shared stubs - unsigned int nShared = 0; - for ( unsigned int i = 0; i < theStubPtrs.size() && nShared < 2; i++) - { - for ( unsigned int j = 0; j < otherStubPtrs.size() && nShared < 2; j++) - { - if ( theStubPtrs.at(i) == otherStubPtrs.at(j) ) - { - nShared++; - } - } - } - - /// Same track if 2 shared stubs - return ( nShared > 1 ); -} - -/// Check SimTracks -template< typename T > -void L1TkTrack< T >::checkSimTrack() -{ - /// Vector to store SimTracks - std::vector< edm::Ptr< SimTrack > > tempVecGen; - std::vector< std::vector< edm::Ptr< SimTrack > > > tempVecComb; - std::vector< uint32_t > evIdGen; - std::vector< std::vector< uint32_t > > evIdComb; - - /// Loop over the Stubs - /// Put the SimTracks together - /// SimTracks from genuine stubs in one container - /// SimTracks from combinatoric stubs in another container - for ( unsigned int js = 0; js < theStubPtrs.size(); js++ ) - { - /// If one Stub is unknown, also the Track is unknown - if ( theStubPtrs.at(js)->isUnknown() ) - return; - - /// Store SimTracks for non-unknown Stubs - if ( theStubPtrs.at(js)->isGenuine() ) - { - tempVecGen.push_back( theStubPtrs.at(js)->getSimTrackPtr() ); - evIdGen.push_back( theStubPtrs.at(js)->getEventId() ); - } - else if ( theStubPtrs.at(js)->isCombinatoric() ) - { - for ( unsigned int ic = 0; ic < 2; ic++ ) - { - std::vector< edm::Ptr< SimTrack > > cluVec = theStubPtrs.at(js)->getClusterPtrs().at(ic)->getSimTrackPtrs(); - tempVecComb.push_back( cluVec ); - std::vector< uint32_t > evVec = theStubPtrs.at(js)->getClusterPtrs().at(ic)->getEventIds(); - evIdComb.push_back( evVec ); - } - } - } - - if ( 2*tempVecGen.size() + tempVecComb.size() != 2*theStubPtrs.size() ) - { - std::cerr << "ERROR!!! HERE WE ARE SUPPOSED TO HAVE ONLY GENUINE AND COMBINATORIAL STUBS" << std::endl; - std::cerr << theStubPtrs.size() << " = " << tempVecGen.size() << " + " << tempVecComb.size()/2 << std::endl; - return; - } - - if ( tempVecComb.size() % 2 != 0 ) - { - std::cerr << "ERROR!!! NO ODD NUMBER OF CLUSTERS FROM COMBINATORIAL STUBS IS SUPPOSED TO BE" << std::endl; - return; - } - - /// If we got here, it means that all the Stubs are genuine/combinatoric - /// COMBINATORIC means that no common SimTrack can be found - /// GENUINE means otherwise - int idSimTrackG = -99999; - uint32_t evIdG = 0xFFFF; - - if ( tempVecGen.size() > 0 ) - { - /// Case of >=1 genuine Stubs - idSimTrackG = tempVecGen.at(0)->trackId(); - evIdG = evIdGen.at(0); - - for ( unsigned int jg = 1; jg < tempVecGen.size(); jg++ ) - { - /// Two genuine Stubs with different EventId mean COMBINATORIC - if ( evIdGen.at(0) != evIdG ) - return; - - /// Two genuine Stubs with different SimTrack mean COMBINATORIC - if ( (int)(tempVecGen.at(0)->trackId()) != idSimTrackG ) - return; - } - - /// If we got here, it means that all the genuine Stubs have the same SimTrack - /// Time to check the combinatoric ones - - /// Case of no combinatoric Stubs - if ( tempVecComb.size() == 0 ) - { - /// No combinatoric stubs found - /// All genuine, all the same SimTrack - theSimTrack = tempVecGen.at(0); - theEventId = evIdGen.at(0); - return; - } - - /// Case of at least 1 Stub is combinatoric - /// If we are here, we must have EVEN tempVecComb.size() - for ( unsigned int jc1 = 0; jc1 < tempVecComb.size(); jc1+=2 ) - { - bool foundSimTrack = false; - /// Check first cluster (see how they are pushed_back) - for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1).size() && !foundSimTrack; jc0++ ) - { - if ( tempVecComb.at(jc1).at(jc0).isNull() ) - continue; - - if ( (int)(tempVecComb.at(jc1).at(jc0)->trackId()) == idSimTrackG && - evIdComb.at(jc1).at(jc0) == evIdG ) - { - foundSimTrack = true; - } - } - /// Check second cluster - for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1+1).size() && !foundSimTrack; jc0++ ) - { - if ( tempVecComb.at(jc1+1).at(jc0).isNull() ) - continue; - - if ( (int)(tempVecComb.at(jc1+1).at(jc0)->trackId()) == idSimTrackG && - evIdComb.at(jc1+1).at(jc0) == evIdG ) - { - foundSimTrack = true; - } - } - - if ( !foundSimTrack ) - return; - - /// If we got here, we have >= 1 genuine Stub whose SimTrack - /// is found in at least 1 Cluster of all other Stubs - theSimTrack = tempVecGen.at(0); - theEventId = evIdGen.at(0); - return; - } - } - else - { - /// No genuine Stubs are found - if ( tempVecComb.size() == 0 ) - { - std::cerr << "YOU SHOULD NEVER GET HERE (0 Genuine and 0 Combinatoric Stubs in a Track)" << std::endl; - return; - } - else if ( tempVecComb.size() == 1 ) - { - std::cerr << "YOU SHOULD NEVER GET HERE (0 Genuine and 1 Combinatoric Stubs in a Track)" << std::endl; - return; - } - - /// We have only combinatoric Stubs - /// We need to have the same SimTrack in all Stubs - /// If we are here, we must have EVEN tempVecComb.size() - /// Map by SimTrackId all the SimTracks and count in how many Stubs they are - std::map< std::pair< unsigned int, uint32_t >, std::vector< unsigned int > > mapSimTrack; - - for ( unsigned int jc1 = 0; jc1 < tempVecComb.size(); jc1+=2 ) - { - /// Check first cluster (see how they are pushed_back) - for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1).size(); jc0++ ) - { - if ( tempVecComb.at(jc1).at(jc0).isNull() ) - continue; - - std::pair< unsigned int, uint32_t > thisId = std::make_pair( tempVecComb.at(jc1).at(jc0)->trackId(), evIdComb.at(jc1).at(jc0) ); - - if ( mapSimTrack.find( thisId ) == mapSimTrack.end() ) - { - /// New SimTrack - /// Push back which Stub idx it is within the Combinatorial ones - std::vector< unsigned int > tempVecStubIdx; - tempVecStubIdx.push_back( jc1/2 ); - mapSimTrack.insert( std::make_pair( thisId, tempVecStubIdx ) ); - } - else - { - /// Existing SimTrack - /// Push back which Stub idx it is within the Combinatorial ones - mapSimTrack.find( thisId )->second.push_back( jc1/2 ); - } - } - /// Check second cluster - for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1+1).size(); jc0++ ) - { - if ( tempVecComb.at(jc1+1).at(jc0).isNull() ) - continue; - - std::pair< unsigned int, uint32_t > thisId = std::make_pair( tempVecComb.at(jc1+1).at(jc0)->trackId(), evIdComb.at(jc1+1).at(jc0) ); - - if ( mapSimTrack.find( thisId ) == mapSimTrack.end() ) - { - /// New SimTrack - /// Push back which Stub idx it is within the Combinatorial ones - std::vector< unsigned int > tempVecStubIdx; - tempVecStubIdx.push_back( jc1/2 ); - mapSimTrack.insert( std::make_pair( thisId, tempVecStubIdx ) ); - } - else - { - /// Existing SimTrack - /// Push back which Stub idx it is within the Combinatorial ones - mapSimTrack.find( thisId )->second.push_back( jc1/2 ); - } - } - } - - /// Check the SimTrack Map - unsigned int countSimTracks = 0; - unsigned int theSimTrackId = 0; - uint32_t theStoredEventId = 0xFFFF; - std::map< std::pair< unsigned int, uint32_t >, std::vector< unsigned int > >::iterator mapIt; - for ( mapIt = mapSimTrack.begin(); - mapIt != mapSimTrack.end(); - ++mapIt ) - { - /// SimTracks found in 1 Cluster of ALL stubs - /// This means that counting the number of different occurencies in the - /// vector one should get the size of the vector of Stubs in the track - /// So, sort and remove duplicates - std::vector< unsigned int > tempVector = mapIt->second; - std::sort( tempVector.begin(), tempVector.end() ); - tempVector.erase( std::unique( tempVector.begin(), tempVector.end() ), tempVector.end() ); - - if ( tempVector.size() == theStubPtrs.size() ) - { - countSimTracks++; - theSimTrackId = mapIt->first.first; - theStoredEventId = mapIt->first.second; - } - } - - /// We want only 1 SimTrack! - if ( countSimTracks != 1 ) - return; - - /// We can look for the SimTrack now ... - /// By construction, it must be in the first Stub ... - /// Check first cluster (see how they are pushed_back) - for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(0).size(); jc0++ ) - { - if ( tempVecComb.at(0).at(jc0).isNull() ) - continue; - - if ( theSimTrackId == tempVecComb.at(0).at(jc0)->trackId() && - theStoredEventId == evIdComb.at(0).at(jc0) ) - { - theSimTrack = tempVecComb.at(0).at(jc0); - theEventId = evIdComb.at(0).at(jc0); - return; - } - } - - /// Check second cluster - for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(1).size(); jc0++ ) - { - if ( tempVecComb.at(1).at(jc0).isNull() ) - continue; - - if ( theSimTrackId == tempVecComb.at(1).at(jc0)->trackId() && - theStoredEventId == evIdComb.at(1).at(jc0) ) - { - theSimTrack = tempVecComb.at(1).at(jc0); - theEventId = evIdComb.at(1).at(jc0); - return; - } - } - } /// End of no genuine stubs are found - - std::cerr << "YOU SHOULD NEVER GET HERE (all cases MUST have been processed earlier)" << std::endl; - -} - -template< typename T > -bool L1TkTrack< T >::isUnknown() const -{ - /// UNKNOWN means that at least 1 Stub is UNKNOWN - - /// Loop over the stubs - for ( unsigned int js = 0; js < theStubPtrs.size(); js++ ) - { - /// If one Stub is unknown, also the Track is unknown - if ( theStubPtrs.at(js)->isUnknown() ) - return true; - } - return false; -} - - -template< typename T > -bool L1TkTrack< T >::isGenuine() const -{ - /// GENUINE means that we could set a SimTrack - if ( theSimTrack.isNull() == false ) - return true; - - return false; -} - - -template< typename T > -bool L1TkTrack< T >::isCombinatoric() const -{ - if ( this->isGenuine() ) - return false; - - if ( this->isUnknown() ) - return false; - - return true; -} - - - -/* - /// Fit - template< typename T > - void L1TkTrack< T >::fitTrack( double aMagneticFieldStrength, bool useAlsoVtx, bool aDoHelixFit ) - { - /// Step 00 - /// Get the magnetic field - /// Usually it is done like the following three lines - //iSetup.get().get(magnet); - //magnet_ = magnet.product(); - //mMagneticFieldStrength = magnet_->inTesla(GlobalPoint(0,0,0)).z(); - /// Calculate factor for rough Pt estimate - /// B rounded to 4.0 or 3.8 - /// This is B * C / 2 * appropriate power of 10 - /// So it's B * 0.0015 - double mPtFactor = (floor(aMagneticFieldStrength*10.0 + 0.5))/10.0*0.0015; - - /// Step 0 - /// Get Stubs chain and Vertex - std::vector< L1TkStub< T > > brickStubs = this->getStubs(); - L1TkTracklet< T > seedTracklet = this->getSeedTracklet(); - /// This automatically sets 00 or beamspot according to L1TkTracklet type - GlobalPoint seedVertexXY = GlobalPoint( seedTracklet.getVertex().x(), seedTracklet.getVertex().y(), 0.0 ); - - /// If the seed vertex is requested for the fit, add it to stubs - if ( useAlsoVtx ) { - /// Prepare dummy stub with vertex position - std::vector< L1TkStub< T > > auxStubs; - auxStubs.clear(); - L1TkStub< T > dummyStub = L1TkStub< T >( 0 ); - -// dummyStub.setPosition( seedTracklet.getVertex() ); -// dummyStub.setDirection( GlobalVector(0,0,0) ); - - auxStubs.push_back( dummyStub ); - /// Put together also other stubs - for ( unsigned int j = 0; j < brickStubs.size(); j++ ) auxStubs.push_back( brickStubs.at(j) ); - /// Overwrite - brickStubs = auxStubs; - } -*/ - - - -/* - /// Step 1 - /// Find charge using only stubs, regardless of useAlsoVtx option! - unsigned int iMin = 0; - if ( useAlsoVtx ) iMin = 1; - /// Check L1TkTracklet for further information - double outerPointPhi = brickStubs.at( brickStubs.size()-1 ).getPosition().phi(); - double innerPointPhi = brickStubs.at( iMin ).getPosition().phi(); - double deltaPhi = outerPointPhi - innerPointPhi; - if ( fabs(deltaPhi) >= KGMS_PI) { - if ( deltaPhi>0 ) deltaPhi = deltaPhi - 2*KGMS_PI; - else deltaPhi = 2*KGMS_PI - fabs(deltaPhi); - } - double deltaPhiC = deltaPhi; /// This is for charge - deltaPhi = fabs(deltaPhi); - double fCharge = -deltaPhiC / deltaPhi; - this->setCharge( fCharge ); - - /// Step 2 - /// Average for Momentum and Axis - std::vector< double > outputFitPt; outputFitPt.clear(); - std::vector< double > outputFitPz; outputFitPz.clear(); - std::vector< double > outputFitX; outputFitX.clear(); - std::vector< double > outputFitY; outputFitY.clear(); - /// Now loop over Triplets - unsigned int totalTriplets = 0; - for ( unsigned int a1 = 0; a1 < brickStubs.size(); a1++ ) { - for ( unsigned int a2 = a1+1; a2 < brickStubs.size(); a2++ ) { - for ( unsigned int a3 = a2+1; a3 < brickStubs.size(); a3++ ) { - totalTriplets++; - /// Read Stubs in a "L1TkTracklet-wise" way - GlobalPoint vtxPos = brickStubs.at(a1).getPosition(); - GlobalPoint innPos = brickStubs.at(a2).getPosition(); - GlobalPoint outPos = brickStubs.at(a3).getPosition(); - /// Correct for position of a1 - innPos = GlobalPoint( innPos.x()-vtxPos.x(), innPos.y()-vtxPos.y(), innPos.z() ); - outPos = GlobalPoint( outPos.x()-vtxPos.x(), outPos.y()-vtxPos.y(), outPos.z() ); - double outRad = outPos.perp(); - double innRad = innPos.perp(); - deltaPhi = outPos.phi() - innPos.phi(); /// NOTE overwrite already declared deltaPhi - if ( fabs(deltaPhi) >= KGMS_PI ) { - if ( deltaPhi>0 ) deltaPhi = deltaPhi - 2*KGMS_PI; - else deltaPhi = 2*KGMS_PI - fabs(deltaPhi); - } - deltaPhi = fabs(deltaPhi); - double x2 = outRad * outRad + innRad * innRad - 2 * innRad * outRad * cos(deltaPhi); - double twoRadius = sqrt(x2) / sin(fabs(deltaPhi)); - double roughPt = mPtFactor * twoRadius; - double roughPz; - /// Switch fit type - if ( !aDoHelixFit ) roughPz = roughPt * (outPos.z()-innPos.z()) / (outRad-innRad); - else { - double phioi = acos(1 - 2*x2/(twoRadius*twoRadius)); - if ( fabs(phioi) >= KGMS_PI ) { - if ( phioi>0 ) phioi = phioi - 2*KGMS_PI; - else phioi = 2*KGMS_PI - fabs(phioi); - } - if ( phioi == 0 ) return; - roughPz = 2 * mPtFactor * (outPos.z()-innPos.z()) / fabs(phioi); - } - /// Store Momenta for average - outputFitPt.push_back( roughPt ); - outputFitPz.push_back( roughPz ); - /// Find angle from a1 pointing to Axis - double vertexangle = acos( outRad/twoRadius ); - vertexangle = outPos.phi() - fCharge * vertexangle; - /// Helix axis - outputFitX.push_back( 0.5 * twoRadius * cos(vertexangle) + vtxPos.x() ); - outputFitY.push_back( 0.5 * twoRadius * sin(vertexangle) + vtxPos.y() ); - } /// End of loop over third element - } /// End of loop over second element - } /// End of loop over first element - /// Compute averages and store them - double tempOutputX = 0; - double tempOutputY = 0; - double tempOutputPt = 0; - double tempOutputPz = 0; - for ( unsigned int q = 0; q < totalTriplets; q++ ) { - tempOutputX += outputFitX.at(q); - tempOutputY += outputFitY.at(q); - tempOutputPt += outputFitPt.at(q); - tempOutputPz += outputFitPz.at(q); - } - - /// Step 3 - /// Get Helix Axis and correct wrt Seed VTX - GlobalPoint fAxis = GlobalPoint( tempOutputX/totalTriplets, tempOutputY/totalTriplets, 0.0 ); - GlobalPoint fAxisCorr = GlobalPoint( fAxis.x() - seedVertexXY.x(), fAxis.y() - seedVertexXY.y(), 0.0 ); - this->setAxis( tempOutputX/totalTriplets, tempOutputY/totalTriplets ); - - /// Step 4 - /// Momentum, starting from azimuth at vertex - double fPhiV = atan2( fCharge*fAxisCorr.x(), -fCharge*fAxisCorr.y() ); - double fPt = tempOutputPt/totalTriplets; - double fPz = tempOutputPz/totalTriplets; - double fRadius = 0.5*fPt/mPtFactor; - GlobalVector fMomentum = GlobalVector( cos(fPhiV)*fPt, sin(fPhiV)*fPt, fPz ); - this->setMomentum( fMomentum ); - - /// Step 5 - /// Average for Vertex (Closest Approach) - double rMinAppr = fAxisCorr.perp() - fRadius; - double xMinAppr = rMinAppr*cos( fAxisCorr.phi() ) + seedVertexXY.x(); - double yMinAppr = rMinAppr*sin( fAxisCorr.phi() ) + seedVertexXY.y(); - GlobalPoint tempVertex = GlobalPoint( xMinAppr, yMinAppr, 0.0 ); - double propFactorHel = 0; - double offsetHel = 0; - /// Average for Vtx z - std::vector< double > outputFitZ; outputFitZ.clear(); - /// Now loop over Doublets - /// Cannot put into the same loop as before because - /// here we need radius and therefore Pt to have - /// the radius, and the radius is needed to find the - /// closest approach distance, is it clear? - unsigned int totalDoublets = 0; - for ( unsigned int a1 = iMin; a1 < brickStubs.size(); a1++) { /// iMin already set according to useAlsoVtx or not - for ( unsigned int a2 = a1+1; a2 < brickStubs.size(); a2++) { - totalDoublets++; - /// Read Stubs in a "L1TkTracklet-wise" way - GlobalPoint innPos = brickStubs.at(a1).getPosition(); - GlobalPoint outPos = brickStubs.at(a2).getPosition(); - /// Calculate z = z0 + c*phiStar - GlobalPoint innPosStar = GlobalPoint( innPos.x() - fAxis.x(), innPos.y() - fAxis.y(), innPos.z() - fAxis.z() ); - GlobalPoint outPosStar = GlobalPoint( outPos.x() - fAxis.x(), outPos.y() - fAxis.y(), outPos.z() - fAxis.z() ); - double deltaPhiStar = outPosStar.phi() - innPosStar.phi(); - if ( fabs(deltaPhiStar) >= KGMS_PI ) { - if ( outPosStar.phi() < 0 ) deltaPhiStar += KGMS_PI; - else deltaPhiStar -= KGMS_PI; - if ( innPosStar.phi() < 0 ) deltaPhiStar -= KGMS_PI; - else deltaPhiStar += KGMS_PI; - } - if ( deltaPhiStar == 0 ) std::cerr<<"BIG PROBLEM IN DELTAPHI DENOMINATOR"<= KGMS_PI ) { - if ( deltaPhi>0 ) deltaPhi = deltaPhi - 2*KGMS_PI; - else deltaPhi = 2*KGMS_PI - fabs(deltaPhi); - } - deltaPhi = fabs(deltaPhi); - double x2 = outRad * outRad + innRad * innRad - 2 * innRad * outRad * cos(deltaPhi); - double twoRadius = sqrt(x2) / sin(fabs(deltaPhi)); - double zProj; - /// Switch fit type - if ( !aDoHelixFit ) zProj = outPos.z() - ( outRad * (outPos.z() - innPos.z()) / (outRad - innRad) ); - else { - double phioi = acos(1 - 2*x2/(twoRadius*twoRadius)); - double phiiv = acos(1 - 2*innRad*innRad/(twoRadius*twoRadius)); - if ( fabs(phioi) >= KGMS_PI ) { - if ( phioi>0 ) phioi = phioi - 2*KGMS_PI; - else phioi = 2*KGMS_PI - fabs(phioi); - } - if ( fabs(phiiv) >= KGMS_PI ) { - if ( phiiv>0 ) phiiv = phiiv - 2*KGMS_PI; - else phiiv = 2*KGMS_PI - fabs(phiiv); - } - if ( phioi == 0 ) return; - /// Vertex - zProj = innPos.z() - (outPos.z()-innPos.z())*phiiv/phioi; - } - outputFitZ.push_back( zProj ); - } /// End of loop over second element - } /// End of loop over first element - /// Compute averages and store them - double tempOutputZ = 0; - for ( unsigned int q = 0; q < totalDoublets; q++ ) tempOutputZ += outputFitZ.at(q); - double zMinAppr = tempOutputZ/totalDoublets; - - /// Step 6 - /// Vertex - GlobalPoint fVertex = GlobalPoint( xMinAppr, yMinAppr, zMinAppr ); - this->setVertex( fVertex ); - - - /// Step 7 - /// Calculate Chi2 - propFactorHel = propFactorHel/totalDoublets; - offsetHel = offsetHel/totalDoublets; - double fChi2RPhi = 0; - double fChi2ZPhi = 0; - double tempStep; - /// Calculate for the Seed VTX if needed - if (useAlsoVtx) { - GlobalPoint posPoint = seedTracklet.getVertex(); - GlobalPoint posPointCorr = GlobalPoint( posPoint.x() - fAxis.x(), posPoint.y() - fAxis.y(), posPoint.z() ); - /// Add X: x_meas - x_fit(phi*_meas) - tempStep = posPoint.x() - fAxis.x() - fRadius * cos( posPointCorr.phi() ); - fChi2RPhi += tempStep*tempStep; - /// Add Y: y_meas - y_fit(phi*_meas) - tempStep = posPoint.y() - fAxis.y() - fRadius * sin( posPointCorr.phi() ); - fChi2RPhi += tempStep*tempStep; - /// b = propFactorH - /// a = offsetH - /// z = b*phi - a - /// Add Z: z_meas - z_fit(phi*_meas) - tempStep = posPoint.z() - offsetHel - propFactorHel * posPointCorr.phi(); - fChi2ZPhi += tempStep*tempStep; - } - /// Calculate for all other Stubs - for ( unsigned int a = iMin; a < brickStubs.size(); a++ ) { - GlobalPoint posPoint = brickStubs.at(a).getPosition(); - GlobalPoint posPointCorr = GlobalPoint( posPoint.x() - fAxis.x(), posPoint.y() - fAxis.y(), posPoint.z() ); - - tempStep = posPoint.x() - fAxis.x() - fRadius * cos( posPointCorr.phi() ); - fChi2RPhi += tempStep*tempStep; - tempStep = posPoint.y() - fAxis.y() - fRadius * sin( posPointCorr.phi() ); - fChi2RPhi += tempStep*tempStep; - - tempStep = posPoint.z() - offsetHel - propFactorHel * posPointCorr.phi(); - fChi2ZPhi += tempStep*tempStep; - } - this->setChi2RPhi( fChi2RPhi ); - this->setChi2ZPhi( fChi2ZPhi ); - -*/ - - - -/* - } - - - - /// /////////////////// /// - /// INFORMATIVE METHODS /// - /// /////////////////// /// - - template< typename T > - std::string L1TkTrack< T >::print( unsigned int i ) const { - std::string padding(""); - for ( unsigned int j=0; j!=i; ++j )padding+="\t"; - std::stringstream output; - output<getSeedDoubleStack() << '\n'; - output << padding << "Length of Chain: " << theBrickStubs.size() << '\n'; - unsigned int iStub = 0; - for ( L1TkStubPtrCollectionIterator i = theBrickStubs.begin(); i!= theBrickStubs.end(); ++i ) - output << padding << "stub: " << iStub++ << ", stack: \n";// << (*i)->getStack() << ", rough Pt: " << '\n';//(*i)->getRoughPt() << '\n'; - return output.str(); - } - - template< typename T > - std::ostream& operator << (std::ostream& os, const L1TkTrack< T >& aL1TkTrack) { - return (os< -#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" -#include "SimDataFormats/SLHC/interface/L1CaloTower.h" - - -namespace l1slhc -{ - - class L1TowerJet - { - - public: - - enum tJetShape - { - square, - circle - }; - - public: - - L1TowerJet( ); - L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea ); - L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea , const int& iEta, const int& iPhi); - ~L1TowerJet( ); - - // getters - const int& iEta( ) const; - const int& iPhi( ) const; - const int& E( ) const; - const bool& central( ) const; - - //asymmetry member variables - const int& AsymEta( ) const; - const int& AsymPhi( ) const; - - //weighted iEta, iPhi - const double& iWeightedEta( ) const; - const double& iWeightedPhi( ) const; - - const double& WeightedEta( ) const; - const double& WeightedPhi( ) const; - - const math::PtEtaPhiMLorentzVector& p4( ) const; // returns LorentzVector in eta,phi space - const int& JetSize( ) const; - const L1TowerJet::tJetShape& JetShape( ) const; - - const int& JetArea( ) const; - -// possibly helpful methods -// double EcalVariance( ) const; -// double HcalVariance( ) const; -// double EnergyVariance( ) const; - - double EcalMAD() const; - double HcalMAD() const; - double EnergyMAD() const; - - // Setters - - void setP4( const math::PtEtaPhiMLorentzVector & p4 ); - void setCentral( const bool& ); -// void setE( const int& ); - - void CalcWeightediEta(); - void CalcWeightediPhi(); - - void calculateWeightedEta( ); - void calculateWeightedPhi(); - - - - - void addConstituent( const L1CaloTowerRef & Tower ); - L1CaloTowerRefVector::iterator getConstituent( const int& eta , const int& phi ); - void removeConstituent( const int& eta , const int& phi ); - - const L1CaloTowerRefVector& getConstituents( ) const; - - - - private: - int mIeta; - int mIphi; - int mE; - bool mCentral; - - //add asym - int mAsymEta; - int mAsymPhi; - - //weighted eta and phi - double mWeightedIeta; - double mWeightedIphi; - double mWeightedEta; - double mWeightedPhi; - - - int mJetSize; - L1TowerJet::tJetShape mJetShapeType; - int mJetArea; - - - L1CaloTowerRefVector mConstituents; - math::PtEtaPhiMLorentzVector mP4; - - - double MAD( std::deque& aDataSet ) const; - - }; - - -} - - -// Sorting functor -namespace std{ - bool operator< ( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ); -} - - -std::ostream & operator<<( std::ostream & , const l1slhc::L1TowerJet & ); - -#endif diff --git a/SimDataFormats/SLHC/interface/L1TowerJetFwd.h b/SimDataFormats/SLHC/interface/L1TowerJetFwd.h deleted file mode 100644 index 5a44cd0a3998e..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TowerJetFwd.h +++ /dev/null @@ -1,21 +0,0 @@ -#ifndef L1TowerJet_Fwd -#define L1TowerJet_Fwd - - -#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" -#include "DataFormats/Common/interface/Ref.h" -#include - -namespace l1slhc -{ - class L1TowerJet; -} - -namespace l1slhc -{ - typedef EtaPhiContainer < L1TowerJet > L1TowerJetCollection; - - typedef edm::Ref < L1TowerJetCollection > L1TowerJetRef; -} - -#endif diff --git a/SimDataFormats/SLHC/interface/L1TowerNav.h b/SimDataFormats/SLHC/interface/L1TowerNav.h deleted file mode 100644 index 29333c633c97b..0000000000000 --- a/SimDataFormats/SLHC/interface/L1TowerNav.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef SimDataFormats_SLHC_L1TowerNav -#define SimDataFormats_SLHC_L1TowerNav - -//proto type, probably should be a namespace but I might extend it -//quick dirty hack to get the towers navigating correctly - -class L1TowerNav { -public: - // static const int kNullIEta=0; //return value if offset brings it to an invalid eta position (now removed, we return invalid iEta positions - static const int kNullIPhi=0; //return value if we have an invalid phi position, note we can only achieve this if the starting iPhi is invalid - - static const int kIPhiMax=72; - static const int kIEtaAbsHEMax=28; //end of HE, useful as the phi scale changes for HF - static const int kIEtaAbsHFMax=32; //pTDR says 41 but we appear to end at 32, are we combining the high eta towers? check this! - static const int kHFIPhiScale=4; //each phi tower in HF is 4 that of HBHE - - static int getOffsetIEta(int iEta,int offset); //returns the iEta which is offset towers away form iEta - static int getOffsetIPhi(int iEta,int iPhi,int offset); //returns the iPhi which is offset towers away from iPhi, needs iEta to know if in HBHE or HF - static int getOffsetIPhiHBHE(int iPhi,int offset); - static int getOffsetIPhiHF(int iPhi,int offset); -}; - - -#endif diff --git a/SimDataFormats/SLHC/interface/StackedTrackerTypes.h b/SimDataFormats/SLHC/interface/StackedTrackerTypes.h deleted file mode 100644 index 74840de251735..0000000000000 --- a/SimDataFormats/SLHC/interface/StackedTrackerTypes.h +++ /dev/null @@ -1,83 +0,0 @@ -/// //////////////////////////////////////// -/// Stacked Tracker Simulations /// -/// Written by: /// -/// Andrew W. Rose /// -/// 2008 /// -/// /// -/// Changed by: /// -/// Nicola Pozzobon /// -/// UNIPD /// -/// 2010, Oct; 2011 July, Sep /// -/// 2013, Mar /// -/// /// -/// Added feature: /// -/// Removed (NOT commented) TTHits /// -/// (Maybe in the future they will be /// -/// reintroduced in the framework...) /// -/// Adapted to the new approach /// -/// Completed with Tracks /// -/// Cleaning while porting to 6_1_1 /// -/// //////////////////////////////////////// - -#ifndef STACKED_TRACKER_TYPES_H -#define STACKED_TRACKER_TYPES_H - -/// Specific Data Formats for Tracking Trigger -#include "SimDataFormats/SLHC/interface/L1TkCluster.h" -#include "SimDataFormats/SLHC/interface/L1TkStub.h" -#include "SimDataFormats/SLHC/interface/L1TkTrack.h" -/// Anders includes -//#include "SimDataFormats/SLHC/interface/L1TRod.hh" -//#include "SimDataFormats/SLHC/interface/L1TSector.hh" -//#include "SimDataFormats/SLHC/interface/L1TStub.hh" -//#include "SimDataFormats/SLHC/interface/L1TWord.hh" -//#include "SimDataFormats/SLHC/interface/slhcevent.hh" -//#include "SimDataFormats/SLHC/interface/L1TTracklet.hh" -//#include "SimDataFormats/SLHC/interface/L1TTracklets.hh" -//#include "SimDataFormats/SLHC/interface/L1TTrack.hh" -//#include "SimDataFormats/SLHC/interface/L1TTracks.hh" - -/// Standard CMS Formats -#include "DataFormats/Common/interface/Ref.h" -#include "DataFormats/Common/interface/Ptr.h" -#include "DataFormats/Common/interface/DetSetVector.h" -#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" -#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" - - /// The reference types - typedef edm::Ref< edm::PSimHitContainer > Ref_PSimHit_; - typedef edm::Ref< edm::DetSetVector , PixelDigi > Ref_PixelDigi_; - - /// Cluster data types - typedef L1TkCluster< Ref_PSimHit_ > L1TkCluster_PSimHit_; - typedef L1TkCluster< Ref_PixelDigi_ > L1TkCluster_PixelDigi_; - - typedef std::vector< L1TkCluster_PSimHit_ > L1TkCluster_PSimHit_Collection; - typedef std::vector< L1TkCluster_PixelDigi_ > L1TkCluster_PixelDigi_Collection; - - typedef std::map< std::pair, L1TkCluster_PSimHit_Collection > L1TkCluster_PSimHit_Map; - typedef std::map< std::pair, L1TkCluster_PixelDigi_Collection > L1TkCluster_PixelDigi_Map; - - typedef edm::Ptr< L1TkCluster_PSimHit_ > L1TkCluster_PSimHit_Pointer; - typedef edm::Ptr< L1TkCluster_PixelDigi_ > L1TkCluster_PixelDigi_Pointer; - - typedef std::vector< L1TkCluster_PSimHit_Pointer > L1TkCluster_PSimHit_Pointer_Collection; - typedef std::vector< L1TkCluster_PixelDigi_Pointer > L1TkCluster_PixelDigi_Pointer_Collection; - - /// Stub data types - typedef L1TkStub< Ref_PSimHit_ > L1TkStub_PSimHit_; - typedef L1TkStub< Ref_PixelDigi_ > L1TkStub_PixelDigi_; - - typedef std::vector< L1TkStub_PSimHit_ > L1TkStub_PSimHit_Collection; - typedef std::vector< L1TkStub_PixelDigi_ > L1TkStub_PixelDigi_Collection; - - /// Track data types - typedef L1TkTrack< Ref_PSimHit_ > L1TkTrack_PSimHit_; - typedef L1TkTrack< Ref_PixelDigi_ > L1TkTrack_PixelDigi_; - - typedef std::vector< L1TkTrack_PSimHit_ > L1TkTrack_PSimHit_Collection; - typedef std::vector< L1TkTrack_PixelDigi_ > L1TkTrack_PixelDigi_Collection; - - -#endif - diff --git a/SimDataFormats/SLHC/interface/slhcevent.hh b/SimDataFormats/SLHC/interface/slhcevent.hh deleted file mode 100755 index e170cc2ce0e2b..0000000000000 --- a/SimDataFormats/SLHC/interface/slhcevent.hh +++ /dev/null @@ -1,643 +0,0 @@ -#ifndef SLHCEVENT_H -#define SLHCEVENT_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include "L1TStub.hh" - -#define NSECTORS 28 - -using namespace std; - -//This is the number of strips in rphi and in z for a module. -//This should be in the header of the ASCII file, but for now -//just hardcoded here. - - -static double two_pi=8*atan(1.0); - -static double x_offset=0.199196*0.0; -static double y_offset=0.299922*0.0; - - - - -class L1SimTrack{ - -public: - - L1SimTrack() { - id_=-1; - } - - L1SimTrack(int id, int type, double pt, double eta, double phi, - double vx, double vy, double vz) { - id_=id; - type_=type; - pt_=pt; - eta_=eta; - phi_=phi; - vx_=vx; - vy_=vy; - vz_=vz; - } - - void write(ofstream& out){ - - out << "L1SimTrack: " - << id_ << "\t" - << type_ << "\t" - << pt_ << "\t" - << eta_ << "\t" - << phi_ << "\t" - << vx_ << "\t" - << vy_ << "\t" - << vz_ << "\t" << endl; - - } - - int id() const { return id_; } - int type() const { return type_; } - double pt() { return pt_; } - double eta() { return eta_; } - double phi() { return phi_; } - double vx() { return vx_; } - double vy() { return vy_; } - double vz() { return vz_; } - -private: - - int id_; - int type_; - double pt_; - double eta_; - double phi_; - double vx_; - double vy_; - double vz_; - -}; - - -class Digi{ - -public: - - - Digi(int layer,int irphi, int iz, int sensorlayer, - int ladder, int module, double x, double y, double z) { - layer_=layer; - irphi_=irphi; - iz_=iz; - sensorlayer_=sensorlayer; - ladder_=ladder; - module_=module; - x_=x; - y_=y; - z_=z; - } - - void AddSimtrack(int simtrackid){ - simtrackids_.push_back(simtrackid); - } - - void write(ofstream& out){ - - out << "Digi: " - << layer_ << "\t" - << irphi_ << "\t" - << iz_ << "\t" - << sensorlayer_ << "\t" - << ladder_ << "\t" - << module_ << "\t" - << x_ << "\t" - << y_ << "\t" - << z_ << "\t" << endl; - - for (unsigned int i=0;i simtrackids_; - -}; - -struct HashOp { - int operator()(const Digi &a) const { - return a.hash(); - } -}; - -struct HashEqual { - bool operator()(const Digi &a, const Digi &b) const { - return a == b; - } -}; - - - - -class SLHCEvent{ - -public: - - - SLHCEvent() { - //empty constructor to be used with 'filler' functions - } - - void setIPx(double x) { x_offset=x;} - void setIPy(double y) { y_offset=y;} - - void addL1SimTrack(int id,int type,double pt,double eta,double phi, - double vx,double vy,double vz){ - - vx-=x_offset; - vy-=y_offset; - L1SimTrack simtrack(id,type,pt,eta,phi,vx,vy,vz); - simtracks_.push_back(simtrack); - - } - - - void addDigi(int layer,int irphi,int iz,int sensorlayer,int ladder,int module, - double x,double y,double z,vector simtrackids){ - - x-=x_offset; - y-=y_offset; - - Digi digi(layer,irphi,iz,sensorlayer,ladder, - module,x,y,z); - - for (unsigned int i=0;i innerStack, - vector irphi, - vector iz, - vector iladder, - vector imodule){ - - x-=x_offset; - y-=y_offset; - - L1TStub stub(-1,-1,-1,layer, ladder, module, x, y, z, -1.0, -1.0, pt); - - for(unsigned int i=0;i> tmp; - while (tmp=="Map:") { - in>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp; - in>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp; - } - if (tmp=="EndMap") { - in>>tmp; - } - if (tmp!="Event:") { - cout << "Expected to read 'Event:' but found:"<> eventnum_; - - cout << "Started to read event="<> tmp; - while (tmp!="SimTrackEnd"){ - if (!(tmp=="SimTrack:"||tmp=="SimTrackEnd")) { - cout << "Expected to read 'SimTrack:' or 'SimTrackEnd' but found:" - << tmp << endl; - abort(); - } - int id; - int type; - double pt; - double eta; - double phi; - double vx; - double vy; - double vz; - in >> id >> type >> pt >> eta >> phi >> vx >> vy >> vz; - if (first) { - mc_rinv=0.00299792*3.8/pt; - mc_phi0=phi; - mc_z0=vz; - mc_t=tan(0.25*two_pi-2.0*atan(exp(-eta))); - event=eventnum_; - first=false; - } - vx-=x_offset; - vy-=y_offset; - L1SimTrack simtrack(id,type,pt,eta,phi,vx,vy,vz); - simtracks_.push_back(simtrack); - in >> tmp; - } - - - - //read te Digis - in >> tmp; - while (tmp!="DigiEnd"){ - if (!(tmp=="Digi:"||tmp=="DigiEnd")) { - cout << "Expected to read 'Digi:' or 'DigiEnd' but found:" - << tmp << endl; - abort(); - } - int layer; - int irphi; - int iz; - int sensorlayer; - int ladder; - int module; - double x; - double y; - double z; - - in >> layer - >> irphi - >> iz - >> sensorlayer - >> ladder - >> module - >> x - >> y - >> z; - - x-=x_offset; - y-=y_offset; - - - Digi digi(layer,irphi,iz,sensorlayer,ladder, - module,x,y,z); - in >> tmp; - while (tmp=="SimTrackId:"){ - int simtrackid; - in >> simtrackid; - digi.AddSimtrack(simtrackid); - in >> tmp; - } - digis_.push_back(digi); - digihash_.insert(digi); - } - - cout << "Read "<> tmp; - while (tmp!="StubEnd"){ - - if (!in.good()) { - cout << "File not good"<> layer >> ladder >> module >> pt >> x >> y >> z; - - layer--; - x-=x_offset; - y-=y_offset; - - if (layer < 10) nlayer[layer]++; - - L1TStub stub(-1,-1,-1,layer, ladder, module, x, y, z, -1.0, -1.0, pt); - - in >> tmp; - - while (tmp=="InnerStackDigi:"||tmp=="OuterStackDigi:"){ - int irphi; - int iz; - int iladder; - int imodule; - in >> irphi; - in >> iz; - in >> iladder; - in >> imodule; - if (tmp=="InnerStackDigi:") stub.AddInnerDigi(iladder,imodule,irphi,iz); - if (tmp=="OuterStackDigi:") stub.AddOuterDigi(iladder,imodule,irphi,iz); - in >> tmp; - } - - bool foundclose=false; - - for (unsigned int i=0;i simtrackids; - - simtrackids=this->simtrackids(stub); - - if (simtrackids.size()==0) { - return -1; - } - - - std::sort(simtrackids.begin(),simtrackids.end()); - - int n_max = 0; - int value_max = 0; - int n_tmp = 1; - int value_tmp = simtrackids[0]; - for (unsigned int i=1; i n_max) { - n_max = n_tmp; - value_max = value_tmp; - } - n_tmp = 1; - value_tmp = simtrackids[i]; - } - } - - if (n_tmp > n_max) value_max = value_tmp; - - return value_max; - - } - - std::vector simtrackids(const L1TStub& stub){ - - //cout << "Entering simtrackids"< simtrackids; - - int layer=stub.layer()+1; - - - vector > innerdigis=stub.innerdigis(); - vector > outerdigis=stub.outerdigis(); - vector > innerdigisladdermodule=stub.innerdigisladdermodule(); - vector > outerdigisladdermodule=stub.outerdigisladdermodule(); - - vector > alldigis=stub.innerdigis(); - alldigis.insert(alldigis.end(),outerdigis.begin(),outerdigis.end()); - vector > alldigisladdermodule=stub.innerdigisladdermodule(); - alldigisladdermodule.insert(alldigisladdermodule.end(), - outerdigisladdermodule.begin(), - outerdigisladdermodule.end()); - - - - if (layer<1000) { - - for (unsigned int k=0;k::const_iterator it=digihash_.find(tmp); - if(it==digihash_.end()){ - static int count=0; - count++; - if (count<5) { - cout << "Warning did not find digi"<::const_iterator it=digihash_.find(tmp); - if(it==digihash_.end()){ - static int count=0; - count++; - if (count < 5) { - cout << "Warning did not find digi in disks"< simtracks_; - vector digis_; - __gnu_cxx::hash_set digihash_; - vector stubs_; - - -}; - -double SLHCEvent::mc_rinv=0.0; -double SLHCEvent::mc_phi0=0.0; -double SLHCEvent::mc_z0=0.0; -double SLHCEvent::mc_t=0.0; -int SLHCEvent::event=0; - -#endif - - - diff --git a/SimDataFormats/SLHC/src/L1CaloCluster.cc b/SimDataFormats/SLHC/src/L1CaloCluster.cc deleted file mode 100644 index 49b64ec5a1069..0000000000000 --- a/SimDataFormats/SLHC/src/L1CaloCluster.cc +++ /dev/null @@ -1,459 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1CaloCluster.h" -#include "SimDataFormats/SLHC/interface/L1TowerNav.h" -#include - -namespace l1slhc -{ - - L1CaloCluster::L1CaloCluster( ):mIeta( 0 ), - mIphi( 0 ), - mEmEt( 0 ), - mHadEt( 0 ), - mLeadTowerE( 0 ), - mSecondTowerE( 0 ), - mThirdTowerE( 0 ), - mFourthTowerE( 0 ), - mRing1E( 0 ), - mRing2E( 0 ), - mRing3E( 0 ), - mRing4E( 0 ), - mFg( false ), - mEgamma( false ), - mCentral( false ), - mIsoeg( false ), - mLeadtowertau( false ), - mIsotau( false ), - mEgammavalue( 0 ), - mInnereta( 0 ), - mInnerphi( 0 ), - mIsoclusterseg( 0 ), - mIsoclusterstau( 0 ), - mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ), - mIsoEmEtEG( 0 ), - mIsoHadEtEG( 0 ) - { - } - - L1CaloCluster::L1CaloCluster( const int &iEta, const int &iPhi ):mIeta( iEta ), - mIphi( iPhi ), - mEmEt( 0 ), - mHadEt( 0 ), - mLeadTowerE( 0 ), - mSecondTowerE( 0 ), - mThirdTowerE( 0 ), - mFourthTowerE( 0 ), - mRing1E( 0 ), - mRing2E( 0 ), - mRing3E( 0 ), - mRing4E( 0 ), - mFg( false ), - mEgamma( false ), - mCentral( false ), - mIsoeg( false ), - mLeadtowertau( false ), - mIsotau( false ), - mEgammavalue( 0 ), - mInnereta( 0 ), - mInnerphi( 0 ), - mIsoclusterseg( 0 ), - mIsoclusterstau( 0 ), - mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ), - mIsoEmEtEG( 0 ), - mIsoHadEtEG( 0 ) - { - } - - - - L1CaloCluster::~L1CaloCluster( ) - { - } - - - const int &L1CaloCluster::iEta( ) const - { - return mIeta; - } - - const int &L1CaloCluster::iPhi( ) const - { - return mIphi; - } - - const int &L1CaloCluster::innerEta( ) const - { - return mInnereta; - } - - const int &L1CaloCluster::innerPhi( ) const - { - return mInnerphi; - } - - - const int L1CaloCluster::Et( int mode ) const - { - int returnEt=0; - if(mode&0x1) returnEt+=mEmEt; - if(mode&0x2) returnEt+=mHadEt; - return returnEt; - } - - const int &L1CaloCluster::EmEt( ) const - { - return mEmEt; - } - - const int &L1CaloCluster::HadEt( ) const - { - return mHadEt; - } - - const int &L1CaloCluster::LeadTowerE( ) const - { - return mLeadTowerE; - } - - const int &L1CaloCluster::SecondTowerE( ) const - { - return mSecondTowerE; - } - - const int &L1CaloCluster::ThirdTowerE( ) const - { - return mThirdTowerE; - } - - const int &L1CaloCluster::FourthTowerE( ) const - { - return mFourthTowerE; - } - - - const int &L1CaloCluster::Ring1E( ) const - { - return mRing1E; - } - - - const int &L1CaloCluster::Ring2E( ) const - { - return mRing2E; - } - - const int &L1CaloCluster::Ring3E( ) const - { - return mRing3E; - } - - const int &L1CaloCluster::Ring4E( ) const - { - return mRing4E; - } - - const bool & L1CaloCluster::fg( ) const - { - return mFg; - } - - const bool & L1CaloCluster::eGamma( ) const - { - return mEgamma; - } - - const bool & L1CaloCluster::hasLeadTower( ) const - { - return mLeadtowertau; - } - - - const int &L1CaloCluster::eGammaValue( ) const - { - return mEgammavalue; - } - - const bool & L1CaloCluster::isoEG( ) const - { - return mIsoeg; - } - - const bool & L1CaloCluster::isoTau( ) const - { - return mIsotau; - } - - const bool & L1CaloCluster::isCentral( ) const - { - return mCentral; - } - - const int &L1CaloCluster::isoClustersEG( ) const - { - return mIsoclusterseg; - } - - const int &L1CaloCluster::isoClustersTau( ) const - { - return mIsoclusterstau; - } - - const int &L1CaloCluster::isoEnergyEG( ) const - { - return mIsoenergyeg; - } - - const int &L1CaloCluster::isoEnergyTau( ) const - { - return mIsoenergytau; - } - - const int &L1CaloCluster::isoEmEtEG( ) const - { - return mIsoEmEtEG; - } - - const int &L1CaloCluster::isoHadEtEG( ) const - { - return mIsoHadEtEG; - } - - bool L1CaloCluster::isEGamma( ) const - { - return ( !fg( ) && eGamma( ) && isCentral( ) ); - } - - bool L1CaloCluster::isIsoEGamma( ) const - { - return ( !fg( ) && eGamma( ) && isoEG( ) && isCentral( ) ); - } - - bool L1CaloCluster::isIsoTau( ) const - { - return hasLeadTower( ) && isoTau( ) && isCentral( ); - } - - bool L1CaloCluster::isTau( ) const - { - return hasLeadTower( ) && isCentral( ); - } - - - void L1CaloCluster::setEmEt( const int &E ) - { - mEmEt = E; - } - - void L1CaloCluster::setHadEt( const int &E ) - { - mHadEt = E; - } - - void L1CaloCluster::setLeadTowerE( const int &E ) - { - mLeadTowerE = E; - } - - void L1CaloCluster::setSecondTowerE( const int &E ) - { - mSecondTowerE = E; - } - - void L1CaloCluster::setThirdTowerE( const int &E ) - { - mThirdTowerE = E; - } - - void L1CaloCluster::setFourthTowerE( const int &E ) - { - mFourthTowerE = E; - } - - - void L1CaloCluster::setRing1E( const int &Ring1E ) - { - mRing1E = Ring1E; - } - - - void L1CaloCluster::setRing2E( const int &Ring2E ) - { - mRing2E = Ring2E; - } - - void L1CaloCluster::setRing3E( const int &Ring3E ) - { - mRing3E = Ring3E; - } - - void L1CaloCluster::setRing4E( const int &Ring4E ) - { - mRing4E = Ring4E; - } - - void L1CaloCluster::setConstituents( const L1CaloTowerRefVector & cons ) - { - mConstituents = cons; - } - - const L1CaloTowerRefVector & L1CaloCluster::getConstituents( ) const - { - return mConstituents; - } - - - void L1CaloCluster::setFg( const bool & fg ) - { - mFg = fg; - } - - - void L1CaloCluster::setEGamma( const bool & eg ) - { - mEgamma = eg; - } - - void L1CaloCluster::setLeadTower( const bool & eg ) - { - mLeadtowertau = eg; - } - - - void L1CaloCluster::setEGammaValue( const int &eg ) - { - mEgammavalue = eg; - } - - void L1CaloCluster::setIsoEG( const bool & eg ) - { - mIsoeg = eg; - } - - void L1CaloCluster::setIsoTau( const bool & eg ) - { - mIsotau = eg; - } - - void L1CaloCluster::setIsoClusters( const int &eg, const int &tau ) - { - mIsoclusterseg = eg; - mIsoclusterstau = tau; - } - - void L1CaloCluster::setIsoEnergy( const int &eg, const int &tau ) - { - mIsoenergyeg = eg; - mIsoenergytau = tau; - } - - void L1CaloCluster::setIsoEmAndHadEtEG(const int& isoEmEt,const int& isoHadEt) - { - mIsoEmEtEG = isoEmEt; - mIsoHadEtEG = isoHadEt; - } - void L1CaloCluster::setCentral( const bool & eg ) - { - mCentral = eg; - } - - void L1CaloCluster::setPosBits( const int &eta, const int &phi ) - { - mInnereta = eta; - mInnerphi = phi; - - } - - void L1CaloCluster::setLorentzVector( const math::PtEtaPhiMLorentzVector & v ) - { - mP4 = v; - } - - - void L1CaloCluster::addConstituent( const L1CaloTowerRef & tower ) - { - mEmEt += tower->E( ); - mHadEt += tower->H( ); - mConstituents.push_back( tower ); - } - - int L1CaloCluster::hasConstituent( const int &eta, const int &phi ) const - { - for ( unsigned int i = 0; i < mConstituents.size( ); ++i ) - { - L1CaloTowerRef tower = mConstituents.at( i ); - if ( tower->iEta( ) == L1TowerNav::getOffsetIEta(mIeta,eta) && tower->iPhi( ) == L1TowerNav::getOffsetIPhi(L1TowerNav::getOffsetIEta(mIeta,eta),mIphi,phi) ) //SHarper change: fix iEta -ve to +ve and iPhi 72->1 bug, warning need to check behavour when the offset eta is on a phi change boundary - { - return i; - } - } - return -1; - } - - - L1CaloTowerRef L1CaloCluster::getConstituent( const int &pos ) const - { - return mConstituents.at( pos ); - } - - - - void L1CaloCluster::removeConstituent( const int &eta, const int &phi ) - { - - int pos = hasConstituent( eta, phi ); - - if ( pos != -1 ) - { - mEmEt-=mConstituents.at( pos )->E( ); - mHadEt-=mConstituents.at( pos )->H( ); - mConstituents.erase( mConstituents.begin( ) + pos ); - } - } - - - - const math::PtEtaPhiMLorentzVector & L1CaloCluster::p4( ) const - { - return mP4; - } - -} - - -namespace std -{ - bool operator<( const l1slhc::L1CaloCluster & aLeft, const l1slhc::L1CaloCluster & aRight ) - { - if ( aLeft.EmEt() + aLeft.HadEt() == aRight.EmEt( ) + aRight.HadEt() ) - { - // for two objects with equal energy, favour the more central one - return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); - } - else - { - return ( aLeft.EmEt()+aLeft.HadEt() < aRight.EmEt() + aRight.HadEt() ); - } - } -} - - -// pretty print -std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1CaloCluster & aL1CaloCluster ) -{ - aStream << "L1CaloCluster" - << " iEta=" << aL1CaloCluster.iEta( ) - << " iPhi=" << aL1CaloCluster.iPhi( ) - << " E=" << aL1CaloCluster.EmEt( ) + aL1CaloCluster.HadEt( ) - << " eta=" << aL1CaloCluster.p4( ).eta( ) - << " phi=" << aL1CaloCluster.p4( ).phi( ) - << " pt=" << aL1CaloCluster.p4( ).pt( ) - << " egamma=" << aL1CaloCluster.eGammaValue( ) - << " central=" << aL1CaloCluster.isCentral( ) - << " fg=" << aL1CaloCluster.fg( ) - << "\n with constituents:\n"; - for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1CaloCluster.getConstituents( ).begin( ); i != aL1CaloCluster.getConstituents( ).end( ); ++i ) - aStream << " iEta=" << ( **i ).iEta( ) - << " iPhi=" << ( **i ).iPhi( ) - << " ET=" << ( **i ).E( ) - << "\n"; - return aStream; -} diff --git a/SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc b/SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc deleted file mode 100644 index 6c43df3044a21..0000000000000 --- a/SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc +++ /dev/null @@ -1,476 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h" -#include "SimDataFormats/SLHC/interface/L1TowerNav.h" - -#include - -#include - -namespace l1slhc -{ - - L1CaloClusterWithSeed::L1CaloClusterWithSeed( ): - mSeedThreshold(4), - mEmThreshold(2), - mHadThreshold(2), - mIeta( 0 ), - mIphi( 0 ), - mEmEt( 0 ), - mHadEt( 0 ), - mTrimmedPlus(false), - mTrimmedMinus(false), - mFg( false ), - mEgamma( false ), - mEgammavalue( 0 ), - mIsoeg( false ), - mIsoEmEtEG( 0 ), - mIsoHadEtEG( 0 ), - mInnereta( 0 ), - mInnerphi( 0 ), - mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ) - { - } - - L1CaloClusterWithSeed::L1CaloClusterWithSeed( const int &iEta, const int &iPhi ): - mSeedThreshold(2), - mEmThreshold(2), - mHadThreshold(2), - mIeta( iEta ), - mIphi( iPhi ), - mEmEt( 0 ), - mHadEt( 0 ), - mTrimmedPlus(false), - mTrimmedMinus(false), - mFg( false ), - mEgamma( false ), - mEgammavalue( 0 ), - mIsoeg( false ), - mIsoEmEtEG( 0 ), - mIsoHadEtEG( 0 ), - mInnereta( 0 ), - mInnerphi( 0 ), - mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ) - { - } - - L1CaloClusterWithSeed::L1CaloClusterWithSeed( const L1CaloTowerRef & seed, int seedThreshold, int emThreshold, int hadThreshold ): - mSeedTower(seed), - mSeedThreshold(seedThreshold), - mEmThreshold(emThreshold), - mHadThreshold(hadThreshold), - mIeta( seed->iEta() ), - mIphi( seed->iPhi() ), - mEmEt( seed->E() ), - mHadEt( (seed->H()>=hadThreshold ? seed->H() : 0.) ), - mTrimmedPlus(false), - mTrimmedMinus(false), - mFg( seed->EcalFG() ), - mEgamma( false ), - mEgammavalue( 0 ), - mIsoeg( false ), - mIsoEmEtEG( 0 ), - mIsoHadEtEG( 0 ), - mInnereta( 0 ), - mInnerphi( 0 ), - mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ) - { - if(seed->E()6 && fg( )) && eGamma( ) ); - } - - const bool & L1CaloClusterWithSeed::isoEG( ) const - { - return mIsoeg; - } - - const int &L1CaloClusterWithSeed::isoEmEtEG( ) const - { - return mIsoEmEtEG; - } - - const int &L1CaloClusterWithSeed::isoHadEtEG( ) const - { - return mIsoHadEtEG; - } - - bool L1CaloClusterWithSeed::isIsoEGamma( ) const - { - return ( !(seedEmEt()>6 && fg( )) && eGamma( ) && isoEG( ) ); - } - - void L1CaloClusterWithSeed::setEmEt( int E ) - { - mEmEt = E; - } - - void L1CaloClusterWithSeed::setHadEt( int H ) - { - mHadEt = H; - } - - void L1CaloClusterWithSeed::setTrimmedPlus( bool trimmed) - { - mTrimmedPlus = trimmed; - } - - void L1CaloClusterWithSeed::setTrimmedMinus( bool trimmed) - { - mTrimmedMinus = trimmed; - } - - - void L1CaloClusterWithSeed::setConstituents( const L1CaloTowerRefVector & cons ) - { - mConstituents = cons; - } - - const L1CaloTowerRefVector & L1CaloClusterWithSeed::getConstituents( ) const - { - return mConstituents; - } - - - void L1CaloClusterWithSeed::setFg( bool fg ) - { - mFg = fg; - } - - - void L1CaloClusterWithSeed::setEGamma( bool eg ) - { - mEgamma = eg; - } - - - void L1CaloClusterWithSeed::setEGammaValue( int eg ) - { - mEgammavalue = eg; - } - - void L1CaloClusterWithSeed::setIsoEG( const bool & eg ) - { - mIsoeg = eg; - } - - void L1CaloClusterWithSeed::setIsoEmAndHadEtEG(const int& isoEmEt,const int& isoHadEt) - { - mIsoEmEtEG = isoEmEt; - mIsoHadEtEG = isoHadEt; - } - - void L1CaloClusterWithSeed::setPosBits( int eta, int phi ) - { - mInnereta = eta; - mInnerphi = phi; - - } - - void L1CaloClusterWithSeed::setLorentzVector( const math::PtEtaPhiMLorentzVector & v ) - { - mP4 = v; - } - - - void L1CaloClusterWithSeed::addConstituent( const L1CaloTowerRef & tower ) - { - mEmEt += (tower->E()>=mEmThreshold ? tower->E( ) : 0); - mHadEt += (tower->H()>=mHadThreshold ? tower->H( ) : 0); - mConstituents.push_back( tower ); - mConstituentSharing.push_back(0); - } - - // Friend towers are not included in the cluster. But may be included in later steps of clustering. - void L1CaloClusterWithSeed::addFriend( const L1CaloTowerRef & tower ) - { - mFriends.push_back( tower ); - } - - int L1CaloClusterWithSeed::hasConstituent( int eta, int phi ) const - { - for ( unsigned int i = 0; i < mConstituents.size( ); ++i ) - { - L1CaloTowerRef tower = mConstituents.at( i ); - //std::cout<<"ieta="<iEta()<<"("<iEta( ) == mIeta + eta && tower->iPhi( ) == mIphi + phi ) - if ( tower->iEta( ) == L1TowerNav::getOffsetIEta(mIeta,eta) && tower->iPhi( ) == L1TowerNav::getOffsetIPhi(L1TowerNav::getOffsetIEta(mIeta,eta),mIphi,phi) ) //SHarper change: fix iEta -ve to +ve and iPhi 72->1 bug, warning need to check behavour when the offset eta is on a phi change boundary - { - return i; - } - } - return -1; - } - - int L1CaloClusterWithSeed::hasFriend( int eta, int phi ) - { - for ( unsigned int i = 0; i < mFriends.size( ); ++i ) - { - L1CaloTowerRef tower = mFriends.at( i ); - //if ( tower->iEta( ) == mIeta + eta && tower->iPhi( ) == mIphi + phi ) - if ( tower->iEta( ) == L1TowerNav::getOffsetIEta(mIeta,eta) && tower->iPhi( ) == L1TowerNav::getOffsetIPhi(L1TowerNav::getOffsetIEta(mIeta,eta),mIphi,phi) ) //SHarper change: fix iEta -ve to +ve and iPhi 72->1 bug, warning need to check behavour when the offset eta is on a phi change boundary - { - return i; - } - } - return -1; - } - - L1CaloTowerRef L1CaloClusterWithSeed::getSeedTower() const - { - return mSeedTower; - } - - L1CaloTowerRef L1CaloClusterWithSeed::getConstituent( int pos ) - { - return mConstituents.at( pos ); - } - - L1CaloTowerRef L1CaloClusterWithSeed::getFriend( int pos ) - { - return mFriends.at( pos ); - } - - - - void L1CaloClusterWithSeed::removeConstituent( int eta, int phi ) - { - - int pos = hasConstituent( eta, phi ); - - if ( pos != -1 ) - { - mEmEt -= constituentEmEt( eta, phi ); - mHadEt -= constituentHadEt( eta, phi ); - mConstituents.erase( mConstituents.begin( ) + pos ); - mConstituentSharing.erase( mConstituentSharing.begin( ) + pos ); - } - } - - void L1CaloClusterWithSeed::removeFriend( int eta, int phi ) - { - - int pos = hasFriend( eta, phi ); - - if ( pos != -1 ) - { - mFriends.erase( mFriends.begin( ) + pos ); - } - } - - - int L1CaloClusterWithSeed::seedEmEt() const - { - return (mSeedTower->E()>=mSeedThreshold ? mSeedTower->E() : 0); - } - - int L1CaloClusterWithSeed::seedHadEt() const - { - return (mSeedTower->H()>=mHadThreshold ? mSeedTower->H() : 0.); - } - - int L1CaloClusterWithSeed::constituentEmEt(int eta, int phi) const - { - int pos = hasConstituent( eta, phi ); - - int lConstituentE = 0; - if ( pos != -1 ) - { - lConstituentE = (mConstituents[pos]->E()>=mEmThreshold ? mConstituents[pos]->E() : 0); - int lSharing = mConstituentSharing[pos]; - switch(lSharing) - { - case 1: - lConstituentE = lConstituentE - lConstituentE/4; - break; - case 2: - lConstituentE = lConstituentE - lConstituentE/2; - break; - case 3: - lConstituentE = lConstituentE/2; - break; - case 4: - lConstituentE = lConstituentE/4; - break; - case 5: - lConstituentE = 0; - break; - default: - break; - }; - } - return lConstituentE; - } - - int L1CaloClusterWithSeed::constituentHadEt(int eta, int phi) const - { - int pos = hasConstituent( eta, phi ); - - int lConstituentH = 0; - if ( pos != -1 ) - { - lConstituentH = (mConstituents[pos]->H()>=mHadThreshold ? mConstituents[pos]->H() : 0); - int lSharing = mConstituentSharing[pos]; - switch(lSharing) - { - case 1: - lConstituentH = lConstituentH - lConstituentH/4; - break; - case 2: - lConstituentH = lConstituentH - lConstituentH/2; - break; - case 3: - lConstituentH = lConstituentH/2; - break; - case 4: - lConstituentH = lConstituentH/4; - break; - case 5: - lConstituentH = 0; - break; - default: - break; - }; - } - return lConstituentH; - } - - void L1CaloClusterWithSeed::shareConstituent(int eta, int phi, int sharing) - { - int pos = hasConstituent( eta, phi ); - if ( pos != -1 ) - { - int cEold = constituentEmEt(eta,phi); - int cHold = constituentHadEt(eta,phi); - mConstituentSharing[pos] = sharing; - int cEnew = constituentEmEt(eta, phi); - int cHnew = constituentHadEt(eta, phi); - mEmEt = mEmEt - cEold + cEnew; - mHadEt = mHadEt - cHold + cHnew; - } - } - - - const math::PtEtaPhiMLorentzVector & L1CaloClusterWithSeed::p4( ) const - { - return mP4; - } - -} - - -namespace std -{ - bool operator<( const l1slhc::L1CaloClusterWithSeed & aLeft, const l1slhc::L1CaloClusterWithSeed & aRight ) - { - if ( aLeft.EmEt()+aLeft.HadEt() == aRight.EmEt()+aRight.HadEt() ) - { - // for two objects with equal energy, favour the more central one - return ( abs( aLeft.iEta() ) > abs( aRight.iEta() ) ); - } - else - { - return ( aLeft.EmEt()+aLeft.HadEt() < aRight.EmEt()+aRight.HadEt() ); - } - } -} - - -// pretty print -std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1CaloClusterWithSeed & aL1CaloClusterWithSeed ) -{ - aStream << "L1CaloClusterWithSeed" - << " iEta=" << aL1CaloClusterWithSeed.iEta( ) - << " iPhi=" << aL1CaloClusterWithSeed.iPhi( ) - << " E=" << aL1CaloClusterWithSeed.EmEt( ) - << " H=" << aL1CaloClusterWithSeed.HadEt( ) - << " eta=" << aL1CaloClusterWithSeed.p4( ).eta( ) - << " phi=" << aL1CaloClusterWithSeed.p4( ).phi( ) - << " pt=" << aL1CaloClusterWithSeed.p4( ).pt( ) - << " egamma=" << aL1CaloClusterWithSeed.eGammaValue( ) - << " fg=" << aL1CaloClusterWithSeed.fg( ) - << "\n with constituents:\n"; - for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1CaloClusterWithSeed.getConstituents( ).begin( ); i != aL1CaloClusterWithSeed.getConstituents( ).end( ); ++i ) - aStream << " iEta=" << ( **i ).iEta( ) - << " iPhi=" << ( **i ).iPhi( ) - << " ET=" << ( **i ).E( ) - << "\n"; - return aStream; -} diff --git a/SimDataFormats/SLHC/src/L1CaloJet.cc b/SimDataFormats/SLHC/src/L1CaloJet.cc deleted file mode 100644 index fa50851e57845..0000000000000 --- a/SimDataFormats/SLHC/src/L1CaloJet.cc +++ /dev/null @@ -1,148 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1CaloJet.h" -#include - -namespace l1slhc -{ - - L1CaloJet::L1CaloJet( ): - mIeta( 0 ), - mIphi( 0 ), - mE( 0 ), - mCentral( true ) - { - } - - - - L1CaloJet::L1CaloJet( const int &iEta, const int &iPhi ): - mIeta( iEta ), - mIphi( iPhi ), - mE( 0 ), - mCentral( true ) - { - } - - L1CaloJet::~L1CaloJet( ) - { - - - } - - void L1CaloJet::setP4( const math::PtEtaPhiMLorentzVector & p4 ) - { - mP4 = p4; - } - - void L1CaloJet::setCentral( const bool & central ) - { - mCentral = central; - } - - - const int &L1CaloJet::iEta( ) const - { - return mIeta; - } - - - const int &L1CaloJet::iPhi( ) const - { - return mIphi; - } - - - const int &L1CaloJet::E( ) const - { - return mE; - } - - const bool & L1CaloJet::central( ) const - { - return mCentral; - } - - - - void L1CaloJet::setE( const int &E ) - { - mE = E; - } - - const math::PtEtaPhiMLorentzVector & L1CaloJet::p4( ) const - { - return mP4; - } - - - void L1CaloJet::addConstituent( const L1CaloRegionRef & region ) - { - mE += region->E( ); - mConstituents.push_back( region ); - } - - const L1CaloRegionRefVector & L1CaloJet::getConstituents( ) const - { - return mConstituents; - } - - int L1CaloJet::hasConstituent( const int &eta, const int &phi ) - { - int pos = -1; - for ( unsigned int i = 0; i < mConstituents.size( ); ++i ) - { - L1CaloRegionRef tower = mConstituents.at( i ); - if ( tower->iEta( ) == eta + mIeta && tower->iPhi( ) == phi + mIphi ) - { - pos = i; - break; - } - } - - return pos; - } - - void L1CaloJet::removeConstituent( const int &eta, const int &phi ) - { - int pos = hasConstituent( eta, phi ); - if ( pos != -1 ) - { - mE = mE - mConstituents.at( pos )->E( ); - mConstituents.erase( mConstituents.begin( ) + pos ); - } - } -} - - - - -namespace std -{ - bool operator<( const l1slhc::L1CaloJet & aLeft, const l1slhc::L1CaloJet & aRight ) - { - if ( aLeft.E( ) == aRight.E( ) ) - { - // for two objects with equal energy, favour the more central one - return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); - } - else - { - return ( aLeft.E( ) < aRight.E( ) ); - } - } -} - - -// pretty print -std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1CaloJet & aL1CaloJet ) -{ - aStream << "L1CaloJet" - << " iEta=" << aL1CaloJet.iEta( ) - << " iPhi=" << aL1CaloJet.iPhi( ) - << "\n with constituents:\n"; - for ( l1slhc::L1CaloRegionRefVector::const_iterator i = aL1CaloJet.getConstituents( ).begin( ); i < aL1CaloJet.getConstituents( ).end( ); ++i ) - aStream << " iEta=" << ( **i ).iEta( ) - << " iPhi=" << ( **i ).iPhi( ) - << " ET=" << ( **i ).E( ) - << "\n"; - return aStream; -} diff --git a/SimDataFormats/SLHC/src/L1CaloRegion.cc b/SimDataFormats/SLHC/src/L1CaloRegion.cc deleted file mode 100644 index 177d54bebad97..0000000000000 --- a/SimDataFormats/SLHC/src/L1CaloRegion.cc +++ /dev/null @@ -1,58 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1CaloRegion.h" - -#include - - -namespace l1slhc -{ - - L1CaloRegion::L1CaloRegion( ):mIeta( 0 ), - mIphi( 0 ), - mE( 0 ) - { - } - - L1CaloRegion::L1CaloRegion( const int &iEta, const int &iPhi, const int &E ):mIeta( iEta ), - mIphi( iPhi ), - mE( E ) - { - } - - - L1CaloRegion::~L1CaloRegion( ) - { - } - - const int &L1CaloRegion::iEta( ) const - { - return mIeta; - } - - const int &L1CaloRegion::iPhi( ) const - { - return mIphi; - } - - const int &L1CaloRegion::E( ) const - { - return mE; - } - -} - - -namespace std -{ - bool operator<( const l1slhc::L1CaloRegion & aLeft, const l1slhc::L1CaloRegion & aRight ) - { - if ( aLeft.E( ) == aRight.E( ) ) - { - // for two objects with equal energy, favour the more central one - return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); - } - else - { - return ( aLeft.E( ) < aRight.E( ) ); - } - } -} diff --git a/SimDataFormats/SLHC/src/L1CaloTower.cc b/SimDataFormats/SLHC/src/L1CaloTower.cc deleted file mode 100644 index 9650f2d585bb7..0000000000000 --- a/SimDataFormats/SLHC/src/L1CaloTower.cc +++ /dev/null @@ -1,109 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1CaloTower.h" - -#include - -namespace l1slhc -{ - - L1CaloTower::L1CaloTower( ): - mEcal( 0 ), - mHcal( 0 ), - mIeta( 0 ), - mIphi( 0 ), - mEcalFG( false ), - mHcalFG( false ) - { - } - - L1CaloTower::L1CaloTower( const int &aIeta, const int &aIphi ):mEcal( 0 ), - mHcal( 0 ), - mIeta( aIeta ), - mIphi( aIphi ), - mEcalFG( false ), - mHcalFG( false ) - { - } - - L1CaloTower::~L1CaloTower( ) - { - } - - - void L1CaloTower::setPos( const int &aIeta, const int &aIphi ) - { - mIeta = aIeta; - mIphi = aIphi; - } - - - /* - void L1CaloTower::setParams( const int& aEcal, const int& aHcal, const bool& aFG ) { mEcal = aEcal; mHcal = aHcal; mEcalFG = aFG; } */ - - - void L1CaloTower::setEcal( const int &aEcal, const bool & aFG ) - { - mEcal = aEcal; - mEcalFG = aFG; - } - - void L1CaloTower::setHcal( const int &aHcal, const bool & aFG ) - { - mHcal = aHcal; - mHcalFG = aFG; - } - - - - - const int &L1CaloTower::E( ) const - { - return mEcal; - } - - const int &L1CaloTower::H( ) const - { - return mHcal; - } - - - const int &L1CaloTower::iEta( ) const - { - return mIeta; - } - - const int &L1CaloTower::iPhi( ) const - { - return mIphi; - } - - const bool & L1CaloTower::EcalFG( ) const - { - return mEcalFG; - } - - const bool & L1CaloTower::HcalFG( ) const - { - return mHcalFG; - } - -} - -namespace std -{ - bool operator<( const l1slhc::L1CaloTower & aLeft, const l1slhc::L1CaloTower & aRight ) - { - int lLeftE = aLeft.E( ) + aLeft.H( ); - int lRightE = aRight.E( ) + aRight.H( ); - - if ( lLeftE == lRightE ) - { - // for two objects with equal energy, favour the more central one - return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); - } - else - { - return ( lLeftE < lRightE ); - } - - } -} diff --git a/SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc b/SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc deleted file mode 100644 index bbb7b86320264..0000000000000 --- a/SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc +++ /dev/null @@ -1,4 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h" -#include "FWCore/Framework/interface/eventsetuprecord_registration_macro.h" - -EVENTSETUP_RECORD_REG( L1CaloTriggerSetupRcd ); diff --git a/SimDataFormats/SLHC/src/L1TkCluster.cc b/SimDataFormats/SLHC/src/L1TkCluster.cc deleted file mode 100644 index e7029e3a27ab0..0000000000000 --- a/SimDataFormats/SLHC/src/L1TkCluster.cc +++ /dev/null @@ -1,48 +0,0 @@ -/// //////////////////////////////////////// -/// Stacked Tracker Simulations /// -/// /// -/// Nicola Pozzobon, UNIPD /// -/// Emmanuele Salvati, Cornell /// -/// /// -/// 2011, June /// -/// 2011, October /// -/// 2013, January /// -/// //////////////////////////////////////// - -#include "SimDataFormats/SLHC/interface/L1TkCluster.h" - - /** ***************************** **/ - /** **/ - /** IMPLEMENTATION OF METHODS **/ - /** **/ - /** ***************************** **/ - - /// Get cluster width - /// Default template for PixelDigis in *.h - /// Specialize the template for PSimHits - template<> - unsigned int L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findWidth() const - { - return theHits.size(); - } - - /// Get hit local coordinates - /// Default template for PixelDigis in *.h - /// Specialize the template for PSimHits - template<> - MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findHitLocalCoordinates( unsigned int hitIdx ) const - { - MeasurementPoint mp( 0, 0 ); /// Dummy values - return mp; - } - - /// Unweighted average local cluster coordinates - /// Default template for PixelDigis in *.h - /// Specialize the template for PSimHits - template<> - MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findAverageLocalCoordinates() const - { - MeasurementPoint mp( 0, 0 ); /// Dummy values - return mp; - } - diff --git a/SimDataFormats/SLHC/src/L1TkStub.cc b/SimDataFormats/SLHC/src/L1TkStub.cc deleted file mode 100644 index 806a8aca14ebc..0000000000000 --- a/SimDataFormats/SLHC/src/L1TkStub.cc +++ /dev/null @@ -1,27 +0,0 @@ -/// //////////////////////////////////////// -/// Stacked Tracker Simulations /// -/// Written by: /// -/// Andrew W. Rose /// -/// 2008 /// -/// /// -/// Modified by: /// -/// Nicola Pozzobon /// -/// UNIPD /// -/// July 2011 /// -/// /// -/// Added features: /// -/// Newer naming scheme and unification /// -/// of LocalStub and GlobalStub /// -/// //////////////////////////////////////// - -#include "SimDataFormats/SLHC/interface/L1TkStub.h" - -namespace cmsUpgrades { - - /// ////////////// /// - /// HELPER METHODS /// - /// ////////////// /// - - -} /// Close namespace - diff --git a/SimDataFormats/SLHC/src/L1TkTrack.cc b/SimDataFormats/SLHC/src/L1TkTrack.cc deleted file mode 100644 index 067fb92f7b1eb..0000000000000 --- a/SimDataFormats/SLHC/src/L1TkTrack.cc +++ /dev/null @@ -1,19 +0,0 @@ -/// //////////////////////////////////////// -/// Stacked Tracker Simulations /// -/// Written by: /// -/// Nicola Pozzobon /// -/// UNIPD /// -/// 2011, Oct /// -/// /// -/// //////////////////////////////////////// - -#include "SimDataFormats/SLHC/interface/L1TkTrack.h" - -namespace cmsUpgrades { - - /// ////////////// /// - /// HELPER METHODS /// - /// ////////////// /// - -} /// Close namespace - diff --git a/SimDataFormats/SLHC/src/L1TowerJet.cc b/SimDataFormats/SLHC/src/L1TowerJet.cc deleted file mode 100644 index 72fa6e00777e0..0000000000000 --- a/SimDataFormats/SLHC/src/L1TowerJet.cc +++ /dev/null @@ -1,634 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1TowerJet.h" -#include - -namespace l1slhc -{ - - L1TowerJet::L1TowerJet( ): - mIeta( 0 ), - mIphi( 0 ), - - mE( 0 ), - mCentral( true ), - mAsymEta(0), - mAsymPhi(0), - mWeightedIeta( 0 ), - mWeightedIphi( 0 ), - mJetSize( 12 ), - mJetShapeType( square ), - mJetArea( 144 ) - { - } - - L1TowerJet::L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea ): - mIeta( 0 ), - mIphi( 0 ), - - mE( 0 ), - mCentral( true ), - mAsymEta(0), - mAsymPhi(0), - mWeightedIeta( 0 ), - mWeightedIphi( 0 ), - - mJetSize( aJetSize ), - mJetShapeType( aJetShapeType ), - mJetArea( aJetArea ) - { - } - - L1TowerJet::L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea , const int &iEta, const int &iPhi ): - mIeta( iEta ), - mIphi( iPhi ), - - mE( 0 ), - mCentral( true ), - mAsymEta(0), - mAsymPhi(0), - - mWeightedIeta( 0 ), - mWeightedIphi( 0 ), - - mJetSize( aJetSize ), - mJetShapeType( aJetShapeType ), - mJetArea( aJetArea ) - { - } - - L1TowerJet::~L1TowerJet( ) - { - } - - - - - void L1TowerJet::setP4( const math::PtEtaPhiMLorentzVector & p4 ) - { - mP4 = p4; - } - - void L1TowerJet::setCentral( const bool & central ) - { - mCentral = central; - } -/* - void L1TowerJet::setE( const int &E ) - { - mE = E; - } -*/ - - - const int &L1TowerJet::iEta( ) const - { - return mIeta; - } - - const int &L1TowerJet::iPhi( ) const - { - return mIphi; - } - - - - - const double &L1TowerJet::iWeightedEta( ) const - { - - return mWeightedIeta; - - } - - const double &L1TowerJet::iWeightedPhi( ) const - { - - return mWeightedIphi; - - } - - const double &L1TowerJet::WeightedEta( ) const - { - - return mWeightedEta; - - } - - const double &L1TowerJet::WeightedPhi( ) const - { - - return mWeightedPhi; - - } - - - - - const int &L1TowerJet::E( ) const - { - return mE; - } - - const int& L1TowerJet::AsymEta( ) const - { - return mAsymEta; - } - - const int& L1TowerJet::AsymPhi( ) const - { - return mAsymPhi; - } - - - const bool & L1TowerJet::central( ) const - { - return mCentral; - } - - const math::PtEtaPhiMLorentzVector & L1TowerJet::p4( ) const - { - return mP4; - } - - const int& L1TowerJet::JetSize( ) const - { - return mJetSize; - } - - const L1TowerJet::tJetShape& L1TowerJet::JetShape( ) const - { - return mJetShapeType; - } - - const int& L1TowerJet::JetArea( ) const - { - return mJetArea; - } - -/* - double L1TowerJet::EcalVariance( ) const - { - double lMean(0.0); - double lMeanSq(0.0); - - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lMean += (**lConstituentIt).E(); - lMeanSq += ((**lConstituentIt).E() * (**lConstituentIt).E()); - } - - lMean /= mConstituents.size(); - lMeanSq /= mConstituents.size(); - - return lMeanSq - (lMean*lMean); - } - - - double L1TowerJet::HcalVariance( ) const - { - double lMean(0.0); - double lMeanSq(0.0); - - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lMean += (**lConstituentIt).H(); - lMeanSq += ((**lConstituentIt).H() * (**lConstituentIt).H()); - } - - lMean /= mConstituents.size(); - lMeanSq /= mConstituents.size(); - - return lMeanSq - (lMean*lMean); - } - - - double L1TowerJet::EnergyVariance( ) const - { - double lMean( double(mE) / double(mConstituents.size()) ); - double lMeanSq(0.0); - - double lTower; - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lTower = (**lConstituentIt).E() + (**lConstituentIt).H(); - lMeanSq += ( lTower * lTower ); - } - - lMeanSq /= mConstituents.size(); - - return lMeanSq - (lMean*lMean); - } -*/ - - - double L1TowerJet::EcalMAD() const - { - std::deque< int > lEnergy; - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lEnergy.push_back( (**lConstituentIt).E() ); - } - lEnergy.resize( mJetArea , 0 ); - return MAD( lEnergy ); - - } - - double L1TowerJet::HcalMAD() const - { - std::deque< int > lEnergy; - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lEnergy.push_back( (**lConstituentIt).H() ); - } - lEnergy.resize( mJetArea , 0 ); - return MAD( lEnergy ); - - } - - - void L1TowerJet::CalcWeightediEta() - { - double etaSumEt(0); - double sumEt (0); - - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - etaSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * ( (**lConstituentIt).iEta() ); - sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; - } -// std::cout<<" eta* energy = "<=0 ) discrete_iEta=int(mWeightedIeta+0.5); - else discrete_iEta=int(mWeightedIeta-0.5); - - //account for the fact there is no 0 - if(mWeightedIeta>=0 && mWeightedIeta<1) discrete_iEta=1; - - if(mWeightedIeta<0 && mWeightedIeta>(-1)) discrete_iEta=-1; - - //std::cout<<"weighted ieta: "<=1) WeightedEta = (0.087*abs_eta - 0.0435); - else WeightedEta = 0.0435*abs_eta ; - - } - else - { - const double endcapEta[8] = { 0.09, 0.1, 0.113, 0.129, 0.15, 0.178, 0.15, 0.35 }; - abs_eta -= 21; - - WeightedEta = 1.74; - - for ( int i = 0; i != int(abs_eta); ++i ) - { - WeightedEta += endcapEta[i]; - } - if( mJetSize % 2 == 0 ){ - WeightedEta += endcapEta[int(abs_eta)] / 2.; - }else{ - WeightedEta += endcapEta[int(abs_eta)]; - } - } - if(mWeightedIeta<0) WeightedEta=-WeightedEta; - - mWeightedEta = WeightedEta; - } - */ - - - void L1TowerJet::CalcWeightediPhi() - { - double phiSumEt(0); - double sumEt (0); - - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - double tower_iPhi =(**lConstituentIt).iPhi(); - if( iPhi() >= (72-JetSize()) ) { //constituents may go over edge, iPhi>66 for 8x8 jet - if( tower_iPhi < (72 - JetSize()) ){//if constituent tower is over edge, ie. iPhi>1 - tower_iPhi+=72; //iPhi=1 -> iPhi=73 - } - } - //calculate weighted phi using corrected iPhi value - phiSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * (tower_iPhi ); - - sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; - } -// std::cout<<"phi sum et: "<72) mWeightedIphi-=72; - - - } - -void L1TowerJet::calculateWeightedPhi( ) -{ -// double JetSize = double(mJetSize) / 2.0; - double WeightedPhi = ( ( mWeightedIphi-0.5 ) * 0.087 ); - //Need this because 72*0.087 != 2pi: else get uneven phi dist - double pi=(72*0.087)/2; - if(WeightedPhi > pi) WeightedPhi -=2*pi; - mWeightedPhi=WeightedPhi; - // std::cout<<"weighted IPhi: "< lEnergy; - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lEnergy.push_back( (**lConstituentIt).E() + (**lConstituentIt).H() ); - } - lEnergy.resize( mJetArea , 0 ); - return MAD( lEnergy ); - } - - - - double L1TowerJet::MAD( std::deque& aDataSet ) const - { - std::sort( aDataSet.begin() , aDataSet.end() ); - - std::size_t lDataSetSize( aDataSet.size() ); - - double lMedian(0); - if( lDataSetSize%2 == 0 ){ - lMedian = double ( aDataSet[ (lDataSetSize/2) - 1 ] + aDataSet[ lDataSetSize/2 ] ) / 2.0 ; - }else{ - lMedian = double( aDataSet[ (lDataSetSize-1)/2 ] ); - } - - - std::deque< double > lMedianSubtractedDataSet; - for ( std::deque< int >::const_iterator lIt = aDataSet.begin() ; lIt != aDataSet.end(); ++lIt ){ - lMedianSubtractedDataSet.push_back( fabs( double(*lIt) - lMedian ) ); - } - - std::sort( lMedianSubtractedDataSet.begin() , lMedianSubtractedDataSet.end() ); - - if( lDataSetSize%2 == 0 ){ - return double ( lMedianSubtractedDataSet[ (lDataSetSize/2) - 1 ] + lMedianSubtractedDataSet[ lDataSetSize/2 ] ) / 2.0 ; - }else{ - return double( lMedianSubtractedDataSet[ (lDataSetSize-1)/2 ] ); - } - - } - - - void L1TowerJet::addConstituent( const L1CaloTowerRef & Tower ) - { - - int lHalfJetSizeEta( mJetSize >> 1 ); - int lHalfJetSizePhi( mJetSize >> 1 ); - - int lTowerEnergy( Tower->E( ) + Tower->H( ) ); - - //slightly different sizes for HF jets - if( abs( iEta() ) > 28 ){ - lHalfJetSizeEta =1; //ie mJetSize/4 as in HF jets 2 in eta - } - - //if iPhi at the edge of the calo wrap round in phi - int ToweriPhi = Tower->iPhi( ); - if(iPhi() > (72 - mJetSize)) { - if(ToweriPhi>=1 && ToweriPhiiPhi())<4){ - std::cout<<"JET: ("<iEta()<< " , " <iPhi()<<" ), energy = " <E()+Tower->H()<iEta( ) == iEta() ) mAsymEta += 0; //do nothing - if( Tower->iEta( ) >= (iEta() + lHalfJetSizeEta) ) { - mAsymEta += lTowerEnergy; - } - else{ /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ - mAsymEta -= lTowerEnergy; - - } - - //if( Tower->iPhi( ) == iPhi() ) mAsymEta += 0; //do nothing - - if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ){ - mAsymPhi += lTowerEnergy; - - } - else{ /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ - mAsymPhi -= lTowerEnergy; - - - } - - }else{ //odd jet size: miss out central towers - - if( Tower->iEta( ) == (lHalfJetSizeEta + iEta()) ) { - mAsymEta += 0; //do nothing - } - else if( Tower->iEta( ) > (iEta() + lHalfJetSizeEta) ) { - mAsymEta += lTowerEnergy; - - }else /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ { - mAsymEta -= lTowerEnergy; - - } - // else it is in the middle so does not contribute to the asymmetry - - if( ToweriPhi == (lHalfJetSizePhi + iPhi()) ) { - mAsymPhi += 0; //do nothing - - } - else if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ) { - mAsymPhi += lTowerEnergy; - - }else /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ { - mAsymPhi -= lTowerEnergy; - - } - // else it is in the middle so does not contribute to the asymmetry - - } - } - - - void L1TowerJet::removeConstituent( const int &eta, const int &phi ) - { - L1CaloTowerRefVector::iterator lConstituent = getConstituent( eta, phi ); - if ( lConstituent != mConstituents.end() ) - { - int lHalfJetSizeEta( mJetSize >> 1 ); - int lHalfJetSizePhi( mJetSize >> 1 ); - int lTowerEnergy( (**lConstituent).E( ) + (**lConstituent).H( ) ); - - mE -= lTowerEnergy; - mConstituents.erase( lConstituent ); - - if( abs( iEta() ) > 28 ){ - lHalfJetSizeEta =1; //ie mJetSize/4 as in HF jets 2 in eta - } - int ToweriPhi = phi; - //if iPhi at the edge of the calo wrap round in phi - if(iPhi() > (72 - mJetSize)) { - if(ToweriPhi>=1 && ToweriPhi < mJetSize) ToweriPhi+=72; - } - - - if( mJetSize % 2 == 0 ){ //even jet size - - if( eta >= (iEta() + lHalfJetSizeEta) ) { - mAsymEta -= lTowerEnergy; - } - else{ /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ - mAsymEta += lTowerEnergy; - } - - - if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ){ - mAsymPhi -= lTowerEnergy; - - }else{ /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ - mAsymPhi += lTowerEnergy; - } - - - }else{ //odd jet size: miss out central towers - - if( eta == (lHalfJetSizeEta + iEta()) ) { - mAsymEta += 0; //do nothing - } - else if( eta > (iEta() + lHalfJetSizeEta) ) { - mAsymEta -= lTowerEnergy; - - }else /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ { - mAsymEta += lTowerEnergy; - - } - - if( ToweriPhi == (lHalfJetSizePhi + iPhi()) ) { - mAsymEta -= 0; //do nothing - - } - else if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ) { - mAsymPhi -= lTowerEnergy; - - }else /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ { - mAsymPhi += lTowerEnergy; - - } - } - } - } - - - const L1CaloTowerRefVector & L1TowerJet::getConstituents( ) const - { - return mConstituents; - } - - - L1CaloTowerRefVector::iterator L1TowerJet::getConstituent( const int &eta, const int &phi ) - { - for ( L1CaloTowerRefVector::iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ) - if ( (**lConstituentIt).iEta( ) == eta + mIeta && (**lConstituentIt).iPhi( ) == phi + mIphi ) - return lConstituentIt; - - return mConstituents.end(); - } - -} - - - - -namespace std -{ - bool operator<( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ) - { - if ( aLeft.E( ) == aRight.E( ) ) - { - // for two objects with equal energy, favour the more central one - return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); - } - else - { - return ( aLeft.E( ) < aRight.E( ) ); - } - } -} - - -// pretty print -std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1TowerJet & aL1TowerJet ) -{ - aStream << "L1TowerJet" - << " iEta=" << aL1TowerJet.iEta( ) - << " iPhi=" << aL1TowerJet.iPhi( ) - << "\n with constituents:\n"; - for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1TowerJet.getConstituents( ).begin( ); i < aL1TowerJet.getConstituents( ).end( ); ++i ) - aStream << " iEta=" << ( **i ).iEta( ) - << " iPhi=" << ( **i ).iPhi( ) - << " ET=" << ( **i ).E( ) - << "\n"; - return aStream; -} diff --git a/SimDataFormats/SLHC/src/L1TowerNav.cc b/SimDataFormats/SLHC/src/L1TowerNav.cc deleted file mode 100644 index db476338176cf..0000000000000 --- a/SimDataFormats/SLHC/src/L1TowerNav.cc +++ /dev/null @@ -1,59 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1TowerNav.h" - -#include - -int L1TowerNav::getOffsetIEta(int iEta,int offset) -{ - int newIEta=iEta+offset; - - //first check for a +ve to -ve transistion (there is no iEta==0) - if( (newIEta)/std::abs(newIEta) != iEta/std::abs(iEta) ) { - if(offset>0) newIEta++; //-ve to +ve - else newIEta--; //+ve to -ve - } - return newIEta; - //now bounds check - //if(std::abs(newIEta)<=kIEtaAbsHFMax) return newIEta; - // else return kNullIEta; - -} - -int L1TowerNav::getOffsetIPhi(int iEta,int iPhi,int offset) -{ - if(std::abs(iEta)<=kIEtaAbsHEMax) return getOffsetIPhiHBHE(iPhi,offset); - else return getOffsetIPhiHF(iPhi,offset); - -} - -int L1TowerNav::getOffsetIPhiHBHE(int iPhi,int offset) -{ - if(iPhi<=0 || iPhi>kIPhiMax) return kNullIPhi; - - offset=offset%kIPhiMax; - iPhi+=offset; - - //technically as we bounds check earilier and ensure the offset is 0 to 71, we can only be a max of 71 out - //however leave as is incase things change, for example we may wish to allow out of bounds phi - while(iPhi<=0) iPhi+=kIPhiMax; - while(iPhi>kIPhiMax) iPhi-=kIPhiMax; - - - return iPhi; -} - -int L1TowerNav::getOffsetIPhiHF(int iPhi,int offset) -{ - if(iPhi<=0 || iPhi>kIPhiMax) return kNullIPhi; - if((iPhi%kHFIPhiScale)!=1) return kNullIPhi; //invalid HF iPhi - - - offset=(offset*kHFIPhiScale)%kIPhiMax; - iPhi+=offset; - - //technically as we bounds check earilier and ensure the offset is 0 to 71, we can only be a max of 71 out - //however leave as is incase things change, for example we may wish to allow out of bounds phi - while(iPhi<=0) iPhi+=kIPhiMax; - while(iPhi>kIPhiMax) iPhi-=kIPhiMax; - - return iPhi; -} diff --git a/SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc b/SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc deleted file mode 100644 index 920362f615f9d..0000000000000 --- a/SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc +++ /dev/null @@ -1,7 +0,0 @@ -#include "SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h" -#include "FWCore/Utilities/interface/typelookup.h" - -// #define EVENTSETUP_DATA_REG(_mDataclass) TYPELOOKUP_DATA_REG(_mDataclass) - -TYPELOOKUP_DATA_REG( L1CaloTriggerSetup ); -// EVENTSETUP_DATA_REG(L1CaloTriggerSetup); diff --git a/SimDataFormats/SLHC/src/classes.h b/SimDataFormats/SLHC/src/classes.h deleted file mode 100644 index d5e06b38d93dc..0000000000000 --- a/SimDataFormats/SLHC/src/classes.h +++ /dev/null @@ -1,227 +0,0 @@ -/// //////////////////////////////////////// -/// Stacked Tracker Simulations /// -/// //////////////////////////////////////// - -#include "DataFormats/Common/interface/Wrapper.h" - -/**********************/ -/** L1 TRACK TRIGGER **/ -/**********************/ - -#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" - -namespace -{ - namespace - { - std::vector > STk_PC; - - Ref_PSimHit_ PSH_; - Ref_PixelDigi_ PD_; - - /// SimHit type - L1TkStub_PSimHit_ S_PSH_; - L1TkStub_PSimHit_Collection S_PSH_C; -// edm::Wrapper S_PSH_CW; - - L1TkTrack_PSimHit_ L1T_PSH_; - L1TkTrack_PSimHit_Collection L1T_PSH_C; -// edm::Wrapper L1T_PSH_CW; - - L1TkCluster_PSimHit_ CL_PSH_; -// L1TkCluster_PSimHit_Map CL_PSH_M; -// edm::Wrapper CL_PSH_MW; - L1TkCluster_PSimHit_Collection CL_PSH_C; - edm::Wrapper CL_PSH_CW; - L1TkCluster_PSimHit_Pointer CL_PSH_P; -// edm::Wrapper CL_PSH_PW; - - L1TkCluster_PixelDigi_ CL_PD_; -// L1TkCluster_PixelDigi_Map CL_PD_M; -// edm::Wrapper CL_PD_MW; - L1TkCluster_PixelDigi_Collection CL_PD_C; - edm::Wrapper CL_PD_CW; - L1TkCluster_PixelDigi_Pointer CL_PD_P; -// edm::Wrapper CL_PD_PW; - - /// PixelDigi type - L1TkStub_PixelDigi_ S_PD_; - L1TkStub_PixelDigi_Collection S_PD_C; - edm::Wrapper S_PD_CW; - - L1TkTrack_PixelDigi_ L1T_PD_; - L1TkTrack_PixelDigi_Collection L1T_PD_C; - edm::Wrapper L1T_PD_CW; - - edm::Ptr P_S_PD_C; - std::vector< std::vector< edm::Ptr > > S_PD_C_C; - edm::Wrapper > > > S_PD_C_CW; - - -/* - // Anders tracks - L1TStub L1TS; - edm::Wrapper L1TS_W; - edm::Wrapper > VEC_L1TS; - - L1TTrack L1T; - edm::Wrapper L1T_W; - edm::Wrapper > VEC_L1T; - - L1TTracks L1TTS; - edm::Wrapper L1TTS_W; - edm::Wrapper > VEC_L1TTS; -*/ - -// std::vector< std::vector< Ref_PixelDigi_ > > STV_PD; -// std::pair STP_STDI_I; // why ??? - -/* - std::pair P_INT_PSHC; - std::pair P_INT_PDC; - - std::pair > P_INT_PTRS_PSH; - std::pair > P_INT_PTRS_PD; -*/ - } -} - -/************************/ -/** L1 DT MUON TRIGGER **/ -/************************/ -/* -#include -#include - -#include "L1Trigger/DTTrackFinder/interface/L1MuDTTrack.h" -#include "L1Trigger/DTTrackFinder/src/L1MuDTAddressArray.h" -#include "L1Trigger/DTTrackFinder/src/L1MuDTSecProcId.h" -#include "L1Trigger/DTTrackFinder/src/L1MuDTTrackSegLoc.h" - -#include "SimDataFormats/SLHC/interface/DTBtiTrigger.h" -#include "SimDataFormats/SLHC/interface/DTTSPhiTrigger.h" -#include "SimDataFormats/SLHC/interface/DTTSThetaTrigger.h" -#include "SimDataFormats/SLHC/interface/DTMatch.h" -#include "SimDataFormats/SLHC/interface/DTMatchPt.h" -#include "SimDataFormats/SLHC/interface/DTMatchPtVariety.h" -#include "SimDataFormats/SLHC/interface/DTMatchPtAlgorithms.h" -#include "SimDataFormats/SLHC/interface/DTTrackerStub.h" -#include "SimDataFormats/SLHC/interface/DTTrackerTracklet.h" -#include "SimDataFormats/SLHC/interface/DTTrackerTrack.h" -#include "SimDataFormats/SLHC/interface/DTMatchesCollection.h" -#include "SimDataFormats/SLHC/interface/DTSeededStubTrack.h" - -namespace { - namespace { - edm::Wrapper Bti1; - std::vector Btv1; - edm::Wrapper > Btc1; - - edm::Wrapper phi1; - std::vector phiv1; - edm::Wrapper > phic1; - - edm::Wrapper DTPt1; - std::vector DTPtV1; - edm::Wrapper > DTPtW1; - - edm::Wrapper DTM1; - std::vector DTMv1; - edm::Wrapper > DTSMwv1; - - std::vector DTMm1; - edm::Wrapper > DTSMwm1; - - std::vector DTTSv1; - edm::Wrapper > DTTSwv1; - edm::Wrapper DTSMc1; - - std::vector DTTTv1; - edm::Wrapper > DTTTwv1; - - std::vector DTTTTv1; - edm::Wrapper > DTTTTwv1; - - edm::Wrapper TS1; - edm::Wrapper TT1; - edm::Wrapper XT1; - edm::Wrapper LT1; - std::set TSv1; - edm::Wrapper > TSwv1; - - DTSeededStubTrack DTTST1; - edm::Wrapper DTTSTw1; - std::vector DTTSTv1; - edm::Wrapper > DTTSTa1; - DTSeededStubTracksCollection DTTSTc1; - edm::Wrapper DTTSTcw1; - - } -} -*/ - -/*********************/ -/** L1 CALO TRIGGER **/ -/*********************/ - -#include "SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h" -#include "SimDataFormats/SLHC/interface/L1CaloTower.h" -#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" -#include "SimDataFormats/SLHC/interface/L1CaloCluster.h" -#include "SimDataFormats/SLHC/interface/L1CaloClusterFwd.h" -#include "SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h" -#include "SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h" -#include "SimDataFormats/SLHC/interface/L1CaloJet.h" -#include "SimDataFormats/SLHC/interface/L1CaloJetFwd.h" -#include "SimDataFormats/SLHC/interface/L1CaloRegion.h" -#include "SimDataFormats/SLHC/interface/L1CaloRegionFwd.h" - -#include "SimDataFormats/SLHC/interface/L1TowerJet.h" -#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" - -#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" - -namespace { - namespace { - - l1slhc::L1CaloTower tower; - std::vector l1calotl; - l1slhc::L1CaloTowerRef towerRef; - - l1slhc::L1CaloTowerCollection towerColl; - l1slhc::L1CaloTowerRefVector towerRefColl; - edm::Wrapper wtowerColl; - edm::Wrapper wtowerRefColl; - - l1slhc::L1CaloCluster calocl; - std::vector l1calocl; - l1slhc::L1CaloClusterCollection l1caloclcoll; - edm::Wrapper< l1slhc::L1CaloClusterCollection > wl1calocl; - - l1slhc::L1CaloClusterWithSeed calocls; - std::vector l1calocls; - l1slhc::L1CaloClusterWithSeedCollection l1caloclscoll; - edm::Wrapper< l1slhc::L1CaloClusterWithSeedCollection > wl1calocls; - - l1slhc::L1CaloJet calojet; - std::vector l1calojetvec; - l1slhc::L1CaloJetCollection l1calojetcoll; - edm::Wrapper< l1slhc::L1CaloJetCollection > wl1calojetcol; - - l1slhc::L1CaloRegion caloregion; - std::vector l1caloregion; - l1slhc::L1CaloRegionRef caloregionRef; - l1slhc::L1CaloRegionCollection caloregionC; - l1slhc::L1CaloRegionRefVector caloregionRefC; - - edm::Wrapper wcaloregionC; - edm::Wrapper qaloregionRefC; - - l1slhc::L1TowerJet towerjet; - std::vector l1towerjetvec; - l1slhc::L1TowerJetCollection l1towerjetcoll; - edm::Wrapper< l1slhc::L1TowerJetCollection > wl1towerjetcol; - - } -} - diff --git a/SimDataFormats/SLHC/src/classes_def.xml b/SimDataFormats/SLHC/src/classes_def.xml deleted file mode 100644 index ed0999845325b..0000000000000 --- a/SimDataFormats/SLHC/src/classes_def.xml +++ /dev/null @@ -1,206 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From e2c8ff61e1f499c4b58692614e6f5e01b349cb63 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sat, 24 May 2014 12:37:53 +0200 Subject: [PATCH 005/252] Nick's latest L1Jets (see TTI of May 16, 2014) --- .../L1CaloTrigger/data/pu140.LUT | 14 + .../L1CaloTrigger/interface/LUT.h | 73 ++ .../plugins/L1CalibFilterTowerJetProducer.cc | 329 ++++-- .../plugins/L1EnergySumProducer.cc | 238 +++++ .../plugins/L1TowerFwdJetProducer.cc | 5 +- .../plugins/L1TowerJetCentralityFilter.cc | 514 +++++++++ .../plugins/L1TowerJetFilter1D.cc | 220 ---- .../plugins/L1TowerJetFilter2D.cc | 208 ---- .../plugins/L1TowerJetPUEstimator.cc | 312 +++++- .../plugins/L1TowerJetPUSubtractedProducer.cc | 214 +++- .../plugins/L1TowerJetProducer.cc | 193 ++-- .../python/SLHCCaloTrigger_cff.py | 6 +- .../python/SLHCCaloTrigger_cfi.py | 133 ++- .../test/test_L1TkEGamma_cfg.py | 29 +- .../L1TrackTrigger/test/test_L1TkJets_cfg.py | 5 +- SimDataFormats/SLHC/interface/L1TowerJet.h | 114 +- SimDataFormats/SLHC/src/L1TowerJet.cc | 994 ++++++++++++------ 17 files changed, 2516 insertions(+), 1085 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc delete mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter1D.cc delete mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter2D.cc diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT b/SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT new file mode 100644 index 0000000000000..dfdb1b10087b0 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT @@ -0,0 +1,14 @@ +0.907747 6.468076 -0.197948 0.045329 9.976110 4.208358, +1.067557 5.477807 9.281958 0.538236 0.429327 2.731133, +0.987411 9.956708 1.369532 0.155267 2.021796 3.518603, +0.969114 9.990500 1.405063 0.169569 1.549711 3.621829, +0.940879 9.875660 2.331352 0.235164 0.821025 3.428161, +1.076993 5.883136 -0.045208 0.287680 0.913810 3.389504, +1.079105 6.086415 9.520870 0.584415 0.396147 2.754608, +1.079105 6.086415 9.520870 0.584415 0.396147 2.754608, +1.076993 5.883136 -0.045208 0.287680 0.913810 3.389504, +0.940879 9.875660 2.331352 0.235164 0.821025 3.428161, +0.969114 9.990500 1.405063 0.169569 1.549711 3.621829, +0.987411 9.956708 1.369532 0.155267 2.021796 3.518603, +1.067557 5.477807 9.281958 0.538236 0.429327 2.731133, +0.907747 6.468076 -0.197948 0.045329 9.976110 4.208358, diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h b/SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h new file mode 100644 index 0000000000000..550c5ab1ee55c --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h @@ -0,0 +1,73 @@ +#ifndef LUT_H +#define LUT_H + +#include + +class LUT{ + + + public: + + LUT(): columns(0), rows(0){} + LUT( int nColumns, int nRows ): columns( nColumns ), rows( nRows ){} + + void loadLUT( TString filename ); + + + int getColumns(){ return columns; } + int getRows(){ return rows; } + + // Return a specific LUT element. Note: numbering starts from 0 + double getElement( int row, int column ){ + int index = column + row*columns; + return LUTArr[ index ]; + } + + + private: + std::vector LUTArr; + + // LUT dimensions + int columns; + int rows; + + +}; + + + + +// Read a LUT stored in a textfile and store in a flat vector +void +LUT::loadLUT( TString filename ){ + + std::ifstream iReadLUT( filename ); + + if(!iReadLUT){ + throw cms::Exception("MissingLUT") << "A LUT could not be loaded as the file: '" << filename << "' does not exist, check the path of all LUTs.\n"; + } + + // Read and store the LUT in a flat vector + while (!iReadLUT.eof()){ + TString element; + iReadLUT >> element; + if (element != ""){ + LUTArr.push_back( element.Atof() ); + } + } + + // Validate input + if ( int( LUTArr.size() ) != columns*rows ){ + + throw cms::Exception("InconsistentLUTEntries") << "LUT dimensions specified:\n" << "\tRows = " << rows << "\n\tColumns = " << columns + << "\n\nExpected " << rows*columns << " entries in LUT but read " << LUTArr.size() + << " entries, check that the input LUT file contains the same dimensions as the LUT object.\n"; + + } + +} + + + +#endif + diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc index c9c21241adef9..d49a49fd246d7 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc @@ -5,7 +5,7 @@ // /**\class CalibTowerJetCollection L1CalibFilterTowerJetProducer.cc MVACALIB/L1CalibFilterTowerJetProducer/src/L1CalibFilterTowerJetProducer.cc - Description: [one line class summary] + Description: Mk1 developer release Implementation: [Notes on implementation] @@ -13,9 +13,9 @@ // // Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, // Created: Mon Nov 19 10:20:06 CET 2012 -// $Id: L1CalibFilterTowerJetProducer.cc,v 1.5 2013/03/21 16:11:18 rlucas Exp $ -// +// $Id: L1CalibFilterTowerJetProducer.cc,v 1.7 2013/05/16 17:35:30 mbaber Exp $ // +// Modifications : Mark Baber Imperial College, London // system include files @@ -40,11 +40,22 @@ #include "FWCore/Framework/interface/LuminosityBlock.h" #include #include +#include -#include "TMVA/Tools.h" -#include "TMVA/Reader.h" #include "FWCore/ParameterSet/interface/FileInPath.h" + +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h" + + +// Ranking function for sort +bool towerJetRankDescending ( l1slhc::L1TowerJet jet1, l1slhc::L1TowerJet jet2 ){ return ( jet1.p4().Pt() > jet2.p4().Pt() ); } +bool L1JetRankDescending ( l1extra::L1JetParticle jet1, l1extra::L1JetParticle jet2 ){ return ( jet1.p4().Pt() > jet2.p4().Pt() ); } + + + + + // // class declaration // @@ -74,147 +85,160 @@ class L1CalibFilterTowerJetProducer : public edm::EDProducer { virtual void endRun(edm::Run&, edm::EventSetup const&); virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); - + + virtual l1extra::L1JetParticleCollection calibrateJetCollection( edm::Handle UncalibJet_Tower, LUT calibLUT ); + // ----------member data --------------------------- ParameterSet conf_; - float l1Pt, l1Eta; + // Jet pt threshold for jet energies used in the calculation of Ht, mHt + double energySumsJetPtThreshold; + + // L1 pT calibration threshold, minimum L1 jet pT to apply correction + double pTCalibrationThreshold; + // Boundaries of eta segmentation for calibration + std::vector etaRegionSlice; + + // Number of parameters used in calibration + uint calibParameters; + + // Calibration look up table + LUT calibrationLUT; + TString lutFilename; + }; L1CalibFilterTowerJetProducer::L1CalibFilterTowerJetProducer(const edm::ParameterSet& iConfig): conf_(iConfig) { + produces( "UncalibratedTowerJets" ) ; + produces( "CalibratedTowerJets" ) ; + produces( "TowerMHT" ) ; - produces("CenJets"); -// produces("CalibFwdJets"); - produces< L1JetParticleCollection >( "Cen8x8" ) ; -// produces< L1JetParticleCollection >( "Fwd8x8" ) ; - produces< L1EtMissParticleCollection >( "TowerMHT" ) ; - produces("TowerHT"); - + // Read the calibration eta segementation + etaRegionSlice = iConfig.getParameter< std::vector >("EtaRegionSlice"); + sort (etaRegionSlice.begin(), etaRegionSlice.end()); // ensure the bins are in ascending order + + + edm::FileInPath LUTFile = iConfig.getParameter("CalibrationLUTFile"); + calibParameters = iConfig.getParameter< uint >("CalibrationParameters"); + + // Calculate LUT dimensions and initialise LUT + int rows = int(calibParameters); + int columns = etaRegionSlice.size() - 1; + calibrationLUT = LUT( rows, columns ); + + // Load the look up table + calibrationLUT.loadLUT( LUTFile.fullPath().c_str() ); + + // Extract jet pT threshold for Ht, mHt calculation + energySumsJetPtThreshold = iConfig.getParameter ("EnergySumsJetPtThreshold"); + + // Minimum PT for calibration. Remove jets which cannot be calibrated + pTCalibrationThreshold = iConfig.getParameter ("pTCalibrationThreshold"); + } L1CalibFilterTowerJetProducer::~L1CalibFilterTowerJetProducer() { - } void L1CalibFilterTowerJetProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { - bool evValid =true; + bool evValid = true; + + auto_ptr outputCalibratedL1Extra(new L1JetParticleCollection()); + auto_ptr outputUncalibratedL1Extra(new L1JetParticleCollection()); + - double ht=(0); - auto_ptr< L1TowerJetCollection > outputCollCen(new L1TowerJetCollection()); -// auto_ptr< L1TowerJetCollection > outputCollFwd(new L1TowerJetCollection()); - auto_ptr< L1JetParticleCollection > outputExtraCen(new L1JetParticleCollection()); - auto_ptr< L1JetParticleCollection > outputExtraFwd(new L1JetParticleCollection()); auto_ptr outputmht(new L1EtMissParticleCollection()); - auto_ptr outRho(new double()); - auto_ptr outHT(new double()); - - //read in collection depending on parameteres in SLHCCaloTrigger_cfi.py - edm::Handle PUSubCen; - iEvent.getByLabel(conf_.getParameter("PUSubtractedCentralJets"), PUSubCen); - if(!PUSubCen.isValid()){ - edm::LogWarning("MissingProduct") << conf_.getParameter("PUSubtractedCentralJets") << std::endl; - evValid=false; + auto_ptr outHT (new double()); + + + // Read in collection depending on parameters in SLHCCaloTrigger_cfi.py + edm::Handle UncalibratedTowerJets; + iEvent.getByLabel(conf_.getParameter("UncalibratedTowerJets"), UncalibratedTowerJets); + if(!UncalibratedTowerJets.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("UncalibratedTowerJets") << std::endl; + evValid = false; } if( evValid ) { + + double ht(0); + math::PtEtaPhiMLorentzVector mht, tempJet; + + // Perform jet eta-pT dependent pT calibrations + l1extra::L1JetParticleCollection calibJets = calibrateJetCollection( UncalibratedTowerJets, calibrationLUT ); - /////////////////////////////////////////////////// - // JET VALUES - /////////////////////////////////////////////////// - - //Value of HT - ht=0; - //vector of MHT - math::PtEtaPhiMLorentzVector mht, upgrade_jet; - - //Produce calibrated pt collection: central jets - for (L1TowerJetCollection::const_iterator il1 = PUSubCen->begin(); - il1!= PUSubCen->end() ; - ++il1 ) - { - - L1TowerJet h=(*il1); + // Store calibrated jets and perform calibrated jet energy sums + for ( l1extra::L1JetParticleCollection::const_iterator calib_Itr = calibJets.begin(); calib_Itr!= calibJets.end() ; ++calib_Itr ){ - // float l1Eta_ = il1->p4().eta(); - // float l1Phi_ = il1->p4().phi(); - float l1Pt_ = il1->p4().Pt(); + L1JetParticle calibJet = (*calib_Itr); + outputCalibratedL1Extra->push_back( calibJet ); - //weighted eta is still not correct - //change the contents out p4, upgrade_jet when it is corrected - float l1wEta_ = il1->WeightedEta(); - float l1wPhi_ = il1->WeightedPhi() ; + // Add jet to energy sums if energy is above threshold + if( calibJet.p4().pt() > energySumsJetPtThreshold ){ + tempJet.SetCoordinates( calibJet.p4().pt(), calibJet.p4().eta(), calibJet.p4().phi(), calibJet.p4().M() ); + ht += tempJet.pt(); + mht += tempJet; - // Currently no calibration is applied - double cal_Pt_ = l1Pt_; + } - math::PtEtaPhiMLorentzVector p4; + } - p4.SetCoordinates(cal_Pt_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); - h.setP4(p4); - outputCollCen->insert( l1wEta_ , l1wPhi_ , h ); - upgrade_jet.SetCoordinates(cal_Pt_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); + + // Store uncalibrated jet collection + for ( L1TowerJetCollection::const_iterator Uncalib_Itr = UncalibratedTowerJets->begin(); Uncalib_Itr != UncalibratedTowerJets->end(); ++Uncalib_Itr ){ + + L1TowerJet uncalibJet = (*Uncalib_Itr); - //if the calibrated jet energy is > 15GeV add to ht,mht - if( cal_Pt_>15 ) ht+=cal_Pt_; - if( cal_Pt_>15 ) mht+=upgrade_jet; + math::PtEtaPhiMLorentzVector tempJet; + tempJet.SetCoordinates( uncalibJet.p4().pt(), uncalibJet.p4().eta(), uncalibJet.p4().phi(), uncalibJet.p4().M() ); - // add jet to L1Extra list - outputExtraCen->push_back( L1JetParticle( math::PtEtaPhiMLorentzVector( cal_Pt_, l1wEta_, l1wPhi_, 0. ), - Ref< L1GctJetCandCollection >(), 0 ) - ); + outputUncalibratedL1Extra->push_back( l1extra::L1JetParticle( tempJet, l1extra::L1JetParticle::JetType::kCentral, 0 ) ); } - - - + // create L1Extra object - math::PtEtaPhiMLorentzVector p4tmp = math::PtEtaPhiMLorentzVector( mht.pt(), 0., mht.phi(), 0. ) ; + math::PtEtaPhiMLorentzVector p4tmp = math::PtEtaPhiMLorentzVector( mht.pt(), 0., mht.phi(), 0. ); - L1EtMissParticle l1extraMHT(p4tmp, - L1EtMissParticle::kMHT, - ht, - Ref< L1GctEtMissCollection >(), - Ref< L1GctEtTotalCollection >(), - Ref< L1GctHtMissCollection >(), - Ref< L1GctEtHadCollection >(), - 0); - - outputmht->push_back(l1extraMHT); - *outHT = ht; - - iEvent.put(outputCollCen,"CenJets"); -// iEvent.put(outputCollFwd,"CalibFwdJets"); - iEvent.put(outputExtraCen,"Cen8x8"); -// iEvent.put(outputExtraFwd,"Fwd8x8"); - iEvent.put(outputmht,"TowerMHT" ); - iEvent.put(outHT,"TowerHT"); - - - } + L1EtMissParticle l1extraMHT(p4tmp, L1EtMissParticle::kMHT, ht, + Ref< L1GctEtMissCollection >(), Ref< L1GctEtTotalCollection >(), + Ref< L1GctHtMissCollection >(), Ref< L1GctEtHadCollection >() , 0); + + outputmht->push_back(l1extraMHT); + + iEvent.put( outputUncalibratedL1Extra,"UncalibratedTowerJets"); + iEvent.put( outputCalibratedL1Extra, "CalibratedTowerJets"); + + + iEvent.put( outputmht, "TowerMHT" ); + + + } } // ------------ method called once each job just before starting event loop ------------ void -L1CalibFilterTowerJetProducer::beginJob() { +L1CalibFilterTowerJetProducer::beginJob() +{ } // ------------ method called once each job just after ending the event loop ------------ void -L1CalibFilterTowerJetProducer::endJob() { +L1CalibFilterTowerJetProducer::endJob() +{ } // ------------ method called when starting to processes a run ------------ @@ -251,6 +275,123 @@ L1CalibFilterTowerJetProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions.addDefault(desc); } +// +// member functions +// + + + + +// Calibrates an input TowerJet collection with the specified input look up table. The resulting calibrated jets are sorted in pT +// and are returned as a L1JetParticleCollection. +l1extra::L1JetParticleCollection +L1CalibFilterTowerJetProducer::calibrateJetCollection( edm::Handle UncalibJet_Tower, LUT calibLUT ){ + + + + std::vector unsortedCalibratedL1Jets; + + // Calibrate jets with LUT + for ( L1TowerJetCollection::const_iterator Uncalib_It = UncalibJet_Tower->begin(); Uncalib_It != UncalibJet_Tower->end(); ++Uncalib_It ){ + + L1TowerJet uncalibJet = (*Uncalib_It); + + // Jet pT threshold for calibration, only calibrate above threshold + if ( uncalibJet.p4().pt() < pTCalibrationThreshold ){ + + // Uncomment to Store un-calibrated L1Jet + // ------------------------------------------------------------ + // Create un-sorted calibrated L1Jet + //math::PtEtaPhiMLorentzVector tempJet; + //tempJet.SetCoordinates( uncalibJet.p4().pt(), uncalibJet.p4().eta(), uncalibJet.p4().phi(), uncalibJet.p4().M() ); + //unsortedCalibratedL1Jets.push_back( l1extra::L1JetParticle( tempJet, l1extra::L1JetParticle::JetType::kCentral, 0 ) ); + + continue; + } + + // Find in which Eta bin the jet resides + uint pEta; + for (pEta = 1; pEta < etaRegionSlice.size(); ++pEta){ + + double eta = uncalibJet.p4().eta(); + + // Get Eta bin lower and upper bounds + double EtaLow = etaRegionSlice[ pEta - 1]; + double EtaHigh = etaRegionSlice[ pEta ]; + // Eta resides within current boundary + if ( (eta >= EtaLow) && (eta < EtaHigh) ){ + break; // found the correct eta bin, break + } + + } + + // Extract eta dependent correction factors + // ************************************************** + int etaIndex = pEta - 1;// Correct for array starting at zero + + + // Perform jet calibration + // ------------------------------------------------------------ + double unCorrectedPt = uncalibJet.p4().pt(); + double correctedPt = 0; + + + // Get calibration parameters for given eta bin + double p0 = calibLUT.getElement( etaIndex, 0 ); + double p1 = calibLUT.getElement( etaIndex, 1 ); + double p2 = calibLUT.getElement( etaIndex, 2 ); + double p3 = calibLUT.getElement( etaIndex, 3 ); + double p4 = calibLUT.getElement( etaIndex, 4 ); + double p5 = calibLUT.getElement( etaIndex, 5 ); + + + + // Calucualte the jet correction + double logPt = log( unCorrectedPt ); + + double term1 = p1 / ( logPt * logPt + p2 ); + double term2 = p3 * exp( -p4*((logPt - p5)*(logPt - p5)) ); + + // Calculate the corrected Pt + double correction = (p0 + term1 + term2); + //double invCorrection = 1/correction; + + // Use invereted correction for Phase 2 + //correctedPt = invCorrection*unCorrectedPt; + correctedPt = correction*unCorrectedPt; + + + + + + + // Create and store unsorted calibrated L1Jet collection + // ------------------------------------------------------------ + + // Create un-sorted calibrated L1Jet + math::PtEtaPhiMLorentzVector tempJet; + tempJet.SetCoordinates( correctedPt, uncalibJet.p4().eta(), uncalibJet.p4().phi(), uncalibJet.p4().M() ); + unsortedCalibratedL1Jets.push_back( l1extra::L1JetParticle( tempJet, l1extra::L1JetParticle::JetType::kCentral, 0 ) ); + + } + + // Sort calibrated jets + std::sort( unsortedCalibratedL1Jets.begin(), unsortedCalibratedL1Jets.end(), L1JetRankDescending ); + + // Return the sorted, calibrated jets + return unsortedCalibratedL1Jets; + + +} + + + + + + + + + diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc new file mode 100644 index 0000000000000..bea1238fef5df --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc @@ -0,0 +1,238 @@ +// -*- C++ -*- +// +// Package: L1CaloTrigger +// Class: L1EnergySumProducer +// +/**\class L1EnergySumProducer L1EnergySumProducer.cc SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc + + Description: Produces energy sums from L1 calorimeter objects + + Implementation: + [Notes on implementation] +*/ +// +// Original Author: Mark Baber +// Created: Tue, 18 Mar 2014 20:07:42 GMT +// $Id$ +// +// + + +// system include files +#include + +// user include files +#include +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "CommonTools/UtilAlgos/interface/TFileService.h" + +#include "TLorentzVector.h" +#include "DataFormats/VertexReco/interface/Vertex.h" +#include "DataFormats/VertexReco/interface/VertexFwd.h" +#include "DataFormats/L1Trigger/interface/L1JetParticle.h" +#include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticle.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticleFwd.h" +#include "SimDataFormats/SLHC/interface/L1TowerJet.h" +#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" +#include "FWCore/Framework/interface/LuminosityBlock.h" +#include + + +#include "FWCore/ParameterSet/interface/FileInPath.h" +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + + +#include "DataFormats/L1Trigger/interface/L1EtMissParticle.h" +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/TriggerTowerGeometry.h" + + + +// +// class declaration +// + +class L1EnergySumProducer : public edm::EDProducer { + public: + explicit L1EnergySumProducer(const edm::ParameterSet&); + ~L1EnergySumProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + private: + virtual void beginJob() override; + virtual void produce(edm::Event&, const edm::EventSetup&) override; + virtual void endJob() override; + + //virtual void beginRun(edm::Run const&, edm::EventSetup const&) override; + //virtual void endRun(edm::Run const&, edm::EventSetup const&) override; + //virtual void beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override; + //virtual void endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override; + + // ----------member data --------------------------- + edm::ParameterSet conf_; + + // Tower geometry converter + TriggerTowerGeometry mTowerGeo; + + +}; + +// +// constants, enums and typedefs +// + + +// +// static data member definitions +// + +// +// constructors and destructor +// +L1EnergySumProducer::L1EnergySumProducer(const edm::ParameterSet& iConfig): conf_(iConfig) +{ + + produces( "MET" ); + + +} + + +L1EnergySumProducer::~L1EnergySumProducer() +{ +} + + +// +// member functions +// + +// ------------ method called to produce the data ------------ +void +L1EnergySumProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + + std::auto_ptr outputMET(new l1extra::L1EtMissParticleCollection()); + + + // TT collection + edm::Handle caloTowers; + iEvent.getByLabel(conf_.getParameter("CalorimeterTowers"), caloTowers); + if(!caloTowers.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("CalorimeterTowers") << std::endl; + } + + + + math::PtEtaPhiMLorentzVector MET, protoMET; + double ET = 0; + + // Calculate TT-energy sums + for( l1slhc::L1CaloTowerCollection::const_iterator lTT_It = caloTowers->begin(); + lTT_It != caloTowers->end() ; ++lTT_It ){ + + // Energies in GeV + double E = 0.5*lTT_It->E(); + double H = 0.5*lTT_It->H(); + int iEta = lTT_It->iEta(); + int iPhi = lTT_It->iPhi(); + + // double Eta = mTowerGeo.eta(iEta); + double Phi = mTowerGeo.phi(iPhi); + + + // Restrict to central TTs + if (abs(iEta) > 28) + continue; + + + // Calculate MET + protoMET.SetCoordinates( E + H, 0, Phi, 0 ); + MET += protoMET; + ET += E + H; + + + } + + + + l1extra::L1EtMissParticle l1extraMET( MET, l1extra::L1EtMissParticle::kMET, ET, + edm::Ref< L1GctEtMissCollection >(), edm::Ref< L1GctEtTotalCollection >(), + edm::Ref< L1GctHtMissCollection >(), edm::Ref< L1GctEtHadCollection >() , 0); + + outputMET->push_back( l1extraMET ); + + + + iEvent.put( outputMET, "MET" ); + +} + +// ------------ method called once each job just before starting event loop ------------ +void +L1EnergySumProducer::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1EnergySumProducer::endJob() { +} + +// ------------ method called when starting to processes a run ------------ +/* +void +L1EnergySumProducer::beginRun(edm::Run const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1EnergySumProducer::endRun(edm::Run const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1EnergySumProducer::beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1EnergySumProducer::endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1EnergySumProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1EnergySumProducer); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc index 713edc4d071d3..8e1de2af33593 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc @@ -1,3 +1,6 @@ +// Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, +// Modifications : Mark Baber Imperial College, London + #include "SLHCUpgradeSimulations/L1CaloTrigger/interface/L1CaloAlgoBase.h" #include "SimDataFormats/SLHC/interface/L1TowerJet.h" @@ -72,7 +75,7 @@ void L1TowerFwdJetProducer::algorithm( const int &aEta, const int &aPhi ) int lTowerIndex = mCaloTriggerSetup->getBin( aEta, aPhi ); std::pair < int, int > lTowerEtaPhi = mCaloTriggerSetup->getTowerEtaPhi( lTowerIndex ); - l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mHFJetShapeMap.size() , lTowerEtaPhi.first , lTowerEtaPhi.second ); + l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mHFJetShapeMap , lTowerEtaPhi.first , lTowerEtaPhi.second ); if(aEta>=60 || aEta<4){ diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc new file mode 100644 index 0000000000000..05437098c9ad8 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc @@ -0,0 +1,514 @@ +// Original Author: Mark Baber Imperial College, London + + + +// system include files +#include +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "CommonTools/UtilAlgos/interface/TFileService.h" + +#include "TLorentzVector.h" +#include "DataFormats/VertexReco/interface/Vertex.h" +#include "DataFormats/VertexReco/interface/VertexFwd.h" +#include "DataFormats/L1Trigger/interface/L1JetParticle.h" +#include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticle.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticleFwd.h" +#include "SimDataFormats/SLHC/interface/L1TowerJet.h" +#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" +#include "FWCore/Framework/interface/LuminosityBlock.h" +#include +#include + +#include "FWCore/ParameterSet/interface/FileInPath.h" + +// Bitonic sorting functions +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/BitonicSort.hpp" + +#include + +// +// class declaration +// + + +using namespace l1slhc; +using namespace edm; +using namespace std; +using namespace reco; +using namespace l1extra; + + + + + +struct tempJet +{ + + tempJet( ) : + mJet( NULL ) + {} //constructor + + + tempJet( const l1slhc::L1TowerJet& aJet ) : + mJet( &aJet ) + { /*....*/ } //constructor + + const l1slhc::L1TowerJet* mJet; +}; + + +/* +bool operator> ( tempJet& aA , tempJet& aB ) +{ + + if( aA.mJet == NULL ) return false; //Jets that don't exist: require 128 or 64 spots + if( aB.mJet == NULL ) return true; + + if ( aA.mJet->E() > aB.mJet->E() ) return true; + if ( aA.mJet->E() < aB.mJet->E() ) return false; + + + //those aA and aB with the same energy are all that remain + // if ( *(aA.mComparisonDirection) == phi ){ + return ( abs( aA.mJet-> AsymPhi() ) <= abs( aB.mJet->AsymPhi() ) ); + // }else{ + return ( abs( aA.mJet-> AsymEta() ) <= abs( aB.mJet->AsymEta() ) ); + // } + +} +*/ + + +bool operator>( tempJet & aLeft, tempJet & aRight ){ + // std::cout << "works???\n"; + + +// std::cout << "Pt1 = " << aLeft.mJet->Pt() << "\tPt2 = " << aRight.mJet->Pt() +// << "\tiEta1 = " << aLeft.mJet->iEta() << "\tiPhi1 = " << aLeft.mJet->iPhi() +// << "\tiEta2 = " << aRight.mJet->iEta() << "\tiPhi2 = " << aRight.mJet->iPhi() +// << "\tCent1 = " << aLeft.mJet->Centrality() << "\tCent2 = " << aRight.mJet->Centrality(); + + + if ( aLeft.mJet->Pt() == aRight.mJet->Pt() ){ + + // Degenerate energies + // ~~~~~~~~~~~~~~~~~~~ + // Order by the lowest centrality, for degenerate centralities favour the right jet to avoid needless sorting. + // Result: Favours jets with the lowest iEta and iPhi, due to the original jet ordering + + // std::cout << "\t1>2 = " << ( aLeft.mJet->Centrality() < aRight.mJet->Centrality() ) << "\n"; + return ( aLeft.mJet->Centrality() < aRight.mJet->Centrality() ); + + } + else{ + + // Rank by pT + // ~~~~~~~~~~ + // std::cout << "\t1>2 = " << ( aLeft.mJet->Pt() > aRight.mJet->Pt() ) << " ENERGIES NOT DEGENERATE\n"; + return ( aLeft.mJet->Pt() > aRight.mJet->Pt() ); + } + + +} + +// Sort with srd::sort +bool tempJetSort (tempJet aJet, tempJet bJet) { return ( aJet>bJet); } +// + + + + + + +class L1TowerJetCentralityFilter : public edm::EDProducer { + public: + explicit L1TowerJetCentralityFilter(const edm::ParameterSet&); + ~L1TowerJetCentralityFilter(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + virtual void beginRun(edm::Run&, edm::EventSetup const&); + virtual void endRun(edm::Run&, edm::EventSetup const&); + virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // ----------member data --------------------------- + ParameterSet conf_; + + // Limit of the number of jets to be retained in filtering + int mNumOfOutputJets; + + std::auto_ptr < l1slhc::L1TowerJetCollection > mOutputCollection; + + +}; + +// +// constructors and destructor +// + +L1TowerJetCentralityFilter::L1TowerJetCentralityFilter(const edm::ParameterSet& iConfig): + conf_(iConfig), + mNumOfOutputJets( iConfig.getParameter("NumOfOutputJets") ) +{ + // produces< l1slhc::L1TowerJetCollection >("FilteredTowerJets"); + produces< l1slhc::L1TowerJetCollection >( ); + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetCentralityFilter\n----------------------------------------\n\n"; + +} + +L1TowerJetCentralityFilter::~L1TowerJetCentralityFilter() +{ +} + + + + +// ------------ method called to produce the data ------------ +void +L1TowerJetCentralityFilter::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + + bool evValid = true; + + edm::Handle< L1TowerJetCollection > preFiltJets; + iEvent.getByLabel(conf_.getParameter("PreFilteredJets"), preFiltJets); + if(!preFiltJets.isValid()){ + evValid=false; + } + + if( !evValid ) { + throw cms::Exception("MissingProduct") << conf_.getParameter("preFiltJets") + << std::endl; + } + else{ + + auto_ptr< L1TowerJetCollection > filteredJets(new L1TowerJetCollection()); // Overlap filtered jets + + + + // std::cout << "FLAG\n\n"; + + // std::vector < const l1slhc::L1TowerJet* > lTowerVector; + std::vector < tempJet > tempJetVec; + + + + for (L1TowerJetCollection::const_iterator jetIt = preFiltJets->begin(); jetIt!= preFiltJets->end(); ++jetIt ){ + + L1TowerJet h = *jetIt; + + tempJetVec.push_back( tempJet( *jetIt ) ); + + // FUNKY, SORT THIS OUT... + // lTowerVector.push_back( &(*jetIt) ); + + // lTowerVector.push_back( *jetIt ); + + } + + + + + + + + // Resize array to a power of 2 for the Bitonic sort algorithm + // Find the smallest power of 2 that contains the require jet multiplicity + + + // PERHAPS CALCULATE THE NEAREST POWER OF TWO, THIS IS OVERKILL. I.E BIT SHIFT LEFT AND "AND" THE OUTPUT TO GET MSB + // lTowerVector.resize(4096); + +// for (unsigned int i = 0; ((i < lTowerVector.size()) && (i < 100)); i++){ +// if ( lTowerVector[i] != NULL ){ +// std::cout << "ET = " << lTowerVector[i]->Pt() << "\tCentrality = " << lTowerVector[i]->Centrality() +// << i << "\tiEta = " << lTowerVector[i]->iEta() << "\tiPhi = " << lTowerVector[i]->iPhi() +// << "\n"; +// } +// } + + // lJetWrapper2DVector.resize(4096); //resize to nearest power of 2 to 72*56 for the bitonic sort algorithm + + + + + /* + // Fill the rest with NULL jets, INCREDIBLE INEFFICIENCT, USE THE RESIZE ROUTINE!!!!!!!!!!!!!!!!! + for (int i = lTowerVector.size(); i <= 4096; i++){ + + l1slhc::L1TowerJet* mJet(NULL); + + lTowerVector.push_back( mJet ); + } + + std::cout << lTowerVector.size() << "\n\n\n"; + + + // PERHAPS CALCULATE THE NEAREST POWER OF TWO, THIS IS OVERKILL. I.E BIT SHIFT LEFT AND "AND" THE OUTPUT TO GET MSB + + lTowerVector.resize(4096); //resize to nearest power of 2 to 72*56 for the bitonic sort algorithm + */ + + + // ********************************************************************** + // * Rank jets * + // ********************************************************************** + // + // Rank jets in descending Et, in the case of degenerate energies, rank by the + // 'centrality' secondary sort parameter. + // --------------------------------------------------------------------- + + // sort jets around eta/phi by energy and relevant asymmetry parameter +// L1TowerJetCollection::iterator lStart( preFiltJets->begin() ); +// L1TowerJetCollection::iterator lEnd( preFiltJets->end() ); + +// std::cout << "Prior to start\n"; +// // std::vector< L1TowerJet >::iterator lStart( filteredJets->begin() ); +// std::vector< const l1slhc::L1TowerJet* >::iterator lStart( lTowerVector.begin() ); +// std::cout << "Prior to End\n"; +// // std::vector< L1TowerJet >::iterator lEnd( filteredJets->end() ); +// std::vector< const l1slhc::L1TowerJet* >::iterator lEnd( lTowerVector.end() ); +// std::cout << "Prior to sort\n"; +// BitonicSort< const l1slhc::L1TowerJet* >( down , lStart , lEnd ); +// std::cout << "After sort\n"; + + +/* + for (unsigned int i = 0; ((i < tempJetVec.size()) && (i < 100)); i++){ + if ( tempJetVec[i].mJet != NULL ){ + std::cout << i << "\tET = " << tempJetVec[i].mJet->Pt() << "\tCentrality = " << tempJetVec[i].mJet->Centrality() + << "\tiEta = " << tempJetVec[i].mJet->iEta() << "\tiPhi = " << tempJetVec[i].mJet->iPhi() + << "\n\tET = " << tempJetVec[i+1].mJet->Pt() << "\tCentrality = " << tempJetVec[i+1].mJet->Centrality() + << "\tiEta = " << tempJetVec[i+1].mJet->iEta() << "\tiPhi = " << tempJetVec[i+1].mJet->iPhi() + << "\n\tJet1 > Jet2 = " << ( tempJetVec[i] > tempJetVec[i+1] ) + << "\n\n"; + } + } +*/ + + /* + std::cout << "Prior to start\n"; +// std::vector< L1TowerJet >::iterator lStart( filteredJets->begin() ); + std::vector< tempJet >::iterator lStart2( tempJetVec.begin() ); + std::cout << "Prior to End\n"; + // std::vector< L1TowerJet >::iterator lEnd( filteredJets->end() ); + std::vector< tempJet >::iterator lEnd2( tempJetVec.end() ); + std::cout << "Prior to sort\n"; + // BitonicSort< tempJet >( down , lStart2 , lEnd2 ); + BitonicSort< tempJet >( down , lStart2 , lEnd2 ); + std::cout << "After sort\n"; + */ + + + + // Sort with the std library + std::sort (tempJetVec.begin(), tempJetVec.end(), tempJetSort); + + +// for (unsigned int i = 0; ((i < lTowerVector.size()) && (i < 100)); i++){ +// if ( lTowerVector[i] != NULL ){ +// std::cout << "ET = " << lTowerVector[i]->Pt() << "\tCentrality = " << lTowerVector[i]->Centrality() +// << i << "\tiEta = " << lTowerVector[i]->iEta() << "\tiPhi = " << lTowerVector[i]->iPhi() +// << "\n"; +// std::cout << (lTowerVector[i] < lTowerVector[i+1]) << "\n"; +// // << *lTowerVector[i] +// } +// } + + + +/* + for (unsigned int i = 0; ((i < tempJetVec.size()) && (i < 100)); i++){ + if ( tempJetVec[i].mJet != NULL ){ + std::cout << i << "\tET = " << tempJetVec[i].mJet->Pt() << "\tCentrality = " << tempJetVec[i].mJet->Centrality() + << "\tiEta = " << tempJetVec[i].mJet->iEta() << "\tiPhi = " << tempJetVec[i].mJet->iPhi() + << "\n\tET = " << tempJetVec[i+1].mJet->Pt() << "\tCentrality = " << tempJetVec[i+1].mJet->Centrality() + << "\tiEta = " << tempJetVec[i+1].mJet->iEta() << "\tiPhi = " << tempJetVec[i+1].mJet->iPhi() + << "\n\tJet1 > Jet2 = " << ( tempJetVec[i] > tempJetVec[i+1] ) + << "\n\n"; + + } + } +*/ + + + + +// std::vector::iterator lStart( lJetWrapper2DVector.begin() ); +// std::vector::iterator lEnd( lJetWrapper2DVector.end() ); +// BitonicSort< JetWrapper2D >( down , lStart , lEnd ); + + + + // iEta, iPhi vetoed positions + std::deque< std::pair > lVetos; + // Number of jets currently retained + int lJetCounter(0); + + //THESE AREN'T FILTERED YET!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + + + + // for (L1TowerJetCollection::const_iterator jetIt = preFiltJets->begin(); jetIt!= preFiltJets->end(); ++jetIt ){ + // for( std::vector::iterator jetIt = lTowerVector.begin(); jetIt != lTowerVector.end(); ++jetIt){ + for (unsigned int iTemp = 0; iTemp < tempJetVec.size(); iTemp++){ + //for( std::vector::iterator lIt =lJetWrapper2DVector.begin(); lIt != lJetWrapper2DVector.end(); ++lIt){ + + + // NOTE: Erroneous vetoting of non-square jet shapes still remains. Problem can only + // be resolved if mJetShapeMap of L1TowerJetProducer becomes a member variable + // of L1TowerJet OR if we pass the jet map from module to module + // ##########################!!!!DO THE LATTER!!!!################################################## + + // ********************************************************************** + // * Jet filtering * + // ********************************************************************** + // + // Pick the highest ranked jets for output and veto all the jets that overlap its position. + // ----------------------------------------------------------------------- + + // if( tempJetVec[iTemp].mJet ){ //if jet exists + int lJetsize = tempJetVec[iTemp].mJet->JetSize() ; + bool lVetoed( false ); + + // Check jet iEta and iPhi against list of vetod iEta and iPhi. If jet is vetoed skip to next jet in sorted list. + for( std::deque< std::pair >::iterator vetoIt = lVetos.begin() ; vetoIt != lVetos.end() ; ++vetoIt ){ + + + if ( ( tempJetVec[iTemp].mJet->iEta() == vetoIt->first ) && ( tempJetVec[iTemp].mJet->iPhi() == vetoIt->second) ){ + // Jet is already vetoed break + + // std::cout << "Jet with iEta,iPhi = " << tempJetVec[iTemp].mJet->iEta() << "," << tempJetVec[iTemp].mJet->iPhi() << " vetoed.\n"; + lVetoed = true; break; + } + + } + + if( !lVetoed ){ // If the jet is not vetoed then add to the output collection and add veto region to veto list. + + + // Store the overlap filtered jet + +// std::cout << "Pt = " << tempJetVec[iTemp].mJet->p4().Pt() << "\t" +// << tempJetVec[iTemp].mJet->WeightedEta() << "\t" +// << tempJetVec[iTemp].mJet->WeightedPhi() << "\n" + + double weightedEta = tempJetVec[iTemp].mJet->WeightedEta(); + double weightedPhi = tempJetVec[iTemp].mJet->WeightedPhi(); + filteredJets->insert( weightedEta, weightedPhi, *tempJetVec[iTemp].mJet ); + + // filteredJets->insert( jetIt->iEta() , jetIt->iPhi() , (*jetIt) ); + lJetCounter++; + + // Generate the veto list + for( int i = -lJetsize +1 ; i != lJetsize ; ++i ){ + + + int lPhi( tempJetVec[iTemp].mJet->iPhi() + i ); + + + if( lPhi > 72 ) lPhi -= 72; + if( lPhi < 1 ) lPhi += 72; + // Single veto coordinate (iEta, iPhi) + std::pair veto; + veto.second = lPhi; + // For each iPhi veto all overlapping iEta positions + for( int j = -lJetsize +1 ; j != lJetsize ; ++j ){ + + int lEta( tempJetVec[iTemp].mJet->iEta() + j ); + + // No iEta = 0 in this coordinate system: need to allow for this + // Accounts for the range scanned being too small, due to no + // iEta = 0 being present, by jumping to the end of the range. + // Obtuse but effective. + if( (lEta == 0) && (j < 0) ) lEta = tempJetVec[iTemp].mJet->iEta() - lJetsize; + if( (lEta == 0) && (j > 0) ) lEta = tempJetVec[iTemp].mJet->iEta() + lJetsize; + veto.first = lEta; + + // Add vetoed coordinate to list of vetoes + lVetos.push_back( veto ); + // std::cout << "(" << lEta << ", " << lPhi << ") vetoed.\n"; + } + } + if( lJetCounter >= mNumOfOutputJets ) break; // Restrict number of jets retained in filtering + } + +// } +// else{ +// std::cout << "This actually does something\n"; +// } + + + } // End jet loop + + + // Store the overlap filtered jets + // iEvent.put( filteredJets,"FilteredTowerJets"); + iEvent.put( filteredJets ); + + } // End valid event + + +} + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TowerJetCentralityFilter::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TowerJetCentralityFilter::endJob() +{ +} + +// ------------ method called when starting to processes a run ------------ +void +L1TowerJetCentralityFilter::beginRun(edm::Run&, edm::EventSetup const&) +{ +} + +// ------------ method called when ending the processing of a run ------------ +void +L1TowerJetCentralityFilter::endRun(edm::Run&, edm::EventSetup const&) +{ +} + +// ------------ method called when starting to processes a luminosity block ------------ +void +L1TowerJetCentralityFilter::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} + +// ------------ method called when ending the processing of a luminosity block ------------ +void +L1TowerJetCentralityFilter::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TowerJetCentralityFilter::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TowerJetCentralityFilter); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter1D.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter1D.cc deleted file mode 100644 index 09b1b013ea740..0000000000000 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter1D.cc +++ /dev/null @@ -1,220 +0,0 @@ - -#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/L1CaloAlgoBase.h" - -#include "SimDataFormats/SLHC/interface/L1TowerJet.h" -#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" - -#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/BitonicSort.hpp" - -#define DEBUG std::cout<< __FILE__ << " : " << __LINE__ << std::endl; - -enum tComparisonDirection { eta , phi }; - -struct JetWrapper -{ - - JetWrapper( ) : - mJet( NULL ), - mComparisonDirection( NULL ) - { /*....*/ } //constructor - - - JetWrapper( const l1slhc::L1TowerJet& aJet , const tComparisonDirection& aComparisonDirection ) : - mJet( &aJet ), - mComparisonDirection( &aComparisonDirection ) - { /*....*/ } //constructor - - const l1slhc::L1TowerJet* mJet; - const tComparisonDirection* mComparisonDirection; -}; - - -bool operator> ( JetWrapper& aA , JetWrapper& aB ) -{ - if( aA.mJet == NULL ) return false; //Jets that don't exist: require 128 or 64 spots - if( aB.mJet == NULL ) return true; - - if ( aA.mJet->E() > aB.mJet->E() ) return true; - if ( aA.mJet->E() < aB.mJet->E() ) return false; - - - //those aA and aB with the same energy are all that remain - if ( *(aA.mComparisonDirection) == phi ){ - return ( abs( aA.mJet-> AsymPhi() ) <= abs( aB.mJet->AsymPhi() ) ); - }else{ - return ( abs( aA.mJet-> AsymEta() ) <= abs( aB.mJet->AsymEta() ) ); - } - - -} - - -class L1TowerJetFilter1D:public L1CaloAlgoBase < l1slhc::L1TowerJetCollection , l1slhc::L1TowerJetCollection > -{ - public: - L1TowerJetFilter1D( const edm::ParameterSet & ); - ~L1TowerJetFilter1D( ); - -// void initialize( ); - - void algorithm( const int &, const int & ); - - - private: - - tComparisonDirection mComparisonDirection; - - int mNumOfOutputJets; - -}; - - -L1TowerJetFilter1D::L1TowerJetFilter1D( const edm::ParameterSet & aConfig ): -L1CaloAlgoBase < l1slhc::L1TowerJetCollection , l1slhc::L1TowerJetCollection > ( aConfig ), -mComparisonDirection( eta ), -mNumOfOutputJets( aConfig.getParameter("NumOfOutputJets") ) -{ - - std::string lComparisonDirection = aConfig.getParameter("ComparisonDirection"); - - //do the comparison in upper case so config file can read "Eta", "eta", "ETA", "eTa", etc. and give the same result. - std::transform( lComparisonDirection.begin() , lComparisonDirection.end() , lComparisonDirection.begin() , ::toupper ); - - if( lComparisonDirection == "PHI" ){ - mComparisonDirection = phi; - } - //else comparison in eta but this is the default - -} - - -L1TowerJetFilter1D::~L1TowerJetFilter1D( ) -{ -} - - -//void L1TowerJetFilter1D::initialize( ) -//{ -//} - -void L1TowerJetFilter1D::algorithm( const int &aEta, const int &aPhi ) -{ - if ( mComparisonDirection == phi && aPhi != mCaloTriggerSetup->phiMin() ) return; - else if ( mComparisonDirection == eta && aEta != mCaloTriggerSetup->etaMin() ) return; - - -//----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -// When we call fetch, we use the Wisconsin coordinate system -// ie aEta, aPhi, lEta and lPhi need to be defined between mCaloTriggerSetup->phiMin() , mCaloTriggerSetup->phiMax(), etc. -// ie aEta 4->60, aPhi 4->75 -//----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - - //declare a vector of structs to pass to algorithm - std::vector< JetWrapper > lJetWrapperVector; - if ( mComparisonDirection == phi ){ - for( int lPhi = mCaloTriggerSetup->phiMin() ; lPhi <= mCaloTriggerSetup->phiMax() ; ++lPhi ){ - l1slhc::L1TowerJetCollection::const_iterator lIt = fetch( aEta, lPhi); - if( lIt != mInputCollection->end( ) ){ - lJetWrapperVector.push_back( JetWrapper( *lIt , mComparisonDirection ) ); - } - } - lJetWrapperVector.resize(128); //algorithm requires 2^N inputs - }else{ // eta - for( int lEta = mCaloTriggerSetup->etaMin() ; lEta <= mCaloTriggerSetup->etaMax() ; ++lEta ){ - l1slhc::L1TowerJetCollection::const_iterator lIt = fetch( lEta, aPhi); - if( lIt != mInputCollection->end( ) ){ - lJetWrapperVector.push_back( JetWrapper( *lIt , mComparisonDirection ) ); - } - } - lJetWrapperVector.resize(64); //algorithm requires 2^N inputs - } - - -//----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -// When we call iEta() and iPhi() on the Jets, we use the sensible integer coordinate system -// ie Eta runs from -28-28 with no 0, and Phi runs from 1-72 -// This system is used everywhere beyond this point -//----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -// std::cout << "Sorting Jets produced by " << sourceName() << std::endl; -// for( std::vector::iterator lIt =lJetWrapperVector.begin(); lIt != lJetWrapperVector.end(); ++lIt){ -// if( (*lIt).mJet ) { -// // std::cout << "Before sort, (eta, phi) = " << (*lIt).mJet->iEta() << " " << (*lIt).mJet->iPhi() <<" energy " << (*lIt).mJet->E() << " and asym = " << (*lIt).mJet->AsymPhi() <::iterator lStart( lJetWrapperVector.begin() ); - std::vector::iterator lEnd( lJetWrapperVector.end() ); - BitonicSort< JetWrapper >( down , lStart , lEnd ); - - //Veto overlapping jets in 1D - std::deque lVetos; - int lCounter(0); - - for( std::vector::iterator lIt =lJetWrapperVector.begin(); lIt != lJetWrapperVector.end(); ++lIt){ - - if( (*lIt).mJet ){ //if jet exists - int lJetsize = (*lIt).mJet->JetSize() ; - - if( mComparisonDirection == phi ){ //phi - bool lVetoed( false ); - for( std::deque< int >::iterator lIt2 = lVetos.begin() ; lIt2 != lVetos.end() ; ++ lIt2 ){ - - if ( (*lIt).mJet->iPhi() == (*lIt2) ){ //if jet is already vetoed break - lVetoed = true; - break; - } - } - - if( !lVetoed ){ //if jet not vetoed then add to collection and create vetoes around it - - mOutputCollection->insert( (*lIt).mJet->iEta() , (*lIt).mJet->iPhi() , *((*lIt).mJet) ); - lCounter++; - for( int i = -lJetsize +1 ; i != lJetsize ; ++i ){ - - int lPhi( (*lIt).mJet->iPhi() + i ); - if( lPhi > 72 ) lPhi -= 72; - if( lPhi < 1 ) lPhi += 72; - lVetos.push_back( lPhi); - - } - if( lCounter > mNumOfOutputJets ) break; //only N jets per ring/strip - } - - }else{ //eta - - bool lVetoed( false ); - for( std::deque::iterator lIt2 = lVetos.begin() ; lIt2 != lVetos.end() ; ++lIt2 ){ - - if( (*lIt).mJet->iEta() == (*lIt2) ){ - lVetoed = true; - break; - } - } - - if( !lVetoed ){ - - mOutputCollection->insert( (*lIt).mJet->iEta() , (*lIt).mJet->iPhi() , *((*lIt).mJet) ); - ++lCounter; - - for( int i = -lJetsize +1 ; i != lJetsize ; ++i ){ - int lEta( (*lIt).mJet->iEta() + i ); - // no eta=0 in this coordinate system: need to allow for this - if(lEta == 0 && i<0) lEta = (*lIt).mJet->iEta() - lJetsize; - if(lEta == 0 && i>0) lEta = (*lIt).mJet->iEta() + lJetsize; - lVetos.push_back( lEta); - } - if( lCounter > mNumOfOutputJets ) break; //only N jets per ring/strip - } - } - } - } - - -} - -DEFINE_EDM_PLUGIN (edm::MakerPluginFactory,edm::WorkerMaker,"L1TowerJetFilter1D"); -DEFINE_FWK_PSET_DESC_FILLER(L1TowerJetFilter1D); - - diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter2D.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter2D.cc deleted file mode 100644 index e17d6196c1b3e..0000000000000 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetFilter2D.cc +++ /dev/null @@ -1,208 +0,0 @@ - -#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/L1CaloAlgoBase.h" - -#include "SimDataFormats/SLHC/interface/L1TowerJet.h" -#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" - -#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/BitonicSort.hpp" - -enum tComparisonDirection { eta , phi }; - -struct JetWrapper2D -{ - - JetWrapper2D( ) : - mJet( NULL ), - mComparisonDirection( NULL ) - { /*....*/ } //constructor - - - JetWrapper2D( const l1slhc::L1TowerJet& aJet , const tComparisonDirection& aComparisonDirection ) : - mJet( &aJet ), - mComparisonDirection( &aComparisonDirection ) - { /*....*/ } //constructor - - const l1slhc::L1TowerJet* mJet; - const tComparisonDirection* mComparisonDirection; -}; - - -bool operator> ( JetWrapper2D& aA , JetWrapper2D& aB ) -{ - if( aA.mJet == NULL ) return false; //Jets that don't exist: require 128 or 64 spots - if( aB.mJet == NULL ) return true; - - if ( aA.mJet->E() > aB.mJet->E() ) return true; - if ( aA.mJet->E() < aB.mJet->E() ) return false; - - - //those aA and aB with the same energy are all that remain - if ( *(aA.mComparisonDirection) == phi ){ - return ( abs( aA.mJet-> AsymPhi() ) <= abs( aB.mJet->AsymPhi() ) ); - }else{ - return ( abs( aA.mJet-> AsymEta() ) <= abs( aB.mJet->AsymEta() ) ); - } - -} - - - -class L1TowerJetFilter2D:public L1CaloAlgoBase < l1slhc::L1TowerJetCollection , l1slhc::L1TowerJetCollection > -{ - public: - L1TowerJetFilter2D( const edm::ParameterSet & ); - ~L1TowerJetFilter2D( ); - -// void initialize( ); - - void algorithm( const int &, const int & ); - - // int DO_ONCE; - private: - - tComparisonDirection mComparisonDirection; - - int mNumOfOutputJets; - - - -}; - -L1TowerJetFilter2D::L1TowerJetFilter2D( const edm::ParameterSet & aConfig ): -L1CaloAlgoBase < l1slhc::L1TowerJetCollection , l1slhc::L1TowerJetCollection > ( aConfig ), -mComparisonDirection( eta ), -mNumOfOutputJets( aConfig.getParameter("NumOfOutputJets") ) -{ - - std::string lComparisonDirection = aConfig.getParameter("ComparisonDirection"); - - //do the comparison in upper case so config file can read "Eta", "eta", "ETA", "eTa", etc. and give the same result. - std::transform( lComparisonDirection.begin() , lComparisonDirection.end() , lComparisonDirection.begin() , ::toupper ); - - if( lComparisonDirection == "PHI" ){ - mComparisonDirection = phi; - } - //else comparison in eta but this is the default - -} - - -L1TowerJetFilter2D::~L1TowerJetFilter2D( ) -{ -} - -/* -void L1TowerJetFilter2D::initialize( ) -{ -} -*/ - - -void L1TowerJetFilter2D::algorithm( const int &aEta, const int &aPhi ) -{ - //Only need an output collection produced once per event: - if( aPhi != mCaloTriggerSetup->phiMin() )return; - if( aEta != mCaloTriggerSetup->etaMin() )return; - - -//--------------------------------------------------------------------------------------------------- -// When we call fetch, we use the Wisconsin coordinate system -// ie aEta, aPhi, lEta and lPhi need to be defined between mCaloTriggerSetup->phiMin() , mCaloTriggerSetup->phiMax(), etc. -// ie aEta 4->60, aPhi 4->75 -//--------------------------------------------------------------------------------------------------- - - //declare a vector of structs to pass to algorithm - - //for just one value of eta/phi depending on mComparisonDirection - std::vector< JetWrapper2D > lJetWrapper2DVector; - - //Want all of the input collection so we can veto properly. - //Its now the same for both directions - - for( int lPhi = mCaloTriggerSetup->phiMin() ; lPhi <= mCaloTriggerSetup->phiMax() ; ++lPhi ){ - for( int lEta = mCaloTriggerSetup->etaMin() ; lEta <= mCaloTriggerSetup->etaMax() ; ++lEta ){ - - l1slhc::L1TowerJetCollection::const_iterator lIt = fetch( lEta, lPhi); - - if( lIt != mInputCollection->end( ) ){ - lJetWrapper2DVector.push_back( JetWrapper2D( *lIt , mComparisonDirection ) ); - } - - } - } - lJetWrapper2DVector.resize(4096); //resize to nearest power of 2 to 72*56 - - - //-------------------------------------------------------------------------------------------------- - // When we call iEta() and iPhi() on the Jets, we use the sensible integer coordinate system - // ie Eta runs from -28-28 with no 0, and Phi runs from 1-72 - // This system is used everywhere beyond this point - //-------------------------------------------------------------------------------------------------- - - //std::cout << "Sorting Jets produced by " << sourceName() << std::endl; - - // for( std::vector::iterator lIt =lJetWrapper2DVector.begin(); lIt != lJetWrapper2DVector.end(); ++lIt){ - // if( (*lIt).mJet ) { - //std::cout << "Before sort, (eta, phi) = " << (*lIt).mJet->iEta() << " " << (*lIt).mJet->iPhi() <<" energy " << (*lIt).mJet->E() << " and asym = " << (*lIt).mJet->AsymPhi() <::iterator lStart( lJetWrapper2DVector.begin() ); - std::vector::iterator lEnd( lJetWrapper2DVector.end() ); - BitonicSort< JetWrapper2D >( down , lStart , lEnd ); - - //Filter the jets with vetoes - std::deque< std::pair > lVetos; - int lCounter(0); - for( std::vector::iterator lIt =lJetWrapper2DVector.begin(); lIt != lJetWrapper2DVector.end(); ++lIt){ - - if( (*lIt).mJet ){ //if jet exists - int lJetsize = (*lIt).mJet->JetSize() ; - bool lVetoed( false ); - - for( std::deque< std::pair >::iterator lIt2 = lVetos.begin() ; lIt2 != lVetos.end() ; ++ lIt2 ){ - - if ( (*lIt).mJet->iEta() == (*lIt2).first && (*lIt).mJet->iPhi() == (*lIt2).second ){ - //if jet is already vetoed break - lVetoed = true; - break; - } - } - - if( !lVetoed ){ //if jet not vetoed then add to collection and create vetoes around it - -// std::cout <<" Added jet to the output collection = (" << (*lIt).mJet->iEta() << " , " << (*lIt).mJet->iPhi() <<"), energy = " << (*lIt).mJet->E() << " and asym = " << (*lIt).mJet->AsymPhi() <<" it "<< lCounter <insert( (*lIt).mJet->iEta() , (*lIt).mJet->iPhi() , *((*lIt).mJet) ); - lCounter++; - for( int i = -lJetsize +1 ; i != lJetsize ; ++i ){ - - int lPhi( (*lIt).mJet->iPhi() + i ); - if( lPhi > 72 ) lPhi -= 72; - if( lPhi < 1 ) lPhi += 72; - std::pair veto; - veto.second = lPhi; - //for each phi, want to eradicate all the etas along it - for( int j = -lJetsize +1 ; j != lJetsize ; ++j ){ - int lEta( (*lIt).mJet->iEta() + j ); - - // no eta=0 in this coordinate system: need to allow for this - if(lEta == 0 && j<0) lEta = (*lIt).mJet->iEta() - lJetsize; - if(lEta == 0 && j>0) lEta = (*lIt).mJet->iEta() + lJetsize; - - veto.first = lEta; - lVetos.push_back( veto ); - } - } - if( lCounter > mNumOfOutputJets ) break; //only N jets per ring/strip - } - }//jet exists - } - - -} - -DEFINE_EDM_PLUGIN (edm::MakerPluginFactory,edm::WorkerMaker,"L1TowerJetFilter2D"); -DEFINE_FWK_PSET_DESC_FILLER(L1TowerJetFilter2D); - diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc index c38b26044ebea..47b92b7a73c90 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc @@ -13,8 +13,8 @@ // // Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, // Created: Mon Nov 19 10:20:06 CET 2012 -// $Id: L1TowerJetPUEstimator.cc,v 1.1 2013/03/21 17:23:28 rlucas Exp $ -// +// $Id: L1TowerJetPUEstimator.cc,v 1.3 2013/05/16 17:35:30 mbaber Exp $ +// Modifications : Mark Baber Imperial College, London // @@ -42,6 +42,10 @@ #include #include "FWCore/ParameterSet/interface/FileInPath.h" + + + + // // class declaration // @@ -54,8 +58,6 @@ using namespace reco; using namespace l1extra; -bool myfunction (double i,double j) { return (i>j); } - bool sortTLorentz (TLorentzVector i,TLorentzVector j) { return ( i.Pt()>j.Pt() ); } @@ -79,10 +81,12 @@ class L1TowerJetPUEstimator : public edm::EDProducer { double get_rho(double L1rho); //fwd calibration: V ROUGH (only to L1extra particles) -// double rough_ptcal(double pt); - + // double rough_ptcal(double pt); + + // Determines the median value of a vector of doubles double Median(vector aVec); + // ----------member data --------------------------- ParameterSet conf_; @@ -92,13 +96,25 @@ class L1TowerJetPUEstimator : public edm::EDProducer { edm::FileInPath inRhoData_edm; + + + // Determines whether to calibrate rho to offline rho + bool useRhoCalib; + // Inclusive upper limit of the jet indexes to exclude from the median calculation for rho from the ordered jet list + // e.g. skipJetsIndex = 2 => Skip first three jets (indices = 0, 1, 2) + unsigned int skipJetsIndex; + + // Local rho eta region boundaries + vector < double > localRhoEtaDiv; + // Minimum jets in region for the calulation of local rho + unsigned int minimumLocalJets; + }; // // constants, enums and typedefs // - // // static data member definitions // @@ -111,17 +127,35 @@ L1TowerJetPUEstimator::L1TowerJetPUEstimator(const edm::ParameterSet& iConfig): conf_(iConfig) { + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetPUEstimator\n----------------------------------------\n\n"; + + // look up tables + inRhoData_edm = iConfig.getParameter ("inRhodata_file"); + // determine whether to perform the rho calibration + useRhoCalib = iConfig.getParameter< bool >("UseRhoCalibration"); + // number of jets to exclude from the median calculation for rho, subtracting 1 to transform to a jet index + skipJetsIndex = iConfig.getParameter< unsigned int >("numberOfSkippedJets") - 1; + // Divisions of the eta regions overwhich to calculate local rhos + localRhoEtaDiv = iConfig.getParameter< vector< double > >("LocalRhoEtaDivisions"); + // Minimum number of jets required in an eta region to perform a measurement of rho + minimumLocalJets = iConfig.getParameter< unsigned int >("LocalRhoMinJetsInRegion"); + + + // Ensure the divisions are in ascending order of eta + sort (localRhoEtaDiv.begin(), localRhoEtaDiv.end()); + + + produces("RhoCalibrated"); produces("Rho"); + produces< vector< double > >("LocalRho"); + produces< vector< double > >("LocalRhoEtaBoundaries"); + } L1TowerJetPUEstimator::~L1TowerJetPUEstimator() { - - // do anything here that needs to be done at desctruction time - // (e.g. close files, deallocate resources etc.) - } @@ -132,48 +166,170 @@ void L1TowerJetPUEstimator::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { - bool evValid =true; + bool evValid = true; double outrho(0); auto_ptr outRho(new double()); + auto_ptr useCalib(new bool()); + // Local rho in corresponding bin + auto_ptr< vector< double > > localRhoCollection( new vector< double >() ); + + + // Incredibly inefficienct - This should just be read from the config file once in each module that requires it + // + // + // Lower eta edge of rho bin, final bin for upper edge of entire range + // localEtaBoundaries = auto_ptr< vector< double > >( new vector< double > (localRhoEtaDiv) ); + auto_ptr< vector< double > > localEtaBoundaries = auto_ptr< vector< double > >( new vector< double > () ); + + for (unsigned int iSlice = 0; iSlice < localRhoEtaDiv.size(); iSlice++){ + double eta = localRhoEtaDiv[iSlice]; + localEtaBoundaries->push_back( eta ); + } + // + // + // + + + // Store whether rho calibration was applied + *useCalib = useRhoCalib; edm::Handle UnCalibCen; iEvent.getByLabel(conf_.getParameter("FilteredCircle8"), UnCalibCen); if(!UnCalibCen.isValid()){evValid=false;} + + if( !evValid ) { - //edm::LogWarning("MissingProduct") << conf_.getParameter("FilteredCircle8") << "," << conf_.getParameter("FilteredFwdCircle8") << std::endl; - edm::LogWarning("MissingProduct") << conf_.getParameter("FilteredCircle8") << std::endl; + // ???? Surely this should throw an exception if collection is not present? ???? + edm::LogWarning("MissingProduct") << conf_.getParameter("FilteredCircle8") + << std::endl; } else{ - //produce calibrated rho collection - - double areaPerJet(9999); - int count(0); - vector Jet2Energies; - for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); - il1!= UnCalibCen->end() ; ++il1 ){ - if( abs(il1->p4().eta() )>3) continue; - if(count>1) { - Jet2Energies.push_back(il1->p4().Pt()); - //cout<<"jet energy: "<< il1->p4().Pt() <JetArea()* (0.087 * 0.087) ; + + // Produce global rho collection + unsigned int jetIndex(0); + + // Jet energy densities inside the entire calorimeter (global) and local regions + vector jetPtAreaRatioGlobal; + vector < vector > jetPtAreaRatioLocal; + + // Resize the local array to fit the required number of regions + jetPtAreaRatioLocal.resize( localRhoEtaDiv.size() - 1 ); + + + for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); il1!= UnCalibCen->end(); ++il1 ){ + + + + // Restrict to jets in barrel and endcap. This will need to be removed when HF jets are included. + double weightedEta = il1->WeightedEta(); + if( fabs( weightedEta ) > 3.) continue; + + + // Skip the specified number of jets in the calculation of the median for rho + if( jetIndex > skipJetsIndex ){ + + + // ********************************************************************** + // * Global rho * + // ********************************************************************** + + // Store the global jet energy density + double ptAreaRatio = il1->Pt() / il1->JetRealArea(); + jetPtAreaRatioGlobal.push_back( ptAreaRatio ); + + + // ********************************************************************** + // * Local rho * + // ********************************************************************** + + // Determine in which region the jet resides + for (unsigned int iSlice = 0;iSlice < localRhoEtaDiv.size() - 1; iSlice++){ + + // Get the current eta slice range + double etaLow = localRhoEtaDiv[iSlice]; + double etaHigh = localRhoEtaDiv[iSlice + 1]; + + // Store the jet in the respective eta region + if ( (weightedEta >= etaLow) && (weightedEta < etaHigh) ){ + + // Fill the jet in respective vector for calculating local rho (lower edge) + jetPtAreaRatioLocal[iSlice].push_back( ptAreaRatio ); + + // std::cout << "pT = " << il1->Pt() << "\tArea = " << il1->JetRealArea() << "\tEta = " << weightedEta << "\tetaRange = (" << etaLow << ", " << etaHigh << ")\n"; + + } + + + } + + + } + jetIndex++; } - double raw_rho2 = ( Median( Jet2Energies ) / areaPerJet ); - - //apply calibration to the raw rho: should we do this at this stage? - //not sure of the effect on high PU data - /////////////////////////////////////////////////// - // SET VALUE OF RHO - /////////////////////////////////////////////////// - outrho=raw_rho2; - + // Calculate global rho, the median jet energy density + double globalRho = Median(jetPtAreaRatioGlobal); + + + // Calculate local rhos for each eta bin + for (unsigned int iSlice = 0; iSlice < jetPtAreaRatioLocal.size(); iSlice++){ + + double localRho; + + // Check whether enough jets are present to perform local PU subtraction + if (jetPtAreaRatioLocal[iSlice].size() >= minimumLocalJets ){ + // Calculate the rho local to the current bin + localRho = Median( jetPtAreaRatioLocal[iSlice] ); + } + else{ // Insufficient statistics to obtain a useful measure of rho of the region + localRho = 0; + } + + + + // Store the local rho + localRhoCollection->push_back(localRho); + //localEtaBoundaries->push_back( etaLow ); + + } + + + // Determine whether to apply the rho calibration (Only to global rho) + if ( useRhoCalib ){ + + //apply calibration to the raw rho: should we do this at this stage? + //not sure of the effect on high PU data + double cal_rhoL1 = globalRho * get_rho(globalRho); + + // return calibrated rho + outrho = cal_rhoL1; + + } + else{ + + // return uncalibrated rho + outrho = globalRho; + } + + + + + + + *outRho = outrho; + // Return whether rho calibration was applied (global only) + iEvent.put(useCalib,"RhoCalibrated"); + + // Return global rho iEvent.put(outRho,"Rho"); + // Return local rho and the eta regions utilised + iEvent.put(localRhoCollection,"LocalRho"); + iEvent.put(localEtaBoundaries,"LocalRhoEtaBoundaries"); + } //valid event } @@ -195,6 +351,32 @@ L1TowerJetPUEstimator::endJob() { void L1TowerJetPUEstimator::beginRun(edm::Run&, edm::EventSetup const&) { + + if (useRhoCalib){ + //read in calibration for rho lookup table + inrhodata.open(inRhoData_edm.fullPath().c_str()); + if(!inrhodata) cerr << " unable to open rho lookup file. " << endl; + + //read into a vector + pair rho_cal; + double L1rho_(9999), calFac_(9999); + while ( !inrhodata.eof() ) { // keep reading until end-of-file + // sets EOF flag if no value found + inrhodata >> L1rho_ >> calFac_ ; + + rho_cal.first = L1rho_; + rho_cal.second= calFac_; + + rho_cal_vec.push_back(rho_cal); + } + inrhodata.close(); + + std::cout << "\nRead in Rho lookup table\n"; + } + else{ + std::cout << "\nWARNING: Not performing rho calibration\n"; + } + } // ------------ method called when ending the processing of a run ------------ @@ -229,23 +411,49 @@ L1TowerJetPUEstimator::fillDescriptions(edm::ConfigurationDescriptions& descript // member functions // double L1TowerJetPUEstimator::Median( vector aVec){ - sort( aVec.begin(), aVec.end() ); - double median(0); - int size = aVec.size(); - if(size ==0){ - median = 0; - } - else if(size==1){ - median = aVec[size-1]; - } - else if( size%2 == 0 ){ - median = ( aVec[ (size/2)-1 ] + aVec[ (size /2) ] )/2; - }else{ - median = aVec [ double( (size/2) ) +0.5 ]; - } - return median; + + // Order vector collection + sort( aVec.begin(), aVec.end() ); + + double median(0); + int size = aVec.size(); + int halfSize = size/2; + if( size == 0 ){ + median = 0; + } + else if( size == 1 ){ + median = aVec[0]; + } + else if( size%2 == 0 ){ + // Even number of entries, take average of the values around center + median = ( aVec[ halfSize - 1 ] + aVec[ halfSize ] ) * 0.5; + } + else{ + // Odd number of entries, halfSize is central element + median = aVec[ halfSize ]; + } + + return median; } + + + + +double L1TowerJetPUEstimator::get_rho(double L1_rho) +{ + + // Get the rho multiplication factor: + // L1_rho * 2 gets the array index + if(L1_rho <= 40.5){ + return rho_cal_vec[L1_rho*2].second; + } + else{ //for L1 rho > 40.5, calibration flattens out + return 1.44576; + } + +} + //define this as a plug-in DEFINE_FWK_MODULE(L1TowerJetPUEstimator); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc index 693e46b35cfae..f9d6643e4cd80 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc @@ -5,6 +5,9 @@ //is filtered, uncalibrated jet collection // //Calibration should be done after this step is completed +// +// Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, +// Modifications : Mark Baber Imperial College, London // system include files #include @@ -61,14 +64,39 @@ class L1TowerJetPUSubtractedProducer : public edm::EDProducer { // ----------member data --------------------------- - ParameterSet conf_; + ParameterSet conf_; + + // Jet pt threshold for jet energies to be retained after PU subtraction + double jetPtPUSubThreshold; + + // Local rho eta region boundaries + vector < double > localRhoEtaDiv; + + }; L1TowerJetPUSubtractedProducer::L1TowerJetPUSubtractedProducer(const edm::ParameterSet& iConfig): conf_(iConfig) { - produces("PUSubCenJets"); - produces< L1JetParticleCollection >( "PUSubCen8x8" ) ; + + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetPUSubtractedProducer\n----------------------------------------\n\n"; + produces("PrePUSubCenJets"); + produces("PUSubCenJets"); + produces("LocalPUSubCenJets"); + + produces("PUSubCen8x8") ; + produces("CalibFwdJets"); + + // Extract pT threshold for retaining PU subtracted jets + jetPtPUSubThreshold = iConfig.getParameter ("JetPtPUSubThreshold"); + + + // Divisions of the eta regions overwhich to calculate local rhos + localRhoEtaDiv = iConfig.getParameter< vector< double > >("LocalRhoEtaDivisions"); + // Ensure the divisions are in ascending order of eta + sort (localRhoEtaDiv.begin(), localRhoEtaDiv.end()); + + } @@ -83,13 +111,15 @@ L1TowerJetPUSubtractedProducer::~L1TowerJetPUSubtractedProducer() void L1TowerJetPUSubtractedProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { - - bool evValid =true; - auto_ptr< L1TowerJetCollection > outputCollCen(new L1TowerJetCollection()); - produces("CalibFwdJets"); + + bool evValid = true; + auto_ptr< L1TowerJetCollection > outputCollCen(new L1TowerJetCollection()); // Global PU-subtracted central jets + auto_ptr< L1TowerJetCollection > cenLocalPUS(new L1TowerJetCollection()); // Local PU-subtracted central jets + auto_ptr< L1TowerJetCollection > outputCollCenPrePUSub(new L1TowerJetCollection()); // Pre PU-subtracted central jets auto_ptr< L1JetParticleCollection > outputExtraCen(new L1JetParticleCollection()); + // WARNING: May or may not be calibrated, depending on the configuration parameters given for L1TowerJetPUEstimator edm::Handle< double > calRho; iEvent.getByLabel(conf_.getParameter("CalibratedL1Rho"), calRho); if(!calRho.isValid()){ @@ -104,12 +134,39 @@ L1TowerJetPUSubtractedProducer::produce(edm::Event& iEvent, const edm::EventSetu evValid=false; } + + + // Local PU subtraction + // ****************************** + edm::Handle< vector > LocalRho; + iEvent.getByLabel(conf_.getParameter("LocalRho"), LocalRho); + if(!LocalRho.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("LocalRho") << std::endl; + evValid=false; + } + /* + edm::Handle< vector > LocalRhoBoundaries; + iEvent.getByLabel(conf_.getParameter("LocalRhoBoundaries"), LocalRhoBoundaries); + if(!LocalRhoBoundaries.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("LocalRhoBoundaries") << std::endl; + evValid=false; + } + */ + + if( evValid ) { - //get rho from the producer L1TowerJetPUSubtraction - //This value is calibrated to offline calo rho + // Get rho from the producer L1TowerJetPUSubtraction + // This value is calibrated to offline calo rho if useRhoCalibration in the config file is set to true double cal_rhoL1 = *calRho; + + // Retrive local rhos and eta boundries corresponding to these rhos + // Local PU subtraction + vector lRho = *LocalRho; + // vector localRhoEtaDiv = localRhoEtaDiv;//*LocalRhoBoundaries; + + /////////////////////////////////////////////////// // JET VALUES /////////////////////////////////////////////////// @@ -117,55 +174,122 @@ L1TowerJetPUSubtractedProducer::produce(edm::Event& iEvent, const edm::EventSetu math::PtEtaPhiMLorentzVector upgrade_jet; //Produce calibrated pt collection: central jets - for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); - il1!= UnCalibCen->end() ; - ++il1 ){ - - L1TowerJet h=(*il1); - - // float l1Eta_ = il1->p4().eta(); - // float l1Phi_ = il1->p4().phi(); - float l1Pt_ = il1->p4().Pt(); - - //weighted eta is still not correct - //change the contents out p4, upgrade_jet when it is corrected - float l1wEta_ = il1->WeightedEta(); - float l1wPhi_ = il1->WeightedPhi() ; - + for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); il1!= UnCalibCen->end(); ++il1 ){ + + L1TowerJet h = (*il1); + + // Extract the old tower jet information and store in a new tower jet + // Extremely awkward, to be fixed later + // double l1Pt_ = il1->Pt(); + double unSubPt = h.Pt(); + double weightedEta = il1->WeightedEta(); + double l1wPhi_ = il1->WeightedPhi() ; + + // **************************************** + // * Store the pre PU subtracted jets * + // **************************************** + + math::PtEtaPhiMLorentzVector p4; + //use weighted eta and phi: these are energy weighted + p4.SetCoordinates(unSubPt , weightedEta , l1wPhi_ , il1->p4().M() ); + h.setP4(p4); + + outputCollCenPrePUSub->insert( weightedEta , l1wPhi_ , h ); //This is just for 8x8 circular jets: change if using different jets - double areaPerJet = 52 * (0.087 * 0.087) ; - //PU subtraction - float l1Pt_PUsub_ = l1Pt_ - (cal_rhoL1 * areaPerJet); + //double areaPerJet = 52 * (0.087 * 0.087) ; - //only keep jet if pt > 0 after PU sub - if(l1Pt_PUsub_>0.1){ + // Get the eta*phi area of the jet + double areaPerJet = il1->JetRealArea(); + + // Perform the PU subtraction + float l1Pt_PUsub_ = unSubPt - (cal_rhoL1 * areaPerJet); + + + // store the PU subtracted jets with Pt greater than specified threshold + if(l1Pt_PUsub_ > jetPtPUSubThreshold){ math::PtEtaPhiMLorentzVector p4; //use weighted eta and phi: these are energy weighted - p4.SetCoordinates(l1Pt_PUsub_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); - + p4.SetCoordinates(l1Pt_PUsub_ , weightedEta , l1wPhi_ , il1->p4().M() ); h.setP4(p4); - outputCollCen->insert( l1wEta_ , l1wPhi_ , h ); - upgrade_jet.SetCoordinates( l1Pt_PUsub_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); + + // Store the PU subtracted towerjet + outputCollCen->insert( weightedEta , l1wPhi_ , h ); + + upgrade_jet.SetCoordinates( l1Pt_PUsub_ , weightedEta , l1wPhi_ , il1->p4().M() ); // add jet to L1Extra list - outputExtraCen->push_back( L1JetParticle( math::PtEtaPhiMLorentzVector( - l1Pt_PUsub_, - l1wEta_, - l1wPhi_, - 0. ), - Ref< L1GctJetCandCollection >(), 0 ) - ); + outputExtraCen->push_back( L1JetParticle( math::PtEtaPhiMLorentzVector( l1Pt_PUsub_, weightedEta, l1wPhi_, 0. ), + Ref< L1GctJetCandCollection >(), 0 ) ); } - } + + + // + // Local PU subtraction + // + + double localSubtractedPt; + + for (unsigned int iSlice = 0;iSlice < localRhoEtaDiv.size() - 1; iSlice++){ + + // Get the current eta slice range + double etaLow = localRhoEtaDiv[iSlice]; + double etaHigh = localRhoEtaDiv[iSlice + 1]; + + + // Store the jet in the respective eta region + if ( (weightedEta >= etaLow) && (weightedEta < etaHigh) ){ + + + // CHECK THIS CORRESPONDS TO THE CORRECT REGION + double localRho = lRho[iSlice]; + + + // Calculate the local PU subtrated pT + localSubtractedPt = unSubPt - localRho * areaPerJet; + + + // std::cout << "pT = " << unSubPt << "\tArea = " << areaPerJet << "\tEta = " << weightedEta << "\tetaRange = (" << etaLow << ", " << etaHigh + // << ")\tPUS pT = " << localSubtractedPt<< "\n"; + // std::cout << "\nEtaLow = " << etaLow << "\tEtaHigh = " << etaHigh << "\tLocalRho = " << localRho << "\tAreaPerJet = " + // << areaPerJet << "\tUnPUSPt = " << unSubPt << "\tLocalPUSPt = " << localSubtractedPt << "\n"; + + } + + + } + + + + + + // store the PU subtracted jets with pT greater than specified threshold + if(localSubtractedPt > jetPtPUSubThreshold){ + + // Local PUS jet + h.setPt(localSubtractedPt); + + // Store the local PUS jet + cenLocalPUS->insert( weightedEta , l1wPhi_, h ); + + } + } + + // Store the pre PU-subtracted, positive energy central jets + iEvent.put(outputCollCenPrePUSub,"PrePUSubCenJets"); + + //this is the slhc collection containing extra information + iEvent.put(outputCollCen,"PUSubCenJets"); - //this is the slhc collection containing extra information - iEvent.put(outputCollCen,"PUSubCenJets"); - //this is the l1extra collection containing the same jet vector as in slhc collection - iEvent.put(outputExtraCen,"PUSubCen8x8"); + iEvent.put(cenLocalPUS,"LocalPUSubCenJets"); + + //this is the l1extra collection containing the same jet vector as in slhc collection + iEvent.put(outputExtraCen,"PUSubCen8x8"); + + } } diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc index 72fe7c1845574..49e210cee49c3 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc @@ -1,3 +1,5 @@ +// Original Author: Andrew W. Rose Imperial College, London +// Modifications : Mark Baber Imperial College, London #include "SLHCUpgradeSimulations/L1CaloTrigger/interface/L1CaloAlgoBase.h" @@ -23,45 +25,62 @@ public L1CaloAlgoBase < l1slhc::L1CaloTowerCollection, l1slhc::L1TowerJetCollect void algorithm( const int &, const int & ); private: - void calculateJetPosition( l1slhc::L1TowerJet & lJet ); + // void calculateJetPosition( l1slhc::L1TowerJet & lJet ); //some helpful members int mJetDiameter; l1slhc::L1TowerJet::tJetShape mJetShape; std::vector< std::pair< int , int > > mJetShapeMap; + // Jet Pt and TT E seed thresholds + double jetPtThreshold, seedEThreshold; + }; L1TowerJetProducer::L1TowerJetProducer( const edm::ParameterSet & aConfig ):L1CaloAlgoBase < l1slhc::L1CaloTowerCollection, l1slhc::L1TowerJetCollection > ( aConfig ) { + + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetProducer\n----------------------------------------\n\n"; + + // load the jet Pt and TT E seed thresholds + jetPtThreshold = aConfig.getParameter ("JetPtThreshold"); + seedEThreshold = aConfig.getParameter ("SeedEnergyThreshold"); + std::string lJetShape = aConfig.getParameter< std::string >("JetShape"); mJetDiameter = aConfig.getParameter("JetDiameter"); mPhiOffset = 0; + + //note: this mEtaOffset works when read in setupHF.xml in SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py + //must be used with aEta>4 in algorithm() function below + // mEtaOffset = -(mJetDiameter+4); + + //if use with setup.xml where don't read in HF wires use + mEtaOffset = -(mJetDiameter); + //and don't need aEta>4 condition + + // mPhiIncrement = 1; + // mEtaIncrement = 1; - //note: this mEtaOffset works when read in setupHF.xml in SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py - //must be used with aEta>4 in algorithm() function below -// mEtaOffset = -(mJetDiameter+4); + mJetShapeMap.reserve(256); //jets will never be 16x16 but it is a nice round number - //if use with setup.xml where don't read in HF wires use - mEtaOffset = -(mJetDiameter); - //and don't need aEta>4 condition - // mPhiIncrement = 1; - // mEtaIncrement = 1; + //do the comparison in upper case so config file can read "Circle", "circle", "CIRCLE", "cIrClE", etc. and give the same result. + std::transform( lJetShape.begin(), lJetShape.end(), lJetShape.begin(), ::toupper ); + std::cout << "Creating JetShapeMap:\n"; - mJetShapeMap.reserve(256); //jets will never be 16x16 but it is a nice round number - std::string lJetShape = aConfig.getParameter< std::string >("JetShape"); - std::transform( lJetShape.begin() , lJetShape.end() , lJetShape.begin() , ::toupper ); //do the comparison in upper case so config file can read "Circle", "circle", "CIRCLE", "cIrClE", etc. and give the same result. + // ******************************************************************** + // * Circular jet shape * + // ******************************************************************** - std::cout << "Creating JetShapeMap:" << std::endl; if ( lJetShape == "CIRCLE" ){ mJetShape = l1slhc::L1TowerJet::circle; - double lCentre( (mJetDiameter-1) / 2.0 ); + double lCentre( (mJetDiameter - 1) / 2.0 ); double lDelta; + // Caculate square of the distance from jet centre to TT std::vector lDeltaSquare; for( int i = 0 ; i != mJetDiameter ; ++i ){ lDelta = double(i) - lCentre; @@ -69,22 +88,28 @@ L1TowerJetProducer::L1TowerJetProducer( const edm::ParameterSet & aConfig ):L1Ca } double lDeltaRSquare; + // Calculate maximum deltaR = (mJetDiameter/2)^2 double lDeltaRSquareMax( (mJetDiameter*mJetDiameter) / 4.0 ); + // Determine and store the TTs that are inside the deltaR region for( int x = 0 ; x != mJetDiameter ; ++x ){ for( int y = 0 ; y != mJetDiameter ; ++y ){ lDeltaRSquare = lDeltaSquare[x] + lDeltaSquare[y]; + // TT is inside the deltaR^2 region if( lDeltaRSquare <= lDeltaRSquareMax ){ mJetShapeMap.push_back( std::make_pair( x , y ) ); - //std::cout << "#" << std::flush; - }else{ - //std::cout << "-" << std::flush; } } - //std::cout << std::endl; } - }else{ + } + + + // ******************************************************************** + // * Square jet shape * + // ******************************************************************** + + else if ( lJetShape == "SQUARE" ){ mJetShape = l1slhc::L1TowerJet::square; @@ -94,117 +119,93 @@ L1TowerJetProducer::L1TowerJetProducer( const edm::ParameterSet & aConfig ):L1Ca } } } + + // Shape does not exist + else{ + + throw cms::Exception("Invalid jet shape type") + << "ERROR: Jet shape '" << lJetShape + << "' not recognised, check the input in the configuration file matches a valid type.\n"; + + } std::cout << "JetShapeMap includes " << mJetShapeMap.size() << " towers." << std::endl; - std::cout<<" Eta offset is "<< mEtaOffset << std::endl; + std::cout << "Eta offset is " << mEtaOffset << std::endl; + + } L1TowerJetProducer::~L1TowerJetProducer( ) { } -/* - void L1TowerJetProducer::initialize( ) { } -*/ +// Generate all the possible tower jets in the event void L1TowerJetProducer::algorithm( const int &aEta, const int &aPhi ) { -// if(aEta>4){ - - int lTowerIndex = mCaloTriggerSetup->getBin( aEta, aPhi ); + + int lTowerIndex = mCaloTriggerSetup->getBin( aEta, aPhi ); std::pair < int, int > lTowerEtaPhi = mCaloTriggerSetup->getTowerEtaPhi( lTowerIndex ); - l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mJetShapeMap.size() , lTowerEtaPhi.first , lTowerEtaPhi.second ); - - for ( std::vector< std::pair< int , int > >::const_iterator lJetShapeMapIt = mJetShapeMap.begin() ; lJetShapeMapIt != mJetShapeMap.end() ; ++lJetShapeMapIt ) - { - int lPhi = aPhi+(lJetShapeMapIt->second); - if ( lPhi > mCaloTriggerSetup->phiMax( ) ) lPhi -= 72; //mCaloTriggerSetup->phiMax( ); - - l1slhc::L1CaloTowerCollection::const_iterator lTowerItr = fetch( aEta+(lJetShapeMapIt->first) , lPhi ); + // Construct a TowerJet object at the current iEta, iPhi position with given jet shape and size + l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mJetShapeMap , lTowerEtaPhi.first , lTowerEtaPhi.second ); + // Calculate the geometric center of the jet + lJet.calculateJetCenter(); - if ( lTowerItr != mInputCollection->end( ) ) - { - l1slhc::L1CaloTowerRef lRef( mInputCollection, lTowerItr - mInputCollection->begin( ) ); - lJet.addConstituent( lRef ); - lJet.CalcWeightediEta(); - lJet.CalcWeightediPhi(); - } - } - - if ( lJet.E( ) > 0 ) - { - calculateJetPosition( lJet ); - - lJet.calculateWeightedEta();lJet.calculateWeightedPhi(); - mOutputCollection->insert( lTowerEtaPhi.first, lTowerEtaPhi.second, lJet ); - } -//} -} + // Parameter to determine whether at least one TT in the tower jet exceeds the specified energy threshold + bool exceedsSeedThreshold = false; + + // Iterate over the jet shape mask + for ( std::vector< std::pair< int , int > >::const_iterator lJetShapeMapIt = mJetShapeMap.begin() ; lJetShapeMapIt != mJetShapeMap.end() ; + ++lJetShapeMapIt ){ -void L1TowerJetProducer::calculateJetPosition( l1slhc::L1TowerJet & lJet ) -{ + // Mask TT iPhi + int lPhi = aPhi + (lJetShapeMapIt->second); + if ( lPhi > mCaloTriggerSetup->phiMax( ) ) lPhi -= 72; //mCaloTriggerSetup->phiMax( ); + + // Get TT at current position: (aEta + jetMapEta, iPhi) + l1slhc::L1CaloTowerCollection::const_iterator lTowerItr = fetch( aEta + (lJetShapeMapIt->first) , lPhi ); - double tmpeta(9999); - double halfTowerOffset = 0.0435; - const double endcapEta[8] = { 0.09, 0.1, 0.113, 0.129, 0.15, 0.178, 0.15, 0.35 }; - double JetSize = double(lJet.JetSize()) / 2.0; - //std::cout<<" jet ieta: "<< lJet.iEta( ); - int abs_eta = lJet.iEta( ) + int(JetSize) ; - //std::cout<<" centre of jet: "<=0 && lJet.iEta( )<0 ) abs_eta += 1; - - //std::cout<<" account for no zero: "<end( ) ){ + l1slhc::L1CaloTowerRef lRef( mInputCollection, lTowerItr - mInputCollection->begin( ) ); + // Check that at least one TT exceeds a seed energy threshold - Compensate for 2 GeV units + if ( (lRef->E() + lRef->H()) >= 2*seedEThreshold ){ + exceedsSeedThreshold = true; + } - if ( abs_eta < 21 ) - { - tmpeta = ( abs_eta * 0.0870 - halfTowerOffset); - - if( lJet.JetSize() % 2 == 1 ) tmpeta += halfTowerOffset; + // Add TT to the tower jet + lJet.addConstituent( lRef ); + } } - else - { - abs_eta -= 21; + - tmpeta = 1.74; + + // Add jets to the output collection, require that the at least one TT possess energy greater than the specified + // seed threshold and that the jet possesses a Pt greater than the specified jet Pt threshold + if ( (exceedsSeedThreshold) && (lJet.E() > jetPtThreshold) ){ - for ( int i = 0; i != int(abs_eta); ++i ) - { - tmpeta += endcapEta[i]; - } + + // Calculate the energy weighted eta and phi and the centrality of the jet + lJet.calculateWeightedJetCenter(); + lJet.calculateCentrality(); + lJet.setP4( math::PtEtaPhiMLorentzVector( lJet.E(), lJet.WeightedEta(), lJet.WeightedPhi(), 0. ) ); - if( lJet.JetSize() % 2 == 0 ) tmpeta += endcapEta[abs_eta] / 2.; - else tmpeta += endcapEta[abs_eta]; + // Store jet in the output collection + mOutputCollection->insert( lTowerEtaPhi.first, lTowerEtaPhi.second, lJet ); } - if(( lJet.iEta( ) + int(JetSize) )<0) tmpeta = (-1)*tmpeta; - //if (lJet.iEta()>0) tmpeta-=0.087; - - // std::cout<<"jet ieta: "<pi) phi-=2*pi; - - double Et = double( lJet.E( ) ) / 2.; - - lJet.setP4( math::PtEtaPhiMLorentzVector( Et, tmpeta, phi, 0. ) ); +} -} diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py index 6e85a1f2d616f..58c7e75672509 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py +++ b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py @@ -21,11 +21,13 @@ L1CaloJetProducer+ L1CaloJetFilter+ L1TowerJetProducer+ - L1TowerJetFilter1D+ - L1TowerJetFilter2D+ + L1TowerJetCentralityFilter+ + #L1TowerJetFilter1D+ + #L1TowerJetFilter2D+ L1TowerJetPUEstimator+ L1TowerJetPUSubtractedProducer+ L1CalibFilterTowerJetProducer+ + L1EnergySumProducer+ # L1TowerFwdJetProducer+ # L1TowerFwdJetFilter1D+ diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py index 1806c8de3fe73..143e77a7cbf53 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py +++ b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py @@ -1,6 +1,30 @@ import FWCore.ParameterSet.Config as cms +#---------------------------------------------------------------------------------------------------- +# Global variables +#---------------------------------------------------------------------------------------------------- +# +# Info: These are variables that are required by several modules. +# +#---------------------------------------------------------------------------------------------------- + + +# Specify the boundaries of the eta regions in which to apply local PU subtraction +gLocalRhoEtaDivisions = cms.vdouble( -3.0, -1.3, 0.0, 1.3, 3.0 ) + +# Run on Asymmetry filtered jets +#gPrePUSJets = "L1TowerJetFilter2D" +# Run on Centrality filtered jets +gPrePUSJets = "L1TowerJetCentralityFilter" + + + +gJetDiameter = cms.uint32(9) # default to 9x9 ~ deltaR 0.4 Jets + + +#==================================================================================================== + L1CaloTriggerSetupSource = cms.ESSource("EmptyESSource", recordName = cms.string('L1CaloTriggerSetupRcd'), firstValid = cms.vuint32(1), @@ -133,59 +157,136 @@ src = cms.InputTag("L1CaloJetFilter") ) + L1TowerJetProducer = cms.EDProducer("L1TowerJetProducer", + + # UNCOMMENT TO RUN ON RINGSUBTRACTED CALOTOWERS + #src = cms.InputTag("L1RingSubtractionProducer"), + # UNCOMMENT TO RUN ON UN-RINGSUBTRACTED CALOTOWERS src = cms.InputTag("L1CaloTowerProducer"), - JetDiameter = cms.uint32(8), - JetShape = cms.string("circle") # "circle" or "square" + + + JetDiameter = gJetDiameter, + JetShape = cms.string("circle"), # "circle" or "square" + + # Jet Pt (GeV) threshold and the seed threshold requirement (require that at least one TT + # posses E greater than threshold) for the constructed jets to be retained + JetPtThreshold = cms.double(0.1), + SeedEnergyThreshold = cms.double(0), + #SeedEnergyThreshold = cms.double(5), +) + +# Centrality filtering +L1TowerJetCentralityFilter = cms.EDProducer("L1TowerJetCentralityFilter", + PreFilteredJets = cms.InputTag("L1TowerJetProducer"), + # Limit on number of jets that can be retained + NumOfOutputJets = cms.uint32(999) ) L1TowerJetFilter1D = cms.EDProducer("L1TowerJetFilter1D", src = cms.InputTag("L1TowerJetProducer"), - ComparisonDirection = cms.string("eta"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(4) + ComparisonDirection = cms.string("eta"), # "eta" or "phi" + # Old arbitrary jet 1D limit + #NumOfOutputJets = cms.uint32(4) + NumOfOutputJets = cms.uint32(999) ) L1TowerJetFilter2D = cms.EDProducer("L1TowerJetFilter2D", src = cms.InputTag("L1TowerJetFilter1D"), - ComparisonDirection = cms.string("phi"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(12) + ComparisonDirection = cms.string("phi"), # "eta" or "phi" + # Old arbitrary jet event limit + #NumOfOutputJets = cms.uint32(12) + NumOfOutputJets = cms.uint32(999) ) + + L1TowerJetPUEstimator = cms.EDProducer("L1TowerJetPUEstimator", - inRhodata_file = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/rho_lookup.txt'), - FilteredCircle8 = cms.InputTag("L1TowerJetFilter2D"), + inRhodata_file = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/rho_lookup.txt'), +# FilteredCircle8 = cms.InputTag("L1TowerJetFilter2D"), + FilteredCircle8 = cms.InputTag(gPrePUSJets), + # Choose whether to calibrate rho to offline rho + UseRhoCalibration = cms.bool(False), + # number of jets, from the start of the ordered jet collection, to exclude from the median calculation of rho + # numberOfSkippedJets = 1 => Skip leading jet only + numberOfSkippedJets = cms.uint32(1), + # Specify the boundaries of the eta regions in which to apply local PU subtraction + LocalRhoEtaDivisions = cms.vdouble( gLocalRhoEtaDivisions ), + # Specify the minimum number of jets in each eta region before a local rho is calculated. + # If threshold is not met, zero is subtracted. + LocalRhoMinJetsInRegion = cms.uint32(2) ) + L1TowerJetPUSubtractedProducer = cms.EDProducer("L1TowerJetPUSubtractedProducer", - FilteredCircle8 = cms.InputTag("L1TowerJetFilter2D"), + + FilteredCircle8 = cms.InputTag(gPrePUSJets), CalibratedL1Rho = cms.InputTag("L1TowerJetPUEstimator", "Rho"), + + # Local PU subtraction + LocalRho = cms.InputTag("L1TowerJetPUEstimator", "LocalRho"), +# LocalRhoBoundaries = cms.InputTag("L1TowerJetPUEstimator", "LocalRhoEtaBoundaries"), + # Specify the boundaries of the eta regions in which to apply local PU subtraction + LocalRhoEtaDivisions = cms.vdouble( gLocalRhoEtaDivisions ), + + # Energy (GeV) threshold of the jets that are to be retained after PU subtraction + JetPtPUSubThreshold = cms.double(0.1), ) + L1CalibFilterTowerJetProducer = cms.EDProducer("L1CalibFilterTowerJetProducer", - inMVA_weights_file = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/TMVARegression_BDT.weights.xml'), - PUSubtractedCentralJets = cms.InputTag("L1TowerJetPUSubtractedProducer","PUSubCenJets"), + + + # Energy (GeV) threshold of jets to be used in the calculation jet energy sums + EnergySumsJetPtThreshold = cms.double(15), + + # Calibration parameters + # ------------------------------ + + # Input uncalibrated jet collection + UncalibratedTowerJets = cms.InputTag("L1TowerJetPUSubtractedProducer","LocalPUSubCenJets"), + + # L1 pT calibration threshold, minimum L1 jet pT (GeV) to apply correction + pTCalibrationThreshold = cms.double( 10 ), + + # Calibration eta-binning + EtaRegionSlice = cms.vdouble( -3.0, -2.172, -1.74, -1.392, -1.044, -0.695, -0.348, 0.0, + 0.348, 0.695, 1.044, 1.392, 1.74, 2.172, 3.0), + + # Number of calibration parameters used in LUT + CalibrationParameters = cms.uint32( 6 ), + + # Location of LUT + CalibrationLUTFile = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT'), + ) +L1EnergySumProducer = cms.EDProducer("L1EnergySumProducer", + CalorimeterTowers = cms.InputTag("L1CaloTowerProducer:","EVENT_DATA"), +) L1TowerFwdJetProducer = cms.EDProducer("L1TowerFwdJetProducer", src = cms.InputTag("L1CaloTowerProducer"), - JetDiameter = cms.uint32(8), - JetShape = cms.string("circle") # "circle" or "square" -) + + JetDiameter = gJetDiameter, + JetShape = cms.string("circle") # "circle" or "square" +) + + L1TowerFwdJetFilter1D = cms.EDProducer("L1TowerJetFilter1D", src = cms.InputTag("L1TowerFwdJetProducer"), ComparisonDirection = cms.string("eta"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(4) + NumOfOutputJets = cms.uint32(999) ) L1TowerFwdJetFilter2D = cms.EDProducer("L1TowerJetFilter2D", src = cms.InputTag("L1TowerFwdJetFilter1D"), ComparisonDirection = cms.string("phi"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(12) + NumOfOutputJets = cms.uint32(999) ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py index 97e51bd8490a0..85047ca211c46 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py @@ -23,10 +23,15 @@ process.source = cms.Source("PoolSource", fileNames = cms.untracked.vstring( # electron file: - #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root' + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SingleElectron_E2023TTI_PU140.root', + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SinglePositron_E2023TTI_PU140.root', + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SinglePositron_E2023TTI_PU140.root' + # # rate test sample: - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + # ) ) @@ -102,9 +107,11 @@ process.pElectronsLoose = cms.Path( process.L1TkElectronsLoose) # to test a lower PT cut : -#process.L1TkElectronsLooseV2 = process.L1TkElectronsLoose.clone() -#process.L1TkElectronsLooseV2.TrackMinPt = cms.double( 2. ) -#process.pElectronsLoose2 = cms.Path( process.L1TkElectronsLooseV2 ) +process.L1TkElectronsLooseV2 = process.L1TkElectronsLoose.clone() +process.L1TkElectronsLooseV2.TrackMinPt = cms.double( 2. ) +process.L1TkElectronsLooseV2.TrackEGammaDeltaPhi = cms.vdouble( 0.2, 0.,0.) +process.L1TkElectronsLooseV2.TrackEGammaDeltaR = cms.vdouble( 0.2, 0.,0.) +process.pElectronsLoose2 = cms.Path( process.L1TkElectronsLooseV2 ) # ---- L1TkElectrons that are isolated w.r.t. L1Tracks : dedicated low PT sequence process.L1TkIsoElectronsLoose = process.L1TkElectronsLoose.clone() @@ -165,7 +172,7 @@ #process.Out.outputCommands.append('keep *_generator_*_*') #process.Out.outputCommands.append('keep *_*gen*_*_*') #process.Out.outputCommands.append('keep *_*Gen*_*_*') -#process.Out.outputCommands.append('keep *_genParticles_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') # the L1Tracks, clusters and stubs @@ -191,13 +198,13 @@ process.Out.outputCommands.append('keep *_L1TkElectronsLoose_*_*') process.Out.outputCommands.append('keep *_L1TkIsoElectronsLoose_*_*') -#process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') +process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') # --- to use the genParticles, one needs to keep the collections of associators below: -#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') -#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') -#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') process.FEVToutput_step = cms.EndPath(process.Out) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py index 1cf4e70a46ff4..c0af59a539850 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py @@ -57,7 +57,7 @@ process.load('Configuration.StandardSequences.RawToDigi_cff') process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") -process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets +#process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets process.p = cms.Path( process.RawToDigi+ @@ -81,7 +81,7 @@ process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkJetProducer_cfi") process.L1TkJetsL1 = process.L1TkJets.clone() -#process.pL1TkJetsL1 = cms.Path( process.L1TkJetsL1 ) +process.pL1TkJetsL1 = cms.Path( process.L1TkJetsL1 ) # --------------------------------------------------------------------------- @@ -117,7 +117,6 @@ # --- Produce L1TkJets from the HeavyIon jets process.L1TkJetsHI = process.L1TkJets.clone() process.L1TkJetsHI.L1CentralJetInputTag = cms.InputTag("L1JetsFromHIHLTJets") -#process.L1TkJetsHI.JET_HLTETA = cms.bool(True) process.pL1TkJetsHI = cms.Path( process.L1TkJetsHI ) # diff --git a/SimDataFormats/SLHC/interface/L1TowerJet.h b/SimDataFormats/SLHC/interface/L1TowerJet.h index 1ab82b3ba302f..3dd3570ada7f6 100644 --- a/SimDataFormats/SLHC/interface/L1TowerJet.h +++ b/SimDataFormats/SLHC/interface/L1TowerJet.h @@ -8,7 +8,7 @@ #include #include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" #include "SimDataFormats/SLHC/interface/L1CaloTower.h" - +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/TriggerTowerGeometry.h" namespace l1slhc { @@ -28,91 +28,144 @@ namespace l1slhc L1TowerJet( ); L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea ); - L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea , const int& iEta, const int& iPhi); - ~L1TowerJet( ); + // L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea , const int& iEta, const int& iPhi); + L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , + const std::vector< std::pair< int, int > >& aJetShapeMap, const int &iEta, const int &iPhi ); + + ~L1TowerJet( ); // getters + // ~~~~~~~ + // Jet iEta and iPhi parameters (Eta and phi of top-left reference TT) const int& iEta( ) const; const int& iPhi( ) const; - const int& E( ) const; + // Total TT energy sum (GeV) + const double& E( ) const; const bool& central( ) const; + // centrality member variables + const double& Centrality( ) const; + //asymmetry member variables const int& AsymEta( ) const; const int& AsymPhi( ) const; - //weighted iEta, iPhi + + /* //weighted iEta, iPhi const double& iWeightedEta( ) const; const double& iWeightedPhi( ) const; - - const double& WeightedEta( ) const; - const double& WeightedPhi( ) const; - - const math::PtEtaPhiMLorentzVector& p4( ) const; // returns LorentzVector in eta,phi space + */ + + // Jet pT + const double Pt( ) const; + // Geometric jet center eta and phi + const double Eta( ) const; + const double Phi( ) const; + // Energy weighted eta and phi of jet center + const double WeightedEta( ) const; + const double WeightedPhi( ) const; + // Jet pT, weighted eta, weighted phi and mass + const math::PtEtaPhiMLorentzVector& p4( ) const; + // Jet shape width in TTs const int& JetSize( ) const; + // Jet shape type const L1TowerJet::tJetShape& JetShape( ) const; - + // Area of jet in TTs const int& JetArea( ) const; + // Real area of jet (deltaEta * deltaPhi) + const double& JetRealArea( ) const; + + +/* const double& MaxTTEnergy( ) const; */ +/* const double& MaxTTEnergyInSeedRegion( ) const; */ // possibly helpful methods // double EcalVariance( ) const; // double HcalVariance( ) const; // double EnergyVariance( ) const; - + // Median absolute deviations double EcalMAD() const; double HcalMAD() const; double EnergyMAD() const; // Setters - + // ~~~~~~~ void setP4( const math::PtEtaPhiMLorentzVector & p4 ); + void setPt( const double & pT ); void setCentral( const bool& ); -// void setE( const int& ); - - void CalcWeightediEta(); - void CalcWeightediPhi(); - - void calculateWeightedEta( ); - void calculateWeightedPhi(); - - + // Calculate the jet centrality + void calculateCentrality(); + // Determine the central jet eta and phi for unweighted and energy weighting + void calculateJetCenter(); + void calculateWeightedJetCenter(); + // Add a TT to the TowerJet void addConstituent( const L1CaloTowerRef & Tower ); L1CaloTowerRefVector::iterator getConstituent( const int& eta , const int& phi ); void removeConstituent( const int& eta , const int& phi ); const L1CaloTowerRefVector& getConstituents( ) const; - + + double MAD( std::deque& aDataSet ) const; private: + // i-coordinates, define the top left TT of the jet int mIeta; int mIphi; - int mE; + // Energy of jet in 2 GeV units: 1 -> 2 GeV (REMOVE THIS) + int mE2GeV; + // True value of E in GeV + double mE; + +/* int mMaxTTEnergy2GeV; */ +/* int mMaxTTEnergyInSeedRegion2GeV; */ + bool mCentral; - //add asym + // Asymmetry parameters int mAsymEta; int mAsymPhi; + + // Centrality parameter + double mCentrality; //weighted eta and phi - double mWeightedIeta; + /*double mWeightedIeta; double mWeightedIphi; + */ + /* double mWeightedEta; double mWeightedPhi; + */ + // Jet center eta and phi + double mJetCenterEta; + double mJetCenterPhi; + // Size and area of jet in TTs int mJetSize; L1TowerJet::tJetShape mJetShapeType; int mJetArea; + // Actual eta*phi jet area + double mJetRealArea; + // Undo wrapping of iPhi + int iPhiUnwrap(int aIphi); + + // Tower geometry converter + static TriggerTowerGeometry mTowerGeo; L1CaloTowerRefVector mConstituents; + + // Pt, energy weighted eta, energy weighted phi and mass of the jet math::PtEtaPhiMLorentzVector mP4; - double MAD( std::deque& aDataSet ) const; + + + static const double PI; }; @@ -120,12 +173,13 @@ namespace l1slhc } -// Sorting functor +// Jet rank operator namespace std{ - bool operator< ( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ); + bool operator<( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ); + bool operator>( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ); } - +// Jet printing std::ostream & operator<<( std::ostream & , const l1slhc::L1TowerJet & ); #endif diff --git a/SimDataFormats/SLHC/src/L1TowerJet.cc b/SimDataFormats/SLHC/src/L1TowerJet.cc index 72fa6e00777e0..e8d5e58f2bdb8 100644 --- a/SimDataFormats/SLHC/src/L1TowerJet.cc +++ b/SimDataFormats/SLHC/src/L1TowerJet.cc @@ -1,221 +1,300 @@ #include "SimDataFormats/SLHC/interface/L1TowerJet.h" #include + namespace l1slhc { + + // Initialising the static tower geometry member variable + TriggerTowerGeometry L1TowerJet::mTowerGeo = TriggerTowerGeometry(); + + const double L1TowerJet::PI = 3.14159265359; + L1TowerJet::L1TowerJet( ): - mIeta( 0 ), - mIphi( 0 ), + mIeta( 0 ), + mIphi( 0 ), + + mE2GeV( 0 ), + mE( 0 ), + mCentral( true ), + mAsymEta(0), + mAsymPhi(0), + /* mWeightedIeta( 0 ), + mWeightedIphi( 0 ),*/ + mJetCenterEta( 0 ), + mJetCenterPhi( 0 ), - mE( 0 ), - mCentral( true ), - mAsymEta(0), - mAsymPhi(0), - mWeightedIeta( 0 ), - mWeightedIphi( 0 ), - mJetSize( 12 ), - mJetShapeType( square ), - mJetArea( 144 ) + mJetSize( 12 ), + mJetShapeType( square ), + mJetArea( 144 ), + mJetRealArea( mJetArea * 0.087 * 0.087 ) { } L1TowerJet::L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea ): - mIeta( 0 ), - mIphi( 0 ), - mE( 0 ), - mCentral( true ), - mAsymEta(0), - mAsymPhi(0), - mWeightedIeta( 0 ), - mWeightedIphi( 0 ), + mIeta( 0 ), + mIphi( 0 ), - mJetSize( aJetSize ), - mJetShapeType( aJetShapeType ), - mJetArea( aJetArea ) - { + mE2GeV( 0 ), + mE( 0 ), + mCentral( true ), + mAsymEta(0), + mAsymPhi(0), + /* mWeightedIeta( 0 ), + mWeightedIphi( 0 ),*/ + mJetCenterEta( 0 ), + mJetCenterPhi( 0 ), + + mJetSize( aJetSize ), + mJetShapeType( aJetShapeType ), + mJetArea( aJetArea ), + mJetRealArea( mJetArea * 0.087 * 0.087 ) + { // The above mJetRealArea calculation assumes the towers in the jet all occupy the region |eta| < 1.74 } - L1TowerJet::L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea , const int &iEta, const int &iPhi ): - mIeta( iEta ), - mIphi( iPhi ), - mE( 0 ), - mCentral( true ), - mAsymEta(0), - mAsymPhi(0), + L1TowerJet::L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , + const std::vector< std::pair< int, int > >& aJetShapeMap, const int &iEta, const int &iPhi ): + + mIeta( iEta ), + mIphi( iPhi ), - mWeightedIeta( 0 ), - mWeightedIphi( 0 ), + mE2GeV( 0 ), + mE( 0 ), + mCentral( true ), + mAsymEta(0), + mAsymPhi(0), + /* mWeightedIeta( 0 ), + mWeightedIphi( 0 ),*/ + mJetCenterEta( 0 ), + mJetCenterPhi( 0 ), - mJetSize( aJetSize ), - mJetShapeType( aJetShapeType ), - mJetArea( aJetArea ) + mJetSize( aJetSize ), + mJetShapeType( aJetShapeType ), + mJetArea( aJetShapeMap.size() ), + mJetRealArea( 0 ) { + + // ************************************************** + // * Calculate the real jet area * + // ************************************************** + + // Check if jet fully contained within |eta| < 1.74, in which case all TTs have the same area + if ( (iEta + mJetSize < 22) && (iEta > -21) ){ + + // real jet area = Number of TTs * deltaPhi * deltaEta + mJetRealArea = mJetArea * 0.087 * 0.087; + } + else{ + + // calculate the real jet area, accounting for the change in trigger tower eta width + for ( std::vector< std::pair< int , int > >::const_iterator lJetShapeMapIt = aJetShapeMap.begin() ; + lJetShapeMapIt != aJetShapeMap.end() ; ++lJetShapeMapIt ){ + + // Get the iEta of the TT + int TTiEta = iEta + lJetShapeMapIt->first; + double TTarea = mTowerGeo.towerEtaSize( TTiEta ) * 0.087; + mJetRealArea += TTarea; + + + // Calculate the geometric center of the jet + //calculateJetCenter(); + + } + + } + } L1TowerJet::~L1TowerJet( ) { } - - + + + // ******************************************************************************** + // * Setters * + // ******************************************************************************** void L1TowerJet::setP4( const math::PtEtaPhiMLorentzVector & p4 ) { - mP4 = p4; + mP4 = p4; } - void L1TowerJet::setCentral( const bool & central ) + void L1TowerJet::setPt( const double & pT ) { - mCentral = central; + mP4.SetPt(pT); } -/* - void L1TowerJet::setE( const int &E ) + + + void L1TowerJet::setCentral( const bool & central ) { - mE = E; + mCentral = central; } -*/ + + // ******************************************************************************** + // * Getters * + // ******************************************************************************** + // iEta, eta of the top-left TT indexing the tower jet const int &L1TowerJet::iEta( ) const { - return mIeta; + return mIeta; } + // iPhi, phi of the top-left TT indexing the tower jet const int &L1TowerJet::iPhi( ) const { - return mIphi; + return mIphi; } - - - - const double &L1TowerJet::iWeightedEta( ) const + // Return Pt of jet + const double L1TowerJet::Pt( ) const { - - return mWeightedIeta; - + return mP4.Pt(); } - const double &L1TowerJet::iWeightedPhi( ) const + // Eta of tower jet geometric center + const double L1TowerJet::Eta( ) const { - - return mWeightedIphi; - + return mJetCenterEta; } - const double &L1TowerJet::WeightedEta( ) const + // Phi of tower jet geometric center + const double L1TowerJet::Phi( ) const { - - return mWeightedEta; - + return mJetCenterPhi; } - const double &L1TowerJet::WeightedPhi( ) const + // Energy weighted eta + const double L1TowerJet::WeightedEta( ) const { - - return mWeightedPhi; - + // The weighted eta information is stored within the four-vector + return mP4.Eta(); + // return mWeightedEta; } - - - - const int &L1TowerJet::E( ) const + // Energy weighted phi + const double L1TowerJet::WeightedPhi( ) const { - return mE; + // The weighted phi information is stored within the four-vector + return mP4.Phi(); + // return mWeightedPhi; + } + + // Total TT energy enclosed by tower jet in GeV (Corrected to account for energy being stored in multiples of 2 GeV) + const double &L1TowerJet::E( ) const + { // True value in GeV + return mE; } + const double &L1TowerJet::Centrality( ) const + { + return mCentrality; + } + const int& L1TowerJet::AsymEta( ) const { - return mAsymEta; + return mAsymEta; } const int& L1TowerJet::AsymPhi( ) const { - return mAsymPhi; + return mAsymPhi; } - const bool & L1TowerJet::central( ) const { - return mCentral; + return mCentral; } const math::PtEtaPhiMLorentzVector & L1TowerJet::p4( ) const { - return mP4; + return mP4; } - + + // The jet diameter in TTs const int& L1TowerJet::JetSize( ) const { - return mJetSize; + return mJetSize; } const L1TowerJet::tJetShape& L1TowerJet::JetShape( ) const { - return mJetShapeType; + return mJetShapeType; } + // The area of the jet in TTs const int& L1TowerJet::JetArea( ) const { - return mJetArea; + return mJetArea; } -/* - double L1TowerJet::EcalVariance( ) const + // The true eta*phi area of the jet + const double& L1TowerJet::JetRealArea( ) const { + return mJetRealArea; + } + + /* + double L1TowerJet::EcalVariance( ) const + { double lMean(0.0); double lMeanSq(0.0); for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lMean += (**lConstituentIt).E(); - lMeanSq += ((**lConstituentIt).E() * (**lConstituentIt).E()); + lMean += (**lConstituentIt).E(); + lMeanSq += ((**lConstituentIt).E() * (**lConstituentIt).E()); } lMean /= mConstituents.size(); lMeanSq /= mConstituents.size(); return lMeanSq - (lMean*lMean); - } + } - double L1TowerJet::HcalVariance( ) const - { + double L1TowerJet::HcalVariance( ) const + { double lMean(0.0); double lMeanSq(0.0); for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lMean += (**lConstituentIt).H(); - lMeanSq += ((**lConstituentIt).H() * (**lConstituentIt).H()); + lMean += (**lConstituentIt).H(); + lMeanSq += ((**lConstituentIt).H() * (**lConstituentIt).H()); } lMean /= mConstituents.size(); lMeanSq /= mConstituents.size(); return lMeanSq - (lMean*lMean); - } + } - double L1TowerJet::EnergyVariance( ) const - { + double L1TowerJet::EnergyVariance( ) const + { double lMean( double(mE) / double(mConstituents.size()) ); double lMeanSq(0.0); double lTower; for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lTower = (**lConstituentIt).E() + (**lConstituentIt).H(); - lMeanSq += ( lTower * lTower ); + lTower = (**lConstituentIt).E() + (**lConstituentIt).H(); + lMeanSq += ( lTower * lTower ); } lMeanSq /= mConstituents.size(); return lMeanSq - (lMean*lMean); - } -*/ + } + */ + + // ******************************************************************************** + // * Median absolute deviations * + // ******************************************************************************** double L1TowerJet::EcalMAD() const { @@ -240,6 +319,70 @@ namespace l1slhc } + + double L1TowerJet::EnergyMAD() const + { + std::deque< int > lEnergy; + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + lEnergy.push_back( (**lConstituentIt).E() + (**lConstituentIt).H() ); + } + lEnergy.resize( mJetArea , 0 ); + return MAD( lEnergy ); + } + + + + double L1TowerJet::MAD( std::deque& aDataSet ) const + { + std::sort( aDataSet.begin() , aDataSet.end() ); + + std::size_t lDataSetSize( aDataSet.size() ); + + double lMedian(0); + if( (lDataSetSize % 2) == 0 ){ + lMedian = double( aDataSet[ (lDataSetSize/2) - 1 ] + aDataSet[ lDataSetSize/2 ] ) / 2.0 ; + }else{ + lMedian = double( aDataSet[ (lDataSetSize-1)/2 ] ); + } + + + std::deque< double > lMedianSubtractedDataSet; + for ( std::deque< int >::const_iterator lIt = aDataSet.begin() ; lIt != aDataSet.end(); ++lIt ){ + lMedianSubtractedDataSet.push_back( fabs( double(*lIt) - lMedian ) ); + } + + std::sort( lMedianSubtractedDataSet.begin() , lMedianSubtractedDataSet.end() ); + + if( (lDataSetSize % 2) == 0 ){ + return double ( lMedianSubtractedDataSet[ (lDataSetSize/2) - 1 ] + lMedianSubtractedDataSet[ lDataSetSize/2 ] ) / 2.0 ; + }else{ + return double( lMedianSubtractedDataSet[ (lDataSetSize-1)/2 ] ); + } + + } + + + + + // ******************************************************************************** + // * Jet eta and phi variables * + // ******************************************************************************** + + + + + + + // ********************************************************************** + // * Jet iEta and iPhi variables * + // ********************************************************************** + + + + // ~ Why is this not following the getter naming convention? ~ + // ~ Weighted iEta assumes all trigger towers have the same width, the result will be different from ~ + // ~ discretising the weighted Eta. ~ + /* void L1TowerJet::CalcWeightediEta() { double etaSumEt(0); @@ -249,7 +392,7 @@ namespace l1slhc etaSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * ( (**lConstituentIt).iEta() ); sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; } -// std::cout<<" eta* energy = "<= (72-JetSize()) ) { //constituents may go over edge, iPhi>66 for 8x8 jet + if( tower_iPhi < (72 - JetSize()) ){//if constituent tower is over edge, ie. iPhi>1 + tower_iPhi+=72; //iPhi=1 -> iPhi=73 + } + } + //calculate weighted phi using corrected iPhi value + phiSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * (tower_iPhi ); + + sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; + } + // std::cout<<"phi sum et: "<72) mWeightedIphi-=72; + + + } + */ + + + + // ********************************************************************** + // * Jet eta and phi variables * + // ********************************************************************** + + + // Calculate the eta and phi of the geometric center of the jet + void L1TowerJet::calculateJetCenter(){ + + // determine the lowest and highest TTs enclosed by the jet shape (assumes square bounding box) + int lowIeta = mIeta; + int lowIphi = mIphi; + int highIeta = lowIeta + (mJetSize - 1); + int highIphi = lowIphi + (mJetSize - 1); + + // Extract the true eta of these TTs + double lowEta = mTowerGeo.eta(lowIeta); + double lowPhi = mTowerGeo.phi(lowIphi); + double highEta = mTowerGeo.eta(highIeta); + double highPhi = mTowerGeo.phi(highIphi); + + // Correct for phi wrap around, if jet map exceeds phi calorimeter range + if ( (lowIphi + (mJetSize - 1) ) > 72 ){ + + // Current tower has wrapped around + if ( highIphi < lowIphi ){ + highPhi += 2*PI; + } + + } + + // Determine the geometric jet center + mJetCenterEta = (highEta + lowEta)/2.0; + mJetCenterPhi = (highPhi + lowPhi)/2.0; + + // Constrain jets to the range [-Pi,Pi] + if (mJetCenterPhi > PI) + mJetCenterPhi -= 2*PI; + + + } + + + + // Calculate the energy weighted eta and phi center of the jet. + // Defined: Sum ( TT_Eta * TT_Et ) / Sum ( TT_Et ), etc + void L1TowerJet::calculateWeightedJetCenter() + { + + // Eta, phi and Et of the TT + double ttEta(0), ttPhi(0), ttEt(0); + // Sums of eta*Et phi*Et and Et + double etaEtSum(0), phiEtSum(0), etSum(0); + + // Iterate through the TTs in the jet map + for (L1CaloTowerRefVector::const_iterator lTT = mConstituents.begin() ; lTT != mConstituents.end(); ++lTT ) { + + // Extract the eta, phi and Et of the TT + ttEta = mTowerGeo.eta( (**lTT).iEta() ); + ttPhi = mTowerGeo.phi( (**lTT).iPhi() ); + ttEt = 0.5*((**lTT).E() + (**lTT).H()); + + + // Correct for phi wrap around, if jet map exceeds phi calorimeter range + if ( (mIphi + (mJetSize - 1) ) > 72 ){ + + // Current tower has wrapped around + if ( (**lTT).iPhi() < mIphi ){ + ttPhi += 2*PI; + } + + } + + // Calculate the weighted eta, weighted phi and Et sums + etaEtSum += ttEta*ttEt; + phiEtSum += ttPhi*ttEt; + etSum += ttEt; + + } + + // Calculate the weighted eta and phi + + double lWeightedEta = etaEtSum/etSum; + double lWeightedPhi = phiEtSum/etSum; + + // Restrict phi to [-pi,pi] range + if(lWeightedPhi > PI){ + lWeightedPhi -= 2*PI; + } + + // Store the weighted eta and phi + mP4.SetEta(lWeightedEta); + mP4.SetPhi(lWeightedPhi); + + + } + + + + + + + // Calculate the energy weighted eta and phi center of the jet. + // Defined: Sum ( TT_Eta * TT_Et ) / Sum ( TT_Et ), etc + void L1TowerJet::calculateCentrality() + { + + + + // ******************************************************************** + // * Calculate the centrality parameter * + // ******************************************************************** + // + // Measure of the deltaR between the jet window centre and the centre of energy + // of the constituent energy deposits. + // + // Definition: + // ~~~~~~~~~~ + // + + // Eta, phi and Et of the TT and delta eta, phi and R between the jet centre and the constituent energy deposit + double ttEta(0), ttPhi(0), ttEt(0), deltaEta(0), deltaPhi(0), deltaR(0); + // Sums of deltaR*Et and Et + double deltaREtSum(0), etSum(0); + // Jet mask center (eta, phi) + double jetCenterPhi = Phi(); + double jetCenterEta = Eta(); + int jetCenteriPhi = (mIphi + mJetSize/2); + + // Correct for the jet mask center wrap around + if (jetCenteriPhi > 72){ + jetCenterPhi += 2*PI; + } + + + // Iterate through the TTs in the jet map + for (L1CaloTowerRefVector::const_iterator lTT = mConstituents.begin() ; lTT != mConstituents.end(); ++lTT ) { + + // Extract the eta, phi and Et of the TT + ttEta = mTowerGeo.eta( (**lTT).iEta() ); + ttPhi = mTowerGeo.phi( (**lTT).iPhi() ); + ttEt = 0.5*((**lTT).E() + (**lTT).H()); + + // Correct for phi wrap around, if jet map exceeds phi calorimeter range + if ( (mIphi + (mJetSize - 1) ) > 72 ){ + + // Current tower has wrapped around + if ( (**lTT).iPhi() < mIphi ){ + ttPhi += 2*PI; + } + + } + + // Unwrap the [-Pi,Pi] range + if (jetCenterPhi < 0) + jetCenterPhi += 2*PI; + + + // Calculate deltaR between energy deposit and jet centre + deltaEta = jetCenterEta - ttEta; + deltaPhi = jetCenterPhi - ttPhi; + deltaR = sqrt( deltaEta*deltaEta + deltaPhi*deltaPhi ); + + // Calculate the weighted deltaR*Et and Et sums + deltaREtSum += deltaR*ttEt; + etSum += ttEt; + + /* + // DEBUGGING Eta = 0, Phi = 0 + std::cout << "----------------------------------------------------------\n" + << "JET : iEta = " << mIeta + mJetSize/2 << "\tiPhi = " << jetCenteriPhi << "\tEta = " << jetCenterEta << "\tPhi = " << jetCenterPhi << "\n" + << "TT : iEta = " << (**lTT).iEta() << "\tiPhi = " << (**lTT).iPhi()<< "\tEta = " << ttEta << "\tPhi = " << ttPhi << "\tE = " + << ttEt << "\n" + << "DeltaEta = " << deltaEta << "\tDeltaPhi = " << deltaPhi << "\tRi = " << sqrt(deltaEta*deltaEta + deltaPhi*deltaPhi)<< "\n"; + */ + + } + + + + // Calculate the centrality of the jet energy deposits + mCentrality = deltaREtSum/etSum; + // std::cout << "Centrality = " << mCentrality << "\n==========================================================\n\n"; + + } + + + + + // + // Below code is incorrrect. Should keep the calculation in eta and phi space and then transform to + // i-eta and i-phi space to avoid discretisation issues and changing eta widths of TTs. // -------------------------------------------------- // modified version to calculate weighted eta by first converting iEta to eta, than weighting + /* void L1TowerJet::calculateWeightedEta() { @@ -295,6 +661,7 @@ namespace l1slhc for (int i=0; i!=int(abs_eta); ++i) tmpEta += endcapEta[i]; + // ~ Why are we treating these differently??? ~ if (mJetSize % 2 == 0) tmpEta += endcapEta[int(abs_eta)] / 2.; else tmpEta += endcapEta[int(abs_eta)]; } @@ -307,277 +674,236 @@ namespace l1slhc mWeightedEta = etaSumEt/sumEt ; } - + */ + /* + void L1TowerJet::calculateWeightedPhi( ) + { + // double JetSize = double(mJetSize) / 2.0; + double WeightedPhi = ( ( mWeightedIphi-0.5 ) * 0.087 ); + //Need this because 72*0.087 != 2pi: else get uneven phi dist + double pi=(72*0.087)/2; + if(WeightedPhi > pi) WeightedPhi -=2*pi; + mWeightedPhi=WeightedPhi; + // std::cout<<"weighted IPhi: "<=1) WeightedEta = (0.087*abs_eta - 0.0435); - else WeightedEta = 0.0435*abs_eta ; + //with discrete iEta this first option should always be the case + if( abs_eta >=1) WeightedEta = (0.087*abs_eta - 0.0435); + else WeightedEta = 0.0435*abs_eta ; } else { - const double endcapEta[8] = { 0.09, 0.1, 0.113, 0.129, 0.15, 0.178, 0.15, 0.35 }; - abs_eta -= 21; + const double endcapEta[8] = { 0.09, 0.1, 0.113, 0.129, 0.15, 0.178, 0.15, 0.35 }; + abs_eta -= 21; - WeightedEta = 1.74; + WeightedEta = 1.74; - for ( int i = 0; i != int(abs_eta); ++i ) - { - WeightedEta += endcapEta[i]; - } - if( mJetSize % 2 == 0 ){ - WeightedEta += endcapEta[int(abs_eta)] / 2.; - }else{ - WeightedEta += endcapEta[int(abs_eta)]; - } + for ( int i = 0; i != int(abs_eta); ++i ) + { + WeightedEta += endcapEta[i]; + } + if( mJetSize % 2 == 0 ){ + WeightedEta += endcapEta[int(abs_eta)] / 2.; + }else{ + WeightedEta += endcapEta[int(abs_eta)]; } - if(mWeightedIeta<0) WeightedEta=-WeightedEta; + } + if(mWeightedIeta<0) WeightedEta=-WeightedEta; mWeightedEta = WeightedEta; } */ - void L1TowerJet::CalcWeightediPhi() - { - double phiSumEt(0); - double sumEt (0); - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - double tower_iPhi =(**lConstituentIt).iPhi(); - if( iPhi() >= (72-JetSize()) ) { //constituents may go over edge, iPhi>66 for 8x8 jet - if( tower_iPhi < (72 - JetSize()) ){//if constituent tower is over edge, ie. iPhi>1 - tower_iPhi+=72; //iPhi=1 -> iPhi=73 - } - } - //calculate weighted phi using corrected iPhi value - phiSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * (tower_iPhi ); - sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; - } -// std::cout<<"phi sum et: "<72) mWeightedIphi-=72; - - - } - -void L1TowerJet::calculateWeightedPhi( ) -{ -// double JetSize = double(mJetSize) / 2.0; - double WeightedPhi = ( ( mWeightedIphi-0.5 ) * 0.087 ); - //Need this because 72*0.087 != 2pi: else get uneven phi dist - double pi=(72*0.087)/2; - if(WeightedPhi > pi) WeightedPhi -=2*pi; - mWeightedPhi=WeightedPhi; - // std::cout<<"weighted IPhi: "< lEnergy; - for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ - lEnergy.push_back( (**lConstituentIt).E() + (**lConstituentIt).H() ); - } - lEnergy.resize( mJetArea , 0 ); - return MAD( lEnergy ); - } - double L1TowerJet::MAD( std::deque& aDataSet ) const - { - std::sort( aDataSet.begin() , aDataSet.end() ); - - std::size_t lDataSetSize( aDataSet.size() ); - - double lMedian(0); - if( lDataSetSize%2 == 0 ){ - lMedian = double ( aDataSet[ (lDataSetSize/2) - 1 ] + aDataSet[ lDataSetSize/2 ] ) / 2.0 ; - }else{ - lMedian = double( aDataSet[ (lDataSetSize-1)/2 ] ); - } - - - std::deque< double > lMedianSubtractedDataSet; - for ( std::deque< int >::const_iterator lIt = aDataSet.begin() ; lIt != aDataSet.end(); ++lIt ){ - lMedianSubtractedDataSet.push_back( fabs( double(*lIt) - lMedian ) ); - } - - std::sort( lMedianSubtractedDataSet.begin() , lMedianSubtractedDataSet.end() ); - - if( lDataSetSize%2 == 0 ){ - return double ( lMedianSubtractedDataSet[ (lDataSetSize/2) - 1 ] + lMedianSubtractedDataSet[ lDataSetSize/2 ] ) / 2.0 ; - }else{ - return double( lMedianSubtractedDataSet[ (lDataSetSize-1)/2 ] ); - } - - } - - void L1TowerJet::addConstituent( const L1CaloTowerRef & Tower ) { int lHalfJetSizeEta( mJetSize >> 1 ); int lHalfJetSizePhi( mJetSize >> 1 ); - + // Tower energy in 2 GeV units -> 1 unit = 2 GeV int lTowerEnergy( Tower->E( ) + Tower->H( ) ); //slightly different sizes for HF jets if( abs( iEta() ) > 28 ){ - lHalfJetSizeEta =1; //ie mJetSize/4 as in HF jets 2 in eta + //???? Not sure what this is doing ???? + lHalfJetSizeEta = 1; //ie mJetSize/4 as in HF jets 2 in eta } - //if iPhi at the edge of the calo wrap round in phi - int ToweriPhi = Tower->iPhi( ); - if(iPhi() > (72 - mJetSize)) { - if(ToweriPhi>=1 && ToweriPhiiEta() << "\t" << Tower->iPhi() << "\t" +// << Tower->E() << "\t" << Tower->H() << "\t" << "\n"; + + + // ******************************************************************** + // * Calculate the asymmetry parameters * + // ******************************************************************** + // + // Currently the choice of definition of these parameters may not be optimal, as the parameters + // favour symmetric jets rather than jets with central energy deposits. There are also problems + // with degeneracy in the sorting stage, making the algorithm dependent on the sorting algorithm. + // + // Definition: + // ~~~~~~~~~~ + // Positive asymmetry = For TT energy deposits 'above' jet center + // Negative asymmetry = For TT energy deposits 'below' jet center + + // TT iPhi without calorimeter wrapping i.e. iPhi can exceed 71 + int ToweriPhi = Tower->iPhi(); + + // Check whether the edge of the jet mask wraps around the calorimeter + if ( iPhi() > (72 - mJetSize) ){ + if ( ToweriPhi < mJetSize ){ + // Undo the wrapping of the calorimeter + ToweriPhi += 72; + } } - mE += lTowerEnergy; - mConstituents.push_back( Tower ); - /* if( (Tower->iPhi())<4){ - std::cout<<"JET: ("<iEta()<< " , " <iPhi()<<" ), energy = " <E()+Tower->H()<iEta( ) == iEta() ) mAsymEta += 0; //do nothing - if( Tower->iEta( ) >= (iEta() + lHalfJetSizeEta) ) { - mAsymEta += lTowerEnergy; + // Eta asymmetry + if( Tower->iEta() >= (iEta() + lHalfJetSizeEta) ) { + mAsymEta += lTowerEnergy; } - else{ /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ + else{ mAsymEta -= lTowerEnergy; - } - //if( Tower->iPhi( ) == iPhi() ) mAsymEta += 0; //do nothing - + // Phi asymmetry if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ){ mAsymPhi += lTowerEnergy; - } - else{ /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ + else{ mAsymPhi -= lTowerEnergy; - - } - }else{ //odd jet size: miss out central towers + } + + // ******************************************************************** + // * Odd jet size * + // ******************************************************************** + + else{ //odd jet size: miss out central towers - if( Tower->iEta( ) == (lHalfJetSizeEta + iEta()) ) { - mAsymEta += 0; //do nothing + if( Tower->iEta() == (iEta() + lHalfJetSizeEta) ) { + mAsymEta += 0; // It is in the middle so does not contribute to the asymmetry } - else if( Tower->iEta( ) > (iEta() + lHalfJetSizeEta) ) { + else if( Tower->iEta() > (iEta() + lHalfJetSizeEta) ) { mAsymEta += lTowerEnergy; - - }else /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ { + } + else{ mAsymEta -= lTowerEnergy; - } - // else it is in the middle so does not contribute to the asymmetry - - if( ToweriPhi == (lHalfJetSizePhi + iPhi()) ) { - mAsymPhi += 0; //do nothing + + if( ToweriPhi == (iPhi() + lHalfJetSizePhi) ) { + mAsymPhi += 0; // It is in the middle so does not contribute to the asymmetry } else if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ) { mAsymPhi += lTowerEnergy; - - }else /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ { + } + else{ mAsymPhi -= lTowerEnergy; - } - // else it is in the middle so does not contribute to the asymmetry - } + } void L1TowerJet::removeConstituent( const int &eta, const int &phi ) { L1CaloTowerRefVector::iterator lConstituent = getConstituent( eta, phi ); - if ( lConstituent != mConstituents.end() ) - { - int lHalfJetSizeEta( mJetSize >> 1 ); - int lHalfJetSizePhi( mJetSize >> 1 ); - int lTowerEnergy( (**lConstituent).E( ) + (**lConstituent).H( ) ); - - mE -= lTowerEnergy; - mConstituents.erase( lConstituent ); + if ( lConstituent != mConstituents.end() ){ + + int lHalfJetSizeEta( mJetSize >> 1 ); + int lHalfJetSizePhi( mJetSize >> 1 ); + int lTowerEnergy( (**lConstituent).E( ) + (**lConstituent).H( ) ); + + mE2GeV -= lTowerEnergy; + mE -= 0.5*lTowerEnergy; + mConstituents.erase( lConstituent ); - if( abs( iEta() ) > 28 ){ - lHalfJetSizeEta =1; //ie mJetSize/4 as in HF jets 2 in eta - } - int ToweriPhi = phi; - //if iPhi at the edge of the calo wrap round in phi - if(iPhi() > (72 - mJetSize)) { - if(ToweriPhi>=1 && ToweriPhi < mJetSize) ToweriPhi+=72; - } + if( abs( iEta() ) > 28 ){ + lHalfJetSizeEta = 1; //ie mJetSize/4 as in HF jets 2 in eta + } + + int ToweriPhi = phi; + //if iPhi at the edge of the calo wrap round in phi + if( iPhi() > (72 - mJetSize) ) { + if (ToweriPhi < mJetSize){ + ToweriPhi += 72; + } + } - if( mJetSize % 2 == 0 ){ //even jet size + if( mJetSize % 2 == 0 ){ //even jet size - if( eta >= (iEta() + lHalfJetSizeEta) ) { - mAsymEta -= lTowerEnergy; - } - else{ /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ - mAsymEta += lTowerEnergy; - } + if( eta >= (iEta() + lHalfJetSizeEta) ) { + mAsymEta -= lTowerEnergy; + } + else{ /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ + mAsymEta += lTowerEnergy; + } - if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ){ - mAsymPhi -= lTowerEnergy; + if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ){ + mAsymPhi -= lTowerEnergy; - }else{ /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ - mAsymPhi += lTowerEnergy; - } + }else{ /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ + mAsymPhi += lTowerEnergy; + } - }else{ //odd jet size: miss out central towers + }else{ //odd jet size: miss out central towers - if( eta == (lHalfJetSizeEta + iEta()) ) { - mAsymEta += 0; //do nothing - } - else if( eta > (iEta() + lHalfJetSizeEta) ) { - mAsymEta -= lTowerEnergy; + if( eta == (lHalfJetSizeEta + iEta()) ) { + mAsymEta += 0; //do nothing + } + else if( eta > (iEta() + lHalfJetSizeEta) ) { + mAsymEta -= lTowerEnergy; - }else /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ { - mAsymEta += lTowerEnergy; + }else /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ { + mAsymEta += lTowerEnergy; - } + } - if( ToweriPhi == (lHalfJetSizePhi + iPhi()) ) { - mAsymEta -= 0; //do nothing + if( ToweriPhi == (lHalfJetSizePhi + iPhi()) ) { + mAsymEta -= 0; //do nothing - } - else if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ) { - mAsymPhi -= lTowerEnergy; + } + else if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ) { + mAsymPhi -= lTowerEnergy; - }else /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ { - mAsymPhi += lTowerEnergy; + }else /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ { + mAsymPhi += lTowerEnergy; - } + } + } } - } } @@ -600,35 +926,89 @@ void L1TowerJet::calculateWeightedPhi( ) +namespace std{ -namespace std -{ - bool operator<( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ) - { - if ( aLeft.E( ) == aRight.E( ) ) - { - // for two objects with equal energy, favour the more central one - return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); - } - else - { - return ( aLeft.E( ) < aRight.E( ) ); - } - } + // Overloaded jet rank comparison operator: First order by Et and, in the case of degenerate energy, rank by centrality + bool operator<( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ){ + +// std::cout << "Pt1 = " << aLeft.Pt() << "\tPt2 = " << aRight.Pt() +// << "Cent1 = " << aLeft.Centrality() << "\tCent2 = " << aRight.Centrality(); + + // Degenerate energies + if ( aLeft.E() == aRight.E() ){ + if ( aLeft.Centrality() == aRight.Centrality() ){ + // std::cout << "ERROR: Degeneracy in the secondary sort parameter.\n\nOffending jets:\n"; + // << aLeft << "\n" << aRight << "\n\n"; + std::cout << "\t1<2 = " << false << "\n"; + return false; // Current solution, pick the jet in the list that is left most. i.e. lowest iEta, iPhi + // throw cms::Exception("Sort degeneracy") + // << "Please debug me! :(\n"; + } + else{ + // Order by the lowest centrality + std::cout << "\t1<2 = " << ( aLeft.Centrality() > aRight.Centrality() ) << "\n"; + return ( aLeft.Centrality() > aRight.Centrality() ); + } + } + else{ + std::cout << "\t1<2 = " << ( aLeft.E() < aRight.E() ) << "\n"; + return ( aLeft.E() < aRight.E() ); + } + } + + + // NOTE: Added to be compatible with the bitonic sort routine which is currently also utilised in Asymmetry filtering + // Overloaded jet rank comparison operator: First order by Et and, in the case of degenerate energy, rank by centrality + bool operator>( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ){ + + // THIS DOESN'T WORK FOR SOME REASON.... + // return ( !(aLeft < aRight) ); + + + // + +// std::cout << "Pt1 = " << aLeft.Pt() << "\tPt2 = " << aRight.Pt() +// << "Cent1 = " << aLeft.Centrality() << "\tCent2 = " << aRight.Centrality(); + + // Degenerate energies + if ( aLeft.E() == aRight.E() ){ + if ( aLeft.Centrality() == aRight.Centrality() ){ + // std::cout << "ERROR: Degeneracy in the secondary sort parameter.\n\nOffending jets:\n"; + // << aLeft << "\n" << aRight << "\n\n"; + std::cout << "\t1>2 = " << true << "\n"; + return true; // Current solution, pick the jet in the list that is left most. i.e. lowest iEta, iPhi + // throw cms::Exception("Sort degeneracy") + // << "Please debug me! :(\n"; + } + else{ + // Order by the lowest centrality + std::cout << "\t1>2 = " << ( aLeft.Centrality() < aRight.Centrality() ) << "\n"; + return ( aLeft.Centrality() < aRight.Centrality() ); + } + } + else{ + std::cout << "\t1>2 = " << ( aLeft.E() > aRight.E() ) << "\n"; + return ( aLeft.E() > aRight.E() ); + } + // + + } + } // pretty print std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1TowerJet & aL1TowerJet ) { - aStream << "L1TowerJet" - << " iEta=" << aL1TowerJet.iEta( ) - << " iPhi=" << aL1TowerJet.iPhi( ) - << "\n with constituents:\n"; - for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1TowerJet.getConstituents( ).begin( ); i < aL1TowerJet.getConstituents( ).end( ); ++i ) - aStream << " iEta=" << ( **i ).iEta( ) - << " iPhi=" << ( **i ).iPhi( ) - << " ET=" << ( **i ).E( ) - << "\n"; - return aStream; + aStream << "L1TowerJet" + << " iEta=" << aL1TowerJet.iEta( ) + << " \tiPhi=" << aL1TowerJet.iPhi( ) + << "\n with constituents:\n"; + for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1TowerJet.getConstituents( ).begin( ); i < aL1TowerJet.getConstituents( ).end( ); ++i ){ + aStream << " \tiEta = " << ( **i ).iEta( ) + << " \tiPhi = " << ( **i ).iPhi( ) + << " \tET = " << ( **i ).E( ) + << "\n"; + } + return aStream; } From 398c9eee1861b94a33eaa6f144dc7c5d97ed93c1 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sat, 24 May 2014 15:17:08 +0200 Subject: [PATCH 006/252] add L1EGammaCrystalsProducer.cc and L1ExtraCrystalPosition.cc - but needs to update L1EGCrystalCluster.h --- .../plugins/L1EGammaCrystalsProducer.cc | 334 ++++++++++++++++++ .../plugins/L1ExtraCrystalPosition.cc | 149 ++++++++ .../SLHC/interface/L1EGCrystalCluster.h | 30 ++ SimDataFormats/SLHC/src/classes.h | 9 + SimDataFormats/SLHC/src/classes_def.xml | 6 + 5 files changed, 528 insertions(+) create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc create mode 100644 SimDataFormats/SLHC/interface/L1EGCrystalCluster.h diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc new file mode 100644 index 0000000000000..32f3b3050e318 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -0,0 +1,334 @@ +// -*- C++ -*- +// +// Package: L1CaloTrigger +// Class: L1EGammaCrystalsProducer +// +/**\class L1EGammaCrystalsProducer L1EGammaCrystalsProducer.cc SLHCUpgradeSimulations/L1CaloTrigger/plugin/L1EGammaCrystalsProducer.cc + +Description: Produces crystal clusters using crystal-level information + +Implementation: +[Notes on implementation] +*/ +// +// Original Author: Nick Smith, Alexander Savin +// Created: Tue Apr 22 2014 +// $Id$ +// +// + + +#include "SimDataFormats/Track/interface/SimTrackContainer.h" +#include "DataFormats/L1Trigger/interface/L1EmParticle.h" +#include "DataFormats/L1Trigger/interface/L1EmParticleFwd.h" +#include "DataFormats/Math/interface/deltaR.h" +#include "DataFormats/Math/interface/deltaPhi.h" + +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "SimDataFormats/CaloHit/interface/PCaloHitContainer.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "Geometry/CaloEventSetup/interface/CaloTopologyRecord.h" +#include "Geometry/Records/interface/CaloGeometryRecord.h" +#include "Geometry/CaloGeometry/interface/CaloSubdetectorGeometry.h" + +#include "Geometry/CaloGeometry/interface/CaloGeometry.h" +#include "Geometry/EcalAlgo/interface/EcalBarrelGeometry.h" +#include "Geometry/EcalAlgo/interface/EcalEndcapGeometry.h" +#include "Geometry/CaloGeometry/interface/CaloCellGeometry.h" +#include + +#include "DataFormats/EcalRecHit/interface/EcalRecHit.h" +#include "DataFormats/EcalRecHit/interface/EcalRecHitCollections.h" +#include "FastSimulation/CaloGeometryTools/interface/CaloGeometryHelper.h" +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" +#include "Geometry/CaloTopology/interface/CaloTopology.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "Geometry/CommonDetUnit/interface/GeomDet.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "SimDataFormats/CaloTest/interface/HcalTestNumbering.h" +#include "DataFormats/HcalDetId/interface/HcalSubdetector.h" +#include "DataFormats/HcalDetId/interface/HcalDetId.h" + +#include "DataFormats/HcalRecHit/interface/HcalRecHitCollections.h" +#include "DataFormats/HcalRecHit/interface/HcalSourcePositionData.h" + +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +class L1EGCrystalClusterProducer : public edm::EDProducer { + public: + explicit L1EGCrystalClusterProducer(const edm::ParameterSet&); + + private: + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void beginRun(edm::Run const&, edm::EventSetup const&); + + CaloGeometryHelper geometryHelper; + bool debug; + bool useECalEndcap; + class SimpleCaloHit + { + public: + EBDetId id; + GlobalVector position; // As opposed to GlobalPoint, so we can add them (for weighted average) + float energy=0.; + bool stale=false; // Hits become stale once used in clustering algorithm to prevent overlap in clusters + bool isEndcapHit=false; // If using endcap, we won't be using integer crystal indices + + // tool functions + inline float pt() const{return (position.mag2()>0) ? energy*sin(position.theta()) : 0.;}; + inline float deta(SimpleCaloHit& other) const{return position.eta() - other.position.eta();}; + int dieta(SimpleCaloHit& other) const + { + if ( isEndcapHit || other.isEndcapHit ) return 9999; // We shouldn't compare integer indices in endcap, the map is not linear + // int indices do not contain zero + // Logic from EBDetId::distanceEta() without the abs() + if (id.ieta() * other.id.ieta() > 0) + return id.ieta()-other.id.ieta(); + return id.ieta()-other.id.ieta()-1; + }; + inline float dphi(SimpleCaloHit& other) const{return reco::deltaPhi(position.phi(), other.position.phi());}; + int diphi(SimpleCaloHit& other) const + { + if ( isEndcapHit || other.isEndcapHit ) return 9999; // We shouldn't compare integer indices in endcap, the map is not linear + // Logic from EBDetId::distancePhi() without the abs() + int PI = 180; + int result = id.iphi() - other.id.iphi(); + while (result > PI) result -= 2*PI; + while (result <= -PI) result += 2*PI; + return result; + }; + float distanceTo(SimpleCaloHit& other) const + { + // Treat position as a point, measure 3D distance + // This is used for endcap hits, where we don't have a rectangular mapping + return (position-other.position).mag(); + }; + bool operator==(SimpleCaloHit& other) const + { + if ( id == other.id && + position == other.position && + energy == other.energy && + isEndcapHit == other.isEndcapHit + ) return true; + + return false; + }; + }; +}; + +L1EGCrystalClusterProducer::L1EGCrystalClusterProducer(const edm::ParameterSet& iConfig) : + debug(iConfig.getUntrackedParameter("debug", false)), + useECalEndcap(iConfig.getUntrackedParameter("useECalEndcap", false)) +{ + produces("EGCrystalCluster"); + produces("EGammaCrystal"); +} + +void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + if ( geometryHelper.getEcalBarrelGeometry() == nullptr ) + { + edm::ESHandle theCaloTopology; + iSetup.get().get(theCaloTopology); + edm::ESHandle pG; + iSetup.get().get(pG); + double bField000 = 4.; + geometryHelper.setupGeometry(*pG); + geometryHelper.setupTopology(*theCaloTopology); + geometryHelper.initialize(bField000); + } + + std::vector ecalhits; + std::vector hcalhits; + + // Retrieve the ecal barrel hits + // using RecHits (https://cmssdt.cern.ch/SDT/doxygen/CMSSW_6_1_2_SLHC6/doc/html/d8/dc9/classEcalRecHit.html) + edm::Handle pcalohits; + iEvent.getByLabel("ecalRecHit","EcalRecHitsEB",pcalohits); + for(auto hit : *pcalohits.product()) + { + if(hit.energy() > 0.2) + { + auto cell = geometryHelper.getEcalBarrelGeometry()->getGeometry(hit.id()); + SimpleCaloHit ehit; + ehit.id = hit.id(); + // So, apparently there are (at least) two competing basic vector classes being tossed around in + // cmssw, the calorimeter geometry package likes to use "DataFormats/GeometryVector/interface/GlobalPoint.h" + // while "DataFormats/Math/interface/Point3D.h" also contains a competing definition of GlobalPoint. Oh well... + ehit.position = GlobalVector(cell->getPosition().x(), cell->getPosition().y(), cell->getPosition().z()); + ehit.energy = hit.energy(); + ecalhits.push_back(ehit); + } + } + + if ( useECalEndcap ) + { + // Retrieve the ecal endcap hits + // using RecHits (https://cmssdt.cern.ch/SDT/doxygen/CMSSW_6_1_2_SLHC6/doc/html/d8/dc9/classEcalRecHit.html) + edm::Handle pcalohitsEndcap; + iEvent.getByLabel("ecalRecHit","EcalRecHitsEE",pcalohitsEndcap); + for(auto hit : *pcalohitsEndcap.product()) + { + if(hit.energy() > 0.2) + { + auto cell = geometryHelper.getEcalEndcapGeometry()->getGeometry(hit.id()); + SimpleCaloHit ehit; + // endcap cell ids won't have any relation to barrel hits + ehit.id = hit.id(); + ehit.position = GlobalVector(cell->getPosition().x(), cell->getPosition().y(), cell->getPosition().z()); + ehit.energy = hit.energy(); + ehit.isEndcapHit = true; + ecalhits.push_back(ehit); + } + } + } + + // Retrive hcal hits + edm::Handle hbhecoll; + iEvent.getByLabel("hbheprereco", hbhecoll); + for (auto hit : *hbhecoll.product()) + { + if ( hit.energy() > 0.1 ) + { + auto cell = geometryHelper.getHcalGeometry()->getGeometry(hit.id()); + SimpleCaloHit hhit; + hhit.id = hit.id(); + hhit.position = GlobalVector(cell->getPosition().x(), cell->getPosition().y(), cell->getPosition().z()); + hhit.energy = hit.energy(); + hcalhits.push_back(hhit); + } + } + + // Cluster containters + std::auto_ptr trigCrystalClusters (new l1slhc::L1EGCrystalClusterCollection ); + std::auto_ptr l1EGammaCrystal( new l1extra::L1EmParticleCollection ); + + // Clustering algorithm + while(true) + { + // Find highest pt hit (that's not already used) + SimpleCaloHit centerhit; + for(const auto& hit : ecalhits) + { + if ( !hit.stale && hit.pt() > centerhit.pt() ) + { + centerhit = hit; + } + } + // If we are less than 1GeV or out of hits (i.e. when centerhit is default constructed) we stop + if ( centerhit.pt() <= 1. ) break; + if ( debug ) std::cout << "-------------------------------------" << std::endl; + if ( debug ) std::cout << "New cluster: center crystal pt = " << centerhit.pt() << std::endl; + + // Find the energy-weighted average position, + // calculate isolation parameter, + // and calculate pileup-corrected pt + GlobalVector weightedPosition; + GlobalVector ECalPileUpVector; + float totalEnergy = 0.; + float ECalIsolation = 0.; + float ECalPileUpEnergy = 0.; + for(auto& hit : ecalhits) + { + if ( !hit.stale && + ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && abs(hit.diphi(centerhit)) < 3) + || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 3.5*1.41 ) )) // endcap crystals are 30mm on a side, 3.5*sqrt(2) cm radius should enclose 3x3 + { + weightedPosition += hit.position*hit.energy; + totalEnergy += hit.energy; + hit.stale = true; + if ( debug && hit == centerhit ) + std::cout << "\x1B[32m"; // green hilight + if ( debug && hit.isEndcapHit ) std::cout << + "\tCrystal pt=" << hit.pt() << + ", eta=" << hit.position.eta() << + ", phi=" << hit.position.phi() << "\x1B[0m" << std::endl; + else if ( debug ) std::cout << + "\tCrystal (" << hit.dieta(centerhit) << "," << hit.diphi(centerhit) << + ") pt=" << hit.pt() << + ", eta=" << hit.position.eta() << + ", phi=" << hit.position.phi() << "\x1B[0m" << std::endl; + } + // Isolation and pileup must not use hits used in a cluster + // We also cut out low pt noise + // As for the endcap hits, well, as far as this algorithm is concerned, caveat emptor... + if ( !hit.stale && hit.pt() > 0.05 ) + { + if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 14 && abs(hit.diphi(centerhit)) < 14) + || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 42. )) + { + ECalIsolation += hit.pt(); + } + if ( hit.pt() < 5. && + ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 7 && abs(hit.diphi(centerhit)) < 57 ) + || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 50.) )) + { + ECalPileUpEnergy += hit.energy; + ECalPileUpVector += hit.position; + } + } + } + weightedPosition /= totalEnergy; + float totalPt = totalEnergy*sin(weightedPosition.theta()); + ECalIsolation /= totalPt; + float totalPtPUcorr = totalPt - ECalPileUpEnergy*sin(ECalPileUpVector.theta())/19.; + + if ( debug ) std::cout << "Weighted position eta = " << weightedPosition.eta() << ", phi = " << weightedPosition.phi() << std::endl; + if ( debug ) std::cout << "Total energy = " << totalEnergy << ", total pt = " << totalPt << std::endl; + if ( debug ) std::cout << "Isolation: " << ECalIsolation << std::endl; + + // Calculate H/E + float hcalEnergy = 0.; + for(const auto& hit : hcalhits) + { + if ( fabs(hit.deta(centerhit)) < 0.15 && fabs(hit.dphi(centerhit)) < 0.15 ) + { + hcalEnergy += hit.energy; + } + } + float hovere = hcalEnergy/totalEnergy; + + if ( debug ) std::cout << "H/E: " << hovere << std::endl; + + // Form a l1slhc::L1EGCrystalCluster + l1slhc::L1EGCrystalCluster cluster; + cluster.et = totalPt; + cluster.eta = weightedPosition.eta(); + cluster.phi = weightedPosition.phi(); + cluster.ieta = centerhit.id.ieta(); + cluster.iphi = centerhit.id.iphi(); + cluster.e = totalEnergy; + cluster.x = weightedPosition.x(); + cluster.y = weightedPosition.y(); + cluster.z = weightedPosition.z(); + cluster.hovere = hovere; + cluster.ECALiso = ECalIsolation; + cluster.ECALetPUcorr = totalPtPUcorr; + + trigCrystalClusters->push_back(cluster); + + // Save clusters with some cuts + if ( cluster.hovere < 2. && cluster.ECALiso < 3. ) + { + reco::Candidate::PolarLorentzVector p4(cluster.et, cluster.eta, cluster.phi, 0.); + l1EGammaCrystal->push_back(l1extra::L1EmParticle(p4, edm::Ref(), 0)); + } + } + + iEvent.put(trigCrystalClusters,"EGCrystalCluster"); + iEvent.put(l1EGammaCrystal, "EGammaCrystal" ); +} + +// ------------ method called when starting to processes a run ------------ +void +L1EGCrystalClusterProducer::beginRun(edm::Run const& iRun, edm::EventSetup const& iSetup) +{ + std::cout << "Apparently beginRun() never gets called?!?!?!" << std::endl; +} + +DEFINE_FWK_MODULE(L1EGCrystalClusterProducer); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc new file mode 100644 index 0000000000000..41ef2d8749f79 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc @@ -0,0 +1,149 @@ +/* L1ExtraMaker Creates L1 Extra Objects from Clusters and jets + + S. Dutta SINP-India*/ + + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "SimDataFormats/SLHC/interface/L1CaloCluster.h" +#include "SimDataFormats/SLHC/interface/L1CaloClusterFwd.h" + +#include "SimDataFormats/SLHC/interface/L1CaloJet.h" +#include "SimDataFormats/SLHC/interface/L1CaloJetFwd.h" +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" + +#include "DataFormats/L1Trigger/interface/L1EmParticle.h" +#include "DataFormats/L1Trigger/interface/L1EmParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1JetParticle.h" +#include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" +#include "DataFormats/Math/interface/deltaR.h" + +#include "DataFormats/Candidate/interface/LeafCandidate.h" + + +class L1CaloGeometry; + +namespace l1extra { + class EtComparator { + public: + bool operator()(const l1extra::L1EmParticle a, const l1extra::L1EmParticle b) const { + double et_a = 0.0; + double et_b = 0.0; + if (cosh(a.eta()) > 0.0) et_a = a.energy()/cosh(a.eta()); + if (cosh(b.eta()) > 0.0) et_b = b.energy()/cosh(b.eta()); + + return et_a > et_b; + } + }; + class ClusterETComparator { + public: + bool operator()(const l1slhc::L1EGCrystalCluster a, const l1slhc::L1EGCrystalCluster b) const { + return a.et > b.et; + } + }; +} +class L1ExtraCrystalPosition:public edm::EDProducer { + +public: + explicit L1ExtraCrystalPosition( const edm::ParameterSet & ); + ~L1ExtraCrystalPosition( ); + +private: + + virtual void produce( edm::Event &, const edm::EventSetup & ); + virtual void endJob( ); + unsigned int getMatchedClusterIndex(l1slhc::L1EGCrystalClusterCollection& egxtals, float& eta, float& phi, float& dr_min); + edm::InputTag mEgamma; + edm::InputTag mEgCluster; +}; + +L1ExtraCrystalPosition::L1ExtraCrystalPosition( const edm::ParameterSet & iConfig ): + mEgamma( iConfig.getParameter < edm::InputTag > ( "eGammaSrc" ) ), + mEgCluster( iConfig.getParameter < edm::InputTag > ( "eClusterSrc" ) ) + +{ + // Register Product + produces < l1extra::L1EmParticleCollection > ( "EGammaCrystal" ); +} + + +L1ExtraCrystalPosition::~L1ExtraCrystalPosition( ) +{ +} + + +void L1ExtraCrystalPosition::produce( edm::Event & iEvent, const edm::EventSetup & iSetup ) { + edm::Handle egCrystalClusters; + iEvent.getByLabel(mEgCluster,egCrystalClusters); + l1slhc::L1EGCrystalClusterCollection clusColl = (*egCrystalClusters.product()); + std::sort(clusColl.begin(), clusColl.end(), l1extra::ClusterETComparator()); + + edm::Handle < l1extra::L1EmParticleCollection > eg; + std::auto_ptr < l1extra::L1EmParticleCollection > l1EGammaCrystal( new l1extra::L1EmParticleCollection ); + + if ( iEvent.getByLabel( mEgamma, eg ) ) { + l1extra::L1EmParticleCollection egColl = (*eg.product()); + std::sort(egColl.begin(), egColl.end(), l1extra::EtComparator()); + std::vector matched_indices; + for ( l1extra::L1EmParticleCollection::const_iterator lIt =egColl.begin(); lIt != egColl.end(); ++lIt ) { + l1extra::L1EmParticle em( *lIt ); + float eta = em.eta(); + float phi = em.phi(); + // float et = 0; + // if (cosh(eta) > 0.0) et = em.energy()/cosh(eta); + // std::cout << " Et, Energy, Eta, Phi (before correction) " << et << " " << em.energy() << " " << eta << " " << phi << std::endl; + float deltaR; + unsigned int indx = getMatchedClusterIndex(clusColl, eta, phi, deltaR); + if (indx != 9999 && deltaR < 0.3) { + l1extra::L1EmParticle* em_new = em.clone(); + float eta_new = clusColl[indx].eta; + float phi_new = clusColl[indx].phi; + // float pt_new = em.pt(); + // if (cosh(eta_new) > 0.0) pt_new = em.p()/cosh(eta_new); + // reco::Candidate::PolarLorentzVector lv_em_corr(pt_new, eta_new, phi_new, em.mass()); + // em_new->setP4(lv_em_corr); + // reco::Candidate::PolarLorentzVector & p4 = const_cast (em_new->polarP4()); + // p4.SetPhi(phi_new); + // p4.SetEta(eta_new); + + reco::Candidate::PolarLorentzVector p4(em.pt(), eta_new, phi_new, em.mass()); + em_new->setP4(p4); + l1EGammaCrystal->push_back( *em_new ); + // float et_new = 0; + // if (cosh(em_new->eta()) > 0.0) et_new = em_new->energy()/cosh(em_new->eta()); + // std::cout << " Et, Energy, Eta, Phi (after correction) " << et_new << " " << em_new->energy() << " " << em_new->eta() << " " << em_new->phi() << " deltaR " << deltaR << std::endl; + // std::cout << " px, py, pz " << em_new->px() << " " << em_new->py() << " " << em_new->pz() << std::endl; + // std::cout << " x, y, z " << clusColl[indx].x << " " << clusColl[indx].y << " " << clusColl[indx].z << std::endl; + } + } + iEvent.put(l1EGammaCrystal, "EGammaCrystal" ); + } +} + +// ------------ method called once each job just after ending the event loop ------------ +void L1ExtraCrystalPosition::endJob( ) +{ +} +unsigned int L1ExtraCrystalPosition::getMatchedClusterIndex(l1slhc::L1EGCrystalClusterCollection& egxtals, float& eta, float& phi, float& dr_min) { + dr_min = 999.9; + size_t index_min = 9999; + for (size_t i = 0; i < egxtals.size(); i++) { + float dr = deltaR(egxtals[i].eta, egxtals[i].phi, eta, phi); + if (dr < dr_min) { + index_min = i; + dr_min = dr; + } + } + return index_min; +} + +DEFINE_FWK_MODULE(L1ExtraCrystalPosition); diff --git a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h new file mode 100644 index 0000000000000..e87a75e8daf01 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h @@ -0,0 +1,30 @@ +#ifndef L1EGammaCrystalsCluster_h +#define L1EGammaCrystalsCluster_h + +#include + +namespace l1slhc +{ + + class L1EGCrystalCluster { + public: + float et ; + float eta ; + float phi ; + float e ; + float x ; + float y ; + float z ; + float hovere ; + + float ECALiso ; + float ECALetPUcorr; + + }; + + + // Concrete collection of output objects (with extra tuning information) + typedef std::vector L1EGCrystalClusterCollection; +} +#endif + diff --git a/SimDataFormats/SLHC/src/classes.h b/SimDataFormats/SLHC/src/classes.h index d5e06b38d93dc..75ae25f283e4d 100644 --- a/SimDataFormats/SLHC/src/classes.h +++ b/SimDataFormats/SLHC/src/classes.h @@ -181,6 +181,9 @@ namespace { #include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" + + namespace { namespace { @@ -222,6 +225,12 @@ namespace { l1slhc::L1TowerJetCollection l1towerjetcoll; edm::Wrapper< l1slhc::L1TowerJetCollection > wl1towerjetcol; + + l1slhc::L1EGCrystalCluster egcrystalcluster; + std::vector l1egcrystalclustervec; + l1slhc::L1EGCrystalClusterCollection l1egcrystalclustercoll; + edm::Wrapper wl1egcrystalclustercoll; + } } diff --git a/SimDataFormats/SLHC/src/classes_def.xml b/SimDataFormats/SLHC/src/classes_def.xml index ed0999845325b..444d7c09cfd1d 100644 --- a/SimDataFormats/SLHC/src/classes_def.xml +++ b/SimDataFormats/SLHC/src/classes_def.xml @@ -202,5 +202,11 @@ + + + + + + From a6709be91b66d390530dd6f09d07345593b1bade Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Mon, 26 May 2014 09:25:33 +0200 Subject: [PATCH 007/252] added minBiasFiles_px_cfi.py for the test rate sample at CERN --- .../python/minBiasFiles_p1_cfi.py | 256 ++++++++++++++++++ .../python/minBiasFiles_p2_cfi.py | 256 ++++++++++++++++++ .../test/test_L1TkEGamma_cfg.py | 17 +- 3 files changed, 521 insertions(+), 8 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py new file mode 100644 index 0000000000000..ae279c2487820 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py @@ -0,0 +1,256 @@ +import FWCore.ParameterSet.Config as cms + +# Test rate sample at CERN, part 1 +# The files in minBiasFiles_p1 correspond to about 20k events + +minBiasFiles_p1 = cms.untracked.vstring( +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_1.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_10.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_100.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_101.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_102.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_103.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_104.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_105.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_106.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_107.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_108.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_109.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_11.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_110.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_111.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_112.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_113.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_114.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_115.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_116.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_117.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_118.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_119.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_12.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_120.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_121.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_122.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_123.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_124.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_125.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_126.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_127.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_128.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_129.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_13.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_130.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_131.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_132.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_133.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_134.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_135.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_136.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_137.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_138.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_139.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_14.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_140.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_141.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_142.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_143.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_144.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_145.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_146.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_147.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_148.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_149.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_15.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_150.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_151.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_152.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_153.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_154.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_155.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_156.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_157.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_158.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_159.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_16.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_160.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_161.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_162.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_163.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_164.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_165.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_166.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_167.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_168.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_169.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_17.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_170.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_171.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_172.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_173.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_174.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_175.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_176.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_177.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_178.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_179.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_18.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_180.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_181.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_182.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_183.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_184.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_185.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_186.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_187.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_188.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_189.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_19.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_190.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_191.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_192.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_193.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_194.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_195.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_196.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_197.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_198.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_199.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_2.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_20.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_200.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_201.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_202.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_203.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_204.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_205.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_206.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_207.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_208.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_209.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_21.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_210.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_211.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_212.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_213.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_214.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_215.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_216.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_217.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_218.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_219.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_22.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_220.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_221.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_222.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_223.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_224.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_225.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_226.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_227.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_228.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_229.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_23.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_230.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_231.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_232.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_233.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_234.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_235.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_236.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_237.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_238.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_239.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_24.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_240.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_241.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_242.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_243.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_244.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_245.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_246.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_247.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_248.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_249.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_25.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_250.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_251.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_252.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_253.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_254.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_255.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_256.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_257.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_258.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_259.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_26.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_260.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_261.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_262.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_263.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_264.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_265.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_266.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_267.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_268.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_269.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_27.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_270.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_271.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_272.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_273.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_274.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_275.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_276.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_277.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_278.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_279.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_28.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_280.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_281.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_282.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_283.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_284.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_285.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_286.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_287.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_288.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_289.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_29.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_290.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_291.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_292.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_293.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_294.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_295.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_296.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_297.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_298.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_299.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_3.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_30.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_300.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_301.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_302.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_303.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_304.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_305.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_306.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_307.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_308.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_309.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_31.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_310.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_311.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_312.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_313.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_314.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_315.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_316.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_317.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_318.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_319.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_32.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_320.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_321.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_322.root" +) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py new file mode 100644 index 0000000000000..477d3efcd79d2 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py @@ -0,0 +1,256 @@ +import FWCore.ParameterSet.Config as cms + +# Test rate sample at CERN, part 2 +# The files in minBiasFiles_p2 correspond to about 20k events + +minBiasFiles_p2 = cms.untracked.vstring( +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_323.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_324.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_325.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_326.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_327.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_328.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_329.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_33.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_330.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_331.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_332.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_333.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_334.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_335.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_336.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_337.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_338.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_339.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_34.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_340.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_341.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_342.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_343.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_344.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_345.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_346.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_347.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_348.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_349.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_35.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_350.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_351.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_352.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_353.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_354.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_355.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_356.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_357.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_358.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_359.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_36.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_360.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_361.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_362.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_363.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_364.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_365.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_366.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_367.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_368.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_369.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_37.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_370.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_371.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_372.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_373.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_374.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_375.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_376.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_377.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_378.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_379.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_38.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_380.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_381.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_382.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_383.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_384.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_385.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_386.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_387.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_388.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_389.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_39.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_390.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_391.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_392.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_393.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_394.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_395.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_396.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_397.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_398.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_399.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_4.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_40.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_400.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_401.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_402.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_403.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_404.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_405.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_406.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_407.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_408.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_409.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_41.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_410.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_411.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_412.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_413.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_414.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_415.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_416.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_417.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_418.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_419.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_42.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_420.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_421.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_422.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_423.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_424.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_425.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_426.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_427.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_428.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_429.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_43.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_430.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_431.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_432.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_433.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_434.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_435.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_436.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_437.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_438.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_439.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_44.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_440.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_441.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_442.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_443.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_444.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_445.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_446.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_447.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_448.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_449.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_45.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_450.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_451.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_452.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_453.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_454.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_455.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_456.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_457.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_458.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_459.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_46.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_460.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_461.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_462.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_463.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_464.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_465.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_466.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_467.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_468.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_469.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_47.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_470.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_471.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_472.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_473.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_474.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_475.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_476.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_477.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_478.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_479.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_48.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_480.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_481.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_482.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_483.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_484.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_485.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_486.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_487.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_488.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_489.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_49.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_490.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_491.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_492.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_493.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_494.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_495.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_496.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_497.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_498.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_499.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_5.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_50.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_51.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_52.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_53.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_54.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_55.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_56.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_57.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_58.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_59.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_6.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_60.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_61.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_62.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_63.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_64.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_65.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_66.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_67.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_68.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_69.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_7.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_70.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_71.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_72.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_73.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_75.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_76.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_77.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_78.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_79.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_8.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_80.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_81.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_82.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_83.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_84.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_85.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_86.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_87.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_88.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_89.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_9.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_90.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_91.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_92.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_93.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_94.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_95.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_96.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_97.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_98.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_99.root" +) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py index 85047ca211c46..7ec5db1121b3f 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py @@ -20,20 +20,21 @@ # that have been created. +# to run over the test rate sample (part 1) : +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * process.source = cms.Source("PoolSource", - fileNames = cms.untracked.vstring( + fileNames = minBiasFiles_p1 +) + +# to run over another sample: +#process.source = cms.Source("PoolSource", # electron file: #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SingleElectron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SinglePositron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SinglePositron_E2023TTI_PU140.root' - # - # rate test sample: - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' - # - ) -) + #) +#) # ---- Global Tag : From d0f7bef50c51b6ebfd1e256d1c95a714da4a04bf Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Mon, 26 May 2014 13:35:01 +0200 Subject: [PATCH 008/252] little fixes to compile the L1EGCrystalCluster code --- .../L1CaloTrigger/plugins/BuildFile.xml | 1 + .../test/test_L1TkEGamma_with_crystal_cfg.py | 260 ++++++++++++++++++ .../SLHC/interface/L1EGCrystalCluster.h | 3 + 3 files changed, 264 insertions(+) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml index 64493e81fc347..b3dd410291b86 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml @@ -14,6 +14,7 @@ + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py new file mode 100644 index 0000000000000..134b9fb89cd8f --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py @@ -0,0 +1,260 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) + +# +# This runs over a file that already contains the L1Tracks. +# +# It produces the following objects : +# - L1EG objects obtained by running the SLHCCaloTrigger sequence +# - this produces both the "old stage-2" and the "new stage-2" objects +# - collection of L1TkEmParticles - produces Trk-based isolated "photons" +# - collection of L1TkElectrons from L1TkElectronTrackProducer +# +# +# It also runs a trivial analyzer than prints the objects +# that have been created. + + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + # electron file: + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SingleElectron_E2023TTI_PU140.root', + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SinglePositron_E2023TTI_PU140.root', + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SinglePositron_E2023TTI_PU140.root' + # + # rate test sample: + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + # + ) +) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + + + +# --------------------------------------------------------------------------- +# +# --- Produces the L1EG objects +# + # To produce L1EG objects corresponding to the "stage-2" algorithms: + # one runs the SLHCCaloTrigger sequence. This produces both the + # "old stage-2" objects (2x2 clustering) and the "new stage-2" + # objects (new clustering from JB Sauvan et al). Note that the + # efficiency of the latter is currently poor at very high PU. + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') + +process.load('Configuration/StandardSequences/L1HwVal_cff') +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +# bug fix for missing HCAL TPs in MC RAW +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + +process.slhccalo = cms.Path( process.RawToDigi + process.valHcalTriggerPrimitiveDigis+process.SLHCCaloTrigger) + + + # To produce L1EG objects corresponding + # to the Run-1 L1EG algorithm, one just needs to run + # L1Reco. The (Run-1) L1EG algorithm has already been + # run in the DIGI step of the production. + +process.load('Configuration.StandardSequences.L1Reco_cff') +process.L1Reco = cms.Path( process.l1extraParticles ) + +# +# --------------------------------------------------------------------------- + + +# -------------------------------------------------------------------------------------------- +# +# ---- Produce the L1EGCrystal clusters (code of Sasha Savin & Nick Smith) + + # first you need the ECAL RecHIts : +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.reconstruction_step = cms.Path( process.calolocalreco ) + +process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", + debug = cms.untracked.bool(False), + useECalEndcap = cms.untracked.bool(True) +) +process.pSasha = cms.Path( process.L1EGammaCrystalsProducer ) + +# -------------------------------------------------------------------------------------------- + +# -------------------------------------------------------------------------------------------- +# +# ---- Match the L1EG stage-2 objects created by the SLHCCaloTrigger sequence above +# with the crystal-level clusters. +# This produces a new collection of L1EG objects, starting from the original +# L1EG collection. The eta and phi of the L1EG objects is corrected using the +# information of the xtal level clusters. + +process.l1ExtraCrystalProducer = cms.EDProducer("L1ExtraCrystalPosition", + eGammaSrc = cms.InputTag("SLHCL1ExtraParticlesNewClustering","EGamma"), + eClusterSrc = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster") +) +process.egcrystal_producer = cms.Path(process.l1ExtraCrystalProducer) + + + + +# --------------------------------------------------------------------------- + +# Now we produce L1TkEmParticles and L1TkElectrons + + +# ---- "photons" isolated w.r.t. L1Tracks : + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmParticleProducer_cfi") +process.pL1TkPhotons = cms.Path( process.L1TkPhotons ) + +# ---- "electrons" from L1Tracks. Inclusive electrons : + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkElectronTrackProducer_cfi") +process.pElectrons = cms.Path( process.L1TkElectrons ) + + # --- collection of L1TkElectrons made from "crystal-level" L1EG objects +process.L1TkElectronsCrystal = process.L1TkElectrons.clone() +process.L1TkElectronsCrystal.L1EGammaInputTag = cms.InputTag("l1ExtraCrystalProducer","EGammaCrystal") + # ... of course, the cuts need to be retuned for the xtal-level granularity +process.pElectronsCrystal = cms.Path( process.L1TkElectronsCrystal ) + + +# ---- L1TkElectrons that are isolated w.r.t. L1Tracks : + +process.L1TkIsoElectrons = process.L1TkElectrons.clone() +process.L1TkIsoElectrons.IsoCut = cms.double(0.1) +process.pElectronsTkIso = cms.Path( process.L1TkIsoElectrons ) + +# ---- "electrons" from L1Tracks, Inclusive electrons : dedicated low PT sequence +process.pElectronsLoose = cms.Path( process.L1TkElectronsLoose) + +# to test with looser cuts : +process.L1TkElectronsLooseV2 = process.L1TkElectronsLoose.clone() +process.L1TkElectronsLooseV2.TrackMinPt = cms.double( 2. ) +process.L1TkElectronsLooseV2.TrackEGammaDeltaPhi = cms.vdouble( 0.2, 0.,0.) +process.L1TkElectronsLooseV2.TrackEGammaDeltaR = cms.vdouble( 0.2, 0.,0.) +process.pElectronsLoose2 = cms.Path( process.L1TkElectronsLooseV2 ) + +# ---- L1TkElectrons that are isolated w.r.t. L1Tracks : dedicated low PT sequence +process.L1TkIsoElectronsLoose = process.L1TkElectronsLoose.clone() +process.L1TkIsoElectronsLoose.IsoCut = cms.double(0.1) +process.pElectronsTkIsoLoose = cms.Path( process.L1TkIsoElectronsLoose ) + + +# ---- L1TkElectrons made from L1IsoEG objects, i.e. from L1EG objects that +# are isolated in the calorimeter : + +process.L1TkElectronsIsoEG = process.L1TkElectrons.clone() +process.L1TkElectronsIsoEG.L1EGammaInputTag = cms.InputTag("SLHCL1ExtraParticlesNewClustering","IsoEGamma") +process.pElectronsIsoEG = cms.Path( process.L1TkElectronsIsoEG ) + +# ---- "electrons" from stubs - not implemented yet. +# +#process.L1TkElectronsStubs = cms.EDProducer("L1TkElectronStubsProducer", +#) +#process.pElectronsStubs = cms.Path( process.L1TkElectronsStubs ) + + + +# --------------------------------------------------------------------------- + + +# Run a trivial analyzer that prints the objects + +process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , + L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here + L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here + L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), + L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), + L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here +) + +#process.pAna = cms.Path( process.ana ) + + + +# --------------------------------------------------------------------------- + +# --- Output module : + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + + # raw data +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + + + # gen-level information +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') + + + # the L1Tracks, clusters and stubs +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + + # the L1EG objects +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_*_*' ) +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticlesNewClustering_*_*') +process.Out.outputCommands.append('keep l1extraL1Em*_l1extraParticles_*_*') + # for crystal-level granularity : +process.Out.outputCommands.append('keep *_L1EGammaCrystalsProducer_*_*') +process.Out.outputCommands.append('keep *_l1ExtraCrystalProducer_*_*') + + # the L1TkEmParticles +process.Out.outputCommands.append('keep *_L1TkPhotons_*_*') + + # the L1TkElectrons +process.Out.outputCommands.append('keep *_L1TkElectrons_*_*') +process.Out.outputCommands.append('keep *_L1TkElectronsCrystal_*_*') # for crystal-level granularity +process.Out.outputCommands.append('keep *_L1TkElectronsIsoEG_*_*') +process.Out.outputCommands.append('keep *_L1TkIsoElectrons_*_*') + +process.Out.outputCommands.append('keep *_L1TkElectronsLoose_*_*') +process.Out.outputCommands.append('keep *_L1TkIsoElectronsLoose_*_*') +process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') + + +# --- to use the genParticles, one needs to keep the collections of associators below: +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + diff --git a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h index e87a75e8daf01..36f9b4aa7d4a0 100644 --- a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h +++ b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h @@ -19,6 +19,9 @@ namespace l1slhc float ECALiso ; float ECALetPUcorr; + + int ieta; + int iphi; }; From 76074f3e582b7dd844fa0aed3905f59cc32e35a1 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Mon, 26 May 2014 18:59:27 +0200 Subject: [PATCH 009/252] fix the in-time condition bx=16 in L1TkMuonProducer.cc --- .../L1TrackTrigger/plugins/L1TkMuonProducer.cc | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc index df94d341e65bc..bf2bf7538a7cf 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc @@ -74,8 +74,6 @@ void L1TkMuonParticleProducer::produce( edm::Event& iEvent, const edm::EventSetu using namespace edm; using namespace std; -std::cout << " --- MANU enter in L1TkMuonParticleProducer " << std::endl; - std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsPriority( new L1TkMuonParticleCollection ); std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsAverage( new L1TkMuonParticleCollection ); std::auto_ptr< L1TkMuonParticleCollection > outputDTMatchInwardsMajorityFullTk( new L1TkMuonParticleCollection ); @@ -95,24 +93,18 @@ std::cout << " --- MANU enter in L1TkMuonParticleProducer " << std::endl; ++iterDTMatch ) { -std::cout << " here a DT match " << std::endl; // create the reference to DTMatch FIXME edm::Ptr< DTMatch > dtMatchRef( DTMatchHandle, iMu++ ); // get the bx int bx = iterDTMatch->getDTBX(); -std::cout << " bx = " << bx << std::endl; -// MANU CHECK ! - //if ( bx != 0 ) continue; + if ( bx != 16 ) continue; // in-time muons have BX = 0 -std::cout << " passes bx " << std::endl; // check the different options -std::cout << " iterDTMatch->getPtPriorityBin() > 0. " << iterDTMatch->getPtPriorityBin() << std::endl; - if ( iterDTMatch->getPtPriorityBin() > 0. ) { float tkIso = -999; // dummy @@ -218,7 +210,6 @@ std::cout << " iterDTMatch->getPtPriorityBin() > 0. " << iterDTMatch->getPtPrior outputDTMatchInwardsMixedMode->push_back( candMu ); } -std::cout << " iterDTMatch->getPtTTTrackBin() > 0. " << iterDTMatch->getPtTTTrackBin() << std::endl; if ( iterDTMatch->getPtTTTrackBin() > 0. ) { From a44626d296a5af0b9e5735f1c935f69ea535868c Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Mon, 26 May 2014 19:21:05 +0200 Subject: [PATCH 010/252] add flag HighPtTracks to L1TkEtMissProducer.cc, to allow to saturate high PT tracks --- .../plugins/L1TkEtMissProducer.cc | 20 ++++++++++++++----- .../python/L1TkEtMissProducer_cfi.py | 8 ++++++-- 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc index 9e8da6f579f75..066f98c586f29 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc @@ -91,6 +91,7 @@ class L1TkEtMissProducer : public edm::EDProducer { int nStubsPSmin ; // minimum number of stubs in PS modules float PTMAX; // in GeV + int HighPtTracks; // saturate or truncate //const StackedTrackerGeometry* theStackedGeometry; @@ -134,6 +135,7 @@ L1TkEtMissProducer::L1TkEtMissProducer(const edm::ParameterSet& iConfig) nStubsPSmin = iConfig.getParameter("nStubsPSmin"); PTMAX = (float)iConfig.getParameter("PTMAX"); + HighPtTracks = iConfig.getParameter("HighPtTracks"); produces("MET"); @@ -228,7 +230,15 @@ L1TkEtMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) if (chi2 > CHI2MAX) continue; - if ( PTMAX > 0 && pt > PTMAX) continue; // ignore these very high PT tracks. + float pt_rescale = 1; + + if ( PTMAX > 0 && pt > PTMAX) { + if (HighPtTracks == 0) continue; // ignore these very high PT tracks. + if (HighPtTracks == 1) { + pt_rescale = pt / PTMAX ; // will be used to rescale px and py + pt = PTMAX; // saturate + } + } int nstubs = 0; float nPS = 0.; // number of stubs in PS modules @@ -249,13 +259,13 @@ L1TkEtMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) if ( fabs(ztr - zVTX) <= DeltaZ) { // eg DeltaZ = 1 mm - sumPx += trackIter->getMomentum().x(); - sumPy += trackIter->getMomentum().y(); + sumPx += trackIter->getMomentum().x() * pt_rescale ; + sumPy += trackIter->getMomentum().y() * pt_rescale ; etTot += pt ; } else { // PU sums - sumPx_PU += trackIter->getMomentum().x(); - sumPy_PU += trackIter->getMomentum().y(); + sumPx_PU += trackIter->getMomentum().x() * pt_rescale ; + sumPy_PU += trackIter->getMomentum().y() * pt_rescale ; etTot_PU += pt ; } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py index ad359c901c91d..29bbbf6085b85 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py @@ -9,8 +9,12 @@ DeltaZ = cms.double( 1. ), # in cm nStubsmin = cms.int32( 4 ), # min number of stubs for the tracks to enter in TrkMET calculation nStubsPSmin = cms.int32( 0), # min number of stubs in the PS Modules - PTMAX = cms.double( 50. ) # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as - # mismeasured are are ignored in the calculation of TrkMET. + PTMAX = cms.double( 50. ), # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as + # mismeasured and are treated according to HighPtTracks below. + # When PTMAX < 0, no special treatment is done for high PT tracks. + HighPtTracks = cms.int32( 0 ) # when = 0 : truncation. Tracks with PT above PTMAX are ignored + # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. + ) From cdebd45d15da4150fff0557c05f5117308e279f9 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 27 May 2014 11:44:42 +0200 Subject: [PATCH 011/252] modif test_L1TkCentralMuons_cfg.py --- .../L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py index e0ab617cc4608..92b5699aaf43f 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py @@ -17,8 +17,8 @@ process.source = cms.Source("PoolSource", fileNames = cms.untracked.vstring( # single muons - #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_53.root' - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Muons/PU140/m1_SingleMuon_E2023TTI_PU140.root' + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_53.root' + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Muons/PU140/m1_SingleMuon_E2023TTI_PU140.root' ) ) @@ -26,9 +26,9 @@ # ---- Global Tag : process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') from Configuration.AlCa.GlobalTag import GlobalTag -#process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') #process.GlobalTag = GlobalTag(process.GlobalTag, 'POSTLS261_V3::All', '') -process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') +#process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') From e2b6108a2f669dc6d78de8e7d7e46b50edacf491 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 27 May 2014 17:52:31 +0200 Subject: [PATCH 012/252] missing commits --- L1Trigger/DTPlusTrackTrigger/BuildFile.xml | 43 + .../interface/DTUtilities.h | 78 + .../DTPlusTrackTrigger/plugins/BuildFile.xml | 7 + .../plugins/DTPlusTrackProducer.cc | 600 ++++++ .../plugins/DTPlusTrackProducer.h | 80 + .../DTPlusTrackTrigger/plugins/module.cc | 3 + .../python/DTPlusTrackProducer_cfi.py | 25 + .../DTPlusTrackTrigger/src/DTUtilities.cc | 60 + .../src/DTUtilities_getDTTrigger.cc | 428 +++++ .../src/DTUtilities_orderDTTriggers.cc | 192 ++ .../DTUtilities_removeRedundantDTTriggers.cc | 137 ++ L1Trigger/DTPlusTrackTrigger/test/.__afs3C91 | 1593 +++++++++++++++ L1Trigger/DTPlusTrackTrigger/test/.__afs4B1 | 906 +++++++++ L1Trigger/DTPlusTrackTrigger/test/.__afs72E4 | 1710 +++++++++++++++++ L1Trigger/DTPlusTrackTrigger/test/.__afs7891 | 1661 ++++++++++++++++ L1Trigger/DTPlusTrackTrigger/test/.__afsA51D | 1638 ++++++++++++++++ L1Trigger/DTPlusTrackTrigger/test/.__afsBE86 | 1130 +++++++++++ .../test/AnalyzerDTMatches.cc | 1637 ++++++++++++++++ .../test/AnalyzerDTMatches_cfg.py | 136 ++ .../DTPlusTrackTrigger/test/BuildFile.xml | 47 + L1Trigger/DTTrigger/BuildFile.xml | 9 +- L1Trigger/DTTrigger/src/DTTrig.cc | 3 + .../test/test_L1TkCentralMuons_cfg.py | 97 +- 23 files changed, 12202 insertions(+), 18 deletions(-) create mode 100644 L1Trigger/DTPlusTrackTrigger/BuildFile.xml create mode 100644 L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h create mode 100644 L1Trigger/DTPlusTrackTrigger/plugins/BuildFile.xml create mode 100644 L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc create mode 100644 L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h create mode 100644 L1Trigger/DTPlusTrackTrigger/plugins/module.cc create mode 100644 L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py create mode 100644 L1Trigger/DTPlusTrackTrigger/src/DTUtilities.cc create mode 100644 L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc create mode 100644 L1Trigger/DTPlusTrackTrigger/src/DTUtilities_orderDTTriggers.cc create mode 100644 L1Trigger/DTPlusTrackTrigger/src/DTUtilities_removeRedundantDTTriggers.cc create mode 100644 L1Trigger/DTPlusTrackTrigger/test/.__afs3C91 create mode 100644 L1Trigger/DTPlusTrackTrigger/test/.__afs4B1 create mode 100644 L1Trigger/DTPlusTrackTrigger/test/.__afs72E4 create mode 100644 L1Trigger/DTPlusTrackTrigger/test/.__afs7891 create mode 100644 L1Trigger/DTPlusTrackTrigger/test/.__afsA51D create mode 100644 L1Trigger/DTPlusTrackTrigger/test/.__afsBE86 create mode 100644 L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc create mode 100644 L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py create mode 100644 L1Trigger/DTPlusTrackTrigger/test/BuildFile.xml diff --git a/L1Trigger/DTPlusTrackTrigger/BuildFile.xml b/L1Trigger/DTPlusTrackTrigger/BuildFile.xml new file mode 100644 index 0000000000000..3036aac8d174e --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/BuildFile.xml @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h b/L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h new file mode 100644 index 0000000000000..51aa0a3cd8eda --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h @@ -0,0 +1,78 @@ +//#define npDEBUG + +/*! \class DTUtilities + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Nicola Pozzobon + * \brief Utilities of L1 DT + Track Trigger for the HL-LHC + * \date 2008, Dec 25 + */ + +#ifndef DTUtilities_h +#define DTUtilities_h + +#include "FWCore/Framework/interface/ESHandle.h" +#include "Geometry/DTGeometry/interface/DTGeometry.h" + +#include "L1Trigger/DTTrigger/interface/DTTrig.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h" + +/// Class implementation +class DTUtilities +{ + public : + + /// Constructor and destructor + DTUtilities( DTTrig* aDTTrigger, + BtiTrigsCollection* someBtiTrigsToStore, + TSPhiTrigsCollection* someTSPhiTrigsToStore, + TSThetaTrigsCollection* someTSThetaTrigsToStore, + bool useTS, bool useRough, + edm::ESHandle< DTGeometry > aMuonDTGeometryHandle, + std::map< unsigned int, std::vector< DTMatch* > >* aDTMatchContainer ); + + ~DTUtilities(); + + /// Main methods + void getDTTrigger(); + void orderDTTriggers(); + void extrapolateDTTriggers(); + void removeRedundantDTTriggers(); + + /// Method to match the BTI with the Phi segment + bool match( DTBtiTrigger const bti, DTChambPhSegm const tsphi ) + { + return ( tsphi.wheel() == bti.wheel() && + tsphi.station() == bti.station() && + tsphi.sector() == bti.sector() && + tsphi.step() == bti.step() && + 2 == bti.btiSL() ); + } + + /// Method to match the Phi and Theta track segments + bool match( DTChambThSegm const tstheta, DTChambPhSegm const tsphi ) + { + return ( tsphi.wheel() == tstheta.ChamberId().wheel() && + tsphi.station() == tstheta.ChamberId().station() && + tsphi.sector() == tstheta.ChamberId().sector() && + tsphi.step() == tstheta.step() ); + } + + private : + + DTTrig* theDTTrigger; + BtiTrigsCollection* theBtiTrigsToStore; + TSPhiTrigsCollection* theTSPhiTrigsToStore; + TSThetaTrigsCollection* theTSThetaTrigsToStore; + bool useTSTheta; + bool useRoughTheta; + edm::ESHandle< DTGeometry > theMuonDTGeometryHandle; + std::map< unsigned int, std::vector< DTMatch* > >* theDTMatchContainer; + +}; /// Close class + +#endif + diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/BuildFile.xml b/L1Trigger/DTPlusTrackTrigger/plugins/BuildFile.xml new file mode 100644 index 0000000000000..2edb623b4a898 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/plugins/BuildFile.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc new file mode 100644 index 0000000000000..6547d37051f5c --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc @@ -0,0 +1,600 @@ +/*! \class DTPlusTrackProducer + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Nicola Pozzobon + * \brief EDProducer of L1 DT + Track Trigger for the HL-LHC + * \date 2008, Dec 25 + */ + +#include "L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h" + +/// Constructor +DTPlusTrackProducer::DTPlusTrackProducer( const edm::ParameterSet& pSet ) : + pSetDT(pSet) +{ + TTStubsInputTag = pSet.getParameter< edm::InputTag >( "TTStubs" ); + TTTracksInputTag = pSet.getParameter< edm::InputTag >( "TTTracks" ); + + produces< BtiTrigsCollection >(); + produces< TSPhiTrigsCollection >(); + produces< DTMatchesCollection >(); + + /// Get bool flags from the cfg file + useTSTheta = pSet.getUntrackedParameter< bool >( "useTSTheta", false ); + useRoughTheta = pSet.getUntrackedParameter< bool >( "useRoughTheta", false ); + + /// Get the size of matching windows in terms of sigmas + numSigmas = pSet.getUntrackedParameter< double >( "numSigmasForMatch", 3. ); + + /// Get some constraints for finding the Pt with several methods + minRInvB = pSet.getUntrackedParameter< double >( "minRInvB", 0.00000045 ); + maxRInvB = pSet.getUntrackedParameter< double >( "maxRInvB", 1.0 ); + station2Correction = pSet.getUntrackedParameter< double >( "station2Correction", 1.0 ); + thirdMethodAccurate = pSet.getUntrackedParameter< bool >( "thirdMethodAccurate", false ); +} + +/// Destructor +DTPlusTrackProducer::~DTPlusTrackProducer(){} + +/// Begin job +void DTPlusTrackProducer::beginJob(){} + +/// Begin run +void DTPlusTrackProducer::beginRun( const edm::Run& run, const edm::EventSetup& eventSetup ) +{ + /// Prepare the DT Trigger to be used and initialize it + theDTTrigger = new DTTrig(pSetDT); + theDTTrigger->createTUs(eventSetup); +} + +/// Implement the producer +void DTPlusTrackProducer::produce( edm::Event& event, const edm::EventSetup& eventSetup ) +{ + /// Prepare the output + outputBtiTrigs = new BtiTrigsCollection(); + outputTSPhiTrigs = new TSPhiTrigsCollection(); + outputTSThetaTrigs = new TSThetaTrigsCollection(); + outputDTMatches = new DTMatchesCollection(); + tempDTMatchContainer = new std::map< unsigned int, std::vector< DTMatch* > >(); + for ( unsigned int iStation = 1; iStation <= 2; iStation++ ) + { + std::vector< DTMatch* > tempVector; + tempVector.clear(); + tempDTMatchContainer->insert( std::make_pair( iStation, tempVector ) ); + } + + /// Get the Stacked Tracker Geometry (Pt modules container) + edm::ESHandle< StackedTrackerGeometry > theStackedTrackerGeomHandle; + eventSetup.get< StackedTrackerGeometryRecord >().get( theStackedTrackerGeomHandle ); + const StackedTrackerGeometry* theStackedTracker = theStackedTrackerGeomHandle.product(); + + /// Get the muon geometry: needed for the TStheta trigger + edm::ESHandle< DTGeometry > theMuonDTGeometryHandle; + eventSetup.get< MuonGeometryRecord >().get( theMuonDTGeometryHandle ); + +/* + /// Get the magnetic field + const MagneticField* theMagneticField = 0; + edm::ESHandle< MagneticField > theMagFieldHandle; + eventSetup.get< IdealMagneticFieldRecord >().get( theMagFieldHandle ); + if ( theMagFieldHandle.isValid() ) + { + theMagneticField = &(*theMagFieldHandle); +std::cerr< > > TTStubHandle; + event.getByLabel( TTStubsInputTag, TTStubHandle ); + + /// Get the TTTrack container + edm::Handle< std::vector< TTTrack< Ref_PixelDigi_ > > > TTTrackHandle; + event.getByLabel( TTTracksInputTag, TTTrackHandle ); + + /// Check if the DT Trigger is correcly created + if ( !theDTTrigger ) + { + std::cerr << "E R R O R! Invalid L1 DT reconstruction ..." << std::endl; + std::cerr << " exiting!" << std::endl; + return; + } + + /// Run the DT Trigger workflow + theDTTrigger->triggerReco( event, eventSetup ); + + /// Prepare the Utilities + DTUtilities* theseUtilities = new DTUtilities( theDTTrigger, + outputBtiTrigs, + outputTSPhiTrigs, + outputTSThetaTrigs, + useTSTheta, useRoughTheta, + theMuonDTGeometryHandle, + tempDTMatchContainer ); + + /// Get the DTTrigger + theseUtilities->getDTTrigger(); + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* DT TRIGGER IS BUILT *" << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* how many BTI's? " << outputBtiTrigs->size() << std::endl; + std::cerr << "* how many TSPhi's? " << outputTSPhiTrigs->size() << std::endl; + std::cerr << "* how many TSTheta's? " << outputTSThetaTrigs->size() << std::endl; + std::cerr << "* how many MB1 DTMatches? " << tempDTMatchContainer->at(1).size() << std::endl; + std::cerr << "* how many MB2 DTMatches? " << tempDTMatchContainer->at(2).size() << std::endl; + std::cerr << "*********************************" << std::endl; +#endif + + /// Next, order DT triggers in ascending order + /// (the lower the best) by: + /// 1. higher code + /// 2. lower phib + theseUtilities->orderDTTriggers(); + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* DT TRIGGERS ARE ORDERED *" << std::endl; + std::cerr << "*********************************" << std::endl; + + for ( unsigned int i = 1; i <= 2; i++ ) + { + for ( unsigned int j = 0; j < tempDTMatchContainer->at(i).size(); j++ ) + { + DTMatch* abc = tempDTMatchContainer->at(i).at(j); + std::cerr << "* DT Match in MB" << i << ", no. " << j << std::endl; + std::cerr << " wh. " << abc->getDTWheel() << " sec. " << abc->getDTSector() << std::endl; + std::cerr << " code " << abc->getDTCode() << " phiB " << abc->getDTTSPhiB() << std::endl; + std::cerr << " order " << abc->getDTTTrigOrder() << std::endl; + } + } +#endif + + /// Extrapolate each DTMatch to each Tracker layer + /// NOTE: this must be done before the "remove redundancies" step + theseUtilities->extrapolateDTTriggers(); + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* DT TRIGGERS ARE EXTRAPOLATED *" << std::endl; + std::cerr << "*********************************" << std::endl; + + for ( unsigned int i = 1; i <= 2; i++ ) + { + for ( unsigned int j = 0; j < tempDTMatchContainer->at(i).size(); j++ ) + { + DTMatch* abc = tempDTMatchContainer->at(i).at(j); + std::cerr << "* DT Match in MB" << i << ", no. " << j << std::endl; + std::cerr << " phi " << abc->getPredVtxPhi() << " +/- " << abc->getPredVtxSigmaPhi() << std::endl; + std::cerr << " theta " << abc->getPredVtxTheta() << " +/- " << abc->getPredVtxSigmaTheta() << std::endl; + for ( unsigned int lay = 1; lay <= 6; lay++ ) + { + std::cerr << " projection to layer " << lay << std::endl; + std::cerr << " phi " << abc->getPredStubPhi(lay) << " +/- " << abc->getPredStubSigmaPhi(lay) << std::endl; + std::cerr << " theta " << abc->getPredStubTheta(lay) << " +/- " << abc->getPredStubSigmaTheta(lay) << std::endl; + } + std::cerr << " flag reject BEFORE removing redundancies "<getRejectionFlag()<removeRedundantDTTriggers(); + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* REDUNDANT DT TRIGGERS FLAGGED *" << std::endl; + std::cerr << "*********************************" << std::endl; + + for ( unsigned int i = 1; i <= 2; i++ ) + { + for ( unsigned int j = 0; j < tempDTMatchContainer->at(i).size(); j++ ) + { + DTMatch* abc = tempDTMatchContainer->at(i).at(j); + std::cerr << "* DT Match in MB" << i << ", no. " << j << std::endl; + std::cerr << " flag reject AFTER removing redundancies "<getRejectionFlag()< >, TTStub< Ref_PixelDigi_ > > > > mapStubByLayer; + mapStubByLayer.clear(); + + /// Loop over the container of stubs (edmNew::DetSetVector) + edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >::const_iterator iterDSV; + edmNew::DetSet< TTStub< Ref_PixelDigi_ > >::const_iterator iterTTStub; + for ( iterDSV = TTStubHandle->begin(); + iterDSV != TTStubHandle->end(); + ++iterDSV ) + { + /// Get the DetId of this Pt-module + DetId thisStackedDetId = iterDSV->id(); + StackedTrackerDetId tkDetId = StackedTrackerDetId( thisStackedDetId ); + + /// Skip if we are looking at Endcap stubs + if ( tkDetId.isEndcap() ) + { + continue; + } + + /// Here we are supposed to be in the Barrel only + int iLayer = tkDetId.iLayer(); + + /// Prepare the map + if ( mapStubByLayer.find( iLayer ) == mapStubByLayer.end() ) + { + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_> >, TTStub< Ref_PixelDigi_ > > > tempVector; + tempVector.clear(); + mapStubByLayer.insert( std::make_pair( iLayer, tempVector ) ); + } + + /// Get the stubs + edmNew::DetSet< TTStub< Ref_PixelDigi_ > > theStubs = (*TTStubHandle)[ thisStackedDetId ]; + + /// Loop over the stubs of this Pt-module + for ( iterTTStub = theStubs.begin(); + iterTTStub != theStubs.end(); + ++iterTTStub ) + { + /// Safety and consistency check + if ( tkDetId != iterTTStub->getDetId() ) + { + std::cerr << " E R R O R!!! module and object DetId are different!!!" << std::endl; + continue; + } + + /// Make the reference to be put in the map + edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > tempStubRef = edmNew::makeRefTo( TTStubHandle, iterTTStub ); + + /// Put it in the map + mapStubByLayer.find( iLayer )->second.push_back( tempStubRef ); + } + } + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* NOW READY TO DT-TK MATCHING *" << std::endl; + std::cerr << "*********************************" << std::endl; +#endif + + /// Now all barrel stubs are stored in mapStubByLayer + /// Loop over the DTMatches + for ( unsigned int i = 1; i <= 2; i++ ) + { + for ( unsigned int j = 0; j < tempDTMatchContainer->at(i).size(); j++ ) + { + /// Consider only trigger primitive at right bx + /// Skip rejected DTMatches + DTMatch* thisDTMatch = tempDTMatchContainer->at(i).at(j); + + if ( !thisDTMatch->getFlagBXOK() || + thisDTMatch->getRejectionFlag() ) + { + continue; + } + + /// Here the DTMatch is a good one + + /// Loop over the layers + for ( unsigned int lay = 1; lay <= 6; lay++ ) + { + /// Get all the stubs from this layer + if ( mapStubByLayer.find( lay ) != mapStubByLayer.end() ) + { + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubsFromThisLayer = mapStubByLayer[lay]; + + /// Prepare a Ref for the closest stub + int minDistance = 9999999; + edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > theClosestStub = theStubsFromThisLayer.at(0); + + /// Loop over the stubs + for ( unsigned int jStub = 0; jStub < theStubsFromThisLayer.size(); jStub++ ) + { + edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > tempStub = theStubsFromThisLayer.at(jStub); + + /// Compare the positions + GlobalPoint stubPos = theStackedTracker->findGlobalPosition( tempStub.get() ); + + int stubPhi = static_cast< int >( (double)(stubPos.phi()) * 4096. ); + int stubTheta = static_cast< int >( (double)(stubPos.theta()) * 4096. ); + + int thisDeltaPhi = thisDTMatch->findStubDeltaPhi( stubPhi, lay ); + +#ifdef npDEBUG + std::cerr << "* checking stub match in layer " << lay << std::endl; + std::cerr << " stub phi " << stubPos.phi() << std::endl; + std::cerr << " converted " << ((double)(stubPos.phi()) * 4096.) << std::endl; + std::cerr << " to integer " << stubPhi << std::endl; + std::cerr << " predicted phi " << thisDTMatch->getPredStubPhi(lay) + << " +/- " << thisDTMatch->getPredStubSigmaPhi(lay) << std::endl; + std::cerr << " deltaPhi " << thisDeltaPhi << std::endl; + std::cerr << " STUB is it in phi window? " << thisDTMatch->checkStubPhiMatch( stubPhi, lay, numSigmas ) << std::endl; +#endif + + /// If within the window, and update the closest stub if any + if ( thisDTMatch->checkStubPhiMatch( stubPhi, lay, numSigmas ) && + thisDTMatch->checkStubThetaMatch( stubTheta, lay, numSigmas ) ) + { +#ifdef npDEBUG + std::cerr << "*** found good match in layer " << lay << std::endl; +#endif + + if ( thisDeltaPhi < minDistance ) + { +#ifdef npDEBUG + std::cerr << "****** updating good match in layer " << lay << std::endl; +#endif + + minDistance = thisDeltaPhi; + theClosestStub = theStubsFromThisLayer.at(jStub); + +#ifdef npDEBUG + std::cerr << "********* which is now " << *(theClosestStub.get()); +#endif + } + } + } /// End of loop over the stubs + + if ( minDistance < 9999999 ) + { +#ifdef npDEBUG + std::cerr << "*********** storing the good match in layer " << lay << std::endl; + std::cerr << theClosestStub->print(); +#endif + + /// Add the stub to the match + thisDTMatch->addMatchedStubRef( theClosestStub, + theStackedTracker->findGlobalPosition( theClosestStub.get() ) ); + } + + } /// End of get all the stubs from this layer + } /// End of loop over the layers + + /// Then match to the tracks + /// This is the "classical" inside-out matching + + /// Get all the TTTracks within matching window + std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > > allTracksInWindow; + + unsigned int jTrack = 0; /// Counter needed to build the edm::Ptr to the TTTrack + typename std::vector< TTTrack< Ref_PixelDigi_ > >::const_iterator inputIter; + for ( inputIter = TTTrackHandle->begin(); + inputIter != TTTrackHandle->end(); + ++inputIter ) + { + /// Make the pointer to be put in the map + edm::Ptr< TTTrack< Ref_PixelDigi_ > > tempTrackPtr( TTTrackHandle, jTrack++ ); + + /// Redundant Pt threshold + if ( inputIter->getMomentum().perp() < 2 ) + { + continue; + } + + /// Check distance with the TTTrack + GlobalVector tkMom = tempTrackPtr->getMomentum(); + + int tkPhi = static_cast< int >( (double)(tkMom.phi()) * 4096. ); + int tkTheta = static_cast< int >( (double)(tkMom.theta()) * 4096. ); + +#ifdef npDEBUG + int thisDeltaPhi = thisDTMatch->findVtxDeltaPhi( tkPhi ); + + std::cerr << "* checking track match at vertex" << std::endl; + std::cerr << " track phi " << tkMom.phi() << std::endl; + std::cerr << " converted " << ((double)(tkMom.phi()) * 4096.) << std::endl; + std::cerr << " to integer " << tkPhi << std::endl; + std::cerr << " predicted phi " << thisDTMatch->getPredVtxPhi() + << " +/- " << thisDTMatch->getPredVtxSigmaPhi() << std::endl; + std::cerr << " deltaPhi " << thisDeltaPhi << std::endl; + std::cerr << " TRACK is it in phi window? " << thisDTMatch->checkVtxPhiMatch( tkPhi, numSigmas ) << std::endl; + std::cerr << " track theta converted to integer " << tkTheta << std::endl; + std::cerr << " predicted theta " << thisDTMatch->getPredVtxTheta() + << " +/- " << thisDTMatch->getPredVtxSigmaTheta() << std::endl; + std::cerr << " TRACK is it in theta window? " << thisDTMatch->checkVtxThetaMatch( tkTheta, numSigmas ) << std::endl; +#endif + + /// If within the window, and update the closest stub if any + if ( thisDTMatch->checkVtxPhiMatch( tkPhi, numSigmas ) && + thisDTMatch->checkVtxThetaMatch( tkTheta, numSigmas ) ) + { +#ifdef npDEBUG + std::cerr << "*** found good match at vertex" << std::endl; +#endif + + /// Add the track to the possible matches + thisDTMatch->addInWindowTrackPtr( tempTrackPtr ); + } + } + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* COUNTING DT-TO-TK MATCHES *" << std::endl; + std::cerr << "*********************************" << std::endl; + + DTMatch* abc = tempDTMatchContainer->at(i).at(j); + std::cerr << "* flag reject cross check " << abc->getRejectionFlag() << std::endl; + if ( abc->getRejectionFlag() == false ) + { + std::cerr << "* DT Match in MB" << i << ", no. " << j << std::endl; + std::cerr << " for DT at phi " << abc->getDTTSPhi() << " and theta " << abc->getDTTSTheta() << j << std::endl; + std::cerr << " matched stubs " << abc->getMatchedStubRefs().size() << std::endl; + + std::map< unsigned int, edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > thisStubMap + = abc->getMatchedStubRefs(); + std::map< unsigned int, edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > >::iterator stubMapIter; + + unsigned int kStub = 0; + for ( stubMapIter = thisStubMap.begin(); + stubMapIter != thisStubMap.end(); + ++stubMapIter ) + { + std::cerr << "** stub number " << kStub++ << std::endl; + const TTStub< Ref_PixelDigi_ >* thisStub = stubMapIter->second.get(); + std::cerr << thisStub->print(); + } + + std::cerr << " tracks in window " << abc->getInWindowTrackPtrs().size() << std::endl; + for ( unsigned int kTrack = 0; kTrack < abc->getInWindowTrackPtrs().size(); kTrack++ ) + { + std::cerr << "** track number " << kTrack << std::endl; + std::cerr << " vtx " << abc->getInWindowTrackPtrs().at(kTrack)->getPOCA() << std::endl; + std::cerr << " mom " << abc->getInWindowTrackPtrs().at(kTrack)->getMomentum() << std::endl; + } + } + else + { + std::cerr << "* wait, there is also a rejected DT object" << std::endl; + } + + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* FIND CLOSEST TRACK *" << std::endl; + std::cerr << "*********************************" << std::endl; +#endif + + /// Check the DT-to-track best Pt match + /// first, get the muon Pt information + int dtPt = thisDTMatch->getDTPt(); + int dtPtMin = thisDTMatch->getDTPtMin( numSigmas ); + int dtPtMax = thisDTMatch->getDTPtMax( numSigmas ); + +#ifdef npDEBUG + std::cerr << "* DT Match in MB" << i << ", no. " << j << std::endl; + std::cerr << " has this Pt range " << dtPtMin << " .. " << dtPt << " .. " << dtPtMax << " with no. sigmas = " << numSigmas << std::endl; +#endif + + /// Now check the best track + if ( thisDTMatch->getInWindowTrackPtrs().size() > 0 ) + { + /// Prepare a Ptr for the closest track + int minPtDifference = 999999; + edm::Ptr< TTTrack< Ref_PixelDigi_ > > theClosestTrack = thisDTMatch->getInWindowTrackPtrs().at(0); + + /// Loop over the tracks + for ( unsigned int jTrack = 0; jTrack < thisDTMatch->getInWindowTrackPtrs().size(); jTrack++ ) + { + edm::Ptr< TTTrack< Ref_PixelDigi_ > > tempTrackPtr = thisDTMatch->getInWindowTrackPtrs().at(jTrack); + + int trackPt = static_cast< int >( tempTrackPtr->getMomentum().perp() ); + + /// Check if they match + if ( trackPt >= dtPtMin && + trackPt <= dtPtMax ) + { +#ifdef npDEBUG + std::cerr << "*** found good Pt match at vertex" << std::endl; +#endif + + int ptDiff = abs( dtPt - trackPt ); + if ( ptDiff < minPtDifference ) + { +#ifdef npDEBUG + std::cerr << "****** updating good Pt match at vertex" << std::endl; +#endif + + minPtDifference = ptDiff; + theClosestTrack = tempTrackPtr; + +#ifdef npDEBUG + std::cerr << "********* which is now " << jTrack << std::endl; + std::cerr << " vtx " << tempTrackPtr->getPOCA() << std::endl; + std::cerr << " mom " << tempTrackPtr->getMomentum() << std::endl; +#endif + } + } + } /// End of loop over tracks + + /// If any, store the matched track + thisDTMatch->setPtMatchedTrackPtr( theClosestTrack ); + } + +#ifdef npDEBUG + if ( abc->getPtMatchedTrackPtr().isNull() == false ) + { + std::cerr << "************ so, the best one is" << std::endl; + std::cerr << " vtx " << abc->getPtMatchedTrackPtr()->getPOCA() << std::endl; + std::cerr << " mom " << abc->getPtMatchedTrackPtr()->getMomentum() << std::endl; + } + else + { + std::cerr << "************ unfortunately, no best track match is available" << std::endl; + } +#endif + + /// Now, set all the possible Pt information + thisDTMatch->setPtMethods( station2Correction, thirdMethodAccurate, + minRInvB, maxRInvB ); + + /// Find the priority and the average Pt's according to the specific encoding + /// defined within the data format class + thisDTMatch->findPtPriority(); + thisDTMatch->findPtAverage(); + + /// Then, assign all the possible Pt bins + thisDTMatch->findPtPriorityBin(); + thisDTMatch->findPtAverageBin(); + thisDTMatch->findPtTTTrackBin(); + thisDTMatch->findPtMajorityFullTkBin(); + thisDTMatch->findPtMajorityBin(); + thisDTMatch->findPtMixedModeBin(); + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* DT-TK PT PRINTOUT *" << std::endl; + std::cerr << "*********************************" << std::endl; + + std::cerr << "* DT Match in MB" << i << ", no. " << j << std::endl; + std::cerr << " priority Pt bin: " << abc->getPtPriorityBin() << " GeV (" << abc->getPtPriority() << " GeV)" << std::endl; + std::cerr << " average Pt bin: " << abc->getPtAverageBin() << " GeV (" << abc->getPtAverage() << " GeV)" << std::endl; + std::cerr << " TTTrack Pt bin: " << abc->getPtTTTrackBin() << " GeV"; + if ( abc->getPtMatchedTrackPtr().isNull() == false ) + std::cerr << " (" << abc->getPtMatchedTrackPtr()->getMomentum().perp() << " GeV)" << std::endl; + else + std::cerr << std::endl; + std::cerr << " full maj. Pt bin: " << abc->getPtMajorityFullTkBin() << " GeV" << std::endl; + std::cerr << " majority Pt bin: " << abc->getPtMajorityBin() << " GeV" << std::endl; + std::cerr << " mixedmode Pt bin: " << abc->getPtMixedModeBin() << " GeV" << std::endl; + + std::map< std::string, DTMatchPt* > abcMap = abc->getPtMethodsMap(); + std::map< std::string, DTMatchPt* >::const_iterator abcMapIter; + + for ( abcMapIter = abcMap.begin(); + abcMapIter != abcMap.end(); + ++abcMapIter ) + { + std::cerr << " >> " << abcMapIter->first << " Pt: " << abcMapIter->second->getPt() << " GeV" << std::endl; + } + + std::cerr << std::endl; +#endif + + outputDTMatches->push_back( *thisDTMatch ); + + } /// End of loop over DT matches + } + + event.put( std::auto_ptr< BtiTrigsCollection >( outputBtiTrigs ) ); + event.put( std::auto_ptr< TSPhiTrigsCollection >( outputTSPhiTrigs ) ); + event.put( std::auto_ptr< DTMatchesCollection >( outputDTMatches ) ); + + return; +} + +/// End job +void DTPlusTrackProducer::endJob(){} + diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h new file mode 100644 index 0000000000000..fdf7b404c4b6e --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h @@ -0,0 +1,80 @@ +#ifndef DTPlusTrackProducer_h +#define DTPlusTrackProducer_h + +/*! \class DTPlusTrackProducer + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Nicola Pozzobon + * \brief EDProducer of L1 DT + Track Trigger for the HL-LHC + * \date 2008, Dec 25 + */ + +#include + +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/CurrentProcessingContext.h" +#include "FWCore/Framework/interface/CachedProducts.h" + +#include "MagneticField/Engine/interface/MagneticField.h" +#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" + +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" +#include "Geometry/Records/interface/MuonGeometryRecord.h" + +#include "L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h" + +class DTPlusTrackProducer : public edm::EDProducer +{ + public : + + explicit DTPlusTrackProducer( const edm::ParameterSet& ); + ~DTPlusTrackProducer(); + + private : + + virtual void beginJob(); + virtual void beginRun( const edm::Run&, const edm::EventSetup& ); + virtual void produce( edm::Event&, const edm::EventSetup& ); + virtual void endJob(); + + /// Input tag + edm::InputTag TTStubsInputTag; + edm::InputTag TTTracksInputTag; + + /// bool flags + bool useTSTheta; + bool useRoughTheta; + + /// How many sigmas for the stub matching? + double numSigmas; + + /// Some constraints for finding the Pt with several methods + double minRInvB; + double maxRInvB; + double station2Correction; + bool thirdMethodAccurate; + + /// The L1 DT products + BtiTrigsCollection* outputBtiTrigs; + TSPhiTrigsCollection* outputTSPhiTrigs; + TSThetaTrigsCollection* outputTSThetaTrigs; + DTMatchesCollection* outputDTMatches; + + /// The collection of matches + std::map< unsigned int, std::vector< DTMatch* > >* tempDTMatchContainer; + + protected : + + DTTrig* theDTTrigger; + const edm::ParameterSet pSetDT; /// needed by DTTrigger + +}; + +#endif + diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/module.cc b/L1Trigger/DTPlusTrackTrigger/plugins/module.cc new file mode 100644 index 0000000000000..f35796d284937 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/plugins/module.cc @@ -0,0 +1,3 @@ +#include "L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h" +DEFINE_FWK_MODULE(DTPlusTrackProducer); + diff --git a/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py b/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py new file mode 100644 index 0000000000000..7b045df116a22 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py @@ -0,0 +1,25 @@ +import FWCore.ParameterSet.Config as cms + +### Needed to access DTConfigManagerRcd and by DTTrig +from L1TriggerConfig.DTTPGConfigProducers.L1DTTPGConfig_cff import * + +DTPlusTrackProducer = cms.EDProducer( + "DTPlusTrackProducer", + + TTStubs = cms.InputTag("TTStubsFromPixelDigis", "StubAccepted"), + TTTracks = cms.InputTag("TTTracksFromPixelDigis", "Level1TTTracks"), + + debug = cms.untracked.bool(False), # needed by DTTrig + digiTag = cms.InputTag('simMuonDTDigis'), # needed by DTTrig + + useTSTheta = cms.untracked.bool(True), + useRoughTheta = cms.untracked.bool(False), + + numSigmasForMatch = cms.untracked.double(3.), + + minRInvB = cms.untracked.double( 0.00000045 ), + maxRInvB = cms.untracked.double( 1.0 ), + station2Correction = cms.untracked.double( 1.0 ), + thirdMethodAccurate = cms.untracked.bool(False), +) + diff --git a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities.cc b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities.cc new file mode 100644 index 0000000000000..2cb9ad0c411a7 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities.cc @@ -0,0 +1,60 @@ +/*! \class DTUtilities + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Nicola Pozzobon + * \brief Utilities of L1 DT + Track Trigger for the HL-LHC + * \date 2008, Dec 25 + */ + +#include "L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h" + +/// Class constructor +DTUtilities::DTUtilities( DTTrig* aDTTrigger, + BtiTrigsCollection* someBtiTrigsToStore, + TSPhiTrigsCollection* someTSPhiTrigsToStore, + TSThetaTrigsCollection* someTSThetaTrigsToStore, + bool useTS, bool useRough, + edm::ESHandle< DTGeometry > aMuonDTGeometryHandle, + std::map< unsigned int, std::vector< DTMatch* > >* aDTMatchContainer ) +{ + theDTTrigger = aDTTrigger; + theBtiTrigsToStore = someBtiTrigsToStore; + theTSPhiTrigsToStore = someTSPhiTrigsToStore; + theTSThetaTrigsToStore = someTSThetaTrigsToStore; + useTSTheta = useTS; + useRoughTheta = useRough; + theMuonDTGeometryHandle = aMuonDTGeometryHandle; + theDTMatchContainer = aDTMatchContainer; +} + +/// Class destructor +DTUtilities::~DTUtilities() +{ + delete theDTTrigger; + delete theBtiTrigsToStore; + delete theTSPhiTrigsToStore; + delete theTSThetaTrigsToStore; + delete theDTMatchContainer; +} + +/// Extrapolation of DT Triggers to Tracker and Vtx +void DTUtilities::extrapolateDTTriggers() +{ + for ( unsigned int i = 1; i <= 2; i++ ) + { + for ( unsigned int j = 0; j < theDTMatchContainer->at(i).size(); j++ ) + { + DTMatch* thisDTMatch = theDTMatchContainer->at(i).at(j); + + /// Extrapolate to each Tracker layer + for ( unsigned int lay = 1; lay <= 6; lay++ ) + { + thisDTMatch->extrapolateToTrackerLayer(lay); + } + + /// Extrapolate also to the Vtx + thisDTMatch->extrapolateToVertex(); + } + } +} + diff --git a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc new file mode 100644 index 0000000000000..c1931d38fdf26 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc @@ -0,0 +1,428 @@ +/*! \class DTUtilities + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Nicola Pozzobon + * \brief Utilities of L1 DT + Track Trigger for the HL-LHC + * \date 2008, Dec 25 + */ + +#include "L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h" + +/// Method to get the DTTrigger +void DTUtilities::getDTTrigger() +{ + /// L1 DT Trigger flags + bool doneBTI = false; + bool doneTSTheta = false; + + /// BTI + std::vector< DTBtiTrigData > theBTITrigs = theDTTrigger->BtiTrigs(); + std::vector< DTBtiTrigData >::const_iterator iterBTITrig; + + /// Loop over the BTI triggers + DTBtiTrigger* aDTBti; + for ( iterBTITrig = theBTITrigs.begin(); + iterBTITrig != theBTITrigs.end(); + iterBTITrig++ ) + { + /// Get the position and direction of the BTI + Global3DPoint pos = theDTTrigger->CMSPosition( &(*iterBTITrig) ); + Global3DVector dir = theDTTrigger->CMSDirection( &(*iterBTITrig) ); + + /// Prepare the BTI to be stored and push them into the output + aDTBti = new DTBtiTrigger( *iterBTITrig, pos, dir ); + theBtiTrigsToStore->push_back(*aDTBti); + + /// Clean the pointer + delete aDTBti; + } + + /// Set the flag + doneBTI = true; + + /// TSTheta + std::vector< DTChambThSegm > theTSThetaTrigs = theDTTrigger->TSThTrigs(); + std::vector< DTChambThSegm >::const_iterator iterTSTheta; + + for ( iterTSTheta = theTSThetaTrigs.begin(); + iterTSTheta != theTSThetaTrigs.end(); + iterTSTheta++ ) + { + /// Store the TSTheta trigger + theTSThetaTrigsToStore->push_back(*iterTSTheta); + } + + /// Set the flag + doneTSTheta = true; + + /// TSPhi + std::vector< DTChambPhSegm > theTSPhiTrigs = theDTTrigger->TSPhTrigs(); + std::vector< DTChambPhSegm >::const_iterator iterTSPhi; + DTTSPhiTrigger* aTSPhiTrig; + + for ( iterTSPhi = theTSPhiTrigs.begin(); + iterTSPhi != theTSPhiTrigs.end(); + iterTSPhi++ ) + { + /// Get the position and direction of the TSPhi trigger + Global3DPoint pos = theDTTrigger->CMSPosition( &(*iterTSPhi) ); + Global3DVector dir = theDTTrigger->CMSDirection( &(*iterTSPhi) ); + + /// Create and store the TSPhi trigger + aTSPhiTrig = new DTTSPhiTrigger( *iterTSPhi, pos, dir ); + theTSPhiTrigsToStore->push_back(*aTSPhiTrig); + + /// Get the chamber Id + const DTChamberId thisChambId = iterTSPhi->ChamberId(); + + /// Find the Id of the two BTI's that compose the segment + DTBtiId innerBti( thisChambId, 1, iterTSPhi->tracoTrig()->posIn() ); + DTBtiId outerBti( thisChambId, 3, iterTSPhi->tracoTrig()->posOut() ); + + /// Find the matches with the BTI's + bool foundTSPhiBtiMatch = false; + + if ( !useTSTheta && doneBTI && + ( iterTSPhi->station() == 1 || iterTSPhi->station() == 2 ) ) + { + for ( BtiTrigsCollection::iterator thisBti = theBtiTrigsToStore->begin(); + thisBti != theBtiTrigsToStore->end(); + thisBti++ ) + { + /// Add DTMatch to DTMatchesCollection. + if( this->match( *thisBti, *iterTSPhi ) ) + { + int tempCode = aTSPhiTrig->code() * 4; + if ( aTSPhiTrig->station() == 1 ) + { + tempCode += 2; + } + if ( thisBti->code() == 8 ) + { + tempCode += 1; + } + + float tempTheta = atan( sqrt( aTSPhiTrig->cmsPosition().x()*aTSPhiTrig->cmsPosition().x() + + aTSPhiTrig->cmsPosition().y()*aTSPhiTrig->cmsPosition().y() ) / + aTSPhiTrig->cmsPosition().z() ); + + if ( aTSPhiTrig->cmsPosition().z() < 0 ) + { + tempTheta += M_PI; + } + + int intTempTheta = static_cast< int >( tempTheta * 4096. ); + +#ifdef npDEBUG + std::cerr << "*** CREATING MATCH from TSPHI and BTI" << std::endl; +#endif + + /// Create the DT match using position as given by TSPhi + DTMatch* aDTMatch = new DTMatch( aTSPhiTrig->wheel(), + aTSPhiTrig->station(), + aTSPhiTrig->sector(), + aTSPhiTrig->step(), + tempCode, + aTSPhiTrig->phi(), + aTSPhiTrig->phiB(), + intTempTheta, + aTSPhiTrig->cmsPosition(), + aTSPhiTrig->cmsDirection(), + (aTSPhiTrig->step() == 16) ? true : false ); + +/* + tempTheta = atan( sqrt( thisBti->cmsPosition().x()*thisBti->cmsPosition().x() + + thisBti->cmsPosition().y()*thisBti->cmsPosition().y() ) / + thisBti->cmsPosition().z() ); + + if ( thisBti->cmsPosition().z() < 0 ) + { + tempTheta += M_PI; + } + + int intTempTheta = static_cast< int >( tempTheta * 4096. ); + + /// Create the DT match using position as given by BTI + DTMatch* aDTMatch = new DTMatch( iterTSTheta->wheel(), + iterTSTheta->station(), + iterTSTheta->sector(), + iterTSTheta->step(), + tempCode, + iterTSTheta->phi(), + iterTSTheta->phiB(), + intTempTheta, + thisBti->cmsPosition(), + thisBti->cmsDirection(), + (iterTSTheta->step() == 16) ? true : false ); +*/ + + aDTMatch->setInnerBtiId( innerBti ); + aDTMatch->setOuterBtiId( outerBti ); + aDTMatch->setMatchedBtiId( thisBti->parentId() ); + + if ( aTSPhiTrig->station() == 1 || aTSPhiTrig->station() == 2 ) /// Redundant + { + theDTMatchContainer->at(aTSPhiTrig->station()).push_back( aDTMatch ); + } + else + { + std::cerr << "A L E R T! Muon station is neither 1 nor 2" << std::endl; + } + + /// Set the flag + foundTSPhiBtiMatch = true; + } + } + } /// End of matches TSPhi-BTI (theta) + + /// Find the matches with TSTheta's + bool foundTSPhiTSThetaMatch = false; + + if ( useTSTheta && doneTSTheta && + ( iterTSPhi->station() == 1 || iterTSPhi->station()==2 ) ) + { + for ( TSThetaTrigsCollection::iterator thisTSTheta = theTSThetaTrigsToStore->begin(); + thisTSTheta != theTSThetaTrigsToStore->end(); + thisTSTheta++ ) + { + /// Prepare the DTMatch + if ( this->match( *thisTSTheta, *iterTSPhi ) ) + { + /// Loop on TSTheta Trigger words + for ( int i = 0; i < 7; i++ ) + { + if ( thisTSTheta->code(i) > 0 ) + { + /// Get the position information + int thwh = thisTSTheta->ChamberId().wheel(); + int thstat = thisTSTheta->ChamberId().station(); + int thsect = thisTSTheta->ChamberId().sector(); + int thqual = thisTSTheta->quality(i); + + /// Identify the BTI + int idBti = (i+1)*8 - 3; + DTBtiId id = DTBtiId( thwh, thstat, thsect, 2, idBti ); + + /// Get the chamber + DTChamberId chaid = DTChamberId( thwh, thstat, thsect ); + const DTChamber* chamb = theMuonDTGeometryHandle->chamber(chaid); + + /// Get the chamber geometry and the BTI position + DTTrigGeom* thisChamberGeometry = new DTTrigGeom( const_cast< DTChamber* >(chamb), false ); + GlobalPoint posBti = thisChamberGeometry->CMSPosition( DTBtiId(chaid, 2, idBti) ); + float thposx = posBti.x(); + float thposy = posBti.y(); + float thposz = posBti.z(); + + /// Get again the position information from the TSPhi + int wh = iterTSPhi->wheel(); + int st = iterTSPhi->station(); + int se = iterTSPhi->sector(); + int bx = iterTSPhi->step(); + int code = iterTSPhi->code()*4 + thqual; + + /// Adjust the code + /// code 0,1 = L + /// 2,3 = H + /// 4 = LL + /// 5 = HL + /// 6 = HH + if ( iterTSPhi->station() == 1 ) + { + code = code + 2; + } + if ( code == 1 && thqual == 1 ) + { + code = code + 1; /// Correction to avoid twice same code + } + + /// Get and adjust polar coordinates + int phi = iterTSPhi->phi(); + int phib = iterTSPhi->phiB(); + float theta = atan( sqrt( thposx*thposx + thposy*thposy ) / thposz ); + + if ( thposz < 0 ) + { + theta += M_PI; + } + + /// Set flag for trigger at right bx + bool flagBxOK = false; + if ( bx == 16 ) + { + flagBxOK = true; + } + + /// Prepare the match + GlobalPoint posMatch( pos.x(), pos.y(), posBti.z() ); + + /// Correct for asymmetries in muon LUT's + if ( wh == 1 || wh == 2 || + ( wh == 0 && + ( se == 2 || se == 3 || se == 6 || se == 7 || se == 10 || se == 11) ) ) + { + /// Positive wheels + if ( code < 16 ) + { + phib = phib - ( -23 + 2*st + wh ) - 1; + } + } + else + { + /// Negative wheels + if ( code < 16 ) + { + phib = phib - ( 11 + 6*st + wh ) + 3; + } + } + + /// Store the TSPhi-TSTheta match +#ifdef npDEBUG + std::cerr << "*** CREATING MATCH from TSPHI and TSTHETA" << std::endl; +#endif + /// Create the DT match using position as given by the match and direction by TSPhi + int intTempTheta = static_cast< int >( theta * 4096. ); + DTMatch* aDTMatch = new DTMatch( wh, st, se, bx, code, phi, phib, intTempTheta, + posMatch, dir, flagBxOK ); + + aDTMatch->setInnerBtiId( innerBti ); + aDTMatch->setOuterBtiId( outerBti ); + aDTMatch->setMatchedBtiId( id ); + + if ( st == 1 || st == 2 ) /// Redundant + { + theDTMatchContainer->at(st).push_back( aDTMatch ); + } + else + { + std::cerr << "A L E R T! Muon station is neither 1 nor 2" << std::endl; + } + + /// Set the flag + foundTSPhiTSThetaMatch = true; + } + } /// End of loop over TSTheta words to get idBti = (i+1)*8 - 3 + + } /// End of if( match( *thisTSTheta, *iterTSPhi ) ) + } /// End of loop over TSTheta triggers + } /// End of match between TSPhi and TSTheta triggers + + /// Case where no Theta Trigger was found: + /// this method is allowed only for TSPhi trigger code >= 2 !! + /// Get chamber center and allow error on whole chamber width + if ( !(foundTSPhiBtiMatch || foundTSPhiTSThetaMatch) && + (iterTSPhi->station() == 1 || iterTSPhi->station() == 2) && + iterTSPhi->code() >= 2 ) + { + /// Same comments as before, unless specified + int wh = iterTSPhi->wheel(); + int st = iterTSPhi->station(); + int se = iterTSPhi->sector(); + int bx = iterTSPhi->step(); + int code = iterTSPhi->code()*4 ; + if ( iterTSPhi->station() == 1 ) + { + code = code + 2; + } + /// Force lower rank assuming it is like station 2 + + if( useRoughTheta ) + { + int phi = iterTSPhi->phi(); + int phib = iterTSPhi->phiB(); + + /// Use the wire: theta is set at station center with half a chamber window + DTWireId wireId = DTWireId( wh, st, se, 2, 1, 1 ); + const DTLayer* layer = theMuonDTGeometryHandle->layer( wireId.layerId() ); + const DTTopology& tp = layer->specificTopology(); + + float posX = tp.wirePosition( tp.firstChannel() ); + LocalPoint posInLayer( posX, 0., 0. ); + GlobalPoint posFirstWire = layer->surface().toGlobal( posInLayer ); + + int ncells = layer->specificTopology().channels(); + + posX = posX + static_cast< float >(ncells) * 4.2; + LocalPoint posInLayer2( posX, 0., 0. ); + GlobalPoint posLastWire = layer->toGlobal( posInLayer2 ); + + float theta = ( posFirstWire.theta() + posLastWire.theta() )/2.; + + posX = posX - static_cast< float >(ncells) * 2.1; + LocalPoint posInLayer3( posX, 0., 0. ); + GlobalPoint posCentralWire = layer->toGlobal( posInLayer3 ); + + GlobalVector gdbti = GlobalVector(); /// Dummy direction + bool flagBxOK = false; + if ( bx == 16 ) + { + flagBxOK = true; + } + + GlobalPoint posMatch( pos.x(), pos.y(), posCentralWire.z() ); + + /// Correct for asymmetries in muon LUT's + if ( wh == 1 || wh == 2 || + ( wh == 0 && + ( se == 2 || se == 3 || se == 6 || se == 7 || se == 10 || se == 11) ) ) + { + /// Positive wheels + if ( code < 16 ) + { + phib = phib - ( -23 + 2*st + wh ) - 1; + } + } + else + { + /// Negative wheels + if ( code < 16 ) + { + phib = phib - ( 11 + 6*st + wh ) + 3; + } + } + +#ifdef npDEBUG + std::cerr << "*** CREATING MATCH from TSPHI ONLY!!" << std::endl; +#endif + + /// Store the TSPhi-TSTheta match + /// Create the DT match using position as given by the match and direction by BTI + int intTempTheta = static_cast< int >( theta * 4096. ); + DTMatch* aDTMatch = new DTMatch( wh, st, se, bx, code, phi, phib, intTempTheta, + posMatch, gdbti, flagBxOK ); + + aDTMatch->setInnerBtiId( innerBti ); + aDTMatch->setOuterBtiId( outerBti ); + /// Leave the matched BTI Id to 0x0 + + /// Set needed data for correct extrapolation search and flag for missing theta + float deltaTheta = fabs( ( posFirstWire.theta() - posLastWire.theta() ) / 2. ); + aDTMatch->setThetaCorrection( deltaTheta ); + + if ( st == 1 || st == 2 ) + { + theDTMatchContainer->at(st).push_back( aDTMatch ); + } + else + { + std::cerr << "A L E R T! Muon station is neither 1 nor 2" << std::endl; + } + } // End if useRoughTheta + } // End if no match is found ... + + /// Clean the pointer + delete aTSPhiTrig; + } + +#ifdef npDEBUG + std::cerr << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* DT TRIGGER OPERATIONS *" << std::endl; + std::cerr << "*********************************" << std::endl; + std::cerr << "* done BTI? " << doneBTI << std::endl; + std::cerr << "* done TSTheta? " << doneTSTheta << std::endl; +#endif + + return; +} + diff --git a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_orderDTTriggers.cc b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_orderDTTriggers.cc new file mode 100644 index 0000000000000..a0fe81e96c9c0 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_orderDTTriggers.cc @@ -0,0 +1,192 @@ +/*! \class DTUtilities + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Nicola Pozzobon + * \brief Utilities of L1 DT + Track Trigger for the HL-LHC + * \date 2008, Dec 25 + */ + +#include "L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h" + +/// Method to give ordering number to the DTTriggers +void DTUtilities::orderDTTriggers() +{ + /// If no DTTrigger is found, skip + if ( theDTMatchContainer->at(1).size() == 0 && + theDTMatchContainer->at(2).size() == 0 ) + { + return; + } + + /// Order DT phi-eta matches: first by higher code, then by lower phib + + /// Utility variables + /// 24 bx, 5 wheels, 12 sectors, 10 max matches + unsigned int sortDTTIMatch[24][5][12][10]; + unsigned int indexDTTIMatch[24][5][12]; + + /// Initialize and store matches per bx, wheel, sector + unsigned int maxMatches = 10; + + for ( int ibx = 8; ibx < 25; ibx++ ) + { + for ( int iwh = -2; iwh < 3; iwh++ ) + { + for ( int isec = 1; isec < 13; isec++ ) + { + indexDTTIMatch[ibx-8][iwh+2][isec-1] = 0; + } + } + } + + unsigned int numDTMatchesSt1 = theDTMatchContainer->at(1).size(); + unsigned int numDTMatches = theDTMatchContainer->at(1).size() + theDTMatchContainer->at(2).size(); + + for ( int ibx = 8; ibx < 25; ibx++ ) + { + for ( int iwh = -2; iwh < 3; iwh++ ) + { + for ( int isec = 1; isec < 13; isec++ ) + { + for ( unsigned int dm = 0; dm < numDTMatchesSt1; dm++ ) + { + DTMatch* thisMatch = theDTMatchContainer->at(1).at(dm); + + if ( thisMatch->getDTBX() == ibx && + thisMatch->getDTWheel() == iwh && + thisMatch->getDTSector() == isec ) + { + if ( indexDTTIMatch[ibx-8][iwh+2][isec-1] < maxMatches ) + { + sortDTTIMatch[ibx-8][iwh+2][isec-1][indexDTTIMatch[ibx-8][iwh+2][isec-1]] = dm; + } + + indexDTTIMatch[ibx-8][iwh+2][isec-1]++; + } + } + + for ( unsigned int dm = numDTMatchesSt1; dm < numDTMatches; dm++ ) + { + DTMatch* thisMatch = theDTMatchContainer->at(2).at( dm - numDTMatchesSt1 ); + + if ( thisMatch->getDTBX() == ibx && + thisMatch->getDTWheel() == iwh && + thisMatch->getDTSector() == isec ) + { + if ( indexDTTIMatch[ibx-8][iwh+2][isec-1] < maxMatches ) + { + sortDTTIMatch[ibx-8][iwh+2][isec-1][ indexDTTIMatch[ibx-8][iwh+2][isec-1] ] = dm; + } + + indexDTTIMatch[ibx-8][iwh+2][isec-1]++; + } + } + } + } + } + + /// Order matches + /// Loop over matches for every bx, wheel, sector + for ( int ibx = 8; ibx < 25; ibx++ ) + { + for ( int iwh = -2; iwh < 3; iwh++ ) + { + for ( int isec = 1; isec < 13; isec++ ) + { + unsigned int im[10]; + unsigned int is[10]; + + for ( unsigned int i = 0; i < maxMatches; i++ ) + { + im[i] = 0; + is[i] = 0; + } + + int ntrig = indexDTTIMatch[ibx-8][iwh+2][isec-1]; + + /// First compare quality code; when these are equal then compare by + /// bending angle: better grade for higher bending. + for ( int itrig = 0; itrig < ntrig; itrig++ ) + { + unsigned int testNumber = sortDTTIMatch[ibx-8][iwh+2][isec-1][itrig]; + + if ( testNumber < numDTMatchesSt1 ) + { + is[itrig] = 1; + im[itrig] = testNumber; + } + else + { + is[itrig] = 2; + im[itrig] = testNumber - numDTMatchesSt1; + } + + if ( itrig == 0 ) + { + /// This is the first match; set as first: + int triggerOrder = 1; + + theDTMatchContainer->at(is[itrig]).at(im[itrig])->setDTTrigOrder(triggerOrder); + } + else if ( itrig > 0 ) + { + /// These are the remaining matches, + /// check against already ordered ones: + int currentCode = theDTMatchContainer->at(is[itrig]).at(im[itrig])->getDTCode(); + int currentPhiB = theDTMatchContainer->at(is[itrig]).at(im[itrig])->getDTTSPhiB(); + + /// Stop loop when the current trigger is higher grade + /// than already ordered ones + int istop = -1; + for ( int i = 0; i < itrig; i++ ) + { + int checkCode = theDTMatchContainer->at(is[i]).at(im[i])->getDTCode(); + int checkPhiB = theDTMatchContainer->at(is[i]).at(im[i])->getDTTSPhiB(); + + /// First case: current code is higher than stored code + if ( checkCode < currentCode ) + { + istop = i; + break; + } + + /// Second case: code is the same: order by lower bending angle + else if ( currentCode == checkCode ) + { + if ( checkPhiB > currentPhiB ) + { + istop = i; + break; + } + } + } /// End loop over already ordered matches + + /// Now set ordinal number + /// First case: current match is lowest rank + if ( istop < 0 ) + { + theDTMatchContainer->at(is[itrig]).at(im[itrig])->setDTTrigOrder(itrig+1); + } + // Second case: current match goes somewhere in the existing list + else + { + int triggerOrder = theDTMatchContainer->at(is[istop]).at(im[istop])->getDTTTrigOrder(); + theDTMatchContainer->at(is[itrig]).at(im[itrig])->setDTTrigOrder(triggerOrder); + + for ( int i = 0; i < itrig; i++ ) + { + if ( theDTMatchContainer->at(is[i]).at(im[i])->getDTTTrigOrder() >= triggerOrder ) + { + theDTMatchContainer->at(is[i]).at(im[i])->setDTTrigOrder( theDTMatchContainer->at(is[i]).at(im[i])->getDTTTrigOrder() + 1 ); + } + } + } + } /// End of setting of order position of the current match + } /// End loop for ordering all matches + } /// End loop over sect + } /// End loop over wh + } /// End loop over bx + + return; +} + diff --git a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_removeRedundantDTTriggers.cc b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_removeRedundantDTTriggers.cc new file mode 100644 index 0000000000000..9d8c675881faa --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_removeRedundantDTTriggers.cc @@ -0,0 +1,137 @@ +/*! \class DTUtilities + * \author Ignazio Lazzizzera + * \author Sara Vanini + * \author Nicola Pozzobon + * \brief Utilities of L1 DT + Track Trigger for the HL-LHC + * \date 2008, Dec 25 + */ + +#include "L1Trigger/DTPlusTrackTrigger/interface/DTUtilities.h" + +/// Method to get rid of redundancies (setting a rejection flag) +void DTUtilities::removeRedundantDTTriggers() +{ + /// Redundant DTMatch cancellation + /// choose one layer for extrapolation (central layer for the time being) + int testLayer = 3; + int numSigmaCut = 3; + + /// Combine together the two vector of pointers + /// Then you can change the objects as you are working with pointers + std::vector< DTMatch* > tempVector = theDTMatchContainer->at(1); + tempVector.insert( tempVector.end(), + theDTMatchContainer->at(2).begin(), theDTMatchContainer->at(2).end() ); + + /// Check the size is correct + unsigned int sumSizes = theDTMatchContainer->at(1).size() + theDTMatchContainer->at(2).size(); + unsigned int mergedSize = tempVector.size(); + + if ( sumSizes != mergedSize ) + { + exit(0); + } + + /// Find II tracks in SAME station SAME sector SAME bx and remove single L in any case + for ( unsigned int iDt = 0; iDt < mergedSize; iDt++ ) + { + if ( tempVector.at(iDt)->getRejectionFlag() == false ) + { + /// Record MB I track station, sector and bx + int station = tempVector.at(iDt)->getDTStation(); + int bx = tempVector.at(iDt)->getDTBX(); + int sector = tempVector.at(iDt)->getDTSector(); + + for ( unsigned int jDt = (iDt + 1); jDt < mergedSize; jDt++ ) + { + if ( tempVector.at(jDt)->getDTStation() == station && + tempVector.at(jDt)->getDTBX() == bx && + tempVector.at(jDt)->getDTSector() == sector && + tempVector.at(jDt)->getRejectionFlag() == false && + tempVector.at(jDt)->getDTCode() <= 7 ) + { + tempVector.at(jDt)->setRejectionFlag(true); + } + } + } + } /// End L II track rejection + + /// Collect MB1 and MB2 DTMatch at same bx in same sector and compare phi, phib + for ( unsigned int iDt = 0; iDt < theDTMatchContainer->at(1).size(); iDt++ ) + { + /// Loop over station == 1 + DTMatch* mb1Match = theDTMatchContainer->at(1).at(iDt); + + if ( mb1Match->getDTStation() != 1 ) + { + exit(0); + } + + if ( mb1Match->getRejectionFlag() == false ) + { + /// Record MB1 track sector and bx + int bx1 = mb1Match->getDTBX(); + int sector1 = mb1Match->getDTSector(); + + /// Get quantities to compare + int phi1 = mb1Match->getPredStubPhi(testLayer); + int theta1 = mb1Match->getPredStubTheta(testLayer); + float phib1 = static_cast< float >( mb1Match->getDTTSPhiB() ); + + /// Needing a small correction in phi predicted (extrapolation precision?) + /// Correction in phib due to field between ST1 and ST2 + int dphicor = static_cast< int >( -0.0097 * phib1 * phib1 + 1.0769 * phib1 + 4.2324 ); + int dphibcor = static_cast< int >( 0.3442 * phib1 ); + + /// Tolerances parameterization + int sigmaPhi =static_cast< int >( 0.006 * phib1 * phib1 + 0.4821 * phib1 + 37.64 ); + int sigmaPhib =static_cast< int >( 0.0005 * phib1 * phib1 + 0.01211 * phib1 + 3.4125 ); + int sigmaTheta = 100; + + /// Find tracks in MB2: SAME sector SAME bx + for ( unsigned int jDt = 0; jDt < theDTMatchContainer->at(2).size(); jDt++ ) + { + /// Loop over station == 2 + DTMatch* mb2Match = theDTMatchContainer->at(2).at(jDt); + + if ( mb2Match->getDTStation() != 2 ) + { + exit(0); + } + + if ( mb2Match->getRejectionFlag() == false && + mb2Match->getDTBX() == bx1 && + mb2Match->getDTSector() == sector1 ) + { + /// Get quantities to compare + int phi2 = mb2Match->getPredStubPhi(testLayer); + int theta2 = mb2Match->getPredStubTheta(testLayer); + float phib2 = static_cast< float >( mb2Match->getDTTSPhiB() ); + + int dphi = abs( phi1 - phi2 ) - dphicor; + int dtheta = abs( theta1 - theta2 ); + int dphib = static_cast< int >(fabs( phib1 - phib2 )) - dphibcor; + + /// Remove redundant DTMatch + /// For the moment keep the one with higher quality + /// Remove if inside all tolerances + if ( dphi < (numSigmaCut*sigmaPhi) && + dphib < (numSigmaCut*sigmaPhib) && + dtheta < (numSigmaCut*sigmaTheta) ) + { + if( mb2Match->getDTCode() <= mb1Match->getDTCode() ) + { + mb2Match->setRejectionFlag(true); + } + else + { + mb1Match->setRejectionFlag(true); + } + } + } + } /// End MB2 loop + } + } /// End MB1 loop + + return; +} + diff --git a/L1Trigger/DTPlusTrackTrigger/test/.__afs3C91 b/L1Trigger/DTPlusTrackTrigger/test/.__afs3C91 new file mode 100644 index 0000000000000..0a33c6dd606de --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/.__afs3C91 @@ -0,0 +1,1593 @@ +crab: Version 2.10.5_patch1 running on Thu May 15 12:02:32 2014 CET (10:02:32 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +Your identity: /DC=ch/DC=cern/OU=Organic Units/OU=Users/CN=pozzo/CN=680448/CN=Nicola Pozzobon +Creating temporary proxy Done +Contacting voms.cern.ch:15002 [/DC=ch/DC=cern/OU=computers/CN=voms.cern.ch] "cms" Done +Creating proxy Done +Your proxy is valid until Fri May 23 12:03:30 2014 +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_t2ny73 + Your task name is: pozzo_WorkingDir_t2ny73 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:03:37 2014 CET (10:03:37 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_w9jo78 + Your task name is: pozzo_WorkingDir_w9jo78 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:03:39 2014 CET (10:03:39 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-6,8-10,7 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9nl24k + Your task name is: pozzo_WorkingDir_9nl24k + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:03:42 2014 CET (10:03:42 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 N Running SubSuccess t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-6,8-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 7 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-6,8-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_95a0ek + Your task name is: pozzo_WorkingDir_95a0ek + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:03:55 2014 CET (10:03:55 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 2-10,1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_71tu8d + Your task name is: pozzo_WorkingDir_71tu8d + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:03:58 2014 CET (10:03:58 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_af61g7 + Your task name is: pozzo_WorkingDir_af61g7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:01 2014 CET (10:04:01 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3p7g6y + Your task name is: pozzo_WorkingDir_3p7g6y + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:05 2014 CET (10:04:05 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_v34uo5 + Your task name is: pozzo_WorkingDir_v34uo5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:10 2014 CET (10:04:10 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_h305rm + Your task name is: pozzo_WorkingDir_h305rm + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:22 2014 CET (10:04:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_px2h48 + Your task name is: pozzo_WorkingDir_px2h48 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:25 2014 CET (10:04:25 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7ju49x + Your task name is: pozzo_WorkingDir_7ju49x + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:29 2014 CET (10:04:29 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 N Running SubSuccess t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-8,10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 9 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-8,10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_5y3p4t + Your task name is: pozzo_WorkingDir_5y3p4t + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:43 2014 CET (10:04:43 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_wfk024 + Your task name is: pozzo_WorkingDir_wfk024 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:47 2014 CET (10:04:47 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_cv5s14 + Your task name is: pozzo_WorkingDir_cv5s14 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:04:50 2014 CET (10:04:50 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7no98w + Your task name is: pozzo_WorkingDir_7no98w + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:05:00 2014 CET (10:05:00 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 2-10,1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_dl38f9 + Your task name is: pozzo_WorkingDir_dl38f9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:05:06 2014 CET (10:05:06 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_h65ex0 + Your task name is: pozzo_WorkingDir_h65ex0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:05:14 2014 CET (10:05:14 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_17si8p + Your task name is: pozzo_WorkingDir_17si8p + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:05:16 2014 CET (10:05:16 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_njo416 + Your task name is: pozzo_WorkingDir_njo416 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:05:19 2014 CET (10:05:19 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 N Running SubSuccess t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-4,6-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 5 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-4,6-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_hl53d9 + Your task name is: pozzo_WorkingDir_hl53d9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:05:29 2014 CET (10:05:29 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9d57tz + Your task name is: pozzo_WorkingDir_9d57tz + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:12 2014 CET (10:06:12 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_fd6t21 + Your task name is: pozzo_WorkingDir_fd6t21 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:15 2014 CET (10:06:15 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3j92oi + Your task name is: pozzo_WorkingDir_3j92oi + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:17 2014 CET (10:06:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms20.cern.ch +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 N Running SubSuccess t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-5,7-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 6 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-5,7-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_86tg5e + Your task name is: pozzo_WorkingDir_86tg5e + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:27 2014 CET (10:06:27 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_a7g94m + Your task name is: pozzo_WorkingDir_a7g94m + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:29 2014 CET (10:06:29 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_m5np79 + Your task name is: pozzo_WorkingDir_m5np79 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:32 2014 CET (10:06:32 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_ac8u17 + Your task name is: pozzo_WorkingDir_ac8u17 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:35 2014 CET (10:06:35 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 N Running SubSuccess t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-6,8-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 7 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-6,8-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2f58wh + Your task name is: pozzo_WorkingDir_2f58wh + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:45 2014 CET (10:06:45 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_k493mj + Your task name is: pozzo_WorkingDir_k493mj + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:48 2014 CET (10:06:48 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_0ljs62 + Your task name is: pozzo_WorkingDir_0ljs62 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:50 2014 CET (10:06:50 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_b3m1u8 + Your task name is: pozzo_WorkingDir_b3m1u8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:53 2014 CET (10:06:53 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_32zbi9 + Your task name is: pozzo_WorkingDir_32zbi9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:55 2014 CET (10:06:55 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_807ygr + Your task name is: pozzo_WorkingDir_807ygr + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:06:59 2014 CET (10:06:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_93d2jz + Your task name is: pozzo_WorkingDir_93d2jz + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:02 2014 CET (10:07:02 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_ev501l + Your task name is: pozzo_WorkingDir_ev501l + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:05 2014 CET (10:07:05 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 N Running SubSuccess t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-8,10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 9 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-8,10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_0c1gp4 + Your task name is: pozzo_WorkingDir_0c1gp4 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:09 2014 CET (10:07:09 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_yi829h + Your task name is: pozzo_WorkingDir_yi829h + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:12 2014 CET (10:07:12 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7r05qp + Your task name is: pozzo_WorkingDir_7r05qp + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:18 2014 CET (10:07:18 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1a54gm + Your task name is: pozzo_WorkingDir_1a54gm + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:22 2014 CET (10:07:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_41ea5d + Your task name is: pozzo_WorkingDir_41ea5d + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:25 2014 CET (10:07:25 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_f40a1b + Your task name is: pozzo_WorkingDir_f40a1b + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:28 2014 CET (10:07:28 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_6f74sb + Your task name is: pozzo_WorkingDir_6f74sb + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:31 2014 CET (10:07:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7my39f + Your task name is: pozzo_WorkingDir_7my39f + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 15 12:07:33 2014 CET (10:07:33 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 N Running SubSuccess t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-4,6-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 5 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-4,6-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1m0hu5 + Your task name is: pozzo_WorkingDir_1m0hu5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log + diff --git a/L1Trigger/DTPlusTrackTrigger/test/.__afs4B1 b/L1Trigger/DTPlusTrackTrigger/test/.__afs4B1 new file mode 100644 index 0000000000000..ef788f33f2f40 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/.__afs4B1 @@ -0,0 +1,906 @@ +crab: Version 2.10.5_patch1 running on Mon May 5 18:10:13 2014 CET (16:10:13 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +Your identity: /DC=ch/DC=cern/OU=Organic Units/OU=Users/CN=pozzo/CN=680448/CN=Nicola Pozzobon +Creating temporary proxy Done +Contacting voms.cern.ch:15002 [/DC=ch/DC=cern/OU=computers/CN=voms.cern.ch] "cms" Done +Creating proxy Done +Your proxy is valid until Tue May 13 18:10:35 2014 +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_8h5tl0 + Your task name is: pozzo_WorkingDir_8h5tl0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:10:45 2014 CET (16:10:45 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_4wo21m + Your task name is: pozzo_WorkingDir_4wo21m + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:10:53 2014 CET (16:10:53 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1n74kg + Your task name is: pozzo_WorkingDir_1n74kg + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:02 2014 CET (16:11:02 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_4vb0r7 + Your task name is: pozzo_WorkingDir_4vb0r7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:07 2014 CET (16:11:07 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_8y71gb + Your task name is: pozzo_WorkingDir_8y71gb + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:12 2014 CET (16:11:12 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_t0m2z6 + Your task name is: pozzo_WorkingDir_t0m2z6 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:17 2014 CET (16:11:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_538pxl + Your task name is: pozzo_WorkingDir_538pxl + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:23 2014 CET (16:11:23 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_yf794g + Your task name is: pozzo_WorkingDir_yf794g + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:28 2014 CET (16:11:28 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2c5lu8 + Your task name is: pozzo_WorkingDir_2c5lu8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:33 2014 CET (16:11:33 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_45_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_zs219e + Your task name is: pozzo_WorkingDir_zs219e + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_45_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:38 2014 CET (16:11:38 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_4_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3w49zv + Your task name is: pozzo_WorkingDir_3w49zv + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_4_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:43 2014 CET (16:11:43 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_50_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_dv12t8 + Your task name is: pozzo_WorkingDir_dv12t8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_50_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:48 2014 CET (16:11:48 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_5_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_0jxe53 + Your task name is: pozzo_WorkingDir_0jxe53 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_5_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:11:53 2014 CET (16:11:53 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_60_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1u8z2k + Your task name is: pozzo_WorkingDir_1u8z2k + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_60_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:02 2014 CET (16:12:02 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_6_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_v79yu4 + Your task name is: pozzo_WorkingDir_v79yu4 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_6_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:07 2014 CET (16:12:07 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_70_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_8pb16a + Your task name is: pozzo_WorkingDir_8pb16a + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_70_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:12 2014 CET (16:12:12 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_7_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_18m2lg + Your task name is: pozzo_WorkingDir_18m2lg + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_7_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:17 2014 CET (16:12:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_80_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_km3j62 + Your task name is: pozzo_WorkingDir_km3j62 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_80_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:22 2014 CET (16:12:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_8_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_308pcq + Your task name is: pozzo_WorkingDir_308pcq + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_8_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:25 2014 CET (16:12:25 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_90_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_37s9fp + Your task name is: pozzo_WorkingDir_37s9fp + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_90_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:30 2014 CET (16:12:30 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_100_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_m5s0c3 + Your task name is: pozzo_WorkingDir_m5s0c3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_100_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:36 2014 CET (16:12:36 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_10_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_50vjk8 + Your task name is: pozzo_WorkingDir_50vjk8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_10_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:39 2014 CET (16:12:39 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_120_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_172cnz + Your task name is: pozzo_WorkingDir_172cnz + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_120_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:45 2014 CET (16:12:45 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_12_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_5w71tg + Your task name is: pozzo_WorkingDir_5w71tg + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_12_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:49 2014 CET (16:12:49 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_310wve + Your task name is: pozzo_WorkingDir_310wve + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:54 2014 CET (16:12:54 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_463lqb + Your task name is: pozzo_WorkingDir_463lqb + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:12:59 2014 CET (16:12:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_q845wv + Your task name is: pozzo_WorkingDir_q845wv + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:13:04 2014 CET (16:13:04 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_26jy5s + Your task name is: pozzo_WorkingDir_26jy5s + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:13:08 2014 CET (16:13:08 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_u982ir + Your task name is: pozzo_WorkingDir_u982ir + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:13:13 2014 CET (16:13:13 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_a196di + Your task name is: pozzo_WorkingDir_a196di + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:13:18 2014 CET (16:13:18 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_4gp5s3 + Your task name is: pozzo_WorkingDir_4gp5s3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:13:22 2014 CET (16:13:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_21szo8 + Your task name is: pozzo_WorkingDir_21szo8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Mon May 5 18:13:25 2014 CET (16:13:25 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7nfh31 + Your task name is: pozzo_WorkingDir_7nfh31 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log + diff --git a/L1Trigger/DTPlusTrackTrigger/test/.__afs72E4 b/L1Trigger/DTPlusTrackTrigger/test/.__afs72E4 new file mode 100644 index 0000000000000..31b0b3331d20f --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/.__afs72E4 @@ -0,0 +1,1710 @@ +crab: Version 2.10.5_patch1 running on Fri May 16 08:52:58 2014 CET (06:52:58 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_t2ny73 + Your task name is: pozzo_WorkingDir_t2ny73 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:01 2014 CET (06:53:01 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_w9jo78 + Your task name is: pozzo_WorkingDir_w9jo78 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:03 2014 CET (06:53:03 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-6,8-10,7 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9nl24k + Your task name is: pozzo_WorkingDir_9nl24k + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:06 2014 CET (06:53:06 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 N Running SubSuccess t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-4,6-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 5 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-4,6-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_158hvs + Your task name is: pozzo_WorkingDir_158hvs + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:10 2014 CET (06:53:10 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 2-10,1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_71tu8d + Your task name is: pozzo_WorkingDir_71tu8d + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:12 2014 CET (06:53:12 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_af61g7 + Your task name is: pozzo_WorkingDir_af61g7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:14 2014 CET (06:53:14 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3p7g6y + Your task name is: pozzo_WorkingDir_3p7g6y + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:17 2014 CET (06:53:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_v34uo5 + Your task name is: pozzo_WorkingDir_v34uo5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:19 2014 CET (06:53:19 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_h305rm + Your task name is: pozzo_WorkingDir_h305rm + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:21 2014 CET (06:53:21 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_px2h48 + Your task name is: pozzo_WorkingDir_px2h48 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:24 2014 CET (06:53:24 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7ju49x + Your task name is: pozzo_WorkingDir_7ju49x + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:26 2014 CET (06:53:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 N Running SubSuccess t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 8 Jobs with Wrapper Exit Code : 0 + List of jobs: 1,3-9 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 2 Jobs Running + List of jobs Running: 2,10 + >>>>>>>>> 8 Jobs Retrieved + List of jobs Retrieved: 1,3-9 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_vp8j42 + Your task name is: pozzo_WorkingDir_vp8j42 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:31 2014 CET (06:53:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_wfk024 + Your task name is: pozzo_WorkingDir_wfk024 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:33 2014 CET (06:53:33 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_cv5s14 + Your task name is: pozzo_WorkingDir_cv5s14 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:35 2014 CET (06:53:35 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7no98w + Your task name is: pozzo_WorkingDir_7no98w + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:37 2014 CET (06:53:37 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 2-10,1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_dl38f9 + Your task name is: pozzo_WorkingDir_dl38f9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:40 2014 CET (06:53:40 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_h65ex0 + Your task name is: pozzo_WorkingDir_h65ex0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:42 2014 CET (06:53:42 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_17si8p + Your task name is: pozzo_WorkingDir_17si8p + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:44 2014 CET (06:53:44 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_njo416 + Your task name is: pozzo_WorkingDir_njo416 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:46 2014 CET (06:53:46 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-9 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 10 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-9 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_8k0f5p + Your task name is: pozzo_WorkingDir_8k0f5p + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:50 2014 CET (06:53:50 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9d57tz + Your task name is: pozzo_WorkingDir_9d57tz + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:53 2014 CET (06:53:53 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_fd6t21 + Your task name is: pozzo_WorkingDir_fd6t21 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:55 2014 CET (06:53:55 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3j92oi + Your task name is: pozzo_WorkingDir_3j92oi + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:53:57 2014 CET (06:53:57 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_os8e16 + Your task name is: pozzo_WorkingDir_os8e16 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:00 2014 CET (06:54:00 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_a7g94m + Your task name is: pozzo_WorkingDir_a7g94m + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:02 2014 CET (06:54:02 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_m5np79 + Your task name is: pozzo_WorkingDir_m5np79 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:04 2014 CET (06:54:04 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_ac8u17 + Your task name is: pozzo_WorkingDir_ac8u17 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:07 2014 CET (06:54:07 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 N Running SubSuccess t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-4,6-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 5 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-4,6-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_23qf0c + Your task name is: pozzo_WorkingDir_23qf0c + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:11 2014 CET (06:54:11 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_k493mj + Your task name is: pozzo_WorkingDir_k493mj + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:13 2014 CET (06:54:13 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_0ljs62 + Your task name is: pozzo_WorkingDir_0ljs62 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:15 2014 CET (06:54:15 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_b3m1u8 + Your task name is: pozzo_WorkingDir_b3m1u8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:18 2014 CET (06:54:18 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_32zbi9 + Your task name is: pozzo_WorkingDir_32zbi9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:20 2014 CET (06:54:20 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_807ygr + Your task name is: pozzo_WorkingDir_807ygr + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:22 2014 CET (06:54:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_93d2jz + Your task name is: pozzo_WorkingDir_93d2jz + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:24 2014 CET (06:54:24 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_ev501l + Your task name is: pozzo_WorkingDir_ev501l + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:26 2014 CET (06:54:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 N Running SubSuccess t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 8 Jobs with Wrapper Exit Code : 0 + List of jobs: 1,3-9 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 2 Jobs Running + List of jobs Running: 2,10 + >>>>>>>>> 8 Jobs Retrieved + List of jobs Retrieved: 1,3-9 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_l93i0m + Your task name is: pozzo_WorkingDir_l93i0m + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:31 2014 CET (06:54:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_yi829h + Your task name is: pozzo_WorkingDir_yi829h + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:33 2014 CET (06:54:33 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7r05qp + Your task name is: pozzo_WorkingDir_7r05qp + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:35 2014 CET (06:54:35 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1a54gm + Your task name is: pozzo_WorkingDir_1a54gm + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:37 2014 CET (06:54:37 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_41ea5d + Your task name is: pozzo_WorkingDir_41ea5d + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:40 2014 CET (06:54:40 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_f40a1b + Your task name is: pozzo_WorkingDir_f40a1b + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:42 2014 CET (06:54:42 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_6f74sb + Your task name is: pozzo_WorkingDir_6f74sb + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:44 2014 CET (06:54:44 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7my39f + Your task name is: pozzo_WorkingDir_7my39f + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:46 2014 CET (06:54:46 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-9 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 10 + >>>>>>>>> 9 Jobs Retrieved + List of jobs Retrieved: 1-9 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_wz53h8 + Your task name is: pozzo_WorkingDir_wz53h8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:49 2014 CET (06:54:49 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_23oyr0 + Your task name is: pozzo_WorkingDir_23oyr0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:51 2014 CET (06:54:51 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-01.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2ax3t6 + Your task name is: pozzo_WorkingDir_2ax3t6 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:54 2014 CET (06:54:54 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_95ec2q + Your task name is: pozzo_WorkingDir_95ec2q + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Fri May 16 08:54:56 2014 CET (06:54:56 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +2 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +3 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +4 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +5 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +6 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +7 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +8 Y Retrieved Cleared 0 0 t2-ce-02.lnl.infn.it +9 Y Retrieved Cleared 0 0 t2-ce-06.lnl.infn.it +10 Y Retrieved Cleared 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_8v0kd6 + Your task name is: pozzo_WorkingDir_8v0kd6 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log diff --git a/L1Trigger/DTPlusTrackTrigger/test/.__afs7891 b/L1Trigger/DTPlusTrackTrigger/test/.__afs7891 new file mode 100644 index 0000000000000..c8660dd610ac4 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/.__afs7891 @@ -0,0 +1,1661 @@ +crab: Version 2.10.5_patch1 running on Wed May 14 21:35:07 2014 CET (19:35:07 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Aborted Aborted 50669 t2-ce-03.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 50669 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 2-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_71tu8d + Your task name is: pozzo_WorkingDir_71tu8d + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:35:25 2014 CET (19:35:25 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_af61g7 + Your task name is: pozzo_WorkingDir_af61g7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:35:35 2014 CET (19:35:35 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3p7g6y + Your task name is: pozzo_WorkingDir_3p7g6y + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:35:40 2014 CET (19:35:40 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_v34uo5 + Your task name is: pozzo_WorkingDir_v34uo5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:35:45 2014 CET (19:35:45 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_h305rm + Your task name is: pozzo_WorkingDir_h305rm + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:35:54 2014 CET (19:35:54 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 2-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 2-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_px2h48 + Your task name is: pozzo_WorkingDir_px2h48 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:35:59 2014 CET (19:35:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms20.cern.ch +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7ju49x + Your task name is: pozzo_WorkingDir_7ju49x + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:08 2014 CET (19:36:08 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +9 N Running SubSuccess t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-8,10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 9 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-8,10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_5y3p4t + Your task name is: pozzo_WorkingDir_5y3p4t + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:13 2014 CET (19:36:13 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_wfk024 + Your task name is: pozzo_WorkingDir_wfk024 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:18 2014 CET (19:36:18 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_cv5s14 + Your task name is: pozzo_WorkingDir_cv5s14 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:23 2014 CET (19:36:23 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7no98w + Your task name is: pozzo_WorkingDir_7no98w + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:28 2014 CET (19:36:28 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 50669 t2-ce-03.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 50669 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 2-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_dl38f9 + Your task name is: pozzo_WorkingDir_dl38f9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:33 2014 CET (19:36:33 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Running SubSuccess t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-9 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 10 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-9 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_h65ex0 + Your task name is: pozzo_WorkingDir_h65ex0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:42 2014 CET (19:36:42 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Running SubSuccess t2-ce-04.lnl.infn.it +5 N Running SubSuccess t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 N Running SubSuccess t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 7 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-3,6-9 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 3 Jobs Running + List of jobs Running: 4-5,10 + >>>>>>>>> 7 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-3,6-9 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_17si8p + Your task name is: pozzo_WorkingDir_17si8p + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:45 2014 CET (19:36:45 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_njo416 + Your task name is: pozzo_WorkingDir_njo416 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:49 2014 CET (19:36:49 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +5 N Running SubSuccess t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-4,6-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 5 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-4,6-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_hl53d9 + Your task name is: pozzo_WorkingDir_hl53d9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:36:55 2014 CET (19:36:55 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9d57tz + Your task name is: pozzo_WorkingDir_9d57tz + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:00 2014 CET (19:37:00 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_fd6t21 + Your task name is: pozzo_WorkingDir_fd6t21 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:05 2014 CET (19:37:05 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3j92oi + Your task name is: pozzo_WorkingDir_3j92oi + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:10 2014 CET (19:37:10 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms20.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 N Running SubSuccess t2-ce-04.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-5,7-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 6 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-5,7-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_86tg5e + Your task name is: pozzo_WorkingDir_86tg5e + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:14 2014 CET (19:37:14 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_a7g94m + Your task name is: pozzo_WorkingDir_a7g94m + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:19 2014 CET (19:37:19 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_m5np79 + Your task name is: pozzo_WorkingDir_m5np79 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:22 2014 CET (19:37:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +2 N Running SubSuccess t2-ce-03.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1,3-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 2 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1,3-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_ac8u17 + Your task name is: pozzo_WorkingDir_ac8u17 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:26 2014 CET (19:37:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Running SubSuccess t2-ce-03.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-6,8-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 7 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-6,8-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2f58wh + Your task name is: pozzo_WorkingDir_2f58wh + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:31 2014 CET (19:37:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_k493mj + Your task name is: pozzo_WorkingDir_k493mj + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:34 2014 CET (19:37:34 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_0ljs62 + Your task name is: pozzo_WorkingDir_0ljs62 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:37 2014 CET (19:37:37 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_b3m1u8 + Your task name is: pozzo_WorkingDir_b3m1u8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:41 2014 CET (19:37:41 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_32zbi9 + Your task name is: pozzo_WorkingDir_32zbi9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:46 2014 CET (19:37:46 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_807ygr + Your task name is: pozzo_WorkingDir_807ygr + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:51 2014 CET (19:37:51 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Running SubSuccess t2-ce-01.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Running SubSuccess t2-ce-04.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 8 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-2,4-6,8-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 2 Jobs Running + List of jobs Running: 3,7 + >>>>>>>>> 8 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-2,4-6,8-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_93d2jz + Your task name is: pozzo_WorkingDir_93d2jz + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:54 2014 CET (19:37:54 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_ev501l + Your task name is: pozzo_WorkingDir_ev501l + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:37:59 2014 CET (19:37:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Running SubSuccess t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-8,10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 9 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-8,10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_0c1gp4 + Your task name is: pozzo_WorkingDir_0c1gp4 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:03 2014 CET (19:38:03 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_yi829h + Your task name is: pozzo_WorkingDir_yi829h + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:07 2014 CET (19:38:07 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7r05qp + Your task name is: pozzo_WorkingDir_7r05qp + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:13 2014 CET (19:38:13 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1a54gm + Your task name is: pozzo_WorkingDir_1a54gm + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:17 2014 CET (19:38:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_41ea5d + Your task name is: pozzo_WorkingDir_41ea5d + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:23 2014 CET (19:38:23 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_f40a1b + Your task name is: pozzo_WorkingDir_f40a1b + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:26 2014 CET (19:38:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_6f74sb + Your task name is: pozzo_WorkingDir_6f74sb + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:31 2014 CET (19:38:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7my39f + Your task name is: pozzo_WorkingDir_7my39f + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:36 2014 CET (19:38:36 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 N Running SubSuccess t2-ce-01.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-4,6-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 5 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-4,6-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1m0hu5 + Your task name is: pozzo_WorkingDir_1m0hu5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:41 2014 CET (19:38:41 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_23oyr0 + Your task name is: pozzo_WorkingDir_23oyr0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:44 2014 CET (19:38:44 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Running SubSuccess t2-ce-03.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-2,4-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 3 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-2,4-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2ax3t6 + Your task name is: pozzo_WorkingDir_2ax3t6 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:49 2014 CET (19:38:49 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Created Created +2 N Created Created +3 N Created Created +4 N Created Created +5 N Created Created +6 N Created Created +7 N Created Created +8 N Created Created +9 N Created Created +10 N Created Created + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Created + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_95ec2q + Your task name is: pozzo_WorkingDir_95ec2q + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Wed May 14 21:38:51 2014 CET (19:38:51 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +3 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +6 N Running SubSuccess t2-ce-01.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 9 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-5,7-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 6 + >>>>>>>>> 9 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-5,7-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1or84q + Your task name is: pozzo_WorkingDir_1or84q + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log diff --git a/L1Trigger/DTPlusTrackTrigger/test/.__afsA51D b/L1Trigger/DTPlusTrackTrigger/test/.__afsA51D new file mode 100644 index 0000000000000..df11758837c70 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/.__afsA51D @@ -0,0 +1,1638 @@ +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:23 2014 CET (18:20:23 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_xd70g1 + Your task name is: pozzo_WorkingDir_xd70g1 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:28 2014 CET (18:20:28 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms20.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 N Running SubSuccess t2-ce-06.lnl.infn.it +3 N Running SubSuccess t2-ce-04.lnl.infn.it +4 N Running SubSuccess t2-ce-06.lnl.infn.it +5 N Running SubSuccess t2-ce-06.lnl.infn.it +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 5 Jobs Submitted + List of jobs Submitted: 6-10 + >>>>>>>>> 4 Jobs Running + List of jobs Running: 2-5 + >>>>>>>>> 1 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_x1z50c + Your task name is: pozzo_WorkingDir_x1z50c + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:31 2014 CET (18:20:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_gta680 + Your task name is: pozzo_WorkingDir_gta680 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:35 2014 CET (18:20:35 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_c6d0q2 + Your task name is: pozzo_WorkingDir_c6d0q2 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:39 2014 CET (18:20:39 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_8k6si9 + Your task name is: pozzo_WorkingDir_8k6si9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:43 2014 CET (18:20:43 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_84avx0 + Your task name is: pozzo_WorkingDir_84avx0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:47 2014 CET (18:20:47 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9o3cs4 + Your task name is: pozzo_WorkingDir_9o3cs4 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:52 2014 CET (18:20:52 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_6yw21c + Your task name is: pozzo_WorkingDir_6yw21c + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:55 2014 CET (18:20:55 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_94e7fp + Your task name is: pozzo_WorkingDir_94e7fp + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:20:59 2014 CET (18:20:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_gy04k8 + Your task name is: pozzo_WorkingDir_gy04k8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:03 2014 CET (18:21:03 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_e58qm1 + Your task name is: pozzo_WorkingDir_e58qm1 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:08 2014 CET (18:21:08 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms20.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_yt9k67 + Your task name is: pozzo_WorkingDir_yt9k67 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:11 2014 CET (18:21:11 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_n64a7h + Your task name is: pozzo_WorkingDir_n64a7h + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:16 2014 CET (18:21:16 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_0cis54 + Your task name is: pozzo_WorkingDir_0cis54 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:20 2014 CET (18:21:20 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_r09io3 + Your task name is: pozzo_WorkingDir_r09io3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:24 2014 CET (18:21:24 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_k913fr + Your task name is: pozzo_WorkingDir_k913fr + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:27 2014 CET (18:21:27 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_948jzb + Your task name is: pozzo_WorkingDir_948jzb + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:31 2014 CET (18:21:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_yo35t7 + Your task name is: pozzo_WorkingDir_yo35t7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:34 2014 CET (18:21:34 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_jg17k6 + Your task name is: pozzo_WorkingDir_jg17k6 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:37 2014 CET (18:21:37 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_w4r7p0 + Your task name is: pozzo_WorkingDir_w4r7p0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:42 2014 CET (18:21:42 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_k8a49z + Your task name is: pozzo_WorkingDir_k8a49z + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:46 2014 CET (18:21:46 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2apz96 + Your task name is: pozzo_WorkingDir_2apz96 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:50 2014 CET (18:21:50 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1c0r6a + Your task name is: pozzo_WorkingDir_1c0r6a + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:55 2014 CET (18:21:55 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_p2ru48 + Your task name is: pozzo_WorkingDir_p2ru48 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_NegMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:21:59 2014 CET (18:21:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_83v5bl + Your task name is: pozzo_WorkingDir_83v5bl + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_100_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:03 2014 CET (18:22:03 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9p1dk3 + Your task name is: pozzo_WorkingDir_9p1dk3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_10_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:06 2014 CET (18:22:06 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_28s6pw + Your task name is: pozzo_WorkingDir_28s6pw + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_120_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:10 2014 CET (18:22:10 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3mr1f2 + Your task name is: pozzo_WorkingDir_3mr1f2 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_12_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:13 2014 CET (18:22:13 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1gkj29 + Your task name is: pozzo_WorkingDir_1gkj29 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_140_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:17 2014 CET (18:22:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it +2 N Running SubSuccess t2-ce-02.lnl.infn.it +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 8 Jobs Submitted + List of jobs Submitted: 3-10 + >>>>>>>>> 2 Jobs Running + List of jobs Running: 1-2 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_j5m9t3 + Your task name is: pozzo_WorkingDir_j5m9t3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_14_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:22 2014 CET (18:22:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_jo0z26 + Your task name is: pozzo_WorkingDir_jo0z26 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_16_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:26 2014 CET (18:22:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_h6g8m3 + Your task name is: pozzo_WorkingDir_h6g8m3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_18_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:30 2014 CET (18:22:30 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_32t0qr + Your task name is: pozzo_WorkingDir_32t0qr + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_20_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:34 2014 CET (18:22:34 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_1yv02q + Your task name is: pozzo_WorkingDir_1yv02q + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_25_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:38 2014 CET (18:22:38 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_5hdj72 + Your task name is: pozzo_WorkingDir_5hdj72 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_30_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:43 2014 CET (18:22:43 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_r2t51g + Your task name is: pozzo_WorkingDir_r2t51g + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_35_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:46 2014 CET (18:22:46 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_x437il + Your task name is: pozzo_WorkingDir_x437il + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_40_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:49 2014 CET (18:22:49 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9a7jv3 + Your task name is: pozzo_WorkingDir_9a7jv3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_45_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:53 2014 CET (18:22:53 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-01.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_p95qy7 + Your task name is: pozzo_WorkingDir_p95qy7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_4_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:56 2014 CET (18:22:56 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms20.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +8 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-06.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_pq65l8 + Your task name is: pozzo_WorkingDir_pq65l8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_50_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:22:59 2014 CET (18:22:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-03.lnl.infn.it +6 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +7 N Done Terminated 0 0 t2-ce-03.lnl.infn.it +8 N Running SubSuccess t2-ce-01.lnl.infn.it +9 N Running SubSuccess t2-ce-03.lnl.infn.it +10 N Submitted SubSuccess + +crab: ExitCodes Summary + >>>>>>>>> 7 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-7 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 1 Jobs Submitted + List of jobs Submitted: 10 + >>>>>>>>> 2 Jobs Running + List of jobs Running: 8-9 + >>>>>>>>> 7 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-7 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_elx076 + Your task name is: pozzo_WorkingDir_elx076 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_5_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:23:04 2014 CET (18:23:04 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_s5p6l3 + Your task name is: pozzo_WorkingDir_s5p6l3 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_60_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:23:09 2014 CET (18:23:09 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-02.lnl.infn.it +9 N Done Terminated 0 0 t2-ce-02.lnl.infn.it +10 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2z4xq9 + Your task name is: pozzo_WorkingDir_2z4xq9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_6_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:23:14 2014 CET (18:23:14 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_60hn8w + Your task name is: pozzo_WorkingDir_60hn8w + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_70_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:23:20 2014 CET (18:23:20 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +2 N Done Terminated 0 0 t2-ce-04.lnl.infn.it +3 N Running SubSuccess t2-ce-04.lnl.infn.it +4 N Done Terminated 0 0 t2-ce-01.lnl.infn.it +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: ExitCodes Summary + >>>>>>>>> 3 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-2,4 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + >>>>>>>>> 6 Jobs Submitted + List of jobs Submitted: 5-10 + >>>>>>>>> 1 Jobs Running + List of jobs Running: 3 + >>>>>>>>> 3 Jobs Done + Jobs terminated: retrieve them with: crab -getoutput + List of jobs: 1-2,4 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_84n9er + Your task name is: pozzo_WorkingDir_84n9er + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_7_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:23:24 2014 CET (18:23:24 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_378ezf + Your task name is: pozzo_WorkingDir_378ezf + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_80_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:23:28 2014 CET (18:23:28 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +2 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +3 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +4 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +5 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +6 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +7 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +8 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it +9 Y Done Terminated 0 0 t2-ce-04.lnl.infn.it +10 Y Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 10 Jobs with Wrapper Exit Code : 0 + List of jobs: 1-10 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 10 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_7t3po9 + Your task name is: pozzo_WorkingDir_7t3po9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_8_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Thu May 22 20:23:31 2014 CET (18:23:31 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess +2 N Submitted SubSuccess +3 N Submitted SubSuccess +4 N Submitted SubSuccess +5 N Submitted SubSuccess +6 N Submitted SubSuccess +7 N Submitted SubSuccess +8 N Submitted SubSuccess +9 N Submitted SubSuccess +10 N Submitted SubSuccess + +crab: 10 Total Jobs + >>>>>>>>> 10 Jobs Submitted + List of jobs Submitted: 1-10 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_ps53t2 + Your task name is: pozzo_WorkingDir_ps53t2 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC12/src/L1Trigger/DTPlusTrackTrigger/test/CRAB_PosMuPt_90_Extended2023TTI_500000_AnalyzerDTMatches/WorkingDir/log/crab.log diff --git a/L1Trigger/DTPlusTrackTrigger/test/.__afsBE86 b/L1Trigger/DTPlusTrackTrigger/test/.__afsBE86 new file mode 100644 index 0000000000000..1817999685b10 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/.__afsBE86 @@ -0,0 +1,1130 @@ +crab: Version 2.10.5_patch1 running on Tue May 6 18:27:42 2014 CET (16:27:42 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +Your identity: /DC=ch/DC=cern/OU=Organic Units/OU=Users/CN=pozzo/CN=680448/CN=Nicola Pozzobon +Creating temporary proxy Done +Contacting lcg-voms.cern.ch:15002 [/DC=ch/DC=cern/OU=computers/CN=lcg-voms.cern.ch] "cms" Done +Creating proxy Done +Your proxy is valid until Wed May 14 18:29:08 2014 +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9l16xi + Your task name is: pozzo_WorkingDir_9l16xi + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:18 2014 CET (16:29:18 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-06.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_gaw281 + Your task name is: pozzo_WorkingDir_gaw281 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:26 2014 CET (16:29:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_82av3y + Your task name is: pozzo_WorkingDir_82av3y + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:35 2014 CET (16:29:35 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_f3cz25 + Your task name is: pozzo_WorkingDir_f3cz25 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:39 2014 CET (16:29:39 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: Establishing gsissh ControlPath. Wait 2 sec ... +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_8c65wq + Your task name is: pozzo_WorkingDir_8c65wq + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:47 2014 CET (16:29:47 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Submitted SubSuccess + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Submitted + List of jobs Submitted: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_q0k29z + Your task name is: pozzo_WorkingDir_q0k29z + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:52 2014 CET (16:29:52 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_jmf531 + Your task name is: pozzo_WorkingDir_jmf531 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:56 2014 CET (16:29:56 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_90yi6j + Your task name is: pozzo_WorkingDir_90yi6j + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:29:59 2014 CET (16:29:59 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-03.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_46b7wo + Your task name is: pozzo_WorkingDir_46b7wo + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:05 2014 CET (16:30:05 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_45_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-06.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_j96nx5 + Your task name is: pozzo_WorkingDir_j96nx5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_45_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:09 2014 CET (16:30:09 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_4_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_5s8z2a + Your task name is: pozzo_WorkingDir_5s8z2a + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_4_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:14 2014 CET (16:30:14 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_50_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-06.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_2c98yq + Your task name is: pozzo_WorkingDir_2c98yq + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_50_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:18 2014 CET (16:30:18 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_5_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_r2p3t5 + Your task name is: pozzo_WorkingDir_r2p3t5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_5_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:22 2014 CET (16:30:22 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_60_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-06.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_f1pd49 + Your task name is: pozzo_WorkingDir_f1pd49 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_60_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:26 2014 CET (16:30:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_6_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_e0ha43 + Your task name is: pozzo_WorkingDir_e0ha43 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_6_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:30 2014 CET (16:30:30 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_70_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_84tc0i + Your task name is: pozzo_WorkingDir_84tc0i + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_70_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:35 2014 CET (16:30:35 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_7_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-06.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_6b0ks9 + Your task name is: pozzo_WorkingDir_6b0ks9 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_7_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:39 2014 CET (16:30:39 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_80_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_mb398i + Your task name is: pozzo_WorkingDir_mb398i + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_80_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:43 2014 CET (16:30:43 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_8_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_08da2e + Your task name is: pozzo_WorkingDir_08da2e + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_8_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:47 2014 CET (16:30:47 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_90_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_x9n4a8 + Your task name is: pozzo_WorkingDir_x9n4a8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_NegMuPt_90_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:51 2014 CET (16:30:51 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_100_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_f9m5w7 + Your task name is: pozzo_WorkingDir_f9m5w7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_100_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:30:56 2014 CET (16:30:56 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_10_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_6ahv58 + Your task name is: pozzo_WorkingDir_6ahv58 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_10_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:02 2014 CET (16:31:02 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_120_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_6u71sq + Your task name is: pozzo_WorkingDir_6u71sq + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_120_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:08 2014 CET (16:31:08 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_12_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_o19u2i + Your task name is: pozzo_WorkingDir_o19u2i + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_12_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:17 2014 CET (16:31:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_95hez0 + Your task name is: pozzo_WorkingDir_95hez0 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_140_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:26 2014 CET (16:31:26 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_g5xw46 + Your task name is: pozzo_WorkingDir_g5xw46 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_14_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:36 2014 CET (16:31:36 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-06.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_3qd29h + Your task name is: pozzo_WorkingDir_3qd29h + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_16_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:44 2014 CET (16:31:44 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_g14ma2 + Your task name is: pozzo_WorkingDir_g14ma2 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_18_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:51 2014 CET (16:31:51 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_nw86b5 + Your task name is: pozzo_WorkingDir_nw86b5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_20_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:31:56 2014 CET (16:31:56 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9d45sp + Your task name is: pozzo_WorkingDir_9d45sp + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_25_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:00 2014 CET (16:32:00 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_b3xw27 + Your task name is: pozzo_WorkingDir_b3xw27 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_30_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:03 2014 CET (16:32:03 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_v38o9p + Your task name is: pozzo_WorkingDir_v38o9p + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_35_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:07 2014 CET (16:32:07 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_p6q8e5 + Your task name is: pozzo_WorkingDir_p6q8e5 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_40_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:13 2014 CET (16:32:13 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_45_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_v738yd + Your task name is: pozzo_WorkingDir_v738yd + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_45_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:17 2014 CET (16:32:17 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_4_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 60302 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 60302 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_951cse + Your task name is: pozzo_WorkingDir_951cse + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_4_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:21 2014 CET (16:32:21 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_50_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-06.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_on073q + Your task name is: pozzo_WorkingDir_on073q + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_50_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:25 2014 CET (16:32:25 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_5_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-02.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_k15oq7 + Your task name is: pozzo_WorkingDir_k15oq7 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_5_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:29 2014 CET (16:32:29 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_60_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-4.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_r6f2d8 + Your task name is: pozzo_WorkingDir_r6f2d8 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_60_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:34 2014 CET (16:32:34 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_6_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host hcc-crabserver.unl.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-01.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_m150bx + Your task name is: pozzo_WorkingDir_m150bx + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_6_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:39 2014 CET (16:32:39 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_70_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_mrx581 + Your task name is: pozzo_WorkingDir_mrx581 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_70_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:44 2014 CET (16:32:44 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_7_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host vocms83.cern.ch +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Done Terminated 0 0 t2-ce-04.lnl.infn.it + +crab: ExitCodes Summary + >>>>>>>>> 1 Jobs with Wrapper Exit Code : 0 + List of jobs: 1 + See https://twiki.cern.ch/twiki/bin/view/CMS/JobExitCodes for Exit Code meaning + +crab: 1 Total Jobs + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_s83x6f + Your task name is: pozzo_WorkingDir_s83x6f + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_7_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:47 2014 CET (16:32:47 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_80_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-04.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_5ap7s1 + Your task name is: pozzo_WorkingDir_5ap7s1 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_80_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:51 2014 CET (16:32:51 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_8_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-01.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_9y4bs1 + Your task name is: pozzo_WorkingDir_9y4bs1 + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_8_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log +crab: Version 2.10.5_patch1 running on Tue May 6 18:32:55 2014 CET (16:32:55 UTC) + +crab. Working options: + scheduler remoteGlidein + job type CMSSW + server OFF + working directory /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_90_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/ + +crab: Checking the status of all jobs: please wait +crab: contacting remote host submit-6.t2.ucsd.edu +crab: +ID END STATUS ACTION ExeExitCode JobExitCode E_HOST +----- --- ----------------- ------------ ---------- ----------- --------- +1 N Running SubSuccess t2-ce-02.lnl.infn.it + +crab: 1 Total Jobs + >>>>>>>>> 1 Jobs Running + List of jobs Running: 1 + +crab: You can also follow the status of this task on : + CMS Dashboard: http://dashb-cms-job-task.cern.ch/taskmon.html#task=pozzo_WorkingDir_179qye + Your task name is: pozzo_WorkingDir_179qye + +Log file is /afs/cern.ch/work/p/pozzo/CMSSW_6_2_0_SLHC10/src/L1Trigger/DTTrackTriggerIntegration/test/CRAB_PosMuPt_90_Extended2023TTI_50000_AnalyzerDTTTIMatches/WorkingDir/log/crab.log diff --git a/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc new file mode 100644 index 0000000000000..ccb1bcbd164ea --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc @@ -0,0 +1,1637 @@ +//#define DEBUG + +/*! \brief Checklist + * \details DT to TK Matches for the HL-LHC + * + * \author Nicola Pozzobon + * \author Pierluigi Zotto + * \date 2014, Apr 1 + * + */ + +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/EDAnalyzer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/PluginManager/interface/ModuleDef.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" +#include "MagneticField/Engine/interface/MagneticField.h" + +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/Records/interface/MuonGeometryRecord.h" +#include "Geometry/DTGeometry/interface/DTGeometry.h" +#include "L1Trigger/DTUtilities/interface/DTTrigGeom.h" + +#include "DataFormats/MuonDetId/interface/DTChamberId.h" +#include "DataFormats/MuonDetId/interface/DTSuperLayerId.h" +#include "DataFormats/MuonDetId/interface/DTLayerId.h" +#include "DataFormats/MuonDetId/interface/DTWireId.h" +#include "DataFormats/DTDigi/interface/DTDigiCollection.h" +#include "SimDataFormats/DigiSimLinks/interface/DTDigiSimLinkCollection.h" + +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTBtiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSPhiTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTTSThetaTrigger.h" +#include "DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h" + +#include "SimTracker/TrackTriggerAssociation/interface/TTClusterAssociationMap.h" +#include "SimTracker/TrackTriggerAssociation/interface/TTStubAssociationMap.h" +#include "SimTracker/TrackTriggerAssociation/interface/TTTrackAssociationMap.h" +#include "SimDataFormats/TrackingAnalysis/interface/TrackingParticle.h" +#include "SimDataFormats/TrackingAnalysis/interface/TrackingVertex.h" + +#include "CommonTools/UtilAlgos/interface/TFileService.h" + +#include "Geometry/CommonTopologies/interface/Topology.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/CommonTopologies/interface/PixelTopology.h" + +#include +#include + +/// Class definition +class AnalyzerDTMatches : public edm::EDAnalyzer +{ + /// Public methods + public : + + /// Constructor/destructor + explicit AnalyzerDTMatches( const edm::ParameterSet& iConfig ); + virtual ~AnalyzerDTMatches(); + + // Typical methods used on Loops over events + virtual void beginJob(); + virtual void endJob(); + virtual void analyze( const edm::Event& iEvent, const edm::EventSetup& iSetup ); + + /// Private methods and variables + private : + bool useBothMuonCharges; + bool selectPositiveMuons; + + /// Histograms + /// identified by pair< wheel, MB > + /// each propagation goes into a vector< layer > where L0 gives the + /// projection to the vertex + std::map< std::pair< int, int >, TH1F* > mapWS_hPhiB_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hPhiB_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hPhiB_L; + + std::map< std::pair< int, int >, TH1F* > mapWS_hPhiG_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hPhiG_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hPhiG_L; + + std::map< std::pair< int, int >, TH1F* > mapWS_hPhi_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hPhi_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hPhi_L; + + std::map< std::pair< int, int >, TH1F* > mapWS_hTheta_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hTheta_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hTheta_L; + + std::map< std::pair< int, int >, TH1F* > mapWS_hTPPhi_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hTPPhi_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hTPPhi_L; + + std::map< std::pair< int, int >, TH1F* > mapWS_hTPTheta_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hTPTheta_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hTPTheta_L; + + std::map< std::pair< int, int >, TH1F* > mapWS_hDeltaPhi_TP_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hDeltaPhi_TP_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hDeltaPhi_TP_L; + + std::map< std::pair< int, int >, TH1F* > mapWS_hDeltaTheta_TP_C; + std::map< std::pair< int, int >, TH1F* > mapWS_hDeltaTheta_TP_H; + std::map< std::pair< int, int >, TH1F* > mapWS_hDeltaTheta_TP_L; + + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhi_TK_C; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhi_TK_H; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhi_TK_L; + + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaTheta_TK_C; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaTheta_TK_H; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaTheta_TK_L; + + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhiResid_TK_C; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhiResid_TK_H; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhiResid_TK_L; + + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaResid_TK_C; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaResid_TK_H; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaResid_TK_L; + + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhiPull_TK_C; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhiPull_TK_H; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaPhiPull_TK_L; + + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaPull_TK_C; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaPull_TK_H; + std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaPull_TK_L; + + TH1F* hMuonTP_Pt_DT; + TH1F* hMuonTP_Pt_DTTF; + TH1F* hMuonTP_Pt_DTMatch; + TH1F* hMuonTP_Pt_DTMatch_TTTrack; + TH1F* hMuonTP_Pt_DTMatch_Majority; + TH1F* hMuonTP_Pt_DTMatch_MixedMode; + TH1F* hMuonTP_Pt_DTMatch_MajorityFull; + TH1F* hMuonTP_Pt_DTMatch_Priority; + TH1F* hMuonTP_Pt_DTMatch_Average; + + TH1F* hMuonTP_PtBin_DT; + TH1F* hMuonTP_PtBin_DTTF; + TH1F* hMuonTP_PtBin_DTMatch; + TH1F* hMuonTP_PtBin_DTMatch_TTTrack; + TH1F* hMuonTP_PtBin_DTMatch_Majority; + TH1F* hMuonTP_PtBin_DTMatch_MixedMode; + TH1F* hMuonTP_PtBin_DTMatch_MajorityFull; + TH1F* hMuonTP_PtBin_DTMatch_Priority; + TH1F* hMuonTP_PtBin_DTMatch_Average; + + /// Containers of parameters passed by python + /// configuration file + edm::ParameterSet config; +}; + +/// Class implementation + +/// Constructor +AnalyzerDTMatches::AnalyzerDTMatches( edm::ParameterSet const& iConfig ) + : config(iConfig) +{ + /// Get from the parameter set + useBothMuonCharges = iConfig.getParameter< bool >("BothCharges"); + selectPositiveMuons = iConfig.getParameter< bool >("GetPositive"); +} + +/// Destructor +AnalyzerDTMatches::~AnalyzerDTMatches() +{ + /// Insert here what you need to delete + /// when you close the class instance +} + +/// End job +void AnalyzerDTMatches::endJob()//edm::Run& run, const edm::EventSetup& iSetup +{ + /// Things to be done at the exit of the event Loop + std::cerr << " AnalyzerDTMatches::endJob" << std::endl; + /// End of things to be done at the exit from the event Loop +} + +/// Begin job +void AnalyzerDTMatches::beginJob() +{ + /// Initialize all slave variables + /// mainly histogram ranges and resolution + std::ostringstream histoName; + std::ostringstream histoTitle; + + /// Things to be done before entering the event Loop + std::cerr << " AnalyzerDTMatches::beginJob" << std::endl; + + /// Book histograms etc + edm::Service< TFileService > fs; + + /// Prepare for DT Pt-bin way + int NumBins = 24; + double* BinVec = new double[NumBins+1]; + BinVec[0] = 0; + BinVec[1] = 4; + BinVec[2] = 5; + BinVec[3] = 6; + BinVec[4] = 7; + BinVec[5] = 8; + BinVec[6] = 10; + BinVec[7] = 12; + BinVec[8] = 14; + BinVec[9] = 16; + BinVec[10] = 18; + BinVec[11] = 20; + BinVec[12] = 25; + BinVec[13] = 30; + BinVec[14] = 35; + BinVec[15] = 40; + BinVec[16] = 45; + BinVec[17] = 50; + BinVec[18] = 60; + BinVec[19] = 70; + BinVec[20] = 80; + BinVec[21] = 90; + BinVec[22] = 100; + BinVec[23] = 120; + BinVec[24] = 140; + //BinVec[25] = 200; + +/* + /// Prepare for LogXY Plots + int NumBins = 200; + double MinPt = 0.0; + double MaxPt = 100.0; + + double* BinVec = new double[NumBins+1]; + for ( int iBin = 0; iBin < NumBins + 1; iBin++ ) + { + double temp = pow( 10, (- NumBins + iBin)/(MaxPt - MinPt) ); + BinVec[ iBin ] = temp; + } +*/ + + for ( int iWh = -2; iWh < 3; iWh++ ) + { + for ( int iSt = 1; iSt < 3; iSt++ ) + { + /// Prepare the key of the map + std::pair< int, int > thisKey = std::make_pair( iWh, iSt ); + + histoName.str(""); histoName << "hPhiB_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#phi_{B} in wheel " << iWh << " station " << iSt << ", correlated"; + mapWS_hPhiB_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 800, -400, 400 ); + mapWS_hPhiB_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhiB_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#phi_{B} in wheel " << iWh << " station " << iSt << ", H single"; + mapWS_hPhiB_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 800, -400, 400 ); + mapWS_hPhiB_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhiB_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#phi_{B} in wheel " << iWh << " station " << iSt << ", L single"; + mapWS_hPhiB_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 800, -400, 400 ); + mapWS_hPhiB_L[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhiG_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "CMS #phi in wheel " << iWh << " station " << iSt << ", correlated"; + mapWS_hPhiG_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hPhiG_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhiG_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "CMS #phi in wheel " << iWh << " station " << iSt << ", H single"; + mapWS_hPhiG_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hPhiG_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhiG_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "CMS #phi in wheel " << iWh << " station " << iSt << ", L single"; + mapWS_hPhiG_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hPhiG_L[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhi_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#phi in wheel " << iWh << " station " << iSt << ", correlated"; + mapWS_hPhi_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hPhi_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhi_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#phi in wheel " << iWh << " station " << iSt << ", H single"; + mapWS_hPhi_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hPhi_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hPhi_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#phi in wheel " << iWh << " station " << iSt << ", L single"; + mapWS_hPhi_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hPhi_L[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTheta_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#theta in wheel " << iWh << " station " << iSt << ", correlated"; + mapWS_hTheta_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 1300, 0, 13000 ); + mapWS_hTheta_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTheta_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#theta in wheel " << iWh << " station " << iSt << ", H single"; + mapWS_hTheta_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 1300, 0, 13000 ); + mapWS_hTheta_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTheta_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#theta in wheel " << iWh << " station " << iSt << ", L single"; + mapWS_hTheta_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 1300, 0, 13000 ); + mapWS_hTheta_L[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTPPhi_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "sim. muon #phi in wheel " << iWh << " station " << iSt << ", correlated"; + mapWS_hTPPhi_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hTPPhi_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTPPhi_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "sim. muon #phi in wheel " << iWh << " station " << iSt << ", H single"; + mapWS_hTPPhi_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hTPPhi_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTPPhi_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "sim. muon #phi in wheel " << iWh << " station " << iSt << ", L single"; + mapWS_hTPPhi_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 2600, 0, 26000 ); + mapWS_hTPPhi_L[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTPTheta_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "sim. muon #theta in wheel " << iWh << " station " << iSt << ", correlated"; + mapWS_hTPTheta_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 1300, 0, 13000 ); + mapWS_hTPTheta_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTPTheta_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "sim. muon #theta in wheel " << iWh << " station " << iSt << ", H single"; + mapWS_hTPTheta_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 1300, 0, 13000 ); + mapWS_hTPTheta_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hTPTheta_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "sim. muon #theta in wheel " << iWh << " station " << iSt << ", L single"; + mapWS_hTPTheta_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 1300, 0, 13000 ); + mapWS_hTPTheta_L[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhi_TP_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (wrt Sim) " << iWh << " station " << iSt << ", correlated"; + mapWS_hDeltaPhi_TP_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ); + mapWS_hDeltaPhi_TP_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhi_TP_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (wrt Sim) " << iWh << " station " << iSt << ", H single"; + mapWS_hDeltaPhi_TP_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ); + mapWS_hDeltaPhi_TP_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhi_TP_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (wrt Sim) " << iWh << " station " << iSt << ", L single"; + mapWS_hDeltaPhi_TP_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ); + mapWS_hDeltaPhi_TP_L[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hDeltaTheta_TP_C_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (wrt Sim) " << iWh << " station " << iSt << ", correlated"; + mapWS_hDeltaTheta_TP_C[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -2000, 2000 ); + mapWS_hDeltaTheta_TP_C[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hDeltaTheta_TP_H_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (wrt Sim) " << iWh << " station " << iSt << ", H single"; + mapWS_hDeltaTheta_TP_H[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -2000, 2000 ); + mapWS_hDeltaTheta_TP_H[thisKey]->Sumw2(); + + histoName.str(""); histoName << "hDeltaTheta_TP_L_" << iWh+2 << "_" << iSt-1; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (wrt Sim) " << iWh << " station " << iSt << ", L single"; + mapWS_hDeltaTheta_TP_L[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -2000, 2000 ); + mapWS_hDeltaTheta_TP_L[thisKey]->Sumw2(); + + /// Projections + mapWS_v_hDeltaPhi_TK_C[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaPhi_TK_H[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaPhi_TK_L[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaTheta_TK_C[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaTheta_TK_H[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaTheta_TK_L[thisKey] = std::vector< TH1F* >(); + + for ( unsigned int iLay = 0; iLay < 7; iLay++ ) + { + histoName.str(""); histoName << "hDeltaPhi_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (wrt Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; + mapWS_v_hDeltaPhi_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ) ); + mapWS_v_hDeltaPhi_TK_C[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhi_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (wrt Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; + mapWS_v_hDeltaPhi_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ) ); + mapWS_v_hDeltaPhi_TK_H[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhi_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (wrt Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; + mapWS_v_hDeltaPhi_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ) ); + mapWS_v_hDeltaPhi_TK_L[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaTheta_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (wrt Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; + mapWS_v_hDeltaTheta_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -2000, 2000 ) ); + mapWS_v_hDeltaTheta_TK_C[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaTheta_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (wrt Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; + mapWS_v_hDeltaTheta_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -2000, 2000 ) ); + mapWS_v_hDeltaTheta_TK_H[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaTheta_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (wrt Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; + mapWS_v_hDeltaTheta_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -2000, 2000 ) ); + mapWS_v_hDeltaTheta_TK_L[thisKey].at(iLay)->Sumw2(); + } /// Projections + + /// Residuals + mapWS_v_hDeltaPhiResid_TK_C[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaPhiResid_TK_H[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaPhiResid_TK_L[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaThetaResid_TK_C[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaThetaResid_TK_H[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaThetaResid_TK_L[thisKey] = std::vector< TH1F* >(); + + for ( unsigned int iLay = 0; iLay < 7; iLay++ ) + { + histoName.str(""); histoName << "hDeltaPhiResid_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; + mapWS_v_hDeltaPhiResid_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ) ); + mapWS_v_hDeltaPhiResid_TK_C[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhiResid_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; + mapWS_v_hDeltaPhiResid_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ) ); + mapWS_v_hDeltaPhiResid_TK_H[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhiResid_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; + mapWS_v_hDeltaPhiResid_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 4000, -4000, 4000 ) ); + mapWS_v_hDeltaPhiResid_TK_L[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaThetaResid_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; + mapWS_v_hDeltaThetaResid_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 800, -4000, 4000 ) ); + mapWS_v_hDeltaThetaResid_TK_C[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaThetaResid_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; + mapWS_v_hDeltaThetaResid_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 800, -4000, 4000 ) ); + mapWS_v_hDeltaThetaResid_TK_H[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaThetaResid_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "#Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; + mapWS_v_hDeltaThetaResid_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 800, -4000, 4000 ) ); + mapWS_v_hDeltaThetaResid_TK_L[thisKey].at(iLay)->Sumw2(); + } /// End residuals + + /// Pulls + mapWS_v_hDeltaPhiPull_TK_C[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaPhiPull_TK_H[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaPhiPull_TK_L[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaThetaPull_TK_C[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaThetaPull_TK_H[thisKey] = std::vector< TH1F* >(); + mapWS_v_hDeltaThetaPull_TK_L[thisKey] = std::vector< TH1F* >(); + + for ( unsigned int iLay = 0; iLay < 7; iLay++ ) + { + histoName.str(""); histoName << "hDeltaPhiPull_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "Pull #Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; + mapWS_v_hDeltaPhiPull_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaPhiPull_TK_C[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhiPull_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "Pull #Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; + mapWS_v_hDeltaPhiPull_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaPhiPull_TK_H[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaPhiPull_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "Pull #Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; + mapWS_v_hDeltaPhiPull_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaPhiPull_TK_L[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaThetaPull_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "Pull #Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; + mapWS_v_hDeltaThetaPull_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaThetaPull_TK_C[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaThetaPull_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "Pull #Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; + mapWS_v_hDeltaThetaPull_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaThetaPull_TK_H[thisKey].at(iLay)->Sumw2(); + + histoName.str(""); histoName << "hDeltaThetaPull_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; + histoTitle.str(""); histoTitle << "Pull #Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; + mapWS_v_hDeltaThetaPull_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaThetaPull_TK_L[thisKey].at(iLay)->Sumw2(); + } /// End pulls + } + } + + /// Pt for matching efficiencies + hMuonTP_Pt_DT = fs->make( "hMuonTP_Pt_DT", "sim muon p_{T}, signal in DT", 200, 0, 200 ); + hMuonTP_Pt_DTTF = fs->make( "hMuonTP_Pt_DTTF", "sim muon p_{T}, w/ DTTF", 200, 0, 200 ); + hMuonTP_Pt_DTMatch = fs->make( "hMuonTP_Pt_DTMatch", "sim muon p_{T}, DTMatch", 200, 0, 200 ); + hMuonTP_Pt_DTMatch_TTTrack = fs->make( "hMuonTP_Pt_DTMatch_TTTrack", "sim muon p_{T}, DTMatch + L1 Track", 200, 0, 200 ); + hMuonTP_Pt_DTMatch_Majority = fs->make( "hMuonTP_Pt_DTMatch_Majority", "sim muon p_{T}, DTMatch + Stubs, Majority", 200, 0, 200 ); + hMuonTP_Pt_DTMatch_MixedMode = fs->make( "hMuonTP_Pt_DTMatch_MixedMode", "sim muon p_{T}, DTMatch + Stubs, Mixed Mode", 200, 0, 200 ); + hMuonTP_Pt_DTMatch_MajorityFull = fs->make( "hMuonTP_Pt_DTMatch_MajorityFull", "sim muon p_{T}, DTMatch + Stubs, Majority Full Tk", 200, 0, 200 ); + hMuonTP_Pt_DTMatch_Priority = fs->make( "hMuonTP_Pt_DTMatch_Priority", "sim muon p_{T}, DTMatch + Stubs, Priority", 200, 0, 200 ); + hMuonTP_Pt_DTMatch_Average = fs->make( "hMuonTP_Pt_DTMatch_Average", "sim muon p_{T}, DTMatch + Stubs, Average", 200, 0, 200 ); + + hMuonTP_PtBin_DT = fs->make( "hMuonTP_PtBin_DT", "sim muon p_{T}, signal in DT", 200, 0, 200 ); + hMuonTP_PtBin_DTTF = fs->make( "hMuonTP_PtBin_DTTF", "sim muon p_{T}, w/ DTTF", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch = fs->make( "hMuonTP_PtBin_DTMatch", "sim muon p_{T}, DTMatch", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch_TTTrack = fs->make( "hMuonTP_PtBin_DTMatch_TTTrack", "sim muon p_{T}, DTMatch + L1 Track", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch_Majority = fs->make( "hMuonTP_PtBin_DTMatch_Majority", "sim muon p_{T}, DTMatch + Stubs, Majority", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch_MixedMode = fs->make( "hMuonTP_PtBin_DTMatch_MixedMode", "sim muon p_{T}, DTMatch + Stubs, Mixed Mode", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch_MajorityFull = fs->make( "hMuonTP_PtBin_DTMatch_MajorityFull", "sim muon p_{T}, DTMatch + Stubs, Majority Full Tk", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch_Priority = fs->make( "hMuonTP_PtBin_DTMatch_Priority", "sim muon p_{T}, DTMatch + Stubs, Priority", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch_Average = fs->make( "hMuonTP_PtBin_DTMatch_Average", "sim muon p_{T}, DTMatch + Stubs, Average", 200, 0, 200 ); + + hMuonTP_PtBin_DT->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTTF->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch_TTTrack->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch_Majority->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch_MixedMode->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch_MajorityFull->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch_Priority->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch_Average->GetXaxis()->Set( NumBins, BinVec ); + + hMuonTP_Pt_DT->Sumw2(); + hMuonTP_Pt_DTTF->Sumw2(); + hMuonTP_Pt_DTMatch->Sumw2(); + hMuonTP_Pt_DTMatch_TTTrack->Sumw2(); + hMuonTP_Pt_DTMatch_Majority->Sumw2(); + hMuonTP_Pt_DTMatch_MixedMode->Sumw2(); + hMuonTP_Pt_DTMatch_MajorityFull->Sumw2(); + hMuonTP_Pt_DTMatch_Priority->Sumw2(); + hMuonTP_Pt_DTMatch_Average->Sumw2(); + + hMuonTP_PtBin_DT->Sumw2(); + hMuonTP_PtBin_DTTF->Sumw2(); + hMuonTP_PtBin_DTMatch->Sumw2(); + hMuonTP_PtBin_DTMatch_TTTrack->Sumw2(); + hMuonTP_PtBin_DTMatch_Majority->Sumw2(); + hMuonTP_PtBin_DTMatch_MixedMode->Sumw2(); + hMuonTP_PtBin_DTMatch_MajorityFull->Sumw2(); + hMuonTP_PtBin_DTMatch_Priority->Sumw2(); + hMuonTP_PtBin_DTMatch_Average->Sumw2(); + + /// End of things to be done before entering the event Loop +} + +/// Analyze +void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup& iSetup ) +{ + /// Geometry handles etc + edm::ESHandle< TrackerGeometry > GeometryHandle; + edm::ESHandle< StackedTrackerGeometry > StackedGeometryHandle; + const StackedTrackerGeometry* theStackedGeometry; + StackedTrackerGeometry::StackContainerIterator StackedTrackerIterator; + + /// Geometry setup + /// Set pointers to Geometry + iSetup.get< TrackerDigiGeometryRecord >().get(GeometryHandle); + /// Set pointers to Stacked Modules + iSetup.get< StackedTrackerGeometryRecord >().get(StackedGeometryHandle); + theStackedGeometry = StackedGeometryHandle.product(); /// Note this is different + /// from the "global" geometry + + /// DT Geometry handle etc + edm::ESHandle< DTGeometry > DTGeometryHandle; + iSetup.get< MuonGeometryRecord >().get( DTGeometryHandle ); + +/* + /// Magnetic Field + edm::ESHandle< MagneticField > magneticFieldHandle; + iSetup.get< IdealMagneticFieldRecord >().get(magneticFieldHandle); + const MagneticField* theMagneticField = magneticFieldHandle.product(); + double mMagneticFieldStrength = theMagneticField->inTesla(GlobalPoint(0,0,0)).z(); +*/ + + /// TrackingParticles + edm::Handle< std::vector< TrackingParticle > > TrackingParticleHandle; + iEvent.getByLabel( "mix", "MergedTrackTruth", TrackingParticleHandle ); + edm::Handle< std::vector< TrackingVertex > > TrackingVertexHandle; + iEvent.getByLabel( "mix", "MergedTrackTruth", TrackingVertexHandle ); + + /// Track Trigger + edm::Handle< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > > > TTStubHandle; + iEvent.getByLabel( "TTStubsFromPixelDigis", "StubAccepted", TTStubHandle ); + edm::Handle< std::vector< TTTrack< Ref_PixelDigi_ > > > TTTrackHandle; + iEvent.getByLabel( "TTTracksFromPixelDigis", "Level1TTTracks", TTTrackHandle ); + + /// Track Trigger MC Truth + edm::Handle< TTStubAssociationMap< Ref_PixelDigi_ > > MCTruthTTStubHandle; + iEvent.getByLabel( "TTStubAssociatorFromPixelDigis", "StubAccepted", MCTruthTTStubHandle ); + edm::Handle< TTTrackAssociationMap< Ref_PixelDigi_ > > MCTruthTTTrackHandle; + iEvent.getByLabel( "TTTrackAssociatorFromPixelDigis", "Level1TTTracks", MCTruthTTTrackHandle ); + + /// DT Trigger +#ifdef DEBUG + edm::Handle< std::vector< DTBtiTrigger > > DTBtiTriggerHandle; +#endif + edm::Handle< std::vector< DTMatch > > DTMatchHandle; + +#ifdef DEBUG + iEvent.getByLabel( "DTPlusTrackProducer", DTBtiTriggerHandle ); +#endif + iEvent.getByLabel( "DTPlusTrackProducer", DTMatchHandle ); + + /// DT Digis + edm::Handle< DTDigiCollection > DTDigiHandle; + iEvent.getByLabel( "simMuonDTDigis", DTDigiHandle ); + + /// DT Digi Sim Link + edm::Handle< DTDigiSimLinkCollection > DTDigiSimLinkHandle; + iEvent.getByLabel( "simMuonDTDigis", DTDigiSimLinkHandle ); + +#ifdef DEBUG + /// Loop over the DT Triggers + std::vector< DTBtiTrigger >::const_iterator iterBti; + for ( iterBti = DTBtiTriggerHandle->begin(); + iterBti != DTBtiTriggerHandle->end(); + ++iterBti ) + { + iterBti->print(); + } +#endif + + /// Preliminary task: map SimTracks by TrackingParticle + /// Prepare the map + std::map< std::pair< unsigned int, EncodedEventId >, edm::Ptr< TrackingParticle > > mapSimTrackUniqueToTP; + mapSimTrackUniqueToTP.clear(); + + if ( TrackingParticleHandle->size() != 0 ) + { + /// Loop over TrackingParticles + unsigned int tpCnt = 0; + std::vector< TrackingParticle >::const_iterator iterTPart; + for ( iterTPart = TrackingParticleHandle->begin(); + iterTPart != TrackingParticleHandle->end(); + ++iterTPart ) + { + /// Make the pointer to the TrackingParticle + edm::Ptr< TrackingParticle > tempTPPtr( TrackingParticleHandle, tpCnt++ ); + + /// Get the EncodedEventId + EncodedEventId eventId = EncodedEventId( tempTPPtr->eventId() ); + + /// Loop over SimTracks inside TrackingParticle + std::vector< SimTrack >::const_iterator iterSimTrack; + for ( iterSimTrack = tempTPPtr->g4Tracks().begin(); + iterSimTrack != tempTPPtr->g4Tracks().end(); + ++iterSimTrack ) + { + /// Build the unique SimTrack Id (which is SimTrack ID + EncodedEventId) + std::pair< unsigned int, EncodedEventId > simTrackUniqueId( iterSimTrack->trackId(), eventId ); + mapSimTrackUniqueToTP.insert( std::make_pair( simTrackUniqueId, tempTPPtr ) ); + } + } /// End of loop over TrackingParticles + } + + /// Prepare container for muons that leave signal in the DT wires + std::map< edm::Ptr< TrackingParticle >, std::vector< bool > > mapMuonTrackingParticleInDTDigi; + mapMuonTrackingParticleInDTDigi.clear(); + + /// This is the idea: if a muon is found in the DT digis, it goes into the map and it is + /// contributor to the denominator for efficiencies by definition. + /// Then, the vector of booleans is used to check if the same muon is found in + /// other matches, according to the following index definition + /// 0) DTTF + /// 1) DTMatch + /// 2) DTMatch + Stubs, Priority + /// 3) DTMatch + Stubs, Average + /// 4) DTMatch + Stubs, Majority Full Tracker + /// 5) DTMatch + Stubs, Majority + /// 6) DTMatch + Stubs, Mixed Mode + /// 7) DTMatch + TTTrack + + + /// Prepare the maps for the DT Digi to DT Digi SimLink association +/* + std::map< DTWireId, std::vector< DTDigiSimLink > > mapDTSimLinkByWire; + std::map< DTWireId, std::vector< edm::Ptr< TrackingParticle > > > mapTrackingParticleByWire; + mapDTSimLinkByWire.clear(); + mapTrackingParticleByWire.clear(); +*/ + std::map< DTBtiId, std::vector< DTDigiSimLink > > mapDTSimLinkByBti; + std::map< DTBtiId, std::vector< edm::Ptr< TrackingParticle > > > mapTrackingParticleByBti; + mapDTSimLinkByBti.clear(); + mapTrackingParticleByBti.clear(); + + /// Here's the idea: + /// DTDigi can be associated 1-to-1 with DTDigiSimLink using DTWireId and number/time + /// Then from DTDigiSimLink one can get the unique id std::pair< unsigned int, EncodedEventId > + /// of the TP, so if they are stored simultaneously in the second element of the pairs + /// in the maps above, one will have that each DTDigiSimLink in the vector is associated + /// 1-to-1 to the TrackingParticle + /// DTTrigGeom allows to convert a wire into the corresponding BTI, so that every TrackingParticle + /// can be mapped with respect to the BTI, i.e. each BTI can be associated to all the TrackingParticles + /// that fired it + + /// Loop over the DT Digi SimLink + DTDigiSimLinkCollection::DigiRangeIterator iterDTSLUnit; + std::vector< DTDigiSimLink >::const_iterator iterDTSL; + for ( iterDTSLUnit = DTDigiSimLinkHandle->begin(); + iterDTSLUnit != DTDigiSimLinkHandle->end(); + ++iterDTSLUnit ) + { + /// Get the layer, chamber Id's and the DT Trigger geometry for this chamber + /// all of these are needed to find the BTI Id of the wire associated to this DigiSimLink + const DTLayerId& thisLayId = (*iterDTSLUnit).first; + const DTChamberId thisChambId = thisLayId.superlayerId().chamberId(); + const DTChamber* thisChamber = DTGeometryHandle->chamber(thisChambId); + DTTrigGeom* thisChamberGeometry = new DTTrigGeom( const_cast< DTChamber* >(thisChamber), false ); + const DTDigiSimLinkCollection::Range& theseDigiSimLinksRange = (*iterDTSLUnit).second; + + for ( iterDTSL = theseDigiSimLinksRange.first; + iterDTSL != theseDigiSimLinksRange.second; + ++iterDTSL ) + { + /// Get the wire Id + DTWireId thisWireId( thisLayId, iterDTSL->wire() ); + + /// Build the BTI Id + int btiNum = thisChamberGeometry->mapTubeInFEch( thisLayId.superlayerId().superlayer(), thisLayId.layer(), thisWireId.wire() ); + DTBtiId thisBtiId( thisChambId, thisLayId.superlayerId().superlayer(), btiNum ); + + /// Build the unique Id to find the TrackingParticle + std::pair< unsigned int, EncodedEventId > thisUniqueId = std::make_pair( iterDTSL->SimTrackId(), iterDTSL->eventId() ); + + /// TrackingParticle pointer to be retrieved (if present) from the map + edm::Ptr< TrackingParticle > thisTPPtr; + + /// Check if the TP is available in the map + if ( mapSimTrackUniqueToTP.find( thisUniqueId ) != mapSimTrackUniqueToTP.end() ) + { + thisTPPtr = mapSimTrackUniqueToTP[ thisUniqueId ]; + } + else + { + thisTPPtr = edm::Ptr< TrackingParticle >(); + } +/* + /// Check if the wire is already in the map or not + if ( mapDTSimLinkByWire.find( thisWireId ) != mapDTSimLinkByWire.end() ) + { + mapDTSimLinkByWire[ thisWireId ].push_back( *iterDTSL ); + mapTrackingParticleByWire[ thisWireId ].push_back( thisTPPtr ); + } + else + { + std::vector< DTDigiSimLink > tempVector1; + std::vector< edm::Ptr< TrackingParticle > > tempVector2; + tempVector1.push_back( *iterDTSL ); + tempVector2.push_back( thisTPPtr ); + mapDTSimLinkByWire.insert( std::make_pair( thisWireId, tempVector1 ) ); + mapTrackingParticleByWire.insert( std::make_pair( thisWireId, tempVector2 ) ); + } +*/ + + /// Check if the BTI is already in the map or not + if ( mapDTSimLinkByBti.find( thisBtiId ) != mapDTSimLinkByBti.end() ) + { + mapDTSimLinkByBti[ thisBtiId ].push_back( *iterDTSL ); + mapTrackingParticleByBti[ thisBtiId ].push_back( thisTPPtr ); + } + else + { + std::vector< DTDigiSimLink > tempVector1; + std::vector< edm::Ptr< TrackingParticle > > tempVector2; + tempVector1.push_back( *iterDTSL ); + tempVector2.push_back( thisTPPtr ); + mapDTSimLinkByBti.insert( std::make_pair( thisBtiId, tempVector1 ) ); + mapTrackingParticleByBti.insert( std::make_pair( thisBtiId, tempVector2 ) ); + } + + /// Check if it is a muon + if( thisTPPtr.isNull() == false && + fabs(thisTPPtr->pdgId()) == 13 ) + { + /// Check if the muon is already in the container for the efficiencies + if ( mapMuonTrackingParticleInDTDigi.find( thisTPPtr ) == mapMuonTrackingParticleInDTDigi.end() ) + { + /// Add it to the map if not present + std::vector< bool > tempVec; + for ( unsigned int jK = 0; jK < 8; jK++ ) + { + /// 0) DTTF + /// 1) DTMatch + /// 2) DTMatch + Stubs, Priority + /// 3) DTMatch + Stubs, Average + /// 4) DTMatch + Stubs, Majority Full Tracker + /// 5) DTMatch + Stubs, Majority + /// 6) DTMatch + Stubs, Mixed Mode + /// 7) DTMatch + TTTrack + + tempVec.push_back(false); + } + + mapMuonTrackingParticleInDTDigi.insert( std::make_pair( thisTPPtr, tempVec ) ); + } + } + + } /// End of loop over the DTDigiSimLinks + } /// End of loop over the DT unit + +/* + std::map< DTWireId, std::vector< DTDigiSimLink > >::const_iterator iterMapDTSimLinkByWire; + + for ( iterMapDTSimLinkByWire = mapDTSimLinkByWire.begin(); + iterMapDTSimLinkByWire != mapDTSimLinkByWire.end(); + ++iterMapDTSimLinkByWire ) + { + DTWireId thisWireId = iterMapDTSimLinkByWire->first; + std::vector< DTDigiSimLink > theseDTSimLinks = iterMapDTSimLinkByWire->second; + std::vector< edm::Ptr< TrackingParticle > > theseTrackingParticles = mapTrackingParticleByWire[ thisWireId ]; /// Safe by construction! + + std::cerr << thisWireId << std::endl; + if ( theseDTSimLinks.size() != theseTrackingParticles.size() ) std::cerr << "DISASTER HAPPENED" << std::endl; + else + { + for ( unsigned int j = 0; j < theseDTSimLinks.size(); j++ ) + { + std::cerr << theseDTSimLinks.at(j).number() << " " << theseDTSimLinks.at(j).time() << std::endl; + std::cerr << theseTrackingParticles.at(j).isNull(); + if ( theseTrackingParticles.at(j).isNull() ) std::cerr << std::endl; + else + { + edm::Ptr< TrackingParticle > thisTPPtr = theseTrackingParticles.at(j); + std::cerr << " " << thisTPPtr->pdgId() << " " << thisTPPtr->momentum() << std::endl; + } + } + } + } +*/ + + /// Now, convert the map< BTI, vector< TP > > to a map< BTI, vector< muon TP > > + /// and to a map< BTI, one single muon TP > + std::map< DTBtiId, std::vector< edm::Ptr< TrackingParticle > > > mapSimMuonsByBti; + std::map< DTBtiId, edm::Ptr< TrackingParticle > > mapTheSimMuonByBti; + mapSimMuonsByBti.clear(); + mapTheSimMuonByBti.clear(); + +/* + std::map< DTBtiId, std::vector< DTDigiSimLink > >::const_iterator iterMapDTSimLinkByBti; + + for ( iterMapDTSimLinkByBti = mapDTSimLinkByBti.begin(); + iterMapDTSimLinkByBti != mapDTSimLinkByBti.end(); + ++iterMapDTSimLinkByBti ) + { +*/ + std::map< DTBtiId, std::vector< edm::Ptr< TrackingParticle > > >::const_iterator iterMapTrackingParticleByBti; + + for ( iterMapTrackingParticleByBti = mapTrackingParticleByBti.begin(); + iterMapTrackingParticleByBti != mapTrackingParticleByBti.end(); + ++iterMapTrackingParticleByBti ) + { + +// DTBtiId thisBtiId = iterMapDTSimLinkByBti->first; +// std::vector< DTDigiSimLink > theseDTSimLinks = iterMapDTSimLinkByBti->second; + + DTBtiId thisBtiId = iterMapTrackingParticleByBti->first; + std::vector< edm::Ptr< TrackingParticle > > theseTrackingParticles = mapTrackingParticleByBti[ thisBtiId ]; /// Safe by construction! + + /// Prepare the map for muons purged + std::vector< edm::Ptr< TrackingParticle > > theseSimMuons; + theseSimMuons.clear(); + + /// Loop over the TrackingParticles + for ( unsigned int j = 0; j < theseTrackingParticles.size(); j++ ) + { + if ( theseTrackingParticles.at(j).isNull() ) + { + continue; + } + else + { + edm::Ptr< TrackingParticle > thisTPPtr = theseTrackingParticles.at(j); + if ( fabs(thisTPPtr->pdgId()) == 13 ) + { + /// Push back only non-duplicate muons! + bool muonFound = false; + for ( unsigned int k = 0; k < theseSimMuons.size() && !muonFound; k++ ) + { + if ( thisTPPtr.get() == theseSimMuons.at(k).get() ) + { + muonFound = true; + } + } + + if ( !muonFound ) + { + theseSimMuons.push_back( thisTPPtr ); + } + } + } + } /// End of loop over TrackingParticles + + if ( theseSimMuons.size() > 0 ) + { + mapSimMuonsByBti.insert( std::make_pair( thisBtiId, theseSimMuons ) ); + } + if ( theseSimMuons.size() == 1 ) + { + mapTheSimMuonByBti.insert( std::make_pair( thisBtiId, theseSimMuons.at(0) ) ); + } + +#ifdef DEBUG + std::cerr << thisBtiId.SLId() << " " << thisBtiId.bti() << std::endl; + if ( mapSimMuonsByBti.find( thisBtiId ) != mapSimMuonsByBti.end() ) + { + std::cerr << "TPs = " << mapTrackingParticleByBti[ thisBtiId ].size() << std::endl; + std::cerr << "MUONS = " << mapSimMuonsByBti[ thisBtiId ].size() << std::endl; + } + if ( mapTheSimMuonByBti.find( thisBtiId ) != mapTheSimMuonByBti.end() ) + { + std::cerr << "THE MUON IS " << mapTheSimMuonByBti[ thisBtiId ]->momentum() << std::endl; + } +#endif + +#ifdef DEBUG +/* + std::cerr << thisBtiId.SLId() << " " << thisBtiId.bti() << std::endl; + if ( theseDTSimLinks.size() != theseTrackingParticles.size() ) std::cerr << "DISASTER HAPPENED" << std::endl; + else + { + for ( unsigned int j = 0; j < theseDTSimLinks.size(); j++ ) + { + std::cerr << theseDTSimLinks.at(j).number() << " " << theseDTSimLinks.at(j).time() << std::endl; + std::cerr << theseTrackingParticles.at(j).isNull(); + if ( theseTrackingParticles.at(j).isNull() ) std::cerr << std::endl; + else + { + edm::Ptr< TrackingParticle > thisTPPtr = theseTrackingParticles.at(j); + std::cerr << " " << thisTPPtr->pdgId() << " " << thisTPPtr->momentum() << std::endl; + } + } + } +*/ +#endif + } + +#ifdef DEBUG + /// Loop over the DT Digis + DTDigiCollection::DigiRangeIterator iterDTUnit; + std::vector< DTDigi >::const_iterator iterDTDigi; + for ( iterDTUnit = DTDigiHandle->begin(); + iterDTUnit != DTDigiHandle->end(); + ++iterDTUnit ) + { + const DTLayerId& thisLayId = (*iterDTUnit).first; + const DTChamberId thisChambId = thisLayId.superlayerId().chamberId(); + const DTDigiCollection::Range& theseDigisRange = (*iterDTUnit).second; + + for ( iterDTDigi = theseDigisRange.first; + iterDTDigi != theseDigisRange.second; + ++iterDTDigi ) + { + DTWireId thisWireId( thisLayId, iterDTDigi->wire() ); + std::cerr<< thisLayId << " " << thisChambId << " " << thisWireId << " " << iterDTDigi->time(); + iterDTDigi->print(); + } + } +#endif + + /// Loop over the DTMatches + std::vector< DTMatch >::const_iterator iterDTM; + for ( iterDTM = DTMatchHandle->begin(); + iterDTM != DTMatchHandle->end(); + ++iterDTM ) + { + /// Skip if wrong BX + bool flagBXOk = iterDTM->getFlagBXOK(); + + if ( !flagBXOk ) + { + continue; + } + + /// Get the Id of all the BTIs of the match + DTBtiId innerBti = iterDTM->getInnerBtiId(); + DTBtiId outerBti = iterDTM->getOuterBtiId(); + DTBtiId matchedBti = iterDTM->getMatchedBtiId(); + +#ifdef DEBUG + std::cerr << " I " << innerBti.SLId() << " " << innerBti.bti() << std::endl; + if ( mapTheSimMuonByBti.find( innerBti ) != mapTheSimMuonByBti.end() ) + std::cerr << " has one muon " << mapTheSimMuonByBti[ innerBti ]->momentum() << std::endl; + else if ( mapSimMuonsByBti.find( innerBti ) != mapSimMuonsByBti.end() ) + std::cerr << " has " << mapSimMuonsByBti[ innerBti ].size() << " muons" << std::endl; + else if ( mapTrackingParticleByBti.find( innerBti ) != mapTrackingParticleByBti.end() ) + std::cerr << " has " << mapTrackingParticleByBti[ innerBti ].size() << " non muon particles" << std::endl; + + std::cerr << " O " << outerBti.SLId() << " " << outerBti.bti() << std::endl; + if ( mapTheSimMuonByBti.find( outerBti ) != mapTheSimMuonByBti.end() ) + std::cerr << " has one muon " << mapTheSimMuonByBti[ outerBti ]->momentum() << std::endl; + else if ( mapSimMuonsByBti.find( outerBti ) != mapSimMuonsByBti.end() ) + std::cerr << " has " << mapSimMuonsByBti[ outerBti ].size() << " muons" << std::endl; + else if ( mapTrackingParticleByBti.find( outerBti ) != mapTrackingParticleByBti.end() ) + std::cerr << " has " << mapTrackingParticleByBti[ outerBti ].size() << " non muon particles" << std::endl; + + std::cerr << " M " << matchedBti.SLId() << " " << matchedBti.bti() << std::endl; + if ( mapTheSimMuonByBti.find( matchedBti ) != mapTheSimMuonByBti.end() ) + std::cerr << " has one muon " << mapTheSimMuonByBti[ matchedBti ]->momentum() << std::endl; + else if ( mapSimMuonsByBti.find( matchedBti ) != mapSimMuonsByBti.end() ) + std::cerr << " has " << mapSimMuonsByBti[ matchedBti ].size() << " muons" << std::endl; + else if ( mapTrackingParticleByBti.find( matchedBti ) != mapTrackingParticleByBti.end() ) + std::cerr << " has " << mapTrackingParticleByBti[ outerBti ].size() << " non muon particles" << std::endl; + + std::cerr<, std::vector< DTBtiId > > mapBtiByFiringMuon; + + if ( mapTheSimMuonByBti.find( innerBti ) != mapTheSimMuonByBti.end() ) + { + /// Only 1 muon fires the BTI + if ( mapTheSimMuonByBti[ innerBti ].isNull() == false ) /// Robustness + { + if ( mapBtiByFiringMuon.find( mapTheSimMuonByBti[ innerBti ] ) != mapBtiByFiringMuon.end() ) + { + mapBtiByFiringMuon[ mapTheSimMuonByBti[ innerBti ] ].push_back( innerBti ); + } + else + { + std::vector< DTBtiId > tempBtiVec; + tempBtiVec.push_back( innerBti ); + mapBtiByFiringMuon.insert( std::make_pair( mapTheSimMuonByBti[ innerBti ], tempBtiVec ) ); + } + } + } + else if ( mapSimMuonsByBti.find( innerBti ) != mapSimMuonsByBti.end() ) + { + /// Case when > 1 muon fires the BTI + for ( unsigned int q = 0; q < mapSimMuonsByBti[ innerBti ].size(); q++ ) + { + if ( mapSimMuonsByBti[ innerBti ].at(q).isNull() == false ) + { + if ( mapBtiByFiringMuon.find( mapSimMuonsByBti[ innerBti ].at(q) ) != mapBtiByFiringMuon.end() ) + { + mapBtiByFiringMuon[ mapSimMuonsByBti[ innerBti ].at(q) ].push_back( innerBti ); + } + else + { + std::vector< DTBtiId > tempBtiVec; + tempBtiVec.push_back( innerBti ); + mapBtiByFiringMuon.insert( std::make_pair( mapSimMuonsByBti[ innerBti ].at(q), tempBtiVec ) ); + } + } + } + } + + if ( mapTheSimMuonByBti.find( outerBti ) != mapTheSimMuonByBti.end() ) + { + /// Only 1 muon fires the BTI + if ( mapTheSimMuonByBti[ outerBti ].isNull() == false ) /// Robustness + { + if ( mapBtiByFiringMuon.find( mapTheSimMuonByBti[ outerBti ] ) != mapBtiByFiringMuon.end() ) + { + mapBtiByFiringMuon[ mapTheSimMuonByBti[ outerBti ] ].push_back( outerBti ); + } + else + { + std::vector< DTBtiId > tempBtiVec; + tempBtiVec.push_back( outerBti ); + mapBtiByFiringMuon.insert( std::make_pair( mapTheSimMuonByBti[ outerBti ], tempBtiVec ) ); + } + } + } + else if ( mapSimMuonsByBti.find( outerBti ) != mapSimMuonsByBti.end() ) + { + /// Case when > 1 muon fires the BTI + for ( unsigned int q = 0; q < mapSimMuonsByBti[ outerBti ].size(); q++ ) + { + if ( mapSimMuonsByBti[ outerBti ].at(q).isNull() == false ) + { + if ( mapBtiByFiringMuon.find( mapSimMuonsByBti[ outerBti ].at(q) ) != mapBtiByFiringMuon.end() ) + { + mapBtiByFiringMuon[ mapSimMuonsByBti[ outerBti ].at(q) ].push_back( outerBti ); + } + else + { + std::vector< DTBtiId > tempBtiVec; + tempBtiVec.push_back( outerBti ); + mapBtiByFiringMuon.insert( std::make_pair( mapSimMuonsByBti[ outerBti ].at(q), tempBtiVec ) ); + } + } + } + } + + if ( mapTheSimMuonByBti.find( matchedBti ) != mapTheSimMuonByBti.end() ) + { + /// Only 1 muon fires the BTI + if ( mapTheSimMuonByBti[ matchedBti ].isNull() == false ) /// Robustness + { + if ( mapBtiByFiringMuon.find( mapTheSimMuonByBti[ matchedBti ] ) != mapBtiByFiringMuon.end() ) + { + mapBtiByFiringMuon[ mapTheSimMuonByBti[ matchedBti ] ].push_back( matchedBti ); + } + else + { + std::vector< DTBtiId > tempBtiVec; + tempBtiVec.push_back( matchedBti ); + mapBtiByFiringMuon.insert( std::make_pair( mapTheSimMuonByBti[ matchedBti ], tempBtiVec ) ); + } + } + } + else if ( mapSimMuonsByBti.find( matchedBti ) != mapSimMuonsByBti.end() ) + { + /// Case when > 1 muon fires the BTI + for ( unsigned int q = 0; q < mapSimMuonsByBti[ matchedBti ].size(); q++ ) + { + if ( mapSimMuonsByBti[ matchedBti ].at(q).isNull() == false ) + { + if ( mapBtiByFiringMuon.find( mapSimMuonsByBti[ matchedBti ].at(q) ) != mapBtiByFiringMuon.end() ) + { + mapBtiByFiringMuon[ mapSimMuonsByBti[ matchedBti ].at(q) ].push_back( matchedBti ); + } + else + { + std::vector< DTBtiId > tempBtiVec; + tempBtiVec.push_back( matchedBti ); + mapBtiByFiringMuon.insert( std::make_pair( mapSimMuonsByBti[ matchedBti ].at(q), tempBtiVec ) ); + } + } + } + } + + /// Now we have a map where each muon firing a BTI --> points to the list of fired Bti + /// Basic criterion: only 1 muon that fires min. 1/3 BTI + edm::Ptr< TrackingParticle > theFiringMuon = edm::Ptr< TrackingParticle >(); + std::map< edm::Ptr< TrackingParticle >, std::vector< DTBtiId > >::const_iterator iterMapBtiByFiringMuon; + + for ( iterMapBtiByFiringMuon = mapBtiByFiringMuon.begin(); + iterMapBtiByFiringMuon != mapBtiByFiringMuon.end(); + ++iterMapBtiByFiringMuon ) + { + if ( theFiringMuon.isNull() ) + { + /// First item in the map + if ( iterMapBtiByFiringMuon->second.size() > 0 ) + { + theFiringMuon = iterMapBtiByFiringMuon->first; + } + } + else + { + /// There is already a muon set! If we get here, + /// the muon has already been assigned and the present one + /// is another muon. If also this has min 1/3 BTI matched, + /// no unique assignment is possible, so force to exit + if ( iterMapBtiByFiringMuon->second.size() > 0 ) + { + /// Force to exit and reset muon to null + theFiringMuon = edm::Ptr< TrackingParticle >(); + iterMapBtiByFiringMuon = mapBtiByFiringMuon.end(); + } + } + + /// For the efficiency plots: numerators can be filled for all the muons + /// that fire at least 1 BTI out of the 3 that make the DTMatch + edm::Ptr< TrackingParticle > thisMuon = iterMapBtiByFiringMuon->first; + + /// Fill the container for the efficiency plots + if ( mapMuonTrackingParticleInDTDigi.find( thisMuon ) != mapMuonTrackingParticleInDTDigi.end() ) + { + /// 0) DTTF + /// 1) DTMatch + /// 2) DTMatch + Stubs, Priority + /// 3) DTMatch + Stubs, Average + /// 4) DTMatch + Stubs, Majority Full Tracker + /// 5) DTMatch + Stubs, Majority + /// 6) DTMatch + Stubs, Mixed Mode + /// 7) DTMatch + TTTrack + + /// 1) DTMatch + mapMuonTrackingParticleInDTDigi[ thisMuon ][1] = true; + + /// 2) DTMatch + Stubs, Priority + if ( iterDTM->getPtPriorityBin() > 0. ) + { + mapMuonTrackingParticleInDTDigi[ thisMuon ][2] = true; + } + + /// 3) DTMatch + Stubs, Average + if ( iterDTM->getPtAverageBin() > 0. ) + { + mapMuonTrackingParticleInDTDigi[ thisMuon ][3] = true; + } + + /// 4) DTMatch + Stubs, Majority Full Tracker + if ( iterDTM->getPtMajorityFullTkBin() > 0. ) + { + mapMuonTrackingParticleInDTDigi[ thisMuon ][4] = true; + } + + /// 5) DTMatch + Stubs, Majority + if ( iterDTM->getPtMajorityBin() > 0. ) + { + mapMuonTrackingParticleInDTDigi[ thisMuon ][5] = true; + } + + /// 6) DTMatch + Stubs, Mixed Mode + if ( iterDTM->getPtMixedModeBin() > 0. ) + { + mapMuonTrackingParticleInDTDigi[ thisMuon ][6] = true; + } + + /// 7) DTMatch + TTTrack + if ( iterDTM->getPtTTTrackBin() > 0. ) + { + mapMuonTrackingParticleInDTDigi[ thisMuon ][7] = true; + } + + + + + + + + } + } + + /// Here, if there is one good muon that builds up this TP seed, it is stored in theFiringMuon + /// if theFiringMuon.isNull(), it means that either no muon 2/3 BTI is found, either more than 1 were found + if ( theFiringMuon.isNull() == false ) + { +#ifdef DEBUG + std::cerr << " I " << innerBti.SLId() << " " << innerBti.bti() << std::endl; + std::cerr << " O " << outerBti.SLId() << " " << outerBti.bti() << std::endl; + std::cerr << " M " << matchedBti.SLId() << " " << matchedBti.bti() << std::endl; + std::cerr << theFiringMuon->momentum() << std::endl; +#endif + + /// Select only the charges you want + int muonCharge = theFiringMuon->charge(); + if ( !useBothMuonCharges ) + { + if ( selectPositiveMuons && ( muonCharge < 0 ) ) + { + continue; + } + if ( !selectPositiveMuons && ( muonCharge > 0 ) ) + { + continue; + } + } + + /// Get the DT Wheel, Station etc. information + int thisDTWheel = iterDTM->getDTWheel(); + int thisDTStation = iterDTM->getDTStation(); + int thisDTCode = iterDTM->getDTCode(); + +#ifdef DEBUG + std::cerr << " ******** " << thisDTWheel << " * " << thisDTStation << std::endl; +#endif + + bool isCorr = false; + bool isHs = false; + bool isLs = false; + + if ( thisDTStation == 1 ) + { + if ( thisDTCode == 27 || thisDTCode == 26 || + thisDTCode == 23 || thisDTCode == 22 || + thisDTCode == 19 || thisDTCode == 18 ) + { + isCorr = true; + } + else if ( thisDTCode == 15 || thisDTCode == 14 || + thisDTCode == 11 || thisDTCode == 10 ) + { + isHs = true; + } + else if ( thisDTCode == 7 || thisDTCode == 6 || + thisDTCode == 3 || thisDTCode == 2 ) + { + isLs = true; + } + } + if ( thisDTStation == 2 ) + { + if ( thisDTCode == 25 || thisDTCode == 24 || + thisDTCode == 21 || thisDTCode == 20 || + thisDTCode == 17 || thisDTCode == 16 ) + { + isCorr = true; + } + else if ( thisDTCode == 13 || thisDTCode == 12 || + thisDTCode == 9 || thisDTCode == 8 ) + { + isHs = true; + } + else if ( thisDTCode == 5 || thisDTCode == 4 || + thisDTCode == 1 || thisDTCode == 0 ) + { + isLs = true; + } + } + + if ( isCorr == false && isHs == false && isLs == false ) + { + /// Exit if the code cannot be assigned to any kind of TP seed + continue; + } + + /// Build the map key + std::pair< int, int > thisKey = std::make_pair( thisDTWheel, thisDTStation ); + + /// Get information from the DT seed + int thisDTTSPhiB = iterDTM->getDTTSPhiB(); + double thisDTGloPhi = iterDTM->getDTPosition().phi(); + if ( thisDTGloPhi < 0 ) thisDTGloPhi += 2 * M_PI; + if ( thisDTGloPhi >= 2 * M_PI ) thisDTGloPhi -= 2 * M_PI; + + int thisDTGloPhiInt = static_cast< int >( thisDTGloPhi * 4096. ); + int thisDTTSPhiCorr = iterDTM->getDTTSPhi() + static_cast< int >( (iterDTM->getDTSector() - 1) * M_PI/6. * 4096.); + int thisDTTSTheta = iterDTM->getDTTSTheta(); + + /// Get information from the generated muon + TrackingParticle::Vector simMuonMomentum = theFiringMuon->momentum(); + double simMuonPhi = simMuonMomentum.phi(); + if ( simMuonPhi < 0 ) simMuonPhi += 2 * M_PI; + if ( simMuonPhi >= 2 * M_PI ) simMuonPhi -= 2 * M_PI; + + int simMuonPhiInt = static_cast< int >( simMuonPhi * 4096. ); + int simMuonThetaInt = static_cast< int >( simMuonMomentum.theta() * 4096. ); + + if ( isCorr ) + { + mapWS_hPhiB_C[thisKey]->Fill( thisDTTSPhiB ); + mapWS_hPhiG_C[thisKey]->Fill( thisDTGloPhiInt ); + mapWS_hPhi_C[thisKey]->Fill( thisDTTSPhiCorr ); + mapWS_hTheta_C[thisKey]->Fill( thisDTTSTheta ); + mapWS_hTPPhi_C[thisKey]->Fill( simMuonPhiInt ); + mapWS_hTPTheta_C[thisKey]->Fill( simMuonThetaInt ); + } + else if ( isHs ) + { + mapWS_hPhiB_H[thisKey]->Fill( thisDTTSPhiB ); + mapWS_hPhiG_H[thisKey]->Fill( thisDTGloPhiInt ); + mapWS_hPhi_H[thisKey]->Fill( thisDTTSPhiCorr ); + mapWS_hTheta_H[thisKey]->Fill( thisDTTSTheta ); + mapWS_hTPPhi_H[thisKey]->Fill( simMuonPhiInt ); + mapWS_hTPTheta_H[thisKey]->Fill( simMuonThetaInt ); + } + else if ( isLs ) + { + mapWS_hPhiB_L[thisKey]->Fill( thisDTTSPhiB ); + mapWS_hPhiG_L[thisKey]->Fill( thisDTGloPhiInt ); + mapWS_hPhi_L[thisKey]->Fill( thisDTTSPhiCorr ); + mapWS_hTheta_L[thisKey]->Fill( thisDTTSTheta ); + mapWS_hTPPhi_L[thisKey]->Fill( simMuonPhiInt ); + mapWS_hTPTheta_L[thisKey]->Fill( simMuonThetaInt ); + } + + /// Prepare for calculations of DeltaPhi + int IMPI = static_cast< int >( M_PI * 4096. ); + int tempPhi1, tempPhi2, tempDeltaPhi; + int tempPhi3; + + /// Difference w.r.t. Gen + tempPhi1 = thisDTTSPhiCorr; + tempPhi2 = simMuonPhiInt; + if ( tempPhi1 < 0 ) tempPhi1 += 2 * IMPI; + if ( tempPhi2 < 0 ) tempPhi2 += 2 * IMPI; + if ( tempPhi1 >= 2 * IMPI ) tempPhi1 -= 2 * IMPI; + if ( tempPhi2 >= 2 * IMPI ) tempPhi2 -= 2 * IMPI; + tempDeltaPhi = tempPhi1 - tempPhi2; + if ( tempDeltaPhi > IMPI ) tempDeltaPhi = 2 * IMPI - tempDeltaPhi; + if ( tempDeltaPhi < -IMPI ) tempDeltaPhi = - 2 * IMPI + tempDeltaPhi; + + if ( isCorr ) + { + mapWS_hDeltaPhi_TP_C[thisKey]->Fill( tempDeltaPhi ); + mapWS_hDeltaTheta_TP_C[thisKey]->Fill( thisDTTSTheta - simMuonThetaInt ); + } + else if ( isHs ) + { + mapWS_hDeltaPhi_TP_H[thisKey]->Fill( tempDeltaPhi ); + mapWS_hDeltaTheta_TP_H[thisKey]->Fill( thisDTTSTheta - simMuonThetaInt ); + } + else if ( isLs ) + { + mapWS_hDeltaPhi_TP_L[thisKey]->Fill( tempDeltaPhi ); + mapWS_hDeltaTheta_TP_L[thisKey]->Fill( thisDTTSTheta - simMuonThetaInt ); + } + + /// Get the L1 tracks associated with the current muon + std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > > theseTracks = MCTruthTTTrackHandle->findTTTrackPtrs( theFiringMuon ); + + if ( theseTracks.size() > 0 ) + { + for ( unsigned int iTk = 0; iTk < theseTracks.size(); iTk++ ) + { + edm::Ptr< TTTrack< Ref_PixelDigi_ > > tempTrackPtr = theseTracks.at( iTk ); + bool genuineTrack = MCTruthTTTrackHandle->isGenuine( tempTrackPtr ); + + if ( !genuineTrack ) continue; + + double trackPhi = tempTrackPtr->getMomentum().phi(); + if ( trackPhi < 0 ) trackPhi += 2 * M_PI; + if ( trackPhi >= 2 * M_PI ) trackPhi -= 2 * M_PI; + tempPhi2 = static_cast< int >( trackPhi * 4096. ); + if ( tempPhi2 < 0 ) tempPhi2 += 2 * IMPI; + if ( tempPhi2 >= 2 * IMPI ) tempPhi2 -= 2 * IMPI; + tempDeltaPhi = tempPhi1 - tempPhi2; + if ( tempDeltaPhi > IMPI ) tempDeltaPhi = 2 * IMPI - tempDeltaPhi; + if ( tempDeltaPhi < -IMPI ) tempDeltaPhi = - 2 * IMPI + tempDeltaPhi; + + int trackThetaInt = static_cast< int >( tempTrackPtr->getMomentum().theta() * 4096. ); + + /// Difference seed to Tk + if ( isCorr ) + { + mapWS_v_hDeltaPhi_TK_C[thisKey].at(0)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaTheta_TK_C[thisKey].at(0)->Fill( thisDTTSTheta - trackThetaInt ); + } + else if ( isHs ) + { + mapWS_v_hDeltaPhi_TK_H[thisKey].at(0)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaTheta_TK_H[thisKey].at(0)->Fill( thisDTTSTheta - trackThetaInt ); + } + else if ( isLs ) + { + mapWS_v_hDeltaPhi_TK_L[thisKey].at(0)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaTheta_TK_L[thisKey].at(0)->Fill( thisDTTSTheta - trackThetaInt ); + } + + /// Difference seed Tk prediction to Tk + tempPhi3 = iterDTM->getPredVtxPhi(); + if ( tempPhi3 < 0 ) tempPhi2 += 2 * IMPI; + if ( tempPhi3 >= 2 * IMPI ) tempPhi3 -= 2 * IMPI; + tempDeltaPhi = tempPhi3 - tempPhi2; + if ( tempDeltaPhi > IMPI ) tempDeltaPhi = 2 * IMPI - tempDeltaPhi; + if ( tempDeltaPhi < -IMPI ) tempDeltaPhi = - 2 * IMPI + tempDeltaPhi; + + int predVtxTheta = iterDTM->getPredVtxTheta(); + int predVtxPhiError = iterDTM->getPredVtxSigmaPhi(); + int predVtxThetaError = iterDTM->getPredVtxSigmaTheta(); + + if ( isCorr ) + { + mapWS_v_hDeltaPhiResid_TK_C[thisKey].at(0)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaThetaResid_TK_C[thisKey].at(0)->Fill( predVtxTheta - trackThetaInt ); + mapWS_v_hDeltaPhiPull_TK_C[thisKey].at(0)->Fill( tempDeltaPhi/predVtxPhiError ); + mapWS_v_hDeltaThetaPull_TK_C[thisKey].at(0)->Fill( (predVtxTheta - trackThetaInt)/predVtxThetaError ); + } + else if ( isHs ) + { + mapWS_v_hDeltaPhiResid_TK_H[thisKey].at(0)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaThetaResid_TK_H[thisKey].at(0)->Fill( predVtxTheta - trackThetaInt ); + mapWS_v_hDeltaPhiPull_TK_H[thisKey].at(0)->Fill( tempDeltaPhi/predVtxPhiError ); + mapWS_v_hDeltaThetaPull_TK_H[thisKey].at(0)->Fill( (predVtxTheta - trackThetaInt)/predVtxThetaError ); + } + else if ( isLs ) + { + mapWS_v_hDeltaPhiResid_TK_L[thisKey].at(0)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaThetaResid_TK_L[thisKey].at(0)->Fill( predVtxTheta - trackThetaInt ); + mapWS_v_hDeltaPhiPull_TK_L[thisKey].at(0)->Fill( tempDeltaPhi/predVtxPhiError ); + mapWS_v_hDeltaThetaPull_TK_L[thisKey].at(0)->Fill( (predVtxTheta - trackThetaInt)/predVtxThetaError ); + } + + } /// End of loop over L1 tracks + } + + /// Get also the stubs associated with the current muon + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theseStubs = MCTruthTTStubHandle->findTTStubRefs( theFiringMuon ); + + if ( theseStubs.size() > 0 ) + { + for ( unsigned int iStub = 0; iStub < theseStubs.size(); iStub++ ) + { + edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > tempStubRef = theseStubs.at( iStub ); + + StackedTrackerDetId tkDetId( tempStubRef->getDetId() ); + if ( tkDetId.isBarrel() == false ) + { + continue; + } + + bool genuineStub = MCTruthTTStubHandle->isGenuine( tempStubRef ); + + if ( !genuineStub ) continue; + + unsigned int jLayer = tkDetId.iLayer(); + + GlobalPoint stubPos = theStackedGeometry->findGlobalPosition( tempStubRef.get() ); + + double stubPhi = stubPos.phi(); + if ( stubPhi < 0 ) stubPhi += 2 * M_PI; + if ( stubPhi >= 2 * M_PI ) stubPhi -= 2 * M_PI; + tempPhi2 = static_cast< int >( stubPhi * 4096. ); + if ( tempPhi2 < 0 ) tempPhi2 += 2 * IMPI; + if ( tempPhi2 >= 2 * IMPI ) tempPhi2 -= 2 * IMPI; + tempDeltaPhi = tempPhi1 - tempPhi2; + if ( tempDeltaPhi > IMPI ) tempDeltaPhi = 2 * IMPI - tempDeltaPhi; + if ( tempDeltaPhi < -IMPI ) tempDeltaPhi = - 2 * IMPI + tempDeltaPhi; + + int stubThetaInt = static_cast< int >( stubPos.theta() * 4096. ); + + if ( isCorr ) + { + mapWS_v_hDeltaPhi_TK_C[thisKey].at(jLayer)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaTheta_TK_C[thisKey].at(jLayer)->Fill( thisDTTSTheta - stubThetaInt ); + } + else if ( isHs ) + { + mapWS_v_hDeltaPhi_TK_H[thisKey].at(jLayer)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaTheta_TK_H[thisKey].at(jLayer)->Fill( thisDTTSTheta - stubThetaInt ); + } + else if ( isLs ) + { + mapWS_v_hDeltaPhi_TK_L[thisKey].at(jLayer)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaTheta_TK_L[thisKey].at(jLayer)->Fill( thisDTTSTheta - stubThetaInt ); + } + + tempPhi3 = iterDTM->getPredStubPhi(jLayer); + if ( tempPhi3 < 0 ) tempPhi2 += 2 * IMPI; + if ( tempPhi3 >= 2 * IMPI ) tempPhi3 -= 2 * IMPI; + tempDeltaPhi = tempPhi3 - tempPhi2; + if ( tempDeltaPhi > IMPI ) tempDeltaPhi = 2 * IMPI - tempDeltaPhi; + if ( tempDeltaPhi < -IMPI ) tempDeltaPhi = - 2 * IMPI + tempDeltaPhi; + + int predStubTheta = iterDTM->getPredStubTheta(jLayer); + int predStubPhiError = iterDTM->getPredStubSigmaPhi(jLayer); + int predStubThetaError = iterDTM->getPredStubSigmaTheta(jLayer); + + if ( isCorr ) + { + mapWS_v_hDeltaPhiResid_TK_C[thisKey].at(jLayer)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaThetaResid_TK_C[thisKey].at(jLayer)->Fill( predStubTheta - stubThetaInt ); + mapWS_v_hDeltaPhiPull_TK_C[thisKey].at(jLayer)->Fill( tempDeltaPhi/predStubPhiError ); + mapWS_v_hDeltaThetaPull_TK_C[thisKey].at(jLayer)->Fill( (predStubTheta - stubThetaInt)/predStubThetaError ); + } + else if ( isHs ) + { + mapWS_v_hDeltaPhiResid_TK_H[thisKey].at(jLayer)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaThetaResid_TK_H[thisKey].at(jLayer)->Fill( predStubTheta - stubThetaInt ); + mapWS_v_hDeltaPhiPull_TK_H[thisKey].at(jLayer)->Fill( tempDeltaPhi/predStubPhiError ); + mapWS_v_hDeltaThetaPull_TK_H[thisKey].at(jLayer)->Fill( (predStubTheta - stubThetaInt)/predStubThetaError ); + } + else if ( isLs ) + { + mapWS_v_hDeltaPhiResid_TK_L[thisKey].at(jLayer)->Fill( tempDeltaPhi ); + mapWS_v_hDeltaThetaResid_TK_L[thisKey].at(jLayer)->Fill( predStubTheta - stubThetaInt ); + mapWS_v_hDeltaPhiPull_TK_L[thisKey].at(jLayer)->Fill( tempDeltaPhi/predStubPhiError ); + mapWS_v_hDeltaThetaPull_TK_L[thisKey].at(jLayer)->Fill( (predStubTheta - stubThetaInt)/predStubThetaError ); + } + + } /// End of loop over stubs + } + + } /// End of check over null muon TrackingParticle + + } /// End of loop over DTMatches + + + /// Fill the plots for the efficiency + std::map< edm::Ptr< TrackingParticle >, std::vector< bool > >::const_iterator iterMapMu; + + for ( iterMapMu = mapMuonTrackingParticleInDTDigi.begin(); + iterMapMu != mapMuonTrackingParticleInDTDigi.end(); + ++iterMapMu ) + { + edm::Ptr< TrackingParticle > thisMuon = iterMapMu->first; + std::vector< bool > theseFlags = iterMapMu->second; + + hMuonTP_Pt_DT->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DT->Fill( thisMuon->p4().pt() ); + + /// 0) DTTF + if ( theseFlags.at(0) == true ) + { + hMuonTP_Pt_DTTF->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTTF->Fill( thisMuon->p4().pt() ); + } + + /// 1) DTMatch + if ( theseFlags.at(1) == true ) + { + hMuonTP_Pt_DTMatch->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch->Fill( thisMuon->p4().pt() ); + } + + /// 2) DTMatch + Stubs, Priority + if ( theseFlags.at(2) == true ) + { + hMuonTP_Pt_DTMatch_Priority->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch_Priority->Fill( thisMuon->p4().pt() ); + } + + /// 3) DTMatch + Stubs, Average + if ( theseFlags.at(3) == true ) + { + hMuonTP_Pt_DTMatch_Average->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch_Average->Fill( thisMuon->p4().pt() ); + } + + /// 4) DTMatch + Stubs, Majority Full Tracker + if ( theseFlags.at(4) == true ) + { + hMuonTP_Pt_DTMatch_MajorityFull->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch_MajorityFull->Fill( thisMuon->p4().pt() ); + } + + /// 5) DTMatch + Stubs, Majority + if ( theseFlags.at(5) == true ) + { + hMuonTP_Pt_DTMatch_Majority->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch_Majority->Fill( thisMuon->p4().pt() ); + } + + /// 6) DTMatch + Stubs, Mixed Mode + if ( theseFlags.at(6) == true ) + { + hMuonTP_Pt_DTMatch_MixedMode->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch_MixedMode->Fill( thisMuon->p4().pt() ); + } + + /// 7) DTMatch + TTTrack + if ( theseFlags.at(1) == true ) + { + hMuonTP_Pt_DTMatch_TTTrack->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch_TTTrack->Fill( thisMuon->p4().pt() ); + } + + } /// End of loop over sim muons + + + +} /// End of analyze() + +/////////////////////////// +// DEFINE THIS AS A PLUG-IN +DEFINE_FWK_MODULE(AnalyzerDTMatches); + diff --git a/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py new file mode 100644 index 0000000000000..d0238e22360c2 --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py @@ -0,0 +1,136 @@ +muonPtString = '20' + +#################################################### +# SLHCUpgradeSimulations # +# Configuration file for Full Workflow # +# Step 2 (again) # +# Understand if everything is fine with # +# L1TkCluster e L1TkStub # +#################################################### +# Nicola Pozzobon # +# CERN, August 2012 # +#################################################### + +################################################################################################# +# import of general framework +################################################################################################# +import FWCore.ParameterSet.Config as cms + +################################################################################################# +# name the process +################################################################################################# +process = cms.Process('AnalyzerDTMatches') + +################################################################################################# +# global tag +################################################################################################# +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') + +################################################################################################# +# load the specific tracker geometry +################################################################################################# +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') + +################################################################################################# +# load the magnetic field +################################################################################################# +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') +#process.load('Configuration.StandardSequences.MagneticField_40T_cff') +#------------------process.VolumeBasedMagneticFieldESProducer.useParametrizedTrackerField = True + +################################################################################################# +# define the source and maximum number of events to process +################################################################################################# +process.source = cms.Source( + "PoolSource", + secondaryFileNames = cms.untracked.vstring(), + fileNames = cms.untracked.vstring( + "file:TwoMuPt_25_Extended2023TTI_50000_DIGI_L1_DIGI2RAW_L1TT_RECO_V001_3_1_H5r.root", + ) +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +################################################################################################# +# load the analyzer +################################################################################################# +process.AnalyzerDTMatches = cms.EDAnalyzer("AnalyzerDTMatches", + BothCharges = cms.bool(False), + GetPositive = cms.bool(True), +) + +################################################################################################# +# define output file and message logger +################################################################################################# +process.TFileService = cms.Service("TFileService", + fileName = cms.string('file:AnalyzerDTMatches_Extended2023TTI_'+muonPtString+'.root') +) + +################################################################################################# +# now, all the DT related stuff +################################################################################################# +# to produce, in case, collection of L1MuDTTrack objects: +#process.dttfDigis = cms.Path(process.simDttfDigis) + +# the DT geometry +process.load("Geometry.DTGeometry.dtGeometry_cfi") +process.load("Geometry.MuonNumbering.muonNumberingInitialization_cfi") +process.load("SimMuon/DTDigitizer/muonDTDigis_cfi") +##process.load("L1TriggerConfig.DTTPGConfigProducers.L1DTTPGConfig_cff") + +################################################################################################# +# define the producer of DT + TK objects +################################################################################################# +process.load("L1Trigger.DTPlusTrackTrigger.DTPlusTrackProducer_cfi") +process.DTPlusTk_step = cms.Path(process.DTPlusTrackProducer) + +################################################################################################# +# produce the L1 Tracks +################################################################################################# +process.load('Configuration.StandardSequences.L1TrackTrigger_cff') +process.TrackFindingTracklet_step = cms.Path(process.TrackTriggerTTTracks) + +#process.load('L1Trigger.TrackFindingAM.L1AMTrack_cfi') +#process.TrackFindingAM_step = cms.Path(process.TTTracksFromPixelDigisAM) + +process.load('SimTracker.TrackTriggerAssociation.TrackTriggerAssociator_cff') +process.TTTrackAssociatorFromPixelDigis = cms.EDProducer("TTTrackAssociator_PixelDigi_", + TTTracks = cms.VInputTag(cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks")), + TTStubTruth = cms.InputTag("TTStubAssociatorFromPixelDigis","StubAccepted"), + TTClusterTruth = cms.InputTag("TTClusterAssociatorFromPixelDigis","ClusterAccepted") +) +process.L1TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) + +################################################################################################# +# Make the job crash in case of missing product +################################################################################################# +process.options = cms.untracked.PSet( + Rethrow = cms.untracked.vstring('ProductNotFound') +) + +################################################################################################# +# define the final path to be fed to cmsRun +################################################################################################# +process.Plots_step = cms.Path( process.AnalyzerDTMatches ) + + +process.eca = cms.EDAnalyzer("EventContentAnalyzer") +process.eca_step = cms.Path(process.eca) + +################################################################################################# +process.schedule = cms.Schedule( +# process.TrackFindingTracklet_step, +# process.TrackFindingAM_step, +# process.L1TTAssociator_step, + process.DTPlusTk_step, + process.Plots_step, +# process.eca_step, +#process.end +) + diff --git a/L1Trigger/DTPlusTrackTrigger/test/BuildFile.xml b/L1Trigger/DTPlusTrackTrigger/test/BuildFile.xml new file mode 100644 index 0000000000000..99dbff051373c --- /dev/null +++ b/L1Trigger/DTPlusTrackTrigger/test/BuildFile.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/L1Trigger/DTTrigger/BuildFile.xml b/L1Trigger/DTTrigger/BuildFile.xml index 4ffc3d4a27f06..2a22cb90a02c4 100644 --- a/L1Trigger/DTTrigger/BuildFile.xml +++ b/L1Trigger/DTTrigger/BuildFile.xml @@ -16,4 +16,11 @@ - + + + + + + + + diff --git a/L1Trigger/DTTrigger/src/DTTrig.cc b/L1Trigger/DTTrigger/src/DTTrig.cc index c537afb52a7c1..f58ac997fc666 100644 --- a/L1Trigger/DTTrigger/src/DTTrig.cc +++ b/L1Trigger/DTTrigger/src/DTTrig.cc @@ -235,6 +235,9 @@ DTTrig::updateES(const edm::EventSetup& iSetup){ edm::ESHandle confHandle; edm::ESHandle geomHandle; +//std:cerr << " >>>>>>>>>>> "<().cacheIdentifier()<< " "<<_configid <().cacheIdentifier()!=_configid) { if (_debug) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py index 92b5699aaf43f..2d2bafe8c79bf 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py @@ -4,7 +4,7 @@ process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(20) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) # # This runs over a file that already contains the L1Tracks. @@ -14,12 +14,72 @@ # that have been created. +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * + process.source = cms.Source("PoolSource", - fileNames = cms.untracked.vstring( + fileNames = minBiasFiles_p1 + #fileNames = cms.untracked.vstring( # single muons - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_53.root' - #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Muons/PU140/m1_SingleMuon_E2023TTI_PU140.root' - ) +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_1.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_10.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_11.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_12.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_13.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_14.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_15.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_16.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_17.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_18.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_19.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_2.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_20.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_21.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_22.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_23.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_24.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_25.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_26.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_27.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_28.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_29.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_3.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_30.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_31.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_32.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_33.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_34.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_35.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_36.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_37.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_38.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_39.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_4.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_40.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_42.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_43.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_44.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_45.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_46.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_47.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_48.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_49.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_5.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_50.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_51.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_52.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_53.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_54.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_55.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_56.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_57.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_58.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_59.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_6.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_60.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_7.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_8.root", +#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_9.root" + #) ) @@ -35,13 +95,8 @@ # --------------------------------------------------------------------------- # -# --- Produces the L1EG objects +# --- Produces the Run-1 L1muon objects # - # To produce L1EG objects corresponding to the "stage-2" algorithms: - # one runs the SLHCCaloTrigger sequence. This produces both the - # "old stage-2" objects (2x2 clustering) and the "new stage-2" - # objects (new clustering from JB Sauvan et al). Note that the - # efficiency of the latter is currently poor at very high PU. process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') @@ -50,12 +105,17 @@ process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') -#process.load('Configuration/StandardSequences/L1HwVal_cff') -#process.load('Configuration.StandardSequences.RawToDigi_cff') -#process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +# --- creates l1extra objects for L1Muons + + # raw2digi to get the GT digis +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.p0 = cms.Path( process.RawToDigi ) + # run L1Reco +process.load('Configuration.StandardSequences.L1Reco_cff') +process.L1Reco = cms.Path( process.l1extraParticles ) + + -#process.load('Configuration.StandardSequences.L1Reco_cff') -#process.L1Reco = cms.Path( process.l1extraParticles ) # # --------------------------------------------------------------------------- @@ -117,13 +177,16 @@ process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "example.root" ), + fileName = cms.untracked.string( "example_CentralMuons.root" ), fastCloning = cms.untracked.bool( False ), outputCommands = cms.untracked.vstring( 'drop *') ) process.Out.outputCommands.append('keep *_L1TkMuons_*_*') + +process.Out.outputCommands.append('keep *L1Muon*_l1extraParticles_*_*') + #process.Out.outputCommands.append('keep *_DTPlusTrackProducer_*_*') # raw data From 200c02adc8143490c409f987919de277d84e4972 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 27 May 2014 18:15:21 +0200 Subject: [PATCH 013/252] port back the MuRef and the quality for L1TkMuons from 61X --- .../interface/L1TkMuonParticle.h | 5 +++ .../L1TrackTrigger/src/L1TkMuonParticle.cc | 16 ++++++++ .../L1TrackTrigger/test/PrintL1TkObjects.cc | 37 ++++++++++++++++++- .../test/test_L1TkEGamma_cfg.py | 4 +- .../L1TrackTrigger/test/test_L1TkMuon.py | 37 +++++++++++++++---- 5 files changed, 88 insertions(+), 11 deletions(-) diff --git a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h index 0afdc84357e36..c46ef6b0c7d65 100644 --- a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h +++ b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h @@ -53,6 +53,9 @@ namespace l1extra { // const edm::Ref< XXXCollection >& getMuRef() const // { return muRef_ ; } + const edm::Ref< L1MuonParticleCollection >& getMuRef() const + { return muRef_ ; } + float getTrkzVtx() const { return TrkzVtx_ ; } float getTrkIsol() const { return TrkIsol_ ; } @@ -63,6 +66,8 @@ namespace l1extra { void setTrkIsol(float TrkIsol) { TrkIsol_ = TrkIsol ; } int bx() const; + unsigned int quality() const; + //void setDeltaR(float dr) { DeltaR_ = dr ; } private: diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index 10be385fe906e..2e3b2c9e470b3 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -48,5 +48,21 @@ int L1TkMuonParticle::bx() const { } +unsigned int L1TkMuonParticle::quality() const { + + int dummy = 999; + + if ( muRef_.isNonnull() ) { + return (getMuRef() -> gmtMuonCand().quality() ); + } + else { + return dummy; + + } + +} + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc b/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc index bae7f8737d135..6e3e93b454cb3 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc @@ -52,6 +52,8 @@ #include "DataFormats/L1TrackTrigger/interface/L1TkJetParticleFwd.h" #include "DataFormats/L1TrackTrigger/interface/L1TkHTMissParticle.h" #include "DataFormats/L1TrackTrigger/interface/L1TkHTMissParticleFwd.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticleFwd.h" #include "TFile.h" #include "TH1F.h" @@ -106,6 +108,10 @@ class PrintL1TkObjects : public edm::EDAnalyzer { // for L1TkHTMParticle edm::InputTag L1TkHTMInputTag; + + // for L1TkMuonParticle + edm::InputTag L1TkMuonsInputTag; + }; // @@ -130,6 +136,8 @@ PrintL1TkObjects::PrintL1TkObjects(const edm::ParameterSet& iConfig) L1TkPhotonsInputTag = iConfig.getParameter("L1TkPhotonsInputTag"); L1TkJetsInputTag = iConfig.getParameter("L1TkJetsInputTag"); L1TkHTMInputTag = iConfig.getParameter("L1TkHTMInputTag"); + L1TkMuonsInputTag = iConfig.getParameter("L1TkMuonsInputTag"); + } @@ -158,9 +166,7 @@ PrintL1TkObjects::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetu edm::Handle HepMCEvt; -std::cout << " ici " << std::endl; iEvent.getByLabel("generator",HepMCEvt); -std::cout << " ici2 " << HepMCEvt.isValid() << std::endl; float zvtx_gen = -999; @@ -372,6 +378,33 @@ std::cout << " ici2 " << HepMCEvt.isValid() << std::endl; } } + // + // ---------------------------------------------------------------------- + // retrieve the L1TkMuons + // + + edm::Handle L1TkMuonsHandle; + iEvent.getByLabel(L1TkMuonsInputTag, L1TkMuonsHandle); + std::vector::const_iterator muIter; + + if ( L1TkMuonsHandle.isValid() ) { + std::cout << " ----- L1TkMuonPaticle objects ---- " << std::endl; + for (muIter = L1TkMuonsHandle -> begin(); muIter != L1TkMuonsHandle->end(); ++muIter) { + float pt = muIter -> pt(); + float eta = muIter -> eta(); + float phi = muIter -> phi(); + float zvtx = muIter -> getTrkzVtx(); + unsigned int quality = muIter -> quality(); + // access the quality via the reference : + const edm::Ref< L1MuonParticleCollection > MuRef = muIter -> getMuRef(); + unsigned int qualityBis = MuRef -> gmtMuonCand().quality(); + std::cout << " a muon candidate pt eta phi " << pt << " " << eta << " " << phi << " zvertex = " << zvtx << std::endl; + std::cout << " quality (the two qual flags are the same by definition) = " << quality << " " << qualityBis << std::endl; + + } + } + + } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py index 7ec5db1121b3f..d255b7a9637a1 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py @@ -146,7 +146,9 @@ L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here - L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI",""), # dummy here + L1TkMuonsInputTag = cms.InputTag("L1TkMuons","") # dummy here + ) #process.pAna = cms.Path( process.ana ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py index 9e6c8903d8887..0fb5f0109c332 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py @@ -22,17 +22,17 @@ process.source = cms.Source("PoolSource", # replace 'myfile.root' with the source file you want to use fileNames = cms.untracked.vstring( - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC8/BE5D/SingleMu_NoPU.root' + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_55.root' ) ) -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5DReco_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5D_cff') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + # --- creates l1extra objects for L1Muons @@ -52,6 +52,27 @@ +# --------------------------------------------------------------------------- + + +# Run a trivial analyzer that prints the objects + +process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , + L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here + L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here + L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), # dummy here + L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), # dummy here + L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI",""), # dummy here + L1TkMuonsInputTag = cms.InputTag("L1TkMuons","") + +) + +process.pAna = cms.Path( process.ana ) + + + + # --------------------------------------------------------------------------- @@ -66,10 +87,10 @@ # genlevel information -process.Out.outputCommands.append('keep *_generator_*_*') -process.Out.outputCommands.append('keep *_*gen*_*_*') -process.Out.outputCommands.append('keep *_*Gen*_*_*') -process.Out.outputCommands.append('keep *_rawDataCollector_*_*') +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') # the L1Tracks, clusters and stubs process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') From e936c98ef1163d5fb1f77c05a19886252a9fb4f7 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 28 May 2014 09:47:56 +0200 Subject: [PATCH 014/252] fix L1TkEtMissProducer.cc (saturation option); update the example test_L1TkCalo_cfg.py to also run with the L1Jets --- .../L1TrackTrigger/plugins/L1TkEtMissProducer.cc | 2 +- .../L1TrackTrigger/test/test_L1TkCalo_cfg.py | 11 ++++------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc index 066f98c586f29..d21eabd19b9a0 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc @@ -235,7 +235,7 @@ L1TkEtMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) if ( PTMAX > 0 && pt > PTMAX) { if (HighPtTracks == 0) continue; // ignore these very high PT tracks. if (HighPtTracks == 1) { - pt_rescale = pt / PTMAX ; // will be used to rescale px and py + pt_rescale = PTMAX / pt; // will be used to rescale px and py pt = PTMAX; // saturate } } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py index ba62747271234..820500fc65df8 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py @@ -9,9 +9,6 @@ # and the tracker digis. # It creates HT and MHT, from the L1Jets and from the HLT HI jets. # -# so far, the creation of TkObjects from L1Jets is commented, as -# we don't have yet the "KIT version" of the L1Jets in 620_SLHC. -# process.source = cms.Source("PoolSource", @@ -20,7 +17,7 @@ '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' ) ) -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) # initialize MessageLogger and output report @@ -59,7 +56,7 @@ process.load('Configuration.StandardSequences.RawToDigi_cff') process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") -process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets +#process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets process.p = cms.Path( process.RawToDigi+ @@ -83,8 +80,8 @@ process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkCaloSequence_cff") -# -- Produce L1TkJets, HT and MHT from the L1Jets : /// temporarily commented -#process.L1TkCaloL1Jets = cms.Path( process.L1TkCaloSequence ) +# -- Produce L1TkJets, HT and MHT from the L1Jets : +process.L1TkCaloL1Jets = cms.Path( process.L1TkCaloSequence ) # -- Produce the HLT JI Jets and L1TkJets, HT and MHT from these jets : process.L1TkCaloHIJets = cms.Path( process.L1TkCaloSequenceHI ) From 80e3a784aaa252bf52fcb1c1286f89836f0c066e Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 28 May 2014 18:43:11 +0200 Subject: [PATCH 015/252] renamed TkMuonDTProducer, added TkMuonMerger, added back some stuff in TkMuonParticle --- .../interface/L1TkMuonParticle.h | 27 ++- .../L1TrackTrigger/src/L1TkMuonParticle.cc | 56 ++++- .../L1TrackTrigger/src/classes_def.xml | 4 +- ...kMuonProducer.cc => L1TkMuonDTProducer.cc} | 20 +- .../L1TrackTrigger/plugins/L1TkMuonMerger.cc | 207 ++++++++++++++++++ ...cer.cc.backup => L1TkMuonNaiveProducer.cc} | 30 +-- .../python/L1TkMuonProducer_cfi.py | 2 +- .../python/singleMuonFiles_cfi.py | 63 ++++++ .../L1TrackTrigger/test/PrintL1TkObjects.cc | 2 - 9 files changed, 379 insertions(+), 32 deletions(-) rename SLHCUpgradeSimulations/L1TrackTrigger/plugins/{L1TkMuonProducer.cc => L1TkMuonDTProducer.cc} (94%) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonMerger.cc rename SLHCUpgradeSimulations/L1TrackTrigger/plugins/{L1TkMuonProducer.cc.backup => L1TkMuonNaiveProducer.cc} (90%) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/singleMuonFiles_cfi.py diff --git a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h index 0292cf096c986..00381625cf427 100644 --- a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h +++ b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h @@ -36,18 +36,43 @@ namespace l1extra L1TkMuonParticle( const LorentzVector& p4, const edm::Ptr< DTMatch >& muRef, float tkisol = -999. ); + + L1TkMuonParticle( const LorentzVector& p4, + const edm::Ref< L1MuonParticleCollection >& muRef, + const edm::Ptr< L1TkTrackType >& trkPtr, + float tkisol = -999. ); + virtual ~L1TkMuonParticle() {} // const member functions const edm::Ptr< DTMatch >& getDTMatchPtr() const { return theDTMatch; } + + const edm::Ptr< L1TkTrackType >& getTrkPtr() const + { return trkPtr_ ; } + float getTrkIsol() const { return theIsolation; } + float getTrkzVtx() const { return TrkzVtx_ ; } + + int bx() const ; + + void setTrkzVtx(float TrkzVtx) { TrkzVtx_ = TrkzVtx ; } + void setTrkIsol(float TrkIsol) { theIsolation = TrkIsol ; } + + unsigned int quality() const; - int bx() const { return theDTMatch->getDTBX(); } private: + + // used for Padova's muons: edm::Ptr< DTMatch > theDTMatch; + + // used for the Naive producer + edm::Ref< L1MuonParticleCollection > muRef_ ; + edm::Ptr< L1TkTrackType > trkPtr_ ; + float theIsolation; + float TrkzVtx_ ; }; } diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index d7c77eddd0563..65d6fa2183940 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -9,6 +9,7 @@ using namespace l1extra; L1TkMuonParticle::L1TkMuonParticle() {} + // Padova's TkMuons L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, const edm::Ptr< DTMatch > &muRef, float tkisol ) @@ -16,7 +17,60 @@ L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, theDTMatch ( muRef ) , theIsolation ( tkisol ) { - // other constructor operations if needed + // need to set the z of the track } + + // Naive TkMuons +L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, + const edm::Ref< L1MuonParticleCollection > &muRef, + const edm::Ptr< L1TkTrackType >& trkPtr, + float tkisol ) + : LeafCandidate( ( char ) 0, p4 ), + muRef_ ( muRef ) , + trkPtr_ ( trkPtr ) , + theIsolation ( tkisol ) + +{ + + if ( trkPtr_.isNonnull() ) { + float z = getTrkPtr() -> getPOCA().z(); + setTrkzVtx( z ); + } +} + + +int L1TkMuonParticle::bx() const { + int dummy = -999; + + if (theDTMatch.isNonnull() ) { + return theDTMatch->getDTBX(); + } + + if (muRef_.isNonnull() ) { + return dummy; + } + + return dummy; +} + + +unsigned int L1TkMuonParticle::quality() const { + + int dummy = 999; + + if ( muRef_.isNonnull() ) { + return (muRef_ -> gmtMuonCand().quality() ); + } + else { + return dummy; + } +} + + + + + + + diff --git a/DataFormats/L1TrackTrigger/src/classes_def.xml b/DataFormats/L1TrackTrigger/src/classes_def.xml index e45542a4e2398..ea6a351143da2 100644 --- a/DataFormats/L1TrackTrigger/src/classes_def.xml +++ b/DataFormats/L1TrackTrigger/src/classes_def.xml @@ -84,8 +84,8 @@ - - + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonDTProducer.cc similarity index 94% rename from SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc rename to SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonDTProducer.cc index bf2bf7538a7cf..7277411e0dc84 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonDTProducer.cc @@ -37,14 +37,14 @@ using namespace l1extra; // class declaration -class L1TkMuonParticleProducer : public edm::EDProducer +class L1TkMuonDTProducer : public edm::EDProducer { public: typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - explicit L1TkMuonParticleProducer( const edm::ParameterSet& ); - ~L1TkMuonParticleProducer(); + explicit L1TkMuonDTProducer( const edm::ParameterSet& ); + ~L1TkMuonDTProducer(); static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); @@ -55,7 +55,7 @@ class L1TkMuonParticleProducer : public edm::EDProducer }; // constructors and destructor -L1TkMuonParticleProducer::L1TkMuonParticleProducer( const edm::ParameterSet& iConfig ) +L1TkMuonDTProducer::L1TkMuonDTProducer( const edm::ParameterSet& iConfig ) { produces< L1TkMuonParticleCollection >("DTMatchInwardsPriority"); produces< L1TkMuonParticleCollection >("DTMatchInwardsAverage"); @@ -66,10 +66,10 @@ L1TkMuonParticleProducer::L1TkMuonParticleProducer( const edm::ParameterSet& iCo produces< L1TkMuonParticleCollection >("DTMatchInwardsTTTrackFullReso"); } -L1TkMuonParticleProducer::~L1TkMuonParticleProducer() {} +L1TkMuonDTProducer::~L1TkMuonDTProducer() {} // method called to produce the data -void L1TkMuonParticleProducer::produce( edm::Event& iEvent, const edm::EventSetup& iSetup ) +void L1TkMuonDTProducer::produce( edm::Event& iEvent, const edm::EventSetup& iSetup ) { using namespace edm; using namespace std; @@ -268,14 +268,14 @@ void L1TkMuonParticleProducer::produce( edm::Event& iEvent, const edm::EventSetu } // method called once each job just before starting event loop -void L1TkMuonParticleProducer::beginJob() {} +void L1TkMuonDTProducer::beginJob() {} // method called once each job just after ending the event loop -void L1TkMuonParticleProducer::endJob() {} +void L1TkMuonDTProducer::endJob() {} // ------------ method fills 'descriptions' with the allowed parameters for the module ------------ void -L1TkMuonParticleProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { +L1TkMuonDTProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { //The following says we do not know what parameters are allowed so do no validation // Please change this to state exactly what you do use, even if it is no parameters edm::ParameterSetDescription desc; @@ -285,5 +285,5 @@ L1TkMuonParticleProducer::fillDescriptions(edm::ConfigurationDescriptions& descr //define this as a plug-in -DEFINE_FWK_MODULE(L1TkMuonParticleProducer); +DEFINE_FWK_MODULE(L1TkMuonDTProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonMerger.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonMerger.cc new file mode 100644 index 0000000000000..f9e49a4530d70 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonMerger.cc @@ -0,0 +1,207 @@ +// -*- C++ -*- +// +// + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" + +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Utilities/interface/InputTag.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticleFwd.h" + +#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" + +#include "DataFormats/Math/interface/LorentzVector.h" + + +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +#include +#include "TMath.h" + + +using namespace l1extra ; +using namespace edm; +using namespace std; + +// +// class declaration +// + +class L1TkMuonMerger : public edm::EDProducer { + public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + explicit L1TkMuonMerger(const edm::ParameterSet&); + ~L1TkMuonMerger(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + //virtual void beginRun(edm::Run&, edm::EventSetup const&); + //virtual void endRun(edm::Run&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // ----------member data --------------------------- + + std::vector TkMuonCollections; + std::vector absEtaMin; + std::vector absEtaMax; + +} ; + + +// +// constructors and destructor +// +L1TkMuonMerger::L1TkMuonMerger(const edm::ParameterSet& iConfig) +{ + + TkMuonCollections = iConfig.getParameter< std::vector >("TkMuonCollections"); + absEtaMin = iConfig.getParameter< std::vector >("absEtaMin"); + absEtaMax = iConfig.getParameter< std::vector >("absEtaMax"); + + int n1 = TkMuonCollections.size(); + int n2 = absEtaMin.size(); + int n3 = absEtaMax.size(); + if ( (n1 != n2) || (n1 != n3) ) { + edm::LogError("L1TkMuonMerger") + << "\n Error in configuration. TkMuonCollections, absEtaMin and absEtaMax should have the sme size. Exit. " + << std::endl; + } + + produces(); +} + +L1TkMuonMerger::~L1TkMuonMerger() { +} + +// ------------ method called to produce the data ------------ +void +L1TkMuonMerger::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + using namespace std; + + + std::auto_ptr result(new L1TkMuonParticleCollection); + + int ncollections = TkMuonCollections.size(); + //cout << " There are " << ncollections << " collections to merge " << std::endl; + + for (int icol=0; icol < ncollections; icol++) { + + edm::InputTag MuonInputTag = TkMuonCollections.at( icol ); + //cout << " Collection: " << MuonInputTag << endl; + + edm::Handle< vector > MuonHandle ; + iEvent.getByLabel( MuonInputTag, MuonHandle ); + + if (! MuonHandle.isValid() ) { + LogError("L1TkMuonMerger") + << "\nWarning: TkMuon collection " << MuonInputTag + << "\nrequested in configuration, but not found in the event. Skip it." + << std::endl; + } + + vector::const_iterator l1MuIter; + + for (l1MuIter = MuonHandle->begin(); l1MuIter != MuonHandle->end(); ++l1MuIter) { + float eta = l1MuIter -> eta(); + float feta = fabs(eta); + if ( feta < absEtaMin[icol] || feta > absEtaMax[icol] ) continue; + + + L1TkMuonParticle tkmuon = *l1MuIter; + + result -> push_back( tkmuon ); + } // end collection + } + + + + iEvent.put( result ); + +} + +// -------------------------------------------------------------------------------------- + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TkMuonMerger::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TkMuonMerger::endJob() { +} + +// ------------ method called when starting to processes a run ------------ +/* +void +L1TkMuonMerger::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) +{ +} +*/ + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1TkMuonMerger::endRun(edm::Run&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1TkMuonMerger::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1TkMuonMerger::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TkMuonMerger::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TkMuonMerger); + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc.backup b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonNaiveProducer.cc similarity index 90% rename from SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc.backup rename to SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonNaiveProducer.cc index eaf692df19520..c80ee6968fd1e 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonProducer.cc.backup +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonNaiveProducer.cc @@ -47,14 +47,14 @@ using namespace l1extra ; // class declaration // -class L1TkMuonParticleProducer : public edm::EDProducer { +class L1TkMuonNaiveProducer : public edm::EDProducer { public: typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - explicit L1TkMuonParticleProducer(const edm::ParameterSet&); - ~L1TkMuonParticleProducer(); + explicit L1TkMuonNaiveProducer(const edm::ParameterSet&); + ~L1TkMuonNaiveProducer(); static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); @@ -93,7 +93,7 @@ class L1TkMuonParticleProducer : public edm::EDProducer { // // constructors and destructor // -L1TkMuonParticleProducer::L1TkMuonParticleProducer(const edm::ParameterSet& iConfig) +L1TkMuonNaiveProducer::L1TkMuonNaiveProducer(const edm::ParameterSet& iConfig) { //L1PLInputTag = iConfig.getParameter("L1PLInputTag"); @@ -113,12 +113,12 @@ L1TkMuonParticleProducer::L1TkMuonParticleProducer(const edm::ParameterSet& iCon produces(); } -L1TkMuonParticleProducer::~L1TkMuonParticleProducer() { +L1TkMuonNaiveProducer::~L1TkMuonNaiveProducer() { } // ------------ method called to produce the data ------------ void -L1TkMuonParticleProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +L1TkMuonNaiveProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { using namespace edm; using namespace std; @@ -240,7 +240,7 @@ L1TkMuonParticleProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSe std::vector::const_iterator muIter ; if (!XXXHandle.isValid() ) { - LogError("L1TkMuonParticleProducer") + LogError("L1TkMuonNaiveProducer") << "\nWarning: L1XXXCollectionType with " << L1PLInputTag << "\nrequested in configuration, but not found in the event. Exit." << std::endl; @@ -296,19 +296,19 @@ L1TkMuonParticleProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSe // ------------ method called once each job just before starting event loop ------------ void -L1TkMuonParticleProducer::beginJob() +L1TkMuonNaiveProducer::beginJob() { } // ------------ method called once each job just after ending the event loop ------------ void -L1TkMuonParticleProducer::endJob() { +L1TkMuonNaiveProducer::endJob() { } // ------------ method called when starting to processes a run ------------ /* void -L1TkMuonParticleProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) +L1TkMuonNaiveProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) { } */ @@ -316,7 +316,7 @@ L1TkMuonParticleProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup // ------------ method called when ending the processing of a run ------------ /* void -L1TkMuonParticleProducer::endRun(edm::Run&, edm::EventSetup const&) +L1TkMuonNaiveProducer::endRun(edm::Run&, edm::EventSetup const&) { } */ @@ -324,7 +324,7 @@ L1TkMuonParticleProducer::endRun(edm::Run&, edm::EventSetup const&) // ------------ method called when starting to processes a luminosity block ------------ /* void -L1TkMuonParticleProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +L1TkMuonNaiveProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) { } */ @@ -332,14 +332,14 @@ L1TkMuonParticleProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::Event // ------------ method called when ending the processing of a luminosity block ------------ /* void -L1TkMuonParticleProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +L1TkMuonNaiveProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) { } */ // ------------ method fills 'descriptions' with the allowed parameters for the module ------------ void -L1TkMuonParticleProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { +L1TkMuonNaiveProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { //The following says we do not know what parameters are allowed so do no validation // Please change this to state exactly what you do use, even if it is no parameters edm::ParameterSetDescription desc; @@ -348,7 +348,7 @@ L1TkMuonParticleProducer::fillDescriptions(edm::ConfigurationDescriptions& descr } //define this as a plug-in -DEFINE_FWK_MODULE(L1TkMuonParticleProducer); +DEFINE_FWK_MODULE(L1TkMuonNaiveProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonProducer_cfi.py index e320fb43155f2..c7e4fa2ecbd07 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonProducer_cfi.py @@ -1,6 +1,6 @@ import FWCore.ParameterSet.Config as cms -L1TkMuons = cms.EDProducer("L1TkMuonParticleProducer", +L1TkMuonsNaive = cms.EDProducer("L1TkMuonNaiveProducer", L1MuonsInputTag = cms.InputTag("l1extraParticles"), L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), ETAMIN = cms.double(0), diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/singleMuonFiles_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/singleMuonFiles_cfi.py new file mode 100644 index 0000000000000..e65a5fa6786c3 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/singleMuonFiles_cfi.py @@ -0,0 +1,63 @@ +import FWCore.ParameterSet.Config as cms + +singleMuonFiles = cms.untracked.vstring( +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_1.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_10.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_11.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_12.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_13.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_14.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_15.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_16.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_17.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_18.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_19.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_2.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_20.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_21.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_22.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_23.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_24.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_25.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_26.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_27.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_28.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_29.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_3.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_30.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_31.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_32.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_33.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_34.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_35.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_36.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_37.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_38.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_39.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_4.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_40.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_42.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_43.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_44.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_45.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_46.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_47.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_48.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_49.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_5.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_50.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_51.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_52.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_53.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_54.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_55.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_56.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_57.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_58.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_59.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_6.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_60.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_7.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_8.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_9.root" +) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc b/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc index bae7f8737d135..3e315d070f172 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/PrintL1TkObjects.cc @@ -158,9 +158,7 @@ PrintL1TkObjects::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetu edm::Handle HepMCEvt; -std::cout << " ici " << std::endl; iEvent.getByLabel("generator",HepMCEvt); -std::cout << " ici2 " << HepMCEvt.isValid() << std::endl; float zvtx_gen = -999; From 7bb6dd248d4b5e1a8c77aea6f8330a854bb45083 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Thu, 29 May 2014 11:32:41 -0500 Subject: [PATCH 016/252] add L1MuonParticleExtended; allow to set most data members; add constructor requiring just the candidate --- .../interface/L1TkMuonParticle.h | 27 +++++++++++--- .../L1TrackTrigger/src/L1TkMuonParticle.cc | 35 +++++++++---------- .../L1TrackTrigger/src/classes_def.xml | 3 +- 3 files changed, 40 insertions(+), 25 deletions(-) diff --git a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h index 00381625cf427..39cc7e970d1e1 100644 --- a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h +++ b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h @@ -22,6 +22,8 @@ #include "DataFormats/L1Trigger/interface/L1MuonParticle.h" #include "DataFormats/L1Trigger/interface/L1MuonParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1MuonParticleExtended.h" +#include "DataFormats/L1Trigger/interface/L1MuonParticleExtendedFwd.h" namespace l1extra { @@ -32,7 +34,7 @@ namespace l1extra typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - L1TkMuonParticle(); + L1TkMuonParticle() : theIsolation(-999.), TrkzVtx_(999.), quality_(999) {} L1TkMuonParticle( const LorentzVector& p4, const edm::Ptr< DTMatch >& muRef, float tkisol = -999. ); @@ -42,6 +44,9 @@ namespace l1extra const edm::Ptr< L1TkTrackType >& trkPtr, float tkisol = -999. ); + //! more basic constructor, in case refs/ptrs can't be set or to be set separately + L1TkMuonParticle(const reco::LeafCandidate& cand) : reco::LeafCandidate(cand), theIsolation(-999.), TrkzVtx_(999.), quality_(999) {} + virtual ~L1TkMuonParticle() {} // const member functions @@ -50,16 +55,27 @@ namespace l1extra const edm::Ptr< L1TkTrackType >& getTrkPtr() const { return trkPtr_ ; } + const L1MuonParticleRef& getMuRef() const + { return muRef_ ; } + + const L1MuonParticleExtendedRef& getMuExtendedRef() const + { return muExtendedRef_ ; } + float getTrkIsol() const { return theIsolation; } float getTrkzVtx() const { return TrkzVtx_ ; } int bx() const ; - void setTrkzVtx(float TrkzVtx) { TrkzVtx_ = TrkzVtx ; } - void setTrkIsol(float TrkIsol) { theIsolation = TrkIsol ; } + unsigned int quality() const {return quality_;} - unsigned int quality() const; + void setTrkPtr(const edm::Ptr< L1TkTrackType >& p) {trkPtr_ = p;} + void setMuRef(const L1MuonParticleRef& r){muRef_ = r;} + void setMuExtendedRef(const L1MuonParticleExtendedRef& r){muExtendedRef_ = r;} + + void setTrkzVtx(float TrkzVtx) { TrkzVtx_ = TrkzVtx ; } + void setTrkIsol(float TrkIsol) { theIsolation = TrkIsol ; } + void setQuality(unsigned int q){ quality_ = q;} private: @@ -69,11 +85,12 @@ namespace l1extra // used for the Naive producer edm::Ref< L1MuonParticleCollection > muRef_ ; + L1MuonParticleExtendedRef muExtendedRef_ ; edm::Ptr< L1TkTrackType > trkPtr_ ; float theIsolation; float TrkzVtx_ ; - + unsigned int quality_; }; } diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index 65d6fa2183940..abb2b7bd86427 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -7,15 +7,15 @@ using namespace l1extra; -L1TkMuonParticle::L1TkMuonParticle() {} - // Padova's TkMuons L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, const edm::Ptr< DTMatch > &muRef, float tkisol ) : LeafCandidate( ( char ) 0, p4 ), theDTMatch ( muRef ) , - theIsolation ( tkisol ) + theIsolation ( tkisol ), + TrkzVtx_(999.), + quality_(999) { // need to set the z of the track @@ -30,14 +30,18 @@ L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, : LeafCandidate( ( char ) 0, p4 ), muRef_ ( muRef ) , trkPtr_ ( trkPtr ) , - theIsolation ( tkisol ) - + theIsolation ( tkisol ), + TrkzVtx_(999), + quality_(999) { if ( trkPtr_.isNonnull() ) { float z = getTrkPtr() -> getPOCA().z(); setTrkzVtx( z ); } + if (muRef_.isNonnull()) { + quality_ = muRef_->gmtMuonCand().quality(); + } } @@ -48,26 +52,19 @@ int L1TkMuonParticle::bx() const { return theDTMatch->getDTBX(); } - if (muRef_.isNonnull() ) { - return dummy; + // PL. In case Pierluigi's objects have a bx + if ( muRef_.isNonnull() ) { + return (getMuRef() -> bx()) ; + } + else if (muExtendedRef_.isNonnull()) { + return getMuExtendedRef()->bx(); + } return dummy; } -unsigned int L1TkMuonParticle::quality() const { - - int dummy = 999; - - if ( muRef_.isNonnull() ) { - return (muRef_ -> gmtMuonCand().quality() ); - } - else { - return dummy; - } -} - diff --git a/DataFormats/L1TrackTrigger/src/classes_def.xml b/DataFormats/L1TrackTrigger/src/classes_def.xml index ea6a351143da2..12e7b9ef72a2d 100644 --- a/DataFormats/L1TrackTrigger/src/classes_def.xml +++ b/DataFormats/L1TrackTrigger/src/classes_def.xml @@ -84,7 +84,8 @@ - + + From b90889fc5d01c2d2197a7ec82e600cae6f348474 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Fri, 23 May 2014 14:42:40 -0500 Subject: [PATCH 017/252] L1MuonParticleExtended to add more handles to details of standalone L1 muon inputs --- .../interface/L1MuonParticleExtended.h | 107 ++++++++++++++++++ .../interface/L1MuonParticleExtendedFwd.h | 25 ++++ .../L1Trigger/src/L1MuonParticleExtended.cc | 15 +++ DataFormats/L1Trigger/src/classes.h | 8 ++ DataFormats/L1Trigger/src/classes_def.xml | 13 +++ 5 files changed, 168 insertions(+) create mode 100644 DataFormats/L1Trigger/interface/L1MuonParticleExtended.h create mode 100644 DataFormats/L1Trigger/interface/L1MuonParticleExtendedFwd.h create mode 100644 DataFormats/L1Trigger/src/L1MuonParticleExtended.cc diff --git a/DataFormats/L1Trigger/interface/L1MuonParticleExtended.h b/DataFormats/L1Trigger/interface/L1MuonParticleExtended.h new file mode 100644 index 0000000000000..cba01c898844e --- /dev/null +++ b/DataFormats/L1Trigger/interface/L1MuonParticleExtended.h @@ -0,0 +1,107 @@ +#ifndef L1Trigger_L1MuonParticleExtended_h +#define L1Trigger_L1MuonParticleExtended_h +// -*- C++ -*- +// +// Package: L1Trigger +// Class : L1MuonParticleExtended +// +// Description: L1MuonParticle with detector layer information. +// Should be useful from the start for detailed analysis of efficiency etc +// Expect this to become feasible for future upgrade hardware. + +// user include files +#include "DataFormats/L1Trigger/interface/L1MuonParticle.h" +#include "DataFormats/Candidate/interface/LeafCandidate.h" + +#include "DataFormats/L1GlobalMuonTrigger/interface/L1MuRegionalCand.h" +#include "DataFormats/DetId/interface/DetId.h" + +// forward declarations + +namespace l1extra { + + class L1MuonParticleExtended : public L1MuonParticle { + public: + L1MuonParticleExtended() : sigmaEta_(-99), sigmaPhi_(-99), quality_(0) {} + + L1MuonParticleExtended( const L1MuonParticle& l1mu) : L1MuonParticle(l1mu), sigmaEta_(-99), sigmaPhi_(-99), quality_(0) {} + + virtual ~L1MuonParticleExtended() {} + + + struct StationData { + StationData() : station(-1), ringOrWheel(-99), bx(-99), quality(-99), + phi(-99), sigmaPhi(-99), + eta(-99), sigmaEta(-99), + bendPhi(-99), bendEta(-99), + bendPhiInt(-99), bendEtaInt(-99), + valid(false) {} + DetId id; + int station; //a bit wasteful + int ringOrWheel; + int bx; + int quality; + float phi; + float sigmaPhi; + float eta; + float sigmaEta; + float bendPhi; //! direction.phi - position.phi + float bendEta; //! direction.eta - position.eta + + int bendPhiInt; //magic word from primitives about phi direction + int bendEtaInt; //magic word from primitives about eta or theta direction + + bool valid; + }; + + // ---------- const member functions --------------------- + virtual L1MuonParticleExtended* clone() const + { return new L1MuonParticleExtended( *this ) ; } + + // ---------- member functions --------------------------- + const L1MuRegionalCand& cscCand() const {return cscCand_;} + void setCscCand(const L1MuRegionalCand& cand) {cscCand_ = cand;} + + const L1MuRegionalCand& rpcCand() const {return rpcCand_;} + void setRpcCand(const L1MuRegionalCand& cand) {rpcCand_ = cand;} + + const L1MuRegionalCand& dtCand() const {return dtCand_;} + void setDtCand(const L1MuRegionalCand& cand) {dtCand_ = cand;} + + float sigmaEta() const { return sigmaEta_; } + void setSigmaEta(float val) {sigmaEta_ = val;} + + float sigmaPhi() const { return sigmaPhi_; } + void setSigmaPhi(float val) {sigmaPhi_ = val;} + + unsigned int quality() const {return quality_;} + void setQuality(unsigned int q) {quality_ = q;} + + const StationData& cscData(unsigned int s ) const {return (s>0 && s<= 4) ? cscData_[s-1] : dummyData_; } + void setCscData(const StationData& sd, unsigned int s) {if (s>0 && s<= 4) cscData_[s-1] = sd; } + + const StationData& dtData(unsigned int s ) const {return (s>0 && s<= 4) ? dtData_[s-1] : dummyData_; } + void setDtData(const StationData& sd, unsigned int s) {if (s>0 && s<= 4) dtData_[s-1] = sd; } + + const StationData& rpcData(unsigned int s ) const {return (s>0 && s<= 4) ? rpcData_[s-1] : dummyData_; } + void setRpcData(const StationData& sd, unsigned int s) {if (s>0 && s<= 4) rpcData_[s-1] = sd; } + private: + // ---------- member data -------------------------------- + L1MuRegionalCand cscCand_; + L1MuRegionalCand rpcCand_; + L1MuRegionalCand dtCand_; + + float sigmaEta_; + float sigmaPhi_; + + unsigned int quality_; + + StationData cscData_[4]; + StationData dtData_[4]; + StationData rpcData_[4]; + + StationData dummyData_; + }; +} + +#endif diff --git a/DataFormats/L1Trigger/interface/L1MuonParticleExtendedFwd.h b/DataFormats/L1Trigger/interface/L1MuonParticleExtendedFwd.h new file mode 100644 index 0000000000000..5605c7b039beb --- /dev/null +++ b/DataFormats/L1Trigger/interface/L1MuonParticleExtendedFwd.h @@ -0,0 +1,25 @@ +#ifndef L1Trigger_L1MuonParticleExtendedFwd_h +#define L1Trigger_L1MuonParticleExtendedFwd_h +// -*- C++ -*- +// +// Package: L1Trigger +// Class : L1MuonParticleExtendedFwd +// + +#include +#include "DataFormats/Common/interface/Ref.h" +#include "DataFormats/Common/interface/RefVector.h" + + +namespace l1extra { + + class L1MuonParticleExtended ; + + typedef std::vector< L1MuonParticleExtended > L1MuonParticleExtendedCollection ; + + typedef edm::Ref< L1MuonParticleExtendedCollection > L1MuonParticleExtendedRef ; + typedef edm::RefVector< L1MuonParticleExtendedCollection > L1MuonParticleExtendedRefVector ; + typedef std::vector< L1MuonParticleExtendedRef > L1MuonParticleExtendedVectorRef ; +} + +#endif diff --git a/DataFormats/L1Trigger/src/L1MuonParticleExtended.cc b/DataFormats/L1Trigger/src/L1MuonParticleExtended.cc new file mode 100644 index 0000000000000..0af2e9ad546bf --- /dev/null +++ b/DataFormats/L1Trigger/src/L1MuonParticleExtended.cc @@ -0,0 +1,15 @@ +// -*- C++ -*- +// +// Package: L1Trigger +// Class : L1MuonParticleExtended +// +// + +// system include files + +// user include files +#include "DataFormats/L1Trigger/interface/L1MuonParticleExtended.h" + +using namespace l1extra ; + + diff --git a/DataFormats/L1Trigger/src/classes.h b/DataFormats/L1Trigger/src/classes.h index fac481f156227..9dfa6b55a4182 100644 --- a/DataFormats/L1Trigger/src/classes.h +++ b/DataFormats/L1Trigger/src/classes.h @@ -11,6 +11,8 @@ #include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" #include "DataFormats/L1Trigger/interface/L1MuonParticle.h" #include "DataFormats/L1Trigger/interface/L1MuonParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1MuonParticleExtended.h" +#include "DataFormats/L1Trigger/interface/L1MuonParticleExtendedFwd.h" #include "DataFormats/L1Trigger/interface/L1EtMissParticle.h" #include "DataFormats/L1Trigger/interface/L1EtMissParticleFwd.h" #include "DataFormats/L1Trigger/interface/L1ParticleMap.h" @@ -29,6 +31,7 @@ namespace { l1extra::L1EmParticleCollection emColl ; l1extra::L1JetParticleCollection jetColl ; l1extra::L1MuonParticleCollection muonColl ; + l1extra::L1MuonParticleExtendedCollection muonCollE ; l1extra::L1EtMissParticle etMiss ; l1extra::L1EtMissParticleCollection etMissColl ; l1extra::L1ParticleMapCollection mapColl ; @@ -37,6 +40,7 @@ namespace { edm::Wrapper w_emColl; edm::Wrapper w_jetColl; edm::Wrapper w_muonColl; + edm::Wrapper w_muonCollE; edm::Wrapper w_etMiss; edm::Wrapper w_etMissColl; edm::Wrapper w_mapColl; @@ -45,18 +49,21 @@ namespace { l1extra::L1EmParticleRef refEm ; l1extra::L1JetParticleRef refJet ; l1extra::L1MuonParticleRef refMuon ; + l1extra::L1MuonParticleExtendedRef refMuonE ; l1extra::L1EtMissParticleRef refEtMiss ; l1extra::L1HFRingsRef refHFRings ; l1extra::L1EmParticleRefVector refVecEmColl ; l1extra::L1JetParticleRefVector refVecJetColl ; l1extra::L1MuonParticleRefVector refVecMuonColl ; + l1extra::L1MuonParticleExtendedRefVector refVecMuonCollE ; l1extra::L1EtMissParticleRefVector refVecEtMiss ; l1extra::L1HFRingsRefVector refVecHFRings ; l1extra::L1EmParticleVectorRef vecRefEmColl ; l1extra::L1JetParticleVectorRef vecRefJetColl ; l1extra::L1MuonParticleVectorRef vecRefMuonColl ; + l1extra::L1MuonParticleExtendedVectorRef vecRefMuonCollE ; l1extra::L1EtMissParticleVectorRef vecRefEtMissColl ; l1extra::L1HFRingsVectorRef vecRefHFRingsColl ; @@ -64,6 +71,7 @@ namespace { edm::reftobase::Holder rtbe; edm::reftobase::Holder rtbm; + edm::reftobase::Holder rtbmE; edm::reftobase::Holder rtbj; edm::reftobase::Holder rtbm1; edm::reftobase::Holder rtbm2; diff --git a/DataFormats/L1Trigger/src/classes_def.xml b/DataFormats/L1Trigger/src/classes_def.xml index 522304c763cc6..f8eff615bf793 100644 --- a/DataFormats/L1Trigger/src/classes_def.xml +++ b/DataFormats/L1Trigger/src/classes_def.xml @@ -8,6 +8,12 @@ + + + + + + @@ -20,12 +26,14 @@ + + @@ -34,18 +42,21 @@ + + + @@ -55,6 +66,8 @@ + + From 083e52a38a32d556525ce64802c542de7c0a96c6 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Fri, 23 May 2014 14:46:30 -0500 Subject: [PATCH 018/252] produce a collection of L1MuonParticleExtended. Details are available only for CSC. For other detectors, it's only marginally more useful than L1MuonParticle. Needs work from other areas --- .../python/l1extraMuExtended_cfi.py | 8 + .../src/L1MuonParticleExtendedProducer.cc | 317 ++++++++++++++++++ 2 files changed, 325 insertions(+) create mode 100644 L1Trigger/L1ExtraFromDigis/python/l1extraMuExtended_cfi.py create mode 100644 L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc diff --git a/L1Trigger/L1ExtraFromDigis/python/l1extraMuExtended_cfi.py b/L1Trigger/L1ExtraFromDigis/python/l1extraMuExtended_cfi.py new file mode 100644 index 0000000000000..bac9c68fc222c --- /dev/null +++ b/L1Trigger/L1ExtraFromDigis/python/l1extraMuExtended_cfi.py @@ -0,0 +1,8 @@ +import FWCore.ParameterSet.Config as cms + +l1extraMuExtended = cms.EDProducer( + "L1MuonParticleExtendedProducer", + gmtROSource = cms.InputTag("simGmtDigis"), + csctfSource = cms.InputTag("simCsctfTrackDigis"), + writeAllCSCTFs = cms.bool(True) + ) diff --git a/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc new file mode 100644 index 0000000000000..6f762762a634a --- /dev/null +++ b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc @@ -0,0 +1,317 @@ +// -*- C++ -*- +// +// Class: L1MuonParticleExtendedProducer +// +// + + +// system include files +#include + +// user include files +#include "Geometry/Records/interface/MuonGeometryRecord.h" +#include "Geometry/CSCGeometry/interface/CSCGeometry.h" + +#include "CondFormats/L1TObjects/interface/L1MuTriggerScales.h" +#include "CondFormats/DataRecord/interface/L1MuTriggerScalesRcd.h" +#include "CondFormats/L1TObjects/interface/L1MuTriggerPtScale.h" +#include "CondFormats/DataRecord/interface/L1MuTriggerPtScaleRcd.h" +#include "DataFormats/L1GlobalMuonTrigger/interface/L1MuGMTReadoutCollection.h" +#include "DataFormats/L1CSCTrackFinder/interface/L1CSCTrackCollection.h" + +#include "DataFormats/L1Trigger/interface/L1MuonParticleExtended.h" +#include "DataFormats/L1Trigger/interface/L1MuonParticleExtendedFwd.h" + +#include "L1Trigger/CSCCommonTrigger/interface/CSCConstants.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "DataFormats/Common/interface/OrphanHandle.h" + +#include "DataFormats/Math/interface/deltaPhi.h" + +// +// class declaration +// +class L1MuonParticleExtendedProducer : public edm::EDProducer { +public: + explicit L1MuonParticleExtendedProducer(const edm::ParameterSet&); + ~L1MuonParticleExtendedProducer() {} + +private: + virtual void produce(edm::Event&, const edm::EventSetup&); + + edm::InputTag gmtROSource_ ; + edm::InputTag csctfSource_ ; + + bool writeAllCSCTFs_; + + static const double muonMassGeV_ ; + +}; + + +// +// static data member definitions +// + +const double L1MuonParticleExtendedProducer::muonMassGeV_ = 0.105658369 ; // PDG06 + +// +// constructors and destructor +// +L1MuonParticleExtendedProducer::L1MuonParticleExtendedProducer(const edm::ParameterSet& iConfig) + : gmtROSource_( iConfig.getParameter< edm::InputTag >("gmtROSource" ) ), + csctfSource_(iConfig.getParameter< edm::InputTag >("csctfSource")), + writeAllCSCTFs_(iConfig.getParameter< bool>("writeAllCSCTFs")) +{ + using namespace l1extra ; + + //register your products + produces< L1MuonParticleExtendedCollection >() ; + if (writeAllCSCTFs_) produces< L1MuonParticleExtendedCollection >("csc") ; +} + + +// ------------ method called to produce the data ------------ +void +L1MuonParticleExtendedProducer::produce( edm::Event& iEvent, + const edm::EventSetup& iSetup) +{ + using namespace edm ; + using namespace l1extra ; + using namespace std ; + using namespace reco ; + + auto_ptr< L1MuonParticleExtendedCollection > muColl( new L1MuonParticleExtendedCollection ); + auto_ptr< L1MuonParticleExtendedCollection > cscColl( new L1MuonParticleExtendedCollection ); + + ESHandle< L1MuTriggerScales > muScales ; + iSetup.get< L1MuTriggerScalesRcd >().get( muScales ) ; + + ESHandle< L1MuTriggerPtScale > muPtScale ; + iSetup.get< L1MuTriggerPtScaleRcd >().get( muPtScale ) ; + + Handle< L1MuGMTReadoutCollection > gmtRO_h ; + iEvent.getByLabel( gmtROSource_, gmtRO_h ) ; + const L1MuGMTReadoutCollection& gmtROs(*gmtRO_h.product()); + + Handle csctftH; + iEvent.getByLabel(csctfSource_, csctftH); + const L1CSCTrackCollection& csctfts(*csctftH.product()); + + ESHandle cscGH; + iSetup.get().get(cscGH); + const CSCGeometry* csc_geometry = &*cscGH; + + + int curMuCollIdx = -1; //index of the GMT-based + for (auto gmtRO : gmtROs.getRecords()){ + vector cscGmtIdxs(4,-1); //index into muColl for a given CSC cand + for (auto const gmtCand : gmtRO.getGMTCands() ){ + if (gmtCand.empty()) continue; + + float pt = muPtScale->getPtScale()->getLowEdge( gmtCand.ptIndex() ) + 1.e-6 ; + float eta = muScales->getGMTEtaScale()->getCenter( gmtCand.etaIndex() ) ; + float phi = muScales->getPhiScale()->getLowEdge( gmtCand.phiIndex() ) ; + + + float etaP = muScales->getGMTEtaScale()->getCenter( gmtCand.etaIndex() +1 ) ; + float phiP = muScales->getPhiScale()->getLowEdge( gmtCand.phiIndex() +1 ) ; + + float etaM = muScales->getGMTEtaScale()->getCenter( gmtCand.etaIndex() -1) ; + float phiM = muScales->getPhiScale()->getLowEdge( gmtCand.phiIndex() -1) ; + + math::PtEtaPhiMLorentzVector p4( pt, eta, phi, muonMassGeV_); + L1MuonParticle l1muP(gmtCand.charge(), p4, gmtCand, gmtCand.bx()); + int cscGmtIdx = -1; + if (!gmtCand.isRPC() && gmtCand.isFwd()) cscGmtIdx = gmtCand.getDTCSCIndex(); + + muColl->push_back(L1MuonParticleExtended(l1muP)); + curMuCollIdx++; + if (cscGmtIdx>=0) cscGmtIdxs[cscGmtIdx] = curMuCollIdx; + L1MuonParticleExtended* aGmtCand = &muColl->back(); + + float sigmaEta=99; + float dEtaP = std::abs(etaP - eta); + float dEtaM = std::abs(etaM - eta); + if (dEtaP < 1 && dEtaM < 1 && dEtaP > 0 && dEtaM > 0){ + sigmaEta = sqrt(dEtaP*dEtaM); //take geom mean for no particular reason + } else if (dEtaP < 1 || dEtaM < 1) { + sigmaEta = dEtaP < dEtaM && dEtaP >0 ? dEtaP : dEtaM; + } + sigmaEta = sigmaEta/sqrt(12.); + + float sigmaPhi=99; + float dPhiP = std::abs(deltaPhi(phiP, phi)); + float dPhiM = std::abs(deltaPhi(phiM, phi)); + if (dPhiP < 1 && dPhiM < 1 && dPhiP > 0 && dPhiM > 0){ + sigmaPhi = sqrt(dPhiP*dPhiM); //take geom mean for no particular reason + } else if (dPhiP < 1 || dPhiM < 1) { + sigmaPhi = dPhiP < dPhiM && dPhiP > 0 ? dPhiP : dPhiM; + } + sigmaPhi = sigmaPhi/sqrt(12.); + + aGmtCand->setSigmaEta(sigmaEta); + aGmtCand->setSigmaEta(sigmaPhi); + aGmtCand->setQuality(gmtCand.quality()); + + } + if (1< 2){ //at the moment this is not really "ALL", just up to 4 from CSCTF + unsigned cscInd = -1; + for (auto const csctfReg : gmtRO.getCSCCands() ){ + cscInd++; + if (csctfReg.empty()) continue; + + float pt = muPtScale->getPtScale()->getLowEdge( csctfReg.pt_packed() ) + 1.e-6 ; + float eta = muScales->getRegionalEtaScale(csctfReg.type_idx())->getCenter(csctfReg.eta_packed()); + float phi = muScales->getPhiScale()->getLowEdge( csctfReg.phi_packed() ) ; + + float etaP = muScales->getRegionalEtaScale(csctfReg.type_idx())->getCenter(csctfReg.eta_packed() + 1); + float phiP = muScales->getPhiScale()->getLowEdge( csctfReg.phi_packed() +1 ) ; + float etaM = muScales->getRegionalEtaScale(csctfReg.type_idx())->getCenter(csctfReg.eta_packed() -1); + float phiM = muScales->getPhiScale()->getLowEdge( csctfReg.phi_packed() -1 ) ; + + int gmtIdx = cscGmtIdxs[cscInd]; + L1MuonParticleExtended* gmtParticle = 0; + if (gmtIdx >=0) gmtParticle = &(*muColl)[gmtIdx]; + L1MuGMTExtendedCand gmtCand = gmtParticle != 0 ? gmtParticle->gmtMuonCand() : L1MuGMTExtendedCand(); + + math::PtEtaPhiMLorentzVector p4( pt, eta, phi, muonMassGeV_); + int qCand = csctfReg.chargeValid() ? csctfReg.chargeValue() : 0; + L1MuonParticle l1muP(qCand, p4, gmtCand, csctfReg.bx()); + + L1MuonParticleExtended cscParticleTmp(l1muP); + cscParticleTmp.setCscCand(csctfReg); + if (gmtParticle) gmtParticle->setCscCand(csctfReg); + cscColl->push_back(cscParticleTmp); + L1MuonParticleExtended* cscParticle = &cscColl->back(); + + float sigmaEta=99; + float dEtaP = std::abs(etaP - eta); + float dEtaM = std::abs(etaM - eta); + if (dEtaP < 1 && dEtaM < 1 && dEtaP > 0 && dEtaM > 0){ + sigmaEta = sqrt(dEtaP*dEtaM); //take geom mean for no particular reason + } else if (dEtaP < 1 || dEtaM < 1) { + sigmaEta = dEtaP < dEtaM && dEtaP >0 ? dEtaP : dEtaM; + } + sigmaEta = sigmaEta/sqrt(12.); + + float sigmaPhi=99; + float dPhiP = std::abs(deltaPhi(phiP, phi)); + float dPhiM = std::abs(deltaPhi(phiM, phi)); + if (dPhiP < 1 && dPhiM < 1 && dPhiP > 0 && dPhiM > 0){ + sigmaPhi = sqrt(dPhiP*dPhiM); //take geom mean for no particular reason + } else if (dPhiP < 1 || dPhiM < 1) { + sigmaPhi = dPhiP < dPhiM && dPhiP > 0 ? dPhiP : dPhiM; + } + sigmaPhi = sigmaPhi/sqrt(12.); + + cscParticle->setSigmaEta(sigmaEta); + cscParticle->setSigmaPhi(sigmaPhi); + + unsigned int qual = 0; + if (gmtParticle) qual = gmtParticle->quality(); + else { + unsigned int qualC = csctfReg.quality(); + if (qualC ==2) qual = 3; + if (qualC ==3) qual = 6; + } + cscParticle->setQuality(qual); + + //now get the details, not the most optimal way .. not a big deal here + unsigned int roWord = csctfReg.getDataWord(); + for (auto csctfFull : csctfts){ + auto cscL1Tk = csctfFull.first; + unsigned int fWord = cscL1Tk.getDataWord(); + //there's probably a more obvious way to match (just by local phi,sector,eta,etc) + if (cscL1Tk.endcap() == 2) fWord |= (1<< (L1MuRegionalCand::ETA_START+L1MuRegionalCand::ETA_LENGTH-1)); + unsigned int fQuality = 0; + unsigned int fPt = 0; + cscL1Tk.decodeRank(cscL1Tk.rank(), fPt, fQuality); + fWord |= (fQuality<< L1MuRegionalCand::QUAL_START); + fWord |= (fPt << L1MuRegionalCand::PT_START); + //from L1Trigger/CSCTrackFinder/src/CSCTFMuonSorter.cc + unsigned int fgPhi = cscL1Tk.localPhi() + (cscL1Tk.sector() -1)*24 + 6; + if(fgPhi > 143) fgPhi -= 143; + fWord |= (fgPhi << L1MuRegionalCand::PHI_START); + // edm::LogWarning("MYDEBUG")<<"Checking or vs other "<4 || aStation<1) { + edm::LogError("BADLCTID")<<"got station "<chamber(anID)->layer(CSCConstants::KEY_CLCT_LAYER)->geometry(); + + typedef L1MuonParticleExtended::StationData StationData; + StationData sData; + for (; aDigi != anLCT.second.second; ++aDigi){ + sData.valid = true; + sData.id = anID.rawId(); + sData.station = aStation; + sData.ringOrWheel = aRing; + sData.bx = aDigi->getBX()-6; //offset to be centered at zero as all higher level objects have it + sData.quality = aDigi->getQuality(); + + int aWG = aDigi->getKeyWG(); + int aHS = aDigi->getStrip(); + float fStrip = 0.5*(aHS+1) - 0.25 ; //mind the offset + float fWire = layer_geometry->middleWireOfGroup(aWG+1); + LocalPoint wireStripPoint = layer_geometry->intersectionOfStripAndWire(fStrip, fWire); + CSCDetId key_id(anID.endcap(), anID.station(), anID.ring(), anID.chamber(), CSCConstants::KEY_CLCT_LAYER); + GlobalPoint gp = csc_geometry->idToDet(key_id)->surface().toGlobal(wireStripPoint); + sData.phi = gp.phi(); + sData.eta = gp.eta(); + + int deltaWire = aWG +1 < layer_geometry->numberOfWireGroups() ? 1 : -1; + int deltaStrip = fStrip +1 <= layer_geometry->numberOfStrips() ? 1 : -1; + + float fStripD1 = fStrip+0.5*deltaStrip; + float fWireD1 = layer_geometry->middleWireOfGroup(aWG+1 + deltaWire); + LocalPoint wireStripPlus1 = layer_geometry->intersectionOfStripAndWire(fStripD1, fWireD1); + GlobalPoint gpD1 = csc_geometry->idToDet(key_id)->surface().toGlobal(wireStripPlus1); + float dPhi = std::abs(deltaPhi(gp.phi(), gpD1.phi())); + + float dEta = fabs(gp.eta() - gpD1.eta()); + + if (dEta<1E-3){ + edm::LogWarning("SmallDeltaEta")<<" st "<< aStation<<" r "<getCLCTPattern(); + if (aDigi->getBend()) sData.bendPhiInt*=-1; + } //LCTs for a given anID + + cscParticle->setCscData(sData, aStation); + if (gmtParticle) gmtParticle->setCscData(sData, aStation); + } //LCT range for anID + }//matched full CSCTF track collection with the current L1MuRegionalCand + }//loop over csctfts + } + } + } + + iEvent.put( muColl ); + if (writeAllCSCTFs_) iEvent.put( cscColl, "csc" ); +} + + +//define this as a plug-in +DEFINE_FWK_MODULE(L1MuonParticleExtendedProducer); From b839da0b8c355f6512c0463506cdbd12e83920a2 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Fri, 23 May 2014 14:46:58 -0500 Subject: [PATCH 019/252] missing dependencies --- L1Trigger/L1ExtraFromDigis/BuildFile.xml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/L1Trigger/L1ExtraFromDigis/BuildFile.xml b/L1Trigger/L1ExtraFromDigis/BuildFile.xml index f74cab6b5bf89..95c472fedfbd8 100644 --- a/L1Trigger/L1ExtraFromDigis/BuildFile.xml +++ b/L1Trigger/L1ExtraFromDigis/BuildFile.xml @@ -4,7 +4,10 @@ + + + From 3b29339bb907cb0e089e50b4aac57ff58837b074 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Thu, 29 May 2014 09:43:54 -0500 Subject: [PATCH 020/252] produce L1TkMuons from L1MuonParticleExtended as input. Full functionality of L1MuonParticleExtended is still not used (current impl would've worked with just the L1MuonParticle with a few extra hacks) --- .../plugins/L1TkMuonFromExtendedProducer.cc | 325 ++++++++++++++++++ .../L1TrackTrigger/python/l1TkMuonsExt_cff.py | 14 + .../L1TrackTrigger/python/l1TkMuonsExt_cfi.py | 19 + 3 files changed, 358 insertions(+) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cff.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc new file mode 100644 index 0000000000000..c305cd8480aa7 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc @@ -0,0 +1,325 @@ +// -*- C++ -*- +// +// input: L1 TkTracks and L1MuonParticleExtended (standalone with component details) +// match the two and produce a collection of L1TkMuonParticle +// eventually, this should be made modular and allow to swap out different algorithms + + +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkMuonParticleFwd.h" + + +// for L1Tracks: +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" + +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" + +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Utilities/interface/InputTag.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "DataFormats/Math/interface/LorentzVector.h" +#include "DataFormats/Math/interface/deltaR.h" +#include "DataFormats/Math/interface/deltaPhi.h" + +#include "TMath.h" + +// system include files +#include +#include + + +using namespace l1extra ; + +// +// class declaration +// + +class L1TkMuonFromExtendedProducer : public edm::EDProducer { +public: + + typedef L1TkTrack_PixelDigi_ L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + struct PropState { //something simple, imagine it's hardware emulation + PropState() : + pt(-99), eta(-99), phi(-99), + sigmaPt(-99), sigmaEta(-99), sigmaPhi(-99), + valid(false) {} + float pt; + float eta; + float phi; + float sigmaPt; + float sigmaEta; + float sigmaPhi; + bool valid; + + }; + + explicit L1TkMuonFromExtendedProducer(const edm::ParameterSet&); + ~L1TkMuonFromExtendedProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + +private: + virtual void produce(edm::Event&, const edm::EventSetup&); + + PropState propagateToGMT(const L1TkTrackType& l1tk) const; + + //configuration (preserving structure of L1TkMuonFromExtendedProducer + edm::InputTag L1MuonsInputTag_; + edm::InputTag L1TrackInputTag_; + + float ETAMIN_; + float ETAMAX_; + float ZMAX_; // |z_track| < ZMAX in cm + float CHI2MAX_; + float PTMINTRA_; + // float DRmax_; + int nStubsmin_ ; // minimum number of stubs + // bool closest_ ; + bool correctGMTPropForTkZ_; + +} ; + + +// +// constructors and destructor +// +L1TkMuonFromExtendedProducer::L1TkMuonFromExtendedProducer(const edm::ParameterSet& iConfig) +{ + + + L1MuonsInputTag_ = iConfig.getParameter("L1MuonsInputTag"); + L1TrackInputTag_ = iConfig.getParameter("L1TrackInputTag"); + + ETAMIN_ = (float)iConfig.getParameter("ETAMIN"); + ETAMAX_ = (float)iConfig.getParameter("ETAMAX"); + ZMAX_ = (float)iConfig.getParameter("ZMAX"); + CHI2MAX_ = (float)iConfig.getParameter("CHI2MAX"); + PTMINTRA_ = (float)iConfig.getParameter("PTMINTRA"); + // DRmax_ = (float)iConfig.getParameter("DRmax"); + nStubsmin_ = iConfig.getParameter("nStubsmin"); + // closest_ = iConfig.getParameter("closest"); + + correctGMTPropForTkZ_ = iConfig.getParameter("correctGMTPropForTkZ"); + + produces(); +} + +L1TkMuonFromExtendedProducer::~L1TkMuonFromExtendedProducer() { +} + +// ------------ method called to produce the data ------------ +void +L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + using namespace std; + + + std::auto_ptr tkMuons(new L1TkMuonParticleCollection); + + edm::Handle l1musH; + iEvent.getByLabel(L1MuonsInputTag_, l1musH); + const L1MuonParticleExtendedCollection& l1mus = *l1musH.product(); + + edm::Handle l1tksH; + iEvent.getByLabel(L1TrackInputTag_, l1tksH); + const L1TkTrackCollectionType& l1tks = *l1tksH.product(); + + L1TkMuonParticleCollection l1tkmuCands; + l1tkmuCands.reserve(l1mus.size()*4); //can do more if really needed + + int imu = -1; + for (auto l1mu : l1mus){ + imu++; + L1MuonParticleExtendedRef l1muRef(l1musH, imu); + + float l1mu_eta = l1mu.eta(); + float l1mu_phi = l1mu.phi(); + + float l1mu_feta = fabs( l1mu_eta ); + if (l1mu_feta < ETAMIN_) continue; + if (l1mu_feta > ETAMAX_) continue; + + // can skip quality cuts at the moment, keep bx=0 req + if (l1mu.bx() != 0) continue; + + unsigned int l1mu_quality = l1mu.quality(); + + const auto& gmtCand = l1mu.gmtMuonCand(); + if (!gmtCand.empty()){ + //some selections here + //currently the input can be a merge from different track finders + //so, the GMT cand may be missing + } + + const auto& dtCand = l1mu.dtCand(); + if (!dtCand.empty()){ + // something can be called from here + } + + const auto& cscCand = l1mu.cscCand(); + if (!cscCand.empty()){ + //apply something specific here + } + + float drmin = 999; + float ptmax = -1; + if (ptmax < 0) ptmax = -1; // dummy + + PropState matchProp; + int match_idx = -1; + int il1tk = -1; + + LogDebug("MDEBUG")<<"have a gmt, look for a match "; + for (auto l1tk : l1tks ){ + il1tk++; + float l1tk_pt = l1tk.getMomentum().perp(); + if (l1tk_pt < PTMINTRA_) continue; + + float l1tk_z = l1tk.getVertex().z(); + if (fabs(l1tk_z) > ZMAX_) continue; + + float l1tk_chi2 = l1tk.getChi2(); + if (l1tk_chi2 > CHI2MAX_) continue; + + int l1tk_nstubs = l1tk.getStubPtrs().size(); + if ( l1tk_nstubs < nStubsmin_) continue; + + float l1tk_eta = l1tk.getMomentum().eta(); + float l1tk_phi = l1tk.getMomentum().phi(); + + + float dr2 = deltaR2(l1mu_eta, l1mu_phi, l1tk_eta, l1tk_phi); + + if (dr2 > 0.3) continue; + + PropState pstate = propagateToGMT(l1tk); + if (!pstate.valid) continue; + + float dr2prop = deltaR2(l1mu_eta, l1mu_phi, pstate.eta, pstate.phi); + + if (dr2prop < drmin){ + drmin = dr2prop; + match_idx = il1tk; + matchProp = pstate; + } + }// over l1tks + + LogDebug("MYDEBUG")<<"matching index is "<= 0){ + const L1TkTrackType& matchTk = l1tks[match_idx]; + + float etaCut = 3.*sqrt(l1mu.sigmaEta()*l1mu.sigmaEta() + matchProp.sigmaEta*matchProp.sigmaEta); + float phiCut = 4.*sqrt(l1mu.sigmaPhi()*l1mu.sigmaPhi() + matchProp.sigmaPhi*matchProp.sigmaPhi); + + float dEta = std::abs(matchProp.eta - l1mu.eta()); + float dPhi = std::abs(deltaPhi(matchProp.phi, l1mu.phi())); + + LogDebug("MYDEBUG")<<"match details: prop "< l1tkPtr(l1tksH, match_idx); + auto p3 = matchTk.getMomentum(); + float p4e = sqrt(0.105658369*0.105658369 + p3.mag()); + math::XYZTLorentzVector l1tkp4(p3.x(), p3.y(), p3.z(), p4e); + + auto tkv3=matchTk.getVertex(); + math::XYZPoint v3(tkv3.x(), tkv3.y(), tkv3.z()); + float trkisol = -999; + int l1tk_q = matchTk.getRInv()>0? 1: -1; + + L1TkMuonParticle l1tkmu(reco::LeafCandidate(l1tk_q, l1tkp4, v3, -13*l1tk_q )); + l1tkmu.setTrkPtr(l1tkPtr); + l1tkmu.setMuExtendedRef(l1muRef); + l1tkmu.setQuality(l1mu_quality); + l1tkmu.setTrkIsol(trkisol); + tkMuons->push_back(l1tkmu); + } + } + + }//over l1mus + + + iEvent.put( tkMuons ); + +} + + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TkMuonFromExtendedProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + + +L1TkMuonFromExtendedProducer::PropState L1TkMuonFromExtendedProducer::propagateToGMT(const L1TkMuonFromExtendedProducer::L1TkTrackType& tk) const { + auto p3 = tk.getMomentum(); + float tk_pt = p3.perp(); + float tk_p = p3.mag(); + float tk_eta = p3.eta(); + float tk_aeta = std::abs(tk_eta); + float tk_phi = p3.phi(); + float tk_q = tk.getRInv()>0? 1.: -1.; + float tk_z = tk.getVertex().z(); + if (!correctGMTPropForTkZ_) tk_z = 0; + + L1TkMuonFromExtendedProducer::PropState dest; + if (tk_p<3.5 ) return dest; + if (tk_aeta <1.1 && tk_pt < 3.5) return dest; + if (tk_aeta > 2.5) return dest; + + //0th order: + dest.valid = true; + + float dzCorrPhi = 1.; + float deta = 0; + float etaProp = tk_aeta; + + if (tk_aeta < 1.1){ + etaProp = 1.1; + deta = tk_z/550./cosh(tk_aeta); + } else { + float delta = tk_z/850.; //roughly scales as distance to 2nd station + if (tk_eta > 0) delta *=-1; + dzCorrPhi = 1. + delta; + + float zOzs = tk_z/850.; + if (tk_eta > 0) deta = zOzs/(1. - zOzs); + else deta = zOzs/(1.+zOzs); + deta = deta*tanh(tk_eta); + } + float resPhi = tk_phi - 1.464*tk_q*cosh(1.7)/cosh(etaProp)/tk_pt*dzCorrPhi - M_PI/144.; + if (resPhi > M_PI) resPhi -= 2.*M_PI; + if (resPhi < -M_PI) resPhi += 2.*M_PI; + + dest.eta = tk_eta + deta; + dest.phi = resPhi; + dest.pt = tk_pt; //not corrected for eloss + + dest.sigmaEta = 0.100/tk_pt; //multiple scattering term + dest.sigmaPhi = 0.106/tk_pt; //need a better estimate for these + return dest; +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TkMuonFromExtendedProducer); + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cff.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cff.py new file mode 100644 index 0000000000000..56e44adbfa292 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cff.py @@ -0,0 +1,14 @@ +import FWCore.ParameterSet.Config as cms + +from SLHCUpgradeSimulations.L1TrackTrigger.l1TkMuonsExt_cfi import l1TkMuonsExt +l1TkMuonsExtCSC = l1TkMuonsExt.clone( + L1MuonsInputTag = cms.InputTag("l1extraMuExtended", "csc"), + ETAMIN = cms.double(1.1) + ) + +l1TkMuonsExtNoZCor = l1TkMuonsExt.clone( correctGMTPropForTkZ = cms.bool(False) ) +l1TkMuonsExtCSCNoZCor = l1TkMuonsExtCSC.clone( correctGMTPropForTkZ = cms.bool(False) ) + +l1TkMuonsExtSequence = cms.Sequence (l1TkMuonsExt * l1TkMuonsExtCSC + * l1TkMuonsExtNoZCor * l1TkMuonsExtCSCNoZCor) + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py new file mode 100644 index 0000000000000..174de44907c06 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py @@ -0,0 +1,19 @@ +import FWCore.ParameterSet.Config as cms + +l1TkMuonsExt = cms.EDProducer( + "L1TkMuonFromExtendedProducer", + L1MuonsInputTag = cms.InputTag("l1extraMuExtended"), + L1TrackInputTag = cms.InputTag("L1Tracks","Level1TkTracks"), + ETAMIN = cms.double(0), + ETAMAX = cms.double(5.), # no cut + ZMAX = cms.double( 25. ), # in cm + CHI2MAX = cms.double( 100. ), + PTMINTRA = cms.double( 2. ), # in GeV +# DRmax = cms.double( 0.5 ), + nStubsmin = cms.int32( 3 ), # minimum number of stubs +# closest = cms.bool( True ), + correctGMTPropForTkZ = cms.bool(True) + +) + + From 2777205d58b6c48d7ef9efb1c34d668a7a28bc11 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Fri, 23 May 2014 15:00:04 -0500 Subject: [PATCH 021/252] empty already --- .../L1Trigger/src/L1MuonParticleExtended.cc | 15 --------------- 1 file changed, 15 deletions(-) delete mode 100644 DataFormats/L1Trigger/src/L1MuonParticleExtended.cc diff --git a/DataFormats/L1Trigger/src/L1MuonParticleExtended.cc b/DataFormats/L1Trigger/src/L1MuonParticleExtended.cc deleted file mode 100644 index 0af2e9ad546bf..0000000000000 --- a/DataFormats/L1Trigger/src/L1MuonParticleExtended.cc +++ /dev/null @@ -1,15 +0,0 @@ -// -*- C++ -*- -// -// Package: L1Trigger -// Class : L1MuonParticleExtended -// -// - -// system include files - -// user include files -#include "DataFormats/L1Trigger/interface/L1MuonParticleExtended.h" - -using namespace l1extra ; - - From 82895e084312e7eba179fd9a1940d9612ee058c3 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Fri, 23 May 2014 20:27:37 -0500 Subject: [PATCH 022/252] fix typo filling sigmaEta and sigmaPhi --- .../L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc index 6f762762a634a..6ebdf1933ac6f 100644 --- a/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc +++ b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc @@ -159,7 +159,7 @@ L1MuonParticleExtendedProducer::produce( edm::Event& iEvent, sigmaPhi = sigmaPhi/sqrt(12.); aGmtCand->setSigmaEta(sigmaEta); - aGmtCand->setSigmaEta(sigmaPhi); + aGmtCand->setSigmaPhi(sigmaPhi); aGmtCand->setQuality(gmtCand.quality()); } From 7d79dbaaf67a2c0e51f80bbae068656e15aedf3f Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Thu, 29 May 2014 10:49:42 -0500 Subject: [PATCH 023/252] correct checksum From 4854a02607317a9d3a2a1af5aadc5a4ea48499f4 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Thu, 29 May 2014 10:50:51 -0500 Subject: [PATCH 024/252] dflt constructor is now inline; quality only in the gmtCand part From 854d489f1bb2c9b944ac56e0ec747aa65403c008 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Thu, 29 May 2014 10:51:21 -0500 Subject: [PATCH 025/252] fixes for new TTTrack interface --- .../plugins/L1TkMuonFromExtendedProducer.cc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc index c305cd8480aa7..80a2276df9778 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc @@ -48,7 +48,7 @@ using namespace l1extra ; class L1TkMuonFromExtendedProducer : public edm::EDProducer { public: - typedef L1TkTrack_PixelDigi_ L1TkTrackType; + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; struct PropState { //something simple, imagine it's hardware emulation @@ -189,13 +189,13 @@ L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& float l1tk_pt = l1tk.getMomentum().perp(); if (l1tk_pt < PTMINTRA_) continue; - float l1tk_z = l1tk.getVertex().z(); + float l1tk_z = l1tk.getPOCA().z(); if (fabs(l1tk_z) > ZMAX_) continue; float l1tk_chi2 = l1tk.getChi2(); if (l1tk_chi2 > CHI2MAX_) continue; - int l1tk_nstubs = l1tk.getStubPtrs().size(); + int l1tk_nstubs = l1tk.getStubRefs().size(); if ( l1tk_nstubs < nStubsmin_) continue; float l1tk_eta = l1tk.getMomentum().eta(); @@ -236,7 +236,7 @@ L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& float p4e = sqrt(0.105658369*0.105658369 + p3.mag()); math::XYZTLorentzVector l1tkp4(p3.x(), p3.y(), p3.z(), p4e); - auto tkv3=matchTk.getVertex(); + auto tkv3=matchTk.getPOCA(); math::XYZPoint v3(tkv3.x(), tkv3.y(), tkv3.z()); float trkisol = -999; int l1tk_q = matchTk.getRInv()>0? 1: -1; @@ -277,7 +277,7 @@ L1TkMuonFromExtendedProducer::PropState L1TkMuonFromExtendedProducer::propagateT float tk_aeta = std::abs(tk_eta); float tk_phi = p3.phi(); float tk_q = tk.getRInv()>0? 1.: -1.; - float tk_z = tk.getVertex().z(); + float tk_z = tk.getPOCA().z(); if (!correctGMTPropForTkZ_) tk_z = 0; L1TkMuonFromExtendedProducer::PropState dest; From 1a15ca1a948c69184f7eb41fff0814e6f29f7875 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Thu, 29 May 2014 12:26:51 -0500 Subject: [PATCH 026/252] new name in 62XSLHC --- .../L1TrackTrigger/python/l1TkMuonsExt_cfi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py index 174de44907c06..7b1baad9c89d2 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py @@ -3,7 +3,7 @@ l1TkMuonsExt = cms.EDProducer( "L1TkMuonFromExtendedProducer", L1MuonsInputTag = cms.InputTag("l1extraMuExtended"), - L1TrackInputTag = cms.InputTag("L1Tracks","Level1TkTracks"), + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis", "Level1TTTracks"), ETAMIN = cms.double(0), ETAMAX = cms.double(5.), # no cut ZMAX = cms.double( 25. ), # in cm From acb642db952f5d8b7c1f5cd2058e465b175212d6 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Fri, 30 May 2014 09:17:28 +0200 Subject: [PATCH 027/252] first commit of Anders L1TkTauFromL1TrackProducer --- .../plugins/L1TkTauFromL1TrackProducer.cc | 375 ++++++++++++++++++ .../python/singleTau1pFiles_cfi.py | 129 ++++++ 2 files changed, 504 insertions(+) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/singleTau1pFiles_cfi.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc new file mode 100644 index 0000000000000..b6ac11fa11e3c --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc @@ -0,0 +1,375 @@ +// -*- C++ -*- +// +// +// Producer for a L1TkTauParticle from Track seeds. +// +// + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" + +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Utilities/interface/InputTag.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticleFwd.h" + + + + +// for TTTracks: +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +#include +#include "TMath.h" + + +using namespace l1extra ; + +// +// class declaration +// + +class L1TkTauFromL1TrackProducer : public edm::EDProducer { + +public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + explicit L1TkTauFromL1TrackProducer(const edm::ParameterSet&); + ~L1TkTauFromL1TrackProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + +private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + //virtual void beginRun(edm::Run&, edm::EventSetup const&); + //virtual void endRun(edm::Run&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // ----------member data --------------------------- + + edm::InputTag L1TrackInputTag; + + float ZMAX; // |z_track| < ZMAX in cm + float CHI2MAX; + float PTMINTRA; + float DRmax; + + int nStubsmin ; // minimum number of stubs + + bool closest ; + + +} ; + + +// +// constructors and destructor +// +L1TkTauFromL1TrackProducer::L1TkTauFromL1TrackProducer(const edm::ParameterSet& iConfig) +{ + + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + + ZMAX = (float)iConfig.getParameter("ZMAX"); + CHI2MAX = (float)iConfig.getParameter("CHI2MAX"); + PTMINTRA = (float)iConfig.getParameter("PTMINTRA"); + DRmax = (float)iConfig.getParameter("DRmax"); + nStubsmin = iConfig.getParameter("nStubsmin"); + + produces(); + +} + +L1TkTauFromL1TrackProducer::~L1TkTauFromL1TrackProducer() { +} + +// ------------ method called to produce the data ------------ +void +L1TkTauFromL1TrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + using namespace std; + + + + std::auto_ptr result(new L1TkTauParticleCollection); + + + edm::Handle L1TkTrackHandle; + iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); + L1TkTrackCollectionType::const_iterator trackIter; + + edm::Ptr< L1TkTrackType > l1tracks[1000]; + + math::XYZTLorentzVector p4[1000]; + double z[1000]; + double chi2[1000]; + int nstub[1000]; + + int ntrack=0; + + int itrack=-1; + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { + itrack++; + + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubs = trackIter ->getStubRefs(); + + z[ntrack]=trackIter->getPOCA().z(); + double px=trackIter->getMomentum().x(); + double py=trackIter->getMomentum().y(); + double pz=trackIter->getMomentum().z(); + double e=sqrt(px*px+py*py+pz*pz+0.14*0.14); + + + nstub[ntrack]=theStubs.size(); + chi2[ntrack]=trackIter->getChi2(); + if (chi2[ntrack]>100) continue; + + + edm::Ptr< L1TkTrackType > L1TrackPtr( L1TkTrackHandle, itrack) ; + l1tracks[ntrack]=L1TrackPtr; + math::XYZTLorentzVector p4tmp(px,py,pz,e); + p4[ntrack++]=p4tmp; + + } + + + //Let's look here for 1 prong taus + + for (int i=0;i10) continue; + if (p4[i].Pt()<10.0) continue; + + bool foundHigher=false; + for (int j=0;jp4[i].Pt()){ + double dphi=p4[i].Phi()-p4[j].Phi(); + if (dphi>3.141592) dphi-=2*3.141592; + if (dphi<-3.141592) dphi+=2*3.141592; + double deta=p4[i].Eta()-p4[j].Eta(); + double dR=sqrt(dphi*dphi+deta*deta); + if (dR<0.3) foundHigher=true; + } + } + + if (foundHigher) continue; + + + math::XYZTLorentzVector p4tot=p4[i]; + + double ptsum=0.0; + for (int l=0;l 0.8 ) continue; + double dphi=p4[i].Phi()-p4[l].Phi(); + if (dphi>3.141592) dphi-=2*3.141592; + if (dphi<-3.141592) dphi+=2*3.141592; + double deta=p4[i].Eta()-p4[l].Eta(); + double dR=sqrt(dphi*dphi+deta*deta); + if (dR>0.3) continue; + ptsum+=p4[l].Pt(); + } + + double reliso=ptsum/p4tot.Pt(); + + + if (reliso>0.999) reliso=0.999; + if (reliso<0.25) { + edm::Ptr< L1TkTrackType > L1TrackPtrNull2; // null pointer + edm::Ptr< L1TkTrackType > L1TrackPtrNull3; // null pointer + edm::Ref< L1JetParticleCollection > tauCaloRef; // null pointer + + L1TkTauParticle trkTau( p4[i], + tauCaloRef, + l1tracks[i], + L1TrackPtrNull2, + L1TrackPtrNull3, + reliso ); + + + result -> push_back( trkTau ); + + } + + } + + + + //Let's look here for 3 prong taus + + for (int i=0;ip4[i].Pt()){ + double dphi=p4[i].Phi()-p4[j].Phi(); + if (dphi>3.141592) dphi-=2*3.141592; + if (dphi<-3.141592) dphi+=2*3.141592; + double deta=p4[i].Eta()-p4[j].Eta(); + double dR=sqrt(dphi*dphi+deta*deta); + if (dR<0.3) foundHigher=true; + } + } + if (foundHigher) continue; + + + double minRelIso=1e10; + + int jmin=-1; + int kmin=-1; + + for (int j=0;jp4[i].Pt()) continue; + math::XYZTLorentzVector p4sum=p4[i]+p4[j]; + if ( p4sum.M() > 1.777 ) continue; + for (int k=0;kp4[i].Pt()) continue; + math::XYZTLorentzVector p4tot=p4sum+p4[k]; + if ( p4tot.M() > 1.777 ) continue; + if ( fabs(z[i]-z[j]) > 1.0 ) continue; + if ( fabs(z[i]-z[k]) > 1.0 ) continue; + double ptsum=0.0; + for (int l=0;l 0.8 ) continue; + double dphi=p4[i].Phi()-p4[l].Phi(); + if (dphi>3.141592) dphi-=2*3.141592; + if (dphi<-3.141592) dphi+=2*3.141592; + double deta=p4[i].Eta()-p4[l].Eta(); + double dR=sqrt(dphi*dphi+deta*deta); + if (dR>0.3) continue; + ptsum+=p4[l].Pt(); + } + double reliso=ptsum/p4tot.Pt(); + if (reliso1e9) { + //Did not find tracks... + continue; + } + + + if (minRelIso>0.999) minRelIso=0.999; + if (minRelIso<0.25) { + edm::Ref< L1JetParticleCollection > tauCaloRef; // null pointer + + L1TkTauParticle trkTau( p4[i]+p4[jmin]+p4[kmin], + tauCaloRef, + l1tracks[i], + l1tracks[jmin], + l1tracks[kmin], + minRelIso ); + + result -> push_back( trkTau ); + + + + } + + } + + + + + + + + iEvent.put( result ); + +} + +// -------------------------------------------------------------------------------------- + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TkTauFromL1TrackProducer::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TkTauFromL1TrackProducer::endJob() { +} + +// ------------ method called when starting to processes a run ------------ +/* +void +L1TkTauFromL1TrackProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) +{ +} +*/ + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1TkTauFromL1TrackProducer::endRun(edm::Run&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1TkTauFromL1TrackProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1TkTauFromL1TrackProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TkTauFromL1TrackProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TkTauFromL1TrackProducer); + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/singleTau1pFiles_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/singleTau1pFiles_cfi.py new file mode 100644 index 0000000000000..b53194521508c --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/singleTau1pFiles_cfi.py @@ -0,0 +1,129 @@ +import FWCore.ParameterSet.Config as cms + + +singleTau1pFiles = cms.untracked.vstring( +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_1.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_10.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_100.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_101.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_102.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_103.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_104.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_105.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_106.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_107.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_108.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_109.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_11.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_110.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_111.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_112.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_113.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_114.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_115.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_116.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_117.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_118.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_119.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_12.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_121.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_122.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_123.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_124.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_125.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_13.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_14.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_15.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_16.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_17.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_18.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_19.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_2.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_20.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_21.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_22.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_23.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_24.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_25.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_26.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_27.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_28.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_29.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_3.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_30.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_31.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_32.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_33.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_34.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_35.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_36.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_37.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_38.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_39.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_4.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_40.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_41.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_42.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_43.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_44.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_45.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_46.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_47.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_48.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_49.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_5.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_50.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_51.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_52.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_53.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_54.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_55.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_56.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_57.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_58.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_59.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_6.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_60.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_61.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_62.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_63.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_64.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_65.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_66.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_67.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_68.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_69.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_7.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_70.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_71.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_72.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_73.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_74.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_75.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_76.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_77.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_78.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_79.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_8.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_80.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_81.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_82.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_83.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_84.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_85.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_86.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_87.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_88.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_89.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_9.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_90.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_91.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_92.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_93.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_94.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_95.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_96.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_97.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_98.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_99.root" +) From 69e893dd8ffbb00aeb3eb4a180f0fc14805cef6b Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Fri, 30 May 2014 13:26:50 +0200 Subject: [PATCH 028/252] add SimDataFormata/SLHC and L1CaloTrigger (needed for clao stuff). No change wrt Slavas code --- .../interface/L1TkMuonParticle.h | 3 + .../L1CaloTrigger/data/pu140.LUT | 14 + .../L1CaloTrigger/interface/LUT.h | 73 ++ .../L1CaloTrigger/plugins/BuildFile.xml | 1 + .../plugins/L1CalibFilterTowerJetProducer.cc | 329 ++++-- .../plugins/L1EGammaCrystalsProducer.cc | 334 ++++++ .../plugins/L1EnergySumProducer.cc | 238 ++++ .../plugins/L1ExtraCrystalPosition.cc | 149 +++ .../plugins/L1TowerFwdJetProducer.cc | 5 +- .../plugins/L1TowerJetCentralityFilter.cc | 514 +++++++++ .../plugins/L1TowerJetPUEstimator.cc | 312 ++++- .../plugins/L1TowerJetPUSubtractedProducer.cc | 214 +++- .../plugins/L1TowerJetProducer.cc | 193 ++-- .../python/SLHCCaloTrigger_cff.py | 6 +- .../python/SLHCCaloTrigger_cfi.py | 133 ++- .../python/minBiasFiles_p1_cfi.py | 256 +++++ .../python/minBiasFiles_p2_cfi.py | 256 +++++ .../L1TrackTrigger/test/test_muons_cfg.py | 216 ++++ SimDataFormats/SLHC/BuildFile.xml | 15 + SimDataFormats/SLHC/doc/html/index.html | 12 + SimDataFormats/SLHC/doc/html/overview.html | 13 + .../SLHC/interface/EtaPhiContainer.h | 177 +++ SimDataFormats/SLHC/interface/L1CaloCluster.h | 204 ++++ .../SLHC/interface/L1CaloClusterFwd.h | 21 + .../SLHC/interface/L1CaloClusterWithSeed.h | 148 +++ .../SLHC/interface/L1CaloClusterWithSeedFwd.h | 21 + SimDataFormats/SLHC/interface/L1CaloJet.h | 67 ++ SimDataFormats/SLHC/interface/L1CaloJetFwd.h | 22 + SimDataFormats/SLHC/interface/L1CaloRegion.h | 40 + .../SLHC/interface/L1CaloRegionFwd.h | 25 + SimDataFormats/SLHC/interface/L1CaloTower.h | 60 + .../SLHC/interface/L1CaloTowerFwd.h | 26 + .../SLHC/interface/L1CaloTriggerSetup.h | 291 +++++ .../SLHC/interface/L1CaloTriggerSetupRcd.h | 11 + .../SLHC/interface/L1EGCrystalCluster.h | 33 + SimDataFormats/SLHC/interface/L1TBarrel.hh | 457 ++++++++ SimDataFormats/SLHC/interface/L1TConstants.hh | 41 + SimDataFormats/SLHC/interface/L1TDisk.hh | 348 ++++++ SimDataFormats/SLHC/interface/L1TGeomBase.hh | 76 ++ SimDataFormats/SLHC/interface/L1TSector.hh | 927 +++++++++++++++ SimDataFormats/SLHC/interface/L1TStub.hh | 203 ++++ SimDataFormats/SLHC/interface/L1TTrack.hh | 664 +++++++++++ SimDataFormats/SLHC/interface/L1TTracklet.hh | 96 ++ SimDataFormats/SLHC/interface/L1TTracklets.hh | 58 + SimDataFormats/SLHC/interface/L1TTracks.hh | 139 +++ SimDataFormats/SLHC/interface/L1TWord.hh | 228 ++++ SimDataFormats/SLHC/interface/L1TkBeam.h | 132 +++ SimDataFormats/SLHC/interface/L1TkCluster.h | 389 +++++++ SimDataFormats/SLHC/interface/L1TkStub.h | 498 ++++++++ SimDataFormats/SLHC/interface/L1TkTrack.h | 859 ++++++++++++++ SimDataFormats/SLHC/interface/L1TowerJet.h | 185 +++ SimDataFormats/SLHC/interface/L1TowerJetFwd.h | 21 + SimDataFormats/SLHC/interface/L1TowerNav.h | 24 + .../SLHC/interface/StackedTrackerTypes.h | 83 ++ SimDataFormats/SLHC/interface/slhcevent.hh | 643 +++++++++++ SimDataFormats/SLHC/src/L1CaloCluster.cc | 459 ++++++++ .../SLHC/src/L1CaloClusterWithSeed.cc | 476 ++++++++ SimDataFormats/SLHC/src/L1CaloJet.cc | 148 +++ SimDataFormats/SLHC/src/L1CaloRegion.cc | 58 + SimDataFormats/SLHC/src/L1CaloTower.cc | 109 ++ .../SLHC/src/L1CaloTriggerSetupRcd.cc | 4 + SimDataFormats/SLHC/src/L1TkCluster.cc | 48 + SimDataFormats/SLHC/src/L1TkStub.cc | 27 + SimDataFormats/SLHC/src/L1TkTrack.cc | 19 + SimDataFormats/SLHC/src/L1TowerJet.cc | 1014 +++++++++++++++++ SimDataFormats/SLHC/src/L1TowerNav.cc | 59 + .../src/T_EventSetup_L1CaloTriggerSetup.cc | 7 + SimDataFormats/SLHC/src/classes.h | 236 ++++ SimDataFormats/SLHC/src/classes_def.xml | 212 ++++ 69 files changed, 13073 insertions(+), 306 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py create mode 100644 SimDataFormats/SLHC/BuildFile.xml create mode 100644 SimDataFormats/SLHC/doc/html/index.html create mode 100644 SimDataFormats/SLHC/doc/html/overview.html create mode 100644 SimDataFormats/SLHC/interface/EtaPhiContainer.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloCluster.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloClusterFwd.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloJet.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloJetFwd.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloRegion.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloRegionFwd.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloTower.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloTowerFwd.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h create mode 100644 SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h create mode 100644 SimDataFormats/SLHC/interface/L1EGCrystalCluster.h create mode 100644 SimDataFormats/SLHC/interface/L1TBarrel.hh create mode 100644 SimDataFormats/SLHC/interface/L1TConstants.hh create mode 100644 SimDataFormats/SLHC/interface/L1TDisk.hh create mode 100644 SimDataFormats/SLHC/interface/L1TGeomBase.hh create mode 100755 SimDataFormats/SLHC/interface/L1TSector.hh create mode 100755 SimDataFormats/SLHC/interface/L1TStub.hh create mode 100644 SimDataFormats/SLHC/interface/L1TTrack.hh create mode 100755 SimDataFormats/SLHC/interface/L1TTracklet.hh create mode 100755 SimDataFormats/SLHC/interface/L1TTracklets.hh create mode 100644 SimDataFormats/SLHC/interface/L1TTracks.hh create mode 100755 SimDataFormats/SLHC/interface/L1TWord.hh create mode 100644 SimDataFormats/SLHC/interface/L1TkBeam.h create mode 100644 SimDataFormats/SLHC/interface/L1TkCluster.h create mode 100644 SimDataFormats/SLHC/interface/L1TkStub.h create mode 100644 SimDataFormats/SLHC/interface/L1TkTrack.h create mode 100644 SimDataFormats/SLHC/interface/L1TowerJet.h create mode 100644 SimDataFormats/SLHC/interface/L1TowerJetFwd.h create mode 100644 SimDataFormats/SLHC/interface/L1TowerNav.h create mode 100644 SimDataFormats/SLHC/interface/StackedTrackerTypes.h create mode 100755 SimDataFormats/SLHC/interface/slhcevent.hh create mode 100644 SimDataFormats/SLHC/src/L1CaloCluster.cc create mode 100644 SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc create mode 100644 SimDataFormats/SLHC/src/L1CaloJet.cc create mode 100644 SimDataFormats/SLHC/src/L1CaloRegion.cc create mode 100644 SimDataFormats/SLHC/src/L1CaloTower.cc create mode 100644 SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc create mode 100644 SimDataFormats/SLHC/src/L1TkCluster.cc create mode 100644 SimDataFormats/SLHC/src/L1TkStub.cc create mode 100644 SimDataFormats/SLHC/src/L1TkTrack.cc create mode 100644 SimDataFormats/SLHC/src/L1TowerJet.cc create mode 100644 SimDataFormats/SLHC/src/L1TowerNav.cc create mode 100644 SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc create mode 100644 SimDataFormats/SLHC/src/classes.h create mode 100644 SimDataFormats/SLHC/src/classes_def.xml diff --git a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h index 39cc7e970d1e1..5e57c3180fe37 100644 --- a/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h +++ b/DataFormats/L1TrackTrigger/interface/L1TkMuonParticle.h @@ -85,7 +85,10 @@ namespace l1extra // used for the Naive producer edm::Ref< L1MuonParticleCollection > muRef_ ; + + // used for Slava's muons: L1MuonParticleExtendedRef muExtendedRef_ ; + edm::Ptr< L1TkTrackType > trkPtr_ ; float theIsolation; diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT b/SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT new file mode 100644 index 0000000000000..dfdb1b10087b0 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT @@ -0,0 +1,14 @@ +0.907747 6.468076 -0.197948 0.045329 9.976110 4.208358, +1.067557 5.477807 9.281958 0.538236 0.429327 2.731133, +0.987411 9.956708 1.369532 0.155267 2.021796 3.518603, +0.969114 9.990500 1.405063 0.169569 1.549711 3.621829, +0.940879 9.875660 2.331352 0.235164 0.821025 3.428161, +1.076993 5.883136 -0.045208 0.287680 0.913810 3.389504, +1.079105 6.086415 9.520870 0.584415 0.396147 2.754608, +1.079105 6.086415 9.520870 0.584415 0.396147 2.754608, +1.076993 5.883136 -0.045208 0.287680 0.913810 3.389504, +0.940879 9.875660 2.331352 0.235164 0.821025 3.428161, +0.969114 9.990500 1.405063 0.169569 1.549711 3.621829, +0.987411 9.956708 1.369532 0.155267 2.021796 3.518603, +1.067557 5.477807 9.281958 0.538236 0.429327 2.731133, +0.907747 6.468076 -0.197948 0.045329 9.976110 4.208358, diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h b/SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h new file mode 100644 index 0000000000000..550c5ab1ee55c --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h @@ -0,0 +1,73 @@ +#ifndef LUT_H +#define LUT_H + +#include + +class LUT{ + + + public: + + LUT(): columns(0), rows(0){} + LUT( int nColumns, int nRows ): columns( nColumns ), rows( nRows ){} + + void loadLUT( TString filename ); + + + int getColumns(){ return columns; } + int getRows(){ return rows; } + + // Return a specific LUT element. Note: numbering starts from 0 + double getElement( int row, int column ){ + int index = column + row*columns; + return LUTArr[ index ]; + } + + + private: + std::vector LUTArr; + + // LUT dimensions + int columns; + int rows; + + +}; + + + + +// Read a LUT stored in a textfile and store in a flat vector +void +LUT::loadLUT( TString filename ){ + + std::ifstream iReadLUT( filename ); + + if(!iReadLUT){ + throw cms::Exception("MissingLUT") << "A LUT could not be loaded as the file: '" << filename << "' does not exist, check the path of all LUTs.\n"; + } + + // Read and store the LUT in a flat vector + while (!iReadLUT.eof()){ + TString element; + iReadLUT >> element; + if (element != ""){ + LUTArr.push_back( element.Atof() ); + } + } + + // Validate input + if ( int( LUTArr.size() ) != columns*rows ){ + + throw cms::Exception("InconsistentLUTEntries") << "LUT dimensions specified:\n" << "\tRows = " << rows << "\n\tColumns = " << columns + << "\n\nExpected " << rows*columns << " entries in LUT but read " << LUTArr.size() + << " entries, check that the input LUT file contains the same dimensions as the LUT object.\n"; + + } + +} + + + +#endif + diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml index 64493e81fc347..b3dd410291b86 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/BuildFile.xml @@ -14,6 +14,7 @@ + diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc index c9c21241adef9..d49a49fd246d7 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1CalibFilterTowerJetProducer.cc @@ -5,7 +5,7 @@ // /**\class CalibTowerJetCollection L1CalibFilterTowerJetProducer.cc MVACALIB/L1CalibFilterTowerJetProducer/src/L1CalibFilterTowerJetProducer.cc - Description: [one line class summary] + Description: Mk1 developer release Implementation: [Notes on implementation] @@ -13,9 +13,9 @@ // // Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, // Created: Mon Nov 19 10:20:06 CET 2012 -// $Id: L1CalibFilterTowerJetProducer.cc,v 1.5 2013/03/21 16:11:18 rlucas Exp $ -// +// $Id: L1CalibFilterTowerJetProducer.cc,v 1.7 2013/05/16 17:35:30 mbaber Exp $ // +// Modifications : Mark Baber Imperial College, London // system include files @@ -40,11 +40,22 @@ #include "FWCore/Framework/interface/LuminosityBlock.h" #include #include +#include -#include "TMVA/Tools.h" -#include "TMVA/Reader.h" #include "FWCore/ParameterSet/interface/FileInPath.h" + +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/LUT.h" + + +// Ranking function for sort +bool towerJetRankDescending ( l1slhc::L1TowerJet jet1, l1slhc::L1TowerJet jet2 ){ return ( jet1.p4().Pt() > jet2.p4().Pt() ); } +bool L1JetRankDescending ( l1extra::L1JetParticle jet1, l1extra::L1JetParticle jet2 ){ return ( jet1.p4().Pt() > jet2.p4().Pt() ); } + + + + + // // class declaration // @@ -74,147 +85,160 @@ class L1CalibFilterTowerJetProducer : public edm::EDProducer { virtual void endRun(edm::Run&, edm::EventSetup const&); virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); - + + virtual l1extra::L1JetParticleCollection calibrateJetCollection( edm::Handle UncalibJet_Tower, LUT calibLUT ); + // ----------member data --------------------------- ParameterSet conf_; - float l1Pt, l1Eta; + // Jet pt threshold for jet energies used in the calculation of Ht, mHt + double energySumsJetPtThreshold; + + // L1 pT calibration threshold, minimum L1 jet pT to apply correction + double pTCalibrationThreshold; + // Boundaries of eta segmentation for calibration + std::vector etaRegionSlice; + + // Number of parameters used in calibration + uint calibParameters; + + // Calibration look up table + LUT calibrationLUT; + TString lutFilename; + }; L1CalibFilterTowerJetProducer::L1CalibFilterTowerJetProducer(const edm::ParameterSet& iConfig): conf_(iConfig) { + produces( "UncalibratedTowerJets" ) ; + produces( "CalibratedTowerJets" ) ; + produces( "TowerMHT" ) ; - produces("CenJets"); -// produces("CalibFwdJets"); - produces< L1JetParticleCollection >( "Cen8x8" ) ; -// produces< L1JetParticleCollection >( "Fwd8x8" ) ; - produces< L1EtMissParticleCollection >( "TowerMHT" ) ; - produces("TowerHT"); - + // Read the calibration eta segementation + etaRegionSlice = iConfig.getParameter< std::vector >("EtaRegionSlice"); + sort (etaRegionSlice.begin(), etaRegionSlice.end()); // ensure the bins are in ascending order + + + edm::FileInPath LUTFile = iConfig.getParameter("CalibrationLUTFile"); + calibParameters = iConfig.getParameter< uint >("CalibrationParameters"); + + // Calculate LUT dimensions and initialise LUT + int rows = int(calibParameters); + int columns = etaRegionSlice.size() - 1; + calibrationLUT = LUT( rows, columns ); + + // Load the look up table + calibrationLUT.loadLUT( LUTFile.fullPath().c_str() ); + + // Extract jet pT threshold for Ht, mHt calculation + energySumsJetPtThreshold = iConfig.getParameter ("EnergySumsJetPtThreshold"); + + // Minimum PT for calibration. Remove jets which cannot be calibrated + pTCalibrationThreshold = iConfig.getParameter ("pTCalibrationThreshold"); + } L1CalibFilterTowerJetProducer::~L1CalibFilterTowerJetProducer() { - } void L1CalibFilterTowerJetProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { - bool evValid =true; + bool evValid = true; + + auto_ptr outputCalibratedL1Extra(new L1JetParticleCollection()); + auto_ptr outputUncalibratedL1Extra(new L1JetParticleCollection()); + - double ht=(0); - auto_ptr< L1TowerJetCollection > outputCollCen(new L1TowerJetCollection()); -// auto_ptr< L1TowerJetCollection > outputCollFwd(new L1TowerJetCollection()); - auto_ptr< L1JetParticleCollection > outputExtraCen(new L1JetParticleCollection()); - auto_ptr< L1JetParticleCollection > outputExtraFwd(new L1JetParticleCollection()); auto_ptr outputmht(new L1EtMissParticleCollection()); - auto_ptr outRho(new double()); - auto_ptr outHT(new double()); - - //read in collection depending on parameteres in SLHCCaloTrigger_cfi.py - edm::Handle PUSubCen; - iEvent.getByLabel(conf_.getParameter("PUSubtractedCentralJets"), PUSubCen); - if(!PUSubCen.isValid()){ - edm::LogWarning("MissingProduct") << conf_.getParameter("PUSubtractedCentralJets") << std::endl; - evValid=false; + auto_ptr outHT (new double()); + + + // Read in collection depending on parameters in SLHCCaloTrigger_cfi.py + edm::Handle UncalibratedTowerJets; + iEvent.getByLabel(conf_.getParameter("UncalibratedTowerJets"), UncalibratedTowerJets); + if(!UncalibratedTowerJets.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("UncalibratedTowerJets") << std::endl; + evValid = false; } if( evValid ) { + + double ht(0); + math::PtEtaPhiMLorentzVector mht, tempJet; + + // Perform jet eta-pT dependent pT calibrations + l1extra::L1JetParticleCollection calibJets = calibrateJetCollection( UncalibratedTowerJets, calibrationLUT ); - /////////////////////////////////////////////////// - // JET VALUES - /////////////////////////////////////////////////// - - //Value of HT - ht=0; - //vector of MHT - math::PtEtaPhiMLorentzVector mht, upgrade_jet; - - //Produce calibrated pt collection: central jets - for (L1TowerJetCollection::const_iterator il1 = PUSubCen->begin(); - il1!= PUSubCen->end() ; - ++il1 ) - { - - L1TowerJet h=(*il1); + // Store calibrated jets and perform calibrated jet energy sums + for ( l1extra::L1JetParticleCollection::const_iterator calib_Itr = calibJets.begin(); calib_Itr!= calibJets.end() ; ++calib_Itr ){ - // float l1Eta_ = il1->p4().eta(); - // float l1Phi_ = il1->p4().phi(); - float l1Pt_ = il1->p4().Pt(); + L1JetParticle calibJet = (*calib_Itr); + outputCalibratedL1Extra->push_back( calibJet ); - //weighted eta is still not correct - //change the contents out p4, upgrade_jet when it is corrected - float l1wEta_ = il1->WeightedEta(); - float l1wPhi_ = il1->WeightedPhi() ; + // Add jet to energy sums if energy is above threshold + if( calibJet.p4().pt() > energySumsJetPtThreshold ){ + tempJet.SetCoordinates( calibJet.p4().pt(), calibJet.p4().eta(), calibJet.p4().phi(), calibJet.p4().M() ); + ht += tempJet.pt(); + mht += tempJet; - // Currently no calibration is applied - double cal_Pt_ = l1Pt_; + } - math::PtEtaPhiMLorentzVector p4; + } - p4.SetCoordinates(cal_Pt_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); - h.setP4(p4); - outputCollCen->insert( l1wEta_ , l1wPhi_ , h ); - upgrade_jet.SetCoordinates(cal_Pt_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); + + // Store uncalibrated jet collection + for ( L1TowerJetCollection::const_iterator Uncalib_Itr = UncalibratedTowerJets->begin(); Uncalib_Itr != UncalibratedTowerJets->end(); ++Uncalib_Itr ){ + + L1TowerJet uncalibJet = (*Uncalib_Itr); - //if the calibrated jet energy is > 15GeV add to ht,mht - if( cal_Pt_>15 ) ht+=cal_Pt_; - if( cal_Pt_>15 ) mht+=upgrade_jet; + math::PtEtaPhiMLorentzVector tempJet; + tempJet.SetCoordinates( uncalibJet.p4().pt(), uncalibJet.p4().eta(), uncalibJet.p4().phi(), uncalibJet.p4().M() ); - // add jet to L1Extra list - outputExtraCen->push_back( L1JetParticle( math::PtEtaPhiMLorentzVector( cal_Pt_, l1wEta_, l1wPhi_, 0. ), - Ref< L1GctJetCandCollection >(), 0 ) - ); + outputUncalibratedL1Extra->push_back( l1extra::L1JetParticle( tempJet, l1extra::L1JetParticle::JetType::kCentral, 0 ) ); } - - - + // create L1Extra object - math::PtEtaPhiMLorentzVector p4tmp = math::PtEtaPhiMLorentzVector( mht.pt(), 0., mht.phi(), 0. ) ; + math::PtEtaPhiMLorentzVector p4tmp = math::PtEtaPhiMLorentzVector( mht.pt(), 0., mht.phi(), 0. ); - L1EtMissParticle l1extraMHT(p4tmp, - L1EtMissParticle::kMHT, - ht, - Ref< L1GctEtMissCollection >(), - Ref< L1GctEtTotalCollection >(), - Ref< L1GctHtMissCollection >(), - Ref< L1GctEtHadCollection >(), - 0); - - outputmht->push_back(l1extraMHT); - *outHT = ht; - - iEvent.put(outputCollCen,"CenJets"); -// iEvent.put(outputCollFwd,"CalibFwdJets"); - iEvent.put(outputExtraCen,"Cen8x8"); -// iEvent.put(outputExtraFwd,"Fwd8x8"); - iEvent.put(outputmht,"TowerMHT" ); - iEvent.put(outHT,"TowerHT"); - - - } + L1EtMissParticle l1extraMHT(p4tmp, L1EtMissParticle::kMHT, ht, + Ref< L1GctEtMissCollection >(), Ref< L1GctEtTotalCollection >(), + Ref< L1GctHtMissCollection >(), Ref< L1GctEtHadCollection >() , 0); + + outputmht->push_back(l1extraMHT); + + iEvent.put( outputUncalibratedL1Extra,"UncalibratedTowerJets"); + iEvent.put( outputCalibratedL1Extra, "CalibratedTowerJets"); + + + iEvent.put( outputmht, "TowerMHT" ); + + + } } // ------------ method called once each job just before starting event loop ------------ void -L1CalibFilterTowerJetProducer::beginJob() { +L1CalibFilterTowerJetProducer::beginJob() +{ } // ------------ method called once each job just after ending the event loop ------------ void -L1CalibFilterTowerJetProducer::endJob() { +L1CalibFilterTowerJetProducer::endJob() +{ } // ------------ method called when starting to processes a run ------------ @@ -251,6 +275,123 @@ L1CalibFilterTowerJetProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions.addDefault(desc); } +// +// member functions +// + + + + +// Calibrates an input TowerJet collection with the specified input look up table. The resulting calibrated jets are sorted in pT +// and are returned as a L1JetParticleCollection. +l1extra::L1JetParticleCollection +L1CalibFilterTowerJetProducer::calibrateJetCollection( edm::Handle UncalibJet_Tower, LUT calibLUT ){ + + + + std::vector unsortedCalibratedL1Jets; + + // Calibrate jets with LUT + for ( L1TowerJetCollection::const_iterator Uncalib_It = UncalibJet_Tower->begin(); Uncalib_It != UncalibJet_Tower->end(); ++Uncalib_It ){ + + L1TowerJet uncalibJet = (*Uncalib_It); + + // Jet pT threshold for calibration, only calibrate above threshold + if ( uncalibJet.p4().pt() < pTCalibrationThreshold ){ + + // Uncomment to Store un-calibrated L1Jet + // ------------------------------------------------------------ + // Create un-sorted calibrated L1Jet + //math::PtEtaPhiMLorentzVector tempJet; + //tempJet.SetCoordinates( uncalibJet.p4().pt(), uncalibJet.p4().eta(), uncalibJet.p4().phi(), uncalibJet.p4().M() ); + //unsortedCalibratedL1Jets.push_back( l1extra::L1JetParticle( tempJet, l1extra::L1JetParticle::JetType::kCentral, 0 ) ); + + continue; + } + + // Find in which Eta bin the jet resides + uint pEta; + for (pEta = 1; pEta < etaRegionSlice.size(); ++pEta){ + + double eta = uncalibJet.p4().eta(); + + // Get Eta bin lower and upper bounds + double EtaLow = etaRegionSlice[ pEta - 1]; + double EtaHigh = etaRegionSlice[ pEta ]; + // Eta resides within current boundary + if ( (eta >= EtaLow) && (eta < EtaHigh) ){ + break; // found the correct eta bin, break + } + + } + + // Extract eta dependent correction factors + // ************************************************** + int etaIndex = pEta - 1;// Correct for array starting at zero + + + // Perform jet calibration + // ------------------------------------------------------------ + double unCorrectedPt = uncalibJet.p4().pt(); + double correctedPt = 0; + + + // Get calibration parameters for given eta bin + double p0 = calibLUT.getElement( etaIndex, 0 ); + double p1 = calibLUT.getElement( etaIndex, 1 ); + double p2 = calibLUT.getElement( etaIndex, 2 ); + double p3 = calibLUT.getElement( etaIndex, 3 ); + double p4 = calibLUT.getElement( etaIndex, 4 ); + double p5 = calibLUT.getElement( etaIndex, 5 ); + + + + // Calucualte the jet correction + double logPt = log( unCorrectedPt ); + + double term1 = p1 / ( logPt * logPt + p2 ); + double term2 = p3 * exp( -p4*((logPt - p5)*(logPt - p5)) ); + + // Calculate the corrected Pt + double correction = (p0 + term1 + term2); + //double invCorrection = 1/correction; + + // Use invereted correction for Phase 2 + //correctedPt = invCorrection*unCorrectedPt; + correctedPt = correction*unCorrectedPt; + + + + + + + // Create and store unsorted calibrated L1Jet collection + // ------------------------------------------------------------ + + // Create un-sorted calibrated L1Jet + math::PtEtaPhiMLorentzVector tempJet; + tempJet.SetCoordinates( correctedPt, uncalibJet.p4().eta(), uncalibJet.p4().phi(), uncalibJet.p4().M() ); + unsortedCalibratedL1Jets.push_back( l1extra::L1JetParticle( tempJet, l1extra::L1JetParticle::JetType::kCentral, 0 ) ); + + } + + // Sort calibrated jets + std::sort( unsortedCalibratedL1Jets.begin(), unsortedCalibratedL1Jets.end(), L1JetRankDescending ); + + // Return the sorted, calibrated jets + return unsortedCalibratedL1Jets; + + +} + + + + + + + + + diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc new file mode 100644 index 0000000000000..32f3b3050e318 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -0,0 +1,334 @@ +// -*- C++ -*- +// +// Package: L1CaloTrigger +// Class: L1EGammaCrystalsProducer +// +/**\class L1EGammaCrystalsProducer L1EGammaCrystalsProducer.cc SLHCUpgradeSimulations/L1CaloTrigger/plugin/L1EGammaCrystalsProducer.cc + +Description: Produces crystal clusters using crystal-level information + +Implementation: +[Notes on implementation] +*/ +// +// Original Author: Nick Smith, Alexander Savin +// Created: Tue Apr 22 2014 +// $Id$ +// +// + + +#include "SimDataFormats/Track/interface/SimTrackContainer.h" +#include "DataFormats/L1Trigger/interface/L1EmParticle.h" +#include "DataFormats/L1Trigger/interface/L1EmParticleFwd.h" +#include "DataFormats/Math/interface/deltaR.h" +#include "DataFormats/Math/interface/deltaPhi.h" + +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "SimDataFormats/CaloHit/interface/PCaloHitContainer.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "Geometry/CaloEventSetup/interface/CaloTopologyRecord.h" +#include "Geometry/Records/interface/CaloGeometryRecord.h" +#include "Geometry/CaloGeometry/interface/CaloSubdetectorGeometry.h" + +#include "Geometry/CaloGeometry/interface/CaloGeometry.h" +#include "Geometry/EcalAlgo/interface/EcalBarrelGeometry.h" +#include "Geometry/EcalAlgo/interface/EcalEndcapGeometry.h" +#include "Geometry/CaloGeometry/interface/CaloCellGeometry.h" +#include + +#include "DataFormats/EcalRecHit/interface/EcalRecHit.h" +#include "DataFormats/EcalRecHit/interface/EcalRecHitCollections.h" +#include "FastSimulation/CaloGeometryTools/interface/CaloGeometryHelper.h" +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" +#include "Geometry/CaloTopology/interface/CaloTopology.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "Geometry/CommonDetUnit/interface/GeomDet.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "SimDataFormats/CaloTest/interface/HcalTestNumbering.h" +#include "DataFormats/HcalDetId/interface/HcalSubdetector.h" +#include "DataFormats/HcalDetId/interface/HcalDetId.h" + +#include "DataFormats/HcalRecHit/interface/HcalRecHitCollections.h" +#include "DataFormats/HcalRecHit/interface/HcalSourcePositionData.h" + +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +class L1EGCrystalClusterProducer : public edm::EDProducer { + public: + explicit L1EGCrystalClusterProducer(const edm::ParameterSet&); + + private: + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void beginRun(edm::Run const&, edm::EventSetup const&); + + CaloGeometryHelper geometryHelper; + bool debug; + bool useECalEndcap; + class SimpleCaloHit + { + public: + EBDetId id; + GlobalVector position; // As opposed to GlobalPoint, so we can add them (for weighted average) + float energy=0.; + bool stale=false; // Hits become stale once used in clustering algorithm to prevent overlap in clusters + bool isEndcapHit=false; // If using endcap, we won't be using integer crystal indices + + // tool functions + inline float pt() const{return (position.mag2()>0) ? energy*sin(position.theta()) : 0.;}; + inline float deta(SimpleCaloHit& other) const{return position.eta() - other.position.eta();}; + int dieta(SimpleCaloHit& other) const + { + if ( isEndcapHit || other.isEndcapHit ) return 9999; // We shouldn't compare integer indices in endcap, the map is not linear + // int indices do not contain zero + // Logic from EBDetId::distanceEta() without the abs() + if (id.ieta() * other.id.ieta() > 0) + return id.ieta()-other.id.ieta(); + return id.ieta()-other.id.ieta()-1; + }; + inline float dphi(SimpleCaloHit& other) const{return reco::deltaPhi(position.phi(), other.position.phi());}; + int diphi(SimpleCaloHit& other) const + { + if ( isEndcapHit || other.isEndcapHit ) return 9999; // We shouldn't compare integer indices in endcap, the map is not linear + // Logic from EBDetId::distancePhi() without the abs() + int PI = 180; + int result = id.iphi() - other.id.iphi(); + while (result > PI) result -= 2*PI; + while (result <= -PI) result += 2*PI; + return result; + }; + float distanceTo(SimpleCaloHit& other) const + { + // Treat position as a point, measure 3D distance + // This is used for endcap hits, where we don't have a rectangular mapping + return (position-other.position).mag(); + }; + bool operator==(SimpleCaloHit& other) const + { + if ( id == other.id && + position == other.position && + energy == other.energy && + isEndcapHit == other.isEndcapHit + ) return true; + + return false; + }; + }; +}; + +L1EGCrystalClusterProducer::L1EGCrystalClusterProducer(const edm::ParameterSet& iConfig) : + debug(iConfig.getUntrackedParameter("debug", false)), + useECalEndcap(iConfig.getUntrackedParameter("useECalEndcap", false)) +{ + produces("EGCrystalCluster"); + produces("EGammaCrystal"); +} + +void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + if ( geometryHelper.getEcalBarrelGeometry() == nullptr ) + { + edm::ESHandle theCaloTopology; + iSetup.get().get(theCaloTopology); + edm::ESHandle pG; + iSetup.get().get(pG); + double bField000 = 4.; + geometryHelper.setupGeometry(*pG); + geometryHelper.setupTopology(*theCaloTopology); + geometryHelper.initialize(bField000); + } + + std::vector ecalhits; + std::vector hcalhits; + + // Retrieve the ecal barrel hits + // using RecHits (https://cmssdt.cern.ch/SDT/doxygen/CMSSW_6_1_2_SLHC6/doc/html/d8/dc9/classEcalRecHit.html) + edm::Handle pcalohits; + iEvent.getByLabel("ecalRecHit","EcalRecHitsEB",pcalohits); + for(auto hit : *pcalohits.product()) + { + if(hit.energy() > 0.2) + { + auto cell = geometryHelper.getEcalBarrelGeometry()->getGeometry(hit.id()); + SimpleCaloHit ehit; + ehit.id = hit.id(); + // So, apparently there are (at least) two competing basic vector classes being tossed around in + // cmssw, the calorimeter geometry package likes to use "DataFormats/GeometryVector/interface/GlobalPoint.h" + // while "DataFormats/Math/interface/Point3D.h" also contains a competing definition of GlobalPoint. Oh well... + ehit.position = GlobalVector(cell->getPosition().x(), cell->getPosition().y(), cell->getPosition().z()); + ehit.energy = hit.energy(); + ecalhits.push_back(ehit); + } + } + + if ( useECalEndcap ) + { + // Retrieve the ecal endcap hits + // using RecHits (https://cmssdt.cern.ch/SDT/doxygen/CMSSW_6_1_2_SLHC6/doc/html/d8/dc9/classEcalRecHit.html) + edm::Handle pcalohitsEndcap; + iEvent.getByLabel("ecalRecHit","EcalRecHitsEE",pcalohitsEndcap); + for(auto hit : *pcalohitsEndcap.product()) + { + if(hit.energy() > 0.2) + { + auto cell = geometryHelper.getEcalEndcapGeometry()->getGeometry(hit.id()); + SimpleCaloHit ehit; + // endcap cell ids won't have any relation to barrel hits + ehit.id = hit.id(); + ehit.position = GlobalVector(cell->getPosition().x(), cell->getPosition().y(), cell->getPosition().z()); + ehit.energy = hit.energy(); + ehit.isEndcapHit = true; + ecalhits.push_back(ehit); + } + } + } + + // Retrive hcal hits + edm::Handle hbhecoll; + iEvent.getByLabel("hbheprereco", hbhecoll); + for (auto hit : *hbhecoll.product()) + { + if ( hit.energy() > 0.1 ) + { + auto cell = geometryHelper.getHcalGeometry()->getGeometry(hit.id()); + SimpleCaloHit hhit; + hhit.id = hit.id(); + hhit.position = GlobalVector(cell->getPosition().x(), cell->getPosition().y(), cell->getPosition().z()); + hhit.energy = hit.energy(); + hcalhits.push_back(hhit); + } + } + + // Cluster containters + std::auto_ptr trigCrystalClusters (new l1slhc::L1EGCrystalClusterCollection ); + std::auto_ptr l1EGammaCrystal( new l1extra::L1EmParticleCollection ); + + // Clustering algorithm + while(true) + { + // Find highest pt hit (that's not already used) + SimpleCaloHit centerhit; + for(const auto& hit : ecalhits) + { + if ( !hit.stale && hit.pt() > centerhit.pt() ) + { + centerhit = hit; + } + } + // If we are less than 1GeV or out of hits (i.e. when centerhit is default constructed) we stop + if ( centerhit.pt() <= 1. ) break; + if ( debug ) std::cout << "-------------------------------------" << std::endl; + if ( debug ) std::cout << "New cluster: center crystal pt = " << centerhit.pt() << std::endl; + + // Find the energy-weighted average position, + // calculate isolation parameter, + // and calculate pileup-corrected pt + GlobalVector weightedPosition; + GlobalVector ECalPileUpVector; + float totalEnergy = 0.; + float ECalIsolation = 0.; + float ECalPileUpEnergy = 0.; + for(auto& hit : ecalhits) + { + if ( !hit.stale && + ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && abs(hit.diphi(centerhit)) < 3) + || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 3.5*1.41 ) )) // endcap crystals are 30mm on a side, 3.5*sqrt(2) cm radius should enclose 3x3 + { + weightedPosition += hit.position*hit.energy; + totalEnergy += hit.energy; + hit.stale = true; + if ( debug && hit == centerhit ) + std::cout << "\x1B[32m"; // green hilight + if ( debug && hit.isEndcapHit ) std::cout << + "\tCrystal pt=" << hit.pt() << + ", eta=" << hit.position.eta() << + ", phi=" << hit.position.phi() << "\x1B[0m" << std::endl; + else if ( debug ) std::cout << + "\tCrystal (" << hit.dieta(centerhit) << "," << hit.diphi(centerhit) << + ") pt=" << hit.pt() << + ", eta=" << hit.position.eta() << + ", phi=" << hit.position.phi() << "\x1B[0m" << std::endl; + } + // Isolation and pileup must not use hits used in a cluster + // We also cut out low pt noise + // As for the endcap hits, well, as far as this algorithm is concerned, caveat emptor... + if ( !hit.stale && hit.pt() > 0.05 ) + { + if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 14 && abs(hit.diphi(centerhit)) < 14) + || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 42. )) + { + ECalIsolation += hit.pt(); + } + if ( hit.pt() < 5. && + ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 7 && abs(hit.diphi(centerhit)) < 57 ) + || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 50.) )) + { + ECalPileUpEnergy += hit.energy; + ECalPileUpVector += hit.position; + } + } + } + weightedPosition /= totalEnergy; + float totalPt = totalEnergy*sin(weightedPosition.theta()); + ECalIsolation /= totalPt; + float totalPtPUcorr = totalPt - ECalPileUpEnergy*sin(ECalPileUpVector.theta())/19.; + + if ( debug ) std::cout << "Weighted position eta = " << weightedPosition.eta() << ", phi = " << weightedPosition.phi() << std::endl; + if ( debug ) std::cout << "Total energy = " << totalEnergy << ", total pt = " << totalPt << std::endl; + if ( debug ) std::cout << "Isolation: " << ECalIsolation << std::endl; + + // Calculate H/E + float hcalEnergy = 0.; + for(const auto& hit : hcalhits) + { + if ( fabs(hit.deta(centerhit)) < 0.15 && fabs(hit.dphi(centerhit)) < 0.15 ) + { + hcalEnergy += hit.energy; + } + } + float hovere = hcalEnergy/totalEnergy; + + if ( debug ) std::cout << "H/E: " << hovere << std::endl; + + // Form a l1slhc::L1EGCrystalCluster + l1slhc::L1EGCrystalCluster cluster; + cluster.et = totalPt; + cluster.eta = weightedPosition.eta(); + cluster.phi = weightedPosition.phi(); + cluster.ieta = centerhit.id.ieta(); + cluster.iphi = centerhit.id.iphi(); + cluster.e = totalEnergy; + cluster.x = weightedPosition.x(); + cluster.y = weightedPosition.y(); + cluster.z = weightedPosition.z(); + cluster.hovere = hovere; + cluster.ECALiso = ECalIsolation; + cluster.ECALetPUcorr = totalPtPUcorr; + + trigCrystalClusters->push_back(cluster); + + // Save clusters with some cuts + if ( cluster.hovere < 2. && cluster.ECALiso < 3. ) + { + reco::Candidate::PolarLorentzVector p4(cluster.et, cluster.eta, cluster.phi, 0.); + l1EGammaCrystal->push_back(l1extra::L1EmParticle(p4, edm::Ref(), 0)); + } + } + + iEvent.put(trigCrystalClusters,"EGCrystalCluster"); + iEvent.put(l1EGammaCrystal, "EGammaCrystal" ); +} + +// ------------ method called when starting to processes a run ------------ +void +L1EGCrystalClusterProducer::beginRun(edm::Run const& iRun, edm::EventSetup const& iSetup) +{ + std::cout << "Apparently beginRun() never gets called?!?!?!" << std::endl; +} + +DEFINE_FWK_MODULE(L1EGCrystalClusterProducer); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc new file mode 100644 index 0000000000000..bea1238fef5df --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc @@ -0,0 +1,238 @@ +// -*- C++ -*- +// +// Package: L1CaloTrigger +// Class: L1EnergySumProducer +// +/**\class L1EnergySumProducer L1EnergySumProducer.cc SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EnergySumProducer.cc + + Description: Produces energy sums from L1 calorimeter objects + + Implementation: + [Notes on implementation] +*/ +// +// Original Author: Mark Baber +// Created: Tue, 18 Mar 2014 20:07:42 GMT +// $Id$ +// +// + + +// system include files +#include + +// user include files +#include +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "CommonTools/UtilAlgos/interface/TFileService.h" + +#include "TLorentzVector.h" +#include "DataFormats/VertexReco/interface/Vertex.h" +#include "DataFormats/VertexReco/interface/VertexFwd.h" +#include "DataFormats/L1Trigger/interface/L1JetParticle.h" +#include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticle.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticleFwd.h" +#include "SimDataFormats/SLHC/interface/L1TowerJet.h" +#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" +#include "FWCore/Framework/interface/LuminosityBlock.h" +#include + + +#include "FWCore/ParameterSet/interface/FileInPath.h" +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + + +#include "DataFormats/L1Trigger/interface/L1EtMissParticle.h" +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/TriggerTowerGeometry.h" + + + +// +// class declaration +// + +class L1EnergySumProducer : public edm::EDProducer { + public: + explicit L1EnergySumProducer(const edm::ParameterSet&); + ~L1EnergySumProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + private: + virtual void beginJob() override; + virtual void produce(edm::Event&, const edm::EventSetup&) override; + virtual void endJob() override; + + //virtual void beginRun(edm::Run const&, edm::EventSetup const&) override; + //virtual void endRun(edm::Run const&, edm::EventSetup const&) override; + //virtual void beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override; + //virtual void endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override; + + // ----------member data --------------------------- + edm::ParameterSet conf_; + + // Tower geometry converter + TriggerTowerGeometry mTowerGeo; + + +}; + +// +// constants, enums and typedefs +// + + +// +// static data member definitions +// + +// +// constructors and destructor +// +L1EnergySumProducer::L1EnergySumProducer(const edm::ParameterSet& iConfig): conf_(iConfig) +{ + + produces( "MET" ); + + +} + + +L1EnergySumProducer::~L1EnergySumProducer() +{ +} + + +// +// member functions +// + +// ------------ method called to produce the data ------------ +void +L1EnergySumProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + + std::auto_ptr outputMET(new l1extra::L1EtMissParticleCollection()); + + + // TT collection + edm::Handle caloTowers; + iEvent.getByLabel(conf_.getParameter("CalorimeterTowers"), caloTowers); + if(!caloTowers.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("CalorimeterTowers") << std::endl; + } + + + + math::PtEtaPhiMLorentzVector MET, protoMET; + double ET = 0; + + // Calculate TT-energy sums + for( l1slhc::L1CaloTowerCollection::const_iterator lTT_It = caloTowers->begin(); + lTT_It != caloTowers->end() ; ++lTT_It ){ + + // Energies in GeV + double E = 0.5*lTT_It->E(); + double H = 0.5*lTT_It->H(); + int iEta = lTT_It->iEta(); + int iPhi = lTT_It->iPhi(); + + // double Eta = mTowerGeo.eta(iEta); + double Phi = mTowerGeo.phi(iPhi); + + + // Restrict to central TTs + if (abs(iEta) > 28) + continue; + + + // Calculate MET + protoMET.SetCoordinates( E + H, 0, Phi, 0 ); + MET += protoMET; + ET += E + H; + + + } + + + + l1extra::L1EtMissParticle l1extraMET( MET, l1extra::L1EtMissParticle::kMET, ET, + edm::Ref< L1GctEtMissCollection >(), edm::Ref< L1GctEtTotalCollection >(), + edm::Ref< L1GctHtMissCollection >(), edm::Ref< L1GctEtHadCollection >() , 0); + + outputMET->push_back( l1extraMET ); + + + + iEvent.put( outputMET, "MET" ); + +} + +// ------------ method called once each job just before starting event loop ------------ +void +L1EnergySumProducer::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1EnergySumProducer::endJob() { +} + +// ------------ method called when starting to processes a run ------------ +/* +void +L1EnergySumProducer::beginRun(edm::Run const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1EnergySumProducer::endRun(edm::Run const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1EnergySumProducer::beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1EnergySumProducer::endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1EnergySumProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1EnergySumProducer); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc new file mode 100644 index 0000000000000..41ef2d8749f79 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc @@ -0,0 +1,149 @@ +/* L1ExtraMaker Creates L1 Extra Objects from Clusters and jets + + S. Dutta SINP-India*/ + + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "SimDataFormats/SLHC/interface/L1CaloCluster.h" +#include "SimDataFormats/SLHC/interface/L1CaloClusterFwd.h" + +#include "SimDataFormats/SLHC/interface/L1CaloJet.h" +#include "SimDataFormats/SLHC/interface/L1CaloJetFwd.h" +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" + +#include "DataFormats/L1Trigger/interface/L1EmParticle.h" +#include "DataFormats/L1Trigger/interface/L1EmParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1JetParticle.h" +#include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" +#include "DataFormats/Math/interface/deltaR.h" + +#include "DataFormats/Candidate/interface/LeafCandidate.h" + + +class L1CaloGeometry; + +namespace l1extra { + class EtComparator { + public: + bool operator()(const l1extra::L1EmParticle a, const l1extra::L1EmParticle b) const { + double et_a = 0.0; + double et_b = 0.0; + if (cosh(a.eta()) > 0.0) et_a = a.energy()/cosh(a.eta()); + if (cosh(b.eta()) > 0.0) et_b = b.energy()/cosh(b.eta()); + + return et_a > et_b; + } + }; + class ClusterETComparator { + public: + bool operator()(const l1slhc::L1EGCrystalCluster a, const l1slhc::L1EGCrystalCluster b) const { + return a.et > b.et; + } + }; +} +class L1ExtraCrystalPosition:public edm::EDProducer { + +public: + explicit L1ExtraCrystalPosition( const edm::ParameterSet & ); + ~L1ExtraCrystalPosition( ); + +private: + + virtual void produce( edm::Event &, const edm::EventSetup & ); + virtual void endJob( ); + unsigned int getMatchedClusterIndex(l1slhc::L1EGCrystalClusterCollection& egxtals, float& eta, float& phi, float& dr_min); + edm::InputTag mEgamma; + edm::InputTag mEgCluster; +}; + +L1ExtraCrystalPosition::L1ExtraCrystalPosition( const edm::ParameterSet & iConfig ): + mEgamma( iConfig.getParameter < edm::InputTag > ( "eGammaSrc" ) ), + mEgCluster( iConfig.getParameter < edm::InputTag > ( "eClusterSrc" ) ) + +{ + // Register Product + produces < l1extra::L1EmParticleCollection > ( "EGammaCrystal" ); +} + + +L1ExtraCrystalPosition::~L1ExtraCrystalPosition( ) +{ +} + + +void L1ExtraCrystalPosition::produce( edm::Event & iEvent, const edm::EventSetup & iSetup ) { + edm::Handle egCrystalClusters; + iEvent.getByLabel(mEgCluster,egCrystalClusters); + l1slhc::L1EGCrystalClusterCollection clusColl = (*egCrystalClusters.product()); + std::sort(clusColl.begin(), clusColl.end(), l1extra::ClusterETComparator()); + + edm::Handle < l1extra::L1EmParticleCollection > eg; + std::auto_ptr < l1extra::L1EmParticleCollection > l1EGammaCrystal( new l1extra::L1EmParticleCollection ); + + if ( iEvent.getByLabel( mEgamma, eg ) ) { + l1extra::L1EmParticleCollection egColl = (*eg.product()); + std::sort(egColl.begin(), egColl.end(), l1extra::EtComparator()); + std::vector matched_indices; + for ( l1extra::L1EmParticleCollection::const_iterator lIt =egColl.begin(); lIt != egColl.end(); ++lIt ) { + l1extra::L1EmParticle em( *lIt ); + float eta = em.eta(); + float phi = em.phi(); + // float et = 0; + // if (cosh(eta) > 0.0) et = em.energy()/cosh(eta); + // std::cout << " Et, Energy, Eta, Phi (before correction) " << et << " " << em.energy() << " " << eta << " " << phi << std::endl; + float deltaR; + unsigned int indx = getMatchedClusterIndex(clusColl, eta, phi, deltaR); + if (indx != 9999 && deltaR < 0.3) { + l1extra::L1EmParticle* em_new = em.clone(); + float eta_new = clusColl[indx].eta; + float phi_new = clusColl[indx].phi; + // float pt_new = em.pt(); + // if (cosh(eta_new) > 0.0) pt_new = em.p()/cosh(eta_new); + // reco::Candidate::PolarLorentzVector lv_em_corr(pt_new, eta_new, phi_new, em.mass()); + // em_new->setP4(lv_em_corr); + // reco::Candidate::PolarLorentzVector & p4 = const_cast (em_new->polarP4()); + // p4.SetPhi(phi_new); + // p4.SetEta(eta_new); + + reco::Candidate::PolarLorentzVector p4(em.pt(), eta_new, phi_new, em.mass()); + em_new->setP4(p4); + l1EGammaCrystal->push_back( *em_new ); + // float et_new = 0; + // if (cosh(em_new->eta()) > 0.0) et_new = em_new->energy()/cosh(em_new->eta()); + // std::cout << " Et, Energy, Eta, Phi (after correction) " << et_new << " " << em_new->energy() << " " << em_new->eta() << " " << em_new->phi() << " deltaR " << deltaR << std::endl; + // std::cout << " px, py, pz " << em_new->px() << " " << em_new->py() << " " << em_new->pz() << std::endl; + // std::cout << " x, y, z " << clusColl[indx].x << " " << clusColl[indx].y << " " << clusColl[indx].z << std::endl; + } + } + iEvent.put(l1EGammaCrystal, "EGammaCrystal" ); + } +} + +// ------------ method called once each job just after ending the event loop ------------ +void L1ExtraCrystalPosition::endJob( ) +{ +} +unsigned int L1ExtraCrystalPosition::getMatchedClusterIndex(l1slhc::L1EGCrystalClusterCollection& egxtals, float& eta, float& phi, float& dr_min) { + dr_min = 999.9; + size_t index_min = 9999; + for (size_t i = 0; i < egxtals.size(); i++) { + float dr = deltaR(egxtals[i].eta, egxtals[i].phi, eta, phi); + if (dr < dr_min) { + index_min = i; + dr_min = dr; + } + } + return index_min; +} + +DEFINE_FWK_MODULE(L1ExtraCrystalPosition); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc index 713edc4d071d3..8e1de2af33593 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerFwdJetProducer.cc @@ -1,3 +1,6 @@ +// Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, +// Modifications : Mark Baber Imperial College, London + #include "SLHCUpgradeSimulations/L1CaloTrigger/interface/L1CaloAlgoBase.h" #include "SimDataFormats/SLHC/interface/L1TowerJet.h" @@ -72,7 +75,7 @@ void L1TowerFwdJetProducer::algorithm( const int &aEta, const int &aPhi ) int lTowerIndex = mCaloTriggerSetup->getBin( aEta, aPhi ); std::pair < int, int > lTowerEtaPhi = mCaloTriggerSetup->getTowerEtaPhi( lTowerIndex ); - l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mHFJetShapeMap.size() , lTowerEtaPhi.first , lTowerEtaPhi.second ); + l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mHFJetShapeMap , lTowerEtaPhi.first , lTowerEtaPhi.second ); if(aEta>=60 || aEta<4){ diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc new file mode 100644 index 0000000000000..05437098c9ad8 --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetCentralityFilter.cc @@ -0,0 +1,514 @@ +// Original Author: Mark Baber Imperial College, London + + + +// system include files +#include +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "CommonTools/UtilAlgos/interface/TFileService.h" + +#include "TLorentzVector.h" +#include "DataFormats/VertexReco/interface/Vertex.h" +#include "DataFormats/VertexReco/interface/VertexFwd.h" +#include "DataFormats/L1Trigger/interface/L1JetParticle.h" +#include "DataFormats/L1Trigger/interface/L1JetParticleFwd.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticle.h" +#include "DataFormats/L1Trigger/interface/L1EtMissParticleFwd.h" +#include "SimDataFormats/SLHC/interface/L1TowerJet.h" +#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" +#include "FWCore/Framework/interface/LuminosityBlock.h" +#include +#include + +#include "FWCore/ParameterSet/interface/FileInPath.h" + +// Bitonic sorting functions +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/BitonicSort.hpp" + +#include + +// +// class declaration +// + + +using namespace l1slhc; +using namespace edm; +using namespace std; +using namespace reco; +using namespace l1extra; + + + + + +struct tempJet +{ + + tempJet( ) : + mJet( NULL ) + {} //constructor + + + tempJet( const l1slhc::L1TowerJet& aJet ) : + mJet( &aJet ) + { /*....*/ } //constructor + + const l1slhc::L1TowerJet* mJet; +}; + + +/* +bool operator> ( tempJet& aA , tempJet& aB ) +{ + + if( aA.mJet == NULL ) return false; //Jets that don't exist: require 128 or 64 spots + if( aB.mJet == NULL ) return true; + + if ( aA.mJet->E() > aB.mJet->E() ) return true; + if ( aA.mJet->E() < aB.mJet->E() ) return false; + + + //those aA and aB with the same energy are all that remain + // if ( *(aA.mComparisonDirection) == phi ){ + return ( abs( aA.mJet-> AsymPhi() ) <= abs( aB.mJet->AsymPhi() ) ); + // }else{ + return ( abs( aA.mJet-> AsymEta() ) <= abs( aB.mJet->AsymEta() ) ); + // } + +} +*/ + + +bool operator>( tempJet & aLeft, tempJet & aRight ){ + // std::cout << "works???\n"; + + +// std::cout << "Pt1 = " << aLeft.mJet->Pt() << "\tPt2 = " << aRight.mJet->Pt() +// << "\tiEta1 = " << aLeft.mJet->iEta() << "\tiPhi1 = " << aLeft.mJet->iPhi() +// << "\tiEta2 = " << aRight.mJet->iEta() << "\tiPhi2 = " << aRight.mJet->iPhi() +// << "\tCent1 = " << aLeft.mJet->Centrality() << "\tCent2 = " << aRight.mJet->Centrality(); + + + if ( aLeft.mJet->Pt() == aRight.mJet->Pt() ){ + + // Degenerate energies + // ~~~~~~~~~~~~~~~~~~~ + // Order by the lowest centrality, for degenerate centralities favour the right jet to avoid needless sorting. + // Result: Favours jets with the lowest iEta and iPhi, due to the original jet ordering + + // std::cout << "\t1>2 = " << ( aLeft.mJet->Centrality() < aRight.mJet->Centrality() ) << "\n"; + return ( aLeft.mJet->Centrality() < aRight.mJet->Centrality() ); + + } + else{ + + // Rank by pT + // ~~~~~~~~~~ + // std::cout << "\t1>2 = " << ( aLeft.mJet->Pt() > aRight.mJet->Pt() ) << " ENERGIES NOT DEGENERATE\n"; + return ( aLeft.mJet->Pt() > aRight.mJet->Pt() ); + } + + +} + +// Sort with srd::sort +bool tempJetSort (tempJet aJet, tempJet bJet) { return ( aJet>bJet); } +// + + + + + + +class L1TowerJetCentralityFilter : public edm::EDProducer { + public: + explicit L1TowerJetCentralityFilter(const edm::ParameterSet&); + ~L1TowerJetCentralityFilter(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + virtual void beginRun(edm::Run&, edm::EventSetup const&); + virtual void endRun(edm::Run&, edm::EventSetup const&); + virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // ----------member data --------------------------- + ParameterSet conf_; + + // Limit of the number of jets to be retained in filtering + int mNumOfOutputJets; + + std::auto_ptr < l1slhc::L1TowerJetCollection > mOutputCollection; + + +}; + +// +// constructors and destructor +// + +L1TowerJetCentralityFilter::L1TowerJetCentralityFilter(const edm::ParameterSet& iConfig): + conf_(iConfig), + mNumOfOutputJets( iConfig.getParameter("NumOfOutputJets") ) +{ + // produces< l1slhc::L1TowerJetCollection >("FilteredTowerJets"); + produces< l1slhc::L1TowerJetCollection >( ); + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetCentralityFilter\n----------------------------------------\n\n"; + +} + +L1TowerJetCentralityFilter::~L1TowerJetCentralityFilter() +{ +} + + + + +// ------------ method called to produce the data ------------ +void +L1TowerJetCentralityFilter::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + + bool evValid = true; + + edm::Handle< L1TowerJetCollection > preFiltJets; + iEvent.getByLabel(conf_.getParameter("PreFilteredJets"), preFiltJets); + if(!preFiltJets.isValid()){ + evValid=false; + } + + if( !evValid ) { + throw cms::Exception("MissingProduct") << conf_.getParameter("preFiltJets") + << std::endl; + } + else{ + + auto_ptr< L1TowerJetCollection > filteredJets(new L1TowerJetCollection()); // Overlap filtered jets + + + + // std::cout << "FLAG\n\n"; + + // std::vector < const l1slhc::L1TowerJet* > lTowerVector; + std::vector < tempJet > tempJetVec; + + + + for (L1TowerJetCollection::const_iterator jetIt = preFiltJets->begin(); jetIt!= preFiltJets->end(); ++jetIt ){ + + L1TowerJet h = *jetIt; + + tempJetVec.push_back( tempJet( *jetIt ) ); + + // FUNKY, SORT THIS OUT... + // lTowerVector.push_back( &(*jetIt) ); + + // lTowerVector.push_back( *jetIt ); + + } + + + + + + + + // Resize array to a power of 2 for the Bitonic sort algorithm + // Find the smallest power of 2 that contains the require jet multiplicity + + + // PERHAPS CALCULATE THE NEAREST POWER OF TWO, THIS IS OVERKILL. I.E BIT SHIFT LEFT AND "AND" THE OUTPUT TO GET MSB + // lTowerVector.resize(4096); + +// for (unsigned int i = 0; ((i < lTowerVector.size()) && (i < 100)); i++){ +// if ( lTowerVector[i] != NULL ){ +// std::cout << "ET = " << lTowerVector[i]->Pt() << "\tCentrality = " << lTowerVector[i]->Centrality() +// << i << "\tiEta = " << lTowerVector[i]->iEta() << "\tiPhi = " << lTowerVector[i]->iPhi() +// << "\n"; +// } +// } + + // lJetWrapper2DVector.resize(4096); //resize to nearest power of 2 to 72*56 for the bitonic sort algorithm + + + + + /* + // Fill the rest with NULL jets, INCREDIBLE INEFFICIENCT, USE THE RESIZE ROUTINE!!!!!!!!!!!!!!!!! + for (int i = lTowerVector.size(); i <= 4096; i++){ + + l1slhc::L1TowerJet* mJet(NULL); + + lTowerVector.push_back( mJet ); + } + + std::cout << lTowerVector.size() << "\n\n\n"; + + + // PERHAPS CALCULATE THE NEAREST POWER OF TWO, THIS IS OVERKILL. I.E BIT SHIFT LEFT AND "AND" THE OUTPUT TO GET MSB + + lTowerVector.resize(4096); //resize to nearest power of 2 to 72*56 for the bitonic sort algorithm + */ + + + // ********************************************************************** + // * Rank jets * + // ********************************************************************** + // + // Rank jets in descending Et, in the case of degenerate energies, rank by the + // 'centrality' secondary sort parameter. + // --------------------------------------------------------------------- + + // sort jets around eta/phi by energy and relevant asymmetry parameter +// L1TowerJetCollection::iterator lStart( preFiltJets->begin() ); +// L1TowerJetCollection::iterator lEnd( preFiltJets->end() ); + +// std::cout << "Prior to start\n"; +// // std::vector< L1TowerJet >::iterator lStart( filteredJets->begin() ); +// std::vector< const l1slhc::L1TowerJet* >::iterator lStart( lTowerVector.begin() ); +// std::cout << "Prior to End\n"; +// // std::vector< L1TowerJet >::iterator lEnd( filteredJets->end() ); +// std::vector< const l1slhc::L1TowerJet* >::iterator lEnd( lTowerVector.end() ); +// std::cout << "Prior to sort\n"; +// BitonicSort< const l1slhc::L1TowerJet* >( down , lStart , lEnd ); +// std::cout << "After sort\n"; + + +/* + for (unsigned int i = 0; ((i < tempJetVec.size()) && (i < 100)); i++){ + if ( tempJetVec[i].mJet != NULL ){ + std::cout << i << "\tET = " << tempJetVec[i].mJet->Pt() << "\tCentrality = " << tempJetVec[i].mJet->Centrality() + << "\tiEta = " << tempJetVec[i].mJet->iEta() << "\tiPhi = " << tempJetVec[i].mJet->iPhi() + << "\n\tET = " << tempJetVec[i+1].mJet->Pt() << "\tCentrality = " << tempJetVec[i+1].mJet->Centrality() + << "\tiEta = " << tempJetVec[i+1].mJet->iEta() << "\tiPhi = " << tempJetVec[i+1].mJet->iPhi() + << "\n\tJet1 > Jet2 = " << ( tempJetVec[i] > tempJetVec[i+1] ) + << "\n\n"; + } + } +*/ + + /* + std::cout << "Prior to start\n"; +// std::vector< L1TowerJet >::iterator lStart( filteredJets->begin() ); + std::vector< tempJet >::iterator lStart2( tempJetVec.begin() ); + std::cout << "Prior to End\n"; + // std::vector< L1TowerJet >::iterator lEnd( filteredJets->end() ); + std::vector< tempJet >::iterator lEnd2( tempJetVec.end() ); + std::cout << "Prior to sort\n"; + // BitonicSort< tempJet >( down , lStart2 , lEnd2 ); + BitonicSort< tempJet >( down , lStart2 , lEnd2 ); + std::cout << "After sort\n"; + */ + + + + // Sort with the std library + std::sort (tempJetVec.begin(), tempJetVec.end(), tempJetSort); + + +// for (unsigned int i = 0; ((i < lTowerVector.size()) && (i < 100)); i++){ +// if ( lTowerVector[i] != NULL ){ +// std::cout << "ET = " << lTowerVector[i]->Pt() << "\tCentrality = " << lTowerVector[i]->Centrality() +// << i << "\tiEta = " << lTowerVector[i]->iEta() << "\tiPhi = " << lTowerVector[i]->iPhi() +// << "\n"; +// std::cout << (lTowerVector[i] < lTowerVector[i+1]) << "\n"; +// // << *lTowerVector[i] +// } +// } + + + +/* + for (unsigned int i = 0; ((i < tempJetVec.size()) && (i < 100)); i++){ + if ( tempJetVec[i].mJet != NULL ){ + std::cout << i << "\tET = " << tempJetVec[i].mJet->Pt() << "\tCentrality = " << tempJetVec[i].mJet->Centrality() + << "\tiEta = " << tempJetVec[i].mJet->iEta() << "\tiPhi = " << tempJetVec[i].mJet->iPhi() + << "\n\tET = " << tempJetVec[i+1].mJet->Pt() << "\tCentrality = " << tempJetVec[i+1].mJet->Centrality() + << "\tiEta = " << tempJetVec[i+1].mJet->iEta() << "\tiPhi = " << tempJetVec[i+1].mJet->iPhi() + << "\n\tJet1 > Jet2 = " << ( tempJetVec[i] > tempJetVec[i+1] ) + << "\n\n"; + + } + } +*/ + + + + +// std::vector::iterator lStart( lJetWrapper2DVector.begin() ); +// std::vector::iterator lEnd( lJetWrapper2DVector.end() ); +// BitonicSort< JetWrapper2D >( down , lStart , lEnd ); + + + + // iEta, iPhi vetoed positions + std::deque< std::pair > lVetos; + // Number of jets currently retained + int lJetCounter(0); + + //THESE AREN'T FILTERED YET!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + + + + // for (L1TowerJetCollection::const_iterator jetIt = preFiltJets->begin(); jetIt!= preFiltJets->end(); ++jetIt ){ + // for( std::vector::iterator jetIt = lTowerVector.begin(); jetIt != lTowerVector.end(); ++jetIt){ + for (unsigned int iTemp = 0; iTemp < tempJetVec.size(); iTemp++){ + //for( std::vector::iterator lIt =lJetWrapper2DVector.begin(); lIt != lJetWrapper2DVector.end(); ++lIt){ + + + // NOTE: Erroneous vetoting of non-square jet shapes still remains. Problem can only + // be resolved if mJetShapeMap of L1TowerJetProducer becomes a member variable + // of L1TowerJet OR if we pass the jet map from module to module + // ##########################!!!!DO THE LATTER!!!!################################################## + + // ********************************************************************** + // * Jet filtering * + // ********************************************************************** + // + // Pick the highest ranked jets for output and veto all the jets that overlap its position. + // ----------------------------------------------------------------------- + + // if( tempJetVec[iTemp].mJet ){ //if jet exists + int lJetsize = tempJetVec[iTemp].mJet->JetSize() ; + bool lVetoed( false ); + + // Check jet iEta and iPhi against list of vetod iEta and iPhi. If jet is vetoed skip to next jet in sorted list. + for( std::deque< std::pair >::iterator vetoIt = lVetos.begin() ; vetoIt != lVetos.end() ; ++vetoIt ){ + + + if ( ( tempJetVec[iTemp].mJet->iEta() == vetoIt->first ) && ( tempJetVec[iTemp].mJet->iPhi() == vetoIt->second) ){ + // Jet is already vetoed break + + // std::cout << "Jet with iEta,iPhi = " << tempJetVec[iTemp].mJet->iEta() << "," << tempJetVec[iTemp].mJet->iPhi() << " vetoed.\n"; + lVetoed = true; break; + } + + } + + if( !lVetoed ){ // If the jet is not vetoed then add to the output collection and add veto region to veto list. + + + // Store the overlap filtered jet + +// std::cout << "Pt = " << tempJetVec[iTemp].mJet->p4().Pt() << "\t" +// << tempJetVec[iTemp].mJet->WeightedEta() << "\t" +// << tempJetVec[iTemp].mJet->WeightedPhi() << "\n" + + double weightedEta = tempJetVec[iTemp].mJet->WeightedEta(); + double weightedPhi = tempJetVec[iTemp].mJet->WeightedPhi(); + filteredJets->insert( weightedEta, weightedPhi, *tempJetVec[iTemp].mJet ); + + // filteredJets->insert( jetIt->iEta() , jetIt->iPhi() , (*jetIt) ); + lJetCounter++; + + // Generate the veto list + for( int i = -lJetsize +1 ; i != lJetsize ; ++i ){ + + + int lPhi( tempJetVec[iTemp].mJet->iPhi() + i ); + + + if( lPhi > 72 ) lPhi -= 72; + if( lPhi < 1 ) lPhi += 72; + // Single veto coordinate (iEta, iPhi) + std::pair veto; + veto.second = lPhi; + // For each iPhi veto all overlapping iEta positions + for( int j = -lJetsize +1 ; j != lJetsize ; ++j ){ + + int lEta( tempJetVec[iTemp].mJet->iEta() + j ); + + // No iEta = 0 in this coordinate system: need to allow for this + // Accounts for the range scanned being too small, due to no + // iEta = 0 being present, by jumping to the end of the range. + // Obtuse but effective. + if( (lEta == 0) && (j < 0) ) lEta = tempJetVec[iTemp].mJet->iEta() - lJetsize; + if( (lEta == 0) && (j > 0) ) lEta = tempJetVec[iTemp].mJet->iEta() + lJetsize; + veto.first = lEta; + + // Add vetoed coordinate to list of vetoes + lVetos.push_back( veto ); + // std::cout << "(" << lEta << ", " << lPhi << ") vetoed.\n"; + } + } + if( lJetCounter >= mNumOfOutputJets ) break; // Restrict number of jets retained in filtering + } + +// } +// else{ +// std::cout << "This actually does something\n"; +// } + + + } // End jet loop + + + // Store the overlap filtered jets + // iEvent.put( filteredJets,"FilteredTowerJets"); + iEvent.put( filteredJets ); + + } // End valid event + + +} + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TowerJetCentralityFilter::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TowerJetCentralityFilter::endJob() +{ +} + +// ------------ method called when starting to processes a run ------------ +void +L1TowerJetCentralityFilter::beginRun(edm::Run&, edm::EventSetup const&) +{ +} + +// ------------ method called when ending the processing of a run ------------ +void +L1TowerJetCentralityFilter::endRun(edm::Run&, edm::EventSetup const&) +{ +} + +// ------------ method called when starting to processes a luminosity block ------------ +void +L1TowerJetCentralityFilter::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} + +// ------------ method called when ending the processing of a luminosity block ------------ +void +L1TowerJetCentralityFilter::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TowerJetCentralityFilter::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TowerJetCentralityFilter); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc index c38b26044ebea..47b92b7a73c90 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUEstimator.cc @@ -13,8 +13,8 @@ // // Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, // Created: Mon Nov 19 10:20:06 CET 2012 -// $Id: L1TowerJetPUEstimator.cc,v 1.1 2013/03/21 17:23:28 rlucas Exp $ -// +// $Id: L1TowerJetPUEstimator.cc,v 1.3 2013/05/16 17:35:30 mbaber Exp $ +// Modifications : Mark Baber Imperial College, London // @@ -42,6 +42,10 @@ #include #include "FWCore/ParameterSet/interface/FileInPath.h" + + + + // // class declaration // @@ -54,8 +58,6 @@ using namespace reco; using namespace l1extra; -bool myfunction (double i,double j) { return (i>j); } - bool sortTLorentz (TLorentzVector i,TLorentzVector j) { return ( i.Pt()>j.Pt() ); } @@ -79,10 +81,12 @@ class L1TowerJetPUEstimator : public edm::EDProducer { double get_rho(double L1rho); //fwd calibration: V ROUGH (only to L1extra particles) -// double rough_ptcal(double pt); - + // double rough_ptcal(double pt); + + // Determines the median value of a vector of doubles double Median(vector aVec); + // ----------member data --------------------------- ParameterSet conf_; @@ -92,13 +96,25 @@ class L1TowerJetPUEstimator : public edm::EDProducer { edm::FileInPath inRhoData_edm; + + + // Determines whether to calibrate rho to offline rho + bool useRhoCalib; + // Inclusive upper limit of the jet indexes to exclude from the median calculation for rho from the ordered jet list + // e.g. skipJetsIndex = 2 => Skip first three jets (indices = 0, 1, 2) + unsigned int skipJetsIndex; + + // Local rho eta region boundaries + vector < double > localRhoEtaDiv; + // Minimum jets in region for the calulation of local rho + unsigned int minimumLocalJets; + }; // // constants, enums and typedefs // - // // static data member definitions // @@ -111,17 +127,35 @@ L1TowerJetPUEstimator::L1TowerJetPUEstimator(const edm::ParameterSet& iConfig): conf_(iConfig) { + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetPUEstimator\n----------------------------------------\n\n"; + + // look up tables + inRhoData_edm = iConfig.getParameter ("inRhodata_file"); + // determine whether to perform the rho calibration + useRhoCalib = iConfig.getParameter< bool >("UseRhoCalibration"); + // number of jets to exclude from the median calculation for rho, subtracting 1 to transform to a jet index + skipJetsIndex = iConfig.getParameter< unsigned int >("numberOfSkippedJets") - 1; + // Divisions of the eta regions overwhich to calculate local rhos + localRhoEtaDiv = iConfig.getParameter< vector< double > >("LocalRhoEtaDivisions"); + // Minimum number of jets required in an eta region to perform a measurement of rho + minimumLocalJets = iConfig.getParameter< unsigned int >("LocalRhoMinJetsInRegion"); + + + // Ensure the divisions are in ascending order of eta + sort (localRhoEtaDiv.begin(), localRhoEtaDiv.end()); + + + produces("RhoCalibrated"); produces("Rho"); + produces< vector< double > >("LocalRho"); + produces< vector< double > >("LocalRhoEtaBoundaries"); + } L1TowerJetPUEstimator::~L1TowerJetPUEstimator() { - - // do anything here that needs to be done at desctruction time - // (e.g. close files, deallocate resources etc.) - } @@ -132,48 +166,170 @@ void L1TowerJetPUEstimator::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { - bool evValid =true; + bool evValid = true; double outrho(0); auto_ptr outRho(new double()); + auto_ptr useCalib(new bool()); + // Local rho in corresponding bin + auto_ptr< vector< double > > localRhoCollection( new vector< double >() ); + + + // Incredibly inefficienct - This should just be read from the config file once in each module that requires it + // + // + // Lower eta edge of rho bin, final bin for upper edge of entire range + // localEtaBoundaries = auto_ptr< vector< double > >( new vector< double > (localRhoEtaDiv) ); + auto_ptr< vector< double > > localEtaBoundaries = auto_ptr< vector< double > >( new vector< double > () ); + + for (unsigned int iSlice = 0; iSlice < localRhoEtaDiv.size(); iSlice++){ + double eta = localRhoEtaDiv[iSlice]; + localEtaBoundaries->push_back( eta ); + } + // + // + // + + + // Store whether rho calibration was applied + *useCalib = useRhoCalib; edm::Handle UnCalibCen; iEvent.getByLabel(conf_.getParameter("FilteredCircle8"), UnCalibCen); if(!UnCalibCen.isValid()){evValid=false;} + + if( !evValid ) { - //edm::LogWarning("MissingProduct") << conf_.getParameter("FilteredCircle8") << "," << conf_.getParameter("FilteredFwdCircle8") << std::endl; - edm::LogWarning("MissingProduct") << conf_.getParameter("FilteredCircle8") << std::endl; + // ???? Surely this should throw an exception if collection is not present? ???? + edm::LogWarning("MissingProduct") << conf_.getParameter("FilteredCircle8") + << std::endl; } else{ - //produce calibrated rho collection - - double areaPerJet(9999); - int count(0); - vector Jet2Energies; - for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); - il1!= UnCalibCen->end() ; ++il1 ){ - if( abs(il1->p4().eta() )>3) continue; - if(count>1) { - Jet2Energies.push_back(il1->p4().Pt()); - //cout<<"jet energy: "<< il1->p4().Pt() <JetArea()* (0.087 * 0.087) ; + + // Produce global rho collection + unsigned int jetIndex(0); + + // Jet energy densities inside the entire calorimeter (global) and local regions + vector jetPtAreaRatioGlobal; + vector < vector > jetPtAreaRatioLocal; + + // Resize the local array to fit the required number of regions + jetPtAreaRatioLocal.resize( localRhoEtaDiv.size() - 1 ); + + + for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); il1!= UnCalibCen->end(); ++il1 ){ + + + + // Restrict to jets in barrel and endcap. This will need to be removed when HF jets are included. + double weightedEta = il1->WeightedEta(); + if( fabs( weightedEta ) > 3.) continue; + + + // Skip the specified number of jets in the calculation of the median for rho + if( jetIndex > skipJetsIndex ){ + + + // ********************************************************************** + // * Global rho * + // ********************************************************************** + + // Store the global jet energy density + double ptAreaRatio = il1->Pt() / il1->JetRealArea(); + jetPtAreaRatioGlobal.push_back( ptAreaRatio ); + + + // ********************************************************************** + // * Local rho * + // ********************************************************************** + + // Determine in which region the jet resides + for (unsigned int iSlice = 0;iSlice < localRhoEtaDiv.size() - 1; iSlice++){ + + // Get the current eta slice range + double etaLow = localRhoEtaDiv[iSlice]; + double etaHigh = localRhoEtaDiv[iSlice + 1]; + + // Store the jet in the respective eta region + if ( (weightedEta >= etaLow) && (weightedEta < etaHigh) ){ + + // Fill the jet in respective vector for calculating local rho (lower edge) + jetPtAreaRatioLocal[iSlice].push_back( ptAreaRatio ); + + // std::cout << "pT = " << il1->Pt() << "\tArea = " << il1->JetRealArea() << "\tEta = " << weightedEta << "\tetaRange = (" << etaLow << ", " << etaHigh << ")\n"; + + } + + + } + + + } + jetIndex++; } - double raw_rho2 = ( Median( Jet2Energies ) / areaPerJet ); - - //apply calibration to the raw rho: should we do this at this stage? - //not sure of the effect on high PU data - /////////////////////////////////////////////////// - // SET VALUE OF RHO - /////////////////////////////////////////////////// - outrho=raw_rho2; - + // Calculate global rho, the median jet energy density + double globalRho = Median(jetPtAreaRatioGlobal); + + + // Calculate local rhos for each eta bin + for (unsigned int iSlice = 0; iSlice < jetPtAreaRatioLocal.size(); iSlice++){ + + double localRho; + + // Check whether enough jets are present to perform local PU subtraction + if (jetPtAreaRatioLocal[iSlice].size() >= minimumLocalJets ){ + // Calculate the rho local to the current bin + localRho = Median( jetPtAreaRatioLocal[iSlice] ); + } + else{ // Insufficient statistics to obtain a useful measure of rho of the region + localRho = 0; + } + + + + // Store the local rho + localRhoCollection->push_back(localRho); + //localEtaBoundaries->push_back( etaLow ); + + } + + + // Determine whether to apply the rho calibration (Only to global rho) + if ( useRhoCalib ){ + + //apply calibration to the raw rho: should we do this at this stage? + //not sure of the effect on high PU data + double cal_rhoL1 = globalRho * get_rho(globalRho); + + // return calibrated rho + outrho = cal_rhoL1; + + } + else{ + + // return uncalibrated rho + outrho = globalRho; + } + + + + + + + *outRho = outrho; + // Return whether rho calibration was applied (global only) + iEvent.put(useCalib,"RhoCalibrated"); + + // Return global rho iEvent.put(outRho,"Rho"); + // Return local rho and the eta regions utilised + iEvent.put(localRhoCollection,"LocalRho"); + iEvent.put(localEtaBoundaries,"LocalRhoEtaBoundaries"); + } //valid event } @@ -195,6 +351,32 @@ L1TowerJetPUEstimator::endJob() { void L1TowerJetPUEstimator::beginRun(edm::Run&, edm::EventSetup const&) { + + if (useRhoCalib){ + //read in calibration for rho lookup table + inrhodata.open(inRhoData_edm.fullPath().c_str()); + if(!inrhodata) cerr << " unable to open rho lookup file. " << endl; + + //read into a vector + pair rho_cal; + double L1rho_(9999), calFac_(9999); + while ( !inrhodata.eof() ) { // keep reading until end-of-file + // sets EOF flag if no value found + inrhodata >> L1rho_ >> calFac_ ; + + rho_cal.first = L1rho_; + rho_cal.second= calFac_; + + rho_cal_vec.push_back(rho_cal); + } + inrhodata.close(); + + std::cout << "\nRead in Rho lookup table\n"; + } + else{ + std::cout << "\nWARNING: Not performing rho calibration\n"; + } + } // ------------ method called when ending the processing of a run ------------ @@ -229,23 +411,49 @@ L1TowerJetPUEstimator::fillDescriptions(edm::ConfigurationDescriptions& descript // member functions // double L1TowerJetPUEstimator::Median( vector aVec){ - sort( aVec.begin(), aVec.end() ); - double median(0); - int size = aVec.size(); - if(size ==0){ - median = 0; - } - else if(size==1){ - median = aVec[size-1]; - } - else if( size%2 == 0 ){ - median = ( aVec[ (size/2)-1 ] + aVec[ (size /2) ] )/2; - }else{ - median = aVec [ double( (size/2) ) +0.5 ]; - } - return median; + + // Order vector collection + sort( aVec.begin(), aVec.end() ); + + double median(0); + int size = aVec.size(); + int halfSize = size/2; + if( size == 0 ){ + median = 0; + } + else if( size == 1 ){ + median = aVec[0]; + } + else if( size%2 == 0 ){ + // Even number of entries, take average of the values around center + median = ( aVec[ halfSize - 1 ] + aVec[ halfSize ] ) * 0.5; + } + else{ + // Odd number of entries, halfSize is central element + median = aVec[ halfSize ]; + } + + return median; } + + + + +double L1TowerJetPUEstimator::get_rho(double L1_rho) +{ + + // Get the rho multiplication factor: + // L1_rho * 2 gets the array index + if(L1_rho <= 40.5){ + return rho_cal_vec[L1_rho*2].second; + } + else{ //for L1 rho > 40.5, calibration flattens out + return 1.44576; + } + +} + //define this as a plug-in DEFINE_FWK_MODULE(L1TowerJetPUEstimator); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc index 693e46b35cfae..f9d6643e4cd80 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetPUSubtractedProducer.cc @@ -5,6 +5,9 @@ //is filtered, uncalibrated jet collection // //Calibration should be done after this step is completed +// +// Original Author: Robyn Elizabeth Lucas,510 1-002,+41227673823, +// Modifications : Mark Baber Imperial College, London // system include files #include @@ -61,14 +64,39 @@ class L1TowerJetPUSubtractedProducer : public edm::EDProducer { // ----------member data --------------------------- - ParameterSet conf_; + ParameterSet conf_; + + // Jet pt threshold for jet energies to be retained after PU subtraction + double jetPtPUSubThreshold; + + // Local rho eta region boundaries + vector < double > localRhoEtaDiv; + + }; L1TowerJetPUSubtractedProducer::L1TowerJetPUSubtractedProducer(const edm::ParameterSet& iConfig): conf_(iConfig) { - produces("PUSubCenJets"); - produces< L1JetParticleCollection >( "PUSubCen8x8" ) ; + + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetPUSubtractedProducer\n----------------------------------------\n\n"; + produces("PrePUSubCenJets"); + produces("PUSubCenJets"); + produces("LocalPUSubCenJets"); + + produces("PUSubCen8x8") ; + produces("CalibFwdJets"); + + // Extract pT threshold for retaining PU subtracted jets + jetPtPUSubThreshold = iConfig.getParameter ("JetPtPUSubThreshold"); + + + // Divisions of the eta regions overwhich to calculate local rhos + localRhoEtaDiv = iConfig.getParameter< vector< double > >("LocalRhoEtaDivisions"); + // Ensure the divisions are in ascending order of eta + sort (localRhoEtaDiv.begin(), localRhoEtaDiv.end()); + + } @@ -83,13 +111,15 @@ L1TowerJetPUSubtractedProducer::~L1TowerJetPUSubtractedProducer() void L1TowerJetPUSubtractedProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { - - bool evValid =true; - auto_ptr< L1TowerJetCollection > outputCollCen(new L1TowerJetCollection()); - produces("CalibFwdJets"); + + bool evValid = true; + auto_ptr< L1TowerJetCollection > outputCollCen(new L1TowerJetCollection()); // Global PU-subtracted central jets + auto_ptr< L1TowerJetCollection > cenLocalPUS(new L1TowerJetCollection()); // Local PU-subtracted central jets + auto_ptr< L1TowerJetCollection > outputCollCenPrePUSub(new L1TowerJetCollection()); // Pre PU-subtracted central jets auto_ptr< L1JetParticleCollection > outputExtraCen(new L1JetParticleCollection()); + // WARNING: May or may not be calibrated, depending on the configuration parameters given for L1TowerJetPUEstimator edm::Handle< double > calRho; iEvent.getByLabel(conf_.getParameter("CalibratedL1Rho"), calRho); if(!calRho.isValid()){ @@ -104,12 +134,39 @@ L1TowerJetPUSubtractedProducer::produce(edm::Event& iEvent, const edm::EventSetu evValid=false; } + + + // Local PU subtraction + // ****************************** + edm::Handle< vector > LocalRho; + iEvent.getByLabel(conf_.getParameter("LocalRho"), LocalRho); + if(!LocalRho.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("LocalRho") << std::endl; + evValid=false; + } + /* + edm::Handle< vector > LocalRhoBoundaries; + iEvent.getByLabel(conf_.getParameter("LocalRhoBoundaries"), LocalRhoBoundaries); + if(!LocalRhoBoundaries.isValid()){ + edm::LogWarning("MissingProduct") << conf_.getParameter("LocalRhoBoundaries") << std::endl; + evValid=false; + } + */ + + if( evValid ) { - //get rho from the producer L1TowerJetPUSubtraction - //This value is calibrated to offline calo rho + // Get rho from the producer L1TowerJetPUSubtraction + // This value is calibrated to offline calo rho if useRhoCalibration in the config file is set to true double cal_rhoL1 = *calRho; + + // Retrive local rhos and eta boundries corresponding to these rhos + // Local PU subtraction + vector lRho = *LocalRho; + // vector localRhoEtaDiv = localRhoEtaDiv;//*LocalRhoBoundaries; + + /////////////////////////////////////////////////// // JET VALUES /////////////////////////////////////////////////// @@ -117,55 +174,122 @@ L1TowerJetPUSubtractedProducer::produce(edm::Event& iEvent, const edm::EventSetu math::PtEtaPhiMLorentzVector upgrade_jet; //Produce calibrated pt collection: central jets - for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); - il1!= UnCalibCen->end() ; - ++il1 ){ - - L1TowerJet h=(*il1); - - // float l1Eta_ = il1->p4().eta(); - // float l1Phi_ = il1->p4().phi(); - float l1Pt_ = il1->p4().Pt(); - - //weighted eta is still not correct - //change the contents out p4, upgrade_jet when it is corrected - float l1wEta_ = il1->WeightedEta(); - float l1wPhi_ = il1->WeightedPhi() ; - + for (L1TowerJetCollection::const_iterator il1 = UnCalibCen->begin(); il1!= UnCalibCen->end(); ++il1 ){ + + L1TowerJet h = (*il1); + + // Extract the old tower jet information and store in a new tower jet + // Extremely awkward, to be fixed later + // double l1Pt_ = il1->Pt(); + double unSubPt = h.Pt(); + double weightedEta = il1->WeightedEta(); + double l1wPhi_ = il1->WeightedPhi() ; + + // **************************************** + // * Store the pre PU subtracted jets * + // **************************************** + + math::PtEtaPhiMLorentzVector p4; + //use weighted eta and phi: these are energy weighted + p4.SetCoordinates(unSubPt , weightedEta , l1wPhi_ , il1->p4().M() ); + h.setP4(p4); + + outputCollCenPrePUSub->insert( weightedEta , l1wPhi_ , h ); //This is just for 8x8 circular jets: change if using different jets - double areaPerJet = 52 * (0.087 * 0.087) ; - //PU subtraction - float l1Pt_PUsub_ = l1Pt_ - (cal_rhoL1 * areaPerJet); + //double areaPerJet = 52 * (0.087 * 0.087) ; - //only keep jet if pt > 0 after PU sub - if(l1Pt_PUsub_>0.1){ + // Get the eta*phi area of the jet + double areaPerJet = il1->JetRealArea(); + + // Perform the PU subtraction + float l1Pt_PUsub_ = unSubPt - (cal_rhoL1 * areaPerJet); + + + // store the PU subtracted jets with Pt greater than specified threshold + if(l1Pt_PUsub_ > jetPtPUSubThreshold){ math::PtEtaPhiMLorentzVector p4; //use weighted eta and phi: these are energy weighted - p4.SetCoordinates(l1Pt_PUsub_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); - + p4.SetCoordinates(l1Pt_PUsub_ , weightedEta , l1wPhi_ , il1->p4().M() ); h.setP4(p4); - outputCollCen->insert( l1wEta_ , l1wPhi_ , h ); - upgrade_jet.SetCoordinates( l1Pt_PUsub_ , l1wEta_ , l1wPhi_ , il1->p4().M() ); + + // Store the PU subtracted towerjet + outputCollCen->insert( weightedEta , l1wPhi_ , h ); + + upgrade_jet.SetCoordinates( l1Pt_PUsub_ , weightedEta , l1wPhi_ , il1->p4().M() ); // add jet to L1Extra list - outputExtraCen->push_back( L1JetParticle( math::PtEtaPhiMLorentzVector( - l1Pt_PUsub_, - l1wEta_, - l1wPhi_, - 0. ), - Ref< L1GctJetCandCollection >(), 0 ) - ); + outputExtraCen->push_back( L1JetParticle( math::PtEtaPhiMLorentzVector( l1Pt_PUsub_, weightedEta, l1wPhi_, 0. ), + Ref< L1GctJetCandCollection >(), 0 ) ); } - } + + + // + // Local PU subtraction + // + + double localSubtractedPt; + + for (unsigned int iSlice = 0;iSlice < localRhoEtaDiv.size() - 1; iSlice++){ + + // Get the current eta slice range + double etaLow = localRhoEtaDiv[iSlice]; + double etaHigh = localRhoEtaDiv[iSlice + 1]; + + + // Store the jet in the respective eta region + if ( (weightedEta >= etaLow) && (weightedEta < etaHigh) ){ + + + // CHECK THIS CORRESPONDS TO THE CORRECT REGION + double localRho = lRho[iSlice]; + + + // Calculate the local PU subtrated pT + localSubtractedPt = unSubPt - localRho * areaPerJet; + + + // std::cout << "pT = " << unSubPt << "\tArea = " << areaPerJet << "\tEta = " << weightedEta << "\tetaRange = (" << etaLow << ", " << etaHigh + // << ")\tPUS pT = " << localSubtractedPt<< "\n"; + // std::cout << "\nEtaLow = " << etaLow << "\tEtaHigh = " << etaHigh << "\tLocalRho = " << localRho << "\tAreaPerJet = " + // << areaPerJet << "\tUnPUSPt = " << unSubPt << "\tLocalPUSPt = " << localSubtractedPt << "\n"; + + } + + + } + + + + + + // store the PU subtracted jets with pT greater than specified threshold + if(localSubtractedPt > jetPtPUSubThreshold){ + + // Local PUS jet + h.setPt(localSubtractedPt); + + // Store the local PUS jet + cenLocalPUS->insert( weightedEta , l1wPhi_, h ); + + } + } + + // Store the pre PU-subtracted, positive energy central jets + iEvent.put(outputCollCenPrePUSub,"PrePUSubCenJets"); + + //this is the slhc collection containing extra information + iEvent.put(outputCollCen,"PUSubCenJets"); - //this is the slhc collection containing extra information - iEvent.put(outputCollCen,"PUSubCenJets"); - //this is the l1extra collection containing the same jet vector as in slhc collection - iEvent.put(outputExtraCen,"PUSubCen8x8"); + iEvent.put(cenLocalPUS,"LocalPUSubCenJets"); + + //this is the l1extra collection containing the same jet vector as in slhc collection + iEvent.put(outputExtraCen,"PUSubCen8x8"); + + } } diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc index 72fe7c1845574..49e210cee49c3 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1TowerJetProducer.cc @@ -1,3 +1,5 @@ +// Original Author: Andrew W. Rose Imperial College, London +// Modifications : Mark Baber Imperial College, London #include "SLHCUpgradeSimulations/L1CaloTrigger/interface/L1CaloAlgoBase.h" @@ -23,45 +25,62 @@ public L1CaloAlgoBase < l1slhc::L1CaloTowerCollection, l1slhc::L1TowerJetCollect void algorithm( const int &, const int & ); private: - void calculateJetPosition( l1slhc::L1TowerJet & lJet ); + // void calculateJetPosition( l1slhc::L1TowerJet & lJet ); //some helpful members int mJetDiameter; l1slhc::L1TowerJet::tJetShape mJetShape; std::vector< std::pair< int , int > > mJetShapeMap; + // Jet Pt and TT E seed thresholds + double jetPtThreshold, seedEThreshold; + }; L1TowerJetProducer::L1TowerJetProducer( const edm::ParameterSet & aConfig ):L1CaloAlgoBase < l1slhc::L1CaloTowerCollection, l1slhc::L1TowerJetCollection > ( aConfig ) { + + std::cout << "\n\n----------------------------------------\nBegin: L1TowerJetProducer\n----------------------------------------\n\n"; + + // load the jet Pt and TT E seed thresholds + jetPtThreshold = aConfig.getParameter ("JetPtThreshold"); + seedEThreshold = aConfig.getParameter ("SeedEnergyThreshold"); + std::string lJetShape = aConfig.getParameter< std::string >("JetShape"); mJetDiameter = aConfig.getParameter("JetDiameter"); mPhiOffset = 0; + + //note: this mEtaOffset works when read in setupHF.xml in SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py + //must be used with aEta>4 in algorithm() function below + // mEtaOffset = -(mJetDiameter+4); + + //if use with setup.xml where don't read in HF wires use + mEtaOffset = -(mJetDiameter); + //and don't need aEta>4 condition + + // mPhiIncrement = 1; + // mEtaIncrement = 1; - //note: this mEtaOffset works when read in setupHF.xml in SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py - //must be used with aEta>4 in algorithm() function below -// mEtaOffset = -(mJetDiameter+4); + mJetShapeMap.reserve(256); //jets will never be 16x16 but it is a nice round number - //if use with setup.xml where don't read in HF wires use - mEtaOffset = -(mJetDiameter); - //and don't need aEta>4 condition - // mPhiIncrement = 1; - // mEtaIncrement = 1; + //do the comparison in upper case so config file can read "Circle", "circle", "CIRCLE", "cIrClE", etc. and give the same result. + std::transform( lJetShape.begin(), lJetShape.end(), lJetShape.begin(), ::toupper ); + std::cout << "Creating JetShapeMap:\n"; - mJetShapeMap.reserve(256); //jets will never be 16x16 but it is a nice round number - std::string lJetShape = aConfig.getParameter< std::string >("JetShape"); - std::transform( lJetShape.begin() , lJetShape.end() , lJetShape.begin() , ::toupper ); //do the comparison in upper case so config file can read "Circle", "circle", "CIRCLE", "cIrClE", etc. and give the same result. + // ******************************************************************** + // * Circular jet shape * + // ******************************************************************** - std::cout << "Creating JetShapeMap:" << std::endl; if ( lJetShape == "CIRCLE" ){ mJetShape = l1slhc::L1TowerJet::circle; - double lCentre( (mJetDiameter-1) / 2.0 ); + double lCentre( (mJetDiameter - 1) / 2.0 ); double lDelta; + // Caculate square of the distance from jet centre to TT std::vector lDeltaSquare; for( int i = 0 ; i != mJetDiameter ; ++i ){ lDelta = double(i) - lCentre; @@ -69,22 +88,28 @@ L1TowerJetProducer::L1TowerJetProducer( const edm::ParameterSet & aConfig ):L1Ca } double lDeltaRSquare; + // Calculate maximum deltaR = (mJetDiameter/2)^2 double lDeltaRSquareMax( (mJetDiameter*mJetDiameter) / 4.0 ); + // Determine and store the TTs that are inside the deltaR region for( int x = 0 ; x != mJetDiameter ; ++x ){ for( int y = 0 ; y != mJetDiameter ; ++y ){ lDeltaRSquare = lDeltaSquare[x] + lDeltaSquare[y]; + // TT is inside the deltaR^2 region if( lDeltaRSquare <= lDeltaRSquareMax ){ mJetShapeMap.push_back( std::make_pair( x , y ) ); - //std::cout << "#" << std::flush; - }else{ - //std::cout << "-" << std::flush; } } - //std::cout << std::endl; } - }else{ + } + + + // ******************************************************************** + // * Square jet shape * + // ******************************************************************** + + else if ( lJetShape == "SQUARE" ){ mJetShape = l1slhc::L1TowerJet::square; @@ -94,117 +119,93 @@ L1TowerJetProducer::L1TowerJetProducer( const edm::ParameterSet & aConfig ):L1Ca } } } + + // Shape does not exist + else{ + + throw cms::Exception("Invalid jet shape type") + << "ERROR: Jet shape '" << lJetShape + << "' not recognised, check the input in the configuration file matches a valid type.\n"; + + } std::cout << "JetShapeMap includes " << mJetShapeMap.size() << " towers." << std::endl; - std::cout<<" Eta offset is "<< mEtaOffset << std::endl; + std::cout << "Eta offset is " << mEtaOffset << std::endl; + + } L1TowerJetProducer::~L1TowerJetProducer( ) { } -/* - void L1TowerJetProducer::initialize( ) { } -*/ +// Generate all the possible tower jets in the event void L1TowerJetProducer::algorithm( const int &aEta, const int &aPhi ) { -// if(aEta>4){ - - int lTowerIndex = mCaloTriggerSetup->getBin( aEta, aPhi ); + + int lTowerIndex = mCaloTriggerSetup->getBin( aEta, aPhi ); std::pair < int, int > lTowerEtaPhi = mCaloTriggerSetup->getTowerEtaPhi( lTowerIndex ); - l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mJetShapeMap.size() , lTowerEtaPhi.first , lTowerEtaPhi.second ); - - for ( std::vector< std::pair< int , int > >::const_iterator lJetShapeMapIt = mJetShapeMap.begin() ; lJetShapeMapIt != mJetShapeMap.end() ; ++lJetShapeMapIt ) - { - int lPhi = aPhi+(lJetShapeMapIt->second); - if ( lPhi > mCaloTriggerSetup->phiMax( ) ) lPhi -= 72; //mCaloTriggerSetup->phiMax( ); - - l1slhc::L1CaloTowerCollection::const_iterator lTowerItr = fetch( aEta+(lJetShapeMapIt->first) , lPhi ); + // Construct a TowerJet object at the current iEta, iPhi position with given jet shape and size + l1slhc::L1TowerJet lJet( mJetDiameter, mJetShape , mJetShapeMap , lTowerEtaPhi.first , lTowerEtaPhi.second ); + // Calculate the geometric center of the jet + lJet.calculateJetCenter(); - if ( lTowerItr != mInputCollection->end( ) ) - { - l1slhc::L1CaloTowerRef lRef( mInputCollection, lTowerItr - mInputCollection->begin( ) ); - lJet.addConstituent( lRef ); - lJet.CalcWeightediEta(); - lJet.CalcWeightediPhi(); - } - } - - if ( lJet.E( ) > 0 ) - { - calculateJetPosition( lJet ); - - lJet.calculateWeightedEta();lJet.calculateWeightedPhi(); - mOutputCollection->insert( lTowerEtaPhi.first, lTowerEtaPhi.second, lJet ); - } -//} -} + // Parameter to determine whether at least one TT in the tower jet exceeds the specified energy threshold + bool exceedsSeedThreshold = false; + + // Iterate over the jet shape mask + for ( std::vector< std::pair< int , int > >::const_iterator lJetShapeMapIt = mJetShapeMap.begin() ; lJetShapeMapIt != mJetShapeMap.end() ; + ++lJetShapeMapIt ){ -void L1TowerJetProducer::calculateJetPosition( l1slhc::L1TowerJet & lJet ) -{ + // Mask TT iPhi + int lPhi = aPhi + (lJetShapeMapIt->second); + if ( lPhi > mCaloTriggerSetup->phiMax( ) ) lPhi -= 72; //mCaloTriggerSetup->phiMax( ); + + // Get TT at current position: (aEta + jetMapEta, iPhi) + l1slhc::L1CaloTowerCollection::const_iterator lTowerItr = fetch( aEta + (lJetShapeMapIt->first) , lPhi ); - double tmpeta(9999); - double halfTowerOffset = 0.0435; - const double endcapEta[8] = { 0.09, 0.1, 0.113, 0.129, 0.15, 0.178, 0.15, 0.35 }; - double JetSize = double(lJet.JetSize()) / 2.0; - //std::cout<<" jet ieta: "<< lJet.iEta( ); - int abs_eta = lJet.iEta( ) + int(JetSize) ; - //std::cout<<" centre of jet: "<=0 && lJet.iEta( )<0 ) abs_eta += 1; - - //std::cout<<" account for no zero: "<end( ) ){ + l1slhc::L1CaloTowerRef lRef( mInputCollection, lTowerItr - mInputCollection->begin( ) ); + // Check that at least one TT exceeds a seed energy threshold - Compensate for 2 GeV units + if ( (lRef->E() + lRef->H()) >= 2*seedEThreshold ){ + exceedsSeedThreshold = true; + } - if ( abs_eta < 21 ) - { - tmpeta = ( abs_eta * 0.0870 - halfTowerOffset); - - if( lJet.JetSize() % 2 == 1 ) tmpeta += halfTowerOffset; + // Add TT to the tower jet + lJet.addConstituent( lRef ); + } } - else - { - abs_eta -= 21; + - tmpeta = 1.74; + + // Add jets to the output collection, require that the at least one TT possess energy greater than the specified + // seed threshold and that the jet possesses a Pt greater than the specified jet Pt threshold + if ( (exceedsSeedThreshold) && (lJet.E() > jetPtThreshold) ){ - for ( int i = 0; i != int(abs_eta); ++i ) - { - tmpeta += endcapEta[i]; - } + + // Calculate the energy weighted eta and phi and the centrality of the jet + lJet.calculateWeightedJetCenter(); + lJet.calculateCentrality(); + lJet.setP4( math::PtEtaPhiMLorentzVector( lJet.E(), lJet.WeightedEta(), lJet.WeightedPhi(), 0. ) ); - if( lJet.JetSize() % 2 == 0 ) tmpeta += endcapEta[abs_eta] / 2.; - else tmpeta += endcapEta[abs_eta]; + // Store jet in the output collection + mOutputCollection->insert( lTowerEtaPhi.first, lTowerEtaPhi.second, lJet ); } - if(( lJet.iEta( ) + int(JetSize) )<0) tmpeta = (-1)*tmpeta; - //if (lJet.iEta()>0) tmpeta-=0.087; - - // std::cout<<"jet ieta: "<pi) phi-=2*pi; - - double Et = double( lJet.E( ) ) / 2.; - - lJet.setP4( math::PtEtaPhiMLorentzVector( Et, tmpeta, phi, 0. ) ); +} -} diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py index 6e85a1f2d616f..58c7e75672509 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py +++ b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cff.py @@ -21,11 +21,13 @@ L1CaloJetProducer+ L1CaloJetFilter+ L1TowerJetProducer+ - L1TowerJetFilter1D+ - L1TowerJetFilter2D+ + L1TowerJetCentralityFilter+ + #L1TowerJetFilter1D+ + #L1TowerJetFilter2D+ L1TowerJetPUEstimator+ L1TowerJetPUSubtractedProducer+ L1CalibFilterTowerJetProducer+ + L1EnergySumProducer+ # L1TowerFwdJetProducer+ # L1TowerFwdJetFilter1D+ diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py index 1806c8de3fe73..143e77a7cbf53 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py +++ b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_cfi.py @@ -1,6 +1,30 @@ import FWCore.ParameterSet.Config as cms +#---------------------------------------------------------------------------------------------------- +# Global variables +#---------------------------------------------------------------------------------------------------- +# +# Info: These are variables that are required by several modules. +# +#---------------------------------------------------------------------------------------------------- + + +# Specify the boundaries of the eta regions in which to apply local PU subtraction +gLocalRhoEtaDivisions = cms.vdouble( -3.0, -1.3, 0.0, 1.3, 3.0 ) + +# Run on Asymmetry filtered jets +#gPrePUSJets = "L1TowerJetFilter2D" +# Run on Centrality filtered jets +gPrePUSJets = "L1TowerJetCentralityFilter" + + + +gJetDiameter = cms.uint32(9) # default to 9x9 ~ deltaR 0.4 Jets + + +#==================================================================================================== + L1CaloTriggerSetupSource = cms.ESSource("EmptyESSource", recordName = cms.string('L1CaloTriggerSetupRcd'), firstValid = cms.vuint32(1), @@ -133,59 +157,136 @@ src = cms.InputTag("L1CaloJetFilter") ) + L1TowerJetProducer = cms.EDProducer("L1TowerJetProducer", + + # UNCOMMENT TO RUN ON RINGSUBTRACTED CALOTOWERS + #src = cms.InputTag("L1RingSubtractionProducer"), + # UNCOMMENT TO RUN ON UN-RINGSUBTRACTED CALOTOWERS src = cms.InputTag("L1CaloTowerProducer"), - JetDiameter = cms.uint32(8), - JetShape = cms.string("circle") # "circle" or "square" + + + JetDiameter = gJetDiameter, + JetShape = cms.string("circle"), # "circle" or "square" + + # Jet Pt (GeV) threshold and the seed threshold requirement (require that at least one TT + # posses E greater than threshold) for the constructed jets to be retained + JetPtThreshold = cms.double(0.1), + SeedEnergyThreshold = cms.double(0), + #SeedEnergyThreshold = cms.double(5), +) + +# Centrality filtering +L1TowerJetCentralityFilter = cms.EDProducer("L1TowerJetCentralityFilter", + PreFilteredJets = cms.InputTag("L1TowerJetProducer"), + # Limit on number of jets that can be retained + NumOfOutputJets = cms.uint32(999) ) L1TowerJetFilter1D = cms.EDProducer("L1TowerJetFilter1D", src = cms.InputTag("L1TowerJetProducer"), - ComparisonDirection = cms.string("eta"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(4) + ComparisonDirection = cms.string("eta"), # "eta" or "phi" + # Old arbitrary jet 1D limit + #NumOfOutputJets = cms.uint32(4) + NumOfOutputJets = cms.uint32(999) ) L1TowerJetFilter2D = cms.EDProducer("L1TowerJetFilter2D", src = cms.InputTag("L1TowerJetFilter1D"), - ComparisonDirection = cms.string("phi"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(12) + ComparisonDirection = cms.string("phi"), # "eta" or "phi" + # Old arbitrary jet event limit + #NumOfOutputJets = cms.uint32(12) + NumOfOutputJets = cms.uint32(999) ) + + L1TowerJetPUEstimator = cms.EDProducer("L1TowerJetPUEstimator", - inRhodata_file = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/rho_lookup.txt'), - FilteredCircle8 = cms.InputTag("L1TowerJetFilter2D"), + inRhodata_file = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/rho_lookup.txt'), +# FilteredCircle8 = cms.InputTag("L1TowerJetFilter2D"), + FilteredCircle8 = cms.InputTag(gPrePUSJets), + # Choose whether to calibrate rho to offline rho + UseRhoCalibration = cms.bool(False), + # number of jets, from the start of the ordered jet collection, to exclude from the median calculation of rho + # numberOfSkippedJets = 1 => Skip leading jet only + numberOfSkippedJets = cms.uint32(1), + # Specify the boundaries of the eta regions in which to apply local PU subtraction + LocalRhoEtaDivisions = cms.vdouble( gLocalRhoEtaDivisions ), + # Specify the minimum number of jets in each eta region before a local rho is calculated. + # If threshold is not met, zero is subtracted. + LocalRhoMinJetsInRegion = cms.uint32(2) ) + L1TowerJetPUSubtractedProducer = cms.EDProducer("L1TowerJetPUSubtractedProducer", - FilteredCircle8 = cms.InputTag("L1TowerJetFilter2D"), + + FilteredCircle8 = cms.InputTag(gPrePUSJets), CalibratedL1Rho = cms.InputTag("L1TowerJetPUEstimator", "Rho"), + + # Local PU subtraction + LocalRho = cms.InputTag("L1TowerJetPUEstimator", "LocalRho"), +# LocalRhoBoundaries = cms.InputTag("L1TowerJetPUEstimator", "LocalRhoEtaBoundaries"), + # Specify the boundaries of the eta regions in which to apply local PU subtraction + LocalRhoEtaDivisions = cms.vdouble( gLocalRhoEtaDivisions ), + + # Energy (GeV) threshold of the jets that are to be retained after PU subtraction + JetPtPUSubThreshold = cms.double(0.1), ) + L1CalibFilterTowerJetProducer = cms.EDProducer("L1CalibFilterTowerJetProducer", - inMVA_weights_file = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/TMVARegression_BDT.weights.xml'), - PUSubtractedCentralJets = cms.InputTag("L1TowerJetPUSubtractedProducer","PUSubCenJets"), + + + # Energy (GeV) threshold of jets to be used in the calculation jet energy sums + EnergySumsJetPtThreshold = cms.double(15), + + # Calibration parameters + # ------------------------------ + + # Input uncalibrated jet collection + UncalibratedTowerJets = cms.InputTag("L1TowerJetPUSubtractedProducer","LocalPUSubCenJets"), + + # L1 pT calibration threshold, minimum L1 jet pT (GeV) to apply correction + pTCalibrationThreshold = cms.double( 10 ), + + # Calibration eta-binning + EtaRegionSlice = cms.vdouble( -3.0, -2.172, -1.74, -1.392, -1.044, -0.695, -0.348, 0.0, + 0.348, 0.695, 1.044, 1.392, 1.74, 2.172, 3.0), + + # Number of calibration parameters used in LUT + CalibrationParameters = cms.uint32( 6 ), + + # Location of LUT + CalibrationLUTFile = cms.FileInPath('SLHCUpgradeSimulations/L1CaloTrigger/data/pu140.LUT'), + ) +L1EnergySumProducer = cms.EDProducer("L1EnergySumProducer", + CalorimeterTowers = cms.InputTag("L1CaloTowerProducer:","EVENT_DATA"), +) L1TowerFwdJetProducer = cms.EDProducer("L1TowerFwdJetProducer", src = cms.InputTag("L1CaloTowerProducer"), - JetDiameter = cms.uint32(8), - JetShape = cms.string("circle") # "circle" or "square" -) + + JetDiameter = gJetDiameter, + JetShape = cms.string("circle") # "circle" or "square" +) + + L1TowerFwdJetFilter1D = cms.EDProducer("L1TowerJetFilter1D", src = cms.InputTag("L1TowerFwdJetProducer"), ComparisonDirection = cms.string("eta"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(4) + NumOfOutputJets = cms.uint32(999) ) L1TowerFwdJetFilter2D = cms.EDProducer("L1TowerJetFilter2D", src = cms.InputTag("L1TowerFwdJetFilter1D"), ComparisonDirection = cms.string("phi"), # "eta" or "phi" - NumOfOutputJets = cms.uint32(12) + NumOfOutputJets = cms.uint32(999) ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py new file mode 100644 index 0000000000000..ae279c2487820 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p1_cfi.py @@ -0,0 +1,256 @@ +import FWCore.ParameterSet.Config as cms + +# Test rate sample at CERN, part 1 +# The files in minBiasFiles_p1 correspond to about 20k events + +minBiasFiles_p1 = cms.untracked.vstring( +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_1.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_10.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_100.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_101.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_102.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_103.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_104.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_105.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_106.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_107.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_108.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_109.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_11.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_110.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_111.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_112.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_113.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_114.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_115.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_116.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_117.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_118.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_119.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_12.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_120.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_121.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_122.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_123.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_124.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_125.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_126.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_127.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_128.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_129.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_13.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_130.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_131.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_132.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_133.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_134.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_135.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_136.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_137.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_138.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_139.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_14.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_140.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_141.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_142.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_143.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_144.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_145.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_146.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_147.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_148.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_149.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_15.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_150.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_151.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_152.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_153.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_154.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_155.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_156.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_157.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_158.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_159.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_16.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_160.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_161.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_162.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_163.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_164.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_165.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_166.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_167.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_168.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_169.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_17.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_170.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_171.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_172.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_173.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_174.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_175.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_176.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_177.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_178.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_179.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_18.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_180.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_181.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_182.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_183.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_184.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_185.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_186.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_187.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_188.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_189.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_19.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_190.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_191.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_192.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_193.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_194.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_195.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_196.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_197.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_198.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_199.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_2.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_20.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_200.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_201.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_202.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_203.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_204.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_205.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_206.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_207.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_208.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_209.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_21.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_210.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_211.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_212.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_213.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_214.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_215.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_216.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_217.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_218.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_219.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_22.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_220.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_221.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_222.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_223.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_224.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_225.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_226.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_227.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_228.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_229.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_23.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_230.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_231.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_232.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_233.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_234.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_235.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_236.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_237.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_238.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_239.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_24.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_240.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_241.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_242.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_243.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_244.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_245.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_246.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_247.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_248.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_249.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_25.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_250.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_251.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_252.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_253.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_254.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_255.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_256.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_257.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_258.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_259.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_26.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_260.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_261.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_262.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_263.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_264.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_265.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_266.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_267.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_268.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_269.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_27.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_270.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_271.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_272.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_273.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_274.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_275.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_276.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_277.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_278.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_279.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_28.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_280.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_281.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_282.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_283.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_284.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_285.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_286.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_287.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_288.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_289.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_29.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_290.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_291.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_292.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_293.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_294.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_295.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_296.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_297.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_298.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_299.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_3.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_30.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_300.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_301.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_302.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_303.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_304.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_305.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_306.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_307.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_308.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_309.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_31.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_310.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_311.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_312.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_313.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_314.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_315.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_316.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_317.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_318.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_319.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_32.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_320.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_321.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_322.root" +) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py new file mode 100644 index 0000000000000..477d3efcd79d2 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/minBiasFiles_p2_cfi.py @@ -0,0 +1,256 @@ +import FWCore.ParameterSet.Config as cms + +# Test rate sample at CERN, part 2 +# The files in minBiasFiles_p2 correspond to about 20k events + +minBiasFiles_p2 = cms.untracked.vstring( +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_323.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_324.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_325.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_326.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_327.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_328.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_329.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_33.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_330.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_331.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_332.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_333.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_334.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_335.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_336.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_337.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_338.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_339.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_34.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_340.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_341.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_342.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_343.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_344.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_345.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_346.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_347.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_348.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_349.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_35.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_350.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_351.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_352.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_353.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_354.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_355.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_356.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_357.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_358.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_359.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_36.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_360.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_361.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_362.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_363.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_364.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_365.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_366.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_367.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_368.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_369.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_37.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_370.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_371.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_372.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_373.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_374.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_375.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_376.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_377.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_378.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_379.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_38.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_380.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_381.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_382.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_383.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_384.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_385.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_386.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_387.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_388.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_389.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_39.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_390.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_391.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_392.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_393.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_394.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_395.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_396.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_397.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_398.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_399.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_4.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_40.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_400.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_401.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_402.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_403.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_404.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_405.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_406.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_407.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_408.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_409.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_41.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_410.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_411.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_412.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_413.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_414.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_415.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_416.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_417.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_418.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_419.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_42.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_420.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_421.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_422.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_423.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_424.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_425.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_426.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_427.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_428.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_429.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_43.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_430.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_431.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_432.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_433.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_434.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_435.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_436.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_437.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_438.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_439.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_44.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_440.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_441.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_442.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_443.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_444.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_445.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_446.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_447.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_448.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_449.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_45.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_450.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_451.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_452.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_453.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_454.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_455.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_456.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_457.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_458.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_459.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_46.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_460.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_461.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_462.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_463.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_464.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_465.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_466.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_467.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_468.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_469.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_47.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_470.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_471.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_472.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_473.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_474.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_475.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_476.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_477.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_478.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_479.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_48.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_480.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_481.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_482.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_483.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_484.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_485.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_486.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_487.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_488.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_489.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_49.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_490.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_491.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_492.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_493.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_494.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_495.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_496.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_497.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_498.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_499.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_5.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_50.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_51.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_52.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_53.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_54.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_55.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_56.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_57.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_58.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_59.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_6.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_60.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_61.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_62.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_63.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_64.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_65.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_66.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_67.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_68.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_69.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_7.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_70.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_71.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_72.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_73.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_75.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_76.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_77.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_78.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_79.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_8.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_80.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_81.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_82.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_83.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_84.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_85.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_86.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_87.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_88.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_89.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_9.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_90.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_91.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_92.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_93.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_94.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_95.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_96.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_97.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_98.root", +"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Neutrinos/PU140/NeutrinoGun_E2023TTI_PU140_99.root" +) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py new file mode 100644 index 0000000000000..9474206a1c73f --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py @@ -0,0 +1,216 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) + +# +# This runs over a file that already contains the L1Tracks. +# +# +# It also runs a trivial analyzer than prints the objects +# that have been created. + + +#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p2_cfi import * +#from SLHCUpgradeSimulations.L1TrackTrigger.singleMuonFiles_cfi import * + +process.source = cms.Source("PoolSource", + fileNames = minBiasFiles_p2 + #fileNames = minBiasFiles_p1 + #fileNames = singleMuonFiles +) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + + + +# --------------------------------------------------------------------------- +# +# --- Produces the Run-1 L1muon objects +# + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') + +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') + + +# --- creates l1extra objects for L1Muons + + # raw2digi to get the GT digis +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.p0 = cms.Path( process.RawToDigi ) + # run L1Reco +process.load('Configuration.StandardSequences.L1Reco_cff') +process.L1Reco = cms.Path( process.l1extraParticles ) + + +# --------------------------------------------------------------------------- + + +# +# --- Produces the L1TkMuons from the naive DeltaR producer :: +# + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkMuonProducer_cfi") +process.pMuonsNaive = cms.Path( process.L1TkMuonsNaive ) + + + +# +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# +# --- The central muons from the Padova algorithm +# + + +################################################################################################# +# now, all the DT related stuff +################################################################################################# +# to produce, in case, collection of L1MuDTTrack objects: +#process.dttfDigis = cms.Path(process.simDttfDigis) + +# the DT geometry +process.load("Geometry.DTGeometry.dtGeometry_cfi") +process.load("Geometry.MuonNumbering.muonNumberingInitialization_cfi") +process.load("SimMuon/DTDigitizer/muonDTDigis_cfi") +##process.load("L1TriggerConfig.DTTPGConfigProducers.L1DTTPGConfig_cff") + +################################################################################################# +# define the producer of DT + TK objects +################################################################################################# +process.load("L1Trigger.DTPlusTrackTrigger.DTPlusTrackProducer_cfi") +process.DTPlusTk_step = cms.Path(process.DTPlusTrackProducer) + + +process.L1TkMuonsDT = cms.EDProducer("L1TkMuonDTProducer" +) + +process.pMuonsDT = cms.Path( process.L1TkMuonsDT ) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# +# --- The muons from Slava + +process.load("L1Trigger.L1ExtraFromDigis.l1extraMuExtended_cfi") +process.load("SLHCUpgradeSimulations.L1TrackTrigger.l1TkMuonsExt_cff") + +# this is based on all GMTs available (BX=0 is hardcoded ) +process.l1tkMusFromExtendedAllEta = cms.Path(process.l1extraMuExtended * process.l1TkMuonsExt ) + +# this is based on CSCTF record directly (no GMT sorting) and creates TkMus in |eta| > 1.1 +process.l1tkMusFromExtendedForward = cms.Path(process.l1extraMuExtended * process.l1TkMuonsExtCSC ) + + + +# --------------------------------------------------------------------------- + +# +# finally, merge the collections of TkMuons. +# - for the central region: take the Padova's algorithm +# - for non-central, take Slava's algorithm +# - at high eta, CSC + new chambers are used +# - in the intermediate region, GMT muons +# are used. +# Currently waiting for Slava's code. So I use the +# TkMuons created by the naive producer. +# + +process.L1TkMuonsMerge = cms.EDProducer("L1TkMuonMerger", + TkMuonCollections = cms.VInputTag( cms.InputTag("L1TkMuonsDT","DTMatchInwardsTTTrackFullReso"), + #cms.InputTag("L1TkMuonsNaive",""), + cms.InputTag("l1TkMuonsExt",""), + cms.InputTag("l1TkMuonsExtCSC","") ), + absEtaMin = cms.vdouble( 0., 0. , 1.1), # Padova's not ready yet + absEtaMax = cms.vdouble( 0., 1.1 , 5.0) +) + +process.pMuonsMerge = cms.Path( process.L1TkMuonsMerge) + + +# Run a trivial analyzer that prints the objects + +process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , + L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here + L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here + L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), # dummy here + L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), # dummy here + L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here +) + +#process.pAna = cms.Path( process.ana ) + + + +# --------------------------------------------------------------------------- + +# --- Output module : + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example_muons.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + +process.Out.outputCommands.append('keep *_L1TkMuons*_*_*') +process.Out.outputCommands.append('keep *_l1extraMuExtended_*_*') +process.Out.outputCommands.append('keep *_l1TkMuonsExt*_*_*') + +process.Out.outputCommands.append('keep *L1Muon*_l1extraParticles_*_*') + +#process.Out.outputCommands.append('keep *_DTPlusTrackProducer_*_*') + + # raw data +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + + + # gen-level information +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') + + + # the L1Tracks, clusters and stubs +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + +# --- to use the genParticles, one needs to keep the collections of associators below: +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + diff --git a/SimDataFormats/SLHC/BuildFile.xml b/SimDataFormats/SLHC/BuildFile.xml new file mode 100644 index 0000000000000..2176dc6067ed1 --- /dev/null +++ b/SimDataFormats/SLHC/BuildFile.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/SimDataFormats/SLHC/doc/html/index.html b/SimDataFormats/SLHC/doc/html/index.html new file mode 100644 index 0000000000000..133483673c9e7 --- /dev/null +++ b/SimDataFormats/SLHC/doc/html/index.html @@ -0,0 +1,12 @@ + + + + + + + + +This Text Inserted from File doc/html/index.html + + + diff --git a/SimDataFormats/SLHC/doc/html/overview.html b/SimDataFormats/SLHC/doc/html/overview.html new file mode 100644 index 0000000000000..3336bef2e166a --- /dev/null +++ b/SimDataFormats/SLHC/doc/html/overview.html @@ -0,0 +1,13 @@ + + + +This Text Inserted from File doc/html/overview.html + + + + + +
Status : +Unknown +
+ diff --git a/SimDataFormats/SLHC/interface/EtaPhiContainer.h b/SimDataFormats/SLHC/interface/EtaPhiContainer.h new file mode 100644 index 0000000000000..4dedb2b0b3c3a --- /dev/null +++ b/SimDataFormats/SLHC/interface/EtaPhiContainer.h @@ -0,0 +1,177 @@ +#ifndef EtaPhiContainer_h +#define EtaPhiContainer_h + +#include +#include +#include + +#include "DataFormats/Common/interface/RefTraits.h" + + + + +template < typename T > class EtaPhiContainer +{ + friend std::ostream& operator<< ( std::ostream& aStream , const EtaPhiContainer& aContainer ){ + int i(0); + for( typename EtaPhiContainer::const_iterator lIt=aContainer.begin() ; lIt!=aContainer.end() ; ++lIt ){ + aStream << "Element " << (i++) << " :\n" << *lIt << "\n"; + } + return aStream; + } + + + public: + typedef typename std::vector < T >::iterator iterator; + typedef typename std::vector < T >::const_iterator const_iterator; + + typedef T value_type; + + public: + EtaPhiContainer( ): + mHash( std::vector < uint16_t > ( 16384, uint16_t( -1 ) ) ) + { + mContainer.reserve( 16384 ); + } + + + EtaPhiContainer( const EtaPhiContainer < T > &aEtaPhiContainer ): + mContainer( aEtaPhiContainer.mContainer ), + mHash( aEtaPhiContainer.mHash ) + { + mContainer.reserve( 16384 ); + } + + + virtual ~ EtaPhiContainer( ) + { + } + + T & at( const std::size_t & aIndex ) + { + return mContainer.at( aIndex ); + } + + const T & at( const std::size_t & aIndex ) const + { + return mContainer.at( aIndex ); + } + + + iterator find( const int &aEta, const int &aPhi ) + { + uint16_t lIndex = mHash.at( hash( aEta, aPhi ) ); + + if ( lIndex == uint16_t( -1 ) ){ + return mContainer.end( ); + } + return mContainer.begin( ) + lIndex; + } + + + const_iterator find( const int &aEta, const int &aPhi )const + { + uint16_t lIndex = mHash.at( hash( aEta, aPhi ) ); + + if ( lIndex == uint16_t( -1 ) ){ + return mContainer.end( ); + } + return mContainer.begin( ) + lIndex; + } + + +/* + std::vector< T >& operator->(){ return mContainer; } + std::vector< T >& operator*(){ return mContainer; } +*/ + + iterator begin( ) + { + return mContainer.begin( ); + } + + const_iterator begin( ) const + { + return mContainer.begin( ); + } + + iterator end( ) + { + return mContainer.end( ); + } + + const_iterator end( ) const + { + return mContainer.end( ); + } + + iterator insert( const int &aEta, const int &aPhi, const T & aT ) + { + mHash.at( hash( aEta, aPhi ) ) = mContainer.size( ); + mContainer.push_back( aT ); + return ( --mContainer.end( ) ); + } + + std::size_t size( )const + { + return mContainer.size( ); + } + + + void sort( ){ + std::multimap < T , uint16_t > lMap; + for( uint16_t lHash = 0 ; lHash != mHash.size( ) ; ++lHash ){ + uint16_t lIndex = mHash.at( lHash ); + if( lIndex != uint16_t( -1 ) ){ + lMap.insert ( std::make_pair( *(mContainer.begin( ) + lIndex) , lHash ) ); + mHash.at( lHash ) = uint16_t( -1 ); + } + } + + mContainer.clear(); + + for( typename std::multimap < T , uint16_t >::reverse_iterator lItr = lMap.rbegin(); lItr != lMap.rend(); ++lItr ){ + mHash.at( lItr->second ) = mContainer.size(); + mContainer.push_back( lItr->first ); + } + } + + + private: + inline uint16_t hash( const int &aEta, const int &aPhi )const + { + return uint16_t( ( ( aEta & 0x7f ) << 7 ) | ( aPhi & 0x7f ) ); + } + + + private: + std::vector < T > mContainer; + std::vector < uint16_t > mHash; +}; + + + + +template < typename T > class EtaPhiContainerLookUp:public std::binary_function < const EtaPhiContainer < T > &, int, const T *> +{ + public: + const T *operator( ) ( const EtaPhiContainer < T > &aContainer, int aIndex ) + { + return &aContainer.at( aIndex ); + } +}; + + +namespace edm +{ + namespace refhelper + { + template < typename T > class FindTrait < EtaPhiContainer < T >, T > + { + public: + typedef EtaPhiContainerLookUp < T > value; + }; + } +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloCluster.h b/SimDataFormats/SLHC/interface/L1CaloCluster.h new file mode 100644 index 0000000000000..78d9946daf682 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloCluster.h @@ -0,0 +1,204 @@ +#ifndef L1CaloCluster_h +#define L1CaloCluster_h + + +#include +/* This ClassDescribes the 2x2 cluster thing 0|1 - - The Cluster reference point is 0 (ieta,iphi)=0,0 2|3 + + M.Bachtis, S.Dasu University of Wisconsin-Madison */ + + +//S. Harper changes: +//WARNING: this class contains MANY SUPRISES +//okay this is a temporary solution as we need something to work right now (22/05) and it has been decided to rewrite this class new the near future for a better package +//it has been decided that e/gamma + taus will continue to share the same cluster class rather than having seperate classes +//however they have little incommon with each other than they are both calo objects +//interface changes +//1) need to store emEt and hadEt seperately +//2) need to store emIsolEt and hadIsolEt seperately (this may change but we study them seperately for now. Instead of repurposing the isolation variables, I just added them for now +//3) E is renamed Et() because thats what it is, it also takes an int telling you if its EmEt, HadEt or TotEt to return, this is really handy for the cluster producers and filtering and swapping between tau and e/gamma mode +//4) leadTowerE is always em+had because its a tau thing + + +#include "DataFormats/Math/interface/LorentzVector.h" +#include "SimDataFormats/SLHC/interface/L1CaloTower.h" +#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" + +namespace l1slhc +{ + + class L1CaloCluster + { + //SH: this operator does not have mIsoenergyeg or tau included for some reason, I have note updated it to have mIsoEmEtEG or mIsoHadEtEG either + friend bool operator==( const l1slhc::L1CaloCluster & a, const l1slhc::L1CaloCluster & b ) + { + if ( a.mIeta != b.mIeta ) + return false; + if ( a.mIphi != b.mIphi ) + return false; + if ( a.mFg != b.mFg ) + return false; + if ( a.mEgamma != b.mEgamma ) + return false; + if ( a.mLeadtowertau != b.mLeadtowertau ) + return false; + if ( a.mEgammavalue != b.mEgammavalue ) + return false; + if ( a.mInnereta != b.mInnereta ) + return false; + if ( a.mInnerphi != b.mInnerphi ) + return false; + if ( a.mIsoclusterseg != b.mIsoclusterseg ) + return false; + if ( a.mIsoclusterstau != b.mIsoclusterstau ) + return false; + if ( a.mIsoeg != b.mIsoeg ) + return false; + if ( a.mIsotau != b.mIsotau ) + return false; + if ( a.mCentral != b.mCentral ) + return false; + if ( a.mEmEt != b.mEmEt ) + return false; + if ( a.mHadEt != b.mHadEt ) + return false; + if ( a.mP4 != b.mP4 ) + return false; + return true; + } + + + public: + L1CaloCluster( ); + L1CaloCluster( const int &, const int & ); + ~L1CaloCluster( ); + + void setFg( const bool & ); // Set FG Bit + void setEGamma( const bool & ); // Set EGamma Bit + void setEGammaValue( const int & ); // Set EGamma Value E/E+H (%) + void setIsoClusters( const int &, const int & ); // Number of isolated objectsisolation Clusters + void setIsoEnergy( const int &, const int & ); // Energy of Isolation + void setIsoEmAndHadEtEG( const int &, const int & ); + void setIsoEG( const bool & ); // EG isolation + void setIsoTau( const bool & ); // Tau isolation + void setCentral( const bool & ); // Central Bit + void setLeadTower( const bool & ); // Lead Tower over threshold bit for taus + void setLorentzVector( const math::PtEtaPhiMLorentzVector & ); // Central Bit + void setPosBits( const int &, const int & ); + void setConstituents( const L1CaloTowerRefVector & ); + void setEmEt( const int & ); + void setHadEt( const int & ); + void setLeadTowerE( const int & ); + void setSecondTowerE( const int & ); + void setThirdTowerE( const int & ); + void setFourthTowerE( const int & ); + void setRing1E( const int & ); + void setRing2E( const int & ); + void setRing3E( const int & ); + void setRing4E( const int & ); + void addConstituent( const L1CaloTowerRef & ); + int hasConstituent( const int &, const int & )const; //SH change: should be const so adding const + void removeConstituent( const int &, const int & ); + + // Get Functions + const int &iEta( ) const; // Eta of origin in integer coordinates + const int &iPhi( ) const; // Phi of Origin in integer + const int Et(int mode=0x3) const; // Compressed Et SH: name change mode = bit 1 add EmEt, bit 2 add HadEt, I had to make this a non-reference variable as it returns the sum of mEmEt + mHadEt, leave as is for now + const int &EmEt()const; // SH: addition + const int &HadEt()const; // SH: addition + const int &LeadTowerE( ) const; // Lead Tower Et + const int &SecondTowerE( ) const; // Lead Tower Et + const int &ThirdTowerE( ) const; // Lead Tower Et + const int &FourthTowerE( ) const; // Lead Tower Et + const int &Ring1E( ) const; // Lead Tower Et + const int &Ring2E( ) const; // Lead Tower Et + const int &Ring3E( ) const; // Lead Tower Et + const int &Ring4E( ) const; // Lead Tower Et + const int &innerEta( ) const; // Weighted position eta + const int &innerPhi( ) const; // Weighted position phi + const L1CaloTowerRefVector & getConstituents( ) const; + L1CaloTowerRef getConstituent( const int & )const; //SH change: should be const so adding const + + + + + + // Electron Variables + const bool & fg( ) const; // Finegrain bit + const bool & eGamma( ) const; // Electron/Photon bit + const int &eGammaValue( ) const; // Electron/Photon bit + + // isolation Variables + const bool & isCentral( ) const; // Means that the cluster was not pruned during isolation + const bool & isoEG( ) const; // Egamma Isolatioon + const bool & isoTau( ) const; // Tau isolation + const int &isoClustersEG( ) const; // 2x2 isolation clusters for Egamma cuts + const int &isoClustersTau( ) const; // 2x2 isolation clusters for Tau Cut + const int &isoEnergyEG( ) const; // 2x2 isolation clusters for Egamma cuts + const int &isoEnergyTau( ) const; // 2x2 isolation clusters for Egamma cuts + const bool & hasLeadTower( ) const; + + const int &isoEmEtEG( ) const; + const int &isoHadEtEG( ) const; + + // Trigger Results + bool isEGamma( ) const; // Returns the EGAMMA decision + bool isIsoEGamma( ) const; // Returns the iso EGAMMA decision + bool isTau( ) const; // returns The Tau decison + bool isIsoTau( ) const; // returns The Tau decison + + const math::PtEtaPhiMLorentzVector & p4( ) const; // returns Physics wise LorentzVector in eta,phi continuous space + + + + private: + // Refs to teh caloTowwers + L1CaloTowerRefVector mConstituents; + + // Coordinates of the reference Point + int mIeta; + int mIphi; + int mEmEt; + int mHadEt; + int mLeadTowerE; //Lead Tower Energy + int mSecondTowerE; //Lead Tower Energy + int mThirdTowerE; //Lead Tower Energy + int mFourthTowerE; //Lead Tower Energy + int mRing1E; //Lead Tower Energy + int mRing2E; //Lead Tower Energy + int mRing3E; //Lead Tower Energy + int mRing4E; //Lead Tower Energy + // FineGrain / EGamma /Isolations + + bool mFg; + bool mEgamma; + bool mCentral; + bool mIsoeg; + bool mLeadtowertau; + bool mIsotau; + int mEgammavalue; + int mInnereta; + int mInnerphi; + int mIsoclusterseg; + int mIsoenergyeg; + int mIsoenergytau; + int mIsoclusterstau; + + math::PtEtaPhiMLorentzVector mP4; // Lorentz Vector of precise position + + int mIsoEmEtEG; // SH: addition + int mIsoHadEtEG; // SH: addition + + }; + +} + +// Sorting functor +namespace std{ + bool operator< ( const l1slhc::L1CaloCluster & aLeft, const l1slhc::L1CaloCluster & aRight ); +} + +std::ostream & operator<<( std::ostream & , const l1slhc::L1CaloCluster & ); + + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloClusterFwd.h b/SimDataFormats/SLHC/interface/L1CaloClusterFwd.h new file mode 100644 index 0000000000000..16b5162b7c908 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloClusterFwd.h @@ -0,0 +1,21 @@ +#ifndef L1CaloCluster_Fwd +#define L1CaloCluster_Fwd + + +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "DataFormats/Common/interface/Ref.h" + +namespace l1slhc +{ + class L1CaloCluster; +} + +namespace l1slhc +{ + // typedef std::vector L1CaloClusterCollection; + typedef EtaPhiContainer < L1CaloCluster > L1CaloClusterCollection; + + typedef edm::Ref < L1CaloClusterCollection > L1CaloClusterRef; +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h b/SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h new file mode 100644 index 0000000000000..55c2e835869ef --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h @@ -0,0 +1,148 @@ +#ifndef L1CaloClusterWithSeed_h +#define L1CaloClusterWithSeed_h + + +#include + +#include "DataFormats/Math/interface/LorentzVector.h" +#include "SimDataFormats/SLHC/interface/L1CaloTower.h" +#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" + +namespace l1slhc +{ + + class L1CaloClusterWithSeed + { + + friend bool operator==( const l1slhc::L1CaloClusterWithSeed & a, const l1slhc::L1CaloClusterWithSeed & b ) + { + if ( a.mIeta != b.mIeta ) + return false; + if ( a.mIphi != b.mIphi ) + return false; + if ( a.mFg != b.mFg ) + return false; + if ( a.mEgamma != b.mEgamma ) + return false; + if ( a.mEgammavalue != b.mEgammavalue ) + return false; + if ( a.mIsoeg != b.mIsoeg ) + return false; + if ( a.mEmEt != b.mEmEt ) + return false; + if ( a.mHadEt != b.mHadEt ) + return false; + if ( a.mP4 != b.mP4 ) + return false; + return true; + } + + + public: + L1CaloClusterWithSeed( ); + L1CaloClusterWithSeed( const int &, const int & ); + L1CaloClusterWithSeed( const L1CaloTowerRef & seed, int seedThreshold=4, int emThreshold=2, int hadThreshold=2 ); + ~L1CaloClusterWithSeed( ); + + void setFg( bool ); // Set FG Bit + void setEGamma( bool ); // Set EGamma Bit + void setEGammaValue( int ); // Set EGamma Value E/E+H (%) + void setIsoEmAndHadEtEG( const int &, const int & ); + void setIsoEG( const bool & ); // EG isolation + void setLorentzVector( const math::PtEtaPhiMLorentzVector & ); + void setPosBits( int , int ); + void setConstituents( const L1CaloTowerRefVector & ); + void setEmEt( int ); + void setHadEt( int ); + void setTrimmedPlus( bool trimmed=true); + void setTrimmedMinus( bool trimmed=true); + void addConstituent( const L1CaloTowerRef & ); + int hasConstituent( int , int ) const; + void removeConstituent( int , int ); + void addFriend(const L1CaloTowerRef & ); + int hasFriend( int , int ); + void removeFriend( int , int ); + + // Get Functions + int iEta( ) const; // Eta of seed in integer coordinates + int iPhi( ) const; // Phi of seed in integer + int Et(int mode=0x3) const; // Compressed Et SH: name change mode = bit 1 add EmEt, bit 2 add HadEt, I had to make this a non-reference variable as it returns the sum of mEmEt + mHadEt, leave as is for now + int EmEt( ) const; // Compressed ECAL Et + int HadEt( ) const; // Compressed HCAL Et + bool trimmedPlus() const; + bool trimmedMinus() const; + int innerEta( ) const; // Weighted position eta + int innerPhi( ) const; // Weighted position phi + L1CaloTowerRef getSeedTower( ) const; + const L1CaloTowerRefVector & getConstituents( ) const; + L1CaloTowerRef getConstituent( int ); + int seedEmEt() const; + int seedHadEt() const; + int constituentEmEt(int , int ) const; + int constituentHadEt(int , int ) const; + void shareConstituent(int, int, int); + L1CaloTowerRef getFriend( int ); + + + + + + // Electron Variables + bool fg( ) const; // Finegrain bit + bool eGamma( ) const; // Electron/Photon bit + int eGammaValue( ) const; // Electron/Photon bit + const bool & isoEG( ) const; // Egamma Isolatioon + + // Trigger Results + bool isEGamma( ) const; // Returns the EGAMMA decision + bool isIsoEGamma( ) const; // Returns the iso EGAMMA decision + const int &isoEmEtEG( ) const; + const int &isoHadEtEG( ) const; + + const math::PtEtaPhiMLorentzVector & p4( ) const; // returns Physics wise LorentzVector in eta,phi continuous space + + + + private: + // Refs to the caloTowwers + L1CaloTowerRef mSeedTower; + L1CaloTowerRefVector mConstituents; + std::vector mConstituentSharing; + L1CaloTowerRefVector mFriends; + + int mSeedThreshold; + int mEmThreshold; + int mHadThreshold;// for H/E calculation + + // Coordinates of the reference Point + int mIeta; + int mIphi; + int mEmEt; + int mHadEt; + + bool mTrimmedPlus; + bool mTrimmedMinus; + bool mFg; + bool mEgamma; + int mEgammavalue; + bool mIsoeg; + int mIsoEmEtEG; // SH: addition + int mIsoHadEtEG; // SH: addition + int mInnereta; + int mInnerphi; + + math::PtEtaPhiMLorentzVector mP4; // Lorentz Vector of precise position + + }; + +} + +// Sorting functor +namespace std{ + bool operator< ( const l1slhc::L1CaloClusterWithSeed & aLeft, const l1slhc::L1CaloClusterWithSeed & aRight ); +} + +std::ostream & operator<<( std::ostream & , const l1slhc::L1CaloClusterWithSeed & ); + + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h b/SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h new file mode 100644 index 0000000000000..7fd19160ddaa0 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h @@ -0,0 +1,21 @@ +#ifndef L1CaloClusterWithSeed_Fwd +#define L1CaloClusterWithSeed_Fwd + + +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "DataFormats/Common/interface/Ref.h" + +namespace l1slhc +{ + class L1CaloClusterWithSeed; +} + +namespace l1slhc +{ + // typedef std::vector L1CaloClusterWithSeedCollection; + typedef EtaPhiContainer < L1CaloClusterWithSeed > L1CaloClusterWithSeedCollection; + + typedef edm::Ref < L1CaloClusterWithSeedCollection > L1CaloClusterWithSeedRef; +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloJet.h b/SimDataFormats/SLHC/interface/L1CaloJet.h new file mode 100644 index 0000000000000..d24c7b6b3fbc9 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloJet.h @@ -0,0 +1,67 @@ +#ifndef L1CaloJet_h +#define L1CaloJet_h + +/* + This class describves the L1 Reconstructed jet M.Bachtis,S.Dasu University of Wisconsin - Madison */ + +#include "DataFormats/Math/interface/LorentzVector.h" +#include +#include "SimDataFormats/SLHC/interface/L1CaloRegionFwd.h" +#include "SimDataFormats/SLHC/interface/L1CaloRegion.h" + +namespace l1slhc +{ + + class L1CaloJet + { + + public: + + L1CaloJet( ); + L1CaloJet( const int&, const int& ); + ~L1CaloJet( ); + + // getters + const int& iEta( ) const; + const int& iPhi( ) const; + const int& E( ) const; + const bool& central( ) const; + const math::PtEtaPhiMLorentzVector& p4( ) const; // returns LorentzVector in eta,phi space + + // Setters + void setP4( const math::PtEtaPhiMLorentzVector & ); + void setCentral( const bool& ); + void setE( const int& ); + + void addConstituent( const L1CaloRegionRef & ); + int hasConstituent( const int&, const int& ); + void removeConstituent( const int&, const int& ); + + const L1CaloRegionRefVector& getConstituents( ) const; + + + + private: + int mIeta; + int mIphi; + int mE; + bool mCentral; + + L1CaloRegionRefVector mConstituents; + math::PtEtaPhiMLorentzVector mP4; + + }; + + +} + + +// Sorting functor +namespace std{ + bool operator< ( const l1slhc::L1CaloJet & aLeft, const l1slhc::L1CaloJet & aRight ); +} + + +std::ostream & operator<<( std::ostream & , const l1slhc::L1CaloJet & ); + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloJetFwd.h b/SimDataFormats/SLHC/interface/L1CaloJetFwd.h new file mode 100644 index 0000000000000..95e331b3f4318 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloJetFwd.h @@ -0,0 +1,22 @@ +#ifndef L1CaloJet_Fwd +#define L1CaloJet_Fwd + + +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "DataFormats/Common/interface/Ref.h" +#include + +namespace l1slhc +{ + class L1CaloJet; +} + +namespace l1slhc +{ + // typedef std::vector L1CaloJetCollection; + typedef EtaPhiContainer < L1CaloJet > L1CaloJetCollection; + + typedef edm::Ref < L1CaloJetCollection > L1CaloJetRef; +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloRegion.h b/SimDataFormats/SLHC/interface/L1CaloRegion.h new file mode 100644 index 0000000000000..0b555c4b89b5a --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloRegion.h @@ -0,0 +1,40 @@ +#ifndef L1CaloRegion_h +#define L1CaloRegion_h + +/* This ClassDescribes the 4x4 region + + M.Bachtis, S.Dasu University of Wisconsin-Madison */ + +namespace l1slhc +{ + + class L1CaloRegion + { + public: + L1CaloRegion( ); + L1CaloRegion( const int&, const int&, const int& ); + ~L1CaloRegion( ); + + // Get Functions + const int& iEta( ) const; // Eta of origin in integer coordinates + const int& iPhi( ) const; // Phi of Origin in integer + const int& E( ) const; // Compressed Et + + + + private: + int mIeta; + int mIphi; + int mE; + + }; + +} + + +// Sorting functor +namespace std{ + bool operator<( const l1slhc::L1CaloRegion & aLeft, const l1slhc::L1CaloRegion & aRight ); +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloRegionFwd.h b/SimDataFormats/SLHC/interface/L1CaloRegionFwd.h new file mode 100644 index 0000000000000..44bcfe8e68941 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloRegionFwd.h @@ -0,0 +1,25 @@ +#ifndef L1CaloRegion_Fwd +#define L1CaloRegion_Fwd + +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "DataFormats/Common/interface/Ref.h" +#include + + +namespace l1slhc +{ + class L1CaloRegion; +} + +namespace l1slhc +{ + // typedef std::vector L1CaloRegionCollection; + typedef EtaPhiContainer < L1CaloRegion > L1CaloRegionCollection; + + + typedef edm::Ref < L1CaloRegionCollection > L1CaloRegionRef; + typedef std::vector < L1CaloRegionRef > L1CaloRegionRefVector; +} + + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTower.h b/SimDataFormats/SLHC/interface/L1CaloTower.h new file mode 100644 index 0000000000000..4b7038101befb --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloTower.h @@ -0,0 +1,60 @@ +/* L1CaloTower class Keeps both ECAL/HCAL Tower information . Used as input for Clustering + + M.Bachtis,S.Dasu University of Wisconsin-Madison + + Modified Andrew W. Rose Imperial College, London */ + + +#ifndef L1CaloTower_h +#define L1CaloTower_h + +#include + + +namespace l1slhc +{ + + class L1CaloTower + { + + public: + + L1CaloTower( ); + L1CaloTower( const int &, const int & ); // Set Tower position (iEta,iPhi) + ~L1CaloTower( ); + + + // Setters + void setPos( const int &, const int & ); // Set Tower position (iEta,iPhi) + // void setParams( const int& , const int& , const bool& ); //Set ECAL,HCAL Energy and finegrain + + void setEcal( const int &, const bool & ); + void setHcal( const int &, const bool & ); + + // getters + const int &E( ) const; + const int &H( ) const; + const int &iEta( ) const; + const int &iPhi( ) const; + const bool & EcalFG( ) const; + const bool & HcalFG( ) const; + + private: + int mEcal; + int mHcal; + int mIeta; + int mIphi; + bool mEcalFG; + bool mHcalFG; + + + }; + +} + +// Sorting functor +namespace std{ + bool operator< ( const l1slhc::L1CaloTower & aLeft, const l1slhc::L1CaloTower & aRight ); +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTowerFwd.h b/SimDataFormats/SLHC/interface/L1CaloTowerFwd.h new file mode 100644 index 0000000000000..2cac83f6c87d2 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloTowerFwd.h @@ -0,0 +1,26 @@ +#ifndef L1CaloTower_Fwd +#define L1CaloTower_Fwd + +#include "DataFormats/Common/interface/Ref.h" +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "SimDataFormats/SLHC/interface/L1CaloTower.h" + +#include + +/* + namespace l1slhc { class L1CaloTower; } */ + + +namespace l1slhc +{ + + + // typedef std::vector L1CaloTowerCollection; + typedef EtaPhiContainer < L1CaloTower > L1CaloTowerCollection; + + typedef edm::Ref < L1CaloTowerCollection > L1CaloTowerRef; + + typedef std::vector < L1CaloTowerRef > L1CaloTowerRefVector; +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h b/SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h new file mode 100644 index 0000000000000..26f5121d439c9 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h @@ -0,0 +1,291 @@ +/* SLHC Calo Trigger Class for Trigger configuration...Contains wiring and Cuts M.Bachtis,S.Dasu. University of Wisconsin-Madison */ + + +#ifndef L1CaloTriggerSetup_h +#define L1CaloTriggerSetup_h + +#include +#include +#include + + +class L1CaloTriggerSetup +{ + private: + int mLatticedim; // Eta Dimension of the square lattice + int mLatticeeta0; // Eta of the Square Lattice + int mLatticephi0; // Phi of the Square Lattice + int mLatticeetam; // Eta of the Square Lattice + int mLatticephim; // Phi of the Square Lattice + int mEcalactivitycut; // Ecal Activity Cut + int mHcalactivitycut; // hcalActivity Cut +/* + int mElectroncuta; //Electron ID Cut + int mElectroncutb; //Electron ID Cut + int mElectroncutc; //Electron ID Cut +*/ + std::vector < int > mElectroncut; + int mTauseedtower; // Electron ID Cut + int mClustercut; // Cluster Threshold Cut + +/* + int mIsolationea; //Isolation ratio Electron; + int mIsolationeb; //Isolation ratio Electron; +*/ + std::vector < int > mIsolatione; +/* + int mIsolationta;//Isolation ratio Tau; + int mIsolationtb;//Isolation ratio Tau; +*/ + std::vector < int > mIsolationt; +/* + int mIsolationthreg; //Isolation threshold EG; + int mIsolationthrtau;//Isolation threshold Tau; +*/ + std::vector < int > mIsothr; + int mIsolationzone; // Number of towers that define the isolation zone; + // int mJetcenter ; //jet Center Deviation + int mJetet; // jet Center Deviation + int mFinegrainpass; // ignore fine grain bit (set it to 0) + + // Geometry Mapping between towers/lattice + std::map < int, std::pair < int, int > > mGeomap; + + + public: + + const std::pair < int, int > &getTowerEtaPhi( const int &bin ) const + { + return mGeomap.find( bin )->second; + } + + + // Lattice Navigation helper Functions + int getEta( const int &bin ) const // get the ieta of a specific Bin + { + return bin % mLatticedim; + + } + int getPhi( const int &bin ) const // get the iphi of a specific bin + { + return bin / mLatticedim; + } + + int getBin( const int &eta, const int &phi ) const // get the bin for a ieta,iphi pair + { + return phi * mLatticedim + eta; + } + + + + const int &etaMin( ) const + { + return mLatticeeta0; + } + + const int &etaMax( ) const + { + return mLatticeetam; + } + + const int &phiMin( ) const + { + return mLatticephi0; + } + + const int &phiMax( ) const + { + return mLatticephim; + } + + + const int &ecalActivityThr( ) const + { + return mEcalactivitycut; + } + + const int &hcalActivityThr( ) const + { + return mHcalactivitycut; + } + + const int &clusterThr( ) const + { + return mClustercut; + } + + const int &seedTowerThr( ) const + { + return mTauseedtower; + } + + + + + const int &nIsoTowers( ) const + { + return mIsolationzone; + } + +/* + const int& jetCenterDev() + { + return mJetcenter; + } +*/ + + const int &minJetET( ) const + { + return mJetet; + } + + const int &fineGrainPass( ) const + { + return mFinegrainpass; + } + + + + + +/* + std::vector electronThr() + { + std::vector a; + a.push_back(mElectroncuta); + a.push_back(mElectroncutb); + a.push_back(mElectroncutc); + return a; + } +*/ + const int &electronThr( const int &aIndex ) const + { + return mElectroncut.at( aIndex ); + } + + +/* + std::vector isoThr() + { + std::vector a; + a.push_back(mIsolationthreg); + a.push_back(mIsolationthrtau); + return a; + } + + std::vector isolationE() { + std::vector a; + a.push_back(mIsolationea); + a.push_back(mIsolationeb); + return a; + } + + std::vector isolationT() { + std::vector a; + a.push_back(mIsolationta); + a.push_back(mIsolationtb); + return a; + } +*/ + + const int &isoThr( const int &aIndex ) const + { + return mIsothr.at( aIndex ); + } + + const int &isolationE( const int &aIndex ) const + { + return mIsolatione.at( aIndex ); + } + + const int &isolationT( const int &aIndex ) const + { + return mIsolationt.at( aIndex ); + } + + + + L1CaloTriggerSetup( ): + mLatticedim( 1 ), + mLatticeeta0( 1 ), + mLatticephi0( 1 ), + mLatticeetam( -1000 ), + mLatticephim( -1111 ), + mEcalactivitycut( 2 ), + mHcalactivitycut( 6 ), +/* mElectroncuta(8), + mElectroncutb(0), + mElectroncutc(0), */ + mElectroncut( std::vector < int >( 3, 0 ) ), + mTauseedtower( 0 ), + mClustercut( 4 ), + mIsolatione( std::vector < int >( 2, 0 ) ), + mIsolationt( std::vector < int >( 2, 0 ) ), + mIsothr( std::vector < int >( 2, 0 ) ) + { + mElectroncut.at( 0 ) = 8; + } + + ~L1CaloTriggerSetup( ) + { + } + + void setGeometry( const int &eta0, const int &phi0, const int &etam, const int &phim, const int &dim ) + { + mLatticedim = dim; + mLatticeeta0 = eta0; + mLatticephi0 = phi0; + mLatticeetam = etam; + mLatticephim = phim; + } + + void addWire( const int &no, const int &eta, const int &phi ) // Configure Wire Connection + { + mGeomap[no] = std::make_pair( eta, phi ); + } + + + void setThresholds( const int &ecal_a_c, const int &hcal_a_c, const int &egammaA, const int &egammaB, const int &egammaC, const int &tauSeed, const int &clusterCut, const int &isoRatioEA, + const int &isoRatioEB, const int &isoRatioTA, const int &isoRatioTB, const int &isoZone, const int &isoThresEG, const int &isoThresTau, const int &jetet, const int &fgp ) + { + + mEcalactivitycut = ecal_a_c; + mHcalactivitycut = hcal_a_c; +/* + mElectroncuta = egammaA; + mElectroncutb = egammaB; + mElectroncutc = egammaC; +*/ + mElectroncut.at( 0 ) = egammaA; + mElectroncut.at( 1 ) = egammaB; + mElectroncut.at( 2 ) = egammaC; + mTauseedtower = tauSeed; + mClustercut = clusterCut; +/* + mIsolationea = isoRatioEA; + mIsolationeb = isoRatioEB; +*/ + mIsolatione.at( 0 ) = isoRatioEA; + mIsolatione.at( 1 ) = isoRatioEB; +/* + mIsolationta = isoRatioTA; + mIsolationtb = isoRatioTB; +*/ + mIsolationt.at( 0 ) = isoRatioTA; + mIsolationt.at( 1 ) = isoRatioTB; + mIsolationzone = isoZone; +/* + mIsolationthreg = isoThresEG; + mIsolationthrtau = isoThresTau; +*/ + mIsothr.at( 0 ) = isoThresEG; + mIsothr.at( 1 ) = isoThresTau; + // mJetcenter = jetc; + mJetet = jetet; + mFinegrainpass = fgp; + } + + +}; + +#endif diff --git a/SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h b/SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h new file mode 100644 index 0000000000000..76756fcbe14bc --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h @@ -0,0 +1,11 @@ +/* SLHC Calo Trigger Record defining the SLHC CaloTrigger Config parameters M.Bachtis,S.Dasu. University of Wisconsin-Madison */ + + +#ifndef L1CaloTriggerSetupRcd_h +#define L1CaloTriggerSetupRcd_h + +#include "FWCore/Framework/interface/EventSetupRecordImplementation.h" +class L1CaloTriggerSetupRcd:public edm::eventsetup::EventSetupRecordImplementation < L1CaloTriggerSetupRcd > +{ +}; +#endif diff --git a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h new file mode 100644 index 0000000000000..36f9b4aa7d4a0 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h @@ -0,0 +1,33 @@ +#ifndef L1EGammaCrystalsCluster_h +#define L1EGammaCrystalsCluster_h + +#include + +namespace l1slhc +{ + + class L1EGCrystalCluster { + public: + float et ; + float eta ; + float phi ; + float e ; + float x ; + float y ; + float z ; + float hovere ; + + float ECALiso ; + float ECALetPUcorr; + + int ieta; + int iphi; + + }; + + + // Concrete collection of output objects (with extra tuning information) + typedef std::vector L1EGCrystalClusterCollection; +} +#endif + diff --git a/SimDataFormats/SLHC/interface/L1TBarrel.hh b/SimDataFormats/SLHC/interface/L1TBarrel.hh new file mode 100644 index 0000000000000..372772ab964cc --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TBarrel.hh @@ -0,0 +1,457 @@ +#ifndef L1TBARREL_H +#define L1TBARREL_H + +#include +#include +#include +#include +#include +using namespace std; + +#include "L1TStub.hh" +#include "L1TTracklet.hh" +#include "L1TTrack.hh" +#include "L1TTracks.hh" +#include "L1TGeomBase.hh" +#include "L1TDisk.hh" + +class L1TBarrel:public L1TGeomBase { + +private: + L1TBarrel(){ + } + + +public: + + L1TBarrel(double rmin,double rmax,double zmax, int NSector){ + rmin_=rmin; + rmax_=rmax; + zmax_=zmax; + NSector_=NSector; + stubs_.resize(NSector); + tracklets_.resize(NSector); + tracks_.resize(NSector); + } + + bool addStub(const L1TStub& aStub){ + if (aStub.r()rmax_||fabs(aStub.z())>zmax_) return false; + double phi=aStub.phi(); + if (phi<0) phi+=two_pi; + int nSector=NSector_*phi/two_pi; + assert(nSector>=0); + assert(nSector=NSector_) jSector-=NSector_; + for (unsigned int i=0;istubs_[jSector].size();j++) { + double r2=L->stubs_[jSector][j].r(); + double z2=L->stubs_[jSector][j].z(); + + double zcrude=z1-(z2-z1)*r1/(r2-r1); + if (fabs(zcrude)>30) continue; + + double phi2=L->stubs_[jSector][j].phi(); + + double deltaphi=phi1-phi2; + + if (deltaphi>0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.5*two_pi); + + + double dist=sqrt(r2*r2+r1*r1-2*r1*r2*cos(deltaphi)); + + double rinv=2*sin(deltaphi)/dist; + + if (fabs(rinv)>0.0057) continue; + + double phi0=phi1+asin(0.5*r1*rinv); + + if (phi0>0.5*two_pi) phi0-=two_pi; + if (phi0<-0.5*two_pi) phi0+=two_pi; + assert(fabs(phi0)<0.5*two_pi); + + double rhopsi1=2*asin(0.5*r1*rinv)/rinv; + + double rhopsi2=2*asin(0.5*r2*rinv)/rinv; + + double t=(z1-z2)/(rhopsi1-rhopsi2); + + double z0=z1-t*rhopsi1; + + if (stubs_[iSector][i].sigmaz()>1.0) { + if (fabs(z1-z2)<10.0){ + z0=0.0; + t=z1/rhopsi1; + } + } + + if (fabs(z0)>15.0) continue; + double pt1=stubs_[iSector][i].pt(); + double pt2=L->stubs_[jSector][j].pt(); + double pttracklet=0.3*3.8/(rinv*100); + bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; + bool pass2=fabs(1.0/pt2-1.0/pttracklet)<0.5; + bool pass=pass1&&pass2; + + if (0) { + static ofstream out("ptmatch.txt"); + out << pt1<<" " + << pt2<<" " + << pttracklet<<" " + << pass + << endl; + } + + if (!pass) continue; + + L1TTracklet tracklet(rinv,phi0,t,z0); + tracklet.addStub(stubs_[iSector][i]); + tracklet.addStub(L->stubs_[jSector][j]); + + tracklets_[iSector].push_back(tracklet); + + if (0) { + static ofstream out("barreltracklets.txt"); + out << iSector<<" "<=NSector_) jSector-=NSector_; + for (unsigned int i=0;istubs_[jSector].size();j++) { + + double r2=D->stubs_[jSector][j].r(); + double z2=D->stubs_[jSector][j].z(); + double zcrude=z1-(z2-z1)*r1/(r2-r1); + if (fabs(zcrude)>30) continue; + + + double phi2=D->stubs_[jSector][j].phi(); + + if (r2>rmax) continue; + + if (r2>80.0) continue; + + double deltaphi=phi1-phi2; + + if (deltaphi>0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.5*two_pi); + + + double dist=sqrt(r2*r2+r1*r1-2*r1*r2*cos(deltaphi)); + + double rinv=2*sin(deltaphi)/dist; + + if (fabs(rinv)>0.0057) continue; + + double phi0=phi1+asin(0.5*r1*rinv); + + if (phi0>0.5*two_pi) phi0-=two_pi; + if (phi0<-0.5*two_pi) phi0+=two_pi; + if (!(fabs(phi0)<0.5*two_pi)) { + cout << "phi0 phi1 r1 rinv : "<1.0) { + if (fabs(z1-z2)<10.0){ + z0=0.0; + t=z1/rhopsi1; + } + } + + if (fabs(z0)>15.0) continue; + + + double pt1=stubs_[iSector][i].pt(); + double pt2=D->stubs_[jSector][j].pt(); + double pttracklet=0.3*3.8/(rinv*100); + bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; + bool pass2=fabs(1.0/pt2-1.0/pttracklet)<0.5; + bool pass=pass1&&pass2; + if (!pass) continue; + + L1TTracklet tracklet(rinv,phi0,t,z0); + tracklet.addStub(stubs_[iSector][i]); + tracklet.addStub(D->stubs_[jSector][j]); + + tracklets_[iSector].push_back(tracklet); + + //cout << "rinv phi0 t z0:"<< + // rinv<<" "<=NSector_) jSector-=NSector_; + if (L->stubs_[jSector].size()==0) continue; + + + double rapprox=L->stubs_[jSector][0].r(); + + double phiprojapprox=phi0-asin(0.5*rapprox*rinv); + double zprojapprox=z0+2*t*asin(0.5*rapprox*rinv)/rinv; + if (phiprojapprox-L->stubs_[jSector][0].phi()<-0.5*two_pi) phiprojapprox+=two_pi; + if (phiprojapprox-L->stubs_[jSector][0].phi()>0.5*two_pi) phiprojapprox-=two_pi; + + for (unsigned int j=0;jstubs_[jSector].size();j++) { + double z=L->stubs_[jSector][j].z(); + if (fabs(z-zprojapprox)>10.0) continue; + double phi=L->stubs_[jSector][j].phi(); + double deltaphiapprox=fabs(phi-phiprojapprox); + assert(deltaphiapprox<12.0); + if (deltaphiapprox*rapprox>1.0) continue; + double r=L->stubs_[jSector][j].r(); + //cout << "r1 phi1 r2 phi2:" + // <stubs_[jSector][j].r()<<" " + // <stubs_[jSector][j].phi()<0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.5*two_pi); + + double rdeltaphi=r*deltaphi; + double deltaz=z-zproj; + + if (0) { + static ofstream out("barrelmatch.txt"); + out << aTracklet.r()<<" "<cutrphi*phiSF) continue; + if (fabs(deltaz)>cutrz) continue; + + /* + double pt1=L->stubs_[jSector][j].pt(); + double pttracklet=aTracklet.pt(3.8); + bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; + if (!pass1) continue; + */ + + double dist=hypot(rdeltaphi/cutrphi,deltaz/cutrz); + + if (diststubs_[jSector][j]; + distbest=dist; + } + + //cout << "rdeltaphi deltaz:"<=NSector_) jSector-=NSector_; + if (D->stubs_[jSector].size()==0) continue; + + double zapprox=D->stubs_[jSector][0].z(); + + double r_track_approx=2.0*sin(0.5*rinv*(zapprox-z0)/t)/rinv; + double phi_track_approx=phi0-0.5*rinv*(zapprox-z0)/t; + if (phi_track_approx-D->stubs_[jSector][0].phi()<-0.5*two_pi) phi_track_approx+=two_pi; + if (phi_track_approx-D->stubs_[jSector][0].phi()>0.5*two_pi) phi_track_approx-=two_pi; + + + for (unsigned int j=0;jstubs_[jSector].size();j++) { + double r=D->stubs_[jSector][j].r(); + if (fabs(r-r_track_approx)>8.0) continue; + double phi=D->stubs_[jSector][j].phi(); + + if (fabs((phi-phi_track_approx)*r_track_approx)>1.0) continue; + double z=D->stubs_[jSector][j].z(); + //skip stub if on disk + if (fabs(z-aTracklet.getStubs()[1].z())<5.0) continue; + + //cout << "r1 phi1 r2 phi2:" + // <stubs_[jSector][j].r()<<" " + // <stubs_[jSector][j].phi()<stubs_[jSector][j].iphi(); + double width=4.608; + double nstrip=508.0; + if (r<60.0) { + width=4.8; + nstrip=480; + } + double Deltai=width*(iphi-nstrip)/nstrip; //A bit of a hack... + if (z>0.0) Deltai=-Deltai; + + + double theta0=asin(Deltai/r); + + double Delta=Deltai-r_track*sin(theta0-(phi_track-phi)); + + + + //double phiturn=0.5*(z-z0)*rinv/t; + //if (fabs(phiturn)>0.25*two_pi) continue; + + //double phiproj=phi0-phiturn; + double rproj=2.0*sin(0.5*(z-z0)*rinv/t)/rinv; + + //double deltaphi=phi-phiproj; + //cout << "deltaphi phi phiproj:"<0.5*two_pi) deltaphi-=two_pi; + //if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + //if (!(fabs(deltaphi)<0.5*two_pi)) { + // cout << "deltaphi: "<0.2*phiSF) continue; + if (fabs(deltar)>3.0) continue; + + double dist=hypot(rdeltaphi/0.2,deltar/3.0); + + if (diststubs_[jSector][j]; + distbest=dist; + } + + } + } + if (distbest<1e30) { + tracklets_[iSector][i].addStub(tmp); + } + } + } + } + + + +private: + + double rmin_; + double rmax_; + double zmax_; + +}; + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TConstants.hh b/SimDataFormats/SLHC/interface/L1TConstants.hh new file mode 100644 index 0000000000000..5e3726598134b --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TConstants.hh @@ -0,0 +1,41 @@ +#ifndef L1TCONSTANTS_H +#define L1TCONSTANTS_H + +//static double DZ=0.0125; +//static double DX=0.00125; + +//static int MAXZ=32768*2; +//static int MAXX=8192; + +//static int BASE=32768*4; +//static int BASE2=BASE*64; +//static int BASE3=1024*8; +//static int BASE4=8192; +//static int BASE5=32768; +//static int BASE6=32768; +//static int BASE7=32768*4; +//static int BASE8=1024*16; + +//static int BASE9=32768*4; + +//static int BASE10=32768*16; +//static int BASE11=8192*4; +//static int BASE12=65536; +//static int BASE13=4096; + +//static int BASE14=4; +//static int BASE15=8; +//static int BASE16=16; +//static int BASE17=1024; + +//static int BASE18=4096; +//static int BASE19=1024; + +//static int BASE20=512; + +//static long long int MAXINT=65535*32768; + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TDisk.hh b/SimDataFormats/SLHC/interface/L1TDisk.hh new file mode 100644 index 0000000000000..2a1c75798ba0c --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TDisk.hh @@ -0,0 +1,348 @@ +#ifndef L1TDISK_H +#define L1TDISK_H + +#include +#include +#include +#include +#include +using namespace std; + +#include "L1TStub.hh" +#include "L1TTracklet.hh" +#include "L1TGeomBase.hh" + +class L1TDisk: public L1TGeomBase{ + +private: + L1TDisk(){ + } + + +public: + + L1TDisk(double zmin,double zmax, int NSector){ + zmin_=zmin; + zmax_=zmax; + if (zmin<0.0) { + zmin_=zmax; + zmax_=zmin; + } + NSector_=NSector; + stubs_.resize(NSector); + tracklets_.resize(NSector); + tracks_.resize(NSector); + } + + bool addStub(const L1TStub& aStub){ + //cout << "z zmin zmax:"<zmax_) return false; + double phi=aStub.phi(); + if (phi<0) phi+=two_pi; + int nSector=NSector_*phi/two_pi; + assert(nSector>=0); + assert(nSector=NSector_) jSector-=NSector_; + for (unsigned int i=0;istubs_[jSector].size();j++) { + double r2=D->stubs_[jSector][j].r(); + double z2=D->stubs_[jSector][j].z(); + double zcrude=z1-(z2-z1)*r1/(r2-r1); + if (fabs(zcrude)>30) continue; + + + double phi2=D->stubs_[jSector][j].phi(); + + if (r1>60.0||r2>60.0) continue; + + double deltaphi=phi1-phi2; + + if (deltaphi>0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.5*two_pi); + + if (fabs(r1-r2)/fabs(z1-z2)<0.1) continue; + + double dist=sqrt(r2*r2+r1*r1-2*r1*r2*cos(deltaphi)); + + double rinv=2*sin(deltaphi)/dist; + + if (fabs(rinv)>0.0057) continue; + + double tmp=0.5*r1*rinv; + + if (fabs(tmp)>=1.0) continue; + + double phi0=phi1+asin(tmp); + + if (phi0>0.5*two_pi) phi0-=two_pi; + if (phi0<-0.5*two_pi) phi0+=two_pi; + if (!(fabs(phi0)<0.5*two_pi)) { + cout << "phi0 "<15.0) continue; + + double pt1=stubs_[iSector][i].pt(); + double pt2=D->stubs_[jSector][j].pt(); + double pttracklet=0.3*3.8/(rinv*100); + bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; + bool pass2=fabs(1.0/pt2-1.0/pttracklet)<0.5; + bool pass=pass1&&pass2; + if (!pass) continue; + + //cout << "L1TDisk found tracklet"<stubs_[jSector][j]); + + //cout << "L1TDisk tracklet z() "<=NSector_) jSector-=NSector_; + if (D->stubs_[jSector].size()==0) continue; + + double zapprox=D->stubs_[jSector][0].z(); + + double r_track_approx=2.0*sin(0.5*rinv*(zapprox-z0)/t)/rinv; + double phi_track_approx=phi0-0.5*rinv*(zapprox-z0)/t; + if (phi_track_approx-D->stubs_[jSector][0].phi()<-0.5*two_pi) phi_track_approx+=two_pi; + if (phi_track_approx-D->stubs_[jSector][0].phi()>0.5*two_pi) phi_track_approx-=two_pi; + + + for (unsigned int j=0;jstubs_[jSector].size();j++) { + double r=D->stubs_[jSector][j].r(); + if (fabs(r-r_track_approx)>10.0) continue; + double z=D->stubs_[jSector][j].z(); + double phi=D->stubs_[jSector][j].phi(); + + if (fabs((phi-phi_track_approx)*r_track_approx)>1.0) continue; + + double r_track=2.0*sin(0.5*rinv*(z-z0)/t)/rinv; + double phi_track=phi0-0.5*rinv*(z-z0)/t; + + int iphi=D->stubs_[jSector][j].iphi(); + double width=4.608; + double nstrip=508.0; + if (r<60.0) { + width=4.8; + nstrip=480; + } + double Deltai=width*(iphi-nstrip)/nstrip; //A bit of a hack... + if (z>0.0) Deltai=-Deltai; + + + double theta0=asin(Deltai/r); + + double Delta=Deltai-r_track*sin(theta0-(phi_track-phi)); + + + + if (Delta!=Delta) { + cout << "Error: "<0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.5*two_pi); + + double rdeltaphi=Delta; + double deltar=r-rproj; + + if (0&&fabs(Delta)<10.0&&fabs(deltar)<15.0) { + static ofstream out("diskmatch.txt"); + out << aTracklet.r()<<" "<rphicut1*phiSF) continue; + if (fabs(deltar)>rcut1) continue; + dist=hypot(rdeltaphi/rphicut1,deltar/rcut1); + } + else { + if (fabs(rdeltaphi)>rphicut2*phiSF) continue; + if (fabs(deltar)>rcut2) continue; + dist=hypot(rdeltaphi/rphicut2,deltar/rcut2); + } + + /* + double pt1=D->stubs_[jSector][j].pt(); + double pttracklet=aTracklet.pt(3.8); + bool pass1=fabs(1.0/pt1-1.0/pttracklet)<0.5; + if (!pass1) continue; + */ + + if (diststubs_[jSector][j]; + } + + //cout << "rdeltaphi deltar:"<=NSector_) jSector-=NSector_; + if (L->stubs_[jSector].size()==0) continue; + + + double rapprox=L->stubs_[jSector][0].r(); + + double phiprojapprox=phi0-asin(0.5*rapprox*rinv); + double zprojapprox=z0+2*t*asin(0.5*rapprox*rinv)/rinv; + if (phiprojapprox-L->stubs_[jSector][0].phi()<-0.5*two_pi) phiprojapprox+=two_pi; + if (phiprojapprox-L->stubs_[jSector][0].phi()>0.5*two_pi) phiprojapprox-=two_pi; + + + for (unsigned int j=0;jstubs_[jSector].size();j++) { + double r=L->stubs_[jSector][j].r(); + double z=L->stubs_[jSector][j].z(); + if (fabs(z-zprojapprox)>15.0) continue; + double phi=L->stubs_[jSector][j].phi(); + double deltaphiapprox=fabs(phi-phiprojapprox); + assert(deltaphiapprox<12.0); + if (deltaphiapprox*rapprox>2.0) continue; + //cout << "r1 phi1 r2 phi2:" + // <stubs_[jSector][j].r()<<" " + // <stubs_[jSector][j].phi()<0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.5*two_pi); + + double rdeltaphi=r*deltaphi; + double deltaz=z-zproj; + + if (fabs(rdeltaphi)>0.1*phiSF) continue; + if (fabs(deltaz)>5.0) continue; //LS modified from 0.5 to 5.0 + + double dist=hypot(rdeltaphi/0.1,deltaz/5.0); //LS modified from 0.5 to 5.0 + + if (diststubs_[jSector][j]; + } + + } + } + if (bestdist<1e30) { + tracklets_[iSector][i].addStub(tmp); + } + } + } + } + + + +private: + + double zmin_; + double zmax_; + +}; + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TGeomBase.hh b/SimDataFormats/SLHC/interface/L1TGeomBase.hh new file mode 100644 index 0000000000000..7cfed036ba979 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TGeomBase.hh @@ -0,0 +1,76 @@ +#ifndef L1TGEOMBASE_H +#define L1TGEOMBASE_H + +#include +#include +#include +#include +#include +using namespace std; + +#include "L1TStub.hh" +#include "L1TTracklet.hh" + +class L1TGeomBase{ + + friend class L1TDisk; + friend class L1TBarrel; + +private: + L1TGeomBase(){ + } + + +public: + + void fitTracks() { + for(int iSector=0;iSector3){ + L1TTrack aTrack(tracklets_[iSector][i]); + tracks_[iSector].addTrack(aTrack); + } + } + } + } + + unsigned int nTracks(int iSector) const {return tracks_[iSector].size();} + L1TTrack& track(int iSector, unsigned int i) {return tracks_[iSector].get(i);} + + unsigned int nTracklets(int iSector) const {return tracklets_[iSector].size();} + L1TTracklet& tracklet(int iSector, unsigned int i) {return tracklets_[iSector][i];} + + L1TTracks allTracks(){ + L1TTracks tracks=tracks_[0]; + for (int i=1;i > stubs_; + + vector > tracklets_; + + vector tracks_; + + +}; + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TSector.hh b/SimDataFormats/SLHC/interface/L1TSector.hh new file mode 100755 index 0000000000000..37aaac2410aa0 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TSector.hh @@ -0,0 +1,927 @@ +#ifndef L1TSECTOR_H +#define L1TSECTOR_H + +#include +#include +using namespace std; + +#include "L1TRod.hh" +#include "L1TTracklets.hh" +#include "L1TTracks.hh" + +//This is the number of strips in rphi and in z for a module. +//This should be in the header of the ASCII file, but for now +//just hardcoded here. + + + +class L1TSector{ + +private: + + L1TSector(): + L11I_(0,1,1), + L11O_(0,2,1), + L12I_(0,1,2), + L12O_(0,2,2), + L13I_(0,1,3), + L13O_(0,2,3), + + L31I_(0,3,1), + L31O_(0,4,1), + L32I_(0,3,2), + L32O_(0,4,2), + L33I_(0,3,3), + L33O_(0,4,3), + L34I_(0,3,4), + L34O_(0,4,4), + + L5a1I_(0,5,1), + L5a1O_(0,6,1), + L5a2I_(0,5,2), + L5a2O_(0,6,2), + L5a3I_(0,5,3), + L5a3O_(0,6,3), + L5a4I_(0,5,4), + L5a4O_(0,6,4), + + L5b1I_(0,7,1), + L5b1O_(0,8,1), + L5b2I_(0,7,2), + L5b2O_(0,8,2), + L5b3I_(0,7,3), + L5b3O_(0,8,3), + L5b4I_(0,7,4), + L5b4O_(0,8,4), + + + L51I_(0,9,1), + L51O_(0,10,1), + L52I_(0,9,2), + L52O_(0,10,2), + L53I_(0,9,3), + L53O_(0,10,3), + L54I_(0,9,4), + L54O_(0,10,4), + L55I_(0,9,5), + L55O_(0,10,5), + L56I_(0,9,6), + L56O_(0,10,6), + L57I_(0,9,7), + L57O_(0,10,7) + { + n_=0; + } + +public: + + L1TSector(int n): + L11I_(n,1,1), + L11O_(n,2,1), + L12I_(n,1,2), + L12O_(n,2,2), + L13I_(n,1,3), + L13O_(n,2,3), + + L31I_(n,3,1), + L31O_(n,4,1), + L32I_(n,3,2), + L32O_(n,4,2), + L33I_(n,3,3), + L33O_(n,4,3), + L34I_(n,3,4), + L34O_(n,4,4), + + L5a1I_(n,5,1), + L5a1O_(n,6,1), + L5a2I_(n,5,2), + L5a2O_(n,6,2), + L5a3I_(n,5,3), + L5a3O_(n,6,3), + L5a4I_(n,5,4), + L5a4O_(n,6,4), + + L5b1I_(n,7,1), + L5b1O_(n,8,1), + L5b2I_(n,7,2), + L5b2O_(n,8,2), + L5b3I_(n,7,3), + L5b3O_(n,8,3), + L5b4I_(n,7,4), + L5b4O_(n,8,4), + + + L51I_(n,9,1), + L51O_(n,10,1), + L52I_(n,9,2), + L52O_(n,10,2), + L53I_(n,9,3), + L53O_(n,10,3), + L54I_(n,9,4), + L54O_(n,10,4), + L55I_(n,9,5), + L55O_(n,10,5), + L56I_(n,9,6), + L56O_(n,10,6), + L57I_(n,9,7), + L57O_(n,10,7) + { + n_=n; + } + + + + //uggly helper function + void append(L1TTracklets& a,L1TTracklets b){ + for (unsigned int i=0;i1) { + L1TTrack aTrack(aTracklet); + L1Tracks_.addTrack(aTrack); + } + } + for (unsigned int i=0; i1) { + L1TTrack aTrack(aTracklet); + L1Tracks_.addTrack(aTrack); + } + } + for (unsigned int i=0; i1) { + L1TTrack aTrack(aTracklet); + L1Tracks_.addTrack(aTrack); + } + } + + } + + L1TTracks getTracks() { + return L1Tracks_; + } + + void print() { + + cout << "Sector:"<999 && z_>0.0) ptsgn=-ptsgn; //sign fix for forward endcap + return ptsgn; + } + + double diphi() { + if (!innerdigis_.size()>0) { + cout << "innerdigis_.size()="<0) { + cout << "outerdigis_.size()="<0) { + cout << "innerdigis_.size()="< > innerdigis() const { return innerdigis_; } + vector > outerdigis() const { return outerdigis_; } + vector > innerdigisladdermodule() const { return innerdigisladdermodule_; } + vector > outerdigisladdermodule() const { return outerdigisladdermodule_; } + double x() const { return x_; } + double y() const { return y_; } + double z() const { return z_; } + double r() const { return sqrt(x_*x_+y_*y_); } + double pt() const { return pt_; } + + double phi() const { return atan2(y_,x_); } + + unsigned int iphi() const { return iphi_; } + unsigned int iz() const { return iz_; } + + void setiphi(int iphi) {iphi_=iphi;} + void setiz(int iz) {iz_=iz;} + + double sigmax() const {return sigmax_;} + double sigmaz() const {return sigmaz_;} + + bool operator== (const L1TStub& other) const { + if (other.iphi()==iphi_ && + other.iz()==iz_ && + other.layer()==layer_ && + other.ladder()==ladder_ && + other.module()==module_) + return true; + + else + return false; + } + + void lorentzcor(double shift){ + double r=this->r(); + double phi=this->phi()-shift/r; + this->x_=r*cos(phi); + this->y_=r*sin(phi); + } + + int simtrackid() const { return simtrackid_;} + + +private: + + int simtrackid_; + unsigned int iphi_; + unsigned int iz_; + unsigned int layer_; + unsigned int ladder_; + unsigned int module_; + double x_; + double y_; + double z_; + double sigmax_; + double sigmaz_; + double pt_; + + vector > innerdigis_; + vector > innerdigisladdermodule_; + vector > outerdigis_; + vector > outerdigisladdermodule_; + + +}; + + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TTrack.hh b/SimDataFormats/SLHC/interface/L1TTrack.hh new file mode 100644 index 0000000000000..f6e84b2252e86 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TTrack.hh @@ -0,0 +1,664 @@ +#ifndef L1TTRACK_H +#define L1TTRACK_H + +#include +#include + + +using namespace std; + +class L1TTrack{ + +public: + + L1TTrack() { }; + + L1TTrack(const L1TTracklet& seed) { + + seed_=seed; + rinv_=seed.rinv(); + phi0_=seed.phi0(); + z0_=seed.z0(); + t_=seed.t(); + stubs_=seed.getStubs(); + + double largestresid; + int ilargestresid; + + for (int i=0;i<1;i++){ + + if (i>0) { + rinv_=rinvfit_; + phi0_=phi0fit_; + z0_=z0fit_; + t_=tfit_; + } + + calculateDerivatives(); + + linearTrackFit(); + + + } + + largestresid=-1.0; + ilargestresid=-1; + + residuals(largestresid,ilargestresid); + + //cout << "Chisq largestresid: "<3&&chisq()>100.0&&largestresid>5.0) { + //cout << "Refitting track"<0.0) Deltai=-Deltai; + double theta0=asin(Deltai/ri); + + double rmultiplier=-sin(theta0-(phi_track-phii)); + double phimultiplier=r_track*cos(theta0-(phi_track-phii)); + + + double drdrinv=-2.0*sin(0.5*rinv_*(zi-z0_)/t_)/(rinv_*rinv_) + +(zi-z0_)*cos(0.5*rinv_*(zi-z0_)/t_)/(rinv_*t_); + double drdphi0=0; + double drdt=-(zi-z0_)*cos(0.5*rinv_*(zi-z0_)/t_)/(t_*t_); + double drdz0=-cos(0.5*rinv_*(zi-z0_)/t_)/t_; + + double dphidrinv=-0.5*(zi-z0_)/t_; + double dphidphi0=1.0; + double dphidt=0.5*rinv_*(zi-z0_)/(t_*t_); + double dphidz0=0.5*rinv_/t_; + + D_[0][j]=drdrinv/sigmaz; + D_[1][j]=drdphi0/sigmaz; + D_[2][j]=drdt/sigmaz; + D_[3][j]=drdz0/sigmaz; + j++; + //second the rphi position + D_[0][j]=(phimultiplier*dphidrinv+rmultiplier*drdrinv)/sigmax; + D_[1][j]=(phimultiplier*dphidphi0+rmultiplier*drdphi0)/sigmax; + D_[2][j]=(phimultiplier*dphidt+rmultiplier*drdt)/sigmax; + D_[3][j]=(phimultiplier*dphidz0+rmultiplier*drdz0)/sigmax; + //old calculation + //D_[0][j]=-0.5*(zi-z0_)/(t_*(sigmax/ri)); + //D_[1][j]=1.0/(sigmax/ri); + //D_[2][j]=-0.5*rinv_*(zi-z0_)/(t_*t_*(sigmax/ri)); + //D_[3][j]=0.5*rinv_/((sigmax/ri)*t_); + j++; + } + + //cout << "Exact rinv derivative: "<0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.1*two_pi); + + delta[j++]=ri*deltaphi/sigmax; + delta[j++]=(z0fit_+(2.0/rinvfit_)*tfit_*asin(0.5*ri*rinvfit_)-zi)/sigmaz; + + } + else { + //we are dealing with a disk hit + + double r_track=2.0*sin(0.5*rinvfit_*(zi-z0fit_)/tfit_)/rinvfit_; + double phi_track=phi0fit_-0.5*rinvfit_*(zi-z0fit_)/tfit_; + + int iphi=stubs_[i].iphi(); + + double width=4.608; + double nstrip=508.0; + if (ri<60.0) { + width=4.8; + nstrip=480; + } + double Deltai=width*(iphi-nstrip)/nstrip; //A bit of a hack... + + if (stubs_[i].z()>0.0) Deltai=-Deltai; + + double theta0=asin(Deltai/ri); + + double Delta=Deltai-r_track*sin(theta0-(phi_track-phii)); + + delta[j++]=(r_track-ri)/sigmaz; + delta[j++]=Delta/sigmax; + } + + if (fabs(delta[j-2])>largestresid) { + largestresid=fabs(delta[j-2]); + ilargestresid=i; + } + + if (fabs(delta[j-1])>largestresid) { + largestresid=fabs(delta[j-1]); + ilargestresid=i; + } + + if (print) cout << delta[j-2]<<" "<0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.1*two_pi); + + delta[j++]=ri*deltaphi/sigmax; + delta[j++]=(z0_+(2.0/rinv_)*t_*asin(0.5*ri*rinv_)-zi)/sigmaz; + + + //numerical derivative check + + for (int iii=0;iii<0;iii++){ + + double drinv=0.0; + double dphi0=0.0; + double dt=0.0; + double dz0=0.0; + + if (iii==0) drinv=0.001*fabs(rinv_); + if (iii==1) dphi0=0.001; + if (iii==2) dt=0.001; + if (iii==3) dz0=0.01; + + double deltaphi=phi0_+dphi0-asin(0.5*ri*(rinv_+drinv))-phii; + if (deltaphi>0.5*two_pi) deltaphi-=two_pi; + if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + assert(fabs(deltaphi)<0.1*two_pi); + + double delphi=ri*deltaphi/sigmax; + double deltaz=(z0_+dz0+(2.0/(rinv_+drinv))*(t_+dt)*asin(0.5*ri*(rinv_+drinv))-zi)/sigmaz; + + + if (iii==0) cout << "Numerical rinv derivative: "<0.0) Deltai=-Deltai; + + double theta0=asin(Deltai/ri); + + double Delta=Deltai-r_track*sin(theta0-(phi_track-phii)); + + delta[j++]=(r_track-ri)/sigmaz; + //double deltaphi=phi_track-phii; + //if (deltaphi>0.5*two_pi) deltaphi-=two_pi; + //if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + //assert(fabs(deltaphi)<0.1*two_pi); + //delta[j++]=deltaphi/(sigmax/ri); + delta[j++]=Delta/sigmax; + + //numerical derivative check + + for (int iii=0;iii<0;iii++){ + + double drinv=0.0; + double dphi0=0.0; + double dt=0.0; + double dz0=0.0; + + if (iii==0) drinv=0.001*fabs(rinv_); + if (iii==1) dphi0=0.001; + if (iii==2) dt=0.001; + if (iii==3) dz0=0.01; + + r_track=2.0*sin(0.5*(rinv_+drinv)*(zi-(z0_+dz0))/(t_+dt))/(rinv_+drinv); + //cout <<"t_track 2: "<0.0) Deltai=-Deltai; + theta0=asin(Deltai/ri); + + Delta=Deltai-r_track*sin(theta0-(phi_track-phii)); + + if (iii==0) cout << "Numerical rinv derivative: "<=2); + + } + + + int simtrackid(double& fraction) const { + + //cout << "In L1TTrack::simtrackid"< simtrackids; + + for(unsigned int i=0;isecond<second>nsimtrack) { + nsimtrack=it->second; + simtrackid=it->first; + } + it++; + } + + //cout << "L1TTrack::simtrackid done"< getStubs() const { return stubs_; } + unsigned int nstub() const { return stubs_.size(); } + double rinv() const { return rinv_; } + double getPhi0() const { return phi0_; } + double getZ0() const { return z0_; } + double getT() const { return t_; } + bool isCombinatorics() const { return isCombinatorics_; } + double getSimTrackID() const { return SimTrackID_; } + + double pt(double bfield) const { return 0.00299792*bfield/rinvfit_; } + //double ipt(double bfield) const { return 0.00299792*bfield/irinvfit(); } + double ptseed(double bfield) const { return 0.00299792*bfield/rinv_; } + + double phi0() const { return phi0fit_;} + //double iphi0() const { return iphi0fit();} + double phi0seed() const { return phi0_;} + + double eta() const { static double two_pi=8*atan(1.0); + return -log(tan(0.5*(0.25*two_pi-atan(tfit_)))); } + //double ieta() const { static double two_pi=8*atan(1.0); + // return -log(tan(0.5*(0.25*two_pi-atan(itfit())))); } + double etaseed() const { static double two_pi=8*atan(1.0); + return -log(tan(0.5*(0.25*two_pi-atan(t_)))); } + + double z0() const { return z0fit_; } + //double iz0() const { return iz0fit(); } + double z0seed() const { return z0_; } + + double chisq1() const {return chisq1_;} + double chisq2() const {return chisq2_;} + + double chisq1dof() const {return chisq1_/(stubs_.size()-2);} + double chisq2dof() const {return chisq2_/(stubs_.size()-2);} + + double chisq() const {return chisq1_+chisq2_; } + double chisqdof() const {return (chisq1_+chisq2_)/(2*stubs_.size()-4); } + + +private: + + L1TTracklet seed_; + vector stubs_; + double rinv_; + double phi0_; + double z0_; + double t_; + bool isCombinatorics_; + int SimTrackID_; + double rinvfit_; + double phi0fit_; + double z0fit_; + double tfit_; + + int irinvfit_; + int iphi0fit_; + int iz0fit_; + int itfit_; + + double chisq1_; + double chisq2_; + + int ichisq1_; + int ichisq2_; + + double D_[4][40]; + + double M_[4][8]; + + double MinvDt_[4][40]; + + +}; + + +#endif diff --git a/SimDataFormats/SLHC/interface/L1TTracklet.hh b/SimDataFormats/SLHC/interface/L1TTracklet.hh new file mode 100755 index 0000000000000..1fd74853bab6b --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TTracklet.hh @@ -0,0 +1,96 @@ +#ifndef L1TTRACKLET_H +#define L1TTRACKLET_H + +#include +#include +#include +#include + +using namespace std; + + + +class L1TTracklet{ + +public: + + L1TTracklet(double rinv, double phi0, double t, double z0){ + + rinv_=rinv; + phi0_=phi0; + t_=t; + z0_=z0; + + } + + L1TTracklet(){ + } + + void addStub(const L1TStub& j){ + stubs_.push_back(j); + } + + vector getStubs() const { + return stubs_; + } + + int simtrackid(double& fraction) const { + + + map simtrackids; + + for(unsigned int i=0;isecond<second>nsimtrack) { + nsimtrack=it->second; + simtrackid=it->first; + } + it++; + } + + fraction=(1.0*nsimtrack)/stubs_.size(); + + return simtrackid; + + } + + double pt(double bfield) const { return 0.00299792*bfield/rinv_; } + + int nStubs() const {return stubs_.size();} + + double rinv() const {return rinv_;} + double phi0() const {return phi0_;} + double t() const {return t_;} + double z0() const {return z0_;} + + double r() const {return stubs_[0].r();} + double z() const {return stubs_[0].z();} + + +private: + + double rinv_; + double phi0_; + double t_; + double z0_; + + vector stubs_; + +}; + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TTracklets.hh b/SimDataFormats/SLHC/interface/L1TTracklets.hh new file mode 100755 index 0000000000000..18d4ca61c23ab --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TTracklets.hh @@ -0,0 +1,58 @@ +#ifndef L1TTRACKLETS_H +#define L1TTRACKLETS_H + +#include +#include + +#include "L1TTracklet.hh" + + +using namespace std; + +//This is the number of strips in rphi and in z for a module. +//This should be in the header of the ASCII file, but for now +//just hardcoded here. + + + +class L1TTracklets{ + +public: + + L1TTracklets(){ + + } + + void addTracklet(const L1TTracklet& aTracklet){ + tracklets_.push_back(aTracklet); + } + + void print() { + + for (unsigned int i=0;i tracklets_; + +}; + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TTracks.hh b/SimDataFormats/SLHC/interface/L1TTracks.hh new file mode 100644 index 0000000000000..eaf085b8e2c70 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TTracks.hh @@ -0,0 +1,139 @@ +#ifndef L1TTRACKS_H +#define L1TTRACKS_H + +#include +#include + +#include "L1TTrack.hh" + + +using namespace std; + + +class L1TTracks{ + +public: + + L1TTracks(){ + + } + + void addTrack(const L1TTrack& aTrack){ + tracks_.push_back(aTrack); + } + + void addTracks(const L1TTracks& tracks){ + for(unsigned int i=0;i NduplicatesPerTrack() { + + vector NdupPerTrack; + vector Ndups((int)tracks_.size()); + + for (unsigned int i=0; i deleted(tracks_.size()); + for(unsigned int i=0;ifabs(tracks_[j].rinv())) { + //if (fractioni=2)){ + deleted[i]=true; + continue; + } + if ((tracks_[j].npixelstrip()<2)&&(tracks_[i].npixelstrip()>=2)){ + deleted[j]=true; + continue; + } + if ((tracks_[i].npixelstrip()<3)&&(tracks_[j].npixelstrip()>=3)){ + deleted[i]=true; + continue; + } + if ((tracks_[j].npixelstrip()<3)&&(tracks_[i].npixelstrip()>=3)){ + deleted[j]=true; + continue; + } + if ((tracks_[i].npixelstrip()<4)&&(tracks_[j].npixelstrip()>=4)){ + deleted[i]=true; + continue; + } + if ((tracks_[j].npixelstrip()<4)&&(tracks_[i].npixelstrip()>=4)){ + deleted[j]=true; + continue; + } + + + + if (tracks_[i].chisqdof()>tracks_[j].chisqdof()) { + deleted[i]=true; + } else { + deleted[j]=true; + } + continue; + } + } + if (deleted[i]) continue; + } + + L1TTracks tmp; + + for(unsigned int i=0;i tracks_; + +}; + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TWord.hh b/SimDataFormats/SLHC/interface/L1TWord.hh new file mode 100755 index 0000000000000..56738e068a772 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TWord.hh @@ -0,0 +1,228 @@ +#ifndef L1TWORD_H +#define L1TWORD_H + +#include +#include +using namespace std; + +//This is the number of strips in rphi and in z for a module. +//This should be in the header of the ASCII file, but for now +//just hardcoded here. + + + +class L1TWord{ + +public: + + explicit L1TWord(bool printstat=false){ + + //cout << "In constructor 1"<maxsize_){ + cout <<"operator= "<maxsize_){ + cout << "Adding "<tmp.maxsize_) { + cout << "operator*:"<tmp.maxsize_) { + cout << "operator*(int):"<<"("<maxvalue_) { + maxvalue_=value; + } + } + + + long long int value_; + long long int maxsize_; + + std::string name_; + + bool printstat_; + long long int maxvalue_; + +}; + + + +#endif + + + diff --git a/SimDataFormats/SLHC/interface/L1TkBeam.h b/SimDataFormats/SLHC/interface/L1TkBeam.h new file mode 100644 index 0000000000000..fa5893cd8d3a1 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TkBeam.h @@ -0,0 +1,132 @@ +/// //////////////////////////////////////// +/// Stacked Tracker Simulations /// +/// Written by: /// +/// Nicola Pozzobon /// +/// UNIPD /// +/// 2011, Nov /// +/// /// +/// //////////////////////////////////////// + +#ifndef STACKED_TRACKER_L1TK_BEAM_FORMAT_H +#define STACKED_TRACKER_L1TK_BEAM_FORMAT_H + +#include "DataFormats/Common/interface/Ref.h" +#include "DataFormats/Common/interface/Ptr.h" + +#include "DataFormats/GeometryVector/interface/GlobalPoint.h" + +namespace cmsUpgrades{ + + /** ************************ **/ + /** **/ + /** DECLARATION OF CLASS **/ + /** **/ + /** ************************ **/ + + class L1TkBeam { + + public: + + private: + /// Data members + unsigned int theBeamType; /// 0 = Beta, 1 = Gauss, 2 = Flat + GlobalPoint theBeamPosition; + double theSizeX; + double theSizeY; + double theSizeZ; + + public: + /// Constructors + L1TkBeam() + { + /// Set default data members + theBeamType = 99; + theBeamPosition = GlobalPoint(0.0, 0.0, 0.0); + theSizeX = 0.0; + theSizeY = 0.0; + theSizeZ = 0.0; + } + + /// Destructor + ~L1TkBeam() + { + /// Nothing to be done + } + + /// //////////////////////// /// + /// METHODS FOR DATA MEMBERS /// + /// Beam position + GlobalPoint getBeamPosition() const + { + return theBeamPosition; + } + + void setBeamPosition( double aPosX, double aPosY, double aPosZ ) + { + theBeamPosition = GlobalPoint( aPosX, aPosY, aPosZ ); + } + + /// Beam size + double getSizeX() const + { + return theSizeX; + } + + double getSizeY() const + { + return theSizeY; + } + + double getSizeZ() const + { + return theSizeZ; + } + + void setBeamSize( double aSizeX, double aSizeY, double aSizeZ ) + { + theSizeX = aSizeX; + theSizeY = aSizeY; + theSizeZ = aSizeZ; + } + + + + /// Beam type + unsigned int getBeamType() const + { + return theBeamType; + } + + void setBeamType( unsigned int aBeamType ) + { + theBeamType = aBeamType; + } + + /// ////////////// /// + /// HELPER METHODS /// + + /// /////////////////// /// + /// INFORMATIVE METHODS /// + + }; /// Close class + + + /** ***************************** **/ + /** **/ + /** IMPLEMENTATION OF METHODS **/ + /** **/ + /** ***************************** **/ + + /// THIS IS NOT A TEMPLATE CLASS, + /// so the definition is typed within the first instance + /// found by the compiler, otherwise, to implement it + /// outside of the class implementation, you need the inline + /// keyword to be used + +} /// Close namespace + +#endif + + + + diff --git a/SimDataFormats/SLHC/interface/L1TkCluster.h b/SimDataFormats/SLHC/interface/L1TkCluster.h new file mode 100644 index 0000000000000..e331bf3f52eb5 --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TkCluster.h @@ -0,0 +1,389 @@ +/// //////////////////////////////////////// +/// Stacked Tracker Simulations /// +/// /// +/// Nicola Pozzobon, UNIPD /// +/// Emmanuele Salvati, Cornell /// +/// /// +/// 2011, June /// +/// 2011, October /// +/// 2012, August /// +/// 2013, January /// +/// //////////////////////////////////////// + +#ifndef STACKED_TRACKER_L1TK_CLUSTER_FORMAT_H +#define STACKED_TRACKER_L1TK_CLUSTER_FORMAT_H + +#include "DataFormats/DetId/interface/DetId.h" +#include "DataFormats/Common/interface/Ref.h" +#include "DataFormats/Common/interface/Ptr.h" +#include "DataFormats/Common/interface/DetSet.h" +#include "DataFormats/Common/interface/DetSetVector.h" +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "DataFormats/GeometryVector/interface/GlobalPoint.h" +#include "DataFormats/GeometryCommonDetAlgo/interface/MeasurementPoint.h" + +#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "SimDataFormats/Track/interface/SimTrack.h" +#include "SimDataFormats/Track/interface/SimTrackContainer.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" + + + /** ************************ **/ + /** **/ + /** DECLARATION OF CLASS **/ + /** **/ + /** ************************ **/ + + template< typename T > + class L1TkCluster + { + public: + /// Constructors + L1TkCluster(); + L1TkCluster( std::vector< T > aHits, DetId aDetId, unsigned int aStackMember ); + + /// Destructor + ~L1TkCluster(); + + /// Data members: getABC( ... ) + /// Helper methods: findABC( ... ) + + /// Hits in the Cluster + std::vector< T > getHits() const; + void setHits( std::vector< T > aHits ); + + /// Detector element + DetId getDetId() const; + void setDetId( DetId aDetId ); + unsigned int getStackMember() const; + void setStackMember( unsigned int aStackMember ); + + /// MC Truth + std::vector< edm::Ptr< SimTrack > > getSimTrackPtrs() const; + std::vector< uint32_t > getEventIds() const; + void addSimTrack( const edm::Ptr< SimTrack > &trk) { theSimTracks.push_back(trk);} + void addEventId( const uint32_t anId ) { theEventIds.push_back(anId); } + bool isGenuine() const; + bool isCombinatoric() const; + bool isUnknown() const; + int findType() const; + unsigned int findSimTrackId() const; + + /// Cluster width + unsigned int findWidth() const; + + /// Single hit coordinates and position + MeasurementPoint findHitLocalCoordinates( unsigned int hitIdx ) const; + + /// Average cluster coordinates and position + MeasurementPoint findAverageLocalCoordinates() const; + + /// Information + std::string print( unsigned int i=0 ) const; + + private: + /// Data members + std::vector< T > theHits; + DetId theDetId; + unsigned int theStackMember; + std::vector< edm::Ptr< SimTrack > > theSimTracks; + std::vector< uint32_t > theEventIds; + + }; /// Close class + + /** ***************************** **/ + /** **/ + /** IMPLEMENTATION OF METHODS **/ + /** **/ + /** ***************************** **/ + + /// Default Constructor + /// NOTE: to be used with setSomething(...) methods + template< typename T > + L1TkCluster< T >::L1TkCluster() + { + /// Set default data members + theHits.clear(); + theDetId = 0; + theStackMember = 0; + theSimTracks.clear(); + } + + /// Another Constructor + template< typename T > + L1TkCluster< T >::L1TkCluster( std::vector< T > aHits, DetId aDetId, unsigned int aStackMember ) + { + /// Set default data members + theHits.clear(); + for ( unsigned int j = 0; j < aHits.size(); j++ ) + theHits.push_back( aHits.at(j) ); + theDetId = aDetId; + theStackMember = aStackMember; + theSimTracks.clear(); + } + + /// Destructor + template< typename T > + L1TkCluster< T >::~L1TkCluster(){} + + /// Hits composing the cluster + template< typename T > + std::vector< T > L1TkCluster< T >::getHits() const { return theHits; } + + template< typename T > + void L1TkCluster< T >::setHits( std::vector< T > aHits ) + { + for ( unsigned int j=0; j + DetId L1TkCluster< T >::getDetId() const { return theDetId; } + + template< typename T > + void L1TkCluster< T >::setDetId( DetId aDetId ) { theDetId = aDetId; } + + template< typename T > + unsigned int L1TkCluster< T >::getStackMember() const { return theStackMember; } + + template< typename T > + void L1TkCluster< T >::setStackMember( unsigned int aStackMember ) { theStackMember = aStackMember; } + + /// MC truth information + template< typename T > + std::vector< edm::Ptr< SimTrack > > L1TkCluster< T >::getSimTrackPtrs() const { return theSimTracks; } + + template< typename T > + std::vector< uint32_t > L1TkCluster< T >::getEventIds() const { return theEventIds; } + + template< typename T > + bool L1TkCluster< T >::isGenuine() const + { + /// Check how many event ID's + std::vector< uint32_t > tempVecEvId = theEventIds; + tempVecEvId.erase( std::unique( tempVecEvId.begin(), tempVecEvId.end() ), tempVecEvId.end() ); + if ( tempVecEvId.size() > 1 ) + return false; + + /// If all SimTracks are from the same event/BX ... + /// GENUINE means that ALL hits could be associated to a + /// SimTrack stored in the corresponding collection, AND + /// all of these SimTracks are actually the same + int prevTrack = -99999; // SimTrackId storage + if ( theSimTracks.size() == 0 ) return false; + for ( unsigned int k = 0; k < theSimTracks.size(); k++ ) + { + edm::Ptr< SimTrack > curSimTrackPtr = theSimTracks.at(k); + if ( curSimTrackPtr.isNull() ) + /// Unknown SimTrack means false + return false; + else + { + if ( theSimTracks.size() > 1 ) + { + if ( prevTrack < 0 ) + { + prevTrack = curSimTrackPtr->trackId(); + } + + if ( prevTrack != (int)curSimTrackPtr->trackId() ) + /// Two different known SimTracks means false + return false; + + prevTrack = curSimTrackPtr->trackId(); + } + } + } + /// If not false, then it is true + return true; + } + + template< typename T > + bool L1TkCluster< T >::isCombinatoric() const + { + /// Check how many event ID's + std::vector< uint32_t > tempVecEvId = theEventIds; + tempVecEvId.erase( std::unique( tempVecEvId.begin(), tempVecEvId.end() ), tempVecEvId.end() ); + if ( tempVecEvId.size() > 1 ) + return true; + + /// If all SimTracks are from the same event/BX ... + /// COMBINATORIC means that different SimTracks contribute + /// to the cluster, which means that both a mixture of NULL + /// pointers and good ones are present, or that all are + /// good but there are more SimTracks associated to the cluster + int prevTrack = -99999; // SimTrackId storage + unsigned int numberNulls = 0; // Number of non-found SimTracks + unsigned int numberGoods = 0; // Number of found SimTracks + for ( unsigned int k = 0; k < theSimTracks.size(); k++ ) + { + edm::Ptr< SimTrack > curSimTrackPtr = theSimTracks.at(k); + if ( curSimTrackPtr.isNull() ) + numberNulls++; + else + numberGoods++; + + if ( numberNulls > 0 && numberGoods > 0 ) + /// Mixture of known and unknown SimTracks means true + return true; + + if ( curSimTrackPtr.isNull() == false ) + { + if ( theSimTracks.size() > 1 ) + { + if ( prevTrack < 0 ) + prevTrack = curSimTrackPtr->trackId(); + + if ( prevTrack != (int)curSimTrackPtr->trackId() ) + /// Two different known SimTracks means true + return true; + + prevTrack = curSimTrackPtr->trackId(); + } + } + } + + if ( numberNulls > 0 && numberGoods == 0 ) + /// Only unknown SimTracks means unknown, hence false + return false; + + /// If not true, then it is false + /// This includes if ( theSimTracks.size() == 0 ) + return false; + } + + template< typename T > + bool L1TkCluster< T >::isUnknown() const + { + /// Check how many event ID's + std::vector< uint32_t > tempVecEvId = theEventIds; + tempVecEvId.erase( std::unique( tempVecEvId.begin(), tempVecEvId.end() ), tempVecEvId.end() ); + if ( tempVecEvId.size() > 1 ) + return false; + + /// If all SimTracks are from the same event/BX ... + /// UNKNOWN means that all SimTracks pointers are NULL + for ( unsigned int k = 0; k < theSimTracks.size(); k++ ) + { + edm::Ptr< SimTrack > curSimTrackPtr = theSimTracks.at(k); + if ( curSimTrackPtr.isNull() == false ) + /// A known SimTrack means false + return false; + } + + /// If not false, then it is true + /// This includes if ( theSimTracks.size() == 0 ) + return true; + } + + template< typename T > + int L1TkCluster< T >::findType() const + { + if ( this->isGenuine() && theSimTracks.size()>0 ) + return theSimTracks.at(0)->type(); + return 999999999; + } + + template< typename T > + unsigned int L1TkCluster< T >::findSimTrackId() const + { + if ( this->isGenuine() && theSimTracks.size()>0 ) + return theSimTracks.at(0)->trackId(); + return 0; + } + + /// Cluster width + /// Specialize the template for PSimHits in *cc + template<> + unsigned int L1TkCluster< edm::Ref >::findWidth() const; + + /// Cluster width + /// Default template for PixelDigis + template< typename T > + unsigned int L1TkCluster< T >::findWidth() const + { + int rowMin = 99999999; + int rowMax = 0; + /// For broadside Clusters this is equivalent to theHits.size() + /// but for 2d or neighbor Clusters this is only the actual size in RPhi + for ( unsigned int i=0; irow() < rowMin ) + rowMin = theHits.at(i)->row(); + if ( theHits.at(i)->row() > rowMax ) + rowMax = theHits.at(i)->row(); + } + return abs( rowMax - rowMin + 1 ); /// This takes care of 1-Pixel clusters + } + + /// Get hit local coordinates + /// Specialize the template for PSimHits in *cc + template<> + MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findHitLocalCoordinates( unsigned int hitIdx ) const; + + /// Get hit local coordinates + /// Default template for PixelDigis + template< typename T > + MeasurementPoint L1TkCluster< T >::findHitLocalCoordinates( unsigned int hitIdx ) const + { + /// NOTE in this case, DO NOT add 0.5 + /// to get the center of the pixel + MeasurementPoint mp( theHits.at(hitIdx)->row(), theHits.at(hitIdx)->column() ); + return mp; + } + + + /// Unweighted average local cluster coordinates + /// Specialize the template for PSimHits in *cc + template<> + MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findAverageLocalCoordinates() const; + + /// Unweighted average local cluster coordinates + /// Default template for PixelDigis + template< typename T > + MeasurementPoint L1TkCluster< T >::findAverageLocalCoordinates() const + { + double averageCol = 0.0; + double averageRow = 0.0; + + /// Loop over the hits and calculate the average coordinates + if ( theHits.size() != 0 ) + { + typename std::vector< T >::const_iterator hitIter; + for ( hitIter = theHits.begin(); + hitIter != theHits.end(); + hitIter++ ) + { + averageCol += (*hitIter)->column(); + averageRow += (*hitIter)->row(); + } + averageCol /= theHits.size(); + averageRow /= theHits.size(); + } + return MeasurementPoint( averageRow, averageCol ); + } + + + /// Information + template< typename T > + std::string L1TkCluster< T >::print( unsigned int i ) const + { + std::string padding(""); + for ( unsigned int j=0; j!=i; ++j ) + padding+="\t"; + std::stringstream output; + output< + std::ostream& operator << (std::ostream& os, const L1TkCluster< T >& aL1TkCluster) { return ( os< + class L1TkStub + { + public: + /// Constructors + L1TkStub(); + L1TkStub( DetId aDetId ); + + /// Destructor + ~L1TkStub(); + + /// Data members: getABC( ... ) + /// Helper methods: findABC( ... ) + + /// Clusters composing the Stub + std::vector< edm::Ptr< L1TkCluster< T > > > getClusterPtrs() const { return theClusters; } + const edm::Ptr< L1TkCluster< T > >& getClusterPtr( unsigned int hitIdentifier ) const; + void addClusterPtr( edm::Ptr< L1TkCluster< T > > aL1TkCluster ); + + /// NOTE they are added and stored as edm::Ptr< Cluster > but + /// returned as just Cluster for backward compatibility with + /// HitMatching Algorithms + + /// Detector element + DetId getDetId() const { return theDetId; } + void setDetId( DetId aDetId ); + + /// Trigger information + double getTriggerDisplacement() const; /// In FULL-STRIP units! (hence, not implemented herein) + void setTriggerDisplacement( int aDisplacement ); /// In HALF-STRIP units! + double getTriggerOffset() const; /// In FULL-STRIP units! (hence, not implemented herein) + void setTriggerOffset( int anOffset ); /// In HALF-STRIP units! + + /// MC truth + edm::Ptr< SimTrack > getSimTrackPtr() const { return theSimTrack; } + uint32_t getEventId() const { return theEventId; } + bool isGenuine() const; + bool isCombinatoric() const; + bool isUnknown() const; + int findType() const; + unsigned int findSimTrackId() const; + + /// Collect MC truth + void checkSimTrack(); + + /// Information + std::string print( unsigned int i=0 ) const; + + private: + /// Data members + DetId theDetId; + std::vector< edm::Ptr< L1TkCluster< T > > > theClusters; + edm::Ptr< SimTrack > theSimTrack; + uint32_t theEventId; + int theDisplacement; + int theOffset; + + }; /// Close class + + /** ***************************** **/ + /** **/ + /** IMPLEMENTATION OF METHODS **/ + /** **/ + /** ***************************** **/ + + /// Default Constructor + template< typename T > + L1TkStub< T >::L1TkStub() + { + /// Set default data members + theDetId = 0; + theClusters.clear(); + theDisplacement = 999999; + theOffset = 0; + /// theSimTrack is NULL by default + theEventId = 0xFFFF; + } + + /// Another Constructor + template< typename T > + L1TkStub< T >::L1TkStub( DetId aDetId ) + { + /// Set default data members + theDetId = aDetId; + theClusters.clear(); + theDisplacement = 999999; + theOffset = 0; + /// theSimTrack is NULL by default + theEventId = 0xFFFF; + } + + /// Destructor + template< typename T > + L1TkStub< T >::~L1TkStub(){} + + /// Get the Pointer to a Cluster + template< typename T > + const edm::Ptr< L1TkCluster< T > >& L1TkStub< T >::getClusterPtr( unsigned int hitIdentifier ) const + { + typename std::vector< edm::Ptr< L1TkCluster< T > > >::const_iterator clusIter; + for ( clusIter = theClusters.begin(); + clusIter != theClusters.end(); + ++clusIter ) + { + if ( (*clusIter)->getStackMember() == hitIdentifier ) + return *clusIter; + } + + //hopefully code doesnt reach this point- not sure who would delete this + edm::Ptr< L1TkCluster< T > >* tmpCluPtr = new edm::Ptr< L1TkCluster< T > >(); + return *tmpCluPtr; + + } + + /// Add the Clusters to the candidate Stub + template< typename T > + void L1TkStub< T >::addClusterPtr( edm::Ptr< L1TkCluster< T > > aL1TkCluster ) + { + /// NOTE: this must be used ONLY as it is used + /// within the L1TkStubBuilder! + /// So, pushing back in the right order!! + theClusters.push_back( aL1TkCluster ); + } + + /// Detector element + template< typename T > + void L1TkStub< T >::setDetId( DetId aDetId ) { theDetId = aDetId; } + + /// Trigger info + template< typename T > + double L1TkStub< T >::getTriggerDisplacement() const { return 0.5*theDisplacement; } + + template< typename T > + void L1TkStub< T >::setTriggerDisplacement( int aDisplacement ) { theDisplacement = aDisplacement; } + + template< typename T > + double L1TkStub< T >::getTriggerOffset() const { return 0.5*theOffset; } + + template< typename T > + void L1TkStub< T >::setTriggerOffset( int anOffset ) { theOffset = anOffset; } + + /// MC truth + template< typename T > + bool L1TkStub< T >::isGenuine() const + { + /* + /// GENUINE for clusters means not combinatoric and + /// not unknown: same MC truth content MUST be found + /// in both clusters composing the stub + if ( theClusters.at(0)->isUnknown() || theClusters.at(1)->isUnknown() ) + /// If at least one cluster is unknown, it means + /// either unknown, either combinatoric + return false; + + else + { + /// Here both are clusters are genuine/combinatoric + /// If both clusters have some known SimTrack content + /// they must be compared to each other + if ( theClusters.at(0)->isGenuine() && theClusters.at(1)->isGenuine() ) + { + if ( theClusters.at(0)->findSimTrackId() == theClusters.at(1)->findSimTrackId() ) + /// Two genuine clusters with same SimTrack content mean genuine + return true; + else + return false; + } + else + { + /// Here, at least one cluster is combinatoric + int prevTrack = -99999; // SimTrackId storage + std::vector< edm::Ptr< SimTrack > > innerSimTracks = theClusters.at(0)->getSimTrackPtrs(); + std::vector< edm::Ptr< SimTrack > > outerSimTracks = theClusters.at(1)->getSimTrackPtrs(); + for ( unsigned int i = 0; i < innerSimTracks.size(); i++ ) + { + /// Skip NULL pointers + if ( innerSimTracks.at(i).isNull() ) + continue; + for ( unsigned int j = 0; j < outerSimTracks.size(); j++ ) + { + /// Skip NULL pointers + if ( outerSimTracks.at(j).isNull() ) + continue; + + if ( innerSimTracks.at(i)->trackId() == outerSimTracks.at(j)->trackId() ) + { + /// Same SimTrack is present in both clusters + if ( prevTrack < 0 ) + prevTrack = outerSimTracks.at(j)->trackId(); + + if ( prevTrack != (int)outerSimTracks.at(j)->trackId() ) + /// If two different SimTracks are found in both clusters, + /// then the stub is for sure combinatoric + return false; + } + } + } + if ( prevTrack < 0 ) + /// No SimTracks were found to be in both clusters + return false; + else + /// Only one SimTrack was found to be present in both clusters + /// even if one of the clusters (or both) are combinatoric: + /// this means there is only one track that participates in + /// both clusters, hence the stub is genuine + return true; + } + } + /// Default + /// Should never get here + std::cerr << "W A R N I N G! L1TkStub::isGenuine() \t we should never get here" << std::endl; + return true; + */ + + if ( theSimTrack.isNull() ) + return false; + + return true; + } + + template< typename T > + bool L1TkStub< T >::isCombinatoric() const + { + if ( this->isGenuine() ) + return false; + + /* + /// COMBINATORIC means that the same MC truth content + /// cannot be found in the pair of clusters that compose + /// the stub, and at leask one of them is not unknown + if ( theClusters.at(0)->isUnknown() && theClusters.at(1)->isUnknown() ) + /// Two unknown clusters mean that the stub is unknown + return false; + + else if ( theClusters.at(0)->isUnknown() || theClusters.at(1)->isUnknown() ) + /// One unknown and one combinatoric mean the stub is combinatoric + /// One unknown and one genuine mean the stub is combinatoric + return true; + + else + { + /// Here both are clusters are genuine/combinatoric + /// If both clusters have some known SimTrack content + /// they must be compared to each other + if ( theClusters.at(0)->isGenuine() && theClusters.at(1)->isGenuine() ) + { + if ( theClusters.at(0)->findSimTrackId() == theClusters.at(1)->findSimTrackId() ) + /// Two genuine clusters with same SimTrack content mean genuine + return false; + else + return true; + } + else + { + /// Here, at least one cluster is combinatoric + int prevTrack = -99999; // SimTrackId storage + std::vector< edm::Ptr< SimTrack > > innerSimTracks = theClusters.at(0)->getSimTrackPtrs(); + std::vector< edm::Ptr< SimTrack > > outerSimTracks = theClusters.at(1)->getSimTrackPtrs(); + for ( unsigned int i = 0; i < innerSimTracks.size(); i++ ) + { + /// Skip NULL pointers + if ( innerSimTracks.at(i).isNull() ) + continue; + for ( unsigned int j = 0; j < outerSimTracks.size(); j++ ) + { + /// Skip NULL pointers + if ( outerSimTracks.at(j).isNull() ) + continue; + + if ( innerSimTracks.at(i)->trackId() == outerSimTracks.at(j)->trackId() ) + { + /// Same SimTrack is present in both clusters + if ( prevTrack < 0 ) + prevTrack = outerSimTracks.at(j)->trackId(); + + if ( prevTrack != (int)outerSimTracks.at(j)->trackId() ) + /// If two different SimTracks are found in both clusters, + /// then the stub is for sure combinatoric + return true; + } + } + } + if ( prevTrack < 0 ) + /// No common SimTracks were found to be in both clusters + return true; + else + /// Only one SimTrack was found to be present in both clusters + /// even if one of the clusters (or both) are combinatoric: + /// this means there is only one track that participates in + /// both clusters, hence the stub is genuine + return false; + } + } + /// Default + /// Should never get here + std::cerr << "W A R N I N G! L1TkStub::isCombinatoric() \t we should never get here" << std::endl; + return false; + */ + + if ( this->isUnknown() ) + return false; + + return true; + } + + template< typename T > + bool L1TkStub< T >::isUnknown() const + { + /// UNKNOWN means that both clusters are unknown + /// ... but if they are both unknown and from different EventId, this is COMBINATORIC! + if ( theClusters.at(0)->isUnknown() && theClusters.at(1)->isUnknown() ) + { + if ( theClusters.at(0)->getEventIds().at(0) == theClusters.at(1)->getEventIds().at(0) ) + return true; /// both UNKNOWN from the same EventId + } + + /// If either one is known OR both unknown from different Event Id's + return false; + } + + template< typename T > + int L1TkStub< T >::findType() const + { + if ( theSimTrack.isNull() ) + return 999999999; + return theSimTrack->type(); + } + + template< typename T > + unsigned int L1TkStub< T >::findSimTrackId() const + { + if ( theSimTrack.isNull() ) + return 0; + return theSimTrack->trackId(); + } + + /// Collect MC truth + template< typename T > + void L1TkStub< T >::checkSimTrack() + { + /// This method is based on the early version of + /// isGenuine >>> same approach to store the SimTrack + + /// GENUINE for clusters means not combinatoric and + /// not unknown: same MC truth content MUST be found + /// in both clusters composing the stub + if ( theClusters.at(0)->isUnknown() || theClusters.at(1)->isUnknown() ) + /// If at least one cluster is unknown, it means + /// either unknown, either combinatoric + /// Do nothing, leave the default NULL + return; + + else + { + /// Here both are clusters are genuine/combinatoric + /// If both clusters have some known SimTrack content + /// they must be compared to each other + if ( theClusters.at(0)->isGenuine() && theClusters.at(1)->isGenuine() ) + { + /// The clusters must be associated to the same event + if ( theClusters.at(0)->getEventIds().at(0) != theClusters.at(1)->getEventIds().at(0) ) + return; + + if ( theClusters.at(0)->findSimTrackId() == theClusters.at(1)->findSimTrackId() ) + { + /// Two genuine clusters with same SimTrack content mean genuine + std::vector< edm::Ptr< SimTrack > > curSimTracks = theClusters.at(0)->getSimTrackPtrs(); + for ( unsigned int k = 0; k < curSimTracks.size(); k++ ) + { + if ( curSimTracks.at(k).isNull() == false ) + { + theSimTrack = curSimTracks.at(k); + theEventId = theClusters.at(0)->getEventIds().at(0); + return; + } + } + } + else + return; + } + else + { + /// Here, at least one cluster is combinatoric + int prevTrack = -99999; // SimTrackId storage + unsigned int whichSimTrack = 0; + std::vector< edm::Ptr< SimTrack > > innerSimTracks = theClusters.at(0)->getSimTrackPtrs(); + std::vector< edm::Ptr< SimTrack > > outerSimTracks = theClusters.at(1)->getSimTrackPtrs(); + std::vector< uint32_t > innerEventIds = theClusters.at(0)->getEventIds(); + std::vector< uint32_t > outerEventIds = theClusters.at(1)->getEventIds(); + + for ( unsigned int i = 0; i < innerSimTracks.size(); i++ ) + { + /// Skip NULL pointers + if ( innerSimTracks.at(i).isNull() ) + continue; + + for ( unsigned int j = 0; j < outerSimTracks.size(); j++ ) + { + /// Skip NULL pointers + if ( outerSimTracks.at(j).isNull() ) + continue; + + /// Skip pairs from different EventId + if ( innerEventIds.at(i) != outerEventIds.at(j) ) + continue; + + if ( innerSimTracks.at(i)->trackId() == outerSimTracks.at(j)->trackId() ) + { + /// Same SimTrack is present in both clusters + if ( prevTrack < 0 ) + { + prevTrack = outerSimTracks.at(j)->trackId(); + whichSimTrack = j; + } + + if ( prevTrack != (int)outerSimTracks.at(j)->trackId() ) + /// If two different SimTracks are found in both clusters, + /// then the stub is for sure combinatoric + return; + } + } + } + if ( prevTrack < 0 ) + /// No SimTracks were found to be in both clusters + return; + else + /// Only one SimTrack was found to be present in both clusters + /// even if one of the clusters (or both) are combinatoric: + /// this means there is only one track that participates in + /// both clusters, hence the stub is genuine + theSimTrack = outerSimTracks.at(whichSimTrack); + theEventId = outerEventIds.at(whichSimTrack); /// Same indexing! + } + } + } + + + /// Information + template< typename T > + std::string L1TkStub< T >::print( unsigned int i ) const + { + std::string padding(""); + for ( unsigned int j=0; j!=i; ++j ) + padding+="\t"; + std::stringstream output; + output< > >::const_iterator clusIter; + for ( clusIter = theClusters.begin(); clusIter!= theClusters.end(); ++clusIter ) + output << padding << "cluster: " << iClu++ << ", member: " << (*clusIter)->getStackMember() << ", cluster size: " << (*clusIter)->getHits().size() << '\n'; + return output.str(); + } + + template< typename T > + std::ostream& operator << (std::ostream& os, const L1TkStub< T >& aL1TkStub) { return ( os< +class L1TkTrack +{ + private: + /// Data members + std::vector< edm::Ptr< L1TkStub< T > > > theStubPtrs; + GlobalVector theMomentum; + GlobalPoint theVertex; + double theRInv; + unsigned int theSector; + unsigned int theWedge; + double theChi2; + edm::Ptr< SimTrack > theSimTrack; + uint32_t theEventId; + + public: + /// Constructors + L1TkTrack(); + L1TkTrack( std::vector< edm::Ptr< L1TkStub< T > > > aStubs ); + + /// Destructor + ~L1TkTrack(); + + /// Track components + std::vector< edm::Ptr< L1TkStub< T > > > getStubPtrs() const { return theStubPtrs; } + void addStubPtr( edm::Ptr< L1TkStub< T > > aStub ); + + /// Track momentum + GlobalVector getMomentum() const { return theMomentum; } + void setMomentum( GlobalVector aMomentum ); + + /// Track parameters + double getRInv() const { return theRInv; } + void setRInv( double aRInv ); + + /// Vertex + GlobalPoint getVertex() const { return theVertex; } + void setVertex( GlobalPoint aVertex ); + + /// Sector + unsigned int getSector() const { return theSector; } + void setSector( unsigned int aSector ); + unsigned int getWedge() const { return theWedge; } + void setWedge( unsigned int aWedge ); + + /// Chi2 + double getChi2() const { return theChi2; } + double getChi2Red() const; + void setChi2( double aChi2 ); + + /// MC Truth + edm::Ptr< SimTrack > getSimTrackPtr() const { return theSimTrack; } + uint32_t getEventId() const { return theEventId; } + bool isGenuine() const; + bool isCombinatoric() const; + bool isUnknown() const; + int findType() const; + unsigned int findSimTrackId() const; + + /// Superstrip + /// Here to prepare inclusion of AM L1 Track finding + uint32_t getSuperStrip() const { return 0; } + + /// ////////////// /// + /// HELPER METHODS /// + bool isTheSameAs( L1TkTrack< T > aTrack ) const; + + /// Fake or not + void checkSimTrack(); + + /// Tricky Fit as suggested by Pierluigi, employing + /// a tracklet-style approach for triplets within + /// the chain of stubs composing the track +// void fitTrack( double aMagneticFieldStrength, bool useAlsoVtx, bool aDoHelixFit ); + + /// /////////////////// /// + /// INFORMATIVE METHODS /// +// std::string print( unsigned int i=0 ) const; + +}; /// Close class + +/** ***************************** **/ +/** **/ +/** IMPLEMENTATION OF METHODS **/ +/** **/ +/** ***************************** **/ + +/// Default Constructor +template< typename T > +L1TkTrack< T >::L1TkTrack() +{ + theStubPtrs.clear(); + theMomentum = GlobalVector(0.0,0.0,0.0); + theRInv = 0; + theVertex = GlobalPoint(0.0,0.0,0.0); + theSector = 0; + theWedge = 0; + theChi2 = 0; + /// theSimTrack is NULL by default + theEventId = 0xFFFF; +} + +/// Another Constructor +template< typename T > +L1TkTrack< T >::L1TkTrack( std::vector< edm::Ptr< L1TkStub< T > > > aStubs ) +{ + theStubPtrs = aStubs; + theMomentum = GlobalVector(0.0,0.0,0.0); + theVertex = GlobalPoint(0.0,0.0,0.0); + theRInv = 0; + theSector = 0; + theWedge = 0; + theChi2 = 0; + /// theSimTrack is NULL by default + theEventId = 0xFFFF; +} + +/// Destructor +template< typename T > +L1TkTrack< T >::~L1TkTrack(){} + +/// Track components +template< typename T > +void L1TkTrack< T >::addStubPtr( edm::Ptr< L1TkStub< T > > aStub ) +{ + theStubPtrs.push_back( aStub ); +} + +/// Track momentum +template< typename T > +void L1TkTrack< T >::setMomentum( GlobalVector aMomentum ) +{ + theMomentum = aMomentum; +} + +/// Vertex +template< typename T > +void L1TkTrack< T >::setVertex( GlobalPoint aVertex ) +{ + theVertex = aVertex; +} + +/// Track parameters +template< typename T > +void L1TkTrack< T >::setRInv( double aRInv ) +{ + theRInv = aRInv; +} + +/// Sector +template< typename T > +void L1TkTrack< T >::setSector( unsigned int aSector ) +{ + theSector = aSector; +} + +template< typename T > +void L1TkTrack< T >::setWedge( unsigned int aWedge ) +{ + theWedge = aWedge; +} + +/// Chi2 +template< typename T > +double L1TkTrack< T >::getChi2Red() const { return theChi2/( 2*theStubPtrs.size() - 4 ); } + +template< typename T > +void L1TkTrack< T >::setChi2( double aChi2 ) +{ + theChi2 = aChi2; +} + +// MC truth +template< typename T > +int L1TkTrack< T >::findType() const +{ + if ( theSimTrack.isNull() ) + return 999999999; + return theSimTrack->type(); +} + +template< typename T > +unsigned int L1TkTrack< T >::findSimTrackId() const +{ + if ( theSimTrack.isNull() ) + return 0; + return theSimTrack->trackId(); +} + +/// ////////////// /// +/// HELPER METHODS /// +/// ////////////// /// + +/// Check if two tracks are the same +template< typename T> +bool L1TkTrack< T >::isTheSameAs( L1TkTrack< T > aTrack ) const +{ + /// Take the other stubs + std::vector< edm::Ptr< L1TkStub< T > > > otherStubPtrs = aTrack.getStubPtrs(); + + /// Count shared stubs + unsigned int nShared = 0; + for ( unsigned int i = 0; i < theStubPtrs.size() && nShared < 2; i++) + { + for ( unsigned int j = 0; j < otherStubPtrs.size() && nShared < 2; j++) + { + if ( theStubPtrs.at(i) == otherStubPtrs.at(j) ) + { + nShared++; + } + } + } + + /// Same track if 2 shared stubs + return ( nShared > 1 ); +} + +/// Check SimTracks +template< typename T > +void L1TkTrack< T >::checkSimTrack() +{ + /// Vector to store SimTracks + std::vector< edm::Ptr< SimTrack > > tempVecGen; + std::vector< std::vector< edm::Ptr< SimTrack > > > tempVecComb; + std::vector< uint32_t > evIdGen; + std::vector< std::vector< uint32_t > > evIdComb; + + /// Loop over the Stubs + /// Put the SimTracks together + /// SimTracks from genuine stubs in one container + /// SimTracks from combinatoric stubs in another container + for ( unsigned int js = 0; js < theStubPtrs.size(); js++ ) + { + /// If one Stub is unknown, also the Track is unknown + if ( theStubPtrs.at(js)->isUnknown() ) + return; + + /// Store SimTracks for non-unknown Stubs + if ( theStubPtrs.at(js)->isGenuine() ) + { + tempVecGen.push_back( theStubPtrs.at(js)->getSimTrackPtr() ); + evIdGen.push_back( theStubPtrs.at(js)->getEventId() ); + } + else if ( theStubPtrs.at(js)->isCombinatoric() ) + { + for ( unsigned int ic = 0; ic < 2; ic++ ) + { + std::vector< edm::Ptr< SimTrack > > cluVec = theStubPtrs.at(js)->getClusterPtrs().at(ic)->getSimTrackPtrs(); + tempVecComb.push_back( cluVec ); + std::vector< uint32_t > evVec = theStubPtrs.at(js)->getClusterPtrs().at(ic)->getEventIds(); + evIdComb.push_back( evVec ); + } + } + } + + if ( 2*tempVecGen.size() + tempVecComb.size() != 2*theStubPtrs.size() ) + { + std::cerr << "ERROR!!! HERE WE ARE SUPPOSED TO HAVE ONLY GENUINE AND COMBINATORIAL STUBS" << std::endl; + std::cerr << theStubPtrs.size() << " = " << tempVecGen.size() << " + " << tempVecComb.size()/2 << std::endl; + return; + } + + if ( tempVecComb.size() % 2 != 0 ) + { + std::cerr << "ERROR!!! NO ODD NUMBER OF CLUSTERS FROM COMBINATORIAL STUBS IS SUPPOSED TO BE" << std::endl; + return; + } + + /// If we got here, it means that all the Stubs are genuine/combinatoric + /// COMBINATORIC means that no common SimTrack can be found + /// GENUINE means otherwise + int idSimTrackG = -99999; + uint32_t evIdG = 0xFFFF; + + if ( tempVecGen.size() > 0 ) + { + /// Case of >=1 genuine Stubs + idSimTrackG = tempVecGen.at(0)->trackId(); + evIdG = evIdGen.at(0); + + for ( unsigned int jg = 1; jg < tempVecGen.size(); jg++ ) + { + /// Two genuine Stubs with different EventId mean COMBINATORIC + if ( evIdGen.at(0) != evIdG ) + return; + + /// Two genuine Stubs with different SimTrack mean COMBINATORIC + if ( (int)(tempVecGen.at(0)->trackId()) != idSimTrackG ) + return; + } + + /// If we got here, it means that all the genuine Stubs have the same SimTrack + /// Time to check the combinatoric ones + + /// Case of no combinatoric Stubs + if ( tempVecComb.size() == 0 ) + { + /// No combinatoric stubs found + /// All genuine, all the same SimTrack + theSimTrack = tempVecGen.at(0); + theEventId = evIdGen.at(0); + return; + } + + /// Case of at least 1 Stub is combinatoric + /// If we are here, we must have EVEN tempVecComb.size() + for ( unsigned int jc1 = 0; jc1 < tempVecComb.size(); jc1+=2 ) + { + bool foundSimTrack = false; + /// Check first cluster (see how they are pushed_back) + for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1).size() && !foundSimTrack; jc0++ ) + { + if ( tempVecComb.at(jc1).at(jc0).isNull() ) + continue; + + if ( (int)(tempVecComb.at(jc1).at(jc0)->trackId()) == idSimTrackG && + evIdComb.at(jc1).at(jc0) == evIdG ) + { + foundSimTrack = true; + } + } + /// Check second cluster + for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1+1).size() && !foundSimTrack; jc0++ ) + { + if ( tempVecComb.at(jc1+1).at(jc0).isNull() ) + continue; + + if ( (int)(tempVecComb.at(jc1+1).at(jc0)->trackId()) == idSimTrackG && + evIdComb.at(jc1+1).at(jc0) == evIdG ) + { + foundSimTrack = true; + } + } + + if ( !foundSimTrack ) + return; + + /// If we got here, we have >= 1 genuine Stub whose SimTrack + /// is found in at least 1 Cluster of all other Stubs + theSimTrack = tempVecGen.at(0); + theEventId = evIdGen.at(0); + return; + } + } + else + { + /// No genuine Stubs are found + if ( tempVecComb.size() == 0 ) + { + std::cerr << "YOU SHOULD NEVER GET HERE (0 Genuine and 0 Combinatoric Stubs in a Track)" << std::endl; + return; + } + else if ( tempVecComb.size() == 1 ) + { + std::cerr << "YOU SHOULD NEVER GET HERE (0 Genuine and 1 Combinatoric Stubs in a Track)" << std::endl; + return; + } + + /// We have only combinatoric Stubs + /// We need to have the same SimTrack in all Stubs + /// If we are here, we must have EVEN tempVecComb.size() + /// Map by SimTrackId all the SimTracks and count in how many Stubs they are + std::map< std::pair< unsigned int, uint32_t >, std::vector< unsigned int > > mapSimTrack; + + for ( unsigned int jc1 = 0; jc1 < tempVecComb.size(); jc1+=2 ) + { + /// Check first cluster (see how they are pushed_back) + for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1).size(); jc0++ ) + { + if ( tempVecComb.at(jc1).at(jc0).isNull() ) + continue; + + std::pair< unsigned int, uint32_t > thisId = std::make_pair( tempVecComb.at(jc1).at(jc0)->trackId(), evIdComb.at(jc1).at(jc0) ); + + if ( mapSimTrack.find( thisId ) == mapSimTrack.end() ) + { + /// New SimTrack + /// Push back which Stub idx it is within the Combinatorial ones + std::vector< unsigned int > tempVecStubIdx; + tempVecStubIdx.push_back( jc1/2 ); + mapSimTrack.insert( std::make_pair( thisId, tempVecStubIdx ) ); + } + else + { + /// Existing SimTrack + /// Push back which Stub idx it is within the Combinatorial ones + mapSimTrack.find( thisId )->second.push_back( jc1/2 ); + } + } + /// Check second cluster + for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(jc1+1).size(); jc0++ ) + { + if ( tempVecComb.at(jc1+1).at(jc0).isNull() ) + continue; + + std::pair< unsigned int, uint32_t > thisId = std::make_pair( tempVecComb.at(jc1+1).at(jc0)->trackId(), evIdComb.at(jc1+1).at(jc0) ); + + if ( mapSimTrack.find( thisId ) == mapSimTrack.end() ) + { + /// New SimTrack + /// Push back which Stub idx it is within the Combinatorial ones + std::vector< unsigned int > tempVecStubIdx; + tempVecStubIdx.push_back( jc1/2 ); + mapSimTrack.insert( std::make_pair( thisId, tempVecStubIdx ) ); + } + else + { + /// Existing SimTrack + /// Push back which Stub idx it is within the Combinatorial ones + mapSimTrack.find( thisId )->second.push_back( jc1/2 ); + } + } + } + + /// Check the SimTrack Map + unsigned int countSimTracks = 0; + unsigned int theSimTrackId = 0; + uint32_t theStoredEventId = 0xFFFF; + std::map< std::pair< unsigned int, uint32_t >, std::vector< unsigned int > >::iterator mapIt; + for ( mapIt = mapSimTrack.begin(); + mapIt != mapSimTrack.end(); + ++mapIt ) + { + /// SimTracks found in 1 Cluster of ALL stubs + /// This means that counting the number of different occurencies in the + /// vector one should get the size of the vector of Stubs in the track + /// So, sort and remove duplicates + std::vector< unsigned int > tempVector = mapIt->second; + std::sort( tempVector.begin(), tempVector.end() ); + tempVector.erase( std::unique( tempVector.begin(), tempVector.end() ), tempVector.end() ); + + if ( tempVector.size() == theStubPtrs.size() ) + { + countSimTracks++; + theSimTrackId = mapIt->first.first; + theStoredEventId = mapIt->first.second; + } + } + + /// We want only 1 SimTrack! + if ( countSimTracks != 1 ) + return; + + /// We can look for the SimTrack now ... + /// By construction, it must be in the first Stub ... + /// Check first cluster (see how they are pushed_back) + for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(0).size(); jc0++ ) + { + if ( tempVecComb.at(0).at(jc0).isNull() ) + continue; + + if ( theSimTrackId == tempVecComb.at(0).at(jc0)->trackId() && + theStoredEventId == evIdComb.at(0).at(jc0) ) + { + theSimTrack = tempVecComb.at(0).at(jc0); + theEventId = evIdComb.at(0).at(jc0); + return; + } + } + + /// Check second cluster + for ( unsigned int jc0 = 0; jc0 < tempVecComb.at(1).size(); jc0++ ) + { + if ( tempVecComb.at(1).at(jc0).isNull() ) + continue; + + if ( theSimTrackId == tempVecComb.at(1).at(jc0)->trackId() && + theStoredEventId == evIdComb.at(1).at(jc0) ) + { + theSimTrack = tempVecComb.at(1).at(jc0); + theEventId = evIdComb.at(1).at(jc0); + return; + } + } + } /// End of no genuine stubs are found + + std::cerr << "YOU SHOULD NEVER GET HERE (all cases MUST have been processed earlier)" << std::endl; + +} + +template< typename T > +bool L1TkTrack< T >::isUnknown() const +{ + /// UNKNOWN means that at least 1 Stub is UNKNOWN + + /// Loop over the stubs + for ( unsigned int js = 0; js < theStubPtrs.size(); js++ ) + { + /// If one Stub is unknown, also the Track is unknown + if ( theStubPtrs.at(js)->isUnknown() ) + return true; + } + return false; +} + + +template< typename T > +bool L1TkTrack< T >::isGenuine() const +{ + /// GENUINE means that we could set a SimTrack + if ( theSimTrack.isNull() == false ) + return true; + + return false; +} + + +template< typename T > +bool L1TkTrack< T >::isCombinatoric() const +{ + if ( this->isGenuine() ) + return false; + + if ( this->isUnknown() ) + return false; + + return true; +} + + + +/* + /// Fit + template< typename T > + void L1TkTrack< T >::fitTrack( double aMagneticFieldStrength, bool useAlsoVtx, bool aDoHelixFit ) + { + /// Step 00 + /// Get the magnetic field + /// Usually it is done like the following three lines + //iSetup.get().get(magnet); + //magnet_ = magnet.product(); + //mMagneticFieldStrength = magnet_->inTesla(GlobalPoint(0,0,0)).z(); + /// Calculate factor for rough Pt estimate + /// B rounded to 4.0 or 3.8 + /// This is B * C / 2 * appropriate power of 10 + /// So it's B * 0.0015 + double mPtFactor = (floor(aMagneticFieldStrength*10.0 + 0.5))/10.0*0.0015; + + /// Step 0 + /// Get Stubs chain and Vertex + std::vector< L1TkStub< T > > brickStubs = this->getStubs(); + L1TkTracklet< T > seedTracklet = this->getSeedTracklet(); + /// This automatically sets 00 or beamspot according to L1TkTracklet type + GlobalPoint seedVertexXY = GlobalPoint( seedTracklet.getVertex().x(), seedTracklet.getVertex().y(), 0.0 ); + + /// If the seed vertex is requested for the fit, add it to stubs + if ( useAlsoVtx ) { + /// Prepare dummy stub with vertex position + std::vector< L1TkStub< T > > auxStubs; + auxStubs.clear(); + L1TkStub< T > dummyStub = L1TkStub< T >( 0 ); + +// dummyStub.setPosition( seedTracklet.getVertex() ); +// dummyStub.setDirection( GlobalVector(0,0,0) ); + + auxStubs.push_back( dummyStub ); + /// Put together also other stubs + for ( unsigned int j = 0; j < brickStubs.size(); j++ ) auxStubs.push_back( brickStubs.at(j) ); + /// Overwrite + brickStubs = auxStubs; + } +*/ + + + +/* + /// Step 1 + /// Find charge using only stubs, regardless of useAlsoVtx option! + unsigned int iMin = 0; + if ( useAlsoVtx ) iMin = 1; + /// Check L1TkTracklet for further information + double outerPointPhi = brickStubs.at( brickStubs.size()-1 ).getPosition().phi(); + double innerPointPhi = brickStubs.at( iMin ).getPosition().phi(); + double deltaPhi = outerPointPhi - innerPointPhi; + if ( fabs(deltaPhi) >= KGMS_PI) { + if ( deltaPhi>0 ) deltaPhi = deltaPhi - 2*KGMS_PI; + else deltaPhi = 2*KGMS_PI - fabs(deltaPhi); + } + double deltaPhiC = deltaPhi; /// This is for charge + deltaPhi = fabs(deltaPhi); + double fCharge = -deltaPhiC / deltaPhi; + this->setCharge( fCharge ); + + /// Step 2 + /// Average for Momentum and Axis + std::vector< double > outputFitPt; outputFitPt.clear(); + std::vector< double > outputFitPz; outputFitPz.clear(); + std::vector< double > outputFitX; outputFitX.clear(); + std::vector< double > outputFitY; outputFitY.clear(); + /// Now loop over Triplets + unsigned int totalTriplets = 0; + for ( unsigned int a1 = 0; a1 < brickStubs.size(); a1++ ) { + for ( unsigned int a2 = a1+1; a2 < brickStubs.size(); a2++ ) { + for ( unsigned int a3 = a2+1; a3 < brickStubs.size(); a3++ ) { + totalTriplets++; + /// Read Stubs in a "L1TkTracklet-wise" way + GlobalPoint vtxPos = brickStubs.at(a1).getPosition(); + GlobalPoint innPos = brickStubs.at(a2).getPosition(); + GlobalPoint outPos = brickStubs.at(a3).getPosition(); + /// Correct for position of a1 + innPos = GlobalPoint( innPos.x()-vtxPos.x(), innPos.y()-vtxPos.y(), innPos.z() ); + outPos = GlobalPoint( outPos.x()-vtxPos.x(), outPos.y()-vtxPos.y(), outPos.z() ); + double outRad = outPos.perp(); + double innRad = innPos.perp(); + deltaPhi = outPos.phi() - innPos.phi(); /// NOTE overwrite already declared deltaPhi + if ( fabs(deltaPhi) >= KGMS_PI ) { + if ( deltaPhi>0 ) deltaPhi = deltaPhi - 2*KGMS_PI; + else deltaPhi = 2*KGMS_PI - fabs(deltaPhi); + } + deltaPhi = fabs(deltaPhi); + double x2 = outRad * outRad + innRad * innRad - 2 * innRad * outRad * cos(deltaPhi); + double twoRadius = sqrt(x2) / sin(fabs(deltaPhi)); + double roughPt = mPtFactor * twoRadius; + double roughPz; + /// Switch fit type + if ( !aDoHelixFit ) roughPz = roughPt * (outPos.z()-innPos.z()) / (outRad-innRad); + else { + double phioi = acos(1 - 2*x2/(twoRadius*twoRadius)); + if ( fabs(phioi) >= KGMS_PI ) { + if ( phioi>0 ) phioi = phioi - 2*KGMS_PI; + else phioi = 2*KGMS_PI - fabs(phioi); + } + if ( phioi == 0 ) return; + roughPz = 2 * mPtFactor * (outPos.z()-innPos.z()) / fabs(phioi); + } + /// Store Momenta for average + outputFitPt.push_back( roughPt ); + outputFitPz.push_back( roughPz ); + /// Find angle from a1 pointing to Axis + double vertexangle = acos( outRad/twoRadius ); + vertexangle = outPos.phi() - fCharge * vertexangle; + /// Helix axis + outputFitX.push_back( 0.5 * twoRadius * cos(vertexangle) + vtxPos.x() ); + outputFitY.push_back( 0.5 * twoRadius * sin(vertexangle) + vtxPos.y() ); + } /// End of loop over third element + } /// End of loop over second element + } /// End of loop over first element + /// Compute averages and store them + double tempOutputX = 0; + double tempOutputY = 0; + double tempOutputPt = 0; + double tempOutputPz = 0; + for ( unsigned int q = 0; q < totalTriplets; q++ ) { + tempOutputX += outputFitX.at(q); + tempOutputY += outputFitY.at(q); + tempOutputPt += outputFitPt.at(q); + tempOutputPz += outputFitPz.at(q); + } + + /// Step 3 + /// Get Helix Axis and correct wrt Seed VTX + GlobalPoint fAxis = GlobalPoint( tempOutputX/totalTriplets, tempOutputY/totalTriplets, 0.0 ); + GlobalPoint fAxisCorr = GlobalPoint( fAxis.x() - seedVertexXY.x(), fAxis.y() - seedVertexXY.y(), 0.0 ); + this->setAxis( tempOutputX/totalTriplets, tempOutputY/totalTriplets ); + + /// Step 4 + /// Momentum, starting from azimuth at vertex + double fPhiV = atan2( fCharge*fAxisCorr.x(), -fCharge*fAxisCorr.y() ); + double fPt = tempOutputPt/totalTriplets; + double fPz = tempOutputPz/totalTriplets; + double fRadius = 0.5*fPt/mPtFactor; + GlobalVector fMomentum = GlobalVector( cos(fPhiV)*fPt, sin(fPhiV)*fPt, fPz ); + this->setMomentum( fMomentum ); + + /// Step 5 + /// Average for Vertex (Closest Approach) + double rMinAppr = fAxisCorr.perp() - fRadius; + double xMinAppr = rMinAppr*cos( fAxisCorr.phi() ) + seedVertexXY.x(); + double yMinAppr = rMinAppr*sin( fAxisCorr.phi() ) + seedVertexXY.y(); + GlobalPoint tempVertex = GlobalPoint( xMinAppr, yMinAppr, 0.0 ); + double propFactorHel = 0; + double offsetHel = 0; + /// Average for Vtx z + std::vector< double > outputFitZ; outputFitZ.clear(); + /// Now loop over Doublets + /// Cannot put into the same loop as before because + /// here we need radius and therefore Pt to have + /// the radius, and the radius is needed to find the + /// closest approach distance, is it clear? + unsigned int totalDoublets = 0; + for ( unsigned int a1 = iMin; a1 < brickStubs.size(); a1++) { /// iMin already set according to useAlsoVtx or not + for ( unsigned int a2 = a1+1; a2 < brickStubs.size(); a2++) { + totalDoublets++; + /// Read Stubs in a "L1TkTracklet-wise" way + GlobalPoint innPos = brickStubs.at(a1).getPosition(); + GlobalPoint outPos = brickStubs.at(a2).getPosition(); + /// Calculate z = z0 + c*phiStar + GlobalPoint innPosStar = GlobalPoint( innPos.x() - fAxis.x(), innPos.y() - fAxis.y(), innPos.z() - fAxis.z() ); + GlobalPoint outPosStar = GlobalPoint( outPos.x() - fAxis.x(), outPos.y() - fAxis.y(), outPos.z() - fAxis.z() ); + double deltaPhiStar = outPosStar.phi() - innPosStar.phi(); + if ( fabs(deltaPhiStar) >= KGMS_PI ) { + if ( outPosStar.phi() < 0 ) deltaPhiStar += KGMS_PI; + else deltaPhiStar -= KGMS_PI; + if ( innPosStar.phi() < 0 ) deltaPhiStar -= KGMS_PI; + else deltaPhiStar += KGMS_PI; + } + if ( deltaPhiStar == 0 ) std::cerr<<"BIG PROBLEM IN DELTAPHI DENOMINATOR"<= KGMS_PI ) { + if ( deltaPhi>0 ) deltaPhi = deltaPhi - 2*KGMS_PI; + else deltaPhi = 2*KGMS_PI - fabs(deltaPhi); + } + deltaPhi = fabs(deltaPhi); + double x2 = outRad * outRad + innRad * innRad - 2 * innRad * outRad * cos(deltaPhi); + double twoRadius = sqrt(x2) / sin(fabs(deltaPhi)); + double zProj; + /// Switch fit type + if ( !aDoHelixFit ) zProj = outPos.z() - ( outRad * (outPos.z() - innPos.z()) / (outRad - innRad) ); + else { + double phioi = acos(1 - 2*x2/(twoRadius*twoRadius)); + double phiiv = acos(1 - 2*innRad*innRad/(twoRadius*twoRadius)); + if ( fabs(phioi) >= KGMS_PI ) { + if ( phioi>0 ) phioi = phioi - 2*KGMS_PI; + else phioi = 2*KGMS_PI - fabs(phioi); + } + if ( fabs(phiiv) >= KGMS_PI ) { + if ( phiiv>0 ) phiiv = phiiv - 2*KGMS_PI; + else phiiv = 2*KGMS_PI - fabs(phiiv); + } + if ( phioi == 0 ) return; + /// Vertex + zProj = innPos.z() - (outPos.z()-innPos.z())*phiiv/phioi; + } + outputFitZ.push_back( zProj ); + } /// End of loop over second element + } /// End of loop over first element + /// Compute averages and store them + double tempOutputZ = 0; + for ( unsigned int q = 0; q < totalDoublets; q++ ) tempOutputZ += outputFitZ.at(q); + double zMinAppr = tempOutputZ/totalDoublets; + + /// Step 6 + /// Vertex + GlobalPoint fVertex = GlobalPoint( xMinAppr, yMinAppr, zMinAppr ); + this->setVertex( fVertex ); + + + /// Step 7 + /// Calculate Chi2 + propFactorHel = propFactorHel/totalDoublets; + offsetHel = offsetHel/totalDoublets; + double fChi2RPhi = 0; + double fChi2ZPhi = 0; + double tempStep; + /// Calculate for the Seed VTX if needed + if (useAlsoVtx) { + GlobalPoint posPoint = seedTracklet.getVertex(); + GlobalPoint posPointCorr = GlobalPoint( posPoint.x() - fAxis.x(), posPoint.y() - fAxis.y(), posPoint.z() ); + /// Add X: x_meas - x_fit(phi*_meas) + tempStep = posPoint.x() - fAxis.x() - fRadius * cos( posPointCorr.phi() ); + fChi2RPhi += tempStep*tempStep; + /// Add Y: y_meas - y_fit(phi*_meas) + tempStep = posPoint.y() - fAxis.y() - fRadius * sin( posPointCorr.phi() ); + fChi2RPhi += tempStep*tempStep; + /// b = propFactorH + /// a = offsetH + /// z = b*phi - a + /// Add Z: z_meas - z_fit(phi*_meas) + tempStep = posPoint.z() - offsetHel - propFactorHel * posPointCorr.phi(); + fChi2ZPhi += tempStep*tempStep; + } + /// Calculate for all other Stubs + for ( unsigned int a = iMin; a < brickStubs.size(); a++ ) { + GlobalPoint posPoint = brickStubs.at(a).getPosition(); + GlobalPoint posPointCorr = GlobalPoint( posPoint.x() - fAxis.x(), posPoint.y() - fAxis.y(), posPoint.z() ); + + tempStep = posPoint.x() - fAxis.x() - fRadius * cos( posPointCorr.phi() ); + fChi2RPhi += tempStep*tempStep; + tempStep = posPoint.y() - fAxis.y() - fRadius * sin( posPointCorr.phi() ); + fChi2RPhi += tempStep*tempStep; + + tempStep = posPoint.z() - offsetHel - propFactorHel * posPointCorr.phi(); + fChi2ZPhi += tempStep*tempStep; + } + this->setChi2RPhi( fChi2RPhi ); + this->setChi2ZPhi( fChi2ZPhi ); + +*/ + + + +/* + } + + + + /// /////////////////// /// + /// INFORMATIVE METHODS /// + /// /////////////////// /// + + template< typename T > + std::string L1TkTrack< T >::print( unsigned int i ) const { + std::string padding(""); + for ( unsigned int j=0; j!=i; ++j )padding+="\t"; + std::stringstream output; + output<getSeedDoubleStack() << '\n'; + output << padding << "Length of Chain: " << theBrickStubs.size() << '\n'; + unsigned int iStub = 0; + for ( L1TkStubPtrCollectionIterator i = theBrickStubs.begin(); i!= theBrickStubs.end(); ++i ) + output << padding << "stub: " << iStub++ << ", stack: \n";// << (*i)->getStack() << ", rough Pt: " << '\n';//(*i)->getRoughPt() << '\n'; + return output.str(); + } + + template< typename T > + std::ostream& operator << (std::ostream& os, const L1TkTrack< T >& aL1TkTrack) { + return (os< +#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" +#include "SimDataFormats/SLHC/interface/L1CaloTower.h" +#include "SLHCUpgradeSimulations/L1CaloTrigger/interface/TriggerTowerGeometry.h" + +namespace l1slhc +{ + + class L1TowerJet + { + + public: + + enum tJetShape + { + square, + circle + }; + + public: + + L1TowerJet( ); + L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea ); + // L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea , const int& iEta, const int& iPhi); + L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , + const std::vector< std::pair< int, int > >& aJetShapeMap, const int &iEta, const int &iPhi ); + + ~L1TowerJet( ); + + // getters + // ~~~~~~~ + // Jet iEta and iPhi parameters (Eta and phi of top-left reference TT) + const int& iEta( ) const; + const int& iPhi( ) const; + // Total TT energy sum (GeV) + const double& E( ) const; + const bool& central( ) const; + + // centrality member variables + const double& Centrality( ) const; + + //asymmetry member variables + const int& AsymEta( ) const; + const int& AsymPhi( ) const; + + + /* //weighted iEta, iPhi + const double& iWeightedEta( ) const; + const double& iWeightedPhi( ) const; + */ + + // Jet pT + const double Pt( ) const; + // Geometric jet center eta and phi + const double Eta( ) const; + const double Phi( ) const; + // Energy weighted eta and phi of jet center + const double WeightedEta( ) const; + const double WeightedPhi( ) const; + // Jet pT, weighted eta, weighted phi and mass + const math::PtEtaPhiMLorentzVector& p4( ) const; + // Jet shape width in TTs + const int& JetSize( ) const; + // Jet shape type + const L1TowerJet::tJetShape& JetShape( ) const; + // Area of jet in TTs + const int& JetArea( ) const; + // Real area of jet (deltaEta * deltaPhi) + const double& JetRealArea( ) const; + + +/* const double& MaxTTEnergy( ) const; */ +/* const double& MaxTTEnergyInSeedRegion( ) const; */ + +// possibly helpful methods +// double EcalVariance( ) const; +// double HcalVariance( ) const; +// double EnergyVariance( ) const; + // Median absolute deviations + double EcalMAD() const; + double HcalMAD() const; + double EnergyMAD() const; + + // Setters + // ~~~~~~~ + void setP4( const math::PtEtaPhiMLorentzVector & p4 ); + void setPt( const double & pT ); + void setCentral( const bool& ); + + // Calculate the jet centrality + void calculateCentrality(); + // Determine the central jet eta and phi for unweighted and energy weighting + void calculateJetCenter(); + void calculateWeightedJetCenter(); + + // Add a TT to the TowerJet + void addConstituent( const L1CaloTowerRef & Tower ); + L1CaloTowerRefVector::iterator getConstituent( const int& eta , const int& phi ); + void removeConstituent( const int& eta , const int& phi ); + + const L1CaloTowerRefVector& getConstituents( ) const; + + double MAD( std::deque& aDataSet ) const; + + + private: + // i-coordinates, define the top left TT of the jet + int mIeta; + int mIphi; + // Energy of jet in 2 GeV units: 1 -> 2 GeV (REMOVE THIS) + int mE2GeV; + // True value of E in GeV + double mE; + +/* int mMaxTTEnergy2GeV; */ +/* int mMaxTTEnergyInSeedRegion2GeV; */ + + bool mCentral; + + // Asymmetry parameters + int mAsymEta; + int mAsymPhi; + + // Centrality parameter + double mCentrality; + + //weighted eta and phi + /*double mWeightedIeta; + double mWeightedIphi; + */ + /* + double mWeightedEta; + double mWeightedPhi; + */ + // Jet center eta and phi + double mJetCenterEta; + double mJetCenterPhi; + + + // Size and area of jet in TTs + int mJetSize; + L1TowerJet::tJetShape mJetShapeType; + int mJetArea; + // Actual eta*phi jet area + double mJetRealArea; + + // Undo wrapping of iPhi + int iPhiUnwrap(int aIphi); + + // Tower geometry converter + static TriggerTowerGeometry mTowerGeo; + + L1CaloTowerRefVector mConstituents; + + // Pt, energy weighted eta, energy weighted phi and mass of the jet + math::PtEtaPhiMLorentzVector mP4; + + + + + static const double PI; + + }; + + +} + + +// Jet rank operator +namespace std{ + bool operator<( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ); + bool operator>( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ); +} + +// Jet printing +std::ostream & operator<<( std::ostream & , const l1slhc::L1TowerJet & ); + +#endif diff --git a/SimDataFormats/SLHC/interface/L1TowerJetFwd.h b/SimDataFormats/SLHC/interface/L1TowerJetFwd.h new file mode 100644 index 0000000000000..5a44cd0a3998e --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TowerJetFwd.h @@ -0,0 +1,21 @@ +#ifndef L1TowerJet_Fwd +#define L1TowerJet_Fwd + + +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" +#include "DataFormats/Common/interface/Ref.h" +#include + +namespace l1slhc +{ + class L1TowerJet; +} + +namespace l1slhc +{ + typedef EtaPhiContainer < L1TowerJet > L1TowerJetCollection; + + typedef edm::Ref < L1TowerJetCollection > L1TowerJetRef; +} + +#endif diff --git a/SimDataFormats/SLHC/interface/L1TowerNav.h b/SimDataFormats/SLHC/interface/L1TowerNav.h new file mode 100644 index 0000000000000..29333c633c97b --- /dev/null +++ b/SimDataFormats/SLHC/interface/L1TowerNav.h @@ -0,0 +1,24 @@ +#ifndef SimDataFormats_SLHC_L1TowerNav +#define SimDataFormats_SLHC_L1TowerNav + +//proto type, probably should be a namespace but I might extend it +//quick dirty hack to get the towers navigating correctly + +class L1TowerNav { +public: + // static const int kNullIEta=0; //return value if offset brings it to an invalid eta position (now removed, we return invalid iEta positions + static const int kNullIPhi=0; //return value if we have an invalid phi position, note we can only achieve this if the starting iPhi is invalid + + static const int kIPhiMax=72; + static const int kIEtaAbsHEMax=28; //end of HE, useful as the phi scale changes for HF + static const int kIEtaAbsHFMax=32; //pTDR says 41 but we appear to end at 32, are we combining the high eta towers? check this! + static const int kHFIPhiScale=4; //each phi tower in HF is 4 that of HBHE + + static int getOffsetIEta(int iEta,int offset); //returns the iEta which is offset towers away form iEta + static int getOffsetIPhi(int iEta,int iPhi,int offset); //returns the iPhi which is offset towers away from iPhi, needs iEta to know if in HBHE or HF + static int getOffsetIPhiHBHE(int iPhi,int offset); + static int getOffsetIPhiHF(int iPhi,int offset); +}; + + +#endif diff --git a/SimDataFormats/SLHC/interface/StackedTrackerTypes.h b/SimDataFormats/SLHC/interface/StackedTrackerTypes.h new file mode 100644 index 0000000000000..74840de251735 --- /dev/null +++ b/SimDataFormats/SLHC/interface/StackedTrackerTypes.h @@ -0,0 +1,83 @@ +/// //////////////////////////////////////// +/// Stacked Tracker Simulations /// +/// Written by: /// +/// Andrew W. Rose /// +/// 2008 /// +/// /// +/// Changed by: /// +/// Nicola Pozzobon /// +/// UNIPD /// +/// 2010, Oct; 2011 July, Sep /// +/// 2013, Mar /// +/// /// +/// Added feature: /// +/// Removed (NOT commented) TTHits /// +/// (Maybe in the future they will be /// +/// reintroduced in the framework...) /// +/// Adapted to the new approach /// +/// Completed with Tracks /// +/// Cleaning while porting to 6_1_1 /// +/// //////////////////////////////////////// + +#ifndef STACKED_TRACKER_TYPES_H +#define STACKED_TRACKER_TYPES_H + +/// Specific Data Formats for Tracking Trigger +#include "SimDataFormats/SLHC/interface/L1TkCluster.h" +#include "SimDataFormats/SLHC/interface/L1TkStub.h" +#include "SimDataFormats/SLHC/interface/L1TkTrack.h" +/// Anders includes +//#include "SimDataFormats/SLHC/interface/L1TRod.hh" +//#include "SimDataFormats/SLHC/interface/L1TSector.hh" +//#include "SimDataFormats/SLHC/interface/L1TStub.hh" +//#include "SimDataFormats/SLHC/interface/L1TWord.hh" +//#include "SimDataFormats/SLHC/interface/slhcevent.hh" +//#include "SimDataFormats/SLHC/interface/L1TTracklet.hh" +//#include "SimDataFormats/SLHC/interface/L1TTracklets.hh" +//#include "SimDataFormats/SLHC/interface/L1TTrack.hh" +//#include "SimDataFormats/SLHC/interface/L1TTracks.hh" + +/// Standard CMS Formats +#include "DataFormats/Common/interface/Ref.h" +#include "DataFormats/Common/interface/Ptr.h" +#include "DataFormats/Common/interface/DetSetVector.h" +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" + + /// The reference types + typedef edm::Ref< edm::PSimHitContainer > Ref_PSimHit_; + typedef edm::Ref< edm::DetSetVector , PixelDigi > Ref_PixelDigi_; + + /// Cluster data types + typedef L1TkCluster< Ref_PSimHit_ > L1TkCluster_PSimHit_; + typedef L1TkCluster< Ref_PixelDigi_ > L1TkCluster_PixelDigi_; + + typedef std::vector< L1TkCluster_PSimHit_ > L1TkCluster_PSimHit_Collection; + typedef std::vector< L1TkCluster_PixelDigi_ > L1TkCluster_PixelDigi_Collection; + + typedef std::map< std::pair, L1TkCluster_PSimHit_Collection > L1TkCluster_PSimHit_Map; + typedef std::map< std::pair, L1TkCluster_PixelDigi_Collection > L1TkCluster_PixelDigi_Map; + + typedef edm::Ptr< L1TkCluster_PSimHit_ > L1TkCluster_PSimHit_Pointer; + typedef edm::Ptr< L1TkCluster_PixelDigi_ > L1TkCluster_PixelDigi_Pointer; + + typedef std::vector< L1TkCluster_PSimHit_Pointer > L1TkCluster_PSimHit_Pointer_Collection; + typedef std::vector< L1TkCluster_PixelDigi_Pointer > L1TkCluster_PixelDigi_Pointer_Collection; + + /// Stub data types + typedef L1TkStub< Ref_PSimHit_ > L1TkStub_PSimHit_; + typedef L1TkStub< Ref_PixelDigi_ > L1TkStub_PixelDigi_; + + typedef std::vector< L1TkStub_PSimHit_ > L1TkStub_PSimHit_Collection; + typedef std::vector< L1TkStub_PixelDigi_ > L1TkStub_PixelDigi_Collection; + + /// Track data types + typedef L1TkTrack< Ref_PSimHit_ > L1TkTrack_PSimHit_; + typedef L1TkTrack< Ref_PixelDigi_ > L1TkTrack_PixelDigi_; + + typedef std::vector< L1TkTrack_PSimHit_ > L1TkTrack_PSimHit_Collection; + typedef std::vector< L1TkTrack_PixelDigi_ > L1TkTrack_PixelDigi_Collection; + + +#endif + diff --git a/SimDataFormats/SLHC/interface/slhcevent.hh b/SimDataFormats/SLHC/interface/slhcevent.hh new file mode 100755 index 0000000000000..e170cc2ce0e2b --- /dev/null +++ b/SimDataFormats/SLHC/interface/slhcevent.hh @@ -0,0 +1,643 @@ +#ifndef SLHCEVENT_H +#define SLHCEVENT_H + +#include +#include +#include +#include +#include +#include +#include +#include +#include "L1TStub.hh" + +#define NSECTORS 28 + +using namespace std; + +//This is the number of strips in rphi and in z for a module. +//This should be in the header of the ASCII file, but for now +//just hardcoded here. + + +static double two_pi=8*atan(1.0); + +static double x_offset=0.199196*0.0; +static double y_offset=0.299922*0.0; + + + + +class L1SimTrack{ + +public: + + L1SimTrack() { + id_=-1; + } + + L1SimTrack(int id, int type, double pt, double eta, double phi, + double vx, double vy, double vz) { + id_=id; + type_=type; + pt_=pt; + eta_=eta; + phi_=phi; + vx_=vx; + vy_=vy; + vz_=vz; + } + + void write(ofstream& out){ + + out << "L1SimTrack: " + << id_ << "\t" + << type_ << "\t" + << pt_ << "\t" + << eta_ << "\t" + << phi_ << "\t" + << vx_ << "\t" + << vy_ << "\t" + << vz_ << "\t" << endl; + + } + + int id() const { return id_; } + int type() const { return type_; } + double pt() { return pt_; } + double eta() { return eta_; } + double phi() { return phi_; } + double vx() { return vx_; } + double vy() { return vy_; } + double vz() { return vz_; } + +private: + + int id_; + int type_; + double pt_; + double eta_; + double phi_; + double vx_; + double vy_; + double vz_; + +}; + + +class Digi{ + +public: + + + Digi(int layer,int irphi, int iz, int sensorlayer, + int ladder, int module, double x, double y, double z) { + layer_=layer; + irphi_=irphi; + iz_=iz; + sensorlayer_=sensorlayer; + ladder_=ladder; + module_=module; + x_=x; + y_=y; + z_=z; + } + + void AddSimtrack(int simtrackid){ + simtrackids_.push_back(simtrackid); + } + + void write(ofstream& out){ + + out << "Digi: " + << layer_ << "\t" + << irphi_ << "\t" + << iz_ << "\t" + << sensorlayer_ << "\t" + << ladder_ << "\t" + << module_ << "\t" + << x_ << "\t" + << y_ << "\t" + << z_ << "\t" << endl; + + for (unsigned int i=0;i simtrackids_; + +}; + +struct HashOp { + int operator()(const Digi &a) const { + return a.hash(); + } +}; + +struct HashEqual { + bool operator()(const Digi &a, const Digi &b) const { + return a == b; + } +}; + + + + +class SLHCEvent{ + +public: + + + SLHCEvent() { + //empty constructor to be used with 'filler' functions + } + + void setIPx(double x) { x_offset=x;} + void setIPy(double y) { y_offset=y;} + + void addL1SimTrack(int id,int type,double pt,double eta,double phi, + double vx,double vy,double vz){ + + vx-=x_offset; + vy-=y_offset; + L1SimTrack simtrack(id,type,pt,eta,phi,vx,vy,vz); + simtracks_.push_back(simtrack); + + } + + + void addDigi(int layer,int irphi,int iz,int sensorlayer,int ladder,int module, + double x,double y,double z,vector simtrackids){ + + x-=x_offset; + y-=y_offset; + + Digi digi(layer,irphi,iz,sensorlayer,ladder, + module,x,y,z); + + for (unsigned int i=0;i innerStack, + vector irphi, + vector iz, + vector iladder, + vector imodule){ + + x-=x_offset; + y-=y_offset; + + L1TStub stub(-1,-1,-1,layer, ladder, module, x, y, z, -1.0, -1.0, pt); + + for(unsigned int i=0;i> tmp; + while (tmp=="Map:") { + in>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp; + in>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp>>tmp; + } + if (tmp=="EndMap") { + in>>tmp; + } + if (tmp!="Event:") { + cout << "Expected to read 'Event:' but found:"<> eventnum_; + + cout << "Started to read event="<> tmp; + while (tmp!="SimTrackEnd"){ + if (!(tmp=="SimTrack:"||tmp=="SimTrackEnd")) { + cout << "Expected to read 'SimTrack:' or 'SimTrackEnd' but found:" + << tmp << endl; + abort(); + } + int id; + int type; + double pt; + double eta; + double phi; + double vx; + double vy; + double vz; + in >> id >> type >> pt >> eta >> phi >> vx >> vy >> vz; + if (first) { + mc_rinv=0.00299792*3.8/pt; + mc_phi0=phi; + mc_z0=vz; + mc_t=tan(0.25*two_pi-2.0*atan(exp(-eta))); + event=eventnum_; + first=false; + } + vx-=x_offset; + vy-=y_offset; + L1SimTrack simtrack(id,type,pt,eta,phi,vx,vy,vz); + simtracks_.push_back(simtrack); + in >> tmp; + } + + + + //read te Digis + in >> tmp; + while (tmp!="DigiEnd"){ + if (!(tmp=="Digi:"||tmp=="DigiEnd")) { + cout << "Expected to read 'Digi:' or 'DigiEnd' but found:" + << tmp << endl; + abort(); + } + int layer; + int irphi; + int iz; + int sensorlayer; + int ladder; + int module; + double x; + double y; + double z; + + in >> layer + >> irphi + >> iz + >> sensorlayer + >> ladder + >> module + >> x + >> y + >> z; + + x-=x_offset; + y-=y_offset; + + + Digi digi(layer,irphi,iz,sensorlayer,ladder, + module,x,y,z); + in >> tmp; + while (tmp=="SimTrackId:"){ + int simtrackid; + in >> simtrackid; + digi.AddSimtrack(simtrackid); + in >> tmp; + } + digis_.push_back(digi); + digihash_.insert(digi); + } + + cout << "Read "<> tmp; + while (tmp!="StubEnd"){ + + if (!in.good()) { + cout << "File not good"<> layer >> ladder >> module >> pt >> x >> y >> z; + + layer--; + x-=x_offset; + y-=y_offset; + + if (layer < 10) nlayer[layer]++; + + L1TStub stub(-1,-1,-1,layer, ladder, module, x, y, z, -1.0, -1.0, pt); + + in >> tmp; + + while (tmp=="InnerStackDigi:"||tmp=="OuterStackDigi:"){ + int irphi; + int iz; + int iladder; + int imodule; + in >> irphi; + in >> iz; + in >> iladder; + in >> imodule; + if (tmp=="InnerStackDigi:") stub.AddInnerDigi(iladder,imodule,irphi,iz); + if (tmp=="OuterStackDigi:") stub.AddOuterDigi(iladder,imodule,irphi,iz); + in >> tmp; + } + + bool foundclose=false; + + for (unsigned int i=0;i simtrackids; + + simtrackids=this->simtrackids(stub); + + if (simtrackids.size()==0) { + return -1; + } + + + std::sort(simtrackids.begin(),simtrackids.end()); + + int n_max = 0; + int value_max = 0; + int n_tmp = 1; + int value_tmp = simtrackids[0]; + for (unsigned int i=1; i n_max) { + n_max = n_tmp; + value_max = value_tmp; + } + n_tmp = 1; + value_tmp = simtrackids[i]; + } + } + + if (n_tmp > n_max) value_max = value_tmp; + + return value_max; + + } + + std::vector simtrackids(const L1TStub& stub){ + + //cout << "Entering simtrackids"< simtrackids; + + int layer=stub.layer()+1; + + + vector > innerdigis=stub.innerdigis(); + vector > outerdigis=stub.outerdigis(); + vector > innerdigisladdermodule=stub.innerdigisladdermodule(); + vector > outerdigisladdermodule=stub.outerdigisladdermodule(); + + vector > alldigis=stub.innerdigis(); + alldigis.insert(alldigis.end(),outerdigis.begin(),outerdigis.end()); + vector > alldigisladdermodule=stub.innerdigisladdermodule(); + alldigisladdermodule.insert(alldigisladdermodule.end(), + outerdigisladdermodule.begin(), + outerdigisladdermodule.end()); + + + + if (layer<1000) { + + for (unsigned int k=0;k::const_iterator it=digihash_.find(tmp); + if(it==digihash_.end()){ + static int count=0; + count++; + if (count<5) { + cout << "Warning did not find digi"<::const_iterator it=digihash_.find(tmp); + if(it==digihash_.end()){ + static int count=0; + count++; + if (count < 5) { + cout << "Warning did not find digi in disks"< simtracks_; + vector digis_; + __gnu_cxx::hash_set digihash_; + vector stubs_; + + +}; + +double SLHCEvent::mc_rinv=0.0; +double SLHCEvent::mc_phi0=0.0; +double SLHCEvent::mc_z0=0.0; +double SLHCEvent::mc_t=0.0; +int SLHCEvent::event=0; + +#endif + + + diff --git a/SimDataFormats/SLHC/src/L1CaloCluster.cc b/SimDataFormats/SLHC/src/L1CaloCluster.cc new file mode 100644 index 0000000000000..49b64ec5a1069 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1CaloCluster.cc @@ -0,0 +1,459 @@ +#include "SimDataFormats/SLHC/interface/L1CaloCluster.h" +#include "SimDataFormats/SLHC/interface/L1TowerNav.h" +#include + +namespace l1slhc +{ + + L1CaloCluster::L1CaloCluster( ):mIeta( 0 ), + mIphi( 0 ), + mEmEt( 0 ), + mHadEt( 0 ), + mLeadTowerE( 0 ), + mSecondTowerE( 0 ), + mThirdTowerE( 0 ), + mFourthTowerE( 0 ), + mRing1E( 0 ), + mRing2E( 0 ), + mRing3E( 0 ), + mRing4E( 0 ), + mFg( false ), + mEgamma( false ), + mCentral( false ), + mIsoeg( false ), + mLeadtowertau( false ), + mIsotau( false ), + mEgammavalue( 0 ), + mInnereta( 0 ), + mInnerphi( 0 ), + mIsoclusterseg( 0 ), + mIsoclusterstau( 0 ), + mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ), + mIsoEmEtEG( 0 ), + mIsoHadEtEG( 0 ) + { + } + + L1CaloCluster::L1CaloCluster( const int &iEta, const int &iPhi ):mIeta( iEta ), + mIphi( iPhi ), + mEmEt( 0 ), + mHadEt( 0 ), + mLeadTowerE( 0 ), + mSecondTowerE( 0 ), + mThirdTowerE( 0 ), + mFourthTowerE( 0 ), + mRing1E( 0 ), + mRing2E( 0 ), + mRing3E( 0 ), + mRing4E( 0 ), + mFg( false ), + mEgamma( false ), + mCentral( false ), + mIsoeg( false ), + mLeadtowertau( false ), + mIsotau( false ), + mEgammavalue( 0 ), + mInnereta( 0 ), + mInnerphi( 0 ), + mIsoclusterseg( 0 ), + mIsoclusterstau( 0 ), + mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ), + mIsoEmEtEG( 0 ), + mIsoHadEtEG( 0 ) + { + } + + + + L1CaloCluster::~L1CaloCluster( ) + { + } + + + const int &L1CaloCluster::iEta( ) const + { + return mIeta; + } + + const int &L1CaloCluster::iPhi( ) const + { + return mIphi; + } + + const int &L1CaloCluster::innerEta( ) const + { + return mInnereta; + } + + const int &L1CaloCluster::innerPhi( ) const + { + return mInnerphi; + } + + + const int L1CaloCluster::Et( int mode ) const + { + int returnEt=0; + if(mode&0x1) returnEt+=mEmEt; + if(mode&0x2) returnEt+=mHadEt; + return returnEt; + } + + const int &L1CaloCluster::EmEt( ) const + { + return mEmEt; + } + + const int &L1CaloCluster::HadEt( ) const + { + return mHadEt; + } + + const int &L1CaloCluster::LeadTowerE( ) const + { + return mLeadTowerE; + } + + const int &L1CaloCluster::SecondTowerE( ) const + { + return mSecondTowerE; + } + + const int &L1CaloCluster::ThirdTowerE( ) const + { + return mThirdTowerE; + } + + const int &L1CaloCluster::FourthTowerE( ) const + { + return mFourthTowerE; + } + + + const int &L1CaloCluster::Ring1E( ) const + { + return mRing1E; + } + + + const int &L1CaloCluster::Ring2E( ) const + { + return mRing2E; + } + + const int &L1CaloCluster::Ring3E( ) const + { + return mRing3E; + } + + const int &L1CaloCluster::Ring4E( ) const + { + return mRing4E; + } + + const bool & L1CaloCluster::fg( ) const + { + return mFg; + } + + const bool & L1CaloCluster::eGamma( ) const + { + return mEgamma; + } + + const bool & L1CaloCluster::hasLeadTower( ) const + { + return mLeadtowertau; + } + + + const int &L1CaloCluster::eGammaValue( ) const + { + return mEgammavalue; + } + + const bool & L1CaloCluster::isoEG( ) const + { + return mIsoeg; + } + + const bool & L1CaloCluster::isoTau( ) const + { + return mIsotau; + } + + const bool & L1CaloCluster::isCentral( ) const + { + return mCentral; + } + + const int &L1CaloCluster::isoClustersEG( ) const + { + return mIsoclusterseg; + } + + const int &L1CaloCluster::isoClustersTau( ) const + { + return mIsoclusterstau; + } + + const int &L1CaloCluster::isoEnergyEG( ) const + { + return mIsoenergyeg; + } + + const int &L1CaloCluster::isoEnergyTau( ) const + { + return mIsoenergytau; + } + + const int &L1CaloCluster::isoEmEtEG( ) const + { + return mIsoEmEtEG; + } + + const int &L1CaloCluster::isoHadEtEG( ) const + { + return mIsoHadEtEG; + } + + bool L1CaloCluster::isEGamma( ) const + { + return ( !fg( ) && eGamma( ) && isCentral( ) ); + } + + bool L1CaloCluster::isIsoEGamma( ) const + { + return ( !fg( ) && eGamma( ) && isoEG( ) && isCentral( ) ); + } + + bool L1CaloCluster::isIsoTau( ) const + { + return hasLeadTower( ) && isoTau( ) && isCentral( ); + } + + bool L1CaloCluster::isTau( ) const + { + return hasLeadTower( ) && isCentral( ); + } + + + void L1CaloCluster::setEmEt( const int &E ) + { + mEmEt = E; + } + + void L1CaloCluster::setHadEt( const int &E ) + { + mHadEt = E; + } + + void L1CaloCluster::setLeadTowerE( const int &E ) + { + mLeadTowerE = E; + } + + void L1CaloCluster::setSecondTowerE( const int &E ) + { + mSecondTowerE = E; + } + + void L1CaloCluster::setThirdTowerE( const int &E ) + { + mThirdTowerE = E; + } + + void L1CaloCluster::setFourthTowerE( const int &E ) + { + mFourthTowerE = E; + } + + + void L1CaloCluster::setRing1E( const int &Ring1E ) + { + mRing1E = Ring1E; + } + + + void L1CaloCluster::setRing2E( const int &Ring2E ) + { + mRing2E = Ring2E; + } + + void L1CaloCluster::setRing3E( const int &Ring3E ) + { + mRing3E = Ring3E; + } + + void L1CaloCluster::setRing4E( const int &Ring4E ) + { + mRing4E = Ring4E; + } + + void L1CaloCluster::setConstituents( const L1CaloTowerRefVector & cons ) + { + mConstituents = cons; + } + + const L1CaloTowerRefVector & L1CaloCluster::getConstituents( ) const + { + return mConstituents; + } + + + void L1CaloCluster::setFg( const bool & fg ) + { + mFg = fg; + } + + + void L1CaloCluster::setEGamma( const bool & eg ) + { + mEgamma = eg; + } + + void L1CaloCluster::setLeadTower( const bool & eg ) + { + mLeadtowertau = eg; + } + + + void L1CaloCluster::setEGammaValue( const int &eg ) + { + mEgammavalue = eg; + } + + void L1CaloCluster::setIsoEG( const bool & eg ) + { + mIsoeg = eg; + } + + void L1CaloCluster::setIsoTau( const bool & eg ) + { + mIsotau = eg; + } + + void L1CaloCluster::setIsoClusters( const int &eg, const int &tau ) + { + mIsoclusterseg = eg; + mIsoclusterstau = tau; + } + + void L1CaloCluster::setIsoEnergy( const int &eg, const int &tau ) + { + mIsoenergyeg = eg; + mIsoenergytau = tau; + } + + void L1CaloCluster::setIsoEmAndHadEtEG(const int& isoEmEt,const int& isoHadEt) + { + mIsoEmEtEG = isoEmEt; + mIsoHadEtEG = isoHadEt; + } + void L1CaloCluster::setCentral( const bool & eg ) + { + mCentral = eg; + } + + void L1CaloCluster::setPosBits( const int &eta, const int &phi ) + { + mInnereta = eta; + mInnerphi = phi; + + } + + void L1CaloCluster::setLorentzVector( const math::PtEtaPhiMLorentzVector & v ) + { + mP4 = v; + } + + + void L1CaloCluster::addConstituent( const L1CaloTowerRef & tower ) + { + mEmEt += tower->E( ); + mHadEt += tower->H( ); + mConstituents.push_back( tower ); + } + + int L1CaloCluster::hasConstituent( const int &eta, const int &phi ) const + { + for ( unsigned int i = 0; i < mConstituents.size( ); ++i ) + { + L1CaloTowerRef tower = mConstituents.at( i ); + if ( tower->iEta( ) == L1TowerNav::getOffsetIEta(mIeta,eta) && tower->iPhi( ) == L1TowerNav::getOffsetIPhi(L1TowerNav::getOffsetIEta(mIeta,eta),mIphi,phi) ) //SHarper change: fix iEta -ve to +ve and iPhi 72->1 bug, warning need to check behavour when the offset eta is on a phi change boundary + { + return i; + } + } + return -1; + } + + + L1CaloTowerRef L1CaloCluster::getConstituent( const int &pos ) const + { + return mConstituents.at( pos ); + } + + + + void L1CaloCluster::removeConstituent( const int &eta, const int &phi ) + { + + int pos = hasConstituent( eta, phi ); + + if ( pos != -1 ) + { + mEmEt-=mConstituents.at( pos )->E( ); + mHadEt-=mConstituents.at( pos )->H( ); + mConstituents.erase( mConstituents.begin( ) + pos ); + } + } + + + + const math::PtEtaPhiMLorentzVector & L1CaloCluster::p4( ) const + { + return mP4; + } + +} + + +namespace std +{ + bool operator<( const l1slhc::L1CaloCluster & aLeft, const l1slhc::L1CaloCluster & aRight ) + { + if ( aLeft.EmEt() + aLeft.HadEt() == aRight.EmEt( ) + aRight.HadEt() ) + { + // for two objects with equal energy, favour the more central one + return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); + } + else + { + return ( aLeft.EmEt()+aLeft.HadEt() < aRight.EmEt() + aRight.HadEt() ); + } + } +} + + +// pretty print +std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1CaloCluster & aL1CaloCluster ) +{ + aStream << "L1CaloCluster" + << " iEta=" << aL1CaloCluster.iEta( ) + << " iPhi=" << aL1CaloCluster.iPhi( ) + << " E=" << aL1CaloCluster.EmEt( ) + aL1CaloCluster.HadEt( ) + << " eta=" << aL1CaloCluster.p4( ).eta( ) + << " phi=" << aL1CaloCluster.p4( ).phi( ) + << " pt=" << aL1CaloCluster.p4( ).pt( ) + << " egamma=" << aL1CaloCluster.eGammaValue( ) + << " central=" << aL1CaloCluster.isCentral( ) + << " fg=" << aL1CaloCluster.fg( ) + << "\n with constituents:\n"; + for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1CaloCluster.getConstituents( ).begin( ); i != aL1CaloCluster.getConstituents( ).end( ); ++i ) + aStream << " iEta=" << ( **i ).iEta( ) + << " iPhi=" << ( **i ).iPhi( ) + << " ET=" << ( **i ).E( ) + << "\n"; + return aStream; +} diff --git a/SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc b/SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc new file mode 100644 index 0000000000000..6c43df3044a21 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1CaloClusterWithSeed.cc @@ -0,0 +1,476 @@ +#include "SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h" +#include "SimDataFormats/SLHC/interface/L1TowerNav.h" + +#include + +#include + +namespace l1slhc +{ + + L1CaloClusterWithSeed::L1CaloClusterWithSeed( ): + mSeedThreshold(4), + mEmThreshold(2), + mHadThreshold(2), + mIeta( 0 ), + mIphi( 0 ), + mEmEt( 0 ), + mHadEt( 0 ), + mTrimmedPlus(false), + mTrimmedMinus(false), + mFg( false ), + mEgamma( false ), + mEgammavalue( 0 ), + mIsoeg( false ), + mIsoEmEtEG( 0 ), + mIsoHadEtEG( 0 ), + mInnereta( 0 ), + mInnerphi( 0 ), + mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ) + { + } + + L1CaloClusterWithSeed::L1CaloClusterWithSeed( const int &iEta, const int &iPhi ): + mSeedThreshold(2), + mEmThreshold(2), + mHadThreshold(2), + mIeta( iEta ), + mIphi( iPhi ), + mEmEt( 0 ), + mHadEt( 0 ), + mTrimmedPlus(false), + mTrimmedMinus(false), + mFg( false ), + mEgamma( false ), + mEgammavalue( 0 ), + mIsoeg( false ), + mIsoEmEtEG( 0 ), + mIsoHadEtEG( 0 ), + mInnereta( 0 ), + mInnerphi( 0 ), + mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ) + { + } + + L1CaloClusterWithSeed::L1CaloClusterWithSeed( const L1CaloTowerRef & seed, int seedThreshold, int emThreshold, int hadThreshold ): + mSeedTower(seed), + mSeedThreshold(seedThreshold), + mEmThreshold(emThreshold), + mHadThreshold(hadThreshold), + mIeta( seed->iEta() ), + mIphi( seed->iPhi() ), + mEmEt( seed->E() ), + mHadEt( (seed->H()>=hadThreshold ? seed->H() : 0.) ), + mTrimmedPlus(false), + mTrimmedMinus(false), + mFg( seed->EcalFG() ), + mEgamma( false ), + mEgammavalue( 0 ), + mIsoeg( false ), + mIsoEmEtEG( 0 ), + mIsoHadEtEG( 0 ), + mInnereta( 0 ), + mInnerphi( 0 ), + mP4( math::PtEtaPhiMLorentzVector( 0.001, 0, 0, 0. ) ) + { + if(seed->E()6 && fg( )) && eGamma( ) ); + } + + const bool & L1CaloClusterWithSeed::isoEG( ) const + { + return mIsoeg; + } + + const int &L1CaloClusterWithSeed::isoEmEtEG( ) const + { + return mIsoEmEtEG; + } + + const int &L1CaloClusterWithSeed::isoHadEtEG( ) const + { + return mIsoHadEtEG; + } + + bool L1CaloClusterWithSeed::isIsoEGamma( ) const + { + return ( !(seedEmEt()>6 && fg( )) && eGamma( ) && isoEG( ) ); + } + + void L1CaloClusterWithSeed::setEmEt( int E ) + { + mEmEt = E; + } + + void L1CaloClusterWithSeed::setHadEt( int H ) + { + mHadEt = H; + } + + void L1CaloClusterWithSeed::setTrimmedPlus( bool trimmed) + { + mTrimmedPlus = trimmed; + } + + void L1CaloClusterWithSeed::setTrimmedMinus( bool trimmed) + { + mTrimmedMinus = trimmed; + } + + + void L1CaloClusterWithSeed::setConstituents( const L1CaloTowerRefVector & cons ) + { + mConstituents = cons; + } + + const L1CaloTowerRefVector & L1CaloClusterWithSeed::getConstituents( ) const + { + return mConstituents; + } + + + void L1CaloClusterWithSeed::setFg( bool fg ) + { + mFg = fg; + } + + + void L1CaloClusterWithSeed::setEGamma( bool eg ) + { + mEgamma = eg; + } + + + void L1CaloClusterWithSeed::setEGammaValue( int eg ) + { + mEgammavalue = eg; + } + + void L1CaloClusterWithSeed::setIsoEG( const bool & eg ) + { + mIsoeg = eg; + } + + void L1CaloClusterWithSeed::setIsoEmAndHadEtEG(const int& isoEmEt,const int& isoHadEt) + { + mIsoEmEtEG = isoEmEt; + mIsoHadEtEG = isoHadEt; + } + + void L1CaloClusterWithSeed::setPosBits( int eta, int phi ) + { + mInnereta = eta; + mInnerphi = phi; + + } + + void L1CaloClusterWithSeed::setLorentzVector( const math::PtEtaPhiMLorentzVector & v ) + { + mP4 = v; + } + + + void L1CaloClusterWithSeed::addConstituent( const L1CaloTowerRef & tower ) + { + mEmEt += (tower->E()>=mEmThreshold ? tower->E( ) : 0); + mHadEt += (tower->H()>=mHadThreshold ? tower->H( ) : 0); + mConstituents.push_back( tower ); + mConstituentSharing.push_back(0); + } + + // Friend towers are not included in the cluster. But may be included in later steps of clustering. + void L1CaloClusterWithSeed::addFriend( const L1CaloTowerRef & tower ) + { + mFriends.push_back( tower ); + } + + int L1CaloClusterWithSeed::hasConstituent( int eta, int phi ) const + { + for ( unsigned int i = 0; i < mConstituents.size( ); ++i ) + { + L1CaloTowerRef tower = mConstituents.at( i ); + //std::cout<<"ieta="<iEta()<<"("<iEta( ) == mIeta + eta && tower->iPhi( ) == mIphi + phi ) + if ( tower->iEta( ) == L1TowerNav::getOffsetIEta(mIeta,eta) && tower->iPhi( ) == L1TowerNav::getOffsetIPhi(L1TowerNav::getOffsetIEta(mIeta,eta),mIphi,phi) ) //SHarper change: fix iEta -ve to +ve and iPhi 72->1 bug, warning need to check behavour when the offset eta is on a phi change boundary + { + return i; + } + } + return -1; + } + + int L1CaloClusterWithSeed::hasFriend( int eta, int phi ) + { + for ( unsigned int i = 0; i < mFriends.size( ); ++i ) + { + L1CaloTowerRef tower = mFriends.at( i ); + //if ( tower->iEta( ) == mIeta + eta && tower->iPhi( ) == mIphi + phi ) + if ( tower->iEta( ) == L1TowerNav::getOffsetIEta(mIeta,eta) && tower->iPhi( ) == L1TowerNav::getOffsetIPhi(L1TowerNav::getOffsetIEta(mIeta,eta),mIphi,phi) ) //SHarper change: fix iEta -ve to +ve and iPhi 72->1 bug, warning need to check behavour when the offset eta is on a phi change boundary + { + return i; + } + } + return -1; + } + + L1CaloTowerRef L1CaloClusterWithSeed::getSeedTower() const + { + return mSeedTower; + } + + L1CaloTowerRef L1CaloClusterWithSeed::getConstituent( int pos ) + { + return mConstituents.at( pos ); + } + + L1CaloTowerRef L1CaloClusterWithSeed::getFriend( int pos ) + { + return mFriends.at( pos ); + } + + + + void L1CaloClusterWithSeed::removeConstituent( int eta, int phi ) + { + + int pos = hasConstituent( eta, phi ); + + if ( pos != -1 ) + { + mEmEt -= constituentEmEt( eta, phi ); + mHadEt -= constituentHadEt( eta, phi ); + mConstituents.erase( mConstituents.begin( ) + pos ); + mConstituentSharing.erase( mConstituentSharing.begin( ) + pos ); + } + } + + void L1CaloClusterWithSeed::removeFriend( int eta, int phi ) + { + + int pos = hasFriend( eta, phi ); + + if ( pos != -1 ) + { + mFriends.erase( mFriends.begin( ) + pos ); + } + } + + + int L1CaloClusterWithSeed::seedEmEt() const + { + return (mSeedTower->E()>=mSeedThreshold ? mSeedTower->E() : 0); + } + + int L1CaloClusterWithSeed::seedHadEt() const + { + return (mSeedTower->H()>=mHadThreshold ? mSeedTower->H() : 0.); + } + + int L1CaloClusterWithSeed::constituentEmEt(int eta, int phi) const + { + int pos = hasConstituent( eta, phi ); + + int lConstituentE = 0; + if ( pos != -1 ) + { + lConstituentE = (mConstituents[pos]->E()>=mEmThreshold ? mConstituents[pos]->E() : 0); + int lSharing = mConstituentSharing[pos]; + switch(lSharing) + { + case 1: + lConstituentE = lConstituentE - lConstituentE/4; + break; + case 2: + lConstituentE = lConstituentE - lConstituentE/2; + break; + case 3: + lConstituentE = lConstituentE/2; + break; + case 4: + lConstituentE = lConstituentE/4; + break; + case 5: + lConstituentE = 0; + break; + default: + break; + }; + } + return lConstituentE; + } + + int L1CaloClusterWithSeed::constituentHadEt(int eta, int phi) const + { + int pos = hasConstituent( eta, phi ); + + int lConstituentH = 0; + if ( pos != -1 ) + { + lConstituentH = (mConstituents[pos]->H()>=mHadThreshold ? mConstituents[pos]->H() : 0); + int lSharing = mConstituentSharing[pos]; + switch(lSharing) + { + case 1: + lConstituentH = lConstituentH - lConstituentH/4; + break; + case 2: + lConstituentH = lConstituentH - lConstituentH/2; + break; + case 3: + lConstituentH = lConstituentH/2; + break; + case 4: + lConstituentH = lConstituentH/4; + break; + case 5: + lConstituentH = 0; + break; + default: + break; + }; + } + return lConstituentH; + } + + void L1CaloClusterWithSeed::shareConstituent(int eta, int phi, int sharing) + { + int pos = hasConstituent( eta, phi ); + if ( pos != -1 ) + { + int cEold = constituentEmEt(eta,phi); + int cHold = constituentHadEt(eta,phi); + mConstituentSharing[pos] = sharing; + int cEnew = constituentEmEt(eta, phi); + int cHnew = constituentHadEt(eta, phi); + mEmEt = mEmEt - cEold + cEnew; + mHadEt = mHadEt - cHold + cHnew; + } + } + + + const math::PtEtaPhiMLorentzVector & L1CaloClusterWithSeed::p4( ) const + { + return mP4; + } + +} + + +namespace std +{ + bool operator<( const l1slhc::L1CaloClusterWithSeed & aLeft, const l1slhc::L1CaloClusterWithSeed & aRight ) + { + if ( aLeft.EmEt()+aLeft.HadEt() == aRight.EmEt()+aRight.HadEt() ) + { + // for two objects with equal energy, favour the more central one + return ( abs( aLeft.iEta() ) > abs( aRight.iEta() ) ); + } + else + { + return ( aLeft.EmEt()+aLeft.HadEt() < aRight.EmEt()+aRight.HadEt() ); + } + } +} + + +// pretty print +std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1CaloClusterWithSeed & aL1CaloClusterWithSeed ) +{ + aStream << "L1CaloClusterWithSeed" + << " iEta=" << aL1CaloClusterWithSeed.iEta( ) + << " iPhi=" << aL1CaloClusterWithSeed.iPhi( ) + << " E=" << aL1CaloClusterWithSeed.EmEt( ) + << " H=" << aL1CaloClusterWithSeed.HadEt( ) + << " eta=" << aL1CaloClusterWithSeed.p4( ).eta( ) + << " phi=" << aL1CaloClusterWithSeed.p4( ).phi( ) + << " pt=" << aL1CaloClusterWithSeed.p4( ).pt( ) + << " egamma=" << aL1CaloClusterWithSeed.eGammaValue( ) + << " fg=" << aL1CaloClusterWithSeed.fg( ) + << "\n with constituents:\n"; + for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1CaloClusterWithSeed.getConstituents( ).begin( ); i != aL1CaloClusterWithSeed.getConstituents( ).end( ); ++i ) + aStream << " iEta=" << ( **i ).iEta( ) + << " iPhi=" << ( **i ).iPhi( ) + << " ET=" << ( **i ).E( ) + << "\n"; + return aStream; +} diff --git a/SimDataFormats/SLHC/src/L1CaloJet.cc b/SimDataFormats/SLHC/src/L1CaloJet.cc new file mode 100644 index 0000000000000..fa50851e57845 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1CaloJet.cc @@ -0,0 +1,148 @@ +#include "SimDataFormats/SLHC/interface/L1CaloJet.h" +#include + +namespace l1slhc +{ + + L1CaloJet::L1CaloJet( ): + mIeta( 0 ), + mIphi( 0 ), + mE( 0 ), + mCentral( true ) + { + } + + + + L1CaloJet::L1CaloJet( const int &iEta, const int &iPhi ): + mIeta( iEta ), + mIphi( iPhi ), + mE( 0 ), + mCentral( true ) + { + } + + L1CaloJet::~L1CaloJet( ) + { + + + } + + void L1CaloJet::setP4( const math::PtEtaPhiMLorentzVector & p4 ) + { + mP4 = p4; + } + + void L1CaloJet::setCentral( const bool & central ) + { + mCentral = central; + } + + + const int &L1CaloJet::iEta( ) const + { + return mIeta; + } + + + const int &L1CaloJet::iPhi( ) const + { + return mIphi; + } + + + const int &L1CaloJet::E( ) const + { + return mE; + } + + const bool & L1CaloJet::central( ) const + { + return mCentral; + } + + + + void L1CaloJet::setE( const int &E ) + { + mE = E; + } + + const math::PtEtaPhiMLorentzVector & L1CaloJet::p4( ) const + { + return mP4; + } + + + void L1CaloJet::addConstituent( const L1CaloRegionRef & region ) + { + mE += region->E( ); + mConstituents.push_back( region ); + } + + const L1CaloRegionRefVector & L1CaloJet::getConstituents( ) const + { + return mConstituents; + } + + int L1CaloJet::hasConstituent( const int &eta, const int &phi ) + { + int pos = -1; + for ( unsigned int i = 0; i < mConstituents.size( ); ++i ) + { + L1CaloRegionRef tower = mConstituents.at( i ); + if ( tower->iEta( ) == eta + mIeta && tower->iPhi( ) == phi + mIphi ) + { + pos = i; + break; + } + } + + return pos; + } + + void L1CaloJet::removeConstituent( const int &eta, const int &phi ) + { + int pos = hasConstituent( eta, phi ); + if ( pos != -1 ) + { + mE = mE - mConstituents.at( pos )->E( ); + mConstituents.erase( mConstituents.begin( ) + pos ); + } + } +} + + + + +namespace std +{ + bool operator<( const l1slhc::L1CaloJet & aLeft, const l1slhc::L1CaloJet & aRight ) + { + if ( aLeft.E( ) == aRight.E( ) ) + { + // for two objects with equal energy, favour the more central one + return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); + } + else + { + return ( aLeft.E( ) < aRight.E( ) ); + } + } +} + + +// pretty print +std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1CaloJet & aL1CaloJet ) +{ + aStream << "L1CaloJet" + << " iEta=" << aL1CaloJet.iEta( ) + << " iPhi=" << aL1CaloJet.iPhi( ) + << "\n with constituents:\n"; + for ( l1slhc::L1CaloRegionRefVector::const_iterator i = aL1CaloJet.getConstituents( ).begin( ); i < aL1CaloJet.getConstituents( ).end( ); ++i ) + aStream << " iEta=" << ( **i ).iEta( ) + << " iPhi=" << ( **i ).iPhi( ) + << " ET=" << ( **i ).E( ) + << "\n"; + return aStream; +} diff --git a/SimDataFormats/SLHC/src/L1CaloRegion.cc b/SimDataFormats/SLHC/src/L1CaloRegion.cc new file mode 100644 index 0000000000000..177d54bebad97 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1CaloRegion.cc @@ -0,0 +1,58 @@ +#include "SimDataFormats/SLHC/interface/L1CaloRegion.h" + +#include + + +namespace l1slhc +{ + + L1CaloRegion::L1CaloRegion( ):mIeta( 0 ), + mIphi( 0 ), + mE( 0 ) + { + } + + L1CaloRegion::L1CaloRegion( const int &iEta, const int &iPhi, const int &E ):mIeta( iEta ), + mIphi( iPhi ), + mE( E ) + { + } + + + L1CaloRegion::~L1CaloRegion( ) + { + } + + const int &L1CaloRegion::iEta( ) const + { + return mIeta; + } + + const int &L1CaloRegion::iPhi( ) const + { + return mIphi; + } + + const int &L1CaloRegion::E( ) const + { + return mE; + } + +} + + +namespace std +{ + bool operator<( const l1slhc::L1CaloRegion & aLeft, const l1slhc::L1CaloRegion & aRight ) + { + if ( aLeft.E( ) == aRight.E( ) ) + { + // for two objects with equal energy, favour the more central one + return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); + } + else + { + return ( aLeft.E( ) < aRight.E( ) ); + } + } +} diff --git a/SimDataFormats/SLHC/src/L1CaloTower.cc b/SimDataFormats/SLHC/src/L1CaloTower.cc new file mode 100644 index 0000000000000..9650f2d585bb7 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1CaloTower.cc @@ -0,0 +1,109 @@ +#include "SimDataFormats/SLHC/interface/L1CaloTower.h" + +#include + +namespace l1slhc +{ + + L1CaloTower::L1CaloTower( ): + mEcal( 0 ), + mHcal( 0 ), + mIeta( 0 ), + mIphi( 0 ), + mEcalFG( false ), + mHcalFG( false ) + { + } + + L1CaloTower::L1CaloTower( const int &aIeta, const int &aIphi ):mEcal( 0 ), + mHcal( 0 ), + mIeta( aIeta ), + mIphi( aIphi ), + mEcalFG( false ), + mHcalFG( false ) + { + } + + L1CaloTower::~L1CaloTower( ) + { + } + + + void L1CaloTower::setPos( const int &aIeta, const int &aIphi ) + { + mIeta = aIeta; + mIphi = aIphi; + } + + + /* + void L1CaloTower::setParams( const int& aEcal, const int& aHcal, const bool& aFG ) { mEcal = aEcal; mHcal = aHcal; mEcalFG = aFG; } */ + + + void L1CaloTower::setEcal( const int &aEcal, const bool & aFG ) + { + mEcal = aEcal; + mEcalFG = aFG; + } + + void L1CaloTower::setHcal( const int &aHcal, const bool & aFG ) + { + mHcal = aHcal; + mHcalFG = aFG; + } + + + + + const int &L1CaloTower::E( ) const + { + return mEcal; + } + + const int &L1CaloTower::H( ) const + { + return mHcal; + } + + + const int &L1CaloTower::iEta( ) const + { + return mIeta; + } + + const int &L1CaloTower::iPhi( ) const + { + return mIphi; + } + + const bool & L1CaloTower::EcalFG( ) const + { + return mEcalFG; + } + + const bool & L1CaloTower::HcalFG( ) const + { + return mHcalFG; + } + +} + +namespace std +{ + bool operator<( const l1slhc::L1CaloTower & aLeft, const l1slhc::L1CaloTower & aRight ) + { + int lLeftE = aLeft.E( ) + aLeft.H( ); + int lRightE = aRight.E( ) + aRight.H( ); + + if ( lLeftE == lRightE ) + { + // for two objects with equal energy, favour the more central one + return ( abs( aLeft.iEta( ) ) > abs( aRight.iEta( ) ) ); + } + else + { + return ( lLeftE < lRightE ); + } + + } +} diff --git a/SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc b/SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc new file mode 100644 index 0000000000000..bbb7b86320264 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1CaloTriggerSetupRcd.cc @@ -0,0 +1,4 @@ +#include "SimDataFormats/SLHC/interface/L1CaloTriggerSetupRcd.h" +#include "FWCore/Framework/interface/eventsetuprecord_registration_macro.h" + +EVENTSETUP_RECORD_REG( L1CaloTriggerSetupRcd ); diff --git a/SimDataFormats/SLHC/src/L1TkCluster.cc b/SimDataFormats/SLHC/src/L1TkCluster.cc new file mode 100644 index 0000000000000..e7029e3a27ab0 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1TkCluster.cc @@ -0,0 +1,48 @@ +/// //////////////////////////////////////// +/// Stacked Tracker Simulations /// +/// /// +/// Nicola Pozzobon, UNIPD /// +/// Emmanuele Salvati, Cornell /// +/// /// +/// 2011, June /// +/// 2011, October /// +/// 2013, January /// +/// //////////////////////////////////////// + +#include "SimDataFormats/SLHC/interface/L1TkCluster.h" + + /** ***************************** **/ + /** **/ + /** IMPLEMENTATION OF METHODS **/ + /** **/ + /** ***************************** **/ + + /// Get cluster width + /// Default template for PixelDigis in *.h + /// Specialize the template for PSimHits + template<> + unsigned int L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findWidth() const + { + return theHits.size(); + } + + /// Get hit local coordinates + /// Default template for PixelDigis in *.h + /// Specialize the template for PSimHits + template<> + MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findHitLocalCoordinates( unsigned int hitIdx ) const + { + MeasurementPoint mp( 0, 0 ); /// Dummy values + return mp; + } + + /// Unweighted average local cluster coordinates + /// Default template for PixelDigis in *.h + /// Specialize the template for PSimHits + template<> + MeasurementPoint L1TkCluster< edm::Ref< edm::PSimHitContainer > >::findAverageLocalCoordinates() const + { + MeasurementPoint mp( 0, 0 ); /// Dummy values + return mp; + } + diff --git a/SimDataFormats/SLHC/src/L1TkStub.cc b/SimDataFormats/SLHC/src/L1TkStub.cc new file mode 100644 index 0000000000000..806a8aca14ebc --- /dev/null +++ b/SimDataFormats/SLHC/src/L1TkStub.cc @@ -0,0 +1,27 @@ +/// //////////////////////////////////////// +/// Stacked Tracker Simulations /// +/// Written by: /// +/// Andrew W. Rose /// +/// 2008 /// +/// /// +/// Modified by: /// +/// Nicola Pozzobon /// +/// UNIPD /// +/// July 2011 /// +/// /// +/// Added features: /// +/// Newer naming scheme and unification /// +/// of LocalStub and GlobalStub /// +/// //////////////////////////////////////// + +#include "SimDataFormats/SLHC/interface/L1TkStub.h" + +namespace cmsUpgrades { + + /// ////////////// /// + /// HELPER METHODS /// + /// ////////////// /// + + +} /// Close namespace + diff --git a/SimDataFormats/SLHC/src/L1TkTrack.cc b/SimDataFormats/SLHC/src/L1TkTrack.cc new file mode 100644 index 0000000000000..067fb92f7b1eb --- /dev/null +++ b/SimDataFormats/SLHC/src/L1TkTrack.cc @@ -0,0 +1,19 @@ +/// //////////////////////////////////////// +/// Stacked Tracker Simulations /// +/// Written by: /// +/// Nicola Pozzobon /// +/// UNIPD /// +/// 2011, Oct /// +/// /// +/// //////////////////////////////////////// + +#include "SimDataFormats/SLHC/interface/L1TkTrack.h" + +namespace cmsUpgrades { + + /// ////////////// /// + /// HELPER METHODS /// + /// ////////////// /// + +} /// Close namespace + diff --git a/SimDataFormats/SLHC/src/L1TowerJet.cc b/SimDataFormats/SLHC/src/L1TowerJet.cc new file mode 100644 index 0000000000000..e8d5e58f2bdb8 --- /dev/null +++ b/SimDataFormats/SLHC/src/L1TowerJet.cc @@ -0,0 +1,1014 @@ +#include "SimDataFormats/SLHC/interface/L1TowerJet.h" +#include + + +namespace l1slhc +{ + + // Initialising the static tower geometry member variable + TriggerTowerGeometry L1TowerJet::mTowerGeo = TriggerTowerGeometry(); + + const double L1TowerJet::PI = 3.14159265359; + + + L1TowerJet::L1TowerJet( ): + mIeta( 0 ), + mIphi( 0 ), + + mE2GeV( 0 ), + mE( 0 ), + mCentral( true ), + mAsymEta(0), + mAsymPhi(0), + /* mWeightedIeta( 0 ), + mWeightedIphi( 0 ),*/ + mJetCenterEta( 0 ), + mJetCenterPhi( 0 ), + + mJetSize( 12 ), + mJetShapeType( square ), + mJetArea( 144 ), + mJetRealArea( mJetArea * 0.087 * 0.087 ) + { + } + + L1TowerJet::L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , const int& aJetArea ): + + mIeta( 0 ), + mIphi( 0 ), + + mE2GeV( 0 ), + mE( 0 ), + mCentral( true ), + mAsymEta(0), + mAsymPhi(0), + /* mWeightedIeta( 0 ), + mWeightedIphi( 0 ),*/ + mJetCenterEta( 0 ), + mJetCenterPhi( 0 ), + + mJetSize( aJetSize ), + mJetShapeType( aJetShapeType ), + mJetArea( aJetArea ), + mJetRealArea( mJetArea * 0.087 * 0.087 ) + { // The above mJetRealArea calculation assumes the towers in the jet all occupy the region |eta| < 1.74 + } + + + L1TowerJet::L1TowerJet( const int& aJetSize, const L1TowerJet::tJetShape& aJetShapeType , + const std::vector< std::pair< int, int > >& aJetShapeMap, const int &iEta, const int &iPhi ): + + mIeta( iEta ), + mIphi( iPhi ), + + mE2GeV( 0 ), + mE( 0 ), + mCentral( true ), + mAsymEta(0), + mAsymPhi(0), + /* mWeightedIeta( 0 ), + mWeightedIphi( 0 ),*/ + mJetCenterEta( 0 ), + mJetCenterPhi( 0 ), + + mJetSize( aJetSize ), + mJetShapeType( aJetShapeType ), + mJetArea( aJetShapeMap.size() ), + mJetRealArea( 0 ) + { + + // ************************************************** + // * Calculate the real jet area * + // ************************************************** + + // Check if jet fully contained within |eta| < 1.74, in which case all TTs have the same area + if ( (iEta + mJetSize < 22) && (iEta > -21) ){ + + // real jet area = Number of TTs * deltaPhi * deltaEta + mJetRealArea = mJetArea * 0.087 * 0.087; + } + else{ + + // calculate the real jet area, accounting for the change in trigger tower eta width + for ( std::vector< std::pair< int , int > >::const_iterator lJetShapeMapIt = aJetShapeMap.begin() ; + lJetShapeMapIt != aJetShapeMap.end() ; ++lJetShapeMapIt ){ + + // Get the iEta of the TT + int TTiEta = iEta + lJetShapeMapIt->first; + double TTarea = mTowerGeo.towerEtaSize( TTiEta ) * 0.087; + mJetRealArea += TTarea; + + + // Calculate the geometric center of the jet + //calculateJetCenter(); + + } + + } + + } + + L1TowerJet::~L1TowerJet( ) + { + } + + + + // ******************************************************************************** + // * Setters * + // ******************************************************************************** + + void L1TowerJet::setP4( const math::PtEtaPhiMLorentzVector & p4 ) + { + mP4 = p4; + } + + void L1TowerJet::setPt( const double & pT ) + { + mP4.SetPt(pT); + } + + + void L1TowerJet::setCentral( const bool & central ) + { + mCentral = central; + } + + + // ******************************************************************************** + // * Getters * + // ******************************************************************************** + + // iEta, eta of the top-left TT indexing the tower jet + const int &L1TowerJet::iEta( ) const + { + return mIeta; + } + + // iPhi, phi of the top-left TT indexing the tower jet + const int &L1TowerJet::iPhi( ) const + { + return mIphi; + } + + // Return Pt of jet + const double L1TowerJet::Pt( ) const + { + return mP4.Pt(); + } + + // Eta of tower jet geometric center + const double L1TowerJet::Eta( ) const + { + return mJetCenterEta; + } + + // Phi of tower jet geometric center + const double L1TowerJet::Phi( ) const + { + return mJetCenterPhi; + } + + // Energy weighted eta + const double L1TowerJet::WeightedEta( ) const + { + // The weighted eta information is stored within the four-vector + return mP4.Eta(); + // return mWeightedEta; + } + + // Energy weighted phi + const double L1TowerJet::WeightedPhi( ) const + { + // The weighted phi information is stored within the four-vector + return mP4.Phi(); + // return mWeightedPhi; + } + + // Total TT energy enclosed by tower jet in GeV (Corrected to account for energy being stored in multiples of 2 GeV) + const double &L1TowerJet::E( ) const + { // True value in GeV + return mE; + } + + const double &L1TowerJet::Centrality( ) const + { + return mCentrality; + } + + const int& L1TowerJet::AsymEta( ) const + { + return mAsymEta; + } + + const int& L1TowerJet::AsymPhi( ) const + { + return mAsymPhi; + } + + const bool & L1TowerJet::central( ) const + { + return mCentral; + } + + const math::PtEtaPhiMLorentzVector & L1TowerJet::p4( ) const + { + return mP4; + } + + // The jet diameter in TTs + const int& L1TowerJet::JetSize( ) const + { + return mJetSize; + } + + const L1TowerJet::tJetShape& L1TowerJet::JetShape( ) const + { + return mJetShapeType; + } + + // The area of the jet in TTs + const int& L1TowerJet::JetArea( ) const + { + return mJetArea; + } + + // The true eta*phi area of the jet + const double& L1TowerJet::JetRealArea( ) const + { + return mJetRealArea; + } + + /* + double L1TowerJet::EcalVariance( ) const + { + double lMean(0.0); + double lMeanSq(0.0); + + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + lMean += (**lConstituentIt).E(); + lMeanSq += ((**lConstituentIt).E() * (**lConstituentIt).E()); + } + + lMean /= mConstituents.size(); + lMeanSq /= mConstituents.size(); + + return lMeanSq - (lMean*lMean); + } + + + double L1TowerJet::HcalVariance( ) const + { + double lMean(0.0); + double lMeanSq(0.0); + + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + lMean += (**lConstituentIt).H(); + lMeanSq += ((**lConstituentIt).H() * (**lConstituentIt).H()); + } + + lMean /= mConstituents.size(); + lMeanSq /= mConstituents.size(); + + return lMeanSq - (lMean*lMean); + } + + + double L1TowerJet::EnergyVariance( ) const + { + double lMean( double(mE) / double(mConstituents.size()) ); + double lMeanSq(0.0); + + double lTower; + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + lTower = (**lConstituentIt).E() + (**lConstituentIt).H(); + lMeanSq += ( lTower * lTower ); + } + + lMeanSq /= mConstituents.size(); + + return lMeanSq - (lMean*lMean); + } + */ + + + // ******************************************************************************** + // * Median absolute deviations * + // ******************************************************************************** + + double L1TowerJet::EcalMAD() const + { + std::deque< int > lEnergy; + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + lEnergy.push_back( (**lConstituentIt).E() ); + } + lEnergy.resize( mJetArea , 0 ); + return MAD( lEnergy ); + + } + + double L1TowerJet::HcalMAD() const + { + std::deque< int > lEnergy; + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + lEnergy.push_back( (**lConstituentIt).H() ); + } + lEnergy.resize( mJetArea , 0 ); + return MAD( lEnergy ); + + } + + + + double L1TowerJet::EnergyMAD() const + { + std::deque< int > lEnergy; + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + lEnergy.push_back( (**lConstituentIt).E() + (**lConstituentIt).H() ); + } + lEnergy.resize( mJetArea , 0 ); + return MAD( lEnergy ); + } + + + + double L1TowerJet::MAD( std::deque& aDataSet ) const + { + std::sort( aDataSet.begin() , aDataSet.end() ); + + std::size_t lDataSetSize( aDataSet.size() ); + + double lMedian(0); + if( (lDataSetSize % 2) == 0 ){ + lMedian = double( aDataSet[ (lDataSetSize/2) - 1 ] + aDataSet[ lDataSetSize/2 ] ) / 2.0 ; + }else{ + lMedian = double( aDataSet[ (lDataSetSize-1)/2 ] ); + } + + + std::deque< double > lMedianSubtractedDataSet; + for ( std::deque< int >::const_iterator lIt = aDataSet.begin() ; lIt != aDataSet.end(); ++lIt ){ + lMedianSubtractedDataSet.push_back( fabs( double(*lIt) - lMedian ) ); + } + + std::sort( lMedianSubtractedDataSet.begin() , lMedianSubtractedDataSet.end() ); + + if( (lDataSetSize % 2) == 0 ){ + return double ( lMedianSubtractedDataSet[ (lDataSetSize/2) - 1 ] + lMedianSubtractedDataSet[ lDataSetSize/2 ] ) / 2.0 ; + }else{ + return double( lMedianSubtractedDataSet[ (lDataSetSize-1)/2 ] ); + } + + } + + + + + // ******************************************************************************** + // * Jet eta and phi variables * + // ******************************************************************************** + + + + + + + // ********************************************************************** + // * Jet iEta and iPhi variables * + // ********************************************************************** + + + + // ~ Why is this not following the getter naming convention? ~ + // ~ Weighted iEta assumes all trigger towers have the same width, the result will be different from ~ + // ~ discretising the weighted Eta. ~ + /* + void L1TowerJet::CalcWeightediEta() + { + double etaSumEt(0); + double sumEt (0); + + for ( L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ){ + etaSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * ( (**lConstituentIt).iEta() ); + sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; + } + // std::cout<<" eta* energy = "<=0 ) discrete_iEta=int(mWeightedIeta+0.5); + else discrete_iEta=int(mWeightedIeta-0.5); + + //account for the fact there is no 0 + if(mWeightedIeta>=0 && mWeightedIeta<1) discrete_iEta=1; + + if(mWeightedIeta<0 && mWeightedIeta>(-1)) discrete_iEta=-1; + + //std::cout<<"weighted ieta: "<= (72-JetSize()) ) { //constituents may go over edge, iPhi>66 for 8x8 jet + if( tower_iPhi < (72 - JetSize()) ){//if constituent tower is over edge, ie. iPhi>1 + tower_iPhi+=72; //iPhi=1 -> iPhi=73 + } + } + //calculate weighted phi using corrected iPhi value + phiSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * (tower_iPhi ); + + sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; + } + // std::cout<<"phi sum et: "<72) mWeightedIphi-=72; + + + } + */ + + + + + // ********************************************************************** + // * Jet eta and phi variables * + // ********************************************************************** + + + // Calculate the eta and phi of the geometric center of the jet + void L1TowerJet::calculateJetCenter(){ + + // determine the lowest and highest TTs enclosed by the jet shape (assumes square bounding box) + int lowIeta = mIeta; + int lowIphi = mIphi; + int highIeta = lowIeta + (mJetSize - 1); + int highIphi = lowIphi + (mJetSize - 1); + + // Extract the true eta of these TTs + double lowEta = mTowerGeo.eta(lowIeta); + double lowPhi = mTowerGeo.phi(lowIphi); + double highEta = mTowerGeo.eta(highIeta); + double highPhi = mTowerGeo.phi(highIphi); + + // Correct for phi wrap around, if jet map exceeds phi calorimeter range + if ( (lowIphi + (mJetSize - 1) ) > 72 ){ + + // Current tower has wrapped around + if ( highIphi < lowIphi ){ + highPhi += 2*PI; + } + + } + + // Determine the geometric jet center + mJetCenterEta = (highEta + lowEta)/2.0; + mJetCenterPhi = (highPhi + lowPhi)/2.0; + + // Constrain jets to the range [-Pi,Pi] + if (mJetCenterPhi > PI) + mJetCenterPhi -= 2*PI; + + + } + + + + // Calculate the energy weighted eta and phi center of the jet. + // Defined: Sum ( TT_Eta * TT_Et ) / Sum ( TT_Et ), etc + void L1TowerJet::calculateWeightedJetCenter() + { + + // Eta, phi and Et of the TT + double ttEta(0), ttPhi(0), ttEt(0); + // Sums of eta*Et phi*Et and Et + double etaEtSum(0), phiEtSum(0), etSum(0); + + // Iterate through the TTs in the jet map + for (L1CaloTowerRefVector::const_iterator lTT = mConstituents.begin() ; lTT != mConstituents.end(); ++lTT ) { + + // Extract the eta, phi and Et of the TT + ttEta = mTowerGeo.eta( (**lTT).iEta() ); + ttPhi = mTowerGeo.phi( (**lTT).iPhi() ); + ttEt = 0.5*((**lTT).E() + (**lTT).H()); + + + // Correct for phi wrap around, if jet map exceeds phi calorimeter range + if ( (mIphi + (mJetSize - 1) ) > 72 ){ + + // Current tower has wrapped around + if ( (**lTT).iPhi() < mIphi ){ + ttPhi += 2*PI; + } + + } + + // Calculate the weighted eta, weighted phi and Et sums + etaEtSum += ttEta*ttEt; + phiEtSum += ttPhi*ttEt; + etSum += ttEt; + + } + + // Calculate the weighted eta and phi + + double lWeightedEta = etaEtSum/etSum; + double lWeightedPhi = phiEtSum/etSum; + + // Restrict phi to [-pi,pi] range + if(lWeightedPhi > PI){ + lWeightedPhi -= 2*PI; + } + + // Store the weighted eta and phi + mP4.SetEta(lWeightedEta); + mP4.SetPhi(lWeightedPhi); + + + } + + + + + + + // Calculate the energy weighted eta and phi center of the jet. + // Defined: Sum ( TT_Eta * TT_Et ) / Sum ( TT_Et ), etc + void L1TowerJet::calculateCentrality() + { + + + + // ******************************************************************** + // * Calculate the centrality parameter * + // ******************************************************************** + // + // Measure of the deltaR between the jet window centre and the centre of energy + // of the constituent energy deposits. + // + // Definition: + // ~~~~~~~~~~ + // + + // Eta, phi and Et of the TT and delta eta, phi and R between the jet centre and the constituent energy deposit + double ttEta(0), ttPhi(0), ttEt(0), deltaEta(0), deltaPhi(0), deltaR(0); + // Sums of deltaR*Et and Et + double deltaREtSum(0), etSum(0); + // Jet mask center (eta, phi) + double jetCenterPhi = Phi(); + double jetCenterEta = Eta(); + int jetCenteriPhi = (mIphi + mJetSize/2); + + // Correct for the jet mask center wrap around + if (jetCenteriPhi > 72){ + jetCenterPhi += 2*PI; + } + + + // Iterate through the TTs in the jet map + for (L1CaloTowerRefVector::const_iterator lTT = mConstituents.begin() ; lTT != mConstituents.end(); ++lTT ) { + + // Extract the eta, phi and Et of the TT + ttEta = mTowerGeo.eta( (**lTT).iEta() ); + ttPhi = mTowerGeo.phi( (**lTT).iPhi() ); + ttEt = 0.5*((**lTT).E() + (**lTT).H()); + + // Correct for phi wrap around, if jet map exceeds phi calorimeter range + if ( (mIphi + (mJetSize - 1) ) > 72 ){ + + // Current tower has wrapped around + if ( (**lTT).iPhi() < mIphi ){ + ttPhi += 2*PI; + } + + } + + // Unwrap the [-Pi,Pi] range + if (jetCenterPhi < 0) + jetCenterPhi += 2*PI; + + + // Calculate deltaR between energy deposit and jet centre + deltaEta = jetCenterEta - ttEta; + deltaPhi = jetCenterPhi - ttPhi; + deltaR = sqrt( deltaEta*deltaEta + deltaPhi*deltaPhi ); + + // Calculate the weighted deltaR*Et and Et sums + deltaREtSum += deltaR*ttEt; + etSum += ttEt; + + /* + // DEBUGGING Eta = 0, Phi = 0 + std::cout << "----------------------------------------------------------\n" + << "JET : iEta = " << mIeta + mJetSize/2 << "\tiPhi = " << jetCenteriPhi << "\tEta = " << jetCenterEta << "\tPhi = " << jetCenterPhi << "\n" + << "TT : iEta = " << (**lTT).iEta() << "\tiPhi = " << (**lTT).iPhi()<< "\tEta = " << ttEta << "\tPhi = " << ttPhi << "\tE = " + << ttEt << "\n" + << "DeltaEta = " << deltaEta << "\tDeltaPhi = " << deltaPhi << "\tRi = " << sqrt(deltaEta*deltaEta + deltaPhi*deltaPhi)<< "\n"; + */ + + } + + + + // Calculate the centrality of the jet energy deposits + mCentrality = deltaREtSum/etSum; + // std::cout << "Centrality = " << mCentrality << "\n==========================================================\n\n"; + + } + + + + + // + // Below code is incorrrect. Should keep the calculation in eta and phi space and then transform to + // i-eta and i-phi space to avoid discretisation issues and changing eta widths of TTs. + + // -------------------------------------------------- + // modified version to calculate weighted eta by first converting iEta to eta, than weighting + /* + void L1TowerJet::calculateWeightedEta() + { + + const double endcapEta[8] = { 0.09, 0.1, 0.113, 0.129, 0.15, 0.178, 0.15, 0.35 }; + + double etaSumEt(0); + double sumEt(0); + + double tmpEta(9999); + double abs_eta(9999); + + for (L1CaloTowerRefVector::const_iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ) { + + abs_eta = fabs((**lConstituentIt).iEta()); + if (abs_eta < 21) tmpEta = (0.087*abs_eta - 0.0435); + else { + abs_eta -= 21; + tmpEta = 1.74; + + for (int i=0; i!=int(abs_eta); ++i) tmpEta += endcapEta[i]; + + // ~ Why are we treating these differently??? ~ + if (mJetSize % 2 == 0) tmpEta += endcapEta[int(abs_eta)] / 2.; + else tmpEta += endcapEta[int(abs_eta)]; + } + if ((**lConstituentIt).iEta()<0) tmpEta = (-1)*tmpEta; + + etaSumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) * ( tmpEta ); + sumEt += ( (**lConstituentIt).E() + (**lConstituentIt).H() ) ; + } + + mWeightedEta = etaSumEt/sumEt ; + + } + */ + /* + void L1TowerJet::calculateWeightedPhi( ) + { + // double JetSize = double(mJetSize) / 2.0; + double WeightedPhi = ( ( mWeightedIphi-0.5 ) * 0.087 ); + //Need this because 72*0.087 != 2pi: else get uneven phi dist + double pi=(72*0.087)/2; + if(WeightedPhi > pi) WeightedPhi -=2*pi; + mWeightedPhi=WeightedPhi; + // std::cout<<"weighted IPhi: "<=1) WeightedEta = (0.087*abs_eta - 0.0435); + else WeightedEta = 0.0435*abs_eta ; + + } + else + { + const double endcapEta[8] = { 0.09, 0.1, 0.113, 0.129, 0.15, 0.178, 0.15, 0.35 }; + abs_eta -= 21; + + WeightedEta = 1.74; + + for ( int i = 0; i != int(abs_eta); ++i ) + { + WeightedEta += endcapEta[i]; + } + if( mJetSize % 2 == 0 ){ + WeightedEta += endcapEta[int(abs_eta)] / 2.; + }else{ + WeightedEta += endcapEta[int(abs_eta)]; + } + } + if(mWeightedIeta<0) WeightedEta=-WeightedEta; + + mWeightedEta = WeightedEta; + } + */ + + + + + + + + + void L1TowerJet::addConstituent( const L1CaloTowerRef & Tower ) + { + + int lHalfJetSizeEta( mJetSize >> 1 ); + int lHalfJetSizePhi( mJetSize >> 1 ); + // Tower energy in 2 GeV units -> 1 unit = 2 GeV + int lTowerEnergy( Tower->E( ) + Tower->H( ) ); + + //slightly different sizes for HF jets + if( abs( iEta() ) > 28 ){ + //???? Not sure what this is doing ???? + lHalfJetSizeEta = 1; //ie mJetSize/4 as in HF jets 2 in eta + } + + // Store the energy in 2GeV units + mE2GeV += lTowerEnergy; + mE += 0.5*lTowerEnergy; + mConstituents.push_back( Tower ); + + +// std::cout << Tower->iEta() << "\t" << Tower->iPhi() << "\t" +// << Tower->E() << "\t" << Tower->H() << "\t" << "\n"; + + + // ******************************************************************** + // * Calculate the asymmetry parameters * + // ******************************************************************** + // + // Currently the choice of definition of these parameters may not be optimal, as the parameters + // favour symmetric jets rather than jets with central energy deposits. There are also problems + // with degeneracy in the sorting stage, making the algorithm dependent on the sorting algorithm. + // + // Definition: + // ~~~~~~~~~~ + // Positive asymmetry = For TT energy deposits 'above' jet center + // Negative asymmetry = For TT energy deposits 'below' jet center + + // TT iPhi without calorimeter wrapping i.e. iPhi can exceed 71 + int ToweriPhi = Tower->iPhi(); + + // Check whether the edge of the jet mask wraps around the calorimeter + if ( iPhi() > (72 - mJetSize) ){ + if ( ToweriPhi < mJetSize ){ + // Undo the wrapping of the calorimeter + ToweriPhi += 72; + } + } + + // ******************************************************************** + // * Even jet size * + // ******************************************************************** + + if ( (mJetSize % 2) == 0 ){ + + // Eta asymmetry + if( Tower->iEta() >= (iEta() + lHalfJetSizeEta) ) { + mAsymEta += lTowerEnergy; + } + else{ + mAsymEta -= lTowerEnergy; + } + + // Phi asymmetry + if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ){ + mAsymPhi += lTowerEnergy; + } + else{ + mAsymPhi -= lTowerEnergy; + } + + } + + // ******************************************************************** + // * Odd jet size * + // ******************************************************************** + + else{ //odd jet size: miss out central towers + + if( Tower->iEta() == (iEta() + lHalfJetSizeEta) ) { + mAsymEta += 0; // It is in the middle so does not contribute to the asymmetry + } + else if( Tower->iEta() > (iEta() + lHalfJetSizeEta) ) { + mAsymEta += lTowerEnergy; + } + else{ + mAsymEta -= lTowerEnergy; + } + + + if( ToweriPhi == (iPhi() + lHalfJetSizePhi) ) { + mAsymPhi += 0; // It is in the middle so does not contribute to the asymmetry + } + else if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ) { + mAsymPhi += lTowerEnergy; + } + else{ + mAsymPhi -= lTowerEnergy; + } + } + + } + + + void L1TowerJet::removeConstituent( const int &eta, const int &phi ) + { + L1CaloTowerRefVector::iterator lConstituent = getConstituent( eta, phi ); + if ( lConstituent != mConstituents.end() ){ + + int lHalfJetSizeEta( mJetSize >> 1 ); + int lHalfJetSizePhi( mJetSize >> 1 ); + int lTowerEnergy( (**lConstituent).E( ) + (**lConstituent).H( ) ); + + mE2GeV -= lTowerEnergy; + mE -= 0.5*lTowerEnergy; + mConstituents.erase( lConstituent ); + + if( abs( iEta() ) > 28 ){ + lHalfJetSizeEta = 1; //ie mJetSize/4 as in HF jets 2 in eta + } + + int ToweriPhi = phi; + //if iPhi at the edge of the calo wrap round in phi + if( iPhi() > (72 - mJetSize) ) { + if (ToweriPhi < mJetSize){ + ToweriPhi += 72; + } + } + + + if( mJetSize % 2 == 0 ){ //even jet size + + if( eta >= (iEta() + lHalfJetSizeEta) ) { + mAsymEta -= lTowerEnergy; + } + else{ /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ + mAsymEta += lTowerEnergy; + } + + + if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ){ + mAsymPhi -= lTowerEnergy; + + }else{ /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ + mAsymPhi += lTowerEnergy; + } + + + }else{ //odd jet size: miss out central towers + + if( eta == (lHalfJetSizeEta + iEta()) ) { + mAsymEta += 0; //do nothing + } + else if( eta > (iEta() + lHalfJetSizeEta) ) { + mAsymEta -= lTowerEnergy; + + }else /*if( Tower->iEta( ) < iEta() + lHalfJetSize )*/ { + mAsymEta += lTowerEnergy; + + } + + if( ToweriPhi == (lHalfJetSizePhi + iPhi()) ) { + mAsymEta -= 0; //do nothing + + } + else if( ToweriPhi < (iPhi() + lHalfJetSizePhi) ) { + mAsymPhi -= lTowerEnergy; + + }else /*if( Tower->iPhi( ) > iPhi() + lHalfJetSize )*/ { + mAsymPhi += lTowerEnergy; + + } + } + } + } + + + const L1CaloTowerRefVector & L1TowerJet::getConstituents( ) const + { + return mConstituents; + } + + + L1CaloTowerRefVector::iterator L1TowerJet::getConstituent( const int &eta, const int &phi ) + { + for ( L1CaloTowerRefVector::iterator lConstituentIt = mConstituents.begin() ; lConstituentIt != mConstituents.end(); ++lConstituentIt ) + if ( (**lConstituentIt).iEta( ) == eta + mIeta && (**lConstituentIt).iPhi( ) == phi + mIphi ) + return lConstituentIt; + + return mConstituents.end(); + } + +} + + + +namespace std{ + + // Overloaded jet rank comparison operator: First order by Et and, in the case of degenerate energy, rank by centrality + bool operator<( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ){ + +// std::cout << "Pt1 = " << aLeft.Pt() << "\tPt2 = " << aRight.Pt() +// << "Cent1 = " << aLeft.Centrality() << "\tCent2 = " << aRight.Centrality(); + + // Degenerate energies + if ( aLeft.E() == aRight.E() ){ + if ( aLeft.Centrality() == aRight.Centrality() ){ + // std::cout << "ERROR: Degeneracy in the secondary sort parameter.\n\nOffending jets:\n"; + // << aLeft << "\n" << aRight << "\n\n"; + std::cout << "\t1<2 = " << false << "\n"; + return false; // Current solution, pick the jet in the list that is left most. i.e. lowest iEta, iPhi + // throw cms::Exception("Sort degeneracy") + // << "Please debug me! :(\n"; + } + else{ + // Order by the lowest centrality + std::cout << "\t1<2 = " << ( aLeft.Centrality() > aRight.Centrality() ) << "\n"; + return ( aLeft.Centrality() > aRight.Centrality() ); + } + } + else{ + std::cout << "\t1<2 = " << ( aLeft.E() < aRight.E() ) << "\n"; + return ( aLeft.E() < aRight.E() ); + } + } + + + // NOTE: Added to be compatible with the bitonic sort routine which is currently also utilised in Asymmetry filtering + // Overloaded jet rank comparison operator: First order by Et and, in the case of degenerate energy, rank by centrality + bool operator>( const l1slhc::L1TowerJet & aLeft, const l1slhc::L1TowerJet & aRight ){ + + // THIS DOESN'T WORK FOR SOME REASON.... + // return ( !(aLeft < aRight) ); + + + // + +// std::cout << "Pt1 = " << aLeft.Pt() << "\tPt2 = " << aRight.Pt() +// << "Cent1 = " << aLeft.Centrality() << "\tCent2 = " << aRight.Centrality(); + + // Degenerate energies + if ( aLeft.E() == aRight.E() ){ + if ( aLeft.Centrality() == aRight.Centrality() ){ + // std::cout << "ERROR: Degeneracy in the secondary sort parameter.\n\nOffending jets:\n"; + // << aLeft << "\n" << aRight << "\n\n"; + std::cout << "\t1>2 = " << true << "\n"; + return true; // Current solution, pick the jet in the list that is left most. i.e. lowest iEta, iPhi + // throw cms::Exception("Sort degeneracy") + // << "Please debug me! :(\n"; + } + else{ + // Order by the lowest centrality + std::cout << "\t1>2 = " << ( aLeft.Centrality() < aRight.Centrality() ) << "\n"; + return ( aLeft.Centrality() < aRight.Centrality() ); + } + } + else{ + std::cout << "\t1>2 = " << ( aLeft.E() > aRight.E() ) << "\n"; + return ( aLeft.E() > aRight.E() ); + } + // + + } + +} + + +// pretty print +std::ostream & operator<<( std::ostream & aStream, const l1slhc::L1TowerJet & aL1TowerJet ) +{ + aStream << "L1TowerJet" + << " iEta=" << aL1TowerJet.iEta( ) + << " \tiPhi=" << aL1TowerJet.iPhi( ) + << "\n with constituents:\n"; + for ( l1slhc::L1CaloTowerRefVector::const_iterator i = aL1TowerJet.getConstituents( ).begin( ); i < aL1TowerJet.getConstituents( ).end( ); ++i ){ + aStream << " \tiEta = " << ( **i ).iEta( ) + << " \tiPhi = " << ( **i ).iPhi( ) + << " \tET = " << ( **i ).E( ) + << "\n"; + } + return aStream; +} diff --git a/SimDataFormats/SLHC/src/L1TowerNav.cc b/SimDataFormats/SLHC/src/L1TowerNav.cc new file mode 100644 index 0000000000000..db476338176cf --- /dev/null +++ b/SimDataFormats/SLHC/src/L1TowerNav.cc @@ -0,0 +1,59 @@ +#include "SimDataFormats/SLHC/interface/L1TowerNav.h" + +#include + +int L1TowerNav::getOffsetIEta(int iEta,int offset) +{ + int newIEta=iEta+offset; + + //first check for a +ve to -ve transistion (there is no iEta==0) + if( (newIEta)/std::abs(newIEta) != iEta/std::abs(iEta) ) { + if(offset>0) newIEta++; //-ve to +ve + else newIEta--; //+ve to -ve + } + return newIEta; + //now bounds check + //if(std::abs(newIEta)<=kIEtaAbsHFMax) return newIEta; + // else return kNullIEta; + +} + +int L1TowerNav::getOffsetIPhi(int iEta,int iPhi,int offset) +{ + if(std::abs(iEta)<=kIEtaAbsHEMax) return getOffsetIPhiHBHE(iPhi,offset); + else return getOffsetIPhiHF(iPhi,offset); + +} + +int L1TowerNav::getOffsetIPhiHBHE(int iPhi,int offset) +{ + if(iPhi<=0 || iPhi>kIPhiMax) return kNullIPhi; + + offset=offset%kIPhiMax; + iPhi+=offset; + + //technically as we bounds check earilier and ensure the offset is 0 to 71, we can only be a max of 71 out + //however leave as is incase things change, for example we may wish to allow out of bounds phi + while(iPhi<=0) iPhi+=kIPhiMax; + while(iPhi>kIPhiMax) iPhi-=kIPhiMax; + + + return iPhi; +} + +int L1TowerNav::getOffsetIPhiHF(int iPhi,int offset) +{ + if(iPhi<=0 || iPhi>kIPhiMax) return kNullIPhi; + if((iPhi%kHFIPhiScale)!=1) return kNullIPhi; //invalid HF iPhi + + + offset=(offset*kHFIPhiScale)%kIPhiMax; + iPhi+=offset; + + //technically as we bounds check earilier and ensure the offset is 0 to 71, we can only be a max of 71 out + //however leave as is incase things change, for example we may wish to allow out of bounds phi + while(iPhi<=0) iPhi+=kIPhiMax; + while(iPhi>kIPhiMax) iPhi-=kIPhiMax; + + return iPhi; +} diff --git a/SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc b/SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc new file mode 100644 index 0000000000000..920362f615f9d --- /dev/null +++ b/SimDataFormats/SLHC/src/T_EventSetup_L1CaloTriggerSetup.cc @@ -0,0 +1,7 @@ +#include "SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h" +#include "FWCore/Utilities/interface/typelookup.h" + +// #define EVENTSETUP_DATA_REG(_mDataclass) TYPELOOKUP_DATA_REG(_mDataclass) + +TYPELOOKUP_DATA_REG( L1CaloTriggerSetup ); +// EVENTSETUP_DATA_REG(L1CaloTriggerSetup); diff --git a/SimDataFormats/SLHC/src/classes.h b/SimDataFormats/SLHC/src/classes.h new file mode 100644 index 0000000000000..75ae25f283e4d --- /dev/null +++ b/SimDataFormats/SLHC/src/classes.h @@ -0,0 +1,236 @@ +/// //////////////////////////////////////// +/// Stacked Tracker Simulations /// +/// //////////////////////////////////////// + +#include "DataFormats/Common/interface/Wrapper.h" + +/**********************/ +/** L1 TRACK TRIGGER **/ +/**********************/ + +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" + +namespace +{ + namespace + { + std::vector > STk_PC; + + Ref_PSimHit_ PSH_; + Ref_PixelDigi_ PD_; + + /// SimHit type + L1TkStub_PSimHit_ S_PSH_; + L1TkStub_PSimHit_Collection S_PSH_C; +// edm::Wrapper S_PSH_CW; + + L1TkTrack_PSimHit_ L1T_PSH_; + L1TkTrack_PSimHit_Collection L1T_PSH_C; +// edm::Wrapper L1T_PSH_CW; + + L1TkCluster_PSimHit_ CL_PSH_; +// L1TkCluster_PSimHit_Map CL_PSH_M; +// edm::Wrapper CL_PSH_MW; + L1TkCluster_PSimHit_Collection CL_PSH_C; + edm::Wrapper CL_PSH_CW; + L1TkCluster_PSimHit_Pointer CL_PSH_P; +// edm::Wrapper CL_PSH_PW; + + L1TkCluster_PixelDigi_ CL_PD_; +// L1TkCluster_PixelDigi_Map CL_PD_M; +// edm::Wrapper CL_PD_MW; + L1TkCluster_PixelDigi_Collection CL_PD_C; + edm::Wrapper CL_PD_CW; + L1TkCluster_PixelDigi_Pointer CL_PD_P; +// edm::Wrapper CL_PD_PW; + + /// PixelDigi type + L1TkStub_PixelDigi_ S_PD_; + L1TkStub_PixelDigi_Collection S_PD_C; + edm::Wrapper S_PD_CW; + + L1TkTrack_PixelDigi_ L1T_PD_; + L1TkTrack_PixelDigi_Collection L1T_PD_C; + edm::Wrapper L1T_PD_CW; + + edm::Ptr P_S_PD_C; + std::vector< std::vector< edm::Ptr > > S_PD_C_C; + edm::Wrapper > > > S_PD_C_CW; + + +/* + // Anders tracks + L1TStub L1TS; + edm::Wrapper L1TS_W; + edm::Wrapper > VEC_L1TS; + + L1TTrack L1T; + edm::Wrapper L1T_W; + edm::Wrapper > VEC_L1T; + + L1TTracks L1TTS; + edm::Wrapper L1TTS_W; + edm::Wrapper > VEC_L1TTS; +*/ + +// std::vector< std::vector< Ref_PixelDigi_ > > STV_PD; +// std::pair STP_STDI_I; // why ??? + +/* + std::pair P_INT_PSHC; + std::pair P_INT_PDC; + + std::pair > P_INT_PTRS_PSH; + std::pair > P_INT_PTRS_PD; +*/ + } +} + +/************************/ +/** L1 DT MUON TRIGGER **/ +/************************/ +/* +#include +#include + +#include "L1Trigger/DTTrackFinder/interface/L1MuDTTrack.h" +#include "L1Trigger/DTTrackFinder/src/L1MuDTAddressArray.h" +#include "L1Trigger/DTTrackFinder/src/L1MuDTSecProcId.h" +#include "L1Trigger/DTTrackFinder/src/L1MuDTTrackSegLoc.h" + +#include "SimDataFormats/SLHC/interface/DTBtiTrigger.h" +#include "SimDataFormats/SLHC/interface/DTTSPhiTrigger.h" +#include "SimDataFormats/SLHC/interface/DTTSThetaTrigger.h" +#include "SimDataFormats/SLHC/interface/DTMatch.h" +#include "SimDataFormats/SLHC/interface/DTMatchPt.h" +#include "SimDataFormats/SLHC/interface/DTMatchPtVariety.h" +#include "SimDataFormats/SLHC/interface/DTMatchPtAlgorithms.h" +#include "SimDataFormats/SLHC/interface/DTTrackerStub.h" +#include "SimDataFormats/SLHC/interface/DTTrackerTracklet.h" +#include "SimDataFormats/SLHC/interface/DTTrackerTrack.h" +#include "SimDataFormats/SLHC/interface/DTMatchesCollection.h" +#include "SimDataFormats/SLHC/interface/DTSeededStubTrack.h" + +namespace { + namespace { + edm::Wrapper Bti1; + std::vector Btv1; + edm::Wrapper > Btc1; + + edm::Wrapper phi1; + std::vector phiv1; + edm::Wrapper > phic1; + + edm::Wrapper DTPt1; + std::vector DTPtV1; + edm::Wrapper > DTPtW1; + + edm::Wrapper DTM1; + std::vector DTMv1; + edm::Wrapper > DTSMwv1; + + std::vector DTMm1; + edm::Wrapper > DTSMwm1; + + std::vector DTTSv1; + edm::Wrapper > DTTSwv1; + edm::Wrapper DTSMc1; + + std::vector DTTTv1; + edm::Wrapper > DTTTwv1; + + std::vector DTTTTv1; + edm::Wrapper > DTTTTwv1; + + edm::Wrapper TS1; + edm::Wrapper TT1; + edm::Wrapper XT1; + edm::Wrapper LT1; + std::set TSv1; + edm::Wrapper > TSwv1; + + DTSeededStubTrack DTTST1; + edm::Wrapper DTTSTw1; + std::vector DTTSTv1; + edm::Wrapper > DTTSTa1; + DTSeededStubTracksCollection DTTSTc1; + edm::Wrapper DTTSTcw1; + + } +} +*/ + +/*********************/ +/** L1 CALO TRIGGER **/ +/*********************/ + +#include "SimDataFormats/SLHC/interface/L1CaloTriggerSetup.h" +#include "SimDataFormats/SLHC/interface/L1CaloTower.h" +#include "SimDataFormats/SLHC/interface/L1CaloTowerFwd.h" +#include "SimDataFormats/SLHC/interface/L1CaloCluster.h" +#include "SimDataFormats/SLHC/interface/L1CaloClusterFwd.h" +#include "SimDataFormats/SLHC/interface/L1CaloClusterWithSeed.h" +#include "SimDataFormats/SLHC/interface/L1CaloClusterWithSeedFwd.h" +#include "SimDataFormats/SLHC/interface/L1CaloJet.h" +#include "SimDataFormats/SLHC/interface/L1CaloJetFwd.h" +#include "SimDataFormats/SLHC/interface/L1CaloRegion.h" +#include "SimDataFormats/SLHC/interface/L1CaloRegionFwd.h" + +#include "SimDataFormats/SLHC/interface/L1TowerJet.h" +#include "SimDataFormats/SLHC/interface/L1TowerJetFwd.h" + +#include "SimDataFormats/SLHC/interface/EtaPhiContainer.h" + +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" + + +namespace { + namespace { + + l1slhc::L1CaloTower tower; + std::vector l1calotl; + l1slhc::L1CaloTowerRef towerRef; + + l1slhc::L1CaloTowerCollection towerColl; + l1slhc::L1CaloTowerRefVector towerRefColl; + edm::Wrapper wtowerColl; + edm::Wrapper wtowerRefColl; + + l1slhc::L1CaloCluster calocl; + std::vector l1calocl; + l1slhc::L1CaloClusterCollection l1caloclcoll; + edm::Wrapper< l1slhc::L1CaloClusterCollection > wl1calocl; + + l1slhc::L1CaloClusterWithSeed calocls; + std::vector l1calocls; + l1slhc::L1CaloClusterWithSeedCollection l1caloclscoll; + edm::Wrapper< l1slhc::L1CaloClusterWithSeedCollection > wl1calocls; + + l1slhc::L1CaloJet calojet; + std::vector l1calojetvec; + l1slhc::L1CaloJetCollection l1calojetcoll; + edm::Wrapper< l1slhc::L1CaloJetCollection > wl1calojetcol; + + l1slhc::L1CaloRegion caloregion; + std::vector l1caloregion; + l1slhc::L1CaloRegionRef caloregionRef; + l1slhc::L1CaloRegionCollection caloregionC; + l1slhc::L1CaloRegionRefVector caloregionRefC; + + edm::Wrapper wcaloregionC; + edm::Wrapper qaloregionRefC; + + l1slhc::L1TowerJet towerjet; + std::vector l1towerjetvec; + l1slhc::L1TowerJetCollection l1towerjetcoll; + edm::Wrapper< l1slhc::L1TowerJetCollection > wl1towerjetcol; + + + l1slhc::L1EGCrystalCluster egcrystalcluster; + std::vector l1egcrystalclustervec; + l1slhc::L1EGCrystalClusterCollection l1egcrystalclustercoll; + edm::Wrapper wl1egcrystalclustercoll; + + } +} + diff --git a/SimDataFormats/SLHC/src/classes_def.xml b/SimDataFormats/SLHC/src/classes_def.xml new file mode 100644 index 0000000000000..444d7c09cfd1d --- /dev/null +++ b/SimDataFormats/SLHC/src/classes_def.xml @@ -0,0 +1,212 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 30999fc7cb7605428fd5f2348a7748b21e3f3c18 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Fri, 30 May 2014 14:49:47 +0200 Subject: [PATCH 029/252] added L1TkMuonSequence_cfi.py and add examples --- .../L1TrackTrigger/src/L1TkMuonParticle.cc | 21 --- ...er_cfi.py => L1TkMuonNaiveProducer_cfi.py} | 0 .../python/L1TkMuonSequence_cfi.py | 34 +++++ .../L1TrackTrigger/test/test_L1TkMuon.py | 108 --------------- .../L1TrackTrigger/test/test_L1TkMuon_cfg.py | 106 +++++++++++++++ .../L1TrackTrigger/test/test_L1TkTau_cfg.py | 128 ++++++++++++++++++ .../L1TrackTrigger/test/test_muons_cfg.py | 8 +- 7 files changed, 272 insertions(+), 133 deletions(-) rename SLHCUpgradeSimulations/L1TrackTrigger/python/{L1TkMuonProducer_cfi.py => L1TkMuonNaiveProducer_cfi.py} (100%) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py delete mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index 7f445e6b88754..af99753b92370 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -65,25 +65,4 @@ int L1TkMuonParticle::bx() const { } -unsigned int L1TkMuonParticle::quality() const { - - int dummy = 999; - - if ( muRef_.isNonnull() ) { - return (getMuRef() -> gmtMuonCand().quality() ); - } - else { - return dummy; - - } - -} - - - - - - - - diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonNaiveProducer_cfi.py similarity index 100% rename from SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonProducer_cfi.py rename to SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonNaiveProducer_cfi.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py new file mode 100644 index 0000000000000..c0bc8aa2dd011 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py @@ -0,0 +1,34 @@ +import FWCore.ParameterSet.Config as cms + + +# +# --- Muons from Slava +# + +from L1Trigger.L1ExtraFromDigis.l1extraMuExtended_cfi import * +from SLHCUpgradeSimulations.L1TrackTrigger.l1TkMuonsExt_cff import * + +# this is based on all GMTs available (BX=0 is hardcoded ) +l1tkMusFromExtendedAllEta = cms.Sequence(l1extraMuExtended * l1TkMuonsExt ) + +# this is based on CSCTF record directly (no GMT sorting) and creates TkMus in |eta| > 1.1 +l1tkMusFromExtendedForward = cms.Sequence(l1extraMuExtended * l1TkMuonsExtCSC ) + + +# +# --- FInal collection of L1TkMuons +# + +L1TkMuonsMerge = cms.EDProducer("L1TkMuonMerger", + TkMuonCollections = cms.VInputTag( + #cms.InputTag("L1TkMuonsDT","DTMatchInwardsTTTrackFullReso"), + cms.InputTag("l1TkMuonsExt",""), + cms.InputTag("l1TkMuonsExtCSC","") ), + absEtaMin = cms.vdouble( 0. , 1.1), # Padova's not ready yet + absEtaMax = cms.vdouble( 1.1 , 5.0) +) + + +L1TkMuons = cms.Sequence( l1tkMusFromExtendedAllEta + l1tkMusFromExtendedForward + L1TkMuonsMerge ) + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py deleted file mode 100644 index 0fb5f0109c332..0000000000000 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon.py +++ /dev/null @@ -1,108 +0,0 @@ -import FWCore.ParameterSet.Config as cms - -process = cms.Process("Muo") - -process.load("FWCore.MessageService.MessageLogger_cfi") - -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(100) ) - -# initialize MessageLogger and output report -process.load("FWCore.MessageLogger.MessageLogger_cfi") -process.MessageLogger.cerr.FwkReport = cms.untracked.PSet( - reportEvery = cms.untracked.int32(500), - limit = cms.untracked.int32(10000000) -) - -# -# This runs over a file that already contains the L1Tracks. -# -# Creates L1TkMuons starting from the Run-1 L1Muons. -# - -process.source = cms.Source("PoolSource", - # replace 'myfile.root' with the source file you want to use - fileNames = cms.untracked.vstring( - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_55.root' - ) -) - - -process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') - -process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") -from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') - - - -# --- creates l1extra objects for L1Muons - - # raw2digi to get the GT digis -process.load('Configuration.StandardSequences.RawToDigi_cff') -process.p0 = cms.Path( process.RawToDigi ) - # run L1Reco -process.load('Configuration.StandardSequences.L1Reco_cff') -process.L1Reco = cms.Path( process.l1extraParticles ) - - -# --- Produces the L1TkMuons : - -process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkMuonProducer_cfi") -process.pMuons = cms.Path( process.L1TkMuons ) - - - -# --------------------------------------------------------------------------- - - -# Run a trivial analyzer that prints the objects - -process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , - L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here - L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here - L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), # dummy here - L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), # dummy here - L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here - L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI",""), # dummy here - L1TkMuonsInputTag = cms.InputTag("L1TkMuons","") - -) - -process.pAna = cms.Path( process.ana ) - - - - - -# --------------------------------------------------------------------------- - -# --- Output module : - - -process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "test_L1TrackTriggerObjects.root" ), - fastCloning = cms.untracked.bool( False ), - outputCommands = cms.untracked.vstring( 'drop *') -) - - - # genlevel information -#process.Out.outputCommands.append('keep *_generator_*_*') -#process.Out.outputCommands.append('keep *_*gen*_*_*') -#process.Out.outputCommands.append('keep *_*Gen*_*_*') -#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') - - # the L1Tracks, clusters and stubs -process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') -process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') -process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') -process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') -process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') -process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') - - # the L1TkMuon -process.Out.outputCommands.append('keep *_L1TkMuons_*_*') - - -process.FEVToutput_step = cms.EndPath(process.Out) - diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py new file mode 100644 index 0000000000000..fe59555b2380f --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py @@ -0,0 +1,106 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) + +# +# This runs over a file that already contains the L1Tracks. +# +# +# It also runs a trivial analyzer than prints the objects +# that have been created. + + +#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * +#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p2_cfi import * +from SLHCUpgradeSimulations.L1TrackTrigger.singleMuonFiles_cfi import * + +process.source = cms.Source("PoolSource", + #fileNames = minBiasFiles_p2 + #fileNames = minBiasFiles_p1 + fileNames = singleMuonFiles +) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') + +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') + + + +# --------------------------------------------------------------------------- +# +# --- Produces various L1TkMuon collections - as well as "extended" L1Muons +# + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkMuonSequence_cfi") +process.pMuons = cms.Path( process.L1TkMuons ) + + +# +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# --- Output module : + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example_muons.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + + # the final collection of L1TkMuons +process.Out.outputCommands.append('keep *_L1TkMuonsMerge_*_*') + + # intermediate collections : +process.Out.outputCommands.append('keep *_L1TkMuons*_*_*') +process.Out.outputCommands.append('keep *_l1extraMuExtended_*_*') +process.Out.outputCommands.append('keep *_l1TkMuonsExt*_*_*') + +#process.Out.outputCommands.append('keep *L1Muon*_l1extraParticles_*_*') + + + # gen-level information +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') + + + # the L1Tracks, clusters and stubs +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + +# --- to browse the genParticles, one needs to keep the collections of associators below: +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py new file mode 100644 index 0000000000000..384c844e3cb2c --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py @@ -0,0 +1,128 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) + +# +# This runs over a file that already contains the L1Tracks. +# + + +# to run over the test rate sample (part 1) : +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * +process.source = cms.Source("PoolSource", + fileNames = minBiasFiles_p1 +) + +#from SLHCUpgradeSimulations.L1TrackTrigger.singleTau1pFiles_cfi import * +#process.source = cms.Source("PoolSource", +# fileNames = singleTau1pFiles +#) + + +# to run over another sample: +#process.source = cms.Source("PoolSource", + # electron file: + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', + #) +#) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + + + +# --------------------------------------------------------------------------- +# +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') + +process.L1TkTauFromL1Track = cms.EDProducer("L1TkTauFromL1TrackProducer", + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + ZMAX = cms.double( 25. ),# in cm + CHI2MAX = cms.double( 100. ), + PTMINTRA = cms.double( 2. ),# in GeV + DRmax = cms.double( 0.5 ), + nStubsmin = cms.int32( 5 ) # minimum number of stubs + ) + +process.pTaus = cms.Path( process.L1TkTauFromL1Track ) + + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# Run a trivial analyzer that prints the objects + +process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , + L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here + L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here + L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), + L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), + L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI",""), # dummy here + L1TkMuonsInputTag = cms.InputTag("L1TkMuons","") # dummy here + +) + +#process.pAna = cms.Path( process.ana ) + + + +# --------------------------------------------------------------------------- + +# --- Output module : + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + + # raw data +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + + + # gen-level information +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') + + + # the L1Tracks, clusters and stubs +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + + # the L1TkTaus +process.Out.outputCommands.append('keep *_L1TkTauFromL1Track_*_*') + + +# --- to browse the genParticles, one needs to keep the collections of associators below: +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py index 9474206a1c73f..3757c941b217f 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py @@ -15,13 +15,13 @@ #from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * -from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p2_cfi import * -#from SLHCUpgradeSimulations.L1TrackTrigger.singleMuonFiles_cfi import * +#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p2_cfi import * +from SLHCUpgradeSimulations.L1TrackTrigger.singleMuonFiles_cfi import * process.source = cms.Source("PoolSource", - fileNames = minBiasFiles_p2 + #fileNames = minBiasFiles_p2 #fileNames = minBiasFiles_p1 - #fileNames = singleMuonFiles + fileNames = singleMuonFiles ) From 79a7f3650512a2fb971de59b69d35d9952fbaa0c Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Fri, 30 May 2014 20:51:44 +0200 Subject: [PATCH 030/252] cleanup --- .../L1TrackTrigger/test/test_muons_cfg.py | 216 ------------------ 1 file changed, 216 deletions(-) delete mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py deleted file mode 100644 index 3757c941b217f..0000000000000 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_muons_cfg.py +++ /dev/null @@ -1,216 +0,0 @@ -import FWCore.ParameterSet.Config as cms - -process = cms.Process("ALL") - -process.load("FWCore.MessageService.MessageLogger_cfi") - -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) - -# -# This runs over a file that already contains the L1Tracks. -# -# -# It also runs a trivial analyzer than prints the objects -# that have been created. - - -#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * -#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p2_cfi import * -from SLHCUpgradeSimulations.L1TrackTrigger.singleMuonFiles_cfi import * - -process.source = cms.Source("PoolSource", - #fileNames = minBiasFiles_p2 - #fileNames = minBiasFiles_p1 - fileNames = singleMuonFiles -) - - -# ---- Global Tag : -process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') -from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') - - - - -# --------------------------------------------------------------------------- -# -# --- Produces the Run-1 L1muon objects -# - -process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') -process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') -process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') - -process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') - - -# --- creates l1extra objects for L1Muons - - # raw2digi to get the GT digis -process.load('Configuration.StandardSequences.RawToDigi_cff') -process.p0 = cms.Path( process.RawToDigi ) - # run L1Reco -process.load('Configuration.StandardSequences.L1Reco_cff') -process.L1Reco = cms.Path( process.l1extraParticles ) - - -# --------------------------------------------------------------------------- - - -# -# --- Produces the L1TkMuons from the naive DeltaR producer :: -# - -process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkMuonProducer_cfi") -process.pMuonsNaive = cms.Path( process.L1TkMuonsNaive ) - - - -# -# --------------------------------------------------------------------------- - - -# --------------------------------------------------------------------------- - -# -# --- The central muons from the Padova algorithm -# - - -################################################################################################# -# now, all the DT related stuff -################################################################################################# -# to produce, in case, collection of L1MuDTTrack objects: -#process.dttfDigis = cms.Path(process.simDttfDigis) - -# the DT geometry -process.load("Geometry.DTGeometry.dtGeometry_cfi") -process.load("Geometry.MuonNumbering.muonNumberingInitialization_cfi") -process.load("SimMuon/DTDigitizer/muonDTDigis_cfi") -##process.load("L1TriggerConfig.DTTPGConfigProducers.L1DTTPGConfig_cff") - -################################################################################################# -# define the producer of DT + TK objects -################################################################################################# -process.load("L1Trigger.DTPlusTrackTrigger.DTPlusTrackProducer_cfi") -process.DTPlusTk_step = cms.Path(process.DTPlusTrackProducer) - - -process.L1TkMuonsDT = cms.EDProducer("L1TkMuonDTProducer" -) - -process.pMuonsDT = cms.Path( process.L1TkMuonsDT ) - -# --------------------------------------------------------------------------- - - -# --------------------------------------------------------------------------- - -# -# --- The muons from Slava - -process.load("L1Trigger.L1ExtraFromDigis.l1extraMuExtended_cfi") -process.load("SLHCUpgradeSimulations.L1TrackTrigger.l1TkMuonsExt_cff") - -# this is based on all GMTs available (BX=0 is hardcoded ) -process.l1tkMusFromExtendedAllEta = cms.Path(process.l1extraMuExtended * process.l1TkMuonsExt ) - -# this is based on CSCTF record directly (no GMT sorting) and creates TkMus in |eta| > 1.1 -process.l1tkMusFromExtendedForward = cms.Path(process.l1extraMuExtended * process.l1TkMuonsExtCSC ) - - - -# --------------------------------------------------------------------------- - -# -# finally, merge the collections of TkMuons. -# - for the central region: take the Padova's algorithm -# - for non-central, take Slava's algorithm -# - at high eta, CSC + new chambers are used -# - in the intermediate region, GMT muons -# are used. -# Currently waiting for Slava's code. So I use the -# TkMuons created by the naive producer. -# - -process.L1TkMuonsMerge = cms.EDProducer("L1TkMuonMerger", - TkMuonCollections = cms.VInputTag( cms.InputTag("L1TkMuonsDT","DTMatchInwardsTTTrackFullReso"), - #cms.InputTag("L1TkMuonsNaive",""), - cms.InputTag("l1TkMuonsExt",""), - cms.InputTag("l1TkMuonsExtCSC","") ), - absEtaMin = cms.vdouble( 0., 0. , 1.1), # Padova's not ready yet - absEtaMax = cms.vdouble( 0., 1.1 , 5.0) -) - -process.pMuonsMerge = cms.Path( process.L1TkMuonsMerge) - - -# Run a trivial analyzer that prints the objects - -process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , - L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here - L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here - L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), # dummy here - L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), # dummy here - L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here - L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here -) - -#process.pAna = cms.Path( process.ana ) - - - -# --------------------------------------------------------------------------- - -# --- Output module : - - -process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "example_muons.root" ), - fastCloning = cms.untracked.bool( False ), - outputCommands = cms.untracked.vstring( 'drop *') -) - - -process.Out.outputCommands.append('keep *_L1TkMuons*_*_*') -process.Out.outputCommands.append('keep *_l1extraMuExtended_*_*') -process.Out.outputCommands.append('keep *_l1TkMuonsExt*_*_*') - -process.Out.outputCommands.append('keep *L1Muon*_l1extraParticles_*_*') - -#process.Out.outputCommands.append('keep *_DTPlusTrackProducer_*_*') - - # raw data -#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') - - - # gen-level information -#process.Out.outputCommands.append('keep *_generator_*_*') -#process.Out.outputCommands.append('keep *_*gen*_*_*') -#process.Out.outputCommands.append('keep *_*Gen*_*_*') -process.Out.outputCommands.append('keep *_genParticles_*_*') - - - # the L1Tracks, clusters and stubs -#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') -#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') -#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') -#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') -#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') -#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') - -# --- to use the genParticles, one needs to keep the collections of associators below: -process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') -process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') -process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') - - -process.FEVToutput_step = cms.EndPath(process.Out) - - - - - - - From 3c9fb2af4b684dfe833944b6a35df69371aba3ca Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sat, 31 May 2014 11:17:05 +0200 Subject: [PATCH 031/252] cleanup --- .../test/test_L1TkCentralMuons_cfg.py | 224 ------------------ 1 file changed, 224 deletions(-) delete mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py deleted file mode 100644 index 2d2bafe8c79bf..0000000000000 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCentralMuons_cfg.py +++ /dev/null @@ -1,224 +0,0 @@ -import FWCore.ParameterSet.Config as cms - -process = cms.Process("ALL") - -process.load("FWCore.MessageService.MessageLogger_cfi") - -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) - -# -# This runs over a file that already contains the L1Tracks. -# -# -# It also runs a trivial analyzer than prints the objects -# that have been created. - - -from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * - -process.source = cms.Source("PoolSource", - fileNames = minBiasFiles_p1 - #fileNames = cms.untracked.vstring( - # single muons -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_1.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_10.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_11.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_12.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_13.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_14.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_15.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_16.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_17.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_18.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_19.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_2.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_20.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_21.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_22.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_23.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_24.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_25.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_26.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_27.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_28.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_29.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_3.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_30.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_31.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_32.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_33.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_34.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_35.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_36.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_37.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_38.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_39.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_4.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_40.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_42.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_43.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_44.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_45.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_46.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_47.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_48.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_49.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_5.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_50.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_51.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_52.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_53.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_54.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_55.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_56.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_57.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_58.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_59.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_6.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_60.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_7.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_8.root", -#"/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/Muons/PU140/SingleMuon_E2023TTI_PU140_9.root" - #) -) - - -# ---- Global Tag : -process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') -from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') -#process.GlobalTag = GlobalTag(process.GlobalTag, 'POSTLS261_V3::All', '') -#process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') - - - - -# --------------------------------------------------------------------------- -# -# --- Produces the Run-1 L1muon objects -# - -process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') -process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') -process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') - -process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') - - -# --- creates l1extra objects for L1Muons - - # raw2digi to get the GT digis -process.load('Configuration.StandardSequences.RawToDigi_cff') -process.p0 = cms.Path( process.RawToDigi ) - # run L1Reco -process.load('Configuration.StandardSequences.L1Reco_cff') -process.L1Reco = cms.Path( process.l1extraParticles ) - - - - -# -# --------------------------------------------------------------------------- - - -################################################################################################# -# now, all the DT related stuff -################################################################################################# -# to produce, in case, collection of L1MuDTTrack objects: -#process.dttfDigis = cms.Path(process.simDttfDigis) - -# the DT geometry -process.load("Geometry.DTGeometry.dtGeometry_cfi") -process.load("Geometry.MuonNumbering.muonNumberingInitialization_cfi") -process.load("SimMuon/DTDigitizer/muonDTDigis_cfi") -##process.load("L1TriggerConfig.DTTPGConfigProducers.L1DTTPGConfig_cff") - -################################################################################################# -# define the producer of DT + TK objects -################################################################################################# -process.load("L1Trigger.DTPlusTrackTrigger.DTPlusTrackProducer_cfi") -process.DTPlusTk_step = cms.Path(process.DTPlusTrackProducer) - - - - - - -# --------------------------------------------------------------------------- - -# Now we produce L1TkEmParticles and L1TkElectrons - -process.L1TkMuons = cms.EDProducer("L1TkMuonParticleProducer" -) - -process.pMuons = cms.Path( process.L1TkMuons ) - -# --------------------------------------------------------------------------- - - -# Run a trivial analyzer that prints the objects - -process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , - L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here - L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here - L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), - L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), - L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here - L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here -) - -#process.pAna = cms.Path( process.ana ) - - - -# --------------------------------------------------------------------------- - -# --- Output module : - - -process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "example_CentralMuons.root" ), - fastCloning = cms.untracked.bool( False ), - outputCommands = cms.untracked.vstring( 'drop *') -) - - -process.Out.outputCommands.append('keep *_L1TkMuons_*_*') - -process.Out.outputCommands.append('keep *L1Muon*_l1extraParticles_*_*') - -#process.Out.outputCommands.append('keep *_DTPlusTrackProducer_*_*') - - # raw data -#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') - - - # gen-level information -#process.Out.outputCommands.append('keep *_generator_*_*') -#process.Out.outputCommands.append('keep *_*gen*_*_*') -#process.Out.outputCommands.append('keep *_*Gen*_*_*') -process.Out.outputCommands.append('keep *_genParticles_*_*') - - - # the L1Tracks, clusters and stubs -#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') -#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') -#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') -#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') -#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') -#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') - -# --- to use the genParticles, one needs to keep the collections of associators below: -process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') -process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') -process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') - - -process.FEVToutput_step = cms.EndPath(process.Out) - - - - - - - From bb0b3e6dc2a4bdcb69a0f3069946cad3e2f20bdd Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sat, 31 May 2014 13:27:32 +0200 Subject: [PATCH 032/252] L1Tracking updates from Louise (Louises L1Track_620_v1) --- .../L1TrackTrigger/plugins/L1TrackProducer.cc | 50 +++++-- .../L1TrackTrigger/plugins/L1Tracking.icc | 41 +++++- SimDataFormats/SLHC/interface/L1TBarrel.hh | 4 +- SimDataFormats/SLHC/interface/L1TDisk.hh | 6 +- SimDataFormats/SLHC/interface/L1TTrack.hh | 137 +++++++++++------- SimDataFormats/SLHC/interface/slhcevent.hh | 6 +- 6 files changed, 165 insertions(+), 79 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc index f57ac6df3dbc7..6b28fcdfd40c8 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc @@ -459,23 +459,47 @@ void L1TrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) TTTrack aTrack; - GlobalPoint bsPosition(0.0, - 0.0, - track.z0() - ); //store the L1 track vertex position - - aTrack.setMomentum( GlobalVector ( GlobalVector::Cylindrical(fabs(track.pt(mMagneticFieldStrength)), - track.phi0(), - fabs(track.pt(mMagneticFieldStrength))*sinh(track.eta())) ) ,4); - - aTrack.setRInv(track.rinv(),4); - aTrack.setSector(999); //this is currently not retrained by the algorithm aTrack.setWedge(999); //not used by the tracklet implementations - aTrack.setChi2(track.chisq(),4); + //First do the 4 parameter fit + + GlobalPoint bsPosition4par(0.0,0.0,track.z04par()); + + aTrack.setPOCA(bsPosition4par,4); + + double pt4par=fabs(track.pt4par(mMagneticFieldStrength)); + + GlobalVector p34par(GlobalVector::Cylindrical(pt4par, + track.phi04par(), + pt4par*sinh(track.eta4par()))); + + aTrack.setMomentum(p34par,4); + + aTrack.setRInv(track.rinv4par(),4); + + aTrack.setChi2(track.chisq4par(),4); + + + //Now do the 5 parameter fit + + GlobalPoint bsPosition5par(track.d0()*cos(track.phi0()),-track.d0()*sin(track.phi0()),track.z0()); + + aTrack.setPOCA(bsPosition5par,5); + + double pt5par=fabs(track.pt(mMagneticFieldStrength)); + + GlobalVector p35par(GlobalVector::Cylindrical(pt5par, + track.phi0(), + pt5par*sinh(track.eta()))); + + aTrack.setMomentum(p35par,5); + + aTrack.setRInv(track.rinv(),5); + + aTrack.setChi2(track.chisq(),5); + - aTrack.setPOCA(bsPosition,4); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1Tracking.icc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1Tracking.icc index 43b762df668be..0eae2076a96f4 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1Tracking.icc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1Tracking.icc @@ -580,8 +580,7 @@ } if (mode==4) { - if (1){ - + if(1){ //tracklettimer.start(); L[0]->findTracklets(L[1]); L[0]->findTracklets(B[0],50.0); @@ -675,10 +674,10 @@ L[3]->findTracklets(F[0]); //tracklettimer.stop(); //matchtimer.start(); - L[3]->findMatches(L[0],phiWindowSF_,0.025,5.0); - L[3]->findMatches(L[1],phiWindowSF_,0.025,3.0); - L[3]->findMatches(L[2],phiWindowSF_,0.03,8.0); - L[3]->findMatches(L[5],phiWindowSF_,0.05,10.0); + L[3]->findMatches(L[0],phiWindowSF_,0.025,10.0); //5->10 + L[3]->findMatches(L[1],phiWindowSF_,0.025,8.0); //3->8 + L[3]->findMatches(L[2],phiWindowSF_,0.03,6.0); //8->6 + L[3]->findMatches(L[5],phiWindowSF_,0.05,8.0); //10->8 L[3]->findMatches(F[0],phiWindowSF_); L[3]->findMatches(F[1],phiWindowSF_); L[3]->findMatches(F[2],phiWindowSF_); @@ -696,6 +695,36 @@ allTracks.addTracks(L[3]->allTracks()); } + + // TEST ADDING SEEDING BETWEEN LAYERS 5 AND 6 + if(1){ + //tracklettimer.start(); + L[4]->findTracklets(L[5]); + //tracklettimer.stop(); + //matchtimer.start(); + L[4]->findMatches(L[0],phiWindowSF_,0.025,10.0); //5->10 + L[4]->findMatches(L[1],phiWindowSF_,0.025,10.0); //5->10 + L[4]->findMatches(L[2],phiWindowSF_,0.03,8.0); //8->8 + L[4]->findMatches(L[3],phiWindowSF_,0.05,6.0); //10->6 + /* + L[4]->findMatches(F[0],phiWindowSF_); + L[4]->findMatches(F[1],phiWindowSF_); + L[4]->findMatches(F[2],phiWindowSF_); + L[4]->findMatches(F[3],phiWindowSF_); + L[4]->findMatches(F[4],phiWindowSF_); + L[4]->findMatches(B[0],phiWindowSF_); + L[4]->findMatches(B[1],phiWindowSF_); + L[4]->findMatches(B[2],phiWindowSF_); + L[4]->findMatches(B[3],phiWindowSF_); + L[4]->findMatches(B[4],phiWindowSF_); + */ + //matchtimer.stop(); + //fittimer.start(); + L[4]->fitTracks(); + //fittimer.stop(); + + allTracks.addTracks(L[4]->allTracks()); + } if(1){ //tracklettimer.start(); diff --git a/SimDataFormats/SLHC/interface/L1TBarrel.hh b/SimDataFormats/SLHC/interface/L1TBarrel.hh index 372772ab964cc..68d3329b0447c 100644 --- a/SimDataFormats/SLHC/interface/L1TBarrel.hh +++ b/SimDataFormats/SLHC/interface/L1TBarrel.hh @@ -315,7 +315,7 @@ public: if (!pass1) continue; */ - double dist=hypot(rdeltaphi/cutrphi,deltaz/cutrz); + double dist=hypot(rdeltaphi/(cutrphi*phiSF),deltaz/cutrz); if (diststubs_[jSector][j]; @@ -423,7 +423,7 @@ public: if (fabs(rdeltaphi)>0.2*phiSF) continue; if (fabs(deltar)>3.0) continue; - double dist=hypot(rdeltaphi/0.2,deltar/3.0); + double dist=hypot(rdeltaphi/(0.2*phiSF),deltar/3.0); if (diststubs_[jSector][j]; diff --git a/SimDataFormats/SLHC/interface/L1TDisk.hh b/SimDataFormats/SLHC/interface/L1TDisk.hh index 2a1c75798ba0c..46fc39dba5b6e 100644 --- a/SimDataFormats/SLHC/interface/L1TDisk.hh +++ b/SimDataFormats/SLHC/interface/L1TDisk.hh @@ -223,12 +223,12 @@ public: if (r<60) { if (fabs(rdeltaphi)>rphicut1*phiSF) continue; if (fabs(deltar)>rcut1) continue; - dist=hypot(rdeltaphi/rphicut1,deltar/rcut1); + dist=hypot(rdeltaphi/(rphicut1*phiSF),deltar/rcut1); } else { if (fabs(rdeltaphi)>rphicut2*phiSF) continue; if (fabs(deltar)>rcut2) continue; - dist=hypot(rdeltaphi/rphicut2,deltar/rcut2); + dist=hypot(rdeltaphi/(rphicut2*phiSF),deltar/rcut2); } /* @@ -315,7 +315,7 @@ public: if (fabs(rdeltaphi)>0.1*phiSF) continue; if (fabs(deltaz)>5.0) continue; //LS modified from 0.5 to 5.0 - double dist=hypot(rdeltaphi/0.1,deltaz/5.0); //LS modified from 0.5 to 5.0 + double dist=hypot(rdeltaphi/(0.1*phiSF),deltaz/5.0); //LS modified from 0.5 to 5.0 if (dist0) { - rinv_=rinvfit_; - phi0_=phi0fit_; - z0_=z0fit_; - t_=tfit_; + rinv_=rinvfit4par_; + phi0_=phi0fit4par_; + z0_=z0fit4par_; + t_=tfit4par_; } - calculateDerivatives(); - - linearTrackFit(); + calculateDerivatives(false); + linearTrackFit(false); } @@ -48,25 +47,28 @@ public: //cout << "Chisq largestresid: "<3&&chisq()>100.0&&largestresid>5.0) { + if (stubs_.size()>3&&chisq4par()>100.0&&largestresid>5.0) { //cout << "Refitting track"<0.5*two_pi) deltaphi-=two_pi; if (deltaphi<-0.5*two_pi) deltaphi+=two_pi; + //cout << "4par : "< getStubs() const { return stubs_; } unsigned int nstub() const { return stubs_.size(); } - double rinv() const { return rinv_; } + double getRinv() const { return rinv_; } double getPhi0() const { return phi0_; } double getZ0() const { return z0_; } double getT() const { return t_; } @@ -597,32 +623,38 @@ public: double getSimTrackID() const { return SimTrackID_; } double pt(double bfield) const { return 0.00299792*bfield/rinvfit_; } + double pt4par(double bfield) const { return 0.00299792*bfield/rinvfit4par_; } //double ipt(double bfield) const { return 0.00299792*bfield/irinvfit(); } double ptseed(double bfield) const { return 0.00299792*bfield/rinv_; } + double rinv() const { return rinvfit_; } + double rinv4par() const { return rinvfit4par_; } + double phi04par() const { return phi0fit4par_;} double phi0() const { return phi0fit_;} + double d0() const { return d0fit_;} //double iphi0() const { return iphi0fit();} double phi0seed() const { return phi0_;} double eta() const { static double two_pi=8*atan(1.0); return -log(tan(0.5*(0.25*two_pi-atan(tfit_)))); } + double eta4par() const { static double two_pi=8*atan(1.0); + return -log(tan(0.5*(0.25*two_pi-atan(tfit4par_)))); } //double ieta() const { static double two_pi=8*atan(1.0); // return -log(tan(0.5*(0.25*two_pi-atan(itfit())))); } double etaseed() const { static double two_pi=8*atan(1.0); return -log(tan(0.5*(0.25*two_pi-atan(t_)))); } double z0() const { return z0fit_; } + double z04par() const { return z0fit4par_; } //double iz0() const { return iz0fit(); } double z0seed() const { return z0_; } - double chisq1() const {return chisq1_;} - double chisq2() const {return chisq2_;} + double chisq() const {return chisq_;} + double chisq4par() const {return chisq4par_;} - double chisq1dof() const {return chisq1_/(stubs_.size()-2);} - double chisq2dof() const {return chisq2_/(stubs_.size()-2);} + double chisqdof() const {return chisq_/(2*stubs_.size()-5);} + double chisqdof4par() const {return chisq4par_/(2*stubs_.size()-4);} - double chisq() const {return chisq1_+chisq2_; } - double chisqdof() const {return (chisq1_+chisq2_)/(2*stubs_.size()-4); } private: @@ -637,25 +669,26 @@ private: int SimTrackID_; double rinvfit_; double phi0fit_; + double d0fit_; double z0fit_; double tfit_; - int irinvfit_; - int iphi0fit_; - int iz0fit_; - int itfit_; + double rinvfit4par_; + double phi0fit4par_; + double z0fit4par_; + double tfit4par_; - double chisq1_; - double chisq2_; + double chisq_; + double chisq4par_; int ichisq1_; int ichisq2_; - double D_[4][40]; + double D_[5][40]; - double M_[4][8]; + double M_[5][10]; - double MinvDt_[4][40]; + double MinvDt_[5][40]; }; diff --git a/SimDataFormats/SLHC/interface/slhcevent.hh b/SimDataFormats/SLHC/interface/slhcevent.hh index e170cc2ce0e2b..2ac8822c198a4 100755 --- a/SimDataFormats/SLHC/interface/slhcevent.hh +++ b/SimDataFormats/SLHC/interface/slhcevent.hh @@ -257,9 +257,9 @@ public: bool foundclose=false; for (unsigned int i=0;i Date: Tue, 3 Jun 2014 13:20:31 +0200 Subject: [PATCH 033/252] updates from Nicola P --- .../L1DTPlusTrackTrigger/src/DTMatch.cc | 15 +- .../src/DTMatch_extrapolations.cc | 211 ++++----- .../L1DTPlusTrackTrigger/src/classes.h | 2 +- .../L1DTPlusTrackTrigger/src/classes_def.xml | 2 +- .../L1TrackTrigger/src/L1TkMuonParticle.cc | 10 +- .../plugins/DTPlusTrackProducer.cc | 24 +- .../plugins/DTPlusTrackProducer.h | 4 +- .../python/DTPlusTrackProducer_cfi.py | 6 +- .../src/DTUtilities_getDTTrigger.cc | 44 +- .../test/AnalyzerDTMatches.cc | 408 ++++++++++++------ .../test/AnalyzerDTMatches_cfg.py | 6 +- .../python/L1TkMuonSequence_cfi.py | 50 ++- 12 files changed, 483 insertions(+), 299 deletions(-) diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc index 24454264165de..23b88898c22b7 100644 --- a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc @@ -188,11 +188,11 @@ int DTMatch::getDTPt() float thisPhiB = fabs( static_cast< float >(this->getDTTSPhiB()) ); /// By Station + 2*Wheel - float B_Pt[10] = {667.8, 433.9, 757.4, 525.1, 751.6, 539.8, 757.2, 525.5, 667.0, 435.0}; + float B_Pt[10] = {-668.1, -433.6, -757.8, -524.7, -751.8, -539.5, -757.5, -525.6, -667.0, -435.0}; if ( thisPhiB > 0.0 ) { - return static_cast< int >( B_Pt[iSt+2*iWh] / thisPhiB ); + return static_cast< int >( fabs(B_Pt[iSt+2*iWh]) / thisPhiB ); } return 1000; @@ -213,12 +213,12 @@ int DTMatch::getDTPtMin( float nSigmas ) float thisSigmaPhiB = this->getPredSigmaPhiB(); /// By Station + 2*Wheel - float B_Pt[10] = {667.8, 433.9, 757.4, 525.1, 751.6, 539.8, 757.2, 525.5, 667.0, 435.0}; + float B_Pt[10] = {-668.1, -433.6, -757.8, -524.7, -751.8, -539.5, -757.5, -525.6, -667.0, -435.0}; if ( thisPhiB > 0.0 ) { float thisPhiBMax = thisPhiB + nSigmas * thisSigmaPhiB; - return static_cast< int >( B_Pt[iSt+2*iWh] / thisPhiBMax - 1); + return static_cast< int >( fabs(B_Pt[iSt+2*iWh]) / thisPhiBMax - 1); } return 0; @@ -239,12 +239,12 @@ int DTMatch::getDTPtMax( float nSigmas ) float thisSigmaPhiB = this->getPredSigmaPhiB(); /// By Station + 2*Wheel - float B_Pt[10] = {667.8, 433.9, 757.4, 525.1, 751.6, 539.8, 757.2, 525.5, 667.0, 435.0}; + float B_Pt[10] = {-668.1, -433.6, -757.8, -524.7, -751.8, -539.5, -757.5, -525.6, -667.0, -435.0}; if ( thisPhiB > 0.0 ) { float thisPhiBMin = thisPhiB - nSigmas * thisSigmaPhiB; - return static_cast< int >( B_Pt[iSt+2*iWh] / thisPhiBMin + 1); + return static_cast< int >( fabs(B_Pt[iSt+2*iWh]) / thisPhiBMin + 1); } return 1000; @@ -813,7 +813,8 @@ unsigned int DTMatch::findPtBin( float aPtInv, unsigned int aMethod ) thisPtBin = iBin; escapeFlag = true; } - else if ( stat == 2 && aPtInv > cutPtInvMB2[aMethod][iBin] ) /// Use the same thresholds as as Mu_2_1 + else if ( stat == 2 && aPtInv > cutPtInvMB2[aMethod][iBin] ) /// aMethod gives the line in the table + /// One line for each Mu_X_Y { thisPtBin = iBin; escapeFlag = true; diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc index f1999ed6973af..eb4b113e2770e 100644 --- a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch_extrapolations.cc @@ -45,126 +45,127 @@ void DTMatch::extrapolateToTrackerLayer( unsigned int aLayer ) {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}, - {0.016, 0.042, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.016, 0.042} }; + {0.016, 0.042, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.016, 0.041} }; float B_DeltaPhi_C[6][10] = { /// Layer, (2*Wheel + Station) - {13.0, 21.8, 11.7, 18.6, 12.0, 18.2, 11.8, 18.5, 13.1, 21.8}, - {12.6, 21.1, 11.4, 18.0, 11.6, 17.6, 11.4, 18.0, 12.6, 21.1}, + {13.0, 21.8, 11.7, 18.6, 11.9, 18.2, 11.8, 18.5, 13.1, 21.8}, + {12.6, 21.2, 11.3, 18.0, 11.6, 17.7, 11.4, 18.0, 12.6, 21.1}, {12.0, 20.3, 10.9, 17.3, 11.1, 17.0, 10.9, 17.3, 12.1, 20.3}, - {11.4, 19.4, 10.3, 16.5, 10.5, 16.2, 10.4, 16.5, 11.5, 19.3}, + {11.4, 19.4, 10.3, 16.5, 10.5, 16.2, 10.3, 16.5, 11.5, 19.3}, {10.7, 18.3, 9.7, 15.6, 9.9, 15.4, 9.7, 15.6, 10.8, 18.2}, - {10.1, 17.3, 9.1, 14.8, 9.3, 14.5, 9.1, 14.8, 10.1, 17.3} }; - + {10.1, 17.4, 9.1, 14.8, 9.3, 14.5, 9.1, 14.8, 10.1, 17.3} }; + /// Single float A_DeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) - {0.016, 0.042, 0.014, 0.033, 0.014, 0.031, 0.013, 0.033, 0.016, 0.042}, {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.014, 0.032, 0.016, 0.042}, + {0.016, 0.042, 0.014, 0.033, 0.014, 0.031, 0.014, 0.033, 0.016, 0.042}, {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.013, 0.033, 0.016, 0.042}, - {0.016, 0.042, 0.014, 0.033, 0.014, 0.031, 0.013, 0.033, 0.016, 0.042}, - {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.014, 0.032, 0.016, 0.042}, - {0.016, 0.043, 0.014, 0.032, 0.014, 0.031, 0.013, 0.032, 0.016, 0.042} }; + {0.016, 0.042, 0.014, 0.033, 0.014, 0.031, 0.013, 0.032, 0.016, 0.042}, + {0.016, 0.042, 0.014, 0.033, 0.014, 0.031, 0.013, 0.032, 0.016, 0.042}, + {0.016, 0.043, 0.014, 0.033, 0.014, 0.032, 0.013, 0.032, 0.016, 0.042} }; float B_DeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) - {13.3, 22.1, 11.8, 18.5, 11.9, 18.1, 11.8, 18.5, 13.3, 22.0}, - {12.8, 21.4, 11.4, 18.0, 11.5, 17.6, 11.4, 18.0, 12.9, 21.3}, + {13.3, 22.1, 11.7, 18.5, 11.9, 18.1, 11.7, 18.5, 13.3, 22.0}, + {12.8, 21.4, 11.3, 18.0, 11.5, 17.6, 11.4, 17.9, 12.8, 21.3}, {12.3, 20.6, 10.9, 17.3, 11.0, 16.9, 10.9, 17.3, 12.3, 20.5}, - {11.7, 19.6, 10.4, 16.5, 10.5, 16.2, 10.4, 16.5, 11.7, 19.6}, + {11.7, 19.6, 10.3, 16.5, 10.5, 16.2, 10.4, 16.5, 11.7, 19.6}, {11.0, 18.5, 9.7, 15.6, 9.8, 15.3, 9.7, 15.6, 11.0, 18.5}, - {10.3, 17.6, 9.1, 14.8, 9.3, 14.5, 9.1, 14.8, 10.4, 17.5} }; + {10.3, 17.6, 9.1, 14.8, 9.2, 14.4, 9.1, 14.7, 10.4, 17.5} }; /// Correlated float A_DeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) - {0.007, 0.017, 0.004, 0.011, -0.000, -0.000, -0.004, -0.011, -0.006, -0.017}, + {0.007, 0.018, 0.004, 0.011, 0.000, 0.000, -0.004, -0.011, -0.006, -0.017}, {0.006, 0.017, 0.004, 0.011, 0.000, 0.000, -0.004, -0.011, -0.006, -0.017}, - {0.006, 0.017, 0.004, 0.010, -0.000, -0.000, -0.004, -0.010, -0.006, -0.017}, - {0.005, 0.016, 0.004, 0.011, -0.000, 0.000, -0.004, -0.011, -0.006, -0.017}, + {0.006, 0.017, 0.004, 0.010, 0.000, -0.000, -0.004, -0.010, -0.006, -0.017}, + {0.006, 0.016, 0.004, 0.011, -0.000, 0.000, -0.004, -0.011, -0.006, -0.017}, {0.006, 0.017, 0.004, 0.009, 0.000, 0.000, -0.004, -0.009, -0.007, -0.017}, - {0.007, 0.017, 0.004, 0.010, -0.000, -0.000, -0.004, -0.009, -0.006, -0.015} }; + {0.007, 0.017, 0.004, 0.010, 0.000, -0.000, -0.004, -0.010, -0.006, -0.016} }; float C_DeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) - {-0.8, 12.6, 23.1, 27.3, 3.2, 2.1, -23.8, -26.5, -1.6, -10.1}, - {8.5, 16.6, 21.6, 24.1, 1.1, 0.2, -21.8, -22.1, -10.1, -13.5}, - {11.3, 18.0, 21.1, 23.7, 0.9, 0.7, -21.3, -21.5, -13.2, -14.6}, - {14.4, 20.0, 26.6, 9.6, -27.5, -17.9, 16.8, 12.2, -28.1, -9.6}, - {22.2, 16.7, 14.0, 18.0, -5.1, 2.4, -20.3, -26.6, -1.5, -13.8}, - {26.8, 28.6, 15.7, 17.5, -2.9, -5.1, -14.7, -19.9, -38.2, -27.4} }; + {-3.0, 11.9, 22.0, 27.1, 2.4, 2.6, -23.6, -25.6, -1.0, -9.0}, + {6.8, 15.9, 20.5, 23.8, 0.5, 0.6, -21.6, -21.2, -9.6, -12.5}, + {9.6, 17.4, 20.1, 23.5, 0.4, 1.0, -21.2, -20.6, -12.7, -13.6}, + {12.8, 19.3, 26.0, 8.8, -27.6, -17.7, 17.0, 13.4, -27.4, -9.0}, + {20.4, 16.1, 12.9, 17.7, -5.0, 2.8, -20.1, -25.8, -1.4, -13.2}, + {24.7, 28.0, 14.7, 17.2, -3.2, -4.9, -14.6, -19.1, -37.6, -26.7} }; /// Single float A_DeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) - {0.006, 0.018, 0.005, 0.011, -0.000, -0.000, -0.004, -0.011, -0.006, -0.017}, - {0.006, 0.017, 0.005, 0.011, 0.000, -0.000, -0.004, -0.010, -0.006, -0.017}, - {0.006, 0.017, 0.005, 0.010, 0.000, 0.000, -0.004, -0.010, -0.006, -0.017}, - {0.005, 0.015, 0.005, 0.011, -0.000, 0.000, -0.004, -0.012, -0.006, -0.016}, + {0.006, 0.017, 0.005, 0.012, -0.000, 0.000, -0.005, -0.011, -0.006, -0.017}, + {0.006, 0.017, 0.005, 0.011, 0.000, 0.000, -0.005, -0.011, -0.006, -0.017}, + {0.006, 0.017, 0.005, 0.011, 0.000, 0.000, -0.005, -0.010, -0.006, -0.017}, + {0.005, 0.015, 0.005, 0.012, -0.000, 0.000, -0.004, -0.012, -0.006, -0.016}, {0.007, 0.019, 0.005, 0.010, 0.000, 0.000, -0.005, -0.010, -0.005, -0.016}, - {0.006, 0.017, 0.004, 0.010, 0.000, -0.000, -0.004, -0.010, -0.006, -0.015} }; + {0.006, 0.017, 0.004, 0.010, 0.000, -0.000, -0.005, -0.010, -0.006, -0.015} }; float C_DeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) - {44.7, 32.5, 40.6, 40.0, 3.3, -1.0, -38.9, -43.3, -49.5, -33.0}, - {48.5, 34.2, 37.5, 37.0, 1.2, -0.8, -34.7, -38.0, -51.1, -33.4}, - {47.9, 36.1, 37.1, 35.0, 1.7, -1.7, -34.6, -34.8, -50.9, -36.0}, - {52.1, 56.9, 38.6, 39.4, -27.8, -15.4, 3.9, -0.2, -33.2, -25.4}, - {54.7, 30.0, 30.0, 33.4, -8.3, 5.3, -40.3, -46.0, -53.1, -37.3}, - {59.4, 49.6, 32.1, 30.9, -6.0, -6.1, -26.6, -34.4, -75.7, -50.8} }; + {43.7, 35.7, 38.0, 36.0, 2.2, 1.3, -38.5, -39.7, -49.0, -33.6}, + {48.1, 36.5, 34.4, 34.4, 0.6, 0.1, -35.0, -34.9, -52.9, -34.0}, + {47.7, 38.0, 34.4, 33.0, 1.0, -0.3, -34.7, -32.3, -52.9, -36.4}, + {51.8, 58.8, 36.1, 38.0, -27.7, -14.0, 3.8, 2.3, -35.3, -25.7}, + {55.2, 31.4, 27.4, 32.2, -8.4, 6.9, -41.0, -44.8, -55.3, -37.8}, + {61.0, 52.1, 29.8, 29.9, -6.4, -6.1, -26.4, -32.6, -80.5, -51.0} }; /// Functions to compute extrapolation windows + /// Correlated float A_SigmaDeltaPhi_C[6][10] = { /// Layer, (2*Wheel + Station) - {0.014, 0.078, 0.008, 0.038, 0.011, 0.040, 0.009, 0.038, 0.014, 0.077}, - {0.013, 0.075, 0.008, 0.038, 0.011, 0.039, 0.008, 0.037, 0.013, 0.075}, - {0.013, 0.072, 0.008, 0.036, 0.010, 0.038, 0.008, 0.036, 0.013, 0.072}, - {0.012, 0.069, 0.007, 0.035, 0.010, 0.036, 0.007, 0.035, 0.012, 0.069}, - {0.011, 0.066, 0.007, 0.033, 0.009, 0.035, 0.007, 0.033, 0.011, 0.065}, - {0.010, 0.061, 0.007, 0.031, 0.009, 0.033, 0.007, 0.031, 0.010, 0.061} }; + {0.014, 0.078, 0.008, 0.039, 0.011, 0.040, 0.009, 0.038, 0.014, 0.077}, + {0.013, 0.076, 0.008, 0.038, 0.011, 0.039, 0.008, 0.037, 0.013, 0.075}, + {0.013, 0.073, 0.008, 0.036, 0.010, 0.038, 0.008, 0.036, 0.013, 0.072}, + {0.012, 0.070, 0.007, 0.035, 0.010, 0.036, 0.007, 0.034, 0.012, 0.069}, + {0.011, 0.066, 0.007, 0.033, 0.009, 0.035, 0.007, 0.033, 0.011, 0.066}, + {0.010, 0.062, 0.007, 0.031, 0.009, 0.033, 0.007, 0.031, 0.010, 0.061} }; float C_SigmaDeltaPhi_C[6][10] = { /// Layer, (2*Wheel + Station) - {21.5, 39.7, 19.4, 33.1, 20.4, 32.2, 19.6, 32.8, 21.2, 39.6}, - {20.9, 38.2, 18.7, 32.0, 19.7, 31.2, 18.9, 31.8, 20.6, 38.1}, - {19.9, 36.9, 18.2, 31.0, 19.0, 30.3, 18.2, 30.8, 19.8, 36.8}, - {19.1, 35.1, 17.3, 29.8, 18.0, 29.0, 17.2, 29.4, 18.8, 34.9}, - {17.8, 33.0, 16.3, 28.4, 17.1, 27.4, 16.3, 27.9, 17.5, 32.7}, - {16.7, 31.0, 15.3, 26.9, 16.0, 25.9, 15.3, 26.6, 16.6, 30.9} }; + {21.6, 39.8, 19.6, 33.3, 20.5, 32.2, 19.8, 32.9, 21.6, 39.7}, + {20.9, 38.6, 18.8, 32.2, 19.9, 31.4, 19.1, 31.9, 20.7, 38.2}, + {19.9, 37.1, 18.4, 31.2, 19.1, 30.3, 18.5, 30.9, 20.0, 36.9}, + {19.1, 35.3, 17.4, 29.9, 18.1, 29.0, 17.4, 29.5, 19.0, 35.1}, + {17.8, 33.1, 16.4, 28.5, 17.3, 27.7, 16.5, 27.9, 17.9, 32.9}, + {16.8, 31.2, 15.4, 27.1, 16.1, 26.0, 15.5, 26.7, 16.7, 31.0} }; + /// Single float A_SigmaDeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) - {0.008, 0.048, 0.006, 0.025, 0.008, 0.026, 0.006, 0.024, 0.008, 0.047}, - {0.008, 0.047, 0.006, 0.025, 0.008, 0.025, 0.006, 0.023, 0.008, 0.046}, - {0.007, 0.046, 0.005, 0.024, 0.008, 0.025, 0.006, 0.023, 0.008, 0.045}, - {0.008, 0.044, 0.005, 0.023, 0.008, 0.024, 0.006, 0.022, 0.007, 0.045}, - {0.007, 0.043, 0.005, 0.022, 0.008, 0.023, 0.005, 0.022, 0.007, 0.042}, - {0.007, 0.041, 0.005, 0.022, 0.007, 0.022, 0.005, 0.021, 0.007, 0.040} }; + {0.008, 0.047, 0.006, 0.023, 0.007, 0.025, 0.005, 0.022, 0.008, 0.047}, + {0.008, 0.046, 0.005, 0.023, 0.007, 0.024, 0.005, 0.022, 0.008, 0.047}, + {0.008, 0.045, 0.005, 0.022, 0.007, 0.024, 0.005, 0.022, 0.007, 0.046}, + {0.007, 0.043, 0.005, 0.022, 0.007, 0.023, 0.004, 0.021, 0.007, 0.044}, + {0.007, 0.042, 0.005, 0.021, 0.006, 0.022, 0.004, 0.020, 0.007, 0.043}, + {0.007, 0.041, 0.005, 0.021, 0.006, 0.021, 0.004, 0.020, 0.006, 0.040} }; float C_SigmaDeltaPhi_S[6][10] = { /// Layer, (2*Wheel + Station) - {162.7, 288.3, 159.5, 260.5, 168.9, 283.5, 137.6, 263.3, 146.3, 293.4}, - {156.5, 280.3, 156.3, 253.7, 164.2, 275.9, 133.4, 257.3, 140.5, 283.6}, - {152.2, 269.6, 149.1, 243.0, 157.2, 265.4, 127.2, 247.2, 135.2, 272.6}, - {143.8, 257.6, 141.3, 233.2, 150.4, 254.3, 121.3, 235.4, 129.2, 260.3}, - {136.2, 243.3, 132.6, 221.5, 141.5, 240.2, 113.8, 223.2, 121.3, 247.8}, - {127.5, 229.0, 124.9, 209.5, 134.2, 230.0, 107.5, 213.1, 114.4, 230.7} }; - + {165.1, 327.0, 172.5, 306.0, 196.2, 317.3, 171.3, 301.0, 163.4, 324.3}, + {159.3, 315.9, 167.8, 298.5, 191.0, 309.1, 166.8, 293.7, 158.2, 312.6}, + {153.0, 304.3, 161.4, 287.7, 183.2, 299.4, 159.5, 283.6, 152.9, 300.6}, + {146.5, 291.0, 153.2, 273.6, 175.0, 285.8, 152.6, 269.6, 144.9, 290.3}, + {137.3, 275.3, 144.1, 260.4, 163.9, 269.7, 142.7, 256.6, 136.2, 272.9}, + {130.2, 259.1, 135.7, 247.8, 154.6, 257.3, 134.6, 242.4, 130.5, 255.6} }; + /// Correlated float A_SigmaDeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) - {0.0098, 0.0412, 0.0037, 0.0185, 0.0004, 0.0023, 0.0036, 0.0195, 0.0090, 0.0401}, - {0.0078, 0.0409, 0.0040, 0.0176, 0.0006, 0.0026, 0.0042, 0.0180, 0.0079, 0.0419}, - {0.0098, 0.0432, 0.0040, 0.0173, 0.0008, 0.0027, 0.0042, 0.0177, 0.0079, 0.0434}, - {0.0099, 0.0442, 0.0063, 0.0184, 0.0003, 0.0063, 0.0059, 0.0223, 0.0087, 0.0455}, - {0.0096, 0.0469, 0.0061, 0.0191, 0.0005, 0.0032, 0.0053, 0.0178, 0.0089, 0.0519}, - {0.0124, 0.0451, 0.0054, 0.0175, 0.0009, 0.0032, 0.0056, 0.0211, 0.0100, 0.0434} }; - + {0.0016, 0.0060, 0.0011, 0.0029, 0.0004, 0.0009, 0.0011, 0.0028, 0.0014, 0.0056}, + {0.0013, 0.0053, 0.0008, 0.0025, 0.0005, 0.0013, 0.0009, 0.0025, 0.0012, 0.0054}, + {0.0015, 0.0061, 0.0009, 0.0027, 0.0007, 0.0018, 0.0010, 0.0027, 0.0014, 0.0059}, + {0.0016, 0.0072, 0.0013, 0.0021, 0.0007, 0.0013, 0.0010, 0.0021, 0.0010, 0.0064}, + {0.0013, 0.0062, 0.0009, 0.0029, 0.0008, 0.0012, 0.0012, 0.0036, 0.0012, 0.0065}, + {0.0019, 0.0077, 0.0011, 0.0037, 0.0012, 0.0030, 0.0011, 0.0037, 0.0020, 0.0073} }; float C_SigmaDeltaTheta_C[6][10] = { /// Layer, (2*Wheel + Station) - {319.0, 351.6, 524.7, 571.8, 730.7, 739.3, 526.0, 569.6, 322.1, 355.0}, - {212.0, 226.9, 331.5, 363.0, 461.0, 464.1, 332.5, 360.9, 212.5, 227.3}, - {144.1, 153.9, 231.6, 249.4, 318.1, 322.6, 232.3, 247.7, 148.1, 155.2}, - {118.5, 122.4, 176.2, 209.0, 211.6, 233.2, 178.0, 186.8, 123.1, 124.3}, - {93.5, 91.5, 140.1, 142.3, 203.2, 198.2, 134.8, 148.0, 97.0, 91.5}, - {73.4, 80.8, 118.9, 124.7, 170.2, 165.9, 118.3, 117.8, 79.2, 84.4} }; + {331.6, 370.2, 537.0, 588.8, 729.3, 741.6, 537.3, 590.4, 333.1, 369.8}, + {216.6, 237.8, 343.9, 377.1, 462.2, 468.5, 343.8, 376.9, 217.7, 237.6}, + {154.2, 166.9, 240.4, 264.1, 321.5, 326.1, 240.2, 263.9, 155.0, 166.6}, + {117.9, 125.4, 189.7, 225.4, 250.7, 268.4, 195.0, 220.7, 127.7, 129.3}, + {101.8, 106.1, 151.2, 158.3, 195.4, 201.9, 147.0, 149.6, 103.1, 104.1}, + {84.1, 87.7, 124.9, 133.3, 165.7, 163.9, 125.7, 133.0, 80.5, 87.6} }; + /// Single float A_SigmaDeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) - {0.0109, 0.0345, 0.0059, 0.0186, 0.0011, 0.0016, 0.0054, 0.0205, 0.0047, 0.0360}, - {0.0118, 0.0416, 0.0065, 0.0201, 0.0009, 0.0021, 0.0047, 0.0187, 0.0067, 0.0447}, - {0.0098, 0.0430, 0.0075, 0.0207, 0.0010, 0.0029, 0.0047, 0.0203, 0.0089, 0.0576}, - {0.0098, 0.0351, 0.0100, 0.0259, 0.0001, 0.0027, 0.0090, 0.0257, 0.0093, 0.0506}, - {0.0126, 0.0564, 0.0084, 0.0222, 0.0001, 0.0023, 0.0055, 0.0211, 0.0102, 0.0497}, - {0.0136, 0.0675, 0.0072, 0.0251, 0.0009, 0.0033, 0.0086, 0.0237, 0.0125, 0.0441} }; - + {0.0020, 0.0041, 0.0013, 0.0036, 0.0004, 0.0016, 0.0013, 0.0029, 0.0015, 0.0043}, + {0.0009, 0.0034, 0.0007, 0.0022, 0.0003, 0.0011, 0.0007, 0.0017, 0.0011, 0.0032}, + {0.0013, 0.0047, 0.0008, 0.0026, 0.0005, 0.0017, 0.0008, 0.0022, 0.0013, 0.0046}, + {0.0013, 0.0067, 0.0014, 0.0005, 0.0005, 0.0013, 0.0015, 0.0007, 0.0009, 0.0075}, + {0.0012, 0.0078, 0.0011, 0.0029, 0.0007, 0.0012, 0.0009, 0.0044, 0.0009, 0.0068}, + {0.0015, 0.0083, 0.0012, 0.0042, 0.0009, 0.0026, 0.0010, 0.0036, 0.0020, 0.0074} }; float C_SigmaDeltaTheta_S[6][10] = { /// Layer, (2*Wheel + Station) - {349.9, 381.4, 527.4, 581.6, 712.4, 725.4, 551.5, 585.6, 350.7, 392.2}, - {226.9, 250.8, 343.2, 373.4, 458.1, 460.3, 358.4, 375.3, 230.5, 258.0}, - {157.4, 169.9, 236.1, 255.5, 320.0, 315.9, 247.0, 260.3, 157.0, 174.2}, - {133.2, 146.5, 181.1, 226.3, 220.3, 237.4, 196.8, 205.4, 132.2, 149.3}, - {103.9, 108.0, 142.1, 162.0, 202.2, 191.0, 156.4, 161.3, 93.4, 116.1}, - {77.8, 90.2, 119.5, 128.7, 168.7, 167.2, 119.5, 134.1, 78.2, 85.1} }; + {375.5, 417.5, 545.7, 600.7, 720.8, 734.0, 551.0, 605.1, 383.2, 420.0}, + {243.0, 270.2, 353.8, 389.7, 459.0, 467.7, 359.1, 392.0, 247.5, 271.2}, + {171.7, 189.8, 253.7, 275.3, 322.6, 326.6, 258.3, 276.6, 176.4, 190.9}, + {132.0, 136.6, 195.3, 237.8, 248.3, 271.4, 198.6, 232.0, 138.4, 133.4}, + {109.7, 108.6, 155.5, 167.3, 198.6, 207.9, 164.4, 156.0, 113.1, 110.5}, + {86.8, 90.7, 132.6, 135.6, 172.3, 165.0, 142.0, 137.4, 85.6, 92.1} }; int bitShift = 8; @@ -248,31 +249,31 @@ void DTMatch::extrapolateToVertex() /// By 2*Wheel+Station float A_DeltaPhi_C[10] = {0.015, 0.041, 0.013, 0.032, 0.014, 0.031, 0.013, 0.032, 0.015, 0.041}; - float B_DeltaPhi_C[10] = {13.8, 23.1, 12.5, 19.6, 12.7, 19.2, 12.5, 19.6, 13.9, 23.0}; - float A_DeltaPhi_S[10] = {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.014, 0.032, 0.016, 0.042}; - float B_DeltaPhi_S[10] = {14.1, 23.3, 12.5, 19.6, 12.6, 19.1, 12.5, 19.6, 14.1, 23.2}; - float A_DeltaTheta_C[10] = {0.006, 0.015, 0.004, 0.009, -0.000, -0.000, -0.004, -0.009, -0.006, -0.015}; - float C_DeltaTheta_C[10] = {23.3, 24.0, 22.0, 24.5, 0.8, 0.1, -21.9, -23.0, -25.1, -20.3}; - float A_DeltaTheta_S[10] = {0.006, 0.016, 0.005, 0.010, -0.000, -0.000, -0.004, -0.009, -0.006, -0.016}; - float C_DeltaTheta_S[10] = {51.3, 42.7, 42.9, 36.7, 1.5, -0.2, -38.9, -36.6, -52.4, -40.8}; + float B_DeltaPhi_C[10] = {13.8, 23.1, 12.4, 19.6, 12.7, 19.2, 12.5, 19.5, 13.9, 23.0}; + float A_DeltaPhi_S[10] = {0.016, 0.042, 0.014, 0.033, 0.014, 0.032, 0.013, 0.032, 0.016, 0.042}; + float B_DeltaPhi_S[10] = {14.0, 23.3, 12.4, 19.6, 12.6, 19.1, 12.5, 19.5, 14.1, 23.2}; + float A_DeltaTheta_C[10] = {0.006, 0.016, 0.004, 0.009, -0.000, -0.000, -0.004, -0.009, -0.006, -0.016}; + float C_DeltaTheta_C[10] = {21.8, 23.3, 20.9, 24.4, 0.7, 0.4, -22.0, -22.1, -24.9, -19.4}; + float A_DeltaTheta_S[10] = {0.006, 0.016, 0.005, 0.010, -0.000, -0.000, -0.005, -0.010, -0.006, -0.016}; + float C_DeltaTheta_S[10] = {51.9, 44.3, 40.0, 35.8, 1.8, 0.1, -39.9, -34.3, -56.2, -41.0}; /// Extrapolation windows - float A_SigmaDeltaPhi_C[10] = {0.015, 0.081, 0.009, 0.040, 0.012, 0.042, 0.009, 0.040, 0.015, 0.081}; - float C_SigmaDeltaPhi_C[10] = {23.0, 41.1, 20.7, 35.3, 21.8, 34.0, 20.9, 34.9, 22.7, 41.1}; - float A_SigmaDeltaPhi_S[10] = {0.008, 0.050, 0.006, 0.025, 0.009, 0.026, 0.006, 0.024, 0.009, 0.049}; - float C_SigmaDeltaPhi_S[10] = {172.0, 303.3, 168.2, 274.3, 177.8, 296.9, 144.8, 275.0, 153.2, 306.0}; - float A_SigmaDeltaTheta_C[10] = {0.0098, 0.0437, 0.0052, 0.0185, 0.0017, 0.0049, 0.0054, 0.0187, 0.0098, 0.0432}; - float C_SigmaDeltaTheta_C[10] = {55.4, 46.2, 79.8, 71.3, 103.4, 87.9, 79.5, 71.0, 55.2, 46.4}; - float A_SigmaDeltaTheta_S[10] = {0.0113, 0.0546, 0.0078, 0.0228, 0.0015, 0.0048, 0.0061, 0.0224, 0.0103, 0.0523}; - float C_SigmaDeltaTheta_S[10] = {55.0, 58.0, 92.2, 83.4, 110.6, 95.3, 93.5, 82.8, 53.8, 55.4}; + float A_SigmaDeltaPhi_C[10] = {0.015, 0.082, 0.009, 0.040, 0.012, 0.042, 0.009, 0.040, 0.015, 0.081}; + float C_SigmaDeltaPhi_C[10] = {23.0, 41.5, 20.9, 35.5, 21.9, 34.0, 21.1, 34.9, 23.1, 41.3}; + float A_SigmaDeltaPhi_S[10] = {0.008, 0.049, 0.006, 0.024, 0.007, 0.025, 0.005, 0.023, 0.008, 0.049}; + float C_SigmaDeltaPhi_S[10] = {173.6, 341.1, 181.9, 321.9, 206.6, 334.1, 180.5, 315.0, 173.5, 338.8}; + float A_SigmaDeltaTheta_C[10] = {0.0021, 0.0084, 0.0014, 0.0050, 0.0014, 0.0041, 0.0014, 0.0050, 0.0021, 0.0083}; + float C_SigmaDeltaTheta_C[10] = {55.5, 50.3, 81.0, 72.4, 105.4, 89.1, 81.3, 72.1, 56.7, 49.8}; + float A_SigmaDeltaTheta_S[10] = {0.0020, 0.0082, 0.0012, 0.0045, 0.0011, 0.0040, 0.0012, 0.0046, 0.0020, 0.0083}; + float C_SigmaDeltaTheta_S[10] = {54.0, 53.1, 97.4, 82.7, 112.8, 92.1, 98.8, 82.7, 55.2, 52.6}; /// Error on PhiB vs. PhiB - float A_SigmaPhiB_C[10] = {0.00069, 0.00219, 0.00050, 0.00132, 0.00058, 0.00146, 0.00050, 0.00130, 0.00068, 0.00219}; - float B_SigmaPhiB_C[10] = {0.046, 0.069, 0.034, 0.044, 0.035, 0.041, 0.034, 0.045, 0.046, 0.068}; + float A_SigmaPhiB_C[10] = {0.00070, 0.00218, 0.00050, 0.00131, 0.00059, 0.00146, 0.00050, 0.00129, 0.00069, 0.00219}; + float B_SigmaPhiB_C[10] = {0.044, 0.068, 0.032, 0.043, 0.033, 0.040, 0.032, 0.044, 0.044, 0.067}; float C_SigmaPhiB_C[10] = {1.3, 1.5, 1.4, 1.5, 1.4, 1.5, 1.4, 1.5, 1.3, 1.5}; - float A_SigmaPhiB_S[10] = {0.00047, 0.00163, 0.00030, 0.00092, 0.00042, 0.00091, 0.00060, 0.00082, 0.00055, 0.00158}; + float A_SigmaPhiB_S[10] = {0.00048, 0.00147, 0.00028, 0.00074, 0.00032, 0.00079, 0.00029, 0.00073, 0.00047, 0.00149}; float B_SigmaPhiB_S[10] = {0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000}; - float C_SigmaPhiB_S[10] = {12.2, 12.7, 13.6, 13.5, 13.9, 14.7, 10.1, 13.6, 10.7, 12.9}; + float C_SigmaPhiB_S[10] = {12.0, 14.2, 14.3, 15.7, 16.0, 16.6, 13.9, 15.5, 11.9, 14.1}; /// Integer calculations: shift by 3 bits to preserve resolution int bitShift = 8; diff --git a/DataFormats/L1DTPlusTrackTrigger/src/classes.h b/DataFormats/L1DTPlusTrackTrigger/src/classes.h index 0f11756b356a8..e2ee132cdc2f4 100644 --- a/DataFormats/L1DTPlusTrackTrigger/src/classes.h +++ b/DataFormats/L1DTPlusTrackTrigger/src/classes.h @@ -28,7 +28,7 @@ namespace edm::Wrapper< DTMatch > wDTM; std::vector< DTMatch > vDTM; edm::Wrapper< std::vector< DTMatch > > wVDTM; - edm::Ptr< DTMatch > ptrDTM; + edm::Ptr< DTMatch > ptrDTM; std::string STR; edm::Wrapper wSTR; diff --git a/DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml b/DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml index fbddd6ee36587..37e49ef76ad83 100644 --- a/DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml +++ b/DataFormats/L1DTPlusTrackTrigger/src/classes_def.xml @@ -19,10 +19,10 @@ - + diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index af99753b92370..fb00be02fd288 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -17,8 +17,14 @@ L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, TrkzVtx_(999.), quality_(999) { - // need to set the z of the track - + // for DTMatch'es matched to a L1Track: set the reference + // to this L1Tracks and its zvertex + const edm::Ptr< TTTrack< Ref_PixelDigi_ > >& trkref = theDTMatch -> DTMatchBase::getPtMatchedTrackPtr(); + setTrkPtr( trkref ); + if ( trkPtr_.isNonnull() ) { + float z = getTrkPtr() -> getPOCA().z(); + setTrkzVtx( z ); + } } diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc index 6547d37051f5c..46ad104d30af8 100644 --- a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc +++ b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc @@ -24,7 +24,9 @@ DTPlusTrackProducer::DTPlusTrackProducer( const edm::ParameterSet& pSet ) : useRoughTheta = pSet.getUntrackedParameter< bool >( "useRoughTheta", false ); /// Get the size of matching windows in terms of sigmas - numSigmas = pSet.getUntrackedParameter< double >( "numSigmasForMatch", 3. ); + numSigmasStub = pSet.getUntrackedParameter< double >( "numSigmasForStubMatch", 4. ); + numSigmasTk = pSet.getUntrackedParameter< double >( "numSigmasForTkMatch", 3. ); + numSigmasPt = pSet.getUntrackedParameter< double >( "numSigmasForPtMatch", 3. ); /// Get some constraints for finding the Pt with several methods minRInvB = pSet.getUntrackedParameter< double >( "minRInvB", 0.00000045 ); @@ -320,12 +322,12 @@ std::cerr<getPredStubPhi(lay) << " +/- " << thisDTMatch->getPredStubSigmaPhi(lay) << std::endl; std::cerr << " deltaPhi " << thisDeltaPhi << std::endl; - std::cerr << " STUB is it in phi window? " << thisDTMatch->checkStubPhiMatch( stubPhi, lay, numSigmas ) << std::endl; + std::cerr << " STUB is it in phi window? " << thisDTMatch->checkStubPhiMatch( stubPhi, lay, numSigmasStub ) << std::endl; #endif /// If within the window, and update the closest stub if any - if ( thisDTMatch->checkStubPhiMatch( stubPhi, lay, numSigmas ) && - thisDTMatch->checkStubThetaMatch( stubTheta, lay, numSigmas ) ) + if ( thisDTMatch->checkStubPhiMatch( stubPhi, lay, numSigmasStub ) && + thisDTMatch->checkStubThetaMatch( stubTheta, lay, numSigmasStub ) ) { #ifdef npDEBUG std::cerr << "*** found good match in layer " << lay << std::endl; @@ -399,16 +401,16 @@ std::cerr<getPredVtxPhi() << " +/- " << thisDTMatch->getPredVtxSigmaPhi() << std::endl; std::cerr << " deltaPhi " << thisDeltaPhi << std::endl; - std::cerr << " TRACK is it in phi window? " << thisDTMatch->checkVtxPhiMatch( tkPhi, numSigmas ) << std::endl; + std::cerr << " TRACK is it in phi window? " << thisDTMatch->checkVtxPhiMatch( tkPhi, numSigmasTk ) << std::endl; std::cerr << " track theta converted to integer " << tkTheta << std::endl; std::cerr << " predicted theta " << thisDTMatch->getPredVtxTheta() << " +/- " << thisDTMatch->getPredVtxSigmaTheta() << std::endl; - std::cerr << " TRACK is it in theta window? " << thisDTMatch->checkVtxThetaMatch( tkTheta, numSigmas ) << std::endl; + std::cerr << " TRACK is it in theta window? " << thisDTMatch->checkVtxThetaMatch( tkTheta, numSigmasTk ) << std::endl; #endif /// If within the window, and update the closest stub if any - if ( thisDTMatch->checkVtxPhiMatch( tkPhi, numSigmas ) && - thisDTMatch->checkVtxThetaMatch( tkTheta, numSigmas ) ) + if ( thisDTMatch->checkVtxPhiMatch( tkPhi, numSigmasTk ) && + thisDTMatch->checkVtxThetaMatch( tkTheta, numSigmasTk ) ) { #ifdef npDEBUG std::cerr << "*** found good match at vertex" << std::endl; @@ -469,12 +471,12 @@ std::cerr<getDTPt(); - int dtPtMin = thisDTMatch->getDTPtMin( numSigmas ); - int dtPtMax = thisDTMatch->getDTPtMax( numSigmas ); + int dtPtMin = thisDTMatch->getDTPtMin( numSigmasPt ); + int dtPtMax = thisDTMatch->getDTPtMax( numSigmasPt ); #ifdef npDEBUG std::cerr << "* DT Match in MB" << i << ", no. " << j << std::endl; - std::cerr << " has this Pt range " << dtPtMin << " .. " << dtPt << " .. " << dtPtMax << " with no. sigmas = " << numSigmas << std::endl; + std::cerr << " has this Pt range " << dtPtMin << " .. " << dtPt << " .. " << dtPtMax << " with no. sigmas = " << numSigmasPt << std::endl; #endif /// Now check the best track diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h index fdf7b404c4b6e..4810b24fc4bd2 100644 --- a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h +++ b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h @@ -52,7 +52,9 @@ class DTPlusTrackProducer : public edm::EDProducer bool useRoughTheta; /// How many sigmas for the stub matching? - double numSigmas; + double numSigmasStub; + double numSigmasTk; + double numSigmasPt; /// Some constraints for finding the Pt with several methods double minRInvB; diff --git a/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py b/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py index 7b045df116a22..21d36f29bfc19 100644 --- a/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py +++ b/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py @@ -13,9 +13,11 @@ digiTag = cms.InputTag('simMuonDTDigis'), # needed by DTTrig useTSTheta = cms.untracked.bool(True), - useRoughTheta = cms.untracked.bool(False), + useRoughTheta = cms.untracked.bool(True), - numSigmasForMatch = cms.untracked.double(3.), + numSigmasForStubMatch = cms.untracked.double(4.), + numSigmasForTkMatch = cms.untracked.double(3.), + numSigmasForPtMatch = cms.untracked.double(3.), minRInvB = cms.untracked.double( 0.00000045 ), maxRInvB = cms.untracked.double( 1.0 ), diff --git a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc index c1931d38fdf26..239722a1c3c89 100644 --- a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc +++ b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc @@ -179,7 +179,7 @@ void DTUtilities::getDTTrigger() bool foundTSPhiTSThetaMatch = false; if ( useTSTheta && doneTSTheta && - ( iterTSPhi->station() == 1 || iterTSPhi->station()==2 ) ) + ( iterTSPhi->station() == 1 || iterTSPhi->station() == 2 ) ) { for ( TSThetaTrigsCollection::iterator thisTSTheta = theTSThetaTrigsToStore->begin(); thisTSTheta != theTSThetaTrigsToStore->end(); @@ -257,22 +257,19 @@ void DTUtilities::getDTTrigger() GlobalPoint posMatch( pos.x(), pos.y(), posBti.z() ); /// Correct for asymmetries in muon LUT's - if ( wh == 1 || wh == 2 || - ( wh == 0 && - ( se == 2 || se == 3 || se == 6 || se == 7 || se == 10 || se == 11) ) ) + if ( code < 16 ) { - /// Positive wheels - if ( code < 16 ) + if ( wh == 1 || wh == 2 || + ( wh == 0 && + ( se == 2 || se == 3 || se == 6 || se == 7 || se == 10 || se == 11) ) ) { - phib = phib - ( -23 + 2*st + wh ) - 1; + /// Positive wheels + phib = phib - ( -17 + 4*(st-1) ) - (3-wh); } - } - else - { - /// Negative wheels - if ( code < 16 ) + else { - phib = phib - ( 11 + 6*st + wh ) + 3; + /// Negative wheels + phib = phib - ( 11 + 4*(st-1) ) - (-3-wh); } } @@ -362,22 +359,19 @@ void DTUtilities::getDTTrigger() GlobalPoint posMatch( pos.x(), pos.y(), posCentralWire.z() ); /// Correct for asymmetries in muon LUT's - if ( wh == 1 || wh == 2 || - ( wh == 0 && - ( se == 2 || se == 3 || se == 6 || se == 7 || se == 10 || se == 11) ) ) + if ( code < 16 ) { - /// Positive wheels - if ( code < 16 ) + if ( wh == 1 || wh == 2 || + ( wh == 0 && + ( se == 2 || se == 3 || se == 6 || se == 7 || se == 10 || se == 11) ) ) { - phib = phib - ( -23 + 2*st + wh ) - 1; + /// Positive wheels + phib = phib - ( -17 + 4*(st-1) ) - (3-wh); } - } - else - { - /// Negative wheels - if ( code < 16 ) + else { - phib = phib - ( 11 + 6*st + wh ) + 3; + /// Negative wheels + phib = phib - ( 11 + 4*(st-1) ) - (-3-wh); } } diff --git a/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc index ccb1bcbd164ea..3ce2d2b55c0f0 100644 --- a/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc +++ b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches.cc @@ -73,6 +73,14 @@ class AnalyzerDTMatches : public edm::EDAnalyzer bool useBothMuonCharges; bool selectPositiveMuons; + std::string theMethods[16] = { + std::string("Mu_2_1"), + std::string("Mu_3_1"), std::string("Mu_3_2"), + std::string("Mu_4_1"), std::string("Mu_4_2"), std::string("Mu_4_3"), + std::string("Mu_5_1"), std::string("Mu_5_2"), std::string("Mu_5_3"), std::string("Mu_5_4"), + std::string("Mu_6_1"), std::string("Mu_6_2"), std::string("Mu_6_3"), std::string("Mu_6_4"), std::string("Mu_6_5"), + std::string("TTTrack") }; + /// Histograms /// identified by pair< wheel, MB > /// each propagation goes into a vector< layer > where L0 gives the @@ -133,6 +141,8 @@ class AnalyzerDTMatches : public edm::EDAnalyzer std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaPull_TK_H; std::map< std::pair< int, int >, std::vector< TH1F* > > mapWS_v_hDeltaThetaPull_TK_L; + std::map< std::pair< std::string, int >, TH1F* > mapMS_hDTMatch_InvPt; + TH1F* hMuonTP_Pt_DT; TH1F* hMuonTP_Pt_DTTF; TH1F* hMuonTP_Pt_DTMatch; @@ -142,6 +152,7 @@ class AnalyzerDTMatches : public edm::EDAnalyzer TH1F* hMuonTP_Pt_DTMatch_MajorityFull; TH1F* hMuonTP_Pt_DTMatch_Priority; TH1F* hMuonTP_Pt_DTMatch_Average; + TH1F* hMuonTP_Pt_DTMatch_TTTrackFullReso; TH1F* hMuonTP_PtBin_DT; TH1F* hMuonTP_PtBin_DTTF; @@ -152,6 +163,27 @@ class AnalyzerDTMatches : public edm::EDAnalyzer TH1F* hMuonTP_PtBin_DTMatch_MajorityFull; TH1F* hMuonTP_PtBin_DTMatch_Priority; TH1F* hMuonTP_PtBin_DTMatch_Average; + TH1F* hMuonTP_PtBin_DTMatch_TTTrackFullReso; + + TH1F* hMuonTP_Eta_DT; + TH1F* hMuonTP_Eta_DTTF; + TH1F* hMuonTP_Eta_DTMatch; + TH1F* hMuonTP_Eta_DTMatch_TTTrack; + TH1F* hMuonTP_Eta_DTMatch_Majority; + TH1F* hMuonTP_Eta_DTMatch_MixedMode; + TH1F* hMuonTP_Eta_DTMatch_MajorityFull; + TH1F* hMuonTP_Eta_DTMatch_Priority; + TH1F* hMuonTP_Eta_DTMatch_Average; + TH1F* hMuonTP_Eta_DTMatch_TTTrackFullReso; + + TH2F* hDTTF_PtBin_MuonTP_Pt; + TH2F* hDTMatch_TTrack_PtBin_MuonTP_Pt; + TH2F* hDTMatch_Majority_PtBin_MuonTP_Pt; + TH2F* hDTMatch_MixedMode_PtBin_MuonTP_Pt; + TH2F* hDTMatch_MajorityFull_PtBin_MuonTP_Pt; + TH2F* hDTMatch_Priority_PtBin_MuonTP_Pt; + TH2F* hDTMatch_Average_PtBin_MuonTP_Pt; + TH2F* hDTMatch_TTTrackFullReso_Pt_MuonTP_Pt; /// Containers of parameters passed by python /// configuration file @@ -199,7 +231,7 @@ void AnalyzerDTMatches::beginJob() edm::Service< TFileService > fs; /// Prepare for DT Pt-bin way - int NumBins = 24; + int NumBins = 25; double* BinVec = new double[NumBins+1]; BinVec[0] = 0; BinVec[1] = 4; @@ -226,21 +258,7 @@ void AnalyzerDTMatches::beginJob() BinVec[22] = 100; BinVec[23] = 120; BinVec[24] = 140; - //BinVec[25] = 200; - -/* - /// Prepare for LogXY Plots - int NumBins = 200; - double MinPt = 0.0; - double MaxPt = 100.0; - - double* BinVec = new double[NumBins+1]; - for ( int iBin = 0; iBin < NumBins + 1; iBin++ ) - { - double temp = pow( 10, (- NumBins + iBin)/(MaxPt - MinPt) ); - BinVec[ iBin ] = temp; - } -*/ + BinVec[25] = 200; for ( int iWh = -2; iWh < 3; iWh++ ) { @@ -463,37 +481,50 @@ void AnalyzerDTMatches::beginJob() { histoName.str(""); histoName << "hDeltaPhiPull_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; histoTitle.str(""); histoTitle << "Pull #Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; - mapWS_v_hDeltaPhiPull_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaPhiPull_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -10, 10 ) ); mapWS_v_hDeltaPhiPull_TK_C[thisKey].at(iLay)->Sumw2(); histoName.str(""); histoName << "hDeltaPhiPull_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; histoTitle.str(""); histoTitle << "Pull #Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; - mapWS_v_hDeltaPhiPull_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaPhiPull_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -10, 10 ) ); mapWS_v_hDeltaPhiPull_TK_H[thisKey].at(iLay)->Sumw2(); histoName.str(""); histoName << "hDeltaPhiPull_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; histoTitle.str(""); histoTitle << "Pull #Delta#phi in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; - mapWS_v_hDeltaPhiPull_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaPhiPull_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -10, 10 ) ); mapWS_v_hDeltaPhiPull_TK_L[thisKey].at(iLay)->Sumw2(); histoName.str(""); histoName << "hDeltaThetaPull_TK_C_" << iWh+2 << "_" << iSt-1 << "_" << iLay; histoTitle.str(""); histoTitle << "Pull #Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", correlated"; - mapWS_v_hDeltaThetaPull_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaThetaPull_TK_C[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -10, 10 ) ); mapWS_v_hDeltaThetaPull_TK_C[thisKey].at(iLay)->Sumw2(); histoName.str(""); histoName << "hDeltaThetaPull_TK_H_" << iWh+2 << "_" << iSt-1 << "_" << iLay; histoTitle.str(""); histoTitle << "Pull #Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", H single"; - mapWS_v_hDeltaThetaPull_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaThetaPull_TK_H[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -10, 10 ) ); mapWS_v_hDeltaThetaPull_TK_H[thisKey].at(iLay)->Sumw2(); histoName.str(""); histoName << "hDeltaThetaPull_TK_L_" << iWh+2 << "_" << iSt-1 << "_" << iLay; histoTitle.str(""); histoTitle << "Pull #Delta#theta in wheel (Tk wrt Pred Tk) " << iWh << " station " << iSt << " layer " << iLay << ", L single"; - mapWS_v_hDeltaThetaPull_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 100, -10, 10 ) ); + mapWS_v_hDeltaThetaPull_TK_L[thisKey].push_back( fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 400, -10, 10 ) ); mapWS_v_hDeltaThetaPull_TK_L[thisKey].at(iLay)->Sumw2(); } /// End pulls } } + for ( int iMeth = 0; iMeth < 16; iMeth++ ) + { + for ( int iSt = 1; iSt < 3; iSt++ ) + { + std::pair< std::string, int > thisKey = std::make_pair(theMethods[iMeth], iSt); + + histoName.str(""); histoName << "hDTMatch_InvPt_" << theMethods[iMeth].c_str() << "_" << iSt-1; + histoTitle.str(""); histoTitle << "Pt Method " << theMethods[iMeth].c_str() << " station " << iSt; + mapMS_hDTMatch_InvPt[thisKey] = fs->make( histoName.str().c_str(), histoTitle.str().c_str(), 1000, 0, 0.5 ); + mapMS_hDTMatch_InvPt[thisKey]->Sumw2(); + } + } + /// Pt for matching efficiencies hMuonTP_Pt_DT = fs->make( "hMuonTP_Pt_DT", "sim muon p_{T}, signal in DT", 200, 0, 200 ); hMuonTP_Pt_DTTF = fs->make( "hMuonTP_Pt_DTTF", "sim muon p_{T}, w/ DTTF", 200, 0, 200 ); @@ -504,6 +535,7 @@ void AnalyzerDTMatches::beginJob() hMuonTP_Pt_DTMatch_MajorityFull = fs->make( "hMuonTP_Pt_DTMatch_MajorityFull", "sim muon p_{T}, DTMatch + Stubs, Majority Full Tk", 200, 0, 200 ); hMuonTP_Pt_DTMatch_Priority = fs->make( "hMuonTP_Pt_DTMatch_Priority", "sim muon p_{T}, DTMatch + Stubs, Priority", 200, 0, 200 ); hMuonTP_Pt_DTMatch_Average = fs->make( "hMuonTP_Pt_DTMatch_Average", "sim muon p_{T}, DTMatch + Stubs, Average", 200, 0, 200 ); + hMuonTP_Pt_DTMatch_TTTrackFullReso = fs->make( "hMuonTP_Pt_DTMatch_TTTrackFullReso", "sim muon p_{T}, DTMatch + L1 Track", 200, 0, 200 ); hMuonTP_PtBin_DT = fs->make( "hMuonTP_PtBin_DT", "sim muon p_{T}, signal in DT", 200, 0, 200 ); hMuonTP_PtBin_DTTF = fs->make( "hMuonTP_PtBin_DTTF", "sim muon p_{T}, w/ DTTF", 200, 0, 200 ); @@ -514,6 +546,7 @@ void AnalyzerDTMatches::beginJob() hMuonTP_PtBin_DTMatch_MajorityFull = fs->make( "hMuonTP_PtBin_DTMatch_MajorityFull", "sim muon p_{T}, DTMatch + Stubs, Majority Full Tk", 200, 0, 200 ); hMuonTP_PtBin_DTMatch_Priority = fs->make( "hMuonTP_PtBin_DTMatch_Priority", "sim muon p_{T}, DTMatch + Stubs, Priority", 200, 0, 200 ); hMuonTP_PtBin_DTMatch_Average = fs->make( "hMuonTP_PtBin_DTMatch_Average", "sim muon p_{T}, DTMatch + Stubs, Average", 200, 0, 200 ); + hMuonTP_PtBin_DTMatch_TTTrackFullReso = fs->make( "hMuonTP_PtBin_DTMatch_TTTrackFullReso", "sim muon p_{T}, DTMatch + L1 Track", 200, 0, 200 ); hMuonTP_PtBin_DT->GetXaxis()->Set( NumBins, BinVec ); hMuonTP_PtBin_DTTF->GetXaxis()->Set( NumBins, BinVec ); @@ -524,6 +557,7 @@ void AnalyzerDTMatches::beginJob() hMuonTP_PtBin_DTMatch_MajorityFull->GetXaxis()->Set( NumBins, BinVec ); hMuonTP_PtBin_DTMatch_Priority->GetXaxis()->Set( NumBins, BinVec ); hMuonTP_PtBin_DTMatch_Average->GetXaxis()->Set( NumBins, BinVec ); + hMuonTP_PtBin_DTMatch_TTTrackFullReso->GetXaxis()->Set( NumBins, BinVec ); hMuonTP_Pt_DT->Sumw2(); hMuonTP_Pt_DTTF->Sumw2(); @@ -534,6 +568,7 @@ void AnalyzerDTMatches::beginJob() hMuonTP_Pt_DTMatch_MajorityFull->Sumw2(); hMuonTP_Pt_DTMatch_Priority->Sumw2(); hMuonTP_Pt_DTMatch_Average->Sumw2(); + hMuonTP_Pt_DTMatch_TTTrackFullReso->Sumw2(); hMuonTP_PtBin_DT->Sumw2(); hMuonTP_PtBin_DTTF->Sumw2(); @@ -544,6 +579,56 @@ void AnalyzerDTMatches::beginJob() hMuonTP_PtBin_DTMatch_MajorityFull->Sumw2(); hMuonTP_PtBin_DTMatch_Priority->Sumw2(); hMuonTP_PtBin_DTMatch_Average->Sumw2(); + hMuonTP_PtBin_DTMatch_TTTrackFullReso->Sumw2(); + + hMuonTP_Eta_DT = fs->make( "hMuonTP_Eta_DT", "sim muon #eta, signal in DT", 100, -1, 1 ); + hMuonTP_Eta_DTTF = fs->make( "hMuonTP_Eta_DTTF", "sim muon #eta, w/ DTTF", 100, -1, 1 ); + hMuonTP_Eta_DTMatch = fs->make( "hMuonTP_Eta_DTMatch", "sim muon #eta, DTMatch", 100, -1, 1 ); + hMuonTP_Eta_DTMatch_TTTrack = fs->make( "hMuonTP_Eta_DTMatch_TTTrack", "sim muon #eta, DTMatch + L1 Track", 100, -1, 1 ); + hMuonTP_Eta_DTMatch_Majority = fs->make( "hMuonTP_Eta_DTMatch_Majority", "sim muon #eta, DTMatch + Stubs, Majority", 100, -1, 1 ); + hMuonTP_Eta_DTMatch_MixedMode = fs->make( "hMuonTP_Eta_DTMatch_MixedMode", "sim muon #eta, DTMatch + Stubs, Mixed Mode", 100, -1, 1 ); + hMuonTP_Eta_DTMatch_MajorityFull = fs->make( "hMuonTP_Eta_DTMatch_MajorityFull", "sim muon #eta, DTMatch + Stubs, Majority Full Tk", 100, -1, 1 ); + hMuonTP_Eta_DTMatch_Priority = fs->make( "hMuonTP_Eta_DTMatch_Priority", "sim muon #eta, DTMatch + Stubs, Priority", 100, -1, 1 ); + hMuonTP_Eta_DTMatch_Average = fs->make( "hMuonTP_Eta_DTMatch_Average", "sim muon #eta, DTMatch + Stubs, Average", 100, -1, 1 ); + hMuonTP_Eta_DTMatch_TTTrackFullReso = fs->make( "hMuonTP_Eta_DTMatch_TTTrackFullReso", "sim muon #eta, DTMatch + L1 Track", 100, -1, 1 ); + + hMuonTP_Eta_DT->Sumw2(); + hMuonTP_Eta_DTTF->Sumw2(); + hMuonTP_Eta_DTMatch->Sumw2(); + hMuonTP_Eta_DTMatch_TTTrack->Sumw2(); + hMuonTP_Eta_DTMatch_Majority->Sumw2(); + hMuonTP_Eta_DTMatch_MixedMode->Sumw2(); + hMuonTP_Eta_DTMatch_MajorityFull->Sumw2(); + hMuonTP_Eta_DTMatch_Priority->Sumw2(); + hMuonTP_Eta_DTMatch_Average->Sumw2(); + hMuonTP_Eta_DTMatch_TTTrackFullReso->Sumw2(); + + hDTTF_PtBin_MuonTP_Pt = fs->make( "hDTTF_PtBin_MuonTP_Pt", "DTTF p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + hDTMatch_TTrack_PtBin_MuonTP_Pt = fs->make( "hDTMatch_TTrack_PtBin_MuonTP_Pt", "DTMatch TTTrack p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + hDTMatch_Majority_PtBin_MuonTP_Pt = fs->make( "hDTMatch_Majority_PtBin_MuonTP_Pt", "DTMatch Majority p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + hDTMatch_MixedMode_PtBin_MuonTP_Pt = fs->make( "hDTMatch_MixedMode_PtBin_MuonTP_Pt", "DTMatch MixedMode p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + hDTMatch_MajorityFull_PtBin_MuonTP_Pt = fs->make( "hDTMatch_MajorityFull_PtBin_MuonTP_Pt", "DTMatch Majority Full Tk p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + hDTMatch_Priority_PtBin_MuonTP_Pt = fs->make( "hDTMatch_Priority_PtBin_MuonTP_Pt", "DTMatch Priority p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + hDTMatch_Average_PtBin_MuonTP_Pt = fs->make( "hDTMatch_Average_PtBin_MuonTP_Pt", "DTMatch Average p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + hDTMatch_TTTrackFullReso_Pt_MuonTP_Pt = fs->make( "hDTMatch_TTTrackFullReso_Pt_MuonTP_Pt", "DTMatch TTTrack Full Reso p_{T} vs sim muon p_{T}", 200, 0, 200, 200, 0, 200 ); + + hDTTF_PtBin_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + hDTMatch_TTrack_PtBin_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + hDTMatch_Majority_PtBin_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + hDTMatch_MixedMode_PtBin_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + hDTMatch_MajorityFull_PtBin_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + hDTMatch_Priority_PtBin_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + hDTMatch_Average_PtBin_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + hDTMatch_TTTrackFullReso_Pt_MuonTP_Pt->GetYaxis()->Set( NumBins, BinVec ); + + hDTTF_PtBin_MuonTP_Pt->Sumw2(); + hDTMatch_TTrack_PtBin_MuonTP_Pt->Sumw2(); + hDTMatch_Majority_PtBin_MuonTP_Pt->Sumw2(); + hDTMatch_MixedMode_PtBin_MuonTP_Pt->Sumw2(); + hDTMatch_MajorityFull_PtBin_MuonTP_Pt->Sumw2(); + hDTMatch_Priority_PtBin_MuonTP_Pt->Sumw2(); + hDTMatch_Average_PtBin_MuonTP_Pt->Sumw2(); + hDTMatch_TTTrackFullReso_Pt_MuonTP_Pt->Sumw2(); /// End of things to be done before entering the event Loop } @@ -621,7 +706,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup iterBti != DTBtiTriggerHandle->end(); ++iterBti ) { - iterBti->print(); + //iterBti->print(); } #endif @@ -675,17 +760,8 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup /// 6) DTMatch + Stubs, Mixed Mode /// 7) DTMatch + TTTrack - /// Prepare the maps for the DT Digi to DT Digi SimLink association -/* - std::map< DTWireId, std::vector< DTDigiSimLink > > mapDTSimLinkByWire; - std::map< DTWireId, std::vector< edm::Ptr< TrackingParticle > > > mapTrackingParticleByWire; - mapDTSimLinkByWire.clear(); - mapTrackingParticleByWire.clear(); -*/ - std::map< DTBtiId, std::vector< DTDigiSimLink > > mapDTSimLinkByBti; std::map< DTBtiId, std::vector< edm::Ptr< TrackingParticle > > > mapTrackingParticleByBti; - mapDTSimLinkByBti.clear(); mapTrackingParticleByBti.clear(); /// Here's the idea: @@ -717,13 +793,6 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup iterDTSL != theseDigiSimLinksRange.second; ++iterDTSL ) { - /// Get the wire Id - DTWireId thisWireId( thisLayId, iterDTSL->wire() ); - - /// Build the BTI Id - int btiNum = thisChamberGeometry->mapTubeInFEch( thisLayId.superlayerId().superlayer(), thisLayId.layer(), thisWireId.wire() ); - DTBtiId thisBtiId( thisChambId, thisLayId.superlayerId().superlayer(), btiNum ); - /// Build the unique Id to find the TrackingParticle std::pair< unsigned int, EncodedEventId > thisUniqueId = std::make_pair( iterDTSL->SimTrackId(), iterDTSL->eventId() ); @@ -739,50 +808,60 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { thisTPPtr = edm::Ptr< TrackingParticle >(); } -/* - /// Check if the wire is already in the map or not - if ( mapDTSimLinkByWire.find( thisWireId ) != mapDTSimLinkByWire.end() ) - { - mapDTSimLinkByWire[ thisWireId ].push_back( *iterDTSL ); - mapTrackingParticleByWire[ thisWireId ].push_back( thisTPPtr ); - } - else - { - std::vector< DTDigiSimLink > tempVector1; - std::vector< edm::Ptr< TrackingParticle > > tempVector2; - tempVector1.push_back( *iterDTSL ); - tempVector2.push_back( thisTPPtr ); - mapDTSimLinkByWire.insert( std::make_pair( thisWireId, tempVector1 ) ); - mapTrackingParticleByWire.insert( std::make_pair( thisWireId, tempVector2 ) ); - } -*/ - /// Check if the BTI is already in the map or not - if ( mapDTSimLinkByBti.find( thisBtiId ) != mapDTSimLinkByBti.end() ) + /// Get the wire Id + DTWireId thisWireId( thisLayId, iterDTSL->wire() ); + + /// Build the channel number + int channelNum = thisChamberGeometry->mapTubeInFEch( thisLayId.superlayerId().superlayer(), thisLayId.layer(), thisWireId.wire() ); + + /// Build the BTI Id + /// Note that each channel can be mapped into 2 or 3 BTI's + /// Channel N goes into BTI N and N+1 + /// Only for Layer 4: also in N+2 + int maxShift = 1; + if ( thisLayId.layer() == 4 ) { - mapDTSimLinkByBti[ thisBtiId ].push_back( *iterDTSL ); - mapTrackingParticleByBti[ thisBtiId ].push_back( thisTPPtr ); + maxShift = 2; } - else + + for ( int jShift = -maxShift; jShift <= maxShift; jShift++ ) { - std::vector< DTDigiSimLink > tempVector1; - std::vector< edm::Ptr< TrackingParticle > > tempVector2; - tempVector1.push_back( *iterDTSL ); - tempVector2.push_back( thisTPPtr ); - mapDTSimLinkByBti.insert( std::make_pair( thisBtiId, tempVector1 ) ); - mapTrackingParticleByBti.insert( std::make_pair( thisBtiId, tempVector2 ) ); - } + /// Build the BTI number + int btiNum = channelNum + jShift; + + if ( btiNum < 0 ) + { + continue; + } + + /// Build the BTI Id + DTBtiId thisBtiId( thisChambId, thisLayId.superlayerId().superlayer(), btiNum ); + + /// Check if the BTI is already in the map or not + //if ( mapDTSimLinkByBti.find( thisBtiId ) != mapDTSimLinkByBti.end() ) + if ( mapTrackingParticleByBti.find( thisBtiId ) != mapTrackingParticleByBti.end() ) + { + mapTrackingParticleByBti[ thisBtiId ].push_back( thisTPPtr ); + } + else + { + std::vector< edm::Ptr< TrackingParticle > > tempVector2; + tempVector2.push_back( thisTPPtr ); + mapTrackingParticleByBti.insert( std::make_pair( thisBtiId, tempVector2 ) ); + } + } /// End of loop over possible shifts of the BTI /// Check if it is a muon - if( thisTPPtr.isNull() == false && - fabs(thisTPPtr->pdgId()) == 13 ) + if ( thisTPPtr.isNull() == false && + fabs(thisTPPtr->pdgId()) == 13 ) { /// Check if the muon is already in the container for the efficiencies if ( mapMuonTrackingParticleInDTDigi.find( thisTPPtr ) == mapMuonTrackingParticleInDTDigi.end() ) { /// Add it to the map if not present std::vector< bool > tempVec; - for ( unsigned int jK = 0; jK < 8; jK++ ) + for ( unsigned int jK = 0; jK < 9; jK++ ) { /// 0) DTTF /// 1) DTMatch @@ -792,46 +871,21 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup /// 5) DTMatch + Stubs, Majority /// 6) DTMatch + Stubs, Mixed Mode /// 7) DTMatch + TTTrack + /// 8) DTMatch + TTTrack, Full Resolution tempVec.push_back(false); } mapMuonTrackingParticleInDTDigi.insert( std::make_pair( thisTPPtr, tempVec ) ); } - } + } /// End of it is a muon } /// End of loop over the DTDigiSimLinks } /// End of loop over the DT unit -/* - std::map< DTWireId, std::vector< DTDigiSimLink > >::const_iterator iterMapDTSimLinkByWire; - - for ( iterMapDTSimLinkByWire = mapDTSimLinkByWire.begin(); - iterMapDTSimLinkByWire != mapDTSimLinkByWire.end(); - ++iterMapDTSimLinkByWire ) - { - DTWireId thisWireId = iterMapDTSimLinkByWire->first; - std::vector< DTDigiSimLink > theseDTSimLinks = iterMapDTSimLinkByWire->second; - std::vector< edm::Ptr< TrackingParticle > > theseTrackingParticles = mapTrackingParticleByWire[ thisWireId ]; /// Safe by construction! - - std::cerr << thisWireId << std::endl; - if ( theseDTSimLinks.size() != theseTrackingParticles.size() ) std::cerr << "DISASTER HAPPENED" << std::endl; - else - { - for ( unsigned int j = 0; j < theseDTSimLinks.size(); j++ ) - { - std::cerr << theseDTSimLinks.at(j).number() << " " << theseDTSimLinks.at(j).time() << std::endl; - std::cerr << theseTrackingParticles.at(j).isNull(); - if ( theseTrackingParticles.at(j).isNull() ) std::cerr << std::endl; - else - { - edm::Ptr< TrackingParticle > thisTPPtr = theseTrackingParticles.at(j); - std::cerr << " " << thisTPPtr->pdgId() << " " << thisTPPtr->momentum() << std::endl; - } - } - } - } -*/ +#ifdef DEBUG + std::cerr << "MAP OF SIM MUONS THAT FIRED DTWires has " << mapMuonTrackingParticleInDTDigi.size() << std::endl; +#endif /// Now, convert the map< BTI, vector< TP > > to a map< BTI, vector< muon TP > > /// and to a map< BTI, one single muon TP > @@ -840,24 +894,12 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup mapSimMuonsByBti.clear(); mapTheSimMuonByBti.clear(); -/* - std::map< DTBtiId, std::vector< DTDigiSimLink > >::const_iterator iterMapDTSimLinkByBti; - - for ( iterMapDTSimLinkByBti = mapDTSimLinkByBti.begin(); - iterMapDTSimLinkByBti != mapDTSimLinkByBti.end(); - ++iterMapDTSimLinkByBti ) - { -*/ std::map< DTBtiId, std::vector< edm::Ptr< TrackingParticle > > >::const_iterator iterMapTrackingParticleByBti; for ( iterMapTrackingParticleByBti = mapTrackingParticleByBti.begin(); iterMapTrackingParticleByBti != mapTrackingParticleByBti.end(); ++iterMapTrackingParticleByBti ) { - -// DTBtiId thisBtiId = iterMapDTSimLinkByBti->first; -// std::vector< DTDigiSimLink > theseDTSimLinks = iterMapDTSimLinkByBti->second; - DTBtiId thisBtiId = iterMapTrackingParticleByBti->first; std::vector< edm::Ptr< TrackingParticle > > theseTrackingParticles = mapTrackingParticleByBti[ thisBtiId ]; /// Safe by construction! @@ -865,7 +907,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup std::vector< edm::Ptr< TrackingParticle > > theseSimMuons; theseSimMuons.clear(); - /// Loop over the TrackingParticles + /// Loop over the TrackingParticles associated to the current BTI for ( unsigned int j = 0; j < theseTrackingParticles.size(); j++ ) { if ( theseTrackingParticles.at(j).isNull() ) @@ -874,6 +916,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup } else { + /// Here the TrackingParticle is found in thisBtiId AND is not null edm::Ptr< TrackingParticle > thisTPPtr = theseTrackingParticles.at(j); if ( fabs(thisTPPtr->pdgId()) == 13 ) { @@ -891,8 +934,8 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { theseSimMuons.push_back( thisTPPtr ); } - } - } + } /// End of non-null muons + } /// End of non-null TrackingParticles } /// End of loop over TrackingParticles if ( theseSimMuons.size() > 0 ) @@ -908,12 +951,12 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup std::cerr << thisBtiId.SLId() << " " << thisBtiId.bti() << std::endl; if ( mapSimMuonsByBti.find( thisBtiId ) != mapSimMuonsByBti.end() ) { - std::cerr << "TPs = " << mapTrackingParticleByBti[ thisBtiId ].size() << std::endl; - std::cerr << "MUONS = " << mapSimMuonsByBti[ thisBtiId ].size() << std::endl; + //std::cerr << "TPs = " << mapTrackingParticleByBti[ thisBtiId ].size() << std::endl; + //std::cerr << "MUONS = " << mapSimMuonsByBti[ thisBtiId ].size() << std::endl; } if ( mapTheSimMuonByBti.find( thisBtiId ) != mapTheSimMuonByBti.end() ) { - std::cerr << "THE MUON IS " << mapTheSimMuonByBti[ thisBtiId ]->momentum() << std::endl; + std::cerr << " >>> THE MUON IS " << mapTheSimMuonByBti[ thisBtiId ]->momentum() << std::endl; } #endif @@ -937,7 +980,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup } */ #endif - } + } /// End of loop over BTI Id #ifdef DEBUG /// Loop over the DT Digis @@ -948,7 +991,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup ++iterDTUnit ) { const DTLayerId& thisLayId = (*iterDTUnit).first; - const DTChamberId thisChambId = thisLayId.superlayerId().chamberId(); +// const DTChamberId thisChambId = thisLayId.superlayerId().chamberId(); const DTDigiCollection::Range& theseDigisRange = (*iterDTUnit).second; for ( iterDTDigi = theseDigisRange.first; @@ -956,12 +999,16 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup ++iterDTDigi ) { DTWireId thisWireId( thisLayId, iterDTDigi->wire() ); - std::cerr<< thisLayId << " " << thisChambId << " " << thisWireId << " " << iterDTDigi->time(); - iterDTDigi->print(); +// std::cerr<< thisLayId << " " << thisChambId << " " << thisWireId << " " << iterDTDigi->time() << " "; +// iterDTDigi->print(); } } #endif +#ifdef DEBUG + std::cerr << "number of DTMatches " << DTMatchHandle->size() << std::endl; +#endif + /// Loop over the DTMatches std::vector< DTMatch >::const_iterator iterDTM; for ( iterDTM = DTMatchHandle->begin(); @@ -1126,13 +1173,19 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup } } +#ifdef DEBUG + std::cerr << "MAP OF SIM MUONS THAT FIRED BTI in DTMatch has " << mapBtiByFiringMuon.size() << std::endl; +#endif + /// Now we have a map where each muon firing a BTI --> points to the list of fired Bti /// Basic criterion: only 1 muon that fires min. 1/3 BTI edm::Ptr< TrackingParticle > theFiringMuon = edm::Ptr< TrackingParticle >(); std::map< edm::Ptr< TrackingParticle >, std::vector< DTBtiId > >::const_iterator iterMapBtiByFiringMuon; + bool escapeFlag = false; /// Originally the code was using only iterMapBtiByFiringMuon + /// but this happened to prevent infinite loops for ( iterMapBtiByFiringMuon = mapBtiByFiringMuon.begin(); - iterMapBtiByFiringMuon != mapBtiByFiringMuon.end(); + iterMapBtiByFiringMuon != mapBtiByFiringMuon.end() && !escapeFlag; ++iterMapBtiByFiringMuon ) { if ( theFiringMuon.isNull() ) @@ -1153,7 +1206,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { /// Force to exit and reset muon to null theFiringMuon = edm::Ptr< TrackingParticle >(); - iterMapBtiByFiringMuon = mapBtiByFiringMuon.end(); + escapeFlag = true; } } @@ -1161,9 +1214,20 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup /// that fire at least 1 BTI out of the 3 that make the DTMatch edm::Ptr< TrackingParticle > thisMuon = iterMapBtiByFiringMuon->first; + if ( thisMuon.isNull() ) + { + continue; + } + if ( iterMapBtiByFiringMuon->second.size() == 0 ) + { + continue; + } + /// Fill the container for the efficiency plots if ( mapMuonTrackingParticleInDTDigi.find( thisMuon ) != mapMuonTrackingParticleInDTDigi.end() ) { + double simPt = thisMuon->p4().pt(); + /// 0) DTTF /// 1) DTMatch /// 2) DTMatch + Stubs, Priority @@ -1172,6 +1236,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup /// 5) DTMatch + Stubs, Majority /// 6) DTMatch + Stubs, Mixed Mode /// 7) DTMatch + TTTrack + /// 8) DTMatch + TTTrack, Full Resolution /// 1) DTMatch mapMuonTrackingParticleInDTDigi[ thisMuon ][1] = true; @@ -1180,56 +1245,75 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup if ( iterDTM->getPtPriorityBin() > 0. ) { mapMuonTrackingParticleInDTDigi[ thisMuon ][2] = true; + hDTMatch_Priority_PtBin_MuonTP_Pt->Fill( simPt, iterDTM->getPtPriorityBin() ); } /// 3) DTMatch + Stubs, Average if ( iterDTM->getPtAverageBin() > 0. ) { mapMuonTrackingParticleInDTDigi[ thisMuon ][3] = true; + hDTMatch_Average_PtBin_MuonTP_Pt->Fill( simPt, iterDTM->getPtAverageBin() ); } /// 4) DTMatch + Stubs, Majority Full Tracker if ( iterDTM->getPtMajorityFullTkBin() > 0. ) { mapMuonTrackingParticleInDTDigi[ thisMuon ][4] = true; + hDTMatch_MajorityFull_PtBin_MuonTP_Pt->Fill( simPt, iterDTM->getPtMajorityFullTkBin() ); } /// 5) DTMatch + Stubs, Majority if ( iterDTM->getPtMajorityBin() > 0. ) { mapMuonTrackingParticleInDTDigi[ thisMuon ][5] = true; + hDTMatch_Majority_PtBin_MuonTP_Pt->Fill( simPt, iterDTM->getPtMajorityBin() ); } /// 6) DTMatch + Stubs, Mixed Mode if ( iterDTM->getPtMixedModeBin() > 0. ) { mapMuonTrackingParticleInDTDigi[ thisMuon ][6] = true; + hDTMatch_MixedMode_PtBin_MuonTP_Pt->Fill( simPt, iterDTM->getPtMixedModeBin() ); } /// 7) DTMatch + TTTrack if ( iterDTM->getPtTTTrackBin() > 0. ) { mapMuonTrackingParticleInDTDigi[ thisMuon ][7] = true; + hDTMatch_TTrack_PtBin_MuonTP_Pt->Fill( simPt, iterDTM->getPtTTTrackBin() ); } - - - - + /// 8) DTMatch + TTTrack, Full Resolution + if ( iterDTM->getPtMatchedTrackPtr().isNull() == false ) + { + mapMuonTrackingParticleInDTDigi[ thisMuon ][8] = true; + hDTMatch_TTTrackFullReso_Pt_MuonTP_Pt->Fill( simPt, iterDTM->getPtMatchedTrackPtr()->getMomentum().perp() ); + } } - } + + } /// End of loop over all possible firing muons /// Here, if there is one good muon that builds up this TP seed, it is stored in theFiringMuon /// if theFiringMuon.isNull(), it means that either no muon 2/3 BTI is found, either more than 1 were found +#ifdef DEBUG + if ( theFiringMuon.isNull() ) + { + std::cerr << " I " << innerBti.SLId() << " " << innerBti.bti() << std::endl; + std::cerr << " O " << outerBti.SLId() << " " << outerBti.bti() << std::endl; + std::cerr << " M " << matchedBti.SLId() << " " << matchedBti.bti() << std::endl; + std::cerr << "NULL firing muon" << std::endl; + } +#endif + if ( theFiringMuon.isNull() == false ) { #ifdef DEBUG std::cerr << " I " << innerBti.SLId() << " " << innerBti.bti() << std::endl; std::cerr << " O " << outerBti.SLId() << " " << outerBti.bti() << std::endl; std::cerr << " M " << matchedBti.SLId() << " " << matchedBti.bti() << std::endl; - std::cerr << theFiringMuon->momentum() << std::endl; + std::cerr << "FIRED by muon " << theFiringMuon->momentum() << std::endl; #endif /// Select only the charges you want @@ -1252,7 +1336,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup int thisDTCode = iterDTM->getDTCode(); #ifdef DEBUG - std::cerr << " ******** " << thisDTWheel << " * " << thisDTStation << std::endl; + std::cerr << " * wheel and station ******* " << thisDTWheel << " * " << thisDTStation << std::endl; #endif bool isCorr = false; @@ -1436,8 +1520,8 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup if ( tempDeltaPhi < -IMPI ) tempDeltaPhi = - 2 * IMPI + tempDeltaPhi; int predVtxTheta = iterDTM->getPredVtxTheta(); - int predVtxPhiError = iterDTM->getPredVtxSigmaPhi(); - int predVtxThetaError = iterDTM->getPredVtxSigmaTheta(); + float predVtxPhiError = static_cast< float >(iterDTM->getPredVtxSigmaPhi()); + float predVtxThetaError = static_cast< float >(iterDTM->getPredVtxSigmaTheta()); if ( isCorr ) { @@ -1523,8 +1607,8 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup if ( tempDeltaPhi < -IMPI ) tempDeltaPhi = - 2 * IMPI + tempDeltaPhi; int predStubTheta = iterDTM->getPredStubTheta(jLayer); - int predStubPhiError = iterDTM->getPredStubSigmaPhi(jLayer); - int predStubThetaError = iterDTM->getPredStubSigmaTheta(jLayer); + float predStubPhiError = static_cast< float >(iterDTM->getPredStubSigmaPhi(jLayer)); + float predStubThetaError = static_cast< float >(iterDTM->getPredStubSigmaTheta(jLayer)); if ( isCorr ) { @@ -1551,6 +1635,34 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup } /// End of loop over stubs } + /// Prepare curvature plots + /// Availability of stubs is checked using Pt method strings from DTMatchBasePtMethods + std::map< std::string, DTMatchPt* > thisPtMethodMap = iterDTM->getPtMethodsMap(); + + /// Loop over the methods (theMethods[0] = "Mu_2_1" ... theMethods[14] = "Mu_6_5") + for ( unsigned int iMethod = 0; iMethod < 15; iMethod++ ) + { + /// Check if the method is available + if ( thisPtMethodMap.find( theMethods[iMethod] ) != thisPtMethodMap.end() ) + { + /// Build the key + std::pair< std::string, int > anotherKey = std::make_pair(theMethods[iMethod], thisDTStation); + + float thisPt = iterDTM->getPt( theMethods[iMethod] ); + float thisPtInv = 1./thisPt; + mapMS_hDTMatch_InvPt[anotherKey]->Fill( thisPtInv ); + } + } + + /// Check also for L1 Track (theMethods[15] == "TTTrack") + if ( iterDTM->getPtMatchedTrackPtr().isNull() == false ) + { + std::pair< std::string, int > anotherKey = std::make_pair(theMethods[15], thisDTStation); + float thisPt = iterDTM->getPtMatchedTrackPtr()->getMomentum().perp(); + float thisPtInv = 1./thisPt; + mapMS_hDTMatch_InvPt[anotherKey]->Fill( thisPtInv ); + } + } /// End of check over null muon TrackingParticle } /// End of loop over DTMatches @@ -1568,12 +1680,14 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup hMuonTP_Pt_DT->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DT->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DT->Fill( thisMuon->p4().eta() ); /// 0) DTTF if ( theseFlags.at(0) == true ) { hMuonTP_Pt_DTTF->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTTF->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTTF->Fill( thisMuon->p4().eta() ); } /// 1) DTMatch @@ -1581,6 +1695,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { hMuonTP_Pt_DTMatch->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTMatch->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch->Fill( thisMuon->p4().eta() ); } /// 2) DTMatch + Stubs, Priority @@ -1588,6 +1703,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { hMuonTP_Pt_DTMatch_Priority->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTMatch_Priority->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch_Priority->Fill( thisMuon->p4().eta() ); } /// 3) DTMatch + Stubs, Average @@ -1595,6 +1711,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { hMuonTP_Pt_DTMatch_Average->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTMatch_Average->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch_Average->Fill( thisMuon->p4().eta() ); } /// 4) DTMatch + Stubs, Majority Full Tracker @@ -1602,6 +1719,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { hMuonTP_Pt_DTMatch_MajorityFull->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTMatch_MajorityFull->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch_MajorityFull->Fill( thisMuon->p4().eta() ); } /// 5) DTMatch + Stubs, Majority @@ -1609,6 +1727,7 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { hMuonTP_Pt_DTMatch_Majority->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTMatch_Majority->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch_Majority->Fill( thisMuon->p4().eta() ); } /// 6) DTMatch + Stubs, Mixed Mode @@ -1616,19 +1735,32 @@ void AnalyzerDTMatches::analyze( const edm::Event& iEvent, const edm::EventSetup { hMuonTP_Pt_DTMatch_MixedMode->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTMatch_MixedMode->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch_MixedMode->Fill( thisMuon->p4().eta() ); } /// 7) DTMatch + TTTrack - if ( theseFlags.at(1) == true ) + if ( theseFlags.at(7) == true ) { hMuonTP_Pt_DTMatch_TTTrack->Fill( thisMuon->p4().pt() ); hMuonTP_PtBin_DTMatch_TTTrack->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch_TTTrack->Fill( thisMuon->p4().eta() ); + } + + /// 8) DTMatch + TTTrack, Full Resolution + if ( theseFlags.at(8) == true ) + { + hMuonTP_Pt_DTMatch_TTTrackFullReso->Fill( thisMuon->p4().pt() ); + hMuonTP_PtBin_DTMatch_TTTrackFullReso->Fill( thisMuon->p4().pt() ); + hMuonTP_Eta_DTMatch_TTTrackFullReso->Fill( thisMuon->p4().eta() ); } - } /// End of loop over sim muons + + + } /// End of loop over sim muons + } /// End of analyze() /////////////////////////// diff --git a/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py index d0238e22360c2..c30648edfa66e 100644 --- a/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py +++ b/L1Trigger/DTPlusTrackTrigger/test/AnalyzerDTMatches_cfg.py @@ -49,12 +49,13 @@ "PoolSource", secondaryFileNames = cms.untracked.vstring(), fileNames = cms.untracked.vstring( - "file:TwoMuPt_25_Extended2023TTI_50000_DIGI_L1_DIGI2RAW_L1TT_RECO_V001_3_1_H5r.root", +#'/store/user/pozzo/MUPGUN_14_Extended2023TTI_6_2_0_SLHC12_GEN_SIM_V002/MUPGUN_14_Extended2023TTI_6_2_0_SLHC12_DIGI_L1_DIGI2RAW_L1TT_RECO_V001G/95a3b5071be09d95bfad13b012bdbdd3/TwoMuPt_14_Extended2023TTI_500000_DIGI_L1_DIGI2RAW_L1TT_RECO_V001G_88_1_VtZ.root', +'/store/user/pozzo/MUPGUN_14_Extended2023TTI_6_2_0_SLHC12_GEN_SIM_V002/MUPGUN_14_Extended2023TTI_6_2_0_SLHC12_DIGI_L1_DIGI2RAW_L1TT_RECO_V001G/95a3b5071be09d95bfad13b012bdbdd3/TwoMuPt_14_Extended2023TTI_500000_DIGI_L1_DIGI2RAW_L1TT_RECO_V001G_89_1_FG5.root', ) ) process.maxEvents = cms.untracked.PSet( - input = cms.untracked.int32(-1) + input = cms.untracked.int32(-2)#2) ) ################################################################################################# @@ -88,6 +89,7 @@ # define the producer of DT + TK objects ################################################################################################# process.load("L1Trigger.DTPlusTrackTrigger.DTPlusTrackProducer_cfi") +#process.DTPlusTrackProducer.useRoughTheta = cms.untracked.bool(True) process.DTPlusTk_step = cms.Path(process.DTPlusTrackProducer) ################################################################################################# diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py index c0bc8aa2dd011..8396d511b0c84 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py @@ -1,6 +1,8 @@ import FWCore.ParameterSet.Config as cms +# --------------------------------------------------------------------------- + # # --- Muons from Slava # @@ -14,6 +16,44 @@ # this is based on CSCTF record directly (no GMT sorting) and creates TkMus in |eta| > 1.1 l1tkMusFromExtendedForward = cms.Sequence(l1extraMuExtended * l1TkMuonsExtCSC ) +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# +# --- Muons from the Padova algorithm +# + +################################################################################################# +# now, all the DT related stuff +################################################################################################# +# to produce, in case, collection of L1MuDTTrack objects: +#process.dttfDigis = cms.Path(process.simDttfDigis) + +# the DT geometry +from Geometry.DTGeometry.dtGeometry_cfi import * +from Geometry.MuonNumbering.muonNumberingInitialization_cfi import * +from SimMuon.DTDigitizer.muonDTDigis_cfi import * + +##process.load("L1TriggerConfig.DTTPGConfigProducers.L1DTTPGConfig_cff") + +################################################################################################# +# define the producer of DT + TK objects +################################################################################################# +from L1Trigger.DTPlusTrackTrigger.DTPlusTrackProducer_cfi import * +#DTPlusTk_step = cms.Path(process.DTPlusTrackProducer) + +L1TkMuonsDT = cms.EDProducer("L1TkMuonDTProducer") + +L1TkMuonsDTSequence = cms.Sequence( DTPlusTrackProducer + L1TkMuonsDT ) + +# --------------------------------------------------------------------------- + + + + +# --------------------------------------------------------------------------- # # --- FInal collection of L1TkMuons @@ -21,14 +61,16 @@ L1TkMuonsMerge = cms.EDProducer("L1TkMuonMerger", TkMuonCollections = cms.VInputTag( - #cms.InputTag("L1TkMuonsDT","DTMatchInwardsTTTrackFullReso"), + cms.InputTag("L1TkMuonsDT","DTMatchInwardsTTTrackFullReso"), cms.InputTag("l1TkMuonsExt",""), cms.InputTag("l1TkMuonsExtCSC","") ), - absEtaMin = cms.vdouble( 0. , 1.1), # Padova's not ready yet - absEtaMax = cms.vdouble( 1.1 , 5.0) + absEtaMin = cms.vdouble( 0. , 1.1, 1.25), + absEtaMax = cms.vdouble( 1.1 , 1.25, 5.0) ) +# --------------------------------------------------------------------------- + -L1TkMuons = cms.Sequence( l1tkMusFromExtendedAllEta + l1tkMusFromExtendedForward + L1TkMuonsMerge ) +L1TkMuons = cms.Sequence( l1tkMusFromExtendedAllEta + l1tkMusFromExtendedForward + L1TkMuonsDTSequence + L1TkMuonsMerge ) From 7c8de5f242601bd8f09eaf8212b2efcab84a288e Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 3 Jun 2014 19:10:37 +0200 Subject: [PATCH 034/252] update runL1Tracks_cfg.py to produce a collection of L1Tracks with a different label --- .../L1TrackTrigger/test/runL1Tracks_cfg.py | 39 +++++++++++++++++-- 1 file changed, 35 insertions(+), 4 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py index bfed0cf5b8885..adf66103dae04 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py @@ -65,11 +65,42 @@ # process.TTTracksFromPixelDigis.geometry = cms.untracked.string('BE5D') # not needed (that's the default) -# if one wants to change the extrapolation window : -process.TTTracksFromPixelDigis.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 + # ---- + # + # 1. the following will re-create a collection of L1Tracks, with + # the same label as the "default" collection : + # + +# here, we change the extrapolation window : +#process.TTTracksFromPixelDigis.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 + +#process.TT_step = cms.Path(process.TrackTriggerTTTracks) +#process.TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) + # + # ---- + + + # ---- + # + # 2. if you want to create a collection of L1Tracks with a different label: + # + # To use these L1Tracks later, one should use : + # L1TrackInputTag = cms.InputTag("TrackTriggerTTTracksLargerPhi","Level1TTTracks") + +process.TTTracksFromPixelDigisLargerPhi = process.TTTracksFromPixelDigis.clone() +process.TTTracksFromPixelDigisLargerPhi.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 +process.TrackTriggerTTTracksLargerPhi = cms.Sequence(process.BeamSpotFromSim*process.TTTracksFromPixelDigisLargerPhi) + +process.TTTrackAssociatorFromPixelDigisLargerPhi = process.TTTrackAssociatorFromPixelDigis.clone() +process.TTTrackAssociatorFromPixelDigisLargerPhi.TTTracks = cms.VInputTag( cms.InputTag("TTTracksFromPixelDigisLargerPhi", "Level1TTTracks") ) +process.TrackTriggerAssociatorTracksLargerPhi = cms.Sequence( process.TTTrackAssociatorFromPixelDigisLargerPhi ) + +process.TT_step = cms.Path( process.TrackTriggerTTTracksLargerPhi ) +process.TTAssociator_step = cms.Path( process.TrackTriggerAssociatorTracksLargerPhi) + # + # ---- + -process.TT_step = cms.Path(process.TrackTriggerTTTracks) -process.TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) From b7a7c5ed35d22539fca90834df38afaf8690b1e5 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 4 Jun 2014 11:40:01 +0200 Subject: [PATCH 035/252] add the zvtx information in L1TkMuonFromExtendedProducer.cc --- .../L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc index 80a2276df9778..2ccfafa372b73 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc @@ -246,6 +246,10 @@ L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& l1tkmu.setMuExtendedRef(l1muRef); l1tkmu.setQuality(l1mu_quality); l1tkmu.setTrkIsol(trkisol); + + // EP: add the zvtx information + l1tkmu.setTrkzVtx( (float)tkv3.z() ); + tkMuons->push_back(l1tkmu); } } From ac69c30183e5f9b8884f8f8977628c2ed39b0c99 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 4 Jun 2014 12:28:08 +0200 Subject: [PATCH 036/252] add L1TrackingSequence_cfi.py and give example usage in test_L1TkMuon_cfg.py; minor fix in runL1Tracks_cfg.py --- .../python/L1TrackingSequence_cfi.py | 48 +++++++++++++++++++ .../L1TrackTrigger/test/runL1Tracks_cfg.py | 2 +- .../L1TrackTrigger/test/test_L1TkMuon_cfg.py | 19 ++++++-- 3 files changed, 65 insertions(+), 4 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py new file mode 100644 index 0000000000000..5735ea38e903f --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py @@ -0,0 +1,48 @@ +import FWCore.ParameterSet.Config as cms + + +from Configuration.StandardSequences.MagneticField_38T_PostLS1_cff import * +from IOMC.EventVertexGenerators.VtxSmearedGauss_cfi import * +from Configuration.Geometry.GeometryExtended2023TTIReco_cff import * +from Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi import * + +BeamSpotFromSim =cms.EDProducer("BeamSpotFromSimProducer") + + +# --------------------------------------------------------------------------- + +# +# --- Rerun the L1Tracking, standard configuration +# Allows to benefit from most recent improvements + +from Configuration.StandardSequences.L1TrackTrigger_cff import * + +DefaultTrackingSequence = cms.Sequence( TrackTriggerTTTracks + TrackTriggerAssociatorTracks) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# +# --- Rerun the L1Tracking, but now in the "electron configuration" +# + +TTTracksFromPixelDigisLargerPhi = TTTracksFromPixelDigis.clone() +TTTracksFromPixelDigisLargerPhi.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 +TrackTriggerTTTracksLargerPhi = cms.Sequence(BeamSpotFromSim*TTTracksFromPixelDigisLargerPhi) + +TTTrackAssociatorFromPixelDigisLargerPhi = TTTrackAssociatorFromPixelDigis.clone() +TTTrackAssociatorFromPixelDigisLargerPhi.TTTracks = cms.VInputTag( cms.InputTag("TTTracksFromPixelDigisLargerPhi", "Level1TTTracks") ) +TrackTriggerAssociatorTracksLargerPhi = cms.Sequence( TTTrackAssociatorFromPixelDigisLargerPhi ) + +ElectronTrackingSequence = cms.Sequence( TrackTriggerTTTracksLargerPhi + TrackTriggerAssociatorTracksLargerPhi ) + +# --------------------------------------------------------------------------- + + + +FullTrackingSequence = cms.Sequence( DefaultTrackingSequence + ElectronTrackingSequence ) + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py index bfed0cf5b8885..6074408d9752e 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Tracks_cfg.py @@ -66,7 +66,7 @@ # process.TTTracksFromPixelDigis.geometry = cms.untracked.string('BE5D') # not needed (that's the default) # if one wants to change the extrapolation window : -process.TTTracksFromPixelDigis.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 +#process.TTTracksFromPixelDigis.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 process.TT_step = cms.Path(process.TrackTriggerTTTracks) process.TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py index fe59555b2380f..7ffecda76a486 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkMuon_cfg.py @@ -4,7 +4,7 @@ process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(20) ) # # This runs over a file that already contains the L1Tracks. @@ -39,6 +39,18 @@ +# --------------------------------------------------------------------------- +# +# --- Recreate the L1Tracks to benefit from the latest updates +# + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.DefaultTrackingSequence ) + +# --------------------------------------------------------------------------- + + + # --------------------------------------------------------------------------- # # --- Produces various L1TkMuon collections - as well as "extended" L1Muons @@ -83,12 +95,13 @@ # the L1Tracks, clusters and stubs +process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + # the clusters and stubs #process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') #process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') #process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') #process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') -#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') -#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') # --- to browse the genParticles, one needs to keep the collections of associators below: process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') From 1f2ed3009fc56566dd33590e61867372801635f3 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Fri, 6 Jun 2014 13:32:39 +0200 Subject: [PATCH 037/252] added pTFrom2Stubs.cc from Jelena and adapted L1TkElectronTrackProducer.cc accordingly --- .../L1TrackTrigger/interface/pTFrom2Stubs.h | 13 ++++ .../plugins/L1TkElectronTrackProducer.cc | 20 +++++- .../python/L1TkElectronTrackProducer_cfi.py | 1 + .../python/L1TrackingSequence_cfi.py | 48 ++++++++++++++ .../L1TrackTrigger/src/pTFrom2Stubs.cc | 65 +++++++++++++++++++ 5 files changed, 146 insertions(+), 1 deletion(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/interface/pTFrom2Stubs.h create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/interface/pTFrom2Stubs.h b/SLHCUpgradeSimulations/L1TrackTrigger/interface/pTFrom2Stubs.h new file mode 100644 index 0000000000000..6c92d4702d842 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/interface/pTFrom2Stubs.h @@ -0,0 +1,13 @@ +#ifndef pTFrom2Stubs_HH +#define pTFrom2Stubs_HH + + +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + +namespace pTFrom2Stubs{ + float rInvFrom2(std::vector< TTTrack< Ref_PixelDigi_> >::const_iterator trk, const StackedTrackerGeometry* theStackedGeometry); + float pTFrom2(std::vector< TTTrack< Ref_PixelDigi_> >::const_iterator trk, const StackedTrackerGeometry* theStackedGeometry); +} +#endif diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc index c228c49c75f81..dd25e9715d8b8 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkElectronTrackProducer.cc @@ -51,6 +51,11 @@ #include "DataFormats/Math/interface/deltaPhi.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/pTFrom2Stubs.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" + + #include #include "TMath.h" @@ -102,6 +107,7 @@ class L1TkElectronTrackProducer : public edm::EDProducer { bool RelativeIsolation; float trkQualityChi2; + bool useTwoStubsPT; float trkQualityPtMin; std::vector dPhiCutoff; std::vector dRCutoff; @@ -139,6 +145,7 @@ L1TkElectronTrackProducer::L1TkElectronTrackProducer(const edm::ParameterSet& iC // parameters to select tracks to match with L1EG trkQualityChi2 = (float)iConfig.getParameter("TrackChi2"); trkQualityPtMin = (float)iConfig.getParameter("TrackMinPt"); + useTwoStubsPT = iConfig.getParameter("useTwoStubsPT"); dPhiCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaPhi"); dRCutoff = iConfig.getParameter< std::vector >("TrackEGammaDeltaR"); dEtaCutoff = (float)iConfig.getParameter("TrackEGammaDeltaEta"); @@ -154,6 +161,13 @@ void L1TkElectronTrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { std::auto_ptr result(new L1TkElectronParticleCollection); + + // geometry needed to call pTFrom2Stubs + edm::ESHandle stackedGeometryHandle; + iSetup.get().get(stackedGeometryHandle); + const StackedTrackerGeometry* theStackedGeometry = stackedGeometryHandle.product(); + + edm::Handle EGammaHandle; iEvent.getByLabel(L1EGammaInputTag,EGammaHandle); l1extra::L1EmParticleCollection eGammaCollection = (*EGammaHandle.product()); @@ -198,7 +212,11 @@ L1TkElectronTrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iS int itrack = -1; for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { edm::Ptr< L1TkTrackType > L1TrackPtr( L1TkTrackHandle, itr) ; - double trkPt = trackIter->getMomentum().perp(); + double trkPt_fit = trackIter->getMomentum().perp(); + double trkPt_stubs = pTFrom2Stubs::pTFrom2( trackIter, theStackedGeometry); + double trkPt = trkPt_fit; + if ( useTwoStubsPT ) trkPt = trkPt_stubs ; + if ( trkPt > trkQualityPtMin && trackIter->getChi2() < trkQualityChi2) { double dPhi = 99.; double dR = 99.; diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py index 9681fe4ed9923..182131a1c56ce 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py @@ -18,6 +18,7 @@ # Quality cuts on Track and Track L1EG matching criteria TrackChi2 = cms.double(100.0), # minimum Chi2 to select tracks TrackMinPt = cms.double(12.0), # minimum Pt to select tracks + useTwoStubsPT = cms.bool( False ), TrackEGammaDeltaPhi = cms.vdouble(0.05, 0.0, 0.0), # functional Delta Phi cut parameters to match Track with L1EG objects TrackEGammaDeltaR = cms.vdouble(0.08, 0.0, 0.0), # functional Delta R cut parameters to match Track with L1EG objects TrackEGammaDeltaEta = cms.double(0.08), # Delta Eta cutoff to match Track with L1EG objects diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py new file mode 100644 index 0000000000000..5735ea38e903f --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TrackingSequence_cfi.py @@ -0,0 +1,48 @@ +import FWCore.ParameterSet.Config as cms + + +from Configuration.StandardSequences.MagneticField_38T_PostLS1_cff import * +from IOMC.EventVertexGenerators.VtxSmearedGauss_cfi import * +from Configuration.Geometry.GeometryExtended2023TTIReco_cff import * +from Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi import * + +BeamSpotFromSim =cms.EDProducer("BeamSpotFromSimProducer") + + +# --------------------------------------------------------------------------- + +# +# --- Rerun the L1Tracking, standard configuration +# Allows to benefit from most recent improvements + +from Configuration.StandardSequences.L1TrackTrigger_cff import * + +DefaultTrackingSequence = cms.Sequence( TrackTriggerTTTracks + TrackTriggerAssociatorTracks) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# +# --- Rerun the L1Tracking, but now in the "electron configuration" +# + +TTTracksFromPixelDigisLargerPhi = TTTracksFromPixelDigis.clone() +TTTracksFromPixelDigisLargerPhi.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 +TrackTriggerTTTracksLargerPhi = cms.Sequence(BeamSpotFromSim*TTTracksFromPixelDigisLargerPhi) + +TTTrackAssociatorFromPixelDigisLargerPhi = TTTrackAssociatorFromPixelDigis.clone() +TTTrackAssociatorFromPixelDigisLargerPhi.TTTracks = cms.VInputTag( cms.InputTag("TTTracksFromPixelDigisLargerPhi", "Level1TTTracks") ) +TrackTriggerAssociatorTracksLargerPhi = cms.Sequence( TTTrackAssociatorFromPixelDigisLargerPhi ) + +ElectronTrackingSequence = cms.Sequence( TrackTriggerTTTracksLargerPhi + TrackTriggerAssociatorTracksLargerPhi ) + +# --------------------------------------------------------------------------- + + + +FullTrackingSequence = cms.Sequence( DefaultTrackingSequence + ElectronTrackingSequence ) + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc b/SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc new file mode 100644 index 0000000000000..b176060fa9adb --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc @@ -0,0 +1,65 @@ + +#include +#include +#include +#include + +#include "pTFrom2Stubs.h" + +namespace pTFrom2Stubs{ + + //==================== + float rInvFrom2(std::vector< TTTrack< Ref_PixelDigi_> >::const_iterator trk, const StackedTrackerGeometry* theStackedGeometry){ + + //vector of R, r and phi for each stub + std::vector< std::vector > riPhiStubs(0); + //get stub reference + std::vector< edm::Ref >, TTStub< Ref_PixelDigi_ > > > vecStubRefs = trk->getStubRefs(); + + //loop over L1Track's stubs + int rsize =vecStubRefs.size(); + for(int j =0; j< rsize; ++j){ + + edm::Ref >, TTStub< Ref_PixelDigi_ > > stubRef =vecStubRefs.at(j) ; + const TTStub* stub=&(*stubRef) ; + + GlobalPoint stubPosition = theStackedGeometry->findGlobalPosition(stub); + + std::vector tmp(0); + float Rad = sqrt(stubPosition.x()*stubPosition.x() + stubPosition.y()*stubPosition.y() + stubPosition.z()+stubPosition.z()); + float r_i = sqrt(stubPosition.x()*stubPosition.x() + stubPosition.y()*stubPosition.y()); + float phi_i=stubPosition.phi(); + + tmp.push_back(Rad); + tmp.push_back(r_i); + tmp.push_back(phi_i); + + riPhiStubs.push_back(tmp); + } + + std::sort(riPhiStubs.begin(), riPhiStubs.end()); + //now calculate the curvature from first 2 stubs + float nr1 = (riPhiStubs[0])[1]; + float nphi1 = (riPhiStubs[0])[2]; + + float nr2 = (riPhiStubs[1])[1]; + float nphi2 = (riPhiStubs[1])[2]; + + float ndeltaphi=nphi1 -nphi2; + static float two_pi=8*atan(1.0); + if (ndeltaphi>0.5*two_pi) ndeltaphi-=two_pi; + if (ndeltaphi<-0.5*two_pi) ndeltaphi+=two_pi; + float ndist=sqrt(nr2*nr2+nr1*nr1-2*nr1*nr2*cos(ndeltaphi)); + + float curvature = 2*sin(ndeltaphi)/ndist; + return curvature; + } + //==================== + float pTFrom2(std::vector< TTTrack< Ref_PixelDigi_> >::const_iterator trk, const StackedTrackerGeometry* theStackedGeometry){ + + float rinv= rInvFrom2(trk, theStackedGeometry); + return fabs( 0.00299792*3.8/rinv); + + } + //==================== +} From 4bd4d24fc7cc69d667cdd0f42746e5878cbddee8 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Fri, 6 Jun 2014 14:33:04 +0200 Subject: [PATCH 038/252] set bx=0 in L1TkMuonParticle.cc; adapt L1TkMuonSequence_cfi.py to run the Padova muons (not in the merger still) --- DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc | 5 ++++- .../L1TrackTrigger/python/L1TkMuonSequence_cfi.py | 12 +++++++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index fb00be02fd288..818a8bd4c888e 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -52,8 +52,10 @@ L1TkMuonParticle::L1TkMuonParticle( const LorentzVector& p4, int L1TkMuonParticle::bx() const { - int dummy = -999; + // int dummy = -999; + int dummy = 0; +/* if (theDTMatch.isNonnull() ) { return theDTMatch->getDTBX(); } @@ -66,6 +68,7 @@ int L1TkMuonParticle::bx() const { return getMuExtendedRef()->bx(); } +*/ return dummy; } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py index 8396d511b0c84..3dc0f340532fb 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkMuonSequence_cfi.py @@ -59,7 +59,17 @@ # --- FInal collection of L1TkMuons # -L1TkMuonsMerge = cms.EDProducer("L1TkMuonMerger", + # --- using only Slava's muons : +L1TkMuonsMerge = cms.EDProducer("L1TkMuonMerger", + TkMuonCollections = cms.VInputTag( cms.InputTag("l1TkMuonsExt",""), + cms.InputTag("l1TkMuonsExtCSC","") ), + absEtaMin = cms.vdouble( 0. , 1.1), + absEtaMax = cms.vdouble( 1.1 , 5.0) +) + + + # --- or using the Padova muons in the central region: +L1TkMuonsMergeWithDT = cms.EDProducer("L1TkMuonMerger", TkMuonCollections = cms.VInputTag( cms.InputTag("L1TkMuonsDT","DTMatchInwardsTTTrackFullReso"), cms.InputTag("l1TkMuonsExt",""), From c563eabe1d088d15df6504f3420d6c9a03c19dca Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Fri, 6 Jun 2014 12:50:22 -0500 Subject: [PATCH 039/252] Updated crystal level EG cluster producer to use dynamic hovere and isolation cuts. Also, refactored the L1EGCrystalCluster class to be more in line with the style of l1extra::L1EmParticle() --- .../plugins/L1EGammaCrystalsProducer.cc | 30 ++++------------- .../plugins/L1ExtraCrystalPosition.cc | 9 +++-- SimDataFormats/SLHC/BuildFile.xml | 1 + .../SLHC/interface/L1EGCrystalCluster.h | 33 ++++++++++--------- 4 files changed, 28 insertions(+), 45 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index 32f3b3050e318..b568a1a93e2dd 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -65,7 +65,6 @@ class L1EGCrystalClusterProducer : public edm::EDProducer { private: virtual void produce(edm::Event&, const edm::EventSetup&); - virtual void beginRun(edm::Run const&, edm::EventSetup const&); CaloGeometryHelper geometryHelper; bool debug; @@ -296,26 +295,16 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet if ( debug ) std::cout << "H/E: " << hovere << std::endl; // Form a l1slhc::L1EGCrystalCluster - l1slhc::L1EGCrystalCluster cluster; - cluster.et = totalPt; - cluster.eta = weightedPosition.eta(); - cluster.phi = weightedPosition.phi(); - cluster.ieta = centerhit.id.ieta(); - cluster.iphi = centerhit.id.iphi(); - cluster.e = totalEnergy; - cluster.x = weightedPosition.x(); - cluster.y = weightedPosition.y(); - cluster.z = weightedPosition.z(); - cluster.hovere = hovere; - cluster.ECALiso = ECalIsolation; - cluster.ECALetPUcorr = totalPtPUcorr; - + reco::Candidate::PolarLorentzVector p4(totalPt, weightedPosition.eta(), weightedPosition.phi(), 0.); + l1slhc::L1EGCrystalCluster cluster(p4, hovere, ECalIsolation, totalPtPUcorr); trigCrystalClusters->push_back(cluster); // Save clusters with some cuts - if ( cluster.hovere < 2. && cluster.ECALiso < 3. ) + // This is a dynamic falling quadratic cut in pt, trying to squeeze as much efficiency as possible + // out of the cut variables, which should have been pt-independent, but are not. + if ( cluster.hovere() < ((cluster.pt() > 35) ? 0.5 : 0.5+pow(cluster.pt()-35,2)/350. ) + && cluster.isolation() < ((cluster.pt() > 35) ? 1.3 : 1.3+pow(cluster.pt()-35,2)*4/(35*35) ) ) { - reco::Candidate::PolarLorentzVector p4(cluster.et, cluster.eta, cluster.phi, 0.); l1EGammaCrystal->push_back(l1extra::L1EmParticle(p4, edm::Ref(), 0)); } } @@ -324,11 +313,4 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet iEvent.put(l1EGammaCrystal, "EGammaCrystal" ); } -// ------------ method called when starting to processes a run ------------ -void -L1EGCrystalClusterProducer::beginRun(edm::Run const& iRun, edm::EventSetup const& iSetup) -{ - std::cout << "Apparently beginRun() never gets called?!?!?!" << std::endl; -} - DEFINE_FWK_MODULE(L1EGCrystalClusterProducer); diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc index 41ef2d8749f79..09693a054b556 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1ExtraCrystalPosition.cc @@ -47,7 +47,7 @@ namespace l1extra { class ClusterETComparator { public: bool operator()(const l1slhc::L1EGCrystalCluster a, const l1slhc::L1EGCrystalCluster b) const { - return a.et > b.et; + return a.pt() > b.pt(); } }; } @@ -105,8 +105,8 @@ void L1ExtraCrystalPosition::produce( edm::Event & iEvent, const edm::EventSetup unsigned int indx = getMatchedClusterIndex(clusColl, eta, phi, deltaR); if (indx != 9999 && deltaR < 0.3) { l1extra::L1EmParticle* em_new = em.clone(); - float eta_new = clusColl[indx].eta; - float phi_new = clusColl[indx].phi; + float eta_new = clusColl[indx].eta(); + float phi_new = clusColl[indx].phi(); // float pt_new = em.pt(); // if (cosh(eta_new) > 0.0) pt_new = em.p()/cosh(eta_new); // reco::Candidate::PolarLorentzVector lv_em_corr(pt_new, eta_new, phi_new, em.mass()); @@ -122,7 +122,6 @@ void L1ExtraCrystalPosition::produce( edm::Event & iEvent, const edm::EventSetup // if (cosh(em_new->eta()) > 0.0) et_new = em_new->energy()/cosh(em_new->eta()); // std::cout << " Et, Energy, Eta, Phi (after correction) " << et_new << " " << em_new->energy() << " " << em_new->eta() << " " << em_new->phi() << " deltaR " << deltaR << std::endl; // std::cout << " px, py, pz " << em_new->px() << " " << em_new->py() << " " << em_new->pz() << std::endl; - // std::cout << " x, y, z " << clusColl[indx].x << " " << clusColl[indx].y << " " << clusColl[indx].z << std::endl; } } iEvent.put(l1EGammaCrystal, "EGammaCrystal" ); @@ -137,7 +136,7 @@ unsigned int L1ExtraCrystalPosition::getMatchedClusterIndex(l1slhc::L1EGCrystalC dr_min = 999.9; size_t index_min = 9999; for (size_t i = 0; i < egxtals.size(); i++) { - float dr = deltaR(egxtals[i].eta, egxtals[i].phi, eta, phi); + float dr = deltaR(egxtals[i].eta(), egxtals[i].phi(), eta, phi); if (dr < dr_min) { index_min = i; dr_min = dr; diff --git a/SimDataFormats/SLHC/BuildFile.xml b/SimDataFormats/SLHC/BuildFile.xml index 2176dc6067ed1..10ee9ae25e394 100644 --- a/SimDataFormats/SLHC/BuildFile.xml +++ b/SimDataFormats/SLHC/BuildFile.xml @@ -2,6 +2,7 @@ + diff --git a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h index 36f9b4aa7d4a0..e893d6004ae13 100644 --- a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h +++ b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h @@ -2,27 +2,28 @@ #define L1EGammaCrystalsCluster_h #include +#include "DataFormats/Candidate/interface/LeafCandidate.h" namespace l1slhc { - class L1EGCrystalCluster { - public: - float et ; - float eta ; - float phi ; - float e ; - float x ; - float y ; - float z ; - float hovere ; - - float ECALiso ; - float ECALetPUcorr; - - int ieta; - int iphi; + class L1EGCrystalCluster : public reco::LeafCandidate { + public: + L1EGCrystalCluster() : LeafCandidate(), hovere_(0.), iso_(0.), PUcorrPt_(0.) {}; + L1EGCrystalCluster(const PolarLorentzVector& p4, float hovere, float iso, float PUcorrPt = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt) {}; + L1EGCrystalCluster(const LorentzVector& p4, float hovere, float iso, float PUcorrPt = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt) {}; + virtual ~L1EGCrystalCluster() {}; + inline float hovere() const { return hovere_; }; + inline float isolation() const { return iso_; }; + inline float PUcorrPt() const { return PUcorrPt_; }; + private: + // HCal energy in region behind cluster (for size, look in producer) / ECal energy in cluster + float hovere_; + // ECal isolation (for outer window size, again look in producer) + float iso_; + // Pileup-corrected energy deposit, not studied carefully yet, don't use + float PUcorrPt_; }; From 8025c83d5ffddf0724d0a2b756cccd455663bde3 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 10 Jun 2014 08:17:50 +0200 Subject: [PATCH 040/252] add produce_L1TkObjects_cfg.py with ESPrefer for DTs; add ETmin param for L1EGCrystals; change default for vertexing: truncation instead of saturation --- .../plugins/L1EGammaCrystalsProducer.cc | 4 + .../python/L1TkPrimaryVertexProducer_cfi.py | 2 +- .../test/produce_L1TkObjects_cfg.py | 261 ++++++++++++++++++ .../test/test_L1TkEGamma_with_crystal_cfg.py | 1 + .../test/test_L1TkEtMiss_cfg.py | 39 ++- 5 files changed, 293 insertions(+), 14 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index b568a1a93e2dd..8faf3936c24da 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -67,6 +67,7 @@ class L1EGCrystalClusterProducer : public edm::EDProducer { virtual void produce(edm::Event&, const edm::EventSetup&); CaloGeometryHelper geometryHelper; + double EtminForStore; bool debug; bool useECalEndcap; class SimpleCaloHit @@ -121,6 +122,7 @@ class L1EGCrystalClusterProducer : public edm::EDProducer { }; L1EGCrystalClusterProducer::L1EGCrystalClusterProducer(const edm::ParameterSet& iConfig) : + EtminForStore(iConfig.getParameter("EtminForStore")), debug(iConfig.getUntrackedParameter("debug", false)), useECalEndcap(iConfig.getUntrackedParameter("useECalEndcap", false)) { @@ -305,7 +307,9 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet if ( cluster.hovere() < ((cluster.pt() > 35) ? 0.5 : 0.5+pow(cluster.pt()-35,2)/350. ) && cluster.isolation() < ((cluster.pt() > 35) ? 1.3 : 1.3+pow(cluster.pt()-35,2)*4/(35*35) ) ) { + if (totalPt >= EtminForStore) { l1EGammaCrystal->push_back(l1extra::L1EmParticle(p4, edm::Ref(), 0)); + } } } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py index d8c26b7504b4b..96c14ef9b1ea1 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py @@ -11,6 +11,6 @@ # mismeasured and are treated according to HighPtTracks below. # When PTMAX < 0, no special treatment is done for high PT tracks. # If PTMAX < 0, no saturation or truncation is done. - HighPtTracks = cms.int32( 1 ) # when = 0 : truncation. Tracks with PT above PTMAX are ignored + HighPtTracks = cms.int32( 0 ) # when = 0 : truncation. Tracks with PT above PTMAX are ignored # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py new file mode 100644 index 0000000000000..2e56d78f15924 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py @@ -0,0 +1,261 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(20) ) + +# +# This runs over a file that already contains the L1Tracks. +# + + +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * + +process.source = cms.Source("PoolSource", + fileNames = minBiasFiles_p1 +) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') + +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') + +# --------------------------------------------------------------------------- +# +# --- Recreate the L1Tracks to benefit from the latest updates +# + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.DefaultTrackingSequence ) + +# --------------------------------------------------------------------------- + + + +# --- Muons +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkMuonSequence_cfi") +process.pMuons = cms.Path( process.L1TkMuons ) + + +# --------------------------------------------------------------------------- + +# +# --- run the L1Calo simulation +# + +process.load('Configuration/StandardSequences/L1HwVal_cff') +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +# bug fix for missing HCAL TPs in MC RAW +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + +process.slhccalo = cms.Path( process.RawToDigi + process.valHcalTriggerPrimitiveDigis+process.SLHCCaloTrigger) + + # To produce L1EG objects corresponding + # to the Run-1 L1EG algorithm, one just needs to run + # L1Reco. The (Run-1) L1EG algorithm has already been + # run in the DIGI step of the production. +process.load('Configuration.StandardSequences.L1Reco_cff') +process.L1Reco = cms.Path( process.l1extraParticles ) + + +# ---- Produce the L1EGCrystal clusters (code of Sasha Savin & Nick Smith) + + # first you need the ECAL RecHIts : +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.reconstruction_step = cms.Path( process.calolocalreco ) +# +process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", + EtminForStore = cms.double( 4. ), + debug = cms.untracked.bool(False), + useECalEndcap = cms.untracked.bool(True) +) +process.pSasha = cms.Path( process.L1EGammaCrystalsProducer ) + + + # needed because the calo stuff above clashes with the DTs +process.es_prefer_dt = cms.ESPrefer("DTConfigTrivialProducer","L1DTConfig") + + + +# --------------------------------------------------------------------------- + +# Now we produce L1TkEmParticles and L1TkElectrons + +# ---- "photons" isolated w.r.t. L1Tracks : + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmParticleProducer_cfi") +process.pL1TkPhotons = cms.Path( process.L1TkPhotons ) + +# ---- "electrons" from L1Tracks. Inclusive electrons : + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkElectronTrackProducer_cfi") +process.pElectrons = cms.Path( process.L1TkElectrons ) + +# ---- L1TkElectrons that are isolated w.r.t. L1Tracks : + +process.L1TkIsoElectrons = process.L1TkElectrons.clone() +process.L1TkIsoElectrons.IsoCut = cms.double(0.1) +process.pElectronsTkIso = cms.Path( process.L1TkIsoElectrons ) + +# ---- "electrons" from L1Tracks, Inclusive electrons : dedicated low PT sequence +process.pElectronsLoose = cms.Path( process.L1TkElectronsLoose) + +# ---- L1TkElectrons that are isolated w.r.t. L1Tracks : dedicated low PT sequence +process.L1TkIsoElectronsLoose = process.L1TkElectronsLoose.clone() +process.L1TkIsoElectronsLoose.IsoCut = cms.double(0.1) +process.pElectronsTkIsoLoose = cms.Path( process.L1TkIsoElectronsLoose ) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- +# --- L1TkMET + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkPrimaryVertexProducer_cfi") +process.pL1TkPrimaryVertex = cms.Path( process.L1TkPrimaryVertex ) + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEtMissProducer_cfi") +process.pL1TrkMET = cms.Path( process.L1TkEtMiss ) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- +# --- TkTaus + +process.L1TkTauFromL1Track = cms.EDProducer("L1TkTauFromL1TrackProducer", + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + ZMAX = cms.double( 25. ),# in cm + CHI2MAX = cms.double( 100. ), + PTMINTRA = cms.double( 2. ),# in GeV + DRmax = cms.double( 0.5 ), + nStubsmin = cms.int32( 5 ) # minimum number of stubs + ) + +process.pTaus = cms.Path( process.L1TkTauFromL1Track ) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- +# --- jets, HT and MHT + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkCaloSequence_cff") + +# -- Produce L1TkJets, HT and MHT from the L1Jets : +process.L1TkCaloL1Jets = cms.Path( process.L1TkCaloSequence ) + +# -- Produce the HLT JI Jets and L1TkJets, HT and MHT from these jets : +process.L1TkCaloHIJets = cms.Path( process.L1TkCaloSequenceHI ) +# --------------------------------------------------------------------------- + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "FileOut.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + + # the final collection of L1TkMuons +process.Out.outputCommands.append('keep *_L1TkMuonsMerge*_*_*') + # intermediate collections : +#process.Out.outputCommands.append('keep *_L1TkMuons*_*_*') +process.Out.outputCommands.append('keep *_L1TkMuonsDT_DTMatchInwardsTTTrackFullReso_*') +process.Out.outputCommands.append('keep *_l1extraMuExtended_*_*') +process.Out.outputCommands.append('keep *_l1TkMuonsExt*_*_*') + + + # the L1EG objects +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_*_*' ) +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticlesNewClustering_*_*') +process.Out.outputCommands.append('keep l1extraL1Em*_l1extraParticles_*_*') + # for crystal-level granularity : +process.Out.outputCommands.append('keep *_L1EGammaCrystalsProducer_*_*') +#process.Out.outputCommands.append('keep *_l1ExtraCrystalProducer_*_*') + # the L1TkEmParticles +process.Out.outputCommands.append('keep *_L1TkPhotons_*_*') + # the L1TkElectrons +process.Out.outputCommands.append('keep *_L1TkElectrons_*_*') +process.Out.outputCommands.append('keep *_L1TkIsoElectrons_*_*') +process.Out.outputCommands.append('keep *_L1TkElectronsLoose_*_*') +process.Out.outputCommands.append('keep *_L1TkIsoElectronsLoose_*_*') + + + # the L1TkPrimaryVertex +process.Out.outputCommands.append('keep *_L1TkPrimaryVertex_*_*') + # the TrkMET +process.Out.outputCommands.append('keep *_L1TkEtMiss*_*_*') + # the calo-based L1MET +process.Out.outputCommands.append('keep *_l1extraParticles_MET_*') + + # TkTaus +process.Out.outputCommands.append('keep *_L1TkTauFromL1Track_*_*') +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_Taus_*') + + # jets, HT, MHT +# Collections of L1TkJets : +process.Out.outputCommands.append('keep *_L1TkJets_*_*') # L1TkJets from the L1Jets +process.Out.outputCommands.append('keep *_L1TkJetsHI_*_*') # L1TkJets from the HLT Heavy Ion jets +# intermediate products: +process.Out.outputCommands.append('keep *_iterativeConePu5CaloJets_*_*') # HLT HI jets +process.Out.outputCommands.append('keep *_L1CalibFilterTowerJetProducer_CalibratedTowerJets_*') # L1Jets +process.Out.outputCommands.append('keep *_L1CalibFilterTowerJetProducer_UncalibratedTowerJets_*') # L1Jets +# Collections of HT and MHT variables : + # -- made from the L1Jets : +process.Out.outputCommands.append('keep *_L1TkHTMissCalo_*_*') # from L1Jets, calo only +process.Out.outputCommands.append('keep *_L1TkHTMissVtx_*_*') # from L1Jets, with vertex constraint + # -- made from the HLT HI jets: +process.Out.outputCommands.append('keep *_L1TkHTMissCaloHI_*_*') # from HLT HI jets, calo only +process.Out.outputCommands.append('keep *_L1TkHTMissVtxHI_*_*') # from HLT HI jets, with vertex constraint + + # keep the (rebuilt) tracks +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_ALL') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_ALL') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_ALL') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_ALL') + +process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_ALL') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_ALL') + + + + + # gen level information +##process.Out.outputCommands.append('keep *_generator_*_*') +##process.Out.outputCommands.append('keep *_*gen*_*_*') +##process.Out.outputCommands.append('keep *_*Gen*_*_*') +#process.Out.outputCommands.append('keep *_genParticles_*_*') + + # the gen-level MET +#process.Out.outputCommands.append('keep *_genMetTrue_*_*') + +# --- to browse the genParticles, one needs to keep the collections of associators below: +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py index 134b9fb89cd8f..64f9a9475d7bc 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py @@ -106,6 +106,7 @@ # information of the xtal level clusters. process.l1ExtraCrystalProducer = cms.EDProducer("L1ExtraCrystalPosition", + EtminForStore = cms.double( 4. ), eGammaSrc = cms.InputTag("SLHCL1ExtraParticlesNewClustering","EGamma"), eClusterSrc = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster") ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss_cfg.py index ccfe59335de10..b59e03802573c 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEtMiss_cfg.py @@ -19,12 +19,17 @@ # or at least the GCT raw data. # +#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p2_cfi import * + process.source = cms.Source("PoolSource", - fileNames = cms.untracked.vstring( - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' - ) + #fileNames = minBiasFiles_p1 + fileNames = minBiasFiles_p2 + #fileNames = cms.untracked.vstring( + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' + #) ) @@ -48,17 +53,25 @@ process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEtMissProducer_cfi") process.pL1TrkMET = cms.Path( process.L1TkEtMiss ) -process.L1TkEtMiss2 = process.L1TkEtMiss.clone(); -process.L1TkEtMiss2.DeltaZ = cms.double(0.2) -process.pL1TrkMET2 = cms.Path( process.L1TkEtMiss2 ) +#process.L1TkEtMiss2 = process.L1TkEtMiss.clone() +#process.L1TkEtMiss2.DeltaZ = cms.double(0.2) +#process.pL1TrkMET2 = cms.Path( process.L1TkEtMiss2 ) + +#process.L1TkEtMiss3 = process.L1TkEtMiss.clone(); +#process.L1TkEtMiss3.PTMAX = cms.double(-1) +#process.pL1TrkMET3 = cms.Path( process.L1TkEtMiss3 ) + +#process.L1TkEtMiss4 = process.L1TkEtMiss.clone() +#process.L1TkEtMiss4.nStubsPSmin = cms.int32( 3 ) +#process.pL1TrkMET4 = cms.Path( process.L1TkEtMiss4 ) -process.L1TkEtMiss3 = process.L1TkEtMiss.clone(); -process.L1TkEtMiss3.PTMAX = cms.double(-1) -process.pL1TrkMET3 = cms.Path( process.L1TkEtMiss3 ) +#process.L1TkEtMiss5 = process.L1TkEtMiss.clone() +#process.L1TkEtMiss5.HighPtTracks = cms.int32( 1 ) +#process.pL1TrkMET5 = cms.Path( process.L1TkEtMiss5 ) -process.L1TkEtMiss4 = process.L1TkEtMiss.clone() -process.L1TkEtMiss4.nStubsPSmin = cms.int32( 3 ) -process.pL1TrkMET4 = cms.Path( process.L1TkEtMiss4 ) +#process.L1TkEtMiss6 = process.L1TkEtMiss.clone() +#process.L1TkEtMiss6.PTMAX = cms.double(999999999.) +#process.pL1TrkMET6 = cms.Path( process.L1TkEtMiss6 ) From 792de4c8ad2d89389321bb6df50c713297dddad3 Mon Sep 17 00:00:00 2001 From: Louise Date: Tue, 10 Jun 2014 12:21:15 +0200 Subject: [PATCH 041/252] update ntuple maker --- .../L1TrackTrigger/test/L1TrackNtupleMaker.cc | 74 +++ .../test/L1TrackNtupleMaker_cfg.py | 21 +- .../L1TrackTrigger/test/L1TrackNtuplePlot.C | 524 ++++++++++++++---- 3 files changed, 516 insertions(+), 103 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc index eababd1c8b5ee..9817e9a6063c9 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc @@ -113,6 +113,7 @@ class L1TrackNtupleMaker : public edm::EDAnalyzer std::vector* m_tp_pt; std::vector* m_tp_eta; std::vector* m_tp_phi; + std::vector* m_tp_d0; std::vector* m_tp_z0; std::vector* m_tp_pdgid; std::vector* m_tp_nmatch; @@ -126,6 +127,14 @@ class L1TrackNtupleMaker : public edm::EDAnalyzer std::vector* m_matchtrk_nstub; std::vector* m_matchtrk_genuine; + // *L1 track* properties ***for 5-parameter fit*** if m_tp_nmatch > 0 + std::vector* m_matchtrk5p_pt; + std::vector* m_matchtrk5p_eta; + std::vector* m_matchtrk5p_phi; + std::vector* m_matchtrk5p_z0; + std::vector* m_matchtrk5p_d0; + std::vector* m_matchtrk5p_chi2; + }; @@ -189,6 +198,7 @@ void L1TrackNtupleMaker::beginJob() m_tp_pt = new std::vector; m_tp_eta = new std::vector; m_tp_phi = new std::vector; + m_tp_d0 = new std::vector; m_tp_z0 = new std::vector; m_tp_pdgid = new std::vector; m_tp_nmatch = new std::vector; @@ -201,6 +211,13 @@ void L1TrackNtupleMaker::beginJob() m_matchtrk_nstub = new std::vector; m_matchtrk_genuine = new std::vector; + m_matchtrk5p_pt = new std::vector; + m_matchtrk5p_eta = new std::vector; + m_matchtrk5p_phi = new std::vector; + m_matchtrk5p_z0 = new std::vector; + m_matchtrk5p_d0 = new std::vector; + m_matchtrk5p_chi2 = new std::vector; + // ntuple eventTree = fs->make("eventTree", "Event tree"); @@ -218,6 +235,7 @@ void L1TrackNtupleMaker::beginJob() eventTree->Branch("tp_pt", &m_tp_pt); eventTree->Branch("tp_eta", &m_tp_eta); eventTree->Branch("tp_phi", &m_tp_phi); + eventTree->Branch("tp_d0", &m_tp_d0); eventTree->Branch("tp_z0", &m_tp_z0); eventTree->Branch("tp_pdgid", &m_tp_pdgid); eventTree->Branch("tp_nmatch", &m_tp_nmatch); @@ -230,6 +248,13 @@ void L1TrackNtupleMaker::beginJob() eventTree->Branch("matchtrk_nstub", &m_matchtrk_nstub); eventTree->Branch("matchtrk_genuine", &m_matchtrk_genuine); + eventTree->Branch("matchtrk5p_pt", &m_matchtrk5p_pt); + eventTree->Branch("matchtrk5p_eta", &m_matchtrk5p_eta); + eventTree->Branch("matchtrk5p_phi", &m_matchtrk5p_phi); + eventTree->Branch("matchtrk5p_z0", &m_matchtrk5p_z0); + eventTree->Branch("matchtrk5p_d0", &m_matchtrk5p_d0); + eventTree->Branch("matchtrk5p_chi2", &m_matchtrk5p_chi2); + } @@ -258,6 +283,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_tp_pt->clear(); m_tp_eta->clear(); m_tp_phi->clear(); + m_tp_d0->clear(); m_tp_z0->clear(); m_tp_pdgid->clear(); m_tp_nmatch->clear(); @@ -270,6 +296,13 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_matchtrk_nstub->clear(); m_matchtrk_genuine->clear(); + m_matchtrk5p_pt->clear(); + m_matchtrk5p_eta->clear(); + m_matchtrk5p_phi->clear(); + m_matchtrk5p_z0->clear(); + m_matchtrk5p_d0->clear(); + m_matchtrk5p_chi2->clear(); + //----------------------------------------------------------------------------------------------- @@ -366,8 +399,18 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup float tmp_tp_eta = iterTP->eta(); float tmp_tp_phi = iterTP->phi(); float tmp_tp_z0 = iterTP->vz(); + float tmp_tp_x0 = iterTP->vx(); + float tmp_tp_y0 = iterTP->vy(); int tmp_tp_pdgid = iterTP->pdgId(); + + float tmp_tp_d0unsigned = sqrt(tmp_tp_x0*tmp_tp_x0 + tmp_tp_y0*tmp_tp_y0); + // sign of d0 + float tp_sign = 1.0; + if (cos(tmp_tp_phi)*tmp_tp_x0 < 0) tp_sign = -1.0; + float tmp_tp_d0 = tmp_tp_d0unsigned*tp_sign; + + if (MyProcess==13 && abs(tmp_tp_pdgid) != 13) continue; if (MyProcess==11 && abs(tmp_tp_pdgid) != 11) continue; if ((MyProcess==6 || MyProcess==15 || MyProcess==211) && abs(tmp_tp_pdgid) != 211) continue; @@ -377,6 +420,10 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup if (fabs(tmp_tp_z0) > 30.0) continue; if ((MyProcess==6 || MyProcess==15) && tmp_tp_pt < 2.0) continue; + // for pions in ttbar, only consider TPs coming from near the IP! + float dxy = sqrt(tmp_tp_x0*tmp_tp_x0 + tmp_tp_y0*tmp_tp_y0); + if (MyProcess==6 && (dxy > 1.0)) continue; + if (DebugMode) cout << "Tracking particle, pt: " << tmp_tp_pt << " eta: " << tmp_tp_eta << " phi: " << tmp_tp_phi << " z0: " << tmp_tp_z0 << " pdgid: " << tmp_tp_pdgid << " eventID: " << iterTP->eventId().event() @@ -459,6 +506,13 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup int tmp_matchtrk_nstub = -999; int tmp_matchtrk_genuine = -999; + float tmp_matchtrk5p_pt = -999; + float tmp_matchtrk5p_eta = -999; + float tmp_matchtrk5p_phi = -999; + float tmp_matchtrk5p_z0 = -999; + float tmp_matchtrk5p_d0 = -999; + float tmp_matchtrk5p_chi2 = -999; + if (nMatch > 1) cout << "WARNING *** 2 or more matches to genuine L1 tracks ***" << endl; if (nMatch > 0) { @@ -469,12 +523,25 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup tmp_matchtrk_chi2 = matchedTracks.at(i_track)->getChi2(); tmp_matchtrk_nstub = (int) matchedTracks.at(i_track)->getStubRefs().size(); tmp_matchtrk_genuine = 1; + + tmp_matchtrk5p_pt = matchedTracks.at(i_track)->getMomentum(5).perp(); + tmp_matchtrk5p_eta = matchedTracks.at(i_track)->getMomentum(5).eta(); + tmp_matchtrk5p_phi = matchedTracks.at(i_track)->getMomentum(5).phi(); + tmp_matchtrk5p_z0 = matchedTracks.at(i_track)->getPOCA(5).z(); + + // sign of d0 + float sign = 1.0; + if (cos(tmp_matchtrk5p_phi)*matchedTracks.at(i_track)->getPOCA(5).x() < 0) sign = -1.0; + tmp_matchtrk5p_d0 = matchedTracks.at(i_track)->getPOCA(5).perp()*sign; + + tmp_matchtrk5p_chi2 = matchedTracks.at(i_track)->getChi2(5); } m_tp_pt->push_back(tmp_tp_pt); m_tp_eta->push_back(tmp_tp_eta); m_tp_phi->push_back(tmp_tp_phi); m_tp_z0->push_back(tmp_tp_z0); + m_tp_d0->push_back(tmp_tp_d0); m_tp_pdgid->push_back(tmp_tp_pdgid); m_tp_nmatch->push_back(nMatch); @@ -485,6 +552,13 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_matchtrk_chi2 ->push_back(tmp_matchtrk_chi2); m_matchtrk_nstub->push_back(tmp_matchtrk_nstub); m_matchtrk_genuine->push_back(tmp_matchtrk_genuine); + + m_matchtrk5p_pt ->push_back(tmp_matchtrk5p_pt); + m_matchtrk5p_eta->push_back(tmp_matchtrk5p_eta); + m_matchtrk5p_phi->push_back(tmp_matchtrk5p_phi); + m_matchtrk5p_z0 ->push_back(tmp_matchtrk5p_z0); + m_matchtrk5p_d0 ->push_back(tmp_matchtrk5p_d0); + m_matchtrk5p_chi2->push_back(tmp_matchtrk5p_chi2); } //end loop tracking particles diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker_cfg.py index e6a6134aac2ea..06db4b2e083fb 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker_cfg.py @@ -14,14 +14,14 @@ process.load('Configuration.StandardSequences.Services_cff') process.load('FWCore.MessageService.MessageLogger_cfi') process.load('Configuration.EventContent.EventContent_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5DReco_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE5D_cff') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') process.load('Configuration.StandardSequences.L1TrackTrigger_cff') process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') ############################################################ @@ -29,10 +29,12 @@ ############################################################ process.maxEvents = cms.untracked.PSet(input = cms.untracked.int32(-1)) -Source_Files = cms.untracked.vstring('/store/group/comm_trigger/L1TrackTrigger/BE5D_620_SLHC6/singleMu/PU140/AssoFix/SingleMuon_BE5D_PU140_25.root') +Source_Files = cms.untracked.vstring( + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Muons/NoPU/SingleMuon_DIGI_1.root', + ) process.source = cms.Source("PoolSource", fileNames = Source_Files) -process.TFileService = cms.Service("TFileService", fileName = cms.string('SingleMuon_BE5D_TrkPerf.root'), closeFileFast = cms.untracked.bool(True)) +process.TFileService = cms.Service("TFileService", fileName = cms.string('Debug_TrkPerf.root'), closeFileFast = cms.untracked.bool(True)) ############################################################ @@ -40,19 +42,20 @@ ############################################################ #run the tracking -#process.TT_step = cms.Path(process.TrackTriggerTTTracks) -#process.TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) +process.TT_step = cms.Path(process.TrackTriggerTTTracks) +process.TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) # Define the track ntuple process, MyProcess is the (unsigned) PDGID corresponding to the process which is run # e.g. single electron/positron = 11 # single pion+/pion- = 211 # single muon+/muon- = 13 +# pions in jets = 6 process.L1TrackNtuple = cms.EDAnalyzer('L1TrackNtupleMaker', MyProcess = cms.int32(13), DebugMode = cms.bool(False) ) process.ana = cms.Path(process.L1TrackNtuple) -#process.schedule = cms.Schedule(process.TT_step,process.TTAssociator_step,process.ana) -process.schedule = cms.Schedule(process.ana) +process.schedule = cms.Schedule(process.TT_step,process.TTAssociator_step,process.ana) +#process.schedule = cms.Schedule(process.ana) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtuplePlot.C b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtuplePlot.C index f01c8f32d045c..86af79d5086e9 100755 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtuplePlot.C +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtuplePlot.C @@ -37,6 +37,7 @@ void L1TrackNtuplePlot(TString type) { SetPlotStyle(); bool doDetailedPlots = false; //turn on to make full set of plots + bool makeCanvas = false; //make PDF file with all the plots // ---------------------------------------------------------------------------------------------------------------- @@ -44,7 +45,7 @@ void L1TrackNtuplePlot(TString type) { TChain* tree = new TChain("L1TrackNtuple/eventTree"); if (type=="test") tree->Add("test_TrkPerf.root"); - else tree->Add("RootFiles/"+type+"_BE5D_TrkPerf.root"); + else tree->Add("RootFiles/"+type+"_TrkPerf.root"); if (tree->GetEntries() == 0) { cout << "File doesn't exist or is empty, returning..." << endl; @@ -71,6 +72,7 @@ void L1TrackNtuplePlot(TString type) { vector* tp_eta; vector* tp_phi; vector* tp_z0; + vector* tp_d0; vector* tp_pdgid; vector* tp_nmatch; @@ -82,6 +84,14 @@ void L1TrackNtuplePlot(TString type) { vector* matchtrk_chi2; vector* matchtrk_nstub; + // *L1 track* properties, for tracking particles matched to a L1 track *** USING 5-PARAMETER TRACK FIT *** + vector* matchtrk5p_pt; + vector* matchtrk5p_eta; + vector* matchtrk5p_phi; + vector* matchtrk5p_z0; + vector* matchtrk5p_d0; + vector* matchtrk5p_chi2; + TBranch* b_trk_pt; TBranch* b_trk_eta; @@ -97,6 +107,7 @@ void L1TrackNtuplePlot(TString type) { TBranch* b_tp_eta; TBranch* b_tp_phi; TBranch* b_tp_z0; + TBranch* b_tp_d0; TBranch* b_tp_pdgid; TBranch* b_tp_nmatch; @@ -107,6 +118,13 @@ void L1TrackNtuplePlot(TString type) { TBranch* b_matchtrk_chi2; TBranch* b_matchtrk_nstub; + TBranch* b_matchtrk5p_pt; + TBranch* b_matchtrk5p_eta; + TBranch* b_matchtrk5p_phi; + TBranch* b_matchtrk5p_z0; + TBranch* b_matchtrk5p_d0; + TBranch* b_matchtrk5p_chi2; + trk_pt = 0; trk_eta = 0; @@ -122,6 +140,7 @@ void L1TrackNtuplePlot(TString type) { tp_eta = 0; tp_phi = 0; tp_z0 = 0; + tp_d0 = 0; tp_pdgid = 0; tp_nmatch = 0; @@ -132,6 +151,13 @@ void L1TrackNtuplePlot(TString type) { matchtrk_chi2 = 0; matchtrk_nstub = 0; + matchtrk5p_pt = 0; + matchtrk5p_eta = 0; + matchtrk5p_phi = 0; + matchtrk5p_z0 = 0; + matchtrk5p_d0 = 0; + matchtrk5p_chi2 = 0; + tree->SetBranchAddress("trk_pt", &trk_pt, &b_trk_pt); tree->SetBranchAddress("trk_eta", &trk_eta, &b_trk_eta); @@ -147,6 +173,7 @@ void L1TrackNtuplePlot(TString type) { tree->SetBranchAddress("tp_eta", &tp_eta, &b_tp_eta); tree->SetBranchAddress("tp_phi", &tp_phi, &b_tp_phi); tree->SetBranchAddress("tp_z0", &tp_z0, &b_tp_z0); + tree->SetBranchAddress("tp_d0", &tp_d0, &b_tp_d0); tree->SetBranchAddress("tp_pdgid", &tp_pdgid, &b_tp_pdgid); tree->SetBranchAddress("tp_nmatch", &tp_nmatch, &b_tp_nmatch); @@ -157,6 +184,13 @@ void L1TrackNtuplePlot(TString type) { tree->SetBranchAddress("matchtrk_chi2", &matchtrk_chi2, &b_matchtrk_chi2); tree->SetBranchAddress("matchtrk_nstub", &matchtrk_nstub, &b_matchtrk_nstub); + tree->SetBranchAddress("matchtrk5p_pt", &matchtrk5p_pt, &b_matchtrk5p_pt); + tree->SetBranchAddress("matchtrk5p_eta", &matchtrk5p_eta, &b_matchtrk5p_eta); + tree->SetBranchAddress("matchtrk5p_phi", &matchtrk5p_phi, &b_matchtrk5p_phi); + tree->SetBranchAddress("matchtrk5p_z0", &matchtrk5p_z0, &b_matchtrk5p_z0); + tree->SetBranchAddress("matchtrk5p_d0", &matchtrk5p_d0, &b_matchtrk5p_d0); + tree->SetBranchAddress("matchtrk5p_chi2", &matchtrk5p_chi2, &b_matchtrk5p_chi2); + // ---------------------------------------------------------------------------------------------------------------- // histograms @@ -178,11 +212,15 @@ void L1TrackNtuplePlot(TString type) { TH1F* h_tp_pt_L = new TH1F("tp_pt_L", ";Tracking particle p_{T} [GeV]; Tracking particles / 0.1 GeV", 50, 0, 5.0); TH1F* h_tp_eta = new TH1F("tp_eta", ";Tracking particle #eta; Tracking particles / 0.1", 50, -2.5, 2.5); TH1F* h_tp_phi = new TH1F("tp_phi", ";Tracking particle #phi [rad]; Tracking particles / 0.1", 64, -3.2, 3.2); + TH1F* h_tp_z0 = new TH1F("tp_z0", ";Tracking particle z_{0} [cm]; Tracking particles / 1.0 cm", 50, -25.0, 25.0); + TH1F* h_tp_d0 = new TH1F("tp_d0", ";Tracking particle d_{0} [cm]; Tracking particles / 0.0002 cm", 100, -0.01, 0.01); TH1F* h_match_tp_pt = new TH1F("match_tp_pt", ";Tracking particle p_{T} [GeV]; Tracking particles / 1.0 GeV", 100, 0, 100.0); TH1F* h_match_tp_pt_L = new TH1F("match_tp_pt_L", ";Tracking particle p_{T} [GeV]; Tracking particles / 0.1 GeV", 50, 0, 5.0); TH1F* h_match_tp_eta = new TH1F("match_tp_eta", ";Tracking particle #eta; Tracking particles / 0.1", 50, -2.5, 2.5); TH1F* h_match_tp_phi = new TH1F("match_tp_phi", ";Tracking particle #phi [rad]; Tracking particles / 0.1", 64, -3.2, 3.2); + TH1F* h_match_tp_z0 = new TH1F("match_tp_z0", ";Tracking particle z_{0} [cm]; Tracking particles / 1.0 cm", 50, -25.0, 25.0); + TH1F* h_match_tp_d0 = new TH1F("match_tp_d0", ";Tracking particle d_{0} [cm]; Tracking particles / 0.0002 cm", 100, -0.01, 0.01); TH1F* h_match_trk_nstub = new TH1F("match_trk_nstub", ";Number of stubs; L1 tracks / 1.0", 15, 0, 15); TH1F* h_match_trk_nstub_C = new TH1F("match_trk_nstub_C", ";Number of stubs; L1 tracks / 1.0", 15, 0, 15); @@ -192,6 +230,7 @@ void L1TrackNtuplePlot(TString type) { // chi2 histograms // note: last bin is an overflow bin TH1F* h_match_trk_chi2 = new TH1F("match_trk_chi2", ";#chi^{2}; L1 tracks / 1.0", 100, 0, 100); + TH1F* h_match5p_trk_chi2 = new TH1F("match5p_trk_chi2", ";#chi^{2}; L1 tracks / 1.0", 100, 0, 100); TH1F* h_match_trk_chi2_C_L = new TH1F("match_trk_chi2_C_L", ";#chi^{2}; L1 tracks / 1.0", 100, 0, 100); TH1F* h_match_trk_chi2_I_L = new TH1F("match_trk_chi2_I_L", ";#chi^{2}; L1 tracks / 1.0", 100, 0, 100); TH1F* h_match_trk_chi2_F_L = new TH1F("match_trk_chi2_F_L", ";#chi^{2}; L1 tracks / 1.0", 100, 0, 100); @@ -205,6 +244,7 @@ void L1TrackNtuplePlot(TString type) { // chi2/dof histograms // note: lastbin is an overflow bin TH1F* h_match_trk_chi2_dof = new TH1F("match_trk_chi2_dof", ";#chi^{2} / D.O.F.; L1 tracks / 0.1", 150, 0, 15); + TH1F* h_match5p_trk_chi2_dof = new TH1F("match5p_trk_chi2_dof", ";#chi^{2} / D.O.F.; L1 tracks / 0.1", 150, 0, 15); TH1F* h_match_trk_chi2_dof_C_L = new TH1F("match_trk_chi2_dof_C_L", ";#chi^{2} / D.O.F.; L1 tracks / 0.1", 150, 0, 15); TH1F* h_match_trk_chi2_dof_I_L = new TH1F("match_trk_chi2_dof_I_L", ";#chi^{2} / D.O.F.; L1 tracks / 0.1", 150, 0, 15); TH1F* h_match_trk_chi2_dof_F_L = new TH1F("match_trk_chi2_dof_F_L", ";#chi^{2} / D.O.F.; L1 tracks / 0.1", 150, 0, 15); @@ -225,6 +265,14 @@ void L1TrackNtuplePlot(TString type) { TH1F* h_res_z0_I = new TH1F("res_z0_I", ";z_{0} residual (L1 - sim) [cm]; L1 tracks / 0.02", 100,-1, 1); TH1F* h_res_z0_F = new TH1F("res_z0_F", ";z_{0} residual (L1 - sim) [cm]; L1 tracks / 0.02", 100,-1, 1); + TH1F* h_res5p_pt = new TH1F("res5p_pt", ";p_{T} residual (L1 - sim) [GeV]; L1 tracks / 0.05", 200,-5.0, 5.0); + TH1F* h_res5p_ptRel = new TH1F("res5p_ptRel", ";p_{T} residual (L1 - sim) / p_{T}; L1 tracks / 0.01", 200,-1.0, 1.0); + TH1F* h_res5p_eta = new TH1F("res5p_eta", ";#eta residual (L1 - sim); L1 tracks / 0.0002", 100,-0.01, 0.01); + TH1F* h_res5p_phi = new TH1F("res5p_phi", ";#phi residual (L1 - sim) [rad]; L1 tracks / 0.0001", 100,-0.005, 0.005); + TH1F* h_res5p_z0 = new TH1F("res5p_z0", ";z_{0} residual (L1 - sim) [cm]; L1 tracks / 0.02", 100,-1, 1); + TH1F* h_res5p_d0 = new TH1F("res5p_d0", ";d_{0} residual (L1 - sim) [cm]; L1 tracks / 0.001 cm", 200,-0.1,0.1); + + // resolution vs. pt histograms const int nRANGE = 20; TString ptrange[nRANGE] = {"0-5","5-10", "10-15","15-20","20-25","25-30","30-35","35-40","40-45","45-50","50-55", @@ -252,6 +300,15 @@ void L1TrackNtuplePlot(TString type) { TH1F* h_resVsPt_eta[nRANGE]; + // *** 5-parameter fit versions *** + TH1F* h_res5pVsPt_pt[nRANGE]; + TH1F* h_res5pVsPt_ptRel[nRANGE]; + TH1F* h_res5pVsPt_z0[nRANGE]; + TH1F* h_res5pVsPt_d0[nRANGE]; + TH1F* h_res5pVsPt_phi[nRANGE]; + TH1F* h_res5pVsPt_eta[nRANGE]; + + for (int i=0; iat(it) > 2.0) { h_tp_eta->Fill(tp_eta->at(it)); h_tp_phi->Fill(tp_phi->at(it)); + h_tp_z0->Fill(tp_z0->at(it)); + h_tp_d0->Fill(tp_d0->at(it)); } // ---------------------------------------------------------------------------------------------------------------- // was the tracking particle matched to a L1 track? - if (tp_nmatch < 1) continue; + if (tp_nmatch->at(it) < 1) continue; // use only tracks with min 4 stubs if (matchtrk_nstub->at(it) < 4) continue; @@ -367,7 +449,16 @@ void L1TrackNtuplePlot(TString type) { h_match_trk_chi2->Fill(chi2); h_match_trk_chi2_dof->Fill(chi2dof); + + float chi2_5p = matchtrk5p_chi2->at(it); + float chi2dof_5p = (float)chi2_5p/ndof; + if (chi2_5p > 100) chi2_5p = 99.9; //for overflow bin + if (chi2dof_5p > 15) chi2dof_5p = 14.99; //for overflow bin + + h_match5p_trk_chi2->Fill(chi2_5p); + h_match5p_trk_chi2_dof->Fill(chi2dof_5p); + // central eta if (fabs(matchtrk_eta->at(it)) < 0.8) { if (matchtrk_pt->at(it) < 5) { @@ -430,6 +521,8 @@ void L1TrackNtuplePlot(TString type) { if (tp_pt->at(it) > 2) { h_match_tp_eta->Fill(tp_eta->at(it)); h_match_tp_phi->Fill(tp_phi->at(it)); + h_match_tp_z0->Fill(tp_z0->at(it)); + h_match_tp_d0->Fill(tp_d0->at(it)); } // fill nstub histograms @@ -445,6 +538,13 @@ void L1TrackNtuplePlot(TString type) { h_res_eta ->Fill(matchtrk_eta->at(it) - tp_eta->at(it)); h_res_phi ->Fill(matchtrk_phi->at(it) - tp_phi->at(it)); h_res_z0 ->Fill(matchtrk_z0->at(it) - tp_z0->at(it)); + + h_res5p_pt ->Fill(matchtrk5p_pt->at(it) - tp_pt->at(it)); + h_res5p_ptRel->Fill((matchtrk5p_pt->at(it) - tp_pt->at(it))/tp_pt->at(it)); + h_res5p_eta ->Fill(matchtrk5p_eta->at(it) - tp_eta->at(it)); + h_res5p_phi ->Fill(matchtrk5p_phi->at(it) - tp_phi->at(it)); + h_res5p_z0 ->Fill(matchtrk5p_z0->at(it) - tp_z0->at(it)); + h_res5p_d0->Fill(matchtrk5p_d0->at(it) - tp_d0->at(it)); if (fabs(matchtrk_eta->at(it)) < 0.8) h_res_z0_C->Fill(matchtrk_z0->at(it) - tp_z0->at(it)); @@ -480,6 +580,14 @@ void L1TrackNtuplePlot(TString type) { h_resVsPt_phi_F[im] ->Fill(matchtrk_phi->at(it) - tp_phi->at(it)); } + // ** 5-parameter fit versions *** + h_res5pVsPt_pt[im] ->Fill(matchtrk5p_pt->at(it) - tp_pt->at(it)); + h_res5pVsPt_ptRel[im]->Fill((matchtrk5p_pt->at(it) - tp_pt->at(it))/tp_pt->at(it)); + h_res5pVsPt_eta[im] ->Fill(matchtrk5p_eta->at(it) - tp_eta->at(it)); + h_res5pVsPt_phi[im] ->Fill(matchtrk5p_phi->at(it) - tp_phi->at(it)); + h_res5pVsPt_z0[im] ->Fill(matchtrk5p_z0->at(it) - tp_z0->at(it)); + h_res5pVsPt_d0[im] ->Fill(matchtrk5p_d0->at(it) - tp_d0->at(it)); + } } @@ -496,6 +604,14 @@ void L1TrackNtuplePlot(TString type) { else if (matchtrk_pt->at(it)<15 && matchtrk_pt->at(it)>=5) h_resVsEta_eta_M[im]->Fill(matchtrk_eta->at(it) - tp_eta->at(it)); else h_resVsEta_eta_H[im]->Fill(matchtrk_eta->at(it) - tp_eta->at(it)); + // *** 5-parameter fit versions *** + h_res5pVsEta_pt[im] ->Fill(matchtrk5p_pt->at(it) - tp_pt->at(it)); + h_res5pVsEta_ptRel[im]->Fill((matchtrk5p_pt->at(it) - tp_pt->at(it))/tp_pt->at(it)); + h_res5pVsEta_eta[im] ->Fill(matchtrk5p_eta->at(it) - tp_eta->at(it)); + h_res5pVsEta_phi[im] ->Fill(matchtrk5p_phi->at(it) - tp_phi->at(it)); + h_res5pVsEta_z0[im] ->Fill(matchtrk5p_z0->at(it) - tp_z0->at(it)); + h_res5pVsEta_d0[im] ->Fill(matchtrk5p_d0->at(it) - tp_d0->at(it)); + } } @@ -542,6 +658,15 @@ void L1TrackNtuplePlot(TString type) { TH1F* h2_resVsPt_eta = new TH1F("resVsPt2_eta", ";Tracking particle p_{T} [GeV]; #eta resolution", 20,0,100); + // *** 5-parameter fit versions *** + TH1F* h2_res5pVsPt_pt = new TH1F("res5pVsPt2_pt", ";Tracking particle p_{T} [GeV]; p_{T} resolution", 20,0,100); + TH1F* h2_res5pVsPt_ptRel = new TH1F("res5pVsPt2_ptRel", ";Tracking particle p_{T} [GeV]; p_{T} resolution / p_{T}", 20,0,100); + TH1F* h2_res5pVsPt_z0 = new TH1F("res5pVsPt2_z0", ";Tracking particle p_{T} [GeV]; z_{0} resolution [cm]", 20,0,100); + TH1F* h2_res5pVsPt_d0 = new TH1F("res5pVsPt2_d0", ";Tracking particle p_{T} [GeV]; d_{0} resolution [cm]", 20,0,100); + TH1F* h2_res5pVsPt_phi = new TH1F("res5pVsPt2_phi", ";Tracking particle p_{T} [GeV]; #phi resolution [rad]", 20,0,100); + TH1F* h2_res5pVsPt_eta = new TH1F("res5pVsPt2_eta", ";Tracking particle p_{T} [GeV]; #eta resolution", 20,0,100); + + for (int i=0; iSetBinContent(i+1, h_resVsPt_pt[i] ->GetRMS()); @@ -591,6 +716,22 @@ void L1TrackNtuplePlot(TString type) { h2_resVsPt_eta->SetBinContent(i+1, h_resVsPt_eta[i]->GetRMS()); h2_resVsPt_eta->SetBinError( i+1, h_resVsPt_eta[i]->GetRMSError()); + + // *** 5-parameter fit versions *** + // set bin content and error + h2_res5pVsPt_pt ->SetBinContent(i+1, h_res5pVsPt_pt[i] ->GetRMS()); + h2_res5pVsPt_pt ->SetBinError( i+1, h_res5pVsPt_pt[i] ->GetRMSError()); + h2_res5pVsPt_ptRel ->SetBinContent(i+1, h_res5pVsPt_ptRel[i] ->GetRMS()); + h2_res5pVsPt_ptRel ->SetBinError( i+1, h_res5pVsPt_ptRel[i] ->GetRMSError()); + h2_res5pVsPt_z0 ->SetBinContent(i+1, h_res5pVsPt_z0[i] ->GetRMS()); + h2_res5pVsPt_z0 ->SetBinError( i+1, h_res5pVsPt_z0[i] ->GetRMSError()); + h2_res5pVsPt_d0 ->SetBinContent(i+1, h_res5pVsPt_d0[i] ->GetRMS()); + h2_res5pVsPt_d0 ->SetBinError( i+1, h_res5pVsPt_d0[i] ->GetRMSError()); + h2_res5pVsPt_phi ->SetBinContent(i+1, h_res5pVsPt_phi[i] ->GetRMS()); + h2_res5pVsPt_phi ->SetBinError( i+1, h_res5pVsPt_phi[i] ->GetRMSError()); + h2_res5pVsPt_eta->SetBinContent(i+1, h_res5pVsPt_eta[i]->GetRMS()); + h2_res5pVsPt_eta->SetBinError( i+1, h_res5pVsPt_eta[i]->GetRMSError()); + } @@ -611,6 +752,15 @@ void L1TrackNtuplePlot(TString type) { TH1F* h2_resVsEta_pt = new TH1F("resVsEta2_pt", ";Tracking particle |#eta|; p_{T} resolution [GeV]", 25,0,2.5); TH1F* h2_resVsEta_ptRel = new TH1F("resVsEta2_ptRel", ";Tracking particle |#eta|; p_{T} resolution / p_{T}", 25,0,2.5); + // *** 5-parameter fit versions *** + TH1F* h2_res5pVsEta_eta = new TH1F("res5pVsEta2_eta", ";Tracking particle |#eta|; #eta resolution", 25,0,2.5); + TH1F* h2_res5pVsEta_z0 = new TH1F("res5pVsEta2_z0", ";Tracking particle |#eta|; z_{0} resolution [cm]", 25,0,2.5); + TH1F* h2_res5pVsEta_d0 = new TH1F("res5pVsEta2_d0", ";Tracking particle |#eta|; d_{0} resolution [cm]", 25,0,2.5); + TH1F* h2_res5pVsEta_phi = new TH1F("res5pVsEta2_phi", ";Tracking particle |#eta|; #phi resolution [rad]", 25,0,2.5); + TH1F* h2_res5pVsEta_pt = new TH1F("res5pVsEta2_pt", ";Tracking particle |#eta|; p_{T} resolution [GeV]", 25,0,2.5); + TH1F* h2_res5pVsEta_ptRel = new TH1F("res5pVsEta2_ptRel", ";Tracking particle |#eta|; p_{T} resolution / p_{T}", 25,0,2.5); + + for (int i=0; iSetBinContent(i+1, h_resVsEta_eta[i] ->GetRMS()); @@ -640,6 +790,22 @@ void L1TrackNtuplePlot(TString type) { h2_resVsEta_pt ->SetBinError( i+1, h_resVsEta_pt[i] ->GetRMSError()); h2_resVsEta_ptRel->SetBinContent(i+1, h_resVsEta_ptRel[i]->GetRMS()); h2_resVsEta_ptRel->SetBinError( i+1, h_resVsEta_ptRel[i]->GetRMSError()); + + // *** 5-parameter fit versions *** + // set bin content and error + h2_res5pVsEta_eta ->SetBinContent(i+1, h_res5pVsEta_eta[i] ->GetRMS()); + h2_res5pVsEta_eta ->SetBinError( i+1, h_res5pVsEta_eta[i] ->GetRMSError()); + h2_res5pVsEta_z0 ->SetBinContent(i+1, h_res5pVsEta_z0[i] ->GetRMS()); + h2_res5pVsEta_z0 ->SetBinError( i+1, h_res5pVsEta_z0[i] ->GetRMSError()); + h2_res5pVsEta_d0 ->SetBinContent(i+1, h_res5pVsEta_d0[i] ->GetRMS()); + h2_res5pVsEta_d0 ->SetBinError( i+1, h_res5pVsEta_d0[i] ->GetRMSError()); + h2_res5pVsEta_phi->SetBinContent(i+1, h_res5pVsEta_phi[i]->GetRMS()); + h2_res5pVsEta_phi->SetBinError( i+1, h_res5pVsEta_phi[i]->GetRMSError()); + h2_res5pVsEta_pt ->SetBinContent(i+1, h_res5pVsEta_pt[i] ->GetRMS()); + h2_res5pVsEta_pt ->SetBinError( i+1, h_res5pVsEta_pt[i] ->GetRMSError()); + h2_res5pVsEta_ptRel->SetBinContent(i+1, h_res5pVsEta_ptRel[i]->GetRMS()); + h2_res5pVsEta_ptRel->SetBinError( i+1, h_res5pVsEta_ptRel[i]->GetRMSError()); + } @@ -676,15 +842,34 @@ void L1TrackNtuplePlot(TString type) { h2_resVsEta_pt ->SetMinimum(0); h2_resVsEta_ptRel->SetMinimum(0); + h2_res5pVsPt_pt ->SetMinimum(0); + h2_res5pVsPt_ptRel ->SetMinimum(0); + h2_res5pVsPt_z0 ->SetMinimum(0); + h2_res5pVsPt_d0 ->SetMinimum(0); + h2_res5pVsPt_phi ->SetMinimum(0); + h2_res5pVsPt_eta->SetMinimum(0); + + h2_res5pVsEta_eta ->SetMinimum(0); + h2_res5pVsEta_z0 ->SetMinimum(0); + h2_res5pVsEta_d0 ->SetMinimum(0); + h2_res5pVsEta_phi->SetMinimum(0); + h2_res5pVsEta_pt ->SetMinimum(0); + h2_res5pVsEta_ptRel->SetMinimum(0); + // draw and save plots char ctxt[500]; - TCanvas c("c"); + TCanvas c; h2_resVsPt_pt->Draw(); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt.png"); - c.SaveAs(type+"_canvas.pdf("); // keep the pdf file open + if (makeCanvas) c.SaveAs(type+"_canvas.pdf("); // keep the pdf file open + + h2_res5pVsPt_pt->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_pt.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_pt.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h2_resVsPt_pt_C->Draw(); @@ -692,27 +877,32 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt_C.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt_C.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_pt_I->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt_I.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt_I.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_pt_F->Draw(); sprintf(ctxt,"|eta| > 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt_F.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_pt_F.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h2_resVsPt_ptRel->Draw(); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsPt_ptRel->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_ptRel.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_ptRel.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h2_resVsPt_ptRel_C->Draw(); @@ -720,27 +910,27 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel_C.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel_C.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_ptRel_I->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel_I.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel_I.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_ptRel_F->Draw(); sprintf(ctxt,"|eta| > 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel_F.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_ptRel_F.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h2_mresVsPt_pt->Draw(); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h2_mresVsPt_pt_C->Draw(); @@ -748,21 +938,21 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_C.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_C.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_mresVsPt_pt_I->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_I.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_I.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_mresVsPt_pt_F->Draw(); sprintf(ctxt,"|eta| > 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_F.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_F.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); // combined plot for the pt residual bias h2_mresVsPt_pt_C->GetYaxis()->SetRangeUser(-1.5,1.5); @@ -786,13 +976,23 @@ void L1TrackNtuplePlot(TString type) { c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_comb.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsPt_pt_comb.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h2_resVsPt_z0->Draw(); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsPt_z0->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_z0.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_z0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsPt_d0->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_d0.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_d0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h2_resVsPt_z0_C->Draw(); @@ -800,28 +1000,32 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.22,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0_C.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0_C.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_z0_I->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6"); mySmallText(0.22,0.22,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0_I.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0_I.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_z0_F->Draw(); sprintf(ctxt,"|eta| > 1.6"); mySmallText(0.22,0.22,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0_F.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_z0_F.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h2_resVsPt_phi->Draw(); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + h2_res5pVsPt_phi->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_phi.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_phi.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h2_resVsPt_phi_C->Draw(); @@ -829,35 +1033,46 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi_C.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi_C.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_phi_I->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi_I.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi_I.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsPt_phi_F->Draw(); sprintf(ctxt,"|eta| > 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi_F.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_phi_F.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h2_resVsPt_eta->Draw(); c.SaveAs("TrkPlots/"+type+"_resVsPt_eta.eps"); c.SaveAs("TrkPlots/"+type+"_resVsPt_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + h2_res5pVsPt_eta->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_eta.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsPt_eta.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsEta_eta->Draw(); sprintf(ctxt,"Full p_{T} range"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsEta_eta->Draw(); + sprintf(ctxt,"Full p_{T} range"); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_eta.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_eta.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h2_resVsEta_eta_L->Draw(); @@ -865,21 +1080,21 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta_L.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta_L.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsEta_eta_M->Draw(); sprintf(ctxt,"5 < p_{T} < 15 GeV"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta_M.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta_M.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsEta_eta_H->Draw(); sprintf(ctxt,"p_{T} > 15 GeV"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta_H.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_eta_H.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h2_mresVsEta_eta->Draw(); @@ -887,7 +1102,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h2_mresVsEta_eta_L->Draw(); @@ -895,21 +1110,21 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta_L.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta_L.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_mresVsEta_eta_M->Draw(); sprintf(ctxt,"5 < p_{T} < 15 GeV"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta_M.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta_M.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_mresVsEta_eta_H->Draw(); sprintf(ctxt,"p_{T} > 15 GeV"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta_H.eps"); c.SaveAs("TrkPlots/"+type+"_mresVsEta_eta_H.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h2_resVsEta_z0->Draw(); @@ -917,26 +1132,58 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsEta_z0.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_z0.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsEta_z0->Draw(); + sprintf(ctxt,"Full p_{T} range"); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_z0.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_z0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsEta_d0->Draw(); + sprintf(ctxt,"Full p_{T} range"); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_d0.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_d0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + h2_resVsEta_phi->Draw(); sprintf(ctxt,"Full p_{T} range"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_resVsEta_phi.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_phi.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsEta_phi->Draw(); + sprintf(ctxt,"Full p_{T} range"); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_phi.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_phi.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsEta_pt->Draw(); c.SaveAs("TrkPlots/"+type+"_resVsEta_pt.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_pt.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsEta_pt->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_pt.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_pt.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h2_resVsEta_ptRel->Draw(); c.SaveAs("TrkPlots/"+type+"_resVsEta_ptRel.eps"); c.SaveAs("TrkPlots/"+type+"_resVsEta_ptRel.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h2_res5pVsEta_ptRel->Draw(); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_ptRel.eps"); + c.SaveAs("TrkPlots/"+type+"_res5pVsEta_ptRel.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + - // ---------------------------------------------------------------------------------------------------------------- // track quality plots // ---------------------------------------------------------------------------------------------------------------- @@ -948,28 +1195,28 @@ void L1TrackNtuplePlot(TString type) { h_match_trk_nstub->Draw(); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_nstub_C->Draw(); sprintf(ctxt,"|eta| < 0.8"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub_C.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub_C.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_nstub_I->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub_I.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub_I.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_nstub_F->Draw(); sprintf(ctxt,"|eta| > 1.6"); mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub_F.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_nstub_F.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h_match_trk_chi2->Draw(); @@ -977,7 +1224,14 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_match5p_trk_chi2->Draw(); + sprintf(ctxt,"|eta| < 2.5; Full p_{T} range"); + mySmallText(0.52,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_match5p_trk_chi2.png"); + c.SaveAs("TrkPlots/"+type+"_match5p_trk_chi2.eps"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h_match_trk_chi2_C_L->Draw(); @@ -985,63 +1239,63 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_L.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_L.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_I_L->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6; p_{T} < 5 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_L.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_L.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_F_L->Draw(); sprintf(ctxt,"|eta| > 1.6; p_{T} < 5 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_L.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_L.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_C_M->Draw(); sprintf(ctxt,"|eta| < 0.8; 5 < p_{T} < 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_M.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_M.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_I_M->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6, 5 < p_{T} < 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_M.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_M.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_F_M->Draw(); sprintf(ctxt,"|eta| > 1.6; 5 < p_{T} < 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_M.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_M.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_C_H->Draw(); sprintf(ctxt,"|eta| < 0.8; p_{T} > 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_H.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_H.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_I_H->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6; p_{T} > 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_H.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_H.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_F_H->Draw(); sprintf(ctxt,"|eta| > 1.6; p_{T} > 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_H.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_H.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h_match_trk_chi2_dof->Draw(); @@ -1049,7 +1303,14 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_match5p_trk_chi2_dof->Draw(); + sprintf(ctxt,"|eta| < 2.5; Full p_{T} range"); + mySmallText(0.52,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_match5p_trk_chi2_dof.png"); + c.SaveAs("TrkPlots/"+type+"_match5p_trk_chi2_dof.eps"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (doDetailedPlots) { h_match_trk_chi2_dof_C_L->Draw(); @@ -1057,63 +1318,63 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_L.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_L.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_I_L->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6; p_{T} < 5 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_L.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_L.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_F_L->Draw(); sprintf(ctxt,"|eta| > 1.6; p_{T} < 5 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_L.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_L.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_C_M->Draw(); sprintf(ctxt,"|eta| < 0.8; 5 < p_{T} < 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_M.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_M.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_I_M->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6, 5 < p_{T} < 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_M.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_M.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_F_M->Draw(); sprintf(ctxt,"|eta| > 1.6; 5 < p_{T} < 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_M.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_M.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_C_H->Draw(); sprintf(ctxt,"|eta| < 0.8; p_{T} > 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_H.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_H.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_I_H->Draw(); sprintf(ctxt,"0.8 < |eta| < 1.6; p_{T} > 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_H.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_H.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_F_H->Draw(); sprintf(ctxt,"|eta| > 1.6; p_{T} > 15 GeV"); mySmallText(0.52,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_H.png"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_H.eps"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } @@ -1157,56 +1418,82 @@ void L1TrackNtuplePlot(TString type) { h_eff_phi->GetYaxis()->SetTitle("Efficiency"); h_eff_phi->Divide(h_match_tp_phi, h_tp_phi, 1.0, 1.0, "B"); + h_match_tp_z0->Sumw2(); + h_tp_z0->Sumw2(); + TH1F* h_eff_z0 = (TH1F*) h_match_tp_z0->Clone(); + h_eff_z0->SetName("eff_z0"); + h_eff_z0->GetYaxis()->SetTitle("Efficiency"); + h_eff_z0->Divide(h_match_tp_z0, h_tp_z0, 1.0, 1.0, "B"); + + h_match_tp_d0->Sumw2(); + h_tp_d0->Sumw2(); + TH1F* h_eff_d0 = (TH1F*) h_match_tp_d0->Clone(); + h_eff_d0->SetName("eff_d0"); + h_eff_d0->GetYaxis()->SetTitle("Efficiency"); + h_eff_d0->Divide(h_match_tp_d0, h_tp_d0, 1.0, 1.0, "B"); + // set the axis range h_eff_pt ->SetAxisRange(0,1.1,"Y"); h_eff_pt_L->SetAxisRange(0,1.1,"Y"); h_eff_eta ->SetAxisRange(0,1.1,"Y"); h_eff_phi ->SetAxisRange(0,1.1,"Y"); - + h_eff_z0 ->SetAxisRange(0,1.1,"Y"); + h_eff_d0 ->SetAxisRange(0,1.1,"Y"); + // draw and save plots h_eff_pt->Draw(); c.SaveAs("TrkPlots/"+type+"_eff_pt.eps"); c.SaveAs("TrkPlots/"+type+"_eff_pt.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (type.Contains("SingleMu")) { h_eff_pt->GetYaxis()->SetRangeUser(0.9,1.01); // zoomed-in plot c.SaveAs("TrkPlots/"+type+"_eff_pt_zoom.eps"); c.SaveAs("TrkPlots/"+type+"_eff_pt_zoom.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h_eff_pt_L->Draw(); c.SaveAs("TrkPlots/"+type+"_eff_pt_L.eps"); c.SaveAs("TrkPlots/"+type+"_eff_pt_L.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_eff_eta->Draw(); c.SaveAs("TrkPlots/"+type+"_eff_eta.eps"); c.SaveAs("TrkPlots/"+type+"_eff_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (type.Contains("SingleMu")) { h_eff_eta->GetYaxis()->SetRangeUser(0.8,1.01); // zoomed-in plot c.SaveAs("TrkPlots/"+type+"_eff_eta_zoom.eps"); c.SaveAs("TrkPlots/"+type+"_eff_eta_zoom.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } h_eff_phi->Draw(); c.SaveAs("TrkPlots/"+type+"_eff_phi.eps"); c.SaveAs("TrkPlots/"+type+"_eff_phi.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); if (type.Contains("SingleMu")) { h_eff_phi->GetYaxis()->SetRangeUser(0.8,1.01); // zoomed-in plot c.SaveAs("TrkPlots/"+type+"_eff_phi_zoom.eps"); c.SaveAs("TrkPlots/"+type+"_eff_phi_zoom.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } + h_eff_z0->Draw(); + c.SaveAs("TrkPlots/"+type+"_eff_z0.eps"); + c.SaveAs("TrkPlots/"+type+"_eff_z0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_eff_d0->Draw(); + c.SaveAs("TrkPlots/"+type+"_eff_d0.eps"); + c.SaveAs("TrkPlots/"+type+"_eff_d0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + // ---------------------------------------------------------------------------------------------------------------- // resolution plots @@ -1223,7 +1510,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_pt.eps"); c.SaveAs("TrkPlots/"+type+"_res_pt.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_res_ptRel->Draw(); rms = h_res_ptRel->GetRMS(); @@ -1231,7 +1518,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_ptRel.eps"); c.SaveAs("TrkPlots/"+type+"_res_ptRel.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_res_eta->Draw(); rms = h_res_eta->GetRMS(); @@ -1239,7 +1526,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_eta.eps"); c.SaveAs("TrkPlots/"+type+"_res_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_res_phi->Draw(); rms = h_res_phi->GetRMS(); @@ -1247,7 +1534,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_phi.eps"); c.SaveAs("TrkPlots/"+type+"_res_phi.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_res_z0->Draw(); rms = h_res_z0->GetRMS(); @@ -1255,7 +1542,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.82,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_z0.eps"); c.SaveAs("TrkPlots/"+type+"_res_z0.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_res_z0_C->Draw(); rms = h_res_z0_C->GetRMS(); @@ -1265,7 +1552,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.76,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_z0_C.eps"); c.SaveAs("TrkPlots/"+type+"_res_z0_C.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_res_z0_I->Draw(); rms = h_res_z0_I->GetRMS(); @@ -1275,7 +1562,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.76,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_z0_I.eps"); c.SaveAs("TrkPlots/"+type+"_res_z0_I.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_res_z0_F->Draw(); rms = h_res_z0_F->GetRMS(); @@ -1285,7 +1572,56 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.22,0.76,1,ctxt); c.SaveAs("TrkPlots/"+type+"_res_z0_F.eps"); c.SaveAs("TrkPlots/"+type+"_res_z0_F.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_res5p_pt->Draw(); + rms = h_res5p_pt->GetRMS(); + sprintf(ctxt,"RMS = %.4f",rms); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5p_pt.eps"); + c.SaveAs("TrkPlots/"+type+"_res5p_pt.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_res5p_ptRel->Draw(); + rms = h_res5p_ptRel->GetRMS(); + sprintf(ctxt,"RMS = %.4f",rms); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5p_ptRel.eps"); + c.SaveAs("TrkPlots/"+type+"_res5p_ptRel.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_res5p_eta->Draw(); + rms = h_res5p_eta->GetRMS(); + sprintf(ctxt,"RMS = %.3e",rms); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5p_eta.eps"); + c.SaveAs("TrkPlots/"+type+"_res5p_eta.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_res5p_phi->Draw(); + rms = h_res5p_phi->GetRMS(); + sprintf(ctxt,"RMS = %.3e",rms); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5p_phi.eps"); + c.SaveAs("TrkPlots/"+type+"_res5p_phi.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_res5p_z0->Draw(); + rms = h_res5p_z0->GetRMS(); + sprintf(ctxt,"RMS = %.4f",rms); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5p_z0.eps"); + c.SaveAs("TrkPlots/"+type+"_res5p_z0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + + h_res5p_d0->Draw(); + rms = h_res5p_d0->GetRMS(); + sprintf(ctxt,"RMS = %.4f",rms); + mySmallText(0.22,0.82,1,ctxt); + c.SaveAs("TrkPlots/"+type+"_res5p_d0.eps"); + c.SaveAs("TrkPlots/"+type+"_res5p_d0.png"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); + } @@ -1299,32 +1635,32 @@ void L1TrackNtuplePlot(TString type) { h_2d_logchi2_eta->Draw("colz"); c.SaveAs("TrkPlots/"+type+"_2d_logchi2_eta.eps"); c.SaveAs("TrkPlots/"+type+"_2d_logchi2_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_2d_logchi2_dof_eta->Draw("colz"); c.SaveAs("TrkPlots/"+type+"_2d_logchi2_dof_eta.eps"); c.SaveAs("TrkPlots/"+type+"_2d_logchi2_dof_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_2d_dz0_eta->Draw("colz"); c.SaveAs("TrkPlots/"+type+"_2d_dz0_eta.eps"); c.SaveAs("TrkPlots/"+type+"_2d_dz0_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_2d_deta_eta->Draw("colz"); c.SaveAs("TrkPlots/"+type+"_2d_deta_eta.eps"); c.SaveAs("TrkPlots/"+type+"_2d_deta_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_2d_dphi_eta->Draw("colz"); c.SaveAs("TrkPlots/"+type+"_2d_dphi_eta.eps"); c.SaveAs("TrkPlots/"+type+"_2d_dphi_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_2d_dptRel_eta->Draw("colz"); c.SaveAs("TrkPlots/"+type+"_2d_dptRel_eta.eps"); c.SaveAs("TrkPlots/"+type+"_2d_dptRel_eta.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); } // ---------------------------------------------------------------------------------------------------------------- @@ -1340,7 +1676,7 @@ void L1TrackNtuplePlot(TString type) { h_match_trk_chi2->Draw(); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_log.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_log.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_C_H->Draw(); h_match_trk_chi2_C_M->Draw("same"); @@ -1362,7 +1698,7 @@ void L1TrackNtuplePlot(TString type) { c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_log_comb.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_C_log_comb.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_I_H->Draw(); h_match_trk_chi2_I_M->Draw("same"); @@ -1374,7 +1710,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.66,0.6,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_log_comb.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_I_log_comb.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_F_H->Draw(); h_match_trk_chi2_F_M->Draw("same"); @@ -1386,12 +1722,12 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.66,0.6,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_log_comb.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_F_log_comb.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof->Draw(); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_log.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_log.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_C_H->Draw(); h_match_trk_chi2_dof_C_M->Draw("same"); @@ -1403,7 +1739,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.66,0.6,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_log_comb.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_C_log_comb.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_I_H->Draw(); h_match_trk_chi2_dof_I_M->Draw("same"); @@ -1415,7 +1751,7 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.66,0.6,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_log_comb.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_I_log_comb.png"); - c.SaveAs(type+"_canvas.pdf"); + if (makeCanvas) c.SaveAs(type+"_canvas.pdf"); h_match_trk_chi2_dof_F_H->Draw(); h_match_trk_chi2_dof_F_M->Draw("same"); @@ -1427,9 +1763,9 @@ void L1TrackNtuplePlot(TString type) { mySmallText(0.66,0.6,1,ctxt); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_log_comb.eps"); c.SaveAs("TrkPlots/"+type+"_match_trk_chi2_dof_F_log_comb.png"); - c.SaveAs(type+"_canvas.pdf)"); // close the pdf file + if (makeCanvas) c.SaveAs(type+"_canvas.pdf)"); // close the pdf file } - else { + else if (makeCanvas) { c.Clear(); c.SaveAs(type+"_canvas.pdf)"); // close the pdf file } From 80cecb624d5d6a1683b8c6131db49970562de54c Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 10 Jun 2014 13:24:25 +0200 Subject: [PATCH 042/252] correct teh include in pTFrom2Stubs.cc --- SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc b/SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc index b176060fa9adb..3539625c7433d 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/src/pTFrom2Stubs.cc @@ -4,7 +4,7 @@ #include #include -#include "pTFrom2Stubs.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/pTFrom2Stubs.h" namespace pTFrom2Stubs{ From 55828978b24639dcce057c7963eb44a9c5d503b3 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 11 Jun 2014 18:08:58 +0200 Subject: [PATCH 043/252] fix bug in L1TkMuonFromExtendedProducer.cc (affected et() ) --- .../L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc index 2ccfafa372b73..c8871bd44064f 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc @@ -233,7 +233,8 @@ L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& if (dEta < etaCut && dPhi < phiCut){ Ptr< L1TkTrackType > l1tkPtr(l1tksH, match_idx); auto p3 = matchTk.getMomentum(); - float p4e = sqrt(0.105658369*0.105658369 + p3.mag()); + float p4e = sqrt(0.105658369*0.105658369 + p3.mag2() ); + math::XYZTLorentzVector l1tkp4(p3.x(), p3.y(), p3.z(), p4e); auto tkv3=matchTk.getPOCA(); From afdd5457115ec7b360c9e8aaefdbb2e9278f5713 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 12 Jun 2014 21:56:45 +0200 Subject: [PATCH 044/252] first version of L1TkTauFromCaloProducer from Alexandros --- .../plugins/L1CaloTauCorrectionsProducer.cc | 216 ++++ ...TauFromCalo.cc => L1TkTauFromCaloDummy.cc} | 28 +- .../plugins/L1TkTauFromCaloProducer.cc | 500 ++++++++++ .../python/tools/datasetsHelper.py | 929 ++++++++++++++++++ .../test/test_L1TkTauFromCalo_cfg.py | 120 +++ 5 files changed, 1779 insertions(+), 14 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTauCorrectionsProducer.cc rename SLHCUpgradeSimulations/L1TrackTrigger/plugins/{L1TkTauFromCalo.cc => L1TkTauFromCaloDummy.cc} (88%) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/tools/datasetsHelper.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTauCorrectionsProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTauCorrectionsProducer.cc new file mode 100644 index 0000000000000..fd49c6ec3655b --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTauCorrectionsProducer.cc @@ -0,0 +1,216 @@ +// -*- C++ -*- +// +// Package: L1CaloTauCorrectionsProducer +// Class: L1CaloTauCorrectionsProducer +// +/**\class L1CaloTauCorrectionsProducer L1CaloTauCorrectionsProducer.cc SLHCUpgradeSimulations/L1CaloTauCorrectionsProducer/plugins/L1CaloTauCorrectionsProducer.cc + + Description: A very trivial producer which takes as input a collections for the stage-2 L1CaloTaus and produces another identical collection with calibration + corrections applied to the 4-momenta of each L1CaloTau. + + Implementation: To be used for L1 Menu (Rate) calculations of stage-2 L1CaloTaus. + +*/ +// +// Original Author: Alexandros Attikis +// Created: Tue, 10 Jun 2014 09:11:12 GMT +// $Id$ +// +// + + +// system include files +#include +#include +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +// +#include "DataFormats/L1Trigger/interface/L1JetParticle.h" + +// +// class declaration +// + +class L1CaloTauCorrectionsProducer : public edm::EDProducer { +public: + +typedef std::vector< l1extra::L1JetParticle > L1CaloTauCollectionType; + +explicit L1CaloTauCorrectionsProducer(const edm::ParameterSet&); +~L1CaloTauCorrectionsProducer(); + +static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + +private: +virtual void beginJob() override; +virtual void produce(edm::Event&, const edm::EventSetup&) override; +virtual void endJob() override; +double GetCorrectionFactor(double Et, double Eta); +int FindNearestIndex(const unsigned int arraySize, double myVector[], double myEtaValue); + +// ----------member data --------------------------- +edm::InputTag L1TausInputTag; + +}; + +// +// constants, enums and typedefs +// + + +// +// static data member definitions +// + +// +// constructors and destructor +// +L1CaloTauCorrectionsProducer::L1CaloTauCorrectionsProducer(const edm::ParameterSet& iConfig) +{ + + +// register your products +L1TausInputTag = iConfig.getParameter("L1TausInputTag"); + +produces("CalibratedTaus").setBranchAlias( "CalibratedTaus"); + +} + + +L1CaloTauCorrectionsProducer::~L1CaloTauCorrectionsProducer() +{ + +} + +// ------------ method called to produce the data ------------ +void +L1CaloTauCorrectionsProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ +using namespace edm; + +std::auto_ptr result(new L1CaloTauCollectionType); + +// Get the stage-2 L1CaloTaus from the L1-ExtraParticles +edm::Handle< L1CaloTauCollectionType > h_L1CaloTau; +iEvent.getByLabel( L1TausInputTag, h_L1CaloTau ); + +// for-loop: L1CaloTaus +for ( L1CaloTauCollectionType::const_iterator L1CaloTau = h_L1CaloTau->begin(); L1CaloTau != h_L1CaloTau->end(); L1CaloTau++){ + +double L1CaloTau_E = L1CaloTau->p4().energy(); +double L1CaloTau_Px = L1CaloTau->p4().px(); +double L1CaloTau_Py = L1CaloTau->p4().py(); +double L1CaloTau_Pz = L1CaloTau->p4().pz(); + +//math::XYZTLorentzVector p4 = L1CaloTau->p4(); +math::XYZTLorentzVector p4Corr(0, 0, 0, 0); + +double corrFactor = L1CaloTauCorrectionsProducer::GetCorrectionFactor( L1CaloTau->p4().Et(), L1CaloTau->p4().eta() ); +p4Corr.SetPxPyPzE( L1CaloTau_Px*corrFactor, L1CaloTau_Py*corrFactor, L1CaloTau_Pz*corrFactor, L1CaloTau_E*corrFactor); +l1extra::L1JetParticle L1CaloTauCorr(p4Corr); + +// std::cout << "---> p4.energy() = " << p4.energy() << ", p4Corr.energy() = " << p4Corr.energy() << std::endl; +result -> push_back( L1CaloTauCorr ); +} + +iEvent.put( result , "CalibratedTaus"); + +} + + +double L1CaloTauCorrectionsProducer::GetCorrectionFactor(double Et, double Eta){ + + double corrFactor = 0; + double myEtaMap[] = {-2.3, -2.1, -1.9, -1.7, -1.5, -1.3, -1.1, -0.9, -0.7, -0.5, -0.3, -0.1, +0.1, +0.3, +0.5, +0.7, +0.9, +1.1, +1.3, +1.5, +1.7, +1.9, +2.1, +2.3}; + int arrayIndex = -1; + arrayIndex = L1CaloTauCorrectionsProducer::FindNearestIndex( 24, myEtaMap, Eta ); + + /// Using "PrivateProduction2014" produced by Emanuelle (tmp solution) + double Et_LEQ20 [] = {1.71, 1.82, 1.64, 1.46, 1.07, 1.31, 1.37, 1.37, 1.31, 1.35, 1.54, 1.52, 1.42, 1.31, 1.26, 1.36, 1.51, 1.22, 1.15, 1.14, 1.39, 1.42, 1.34, 1.31}; + double Et_G20_LEQ40 [] = {1.10, 1.14, 1.19, 1.12, 0.89, 0.94, 1.07, 1.06, 0.99, 1.10, 1.08, 1.14, 1.16, 1.09, 1.09, 1.00, 1.02, 0.99, 0.92, 0.90, 1.15, 1.23, 1.11, 1.13}; + double Et_G40_LEQ60 [] = {1.01, 0.99, 1.05, 0.99, 0.84, 0.81, 0.87, 0.87, 0.93, 0.95, 0.98, 0.99, 0.96, 1.00, 0.96, 0.93, 0.89, 0.86, 0.86, 0.81, 1.00, 1.06, 1.01, 1.00}; + double Et_G60_LEQ80 [] = {0.98, 0.90, 0.96, 0.91, 0.75, 0.76, 0.77, 0.86, 0.84, 0.90, 0.87, 0.93, 0.94, 0.87, 0.88, 0.86, 0.78, 0.77, 0.76, 0.76, 0.88, 1.02, 0.89, 1.00}; + double Et_G80 [] = {0.91, 0.91, 0.66, 0.66, 0.65, 0.68, 0.71, 0.74, 0.75, 0.83, 0.77, 0.77, 0.77, 0.74, 0.72, 0.77, 0.76, 0.76, 0.71, 0.65, 0.71, 0.71, 0.75, 0.91}; + + /// Using "TTI2023Upg14D" official producation (for Technical Proposal), dataset "SingleTauOneProng" + // double Et_LEQ20 [] = {2.26, 2.31, 1.78, 1.44, 1.12, 1.13, 1.17, 1.16, 1.23, 1.27, 1.29, 1.34, 1.26, 1.3 , 1.26, 1.28, 1.17, 1.13, 1.15, 1.16, 1.4 , 1.51, 2.13, 2.1 }; + // double Et_G20_LEQ40 [] = {1.08, 1.04, 1.15, 1.09, 0.84, 0.88, 0.93, 0.97, 1.01, 1.03, 1.05, 1.08, 1.07, 1.07, 1.02, 1.0 , 0.98, 0.92, 0.9 , 0.84, 1.08, 1.13, 1.04, 1.08}; + // double Et_G40_LEQ60 [] = {1.05, 1.0 , 1.04, 1.01, 0.81, 0.81, 0.84, 0.89, 0.93, 0.95, 0.98, 1.0 , 1.0 , 0.99, 0.96, 0.91, 0.89, 0.85, 0.83, 0.77, 1.01, 1.06, 1.02, 1.07}; + // double Et_G60_LEQ80 [] = {1.01, 0.97, 0.99, 0.96, 0.74, 0.79, 0.79, 0.83, 0.88, 0.91, 0.95, 0.97, 0.95, 0.91, 0.89, 0.87, 0.84, 0.82, 0.77, 0.74, 0.95, 0.99, 0.97, 1.03}; + // double Et_G80 [] = {0.93, 0.86, 0.91, 0.86, 0.67, 0.69, 0.73, 0.78, 0.79, 0.83, 0.85, 0.87, 0.87, 0.85, 0.84, 0.81, 0.77, 0.74, 0.72, 0.67, 0.87, 0.89, 0.86, 0.93}; + + // Determine the calibration correction factor + if ( Et <= 20.0){ corrFactor = Et_LEQ20[arrayIndex]; } + else if ( ( 20.0 < Et ) && ( Et <= 40.0) ){ corrFactor = Et_G20_LEQ40[arrayIndex]; } + else if ( ( 40.0 < Et ) && ( Et <= 60.0) ){ corrFactor = Et_G40_LEQ60[arrayIndex]; } + else if ( ( 60.0 < Et ) && ( Et <= 80.0) ){ corrFactor = Et_G60_LEQ80[arrayIndex]; } + else if ( 80.0 < Et ) corrFactor = Et_G80[arrayIndex]; + else { throw cms::Exception("Logic") << "Could not find correction factor for L1 CaloTau with Et = " << Et << " and Eta = " << Eta << std::endl;} + + // std::cout << "*** Et = " << Et << ", Eta = " << Eta << ", ArrayIndex = " << arrayIndex << ", CorrFactor = " << corrFactor << std::endl; + return corrFactor; + + } + + +int L1CaloTauCorrectionsProducer::FindNearestIndex(const unsigned int arraySize, double myArray[], double myEtaValue){ + + + // Variable declaration/initialisation + int index = -1; + int counter = 0; + std::vector v_eta; + v_eta.reserve(arraySize); + + // Convert array to vector to simplify things + for(unsigned int i = 0; i< arraySize; i++){ v_eta.push_back( myArray[i]); } + + // Loop over all eta values and find the array index with a value closest to a chosen Eta value + std::vector::iterator it_eta = v_eta.begin(); + double best_diff = 9999.9; + for( it_eta = v_eta.begin(); it_eta != v_eta.end(); it_eta++){ + + double diff = std::abs( *(it_eta) - myEtaValue ); + if ( diff < best_diff ){ + index = counter; + best_diff = diff; + } + counter++; + + } + + return index; + +} + + + +// ------------ method called once each job just before starting event loop ------------ +void +L1CaloTauCorrectionsProducer::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1CaloTauCorrectionsProducer::endJob() { +} + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1CaloTauCorrectionsProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { +//The following says we do not know what parameters are allowed so do no validation +// Please change this to state exactly what you do use, even if it is no parameters +edm::ParameterSetDescription desc; +desc.setUnknown(); +descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1CaloTauCorrectionsProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCalo.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloDummy.cc similarity index 88% rename from SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCalo.cc rename to SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloDummy.cc index f1d8f4de5c17d..33a8be6f3ce12 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCalo.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloDummy.cc @@ -46,14 +46,14 @@ using namespace l1extra ; // class declaration // -class L1TkTauFromCaloProducer : public edm::EDProducer { +class DummyL1TkTauFromCaloProducer : public edm::EDProducer { public: typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - explicit L1TkTauFromCaloProducer(const edm::ParameterSet&); - ~L1TkTauFromCaloProducer(); + explicit DummyL1TkTauFromCaloProducer(const edm::ParameterSet&); + ~DummyL1TkTauFromCaloProducer(); static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); @@ -90,7 +90,7 @@ class L1TkTauFromCaloProducer : public edm::EDProducer { // // constructors and destructor // -L1TkTauFromCaloProducer::L1TkTauFromCaloProducer(const edm::ParameterSet& iConfig) +DummyL1TkTauFromCaloProducer::DummyL1TkTauFromCaloProducer(const edm::ParameterSet& iConfig) { L1TausInputTag = iConfig.getParameter("L1TausInputTag"); @@ -105,12 +105,12 @@ L1TkTauFromCaloProducer::L1TkTauFromCaloProducer(const edm::ParameterSet& iConfi produces(); } -L1TkTauFromCaloProducer::~L1TkTauFromCaloProducer() { +DummyL1TkTauFromCaloProducer::~DummyL1TkTauFromCaloProducer() { } // ------------ method called to produce the data ------------ void -L1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +DummyL1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { using namespace edm; using namespace std; @@ -223,19 +223,19 @@ L1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSet // ------------ method called once each job just before starting event loop ------------ void -L1TkTauFromCaloProducer::beginJob() +DummyL1TkTauFromCaloProducer::beginJob() { } // ------------ method called once each job just after ending the event loop ------------ void -L1TkTauFromCaloProducer::endJob() { +DummyL1TkTauFromCaloProducer::endJob() { } // ------------ method called when starting to processes a run ------------ /* void -L1TkTauFromCaloProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) +DummyL1TkTauFromCaloProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) { } */ @@ -243,7 +243,7 @@ L1TkTauFromCaloProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) // ------------ method called when ending the processing of a run ------------ /* void -L1TkTauFromCaloProducer::endRun(edm::Run&, edm::EventSetup const&) +DummyL1TkTauFromCaloProducer::endRun(edm::Run&, edm::EventSetup const&) { } */ @@ -251,7 +251,7 @@ L1TkTauFromCaloProducer::endRun(edm::Run&, edm::EventSetup const&) // ------------ method called when starting to processes a luminosity block ------------ /* void -L1TkTauFromCaloProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +DummyL1TkTauFromCaloProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) { } */ @@ -259,14 +259,14 @@ L1TkTauFromCaloProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventS // ------------ method called when ending the processing of a luminosity block ------------ /* void -L1TkTauFromCaloProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +DummyL1TkTauFromCaloProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) { } */ // ------------ method fills 'descriptions' with the allowed parameters for the module ------------ void -L1TkTauFromCaloProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { +DummyL1TkTauFromCaloProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { //The following says we do not know what parameters are allowed so do no validation // Please change this to state exactly what you do use, even if it is no parameters edm::ParameterSetDescription desc; @@ -275,7 +275,7 @@ L1TkTauFromCaloProducer::fillDescriptions(edm::ConfigurationDescriptions& descri } //define this as a plug-in -DEFINE_FWK_MODULE(L1TkTauFromCaloProducer); +DEFINE_FWK_MODULE(DummyL1TkTauFromCaloProducer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc new file mode 100644 index 0000000000000..59aaa4bf765db --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc @@ -0,0 +1,500 @@ +// -*- C++ -*- +// +// +// dummy producer for a L1TkTauParticle +// The code simply match the L1CaloTaus with the closest L1Track. +// + +// system include files +#include +#include +#include "TMath.h" +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Utilities/interface/InputTag.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticleFwd.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" // new +#include "DataFormats/Math/interface/LorentzVector.h" +#include "DataFormats/Math/interface/deltaR.h" +#include "DataFormats/Math/interface/deltaPhi.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" // new +// for L1Tracks: +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" //for 'L1TkTrack_PixelDigi_Collection', etc.. +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +using namespace l1extra ; + +// ---------- class declaration ---------- // +class L1TkTauFromCaloProducer : public edm::EDProducer { +public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef edm::Ptr< L1TkTrackType > L1TkTrackRefPtr; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + typedef edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > L1TkStubRef; //new + + explicit L1TkTauFromCaloProducer(const edm::ParameterSet&); + ~L1TkTauFromCaloProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + struct TrackPtComparator{ + bool operator() (const L1TkTrackRefPtr trackA, L1TkTrackRefPtr trackB ) const + { + return ( trackA->getMomentum().perp() > trackB->getMomentum().perp() ); + } + }; + + struct IsBelowTrackPtThreshold{ + float ptMinTrack; + bool operator()(const L1TkTrackRefPtr track) { return track->getMomentum().perp() < ptMinTrack; } + }; + + struct IsAboveChi2RedMaxThreshold{ + float chi2RedMaxNoEndcapStub; + float chi2RedMaxWithEndcapStub; + float chi2RedMax; + bool operator()(const L1TkTrackRefPtr track) { + + /// Get the number of the L1TkTracks_Stubs + std::vector< L1TkStubRef > theStubs = track -> getStubRefs(); + unsigned int nStubs = (int) theStubs.size(); //new + bool bHasEndcap = false; + + /// For-loop: L1TkTracks Stubs + for ( unsigned int jStub = 0; jStub < nStubs; jStub++ ){ + + /// Get the detector id for the stub (barrel / endcap) + StackedTrackerDetId thisDetId( theStubs.at(jStub)->getDetId() ); //new + + if ( thisDetId.isEndcap() ){ + bHasEndcap = true; + break; + } + + } //For-loop: L1TkTracks Stubs + + /// Apply stub quality criteria for the L1TkTracks. + if ( bHasEndcap ){ chi2RedMax = chi2RedMaxWithEndcapStub; } + else{ chi2RedMax = chi2RedMaxNoEndcapStub; } + return track->getChi2Red() > chi2RedMax; + } + }; + + struct IsBelowNStubsMinThreshold{ + unsigned int nStubsMin; + bool operator()(const L1TkTrackRefPtr track) { return track->getStubRefs().size() < nStubsMin; } //new + }; + + struct IsAboveVtxZ0MaxThreshold{ + float vtxZ0Max; + bool operator()(const L1TkTrackRefPtr track) { return fabs(track->getPOCA().z()) > vtxZ0Max; } //new + }; + + struct TrackFoundInTkClusterMap{ + std::map< L1TkTrackRefPtr, unsigned int > m_TrackToCluster; + bool operator()(const L1TkTrackRefPtr track) { return m_TrackToCluster.find( track ) != m_TrackToCluster.end(); } + }; + + +private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + // ---------- member data ---------- // + edm::InputTag L1TausInputTag; + edm::InputTag L1TrackInputTag; + unsigned int L1TkTrack_NStubsMin; // Min number of stubs per Track (unitless) + double L1TkTrack_PtMin_AllTracks; // Min pT of tracks to consider [GeV] + double L1TkTrack_PtMin_SignalTracks; // Min pT applied on signal L1TkTracks [GeV] + double L1TkTrack_PtMin_IsoTracks; // Min pT applied on isolation L1TkTracks [GeV] + double L1TkTrack_RedChiSquareEndcapMax; // Max chi squared for L1TkTracks in Endcap [unitless] + double L1TkTrack_RedChiSquareBarrelMax; // Max chi squared for L1TkTracks in Barrel [unitless] + bool L1TkTrack_ApplyVtxIso; // Produce isolated L1TkTaus (True) or just L1TkTaus (False). + double L1TkTrack_VtxIsoZ0Max; // Max vertex z for L1TkTracks for VtxIsolation [cm] + double L1TkTrack_VtxZ0Max; // Max vertex z for L1TkTracks [cm] + double DeltaR_L1TkTau_L1TkTrack; // Cone size for assigning L1TkTracks to L1TkTau candidate [unitless] + double DeltaR_L1TkTauIsolation; // Isolation cone size for L1TkTau [unitless] + double DeltaR_L1TkTau_L1CaloTau; // Cone size for matching L1TkTau to L1CaloTau [unitless] + double L1CaloTau_EtMin; // Min eT applied on all L1CaloTaus [GeV] + bool RemoveL1TkTauTracksFromIsoCalculation; // Remove tracks used in L1TkTau construction from isolation calculation? + +} ; + + +// ------------ constructor ------------ // +L1TkTauFromCaloProducer::L1TkTauFromCaloProducer(const edm::ParameterSet& iConfig){ + + L1TausInputTag = iConfig.getParameter("L1TausInputTag"); + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + L1TkTrack_NStubsMin = (unsigned int)iConfig.getParameter("L1TkTrack_NStubsMin"); + L1TkTrack_PtMin_AllTracks = iConfig.getParameter("L1TkTrack_PtMin_AllTracks"); + L1TkTrack_PtMin_SignalTracks = iConfig.getParameter("L1TkTrack_PtMin_SignalTracks"); + L1TkTrack_PtMin_IsoTracks = iConfig.getParameter("L1TkTrack_PtMin_IsoTracks"); + L1TkTrack_RedChiSquareEndcapMax = iConfig.getParameter< double >("L1TkTrack_RedChiSquareEndcapMax"); + L1TkTrack_RedChiSquareBarrelMax = iConfig.getParameter< double >("L1TkTrack_RedChiSquareBarrelMax"); + L1TkTrack_ApplyVtxIso = iConfig.getParameter< bool >("L1TkTrack_ApplyVtxIso"); + L1TkTrack_VtxIsoZ0Max = iConfig.getParameter< double >("L1TkTrack_VtxIsoZ0Max"); + L1TkTrack_VtxZ0Max = iConfig.getParameter< double >("L1TkTrack_VtxZ0Max"); + DeltaR_L1TkTau_L1TkTrack = iConfig.getParameter< double >("DeltaR_L1TkTau_L1TkTrack"); + DeltaR_L1TkTauIsolation = iConfig.getParameter< double >("DeltaR_L1TkTauIsolation"); + DeltaR_L1TkTau_L1CaloTau = iConfig.getParameter< double >("DeltaR_L1TkTau_L1CaloTau"); + L1CaloTau_EtMin = iConfig.getParameter< double >("L1CaloTau_EtMin"); + RemoveL1TkTauTracksFromIsoCalculation = iConfig.getParameter< bool >("RemoveL1TkTauTracksFromIsoCalculation"); + produces(); +} + + +// ------------ destructor ------------ // +L1TkTauFromCaloProducer::~L1TkTauFromCaloProducer(){} + +// ------------ method called to produce the data ------------ // +void L1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup){ + + using namespace edm; + using namespace std; + std::auto_ptr result(new L1TkTauParticleCollection); + + /// Collection Handles: The L1TkTracks the PixelDigi collection + typedef std::vector< L1TkTrackType > L1TkTrack_PixelDigi_MyCollection; + edm::Handle< L1TkTrack_PixelDigi_MyCollection > h_PixelDigi_L1TkTrack; //new + iEvent.getByLabel( L1TrackInputTag, h_PixelDigi_L1TkTrack ); + L1TkTrack_PixelDigi_MyCollection::const_iterator L1TkTrack; + + /// Collection Handles: The L1CaloTau from the L1 ExtraParticles + edm::Handle< std::vector< l1extra::L1JetParticle > > h_L1CaloTau; + iEvent.getByLabel( L1TausInputTag, h_L1CaloTau ); + + /// Define maps and their iterators + std::map< L1TkTrackRefPtr, unsigned int > m_L1TkTrackToL1TkCluster; // L1TkTrackRefPtr --> Cluster index it belongs to + std::map< L1TkTrackRefPtr, unsigned int >::const_iterator it_L1TkTrackToL1TkCluster; + + std::map< unsigned int, std::vector< L1TkTrackRefPtr > > m_L1TkClusterToL1TkTracks; // Reverse of m_L1TkTrackToL1TkCluster + std::map< unsigned int, std::vector< L1TkTrackRefPtr > >::const_iterator it_L1TkClusterToL1TkTracks; + + + /// L1TkTracks: Quality Criteria + //////////////////////////////// + std::vector< L1TkTrackRefPtr > v_L1TkTracks_wQuality; + unsigned int iL1TkTrack = 0; + + /// For-loop: L1TkTracks + for ( L1TkTrack = h_PixelDigi_L1TkTrack->begin(); L1TkTrack != h_PixelDigi_L1TkTrack->end(); L1TkTrack++ ){ + + /// Make a pointer to the L1TkTracks + L1TkTrackRefPtr L1TkTrack_Ptr( h_PixelDigi_L1TkTrack, iL1TkTrack++); + + /// Get the number of stubs of the L1TkTracks + std::vector< L1TkStubRef > L1TkTrackStubs = L1TkTrack -> getStubRefs() ; + unsigned int L1TkTrack_NStubs = L1TkTrackStubs.size(); + double L1TkTrack_Pt = L1TkTrack->getMomentum().perp(); + double L1TkTrack_VtxZ0 = L1TkTrack->getPOCA().z(); + bool L1TkTrack_HasEndcap = false; + bool L1TkTrack_HasBarrel = false; + + /// Apply user-defined L1TkTracks quality criteria + if ( L1TkTrack_NStubs < L1TkTrack_NStubsMin ){ continue; } + if ( L1TkTrack_Pt < L1TkTrack_PtMin_AllTracks ){ continue; } + if ( fabs( L1TkTrack_VtxZ0 ) > L1TkTrack_VtxZ0Max ){ continue; } + + /// Nested for-loop: L1TkTrack Stubs + for ( unsigned int iStub = 0; iStub < L1TkTrack_NStubs; iStub++ ){ + + /// Get the detector id for the stub (barrel / endcap) + StackedTrackerDetId thisDetId( L1TkTrackStubs.at(iStub)->getDetId() ); + if ( thisDetId.isEndcap() ){ L1TkTrack_HasEndcap = true; } + if ( thisDetId.isBarrel() ){ L1TkTrack_HasBarrel = true; } + + } // nested for-loop: L1TkTrack Stubs + + /// Apply user-defined L1TkTracks stub quality criteria + if ( ( L1TkTrack_HasEndcap ) && ( L1TkTrack->getChi2Red() > L1TkTrack_RedChiSquareEndcapMax ) ){ continue; } + if ( ( L1TkTrack_HasBarrel ) && ( L1TkTrack->getChi2Red() > L1TkTrack_RedChiSquareBarrelMax ) ){ continue; } + + v_L1TkTracks_wQuality.push_back( L1TkTrack_Ptr ); + + } // For-loop: L1TkTracks + + + /// Sort the quality L1TkTrack with pT + std::sort( v_L1TkTracks_wQuality.begin(), v_L1TkTracks_wQuality.end(), TrackPtComparator() ); + + + /// L1TkTracks: Isolation Cone + ////////////////////////////// + std::vector< L1TkTrackRefPtr > v_L1TkTracks_IsoCone = v_L1TkTracks_wQuality; + + /// Apply min pt requirement + IsBelowTrackPtThreshold L1TkTracks_PtFilterIso; + L1TkTracks_PtFilterIso.ptMinTrack = L1TkTrack_PtMin_IsoTracks; + v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_PtFilterIso ), v_L1TkTracks_IsoCone.end() ); + + // /// Apply max reduced chi squared requirement + // IsAboveChi2RedMaxThreshold L1TkTracks_Chi2RedFilter; + // L1TkTracks_Chi2RedFilter.chi2RedMaxNoEndcapStub = L1TkTrack_RedChiSquareBarrelMax; + // L1TkTracks_Chi2RedFilter.chi2RedMaxWithEndcapStub = L1TkTrack_RedChiSquareEndcapMax; + // v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_Chi2RedFilter ), v_L1TkTracks_IsoCone.end()); + + // /// Apply min number of stubs requirement + // IsBelowNStubsMinThreshold L1TkTracks_NStubsMinFilter; + // L1TkTracks_NStubsMinFilter.nStubsMin = L1TkTrack_NStubsMin; + // v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_NStubsMinFilter ), v_L1TkTracks_IsoCone.end()); + + // /// Apply max vertex-z requirement + // IsAboveVtxZ0MaxThreshold L1TkTracks_VtxZ0MaxFilter; + // L1TkTracks_VtxZ0MaxFilter.vtxZ0Max = L1TkTrack_VtxZ0Max; + // v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_VtxZ0MaxFilter ), v_L1TkTracks_IsoCone.end()); + + /// L1TkTracks: Signal Cone + /////////////////////////// + std::vector< L1TkTrackRefPtr > v_L1TkTracks_Signal = v_L1TkTracks_wQuality; + + /// Apply min pt requirement + IsBelowTrackPtThreshold L1TkTracks_PtFilterSignal; + L1TkTracks_PtFilterSignal.ptMinTrack = L1TkTrack_PtMin_SignalTracks; + v_L1TkTracks_Signal.erase( remove_if(v_L1TkTracks_Signal.begin(), v_L1TkTracks_Signal.end(), L1TkTracks_PtFilterSignal ), v_L1TkTracks_Signal.end() ); + + + /// L1TkTau: Cluster Construction + ///////////////////////////////// + unsigned int nL1TkTauClusters = 0; + /// For-loop: L1TkTracks + for ( unsigned int iTrack = 0; iTrack < v_L1TkTracks_Signal.size(); iTrack++ ){ + + L1TkTrackRefPtr ldgTk = v_L1TkTracks_Signal.at(iTrack); + + /// Determine if track has already been assigned to a cluster + bool bLdgTkFoundInTkClusterMap = m_L1TkTrackToL1TkCluster.find( ldgTk ) != m_L1TkTrackToL1TkCluster.end(); + if ( bLdgTkFoundInTkClusterMap == true ){ continue; } + + /// Add L1TkTrack to the L1TkTau Cluster + nL1TkTauClusters++; + m_L1TkTrackToL1TkCluster.insert( std::make_pair( ldgTk, nL1TkTauClusters ) ); + + /// Get the L1TkTrack properties + double ldgTk_Eta = ldgTk->getMomentum().eta(); + double ldgTk_Phi = ldgTk->getMomentum().phi(); + + /// Nested for-loop: L1TkTracks + for ( unsigned int jTrack = 0; jTrack < v_L1TkTracks_Signal.size(); jTrack++ ){ + + L1TkTrackRefPtr tkToAdd = v_L1TkTracks_Signal.at(jTrack); + + /// Skip if L1TkTrack is identical to ldgTk or if previously used in another L1TkTau Cluster + if ( ldgTk.get() == tkToAdd.get() ){ continue; } + bool bTKFoundInTkClusterMap = m_L1TkTrackToL1TkCluster.find( tkToAdd ) != m_L1TkTrackToL1TkCluster.end(); + if ( bTKFoundInTkClusterMap == true ){ continue; } + + /// Check if the L1TkTrack is inside L1TkTau signal cone (around ldgTk). If yes add it to the L1TkTau Cluster + double tkToAdd_Eta = tkToAdd->getMomentum().eta(); + double tkToAdd_Phi = tkToAdd->getMomentum().phi(); + double deltaR = reco::deltaR(ldgTk_Eta, ldgTk_Phi, tkToAdd_Eta, tkToAdd_Phi); + if ( deltaR > DeltaR_L1TkTau_L1TkTrack ){ continue; } + m_L1TkTrackToL1TkCluster.insert( std::make_pair( tkToAdd, nL1TkTauClusters ) ); + + } /// Nested for-loop: L1TkTracks + + } /// For-loop: L1TkTracks + + + + /// L1TkTau: Cluster Construction (reverse map) + /////////////////////////////////////////////// + + /// For-loop: m_L1TkTrackToL1TkTracks elements + for ( it_L1TkTrackToL1TkCluster = m_L1TkTrackToL1TkCluster.begin(); it_L1TkTrackToL1TkCluster != m_L1TkTrackToL1TkCluster.end(); it_L1TkTrackToL1TkCluster++ ){ + + /// Check if the cluster is already put in the reverse-map. If not, create the vector and put into the map, if yes, add to the vector. + bool bTkClusterFoundInTkMap = m_L1TkClusterToL1TkTracks.find( it_L1TkTrackToL1TkCluster->second ) != m_L1TkClusterToL1TkTracks.end(); + + if ( !bTkClusterFoundInTkMap ){ + std::vector< L1TkTrackRefPtr > temp; + temp.push_back( it_L1TkTrackToL1TkCluster->first ); + m_L1TkClusterToL1TkTracks.insert( std::make_pair( it_L1TkTrackToL1TkCluster->second, temp ) ); + } + else{ m_L1TkClusterToL1TkTracks.find( it_L1TkTrackToL1TkCluster->second )->second.push_back( it_L1TkTrackToL1TkCluster->first ); } + + } // For-loop: m_L1TkTrackToL1TkTracks elements + + + + /// L1TkTau: Isolation + ////////////////////// + + /// Exclude L1TkTracks that have been used in the construction of the L1TkTaus from isolation calculation? + TrackFoundInTkClusterMap L1TkTracks_TkClusterFilter; + L1TkTracks_TkClusterFilter.m_TrackToCluster = m_L1TkTrackToL1TkCluster; + if( RemoveL1TkTauTracksFromIsoCalculation == true ) { + v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_TkClusterFilter ), v_L1TkTracks_IsoCone.end()); + } + + unsigned int nTksIsoCone_VtxIso = 0; + bool bL1TkTauPassedVtxIso = true; + /// For-loop: m_L1TkClusterToL1TkTracks elements + for ( it_L1TkClusterToL1TkTracks = m_L1TkClusterToL1TkTracks.begin(); it_L1TkClusterToL1TkTracks != m_L1TkClusterToL1TkTracks.end(); it_L1TkClusterToL1TkTracks++ ){ + + nTksIsoCone_VtxIso = 0; + bL1TkTauPassedVtxIso = true; + + /// Get the L1TkTracks that compose the L1TkTau and sort by pT + std::vector< L1TkTrackRefPtr > theseTracks = it_L1TkClusterToL1TkTracks->second; + + /// Get direction of the L1TkTau LdgTk + double L1TkTau_LdgTk_Eta = theseTracks.at(0)->getMomentum().eta(); + double L1TkTau_LdgTk_Phi = theseTracks.at(0)->getMomentum().phi(); + double L1TkTau_LdgTk_VtxZ0 = theseTracks.at(0)->getPOCA().z(); //new + + /// Nested for-loop: L1TkTracks (IsoCone) + for ( unsigned int iTrack = 0; iTrack < v_L1TkTracks_IsoCone.size(); iTrack++ ){ + + L1TkTrackRefPtr isoTk = v_L1TkTracks_IsoCone.at(iTrack); + + /// If this L1TkTrack belongs to the L1TkTau, or if outside the isolation cone skip it + bool bSkipThisTrack = false; + + /// Nested for-loop: L1TkTracks (Cluster) + for ( unsigned int jTrack = 0; jTrack < theseTracks.size(); jTrack++ ){ + + /// Skip identical tracks + L1TkTrackRefPtr L1TkTau_ClusterTk = theseTracks.at(jTrack); + if ( L1TkTau_ClusterTk.get() == isoTk.get() ){ bSkipThisTrack = true; } + + } /// Nested for-loop: L1TkTracks in Cluster + if ( bSkipThisTrack == true ){ continue; } + + /// Is the L1TkTrack within the isolation cone of the L1TkTau? + float isoTk_Eta = isoTk-> getMomentum().eta(); + float isoTk_Phi = isoTk-> getMomentum().phi(); + double deltaR = reco::deltaR(L1TkTau_LdgTk_Eta, L1TkTau_LdgTk_Phi, isoTk_Eta, isoTk_Phi); + if ( deltaR > DeltaR_L1TkTauIsolation ){ continue; } + + /// Calculate number of L1TkTracks inside isolation cone of L1TkTau, that are within a distance "L1TkTrack_VtxZ0Max" in vertex-z position + double isoTk_VtxZ0 = isoTk->getPOCA().z(); //new + double deltaVtxIso_Z0 = fabs ( L1TkTau_LdgTk_VtxZ0 - isoTk_VtxZ0 ); + if ( deltaVtxIso_Z0 <= L1TkTrack_VtxIsoZ0Max ){ nTksIsoCone_VtxIso++; } + + } /// Nested for-loop: L1TkTracks (Signal) + + if ( nTksIsoCone_VtxIso > 0 && L1TkTrack_ApplyVtxIso == true){ bL1TkTauPassedVtxIso = false; } + + + /// L1CaloTau: Matching with L1TkTau + //////////////////////////////////// + unsigned int iL1CaloTauIndex = -1; + unsigned int iMatchedL1CaloTau = 0; + double minDeltaR = 99999; + bool bFoundL1TkTauCaloMatch = false; + std::vector< L1TkTrackRefPtr > L1TkTau_TkPtrs; + + /// Nested for-loop: L1CaloTaus + for ( std::vector< l1extra::L1JetParticle >::const_iterator L1CaloTau = h_L1CaloTau->begin(); L1CaloTau != h_L1CaloTau->end(); L1CaloTau++){ + + iL1CaloTauIndex++; //starts at 0 + + /// Match L1CaloTau with L1TkTau + double L1CaloTau_Et = L1CaloTau->et(); + double L1CaloTau_Eta = L1CaloTau->eta(); + double L1CaloTau_Phi = L1CaloTau->phi(); + if ( L1CaloTau_Et < L1CaloTau_EtMin){ continue; } + + /// Calculate distance of L1CaloTau from the L1TkTau Leading Track + double deltaR = reco::deltaR(L1TkTau_LdgTk_Eta, L1TkTau_LdgTk_Phi, L1CaloTau_Eta, L1CaloTau_Phi); + if ( deltaR < minDeltaR ){ + minDeltaR = deltaR; + iMatchedL1CaloTau = iL1CaloTauIndex; + } + + } /// Nested for-Loop: L1CaloTaus + + /// Ensuse that the L1CaloTau closest to the L1TkTau is at least within a certain matching cone size. Create a L1CaloTau Ref Pointer + if ( minDeltaR < DeltaR_L1TkTau_L1CaloTau ){ + bFoundL1TkTauCaloMatch = true; + L1TkTau_TkPtrs = it_L1TkClusterToL1TkTracks->second; + } + + /// Construct 4-Momentum of L1TkTau Candidate + math::XYZTLorentzVector L1TkTau_P4(0, 0, 0, 0); + float mPionPlus = 0.140; // GeV + + /// Nested for-loop: L1TkTracks of L1TkTau //fixme: use calo Et + for ( unsigned int iTk = 0; iTk < L1TkTau_TkPtrs.size(); iTk++ ){ + + L1TkTrackRefPtr tk = L1TkTau_TkPtrs.at(iTk); + + float L1TkTauTk_Px = tk-> getMomentum().x(); + float L1TkTauTk_Py = tk-> getMomentum().y(); + float L1TkTauTk_Pz = tk-> getMomentum().z(); + float L1TkTauTk_E = sqrt( L1TkTauTk_Px*L1TkTauTk_Px + L1TkTauTk_Py*L1TkTauTk_Py + L1TkTauTk_Pz*L1TkTauTk_Pz + mPionPlus * mPionPlus ); + math::XYZTLorentzVector tmp_P4(L1TkTauTk_Px, L1TkTauTk_Py, L1TkTauTk_Pz, L1TkTauTk_E); + L1TkTau_P4 += tmp_P4; + + } /// Nested for-loop: L1TkTracks of L1TkTau + + /// Apply Vtx-Based isolation on L1TkTaus. Also ensure a L1CaloTau has been matched to a L1TkTau + bool bFillEvent = bL1TkTauPassedVtxIso * bFoundL1TkTauCaloMatch; + if( bFillEvent == false ) { continue; } + + /// Save the L1TkTau candidate, its tracks, isolation variable (dumbie) and its L1CaloTau reference. + float L1TkTau_TkIsol = -999.9; + edm::Ref< L1JetParticleCollection > L1TauCaloRef( h_L1CaloTau, iMatchedL1CaloTau ); + + /// Since the L1TkTauParticle does not support a vector of Track Ptrs yet, use instead a "hack" to simplify the code. + edm::Ptr< L1TkTrackType > L1TrackPtrNull; + if (L1TkTau_TkPtrs.size() == 1) { + L1TkTau_TkPtrs.push_back(L1TrackPtrNull); + L1TkTau_TkPtrs.push_back(L1TrackPtrNull); + } + else if (L1TkTau_TkPtrs.size() == 2) { + L1TkTau_TkPtrs.push_back(L1TrackPtrNull); + } + else{} + + /// Fill The L1TkTauParticle object: + // L1TkTauParticle L1TkTauFromCalo( L1TkTau_P4, L1TauCaloRef, L1TkTau_TkPtrs, L1TkTau_TkIsol ); + L1TkTauParticle L1TkTauFromCalo( L1TkTau_P4, + L1TauCaloRef, + L1TkTau_TkPtrs[0], + L1TkTau_TkPtrs[1], + L1TkTau_TkPtrs[2], + L1TkTau_TkIsol ); + + result -> push_back( L1TkTauFromCalo ); + + } /// For-loop: m_L1TkClusterToL1TkTracks elements + + iEvent.put( result ); + +} + + +// ------------ method called once each job just before starting event loop ------------ // +void L1TkTauFromCaloProducer::beginJob(){} + +// ------------ method called once each job just after ending the event loop ------------ // +void L1TkTauFromCaloProducer::endJob() {} + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ // +void L1TkTauFromCaloProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TkTauFromCaloProducer); + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/tools/datasetsHelper.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/tools/datasetsHelper.py new file mode 100644 index 0000000000000..642afe946e471 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/tools/datasetsHelper.py @@ -0,0 +1,929 @@ +#!/usr/bin/env python +############################################################### +### All imported modules +############################################################### +### System modules +import os +### CMS-specific modules +import FWCore.ParameterSet.Config as cms + +############################################################### +### Function definition +############################################################### +def GetEosRootFilesForDataset(dataset): + + allDatasets = ["Neutrino_Pt2to20_gun", "PYTHIA6_Tauola_TTbar_ChargedHiggs160_taunu_14TeV", "PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV", "PYTHIA_Tauola_TB_ChargedHiggs200_14TeV", "SinglePionMinusFlatPt0p2To50", "SinglePionPlusFlatPt0p2To50", "SingleTauOneProngFlatPt10To100" "TauThreeProngsEnriched", "VBF_HToTauTau_125_14TeV_powheg_pythia6"] + filePath = "/store/mc/TTI2023Upg14D/" + dataset + "/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000/" + + if dataset not in allDatasets: + raise Exception("Unknown dataset '%s'. Please select a valid dataset from this list:\n\t%s" % (dataset, "\n\t".join(allDatasets)) ) + + if dataset == "Neutrino_Pt2to20_gun": + myVstring1 = cms.untracked.vstring( + filePath + "022FFF01-E4E0-E311-9DAD-002618943919.root", + filePath + "0257B6AB-00E6-E311-A12F-0025905A6068.root", + filePath + "028A8772-F9E0-E311-8A79-00261894393E.root", + filePath + "02D2A39E-F0E5-E311-9640-0025905A60CE.root", + filePath + "04495E11-F0E5-E311-AB97-0025905964C0.root", + filePath + "04555820-0CE2-E311-9784-0025905964B6.root", + filePath + "0613FF12-D7E0-E311-B989-003048FFD76E.root", + filePath + "06264B00-30E6-E311-B0C4-002618943849.root", + filePath + "068B668B-6AE1-E311-A2C3-003048FFD736.root", + filePath + "08A2DCFD-EBE5-E311-9BA6-0025905822B6.root", + filePath + "0A17EF9E-D5E0-E311-96AD-0025905A497A.root", + filePath + "0AD86451-E7E5-E311-9A19-0025905A605E.root", + filePath + "0C13EA2F-32E6-E311-91D5-0025905A60EE.root", + filePath + "0C2F1704-06E1-E311-AF0A-0025905A6136.root", + filePath + "0CD75128-E6E5-E311-A9E9-0025905A6092.root", + filePath + "0E6649F9-A9E1-E311-9933-0025905A612A.root", + filePath + "0E9FDE1A-F2E0-E311-ADB1-0025905A605E.root", + filePath + "0EA3A291-EAE0-E311-BB8C-0025905A60F8.root", + filePath + "12C5C30E-35E6-E311-A633-0025905A6070.root", + filePath + "1441062D-06E6-E311-832E-002618943924.root", + filePath + "1462B0B5-07E6-E311-9D89-0025905A610A.root", + filePath + "18465143-37E6-E311-B51D-0025905A4964.root", + filePath + "188A9D4C-39E6-E311-8EDE-002590593876.root", + filePath + "18E96B31-E1E0-E311-B251-0025905A6132.root", + filePath + "1A201BB4-CBE0-E311-B50B-00261894386A.root", + filePath + "1A267CCD-FAE0-E311-AD65-0025905A60F8.root", + filePath + "1AA7D1DD-F5E5-E311-B608-0025905A6068.root", + filePath + "1ABD77E1-3AE1-E311-89D5-0026189438B5.root", + filePath + "1C3DF109-62E1-E311-A2BB-0026189438E4.root", + filePath + "1E0235D3-06E1-E311-AEC8-002618FDA207.root", + filePath + "1E24EA2E-CAE0-E311-9C66-002618943856.root", + filePath + "1EAF6236-F1E5-E311-A488-0025905A60DA.root", + filePath + "1EFDD4F7-5FE1-E311-9562-0025905A6064.root", + filePath + "1EFED4FD-CCE0-E311-B63B-0025905A608C.root", + filePath + "1EFFF999-2DE6-E311-9986-002618943964.root", + filePath + "20085CF9-F2E5-E311-BDA8-0025905A4964.root", + filePath + "201BE8AF-D4E0-E311-B6B2-003048FFD76E.root", + filePath + "20B1A87A-EFE5-E311-BA6F-002590596498.root", + filePath + "20D62E56-F0E5-E311-A1F6-003048FFCC1E.root", + filePath + "26C45514-E5E0-E311-AC39-003048678DD6.root", + filePath + "26C54ABF-EEE0-E311-9C0E-00261894393B.root", + filePath + "26FE17E5-CCE0-E311-AB4B-0025905A48B2.root", + filePath + "28014F36-21E1-E311-9D82-003048678BB2.root", + filePath + "28F8BAE7-01E2-E311-9621-00304867926C.root", + filePath + "2A2E9C1D-4FE1-E311-8AF1-0026189438A2.root", + filePath + "2A3BDACE-DAE0-E311-B5C7-0025905A60DA.root", + filePath + "2A49AD92-C1E1-E311-8D5D-0025905A6118.root", + filePath + "2A7371A4-FEE5-E311-9354-003048679182.root", + filePath + "2A8B8AE7-F3E5-E311-BEFE-0025905A612A.root", + filePath + "2AAF9114-CEE0-E311-9F82-00261894386A.root", + filePath + "2AC6D4FF-0EE2-E311-92B9-003048678B3C.root", + filePath + "2AFBEA3E-16E2-E311-9C7F-002590596498.root", + filePath + "2CF2F4A7-FBE5-E311-BFDA-0025905A60E0.root", + filePath + "2EDBEFAB-EEE0-E311-A9C5-00261894390A.root", + filePath + "300EE73D-F4E0-E311-B31A-0025905A60B6.root", + filePath + "30406994-EEE5-E311-BE81-002590593878.root", + filePath + "30425B37-16E6-E311-B6AE-002618943974.root", + filePath + "308F84C1-F2E5-E311-8813-0025905A48C0.root", + filePath + "32F48A12-16E1-E311-BDDD-00304867916E.root", + filePath + "346DB972-D5E0-E311-9C15-00259059642A.root", + filePath + "34873A94-F5E5-E311-86A7-003048FFD770.root", + filePath + "3640FE47-F5E5-E311-AEC4-003048FFD7BE.root", + filePath + "380F8F82-D0E1-E311-A059-0025905A48E4.root", + filePath + "382BCF6B-2CE6-E311-BCA8-002618943845.root", + filePath + "3866BA80-F1E5-E311-A836-002590596498.root", + filePath + "38F09D42-0CE7-E311-A7FF-0025905964C4.root", + filePath + "3AA400E9-DFE0-E311-9EF4-0025905A60BC.root", + filePath + "3CAB0434-E2E0-E311-842E-0025905A48BC.root", + filePath + "3CABB763-F0E0-E311-AA2D-003048FFD752.root", + filePath + "3CCF429B-F0E5-E311-A996-002618943811.root", + filePath + "3E20FEDB-E2E0-E311-ABC8-0025905A60F8.root", + filePath + "3EA7CC84-34E1-E311-9750-0025905A6088.root", + filePath + "3EB77375-F1E5-E311-BDEC-003048FFD740.root", + filePath + "406F7969-1AE1-E311-B55F-003048FF9AA6.root", + filePath + "423CD269-F2E5-E311-AA0D-0025905A611C.root", + filePath + "424E3351-F2E0-E311-B37C-003048678B0A.root", + filePath + "42A3BC12-2FE6-E311-82C4-00261894391C.root", + filePath + "44090790-09E1-E311-B4ED-0025905A60D6.root", + filePath + "44244A17-F2E5-E311-8835-0025905A60CE.root", + filePath + "443AD822-EDE5-E311-9A78-002618943914.root", + filePath + "4441BC34-D2E0-E311-A978-0025905A608A.root", + filePath + "4470FDF2-C0E1-E311-93A4-0025905A6090.root", + filePath + "44E51577-32E6-E311-BC7D-0025905A60D2.root", + filePath + "44E6A539-D0E0-E311-902B-0025905A60BC.root", + filePath + "44FBB649-35E6-E311-AF56-003048FF9AC6.root", + filePath + "464992B9-2BE6-E311-8B29-003048678C06.root", + filePath + "46662FEA-FFE0-E311-B51A-0025905A48D0.root", + filePath + "48287FEF-36E6-E311-AAF9-0025905AA9CC.root", + filePath + "484A95A5-34E6-E311-9B8B-003048FF9AC6.root", + filePath + "485C5EA5-F0E5-E311-B374-0025905A6118.root", + filePath + "48831148-05E6-E311-BA3E-0025905A6070.root", + filePath + "48C92B57-3BE6-E311-A687-0025905A6084.root", + filePath + "48E2FBF1-D5E0-E311-854F-003048FFD75C.root", + filePath + "48E8431E-6FE1-E311-B29A-003048678BAC.root", + filePath + "4A1A2FB5-E6E0-E311-93E3-0025905A48F0.root", + filePath + "4A56125C-D0E0-E311-B1A6-0025905A60FE.root", + filePath + "4A659B68-EFE0-E311-BF56-003048678F8C.root", + filePath + "4CA51C93-CAE0-E311-BE3D-002618943856.root", + filePath + "4CD0C90F-02E1-E311-87F3-003048679180.root", + filePath + "4E7CE27B-E8E5-E311-8736-0025905A608A.root", + filePath + "4E90547B-D1E0-E311-B446-0025905A60D2.root", + filePath + "4EE8B5D1-19E3-E311-8151-0025905964A6.root", + filePath + "501E6F7A-36E6-E311-BCE5-0025905A6104.root", + filePath + "52155D19-E3E0-E311-9557-0025905A6104.root", + filePath + "5215EA39-DBE0-E311-BFEA-0026189438EB.root", + filePath + "52EEDB2C-D2E0-E311-A68C-0025905A6088.root", + filePath + "549904B6-36E6-E311-BC83-0025905A48BA.root", + filePath + "54E897E8-DBE0-E311-8D69-0026189438EB.root", + filePath + "54F9E518-CFE0-E311-8371-00261894386A.root", + filePath + "5653868D-EAE5-E311-A0CC-0026189437ED.root", + filePath + "56A71528-7BE1-E311-9AD7-00261894386D.root", + filePath + "56D7544D-62E3-E311-AFD0-003048679180.root", + filePath + "56F1F1E4-F2E0-E311-A377-002618943963.root", + filePath + "56F4CBCB-FCE5-E311-8D63-0025905A48F2.root", + filePath + "580315E6-E7E5-E311-A960-0025905A6104.root", + filePath + "58182547-02E1-E311-A28E-002618943916.root", + filePath + "58A5B057-01E1-E311-9188-0025905A60BE.root", + filePath + "58E24269-D5E0-E311-823C-0030486792AC.root", + filePath + "58FC6DC3-F9E0-E311-98A5-0025905A497A.root", + filePath + "5A530249-F5E5-E311-A2E4-003048FFD736.root", + filePath + "5A591C73-E7E0-E311-ABB3-0025905A4964.root", + filePath + "5ABED4C0-CCE0-E311-B347-0025905A60BC.root", + filePath + "5AF24FE7-D3E0-E311-B385-0025905A6118.root", + filePath + "5C741C1C-F9E5-E311-9F42-00304867920C.root", + filePath + "5C8C483A-CEE0-E311-937E-003048678ED2.root", + filePath + "5C9B4B92-BDE1-E311-A66D-0030486791DC.root", + filePath + "5CE1FCF1-A2E1-E311-A49E-00304867BF18.root", + filePath + "5CFB96C2-E7E0-E311-B8FA-0025905A6134.root", + filePath + "5EB13592-CBE0-E311-B0D0-003048FFD760.root", + filePath + "5EE42F46-FEE0-E311-A46A-0030486790BE.root", + filePath + "601660DB-D2E0-E311-8FC1-003048679266.root", + filePath + "60CEA5DA-F3E5-E311-9107-003048FFD7BE.root") + + ### too many files (max ~255 arguments supported by python) => Split to two vstrings. + myVstring2 = cms.untracked.vstring( + filePath + "60D5BC5C-D6E0-E311-918F-0025905A60DA.root", + filePath + "60E09492-44E1-E311-9294-003048678B00.root", + filePath + "62712EBF-09E6-E311-8380-002618943923.root", + filePath + "62D94935-FCE0-E311-A955-002590593876.root", + filePath + "62E4A89F-F0E5-E311-91A2-00261894398D.root", + filePath + "64B47781-04E6-E311-BA4F-0025905A612A.root", + filePath + "64FC63B6-E6E5-E311-8375-003048FFCB96.root", + filePath + "6636AF33-F1E5-E311-8B95-0025905A48D0.root", + filePath + "66BB77D9-F3E5-E311-A67C-002618943900.root", + filePath + "66E73FB9-F2E5-E311-BE7D-0025905A60EE.root", + filePath + "6816F64B-FBE5-E311-9AE8-0026189438E4.root", + filePath + "68441A1E-77E1-E311-A0D9-002618943986.root", + filePath + "688BB697-FCE0-E311-AF8A-0025905A6136.root", + filePath + "68FC6ED7-FCE5-E311-B82D-0025905A6064.root", + filePath + "6A0EC09A-0BE1-E311-B8C1-0025905938A8.root", + filePath + "6A96DE6E-CDE0-E311-B919-0026189438BF.root", + filePath + "6AFD26CD-D3E0-E311-B9D9-0025905A60D2.root", + filePath + "6C0132E7-F3E5-E311-9631-0025905A6066.root", + filePath + "6C849AC8-F4E0-E311-BF86-0025905964B6.root", + filePath + "6E5A940D-F2E5-E311-9AD6-0026189438DD.root", + filePath + "7002785B-3EE6-E311-98BD-003048FFCBFC.root", + filePath + "700E95E0-30E6-E311-B374-00248C55CC97.root", + filePath + "7082B7DB-EAE5-E311-872A-0025905964C2.root", + filePath + "70A96AD6-FCE0-E311-863D-003048678C06.root", + filePath + "761A1663-3EE1-E311-A353-003048679236.root", + filePath + "7627FF4C-26E2-E311-99A9-0025905A608A.root", + filePath + "762DC1C0-E1E0-E311-9F96-002590593876.root", + filePath + "76AA3F3F-E5E0-E311-8881-0025905A6134.root", + filePath + "76FA50E5-ECE5-E311-9B2B-002618943810.root", + filePath + "7850B699-BBE1-E311-83B9-0025905964BC.root", + filePath + "788D38D5-DFE0-E311-8D8D-003048FFCB96.root", + filePath + "78BBFE03-E0E0-E311-8279-00248C55CC97.root", + filePath + "7A8BBC37-F4E5-E311-88AE-0025905A60BC.root", + filePath + "7AB3798E-EAE0-E311-9740-003048FFD79C.root", + filePath + "7AFD2384-ECE0-E311-9E2C-002618943800.root", + filePath + "7C0E6225-FAE5-E311-B908-00261894389E.root", + filePath + "7C7070C7-00E1-E311-8DAF-002618943868.root", + filePath + "7C70E52A-00E1-E311-842E-0025905A60AA.root", + filePath + "7C928342-ECE5-E311-A25C-0025905A497A.root", + filePath + "7CC3B6F2-F0E5-E311-9B7B-0025905A608C.root", + filePath + "7E690E21-31E6-E311-BCA0-002618943865.root", + filePath + "7E72C749-F6E0-E311-AA69-0025905A6134.root", + filePath + "8090E81F-60E2-E311-A49F-0025905A48F0.root", + filePath + "80B131DA-C8E1-E311-B2A7-002354EF3BE0.root", + filePath + "8270C2FA-F2E5-E311-B1B2-0025905A6138.root", + filePath + "82C0D6E0-DAE0-E311-93FC-0026189438EB.root", + filePath + "82F9848D-ECE5-E311-AFB8-003048FFCC2C.root", + filePath + "84A8164B-C3E1-E311-ADE8-003048678FEA.root", + filePath + "866096F6-B5E1-E311-B698-0026189438D4.root", + filePath + "869388EC-F0E5-E311-9E2B-0025905A48D8.root", + filePath + "86F3E013-E9E5-E311-889F-00304867D446.root", + filePath + "881E0699-ECE2-E311-8F2F-0026189438F4.root", + filePath + "88275A6F-01E6-E311-82A0-0025905A606A.root", + filePath + "883DEEE1-98E1-E311-AEB1-00261894386D.root", + filePath + "8A296D99-8DE1-E311-B691-003048FFD7D4.root", + filePath + "8A9663F4-2EE6-E311-8130-00261894393D.root", + filePath + "8A968626-DFE0-E311-8C71-003048FFD732.root", + filePath + "8AED7B6D-F6E5-E311-82B8-0025905A612A.root", + filePath + "8C7507AA-F9E5-E311-8B53-002590593902.root", + filePath + "8C9FA527-C7E1-E311-8288-0025905A60E0.root", + filePath + "8E832745-FCE5-E311-B07C-00259059391E.root", + filePath + "8EE4AC62-E9E5-E311-8374-0026189438D8.root", + filePath + "904C03FB-3FE6-E311-9903-0025905938A8.root", + filePath + "92996C48-03E6-E311-AF1D-002618943947.root", + filePath + "94DC28EB-DCE0-E311-BF47-002590596498.root", + filePath + "98A6AAE3-EEE5-E311-A0FE-0025905964C4.root", + filePath + "98B8F60E-3DE6-E311-A9EB-0025905964B6.root", + filePath + "98E93FA2-DFE0-E311-982F-0025905A60B0.root", + filePath + "9A27AD8A-CBE1-E311-B5FF-0025905A6110.root", + filePath + "9A99CF21-DDE0-E311-93E1-0026189438AB.root", + filePath + "9AEDECEB-DDE0-E311-9E1F-002618943832.root", + filePath + "9C3800F3-E9E5-E311-8624-003048FFCC1E.root", + filePath + "9C4F4FF4-F0E5-E311-84F6-0025905A48C0.root", + filePath + "9C541DD1-D7E0-E311-B189-003048FFD76E.root", + filePath + "9E0F8CB1-EEE0-E311-AC43-0025905A48D6.root", + filePath + "9E1A6041-F3E5-E311-8806-0025905A60DE.root", + filePath + "9E342814-EEE5-E311-B71E-0025905A610C.root", + filePath + "9E6009CF-EEE0-E311-B063-0025905A60DA.root", + filePath + "A05333A3-7DE1-E311-843A-002354EF3BD2.root", + filePath + "A0814EE5-F2E0-E311-B716-002618943856.root", + filePath + "A0D5658D-F3E5-E311-B4CA-003048FFD720.root", + filePath + "A0E9FF52-FDE5-E311-B141-003048679168.root", + filePath + "A2AC7C54-DDE0-E311-9389-002590593876.root", + filePath + "A40699F9-FBE5-E311-B6ED-0025905A6060.root", + filePath + "A4231997-20E1-E311-85D0-003048679294.root", + filePath + "A44A60FD-ECE0-E311-9645-0025905A6070.root", + filePath + "A4601615-FFE5-E311-BDF9-0026189438C4.root", + filePath + "A4A0C40B-F2E0-E311-B5E9-0025905A606A.root", + filePath + "A4ACCECA-EFE5-E311-958A-0025905A48F2.root", + filePath + "A662FB2D-75E1-E311-B67E-002618943857.root", + filePath + "A66858B2-F2E5-E311-9BBF-0025905A6088.root", + filePath + "A67BC39B-F9E0-E311-AA50-002618943867.root", + filePath + "A680573B-F3E5-E311-B847-003048FFCC0A.root", + filePath + "A6E29705-F0E5-E311-920A-0025905938AA.root", + filePath + "A83B1B7A-EDE5-E311-BF82-003048FFD7BE.root", + filePath + "A862A18A-F8E0-E311-A3A6-0025905A60E0.root", + filePath + "A87C7504-F5E5-E311-B99A-0025905A60D2.root", + filePath + "A88A7DB0-FFE1-E311-B72C-00248C65A3EC.root", + filePath + "AA1F53B4-F4E5-E311-9D1C-0025905822B6.root", + filePath + "AC183697-38E6-E311-ACA4-0025905964A6.root", + filePath + "AC45CB2E-34E6-E311-864C-0025905AA9CC.root", + filePath + "AC7B4615-F2E5-E311-A2EE-0025905A60A6.root", + filePath + "ACAEB800-F3E5-E311-9C9F-0025905A48D6.root", + filePath + "ACF68BAC-35E6-E311-8631-0025905A60A6.root", + filePath + "AE427DAC-FBE0-E311-98E7-00261894393E.root", + filePath + "AE4351F0-B4E1-E311-B993-0025905A608A.root", + filePath + "AE43B4AD-93E2-E311-A25D-0025905A60A6.root", + filePath + "AE497FCB-F1E5-E311-953C-0025905A60E4.root", + filePath + "AE77733B-36E2-E311-95DC-00261894395C.root", + filePath + "AEEA184B-DDE0-E311-82A5-002618943896.root", + filePath + "B2B11122-24E1-E311-88F8-002590596490.root", + filePath + "B2F42171-DCE0-E311-BA99-00304867918A.root", + filePath + "B47EED40-3CE6-E311-B2CE-0025905A6084.root", + filePath + "B4DA0E99-F3E5-E311-A2CA-0025905A60DA.root", + filePath + "B8B5D541-DCE0-E311-A640-0026189438EB.root", + filePath + "B8D72D6D-04E1-E311-B090-0025905A60BE.root", + filePath + "BA451CD4-6FE2-E311-92D3-00261894393E.root", + filePath + "BAB2C8C6-F1E5-E311-91B3-00248C65A3EC.root", + filePath + "BAB90734-DAE0-E311-8E69-0025905964C2.root", + filePath + "BAE802E1-D8E2-E311-B035-002354EF3BDF.root", + filePath + "BCA2645F-07E6-E311-86B8-0025905A60DA.root", + filePath + "BCBC2826-20E2-E311-816E-002618943971.root", + filePath + "BCC72015-02E6-E311-8512-002618943923.root", + filePath + "BE402D5C-06E6-E311-B73C-0025905A612A.root", + filePath + "BEEDB2CF-ECE0-E311-BF8E-001A92971BB4.root", + filePath + "C05AAC63-EBE5-E311-A701-00304867918A.root", + filePath + "C248CBEB-67E1-E311-97D7-002618943810.root", + filePath + "C28C0C29-B9E1-E311-8CD5-0030486792A8.root", + filePath + "C2CE094D-F7E5-E311-9D37-00259059642E.root", + filePath + "C4362A84-F9E0-E311-A33A-0025905A60CE.root", + filePath + "C4844511-E0E0-E311-85C1-003048D3C010.root", + filePath + "C495B0E5-02E6-E311-AE1D-002618943947.root", + filePath + "C4984EE7-F1E0-E311-AD82-0025905A48D6.root", + filePath + "C4C6525F-F7E0-E311-BBE1-002618943868.root", + filePath + "C610B6D9-FAE5-E311-A786-0025905A60B2.root", + filePath + "C62DE814-FDE5-E311-B865-0025905A606A.root", + filePath + "C62F64B3-F4E5-E311-B8EC-0025905A60B2.root", + filePath + "C6400E24-13E2-E311-AA78-00261894386C.root", + filePath + "C814094E-2DE6-E311-92BE-002618FDA21D.root", + filePath + "C82BFE34-D6E0-E311-AAD7-002618943977.root", + filePath + "C8336379-10E6-E311-B040-003048678B18.root", + filePath + "C8546CD6-BFE1-E311-A75F-00304867908C.root", + filePath + "C8C4B5C8-F1E5-E311-8FD5-0026189438CB.root", + filePath + "C8F3905F-00E6-E311-9A2C-0025905A60B0.root", + filePath + "CA0685CE-F6E5-E311-848B-00261894385D.root", + filePath + "CA685369-F4E5-E311-80BB-003048FFD7BE.root", + filePath + "CC6161B6-6BE1-E311-91B9-002618943829.root", + filePath + "CE97874B-96E1-E311-A152-00304867BFBC.root", + filePath + "D2FC6069-36E6-E311-A32B-0026189438AC.root", + filePath + "D6A8D9C3-EFE5-E311-B5D7-0026189438C1.root", + filePath + "D6E5B23C-D6E3-E311-AC77-00261894393E.root", + filePath + "D813D9CD-F1E5-E311-A1C8-002354EF3BE6.root", + filePath + "D824C41D-FBE0-E311-8BCC-00261894387C.root", + filePath + "D860F0F7-F8E1-E311-A733-0025905A48BA.root", + filePath + "D882A981-D6E0-E311-8DFF-0025905A6132.root", + filePath + "DAD1E8FA-71E1-E311-933F-00248C55CC9D.root", + filePath + "DC156B03-F2E0-E311-BC2F-00304867BEDE.root", + filePath + "DC157DCD-6FE1-E311-A1A7-00261894395B.root", + filePath + "DE10A43D-98E3-E311-A3BD-0025905A609E.root", + filePath + "DE2492E7-EEE5-E311-BD3F-003048FFCB6A.root", + filePath + "DE5C4781-E0E0-E311-9678-00248C55CC40.root", + filePath + "DE717A04-CAE0-E311-9825-0025905964B2.root", + filePath + "DE8F10FF-D2E2-E311-A0A5-002618943913.root", + filePath + "DE8F3908-CBE0-E311-A3E2-0025905A6118.root", + filePath + "E0440EB3-EDE1-E311-A67B-0030486791DC.root", + filePath + "E07C8817-ECE0-E311-AD86-002618943800.root", + filePath + "E202EF8F-F3E5-E311-AA7F-0025905A48FC.root", + filePath + "E216449B-F7E0-E311-8AEB-0025905A6136.root", + filePath + "E2D9E22F-38E6-E311-B3B5-0025905A6118.root", + filePath + "E4A35ED8-F7E5-E311-AF34-002590596468.root", + filePath + "E4B1BB91-37E6-E311-9E2C-0025905A48BA.root", + filePath + "E4EA45D7-FCE0-E311-81F4-0025905A60CE.root", + filePath + "E61D2AE5-F3E5-E311-B07D-0025905A6134.root", + filePath + "E669CD06-E8E0-E311-8306-003048FFD79C.root", + filePath + "E68A0E93-EAE5-E311-A0C8-0026189438B5.root", + filePath + "E69B4070-D8E1-E311-BE3D-0025905A48F2.root", + filePath + "E8C7EFBF-F2E5-E311-BCAB-003048FFD7BE.root", + filePath + "EA526512-48E1-E311-B2BF-002618943821.root", + filePath + "EA60D96E-28E6-E311-888F-003048678C06.root", + filePath + "EADFFDD1-0DE6-E311-AC90-0025905964C2.root", + filePath + "EAF33D3F-10E1-E311-8CA3-0025905A6056.root", + filePath + "EAF54BF1-FDE5-E311-B437-0025905A609E.root", + filePath + "EC148BE1-2AE6-E311-A140-0025905A60DA.root", + filePath + "EC1A426B-F8E5-E311-8225-00261894384F.root", + filePath + "EC42EFB6-FFE5-E311-A197-002354EF3BDC.root", + filePath + "EC92099F-02E1-E311-AA49-002618943916.root", + filePath + "EC9F7C35-F1E5-E311-B092-0025905A48BA.root", + filePath + "ECBBE773-EFE5-E311-BF23-002618FDA208.root", + filePath + "EE706125-F4E5-E311-92EF-003048FFCC1E.root", + filePath + "F0C0C633-4CE1-E311-A4D6-003048678A78.root", + filePath + "F228B756-33E6-E311-ACD0-0025905AA9CC.root", + filePath + "F231BE08-D6E0-E311-99BF-0025905A60AA.root", + filePath + "F2427564-F8E0-E311-8457-003048678F62.root", + filePath + "F4102D15-CFE0-E311-99A2-00304867902E.root", + filePath + "F45951E8-FCE0-E311-B012-003048678FD6.root", + filePath + "F4A48065-82E1-E311-AA1A-00261894388D.root", + filePath + "F4AE74F0-58E1-E311-BA5D-003048678FE4.root", + filePath + "F4BDA166-E8E0-E311-9F6B-003048FFCB96.root", + filePath + "F4D584B8-C2E1-E311-A55D-0025905A6060.root", + filePath + "F80A1E55-F0E0-E311-A166-0025905A48D0.root", + filePath + "F8E16277-8EE1-E311-8CD9-0025905A60D6.root", + filePath + "FA28B92C-EFE5-E311-A5F2-0025905A6132.root", + filePath + "FC765079-EDE5-E311-B46B-0026189438DE.root", + filePath + "FCC991FF-B3E1-E311-AED1-0025905A605E.root", + filePath + "FE473BB0-E9E5-E311-8A1D-0025905938A8.root", + filePath + "FECAA992-D9E0-E311-896F-0025905A60BC.root", + filePath + "FEE6BE48-42E6-E311-9312-002618943858.root") + return myVstring1 + myVstring2 + + elif dataset == "PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV": + myVstring = cms.untracked.vstring( + filePath + "00F0F213-B1E5-E311-9C9A-002618943977.root", + filePath + "0425FC8A-C0E5-E311-9731-0025905A60BC.root", + filePath + "08257BA4-B5E5-E311-929F-003048678B44.root", + filePath + "08914F9D-C2E5-E311-A8E4-00261894395B.root", + filePath + "0EA8493A-AAE5-E311-B2E4-0025905A611E.root", + filePath + "1028F7B7-B6E5-E311-B5EC-0026189438FA.root", + filePath + "10B78303-B4E5-E311-A1B3-002590593920.root", + filePath + "124C7445-B8E5-E311-842C-003048FFD752.root", + filePath + "127AC0B6-AEE5-E311-8FFC-0026189438E2.root", + filePath + "1451C784-B0E5-E311-9CDB-003048D15DDA.root", + filePath + "1C11765E-BFE5-E311-8C61-00261894395F.root", + filePath + "1CDCA5E1-B4E5-E311-819C-003048678FF6.root", + filePath + "2004FAE3-B4E5-E311-8FA4-003048678B44.root", + filePath + "202F0848-BDE5-E311-8C45-002618943810.root", + filePath + "20BBE62B-B0E5-E311-A04F-0025905A60D2.root", + filePath + "240DE3F0-B1E5-E311-AAA3-003048FFD76E.root", + filePath + "2653B96A-ABE5-E311-B942-0030486790A6.root", + filePath + "26D2EE0E-33E2-E311-B356-0025905938D4.root", + filePath + "26FA5FAE-C4E5-E311-B436-002618943961.root", + filePath + "28FD1397-AFE5-E311-9750-003048678B84.root", + filePath + "2ACDF84C-BBE5-E311-9CD7-0025905A60F2.root", + filePath + "2CC20AD9-B2E5-E311-B670-0025905938A4.root", + filePath + "2E07A990-BBE5-E311-87FE-002354EF3BDE.root", + filePath + "2E26B44F-B4E5-E311-9AC9-0025905A48F2.root", + filePath + "2EEAB7B6-BCE5-E311-AE4D-0025905A48E4.root", + filePath + "30808E6E-B9E5-E311-A86D-002618FDA250.root", + filePath + "308C6E25-BCE5-E311-80FD-002618B27F8A.root", + filePath + "322F4739-ADE5-E311-9877-0025905A48D8.root", + filePath + "3602FC1D-BAE5-E311-8798-003048D15DB6.root", + filePath + "36946947-AFE5-E311-A7E2-003048678ED4.root", + filePath + "38E10606-B4E5-E311-AEC6-003048FFCC18.root", + filePath + "3C4A787C-AAE5-E311-8617-003048678AE2.root", + filePath + "3E1FD7A9-BFE5-E311-8721-002618943910.root", + filePath + "3E23ADFF-C1E5-E311-9F7B-00261894394A.root", + filePath + "3E541785-B0E5-E311-AD7F-003048678ADA.root", + filePath + "3EE0FEF4-C2E5-E311-8911-003048678C26.root", + filePath + "40EB70F6-BAE5-E311-8F2D-0025905A48E4.root", + filePath + "448132B2-A8E5-E311-BA9E-003048678F8C.root", + filePath + "46ADA7C6-A9E1-E311-B57C-0025905A6138.root", + filePath + "46E0A383-C3E5-E311-B922-003048678FB4.root", + filePath + "48391443-ACE5-E311-A5EF-003048678E92.root", + filePath + "4AFCC957-B8E5-E311-AFE4-00261894386E.root", + filePath + "4AFF0350-BAE5-E311-BABE-002618943911.root", + filePath + "4C1D0806-BDE5-E311-83B4-002618943870.root", + filePath + "4C972F1F-C1E5-E311-80BD-002618FDA279.root", + filePath + "50FF9095-B4E5-E311-8F77-0025905A6134.root", + filePath + "548DDA6A-CCE5-E311-B311-001A92971B72.root", + filePath + "56839E4F-C2E5-E311-8B54-0026189438BC.root", + filePath + "58ABC9E0-B8E5-E311-A247-003048678BAE.root", + filePath + "58AF47AD-BFE5-E311-A5F4-0025905A612A.root", + filePath + "58B518EE-B1E5-E311-BA43-002618943865.root", + filePath + "58F9880C-DFE5-E311-AA51-0026189438D8.root", + filePath + "5C10382E-BCE5-E311-9BF2-0025905A60CE.root", + filePath + "5CABD6A4-B1E5-E311-8A03-002618943811.root", + filePath + "5ECDD519-BAE5-E311-96A2-00304866C398.root", + filePath + "628BE72D-E5E1-E311-948B-0025905A60E0.root", + filePath + "6449A028-D2E5-E311-8EE0-00259059642E.root", + filePath + "64886E02-B4E5-E311-BA8A-003048678F74.root", + filePath + "662B4AA2-B1E5-E311-B6A2-0026189437F5.root", + filePath + "6684C69C-AFE5-E311-AB82-0025905A60F4.root", + filePath + "669E8886-B2E5-E311-AFFE-0025905A48EC.root", + filePath + "683A0029-B9E5-E311-8F24-00261894395C.root", + filePath + "68F3F465-CEE5-E311-9E61-002618943976.root", + filePath + "6A9AEC43-AFE5-E311-93B0-0026189438E2.root", + filePath + "6AB7649E-BAE5-E311-A4D7-003048678B00.root", + filePath + "6C96B1FC-BFE5-E311-880A-0025905A60BC.root", + filePath + "6CC2F2C6-B0E5-E311-8CB2-002618943934.root", + filePath + "6CD358D7-B5E5-E311-9BF2-003048678B1A.root", + filePath + "6EE0C9B4-B7E5-E311-9A9B-0026189438AA.root", + filePath + "702A0F55-AEE5-E311-816D-0025905938A4.root", + filePath + "7062D2A6-B1E5-E311-AB71-00261894384A.root", + filePath + "78493034-B9E5-E311-8183-003048678B0E.root", + filePath + "7E6B3358-B5E5-E311-847C-00261894380B.root", + filePath + "7E98450C-B8E5-E311-AC84-0025905A609E.root", + filePath + "80CFB32F-B6E5-E311-8AD4-003048FFD796.root", + filePath + "80FA22BF-B9E5-E311-A452-00261894386D.root", + filePath + "826484B8-B6E5-E311-A5AB-002618FDA237.root", + filePath + "842654AD-B5E5-E311-80F2-0025905A6082.root", + filePath + "8494D5B6-B7E5-E311-9443-0025905A60F2.root", + filePath + "84AB8635-ABE2-E311-A265-00304867920A.root", + filePath + "860AC797-BDE5-E311-8114-0026189438D8.root", + filePath + "880099FE-68E1-E311-8EE5-003048678FB8.root", + filePath + "88D7C5BB-B7E5-E311-89DE-0025905A6068.root", + filePath + "8A25A451-B7E5-E311-8125-003048679162.root", + filePath + "8A55CC6F-B9E5-E311-9F42-003048678C62.root", + filePath + "8A6F7CC0-ADE5-E311-AA7F-002618943927.root", + filePath + "8CC45A82-BBE5-E311-93CB-002618943937.root", + filePath + "90DEE929-BCE5-E311-A8A4-0025905A6082.root", + filePath + "90E9360E-B7E5-E311-87E9-0025905A606A.root", + filePath + "90FD019C-A9E5-E311-945F-00304867926C.root", + filePath + "9261DF99-BDE5-E311-A444-0025905964CC.root", + filePath + "941528AF-AEE5-E311-B9FA-0025905A48BA.root", + filePath + "9491E4F8-AEE5-E311-A023-002618943870.root", + filePath + "960FE833-BEE5-E311-914F-0026189438E9.root", + filePath + "9840150B-B4E5-E311-980C-0025905A60A0.root", + filePath + "98471380-BCE5-E311-8D79-002618943913.root", + filePath + "9AE05C4C-BBE5-E311-B249-0026189438C1.root", + filePath + "9C070FE4-ACE5-E311-9C9C-003048678F9C.root", + filePath + "9E83A73C-C0E5-E311-85F3-0026189438D7.root", + filePath + "9EECE69E-B5E5-E311-8E2D-0030486792F0.root", + filePath + "A04B5DB4-9AE1-E311-9CC9-003048678BAA.root", + filePath + "A20C4520-C1E5-E311-92B7-0025905964A6.root", + filePath + "A45B1200-B9E5-E311-811F-0025905A60D6.root", + filePath + "A61FFA2E-3BE1-E311-B074-003048678B3C.root", + filePath + "A6ED34F4-B8E5-E311-94BD-003048FFD752.root", + filePath + "A8A98479-BCE5-E311-BC9A-00304867D836.root", + filePath + "A8C3AF91-B4E5-E311-B364-003048679166.root", + filePath + "AE20328F-B8E5-E311-86FD-0026189438D9.root", + filePath + "AE49C9E4-ACE5-E311-9294-0026189438D5.root", + filePath + "AEE31A19-BAE5-E311-A881-002618943954.root", + filePath + "B4B4FC77-B6E5-E311-B93C-0025905A48F0.root", + filePath + "B830253D-B2E5-E311-9652-0025905A611E.root", + filePath + "B853F7B5-BCE5-E311-AA59-0025905A48EC.root", + filePath + "BA494230-BEE5-E311-A1B8-002618943960.root", + filePath + "BE8D19D9-AAE5-E311-9C96-0025905A613C.root", + filePath + "BE9830B4-C1E5-E311-BB58-0025905938D4.root", + filePath + "C01B2734-C6E5-E311-8DB4-0025905A48BC.root", + filePath + "C051FA80-B6E5-E311-940A-0026189438BA.root", + filePath + "C059888E-B8E5-E311-A34B-002618943946.root", + filePath + "C40B806E-C1E5-E311-AE32-002618943849.root", + filePath + "C4635BDA-B8E5-E311-8765-00304867BFBC.root", + filePath + "CAE6F8DD-C0E5-E311-856F-0025905A610C.root", + filePath + "CE17BD86-B0E5-E311-9DFB-00261894382A.root", + filePath + "CED472CB-C6E5-E311-8F24-0026189438F5.root", + filePath + "D011B55B-BAE5-E311-A470-0025905A48E4.root", + filePath + "D0E4D868-B1E5-E311-839C-00304867904E.root", + filePath + "D2463FEA-BAE5-E311-86D2-00261894393A.root", + filePath + "D2D6FD85-B2E5-E311-9F0E-0025905A6090.root", + filePath + "D6A73BD8-CFE5-E311-AEF9-0025905A60AA.root", + filePath + "D8498D48-B5E5-E311-83C0-003048679236.root", + filePath + "D89D7769-ABE5-E311-B4BF-00304867BFF2.root", + filePath + "DC7B6FC2-BEE5-E311-99A1-00261894395F.root", + filePath + "DEACD80E-AEE5-E311-B9BA-0025905A6092.root", + filePath + "E059E103-ACE5-E311-BF61-003048678F9C.root", + filePath + "E0EEEEB3-B3E5-E311-A90F-003048678BAA.root", + filePath + "E41FB08D-BBE5-E311-AA07-0025905A60CE.root", + filePath + "E80DCD18-B3E5-E311-BE59-003048678AE2.root", + filePath + "EC750FAE-ABE5-E311-8F82-0025905A60B2.root", + filePath + "EE248300-B7E5-E311-BB3A-00304867920A.root", + filePath + "F01A9158-B8E5-E311-80BD-0025905A60F2.root", + filePath + "F0698C51-1FE6-E311-9195-0025905A60EE.root", + filePath + "F07E4C9A-C5E5-E311-98B6-0026189438BC.root", + filePath + "F0F2D3D9-B2E5-E311-9451-003048FF9AC6.root", + filePath + "F6524744-B5E5-E311-9FC3-0026189438E0.root", + filePath + "F6B79650-B8E5-E311-B250-003048679070.root", + filePath + "FCE78986-10E3-E311-8C30-0025905A6110.root", + filePath + "FCF3EC6A-C9E5-E311-A79B-002618943921.root" + ) + return myVstring + + elif dataset == "PYTHIA6_Tauola_TTbar_ChargedHiggs160_taunu_14TeV": + myVstring = cms.untracked.vstring( + filePath + "02726860-24E1-E311-B644-002618943962.root", + filePath + "0406641B-09E7-E311-8C83-002618943875.root", + filePath + "04FCB21C-E6E1-E311-8DEA-0025905A6066.root", + filePath + "0C2962BE-1EE7-E311-9EA8-003048FFCBB0.root", + filePath + "0E7A9986-F4E6-E311-9D36-003048FFD732.root", + filePath + "124A9D79-F7E6-E311-BAB3-002618943874.root", + filePath + "12796840-1DE7-E311-A1E7-0025905938A8.root", + filePath + "144CFF86-29E7-E311-8EC6-0026189438B9.root", + filePath + "14717FDB-1BE7-E311-BE9D-0025905A60DE.root", + filePath + "14864962-15E7-E311-88EB-003048FFD7D4.root", + filePath + "1ACDF005-FBE6-E311-ADB8-0025905AA9CC.root", + filePath + "1ADEB3EF-23E7-E311-8423-003048FFD76E.root", + filePath + "1C4CA2B1-17E7-E311-A82A-0026189438F2.root", + filePath + "264477E5-F3E6-E311-9001-003048FFD71E.root", + filePath + "2CC6E953-53E7-E311-813B-0026189438A5.root", + filePath + "365DD5ED-18E7-E311-89E0-003048FFD744.root", + filePath + "380AB520-11E7-E311-9C07-0025905A60C6.root", + filePath + "3A5D2532-17E7-E311-868D-003048678F74.root", + filePath + "3A6B803D-1BE7-E311-8BF2-0025905A60B8.root", + filePath + "3EB80082-1EE7-E311-B562-0025905938A8.root", + filePath + "4482E956-13E7-E311-A083-002354EF3BE2.root", + filePath + "44CE3153-19E7-E311-8A52-0025905A60B4.root", + filePath + "4C77EAF9-1CE7-E311-B5C2-002618943982.root", + filePath + "4C9BA307-23E7-E311-82EA-003048FFD76E.root", + filePath + "4E021466-18E7-E311-9500-002590596484.root", + filePath + "4E85C73C-10E7-E311-8BCD-00261894392B.root", + filePath + "50D06F40-08E7-E311-B8B0-002618943821.root", + filePath + "5231F8F1-1FE7-E311-84DE-003048FFD76E.root", + filePath + "54F2280E-F2E6-E311-8955-003048679166.root", + filePath + "58D258B6-1CE7-E311-B714-003048FFD732.root", + filePath + "5C59D0F8-13E7-E311-9DCE-003048678B86.root", + filePath + "605A1E1A-27E7-E311-A9EE-002618943862.root", + filePath + "645536E4-1DE7-E311-A466-0025905A6122.root", + filePath + "660E6980-39E7-E311-B5BF-0026189438F8.root", + filePath + "66C9A834-0DE7-E311-8AB9-00261894389E.root", + filePath + "6CF87F8E-06E7-E311-8CE2-0025905A6094.root", + filePath + "743C254C-98E7-E311-BA1F-0025905A60BE.root", + filePath + "7491C44D-11E7-E311-B30B-0025905A60DE.root", + filePath + "74A5B85B-05E7-E311-BABA-0025905A6118.root", + filePath + "780D93C0-22E7-E311-B769-0025905A60A0.root", + filePath + "783D516F-17E7-E311-A52C-00261894386A.root", + filePath + "78BA5037-0FE7-E311-816A-0025905A60F4.root", + filePath + "7A26953C-25E7-E311-BEF4-0025905A60D0.root", + filePath + "7A535752-02E7-E311-AC1F-003048678F9C.root", + filePath + "7CCB4C99-19E7-E311-9959-002618943950.root", + filePath + "825546F0-1AE7-E311-8753-0026189438CC.root", + filePath + "8442A414-F5E6-E311-9883-0025905A6132.root", + filePath + "864B156C-1CE7-E311-8784-0026189438FC.root", + filePath + "921C3AA8-1AE7-E311-BCF1-0025905964A6.root", + filePath + "9238549D-D0E2-E311-83B2-003048678E52.root", + filePath + "94E31A24-31E7-E311-B0A7-00261894393A.root", + filePath + "987B1FC7-15E7-E311-BB0B-003048FFD760.root", + filePath + "9AA665E4-11E7-E311-BA3B-00261894398A.root", + filePath + "A210AC59-F8E6-E311-8BB7-003048FFCC1E.root", + filePath + "A41777F0-0FE7-E311-B80B-0025905964B6.root", + filePath + "A4BCBCD1-16E7-E311-8CCC-003048678B5E.root", + filePath + "A6260186-1BE7-E311-8897-0025905938A8.root", + filePath + "AA9F59C4-07E7-E311-A83B-0025905A6094.root", + filePath + "B0646CAB-15E7-E311-A0E4-00259059649C.root", + filePath + "B4731B5D-1AE7-E311-869B-002618943950.root", + filePath + "B49620A0-18E7-E311-B82C-00261894386A.root", + filePath + "BA61C1AE-70E1-E311-98C8-0025905A60FE.root", + filePath + "BC91D308-18E7-E311-BC81-002618943950.root", + filePath + "BCA3C7EC-0AE7-E311-B590-00261894385A.root", + filePath + "C0143B50-F6E6-E311-8BDD-0025905A48D0.root", + filePath + "C614DAEE-02E7-E311-9D23-003048FFD7A2.root", + filePath + "C654D858-23E7-E311-AF69-0025905938AA.root", + filePath + "C86C6CF8-07E7-E311-98F5-0025905A60B6.root", + filePath + "CE1124FB-15E7-E311-AB46-003048FFCBB0.root", + filePath + "CE2E12D3-19E7-E311-9880-00261894385A.root", + filePath + "D66A3577-04E7-E311-B9C5-003048679182.root", + filePath + "E2641696-21E7-E311-B11C-003048FFD76E.root", + filePath + "E2A1DBCD-14E7-E311-96CA-002354EF3BE2.root", + filePath + "E4214FBF-05E7-E311-8454-00304867BED8.root", + filePath + "EAC42806-19E7-E311-A9D0-0025905A6104.root", + filePath + "ECF830B6-20E7-E311-802C-003048D3FC94.root", + filePath + "EE5913C9-04E7-E311-BBAD-003048FFD7A2.root", + filePath + "F4B0BDE1-16E7-E311-8EFE-0025905AA9CC.root", + filePath + "F83EA6D5-1BE7-E311-9791-0026189438FC.root", + filePath + "FE0011A7-03E7-E311-8DF0-003048FFD796.root" + ) + return myVstring + + elif dataset == "PYTHIA_Tauola_TB_ChargedHiggs200_14TeV": + myVstring = cms.untracked.vstring( + filePath + "00B03ED2-FEE6-E311-A112-00304867920A.root", + filePath + "023D04D6-19E7-E311-A0AB-0025905A60DE.root", + filePath + "0413B342-21E7-E311-845A-0025905A60A0.root", + filePath + "04372F54-FCE6-E311-AEB5-0025905AA9F0.root", + filePath + "060B6D02-08E7-E311-9F68-002618943916.root", + filePath + "08BB0F5A-1AE7-E311-8506-00261894396B.root", + filePath + "0C0673A4-0EE7-E311-A823-0025905A48EC.root", + filePath + "0C52C64D-FDE6-E311-9B84-0025905A611E.root", + filePath + "1007C3F3-04E3-E311-AF9A-0025905822B6.root", + filePath + "121A85B9-18E7-E311-AFB1-0026189438FA.root", + filePath + "121BE371-15E7-E311-A9AF-002354EF3BD0.root", + filePath + "12E16203-16E7-E311-8F9B-00261894393E.root", + filePath + "148B5499-19E7-E311-A34F-002618943950.root", + filePath + "14BDCCF6-11E7-E311-8974-0025905A612E.root", + filePath + "2055993C-61E1-E311-8830-00304867BF18.root", + filePath + "228B5140-0DE7-E311-B16B-0025905A6136.root", + filePath + "246B1119-01E7-E311-B16D-0025905AA9F0.root", + filePath + "32BF8B1A-1FE1-E311-A56F-0025905A6088.root", + filePath + "38820AB7-11E7-E311-A21C-0025905A611E.root", + filePath + "3C174073-13E7-E311-B090-003048678A6C.root", + filePath + "3E3285BA-1EE7-E311-ADEC-0025905A609E.root", + filePath + "48147DB2-01E7-E311-A524-002354EF3BDD.root", + filePath + "4869AFA5-13E7-E311-8CB7-0026189438AE.root", + filePath + "4A5EC6E2-1DE7-E311-9140-003048FFCC1E.root", + filePath + "4C98EDBC-67E7-E311-BF6C-002618943984.root", + filePath + "52609C4E-FFE6-E311-9D58-0025905A6084.root", + filePath + "563DAD9E-03E7-E311-A0FA-003048FF86CA.root", + filePath + "58945861-2DE7-E311-889B-002354EF3BE0.root", + filePath + "5C3B4360-11E7-E311-BB96-0025905A48D8.root", + filePath + "5E10CBD8-1BE7-E311-85C3-002354EF3BCE.root", + filePath + "6A2DCC32-06E7-E311-BB85-002618943949.root", + filePath + "6ACB1DB3-FFE6-E311-8788-00304867915A.root", + filePath + "6EFD9B64-1CE7-E311-95A8-002354EF3BCE.root", + filePath + "783ECBCD-0BE7-E311-856C-0025905A60A8.root", + filePath + "7A71F73B-00E7-E311-8FA7-0025905A60B6.root", + filePath + "7CF2DD8A-0BE7-E311-965E-003048FFCB8C.root", + filePath + "7CF83689-0DE7-E311-B991-0025905A60AA.root", + filePath + "7EF854EF-18E7-E311-812B-002618943886.root", + filePath + "80CB7F20-15E7-E311-AC04-0025905A48BC.root", + filePath + "825D27EF-0FE7-E311-AC06-0025905A612E.root", + filePath + "84A9EB7D-14E7-E311-A70F-0026189438AE.root", + filePath + "86D40C9C-16E7-E311-B6B8-003048679076.root", + filePath + "8C1C1FED-0FE7-E311-BECF-0025905AA9CC.root", + filePath + "8EDCA17A-10E7-E311-9285-0025905AA9CC.root", + filePath + "96E08127-09E7-E311-86C0-003048FFD752.root", + filePath + "9EBDFE39-03E7-E311-940A-0025905A6110.root", + filePath + "A6491521-FEE6-E311-974A-0025905964B4.root", + filePath + "A82096E8-FFE6-E311-B09E-0025905A6132.root", + filePath + "A8BCB564-FFE6-E311-B16B-003048FFD7D4.root", + filePath + "AECE17EF-13E7-E311-8C18-00304867902E.root", + filePath + "AEEEF847-19E7-E311-90E6-003048FFCBFC.root", + filePath + "B2B8B877-10E7-E311-BB32-0025905A48BC.root", + filePath + "B6224E3E-0FE7-E311-AB53-0025905A611E.root", + filePath + "BC0C09B0-15E7-E311-9EDA-0025905A60D0.root", + filePath + "C23D610A-18E7-E311-AF37-002618943886.root", + filePath + "C4500B8F-CFE1-E311-B036-0025905A6122.root", + filePath + "C462FD0A-13E7-E311-ACD5-002618943939.root", + filePath + "C678FB03-1DE7-E311-AB65-00259059642E.root", + filePath + "CA2BEB3A-45E1-E311-A490-00261894382D.root", + filePath + "D001AB40-1BE7-E311-A83D-003048FFD744.root", + filePath + "D235759B-1FE7-E311-87D1-003048FFCC1E.root", + filePath + "D66D4074-17E7-E311-86B1-003048FFD756.root", + filePath + "D6CEF931-17E7-E311-8DFD-0025905A610C.root", + filePath + "DCCE3A1F-15E7-E311-8715-0025905A48D8.root", + filePath + "DE6D92C7-00E7-E311-8823-0025905A60DE.root", + filePath + "DE7AD8AB-0AE7-E311-8831-00261894385A.root", + filePath + "E436E06A-18E7-E311-B98B-0025905938B4.root", + filePath + "EA9D0C09-18E7-E311-8D4D-002618943950.root", + filePath + "F2F756C9-00E7-E311-9204-0026189438EB.root", + filePath + "F43F8F15-05E7-E311-A696-002618943829.root", + filePath + "F4F0760E-23E7-E311-8239-0025905A610A.root", + filePath + "F80E30C1-12E7-E311-9465-0026189438E8.root", + filePath + "F8AB77FE-0EE7-E311-8863-0025905964A6.root", + filePath + "FC741D6D-0AE7-E311-95EB-003048FFD760.root", + filePath + "FE6C9B66-0CE7-E311-A22C-0025905A608E.root", + filePath + "FE7C48EF-16E7-E311-A4FA-0025905A48FC.root", + filePath + "FEFB630A-11E7-E311-A22A-0025905A6076.root" + ) + return myVstring + + elif dataset == "SinglePionMinusFlatPt0p2To50": + myVstring = cms.untracked.vstring( + filePath + "0002415F-F5E6-E311-82F0-003048D15E02.root", + filePath + "0626DB06-DAE6-E311-8276-0025905A6126.root", + filePath + "0662419C-39E1-E311-B525-0025905A60CE.root", + filePath + "0837CAB6-DCE6-E311-B780-0025905A48BA.root", + filePath + "08927915-E2E6-E311-9B9A-003048678A78.root", + filePath + "08E86C56-DAE6-E311-AF4E-003048FFD740.root", + filePath + "102B9AD1-C3E1-E311-8782-0026189438D5.root", + filePath + "1213AC6C-37E1-E311-97FD-003048678ED2.root", + filePath + "16752E52-E6E6-E311-99DB-002618FDA259.root", + filePath + "18D08A95-D5E6-E311-B52C-0025905938A4.root", + filePath + "1A43EBF6-DAE6-E311-8140-0025905A608E.root", + filePath + "1AA3EF1E-1CE7-E311-9191-0025905A6126.root", + filePath + "26E62588-97E1-E311-B92B-003048678B0E.root", + filePath + "282D7CE2-D4E6-E311-9C72-0025905A6068.root", + filePath + "2AC6B62C-ECE6-E311-A514-003048FF9AC6.root", + filePath + "3A4B1F30-E1E6-E311-A3BA-0025905A609E.root", + filePath + "42118396-D5E6-E311-9395-0025905964B2.root", + filePath + "48C32ED5-D8E6-E311-B30F-0025905A60A0.root", + filePath + "48C94748-DDE6-E311-9519-00259059391E.root", + filePath + "4C3B46BC-E5E6-E311-8072-0025905A60B4.root", + filePath + "5421C7A4-39E1-E311-AF9D-0025905964CC.root", + filePath + "5686FB82-E7E6-E311-95F2-00261894394A.root", + filePath + "64F9C9EF-DAE6-E311-ABC1-003048FFD720.root", + filePath + "6A854223-D9E6-E311-B1CA-0025905A6088.root", + filePath + "6EBE3B6C-DCE6-E311-9BCC-0025905A48D8.root", + filePath + "72E3917A-DBE6-E311-9A38-0026189438EA.root", + filePath + "7A40EFB7-D6E6-E311-A717-00261894396F.root", + filePath + "806EABED-DDE6-E311-A30C-0026189438F7.root", + filePath + "86B7E69F-DDE6-E311-8AE5-003048FFD760.root", + filePath + "8C50DBBA-D9E6-E311-921E-0025905A497A.root", + filePath + "8CCB5470-DFE6-E311-BB7B-00261894389F.root", + filePath + "8CD7DF11-E3E6-E311-BD4C-0025905A609E.root", + filePath + "8EDF2B9D-D4E6-E311-B7BF-002618943963.root", + filePath + "94820E88-02E3-E311-9BC6-0025905964A6.root", + filePath + "960D003A-D8E6-E311-92D2-00248C0BE012.root", + filePath + "A2A97B5D-C1E3-E311-9035-002618943870.root", + filePath + "A47B4759-46E1-E311-9384-00261894393F.root", + filePath + "B086C678-D6E6-E311-BD4B-0025905A60C6.root", + filePath + "B2AF39FB-38E1-E311-81A7-002618943800.root", + filePath + "B49F54CF-DEE6-E311-B183-0026189438C9.root", + filePath + "BA0CADE4-D5E6-E311-B21A-0025905A6092.root", + filePath + "C05521E6-87E3-E311-AF32-0025905938A4.root", + filePath + "C28F7AA7-8CE7-E311-83B0-003048678B72.root", + filePath + "CCC63508-E5E6-E311-8785-0025905964BE.root", + filePath + "D019764D-E0E6-E311-8B87-0025905A60F2.root", + filePath + "D05DB581-D8E6-E311-87BA-0025905A60E0.root", + filePath + "D68AD685-E4E6-E311-BA99-0025905A6056.root", + filePath + "E0E7B98A-DAE2-E311-8AB6-003048FFCBB0.root", + filePath + "E2104185-DEE6-E311-8EB7-003048679080.root", + filePath + "E68BED90-E3E6-E311-861E-0025905964CC.root", + filePath + "EE283FE7-D7E6-E311-BD30-00261894384A.root", + filePath + "EE420008-D7E6-E311-ACA8-0025905A6136.root", + filePath + "EEAEF440-DEE6-E311-88AB-0025905A6076.root", + filePath + "EEC9A902-D4E6-E311-9985-002618943966.root", + filePath + "F254DDA0-D7E6-E311-BA20-0025905A60B8.root", + filePath + "F277219D-88E1-E311-BDFD-0025905964BE.root", + filePath + "F43709B0-DFE6-E311-A11F-003048678FFA.root", + filePath + "F866FC6D-D3E6-E311-BC1B-0025905A6070.root", + filePath + "FC864313-DCE6-E311-81E8-00304867BEDE.root", + ) + return myVstring + + elif dataset == "SinglePionPlusFlatPt0p2To50": + myVstring = cms.untracked.vstring( + filePath + "065654D-E9E6-E311-A6E1-0026189438B0.root", + filePath + "04BA1DA8-27E2-E311-A1A9-00304867904E.root", + filePath + "061D1A95-EDE6-E311-A11E-003048679006.root", + filePath + "0AA8C12D-ECE6-E311-8F8A-0025905A60A0.root", + filePath + "0AFBDC2D-05E7-E311-996A-00261894398D.root", + filePath + "0CF2F87A-E4E6-E311-BF35-0025905964BE.root", + filePath + "10B97C58-E0E6-E311-8BCE-003048FFD736.root", + filePath + "14960519-EDE6-E311-8053-002618FDA210.root", + filePath + "188A9E45-EEE6-E311-8F12-002590596490.root", + filePath + "189B0E0C-E3E6-E311-837E-0025905964B2.root", + filePath + "1E77C37C-EFE6-E311-A659-003048678DA2.root", + filePath + "209BC4C4-E4E6-E311-9D2C-0026189438F7.root", + filePath + "2879AB00-E6E6-E311-B152-003048678E92.root", + filePath + "3647FE99-E6E6-E311-BCD3-002618FDA210.root", + filePath + "385779FA-F8E1-E311-B237-00261894383E.root", + filePath + "3CA14488-E3E6-E311-A063-003048678B92.root", + filePath + "4626CCD2-EBE6-E311-92D0-00261894397E.root", + filePath + "4CA0BDC6-EAE6-E311-ABC4-003048678FB8.root", + filePath + "52CB643D-E7E6-E311-9D62-00261894386E.root", + filePath + "564F87B5-ECE6-E311-BB34-00259059642A.root", + filePath + "56C75214-EBE6-E311-8B48-0025905964A6.root", + filePath + "5A38EE6C-EBE6-E311-8A14-002590593920.root", + filePath + "5CB63C7C-F4E6-E311-8A93-0025905A48D0.root", + filePath + "5EF4B7F8-E9E6-E311-ADAA-002618943913.root", + filePath + "600BE37C-EFE6-E311-A618-001BFCDBD1BA.root", + filePath + "68E5E788-29E7-E311-9589-002618943983.root", + filePath + "76246E81-EAE6-E311-8B59-0025905A6136.root", + filePath + "7899E7DA-E1E6-E311-BC95-0025905A609E.root", + filePath + "7C442A22-EFE6-E311-A2FD-0025905964A2.root", + filePath + "7EE6DDBF-EAE6-E311-84F0-003048678BE8.root", + filePath + "84411EE3-E9E6-E311-8D4A-0025905A48C0.root", + filePath + "98843F49-EDE6-E311-B869-002618943914.root", + filePath + "9A6B1AB0-E5E6-E311-ABEF-0025905964BE.root", + filePath + "9A7BE7E8-EDE6-E311-AF3C-0025905A60B4.root", + filePath + "9AEA8341-1BE7-E311-83F8-003048FFCBFC.root", + filePath + "9C66F8AF-E7E6-E311-8477-00261894397D.root", + filePath + "9C96B1EA-E6E6-E311-B603-0026189438DF.root", + filePath + "9EC595CF-F1E6-E311-8E3B-003048678C62.root", + filePath + "A09B982E-EAE6-E311-979D-00261894397B.root", + filePath + "ACF87C58-E6E6-E311-B97E-003048678E92.root", + filePath + "AEF89AE0-E3E6-E311-9336-002618943962.root", + filePath + "B4B4436D-ECE6-E311-8327-0026189438AD.root", + filePath + "BA88BA20-EDE6-E311-A452-003048679164.root", + filePath + "C262D25B-E5E6-E311-93F6-0025905964B2.root", + filePath + "C64D94E8-EDE6-E311-BA56-0026189438E2.root", + filePath + "CAE3DCB2-F0E6-E311-9227-001A92971BB4.root", + filePath + "CC9938B6-E8E6-E311-B63D-003048678E80.root", + filePath + "D40B4132-EAE6-E311-AD07-002618943885.root", + filePath + "DC1EE80F-F0E6-E311-BB1E-003048678E52.root", + filePath + "E82481EA-E7E6-E311-9309-0026189438F7.root", + filePath + "E8FF6A7D-C6E2-E311-887C-003048679070.root", + filePath + "EC720D3B-E1E6-E311-B96A-003048678AFA.root", + filePath + "EE4CDB8C-72E1-E311-A2A7-003048678FD6.root", + filePath + "F4F15FFA-E8E6-E311-8C5E-00304867C1BA.root", + filePath + "F6E2B45E-81E3-E311-B6E8-00261894385A.root", + ) + return myVstring + + elif dataset == "SingleTauOneProngFlatPt10To100": + myVstring = cms.untracked.vstring( + filePath + "06ABA3EB-FCE6-E311-85A2-0026189438BD.root", + filePath + "0823C16F-FAE6-E311-9D61-003048FFD79C.root", + filePath + "084DF30C-24E7-E311-8604-0025905A610A.root", + filePath + "08DA8981-C3E1-E311-91C0-0026189438D5.root", + filePath + "0A672DC4-FDE6-E311-9ABD-002618943918.root", + filePath + "0A9B08BC-8CE7-E311-AEA9-002618943985.root", + filePath + "0AC8B373-EEE6-E311-B06D-003048D15E2C.root", + filePath + "10268600-F9E6-E311-A8B0-0025905964BC.root", + filePath + "10401B04-FBE6-E311-BDE7-0025905A60D6.root", + filePath + "121E37FF-0DE7-E311-8985-0025905A610C.root", + filePath + "14FE28D4-FBE6-E311-B350-003048678B12.root", + filePath + "160895FC-ECE6-E311-9128-003048678FB4.root", + filePath + "16901397-FBE6-E311-BA20-0025905A48BA.root", + filePath + "2C038A3A-03E7-E311-94F2-0025905A6118.root", + filePath + "342F6626-0CE7-E311-B84F-00261894390B.root", + filePath + "369B3751-FCE6-E311-AFB2-0025905A60B4.root", + filePath + "36F633D4-03E7-E311-9992-0025905A497A.root", + filePath + "38B51BA4-F9E6-E311-B1FC-0025905A60B2.root", + filePath + "3ABC5ACC-BEE3-E311-97EA-002618943918.root", + filePath + "3C7CFE86-09E7-E311-859E-0025905964C2.root", + filePath + "461F5C09-54E2-E311-8644-0025905A6092.root", + filePath + "4CF81F82-F7E6-E311-8349-0025905A60BC.root", + filePath + "52B75CE0-F6E6-E311-82A5-0025905A48D6.root", + filePath + "5499BB95-08E7-E311-99B9-0025905A6076.root", + filePath + "601922D7-F7E6-E311-85AD-0025905A6090.root", + filePath + "6813AB2F-F1E6-E311-9901-003048678AC0.root", + filePath + "6EACBB1E-07E7-E311-9DCB-0026189438CB.root", + filePath + "72887E4D-F9E6-E311-A04B-003048FFD7C2.root", + filePath + "7ADFEA9D-F6E6-E311-BEBA-0025905A6076.root", + filePath + "7C53C75C-FEE6-E311-9392-0025905A6122.root", + filePath + "827B6953-00E7-E311-A381-0025905A6134.root", + filePath + "84087179-FDE6-E311-8072-0026189438BF.root", + filePath + "86CDDFE3-F3E6-E311-A708-003048D15DB6.root", + filePath + "8E18EB63-01E7-E311-9F92-002618FDA262.root", + filePath + "9646FBBD-FCE6-E311-AE22-0025905A6104.root", + filePath + "A471E9D3-FBE6-E311-8125-0026189438BA.root", + filePath + "A6E205F6-36E1-E311-889D-003048FFCC1E.root", + filePath + "A89CE9EA-33E1-E311-ACC1-0026189437F0.root", + filePath + "AC1C439C-71E2-E311-A92B-0025905A48F0.root", + filePath + "AC78D948-05E7-E311-BF9A-0025905A60B6.root", + filePath + "ACC98F2C-01E7-E311-B8C3-0025905A60DA.root", + filePath + "ACFBDA8C-00E7-E311-8292-0025905A60FE.root", + filePath + "AEA24245-F6E6-E311-B637-0025905A611E.root", + filePath + "B06E5FBF-FAE6-E311-8453-0025905A608A.root", + filePath + "B0B21B0C-FEE6-E311-BC72-003048678BB2.root", + filePath + "B0E92042-FFE6-E311-8BEE-003048679080.root", + filePath + "B62A4DB7-F8E6-E311-9F99-00248C0BE01E.root", + filePath + "BAD554AE-F5E6-E311-A6AC-0025905A48B2.root", + filePath + "BCD0B320-F5E6-E311-8F98-0025905A6104.root", + filePath + "BE1E0F85-02E3-E311-909A-003048678B0E.root", + filePath + "C4B36BA3-FCE6-E311-AEEE-0025905964BC.root", + filePath + "CA82C162-EFE6-E311-9A9A-0025905A60B6.root", + filePath + "CC0F7B35-06E7-E311-A5BC-0025905A60D2.root", + filePath + "D0BB4D48-02E7-E311-BEA2-0025905AA9CC.root", + filePath + "D618E76A-F2E6-E311-ABF7-002618943956.root", + filePath + "D68D0E94-FFE6-E311-AA28-0025905964C4.root", + filePath + "D836BAB5-04E7-E311-A82C-0025905A6094.root", + filePath + "E2D577B2-0AE7-E311-97F2-003048FFCB74.root", + filePath + "E82842FF-FEE6-E311-94B0-002618943954.root", + filePath + "F0585CE5-02E7-E311-9433-0026189438DE.root", + filePath + "F0B52649-F0E6-E311-B04E-0025905A60AA.root", + filePath + "F849A8B3-12E7-E311-910F-0025905A60DA.root", + filePath + "F84D6FF7-F9E6-E311-B2F3-003048678F26.root", + filePath + "FE358131-F7E6-E311-85A7-00259059649C.root" + ) + return myVstring + + elif dataset == "TauThreeProngsEnriched": + raise Exception("The ROOT files for dataset '%s' are not yet ready." % (dataset) ) + elif dataset == "VBF_HToTauTau_125_14TeV_powheg_pythia6": + + myVstring = cms.untracked.vstring( + filePath + "00114910-0DE9-E311-B42B-0025905A60F4.root", + filePath + "06B547C1-03E9-E311-864E-0025905A48D6.root", + filePath + "0EFF9054-0CE9-E311-94C0-0025905A60F4.root", + filePath + "16C00111-F8E8-E311-9E15-0025905A60F4.root", + filePath + "2E87B579-0BE9-E311-AB95-0025905A60E0.root", + filePath + "32AB81E7-FEE8-E311-8BF0-0025905A610C.root", + filePath + "361E96CA-0DE9-E311-B125-0025905A60A0.root", + filePath + "3863D90D-54E9-E311-A058-0025905A613C.root", + filePath + "38D7EA76-F7E8-E311-942F-0025905A6134.root", + filePath + "3A62DD3A-FAE8-E311-BEC7-0025905A48D8.root", + filePath + "3C93BF0E-0CE9-E311-AFB6-0025905A60E0.root", + filePath + "40D9A6DF-04E9-E311-AF30-002618FDA262.root", + filePath + "42B5A33C-0EE9-E311-A9F0-0025905A613C.root", + filePath + "5476408F-0AE9-E311-BD50-0025905A60AA.root", + filePath + "5EC6B1F5-00E9-E311-85F1-002590596498.root", + filePath + "6229198C-0AE9-E311-B8E5-0025905A60DA.root", + filePath + "643261B3-03E9-E311-AAFF-0025905A60F4.root", + filePath + "741B1BD0-F7E8-E311-BBE7-0025905A6122.root", + filePath + "7CC68AFC-07E9-E311-AF74-002618943978.root", + filePath + "886A36E4-0AE9-E311-BA5B-0025905A6088.root", + filePath + "8A6C0700-01E9-E311-9007-0025905A607E.root", + filePath + "8A8944EE-FEE8-E311-AA56-0025905A60E4.root", + filePath + "8C44A872-1DE9-E311-AF5E-0025905A611C.root", + filePath + "8E6DDCC4-0CE9-E311-8726-0025905A608E.root", + filePath + "8ECA648F-11E9-E311-A14C-0025905A48C0.root", + filePath + "92E9EC3D-0DE9-E311-8378-0025905A60E0.root", + filePath + "987B3266-F8E8-E311-A45D-0025905A6076.root", + filePath + "9C51B3A7-01E9-E311-986D-002590593876.root", + filePath + "9C969434-12E9-E311-A310-0025905A608E.root", + filePath + "A45462C4-0CE9-E311-A705-0025905A60E0.root", + filePath + "B222D8D7-0BE9-E311-8F8B-0025905A609A.root", + filePath + "B4DAAF17-03E9-E311-80AC-0025905A48D8.root", + filePath + "C0D79D26-F8E8-E311-8C33-003048FFD752.root", + filePath + "C2218079-80E9-E311-BD87-0025905A60E0.root", + filePath + "C6E86797-0AE9-E311-B910-0025905A6136.root", + filePath + "D07B7F5F-10E9-E311-8804-0025905A48C0.root", + filePath + "E07E30CA-09E9-E311-BB64-0025905A60DA.root", + filePath + "E8FD83A2-01E9-E311-9240-0025905A60E4.root", + filePath + "FA663EE6-00E9-E311-AFF5-0025905964C4.root", + filePath + "FC32DBC6-14E9-E311-A3E5-0025905A613C.root", + filePath + "FEB7427D-0BE9-E311-8601-0025905A48EC.root" + ) + return myVstring + else: + raise Exception("Unknown dataset '%s'. Please provide a valid dataset." % (dataset) ) + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py new file mode 100644 index 0000000000000..ba1b8ebd69c61 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py @@ -0,0 +1,120 @@ +# Import configurations +import FWCore.ParameterSet.Config as cms + +# Import a helper function for accessing dataset files on EOS +import SLHCUpgradeSimulations.L1TrackTrigger.tools.datasetsHelper as m_datasetsHelper + +# set up process +process = cms.Process("Tau") + +# +# This configuration runs over a file that contains the L1Tracks +# and the tracker digis. +# It creates L1TkTausFromCalo by clustering together high-pT L1Tracks +# and matching them to stage-2 L1CaloTaus. +# + +from SLHCUpgradeSimulations.L1TrackTrigger.singleTau1pFiles_cfi import * + +process.source = cms.Source("PoolSource", + #fileNames = m_datasetsHelper.GetEosRootFilesForDataset("Neutrino_Pt2to20_gun") + fileNames = singleTau1pFiles # the private files are better as the official sample + # for singleTau missed many decay modes + + ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(100) ) + +# initialize MessageLogger and output report +process.load("FWCore.MessageLogger.MessageLogger_cfi") +process.MessageLogger.cerr.FwkReport = cms.untracked.PSet( + reportEvery = cms.untracked.int32(10), + limit = cms.untracked.int32(10000000) +) + +process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(False) ) + +# Load geometry +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') + +# Global Tag +process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + +# Load Sequences: (Check that the following are all needed) +process.load("Configuration.StandardSequences.Services_cff") +process.load("Configuration.StandardSequences.RawToDigi_Data_cff") ###check this for MC! +process.load('Configuration.StandardSequences.L1Reco_cff') +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.load('Configuration/StandardSequences/EndOfProcess_cff') +process.load('Configuration/StandardSequences/L1HwVal_cff') +# Run the SLHCCaloSequence to produce the L1Jets +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +# The sequence SLHCCaloTrigger creates "stage-2" L1Taus. +# Two collections are created: +# a) ("SLHCL1ExtraParticles","Taus") +# b) ("SLHCL1ExtraParticles","IsoTaus") +# So far only the ("SLHCL1ExtraParticles","Taus") collection has been used. +# The ("SLHCL1ExtraParticles","IsoTaus") has not been looked yet. +process.p = cms.Path( + process.RawToDigi+ + process.SLHCCaloTrigger + ) + +# bug fix for missing HCAL TPs in MC RAW +process.p.insert(1, process.valHcalTriggerPrimitiveDigis) +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + +# Produce calibrated (eT-corrected) L1CaloTaus: +process.L1CaloTauCorrectionsProducer = cms.EDProducer("L1CaloTauCorrectionsProducer", + L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus") +) + +# Setup the L1TkTauFromCalo producer: +process.L1TkTauFromCaloProducer = cms.EDProducer("L1TkTauFromCaloProducer", + #L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus"), + L1TausInputTag = cms.InputTag("L1CaloTauCorrectionsProducer","CalibratedTaus"), + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + L1TkTrack_ApplyVtxIso = cms.bool( True ), # Produce vertex-isolated L1TkTaus? + L1TkTrack_VtxIsoZ0Max = cms.double( 1.0 ), # Max vertex z for L1TkTracks for VtxIsolation [cm] + L1TkTrack_NStubsMin = cms.uint32( 5 ), # Min number of stubs per L1TkTrack [unitless] + L1TkTrack_PtMin_AllTracks = cms.double( 2.0 ), # Min pT applied on all L1TkTracks [GeV] + L1TkTrack_PtMin_SignalTracks = cms.double( 10.0), # Min pT applied on signal L1TkTracks [GeV] + L1TkTrack_PtMin_IsoTracks = cms.double( 2.0 ), # Min pT applied on isolation L1TkTracks [GeV] + L1TkTrack_RedChiSquareEndcapMax = cms.double( 5.0 ), # Max red-chi squared for L1TkTracks in Endcap + L1TkTrack_RedChiSquareBarrelMax = cms.double( 2.0 ), # Max red-chi squared for L1TkTracks in Barrel + L1TkTrack_VtxZ0Max = cms.double( 30.0 ), # Max vertex z for L1TkTracks [cm] + DeltaR_L1TkTau_L1TkTrack = cms.double( 0.10 ), # Cone size for L1TkTracks assigned to L1TkTau + DeltaR_L1TkTauIsolation = cms.double( 0.40 ), # Isolation cone size for L1TkTau + DeltaR_L1TkTau_L1CaloTau = cms.double( 0.15 ), # Matching cone for L1TkTau and L1CaloTau + L1CaloTau_EtMin = cms.double( 5.0 ), # Min eT applied on all L1CaloTaus [GeV] + RemoveL1TkTauTracksFromIsoCalculation = cms.bool( False ), # Remove tracks used in L1TkTau construction from VtxIso calculation? +) + +process.pCorr = cms.Path( process.L1CaloTauCorrectionsProducer ) +process.pTaus = cms.Path( process.L1TkTauFromCaloProducer ) + +# Define the output module +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "output.root" ), #"L1TkTausFromCalo.root" + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + +# Define the collections to be saved +process.Out.outputCommands.append('keep *_L1CaloTauCorrections*_*_*') +process.Out.outputCommands.append('keep *_L1TkTauFromCalo*_*_*') +process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_*_*') +process.Out.outputCommands.append('keep *_gen*_*_*') + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + From 5a43526947df01d59cc3ac5610a481f38a467b03 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 19 Jun 2014 12:51:11 +0200 Subject: [PATCH 045/252] Latest electron setup (enlarged phiwindows etc) + update of L1TkEm (retuned photon isolation) --- .../plugins/L1TkEmParticleProducer.cc | 34 +++++++++++++++++++ .../python/L1TkElectronTrackProducer_cfi.py | 17 +++++----- .../python/L1TkEmParticleProducer_cfi.py | 5 ++- .../src/L1TkElectronTrackMatchAlgo.cc | 3 +- .../test/produce_L1TkObjects_cfg.py | 9 +++-- .../test/test_L1TkEGamma_cfg.py | 16 +++++++-- .../test/test_L1TkEGamma_with_crystal_cfg.py | 31 +++++++++++------ 7 files changed, 90 insertions(+), 25 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmParticleProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmParticleProducer.cc index 5ecf8e47284fc..27bb80fad9144 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmParticleProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmParticleProducer.cc @@ -84,6 +84,7 @@ class L1TkEmParticleProducer : public edm::EDProducer { float DRmax; float PTMINTRA; bool PrimaryVtxConstrain; // use the primary vertex (default = false) + //bool DeltaZConstrain; // use z = z of the leading track within DR < DRmax; float DeltaZMax; // | z_track - z_primaryvtx | < DeltaZMax in cm. // Used only when PrimaryVtxConstrain = True. float IsoCut; @@ -116,6 +117,7 @@ L1TkEmParticleProducer::L1TkEmParticleProducer(const edm::ParameterSet& iConfig) DRmin = (float)iConfig.getParameter("DRmin"); DRmax = (float)iConfig.getParameter("DRmax"); PrimaryVtxConstrain = iConfig.getParameter("PrimaryVtxConstrain"); + //DeltaZConstrain = iConfig.getParameter("DeltaZConstrain"); DeltaZMax = (float)iConfig.getParameter("DeltaZMax"); // cut applied on the isolation (if this number is <= 0, no cut is applied) IsoCut = (float)iConfig.getParameter("IsoCut"); @@ -214,6 +216,32 @@ L1TkEmParticleProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu //std::cout << " here an EG w et = " << et << std::endl; + //float z_leadingTrack = -999; + //float Pt_leadingTrack = -999; + +/* + if (DeltaZConstrain) { + // first loop over the tracks to find the leading one in DR < DRmax + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { + float Pt = trackIter->getMomentum().perp(); + float Eta = trackIter->getMomentum().eta(); + float Phi = trackIter->getMomentum().phi(); + float z = trackIter->getPOCA().z(); + if (fabs(z) > ZMAX) continue; + if (Pt < PTMINTRA) continue; + float chi2 = trackIter->getChi2(); + if (chi2 > CHI2MAX) continue; + float dr = deltaR(Eta, eta, Phi,phi); + if (dr < DRmax) { + if (Pt > Pt_leadingTrack) { + Pt_leadingTrack = Pt; + z_leadingTrack = z; + } + } + } // end loop over the tracks + } // endif DeltaZConstrain +*/ + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { float Pt = trackIter->getMomentum().perp(); @@ -229,6 +257,12 @@ L1TkEmParticleProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu if ( zvtxL1tk > -999 && fabs( z - zvtxL1tk) >= DeltaZMax) continue; } +/* + if (DeltaZConstrain) { + if ( fabs( z - z_leadingTrack) >= DeltaZMax) continue; + } +*/ + float dr = deltaR(Eta, eta, Phi,phi); if (dr < DRmax && dr >= DRmin) { //std::cout << " a track in the cone, z Pt = " << z << " " << Pt << std::endl; diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py index 182131a1c56ce..dab3eae093112 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkElectronTrackProducer_cfi.py @@ -14,18 +14,19 @@ # ("SLHCL1ExtraParticlesNewClustering","EGamma"). ETmin = cms.double( -1.0 ), # Only the L1EG objects that have ET > ETmin in GeV # are considered. ETmin < 0 means that no cut is applied. - L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + #L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigisLargerPhi","Level1TTTracks"), # Quality cuts on Track and Track L1EG matching criteria - TrackChi2 = cms.double(100.0), # minimum Chi2 to select tracks - TrackMinPt = cms.double(12.0), # minimum Pt to select tracks - useTwoStubsPT = cms.bool( False ), - TrackEGammaDeltaPhi = cms.vdouble(0.05, 0.0, 0.0), # functional Delta Phi cut parameters to match Track with L1EG objects + TrackChi2 = cms.double(1e10), # minimum Chi2 to select tracks + TrackMinPt = cms.double(10.0), # minimum Pt to select tracks + useTwoStubsPT = cms.bool( True ), + TrackEGammaDeltaPhi = cms.vdouble(0.07, 0.0, 0.0), # functional Delta Phi cut parameters to match Track with L1EG objects TrackEGammaDeltaR = cms.vdouble(0.08, 0.0, 0.0), # functional Delta R cut parameters to match Track with L1EG objects - TrackEGammaDeltaEta = cms.double(0.08), # Delta Eta cutoff to match Track with L1EG objects - # are considered. + TrackEGammaDeltaEta = cms.double(1e10), # Delta Eta cutoff to match Track with L1EG objects + # are considered. (unused in default configuration) RelativeIsolation = cms.bool( True ), # default = True. The isolation variable is relative if True, # else absolute. - IsoCut = cms.double( -0.15 ), # Cut on the (Trk-based) isolation: only the L1TkEmParticle for which + IsoCut = cms.double( -0.10 ), # Cut on the (Trk-based) isolation: only the L1TkEmParticle for which # the isolation is below RelIsoCut are written into # the output collection. When RelIsoCut < 0, no cut is applied. # When RelativeIsolation = False, IsoCut is in GeV. diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py index a240159e39371..48aec49de87fb 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py @@ -16,7 +16,7 @@ # are considered. ETmin < 0 means that no cut is applied. RelativeIsolation = cms.bool( True ), # default = True. The isolation variable is relative if True, # else absolute. - IsoCut = cms.double( 0.1 ), # Cut on the (Trk-based) isolation: only the L1TkEmParticle for which + IsoCut = cms.double( 0.23 ), # Cut on the (Trk-based) isolation: only the L1TkEmParticle for which # the isolation is below RelIsoCut are written into # the output collection. When RelIsoCut < 0, no cut is applied. # When RelativeIsolation = False, IsoCut is in GeV. @@ -30,6 +30,9 @@ PrimaryVtxConstrain = cms.bool( False ), # default = False # if set to True, the L1TkPrimaryVertex is used to constrain # the tracks entering in the calculation of the isolatiom. + #DeltaZConstrain = cms.bool( False ), # default = False + # if set to True, constrain to the z of the leading + # track within DR < DRmax DeltaZMax = cms.double( 999. ), # in cm. Used only when PrimaryVtxConstrain = True L1VertexInputTag = cms.InputTag("NotUsed"), # Used only when PrimaryVtxConstrain = True ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc index d9209b42006e9..4e8a952ea097a 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/src/L1TkElectronTrackMatchAlgo.cc @@ -51,7 +51,8 @@ namespace L1TkElectronTrackMatchAlgo { } // --------------- calculate deltaPhi between Track and EGamma object double deltaR(const GlobalPoint& epos, const edm::Ptr< L1TkTrackType > & pTrk){ - double dPhi = fabs(reco::deltaPhi(epos.phi(), pTrk->getMomentum().phi())); + //double dPhi = fabs(reco::deltaPhi(epos.phi(), pTrk->getMomentum().phi())); + double dPhi = L1TkElectronTrackMatchAlgo::deltaPhi(epos, pTrk); double dEta = deltaEta(epos, pTrk); return sqrt(dPhi*dPhi + dEta*dEta); } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py index 2e56d78f15924..d04671a81064a 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py @@ -4,7 +4,7 @@ process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(20) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) # # This runs over a file that already contains the L1Tracks. @@ -32,11 +32,14 @@ # --------------------------------------------------------------------------- # -# --- Recreate the L1Tracks to benefit from the latest updates +# --- Recreate the L1Tracks to benefit from the latest updates, and create +# the collection of special tracks for electrons # process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") -process.pTracking = cms.Path( process.DefaultTrackingSequence ) +#process.pTracking = cms.Path( process.DefaultTrackingSequence ) +process.pTracking = cms.Path( process.FullTrackingSequence ) + # --------------------------------------------------------------------------- diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py index d255b7a9637a1..8816a0d00d7f0 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py @@ -4,10 +4,11 @@ process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) # -# This runs over a file that already contains the L1Tracks. +# This first creates the collection of "L1Tracks for electrons" by running +# the FullTrackingSequence. # # It produces the following objects : # - L1EG objects obtained by running the SLHCCaloTrigger sequence @@ -43,6 +44,17 @@ process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') +# --------------------------------------------------------------------------- +# +# --- Create the collection of special tracks for electrons +# + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.ElectronTrackingSequence ) + +# --------------------------------------------------------------------------- + + # --------------------------------------------------------------------------- diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py index 64f9a9475d7bc..500603ac815bd 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py @@ -7,7 +7,8 @@ process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) # -# This runs over a file that already contains the L1Tracks. +# This first creates the collection of "L1Tracks for electrons" by running +# the FullTrackingSequence. # # It produces the following objects : # - L1EG objects obtained by running the SLHCCaloTrigger sequence @@ -20,20 +21,21 @@ # that have been created. +# to run over the test rate sample (part 1) : +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * process.source = cms.Source("PoolSource", - fileNames = cms.untracked.vstring( + fileNames = minBiasFiles_p1 +) + +# to run over another sample: +#process.source = cms.Source("PoolSource", # electron file: #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SingleElectron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SinglePositron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SinglePositron_E2023TTI_PU140.root' - # - # rate test sample: - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m1_SingleNeutrino_E2023TTI_PU140.root', - '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Neutrinos/PU140_newGT/m2_SingleNeutrino_E2023TTI_PU140.root' - # - ) -) + #) +#) # ---- Global Tag : @@ -42,6 +44,15 @@ process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') +# --------------------------------------------------------------------------- +# +# --- Create the collection of special tracks for electrons +# + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.ElectronTrackingSequence ) + +# --------------------------------------------------------------------------- # --------------------------------------------------------------------------- @@ -90,6 +101,7 @@ process.reconstruction_step = cms.Path( process.calolocalreco ) process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", + EtminForStore = cms.double( -999.), debug = cms.untracked.bool(False), useECalEndcap = cms.untracked.bool(True) ) @@ -106,7 +118,6 @@ # information of the xtal level clusters. process.l1ExtraCrystalProducer = cms.EDProducer("L1ExtraCrystalPosition", - EtminForStore = cms.double( 4. ), eGammaSrc = cms.InputTag("SLHCL1ExtraParticlesNewClustering","EGamma"), eClusterSrc = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster") ) From 19b37553e2538e842ea88da8eaa6aec89106986c Mon Sep 17 00:00:00 2001 From: Nicola Date: Thu, 19 Jun 2014 16:24:29 +0200 Subject: [PATCH 046/252] DT-Tk Trigger update (no analyzer) --- .../L1DTPlusTrackTrigger/interface/DTMatch.h | 67 +++++++++---------- .../L1DTPlusTrackTrigger/src/DTMatch.cc | 25 +++++-- 2 files changed, 52 insertions(+), 40 deletions(-) diff --git a/DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h index 7fec05bc4e670..babdec4d28158 100644 --- a/DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h +++ b/DataFormats/L1DTPlusTrackTrigger/interface/DTMatch.h @@ -35,39 +35,38 @@ float const binPt[25] = { 0., /// Lower limit /// There are two tables: one for DT seeds in station MB1, one for DT seeds /// in station MB2 float const cutPtInvMB1[15][24] = { - {0.3752,0.2424,0.1967,0.1660,0.1436,0.1136,0.0941,0.0802,0.0699,0.0621,0.0559,0.0446,0.0372,0.0319,0.0280,0.0250,0.0226,0.0189,0.0164,0.0145,0.0130,0.0118,0.0101,0.0088}, - {0.3853,0.2429,0.1974,0.1669,0.1443,0.1140,0.0945,0.0806,0.0702,0.0624,0.0561,0.0448,0.0373,0.0320,0.0280,0.0250,0.0226,0.0189,0.0164,0.0145,0.0129,0.0118,0.0100,0.0088}, - {0.4082,0.2436,0.1977,0.1672,0.1445,0.1142,0.0947,0.0807,0.0704,0.0625,0.0562,0.0449,0.0374,0.0320,0.0281,0.0251,0.0226,0.0190,0.0164,0.0145,0.0130,0.0118,0.0100,0.0088}, - {0.4074,0.2433,0.1976,0.1671,0.1444,0.1142,0.0946,0.0807,0.0703,0.0625,0.0562,0.0448,0.0373,0.0320,0.0281,0.0251,0.0226,0.0189,0.0164,0.0145,0.0129,0.0118,0.0100,0.0088}, - {0.4016,0.2444,0.1982,0.1674,0.1447,0.1144,0.0948,0.0808,0.0705,0.0625,0.0563,0.0449,0.0374,0.0321,0.0281,0.0251,0.0227,0.0190,0.0164,0.0145,0.0130,0.0118,0.0101,0.0088}, - {0.4523,0.2460,0.1996,0.1686,0.1457,0.1152,0.0954,0.0813,0.0709,0.0630,0.0567,0.0452,0.0377,0.0323,0.0283,0.0254,0.0229,0.0192,0.0167,0.0148,0.0132,0.0120,0.0103,0.0090}, - {0.4743,0.2464,0.2006,0.1699,0.1470,0.1162,0.0963,0.0821,0.0716,0.0636,0.0572,0.0457,0.0380,0.0326,0.0286,0.0256,0.0231,0.0193,0.0168,0.0148,0.0133,0.0121,0.0103,0.0091}, - {0.4410,0.2475,0.2010,0.1703,0.1473,0.1165,0.0966,0.0823,0.0717,0.0637,0.0573,0.0458,0.0381,0.0327,0.0286,0.0256,0.0231,0.0194,0.0168,0.0149,0.0133,0.0121,0.0104,0.0091}, - {0.7146,0.2499,0.2028,0.1717,0.1483,0.1173,0.0972,0.0828,0.0722,0.0642,0.0577,0.0461,0.0383,0.0329,0.0288,0.0258,0.0233,0.0195,0.0169,0.0150,0.0134,0.0122,0.0105,0.0092}, - {0.5429,0.2502,0.2032,0.1720,0.1485,0.1176,0.0974,0.0830,0.0724,0.0643,0.0578,0.0461,0.0384,0.0329,0.0289,0.0259,0.0234,0.0195,0.0170,0.0150,0.0135,0.0123,0.0105,0.0092}, - {0.5257,0.2464,0.2007,0.1705,0.1473,0.1166,0.0966,0.0823,0.0717,0.0638,0.0574,0.0457,0.0381,0.0327,0.0286,0.0256,0.0231,0.0194,0.0168,0.0149,0.0133,0.0121,0.0104,0.0091}, - {0.8706,0.2471,0.2014,0.1707,0.1476,0.1168,0.0968,0.0825,0.0719,0.0639,0.0574,0.0459,0.0382,0.0327,0.0287,0.0257,0.0232,0.0194,0.0169,0.0149,0.0134,0.0122,0.0104,0.0091}, - {1.0308,0.2499,0.2032,0.1721,0.1486,0.1176,0.0974,0.0831,0.0724,0.0643,0.0579,0.0462,0.0384,0.0329,0.0289,0.0259,0.0233,0.0196,0.0170,0.0150,0.0135,0.0123,0.0105,0.0092}, - {0.4280,0.2504,0.2037,0.1725,0.1489,0.1179,0.0976,0.0832,0.0725,0.0644,0.0580,0.0462,0.0385,0.0330,0.0289,0.0259,0.0234,0.0196,0.0170,0.0151,0.0135,0.0123,0.0106,0.0093}, - {0.3503,0.2596,0.2091,0.1769,0.1528,0.1209,0.1001,0.0852,0.0742,0.0660,0.0593,0.0474,0.0395,0.0339,0.0297,0.0267,0.0241,0.0202,0.0176,0.0157,0.0141,0.0129,0.0111,0.0098} }; - + {0.3212, 0.2390, 0.1932, 0.1630, 0.1410, 0.1115, 0.0923, 0.0787, 0.0686, 0.0608, 0.0546, 0.0436, 0.0363, 0.0312, 0.0273, 0.0243, 0.0220, 0.0184, 0.0159, 0.0140, 0.0126, 0.0114, 0.0097, 0.0084}, + {0.3209, 0.2395, 0.1938, 0.1636, 0.1416, 0.1119, 0.0926, 0.0791, 0.0689, 0.0611, 0.0549, 0.0438, 0.0365, 0.0313, 0.0274, 0.0245, 0.0221, 0.0185, 0.0160, 0.0141, 0.0126, 0.0115, 0.0097, 0.0085}, + {0.3231, 0.2409, 0.1951, 0.1646, 0.1423, 0.1125, 0.0930, 0.0794, 0.0692, 0.0613, 0.0551, 0.0440, 0.0366, 0.0314, 0.0276, 0.0246, 0.0222, 0.0186, 0.0161, 0.0142, 0.0127, 0.0115, 0.0098, 0.0086}, + {0.3208, 0.2403, 0.1950, 0.1646, 0.1424, 0.1126, 0.0931, 0.0795, 0.0693, 0.0614, 0.0552, 0.0441, 0.0367, 0.0315, 0.0276, 0.0246, 0.0222, 0.0186, 0.0161, 0.0142, 0.0127, 0.0116, 0.0098, 0.0086}, + {0.3230, 0.2420, 0.1960, 0.1655, 0.1432, 0.1131, 0.0936, 0.0798, 0.0696, 0.0617, 0.0554, 0.0442, 0.0369, 0.0316, 0.0277, 0.0247, 0.0223, 0.0187, 0.0162, 0.0143, 0.0128, 0.0116, 0.0099, 0.0087}, + {0.3265, 0.2439, 0.1976, 0.1665, 0.1442, 0.1139, 0.0941, 0.0803, 0.0700, 0.0620, 0.0557, 0.0445, 0.0370, 0.0318, 0.0279, 0.0249, 0.0224, 0.0188, 0.0163, 0.0144, 0.0129, 0.0117, 0.0100, 0.0087}, + {0.3212, 0.2418, 0.1962, 0.1658, 0.1436, 0.1135, 0.0939, 0.0802, 0.0698, 0.0619, 0.0556, 0.0444, 0.0370, 0.0317, 0.0278, 0.0248, 0.0224, 0.0188, 0.0163, 0.0144, 0.0129, 0.0117, 0.0100, 0.0087}, + {0.3240, 0.2433, 0.1976, 0.1667, 0.1444, 0.1141, 0.0943, 0.0805, 0.0702, 0.0622, 0.0559, 0.0446, 0.0372, 0.0319, 0.0280, 0.0249, 0.0225, 0.0189, 0.0164, 0.0144, 0.0130, 0.0118, 0.0100, 0.0088}, + {0.3268, 0.2455, 0.1990, 0.1680, 0.1455, 0.1148, 0.0950, 0.0809, 0.0706, 0.0626, 0.0562, 0.0448, 0.0374, 0.0321, 0.0281, 0.0251, 0.0226, 0.0190, 0.0165, 0.0146, 0.0131, 0.0119, 0.0101, 0.0089}, + {0.3312, 0.2480, 0.2011, 0.1698, 0.1468, 0.1158, 0.0957, 0.0817, 0.0712, 0.0631, 0.0566, 0.0452, 0.0376, 0.0323, 0.0283, 0.0253, 0.0228, 0.0192, 0.0166, 0.0147, 0.0132, 0.0120, 0.0103, 0.0090}, + {0.3222, 0.2436, 0.1981, 0.1675, 0.1449, 0.1146, 0.0948, 0.0808, 0.0705, 0.0625, 0.0561, 0.0448, 0.0373, 0.0320, 0.0281, 0.0250, 0.0226, 0.0190, 0.0164, 0.0145, 0.0131, 0.0119, 0.0101, 0.0089}, + {0.3250, 0.2453, 0.1993, 0.1684, 0.1458, 0.1153, 0.0953, 0.0813, 0.0708, 0.0628, 0.0564, 0.0450, 0.0375, 0.0322, 0.0282, 0.0252, 0.0227, 0.0191, 0.0165, 0.0146, 0.0131, 0.0120, 0.0102, 0.0089}, + {0.3277, 0.2473, 0.2010, 0.1698, 0.1469, 0.1160, 0.0960, 0.0818, 0.0713, 0.0632, 0.0568, 0.0453, 0.0378, 0.0324, 0.0284, 0.0253, 0.0229, 0.0193, 0.0167, 0.0147, 0.0133, 0.0121, 0.0103, 0.0090}, + {0.3321, 0.2502, 0.2032, 0.1714, 0.1484, 0.1171, 0.0968, 0.0826, 0.0719, 0.0637, 0.0572, 0.0457, 0.0381, 0.0327, 0.0287, 0.0256, 0.0231, 0.0194, 0.0168, 0.0149, 0.0134, 0.0122, 0.0105, 0.0092}, + {0.3374, 0.2539, 0.2060, 0.1738, 0.1503, 0.1185, 0.0979, 0.0834, 0.0727, 0.0644, 0.0579, 0.0462, 0.0385, 0.0330, 0.0290, 0.0259, 0.0234, 0.0197, 0.0171, 0.0151, 0.0136, 0.0124, 0.0106, 0.0094} }; float const cutPtInvMB2[15][24] = { - {0.5051,0.2637,0.2073,0.1728,0.1488,0.1162,0.0955,0.0818,0.0712,0.0627,0.0567,0.0454,0.0379,0.0328,0.0288,0.0259,0.0235,0.0200,0.0175,0.0156,0.0141,0.0130,0.0113,0.0101}, - {0.4895,0.2653,0.2095,0.1735,0.1500,0.1168,0.0960,0.0822,0.0715,0.0631,0.0570,0.0456,0.0381,0.0330,0.0289,0.0260,0.0236,0.0201,0.0176,0.0157,0.0142,0.0131,0.0114,0.0102}, - {0.5166,0.2649,0.2100,0.1739,0.1499,0.1171,0.0960,0.0823,0.0715,0.0632,0.0571,0.0456,0.0381,0.0331,0.0290,0.0261,0.0237,0.0201,0.0176,0.0158,0.0142,0.0132,0.0114,0.0102}, - {0.5505,0.2656,0.2094,0.1739,0.1498,0.1169,0.0961,0.0823,0.0717,0.0632,0.0572,0.0457,0.0382,0.0330,0.0290,0.0261,0.0236,0.0202,0.0176,0.0158,0.0142,0.0132,0.0114,0.0103}, - {0.4948,0.2661,0.2097,0.1748,0.1504,0.1172,0.0963,0.0824,0.0717,0.0633,0.0572,0.0457,0.0382,0.0331,0.0291,0.0262,0.0237,0.0202,0.0177,0.0158,0.0143,0.0132,0.0115,0.0103}, - {0.8226,0.2697,0.2117,0.1758,0.1517,0.1178,0.0971,0.0831,0.0722,0.0637,0.0576,0.0461,0.0386,0.0333,0.0293,0.0264,0.0240,0.0205,0.0179,0.0161,0.0145,0.0135,0.0118,0.0105}, - {0.6968,0.2717,0.2147,0.1778,0.1533,0.1194,0.0983,0.0838,0.0731,0.0644,0.0583,0.0467,0.0389,0.0338,0.0296,0.0268,0.0243,0.0208,0.0182,0.0164,0.0147,0.0137,0.0119,0.0108}, - {0.4571,0.2766,0.2147,0.1784,0.1535,0.1199,0.0981,0.0841,0.0731,0.0645,0.0583,0.0468,0.0390,0.0339,0.0298,0.0268,0.0243,0.0209,0.0183,0.0164,0.0148,0.0138,0.0120,0.0108}, - {0.3605,0.2750,0.2168,0.1799,0.1550,0.1207,0.0989,0.0849,0.0736,0.0650,0.0588,0.0471,0.0394,0.0341,0.0300,0.0271,0.0246,0.0211,0.0185,0.0167,0.0150,0.0140,0.0122,0.0110}, - {0.9221,0.2797,0.2169,0.1810,0.1551,0.1208,0.0992,0.0850,0.0739,0.0652,0.0588,0.0472,0.0394,0.0342,0.0301,0.0271,0.0247,0.0211,0.0186,0.0167,0.0151,0.0140,0.0123,0.0111}, - {0.8316,0.2724,0.2148,0.1786,0.1535,0.1195,0.0985,0.0842,0.0733,0.0647,0.0585,0.0468,0.0390,0.0339,0.0298,0.0268,0.0244,0.0209,0.0183,0.0164,0.0148,0.0138,0.0120,0.0108}, - {0.9734,0.2732,0.2154,0.1792,0.1542,0.1203,0.0985,0.0845,0.0733,0.0648,0.0586,0.0469,0.0391,0.0340,0.0298,0.0269,0.0244,0.0210,0.0184,0.0165,0.0149,0.0138,0.0121,0.0109}, - {0.8544,0.2810,0.2171,0.1804,0.1555,0.1207,0.0993,0.0851,0.0738,0.0652,0.0590,0.0472,0.0394,0.0343,0.0301,0.0272,0.0247,0.0212,0.0186,0.0168,0.0151,0.0140,0.0123,0.0111}, - {0.8574,0.2799,0.2174,0.1813,0.1557,0.1212,0.0993,0.0851,0.0741,0.0653,0.0590,0.0473,0.0396,0.0344,0.0302,0.0273,0.0248,0.0213,0.0187,0.0168,0.0152,0.0141,0.0124,0.0112}, - {0.8574,0.6947,0.5410,0.4498,0.3875,0.3013,0.2474,0.2122,0.1840,0.1626,0.1470,0.1177,0.0983,0.0854,0.0749,0.0676,0.0614,0.0527,0.0463,0.0417,0.0376,0.0349,0.0305,0.0275} }; + {0.3882, 0.2744, 0.2174, 0.1815, 0.1560, 0.1223, 0.1007, 0.0857, 0.0746, 0.0661, 0.0593, 0.0474, 0.0395, 0.0340, 0.0299, 0.0268, 0.0243, 0.0205, 0.0178, 0.0158, 0.0143, 0.0130, 0.0112, 0.0099}, + {0.3894, 0.2765, 0.2193, 0.1829, 0.1574, 0.1234, 0.1015, 0.0864, 0.0752, 0.0666, 0.0598, 0.0478, 0.0399, 0.0343, 0.0302, 0.0270, 0.0245, 0.0207, 0.0180, 0.0160, 0.0144, 0.0132, 0.0114, 0.0101}, + {0.3952, 0.2798, 0.2216, 0.1848, 0.1588, 0.1245, 0.1024, 0.0871, 0.0757, 0.0671, 0.0602, 0.0481, 0.0402, 0.0346, 0.0304, 0.0273, 0.0247, 0.0209, 0.0182, 0.0162, 0.0146, 0.0134, 0.0115, 0.0102}, + {0.3922, 0.2790, 0.2217, 0.1851, 0.1593, 0.1248, 0.1027, 0.0874, 0.0761, 0.0673, 0.0605, 0.0483, 0.0403, 0.0347, 0.0306, 0.0274, 0.0248, 0.0210, 0.0183, 0.0163, 0.0147, 0.0135, 0.0116, 0.0103}, + {0.3979, 0.2823, 0.2238, 0.1867, 0.1608, 0.1260, 0.1036, 0.0880, 0.0767, 0.0679, 0.0610, 0.0487, 0.0406, 0.0350, 0.0308, 0.0276, 0.0251, 0.0212, 0.0185, 0.0164, 0.0149, 0.0136, 0.0117, 0.0104}, + {0.4051, 0.2865, 0.2269, 0.1892, 0.1627, 0.1274, 0.1048, 0.0890, 0.0775, 0.0686, 0.0616, 0.0492, 0.0411, 0.0353, 0.0311, 0.0279, 0.0253, 0.0215, 0.0187, 0.0167, 0.0151, 0.0138, 0.0119, 0.0106}, + {0.3961, 0.2829, 0.2251, 0.1880, 0.1617, 0.1267, 0.1042, 0.0887, 0.0772, 0.0684, 0.0614, 0.0490, 0.0409, 0.0352, 0.0310, 0.0278, 0.0252, 0.0214, 0.0187, 0.0166, 0.0150, 0.0138, 0.0119, 0.0105}, + {0.4013, 0.2864, 0.2276, 0.1897, 0.1633, 0.1279, 0.1053, 0.0895, 0.0778, 0.0690, 0.0619, 0.0495, 0.0413, 0.0355, 0.0313, 0.0281, 0.0255, 0.0216, 0.0189, 0.0168, 0.0152, 0.0139, 0.0121, 0.0107}, + {0.4091, 0.2911, 0.2308, 0.1923, 0.1655, 0.1294, 0.1065, 0.0905, 0.0787, 0.0697, 0.0626, 0.0500, 0.0417, 0.0359, 0.0317, 0.0284, 0.0258, 0.0219, 0.0191, 0.0171, 0.0155, 0.0142, 0.0123, 0.0109}, + {0.4185, 0.2968, 0.2349, 0.1956, 0.1682, 0.1316, 0.1081, 0.0918, 0.0798, 0.0707, 0.0635, 0.0507, 0.0423, 0.0365, 0.0322, 0.0288, 0.0262, 0.0223, 0.0195, 0.0174, 0.0158, 0.0145, 0.0125, 0.0112}, + {0.4005, 0.2876, 0.2285, 0.1909, 0.1642, 0.1287, 0.1058, 0.0901, 0.0783, 0.0694, 0.0623, 0.0498, 0.0415, 0.0358, 0.0315, 0.0283, 0.0257, 0.0218, 0.0190, 0.0170, 0.0154, 0.0141, 0.0122, 0.0109}, + {0.4064, 0.2911, 0.2312, 0.1928, 0.1659, 0.1300, 0.1069, 0.0908, 0.0791, 0.0700, 0.0629, 0.0502, 0.0419, 0.0361, 0.0319, 0.0286, 0.0259, 0.0220, 0.0193, 0.0172, 0.0156, 0.0143, 0.0124, 0.0110}, + {0.4137, 0.2957, 0.2346, 0.1955, 0.1682, 0.1317, 0.1082, 0.0920, 0.0800, 0.0708, 0.0636, 0.0508, 0.0424, 0.0365, 0.0322, 0.0289, 0.0263, 0.0223, 0.0195, 0.0175, 0.0158, 0.0145, 0.0126, 0.0113}, + {0.4238, 0.3015, 0.2388, 0.1990, 0.1712, 0.1338, 0.1099, 0.0934, 0.0812, 0.0719, 0.0645, 0.0516, 0.0431, 0.0371, 0.0328, 0.0294, 0.0267, 0.0228, 0.0199, 0.0178, 0.0162, 0.0149, 0.0130, 0.0116}, + {0.4366, 0.3095, 0.2448, 0.2038, 0.1750, 0.1367, 0.1123, 0.0954, 0.0828, 0.0733, 0.0658, 0.0526, 0.0439, 0.0379, 0.0334, 0.0300, 0.0273, 0.0233, 0.0205, 0.0183, 0.0167, 0.0153, 0.0134, 0.0119} }; /// Class implementation class DTMatch : public DTMatchBase @@ -136,9 +135,9 @@ class DTMatch : public DTMatchBase /*** DT TRIGGER MOMENTUM PARAMETERISATION ***/ /// Return functions - int getDTPt(); - int getDTPtMin( float nSigmas ); - int getDTPtMax( float nSigmas ); + int getDTPt() const; + int getDTPtMin( float nSigmas ) const; + int getDTPtMax( float nSigmas ) const; /// Extrapolation of DT object to TK and Vtx void extrapolateToTrackerLayer( unsigned int aLayer ); /// This runs from 1 to N, as the DetId index diff --git a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc index 23b88898c22b7..1d18878a09c31 100644 --- a/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc +++ b/DataFormats/L1DTPlusTrackTrigger/src/DTMatch.cc @@ -175,7 +175,7 @@ DTMatch& DTMatch::operator = ( const DTMatch& aDTM ) /*** DT TRIGGER MOMENTUM PARAMETERISATION ***/ /// Return function for the parameterised Pt -int DTMatch::getDTPt() +int DTMatch::getDTPt() const { /// For high quality seeds, it comes from a fit to PhiB [int] as a function of Pt [GeV/c] /// PhiB [int] = A + B / Pt [GeV/c] @@ -199,7 +199,7 @@ int DTMatch::getDTPt() } /// Return function for the minimum allowed parameterised Pt -int DTMatch::getDTPtMin( float nSigmas ) +int DTMatch::getDTPtMin( float nSigmas ) const { /// For high quality seeds, it comes from a fit to PhiB [int] as a function of Pt [GeV/c] /// PhiB [int] = A + B / Pt [GeV/c] @@ -225,7 +225,7 @@ int DTMatch::getDTPtMin( float nSigmas ) } /// Return function for the maximum allowed parameterised Pt -int DTMatch::getDTPtMax( float nSigmas ) +int DTMatch::getDTPtMax( float nSigmas ) const { /// For high quality seeds, it comes from a fit to PhiB [int] as a function of Pt [GeV/c] /// PhiB [int] = A + B / Pt [GeV/c] @@ -237,13 +237,13 @@ int DTMatch::getDTPtMax( float nSigmas ) int iWh = this->getDTWheel() + 2; float thisPhiB = fabs( static_cast< float >(this->getDTTSPhiB()) ); float thisSigmaPhiB = this->getPredSigmaPhiB(); + float thisPhiBMin = thisPhiB - nSigmas * thisSigmaPhiB; /// By Station + 2*Wheel float B_Pt[10] = {-668.1, -433.6, -757.8, -524.7, -751.8, -539.5, -757.5, -525.6, -667.0, -435.0}; - if ( thisPhiB > 0.0 ) + if ( thisPhiBMin > 0.0 ) { - float thisPhiBMin = thisPhiB - nSigmas * thisSigmaPhiB; return static_cast< int >( fabs(B_Pt[iSt+2*iWh]) / thisPhiBMin + 1); } @@ -266,7 +266,16 @@ bool DTMatch::checkStubPhiMatch( int anotherPhi, unsigned int aLayer, float nSig bool DTMatch::checkStubThetaMatch( int anotherTheta, unsigned int aLayer, float nSigmas ) const { int deltaTheta = abs( this->getPredStubTheta( aLayer ) - anotherTheta ); - if ( deltaTheta < nSigmas * this->getPredStubSigmaTheta( aLayer ) ) + int dtStubSigmaTheta = this->getPredStubSigmaTheta( aLayer ); + + /// Check the theta flag (if false, rough theta is used, + /// and a wire-based correction has been set) + if ( !this->getThetaFlag() ) + { + dtStubSigmaTheta += this->getDeltaTheta(); + } + + if ( deltaTheta < nSigmas * dtStubSigmaTheta ) { return true; } @@ -835,10 +844,14 @@ unsigned int DTMatch::findPtBin( float aPtInv, unsigned int aMethod ) void DTMatch::findPtTTTrackBin() { /// Here's the curvature table +/* float cutPtInvTK[24] = { 0.2533,0.2026,0.1689,0.1448,0.1266,0.1014, 0.0845,0.0724,0.0634,0.0564,0.0508,0.0406,0.0339, 0.0291,0.0255,0.0227,0.0204,0.0171,0.0147,0.0129, 0.0115,0.0104,0.0087,0.0075 }; +*/ + + float const cutPtInvTK[24] = {0.2525, 0.2019, 0.1682, 0.1441, 0.1261, 0.1008, 0.0840, 0.0720, 0.0630, 0.0560, 0.0504, 0.0403, 0.0336, 0.0288, 0.0252, 0.0224, 0.0202, 0.0168, 0.0144, 0.0127, 0.0113, 0.0101, 0.0085, 0.0073}; /// Start by setting 0 as default value this->setPtTTTrackBin(binPt[0]); From 789502ecf45f4b339a838c0410c2b02ff8171112 Mon Sep 17 00:00:00 2001 From: Nicola Date: Thu, 19 Jun 2014 16:24:46 +0200 Subject: [PATCH 047/252] DT-Tk Trigger update (no analyzer) --- .../plugins/DTPlusTrackProducer.cc | 20 ++++++++++++++++--- .../plugins/DTPlusTrackProducer.h | 3 +++ .../python/DTPlusTrackProducer_cfi.py | 2 ++ .../src/DTUtilities_getDTTrigger.cc | 2 +- 4 files changed, 23 insertions(+), 4 deletions(-) diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc index 46ad104d30af8..6dac60e0b3d5a 100644 --- a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc +++ b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.cc @@ -28,6 +28,9 @@ DTPlusTrackProducer::DTPlusTrackProducer( const edm::ParameterSet& pSet ) : numSigmasTk = pSet.getUntrackedParameter< double >( "numSigmasForTkMatch", 3. ); numSigmasPt = pSet.getUntrackedParameter< double >( "numSigmasForPtMatch", 3. ); + /// Minimum Pt of L1 Tracks for matching + minL1TrackPt = pSet.getUntrackedParameter< double >( "minL1TrackPt", 2. ); + /// Get some constraints for finding the Pt with several methods minRInvB = pSet.getUntrackedParameter< double >( "minRInvB", 0.00000045 ); maxRInvB = pSet.getUntrackedParameter< double >( "maxRInvB", 1.0 ); @@ -365,7 +368,7 @@ std::cerr< > > allTracksInWindow; @@ -380,11 +383,19 @@ std::cerr< > tempTrackPtr( TTTrackHandle, jTrack++ ); /// Redundant Pt threshold - if ( inputIter->getMomentum().perp() < 2 ) + if ( inputIter->getMomentum().perp() < minL1TrackPt ) { continue; } + /// Additional quality cut + if ( inputIter->getChi2() >= 100 ) + continue; + if ( fabs(inputIter->getPOCA().z()) >= 25. ) + continue; + if ( inputIter->getStubRefs().size() < 3 ) + continue; + /// Check distance with the TTTrack GlobalVector tkMom = tempTrackPtr->getMomentum(); @@ -521,7 +532,10 @@ std::cerr<setPtMatchedTrackPtr( theClosestTrack ); + if ( minPtDifference < 999999 ) + { + thisDTMatch->setPtMatchedTrackPtr( theClosestTrack ); + } } #ifdef npDEBUG diff --git a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h index 4810b24fc4bd2..14bfdf82da7fa 100644 --- a/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h +++ b/L1Trigger/DTPlusTrackTrigger/plugins/DTPlusTrackProducer.h @@ -56,6 +56,9 @@ class DTPlusTrackProducer : public edm::EDProducer double numSigmasTk; double numSigmasPt; + /// Min Pt of L1Tracks for matching + double minL1TrackPt; + /// Some constraints for finding the Pt with several methods double minRInvB; double maxRInvB; diff --git a/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py b/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py index 21d36f29bfc19..2c8c0b0705611 100644 --- a/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py +++ b/L1Trigger/DTPlusTrackTrigger/python/DTPlusTrackProducer_cfi.py @@ -19,6 +19,8 @@ numSigmasForTkMatch = cms.untracked.double(3.), numSigmasForPtMatch = cms.untracked.double(3.), + minL1TrackPt = cms.untracked.double(2.), + minRInvB = cms.untracked.double( 0.00000045 ), maxRInvB = cms.untracked.double( 1.0 ), station2Correction = cms.untracked.double( 1.0 ), diff --git a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc index 239722a1c3c89..aaa58bca98cd1 100644 --- a/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc +++ b/L1Trigger/DTPlusTrackTrigger/src/DTUtilities_getDTTrigger.cc @@ -390,7 +390,7 @@ void DTUtilities::getDTTrigger() /// Leave the matched BTI Id to 0x0 /// Set needed data for correct extrapolation search and flag for missing theta - float deltaTheta = fabs( ( posFirstWire.theta() - posLastWire.theta() ) / 2. ); + float deltaTheta = fabs( ( posFirstWire.theta() - posLastWire.theta() ) / sqrt(12.) ); /// Error set to sigma of flat distribution aDTMatch->setThetaCorrection( deltaTheta ); if ( st == 1 || st == 2 ) From 5e490d1139f43202930bcfb064794675ff9d3fec Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 19 Jun 2014 18:09:45 +0200 Subject: [PATCH 048/252] added L1TkPhotonsTightIsol and L1CaloTauSequences_cfi.py --- .../python/L1CaloTauSequences_cfi.py | 30 ++++++++ .../python/L1TkEmParticleProducer_cfi.py | 4 ++ .../test/produce_L1TkObjects_cfg.py | 3 + .../test/test_L1TkTauFromCalo_cfg.py | 69 +++++++++++-------- 4 files changed, 76 insertions(+), 30 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py new file mode 100644 index 0000000000000..13e2745194112 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py @@ -0,0 +1,30 @@ +import FWCore.ParameterSet.Config as cms + +L1CaloTauCorrectionsProducer = cms.EDProducer("L1CaloTauCorrectionsProducer", + L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus") +) + +# Setup the L1TkTauFromCalo producer: +L1TkTauFromCaloProducer = cms.EDProducer("L1TkTauFromCaloProducer", + #L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus"), + L1TausInputTag = cms.InputTag("L1CaloTauCorrectionsProducer","CalibratedTaus"), + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + L1TkTrack_ApplyVtxIso = cms.bool( True ), # Produce vertex-isolated L1TkTaus? + L1TkTrack_VtxIsoZ0Max = cms.double( 1.0 ), # Max vertex z for L1TkTracks for VtxIsolation [cm] + L1TkTrack_NStubsMin = cms.uint32( 5 ), # Min number of stubs per L1TkTrack [unitless] + L1TkTrack_PtMin_AllTracks = cms.double( 2.0 ), # Min pT applied on all L1TkTracks [GeV] + L1TkTrack_PtMin_SignalTracks = cms.double( 10.0), # Min pT applied on signal L1TkTracks [GeV] + L1TkTrack_PtMin_IsoTracks = cms.double( 2.0 ), # Min pT applied on isolation L1TkTracks [GeV] + L1TkTrack_RedChiSquareEndcapMax = cms.double( 5.0 ), # Max red-chi squared for L1TkTracks in Endcap + L1TkTrack_RedChiSquareBarrelMax = cms.double( 2.0 ), # Max red-chi squared for L1TkTracks in Barrel + L1TkTrack_VtxZ0Max = cms.double( 30.0 ), # Max vertex z for L1TkTracks [cm] + DeltaR_L1TkTau_L1TkTrack = cms.double( 0.10 ), # Cone size for L1TkTracks assigned to L1TkTau + DeltaR_L1TkTauIsolation = cms.double( 0.40 ), # Isolation cone size for L1TkTau + DeltaR_L1TkTau_L1CaloTau = cms.double( 0.15 ), # Matching cone for L1TkTau and L1CaloTau + L1CaloTau_EtMin = cms.double( 5.0 ), # Min eT applied on all L1CaloTaus [GeV] + RemoveL1TkTauTracksFromIsoCalculation = cms.bool( False ), # Remove tracks used in L1TkTau construction from VtxIso calculation? +) + + +CaloTauSequence = cms.Sequence( L1CaloTauCorrectionsProducer + L1TkTauFromCaloProducer ) + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py index 48aec49de87fb..d1e585179cbf6 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmParticleProducer_cfi.py @@ -37,3 +37,7 @@ L1VertexInputTag = cms.InputTag("NotUsed"), # Used only when PrimaryVtxConstrain = True ) + +L1TkPhotonsTightIsol = L1TkPhotons.clone() +L1TkPhotonsTightIsol.IsoCut = cms.double( 0.10) + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py index d04671a81064a..ed2772142f41b 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py @@ -104,6 +104,9 @@ process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmParticleProducer_cfi") process.pL1TkPhotons = cms.Path( process.L1TkPhotons ) +# ---- "photons", tighter isolation working point - e.g. for SinglePhoton trigger +process.pL1TkPhotonsTightIsol = cms.Path( process.L1TkPhotonsTightIsol ) + # ---- "electrons" from L1Tracks. Inclusive electrons : process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkElectronTrackProducer_cfi") diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py index ba1b8ebd69c61..38c6722f3ba86 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py @@ -8,10 +8,10 @@ process = cms.Process("Tau") # -# This configuration runs over a file that contains the L1Tracks -# and the tracker digis. -# It creates L1TkTausFromCalo by clustering together high-pT L1Tracks +# This configuration creates L1TkTausFromCalo by clustering together high-pT L1Tracks # and matching them to stage-2 L1CaloTaus. +# Th1 L1Tracks are recreated at the beginning, to benefit from the latest +# L1Tracking improvements. # from SLHCUpgradeSimulations.L1TrackTrigger.singleTau1pFiles_cfi import * @@ -42,6 +42,23 @@ from Configuration.AlCa.GlobalTag import GlobalTag process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +# --------------------------------------------------------------------------- +# +# --- Recreate the L1Tracks to benefit from the latest updates +# + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.FullTrackingSequence ) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# -- the usual L1Calo stuff + # Load Sequences: (Check that the following are all needed) process.load("Configuration.StandardSequences.Services_cff") process.load("Configuration.StandardSequences.RawToDigi_Data_cff") ###check this for MC! @@ -71,38 +88,30 @@ process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") -# Produce calibrated (eT-corrected) L1CaloTaus: -process.L1CaloTauCorrectionsProducer = cms.EDProducer("L1CaloTauCorrectionsProducer", - L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus") -) +# --------------------------------------------------------------------------- + + + + +# ------------------------------------------------------------------------------ +# +# --- the caloTau producers : +# L1CaloTauCorrectionsProducer does a recalibration of the CaloTaus +# L1TkTauFromCaloProducer produces the Tk-matched CaloTaus + + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1CaloTauSequences_cfi") + +process.CaloTaus = cms.Path( process.CaloTauSequence ) + +# ------------------------------------------------------------------------------ + -# Setup the L1TkTauFromCalo producer: -process.L1TkTauFromCaloProducer = cms.EDProducer("L1TkTauFromCaloProducer", - #L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus"), - L1TausInputTag = cms.InputTag("L1CaloTauCorrectionsProducer","CalibratedTaus"), - L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), - L1TkTrack_ApplyVtxIso = cms.bool( True ), # Produce vertex-isolated L1TkTaus? - L1TkTrack_VtxIsoZ0Max = cms.double( 1.0 ), # Max vertex z for L1TkTracks for VtxIsolation [cm] - L1TkTrack_NStubsMin = cms.uint32( 5 ), # Min number of stubs per L1TkTrack [unitless] - L1TkTrack_PtMin_AllTracks = cms.double( 2.0 ), # Min pT applied on all L1TkTracks [GeV] - L1TkTrack_PtMin_SignalTracks = cms.double( 10.0), # Min pT applied on signal L1TkTracks [GeV] - L1TkTrack_PtMin_IsoTracks = cms.double( 2.0 ), # Min pT applied on isolation L1TkTracks [GeV] - L1TkTrack_RedChiSquareEndcapMax = cms.double( 5.0 ), # Max red-chi squared for L1TkTracks in Endcap - L1TkTrack_RedChiSquareBarrelMax = cms.double( 2.0 ), # Max red-chi squared for L1TkTracks in Barrel - L1TkTrack_VtxZ0Max = cms.double( 30.0 ), # Max vertex z for L1TkTracks [cm] - DeltaR_L1TkTau_L1TkTrack = cms.double( 0.10 ), # Cone size for L1TkTracks assigned to L1TkTau - DeltaR_L1TkTauIsolation = cms.double( 0.40 ), # Isolation cone size for L1TkTau - DeltaR_L1TkTau_L1CaloTau = cms.double( 0.15 ), # Matching cone for L1TkTau and L1CaloTau - L1CaloTau_EtMin = cms.double( 5.0 ), # Min eT applied on all L1CaloTaus [GeV] - RemoveL1TkTauTracksFromIsoCalculation = cms.bool( False ), # Remove tracks used in L1TkTau construction from VtxIso calculation? -) -process.pCorr = cms.Path( process.L1CaloTauCorrectionsProducer ) -process.pTaus = cms.Path( process.L1TkTauFromCaloProducer ) # Define the output module process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "output.root" ), #"L1TkTausFromCalo.root" + fileName = cms.untracked.string( "output.root" ), fastCloning = cms.untracked.bool( False ), outputCommands = cms.untracked.vstring( 'drop *') ) From c63fbbbc1c76837f05b8e1b0bc1af85ec72286ea Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 19 Jun 2014 19:07:43 +0200 Subject: [PATCH 049/252] update test_L1TkEGamma_cfg.py to include PhotonsTight --- .../L1TrackTrigger/test/test_L1TkEGamma_cfg.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py index 8816a0d00d7f0..6faa8c6ca2e4d 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py @@ -105,6 +105,10 @@ process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmParticleProducer_cfi") process.pL1TkPhotons = cms.Path( process.L1TkPhotons ) +# ---- "photons", tighter isolation working point - e.g. for SinglePhoton trigger +process.pL1TkPhotonsTightIsol = cms.Path( process.L1TkPhotonsTightIsol ) + + # ---- "electrons" from L1Tracks. Inclusive electrons : process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkElectronTrackProducer_cfi") From 6cb510a6c30a70c10d69c24877b88f879c4bd683 Mon Sep 17 00:00:00 2001 From: Louise Date: Fri, 20 Jun 2014 15:47:03 +0200 Subject: [PATCH 050/252] add track-stub pt consistency --- .../interface/StackedTrackerGeometry.h | 16 ++- .../interface/StubPtConsistency.h | 10 ++ .../L1TrackTrigger/plugins/L1TrackProducer.cc | 16 ++- .../L1TrackTrigger/src/StubPtConsistency.cc | 103 ++++++++++++++++++ .../L1TrackTrigger/test/L1TrackNtupleMaker.cc | 21 ++++ 5 files changed, 161 insertions(+), 5 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/interface/StubPtConsistency.h create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/src/StubPtConsistency.cc diff --git a/Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h b/Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h index 8a5d71ebf64cb..3e502698858d3 100644 --- a/Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h +++ b/Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h @@ -385,10 +385,13 @@ double StackedTrackerGeometry::findRoughPt( double aMagneticFieldStrength, const deltaPhi = 2*M_PI - deltaPhi; /// Return the rough Pt - return ( deltaRadius * mPtFactor / deltaPhi ); + double roughPt = deltaRadius * mPtFactor / deltaPhi; + if (roughPt > 10000.) roughPt = 9999.; + return roughPt; } else if (tempDetId.isEndcap()) { + /* /// Test approximated formula for Endcap stubs /// Check always to be consistent with HitMatchingAlgorithm_window2012.h double roughPt = innerPointRadius * innerPointRadius * mPtFactor / fabs(findAverageLocalPosition( stub->getClusterRef(0).get() ).x()) ; @@ -397,6 +400,17 @@ double StackedTrackerGeometry::findRoughPt( double aMagneticFieldStrength, const /// Return the rough Pt return roughPt; + */ + + double deltax = fabs(findAverageLocalPosition( stub->getClusterRef(0).get() ).x()-findAverageLocalPosition( stub->getClusterRef(1).get() ).x()) + -fabs((innerHitPosition.z()-outerHitPosition.z())/innerHitPosition.z())*fabs(findAverageLocalPosition( stub->getClusterRef(0).get() ).x()); + double deltaPhi = fabs(deltax)/innerPointRadius; + double deltaR = fabs(outerHitPosition.z()-innerHitPosition.z())*innerPointRadius/fabs(innerHitPosition.z()); + + /// Return the rough Pt + double roughPt = deltaR * mPtFactor / deltaPhi; + if (roughPt > 10000.) roughPt = 9999.; + return roughPt; } /// Default diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/interface/StubPtConsistency.h b/SLHCUpgradeSimulations/L1TrackTrigger/interface/StubPtConsistency.h new file mode 100644 index 0000000000000..54b3d566184d5 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/interface/StubPtConsistency.h @@ -0,0 +1,10 @@ +#ifndef StubPtConsistency_HH +#define StubPtConsistency_HH + +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + +namespace StubPtConsistency { + float getConsistency(TTTrack< Ref_PixelDigi_ > aTrack, const StackedTrackerGeometry* theStackedGeometry, double mMagneticFieldStrength, int nPar); +} +#endif diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc index 6b28fcdfd40c8..a0b954c183f31 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackProducer.cc @@ -90,6 +90,8 @@ #include "DataFormats/GeometryCommonDetAlgo/interface/MeasurementVector.h" #include "DataFormats/GeometrySurface/interface/BoundPlane.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/StubPtConsistency.h" + ////////////// // STD HEADERS #include @@ -480,7 +482,7 @@ void L1TrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) aTrack.setChi2(track.chisq4par(),4); - + //Now do the 5 parameter fit GlobalPoint bsPosition5par(track.d0()*cos(track.phi0()),-track.d0()*sin(track.phi0()),track.z0()); @@ -498,9 +500,6 @@ void L1TrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) aTrack.setRInv(track.rinv(),5); aTrack.setChi2(track.chisq(),5); - - - vector stubs = track.getStubs(); @@ -530,6 +529,15 @@ void L1TrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) } } + + // pt consistency + float consistency4par = StubPtConsistency::getConsistency(aTrack, theStackedGeometry, mMagneticFieldStrength, 4); + aTrack.setStubPtConsistency(consistency4par, 4); + + float consistency5par = StubPtConsistency::getConsistency(aTrack, theStackedGeometry, mMagneticFieldStrength, 5); + aTrack.setStubPtConsistency(consistency5par,5); + + L1TkTracksForOutput->push_back(aTrack); } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/src/StubPtConsistency.cc b/SLHCUpgradeSimulations/L1TrackTrigger/src/StubPtConsistency.cc new file mode 100644 index 0000000000000..18be0210e76e7 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/src/StubPtConsistency.cc @@ -0,0 +1,103 @@ +#include +#include +//#include + +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/StubPtConsistency.h" + +namespace StubPtConsistency { + + float getConsistency(TTTrack< Ref_PixelDigi_ > aTrack, const StackedTrackerGeometry* theStackedGeometry, double mMagneticFieldStrength, int nPar) { + + double m_ptconsist = 0.0; + + if ( !(nPar==4 || nPar==5)) { + std::cerr << "Not a valid nPar option!" << std::endl; + return m_ptconsist; + } + + + // ---------------------------------------------------------------------------------------------------------- + // define stub 1/pt RMS for different regions + // ---------------------------------------------------------------------------------------------------------- + + const int nREGION = 3; //barrel, outer disks (dR>60cm), inner disks (dR<60cm) + const int nLAYER = 6; + + double rms_stub[nREGION][nLAYER] = { + {0.12, 0.12, 0.10, 0.07, 0.06, 0.06}, //barrel + {0.08, 0.09, 0.09, 0.10, 0.10, 1.0}, //endcap, outer part of disks, dR>60cm (no layer6) + {0.21, 0.23, 0.22, 0.21, 0.21, 1.0} //endcap, inner part of disks, dR<60cm (no layer6) + }; + + + // ---------------------------------------------------------------------------------------------------------- + // get charged track pt + // ---------------------------------------------------------------------------------------------------------- + + double this_trk_pt = aTrack.getMomentum(nPar).perp(); + + double this_trk_ptsign = 1.0; + if (aTrack.getRInv(nPar) < 0) this_trk_ptsign = -1.0; + + this_trk_pt = this_trk_pt*this_trk_ptsign; + + + // ---------------------------------------------------------------------------------------------------------- + // loop over stubs + // ---------------------------------------------------------------------------------------------------------- + + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubRefs = aTrack.getStubRefs(); + + for (unsigned int iStub=0; iStubgetDetId() ); + GlobalPoint posStub = theStackedGeometry->findGlobalPosition( &(*theStubRefs.at(iStub)) ); + + float dR = fabs(posStub.x()*posStub.x() + posStub.y()*posStub.y()); + int iRegion = 0; + if (thisDetId.isEndcap() && (dR > 60.0) ) iRegion = 1; + else if (thisDetId.isEndcap()) iRegion = 2; + + int iLayer = 0; + if (thisDetId.isBarrel()) iLayer = thisDetId.iLayer()-1; + else iLayer = thisDetId.iDisk()-1; + + + // read stub invPt RMS + double this_stub_rms = rms_stub[iRegion][iLayer]; + + + // read signed stub pt + double this_stub_pt = (double)theStackedGeometry->findRoughPt(mMagneticFieldStrength,&(*theStubRefs.at(iStub))); + + double this_stub_ptsign = 1.0; + double trigBend = theStubRefs.at(iStub)->getTriggerBend(); + + if (thisDetId.isEndcap() && (posStub.z() > 0)) { + if (trigBend>0) this_stub_ptsign = (-1)*this_stub_ptsign; + } + else { + if (trigBend<0) this_stub_ptsign = (-1)*this_stub_ptsign; + } + + this_stub_pt = this_stub_pt*this_stub_ptsign; + + if ( this_stub_pt == 0 ) { + std::cerr << "Could not calculate track-stub pt consistency!" << std::endl; + m_ptconsist = 0.0; + break; + } + + // add to variable + m_ptconsist += (1.0/this_trk_pt - 1.0/this_stub_pt)*(1.0/this_trk_pt - 1.0/this_stub_pt)/(this_stub_rms*this_stub_rms); + + }// end loop over stubs + // ---------------------------------------------------------------------------------------------------------- + + // return value + return m_ptconsist; + + } + +} diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc index 9817e9a6063c9..927aabb78b150 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackNtupleMaker.cc @@ -104,6 +104,7 @@ class L1TrackNtupleMaker : public edm::EDAnalyzer std::vector* m_trk_phi; std::vector* m_trk_z0; std::vector* m_trk_chi2; + std::vector* m_trk_consistency; std::vector* m_trk_nstub; std::vector* m_trk_genuine; std::vector* m_trk_unknown; @@ -124,6 +125,7 @@ class L1TrackNtupleMaker : public edm::EDAnalyzer std::vector* m_matchtrk_phi; std::vector* m_matchtrk_z0; std::vector* m_matchtrk_chi2; + std::vector* m_matchtrk_consistency; std::vector* m_matchtrk_nstub; std::vector* m_matchtrk_genuine; @@ -134,6 +136,7 @@ class L1TrackNtupleMaker : public edm::EDAnalyzer std::vector* m_matchtrk5p_z0; std::vector* m_matchtrk5p_d0; std::vector* m_matchtrk5p_chi2; + std::vector* m_matchtrk5p_consistency; }; @@ -190,6 +193,7 @@ void L1TrackNtupleMaker::beginJob() m_trk_phi = new std::vector; m_trk_z0 = new std::vector; m_trk_chi2 = new std::vector; + m_trk_consistency = new std::vector; m_trk_nstub = new std::vector; m_trk_genuine = new std::vector; m_trk_unknown = new std::vector; @@ -208,6 +212,7 @@ void L1TrackNtupleMaker::beginJob() m_matchtrk_phi = new std::vector; m_matchtrk_z0 = new std::vector; m_matchtrk_chi2 = new std::vector; + m_matchtrk_consistency = new std::vector; m_matchtrk_nstub = new std::vector; m_matchtrk_genuine = new std::vector; @@ -217,6 +222,7 @@ void L1TrackNtupleMaker::beginJob() m_matchtrk5p_z0 = new std::vector; m_matchtrk5p_d0 = new std::vector; m_matchtrk5p_chi2 = new std::vector; + m_matchtrk5p_consistency = new std::vector; // ntuple @@ -227,6 +233,7 @@ void L1TrackNtupleMaker::beginJob() eventTree->Branch("trk_phi", &m_trk_phi); eventTree->Branch("trk_z0", &m_trk_z0); eventTree->Branch("trk_chi2", &m_trk_chi2); + eventTree->Branch("trk_consistency", &m_trk_consistency); eventTree->Branch("trk_nstub", &m_trk_nstub); eventTree->Branch("trk_genuine", &m_trk_genuine); eventTree->Branch("trk_unknown", &m_trk_unknown); @@ -245,6 +252,7 @@ void L1TrackNtupleMaker::beginJob() eventTree->Branch("matchtrk_phi", &m_matchtrk_phi); eventTree->Branch("matchtrk_z0", &m_matchtrk_z0); eventTree->Branch("matchtrk_chi2", &m_matchtrk_chi2); + eventTree->Branch("matchtrk_consistency", &m_matchtrk_consistency); eventTree->Branch("matchtrk_nstub", &m_matchtrk_nstub); eventTree->Branch("matchtrk_genuine", &m_matchtrk_genuine); @@ -254,6 +262,7 @@ void L1TrackNtupleMaker::beginJob() eventTree->Branch("matchtrk5p_z0", &m_matchtrk5p_z0); eventTree->Branch("matchtrk5p_d0", &m_matchtrk5p_d0); eventTree->Branch("matchtrk5p_chi2", &m_matchtrk5p_chi2); + eventTree->Branch("matchtrk5p_consistency", &m_matchtrk5p_consistency); } @@ -275,6 +284,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_trk_phi->clear(); m_trk_z0->clear(); m_trk_chi2->clear(); + m_trk_consistency->clear(); m_trk_nstub->clear(); m_trk_genuine->clear(); m_trk_unknown->clear(); @@ -293,6 +303,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_matchtrk_phi->clear(); m_matchtrk_z0->clear(); m_matchtrk_chi2->clear(); + m_matchtrk_consistency->clear(); m_matchtrk_nstub->clear(); m_matchtrk_genuine->clear(); @@ -302,6 +313,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_matchtrk5p_z0->clear(); m_matchtrk5p_d0->clear(); m_matchtrk5p_chi2->clear(); + m_matchtrk5p_consistency->clear(); @@ -346,6 +358,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup float tmp_trk_phi = iterL1Track->getMomentum().phi(); float tmp_trk_z0 = iterL1Track->getPOCA().z(); //cm float tmp_trk_chi2 = iterL1Track->getChi2(); + float tmp_trk_consistency = iterL1Track->getStubPtConsistency(); int tmp_trk_nstub = (int) iterL1Track->getStubRefs().size(); if (tmp_trk_pt < 2.0) continue; @@ -370,6 +383,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_trk_phi->push_back(tmp_trk_phi); m_trk_z0 ->push_back(tmp_trk_z0); m_trk_chi2 ->push_back(tmp_trk_chi2); + m_trk_consistency->push_back(tmp_trk_consistency); m_trk_nstub->push_back(tmp_trk_nstub); m_trk_genuine->push_back(tmp_trk_genuine); m_trk_unknown->push_back(tmp_trk_unknown); @@ -467,6 +481,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup << " eta = " << matchedTracks.at(it)->getMomentum().eta() << " phi = " << matchedTracks.at(it)->getMomentum().phi() << " chi2 = " << matchedTracks.at(it)->getChi2() + << " consistency = " << matchedTracks.at(it)->getStubPtConsistency() << " z0 = " << matchedTracks.at(it)->getPOCA().z() << " nstub = " << matchedTracks.at(it)->getStubRefs().size(); if (tmp_trk_genuine) cout << " (genuine!) " << endl; @@ -503,6 +518,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup float tmp_matchtrk_phi = -999; float tmp_matchtrk_z0 = -999; float tmp_matchtrk_chi2 = -999; + float tmp_matchtrk_consistency = -999; int tmp_matchtrk_nstub = -999; int tmp_matchtrk_genuine = -999; @@ -512,6 +528,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup float tmp_matchtrk5p_z0 = -999; float tmp_matchtrk5p_d0 = -999; float tmp_matchtrk5p_chi2 = -999; + float tmp_matchtrk5p_consistency = -999; if (nMatch > 1) cout << "WARNING *** 2 or more matches to genuine L1 tracks ***" << endl; @@ -521,6 +538,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup tmp_matchtrk_phi = matchedTracks.at(i_track)->getMomentum().phi(); tmp_matchtrk_z0 = matchedTracks.at(i_track)->getPOCA().z(); tmp_matchtrk_chi2 = matchedTracks.at(i_track)->getChi2(); + tmp_matchtrk_consistency = matchedTracks.at(i_track)->getStubPtConsistency(); tmp_matchtrk_nstub = (int) matchedTracks.at(i_track)->getStubRefs().size(); tmp_matchtrk_genuine = 1; @@ -535,6 +553,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup tmp_matchtrk5p_d0 = matchedTracks.at(i_track)->getPOCA(5).perp()*sign; tmp_matchtrk5p_chi2 = matchedTracks.at(i_track)->getChi2(5); + tmp_matchtrk5p_consistency = matchedTracks.at(i_track)->getStubPtConsistency(5); } m_tp_pt->push_back(tmp_tp_pt); @@ -550,6 +569,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_matchtrk_phi->push_back(tmp_matchtrk_phi); m_matchtrk_z0 ->push_back(tmp_matchtrk_z0); m_matchtrk_chi2 ->push_back(tmp_matchtrk_chi2); + m_matchtrk_consistency->push_back(tmp_matchtrk_consistency); m_matchtrk_nstub->push_back(tmp_matchtrk_nstub); m_matchtrk_genuine->push_back(tmp_matchtrk_genuine); @@ -559,6 +579,7 @@ void L1TrackNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup m_matchtrk5p_z0 ->push_back(tmp_matchtrk5p_z0); m_matchtrk5p_d0 ->push_back(tmp_matchtrk5p_d0); m_matchtrk5p_chi2->push_back(tmp_matchtrk5p_chi2); + m_matchtrk5p_consistency->push_back(tmp_matchtrk5p_consistency); } //end loop tracking particles From f02667042594de2ca7d08c723a239ece1dd5e015 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Fri, 20 Jun 2014 19:09:03 -0500 Subject: [PATCH 051/252] set also DT and RPC candidates, minor refactoring --- .../src/L1MuonParticleExtendedProducer.cc | 110 +++++++++++------- 1 file changed, 67 insertions(+), 43 deletions(-) diff --git a/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc index 6ebdf1933ac6f..63245d74de81b 100644 --- a/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc +++ b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc @@ -47,6 +47,10 @@ class L1MuonParticleExtendedProducer : public edm::EDProducer { private: virtual void produce(edm::Event&, const edm::EventSetup&); + //some helper functions + float getSigmaEta(float eta, float etaP, float etaM) const; + float getSigmaPhi(float phi, float phiP, float phiM) const; + edm::InputTag gmtROSource_ ; edm::InputTag csctfSource_ ; @@ -114,7 +118,15 @@ L1MuonParticleExtendedProducer::produce( edm::Event& iEvent, int curMuCollIdx = -1; //index of the GMT-based for (auto gmtRO : gmtROs.getRecords()){ vector cscGmtIdxs(4,-1); //index into muColl for a given CSC cand - for (auto const gmtCand : gmtRO.getGMTCands() ){ + vector dtGmtIdxs(4,-1); //index into muColl for a given DT cand + + auto const gmtCands = gmtRO.getGMTCands(); + auto const dtCands = gmtRO.getDTBXCands(); + auto const cscCands = gmtRO.getCSCCands(); + auto const rpcBrlCands = gmtRO.getBrlRPCCands(); + auto const rpcFwdCands = gmtRO.getFwdRPCCands(); + + for (auto const gmtCand : gmtCands){ if (gmtCand.empty()) continue; float pt = muPtScale->getPtScale()->getLowEdge( gmtCand.ptIndex() ) + 1.e-6 ; @@ -131,39 +143,40 @@ L1MuonParticleExtendedProducer::produce( edm::Event& iEvent, math::PtEtaPhiMLorentzVector p4( pt, eta, phi, muonMassGeV_); L1MuonParticle l1muP(gmtCand.charge(), p4, gmtCand, gmtCand.bx()); int cscGmtIdx = -1; - if (!gmtCand.isRPC() && gmtCand.isFwd()) cscGmtIdx = gmtCand.getDTCSCIndex(); + if ((!gmtCand.isRPC()) && gmtCand.isFwd()) cscGmtIdx = gmtCand.getDTCSCIndex(); + int dtGmtIdx = -1; + if ((!gmtCand.isRPC()) && (!gmtCand.isFwd())) dtGmtIdx = gmtCand.getDTCSCIndex(); + int rpcGmtIdx = -1; + if (gmtCand.isRPC()) rpcGmtIdx = gmtCand.getRPCIndex(); muColl->push_back(L1MuonParticleExtended(l1muP)); curMuCollIdx++; if (cscGmtIdx>=0) cscGmtIdxs[cscGmtIdx] = curMuCollIdx; + if (dtGmtIdx>=0) dtGmtIdxs[dtGmtIdx] = curMuCollIdx; L1MuonParticleExtended* aGmtCand = &muColl->back(); - float sigmaEta=99; - float dEtaP = std::abs(etaP - eta); - float dEtaM = std::abs(etaM - eta); - if (dEtaP < 1 && dEtaM < 1 && dEtaP > 0 && dEtaM > 0){ - sigmaEta = sqrt(dEtaP*dEtaM); //take geom mean for no particular reason - } else if (dEtaP < 1 || dEtaM < 1) { - sigmaEta = dEtaP < dEtaM && dEtaP >0 ? dEtaP : dEtaM; - } - sigmaEta = sigmaEta/sqrt(12.); - - float sigmaPhi=99; - float dPhiP = std::abs(deltaPhi(phiP, phi)); - float dPhiM = std::abs(deltaPhi(phiM, phi)); - if (dPhiP < 1 && dPhiM < 1 && dPhiP > 0 && dPhiM > 0){ - sigmaPhi = sqrt(dPhiP*dPhiM); //take geom mean for no particular reason - } else if (dPhiP < 1 || dPhiM < 1) { - sigmaPhi = dPhiP < dPhiM && dPhiP > 0 ? dPhiP : dPhiM; - } - sigmaPhi = sigmaPhi/sqrt(12.); + float sigmaEta = getSigmaEta(eta, etaP, etaM); + float sigmaPhi = getSigmaPhi(phi, phiP, phiM); aGmtCand->setSigmaEta(sigmaEta); aGmtCand->setSigmaPhi(sigmaPhi); aGmtCand->setQuality(gmtCand.quality()); - + + //set regional candidates known to this GMT candidate here + if (dtGmtIdx>=0) aGmtCand->setDtCand(dtCands.at(dtGmtIdx)); //use .at, don't really trust the size + if (cscGmtIdx>=0) aGmtCand->setCscCand(cscCands.at(cscGmtIdx)); + if (rpcGmtIdx>=0){ + if (gmtCand.isFwd()) aGmtCand->setRpcCand(rpcFwdCands.at(rpcGmtIdx)); + else aGmtCand->setRpcCand(rpcBrlCands.at(rpcGmtIdx)); + } } - if (1< 2){ //at the moment this is not really "ALL", just up to 4 from CSCTF + // I fill station level data derived from different kind of regional candidates below + // this data is filled for both the GMT candidate and the regional candidates before GMT sorting + // to avoid copy-paste, gmt-driven cands (started in the loop above) are modified below + // only CSCTF details are filled in full + + // The intent is to create one L1MuExtended for each CSCTF track available + if (1< 2){ //at the moment this is not really "ALL", just up to 4 from CSCTF showing up in the GMTReadoutRecord unsigned cscInd = -1; for (auto const csctfReg : gmtRO.getCSCCands() ){ cscInd++; @@ -189,29 +202,11 @@ L1MuonParticleExtendedProducer::produce( edm::Event& iEvent, L1MuonParticleExtended cscParticleTmp(l1muP); cscParticleTmp.setCscCand(csctfReg); - if (gmtParticle) gmtParticle->setCscCand(csctfReg); cscColl->push_back(cscParticleTmp); L1MuonParticleExtended* cscParticle = &cscColl->back(); - float sigmaEta=99; - float dEtaP = std::abs(etaP - eta); - float dEtaM = std::abs(etaM - eta); - if (dEtaP < 1 && dEtaM < 1 && dEtaP > 0 && dEtaM > 0){ - sigmaEta = sqrt(dEtaP*dEtaM); //take geom mean for no particular reason - } else if (dEtaP < 1 || dEtaM < 1) { - sigmaEta = dEtaP < dEtaM && dEtaP >0 ? dEtaP : dEtaM; - } - sigmaEta = sigmaEta/sqrt(12.); - - float sigmaPhi=99; - float dPhiP = std::abs(deltaPhi(phiP, phi)); - float dPhiM = std::abs(deltaPhi(phiM, phi)); - if (dPhiP < 1 && dPhiM < 1 && dPhiP > 0 && dPhiM > 0){ - sigmaPhi = sqrt(dPhiP*dPhiM); //take geom mean for no particular reason - } else if (dPhiP < 1 || dPhiM < 1) { - sigmaPhi = dPhiP < dPhiM && dPhiP > 0 ? dPhiP : dPhiM; - } - sigmaPhi = sigmaPhi/sqrt(12.); + float sigmaEta = getSigmaEta(eta, etaP, etaM); + float sigmaPhi = getSigmaPhi(phi, phiP, phiM); cscParticle->setSigmaEta(sigmaEta); cscParticle->setSigmaPhi(sigmaPhi); @@ -312,6 +307,35 @@ L1MuonParticleExtendedProducer::produce( edm::Event& iEvent, if (writeAllCSCTFs_) iEvent.put( cscColl, "csc" ); } +float L1MuonParticleExtendedProducer::getSigmaEta(float eta, float etaP, float etaM) const{ + float sigmaEta=99; + + float dEtaP = std::abs(etaP - eta); + float dEtaM = std::abs(etaM - eta); + if (dEtaP < 1 && dEtaM < 1 && dEtaP > 0 && dEtaM > 0){ + sigmaEta = sqrt(dEtaP*dEtaM); //take geom mean for no particular reason + } else if (dEtaP < 1 || dEtaM < 1) { + sigmaEta = dEtaP < dEtaM && dEtaP >0 ? dEtaP : dEtaM; + } + + sigmaEta = sigmaEta/sqrt(12.); + + return sigmaEta; +} + +float L1MuonParticleExtendedProducer::getSigmaPhi(float phi, float phiP, float phiM) const{ + float sigmaPhi=99; + float dPhiP = std::abs(deltaPhi(phiP, phi)); + float dPhiM = std::abs(deltaPhi(phiM, phi)); + if (dPhiP < 1 && dPhiM < 1 && dPhiP > 0 && dPhiM > 0){ + sigmaPhi = sqrt(dPhiP*dPhiM); //take geom mean for no particular reason + } else if (dPhiP < 1 || dPhiM < 1) { + sigmaPhi = dPhiP < dPhiM && dPhiP > 0 ? dPhiP : dPhiM; + } + sigmaPhi = sigmaPhi/sqrt(12.); + + return sigmaPhi; +} //define this as a plug-in DEFINE_FWK_MODULE(L1MuonParticleExtendedProducer); From 00bebf00b6eaed424f45ddcf4331cb1036684052 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Fri, 20 Jun 2014 19:30:16 -0500 Subject: [PATCH 052/252] add an option to use the 5-parameter fit of the tracks in making the L1TkMus --- .../plugins/L1TkMuonFromExtendedProducer.cc | 29 ++++++++++++++----- .../L1TrackTrigger/python/l1TkMuonsExt_cfi.py | 3 +- 2 files changed, 23 insertions(+), 9 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc index c8871bd44064f..39a63c76185f3 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkMuonFromExtendedProducer.cc @@ -90,6 +90,7 @@ class L1TkMuonFromExtendedProducer : public edm::EDProducer { // bool closest_ ; bool correctGMTPropForTkZ_; + bool use5ParameterFit_; } ; @@ -114,6 +115,7 @@ L1TkMuonFromExtendedProducer::L1TkMuonFromExtendedProducer(const edm::ParameterS correctGMTPropForTkZ_ = iConfig.getParameter("correctGMTPropForTkZ"); + use5ParameterFit_ = iConfig.getParameter("use5ParameterFit"); produces(); } @@ -175,6 +177,11 @@ L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& //apply something specific here } + const auto& rpcCand = l1mu.rpcCand(); + if (!rpcCand.empty()){ + //apply something specific here + } + float drmin = 999; float ptmax = -1; if (ptmax < 0) ptmax = -1; // dummy @@ -186,20 +193,23 @@ L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& LogDebug("MDEBUG")<<"have a gmt, look for a match "; for (auto l1tk : l1tks ){ il1tk++; - float l1tk_pt = l1tk.getMomentum().perp(); + + unsigned int nPars = 4; + if (use5ParameterFit_) nPars = 5; + float l1tk_pt = l1tk.getMomentum(nPars).perp(); if (l1tk_pt < PTMINTRA_) continue; - float l1tk_z = l1tk.getPOCA().z(); + float l1tk_z = l1tk.getPOCA(nPars).z(); if (fabs(l1tk_z) > ZMAX_) continue; - float l1tk_chi2 = l1tk.getChi2(); + float l1tk_chi2 = l1tk.getChi2(nPars); if (l1tk_chi2 > CHI2MAX_) continue; int l1tk_nstubs = l1tk.getStubRefs().size(); if ( l1tk_nstubs < nStubsmin_) continue; - float l1tk_eta = l1tk.getMomentum().eta(); - float l1tk_phi = l1tk.getMomentum().phi(); + float l1tk_eta = l1tk.getMomentum(nPars).eta(); + float l1tk_phi = l1tk.getMomentum(nPars).phi(); float dr2 = deltaR2(l1mu_eta, l1mu_phi, l1tk_eta, l1tk_phi); @@ -232,15 +242,18 @@ L1TkMuonFromExtendedProducer::produce(edm::Event& iEvent, const edm::EventSetup& <<" mutk "< l1tkPtr(l1tksH, match_idx); - auto p3 = matchTk.getMomentum(); + + unsigned int nPars = 4; + if (use5ParameterFit_) nPars = 5; + auto p3 = matchTk.getMomentum(nPars); float p4e = sqrt(0.105658369*0.105658369 + p3.mag2() ); math::XYZTLorentzVector l1tkp4(p3.x(), p3.y(), p3.z(), p4e); - auto tkv3=matchTk.getPOCA(); + auto tkv3=matchTk.getPOCA(nPars); math::XYZPoint v3(tkv3.x(), tkv3.y(), tkv3.z()); float trkisol = -999; - int l1tk_q = matchTk.getRInv()>0? 1: -1; + int l1tk_q = matchTk.getRInv(nPars)>0? 1: -1; L1TkMuonParticle l1tkmu(reco::LeafCandidate(l1tk_q, l1tkp4, v3, -13*l1tk_q )); l1tkmu.setTrkPtr(l1tkPtr); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py index 7b1baad9c89d2..b3ad0aeed1ce0 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/l1TkMuonsExt_cfi.py @@ -12,7 +12,8 @@ # DRmax = cms.double( 0.5 ), nStubsmin = cms.int32( 3 ), # minimum number of stubs # closest = cms.bool( True ), - correctGMTPropForTkZ = cms.bool(True) + correctGMTPropForTkZ = cms.bool(True), + use5ParameterFit = cms.bool(False) #use 4-pars by defaults ) From 1c5ccc0c74eaaf9af4bd5435a919fd07f32392d0 Mon Sep 17 00:00:00 2001 From: Slava Krutelyov Date: Mon, 23 Jun 2014 11:23:16 -0500 Subject: [PATCH 053/252] set phi bend from gemDPhi --- .../L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc index 63245d74de81b..13627871bc92f 100644 --- a/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc +++ b/L1Trigger/L1ExtraFromDigis/src/L1MuonParticleExtendedProducer.cc @@ -290,6 +290,8 @@ L1MuonParticleExtendedProducer::produce( edm::Event& iEvent, sData.sigmaPhi = dPhi/sqrt(12.); //just the roundoff uncertainty (could be worse) sData.sigmaEta = dEta/sqrt(12.); + sData.bendPhi = aDigi->getGEMDPhi(); //FIXME: need something in normal global coordinates + sData.bendPhiInt = aDigi->getCLCTPattern(); if (aDigi->getBend()) sData.bendPhiInt*=-1; } //LCTs for a given anID From fc9a2f7f8e3afcdb94204082c59d357cccdb64aa Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Fri, 20 Jun 2014 12:42:18 -0500 Subject: [PATCH 054/252] Made endcap usage a tracked parameter, small performance bugfix. --- .../plugins/L1EGammaCrystalsProducer.cc | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index 8faf3936c24da..bc34b1d77d5c7 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -124,7 +124,7 @@ class L1EGCrystalClusterProducer : public edm::EDProducer { L1EGCrystalClusterProducer::L1EGCrystalClusterProducer(const edm::ParameterSet& iConfig) : EtminForStore(iConfig.getParameter("EtminForStore")), debug(iConfig.getUntrackedParameter("debug", false)), - useECalEndcap(iConfig.getUntrackedParameter("useECalEndcap", false)) + useECalEndcap(iConfig.getParameter("useECalEndcap")) { produces("EGCrystalCluster"); produces("EGammaCrystal"); @@ -151,7 +151,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet // using RecHits (https://cmssdt.cern.ch/SDT/doxygen/CMSSW_6_1_2_SLHC6/doc/html/d8/dc9/classEcalRecHit.html) edm::Handle pcalohits; iEvent.getByLabel("ecalRecHit","EcalRecHitsEB",pcalohits); - for(auto hit : *pcalohits.product()) + for(auto& hit : *pcalohits.product()) { if(hit.energy() > 0.2) { @@ -173,7 +173,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet // using RecHits (https://cmssdt.cern.ch/SDT/doxygen/CMSSW_6_1_2_SLHC6/doc/html/d8/dc9/classEcalRecHit.html) edm::Handle pcalohitsEndcap; iEvent.getByLabel("ecalRecHit","EcalRecHitsEE",pcalohitsEndcap); - for(auto hit : *pcalohitsEndcap.product()) + for(auto& hit : *pcalohitsEndcap.product()) { if(hit.energy() > 0.2) { @@ -192,7 +192,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet // Retrive hcal hits edm::Handle hbhecoll; iEvent.getByLabel("hbheprereco", hbhecoll); - for (auto hit : *hbhecoll.product()) + for (auto& hit : *hbhecoll.product()) { if ( hit.energy() > 0.1 ) { @@ -307,9 +307,10 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet if ( cluster.hovere() < ((cluster.pt() > 35) ? 0.5 : 0.5+pow(cluster.pt()-35,2)/350. ) && cluster.isolation() < ((cluster.pt() > 35) ? 1.3 : 1.3+pow(cluster.pt()-35,2)*4/(35*35) ) ) { - if (totalPt >= EtminForStore) { - l1EGammaCrystal->push_back(l1extra::L1EmParticle(p4, edm::Ref(), 0)); - } + // Optional min. Et cut + if (cluster.pt() >= EtminForStore) { + l1EGammaCrystal->push_back(l1extra::L1EmParticle(p4, edm::Ref(), 0)); + } } } From 1758265cdf2e62bd2846688d52e94f58d9b07f47 Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Fri, 27 Jun 2014 08:34:09 -0500 Subject: [PATCH 055/252] Added new cut quantities to EG crystal cluster algorithm. They are documented in the header. --- .../plugins/L1EGammaCrystalsProducer.cc | 16 ++++++++++++-- .../SLHC/interface/L1EGCrystalCluster.h | 21 ++++++++++++++++--- 2 files changed, 32 insertions(+), 5 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index bc34b1d77d5c7..1043b874a1cba 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -228,12 +228,15 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet // Find the energy-weighted average position, // calculate isolation parameter, - // and calculate pileup-corrected pt + // calculate pileup-corrected pt, + // and quantify likelihood of a brem GlobalVector weightedPosition; GlobalVector ECalPileUpVector; float totalEnergy = 0.; float ECalIsolation = 0.; float ECalPileUpEnergy = 0.; + float sideLobeEnergy = 0.; + std::vector crystalPt; for(auto& hit : ecalhits) { if ( !hit.stale && @@ -243,6 +246,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet weightedPosition += hit.position*hit.energy; totalEnergy += hit.energy; hit.stale = true; + crystalPt.push_back(hit.pt()); if ( debug && hit == centerhit ) std::cout << "\x1B[32m"; // green hilight if ( debug && hit.isEndcapHit ) std::cout << @@ -265,6 +269,11 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet { ECalIsolation += hit.pt(); } + if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && abs(hit.diphi(centerhit)) >= 3 && abs(hit.diphi(centerhit)) < 6) + || (centerhit.isEndcapHit && fabs(hit.deta(centerhit)) < 0.02 && fabs(hit.dphi(centerhit)) >= 0.0173*3 && fabs(hit.dphi(centerhit)) < 0.0173*6 )) + { + sideLobeEnergy += hit.pt(); + } if ( hit.pt() < 5. && ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 7 && abs(hit.diphi(centerhit)) < 57 ) || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 50.) )) @@ -278,6 +287,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet float totalPt = totalEnergy*sin(weightedPosition.theta()); ECalIsolation /= totalPt; float totalPtPUcorr = totalPt - ECalPileUpEnergy*sin(ECalPileUpVector.theta())/19.; + float bremStrength = sideLobeEnergy / totalPt; if ( debug ) std::cout << "Weighted position eta = " << weightedPosition.eta() << ", phi = " << weightedPosition.phi() << std::endl; if ( debug ) std::cout << "Total energy = " << totalEnergy << ", total pt = " << totalPt << std::endl; @@ -298,7 +308,9 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet // Form a l1slhc::L1EGCrystalCluster reco::Candidate::PolarLorentzVector p4(totalPt, weightedPosition.eta(), weightedPosition.phi(), 0.); - l1slhc::L1EGCrystalCluster cluster(p4, hovere, ECalIsolation, totalPtPUcorr); + l1slhc::L1EGCrystalCluster cluster(p4, hovere, ECalIsolation, totalPtPUcorr, bremStrength); + // Save pt array + cluster.SetCrystalPtInfo(crystalPt); trigCrystalClusters->push_back(cluster); // Save clusters with some cuts diff --git a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h index e893d6004ae13..d7ed60c962c51 100644 --- a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h +++ b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h @@ -2,6 +2,7 @@ #define L1EGammaCrystalsCluster_h #include +#include #include "DataFormats/Candidate/interface/LeafCandidate.h" namespace l1slhc @@ -9,13 +10,23 @@ namespace l1slhc class L1EGCrystalCluster : public reco::LeafCandidate { public: - L1EGCrystalCluster() : LeafCandidate(), hovere_(0.), iso_(0.), PUcorrPt_(0.) {}; - L1EGCrystalCluster(const PolarLorentzVector& p4, float hovere, float iso, float PUcorrPt = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt) {}; - L1EGCrystalCluster(const LorentzVector& p4, float hovere, float iso, float PUcorrPt = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt) {}; + L1EGCrystalCluster() : LeafCandidate(), hovere_(0.), iso_(0.), PUcorrPt_(0.), bremStrength_(0.) {}; + L1EGCrystalCluster(const PolarLorentzVector& p4, float hovere, float iso, float PUcorrPt = 0., float bremStrength = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt), bremStrength_(bremStrength) {}; + L1EGCrystalCluster(const LorentzVector& p4, float hovere, float iso, float PUcorrPt = 0., float bremStrength = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt), bremStrength_(bremStrength) {}; virtual ~L1EGCrystalCluster() {}; inline float hovere() const { return hovere_; }; inline float isolation() const { return iso_; }; inline float PUcorrPt() const { return PUcorrPt_; }; + inline float bremStrength() const { return bremStrength_; }; + void SetCrystalPtInfo(std::vector &info) { + std::sort(info.begin(), info.end()); + std::reverse(info.begin(), info.end()); + crystalPt_ = info; + }; + + // The index range depends on the algorithm eta,phi window, currently 3x5 + // The pt should always be ordered. + inline float GetCrystalPt(unsigned int index) const { return (index < crystalPt_.size()) ? crystalPt_[index] : 0.; }; private: // HCal energy in region behind cluster (for size, look in producer) / ECal energy in cluster @@ -24,6 +35,10 @@ namespace l1slhc float iso_; // Pileup-corrected energy deposit, not studied carefully yet, don't use float PUcorrPt_; + // Bremstrahlung strength, should be proportional to the likelihood of a brem. + float bremStrength_; + // Crystal pt (in order of strength) for all crystals in the cluster + std::vector crystalPt_; }; From 3aee3eeb6a9377141c82127741a19355c7d2f204 Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Fri, 27 Jun 2014 08:42:18 -0500 Subject: [PATCH 056/252] Latest cut on l1EG crystal clusters. --- .../L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index 1043b874a1cba..2d2f94c359cd8 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -317,7 +317,9 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet // This is a dynamic falling quadratic cut in pt, trying to squeeze as much efficiency as possible // out of the cut variables, which should have been pt-independent, but are not. if ( cluster.hovere() < ((cluster.pt() > 35) ? 0.5 : 0.5+pow(cluster.pt()-35,2)/350. ) - && cluster.isolation() < ((cluster.pt() > 35) ? 1.3 : 1.3+pow(cluster.pt()-35,2)*4/(35*35) ) ) + && cluster.isolation() < ((cluster.pt() > 35) ? 1.3 : 1.3+pow(cluster.pt()-35,2)*4/(35*35) ) + && (cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cluster.pt() < 20) ? 0.08:0.08*(1+(cluster.pt()-20)/30.) ) ) + && ((cluster.pt() > 10) ? (cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) > 0.):true) ) { // Optional min. Et cut if (cluster.pt() >= EtminForStore) { From a888479f0ff67c63396464e5be4eb093e71861e8 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 1 Jul 2014 16:38:49 +0200 Subject: [PATCH 057/252] updates to L1Tkvertex: possibility to add quality cuts a la Louise --- .../plugins/L1TkFastVertexProducer.cc | 47 +++++- .../python/L1TkPrimaryVertexProducer_cfi.py | 6 +- .../L1TrackTrigger/python/ttbarFiles_cfi.py | 151 ++++++++++++++++++ 3 files changed, 198 insertions(+), 6 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/ttbarFiles_cfi.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc index 87c82eddef585..b93c28cc5c284 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc @@ -101,6 +101,10 @@ class L1TkFastVertexProducer : public edm::EDProducer { int nStubsmin ; // minimum number of stubs int nStubsPSmin ; // minimum number of stubs in PS modules + int nBinning; // number of bins used in the temp histogram + + bool MonteCarloVertex; // + bool StandardQualityCutsOnTracks; //const StackedTrackerGeometry* theStackedGeometry; TH1F* htmp; @@ -145,6 +149,10 @@ L1TkFastVertexProducer::L1TkFastVertexProducer(const edm::ParameterSet& iConfig) nStubsmin = iConfig.getParameter("nStubsmin"); nStubsPSmin = iConfig.getParameter("nStubsPSmin"); + nBinning = iConfig.getParameter("nBinning"); + + MonteCarloVertex = iConfig.getParameter("MonteCarloVertex"); + StandardQualityCutsOnTracks = iConfig.getParameter("StandardQualityCutsOnTracks"); //int nbins = 300; @@ -155,9 +163,10 @@ L1TkFastVertexProducer::L1TkFastVertexProducer(const edm::ParameterSet& iConfig) //float xmin = -15; //float xmax = +15; - int nbins = 600; - float xmin = -30 + 0.05/2.; - float xmax = +30 + 0.05/2.; + //int nbins = 600; + int nbins = nBinning ; // should be odd + float xmin = -30 ; + float xmax = +30 ; htmp = new TH1F("htmp",";z (cm); Tracks",nbins,xmin,xmax); htmp_weight = new TH1F("htmp_weight",";z (cm); Tracks",nbins,xmin,xmax); @@ -206,7 +215,6 @@ L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu // ---------------------------------------------------------------------- -/* // MC info ... retrieve the zvertex edm::Handle HepMCEvt; iEvent.getByLabel("generator",HepMCEvt); @@ -239,9 +247,14 @@ L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu zvtx_gen = pos.z()*mm; break; // there should be one single primary vertex } // end loop over gen vertices -*/ + if (MonteCarloVertex) { + L1TkPrimaryVertex genvtx( zvtx_gen, -999.); + result -> push_back( genvtx ); + iEvent.put( result); + return; + } edm::Handle L1TkTrackHandle; iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); @@ -264,6 +277,8 @@ L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu float z = trackIter->getPOCA().z(); float chi2 = trackIter->getChi2(); float pt = trackIter->getMomentum().perp(); + float eta = trackIter ->getMomentum().eta(); + if (fabs(z) > ZMAX ) continue; if (chi2 > CHI2MAX) continue; @@ -299,6 +314,28 @@ L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu } // end loop over stubs if (nstubs < nStubsmin) continue; if (nPS < nStubsPSmin) continue; + + + + // quality cuts from Louise S, based on the pt-stub compatibility (June 20, 2014) + if (StandardQualityCutsOnTracks) { + + float trk_consistency = trackIter ->getStubPtConsistency(); + int trk_nstub = (int) trackIter ->getStubRefs().size(); + + float chi2dof = chi2 / (2*trk_nstub-4); + + if (trk_nstub < 4) continue; + if (chi2 > 100.0) continue; + if (trk_nstub == 4) { + if (fabs(eta)<2.2 && trk_consistency>10) continue; + else if (fabs(eta)>2.2 && chi2dof>5.0) continue; + } + if (pt>10.0 && chi2dof>5.0) continue; + + } + + htmp -> Fill( z ); htmp_weight -> Fill( z, pt ); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py index 96c14ef9b1ea1..42aa1829de5d1 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py @@ -7,10 +7,14 @@ PTMINTRA = cms.double( 2.), # PTMIN of L1Tracks, in GeV nStubsmin = cms.int32( 4 ) , # minimum number of stubs nStubsPSmin = cms.int32( 3 ), # minimum number of stubs in PS modules + nBinning = cms.int32( 601 ), # number of bins for the temp histo (from -30 cm to + 30 cm) PTMAX = cms.double( 50. ), # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as # mismeasured and are treated according to HighPtTracks below. # When PTMAX < 0, no special treatment is done for high PT tracks. # If PTMAX < 0, no saturation or truncation is done. - HighPtTracks = cms.int32( 0 ) # when = 0 : truncation. Tracks with PT above PTMAX are ignored + HighPtTracks = cms.int32( 0 ), # when = 0 : truncation. Tracks with PT above PTMAX are ignored # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. + MonteCarloVertex = cms.bool( False ), # when True: dont run the vxt finding algo but pick up the MC generated vtx + StandardQualityCutsOnTracks = cms.bool( False ) # Louises quality cuts on tracks + ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/ttbarFiles_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/ttbarFiles_cfi.py new file mode 100644 index 0000000000000..442e3ca3e62a5 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/ttbarFiles_cfi.py @@ -0,0 +1,151 @@ +import FWCore.ParameterSet.Config as cms + +ttbarFiles = cms.untracked.vstring( +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//00F0F213-B1E5-E311-9C9A-002618943977.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//0425FC8A-C0E5-E311-9731-0025905A60BC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//08257BA4-B5E5-E311-929F-003048678B44.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//08914F9D-C2E5-E311-A8E4-00261894395B.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//0EA8493A-AAE5-E311-B2E4-0025905A611E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//1028F7B7-B6E5-E311-B5EC-0026189438FA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//10B78303-B4E5-E311-A1B3-002590593920.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//124C7445-B8E5-E311-842C-003048FFD752.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//127AC0B6-AEE5-E311-8FFC-0026189438E2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//1451C784-B0E5-E311-9CDB-003048D15DDA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//1C11765E-BFE5-E311-8C61-00261894395F.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//1CDCA5E1-B4E5-E311-819C-003048678FF6.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//2004FAE3-B4E5-E311-8FA4-003048678B44.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//202F0848-BDE5-E311-8C45-002618943810.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//20BBE62B-B0E5-E311-A04F-0025905A60D2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//240DE3F0-B1E5-E311-AAA3-003048FFD76E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//2653B96A-ABE5-E311-B942-0030486790A6.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//26D2EE0E-33E2-E311-B356-0025905938D4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//26FA5FAE-C4E5-E311-B436-002618943961.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//28FD1397-AFE5-E311-9750-003048678B84.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//2ACDF84C-BBE5-E311-9CD7-0025905A60F2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//2CC20AD9-B2E5-E311-B670-0025905938A4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//2E07A990-BBE5-E311-87FE-002354EF3BDE.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//2E26B44F-B4E5-E311-9AC9-0025905A48F2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//2EEAB7B6-BCE5-E311-AE4D-0025905A48E4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//30808E6E-B9E5-E311-A86D-002618FDA250.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//308C6E25-BCE5-E311-80FD-002618B27F8A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//322F4739-ADE5-E311-9877-0025905A48D8.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//3602FC1D-BAE5-E311-8798-003048D15DB6.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//36946947-AFE5-E311-A7E2-003048678ED4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//38E10606-B4E5-E311-AEC6-003048FFCC18.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//3C4A787C-AAE5-E311-8617-003048678AE2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//3E1FD7A9-BFE5-E311-8721-002618943910.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//3E23ADFF-C1E5-E311-9F7B-00261894394A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//3E541785-B0E5-E311-AD7F-003048678ADA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//3EE0FEF4-C2E5-E311-8911-003048678C26.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//40EB70F6-BAE5-E311-8F2D-0025905A48E4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//448132B2-A8E5-E311-BA9E-003048678F8C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//46ADA7C6-A9E1-E311-B57C-0025905A6138.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//46E0A383-C3E5-E311-B922-003048678FB4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//48391443-ACE5-E311-A5EF-003048678E92.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//4AFCC957-B8E5-E311-AFE4-00261894386E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//4AFF0350-BAE5-E311-BABE-002618943911.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//4C1D0806-BDE5-E311-83B4-002618943870.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//4C972F1F-C1E5-E311-80BD-002618FDA279.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//50FF9095-B4E5-E311-8F77-0025905A6134.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//548DDA6A-CCE5-E311-B311-001A92971B72.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//56839E4F-C2E5-E311-8B54-0026189438BC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//58ABC9E0-B8E5-E311-A247-003048678BAE.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//58AF47AD-BFE5-E311-A5F4-0025905A612A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//58B518EE-B1E5-E311-BA43-002618943865.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//58F9880C-DFE5-E311-AA51-0026189438D8.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//5C10382E-BCE5-E311-9BF2-0025905A60CE.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//5CABD6A4-B1E5-E311-8A03-002618943811.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//5ECDD519-BAE5-E311-96A2-00304866C398.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//628BE72D-E5E1-E311-948B-0025905A60E0.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6449A028-D2E5-E311-8EE0-00259059642E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//64886E02-B4E5-E311-BA8A-003048678F74.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//662B4AA2-B1E5-E311-B6A2-0026189437F5.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6684C69C-AFE5-E311-AB82-0025905A60F4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//669E8886-B2E5-E311-AFFE-0025905A48EC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//683A0029-B9E5-E311-8F24-00261894395C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//68F3F465-CEE5-E311-9E61-002618943976.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6A9AEC43-AFE5-E311-93B0-0026189438E2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6AB7649E-BAE5-E311-A4D7-003048678B00.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6C96B1FC-BFE5-E311-880A-0025905A60BC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6CC2F2C6-B0E5-E311-8CB2-002618943934.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6CD358D7-B5E5-E311-9BF2-003048678B1A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//6EE0C9B4-B7E5-E311-9A9B-0026189438AA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//702A0F55-AEE5-E311-816D-0025905938A4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//7062D2A6-B1E5-E311-AB71-00261894384A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//78493034-B9E5-E311-8183-003048678B0E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//7E6B3358-B5E5-E311-847C-00261894380B.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//7E98450C-B8E5-E311-AC84-0025905A609E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//80CFB32F-B6E5-E311-8AD4-003048FFD796.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//80FA22BF-B9E5-E311-A452-00261894386D.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//826484B8-B6E5-E311-A5AB-002618FDA237.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//842654AD-B5E5-E311-80F2-0025905A6082.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//8494D5B6-B7E5-E311-9443-0025905A60F2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//84AB8635-ABE2-E311-A265-00304867920A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//860AC797-BDE5-E311-8114-0026189438D8.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//880099FE-68E1-E311-8EE5-003048678FB8.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//88D7C5BB-B7E5-E311-89DE-0025905A6068.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//8A25A451-B7E5-E311-8125-003048679162.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//8A55CC6F-B9E5-E311-9F42-003048678C62.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//8A6F7CC0-ADE5-E311-AA7F-002618943927.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//8CC45A82-BBE5-E311-93CB-002618943937.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//90DEE929-BCE5-E311-A8A4-0025905A6082.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//90E9360E-B7E5-E311-87E9-0025905A606A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//90FD019C-A9E5-E311-945F-00304867926C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//9261DF99-BDE5-E311-A444-0025905964CC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//941528AF-AEE5-E311-B9FA-0025905A48BA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//9491E4F8-AEE5-E311-A023-002618943870.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//960FE833-BEE5-E311-914F-0026189438E9.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//9840150B-B4E5-E311-980C-0025905A60A0.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//98471380-BCE5-E311-8D79-002618943913.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//9AE05C4C-BBE5-E311-B249-0026189438C1.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//9C070FE4-ACE5-E311-9C9C-003048678F9C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//9E83A73C-C0E5-E311-85F3-0026189438D7.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//9EECE69E-B5E5-E311-8E2D-0030486792F0.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//A04B5DB4-9AE1-E311-9CC9-003048678BAA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//A20C4520-C1E5-E311-92B7-0025905964A6.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//A45B1200-B9E5-E311-811F-0025905A60D6.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//A61FFA2E-3BE1-E311-B074-003048678B3C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//A6ED34F4-B8E5-E311-94BD-003048FFD752.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//A8A98479-BCE5-E311-BC9A-00304867D836.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//A8C3AF91-B4E5-E311-B364-003048679166.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//AE20328F-B8E5-E311-86FD-0026189438D9.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//AE49C9E4-ACE5-E311-9294-0026189438D5.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//AEE31A19-BAE5-E311-A881-002618943954.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//B4B4FC77-B6E5-E311-B93C-0025905A48F0.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//B830253D-B2E5-E311-9652-0025905A611E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//B853F7B5-BCE5-E311-AA59-0025905A48EC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//BA494230-BEE5-E311-A1B8-002618943960.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//BE8D19D9-AAE5-E311-9C96-0025905A613C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//BE9830B4-C1E5-E311-BB58-0025905938D4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//C01B2734-C6E5-E311-8DB4-0025905A48BC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//C051FA80-B6E5-E311-940A-0026189438BA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//C059888E-B8E5-E311-A34B-002618943946.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//C40B806E-C1E5-E311-AE32-002618943849.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//C4635BDA-B8E5-E311-8765-00304867BFBC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//CAE6F8DD-C0E5-E311-856F-0025905A610C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//CE17BD86-B0E5-E311-9DFB-00261894382A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//CED472CB-C6E5-E311-8F24-0026189438F5.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//D011B55B-BAE5-E311-A470-0025905A48E4.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//D0E4D868-B1E5-E311-839C-00304867904E.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//D2463FEA-BAE5-E311-86D2-00261894393A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//D2D6FD85-B2E5-E311-9F0E-0025905A6090.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//D6A73BD8-CFE5-E311-AEF9-0025905A60AA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//D8498D48-B5E5-E311-83C0-003048679236.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//D89D7769-ABE5-E311-B4BF-00304867BFF2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//DC7B6FC2-BEE5-E311-99A1-00261894395F.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//DEACD80E-AEE5-E311-B9BA-0025905A6092.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//E059E103-ACE5-E311-BF61-003048678F9C.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//E0EEEEB3-B3E5-E311-A90F-003048678BAA.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//E41FB08D-BBE5-E311-AA07-0025905A60CE.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//E80DCD18-B3E5-E311-BE59-003048678AE2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//EC750FAE-ABE5-E311-8F82-0025905A60B2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//EE248300-B7E5-E311-BB3A-00304867920A.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//F01A9158-B8E5-E311-80BD-0025905A60F2.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//F0698C51-1FE6-E311-9195-0025905A60EE.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//F07E4C9A-C5E5-E311-98B6-0026189438BC.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//F0F2D3D9-B2E5-E311-9451-003048FF9AC6.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//F6524744-B5E5-E311-9FC3-0026189438E0.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//F6B79650-B8E5-E311-B250-003048679070.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//FCE78986-10E3-E311-8C30-0025905A6110.root", +"/store/mc/TTI2023Upg14D/PYTHIA6_Tauola_TTbar_TuneZ2star_14TeV/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000//FCF3EC6A-C9E5-E311-A79B-002618943921.root" +) From f7468a28cc88ec7170b831b0db6c5866128a94b3 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 2 Jul 2014 17:44:57 +0200 Subject: [PATCH 058/252] add doPtComp and doTightChi2 to TkJetProducer, TkMETProducer and TkVertex --- .../plugins/L1TkEtMissProducer.cc | 34 ++++++++++- .../plugins/L1TkFastVertexProducer.cc | 60 ++++++++++++++----- .../L1TrackTrigger/plugins/L1TkJetProducer.cc | 29 +++++++++ .../python/L1TkEtMissProducer_cfi.py | 9 ++- .../python/L1TkJetProducer_cfi.py | 4 +- .../python/L1TkPrimaryVertexProducer_cfi.py | 4 +- 6 files changed, 117 insertions(+), 23 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc index d21eabd19b9a0..c931a684a5a03 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEtMissProducer.cc @@ -93,6 +93,9 @@ class L1TkEtMissProducer : public edm::EDProducer { float PTMAX; // in GeV int HighPtTracks; // saturate or truncate + bool doPtComp; + bool doTightChi2; + //const StackedTrackerGeometry* theStackedGeometry; }; @@ -136,6 +139,8 @@ L1TkEtMissProducer::L1TkEtMissProducer(const edm::ParameterSet& iConfig) PTMAX = (float)iConfig.getParameter("PTMAX"); HighPtTracks = iConfig.getParameter("HighPtTracks"); + doPtComp = iConfig.getParameter("doPtComp"); + doTightChi2 = iConfig.getParameter("doTightChi2"); produces("MET"); @@ -222,13 +227,14 @@ L1TkEtMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { float pt = trackIter->getMomentum().perp(); + float eta = trackIter->getMomentum().eta(); float chi2 = trackIter->getChi2(); float ztr = trackIter->getPOCA().z(); - + if (pt < PTMINTRA) continue; if (fabs(ztr) > ZMAX ) continue; if (chi2 > CHI2MAX) continue; - + float pt_rescale = 1; @@ -257,6 +263,30 @@ L1TkEtMissProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) if (nstubs < nStubsmin) continue; if (nPS < nStubsPSmin) continue; + + ////_______ + ////------- + float trk_consistency = trackIter ->getStubPtConsistency(); + float chi2dof = chi2 / (2*nstubs-4); + + if(doPtComp) { + // if (trk_nstub < 4) continue; + // if (trk_chi2 > 100.0) continue; + if (nstubs == 4) { + if (fabs(eta)<2.2 && trk_consistency>10) continue; + else if (fabs(eta)>2.2 && chi2dof>5.0) continue; + } + } + + if(doTightChi2) { + if(pt>10.0 && chi2dof>5.0 ) continue; + } + + ////_______ + ////------- + + + if ( fabs(ztr - zVTX) <= DeltaZ) { // eg DeltaZ = 1 mm sumPx += trackIter->getMomentum().x() * pt_rescale ; diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc index b93c28cc5c284..fddf6b4b90d6f 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkFastVertexProducer.cc @@ -104,9 +104,11 @@ class L1TkFastVertexProducer : public edm::EDProducer { int nBinning; // number of bins used in the temp histogram bool MonteCarloVertex; // - bool StandardQualityCutsOnTracks; //const StackedTrackerGeometry* theStackedGeometry; + bool doPtComp ; + bool doTightChi2 ; + TH1F* htmp; TH1F* htmp_weight; @@ -152,7 +154,8 @@ L1TkFastVertexProducer::L1TkFastVertexProducer(const edm::ParameterSet& iConfig) nBinning = iConfig.getParameter("nBinning"); MonteCarloVertex = iConfig.getParameter("MonteCarloVertex"); - StandardQualityCutsOnTracks = iConfig.getParameter("StandardQualityCutsOnTracks"); + doPtComp = iConfig.getParameter("doPtComp"); + doTightChi2 = iConfig.getParameter("doTightChi2"); //int nbins = 300; @@ -194,6 +197,7 @@ void L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { using namespace edm; + using namespace std; std::auto_ptr result(new L1TkPrimaryVertexCollection); @@ -215,15 +219,23 @@ L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu // ---------------------------------------------------------------------- + if (MonteCarloVertex) { + // MC info ... retrieve the zvertex edm::Handle HepMCEvt; iEvent.getByLabel("generator",HepMCEvt); - const HepMC::GenEvent* MCEvt = HepMCEvt->GetEvent(); - const double mm=0.1; + edm::Handle< vector > GenParticleHandle; + iEvent.getByLabel("genParticles","",GenParticleHandle); + const double mm=0.1; float zvtx_gen = -999; + + if ( HepMCEvt.isValid() ) { + // using HepMCEvt + + const HepMC::GenEvent* MCEvt = HepMCEvt->GetEvent(); for ( HepMC::GenEvent::vertex_const_iterator ivertex = MCEvt->vertices_begin(); ivertex != MCEvt->vertices_end(); ++ivertex ) { bool hasParentVertex = false; @@ -248,8 +260,26 @@ L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu break; // there should be one single primary vertex } // end loop over gen vertices + } + else if (GenParticleHandle.isValid() ) { + vector::const_iterator genpartIter ; + for (genpartIter = GenParticleHandle->begin(); genpartIter != GenParticleHandle->end(); ++genpartIter) { + int status = genpartIter -> status() ; + if (status != 3) continue; + if ( genpartIter -> numberOfMothers() == 0) continue; // the incoming hadrons + float part_zvertex = genpartIter -> vz() ; + zvtx_gen = part_zvertex ; + break; // + } + } + else { + edm::LogError("L1TkFastVertexProducer") + << "\nerror: try to retrieve the MC vertex (MonteCarloVertex = True) " + << "\nbut the input file contains neither edm::HepMCProduct> nor vector. Exit" + << std::endl; + } + - if (MonteCarloVertex) { L1TkPrimaryVertex genvtx( zvtx_gen, -999.); result -> push_back( genvtx ); iEvent.put( result); @@ -318,23 +348,21 @@ L1TkFastVertexProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetu // quality cuts from Louise S, based on the pt-stub compatibility (June 20, 2014) - if (StandardQualityCutsOnTracks) { + int trk_nstub = (int) trackIter ->getStubRefs().size(); + float chi2dof = chi2 / (2*trk_nstub-4); + if (doPtComp) { float trk_consistency = trackIter ->getStubPtConsistency(); - int trk_nstub = (int) trackIter ->getStubRefs().size(); - - float chi2dof = chi2 / (2*trk_nstub-4); - - if (trk_nstub < 4) continue; - if (chi2 > 100.0) continue; + //if (trk_nstub < 4) continue; // done earlier + //if (chi2 > 100.0) continue; // done earlier if (trk_nstub == 4) { if (fabs(eta)<2.2 && trk_consistency>10) continue; else if (fabs(eta)>2.2 && chi2dof>5.0) continue; } - if (pt>10.0 && chi2dof>5.0) continue; - - } - + } + if (doTightChi2) { + if (pt>10.0 && chi2dof>5.0) continue; + } htmp -> Fill( z ); htmp_weight -> Fill( z, pt ); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc index 2d482255d0d0f..a73a915e055dc 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkJetProducer.cc @@ -91,6 +91,8 @@ class L1TkJetProducer : public edm::EDProducer // jet cut //bool JET_HLTETA; // temporary hack to remove bad jets when using HI HLT jets! + bool doPtComp; + bool doTightChi2; // geometry for stub info const StackedTrackerGeometry* theStackedGeometry; @@ -114,6 +116,8 @@ L1TkJetProducer::L1TkJetProducer(const edm::ParameterSet& iConfig) TRK_NSTUBMIN = (int)iConfig.getParameter("TRK_NSTUBMIN"); TRK_NSTUBPSMIN = (int)iConfig.getParameter("TRK_NSTUBPSMIN"); //JET_HLTETA = (bool)iConfig.getParameter("JET_HLTETA"); + doPtComp = iConfig.getParameter("doPtComp"); + doTightChi2 = iConfig.getParameter("doTightChi2"); } @@ -265,6 +269,31 @@ void L1TkJetProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) if (tmp_trk_nstubPS < TRK_NSTUBPSMIN) continue; + ////_______ + ////------- + float tmp_trk_consistency = trackIter ->getStubPtConsistency(); + float chi2dof = tmp_trk_chi2 / (2*tmp_trk_nstub-4); + + if(doPtComp) { + // if (trk_nstub < 4) continue; + // if (trk_chi2 > 100.0) continue; + if (tmp_trk_nstub == 4) { + if (fabs(tmp_trk_eta)<2.2 && tmp_trk_consistency>10) continue; + else if (fabs(tmp_trk_eta)>2.2 && chi2dof>5.0) continue; + } + } + + if(doTightChi2) { + if(tmp_trk_pt>10.0 && chi2dof>5.0 ) continue; + } + + + ////_______ + ////------- + + + + // deltaR float deltaEta = fabs(tmp_jet_eta-tmp_trk_eta); float deltaPhi = fabs(tmp_jet_phi-tmp_trk_phi); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py index 29bbbf6085b85..b0e48982e2e8b 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py @@ -9,11 +9,16 @@ DeltaZ = cms.double( 1. ), # in cm nStubsmin = cms.int32( 4 ), # min number of stubs for the tracks to enter in TrkMET calculation nStubsPSmin = cms.int32( 0), # min number of stubs in the PS Modules - PTMAX = cms.double( 50. ), # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as + #PTMAX = cms.double( 50. ), # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as # mismeasured and are treated according to HighPtTracks below. # When PTMAX < 0, no special treatment is done for high PT tracks. - HighPtTracks = cms.int32( 0 ) # when = 0 : truncation. Tracks with PT above PTMAX are ignored + PTMAX = cms.double( -1. ), + HighPtTracks = cms.int32( 0 ), # when = 0 : truncation. Tracks with PT above PTMAX are ignored # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. + # When PTMAX < 0, no special treatment is done for high PT tracks. + doPtComp = cms.bool( True ), # track-stubs PT compatibility cut + doTightChi2 = cms.bool( True ) # chi2dof < 5 for tracks with PT > 10 + ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py index 0eee5fb668a1e..aa3f317d76017 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py @@ -10,5 +10,7 @@ TRK_ETAMAX = cms.double(2.5), # maximum track eta TRK_NSTUBMIN = cms.int32(4), # minimum number of stubs on track TRK_NSTUBPSMIN = cms.int32(2), # minimum number of stubs in PS modules on track - #JET_HLTETA = cms.bool(False) # temporary hack, for HLT jets remove jets from bad eta regions + #JET_HLTETA = cms.bool(False), # temporary hack, for HLT jets remove jets from bad eta regions + doPtComp = cms.bool( True ), # track-stubs PT compatibility cut + doTightChi2 = cms.bool( True ) # chi2dof < 5 for tracks with PT > 10 ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py index 42aa1829de5d1..ce64646cc2a38 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py @@ -15,6 +15,6 @@ HighPtTracks = cms.int32( 0 ), # when = 0 : truncation. Tracks with PT above PTMAX are ignored # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. MonteCarloVertex = cms.bool( False ), # when True: dont run the vxt finding algo but pick up the MC generated vtx - StandardQualityCutsOnTracks = cms.bool( False ) # Louises quality cuts on tracks - + doPtComp = cms.bool( True ), # track-stubs PT compatibility cut + doTightChi2 = cms.bool( True ) # chi2dof < 5 for tracks with PT > 10 ) From 521ddea663b966ed2253e560ee8eff4d4ada90ea Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 2 Jul 2014 18:41:53 +0200 Subject: [PATCH 059/252] added Anders TkEmTaus --- .../plugins/L1CaloTausToTkTausTranslator.cc | 132 +++++ .../plugins/L1TkEmTauProducer.cc | 425 +++++++++++++++ .../test/L1TkEmTauNtupleMaker.cc | 496 ++++++++++++++++++ .../L1TrackTrigger/test/L1TrackTauAnalyzer.cc | 388 ++++++++++++++ .../L1TrackTrigger/test/test_L1TkEmTau_cfg.py | 345 ++++++++++++ 5 files changed, 1786 insertions(+) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/L1TkEmTauNtupleMaker.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackTauAnalyzer.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc new file mode 100644 index 0000000000000..984687539bcb8 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc @@ -0,0 +1,132 @@ +// -*- C++ -*- +// +// +// dummy producer for a L1TkTauParticle +// The code simply match the L1CaloTaus with the closest L1Track. +// + +// system include files +#include +#include +#include "TMath.h" +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Utilities/interface/InputTag.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticleFwd.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" // new +#include "DataFormats/Math/interface/LorentzVector.h" +#include "DataFormats/Math/interface/deltaR.h" +#include "DataFormats/Math/interface/deltaPhi.h" +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" // new +// for L1Tracks: +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" //for 'L1TkTrack_PixelDigi_Collection', etc.. +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +using namespace l1extra ; + +// ---------- class declaration ---------- // +class L1CaloTausToTkTausTranslator : public edm::EDProducer { +public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef edm::Ptr< L1TkTrackType > L1TkTrackRefPtr; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + typedef edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > L1TkStubRef; //new + + explicit L1CaloTausToTkTausTranslator(const edm::ParameterSet&); + ~L1CaloTausToTkTausTranslator(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + +private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + // ---------- member data ---------- // + edm::InputTag L1TausInputTag; + +} ; + + +// ------------ constructor ------------ // +L1CaloTausToTkTausTranslator::L1CaloTausToTkTausTranslator(const edm::ParameterSet& iConfig){ + + L1TausInputTag = iConfig.getParameter("L1TausInputTag"); + + produces(); + +} + + +// ------------ destructor ------------ // +L1CaloTausToTkTausTranslator::~L1CaloTausToTkTausTranslator(){} + +// ------------ method called to produce the data ------------ // +void L1CaloTausToTkTausTranslator::produce(edm::Event& iEvent, const edm::EventSetup& iSetup){ + + using namespace edm; + using namespace std; + std::auto_ptr result(new L1TkTauParticleCollection); + + // Collection Handles: The L1CaloTau from the L1 ExtraParticles + edm::Handle< std::vector< l1extra::L1JetParticle > > h_L1CaloTau; + iEvent.getByLabel( L1TausInputTag, h_L1CaloTau ); + + int iL1CaloTauIndex=0; + + // Nested for-loop: L1CaloTaus + for ( std::vector< l1extra::L1JetParticle >::const_iterator L1CaloTau = h_L1CaloTau->begin(); L1CaloTau != h_L1CaloTau->end(); L1CaloTau++){ + + edm::Ref< L1JetParticleCollection > L1TauCaloRef( h_L1CaloTau, iL1CaloTauIndex ); + + edm::Ptr< L1TkTrackType > L1TrackPtrNull; + + L1TkTauParticle L1TkTauFromCalo( L1CaloTau->p4(), + L1TauCaloRef, + L1TrackPtrNull, + L1TrackPtrNull, + L1TrackPtrNull, + 0.0); + + result -> push_back( L1TkTauFromCalo ); + + iL1CaloTauIndex++; //starts at 0 + + } + + iEvent.put( result ); + +} + + +// ------------ method called once each job just before starting event loop ------------ // +void L1CaloTausToTkTausTranslator::beginJob(){} + +// ------------ method called once each job just after ending the event loop ------------ // +void L1CaloTausToTkTausTranslator::endJob() {} + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ // +void L1CaloTausToTkTausTranslator::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1CaloTausToTkTausTranslator); + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc new file mode 100644 index 0000000000000..f695943d40a5f --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc @@ -0,0 +1,425 @@ +// -*- C++ -*- +// +// +// Producer for a L1TkTauParticle from L1 Tracks and EG Crystal info. +// +// + +// system include files +#include + +// User include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" + +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Utilities/interface/InputTag.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticleFwd.h" + +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" + + +// for TTTracks: +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +#include +#include "TMath.h" + + +using namespace l1extra ; + +// +// class declaration +// + +class L1TkEmTauProducer : public edm::EDProducer { + +public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + explicit L1TkEmTauProducer(const edm::ParameterSet&); + ~L1TkEmTauProducer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + +private: + virtual void beginJob() ; + virtual void produce(edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + double dR(math::XYZTLorentzVector p41,math::XYZTLorentzVector p42); + + //virtual void beginRun(edm::Run&, edm::EventSetup const&); + //virtual void endRun(edm::Run&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&); + + // ----------member data --------------------------- + + edm::InputTag L1TrackInputTag; + edm::InputTag L1EmInputTag; + + double ptleadcut=10.0; //Minimum pt of lead track + double ptleadcone=0.3; //Cone in which there is no higher pt track + double masscut=1.77; //Mass cut + double emptcut=7.0; //minimum emcut + double trketacut=2.3; //largest lead trk eta + double pttotcut=25.0; //Total transverse energy cut + double isocone=0.5; //size of isolation cone + double isodz=1.0; //use tracks within one cm of lead track + double relisocut=0.15; //cut on reliso; + double chisqcut=40.0; + int nstubcut=5; //minimum number of stubs + double dzcut=0.8; //Look for tau tracks near lead track + + +} ; + + +// +// constructors and destructor +// +L1TkEmTauProducer::L1TkEmTauProducer(const edm::ParameterSet& iConfig) +{ + + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + L1EmInputTag = iConfig.getParameter("L1EmInputTag"); + + ptleadcut=iConfig.getParameter("ptleadcut"); + ptleadcone=iConfig.getParameter("ptleadcone"); + masscut=iConfig.getParameter("masscut"); + emptcut=iConfig.getParameter("emptcut"); + trketacut=iConfig.getParameter("trketacut"); + pttotcut=iConfig.getParameter("pttotcut"); + isocone=iConfig.getParameter("isocone"); + isodz=iConfig.getParameter("isodz"); + relisocut=iConfig.getParameter("relisocut"); + chisqcut=iConfig.getParameter("chisqcut"); + nstubcut=iConfig.getParameter("nstubcut"); + dzcut=iConfig.getParameter("dzcut"); + + produces(); + +} + +L1TkEmTauProducer::~L1TkEmTauProducer() { +} + +// ------------ method called to produce the data ------------ +void +L1TkEmTauProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + using namespace std; + + + + std::auto_ptr result(new L1TkTauParticleCollection); + + + edm::Handle L1TkTrackHandle; + iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); + L1TkTrackCollectionType::const_iterator trackIter; + + edm::Ptr< L1TkTrackType > l1tracks[1000]; + + math::XYZTLorentzVector p4[1000]; + double z[1000]; + double chi2[1000]; + int nstub[1000]; + + int ntrack=0; + + int itrack=-1; + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { + itrack++; + + std::vector< edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > > theStubs = trackIter ->getStubRefs(); + + z[ntrack]=trackIter->getPOCA().z(); + double px=trackIter->getMomentum().x(); + double py=trackIter->getMomentum().y(); + double pz=trackIter->getMomentum().z(); + double e=sqrt(px*px+py*py+pz*pz+0.14*0.14); + + + nstub[ntrack]=theStubs.size(); + chi2[ntrack]=trackIter->getChi2(); + if (chi2[ntrack]>100) continue; + + + edm::Ptr< L1TkTrackType > L1TrackPtr( L1TkTrackHandle, itrack) ; + l1tracks[ntrack]=L1TrackPtr; + math::XYZTLorentzVector p4tmp(px,py,pz,e); + p4[ntrack++]=p4tmp; + + } + + ///sort tracks based on pt - use simple bubble sort... + + bool more=false; + + do { + + more=false; + + for (int i=0;i tmpl1=l1tracks[i]; + l1tracks[i]=l1tracks[i+1]; + l1tracks[i+1]=tmpl1; + + math::XYZTLorentzVector tmpp4=p4[i]; + p4[i]=p4[i+1]; + p4[i+1]=tmpp4; + + double tmpz=z[i]; + z[i]=z[i+1]; + z[i+1]=tmpz; + + double tmpchi2=chi2[i]; + chi2[i]=chi2[i+1]; + chi2[i+1]=tmpchi2; + + int tmpnstub=nstub[i]; + nstub[i]=nstub[i+1]; + nstub[i+1]=tmpnstub; + + } + } + } while (more); + + + math::XYZTLorentzVector p4em[1000]; + int nem=0; + + edm::Handle L1EmHandle; + iEvent.getByLabel(L1EmInputTag, L1EmHandle); + std::vector::const_iterator egIter; + + if ( L1EmHandle.isValid() ) { + //std::cout << "Found L1EmParticles"<begin();egIter!=L1EmHandle->end();++egIter) { + double theta=2*atan(exp(-egIter->eta())); + double px=egIter->pt()*cos(egIter->phi()); + double py=egIter->pt()*sin(egIter->phi()); + double pz=egIter->pt()/tan(theta); + double e=sqrt(px*px+py*py+pz*pz); + math::XYZTLorentzVector p4tmp(px,py,pz,e); + p4em[nem++]=p4tmp; + } + } + else { + std::cout << "Did not find L1EmParticles"<chisqcut) continue; + if (nstub[it]trketacut) continue; + + + //Found candidate lead track + //Now check if there ishigher pTtrack nearby + + bool higherpt=false; + for (int it2=0; it2 tracks; + tracks.push_back(it); + + for (int it2=0; it2dzcut) continue; + //if (dR(p4lead,p4[it2])>ptleadcone/2.0) continue; + math::XYZTLorentzVector p4trk=p4[it2]; + if ((p4trk+p4tau).M()relisocut) continue; + + + edm::Ref< L1JetParticleCollection > tauCaloRef; // null pointer + + edm::Ptr< L1TkTrackType > L1Track2; // null pointer + edm::Ptr< L1TkTrackType > L1Track3; // null pointer + + if (tracks.size()>1) L1Track2=l1tracks[tracks[1]]; + if (tracks.size()>2) L1Track3=l1tracks[tracks[2]]; + + + //std::cout << "Creating tau"< push_back( trkTau ); + + } + + iEvent.put( result ); + +} + +double L1TkEmTauProducer::dR(math::XYZTLorentzVector p41,math::XYZTLorentzVector p42) { + + double dPhi=p41.Phi()-p42.Phi(); + static const double pi=4*atan(1.0); + + if (dPhi>pi) dPhi-=2*pi; + if (dPhi<-pi) dPhi+=2*pi; + + double deta=p41.Eta()-p42.Eta(); + + double dr=sqrt(dPhi*dPhi+deta*deta); + + + return dr; + +} + + + +// -------------------------------------------------------------------------------------- + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TkEmTauProducer::beginJob() +{ +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TkEmTauProducer::endJob() { +} + +// ------------ method called when starting to processes a run ------------ +/* +void +L1TkEmTauProducer::beginRun(edm::Run& iRun, edm::EventSetup const& iSetup) +{ +} +*/ + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1TkEmTauProducer::endRun(edm::Run&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1TkEmTauProducer::beginLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1TkEmTauProducer::endLuminosityBlock(edm::LuminosityBlock&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TkEmTauProducer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TkEmTauProducer); + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TkEmTauNtupleMaker.cc b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TkEmTauNtupleMaker.cc new file mode 100644 index 0000000000000..fa2f2c3429492 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TkEmTauNtupleMaker.cc @@ -0,0 +1,496 @@ +////////////////////////////////////////////////////////////////////// +// // +// Analyzer for making mini-ntuple for L1 track + EM Tau selection // +// // +////////////////////////////////////////////////////////////////////// + +//////////////////// +// FRAMEWORK HEADERS +#include "FWCore/PluginManager/interface/ModuleDef.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "FWCore/Framework/interface/EDAnalyzer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/Utilities/interface/InputTag.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +/////////////////////// +// DATA FORMATS HEADERS +#include "DataFormats/Common/interface/Handle.h" +#include "DataFormats/Common/interface/EDProduct.h" +#include "DataFormats/Common/interface/Ref.h" + +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" +#include "DataFormats/L1TrackTrigger/interface/TTCluster.h" +#include "DataFormats/L1TrackTrigger/interface/TTStub.h" +#include "DataFormats/L1TrackTrigger/interface/TTTrack.h" +#include "SimDataFormats/TrackingAnalysis/interface/TrackingParticle.h" +#include "SimDataFormats/TrackingAnalysis/interface/TrackingVertex.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" +#include "SimDataFormats/TrackingHit/interface/PSimHit.h" +#include "SimTracker/TrackTriggerAssociation/interface/TTClusterAssociationMap.h" +#include "SimTracker/TrackTriggerAssociation/interface/TTStubAssociationMap.h" +#include "SimTracker/TrackTriggerAssociation/interface/TTTrackAssociationMap.h" +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkEmParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkEmParticleFwd.h" +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "SimDataFormats/GeneratorProducts/interface/HepMCProduct.h" +#include "DataFormats/Candidate/interface/Candidate.h" +#include "SimDataFormats/SLHC/interface/L1EGCrystalCluster.h" + + +//////////////// +// PHYSICS TOOLS +#include "CommonTools/UtilAlgos/interface/TFileService.h" + +/////////////// +// ROOT HEADERS +#include +#include +#include +#include +#include +#include +#include + +////////////// +// STD HEADERS +#include +#include +#include + +////////////// +// NAMESPACES +using namespace std; +using namespace edm; +using namespace l1extra; +using namespace reco; + + +////////////////////////////// +// // +// CLASS DEFINITION // +// // +////////////////////////////// + +class L1TkEmTauNtupleMaker : public edm::EDAnalyzer +{ +public: + + // Constructor/destructor + explicit L1TkEmTauNtupleMaker(const edm::ParameterSet& iConfig); + virtual ~L1TkEmTauNtupleMaker(); + + // Mandatory methods + virtual void beginJob(); + virtual void endJob(); + virtual void analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup); + +protected: + +private: + + // Containers of parameters passed by python configuration file + edm::ParameterSet config; + + int MyProcess; + bool DebugMode; + + + //----------------------------------------------------------------------------------------------- + // tree & branches for mini-ntuple + + TTree* eventTree; + + // all L1 tracks + std::vector* m_trk_pt; + std::vector* m_trk_eta; + std::vector* m_trk_phi; + std::vector* m_trk_z0; + std::vector* m_trk_chi2; + std::vector* m_trk_nstub; + std::vector* m_trk_genuine; + std::vector* m_trk_unknown; + std::vector* m_trk_combinatoric; + + // EM objects + std::vector* m_em_pt; + std::vector* m_em_eta; + std::vector* m_em_phi; + + // tau mc objects + std::vector* m_tau_pt; + std::vector* m_tau_eta; + std::vector* m_tau_phi; + std::vector* m_tau_mode; + + // tau mc daugther + std::vector* m_taudaug_pt; + std::vector* m_taudaug_eta; + std::vector* m_taudaug_phi; + std::vector* m_taudaug_id; + std::vector* m_taudaug_parindex; + + + // for L1EmParticle + edm::InputTag L1EmInputTag; + + +}; + + +////////////////////////////////// +// // +// CLASS IMPLEMENTATION // +// // +////////////////////////////////// + +////////////// +// CONSTRUCTOR +L1TkEmTauNtupleMaker::L1TkEmTauNtupleMaker(edm::ParameterSet const& iConfig) : + config(iConfig) +{ + + MyProcess = iConfig.getParameter< int >("MyProcess"); + DebugMode = iConfig.getParameter< bool >("DebugMode"); + L1EmInputTag = iConfig.getParameter("L1EmInputTag"); + +} + +///////////// +// DESTRUCTOR +L1TkEmTauNtupleMaker::~L1TkEmTauNtupleMaker() +{ +} + +////////// +// END JOB +void L1TkEmTauNtupleMaker::endJob() +{ + // things to be done at the exit of the event Loop + cerr << "L1TkEmTauNtupleMaker::endJob" << endl; + +} + +//////////// +// BEGIN JOB +void L1TkEmTauNtupleMaker::beginJob() +{ + + // things to be done before entering the event Loop + cerr << "L1TkEmTauNtupleMaker::beginJob" << endl; + + + //----------------------------------------------------------------------------------------------- + // book histograms / make ntuple + edm::Service fs; + + + // initilize + m_trk_pt = new std::vector; + m_trk_eta = new std::vector; + m_trk_phi = new std::vector; + m_trk_z0 = new std::vector; + m_trk_chi2 = new std::vector; + m_trk_nstub = new std::vector; + m_trk_genuine = new std::vector; + m_trk_unknown = new std::vector; + m_trk_combinatoric = new std::vector; + + m_em_pt = new std::vector; + m_em_eta = new std::vector; + m_em_phi = new std::vector; + + m_tau_pt = new std::vector; + m_tau_eta = new std::vector; + m_tau_phi = new std::vector; + m_tau_mode = new std::vector; + + m_taudaug_pt = new std::vector; + m_taudaug_eta = new std::vector; + m_taudaug_phi = new std::vector; + m_taudaug_id = new std::vector; + m_taudaug_parindex = new std::vector; + + + + // ntuple + eventTree = fs->make("TkEmTauTree", "Event tree"); + + eventTree->Branch("trk_pt", &m_trk_pt); + eventTree->Branch("trk_eta", &m_trk_eta); + eventTree->Branch("trk_phi", &m_trk_phi); + eventTree->Branch("trk_z0", &m_trk_z0); + eventTree->Branch("trk_chi2", &m_trk_chi2); + eventTree->Branch("trk_nstub", &m_trk_nstub); + eventTree->Branch("trk_genuine", &m_trk_genuine); + eventTree->Branch("trk_unknown", &m_trk_unknown); + eventTree->Branch("trk_combinatoric", &m_trk_combinatoric); + + + eventTree->Branch("em_pt", &m_em_pt); + eventTree->Branch("em_eta", &m_em_eta); + eventTree->Branch("em_phi", &m_em_phi); + + eventTree->Branch("tau_pt", &m_tau_pt); + eventTree->Branch("tau_eta", &m_tau_eta); + eventTree->Branch("tau_phi", &m_tau_phi); + eventTree->Branch("tau_mode", &m_tau_mode); + + eventTree->Branch("taudaug_pt", &m_taudaug_pt); + eventTree->Branch("taudaug_eta", &m_taudaug_eta); + eventTree->Branch("taudaug_phi", &m_taudaug_phi); + eventTree->Branch("taudaug_id", &m_taudaug_id); + eventTree->Branch("taudaug_parindex", &m_taudaug_parindex); + +} + + +// +// member functions +// + +int tauClass(std::vector& stabledaughters, + double& maxpt) { + + // -999 means not classified + // 1 means electron + // 2 means muon + // 3 means had 1 prong + // 4 means had 3 prong + // 5 means had 5 prong + + maxpt=-999.9; + + if (stabledaughters[1]->pdgId()==11||stabledaughters[1]->pdgId()==-11) return 1; + if (stabledaughters[1]->pdgId()==13||stabledaughters[1]->pdgId()==-13) return 2; + + int nprong=0; + + for (unsigned int i=0;ipdgId()==211||stabledaughters[i]->pdgId()==-211) { + nprong++; + if (stabledaughters[i]->pt()>maxpt) maxpt=stabledaughters[i]->pt(); + } + } + + if (nprong==1) return 3; + if (nprong==3) return 4; + if (nprong==5) return 5; + + return -999; + +} + + +void getStableDaughters(const reco::Candidate & p, + std::vector& stabledaughters){ + + int ndaug=p.numberOfDaughters(); + + for(int j=0;jstatus()==1) { + stabledaughters.push_back(daug); + } + else { + getStableDaughters(*daug,stabledaughters); + } + } + +} + + +////////// +// ANALYZE +void L1TkEmTauNtupleMaker::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + + // clear variables + m_trk_pt->clear(); + m_trk_eta->clear(); + m_trk_phi->clear(); + m_trk_z0->clear(); + m_trk_chi2->clear(); + m_trk_nstub->clear(); + m_trk_genuine->clear(); + m_trk_unknown->clear(); + m_trk_combinatoric->clear(); + + m_em_pt->clear(); + m_em_eta->clear(); + m_em_phi->clear(); + + m_tau_pt->clear(); + m_tau_eta->clear(); + m_tau_phi->clear(); + m_tau_mode->clear(); + + + m_taudaug_pt->clear(); + m_taudaug_eta->clear(); + m_taudaug_phi->clear(); + m_taudaug_id->clear(); + m_taudaug_parindex->clear(); + + + + + + //----------------------------------------------------------------------------------------------- + // retrieve various containers + //----------------------------------------------------------------------------------------------- + + // L1 tracks + edm::Handle< std::vector< TTTrack< Ref_PixelDigi_ > > > TTTrackHandle; + iEvent.getByLabel("TTTracksFromPixelDigis", "Level1TTTracks", TTTrackHandle); + + // MC truth association maps + edm::Handle< TTTrackAssociationMap< Ref_PixelDigi_ > > MCTruthTTTrackHandle; + iEvent.getByLabel("TTTrackAssociatorFromPixelDigis", "Level1TTTracks", MCTruthTTTrackHandle); + edm::Handle< TTClusterAssociationMap< Ref_PixelDigi_ > > MCTruthTTClusterHandle; + iEvent.getByLabel("TTClusterAssociatorFromPixelDigis", "ClusterAccepted", MCTruthTTClusterHandle); + edm::Handle< TTStubAssociationMap< Ref_PixelDigi_ > > MCTruthTTStubHandle; + iEvent.getByLabel("TTStubAssociatorFromPixelDigis", "StubAccepted", MCTruthTTStubHandle); + + // tracking particles + edm::Handle< std::vector< TrackingParticle > > TrackingParticleHandle; + edm::Handle< std::vector< TrackingVertex > > TrackingVertexHandle; + iEvent.getByLabel("mix", "MergedTrackTruth", TrackingParticleHandle); + iEvent.getByLabel("mix", "MergedTrackTruth", TrackingVertexHandle); + + + //Get generator MC truth + + Handle genParticles; + iEvent.getByLabel("genParticles", genParticles); + int ntau=0; + for(size_t i = 0; i < genParticles->size(); ++ i) { + const GenParticle & p = (*genParticles)[i]; + int id = p.pdgId(); + //int st = p.status(); + double eta=p.p4().eta(); + double phi=p.p4().phi(); + double pt=p.p4().pt(); + if (!(id==15||id==-15)) continue; + if(abs(p.daughter(0)->pdgId())==15) continue; //skip if daugther is tau + //int nmother=p.numberOfMothers(); + //if (nmother!=1) continue; + //if (p.mother(0)->pdgId()!=25) continue; + + //double vx = p.vx(), vy = p.vy(), vz = p.vz(); + + //std::cout << "vertex : "< stabledaughters; + + getStableDaughters(p,stabledaughters); + + double tauplusmaxpt=0.0; + + m_tau_pt->push_back(pt); + m_tau_eta->push_back(eta); + m_tau_phi->push_back(phi); + m_tau_mode->push_back(tauClass(stabledaughters,tauplusmaxpt)); + + for (unsigned int j=0;jpush_back(stabledaughters[j]->pt()); + m_taudaug_eta->push_back(stabledaughters[j]->eta()); + m_taudaug_phi->push_back(stabledaughters[j]->phi()); + m_taudaug_id->push_back(stabledaughters[j]->pdgId()); + m_taudaug_parindex->push_back(ntau); + } + + ntau++; + + } + + + + // ---------------------------------------------------------------------------------------------- + // loop over L1 tracks + // ---------------------------------------------------------------------------------------------- + + if (DebugMode) cout << endl << "Loop over L1 tracks!" << endl; + + int this_l1track = 0; + std::vector< TTTrack< Ref_PixelDigi_ > >::const_iterator iterL1Track; + for ( iterL1Track = TTTrackHandle->begin(); iterL1Track != TTTrackHandle->end(); iterL1Track++ ) { + + edm::Ptr< TTTrack< Ref_PixelDigi_ > > l1track_ptr(TTTrackHandle, this_l1track); + this_l1track++; + + float tmp_trk_pt = iterL1Track->getMomentum().perp(); + float tmp_trk_eta = iterL1Track->getMomentum().eta(); + float tmp_trk_phi = iterL1Track->getMomentum().phi(); + float tmp_trk_z0 = iterL1Track->getPOCA().z(); //cm + float tmp_trk_chi2 = iterL1Track->getChi2(); + int tmp_trk_nstub = (int) iterL1Track->getStubRefs().size(); + + if (tmp_trk_pt < 2.0) continue; + + int tmp_trk_genuine = 0; + int tmp_trk_unknown = 0; + int tmp_trk_combinatoric = 0; + if (MCTruthTTTrackHandle->isGenuine(l1track_ptr)) tmp_trk_genuine = 1; + if (MCTruthTTTrackHandle->isUnknown(l1track_ptr)) tmp_trk_unknown = 1; + if (MCTruthTTTrackHandle->isCombinatoric(l1track_ptr)) tmp_trk_combinatoric = 1; + + if (DebugMode) { + cout << "L1 track, pt: " << tmp_trk_pt << " eta: " << tmp_trk_eta << " phi: " << tmp_trk_phi + << " z0: " << tmp_trk_z0 << " chi2: " << tmp_trk_chi2 << " nstub: " << tmp_trk_nstub; + if (tmp_trk_genuine) cout << " (is genuine)" << endl; + if (tmp_trk_unknown) cout << " (is unknown)" << endl; + if (tmp_trk_combinatoric) cout << " (is combinatoric)" << endl; + } + + m_trk_pt ->push_back(tmp_trk_pt); + m_trk_eta->push_back(tmp_trk_eta); + m_trk_phi->push_back(tmp_trk_phi); + m_trk_z0 ->push_back(tmp_trk_z0); + m_trk_chi2 ->push_back(tmp_trk_chi2); + m_trk_nstub->push_back(tmp_trk_nstub); + m_trk_genuine->push_back(tmp_trk_genuine); + m_trk_unknown->push_back(tmp_trk_unknown); + m_trk_combinatoric->push_back(tmp_trk_combinatoric); + + } + + edm::Handle L1EmHandle; + iEvent.getByLabel(L1EmInputTag, L1EmHandle); + std::vector::const_iterator egIter; + + if ( L1EmHandle.isValid() ) { + //std::cout << "Found L1EmParticles"<begin();egIter!=L1EmHandle->end();++egIter) { + m_em_pt->push_back(egIter->pt()); + m_em_eta->push_back(egIter->eta()); + m_em_phi->push_back(egIter->phi()); + } + } + else { + std::cout << "Did not find L1EmParticles"<Fill(); + + +} // end of analyze() + + +/////////////////////////// +// DEFINE THIS AS A PLUG-IN +DEFINE_FWK_MODULE(L1TkEmTauNtupleMaker); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackTauAnalyzer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackTauAnalyzer.cc new file mode 100644 index 0000000000000..a0b2352249615 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/L1TrackTauAnalyzer.cc @@ -0,0 +1,388 @@ +// -*- C++ -*- +// +// Package: L1TrackTriggerObjectsAnalyzer +// Class: L1TrackTriggerObjectsAnalyzer +// +/**\class L1TrackTriggerObjectsAnalyzer L1TrackTriggerObjectsAnalyzer.cc SLHCUpgradeSimulations/L1TrackTriggerObjectsAnalyzer/src/L1TrackTriggerObjectsAnalyzer.cc + + Description: [one line class summary] + + Implementation: + [Notes on implementation] +*/ +// +// Original Author: Emmanuelle Perez,40 1-A28,+41227671915, +// Created: Thu Nov 14 11:22:13 CET 2013 +// $Id$ +// +// + + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDAnalyzer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" + +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "DataFormats/Common/interface/Handle.h" + +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "FWCore/Utilities/interface/InputTag.h" + + +// Gen-level stuff: +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "SimDataFormats/GeneratorProducts/interface/HepMCProduct.h" +#include "DataFormats/Candidate/interface/Candidate.h" + + +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticleFwd.h" + +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" + +#include "TTree.h" +#include "TFile.h" +#include "TH1F.h" +#include "CommonTools/UtilAlgos/interface/TFileService.h" + + +using namespace l1extra; + + + +// +// class declaration +// + +class L1TrackTauAnalyzer : public edm::EDAnalyzer { +public: + + typedef L1TkTrack_PixelDigi_ L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + explicit L1TrackTauAnalyzer(const edm::ParameterSet&); + ~L1TrackTauAnalyzer(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + +private: + virtual void beginJob() ; + virtual void analyze(const edm::Event&, const edm::EventSetup&); + virtual void endJob() ; + + //virtual void beginRun(edm::Run const&, edm::EventSetup const&); + //virtual void endRun(edm::Run const&, edm::EventSetup const&); + //virtual void beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&); + //virtual void endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&); + + void getStableDaughters(const reco::Candidate & p, + std::vector& stabledaughters); + + int tauClass(std::vector& stabledaughters); + + + // ----------member data --------------------------- + + + TTree* eventTree; + + //reconstructed taus + std::vector* m_tau_pt; + std::vector* m_tau_eta; + std::vector* m_tau_phi; + std::vector* m_tau_z; + + //generated taus + std::vector* m_taugen_pt; + std::vector* m_taugen_eta; + std::vector* m_taugen_phi; + std::vector* m_taugen_etvis; + std::vector* m_taugen_z; + std::vector* m_taugen_class; + + + // for L1TkTauParticles + edm::InputTag L1TkTauInputTag; + +}; + +// +// constants, enums and typedefs +// + +// +// static data member definitions +// + +// +// constructors and destructor +// +L1TrackTauAnalyzer::L1TrackTauAnalyzer(const edm::ParameterSet& iConfig) + +{ + //now do what ever initialization is needed + + + L1TkTauInputTag = iConfig.getParameter("L1TkTauInputTag"); + +} + + +L1TrackTauAnalyzer::~L1TrackTauAnalyzer() +{ + + // do anything here that needs to be done at desctruction time + // (e.g. close files, deallocate resources etc.) + +} + + +// +// member functions +// + +int L1TrackTauAnalyzer::tauClass(std::vector& stabledaughters) { + + // -999 means not classified + // 1 means electron + // 2 means muon + // 3 means had 1 prong + // 4 means had 3 prong + // 5 means had 5 prong + + if (stabledaughters[1]->pdgId()==11||stabledaughters[1]->pdgId()==-11) return 1; + if (stabledaughters[1]->pdgId()==13||stabledaughters[1]->pdgId()==-13) return 2; + + int nprong=0; + + for (unsigned int i=0;ipdgId()==211||stabledaughters[i]->pdgId()==-211) nprong++; + } + + if (nprong==1) return 3; + if (nprong==3) return 4; + if (nprong==5) return 5; + + return -999; + +} + + +void L1TrackTauAnalyzer::getStableDaughters(const reco::Candidate & p, + std::vector& stabledaughters){ + + int ndaug=p.numberOfDaughters(); + + for(int j=0;jstatus()==1) { + stabledaughters.push_back(daug); + } + else { + getStableDaughters(*daug,stabledaughters); + } + } + +} + +// ------------ method called for each event ------------ +void +L1TrackTauAnalyzer::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + using namespace edm; + using namespace reco; + + m_tau_pt->clear(); + m_tau_eta->clear(); + m_tau_phi->clear(); + m_tau_z->clear(); + + m_taugen_pt->clear(); + m_taugen_eta->clear(); + m_taugen_phi->clear(); + m_taugen_etvis->clear(); + m_taugen_z->clear(); + m_taugen_class->clear(); + + + //std::cout << " ---- a new event ----- " << std::endl; + + Handle genParticles; + iEvent.getByLabel("genParticles", genParticles); + for(size_t i = 0; i < genParticles->size(); ++ i) { + const GenParticle & p = (*genParticles)[i]; + int id = p.pdgId(); + //int st = p.status(); + double eta=p.p4().eta(); + double phi=p.p4().phi(); + double pt=p.p4().pt(); + if (!(id==15||id==-15)) continue; + int nmother=p.numberOfMothers(); + if (nmother!=1) continue; + if (abs(p.mother(0)->pdgId())==15) continue; + + double vz = p.vz(); + + std::vector stabledaughters; + + getStableDaughters(p,stabledaughters); + int tauclass=tauClass(stabledaughters); + + double etvis=0.0; + for(unsigned int j=0;jpdgId())==16) continue; + etvis+=stabledaughters[j]->p4().pt(); + //std::cout << "daug: "<push_back(pt); + m_taugen_eta->push_back(eta); + m_taugen_phi->push_back(phi); + m_taugen_etvis->push_back(etvis); + m_taugen_z->push_back(vz); + m_taugen_class->push_back(tauclass); + + + } + + // + // ---------------------------------------------------------------------- + // retrieve the L1TkTau objects + // + + + edm::Handle L1TkTausHandle; + iEvent.getByLabel(L1TkTauInputTag, L1TkTausHandle); + std::vector::const_iterator tauIter ; + + + if ( L1TkTausHandle.isValid() ) { + //std::cout << " ----- L1TkTauParticle objects ----- " << std::endl; + for (tauIter = L1TkTausHandle -> begin(); tauIter != L1TkTausHandle->end(); ++tauIter) { + float et = tauIter -> pt(); + float phi = tauIter -> phi(); + float eta = tauIter -> eta(); + float z = 0.0; + + if (!tauIter->getTrkPtr().isNull()) { + z=tauIter->getTrkPtr()->getPOCA().z(); + } + + m_tau_pt->push_back(et); + m_tau_phi->push_back(phi); + m_tau_eta->push_back(eta); + m_tau_z->push_back(z); + } + } else { + std::cout << "Did not find L1TkTauParticle collection"<Fill(); + +} + + +// ------------ method called once each job just before starting event loop ------------ +void +L1TrackTauAnalyzer::beginJob() +{ + + edm::Service fs; + + //reconstructed taus + m_tau_pt = new std::vector; + m_tau_eta = new std::vector; + m_tau_phi = new std::vector; + m_tau_z = new std::vector; + + //generated taus + m_taugen_pt = new std::vector; + m_taugen_eta = new std::vector; + m_taugen_phi = new std::vector; + m_taugen_etvis = new std::vector; + m_taugen_z = new std::vector; + m_taugen_class = new std::vector; + + + eventTree = fs->make("eventTree","Event Tree"); + + eventTree->Branch("tau_pt",&m_tau_pt); + eventTree->Branch("tau_eta",&m_tau_eta); + eventTree->Branch("tau_phi",&m_tau_phi); + eventTree->Branch("tau_z",&m_tau_z); + + eventTree->Branch("taugen_pt",&m_taugen_pt); + eventTree->Branch("taugen_eta",&m_taugen_eta); + eventTree->Branch("taugen_phi",&m_taugen_phi); + eventTree->Branch("taugen_etvis",&m_taugen_etvis); + eventTree->Branch("taugen_z",&m_taugen_z); + eventTree->Branch("taugen_class",&m_taugen_class); + + +} + +// ------------ method called once each job just after ending the event loop ------------ +void +L1TrackTauAnalyzer::endJob() +{ +} + +// ------------ method called when starting to processes a run ------------ +/* +void +L1TrackTauAnalyzer::beginRun(edm::Run const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a run ------------ +/* +void +L1TrackTauAnalyzer::endRun(edm::Run const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void +L1TrackTauAnalyzer::beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void +L1TrackTauAnalyzer::endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) +{ +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void +L1TrackTauAnalyzer::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +//define this as a plug-in +DEFINE_FWK_MODULE(L1TrackTauAnalyzer); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py new file mode 100644 index 0000000000000..6daa029ec532b --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py @@ -0,0 +1,345 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) + +# +# This runs over a file that already contains the L1Tracks. +# +# It produces the following objects : +# - L1EG objects obtained by running the SLHCCaloTrigger sequence +# - this produces both the "old stage-2" and the "new stage-2" objects +# - collection of L1TkEmParticles - produces Trk-based isolated "photons" +# - collection of L1TkElectrons from L1TkElectronTrackProducer +# +# +# It also runs a trivial analyzer than prints the objects +# that have been created. + + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( +# '/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/PU140/SingleTau1p_E2023TTI_PU140_1.root', + ## + ## rate test sample: + ## + #'/store/mc/TTI2023Upg14D/Neutrino_Pt2to20_gun/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000/022FFF01-E4E0-E311-9DAD-002618943919.root', + #'/store/mc/TTI2023Upg14D/Neutrino_Pt2to20_gun/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v2/00000/0257B6AB-00E6-E311-A12F-0025905A6068.root', +## VBF H->tautau + '/store/mc/TTI2023Upg14D/VBF_HToTauTau_125_14TeV_powheg_pythia6/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v1/00000/00114910-0DE9-E311-B42B-0025905A60F4.root', + '/store/mc/TTI2023Upg14D/VBF_HToTauTau_125_14TeV_powheg_pythia6/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v1/00000/06B547C1-03E9-E311-864E-0025905A48D6.root', + '/store/mc/TTI2023Upg14D/VBF_HToTauTau_125_14TeV_powheg_pythia6/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v1/00000/0EFF9054-0CE9-E311-94C0-0025905A60F4.root', + '/store/mc/TTI2023Upg14D/VBF_HToTauTau_125_14TeV_powheg_pythia6/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v1/00000/16C00111-F8E8-E311-9E15-0025905A60F4.root', + '/store/mc/TTI2023Upg14D/VBF_HToTauTau_125_14TeV_powheg_pythia6/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v1/00000/2E87B579-0BE9-E311-AB95-0025905A60E0.root', + ) +) + +# --- root output +process.TFileService = cms.Service("TFileService", fileName = cms.string('TkEmTau.root'), closeFileFast = cms.untracked.bool(True)) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + + +# --------------------------------------------------------------------------- +# +# --- Recreate the L1Tracks to benefit from the latest updates + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') + +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.DefaultTrackingSequence ) + + +# --------------------------------------------------------------------------- + + + +# --------------------------------------------------------------------------- +# +# --- Produces the L1calo objects +# + # To produce L1EG objects corresponding to the "stage-2" algorithms: + # one runs the SLHCCaloTrigger sequence. This produces both the + # "old stage-2" objects (2x2 clustering) and the "new stage-2" + # objects (new clustering from JB Sauvan et al). Note that the + # efficiency of the latter is currently poor at very high PU. + +# The sequence SLHCCaloTrigger creates "stage-2" L1Taus. +# Two collections are created: +# a) ("SLHCL1ExtraParticles","Taus") +# b) ("SLHCL1ExtraParticles","IsoTaus") +# So far only the ("SLHCL1ExtraParticles","Taus") collection has been used. +# The ("SLHCL1ExtraParticles","IsoTaus") has not been looked yet. + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') + +process.load('Configuration/StandardSequences/L1HwVal_cff') +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") + +# bug fix for missing HCAL TPs in MC RAW +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + +process.slhccalo = cms.Path( process.RawToDigi + process.valHcalTriggerPrimitiveDigis+process.SLHCCaloTrigger) + + + # To produce L1EG objects corresponding + # to the Run-1 L1EG algorithm, one just needs to run + # L1Reco. The (Run-1) L1EG algorithm has already been + # run in the DIGI step of the production. + +process.load('Configuration.StandardSequences.L1Reco_cff') +process.L1Reco = cms.Path( process.l1extraParticles ) + +# +# --------------------------------------------------------------------------- + + +# -------------------------------------------------------------------------------------------- +# +# ---- Produce the L1EGCrystal clusters (code of Sasha Savin & Nick Smith) + + # first you need the ECAL RecHIts : +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.reconstruction_step = cms.Path( process.calolocalreco ) + +process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", + EtminForStore = cms.double(-1.0), + debug = cms.untracked.bool(False), + useECalEndcap = cms.bool(True) +) +process.pSasha = cms.Path( process.L1EGammaCrystalsProducer ) + +# -------------------------------------------------------------------------------------------- + + +# ---------------------------------------- stage - 2 calibrated taus ------------------- + +# Produce calibrated (eT-corrected) L1CaloTaus: +process.L1CaloTauCorrectionsProducer = cms.EDProducer("L1CaloTauCorrectionsProducer", + L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus") +) + +# -------------------------------------------------------------------------------- + + +# Setup the L1TkTauFromCalo producer: +process.L1TkTauFromCaloProducer = cms.EDProducer("L1TkTauFromCaloProducer", + #L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus"), + L1TausInputTag = cms.InputTag("L1CaloTauCorrectionsProducer","CalibratedTaus"), + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + L1TkTrack_ApplyVtxIso = cms.bool( True ), # Produce vertex-isolated L1TkTaus? + L1TkTrack_VtxIsoZ0Max = cms.double( 1.0 ), # Max vertex z for L1TkTracks for VtxIsolation [cm] + L1TkTrack_NStubsMin = cms.uint32( 5 ), # Min number of stubs per L1TkTrack [unitless] + L1TkTrack_PtMin_AllTracks = cms.double( 2.0 ), # Min pT applied on all L1TkTracks [GeV] + L1TkTrack_PtMin_SignalTracks = cms.double( 10.0), # Min pT applied on signal L1TkTracks [GeV] + L1TkTrack_PtMin_IsoTracks = cms.double( 2.0 ), # Min pT applied on isolation L1TkTracks [GeV] + L1TkTrack_RedChiSquareEndcapMax = cms.double( 5.0 ), # Max red-chi squared for L1TkTracks in Endcap + L1TkTrack_RedChiSquareBarrelMax = cms.double( 2.0 ), # Max red-chi squared for L1TkTracks in Barrel + L1TkTrack_VtxZ0Max = cms.double( 30.0 ), # Max vertex z for L1TkTracks [cm] + DeltaR_L1TkTau_L1TkTrack = cms.double( 0.10 ), # Cone size for L1TkTracks assigned to L1TkTau + DeltaR_L1TkTauIsolation = cms.double( 0.40 ), # Isolation cone size for L1TkTau + DeltaR_L1TkTau_L1CaloTau = cms.double( 0.15 ), # Matching cone for L1TkTau and L1CaloTau + L1CaloTau_EtMin = cms.double( 5.0 ), # Min eT applied on all L1CaloTaus [GeV] + RemoveL1TkTauTracksFromIsoCalculation = cms.bool( False ), # Remove tracks used in L1TkTau construction from VtxIso calculation? +) + +process.pCorr = cms.Path( process.L1CaloTauCorrectionsProducer ) +process.caloTaus = cms.Path( process.L1TkTauFromCaloProducer ) + + +# Setup the L1CaloTau producer: +process.L1CaloTauProducer = cms.EDProducer("L1CaloTausToTkTausTranslator", + L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus"), + #L1TausInputTag = cms.InputTag("L1CaloTauCorrectionsProducer","CalibratedTaus"), +) + +process.plaincaloTaus = cms.Path( process.L1CaloTauProducer ) + + +# -------------- Tracker only based taus ------------------------------------ + +process.L1TkTauFromL1Track = cms.EDProducer("L1TkTauFromL1TrackProducer", + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + ZMAX = cms.double( 25. ),# in cm + CHI2MAX = cms.double( 100. ), + PTMINTRA = cms.double( 2. ),# in GeV + DRmax = cms.double( 0.5 ), + nStubsmin = cms.int32( 5 ) # minimum number of stubs + ) + +process.tkOnlyTaus = cms.Path( process.L1TkTauFromL1Track ) + + + + +# --------------------------------------------------------------------------- + +# Now we produce L1TkEmParticles and L1TkElectrons + + +# ---- "photons" isolated w.r.t. L1Tracks : + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmParticleProducer_cfi") +process.pL1TkPhotons = cms.Path( process.L1TkPhotons ) + + + + +# --------------------------------------------------------------------------- + + +# Run a trivial analyzer that prints the objects + +#process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , +# L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here +# L1TkMuonsInputTag = cms.InputTag("L1TkMuons"), # dummy here +# L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here +# L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), +# L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), +# L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here +# L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI",""), # dummy here +# L1EmInputTag = cms.InputTag("l1ExtraCrystalProducer","EGammaCrystal") +#) +# +#process.pAna = cms.Path( process.ana ) + +process.tau = cms.EDAnalyzer( 'L1TkEmTauNtupleMaker' , + MyProcess = cms.int32(13), + DebugMode = cms.bool(False), + L1EmInputTag = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster") +) + +process.pTau = cms.Path( process.tau ) + + +process.tkemtau = cms.EDProducer( 'L1TkEmTauProducer' , + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + L1EmInputTag = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster"), + ptleadcut = cms.double(5.0), + ptleadcone = cms.double(0.3), + masscut = cms.double(1.77), + emptcut = cms.double(5.0), + trketacut = cms.double(2.3), + pttotcut = cms.double(5.0), + isocone = cms.double(0.25), + isodz = cms.double(0.6), + relisocut = cms.double(0.15), + chisqcut = cms.double(40.0), + nstubcut = cms.int32(5), + dzcut = cms.double(0.8) +) + +process.pTkemtau = cms.Path( process.tkemtau ) + + +process.tkemtauAnalyzer = cms.EDAnalyzer( 'L1TrackTauAnalyzer' , + L1TkTauInputTag = cms.InputTag("tkemtau","") +) + +process.ptkemtauAnalyzer = cms.Path( process.tkemtauAnalyzer ) + +process.L1TkTauFromCaloProducerAnalyzer = cms.EDAnalyzer( 'L1TrackTauAnalyzer' , + L1TkTauInputTag = cms.InputTag("L1TkTauFromCaloProducer","") +) + +process.pL1TkTauFromCaloProducerAnalyzer = cms.Path( process.L1TkTauFromCaloProducerAnalyzer ) + +process.L1TkTauFromL1TrackAnalyzer = cms.EDAnalyzer( 'L1TrackTauAnalyzer' , + L1TkTauInputTag = cms.InputTag("L1TkTauFromL1Track","") +) + +process.pL1TkTauFromL1TrackAnalyzer = cms.Path( process.L1TkTauFromL1TrackAnalyzer ) + + +process.L1CaloTauProducerAnalyzer = cms.EDAnalyzer( 'L1TrackTauAnalyzer' , + L1TkTauInputTag = cms.InputTag("L1CaloTauProducer","") +) + +process.pL1CaloTauProducerAnalyzer = cms.Path( process.L1CaloTauProducerAnalyzer ) + + + + +# --------------------------------------------------------------------------- + +# --- Output module : + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + + # raw data +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + + + # gen-level information +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +#process.Out.outputCommands.append('keep *_genParticles_*_*') + + + # the L1Tracks, clusters and stubs +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + + # the L1EG objects +#process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_*_*' ) +#process.Out.outputCommands.append('keep *_SLHCL1ExtraParticlesNewClustering_*_*') +#process.Out.outputCommands.append('keep l1extraL1Em*_l1extraParticles_*_*') + # for crystal-level granularity : +#process.Out.outputCommands.append('keep *_L1EGammaCrystalsProducer_*_*') +#process.Out.outputCommands.append('keep *_l1ExtraCrystalProducer_*_*') + + # the L1TkEmParticles +#process.Out.outputCommands.append('keep *_L1TkPhotons_*_*') + + # the L1TkElectrons +#process.Out.outputCommands.append('keep *_L1TkElectrons_*_*') +#process.Out.outputCommands.append('keep *_L1TkElectronsCrystal_*_*') # for crystal-level granularity +#process.Out.outputCommands.append('keep *_L1TkElectronsIsoEG_*_*') +#process.Out.outputCommands.append('keep *_L1TkIsoElectrons_*_*') + +#process.Out.outputCommands.append('keep *_L1TkElectronsLoose_*_*') +#process.Out.outputCommands.append('keep *_L1TkIsoElectronsLoose_*_*') +#process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') + + +# --- to use the genParticles, one needs to keep the collections of associators below: +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + +#process.Out.outputCommands.append('keep *_*_*_*' ) +#process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + From 20730ad032bcb4fd9e985aaa8dfff718981388ce Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Wed, 2 Jul 2014 19:35:45 +0200 Subject: [PATCH 060/252] updates from Alexandros --- .../plugins/L1TkTauFromCaloProducer.cc | 545 ++++++++---------- .../python/L1CaloTauSequences_cfi.py | 18 +- .../L1TrackTrigger/test/test_L1TkEmTau_cfg.py | 3 +- 3 files changed, 256 insertions(+), 310 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc index 59aaa4bf765db..02dd99a73873b 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc @@ -23,13 +23,13 @@ #include "FWCore/ParameterSet/interface/ParameterSet.h" #include "DataFormats/L1TrackTrigger/interface/L1TkTauParticle.h" #include "DataFormats/L1TrackTrigger/interface/L1TkTauParticleFwd.h" -#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" // new +#include "DataFormats/L1TrackTrigger/interface/L1TkPrimaryVertex.h" #include "DataFormats/Math/interface/LorentzVector.h" #include "DataFormats/Math/interface/deltaR.h" #include "DataFormats/Math/interface/deltaPhi.h" -#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" // new +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" // for L1Tracks: -#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" //for 'L1TkTrack_PixelDigi_Collection', etc.. +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" #include "DataFormats/HepMCCandidate/interface/GenParticle.h" using namespace l1extra ; @@ -40,9 +40,10 @@ class L1TkTauFromCaloProducer : public edm::EDProducer { typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; typedef edm::Ptr< L1TkTrackType > L1TkTrackRefPtr; - typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; - typedef edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > L1TkStubRef; //new - + typedef std::vector< L1TkTrackType > L1TkTrack_Collection; + typedef std::vector< L1TkTrackRefPtr > L1TkTrackRefPtr_Collection; + typedef edm::Ref< edmNew::DetSetVector< TTStub< Ref_PixelDigi_ > >, TTStub< Ref_PixelDigi_ > > L1TkStubRef; + explicit L1TkTauFromCaloProducer(const edm::ParameterSet&); ~L1TkTauFromCaloProducer(); @@ -56,56 +57,26 @@ class L1TkTauFromCaloProducer : public edm::EDProducer { }; struct IsBelowTrackPtThreshold{ - float ptMinTrack; - bool operator()(const L1TkTrackRefPtr track) { return track->getMomentum().perp() < ptMinTrack; } - }; - - struct IsAboveChi2RedMaxThreshold{ - float chi2RedMaxNoEndcapStub; - float chi2RedMaxWithEndcapStub; - float chi2RedMax; - bool operator()(const L1TkTrackRefPtr track) { - - /// Get the number of the L1TkTracks_Stubs - std::vector< L1TkStubRef > theStubs = track -> getStubRefs(); - unsigned int nStubs = (int) theStubs.size(); //new - bool bHasEndcap = false; - - /// For-loop: L1TkTracks Stubs - for ( unsigned int jStub = 0; jStub < nStubs; jStub++ ){ - - /// Get the detector id for the stub (barrel / endcap) - StackedTrackerDetId thisDetId( theStubs.at(jStub)->getDetId() ); //new - - if ( thisDetId.isEndcap() ){ - bHasEndcap = true; - break; - } - - } //For-loop: L1TkTracks Stubs - - /// Apply stub quality criteria for the L1TkTracks. - if ( bHasEndcap ){ chi2RedMax = chi2RedMaxWithEndcapStub; } - else{ chi2RedMax = chi2RedMaxNoEndcapStub; } - return track->getChi2Red() > chi2RedMax; - } - }; - - struct IsBelowNStubsMinThreshold{ - unsigned int nStubsMin; - bool operator()(const L1TkTrackRefPtr track) { return track->getStubRefs().size() < nStubsMin; } //new + float ptMin; + bool operator()(const L1TkTrackRefPtr track) { return track->getMomentum().perp() < ptMin; } }; - struct IsAboveVtxZ0MaxThreshold{ - float vtxZ0Max; - bool operator()(const L1TkTrackRefPtr track) { return fabs(track->getPOCA().z()) > vtxZ0Max; } //new + struct IsAboveTrackPtThreshold{ + float ptMax; + bool operator()(const L1TkTrackRefPtr track) { return track->getMomentum().perp() > ptMax; } }; struct TrackFoundInTkClusterMap{ std::map< L1TkTrackRefPtr, unsigned int > m_TrackToCluster; bool operator()(const L1TkTrackRefPtr track) { return m_TrackToCluster.find( track ) != m_TrackToCluster.end(); } }; - + + struct CaloTauEtComparator{ + bool operator() (const l1extra::L1JetParticle tauA, const l1extra::L1JetParticle tauB) const + { + return ( tauA.et() > tauB.et() ); + } + }; private: virtual void beginJob() ; @@ -113,22 +84,26 @@ class L1TkTauFromCaloProducer : public edm::EDProducer { virtual void endJob() ; // ---------- member data ---------- // - edm::InputTag L1TausInputTag; - edm::InputTag L1TrackInputTag; - unsigned int L1TkTrack_NStubsMin; // Min number of stubs per Track (unitless) - double L1TkTrack_PtMin_AllTracks; // Min pT of tracks to consider [GeV] - double L1TkTrack_PtMin_SignalTracks; // Min pT applied on signal L1TkTracks [GeV] - double L1TkTrack_PtMin_IsoTracks; // Min pT applied on isolation L1TkTracks [GeV] - double L1TkTrack_RedChiSquareEndcapMax; // Max chi squared for L1TkTracks in Endcap [unitless] - double L1TkTrack_RedChiSquareBarrelMax; // Max chi squared for L1TkTracks in Barrel [unitless] - bool L1TkTrack_ApplyVtxIso; // Produce isolated L1TkTaus (True) or just L1TkTaus (False). - double L1TkTrack_VtxIsoZ0Max; // Max vertex z for L1TkTracks for VtxIsolation [cm] - double L1TkTrack_VtxZ0Max; // Max vertex z for L1TkTracks [cm] - double DeltaR_L1TkTau_L1TkTrack; // Cone size for assigning L1TkTracks to L1TkTau candidate [unitless] - double DeltaR_L1TkTauIsolation; // Isolation cone size for L1TkTau [unitless] - double DeltaR_L1TkTau_L1CaloTau; // Cone size for matching L1TkTau to L1CaloTau [unitless] + /// Parameters whose values are given through the python cfg file + edm::InputTag cfg_L1TausInputTag; // Tag of Collection to be used for L1 Calorimeter Taus + edm::InputTag cfg_L1TrackInputTag; // Tag of Collection to be used for L1 Track Trigger Tracks + unsigned int cfg_L1TkTrack_NStubsMin; // Min number of stubs per L1TkTrack [unitless] + double cfg_L1TkTrack_PtMin_AllTracks; // Min pT applied on all L1TkTracks [GeV] + double cfg_L1TkTrack_PtMin_SignalTracks; // Min pT applied on signal L1TkTracks [GeV] + double cfg_L1TkTrack_PtMin_IsoTracks; // Min pT applied on isolation L1TkTracks [GeV] + double cfg_L1TkTrack_RedChiSquareEndcapMax; // Max chi squared for L1TkTracks in Endcap [unitless] + double cfg_L1TkTrack_RedChiSquareBarrelMax; // Max chi squared for L1TkTracks in Barrel [unitless] + bool cfg_L1TkTrack_ApplyVtxIso; // Produce isolated L1TkTaus (True) or just L1TkTaus (False). + double cfg_L1TkTrack_VtxIsoZ0Max; // Max vertex z for L1TkTracks for VtxIsolation [cm] + double cfg_L1TkTrack_VtxZ0Max; // Max vertex z for L1TkTracks [cm] + double cfg_DeltaR_L1TkTau_L1TkTrack; // Cone size for assigning L1TkTracks to L1TkTau candidate [unitless] + double cfg_DeltaR_L1TkTau_L1CaloTau; // Matching cone for L1TkTau and L1CaloTau [unitless] + double cfg_DeltaR_L1TkTau_Isolation_Min; // Isolation cone size for L1TkTau [unitless]. If ">0" the isolation cone becomes an isolation annulus (default=0.1) + double cfg_DeltaR_L1TkTau_Isolation_Max; // Isolation cone size for L1TkTau [unitless] (default=0.4) + bool cfg_RemoveL1TkTauTracksFromIsoCalculation; // Remove tracks used in L1TkTau construction from isolation calculation? + double L1CaloTau_EtMin; // Min eT applied on all L1CaloTaus [GeV] - bool RemoveL1TkTauTracksFromIsoCalculation; // Remove tracks used in L1TkTau construction from isolation calculation? + } ; @@ -136,23 +111,27 @@ class L1TkTauFromCaloProducer : public edm::EDProducer { // ------------ constructor ------------ // L1TkTauFromCaloProducer::L1TkTauFromCaloProducer(const edm::ParameterSet& iConfig){ - L1TausInputTag = iConfig.getParameter("L1TausInputTag"); - L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); - L1TkTrack_NStubsMin = (unsigned int)iConfig.getParameter("L1TkTrack_NStubsMin"); - L1TkTrack_PtMin_AllTracks = iConfig.getParameter("L1TkTrack_PtMin_AllTracks"); - L1TkTrack_PtMin_SignalTracks = iConfig.getParameter("L1TkTrack_PtMin_SignalTracks"); - L1TkTrack_PtMin_IsoTracks = iConfig.getParameter("L1TkTrack_PtMin_IsoTracks"); - L1TkTrack_RedChiSquareEndcapMax = iConfig.getParameter< double >("L1TkTrack_RedChiSquareEndcapMax"); - L1TkTrack_RedChiSquareBarrelMax = iConfig.getParameter< double >("L1TkTrack_RedChiSquareBarrelMax"); - L1TkTrack_ApplyVtxIso = iConfig.getParameter< bool >("L1TkTrack_ApplyVtxIso"); - L1TkTrack_VtxIsoZ0Max = iConfig.getParameter< double >("L1TkTrack_VtxIsoZ0Max"); - L1TkTrack_VtxZ0Max = iConfig.getParameter< double >("L1TkTrack_VtxZ0Max"); - DeltaR_L1TkTau_L1TkTrack = iConfig.getParameter< double >("DeltaR_L1TkTau_L1TkTrack"); - DeltaR_L1TkTauIsolation = iConfig.getParameter< double >("DeltaR_L1TkTauIsolation"); - DeltaR_L1TkTau_L1CaloTau = iConfig.getParameter< double >("DeltaR_L1TkTau_L1CaloTau"); + cfg_L1TausInputTag = iConfig.getParameter("L1TausInputTag"); + cfg_L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + cfg_L1TkTrack_NStubsMin = (unsigned int)iConfig.getParameter< uint32_t >("L1TkTrack_NStubsMin"); + cfg_L1TkTrack_PtMin_AllTracks = iConfig.getParameter< double >("L1TkTrack_PtMin_AllTracks"); + cfg_L1TkTrack_PtMin_SignalTracks = iConfig.getParameter< double >("L1TkTrack_PtMin_SignalTracks"); + cfg_L1TkTrack_PtMin_IsoTracks = iConfig.getParameter< double >("L1TkTrack_PtMin_IsoTracks"); + cfg_L1TkTrack_RedChiSquareEndcapMax = iConfig.getParameter< double >("L1TkTrack_RedChiSquareEndcapMax"); + cfg_L1TkTrack_RedChiSquareBarrelMax = iConfig.getParameter< double >("L1TkTrack_RedChiSquareBarrelMax"); + cfg_L1TkTrack_ApplyVtxIso = iConfig.getParameter< bool >("L1TkTrack_ApplyVtxIso"); + cfg_L1TkTrack_VtxIsoZ0Max = iConfig.getParameter< double >("L1TkTrack_VtxIsoZ0Max"); + cfg_L1TkTrack_VtxZ0Max = iConfig.getParameter< double >("L1TkTrack_VtxZ0Max"); + cfg_DeltaR_L1TkTau_L1TkTrack = iConfig.getParameter< double >("DeltaR_L1TkTau_L1TkTrack"); + cfg_DeltaR_L1TkTau_L1CaloTau = iConfig.getParameter< double >("DeltaR_L1TkTau_L1CaloTau"); + cfg_DeltaR_L1TkTau_Isolation_Min = iConfig.getParameter< double >("DeltaR_L1TkTau_Isolation_Min"); + cfg_DeltaR_L1TkTau_Isolation_Max = iConfig.getParameter< double >("DeltaR_L1TkTau_Isolation_Max"); + cfg_RemoveL1TkTauTracksFromIsoCalculation = iConfig.getParameter< bool >("RemoveL1TkTauTracksFromIsoCalculation"); + L1CaloTau_EtMin = iConfig.getParameter< double >("L1CaloTau_EtMin"); - RemoveL1TkTauTracksFromIsoCalculation = iConfig.getParameter< bool >("RemoveL1TkTauTracksFromIsoCalculation"); + produces(); + // produces("Tau").setBranchAlias( "Tau"); } @@ -166,288 +145,256 @@ void L1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& using namespace std; std::auto_ptr result(new L1TkTauParticleCollection); - /// Collection Handles: The L1TkTracks the PixelDigi collection - typedef std::vector< L1TkTrackType > L1TkTrack_PixelDigi_MyCollection; - edm::Handle< L1TkTrack_PixelDigi_MyCollection > h_PixelDigi_L1TkTrack; //new - iEvent.getByLabel( L1TrackInputTag, h_PixelDigi_L1TkTrack ); - L1TkTrack_PixelDigi_MyCollection::const_iterator L1TkTrack; - /// Collection Handles: The L1CaloTau from the L1 ExtraParticles + // ------------ Declaratations ------------ // + // double nan = std::numeric_limits::quiet_NaN(); + + /// First element is a L1TkTrack, second element is the index of the cluster it belongs to + std::map< L1TkTrackRefPtr, unsigned int > m_L1TkTrackToL1TkCluster; + + /// First element is an index of the cluster a L1TkTrack belongs to, second element is a vector of L1TkTrack_Ptrs (reverse of m_L1TkTrackToL1TkCluster) + std::map< unsigned int, std::vector< L1TkTrackRefPtr > > m_L1TkClusterToL1TkTracks; + + /// First element is the L1 Calo Tau, second element is the index of the closest (if matched, if any) L1 Tracker Track Cluster + std::map< edm::Ptr< l1extra::L1JetParticle >, unsigned int > m_L1CaloTauToMatchedL1TkCluster; + + /// L1CaloTau edm::Handle< std::vector< l1extra::L1JetParticle > > h_L1CaloTau; - iEvent.getByLabel( L1TausInputTag, h_L1CaloTau ); + iEvent.getByLabel( cfg_L1TausInputTag, h_L1CaloTau ); - /// Define maps and their iterators - std::map< L1TkTrackRefPtr, unsigned int > m_L1TkTrackToL1TkCluster; // L1TkTrackRefPtr --> Cluster index it belongs to - std::map< L1TkTrackRefPtr, unsigned int >::const_iterator it_L1TkTrackToL1TkCluster; - - std::map< unsigned int, std::vector< L1TkTrackRefPtr > > m_L1TkClusterToL1TkTracks; // Reverse of m_L1TkTrackToL1TkCluster - std::map< unsigned int, std::vector< L1TkTrackRefPtr > >::const_iterator it_L1TkClusterToL1TkTracks; + // ------------ L1TkTracks ------------ // + edm::Handle< L1TkTrack_Collection > h_PixelDigi_L1TkTrack; + iEvent.getByLabel( cfg_L1TrackInputTag, h_PixelDigi_L1TkTrack ); - /// L1TkTracks: Quality Criteria - //////////////////////////////// - std::vector< L1TkTrackRefPtr > v_L1TkTracks_wQuality; - unsigned int iL1TkTrack = 0; + L1TkTrackRefPtr_Collection c_L1TkTracks_Quality; + unsigned int track_counter = 0; /// For-loop: L1TkTracks - for ( L1TkTrack = h_PixelDigi_L1TkTrack->begin(); L1TkTrack != h_PixelDigi_L1TkTrack->end(); L1TkTrack++ ){ - + for ( L1TkTrack_Collection::const_iterator track = h_PixelDigi_L1TkTrack->begin(); track != h_PixelDigi_L1TkTrack->end(); track++ ){ + /// Make a pointer to the L1TkTracks - L1TkTrackRefPtr L1TkTrack_Ptr( h_PixelDigi_L1TkTrack, iL1TkTrack++); + L1TkTrackRefPtr track_RefPtr( h_PixelDigi_L1TkTrack, track_counter++); - /// Get the number of stubs of the L1TkTracks - std::vector< L1TkStubRef > L1TkTrackStubs = L1TkTrack -> getStubRefs() ; - unsigned int L1TkTrack_NStubs = L1TkTrackStubs.size(); - double L1TkTrack_Pt = L1TkTrack->getMomentum().perp(); - double L1TkTrack_VtxZ0 = L1TkTrack->getPOCA().z(); - bool L1TkTrack_HasEndcap = false; - bool L1TkTrack_HasBarrel = false; - - /// Apply user-defined L1TkTracks quality criteria - if ( L1TkTrack_NStubs < L1TkTrack_NStubsMin ){ continue; } - if ( L1TkTrack_Pt < L1TkTrack_PtMin_AllTracks ){ continue; } - if ( fabs( L1TkTrack_VtxZ0 ) > L1TkTrack_VtxZ0Max ){ continue; } - - /// Nested for-loop: L1TkTrack Stubs - for ( unsigned int iStub = 0; iStub < L1TkTrack_NStubs; iStub++ ){ - + /// Declare for-loop variables + std::vector< L1TkStubRef > track_Stubs = track -> getStubRefs(); + unsigned int track_NStubs = track_Stubs.size(); + double track_Pt = track->getMomentum().perp(); + double track_VtxZ0 = track->getPOCA().z(); + double track_RedChiSq = track->getChi2Red(); + bool track_HasEndcapStub = false; + bool track_HasBarrelStub = false; + + /// Apply L1TkTracks quality criteria + if ( track_Pt < cfg_L1TkTrack_PtMin_AllTracks ){ continue; } + if ( track_NStubs < cfg_L1TkTrack_NStubsMin ){ continue; } + if ( fabs( track_VtxZ0 ) > cfg_L1TkTrack_VtxZ0Max ){ continue; } + + /// For-loop (nested): L1TkTrack Stubs + for ( unsigned int iStub = 0; iStub < track_NStubs; iStub++ ){ + /// Get the detector id for the stub (barrel / endcap) - StackedTrackerDetId thisDetId( L1TkTrackStubs.at(iStub)->getDetId() ); - if ( thisDetId.isEndcap() ){ L1TkTrack_HasEndcap = true; } - if ( thisDetId.isBarrel() ){ L1TkTrack_HasBarrel = true; } - - } // nested for-loop: L1TkTrack Stubs + StackedTrackerDetId thisDetId( track_Stubs.at(iStub)->getDetId() ); + if ( thisDetId.isEndcap() ){ track_HasEndcapStub = true; } + if ( thisDetId.isBarrel() ){ track_HasBarrelStub = true; } - /// Apply user-defined L1TkTracks stub quality criteria - if ( ( L1TkTrack_HasEndcap ) && ( L1TkTrack->getChi2Red() > L1TkTrack_RedChiSquareEndcapMax ) ){ continue; } - if ( ( L1TkTrack_HasBarrel ) && ( L1TkTrack->getChi2Red() > L1TkTrack_RedChiSquareBarrelMax ) ){ continue; } + } /// For-loop (nested): L1TkTrack Stubs - v_L1TkTracks_wQuality.push_back( L1TkTrack_Ptr ); - + /// Apply L1TkTracks Stubs quality criteria + if ( ( track_HasEndcapStub ) && ( track_RedChiSq > cfg_L1TkTrack_RedChiSquareEndcapMax ) ){ continue; } + if ( ( track_HasBarrelStub ) && ( track_RedChiSq > cfg_L1TkTrack_RedChiSquareBarrelMax ) ){ continue; } + + /// Beyond this point we should only have the user-defined quality L1TkTracks + c_L1TkTracks_Quality.push_back( track_RefPtr ); + } // For-loop: L1TkTracks + /// Sort by pT all selected L1TkTracks + std::sort( c_L1TkTracks_Quality.begin(), c_L1TkTracks_Quality.end(), TrackPtComparator() ); - /// Sort the quality L1TkTrack with pT - std::sort( v_L1TkTracks_wQuality.begin(), v_L1TkTracks_wQuality.end(), TrackPtComparator() ); - - - /// L1TkTracks: Isolation Cone - ////////////////////////////// - std::vector< L1TkTrackRefPtr > v_L1TkTracks_IsoCone = v_L1TkTracks_wQuality; - /// Apply min pt requirement - IsBelowTrackPtThreshold L1TkTracks_PtFilterIso; - L1TkTracks_PtFilterIso.ptMinTrack = L1TkTrack_PtMin_IsoTracks; - v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_PtFilterIso ), v_L1TkTracks_IsoCone.end() ); + // ------------ L1TkTracks (Isolation Cone) ------------ // + IsAboveTrackPtThreshold filter_IsAboveTrackPtThreshold; + L1TkTrackRefPtr_Collection c_L1TkTracks_IsoCone = c_L1TkTracks_Quality; + filter_IsAboveTrackPtThreshold.ptMax = cfg_L1TkTrack_PtMin_SignalTracks; + c_L1TkTracks_IsoCone.erase( remove_if( c_L1TkTracks_IsoCone.begin(), c_L1TkTracks_IsoCone.end(), filter_IsAboveTrackPtThreshold ), c_L1TkTracks_IsoCone.end() ); + + /// Sort tracks by pT + std::sort( c_L1TkTracks_IsoCone.begin(), c_L1TkTracks_IsoCone.end(), TrackPtComparator() ); - // /// Apply max reduced chi squared requirement - // IsAboveChi2RedMaxThreshold L1TkTracks_Chi2RedFilter; - // L1TkTracks_Chi2RedFilter.chi2RedMaxNoEndcapStub = L1TkTrack_RedChiSquareBarrelMax; - // L1TkTracks_Chi2RedFilter.chi2RedMaxWithEndcapStub = L1TkTrack_RedChiSquareEndcapMax; - // v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_Chi2RedFilter ), v_L1TkTracks_IsoCone.end()); - // /// Apply min number of stubs requirement - // IsBelowNStubsMinThreshold L1TkTracks_NStubsMinFilter; - // L1TkTracks_NStubsMinFilter.nStubsMin = L1TkTrack_NStubsMin; - // v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_NStubsMinFilter ), v_L1TkTracks_IsoCone.end()); + // ------------ L1TkTracks (Signal Cone) ------------ // + IsBelowTrackPtThreshold filter_IsBelowTrackPtThreshold; + L1TkTrackRefPtr_Collection c_L1TkTracks_SignalCone = c_L1TkTracks_Quality; + filter_IsBelowTrackPtThreshold.ptMin = cfg_L1TkTrack_PtMin_SignalTracks; + c_L1TkTracks_SignalCone.erase( remove_if( c_L1TkTracks_SignalCone.begin(), c_L1TkTracks_SignalCone.end(), filter_IsBelowTrackPtThreshold ), c_L1TkTracks_SignalCone.end() ); - // /// Apply max vertex-z requirement - // IsAboveVtxZ0MaxThreshold L1TkTracks_VtxZ0MaxFilter; - // L1TkTracks_VtxZ0MaxFilter.vtxZ0Max = L1TkTrack_VtxZ0Max; - // v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_VtxZ0MaxFilter ), v_L1TkTracks_IsoCone.end()); + /// Sort tracks by pT + std::sort( c_L1TkTracks_SignalCone.begin(), c_L1TkTracks_SignalCone.end(), TrackPtComparator() ); - /// L1TkTracks: Signal Cone - /////////////////////////// - std::vector< L1TkTrackRefPtr > v_L1TkTracks_Signal = v_L1TkTracks_wQuality; - - /// Apply min pt requirement - IsBelowTrackPtThreshold L1TkTracks_PtFilterSignal; - L1TkTracks_PtFilterSignal.ptMinTrack = L1TkTrack_PtMin_SignalTracks; - v_L1TkTracks_Signal.erase( remove_if(v_L1TkTracks_Signal.begin(), v_L1TkTracks_Signal.end(), L1TkTracks_PtFilterSignal ), v_L1TkTracks_Signal.end() ); + // ------------ L1TkTau Cluster: Construction ------------ // + unsigned int nL1TkTaus = 0; - /// L1TkTau: Cluster Construction - ///////////////////////////////// - unsigned int nL1TkTauClusters = 0; - /// For-loop: L1TkTracks - for ( unsigned int iTrack = 0; iTrack < v_L1TkTracks_Signal.size(); iTrack++ ){ + /// For-loop: L1TkTracks (Signal Cone) + for ( unsigned int i=0; i < c_L1TkTracks_SignalCone.size(); i++ ){ - L1TkTrackRefPtr ldgTk = v_L1TkTracks_Signal.at(iTrack); + L1TkTrackRefPtr iTrack = c_L1TkTracks_SignalCone.at(i); /// Determine if track has already been assigned to a cluster - bool bLdgTkFoundInTkClusterMap = m_L1TkTrackToL1TkCluster.find( ldgTk ) != m_L1TkTrackToL1TkCluster.end(); - if ( bLdgTkFoundInTkClusterMap == true ){ continue; } + bool bTrackFoundInTkClusterMap = m_L1TkTrackToL1TkCluster.find( iTrack ) != m_L1TkTrackToL1TkCluster.end(); + if ( bTrackFoundInTkClusterMap == true ){ continue; } + + /// If track has not already been assigned to a cluster then this is a new cluster + nL1TkTaus++; - /// Add L1TkTrack to the L1TkTau Cluster - nL1TkTauClusters++; - m_L1TkTrackToL1TkCluster.insert( std::make_pair( ldgTk, nL1TkTauClusters ) ); + /// Add this (leading) L1TkTrack to the L1TkTau Cluster. Increment L1TkTau Cluster counter + m_L1TkTrackToL1TkCluster.insert( std::make_pair( iTrack, nL1TkTaus ) ); /// Get the L1TkTrack properties - double ldgTk_Eta = ldgTk->getMomentum().eta(); - double ldgTk_Phi = ldgTk->getMomentum().phi(); + double ldgTrack_Eta = iTrack->getMomentum().eta(); + double ldgTrack_Phi = iTrack->getMomentum().phi(); - /// Nested for-loop: L1TkTracks - for ( unsigned int jTrack = 0; jTrack < v_L1TkTracks_Signal.size(); jTrack++ ){ + /// For-loop (nested): L1TkTracks (Signal Cone) + for ( unsigned int j=0; j < c_L1TkTracks_SignalCone.size(); j++ ){ - L1TkTrackRefPtr tkToAdd = v_L1TkTracks_Signal.at(jTrack); - - /// Skip if L1TkTrack is identical to ldgTk or if previously used in another L1TkTau Cluster - if ( ldgTk.get() == tkToAdd.get() ){ continue; } - bool bTKFoundInTkClusterMap = m_L1TkTrackToL1TkCluster.find( tkToAdd ) != m_L1TkTrackToL1TkCluster.end(); - if ( bTKFoundInTkClusterMap == true ){ continue; } + /// Skip identical L1TkTracks + L1TkTrackRefPtr jTrack = c_L1TkTracks_SignalCone.at(j); + if ( iTrack.get() == jTrack.get() ){ continue; } - /// Check if the L1TkTrack is inside L1TkTau signal cone (around ldgTk). If yes add it to the L1TkTau Cluster - double tkToAdd_Eta = tkToAdd->getMomentum().eta(); - double tkToAdd_Phi = tkToAdd->getMomentum().phi(); - double deltaR = reco::deltaR(ldgTk_Eta, ldgTk_Phi, tkToAdd_Eta, tkToAdd_Phi); - if ( deltaR > DeltaR_L1TkTau_L1TkTrack ){ continue; } - m_L1TkTrackToL1TkCluster.insert( std::make_pair( tkToAdd, nL1TkTauClusters ) ); + /// If this track was used already in another L1TkTau Cluster, skip it. + bool bTrackFoundInTkClusterMap = m_L1TkTrackToL1TkCluster.find( jTrack ) != m_L1TkTrackToL1TkCluster.end(); + if ( bTrackFoundInTkClusterMap == true ){ continue; } + + /// Get the L1TkTrack direction and distance to the ldg L1TkTrack of the L1TkTau + double track_Eta = jTrack->getMomentum().eta(); + double track_Phi = jTrack->getMomentum().phi(); + double deltaR = reco::deltaR(ldgTrack_Eta, ldgTrack_Phi, track_Eta, track_Phi); + + /// If L1TkTrack is outside the signal cone, skip it. Otherwise, add it to the L1TkTau Cluster. + if ( deltaR > cfg_DeltaR_L1TkTau_L1TkTrack ){ continue; } + m_L1TkTrackToL1TkCluster.insert( std::make_pair( jTrack, nL1TkTaus ) ); - } /// Nested for-loop: L1TkTracks - - } /// For-loop: L1TkTracks - - + } /// For-loop (nested): L1TkTracks (Signal Cone) + } /// For-loop: L1TkTracks (Signal Cone) + + /// Remove L1TkTracks from the Isolation-Cone L1TkTrack-Collection if they have been used in L1TkTau Clusters + TrackFoundInTkClusterMap filter_TkFoundInTkCluster; + filter_TkFoundInTkCluster.m_TrackToCluster = m_L1TkTrackToL1TkCluster; + if( cfg_RemoveL1TkTauTracksFromIsoCalculation == true ) { + c_L1TkTracks_IsoCone.erase( remove_if( c_L1TkTracks_IsoCone.begin(), c_L1TkTracks_IsoCone.end(), filter_TkFoundInTkCluster ), c_L1TkTracks_IsoCone.end()); + } - /// L1TkTau: Cluster Construction (reverse map) - /////////////////////////////////////////////// - - /// For-loop: m_L1TkTrackToL1TkTracks elements - for ( it_L1TkTrackToL1TkCluster = m_L1TkTrackToL1TkCluster.begin(); it_L1TkTrackToL1TkCluster != m_L1TkTrackToL1TkCluster.end(); it_L1TkTrackToL1TkCluster++ ){ + /// For-loop: m_L1TkTrackToL1TkTracks + for ( std::map< L1TkTrackRefPtr, unsigned int >::const_iterator it_map = m_L1TkTrackToL1TkCluster.begin(); it_map != m_L1TkTrackToL1TkCluster.end(); ++it_map ){ /// Check if the cluster is already put in the reverse-map. If not, create the vector and put into the map, if yes, add to the vector. - bool bTkClusterFoundInTkMap = m_L1TkClusterToL1TkTracks.find( it_L1TkTrackToL1TkCluster->second ) != m_L1TkClusterToL1TkTracks.end(); + bool bTkClusterFoundInTkMap = m_L1TkClusterToL1TkTracks.find( it_map->second ) != m_L1TkClusterToL1TkTracks.end(); if ( !bTkClusterFoundInTkMap ){ std::vector< L1TkTrackRefPtr > temp; - temp.push_back( it_L1TkTrackToL1TkCluster->first ); - m_L1TkClusterToL1TkTracks.insert( std::make_pair( it_L1TkTrackToL1TkCluster->second, temp ) ); + temp.push_back( it_map->first ); + m_L1TkClusterToL1TkTracks.insert( std::make_pair( it_map->second, temp ) ); } - else{ m_L1TkClusterToL1TkTracks.find( it_L1TkTrackToL1TkCluster->second )->second.push_back( it_L1TkTrackToL1TkCluster->first ); } + else{ m_L1TkClusterToL1TkTracks.find( it_map->second )->second.push_back( it_map->first ); } - } // For-loop: m_L1TkTrackToL1TkTracks elements + } /// For-loop: m_L1TkTrackToL1TkTracks + // ------------ L1TkTau Cluster: Isolation ------------ // + unsigned int nCloseTracks_Xcm = 0; + bool bPassedVtxIso = true; - /// L1TkTau: Isolation - ////////////////////// - - /// Exclude L1TkTracks that have been used in the construction of the L1TkTaus from isolation calculation? - TrackFoundInTkClusterMap L1TkTracks_TkClusterFilter; - L1TkTracks_TkClusterFilter.m_TrackToCluster = m_L1TkTrackToL1TkCluster; - if( RemoveL1TkTauTracksFromIsoCalculation == true ) { - v_L1TkTracks_IsoCone.erase( remove_if(v_L1TkTracks_IsoCone.begin(), v_L1TkTracks_IsoCone.end(), L1TkTracks_TkClusterFilter ), v_L1TkTracks_IsoCone.end()); - } - - unsigned int nTksIsoCone_VtxIso = 0; - bool bL1TkTauPassedVtxIso = true; /// For-loop: m_L1TkClusterToL1TkTracks elements - for ( it_L1TkClusterToL1TkTracks = m_L1TkClusterToL1TkTracks.begin(); it_L1TkClusterToL1TkTracks != m_L1TkClusterToL1TkTracks.end(); it_L1TkClusterToL1TkTracks++ ){ + for ( std::map< unsigned int, std::vector< L1TkTrackRefPtr > >::const_iterator it = m_L1TkClusterToL1TkTracks.begin(); it != m_L1TkClusterToL1TkTracks.end(); it++){ - nTksIsoCone_VtxIso = 0; - bL1TkTauPassedVtxIso = true; + nCloseTracks_Xcm = 0; + bPassedVtxIso = true; - /// Get the L1TkTracks that compose the L1TkTau and sort by pT - std::vector< L1TkTrackRefPtr > theseTracks = it_L1TkClusterToL1TkTracks->second; - - /// Get direction of the L1TkTau LdgTk - double L1TkTau_LdgTk_Eta = theseTracks.at(0)->getMomentum().eta(); - double L1TkTau_LdgTk_Phi = theseTracks.at(0)->getMomentum().phi(); - double L1TkTau_LdgTk_VtxZ0 = theseTracks.at(0)->getPOCA().z(); //new + /// Get the L1TkTracks that compose the L1TkTracks_Cluster + std::vector< L1TkTrackRefPtr > theseTracks = it->second; - /// Nested for-loop: L1TkTracks (IsoCone) - for ( unsigned int iTrack = 0; iTrack < v_L1TkTracks_IsoCone.size(); iTrack++ ){ + /// Sort track in pT + std::sort( theseTracks.begin(), theseTracks.end(), TrackPtComparator() ); - L1TkTrackRefPtr isoTk = v_L1TkTracks_IsoCone.at(iTrack); + /// Get the L1TkTrack properties + L1TkTrackRefPtr ldgTrack = theseTracks.at(0); + double ldgTrack_Eta = (ldgTrack)->getMomentum().eta(); + double ldgTrack_Phi = (ldgTrack)->getMomentum().phi(); + double ldgTrack_VtxZ0 = (ldgTrack)->getPOCA().z(); + + /// For-loop (nested): L1TkTracks (Isolation Cone) + for ( unsigned int index = 0; index < c_L1TkTracks_IsoCone.size(); index++ ){ - /// If this L1TkTrack belongs to the L1TkTau, or if outside the isolation cone skip it - bool bSkipThisTrack = false; + /// Skip tracks that are identical to the one under investigation + L1TkTrackRefPtr thisTrack = c_L1TkTracks_IsoCone.at(index); + if ( thisTrack.get() == theseTracks.at(0).get() ){ continue; } - /// Nested for-loop: L1TkTracks (Cluster) - for ( unsigned int jTrack = 0; jTrack < theseTracks.size(); jTrack++ ){ + /// Use only tracks close in eta/phi + double thisEta = thisTrack->getMomentum().eta(); + double thisPhi = thisTrack->getMomentum().phi(); + double deltaR = reco::deltaR(ldgTrack_Eta, ldgTrack_Phi, thisEta, thisPhi); - /// Skip identical tracks - L1TkTrackRefPtr L1TkTau_ClusterTk = theseTracks.at(jTrack); - if ( L1TkTau_ClusterTk.get() == isoTk.get() ){ bSkipThisTrack = true; } + /// Ensure that this "isolation" track is within the signal cone (annulus) defined by the user + if ( (deltaR > cfg_DeltaR_L1TkTau_Isolation_Max) || (deltaR < cfg_DeltaR_L1TkTau_Isolation_Min) ){ continue; } - } /// Nested for-loop: L1TkTracks in Cluster - if ( bSkipThisTrack == true ){ continue; } - - /// Is the L1TkTrack within the isolation cone of the L1TkTau? - float isoTk_Eta = isoTk-> getMomentum().eta(); - float isoTk_Phi = isoTk-> getMomentum().phi(); - double deltaR = reco::deltaR(L1TkTau_LdgTk_Eta, L1TkTau_LdgTk_Phi, isoTk_Eta, isoTk_Phi); - if ( deltaR > DeltaR_L1TkTauIsolation ){ continue; } - - /// Calculate number of L1TkTracks inside isolation cone of L1TkTau, that are within a distance "L1TkTrack_VtxZ0Max" in vertex-z position - double isoTk_VtxZ0 = isoTk->getPOCA().z(); //new - double deltaVtxIso_Z0 = fabs ( L1TkTau_LdgTk_VtxZ0 - isoTk_VtxZ0 ); - if ( deltaVtxIso_Z0 <= L1TkTrack_VtxIsoZ0Max ){ nTksIsoCone_VtxIso++; } + /// Calculate the vertex-z distance of the "isolation" track from the ldg track + double thisVtxZ0 = c_L1TkTracks_IsoCone.at(index)->getPOCA().z(); + double deltaVtxIso_Z0 = fabs ( ldgTrack_VtxZ0 - thisVtxZ0 ); - } /// Nested for-loop: L1TkTracks (Signal) - - if ( nTksIsoCone_VtxIso > 0 && L1TkTrack_ApplyVtxIso == true){ bL1TkTauPassedVtxIso = false; } + /// Calculate Vertex Isolation for L1TkTau + if ( deltaVtxIso_Z0 <= cfg_L1TkTrack_VtxIsoZ0Max ){ nCloseTracks_Xcm++; } + + } /// For-loop (nested): L1TkTracks (Isolation Cone) + if ( nCloseTracks_Xcm > 0 && cfg_L1TkTrack_ApplyVtxIso == true){ bPassedVtxIso = false; } /// L1CaloTau: Matching with L1TkTau - //////////////////////////////////// + double minDeltaR = 99999.9; + unsigned int iMatchedL1CaloTau = 0; unsigned int iL1CaloTauIndex = -1; - unsigned int iMatchedL1CaloTau = 0; - double minDeltaR = 99999; - bool bFoundL1TkTauCaloMatch = false; - std::vector< L1TkTrackRefPtr > L1TkTau_TkPtrs; - - /// Nested for-loop: L1CaloTaus - for ( std::vector< l1extra::L1JetParticle >::const_iterator L1CaloTau = h_L1CaloTau->begin(); L1CaloTau != h_L1CaloTau->end(); L1CaloTau++){ - - iL1CaloTauIndex++; //starts at 0 + std::vector< l1extra::L1JetParticle >::const_iterator L1CaloTau_Closest = h_L1CaloTau->end(); + bool bFoundCaloMatch = false; + std::vector< L1TkTrackRefPtr > L1TkTau_TkPtrs; - /// Match L1CaloTau with L1TkTau - double L1CaloTau_Et = L1CaloTau->et(); + + // ------------ L1TkTau Cluster: Calo-Matching ------------ // + /// For-Loop (nested): L1CaloTaus + for( std::vector< l1extra::L1JetParticle >::const_iterator L1CaloTau = h_L1CaloTau->begin(); L1CaloTau != h_L1CaloTau->end(); L1CaloTau++){ + + iL1CaloTauIndex++; //starts at zero + + /// Calculate distance of L1CaloTau from the Leading Track of the L1TkTau Cluster double L1CaloTau_Eta = L1CaloTau->eta(); double L1CaloTau_Phi = L1CaloTau->phi(); + double deltaR = reco::deltaR(ldgTrack_Eta, ldgTrack_Phi, L1CaloTau_Eta, L1CaloTau_Phi); + + double L1CaloTau_Et = L1CaloTau->et(); if ( L1CaloTau_Et < L1CaloTau_EtMin){ continue; } - /// Calculate distance of L1CaloTau from the L1TkTau Leading Track - double deltaR = reco::deltaR(L1TkTau_LdgTk_Eta, L1TkTau_LdgTk_Phi, L1CaloTau_Eta, L1CaloTau_Phi); - if ( deltaR < minDeltaR ){ - minDeltaR = deltaR; - iMatchedL1CaloTau = iL1CaloTauIndex; + + /// Update closest L1TkTrack + if ( deltaR < minDeltaR ){ + minDeltaR = deltaR; + L1CaloTau_Closest = L1CaloTau; + iMatchedL1CaloTau = iL1CaloTauIndex; } - - } /// Nested for-Loop: L1CaloTaus - /// Ensuse that the L1CaloTau closest to the L1TkTau is at least within a certain matching cone size. Create a L1CaloTau Ref Pointer - if ( minDeltaR < DeltaR_L1TkTau_L1CaloTau ){ - bFoundL1TkTauCaloMatch = true; - L1TkTau_TkPtrs = it_L1TkClusterToL1TkTracks->second; + } /// For-Loop (nested): L1CaloTaus + + /// Ensuse that the L1CaloTau closest to the L1TkTau is at least within a certain matching cone size. Create a L1CaloTau Ref Pointer + if ( minDeltaR < cfg_DeltaR_L1TkTau_L1CaloTau ){ + bFoundCaloMatch = true; + L1TkTau_TkPtrs = it->second; } - /// Construct 4-Momentum of L1TkTau Candidate - math::XYZTLorentzVector L1TkTau_P4(0, 0, 0, 0); - float mPionPlus = 0.140; // GeV - - /// Nested for-loop: L1TkTracks of L1TkTau //fixme: use calo Et - for ( unsigned int iTk = 0; iTk < L1TkTau_TkPtrs.size(); iTk++ ){ - - L1TkTrackRefPtr tk = L1TkTau_TkPtrs.at(iTk); - - float L1TkTauTk_Px = tk-> getMomentum().x(); - float L1TkTauTk_Py = tk-> getMomentum().y(); - float L1TkTauTk_Pz = tk-> getMomentum().z(); - float L1TkTauTk_E = sqrt( L1TkTauTk_Px*L1TkTauTk_Px + L1TkTauTk_Py*L1TkTauTk_Py + L1TkTauTk_Pz*L1TkTauTk_Pz + mPionPlus * mPionPlus ); - math::XYZTLorentzVector tmp_P4(L1TkTauTk_Px, L1TkTauTk_Py, L1TkTauTk_Pz, L1TkTauTk_E); - L1TkTau_P4 += tmp_P4; - - } /// Nested for-loop: L1TkTracks of L1TkTau - /// Apply Vtx-Based isolation on L1TkTaus. Also ensure a L1CaloTau has been matched to a L1TkTau - bool bFillEvent = bL1TkTauPassedVtxIso * bFoundL1TkTauCaloMatch; + bool bFillEvent = bPassedVtxIso * bFoundCaloMatch; if( bFillEvent == false ) { continue; } - /// Save the L1TkTau candidate, its tracks, isolation variable (dumbie) and its L1CaloTau reference. + /// Save the L1TkTau candidate's L1CaloTau P4, its L1CaloTau reference, its associated tracks and a dumbie isolation variable float L1TkTau_TkIsol = -999.9; - edm::Ref< L1JetParticleCollection > L1TauCaloRef( h_L1CaloTau, iMatchedL1CaloTau ); + edm::Ref< L1JetParticleCollection > L1TauCaloRef( h_L1CaloTau, iMatchedL1CaloTau ); /// Since the L1TkTauParticle does not support a vector of Track Ptrs yet, use instead a "hack" to simplify the code. edm::Ptr< L1TkTrackType > L1TrackPtrNull; @@ -461,18 +408,17 @@ void L1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& else{} /// Fill The L1TkTauParticle object: - // L1TkTauParticle L1TkTauFromCalo( L1TkTau_P4, L1TauCaloRef, L1TkTau_TkPtrs, L1TkTau_TkIsol ); - L1TkTauParticle L1TkTauFromCalo( L1TkTau_P4, - L1TauCaloRef, - L1TkTau_TkPtrs[0], - L1TkTau_TkPtrs[1], - L1TkTau_TkPtrs[2], - L1TkTau_TkIsol ); + L1TkTauParticle L1TkTauFromCalo( L1TauCaloRef->p4(), + L1TauCaloRef, + L1TkTau_TkPtrs[0], + L1TkTau_TkPtrs[1], + L1TkTau_TkPtrs[2], + L1TkTau_TkIsol ); result -> push_back( L1TkTauFromCalo ); } /// For-loop: m_L1TkClusterToL1TkTracks elements - + iEvent.put( result ); } @@ -495,6 +441,3 @@ void L1TkTauFromCaloProducer::fillDescriptions(edm::ConfigurationDescriptions& d //define this as a plug-in DEFINE_FWK_MODULE(L1TkTauFromCaloProducer); - - - diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py index 13e2745194112..0319357d0f142 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1CaloTauSequences_cfi.py @@ -9,20 +9,22 @@ #L1TausInputTag = cms.InputTag("SLHCL1ExtraParticles","Taus"), L1TausInputTag = cms.InputTag("L1CaloTauCorrectionsProducer","CalibratedTaus"), L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), - L1TkTrack_ApplyVtxIso = cms.bool( True ), # Produce vertex-isolated L1TkTaus? + #L1TkTrack_ApplyVtxIso = cms.bool( False ), # Produce vertex-isolated L1TkTaus? + L1TkTrack_ApplyVtxIso = cms.bool( True ), # Produce vertex-isolated L1TkTaus? L1TkTrack_VtxIsoZ0Max = cms.double( 1.0 ), # Max vertex z for L1TkTracks for VtxIsolation [cm] L1TkTrack_NStubsMin = cms.uint32( 5 ), # Min number of stubs per L1TkTrack [unitless] L1TkTrack_PtMin_AllTracks = cms.double( 2.0 ), # Min pT applied on all L1TkTracks [GeV] - L1TkTrack_PtMin_SignalTracks = cms.double( 10.0), # Min pT applied on signal L1TkTracks [GeV] + L1TkTrack_PtMin_SignalTracks = cms.double( 10.0 ), # Min pT applied on signal L1TkTracks [GeV] L1TkTrack_PtMin_IsoTracks = cms.double( 2.0 ), # Min pT applied on isolation L1TkTracks [GeV] - L1TkTrack_RedChiSquareEndcapMax = cms.double( 5.0 ), # Max red-chi squared for L1TkTracks in Endcap - L1TkTrack_RedChiSquareBarrelMax = cms.double( 2.0 ), # Max red-chi squared for L1TkTracks in Barrel + L1TkTrack_RedChiSquareEndcapMax = cms.double( 5.0 ), # Max chi squared for L1TkTracks in Endcap [unitless] + L1TkTrack_RedChiSquareBarrelMax = cms.double( 2.0 ), # Max chi squared for L1TkTracks in Barrel [unitless] L1TkTrack_VtxZ0Max = cms.double( 30.0 ), # Max vertex z for L1TkTracks [cm] - DeltaR_L1TkTau_L1TkTrack = cms.double( 0.10 ), # Cone size for L1TkTracks assigned to L1TkTau - DeltaR_L1TkTauIsolation = cms.double( 0.40 ), # Isolation cone size for L1TkTau - DeltaR_L1TkTau_L1CaloTau = cms.double( 0.15 ), # Matching cone for L1TkTau and L1CaloTau + DeltaR_L1TkTau_L1TkTrack = cms.double( 0.10 ), # Signal-cone size for assigning L1TkTracks to L1TkTau candidate + DeltaR_L1TkTau_Isolation_Min = cms.double( 0.10 ), # Isolation-cone size (min) - becomes isolation annulus if > 0.0 + DeltaR_L1TkTau_Isolation_Max = cms.double( 0.40 ), # Isolation cone size (max) + DeltaR_L1TkTau_L1CaloTau = cms.double( 0.15), # Matching cone for L1TkTau and L1CaloTau + RemoveL1TkTauTracksFromIsoCalculation = cms.bool( False ), # Remove tracks used in L1TkTau construction from isolation calculation? L1CaloTau_EtMin = cms.double( 5.0 ), # Min eT applied on all L1CaloTaus [GeV] - RemoveL1TkTauTracksFromIsoCalculation = cms.bool( False ), # Remove tracks used in L1TkTau construction from VtxIso calculation? ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py index 6daa029ec532b..4e9c711e4a28a 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py @@ -153,7 +153,8 @@ L1TkTrack_RedChiSquareBarrelMax = cms.double( 2.0 ), # Max red-chi squared for L1TkTracks in Barrel L1TkTrack_VtxZ0Max = cms.double( 30.0 ), # Max vertex z for L1TkTracks [cm] DeltaR_L1TkTau_L1TkTrack = cms.double( 0.10 ), # Cone size for L1TkTracks assigned to L1TkTau - DeltaR_L1TkTauIsolation = cms.double( 0.40 ), # Isolation cone size for L1TkTau + DeltaR_L1TkTau_Isolation_Min = cms.double( 0.10 ), # Isolation-cone size (min) - becomes isolation annulus if > 0.0 + DeltaR_L1TkTau_Isolation_Max = cms.double( 0.40 ), # Isolation cone size (max) DeltaR_L1TkTau_L1CaloTau = cms.double( 0.15 ), # Matching cone for L1TkTau and L1CaloTau L1CaloTau_EtMin = cms.double( 5.0 ), # Min eT applied on all L1CaloTaus [GeV] RemoveL1TkTauTracksFromIsoCalculation = cms.bool( False ), # Remove tracks used in L1TkTau construction from VtxIso calculation? From ecc90e845691272391642f19dc7924f951dd4bb9 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 3 Jul 2014 17:49:31 +0200 Subject: [PATCH 061/252] updated test_L1TkEGamma_with_crystal_cfg.py --- .../test/test_L1TkEGamma_with_crystal_cfg.py | 108 ++++-------------- 1 file changed, 24 insertions(+), 84 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py index 500603ac815bd..ce25bf218b423 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py @@ -4,7 +4,7 @@ process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) # # This first creates the collection of "L1Tracks for electrons" by running @@ -22,20 +22,21 @@ # to run over the test rate sample (part 1) : -from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * -process.source = cms.Source("PoolSource", - fileNames = minBiasFiles_p1 -) +#from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * +#process.source = cms.Source("PoolSource", +# fileNames = minBiasFiles_p1 +#) # to run over another sample: -#process.source = cms.Source("PoolSource", +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( # electron file: - #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', + '/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SingleElectron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SinglePositron_E2023TTI_PU140.root', #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m2_SinglePositron_E2023TTI_PU140.root' - #) -#) + ) +) # ---- Global Tag : @@ -103,7 +104,7 @@ process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", EtminForStore = cms.double( -999.), debug = cms.untracked.bool(False), - useECalEndcap = cms.untracked.bool(True) + useECalEndcap = cms.bool(True) ) process.pSasha = cms.Path( process.L1EGammaCrystalsProducer ) @@ -117,11 +118,17 @@ # L1EG collection. The eta and phi of the L1EG objects is corrected using the # information of the xtal level clusters. -process.l1ExtraCrystalProducer = cms.EDProducer("L1ExtraCrystalPosition", - eGammaSrc = cms.InputTag("SLHCL1ExtraParticlesNewClustering","EGamma"), - eClusterSrc = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster") -) -process.egcrystal_producer = cms.Path(process.l1ExtraCrystalProducer) +# ---- Note: this is not needed anymore. The latest code of L1EGCrystalClusterProducer, +# provides similar rates as the new stage-2 algorithm (and with a better +# efficiency). Hence we don;t need anymore to rely on the tower-based +# new stage-2 algorithm for the ele-ID of the EGamma object, we can +# directly use teh clusters from Sasha & Nick. + +#process.l1ExtraCrystalProducer = cms.EDProducer("L1ExtraCrystalPosition", +# eGammaSrc = cms.InputTag("SLHCL1ExtraParticlesNewClustering","EGamma"), +# eClusterSrc = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster") +#) +#process.egcrystal_producer = cms.Path(process.l1ExtraCrystalProducer) @@ -131,11 +138,6 @@ # Now we produce L1TkEmParticles and L1TkElectrons -# ---- "photons" isolated w.r.t. L1Tracks : - -process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmParticleProducer_cfi") -process.pL1TkPhotons = cms.Path( process.L1TkPhotons ) - # ---- "electrons" from L1Tracks. Inclusive electrons : process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkElectronTrackProducer_cfi") @@ -143,65 +145,11 @@ # --- collection of L1TkElectrons made from "crystal-level" L1EG objects process.L1TkElectronsCrystal = process.L1TkElectrons.clone() -process.L1TkElectronsCrystal.L1EGammaInputTag = cms.InputTag("l1ExtraCrystalProducer","EGammaCrystal") +process.L1TkElectronsCrystal.L1EGammaInputTag = cms.InputTag("L1EGammaCrystalsProducer","EGammaCrystal") # ... of course, the cuts need to be retuned for the xtal-level granularity process.pElectronsCrystal = cms.Path( process.L1TkElectronsCrystal ) -# ---- L1TkElectrons that are isolated w.r.t. L1Tracks : - -process.L1TkIsoElectrons = process.L1TkElectrons.clone() -process.L1TkIsoElectrons.IsoCut = cms.double(0.1) -process.pElectronsTkIso = cms.Path( process.L1TkIsoElectrons ) - -# ---- "electrons" from L1Tracks, Inclusive electrons : dedicated low PT sequence -process.pElectronsLoose = cms.Path( process.L1TkElectronsLoose) - -# to test with looser cuts : -process.L1TkElectronsLooseV2 = process.L1TkElectronsLoose.clone() -process.L1TkElectronsLooseV2.TrackMinPt = cms.double( 2. ) -process.L1TkElectronsLooseV2.TrackEGammaDeltaPhi = cms.vdouble( 0.2, 0.,0.) -process.L1TkElectronsLooseV2.TrackEGammaDeltaR = cms.vdouble( 0.2, 0.,0.) -process.pElectronsLoose2 = cms.Path( process.L1TkElectronsLooseV2 ) - -# ---- L1TkElectrons that are isolated w.r.t. L1Tracks : dedicated low PT sequence -process.L1TkIsoElectronsLoose = process.L1TkElectronsLoose.clone() -process.L1TkIsoElectronsLoose.IsoCut = cms.double(0.1) -process.pElectronsTkIsoLoose = cms.Path( process.L1TkIsoElectronsLoose ) - - -# ---- L1TkElectrons made from L1IsoEG objects, i.e. from L1EG objects that -# are isolated in the calorimeter : - -process.L1TkElectronsIsoEG = process.L1TkElectrons.clone() -process.L1TkElectronsIsoEG.L1EGammaInputTag = cms.InputTag("SLHCL1ExtraParticlesNewClustering","IsoEGamma") -process.pElectronsIsoEG = cms.Path( process.L1TkElectronsIsoEG ) - -# ---- "electrons" from stubs - not implemented yet. -# -#process.L1TkElectronsStubs = cms.EDProducer("L1TkElectronStubsProducer", -#) -#process.pElectronsStubs = cms.Path( process.L1TkElectronsStubs ) - - - -# --------------------------------------------------------------------------- - - -# Run a trivial analyzer that prints the objects - -process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , - L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here - L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here - L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), - L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), - L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here - L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI","") # dummy here -) - -#process.pAna = cms.Path( process.ana ) - - # --------------------------------------------------------------------------- @@ -242,21 +190,13 @@ process.Out.outputCommands.append('keep *_L1EGammaCrystalsProducer_*_*') process.Out.outputCommands.append('keep *_l1ExtraCrystalProducer_*_*') - # the L1TkEmParticles -process.Out.outputCommands.append('keep *_L1TkPhotons_*_*') # the L1TkElectrons process.Out.outputCommands.append('keep *_L1TkElectrons_*_*') process.Out.outputCommands.append('keep *_L1TkElectronsCrystal_*_*') # for crystal-level granularity -process.Out.outputCommands.append('keep *_L1TkElectronsIsoEG_*_*') -process.Out.outputCommands.append('keep *_L1TkIsoElectrons_*_*') - -process.Out.outputCommands.append('keep *_L1TkElectronsLoose_*_*') -process.Out.outputCommands.append('keep *_L1TkIsoElectronsLoose_*_*') -process.Out.outputCommands.append('keep *_L1TkElectronsLooseV2_*_*') -# --- to use the genParticles, one needs to keep the collections of associators below: +# --- to browse the genParticles in ROOT, one needs to keep the collections of associators below: process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') From 47a88dd589fd20abdb0abdc7c0bc3a58312f508c Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 3 Jul 2014 18:50:18 +0200 Subject: [PATCH 062/252] added possibility to sort the TkTau collections; added L1TkEmTauSequence_cfi.py and updated test_L1TkTau_cfg.py --- .../interface/L1TkTauEtComparator.h | 27 ++++ .../plugins/L1CaloTausToTkTausTranslator.cc | 4 + .../plugins/L1TkEmTauProducer.cc | 5 + .../plugins/L1TkTauFromCaloProducer.cc | 5 + .../plugins/L1TkTauFromL1TrackProducer.cc | 9 +- .../python/L1TkEmTauSequence_cfi.py | 33 +++++ .../python/L1TkEtMissProducer_cfi.py | 2 +- .../L1TrackTrigger/test/test_L1TkEmTau_cfg.py | 14 -- .../test/test_L1TkTauFromTracks_cfg.py | 128 ++++++++++++++++++ .../L1TrackTrigger/test/test_L1TkTau_cfg.py | 105 +++++++------- 10 files changed, 253 insertions(+), 79 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmTauSequence_cfi.py create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromTracks_cfg.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h b/SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h new file mode 100644 index 0000000000000..ea1c846ec5106 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h @@ -0,0 +1,27 @@ +#ifndef L1TkTauEtComparator_HH +#define L1TkTauEtComparator_HH +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticle.h" +#include "DataFormats/L1TrackTrigger/interface/L1TkTauParticleFwd.h" + +namespace L1TkTau{ + class EtComparator { + public: + bool operator()(const l1extra::L1TkTauParticle& a, const l1extra::L1TkTauParticle& b) const { + double et_a = a.et(); + double et_b = b.et(); + return et_a > et_b; + } + }; + + class PtComparator { + public: + bool operator()(const l1extra::L1TkTauParticle& a, const l1extra::L1TkTauParticle& b) const { + double et_a = a.pt(); + double et_b = b.pt(); + return et_a > et_b; + } + }; + +} +#endif + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc index 984687539bcb8..703cc4c07aa8b 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc @@ -32,6 +32,8 @@ #include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" //for 'L1TkTrack_PixelDigi_Collection', etc.. #include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h" + using namespace l1extra ; // ---------- class declaration ---------- // @@ -105,6 +107,8 @@ void L1CaloTausToTkTausTranslator::produce(edm::Event& iEvent, const edm::EventS } + //sort( result->begin(), result->end(), L1TkTau::EtComparator() ); + iEvent.put( result ); } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc index f695943d40a5f..e586a56a08dbd 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc @@ -33,6 +33,9 @@ #include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h" + + #include #include "TMath.h" @@ -339,6 +342,8 @@ L1TkEmTauProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) } + //sort( result ->begin(), result ->end(), L1TkTau::EtComparator() ); + iEvent.put( result ); } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc index 02dd99a73873b..70220ea7bfa46 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc @@ -32,6 +32,9 @@ #include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" #include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h" + + using namespace l1extra ; // ---------- class declaration ---------- // @@ -419,6 +422,8 @@ void L1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& } /// For-loop: m_L1TkClusterToL1TkTracks elements + //sort( result->begin(), result->end(), L1TkTau::EtComparator() ); + iEvent.put( result ); } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc index b6ac11fa11e3c..1ad92d3998c9a 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc @@ -33,6 +33,9 @@ #include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/L1TkTauEtComparator.h" + + #include #include "TMath.h" @@ -302,11 +305,7 @@ L1TkTauFromL1TrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& i } - - - - - + //sort( result->begin(), result->end(), L1TkTau::PtComparator() ); iEvent.put( result ); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmTauSequence_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmTauSequence_cfi.py new file mode 100644 index 0000000000000..0a2f9dc723180 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEmTauSequence_cfi.py @@ -0,0 +1,33 @@ +import FWCore.ParameterSet.Config as cms + + +# --- to run L1EGCrystalClusterProducer, one needs the ECAL RecHits: +from Configuration.StandardSequences.Reconstruction_cff import * + + +L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", + EtminForStore = cms.double(-1.0), + debug = cms.untracked.bool(False), + useECalEndcap = cms.bool(True) +) + + +L1TkEmTauProducer = cms.EDProducer( 'L1TkEmTauProducer' , + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + L1EmInputTag = cms.InputTag("L1EGammaCrystalsProducer","EGCrystalCluster"), + ptleadcut = cms.double(5.0), + ptleadcone = cms.double(0.3), + masscut = cms.double(1.77), + emptcut = cms.double(5.0), + trketacut = cms.double(2.3), + pttotcut = cms.double(5.0), + isocone = cms.double(0.25), + isodz = cms.double(0.6), + relisocut = cms.double(0.15), + chisqcut = cms.double(40.0), + nstubcut = cms.int32(5), + dzcut = cms.double(0.8) +) + + +TkEmTauSequence = cms.Sequence( calolocalreco + L1EGammaCrystalsProducer + L1TkEmTauProducer) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py index b0e48982e2e8b..8b2f78c817f72 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py @@ -12,7 +12,7 @@ #PTMAX = cms.double( 50. ), # in GeV. When PTMAX > 0, tracks with PT above PTMAX are considered as # mismeasured and are treated according to HighPtTracks below. # When PTMAX < 0, no special treatment is done for high PT tracks. - PTMAX = cms.double( -1. ), + PTMAX = cms.double( 50. ), HighPtTracks = cms.int32( 0 ), # when = 0 : truncation. Tracks with PT above PTMAX are ignored # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. # When PTMAX < 0, no special treatment is done for high PT tracks. diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py index 4e9c711e4a28a..efebb8c4e58ce 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py @@ -188,20 +188,6 @@ - -# --------------------------------------------------------------------------- - -# Now we produce L1TkEmParticles and L1TkElectrons - - -# ---- "photons" isolated w.r.t. L1Tracks : - -process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmParticleProducer_cfi") -process.pL1TkPhotons = cms.Path( process.L1TkPhotons ) - - - - # --------------------------------------------------------------------------- diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromTracks_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromTracks_cfg.py new file mode 100644 index 0000000000000..384c844e3cb2c --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromTracks_cfg.py @@ -0,0 +1,128 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("ALL") + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) + +# +# This runs over a file that already contains the L1Tracks. +# + + +# to run over the test rate sample (part 1) : +from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * +process.source = cms.Source("PoolSource", + fileNames = minBiasFiles_p1 +) + +#from SLHCUpgradeSimulations.L1TrackTrigger.singleTau1pFiles_cfi import * +#process.source = cms.Source("PoolSource", +# fileNames = singleTau1pFiles +#) + + +# to run over another sample: +#process.source = cms.Source("PoolSource", + # electron file: + #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', + #) +#) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + + + +# --------------------------------------------------------------------------- +# +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') + +process.L1TkTauFromL1Track = cms.EDProducer("L1TkTauFromL1TrackProducer", + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + ZMAX = cms.double( 25. ),# in cm + CHI2MAX = cms.double( 100. ), + PTMINTRA = cms.double( 2. ),# in GeV + DRmax = cms.double( 0.5 ), + nStubsmin = cms.int32( 5 ) # minimum number of stubs + ) + +process.pTaus = cms.Path( process.L1TkTauFromL1Track ) + + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# Run a trivial analyzer that prints the objects + +process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , + L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here + L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here + L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), + L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), + L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here + L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI",""), # dummy here + L1TkMuonsInputTag = cms.InputTag("L1TkMuons","") # dummy here + +) + +#process.pAna = cms.Path( process.ana ) + + + +# --------------------------------------------------------------------------- + +# --- Output module : + + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') +) + + + # raw data +#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + + + # gen-level information +#process.Out.outputCommands.append('keep *_generator_*_*') +#process.Out.outputCommands.append('keep *_*gen*_*_*') +#process.Out.outputCommands.append('keep *_*Gen*_*_*') +process.Out.outputCommands.append('keep *_genParticles_*_*') + + + # the L1Tracks, clusters and stubs +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') +#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') +#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') + + # the L1TkTaus +process.Out.outputCommands.append('keep *_L1TkTauFromL1Track_*_*') + + +# --- to browse the genParticles, one needs to keep the collections of associators below: +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') +process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py index 384c844e3cb2c..50d7768e9f680 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py @@ -4,31 +4,25 @@ process.load("FWCore.MessageService.MessageLogger_cfi") -process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(1000) ) # -# This runs over a file that already contains the L1Tracks. +# This reruns the L1Tracking to benefit from the latest updates, +# runs the SLHCCaloSequence and produce the L1EGammaCrystal objects, +# and rune the L1TkEmTau producer. # -# to run over the test rate sample (part 1) : from SLHCUpgradeSimulations.L1TrackTrigger.minBiasFiles_p1_cfi import * + process.source = cms.Source("PoolSource", - fileNames = minBiasFiles_p1 + fileNames = minBiasFiles_p1 + #fileNames = cms.untracked.vstring( + ## VBF H->tautau + #'/store/mc/TTI2023Upg14D/VBF_HToTauTau_125_14TeV_powheg_pythia6/GEN-SIM-DIGI-RAW/PU140bx25_PH2_1K_FB_V3-v1/00000/00114910-0DE9-E311-B42B-0025905A60F4.root', + #) ) -#from SLHCUpgradeSimulations.L1TrackTrigger.singleTau1pFiles_cfi import * -#process.source = cms.Source("PoolSource", -# fileNames = singleTau1pFiles -#) - - -# to run over another sample: -#process.source = cms.Source("PoolSource", - # electron file: - #'/store/group/comm_trigger/L1TrackTrigger/620_SLHC10/Extended2023TTI/Electrons/PU140/m1_SingleElectron_E2023TTI_PU140.root', - #) -#) # ---- Global Tag : @@ -38,42 +32,54 @@ - # --------------------------------------------------------------------------- # +# --- Recreate the L1Tracks to benefit from the latest updates + process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') -process.L1TkTauFromL1Track = cms.EDProducer("L1TkTauFromL1TrackProducer", - L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), - ZMAX = cms.double( 25. ),# in cm - CHI2MAX = cms.double( 100. ), - PTMINTRA = cms.double( 2. ),# in GeV - DRmax = cms.double( 0.5 ), - nStubsmin = cms.int32( 5 ) # minimum number of stubs - ) +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') -process.pTaus = cms.Path( process.L1TkTauFromL1Track ) +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.DefaultTrackingSequence ) # --------------------------------------------------------------------------- + # --------------------------------------------------------------------------- +# +# --- Produces the L1calo objects : run the SLHCCaloSequence +# +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') -# Run a trivial analyzer that prints the objects +process.load('Configuration/StandardSequences/L1HwVal_cff') +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") -process.ana = cms.EDAnalyzer( 'PrintL1TkObjects' , - L1VtxInputTag = cms.InputTag("L1TkPrimaryVertex"), # dummy here - L1TkEtMissInputTag = cms.InputTag("L1TkEtMiss","MET"), # dummy here - L1TkElectronsInputTag = cms.InputTag("L1TkElectrons","EG"), - L1TkPhotonsInputTag = cms.InputTag("L1TkPhotons","EG"), - L1TkJetsInputTag = cms.InputTag("L1TkJets","Central"), # dummy here - L1TkHTMInputTag = cms.InputTag("L1TkHTMissCaloHI",""), # dummy here - L1TkMuonsInputTag = cms.InputTag("L1TkMuons","") # dummy here +# bug fix for missing HCAL TPs in MC RAW +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") -) +process.slhccalo = cms.Path( process.RawToDigi + process.valHcalTriggerPrimitiveDigis+process.SLHCCaloTrigger) -#process.pAna = cms.Path( process.ana ) + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- + +# --- Produce the L1TkEmTau objects + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmTauSequence_cfi") +process.pL1TkEmTaus = cms.Path( process.TkEmTauSequence ) + +# --------------------------------------------------------------------------- @@ -88,34 +94,15 @@ outputCommands = cms.untracked.vstring( 'drop *') ) - - # raw data -#process.Out.outputCommands.append('keep *_rawDataCollector_*_*') + # the collection of TkEmTau objects to be used for L1Menu : +process.Out.outputCommands.append('keep *_L1TkEmTauProducer_*_*') # gen-level information #process.Out.outputCommands.append('keep *_generator_*_*') #process.Out.outputCommands.append('keep *_*gen*_*_*') #process.Out.outputCommands.append('keep *_*Gen*_*_*') -process.Out.outputCommands.append('keep *_genParticles_*_*') - - - # the L1Tracks, clusters and stubs -#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_ClusterAccepted_*') -#process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_ClusterAccepted_*') -#process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_StubAccepted_*') -#process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_*') -#process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') -#process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_*') - - # the L1TkTaus -process.Out.outputCommands.append('keep *_L1TkTauFromL1Track_*_*') - - -# --- to browse the genParticles, one needs to keep the collections of associators below: -process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') -process.Out.outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') -process.Out.outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') +#process.Out.outputCommands.append('keep *_genParticles_*_*') process.FEVToutput_step = cms.EndPath(process.Out) From 5419cf62bd9b17eeadb8f455dd6b89e8e2479052 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Thu, 3 Jul 2014 19:04:07 +0200 Subject: [PATCH 063/252] updated produce_L1TkObjects_cfg.py: useECalEndcap is now tracked --- .../L1TrackTrigger/test/produce_L1TkObjects_cfg.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py index ed2772142f41b..f0a79cff4f888 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py @@ -85,7 +85,7 @@ process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", EtminForStore = cms.double( 4. ), debug = cms.untracked.bool(False), - useECalEndcap = cms.untracked.bool(True) + useECalEndcap = cms.bool(True) ) process.pSasha = cms.Path( process.L1EGammaCrystalsProducer ) From 3947c8a6b6e27c8187eff742c4b009844cbad41b Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sun, 13 Jul 2014 18:03:47 +0200 Subject: [PATCH 064/252] updated produce_L1TkObjects_cfg.py to use the TkEmTaus --- .../test/produce_L1TkObjects_cfg.py | 42 +++++++++++-------- 1 file changed, 24 insertions(+), 18 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py index f0a79cff4f888..a9d6d81444227 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py @@ -78,16 +78,19 @@ # ---- Produce the L1EGCrystal clusters (code of Sasha Savin & Nick Smith) +# This is now included in L1TkEmTauSequence_cfi.py, which is run later + # first you need the ECAL RecHIts : -process.load('Configuration.StandardSequences.Reconstruction_cff') -process.reconstruction_step = cms.Path( process.calolocalreco ) +#process.load('Configuration.StandardSequences.Reconstruction_cff') +#process.reconstruction_step = cms.Path( process.calolocalreco ) # -process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", - EtminForStore = cms.double( 4. ), - debug = cms.untracked.bool(False), - useECalEndcap = cms.bool(True) -) -process.pSasha = cms.Path( process.L1EGammaCrystalsProducer ) +# +#process.L1EGammaCrystalsProducer = cms.EDProducer("L1EGCrystalClusterProducer", +# EtminForStore = cms.double( 4. ), +# debug = cms.untracked.bool(False), +# useECalEndcap = cms.bool(True) +#) +#process.pSasha = cms.Path( process.L1EGammaCrystalsProducer ) # needed because the calo stuff above clashes with the DTs @@ -144,16 +147,18 @@ # --------------------------------------------------------------------------- # --- TkTaus -process.L1TkTauFromL1Track = cms.EDProducer("L1TkTauFromL1TrackProducer", - L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), - ZMAX = cms.double( 25. ),# in cm - CHI2MAX = cms.double( 100. ), - PTMINTRA = cms.double( 2. ),# in GeV - DRmax = cms.double( 0.5 ), - nStubsmin = cms.int32( 5 ) # minimum number of stubs - ) +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TkEmTauSequence_cfi") +process.pTaus = cms.Path( process.TkEmTauSequence ) -process.pTaus = cms.Path( process.L1TkTauFromL1Track ) +#process.L1TkTauFromL1Track = cms.EDProducer("L1TkTauFromL1TrackProducer", +# L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), +# ZMAX = cms.double( 25. ),# in cm +# CHI2MAX = cms.double( 100. ), +# PTMINTRA = cms.double( 2. ),# in GeV +# DRmax = cms.double( 0.5 ), +# nStubsmin = cms.int32( 5 ) # minimum number of stubs +# ) +#process.pTaus = cms.Path( process.L1TkTauFromL1Track ) # --------------------------------------------------------------------------- @@ -211,7 +216,7 @@ process.Out.outputCommands.append('keep *_l1extraParticles_MET_*') # TkTaus -process.Out.outputCommands.append('keep *_L1TkTauFromL1Track_*_*') +process.Out.outputCommands.append('keep *_L1TkEmTauProducer_*_*') process.Out.outputCommands.append('keep *_SLHCL1ExtraParticles_Taus_*') # jets, HT, MHT @@ -237,6 +242,7 @@ #process.Out.outputCommands.append('keep *_TTStubsFromPixelDigis_StubAccepted_ALL') process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_ALL') +process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigisLargerPhi_Level1TTTracks_ALL') #process.Out.outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_Level1TTTracks_ALL') From 2d0f770b1d060d62ddac916c1494218eb0fcc5ba Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sun, 13 Jul 2014 18:11:35 +0200 Subject: [PATCH 065/252] changed default to doTightChi2=false for vertex,jet and Etmiss --- .../L1TrackTrigger/python/L1TkEtMissProducer_cfi.py | 2 +- .../L1TrackTrigger/python/L1TkJetProducer_cfi.py | 2 +- .../L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py index 8b2f78c817f72..6855fff8a15a3 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkEtMissProducer_cfi.py @@ -17,7 +17,7 @@ # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. # When PTMAX < 0, no special treatment is done for high PT tracks. doPtComp = cms.bool( True ), # track-stubs PT compatibility cut - doTightChi2 = cms.bool( True ) # chi2dof < 5 for tracks with PT > 10 + doTightChi2 = cms.bool( False ) # chi2dof < 5 for tracks with PT > 10 ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py index aa3f317d76017..3a989b89d1acc 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkJetProducer_cfi.py @@ -12,5 +12,5 @@ TRK_NSTUBPSMIN = cms.int32(2), # minimum number of stubs in PS modules on track #JET_HLTETA = cms.bool(False), # temporary hack, for HLT jets remove jets from bad eta regions doPtComp = cms.bool( True ), # track-stubs PT compatibility cut - doTightChi2 = cms.bool( True ) # chi2dof < 5 for tracks with PT > 10 + doTightChi2 = cms.bool( False ) # chi2dof < 5 for tracks with PT > 10 ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py index ce64646cc2a38..edc7de9e30518 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/python/L1TkPrimaryVertexProducer_cfi.py @@ -16,5 +16,5 @@ # when = 1 : saturation. Tracks with PT above PTMAX are set to PT=PTMAX. MonteCarloVertex = cms.bool( False ), # when True: dont run the vxt finding algo but pick up the MC generated vtx doPtComp = cms.bool( True ), # track-stubs PT compatibility cut - doTightChi2 = cms.bool( True ) # chi2dof < 5 for tracks with PT > 10 + doTightChi2 = cms.bool( False ) # chi2dof < 5 for tracks with PT > 10 ) From 802f9710e4980200226601a03f4cbdcbd75099ea Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Mon, 14 Jul 2014 13:56:52 -0500 Subject: [PATCH 066/252] Added DetId of seed crystal used to form cluster to L1EGCrystalCluster container. --- .../L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc | 2 +- SimDataFormats/SLHC/interface/L1EGCrystalCluster.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index 2d2f94c359cd8..3036e325c08d2 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -308,7 +308,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet // Form a l1slhc::L1EGCrystalCluster reco::Candidate::PolarLorentzVector p4(totalPt, weightedPosition.eta(), weightedPosition.phi(), 0.); - l1slhc::L1EGCrystalCluster cluster(p4, hovere, ECalIsolation, totalPtPUcorr, bremStrength); + l1slhc::L1EGCrystalCluster cluster(p4, hovere, ECalIsolation, centerhit.id, totalPtPUcorr, bremStrength); // Save pt array cluster.SetCrystalPtInfo(crystalPt); trigCrystalClusters->push_back(cluster); diff --git a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h index d7ed60c962c51..0795dcdf5b72c 100644 --- a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h +++ b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h @@ -4,6 +4,7 @@ #include #include #include "DataFormats/Candidate/interface/LeafCandidate.h" +#include "DataFormats/DetId/interface/DetId.h" namespace l1slhc { @@ -11,13 +12,14 @@ namespace l1slhc class L1EGCrystalCluster : public reco::LeafCandidate { public: L1EGCrystalCluster() : LeafCandidate(), hovere_(0.), iso_(0.), PUcorrPt_(0.), bremStrength_(0.) {}; - L1EGCrystalCluster(const PolarLorentzVector& p4, float hovere, float iso, float PUcorrPt = 0., float bremStrength = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt), bremStrength_(bremStrength) {}; + L1EGCrystalCluster(const PolarLorentzVector& p4, float hovere, float iso, DetId seedCrystal, float PUcorrPt = 0., float bremStrength = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), seedCrystal_(seedCrystal), PUcorrPt_(PUcorrPt), bremStrength_(bremStrength) {}; L1EGCrystalCluster(const LorentzVector& p4, float hovere, float iso, float PUcorrPt = 0., float bremStrength = 0.) : LeafCandidate(0, p4), hovere_(hovere), iso_(iso), PUcorrPt_(PUcorrPt), bremStrength_(bremStrength) {}; virtual ~L1EGCrystalCluster() {}; inline float hovere() const { return hovere_; }; inline float isolation() const { return iso_; }; inline float PUcorrPt() const { return PUcorrPt_; }; inline float bremStrength() const { return bremStrength_; }; + inline DetId seedCrystal() const { return seedCrystal_; }; void SetCrystalPtInfo(std::vector &info) { std::sort(info.begin(), info.end()); std::reverse(info.begin(), info.end()); @@ -33,6 +35,8 @@ namespace l1slhc float hovere_; // ECal isolation (for outer window size, again look in producer) float iso_; + // DetId of seed crystal used to make cluster (could be EBDetId or EEDetId) + DetId seedCrystal_; // Pileup-corrected energy deposit, not studied carefully yet, don't use float PUcorrPt_; // Bremstrahlung strength, should be proportional to the likelihood of a brem. From a9aba0ead24f3277f643ef2981533171de6d7b0b Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Mon, 14 Jul 2014 16:07:03 -0500 Subject: [PATCH 067/252] More optimal EG crystal producer cuts. --- .../L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index 3036e325c08d2..9eb52d102251f 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -314,11 +314,11 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet trigCrystalClusters->push_back(cluster); // Save clusters with some cuts - // This is a dynamic falling quadratic cut in pt, trying to squeeze as much efficiency as possible + // This is a dynamic cut in pt, trying to squeeze as much efficiency as possible // out of the cut variables, which should have been pt-independent, but are not. - if ( cluster.hovere() < ((cluster.pt() > 35) ? 0.5 : 0.5+pow(cluster.pt()-35,2)/350. ) - && cluster.isolation() < ((cluster.pt() > 35) ? 1.3 : 1.3+pow(cluster.pt()-35,2)*4/(35*35) ) - && (cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cluster.pt() < 20) ? 0.08:0.08*(1+(cluster.pt()-20)/30.) ) ) + if ( cluster.hovere() < 14./cluster.pt()+0.05 + && cluster.isolation() < 40./cluster.pt()+0.1 + && (cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cluster.pt() < 20) ? 0.08:0.08*(1+(cluster.pt()-20)/25.) ) ) && ((cluster.pt() > 10) ? (cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) > 0.):true) ) { // Optional min. Et cut From 17a0f02fa90fdcf6d5b22f50598a6e4c17cabf2d Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Thu, 17 Jul 2014 10:29:43 -0500 Subject: [PATCH 068/252] Removed out of time and l1a spike flagged EcalRecHits from EG Crystal cluster producer. --- .../L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index 9eb52d102251f..bec9f31113e38 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -153,7 +153,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet iEvent.getByLabel("ecalRecHit","EcalRecHitsEB",pcalohits); for(auto& hit : *pcalohits.product()) { - if(hit.energy() > 0.2) + if(hit.energy() > 0.2 && !hit.checkFlag(EcalRecHit::kOutOfTime) && !hit.checkFlag(EcalRecHit::kL1SpikeFlag)) { auto cell = geometryHelper.getEcalBarrelGeometry()->getGeometry(hit.id()); SimpleCaloHit ehit; @@ -175,7 +175,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet iEvent.getByLabel("ecalRecHit","EcalRecHitsEE",pcalohitsEndcap); for(auto& hit : *pcalohitsEndcap.product()) { - if(hit.energy() > 0.2) + if(hit.energy() > 0.2 && !hit.checkFlag(EcalRecHit::kOutOfTime) && !hit.checkFlag(EcalRecHit::kL1SpikeFlag)) { auto cell = geometryHelper.getEcalEndcapGeometry()->getGeometry(hit.id()); SimpleCaloHit ehit; From a39ff6a518b934ea8900807bb5283b588d78dc8d Mon Sep 17 00:00:00 2001 From: Anders Date: Sun, 20 Jul 2014 21:02:12 +0200 Subject: [PATCH 069/252] New code to add pixel hits to L1 tracks. --- .../L1TrackTrigger/interface/TTPixelTrack.h | 192 ++++ DataFormats/L1TrackTrigger/src/classes.h | 13 + .../L1TrackTrigger/src/classes_def.xml | 9 + .../L1TrackTrigger/plugins/L1PixelTrackFit.cc | 946 ++++++++++++++++++ .../L1TrackTrigger/test/test_L1PixelTrack.py | 119 +++ 5 files changed, 1279 insertions(+) create mode 100644 DataFormats/L1TrackTrigger/interface/TTPixelTrack.h create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py diff --git a/DataFormats/L1TrackTrigger/interface/TTPixelTrack.h b/DataFormats/L1TrackTrigger/interface/TTPixelTrack.h new file mode 100644 index 0000000000000..a2fa3351dcd6c --- /dev/null +++ b/DataFormats/L1TrackTrigger/interface/TTPixelTrack.h @@ -0,0 +1,192 @@ +/*! \class TTPixelTrack + * \brief Class to store the L1 Pixel Trigger tracks + * \details + * + * \author Anders Ryd + * \date 2014, Jul 15 + * + */ + +#ifndef TTPIXELTRACK_H +#define TTPIXELTRACK_H + +#include "DataFormats/L1TrackTrigger/interface/TTTrack.h" +#include "DataFormats/SiPixelDetId/interface/StackedTrackerDetId.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" + +class TTPixelTrack +{ + + public: + /// Constructors + TTPixelTrack(); + + /// Destructor + ~TTPixelTrack(); + + /// Track components + //std::vector< edm::Ref< edmNew::DetSetVector< TTStub< T > >, TTStub< T > > > getStubRefs() const { return theStubRefs; } + //void addStubRef( edm::Ref< edmNew::DetSetVector< TTStub< T > >, TTStub< T > > aStub ) { theStubRefs.push_back( aStub ); } + //void setStubRefs( std::vector< edm::Ref< edmNew::DetSetVector< TTStub< T > >, TTStub< T > > > aStubs ) { theStubRefs = aStubs; } + + /// Track momentum + GlobalVector getMomentum() const; + + /// Track curvature + double getRInv() const; + + /// POCA + GlobalPoint getPOCA() const; + + /// L1Track + edm::Ref >, TTTrack > getL1Track() const; + + /// Chi2 + double getChi2() const; + double getChi2Red() const; + + void init(const edm::Ref >, TTTrack >& aL1Track, + const GlobalVector& aMomentum, + const GlobalPoint& aPOCA, + double aRInv, + double aChi2); + + /// Information + std::string print( unsigned int i = 0 ) const; + + private: + + /// Data members + //std::vector< edm::Ref< edmNew::DetSetVector< TTStub< T > >, TTStub< T > > > + // theStubRefs; + edm::Ref >, TTTrack > theL1Track; + GlobalVector theMomentum; + GlobalPoint thePOCA; + double theRInv; + double theChi2; + + +}; /// Close class + +/*! \brief Implementation of methods + * \details + */ + +/// Default Constructor +TTPixelTrack::TTPixelTrack() +{ + //theStubRefs.clear(); + theMomentum=GlobalVector(0.0,0.0,0.0); + theRInv=0.0; + thePOCA=GlobalPoint(0.0,0.0,0.0); + theChi2=0.0; +} + +/// Destructor +TTPixelTrack::~TTPixelTrack(){} + +void TTPixelTrack::init(const edm::Ref >, TTTrack >& aL1Track, + const GlobalVector& aMomentum, + const GlobalPoint& aPOCA, + double aRInv, + double aChi2){ + + theL1Track=aL1Track; + theMomentum=aMomentum; + thePOCA=aPOCA; + theRInv=aRInv; + theChi2=aChi2; + +} + +edm::Ref >, TTTrack > TTPixelTrack::getL1Track() const{ + + return theL1Track; + +} + + +GlobalVector TTPixelTrack::getMomentum() const{ + + return theMomentum; + +} + + + + +double TTPixelTrack::getRInv() const { + + return theRInv; + +} + + + +GlobalPoint TTPixelTrack::getPOCA() const +{ + + return thePOCA; + +} + + +/// Chi2 +double TTPixelTrack::getChi2() const +{ + + return theChi2; + +} + + + +/// Chi2 reduced +double TTPixelTrack::getChi2Red() const +{ + + return 0.0; + //return theChi25Par/( 2*theStubRefs.size() - 5 ); + //Need to fix when we also store pixel refs. + +} + + + +/// Information +std::string TTPixelTrack::print( unsigned int i ) const +{ + std::string padding(""); + for ( unsigned int j = 0; j != i; ++j ) + { + padding+="\t"; + } + + std::stringstream output; + output< >, TTStub< T > > >::const_iterator stubIter; + //for ( stubIter = theStubRefs.begin(); + // stubIter!= theStubRefs.end(); + // ++stubIter ) + //{ + // output << padding << "stub: " << iStub++ << ", DetId: " << ((*stubIter)->getDetId()).rawId() << '\n'; + //} + + output << ", z-vertex: " << thePOCA.z() << " (cm), transverse momentum " << theMomentum.perp() << " (GeV/c)"; + //output << ", red. chi2 " << this->getChi2Red() << '\n'; + + return output.str(); +} + + + + +std::ostream& operator << ( std::ostream& os, const TTPixelTrack& aTTPixelTrack ) { return ( os << aTTPixelTrack.print() ); } + + +#endif + diff --git a/DataFormats/L1TrackTrigger/src/classes.h b/DataFormats/L1TrackTrigger/src/classes.h index 18259c4d71333..bdfb0fc3ab2ca 100644 --- a/DataFormats/L1TrackTrigger/src/classes.h +++ b/DataFormats/L1TrackTrigger/src/classes.h @@ -10,6 +10,7 @@ #include "DataFormats/Common/interface/Wrapper.h" #include "DataFormats/Common/interface/DetSetVectorNew.h" #include "DataFormats/L1TrackTrigger/interface/TTTypes.h" +#include "DataFormats/L1TrackTrigger/interface/TTPixelTrack.h" // includes needed for the L1TrackTriggerObjects @@ -83,6 +84,18 @@ namespace std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > > V_P_T_PD; edm::Wrapper< std::vector< edm::Ptr< TTTrack< Ref_PixelDigi_ > > > > W_V_P_T_PD; + /// TTPixelTrack and containers + TTPixelTrack TT_PT; + std::vector< TTPixelTrack > V_TT_PT; + edm::Wrapper< std::vector< TTPixelTrack > > W_V_TT_PT; + + /// edm::Ptr to TTPixelTrack and containers + edm::Ptr< TTPixelTrack > P_TT_PT; + edm::Wrapper< edm::Ptr< TTPixelTrack > > W_P_TT_PT; + std::vector< edm::Ptr< TTPixelTrack > > V_P_TT_PT; + edm::Wrapper< std::vector< edm::Ptr< TTPixelTrack > > > W_V_P_TT_PT; + + } } diff --git a/DataFormats/L1TrackTrigger/src/classes_def.xml b/DataFormats/L1TrackTrigger/src/classes_def.xml index 12e7b9ef72a2d..9b4b5def861c5 100644 --- a/DataFormats/L1TrackTrigger/src/classes_def.xml +++ b/DataFormats/L1TrackTrigger/src/classes_def.xml @@ -40,6 +40,15 @@ + + + + + + + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc new file mode 100644 index 0000000000000..c144c6158c161 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc @@ -0,0 +1,946 @@ +////////////////////////// +// Producer by Anders // +// july 2014 @ CU // +////////////////////////// + + +#ifndef L1PIXELTRACKFIT +#define L1PIXELTRACKFIT + +//////////////////// +// FRAMEWORK HEADERS +#include "FWCore/PluginManager/interface/ModuleDef.h" +#include "FWCore/Framework/interface/MakerMacros.h" +// +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +// +#include "FWCore/Utilities/interface/InputTag.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +/////////////////////// +// DATA FORMATS HEADERS +#include "DataFormats/Common/interface/Handle.h" +#include "DataFormats/Common/interface/EDProduct.h" +#include "DataFormats/Common/interface/Ref.h" +#include "DataFormats/TrackerRecHit2D/interface/SiPixelRecHitCollection.h" +// +#include "DataFormats/DetId/interface/DetId.h" +#include "DataFormats/SiPixelDetId/interface/PXBDetId.h" +#include "DataFormats/SiPixelDetId/interface/PXFDetId.h" +#include "DataFormats/Common/interface/DetSetVector.h" +// +#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" +#include "SimDataFormats/TrackingHit/interface/PSimHit.h" +#include "SimDataFormats/Track/interface/SimTrack.h" +#include "SimDataFormats/Track/interface/SimTrackContainer.h" +#include "SimDataFormats/Vertex/interface/SimVertex.h" +#include "SimDataFormats/Vertex/interface/SimVertexContainer.h" +// +#include "DataFormats/Math/interface/LorentzVector.h" +#include "DataFormats/Math/interface/Vector3D.h" +// +#include "DataFormats/L1TrackTrigger/interface/TTStub.h" +#include "DataFormats/L1TrackTrigger/interface/TTTrack.h" +#include "DataFormats/L1TrackTrigger/interface/TTPixelTrack.h" +// +#include "DataFormats/HepMCCandidate/interface/GenParticle.h" +#include "DataFormats/Candidate/interface/Candidate.h" +// +#include "DataFormats/GeometryCommonDetAlgo/interface/MeasurementPoint.h" +#include "DataFormats/BeamSpot/interface/BeamSpot.h" +#include "DataFormats/SiPixelDetId/interface/PixelChannelIdentifier.h" +#include "TrackingTools/GeomPropagators/interface/HelixArbitraryPlaneCrossing.h" +//////////////////////// +// FAST SIMULATION STUFF +#include "FastSimulation/Particle/interface/RawParticle.h" +#include "FastSimulation/BaseParticlePropagator/interface/BaseParticlePropagator.h" + +//////////////////////////// +// DETECTOR GEOMETRY HEADERS +#include "MagneticField/Engine/interface/MagneticField.h" +#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetType.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelTopologyBuilder.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/RectangularPixelTopology.h" +#include "Geometry/CommonDetUnit/interface/GeomDetType.h" +#include "Geometry/CommonDetUnit/interface/GeomDetUnit.h" +// +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerDetUnit.h" +#include "DataFormats/SiPixelDetId/interface/StackedTrackerDetId.h" + +//////////////// +// PHYSICS TOOLS +#include "RecoTracker/TkSeedGenerator/interface/FastHelix.h" +#include "TrackingTools/TrajectoryState/interface/FreeTrajectoryState.h" +// +#include "DataFormats/GeometryCommonDetAlgo/interface/MeasurementVector.h" +#include "DataFormats/GeometrySurface/interface/BoundPlane.h" + +#include "SLHCUpgradeSimulations/L1TrackTrigger/interface/StubPtConsistency.h" + +////////////// +// STD HEADERS +#include +#include +#include +#include + +////////////// +// NAMESPACES +// using namespace std; +// using namespace reco; +using namespace edm; + + +////////////////////////////// +// // +// CLASS DEFINITION // +// // +////////////////////////////// + +class L1PixelTrackFit : public edm::EDProducer +{ +public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + + /// Constructor/destructor + explicit L1PixelTrackFit(const edm::ParameterSet& iConfig); + virtual ~L1PixelTrackFit(); + +protected: + +private: + + /// Containers of parameters passed by python configuration file + edm::ParameterSet config; + + void multifit(double invr, double phi0, double t, double z0, + std::vector hitL1, + std::vector hitL2, + std::vector hitL3, + std::vector hitL4, + std::vector hitD1, + std::vector hitD2, + std::vector hitD3, + bool& success, + double& invrfit, + double& phi0fit, + double& d0fit, + double& tfit, + double& z0fit, + double& chisqfit); + + /// ///////////////// /// + /// MANDATORY METHODS /// + virtual void beginRun( const edm::Run& run, const edm::EventSetup& iSetup ); + virtual void endRun( const edm::Run& run, const edm::EventSetup& iSetup ); + virtual void produce( edm::Event& iEvent, const edm::EventSetup& iSetup ); + + void invert(double M[5][10],unsigned int n); + void calculateDerivatives(double rinv, double phi0, double t, double z0, + std::vector fithits, + std::vector fitbarrel, + double D[5][8], double MinvDt[5][8]); + void linearTrackFit(double rinv, double phi0, double t, double z0, + double& rinvfit, double& phi0fit, double& d0fit, + double& tfit, double& z0fit, double& chisqfit, + std::vector fithits, + std::vector fitbarrel, + double D[5][8], double MinvDt[5][8]); + + void trackfit(double rinv, double phi0, double t, double z0, + double& rinvfit, double& phi0fit, double& d0fit, + double& tfit, double& z0fit, double& chisqfit, + std::vector fithits, + std::vector fitbarrel); + +}; + + +////////////// +// CONSTRUCTOR +L1PixelTrackFit::L1PixelTrackFit(edm::ParameterSet const& iConfig) // : config(iConfig) +{ + + produces< std::vector< TTPixelTrack > >( "Level1PixelTracks" ).setBranchAlias("Level1PixelTracks"); + +} + +///////////// +// DESTRUCTOR +L1PixelTrackFit::~L1PixelTrackFit() +{ + /// Insert here what you need to delete + /// when you close the class instance +} + +////////// +// END JOB +void L1PixelTrackFit::endRun(const edm::Run& run, const edm::EventSetup& iSetup) +{ + /// Things to be done at the exit of the event Loop + +} + +//////////// +// BEGIN JOB +void L1PixelTrackFit::beginRun(const edm::Run& run, const edm::EventSetup& iSetup ) +{ + +} + +////////// +// PRODUCE +void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + + /// Prepare output + std::auto_ptr< std::vector< TTPixelTrack > > L1PixelTracksForOutput( new std::vector< TTPixelTrack > ); + + + std::vector cl_pos; + std::vector cl_type; + + ////////////////////////////////////////////////////////// + // Geometry + ////////////////////////////////////////////////////////// + edm::ESHandle geom; + iSetup.get().get(geom); + ////////////////////////////////////////////////////////// + // RecHits + ////////////////////////////////////////////////////////// + edm::Handle recHits; + iEvent.getByLabel( "siPixelRecHits", recHits ); + SiPixelRecHitCollection::const_iterator detUnitIt = recHits->begin(); + SiPixelRecHitCollection::const_iterator detUnitItEnd = recHits->end(); + for ( ; detUnitIt != detUnitItEnd; detUnitIt++ ) { + DetId detId = DetId(detUnitIt->detId()); + SiPixelRecHitCollection::DetSet::const_iterator recHitIt = detUnitIt->begin(); + SiPixelRecHitCollection::DetSet::const_iterator recHitItEnd = detUnitIt->end(); + for ( ; recHitIt != recHitItEnd; ++recHitIt) { + LocalPoint lp = recHitIt->localPosition(); + GlobalPoint gp = ( (geom.product())->idToDet(detId) )->surface().toGlobal(lp); + if ( gp.perp() < 20.0 && fabs(gp.z()) < 55.0){ // reject outer tracker + cl_pos.push_back(gp); + std::cout << "r z : "<28.0) type=-1; + if (fabs(gp.z())>35.0) type=-2; + if (fabs(gp.z())>45.0) type=-3; + std::cout << "r z type : "< L1TrackHandle; + //iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); + + //edm::Handle L1TrackHandle; + iEvent.getByLabel("TTTracksFromPixelDigis", "Level1TTTracks", L1TrackHandle); + + //Very inefficient double nested loop... + L1TkTrackCollectionType::const_iterator iterL1Track; + int itrack=0; + for (iterL1Track = L1TrackHandle->begin(); iterL1Track != L1TrackHandle->end(); ++iterL1Track) { + double invr=iterL1Track->getRInv(); + double phi0=iterL1Track->getMomentum().phi(); + double z0=iterL1Track->getPOCA().z(); + double eta=iterL1Track->getMomentum().eta(); + double t=tan(2.0*atan(1.0)-2.0*atan(exp(-eta))); + std::vector hitL1; + std::vector hitL2; + std::vector hitL3; + std::vector hitL4; + std::vector hitD1; + std::vector hitD2; + std::vector hitD3; + + static const double m_pi=4.0*atan(1.0); + + for(unsigned int i=0;i0) { + //handle barrel hit here + double rhit=cl_pos[i].perp(); + double tmp=asin(0.5*rhit*invr); + double phi_proj=phi0-tmp; + double z_proj=z0+2.0*t*tmp/invr; + std::cout<<" rhit zhit z_proj : "<1.0) continue; // 1 cm cut in z!!! + double dphi=phi_proj-cl_pos[i].phi(); + if (dphi>m_pi) dphi-=2.0*m_pi; + if (dphi<-m_pi) dphi+=2.0*m_pi; + if (fabs(dphi*rhit)>0.3) continue; // 3 mm cut in phi!!! + //found matching hit + if (cl_type[i]==1) hitL1.push_back(cl_pos[i]); + if (cl_type[i]==2) hitL2.push_back(cl_pos[i]); + if (cl_type[i]==3) hitL3.push_back(cl_pos[i]); + if (cl_type[i]==4) hitL4.push_back(cl_pos[i]); + + } else { + //handle disk hit here + double zhit=cl_pos[i].z(); + double tmp=0.5*(zhit-z0)*invr/t; + double r_proj=2.0*sin(tmp)/invr; + double phi_proj=phi0-tmp; + if (fabs(r_proj-cl_pos[i].perp())>0.5) continue; // 5 mm cut in r!!! + double dphi=phi_proj-cl_pos[i].phi(); + if (dphi>m_pi) dphi-=2.0*m_pi; + if (dphi<-m_pi) dphi+=2.0*m_pi; + if (fabs(dphi*cl_pos[i].perp())>0.3) continue; // 3 mm cut in phi!!! + //found matching hit + if (cl_type[i]==-1) hitD1.push_back(cl_pos[i]); + if (cl_type[i]==-2) hitD2.push_back(cl_pos[i]); + if (cl_type[i]==-3) hitD3.push_back(cl_pos[i]); + } + } + + bool success=false; + double invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit; + + multifit(invr,phi0,t,z0,hitL1,hitL2,hitL3,hitL4,hitD1,hitD2,hitD3,success,invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit); + + if (success) { + + TTPixelTrack aTrack; + + const GlobalVector aMomentum; + + GlobalPoint thePOCA(d0fit*cos(phi0fit),-d0fit*sin(phi0fit),z0); + + double pt=iterL1Track->getMomentum().perp(); //FIXME using old pt + + GlobalVector theMomentum(GlobalVector::Cylindrical(pt,phi0fit,pt*tfit)); + + edm::Ref< L1TkTrackCollectionType > L1TrackPtr( L1TrackHandle, itrack) ; + + aTrack.init(L1TrackPtr,theMomentum,thePOCA,invrfit,chisqfit); + + L1PixelTracksForOutput->push_back(aTrack); + + } + + itrack++; + + }// end loop L1 tracks + + + + + + iEvent.put( L1PixelTracksForOutput, "Level1PixelTracks"); + +} /// End of produce() + + +void L1PixelTrackFit::multifit(double rinv, double phi0, double t, double z0, + std::vector hitL1, + std::vector hitL2, + std::vector hitL3, + std::vector hitL4, + std::vector hitD1, + std::vector hitD2, + std::vector hitD3, + bool& success, + double& invrfinal, + double& phi0final, + double& d0final, + double& tfinal, + double& z0final, + double& chisqfinal) { + + success=false; + + static ofstream out("fitdump.txt"); + + out << "L1Track: " << rinv << " " << phi0 << " " << t << " " << z0 << std::endl; + out << hitL1.size() << std::endl; + for(unsigned int i=0;i hits[7]; + bool barrel[7]; + + barrel[0]=true; + barrel[1]=true; + barrel[2]=true; + barrel[3]=true; + barrel[4]=false; + barrel[5]=false; + barrel[6]=false; + + hits[0]=hitL1; + hits[1]=hitL2; + hits[2]=hitL3; + hits[3]=hitL4; + hits[4]=hitD1; + hits[5]=hitD2; + hits[6]=hitD3; + + + //sort on number of hits per layer + + bool more=false; + do { + more=false; + for(int i=0;i<6;i++) { + if (hits[i].size() tmp=hits[i]; + hits[i]=hits[i+1]; + hits[i+1]=tmp; + bool tmpb=barrel[i]; + barrel[i]=barrel[i+1]; + barrel[i+1]=tmpb; + } + } + } while(more); + + //now start fitting + + double bestChisqdof=1e30; + int i0best; + int i1best; + int i2best; + int i3best; + double rinvbest=9999.9; + double phi0best=9999.9; + double d0best=9999.9; + double tbest=9999.9; + double z0best=9999.9; + + + for(unsigned int i0=0;i0 fithits; + std::vector fitbarrel; + if (i0 fithits, + std::vector fitbarrel, + double D[5][8], double MinvDt[5][8]){ + + + unsigned int n=fithits.size(); + + //Next calculate the residuals + + double delta[40]; + + double chisq=0; + + unsigned int j=0; + + for(unsigned int i=0;i0.0) Deltai=-Deltai; + theta0=asin(Deltai/ri); + + Delta=Deltai-r_track*sin(theta0-(phi_track-phii)); + + if (iii==0) cout << "Numerical rinv derivative: "< fithits, + std::vector fitbarrel){ + + double D[5][8]; + double MinvDt[5][8]; + + + + calculateDerivatives(rinv, phi0, t, z0,fithits,fitbarrel,D,MinvDt); + linearTrackFit(rinv, phi0, t, z0, + rinvfit, phi0fit, d0fit, tfit, z0fit, chisqfit, + fithits,fitbarrel,D,MinvDt); + +} + + + + +// /////////////////////////// +// // DEFINE THIS AS A PLUG-IN +DEFINE_FWK_MODULE(L1PixelTrackFit); + +#endif + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py new file mode 100644 index 0000000000000..50023e1554342 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py @@ -0,0 +1,119 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("Demo") + +process.load('FWCore.MessageService.MessageLogger_cfi') +process.load('SimGeneral.MixingModule.mixNoPU_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Configuration.StandardSequences.L1HwVal_cff') +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +process.load('SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff') + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + +'/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/SingleTau1p/NoPU/SingleTau1p_E2023TTI_NoPU.root' +#'/store/group/comm_trigger/L1TrackTrigger/620_SLHC12/Extended2023TTI/ZH_HToBB_ZToNuNu/NoPU/ZH_Hbb_E2023TTI_NoPU.root' + + + + ) +) + + +process.load('Configuration.StandardSequences.Services_cff') +process.load('Configuration.StandardSequences.RawToDigi_Data_cff') ###check this for MC! +process.load('Configuration.StandardSequences.L1Reco_cff') +process.load('Configuration/StandardSequences/EndOfProcess_cff') + +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + +################################################################################################# +# L1 Track +################################################################################################# + +# for 6.1 +# process.L1TrackTrigger_step = cms.Path(process.L1TrackTrigger) +# process.BeamSpotFromSim = cms.EDProducer("BeamSpotFromSimProducer") +# process.TT_step = cms.Path(process.BeamSpotFromSim*process.L1Tracks) + +# -- Run the L1Tracking : + +process.load('IOMC.EventVertexGenerators.VtxSmearedGauss_cfi') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') + +process.BeamSpotFromSim =cms.EDProducer("BeamSpotFromSimProducer") + +process.load('Configuration.StandardSequences.L1TrackTrigger_cff') + +# if one wants to change the extrapolation window : +process.TTTracksFromPixelDigis.phiWindowSF = cms.untracked.double(2.0) # default is 1.0 + +process.TT_step = cms.Path(process.TrackTriggerTTTracks) +process.TTAssociator_step = cms.Path(process.TrackTriggerAssociatorTracks) + +process.load('SLHCUpgradeSimulations.L1TrackTrigger.L1TkJetProducer_cfi') +process.L1TkJetsL1 = process.L1TkJets.clone() + +################################################################################################# +# Analyzer +################################################################################################# +#process.L1PixelTrigger = cms.EDAnalyzer('L1PixelTrigger', +# L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis", "Level1TTTracks"), +# L1TkJetInputTag = cms.InputTag("L1TkJetsL1","Central") +# #L1TkJetInputTag = cms.InputTag("L1TkJets","Central") +# #L1TkJetInputTag = cms.InputTag("L1CalibFilterTowerJetProducer","CalibratedTowerJets") +## tau = cms.InputTag("SLHCL1ExtraParticles","Taus"), +## egamma = cms.InputTag("SLHCL1ExtraParticlesNewClustering","EGamma") +#) + +process.L1PixelTrackFit = cms.EDProducer("L1PixelTrackFit") + +process.p = cms.Path( + process.RawToDigi+ + process.valHcalTriggerPrimitiveDigis+ + process.SLHCCaloTrigger+ + process.L1TkJetsL1+ + process.siPixelRecHits +) + +from RecoLocalTracker.SiPixelRecHits.SiPixelRecHits_cfi import * +process.siPixelRecHits = siPixelRecHits + +process.raw2digi_step = cms.Path(process.RawToDigi) +process.mix.digitizers = cms.PSet(process.theDigitizersValid) + +# bug fix for missing HCAL TPs in MC RAW +from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT +HcalTPGCoderULUT.LUTGenerationMode = cms.bool(True) +process.valRctDigis.hcalDigis = cms.VInputTag(cms.InputTag('valHcalTriggerPrimitiveDigis')) +process.L1CaloTowerProducer.HCALDigis = cms.InputTag("valHcalTriggerPrimitiveDigis") + + +################################################################################################# +# Output file +################################################################################################# +process.TFileService = cms.Service("TFileService", fileName = cms.string('ntuple.root') ) + + +# Schedule definition +#process.schedule = cms.Schedule(process.raw2digi_step,process.TT_step,process.reconstruction_step,process.p) +#process.schedule = cms.Schedule(process.TT_step,process.L1TkJetsL1,process.p) +#process.schedule = cms.Schedule(process.TT_step,process.L1TkJetsL1) + + +# Automatic addition of the customisation function from SLHCUpgradeSimulations.Configuration.combinedCustoms +from SLHCUpgradeSimulations.Configuration.combinedCustoms import cust_2023TTI + +#call to customisation function cust_2023TTI imported from SLHCUpgradeSimulations.Configuration.combinedCustoms +process = cust_2023TTI(process) + +process.p2 = cms.Path( + process.L1PixelTrackFit +) From a7faeda8badc754e2ff810a130d99fef7b36a599 Mon Sep 17 00:00:00 2001 From: Anders Date: Tue, 22 Jul 2014 11:42:37 +0200 Subject: [PATCH 070/252] Updates to use 5 parameter fit as starting point for pixel refit --- .../L1TrackTrigger/plugins/L1PixelTrackFit.cc | 63 ++++++++++++------- 1 file changed, 40 insertions(+), 23 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc index c144c6158c161..c822c1c6ff688 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc @@ -1,6 +1,6 @@ ////////////////////////// // Producer by Anders // -// july 2014 @ CU // +// July 2014 @ CU // ////////////////////////// @@ -128,7 +128,7 @@ class L1PixelTrackFit : public edm::EDProducer /// Containers of parameters passed by python configuration file edm::ParameterSet config; - void multifit(double invr, double phi0, double t, double z0, + void multifit(double invr, double phi0, double d0, double t, double z0, std::vector hitL1, std::vector hitL2, std::vector hitL3, @@ -155,14 +155,14 @@ class L1PixelTrackFit : public edm::EDProducer std::vector fithits, std::vector fitbarrel, double D[5][8], double MinvDt[5][8]); - void linearTrackFit(double rinv, double phi0, double t, double z0, + void linearTrackFit(double rinv, double phi0, double d0, double t, double z0, double& rinvfit, double& phi0fit, double& d0fit, double& tfit, double& z0fit, double& chisqfit, std::vector fithits, std::vector fitbarrel, double D[5][8], double MinvDt[5][8]); - void trackfit(double rinv, double phi0, double t, double z0, + void trackfit(double rinv, double phi0, double d0, double t, double z0, double& rinvfit, double& phi0fit, double& d0fit, double& tfit, double& z0fit, double& chisqfit, std::vector fithits, @@ -264,11 +264,17 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) L1TkTrackCollectionType::const_iterator iterL1Track; int itrack=0; for (iterL1Track = L1TrackHandle->begin(); iterL1Track != L1TrackHandle->end(); ++iterL1Track) { - double invr=iterL1Track->getRInv(); - double phi0=iterL1Track->getMomentum().phi(); - double z0=iterL1Track->getPOCA().z(); - double eta=iterL1Track->getMomentum().eta(); + int npar=5; + double invr=iterL1Track->getRInv(npar); + int charge=1; + if (invr<0.0) charge=-1; + double phi0=iterL1Track->getMomentum(npar).phi(); + double z0=iterL1Track->getPOCA(npar).z(); + double eta=iterL1Track->getMomentum(npar).eta(); + double d0=-iterL1Track->getPOCA(npar).perp(); + if (cos(phi0)*iterL1Track->getPOCA(npar).x()<0.0) d0=-d0; double t=tan(2.0*atan(1.0)-2.0*atan(exp(-eta))); + std::vector hitL1; std::vector hitL2; std::vector hitL3; @@ -284,7 +290,7 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) //handle barrel hit here double rhit=cl_pos[i].perp(); double tmp=asin(0.5*rhit*invr); - double phi_proj=phi0-tmp; + double phi_proj=phi0-tmp-charge*d0/rhit; double z_proj=z0+2.0*t*tmp/invr; std::cout<<" rhit zhit z_proj : "<1.0) continue; // 1 cm cut in z!!! @@ -301,10 +307,11 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) } else { //handle disk hit here double zhit=cl_pos[i].z(); + double rhit=cl_pos[i].perp(); double tmp=0.5*(zhit-z0)*invr/t; double r_proj=2.0*sin(tmp)/invr; - double phi_proj=phi0-tmp; - if (fabs(r_proj-cl_pos[i].perp())>0.5) continue; // 5 mm cut in r!!! + double phi_proj=phi0-tmp-charge*d0/rhit; + if (fabs(r_proj-rhit)>0.5) continue; // 5 mm cut in r!!! double dphi=phi_proj-cl_pos[i].phi(); if (dphi>m_pi) dphi-=2.0*m_pi; if (dphi<-m_pi) dphi+=2.0*m_pi; @@ -319,7 +326,7 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) bool success=false; double invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit; - multifit(invr,phi0,t,z0,hitL1,hitL2,hitL3,hitL4,hitD1,hitD2,hitD3,success,invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit); + multifit(invr,phi0,d0,t,z0,hitL1,hitL2,hitL3,hitL4,hitD1,hitD2,hitD3,success,invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit); if (success) { @@ -327,7 +334,7 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) const GlobalVector aMomentum; - GlobalPoint thePOCA(d0fit*cos(phi0fit),-d0fit*sin(phi0fit),z0); + GlobalPoint thePOCA(d0fit*cos(phi0fit),-d0fit*sin(phi0fit),z0fit); double pt=iterL1Track->getMomentum().perp(); //FIXME using old pt @@ -354,7 +361,8 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) } /// End of produce() -void L1PixelTrackFit::multifit(double rinv, double phi0, double t, double z0, +void L1PixelTrackFit::multifit(double rinv, double phi0, double d0, + double t, double z0, std::vector hitL1, std::vector hitL2, std::vector hitL3, @@ -372,6 +380,7 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double t, double z0, success=false; + /* static ofstream out("fitdump.txt"); out << "L1Track: " << rinv << " " << phi0 << " " << t << " " << z0 << std::endl; @@ -404,6 +413,7 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double t, double z0, out << hitD3[i].x() << " " << hitD3[i].y() << " " << hitD3[i].z() << std::endl; } + */ std::vector hits[7]; bool barrel[7]; @@ -488,7 +498,7 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double t, double z0, fitbarrel.push_back(barrel[3]); } double rinvfit,phi0fit,d0fit,tfit,z0fit,chisqfit; - trackfit(rinv,phi0,t,z0, + trackfit(rinv,phi0,d0,t,z0, rinvfit,phi0fit,d0fit,tfit,z0fit,chisqfit, fithits,fitbarrel); double chisqdof=chisqfit/(2.0*npixel-4.0); @@ -506,7 +516,8 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double t, double z0, } std::cout << "Original: rinv="< 1.479 ) + { + if ( cluster.hovere() < 22./cluster.pt() + && cluster.isolation() < 64./cluster.pt()+0.1 + && cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cluster.pt() < 40) ? 0.18*(1-cluster.pt()/70.):0.18*3/7. ) ) + { + return true; + } + } + else + { + if ( cluster.hovere() < 14./cluster.pt()+0.05 + && cluster.isolation() < 40./cluster.pt()+0.1 + && cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cluster.pt() < 30) ? 0.18*(1-cluster.pt()/100.):0.18*0.7 ) ) + { + return true; + } + } + return false; +} + DEFINE_FWK_MODULE(L1EGCrystalClusterProducer); From 1f9a6095aa358c08247fd79ca52becf113a688e6 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Sun, 27 Jul 2014 19:41:17 +0200 Subject: [PATCH 072/252] collections of TkTaus now sorted in PT --- DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc | 3 --- .../L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc | 2 +- .../L1TrackTrigger/plugins/L1TkEmTauProducer.cc | 2 +- .../L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc | 2 +- .../L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc | 2 +- 5 files changed, 4 insertions(+), 7 deletions(-) diff --git a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc index 818a8bd4c888e..602fc72b04940 100644 --- a/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc +++ b/DataFormats/L1TrackTrigger/src/L1TkMuonParticle.cc @@ -72,6 +72,3 @@ int L1TkMuonParticle::bx() const { return dummy; } - - - diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc index 703cc4c07aa8b..ad6b69855ccfe 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1CaloTausToTkTausTranslator.cc @@ -107,7 +107,7 @@ void L1CaloTausToTkTausTranslator::produce(edm::Event& iEvent, const edm::EventS } - //sort( result->begin(), result->end(), L1TkTau::EtComparator() ); + sort( result->begin(), result->end(), L1TkTau::EtComparator() ); iEvent.put( result ); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc index e586a56a08dbd..0af1a4d0fd63d 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkEmTauProducer.cc @@ -342,7 +342,7 @@ L1TkEmTauProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) } - //sort( result ->begin(), result ->end(), L1TkTau::EtComparator() ); + sort( result ->begin(), result ->end(), L1TkTau::EtComparator() ); iEvent.put( result ); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc index 70220ea7bfa46..a6c4b5cb34895 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromCaloProducer.cc @@ -422,7 +422,7 @@ void L1TkTauFromCaloProducer::produce(edm::Event& iEvent, const edm::EventSetup& } /// For-loop: m_L1TkClusterToL1TkTracks elements - //sort( result->begin(), result->end(), L1TkTau::EtComparator() ); + sort( result->begin(), result->end(), L1TkTau::EtComparator() ); iEvent.put( result ); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc index 1ad92d3998c9a..fa58dbbd4b14b 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TkTauFromL1TrackProducer.cc @@ -305,7 +305,7 @@ L1TkTauFromL1TrackProducer::produce(edm::Event& iEvent, const edm::EventSetup& i } - //sort( result->begin(), result->end(), L1TkTau::PtComparator() ); + sort( result->begin(), result->end(), L1TkTau::PtComparator() ); iEvent.put( result ); From 8dc8d8213228b31ccb2cdb9c9610f54800bd0535 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Wed, 23 Jul 2014 20:28:46 +0200 Subject: [PATCH 073/252] hack to remove linking in the same layer --- RecoParticleFlow/PFClusterProducer/src/Arbor.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/src/Arbor.cc b/RecoParticleFlow/PFClusterProducer/src/Arbor.cc index c1fef9c44aa89..3405ec5e40032 100644 --- a/RecoParticleFlow/PFClusterProducer/src/Arbor.cc +++ b/RecoParticleFlow/PFClusterProducer/src/Arbor.cc @@ -286,7 +286,7 @@ void BuildInitLink() const auto& PosB = cleanedHits[found[j0].data]; PosDiffAB = PosA - PosB; - if( PosDiffAB.Mag2() < InitLinkThreshold2 ) // || ( PosDiffAB.Mag() < 1.6*InitLinkThreshold && PosDiffAB.Dot(PosB) < 0.9*PosDiffAB.Mag()*PosB.Mag() ) ) //Distance threshold to be optimized - should also depends on Geometry + if( std::abs(PosDiffAB.Z()) > 1e-3 && PosDiffAB.Mag2() < InitLinkThreshold2 ) // || ( PosDiffAB.Mag() < 1.6*InitLinkThreshold && PosDiffAB.Dot(PosB) < 0.9*PosDiffAB.Mag()*PosB.Mag() ) ) //Distance threshold to be optimized - should also depends on Geometry { std::pair a_Link; if( PosA.Mag2() > PosB.Mag2() ) @@ -461,7 +461,8 @@ void LinkIteration() //Energy corrections, semi-local correction PosB = cleanedHits[found[j1].data]; DiffPosAB = PosB - PosA; - if( DiffPosAB.Mag2() < IterLinkThreshold2 && + if( std::abs(DiffPosAB.Z()) > 1e-3 && + DiffPosAB.Mag2() < IterLinkThreshold2 && DiffPosAB.Mag2() > InitLinkThreshold2 && DiffPosAB.Angle(RefDir[i1]) < 0.8 ) { From 617704933e3aa9562fff6a371ef51a3b024261db Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Tue, 29 Jul 2014 16:50:11 -0500 Subject: [PATCH 074/252] Added experimental parameters map to crystal cluster container. --- .../plugins/L1EGammaCrystalsProducer.cc | 13 ++++++++++--- SimDataFormats/SLHC/interface/L1EGCrystalCluster.h | 7 +++++++ 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index d4e0a4705e061..6fb05f1aeee6b 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -226,6 +226,9 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet if ( centerhit.pt() <= 1. ) break; if ( debug ) std::cout << "-------------------------------------" << std::endl; if ( debug ) std::cout << "New cluster: center crystal pt = " << centerhit.pt() << std::endl; + + // Experimental parameters, don't want to bother with hardcoding them in data format + std::map params; // Find the energy-weighted average position, // calculate isolation parameter, @@ -260,15 +263,17 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet ", eta=" << hit.position.eta() << ", phi=" << hit.position.phi() << "\x1B[0m" << std::endl; } - // Isolation and pileup must not use hits used in a cluster - // We also cut out low pt noise + // Isolation and pileup must not use hits used in the cluster // As for the endcap hits, well, as far as this algorithm is concerned, caveat emptor... - if ( !hit.stale && hit.pt() > 0.05 ) + if ( !(!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && abs(hit.diphi(centerhit)) < 3) + && !(centerhit.isEndcapHit && hit.distanceTo(centerhit) < 3.5*1.41 ) ) { if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 14 && abs(hit.diphi(centerhit)) < 14) || (centerhit.isEndcapHit && hit.distanceTo(centerhit) < 42. )) { ECalIsolation += hit.pt(); + if ( hit.pt() > 1. ) + params["nIsoCrystals1"]++; } if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && abs(hit.diphi(centerhit)) >= 3 && abs(hit.diphi(centerhit)) < 6) || (centerhit.isEndcapHit && fabs(hit.deta(centerhit)) < 0.02 && fabs(hit.dphi(centerhit)) >= 0.0173*3 && fabs(hit.dphi(centerhit)) < 0.0173*6 )) @@ -286,6 +291,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet } weightedPosition /= totalEnergy; float totalPt = totalEnergy*sin(weightedPosition.theta()); + params["avgIsoCrystalE"] = (params["nIsoCrystals1"] > 0.) ? ECalIsolation/params["nIsoCrystals1"] : 0.; ECalIsolation /= totalPt; float totalPtPUcorr = totalPt - ECalPileUpEnergy*sin(ECalPileUpVector.theta())/19.; float bremStrength = sideLobeEnergy / totalPt; @@ -312,6 +318,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet l1slhc::L1EGCrystalCluster cluster(p4, hovere, ECalIsolation, centerhit.id, totalPtPUcorr, bremStrength); // Save pt array cluster.SetCrystalPtInfo(crystalPt); + cluster.SetExperimentalParams(params); trigCrystalClusters->push_back(cluster); // Save clusters with some cuts diff --git a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h index 0795dcdf5b72c..0a7dfd1ca6ac4 100644 --- a/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h +++ b/SimDataFormats/SLHC/interface/L1EGCrystalCluster.h @@ -2,6 +2,8 @@ #define L1EGammaCrystalsCluster_h #include +#include +#include #include #include "DataFormats/Candidate/interface/LeafCandidate.h" #include "DataFormats/DetId/interface/DetId.h" @@ -25,6 +27,9 @@ namespace l1slhc std::reverse(info.begin(), info.end()); crystalPt_ = info; }; + void SetExperimentalParams(const std::map ¶ms) { experimentalParams_ = params; }; + const std::map GetExperimentalParams() const { return experimentalParams_; }; + inline float GetExperimentalParam(std::string name) const { return experimentalParams_.at(name); }; // The index range depends on the algorithm eta,phi window, currently 3x5 // The pt should always be ordered. @@ -43,6 +48,8 @@ namespace l1slhc float bremStrength_; // Crystal pt (in order of strength) for all crystals in the cluster std::vector crystalPt_; + // For investigating novel algorithm parameters + std::map experimentalParams_; }; From 941fb6d443d8bf5924ac9752a0689db6b8411cb1 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Mon, 4 Aug 2014 12:01:38 +0100 Subject: [PATCH 075/252] use hash map when finding HGC neighbours instead of tree based map --- .../interface/PFRecHitCaloNavigator.h | 185 +++++++++------- .../interface/PFRecHitNavigatorBase.h | 24 +- .../plugins/PFRecHitProducer.cc | 21 +- .../plugins/PFRecHitProducer.h | 1 + .../python/particleFlowRecHitHGCEE_cfi.py | 1 + .../python/particleFlowRecHitHGCHEB_cfi.py | 1 + .../python/particleFlowRecHitHGCHEF_cfi.py | 1 + .../PFClusterProducer/test/hgcal_rechits.fwc | 208 +++++++++++++++--- .../PFClusterProducer/test/run_display.sh | 2 +- 9 files changed, 328 insertions(+), 116 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/interface/PFRecHitCaloNavigator.h b/RecoParticleFlow/PFClusterProducer/interface/PFRecHitCaloNavigator.h index 5c7d18ad6d6a4..35d73971e3649 100644 --- a/RecoParticleFlow/PFClusterProducer/interface/PFRecHitCaloNavigator.h +++ b/RecoParticleFlow/PFClusterProducer/interface/PFRecHitCaloNavigator.h @@ -41,84 +41,113 @@ class PFRecHitCaloNavigator : public PFRecHitNavigatorBase { virtual ~PFRecHitCaloNavigator() { if(!ownsTopo) { topology_.release(); } } - void associateNeighbours(reco::PFRecHit& hit,std::auto_ptr& hits,edm::RefProd& refProd) { - constexpr unsigned short halfDim = 1; // range in each dimension - constexpr unsigned short dimSize = 3; - constexpr CaloDirection directions[6] = { NORTH, SOUTH, EAST, WEST, UP, DOWN }; // max available directions - - DET detid( hit.detId() ); - if( detid.null() ) return; - // this is a ripoff of getWindow() from CaloSubDetTopology - NeighbourInfo cellsInWindow; - DET tmpId(detid); - NeighbourInfo fringe; - fringe.emplace_back(tmpId,std::make_tuple(0,0,0)); - - std::vector > visited_cells; - visited_cells.resize(std::pow(dimSize,DIM)); - - while (fringe.size() > 0) { - NeighbourInfo::value_type cur = fringe.back(); - fringe.pop_back(); - // check all 2*DIM neighbours (in case of 2D only check NSEW) - for (unsigned dirnum = 0; dirnum < 2*DIM; ++dirnum) { - Coordinate neighbour = getNeighbourIndex(cur.second,directions[dirnum]); - //If outside the window range - if ( std::get<0>(neighbour) < -halfDim || - std::get<0>(neighbour) > halfDim || - std::get<1>(neighbour) < -halfDim || - std::get<1>(neighbour) > halfDim || - std::get<2>(neighbour) < -halfDim || - std::get<2>(neighbour) > halfDim ) - continue; - - //Found integer index in the matrix - unsigned int_index = ( std::get<0>(neighbour) + halfDim + - dimSize * (std::get<1>(neighbour) + halfDim ) + - (DIM==3)*dimSize*dimSize * ( std::get<2>(neighbour) + halfDim ) ); - assert(int_index < visited_cells.size()); - - // check whether we have seen this neighbour already - if (visited_cells[int_index].first.visited) - // we have seen this one already - continue; - - // a new cell, get the DetId of the neighbour, mark it - // as visited and add it to the fringe - visited_cells[int_index].first.visited = true; - std::vector neighbourCells = getNeighbours(cur.first,directions[dirnum]); - - if ( neighbourCells.size() == 1 ) { - visited_cells[int_index].first.cell = neighbourCells[0]; - visited_cells[int_index].second = neighbour; - } else if ( neighbourCells.size() == 0 ) { - visited_cells[int_index].first.cell = DetId(0); - visited_cells[int_index].second = neighbour; - } else { - throw cms::Exception("getWindowError") << "Not supported subdetector for getWindow method"; - } - - if (!visited_cells[int_index].first.cell.null()) - fringe.emplace_back(visited_cells[int_index].first.cell,neighbour); - - } // loop over all possible directions - } // while some cells are left on the fringe - - for (unsigned int i=0; i(coord) != 0 || - std::get<1>(coord) != 0 || - std::get<2>(coord) != 0 ) { - associateNeighbour( id,hit,hits,refProd, - std::get<0>(coord), - std::get<1>(coord), - std::get<2>(coord) ); - } - } - } - } + void associateNeighbours(reco::PFRecHit& hit, + std::auto_ptr& hits, + const DetIdToHitIdx& hitmap, + edm::RefProd& refProd) override { + auto visited_cells = std::move( getWindow( hit ) ); + for (unsigned int i=0; i(coord) != 0 || + std::get<1>(coord) != 0 || + std::get<2>(coord) != 0 ) { + associateNeighbour( id,hit,hits,hitmap,refProd, + std::get<0>(coord), + std::get<1>(coord), + std::get<2>(coord) ); + } + } + } + } + + void associateNeighbours(reco::PFRecHit& hit, + std::auto_ptr& hits, + edm::RefProd& refProd) { + auto visited_cells = std::move( getWindow( hit ) ); + for (unsigned int i=0; i(coord) != 0 || + std::get<1>(coord) != 0 || + std::get<2>(coord) != 0 ) { + associateNeighbour( id,hit,hits,refProd, + std::get<0>(coord), + std::get<1>(coord), + std::get<2>(coord) ); + } + } + } + } + + + std::vector > getWindow(reco::PFRecHit& hit) { + constexpr unsigned short halfDim = 1; // range in each dimension + constexpr unsigned short dimSize = 3; + constexpr CaloDirection directions[6] = { NORTH, SOUTH, EAST, WEST, UP, DOWN }; // max available directions + + DET detid( hit.detId() ); + if( detid.null() ) return std::vector >(); + // this is a ripoff of getWindow() from CaloSubDetTopology + NeighbourInfo cellsInWindow; + DET tmpId(detid); + NeighbourInfo fringe; + fringe.emplace_back(tmpId,std::make_tuple(0,0,0)); + + std::vector > visited_cells; + visited_cells.resize(std::pow(dimSize,DIM)); + + while (fringe.size() > 0) { + NeighbourInfo::value_type cur = fringe.back(); + fringe.pop_back(); + // check all 2*DIM neighbours (in case of 2D only check NSEW) + for (unsigned dirnum = 0; dirnum < 2*DIM; ++dirnum) { + Coordinate neighbour = getNeighbourIndex(cur.second,directions[dirnum]); + //If outside the window range + if ( std::get<0>(neighbour) < -halfDim || + std::get<0>(neighbour) > halfDim || + std::get<1>(neighbour) < -halfDim || + std::get<1>(neighbour) > halfDim || + std::get<2>(neighbour) < -halfDim || + std::get<2>(neighbour) > halfDim ) + continue; + + //Found integer index in the matrix + unsigned int_index = ( std::get<0>(neighbour) + halfDim + + dimSize * (std::get<1>(neighbour) + halfDim ) + + (DIM==3)*dimSize*dimSize * ( std::get<2>(neighbour) + halfDim ) ); + assert(int_index < visited_cells.size()); + + // check whether we have seen this neighbour already + if (visited_cells[int_index].first.visited) + // we have seen this one already + continue; + + // a new cell, get the DetId of the neighbour, mark it + // as visited and add it to the fringe + visited_cells[int_index].first.visited = true; + std::vector neighbourCells = getNeighbours(cur.first,directions[dirnum]); + + if ( neighbourCells.size() == 1 ) { + visited_cells[int_index].first.cell = neighbourCells[0]; + visited_cells[int_index].second = neighbour; + } else if ( neighbourCells.size() == 0 ) { + visited_cells[int_index].first.cell = DetId(0); + visited_cells[int_index].second = neighbour; + } else { + throw cms::Exception("getWindowError") << "Not supported subdetector for getWindow method"; + } + + if (!visited_cells[int_index].first.cell.null()) + fringe.emplace_back(visited_cells[int_index].first.cell,neighbour); + + } // loop over all possible directions + } // while some cells are left on the fringe + + return visited_cells; + } protected: std::unique_ptr topology_; diff --git a/RecoParticleFlow/PFClusterProducer/interface/PFRecHitNavigatorBase.h b/RecoParticleFlow/PFClusterProducer/interface/PFRecHitNavigatorBase.h index ddebf1960f1af..c4d7ddb59ea3a 100644 --- a/RecoParticleFlow/PFClusterProducer/interface/PFRecHitNavigatorBase.h +++ b/RecoParticleFlow/PFClusterProducer/interface/PFRecHitNavigatorBase.h @@ -21,9 +21,12 @@ #include "Geometry/CaloGeometry/interface/TruncatedPyramid.h" #include "Geometry/Records/interface/CaloGeometryRecord.h" +#include class PFRecHitNavigatorBase { public: + typedef std::unordered_map DetIdToHitIdx; + PFRecHitNavigatorBase() {} PFRecHitNavigatorBase(const edm::ParameterSet& iConfig) {} @@ -31,10 +34,14 @@ class PFRecHitNavigatorBase { virtual void beginEvent(const edm::EventSetup&)=0; virtual void associateNeighbours(reco::PFRecHit&,std::auto_ptr&,edm::RefProd&)=0; + virtual void associateNeighbours(reco::PFRecHit&, + std::auto_ptr&, + const DetIdToHitIdx&, + edm::RefProd&) {}; protected: - + // assumes sorted void associateNeighbour(const DetId& id, reco::PFRecHit& hit,std::auto_ptr& hits,edm::RefProd& refProd,short eta, short phi,short depth) { const reco::PFRecHit temp(id,PFLayer::NONE,0.0,math::XYZPoint(0,0,0),math::XYZVector(0,0,0),std::vector()); auto found_hit = std::lower_bound(hits->begin(),hits->end(), @@ -47,7 +54,20 @@ class PFRecHitNavigatorBase { hit.addNeighbour(eta,phi,depth,reco::PFRecHitRef(refProd,std::distance(hits->begin(),found_hit))); } } - + // map to indices is provided + void associateNeighbour(const DetId& id, + reco::PFRecHit& hit, + std::auto_ptr& hits, + const DetIdToHitIdx& hitmap, + edm::RefProd& refProd, + short eta, short phi,short depth) { + auto found_hit = hitmap.find(id.rawId()); + if( found_hit != hitmap.end() ) { + auto begin = hits->begin(); + auto hit_pos = begin + found_hit->second; + hit.addNeighbour(eta,phi,depth,reco::PFRecHitRef(refProd,std::distance(begin,hit_pos))); + } + } }; diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc index 5da9d34e27dbf..ab1fd3a1410c3 100644 --- a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc @@ -7,7 +7,8 @@ namespace { } } - PFRecHitProducer:: PFRecHitProducer(const edm::ParameterSet& iConfig) +PFRecHitProducer:: PFRecHitProducer(const edm::ParameterSet& iConfig): + _useHitMap(iConfig.getUntrackedParameter("useHitMap",false)) { produces(); @@ -52,14 +53,26 @@ void creators_.at(i)->importRecHits(out,cleaned,iEvent,iSetup); } - std::sort(out->begin(),out->end(),sortByDetId); + if(!_useHitMap) std::sort(out->begin(),out->end(),sortByDetId); + + reco::PFRecHitCollection& outprod = *out; + PFRecHitNavigatorBase::DetIdToHitIdx hitmap(outprod.size()); + if( _useHitMap ) { + for( unsigned i = 0 ; i < outprod.size(); ++i ) { + hitmap[outprod[i].detId()] = i; + } + } //create a refprod here edm::RefProd refProd = iEvent.getRefBeforePut(); - for( unsigned int i=0;isize();++i) { - navigator_->associateNeighbours(out->at(i),out,refProd); + for( unsigned int i=0;iassociateNeighbours(outprod[i],out,hitmap,refProd); + } else { + navigator_->associateNeighbours(outprod[i],out,refProd); + } } iEvent.put(out,""); diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.h b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.h index 28983036cae60..a3db544c01c25 100644 --- a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.h +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.h @@ -26,6 +26,7 @@ class PFRecHitProducer : public edm::EDProducer { static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); private: + const bool _useHitMap; virtual void produce(edm::Event&, const edm::EventSetup&) override; std::vector > creators_; std::unique_ptr navigator_; diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCEE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCEE_cfi.py index 2cc4652982e89..049c21f86f523 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCEE_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCEE_cfi.py @@ -1,6 +1,7 @@ import FWCore.ParameterSet.Config as cms particleFlowRecHitHGCEE = cms.EDProducer("PFRecHitProducer", + useHitMap = cms.untracked.bool(True), navigator = cms.PSet( name = cms.string("PFRecHitHGCEENavigator"), topologySource = cms.string("HGCalEESensitive"), diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEB_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEB_cfi.py index c7f63b3ca916f..e7cb507b278a6 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEB_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEB_cfi.py @@ -1,6 +1,7 @@ import FWCore.ParameterSet.Config as cms particleFlowRecHitHGCHEB = cms.EDProducer("PFRecHitProducer", + useHitMap = cms.untracked.bool(True), navigator = cms.PSet( name = cms.string("PFRecHitHGCHENavigator"), topologySource = cms.string("HGCalHEScintillatorSensitive"), diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEF_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEF_cfi.py index 5615b9ca7da57..e8d01dd94ee9c 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEF_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHGCHEF_cfi.py @@ -1,6 +1,7 @@ import FWCore.ParameterSet.Config as cms particleFlowRecHitHGCHEF = cms.EDProducer("PFRecHitProducer", + useHitMap = cms.untracked.bool(True), navigator = cms.PSet( name = cms.string("PFRecHitHGCHENavigator"), topologySource = cms.string("HGCalHESiliconSensitive"), diff --git a/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc b/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc index 1b918813d32cf..6fb000b21c9a1 100644 --- a/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc +++ b/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc @@ -96,10 +96,10 @@ - std::vector<reco::CaloJet> + std::vector<reco::PFJet> - iterativeCone5CaloJets + ak5PFJets @@ -362,10 +362,10 @@ - std::vector<reco::MET> + std::vector<reco::PFMET> - tcMet + pfMet @@ -652,7 +652,7 @@ 1009 - t + f 31 @@ -686,7 +686,7 @@ 1011 - t + f 32 @@ -720,7 +720,7 @@ 1014 - t + f 33 @@ -734,6 +734,116 @@ + + + std::vector<reco::GenParticle> + + + genParticles + + + + + + + + + + + + 1019 + + + t + + + 34 + + + GenParticles + + + 0 + + + + + 0 + + + 2 + + + + + + + std::vector<SimTrack> + + + g4SimHits + + + + + + + + + + + + 1029 + + + t + + + 35 + + + SimTracks + + + 0 + + + + + + + std::vector<reco::PFCandidate> + + + particleFlow + + + + + + + + + + + + 1000 + + + t + + + 36 + + + PF Candidates + + + 0 + + + + @@ -787,7 +897,7 @@ 54 - 31 + 44 1263 @@ -901,22 +1011,22 @@ 1 - -0.660885 + -0.401173 - -0.653181 + -0.563483 - 0.369579 + 0.722185 0 - 0.702949 + 0.814632 - -0.71124 + -0.579978 0 @@ -925,25 +1035,25 @@ 0 - 0.262858 + 0.41885 - 0.259795 + 0.588315 - 0.9292 + 0.691701 0 - -2205.43 + -1458.17 - -2147.69 + -2016.83 - 1314.98 + 2612.92 1 @@ -985,19 +1095,19 @@ 0 - -0.180542 + -52.4547 - 0.521286 + -37.8377 - 24.0227 + 317.74 1 - 28.329 + 3.09973 @@ -1399,7 +1509,7 @@ 0 - Pt + pT pt 1 eta @@ -1417,12 +1527,6 @@ emf emEnergyFraction() 3 - size_eta - sqrt(etaetaMoment) - 3 - size_phi - sqrt(phiphiMoment) - 3 pT @@ -1482,7 +1586,7 @@ 3 - MET + et et 1 phi @@ -1533,6 +1637,46 @@ charge 0 + + Pt + pt + 1 + eta + eta + 3 + phi + phi + 3 + ECAL + p4().E() * emEnergyFraction() + 1 + HCAL + p4().E() * energyFractionHadronic() + 1 + emf + emEnergyFraction() + 3 + size_eta + sqrt(etaetaMoment) + 3 + size_phi + sqrt(phiphiMoment) + 3 + + + MET + et + 1 + phi + phi + 3 + sumEt + sumEt + 1 + mEtSig + mEtSig + 3 + pT pt @@ -1634,6 +1778,8 @@ reco::Jet reco::MET reco::Muon + reco::PFJet + reco::PFMET reco::Photon reco::Track reco::Vertex diff --git a/RecoParticleFlow/PFClusterProducer/test/run_display.sh b/RecoParticleFlow/PFClusterProducer/test/run_display.sh index 72b3beb6f68d4..f36f11d10a0e0 100755 --- a/RecoParticleFlow/PFClusterProducer/test/run_display.sh +++ b/RecoParticleFlow/PFClusterProducer/test/run_display.sh @@ -1,6 +1,6 @@ #!/bin/bash -cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g /afs/cern.ch/user/l/lgray/work/public/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file /afs/cern.ch/user/l/lgray/work/public/xHGCAL/cmsSimGeom-14-HGCAL.root /afs/cern.ch/user/l/lgray/work/public/CMSSW_6_2_X_SLHC_2014-07-17-0200/src/matrix_tests/simple_jet_gun/step3.root +cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g /home/lgray/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file /home/lgray/xHGCAL/cmsSimGeom-14-HGCAL.root /home/lgray/CMSSW_6_2_0_SLHC16/src/matrix_tests/simple_jet_gun/step3.root #12202_SinglePionPt35+SinglePionPt35_Extended2023HGCalMuon_GenSimFull+DigiFull_Extended2023HGCalMuon+RecoFull_Extended2023HGCalMuon+HARVESTFull_Extended2023HGCalMuon From 6755c4cf802e6db3019238249a0a9e94884aa2c8 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Mon, 4 Aug 2014 18:30:20 +0200 Subject: [PATCH 076/252] added L1TrackDegraded.cc --- .../L1TrackTrigger/plugins/L1TrackDegraded.cc | 181 ++++++++++++++++++ .../L1TrackTrigger/test/testDegrader_cfg.py | 58 ++++++ 2 files changed, 239 insertions(+) create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc create mode 100644 SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc new file mode 100644 index 0000000000000..0f314f748dcdb --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc @@ -0,0 +1,181 @@ +#ifndef L1TTRACK_DEGRADE_H +#define L1TTRACK_DEGRADE_H + +#include "FWCore/PluginManager/interface/ModuleDef.h" +#include "FWCore/Framework/interface/MakerMacros.h" +// +// #include "FWCore/Framework/interface/EDAnalyzer.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +// +#include "FWCore/Utilities/interface/InputTag.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "DataFormats/Common/interface/Handle.h" +#include "DataFormats/Common/interface/EDProduct.h" + +#include "DataFormats/L1TrackTrigger/interface/TTTypes.h" + +//#include "SimDataFormats/SLHC/interface/StackedTrackerTypes.h" +//#include "SimDataFormats/SLHC/interface/slhcevent.hh" +#include "DataFormats/GeometryVector/interface/GlobalPoint.h" +#include "DataFormats/GeometryVector/interface/GlobalVector.h" + +//#include "SimDataFormats/SLHC/interface/L1TBarrel.hh" +//#include "SimDataFormats/SLHC/interface/L1TDisk.hh" +//#include "SimDataFormats/SLHC/interface/L1TStub.hh" + +#include "TRandom.h" +#include "TMath.h" + + +using namespace edm; + +class L1TrackDegrader : public edm::EDProducer +{ +public: + + typedef TTTrack< Ref_PixelDigi_ > L1TkTrackType; + typedef std::vector< L1TkTrackType > L1TkTrackCollectionType; + + /// Constructor/destructor + explicit L1TrackDegrader(const edm::ParameterSet& iConfig); + virtual ~L1TrackDegrader(); + +protected: + +private: + edm::InputTag L1TrackInputTag; + + bool degradeZ0; + bool degradeMomentum; + int NsigmaPT ; // smear the PT by N sigmas + + + TRandom ran; + + + /// ///////////////// /// + /// MANDATORY METHODS /// + virtual void beginRun( edm::Run& run, const edm::EventSetup& iSetup ); + virtual void endRun( edm::Run& run, const edm::EventSetup& iSetup ); + virtual void produce( edm::Event& iEvent, const edm::EventSetup& iSetup ); +}; + + +L1TrackDegrader::L1TrackDegrader(edm::ParameterSet const& iConfig) // : config(iConfig) +{ + + L1TrackInputTag = iConfig.getParameter("L1TrackInputTag"); + + degradeZ0 = iConfig.getParameter("degradeZ0"); + degradeMomentum = iConfig.getParameter("degradeMomentum"); + NsigmaPT = iConfig.getParameter("NsigmaPT"); + + ran.SetSeed(0); + +produces< std::vector< TTTrack< Ref_PixelDigi_ > > >( "Level1TTTracks" ).setBranchAlias("Level1TTTracks"); + +} + +L1TrackDegrader::~L1TrackDegrader() +{ + /// Insert here what you need to delete + /// when you close the class instance +} + + +void L1TrackDegrader::beginRun(edm::Run& run, const edm::EventSetup& iSetup ) +{ +} + + +void L1TrackDegrader::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) +{ + + edm::Handle L1TkTrackHandle; + iEvent.getByLabel(L1TrackInputTag, L1TkTrackHandle); + L1TkTrackCollectionType::const_iterator trackIter; + + std::auto_ptr< L1TkTrackCollectionType > L1TkTracksForOutput( new L1TkTrackCollectionType ); + + int Npar = 4; // smear the 4-parameter tracks + + for (trackIter = L1TkTrackHandle->begin(); trackIter != L1TkTrackHandle->end(); ++trackIter) { + + float Eta = fabs( trackIter->getMomentum(Npar).eta() ); + //float Pt = trackIter->getMomentum().perp(); + float z0 = trackIter->getPOCA(Npar).z(); + + L1TkTrackType smearedTrack = *trackIter; + + if ( degradeZ0 ) { + + // hard-coding of the z-smearing based on Stefano's plots + + float sigma= 0; + + if (Eta >= 0.5 && Eta < 2) sigma = 0.168 * Eta - 0.08 ; + if (Eta >= 2 && Eta < 2.3) sigma = 0.256; + + float deltaZ = ran.Gaus(0.,sigma); + float smeared_z = z0 + deltaZ ; + + float x0 = trackIter->getPOCA(Npar).x(); + float y0 = trackIter->getPOCA(Npar).y(); + + GlobalPoint smearedVertex(x0, y0, smeared_z); + smearedTrack.setPOCA( smearedVertex, Npar ); + + } + + if ( degradeMomentum ) { + + float Pt = trackIter->getMomentum().perp(); + float pz = trackIter->getMomentum().z(); + float Phi = trackIter->getMomentum().phi(); + + float NewPt = Pt; // the NewPt would be smeared + /* typically something like : + depending on Pt and eta, pick up the resolution (sigma) from Louise's histogram + float deltaPt = ran.Gaus(0., sigma); + float NewPt = Pt + NsigmaPT * deltaPt : + */ + + float NewPz = pz * NewPt / Pt; + GlobalVector smearedMomentum(GlobalVector::Cylindrical( NewPt, + Phi, NewPz )); + smearedTrack.setMomentum( smearedMomentum, Npar ); + } + + L1TkTracksForOutput->push_back( smearedTrack ); + + } + + iEvent.put( L1TkTracksForOutput, "Level1TTTracks"); + +} + + +void L1TrackDegrader::endRun(edm::Run& run, const edm::EventSetup& iSetup) +{ + /// Things to be done at the exit of the event Loop + +} + +// /////////////////////////// +// // DEFINE THIS AS A PLUG-IN +DEFINE_FWK_MODULE(L1TrackDegrader); + +#endif + + + + + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py new file mode 100644 index 0000000000000..0140ecf9a0e16 --- /dev/null +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py @@ -0,0 +1,58 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("VTX") + +# +# This runs over a file containing L1Tracks, and determines the +# event primary vertex by running the L1TkFastVertexProducer. +# + + +process.load("FWCore.MessageService.MessageLogger_cfi") + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32( 10 ) ) + +from SLHCUpgradeSimulations.L1TrackTrigger.ttbarFiles_cfi import * + + + +process.source = cms.Source("PoolSource", + fileNames = ttbarFiles +) + + +# ---- Global Tag : +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') + + +process.L1TrackDegrader = cms.EDProducer("L1TrackDegrader", + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), + degradeZ0 = cms.bool( True ), + degradeMomentum = cms.bool( False ), + NsigmaPT = cms.int32( 3 ) +) + +process.p = cms.Path( process.L1TrackDegrader ) + +process.Out = cms.OutputModule( "PoolOutputModule", + fileName = cms.untracked.string( "example.root" ), + fastCloning = cms.untracked.bool( False ), + outputCommands = cms.untracked.vstring( 'drop *') + +) + + + # the degraded tracks +process.Out.outputCommands.append('keep *_L1TrackDegrader_*_*') + + # the L1Tracks, clusters and stubs +process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') + + +process.FEVToutput_step = cms.EndPath(process.Out) + + + + From c09741392d6896daa31b639aaae51f752ba7861a Mon Sep 17 00:00:00 2001 From: Nick Smith Date: Tue, 5 Aug 2014 14:18:25 -0500 Subject: [PATCH 077/252] New sidelobe energy included in crystal EG alg., makes pt resolution have less brem tail. --- .../plugins/L1EGammaCrystalsProducer.cc | 39 +++++++++++++------ 1 file changed, 27 insertions(+), 12 deletions(-) diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc index 6fb05f1aeee6b..fef88b4fd8f7a 100644 --- a/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc +++ b/SLHCUpgradeSimulations/L1CaloTrigger/plugins/L1EGammaCrystalsProducer.cc @@ -239,7 +239,8 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet float totalEnergy = 0.; float ECalIsolation = 0.; float ECalPileUpEnergy = 0.; - float sideLobeEnergy = 0.; + float upperSideLobeEnergy = 0.; + float lowerSideLobeEnergy = 0.; std::vector crystalPt; for(auto& hit : ecalhits) { @@ -275,10 +276,15 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet if ( hit.pt() > 1. ) params["nIsoCrystals1"]++; } - if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && abs(hit.diphi(centerhit)) >= 3 && abs(hit.diphi(centerhit)) < 6) - || (centerhit.isEndcapHit && fabs(hit.deta(centerhit)) < 0.02 && fabs(hit.dphi(centerhit)) >= 0.0173*3 && fabs(hit.dphi(centerhit)) < 0.0173*6 )) + if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && hit.diphi(centerhit) >= 3 && hit.diphi(centerhit) < 6) + || (centerhit.isEndcapHit && fabs(hit.deta(centerhit)) < 0.02 && hit.dphi(centerhit) >= 0.0173*3 && hit.dphi(centerhit) < 0.0173*6 )) { - sideLobeEnergy += hit.pt(); + upperSideLobeEnergy += hit.pt(); + } + if ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 2 && hit.diphi(centerhit) > -6 && hit.diphi(centerhit) <= -3) + || (centerhit.isEndcapHit && fabs(hit.deta(centerhit)) < 0.02 && hit.dphi(centerhit)*-1 >= 0.0173*3 && hit.dphi(centerhit)*-1 < 0.0173*6 )) + { + lowerSideLobeEnergy += hit.pt(); } if ( hit.pt() < 5. && ( (!centerhit.isEndcapHit && abs(hit.dieta(centerhit)) < 7 && abs(hit.diphi(centerhit)) < 57 ) @@ -291,10 +297,18 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet } weightedPosition /= totalEnergy; float totalPt = totalEnergy*sin(weightedPosition.theta()); + float correctedTotalPt = totalPt; + if ( upperSideLobeEnergy/totalPt > 0.1 && upperSideLobeEnergy > lowerSideLobeEnergy ) + correctedTotalPt += upperSideLobeEnergy; + if ( lowerSideLobeEnergy/totalPt > 0.1 && lowerSideLobeEnergy > upperSideLobeEnergy ) + correctedTotalPt += lowerSideLobeEnergy; + params["uncorrectedPt"] = totalPt; params["avgIsoCrystalE"] = (params["nIsoCrystals1"] > 0.) ? ECalIsolation/params["nIsoCrystals1"] : 0.; + params["upperSideLobeEnergy"] = upperSideLobeEnergy; + params["lowerSideLobeEnergy"] = lowerSideLobeEnergy; ECalIsolation /= totalPt; float totalPtPUcorr = totalPt - ECalPileUpEnergy*sin(ECalPileUpVector.theta())/19.; - float bremStrength = sideLobeEnergy / totalPt; + float bremStrength = (upperSideLobeEnergy + lowerSideLobeEnergy) / params["uncorrectedPt"]; if ( debug ) std::cout << "Weighted position eta = " << weightedPosition.eta() << ", phi = " << weightedPosition.phi() << std::endl; if ( debug ) std::cout << "Total energy = " << totalEnergy << ", total pt = " << totalPt << std::endl; @@ -314,7 +328,7 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet if ( debug ) std::cout << "H/E: " << hovere << std::endl; // Form a l1slhc::L1EGCrystalCluster - reco::Candidate::PolarLorentzVector p4(totalPt, weightedPosition.eta(), weightedPosition.phi(), 0.); + reco::Candidate::PolarLorentzVector p4(correctedTotalPt, weightedPosition.eta(), weightedPosition.phi(), 0.); l1slhc::L1EGCrystalCluster cluster(p4, hovere, ECalIsolation, centerhit.id, totalPtPUcorr, bremStrength); // Save pt array cluster.SetCrystalPtInfo(crystalPt); @@ -337,20 +351,21 @@ void L1EGCrystalClusterProducer::produce(edm::Event& iEvent, const edm::EventSet bool L1EGCrystalClusterProducer::cluster_passes_cuts(const l1slhc::L1EGCrystalCluster& cluster) const { + float cut_pt = cluster.GetExperimentalParam("uncorrectedPt"); if ( fabs(cluster.eta()) > 1.479 ) { - if ( cluster.hovere() < 22./cluster.pt() - && cluster.isolation() < 64./cluster.pt()+0.1 - && cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cluster.pt() < 40) ? 0.18*(1-cluster.pt()/70.):0.18*3/7. ) ) + if ( cluster.hovere() < 22./cut_pt + && cluster.isolation() < 64./cut_pt+0.1 + && cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cut_pt < 40) ? 0.18*(1-cut_pt/70.):0.18*3/7. ) ) { return true; } } else { - if ( cluster.hovere() < 14./cluster.pt()+0.05 - && cluster.isolation() < 40./cluster.pt()+0.1 - && cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cluster.pt() < 30) ? 0.18*(1-cluster.pt()/100.):0.18*0.7 ) ) + if ( cluster.hovere() < 14./cut_pt+0.05 + && cluster.isolation() < 40./cut_pt+0.1 + && cluster.GetCrystalPt(4)/(cluster.GetCrystalPt(0)+cluster.GetCrystalPt(1)) < ( (cut_pt < 30) ? 0.18*(1-cut_pt/100.):0.18*0.7 ) ) { return true; } From b0c5054ae163a5f4c2ced8eea291288926087275 Mon Sep 17 00:00:00 2001 From: Suchandra Date: Mon, 18 Aug 2014 12:41:13 +0200 Subject: [PATCH 078/252] Latest code before integrating within the framework --- .../plugins/SiPhase2DigitizerAlgorithm.cc | 729 +++--------------- .../plugins/SiPhase2DigitizerAlgorithm.h | 80 +- .../python/phase2PixelDigitizer_cfi.py | 74 +- .../SiPhase2Digitizer/test/DigiValidation.cc | 232 +++++- .../test/DigiValidationTest_cfg.py | 14 +- 5 files changed, 358 insertions(+), 771 deletions(-) diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc index e24fbdface25c..834d665890199 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc @@ -1,44 +1,3 @@ -//class SiPhase2DigitizerAlgorithm SimTracker/MyDigitizer/src/MyDigitizerAlgoithm.cc - -// Original Author Danek Kotlinski -// Ported in CMSSW by Michele Pioppi-INFN perugia -// Added DB capabilities by F.Blekman, Cornell University -// Created: Mon Sep 26 11:08:32 CEST 2005 -// Add tof, change AddNoise to tracked. 4/06 -// Change drift direction. 6/06 d.k. -// Add the statuis (non-rate dependent) inefficiency. -// -1 - no ineffciency -// 0 - static inefficency only -// 1,2 - low-lumi rate dependent inefficency added -// 10 - high-lumi inefficiency added -// Adopt the correct drift sign convetion from Morris Swartz. d.k. 8/06 -// Add more complex misscalinbration, change kev/e to 3.61, diff=3.7,d.k.9/06 -// Add the readout channel electronic noise. d.k. 3/07 -// Lower the pixel noise from 500 to 175elec. -// Change the input threshold from noise units to electrons. -// Lower the amount of static dead pixels from 0.01 to 0.001. -// Modify to the new random number services. d.k. 5/07 -// Protect against sigma=0 (delta tracks on the surface). d.k.5/07 -// Change the TOF cut to lower and upper limit. d.k. 7/07 -// -// July 2008: Split Lorentz Angle configuration in BPix/FPix (V. Cuplov) -// tanLorentzAngleperTesla_FPix=0.0912 and tanLorentzAngleperTesla_BPix=0.106 -// Sept. 2008: Disable Pixel modules which are declared dead in the configuration python file. (V. Cuplov) -// Oct. 2008: Accessing/Reading the Lorentz angle from the DataBase instead of the cfg file. (V. Cuplov) -// Accessing dead modules from the DB. Implementation done and tested on a test.db -// Do not use this option for now. The PixelQuality Objects are not in the official DB yet. -// Feb. 2009: Split Fpix and Bpix threshold and use official numbers (V. Cuplov) -// ThresholdInElectrons_FPix = 2870 and ThresholdInElectrons_BPix = 3700 -// update the electron to VCAL conversion using: VCAL_electrons = VCAL * 65.5 - 414 -// Feb. 2009: Threshold gaussian smearing (V. Cuplov) -// March, 2009: changed DB access to *SimRcd objects (to de-couple the DB objects from reco chain) (F. Blekman) -// May, 2009: Pixel charge VCAL smearing. (V. Cuplov) -// November, 2009: new parameterization of the pixel response. (V. Cuplov) -// December, 2009: Fix issue with different compilers. -// October, 2010: Improvement: Removing single dead ROC (V. Cuplov) -// November, 2010: Bug fix in removing TBMB/A half-modules (V. Cuplov) -// February, 2011: Time improvement in DriftDirection() (J. Bashir Butt) -// June, 2011: Bug Fix for pixels on ROC edges in module_killing_DB() (J. Bashir Butt) #include #include @@ -127,8 +86,8 @@ SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& _signal(), makeDigiSimLinks_(conf.getUntrackedParameter("makeDigiSimLinks", true)), - use_ineff_from_db_(conf.getParameter("useDB")), - use_module_killing_(conf.getParameter("killModules")), // boolean to kill or not modules + use_ineff_from_db_(conf.getParameter("Inefficiency_DB")), + use_module_killing_(conf.getParameter("KillModules")), // boolean to kill or not modules use_deadmodule_DB_(conf.getParameter("DeadModules_DB")), // boolean to access dead modules from DB use_LorentzAngle_DB_(conf.getParameter("LorentzAngle_DB")), // boolean to access Lorentz angle from DB @@ -149,12 +108,7 @@ SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& ClusterWidth(conf.getParameter("ClusterWidth")), // Charge integration spread on the collection plane - // get external parameters: - // To account for upgrade geometries do not assume the number - // of layers or disks. - NumberOfBarrelLayers(conf.exists("NumPixelBarrel")?conf.getParameter("NumPixelBarrel"):3), - NumberOfEndcapDisks(conf.exists("NumPixelEndcap")?conf.getParameter("NumPixelEndcap"):2), - + doDigitalReadout(conf.getParameter("DigitalReadout")), // Flag to decide analog or digital readout // ADC calibration 1adc count(135e. // Corresponds to 2adc/kev, 270[e/kev]/135[e/adc](2[adc/kev] // Be carefull, this parameter is also used in SiPixelDet.cc to @@ -163,11 +117,8 @@ SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& theElectronPerADC(conf.getParameter("ElectronPerAdc")), // ADC saturation value, 255(8bit adc. - //theAdcFullScale(conf.getUntrackedParameter("AdcFullScale",255)), theAdcFullScale(conf.getParameter("AdcFullScale")), - theAdcFullScaleStack(conf.exists("AdcFullScaleStack")?conf.getParameter("AdcFullScaleStack"):255), - theFirstStackLayer(conf.exists("FirstStackLayer")?conf.getParameter("FirstStackLayer"):5), - + // Noise in electrons: // Pixel cell noise, relevant for generating noisy pixels theNoiseInElectrons(conf.getParameter("NoiseInElectrons")), @@ -176,21 +127,15 @@ SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& //theReadoutNoise(conf.getUntrackedParameter("ReadoutNoiseInElec",500.)), theReadoutNoise(conf.getParameter("ReadoutNoiseInElec")), - // Pixel threshold in units of noise: + // Threshold in units of noise: // thePixelThreshold(conf.getParameter("ThresholdInNoiseUnits")), // Pixel threshold in electron units. - theThresholdInE_FPix(conf.getParameter("ThresholdInElectrons_FPix")), - theThresholdInE_BPix(conf.getParameter("ThresholdInElectrons_BPix")), - theThresholdInE_BPix_L1(conf.exists("ThresholdInElectrons_BPix_L1")?conf.getParameter("ThresholdInElectrons_BPix_L1"):theThresholdInE_BPix), + theThresholdInE_Endcap(conf.getParameter("ThresholdInElectrons_Endcap")), + theThresholdInE_Barrel(conf.getParameter("ThresholdInElectrons_Barrel")), // Add threshold gaussian smearing: - theThresholdSmearing_FPix(conf.getParameter("ThresholdSmearing_FPix")), - theThresholdSmearing_BPix(conf.getParameter("ThresholdSmearing_BPix")), - theThresholdSmearing_BPix_L1(conf.exists("ThresholdSmearing_BPix_L1")?conf.getParameter("ThresholdSmearing_BPix_L1"):theThresholdSmearing_BPix), - - // electrons to VCAL conversion needed in misscalibrate() - electronsPerVCAL(conf.getParameter("ElectronsPerVcal")), - electronsPerVCAL_Offset(conf.getParameter("ElectronsPerVcal_Offset")), + theThresholdSmearing_Endcap(conf.getParameter("ThresholdSmearing_Endcap")), + theThresholdSmearing_Barrel(conf.getParameter("ThresholdSmearing_Barrel")), //theTofCut 12.5, cut in particle TOD +/- 12.5ns //theTofCut(conf.getUntrackedParameter("TofCut",12.5)), @@ -198,27 +143,12 @@ SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& theTofUpperCut(conf.getParameter("TofUpperCut")), // Get the Lorentz angle from the cfg file: - tanLorentzAnglePerTesla_FPix(use_LorentzAngle_DB_ ? 0.0 : conf.getParameter("TanLorentzAnglePerTesla_FPix")), - tanLorentzAnglePerTesla_BPix(use_LorentzAngle_DB_ ? 0.0 : conf.getParameter("TanLorentzAnglePerTesla_BPix")), - - // signal response new parameterization: split Fpix and BPix - FPix_p0(conf.getParameter("FPix_SignalResponse_p0")), - FPix_p1(conf.getParameter("FPix_SignalResponse_p1")), - FPix_p2(conf.getParameter("FPix_SignalResponse_p2")), - FPix_p3(conf.getParameter("FPix_SignalResponse_p3")), - - BPix_p0(conf.getParameter("BPix_SignalResponse_p0")), - BPix_p1(conf.getParameter("BPix_SignalResponse_p1")), - BPix_p2(conf.getParameter("BPix_SignalResponse_p2")), - BPix_p3(conf.getParameter("BPix_SignalResponse_p3")), + tanLorentzAnglePerTesla_Endcap(use_LorentzAngle_DB_ ? 0.0 : conf.getParameter("TanLorentzAnglePerTesla_Endcap")), + tanLorentzAnglePerTesla_Barrel(use_LorentzAngle_DB_ ? 0.0 : conf.getParameter("TanLorentzAnglePerTesla_Barrel")), // Add noise addNoise(conf.getParameter("AddNoise")), - // Smear the pixel charge with a gaussian which RMS is a function of the - // pixel charge (Danek's study) - addChargeVCALSmearing(conf.getParameter("ChargeVCALSmearing")), - // Add noisy pixels addNoisyPixels(conf.getParameter("AddNoisyPixels")), @@ -226,16 +156,11 @@ SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& fluctuateCharge(conf.getUntrackedParameter("FluctuateCharge",true)), // Control the pixel inefficiency - AddPixelInefficiency(conf.getParameter("AddPixelInefficiencyFromPython")), + AddPixelInefficiency(conf.getParameter("AddInefficiency")), // Add threshold gaussian smearing: addThresholdSmearing(conf.getParameter("AddThresholdSmearing")), - // Get the constants for the miss-calibration studies - doMissCalibrate(conf.getParameter("MissCalibrate")), // Enable miss-calibration - theGainSmearing(conf.getParameter("GainSmearing")), // sigma of the gain smearing - theOffsetSmearing(conf.getParameter("OffsetSmearing")), //sigma of the offset smearing - // Add some pseudo-red damage pseudoRadDamage(conf.exists("PseudoRadDamage")?conf.getParameter("PseudoRadDamage"):double(0.0)), pseudoRadDamageRadius(conf.exists("PseudoRadDamageRadius")?conf.getParameter("PseudoRadDamageRadius"):double(0.0)), @@ -247,195 +172,42 @@ SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& fluctuate(fluctuateCharge ? new SiG4UniversalFluctuation(eng) : 0), theNoiser(addNoise ? new GaussianTailNoiseGenerator(eng) : 0), - calmap(doMissCalibrate ? initCal() : std::map >()), theSiPixelGainCalibrationService_(use_ineff_from_db_ ? new SiPixelGainCalibrationOfflineSimService(conf) : 0), - pixelEfficiencies_(conf, AddPixelInefficiency,NumberOfBarrelLayers,NumberOfEndcapDisks), + subdetEfficiencies_(conf), flatDistribution_((addNoise || AddPixelInefficiency || fluctuateCharge || addThresholdSmearing) ? new CLHEP::RandFlat(eng, 0., 1.) : 0), gaussDistribution_((addNoise || AddPixelInefficiency || fluctuateCharge || addThresholdSmearing) ? new CLHEP::RandGaussQ(eng, 0., theReadoutNoise) : 0), - gaussDistributionVCALNoise_((addNoise || AddPixelInefficiency || fluctuateCharge || addThresholdSmearing) ? new CLHEP::RandGaussQ(eng, 0., 1.) : 0), // Threshold smearing with gaussian distribution: - smearedThreshold_FPix_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_FPix , theThresholdSmearing_FPix) : 0), - smearedThreshold_BPix_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_BPix , theThresholdSmearing_BPix) : 0), - smearedThreshold_BPix_L1_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_BPix_L1 , theThresholdSmearing_BPix_L1) : 0) + smearedThreshold_Endcap_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_Endcap , theThresholdSmearing_Endcap) : 0), + smearedThreshold_Barrel_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_Barrel , theThresholdSmearing_Barrel) : 0) { LogInfo ("PixelDigitizer ") <<"SiPhase2DigitizerAlgorithm constructed" <<"Configuration parameters:" << "Threshold/Gain = " - << "threshold in electron FPix = " - << theThresholdInE_FPix - << "threshold in electron BPix = " - << theThresholdInE_BPix - << "threshold in electron BPix Layer1 = " - << theThresholdInE_BPix_L1 + << "threshold in electron Endcap = " + << theThresholdInE_Endcap + << "threshold in electron Barrel = " + << theThresholdInE_Barrel <<" " << theElectronPerADC << " " << theAdcFullScale << " The delta cut-off is set to " << tMax << " pix-inefficiency "< > -SiPhase2DigitizerAlgorithm::initCal() const { - - using std::cerr; - using std::cout; - using std::endl; - - std::map > calmap; - // Prepare for the analog amplitude miss-calibration - LogDebug ("PixelDigitizer ") - << " miss-calibrate the pixel amplitude "; - - const bool ReadCalParameters = false; - if(ReadCalParameters) { // Read the calibration files from file - // read the calibration constants from a file (testing only) - std::ifstream in_file; // data file pointer - char filename[80] = "phCalibrationFit_C0.dat"; - - in_file.open(filename, std::ios::in ); // in C++ - if(in_file.bad()) { - cout << " File not found " << endl; - return calmap; // signal error - } - cout << " file opened : " << filename << endl; - - char line[500]; - for (int i = 0; i < 3; i++) { - in_file.getline(line, 500,'\n'); - cout<> par0 >> par1 >> par2 >> par3 >> name >> colid >> rowid; - if(in_file.bad()) { // check for errors - cerr << "Cannot read data file" << endl; - return calmap; - } - if( in_file.eof() != 0 ) { - cerr << in_file.eof() << " " << in_file.gcount() << " " - << in_file.fail() << " " << in_file.good() << " end of file " - << endl; - return calmap; - } + std::cout << "use_ineff_from_db_ " << use_ineff_from_db_ + << " use_module_killing_ " << use_module_killing_ + << " AddPixelInefficiency " << AddPixelInefficiency + << " use_deadmodule_DB_ " << use_deadmodule_DB_ + << std::endl; - //cout << " line " << i << " " <(chan,onePix)); - - // Testing the index conversion, can be skipped - std::pair p = PixelIndices::channelToPixelROC(chan); - if(rowid!=p.first) cout<<" wrong channel row "< >::iterator ix,it; -// map >::const_iterator ip; -// for (ix = calmap.begin(); ix != calmap.end(); ++ix) { -// int i = (*ix).first; -// std::pair p = channelToPixelROC(i); -// it = calmap.find(i); -// CalParameters y = (*it).second; -// CalParameters z = (*ix).second; -// cout << i <<" "<>dummy; -// } +} - } // end if readparameters - return calmap; -} // end initCal() //========================================================================= SiPhase2DigitizerAlgorithm::~SiPhase2DigitizerAlgorithm() { LogDebug ("PixelDigitizer")<<"SiPhase2DigitizerAlgorithm deleted"; } -SiPhase2DigitizerAlgorithm::PixelEfficiencies::PixelEfficiencies(const edm::ParameterSet& conf, bool AddPixelInefficiency, int NumberOfBarrelLayers, int NumberOfEndcapDisks) { - // pixel inefficiency - // Don't use Hard coded values, read inefficiencies in from python or don't use any - int NumberOfTotLayers = NumberOfBarrelLayers + NumberOfEndcapDisks; - FPixIndex=NumberOfBarrelLayers; - if (AddPixelInefficiency){ - int i=0; - thePixelColEfficiency[i++] = conf.getParameter("thePixelColEfficiency_BPix1"); - thePixelColEfficiency[i++] = conf.getParameter("thePixelColEfficiency_BPix2"); - thePixelColEfficiency[i++] = conf.getParameter("thePixelColEfficiency_BPix3"); - if (NumberOfBarrelLayers>=4){thePixelColEfficiency[i++] = conf.getParameter("thePixelColEfficiency_BPix4");} - // - i=0; - thePixelEfficiency[i++] = conf.getParameter("thePixelEfficiency_BPix1"); - thePixelEfficiency[i++] = conf.getParameter("thePixelEfficiency_BPix2"); - thePixelEfficiency[i++] = conf.getParameter("thePixelEfficiency_BPix3"); - if (NumberOfBarrelLayers>=4){thePixelEfficiency[i++] = conf.getParameter("thePixelEfficiency_BPix4");} - // - i=0; - thePixelChipEfficiency[i++] = conf.getParameter("thePixelChipEfficiency_BPix1"); - thePixelChipEfficiency[i++] = conf.getParameter("thePixelChipEfficiency_BPix2"); - thePixelChipEfficiency[i++] = conf.getParameter("thePixelChipEfficiency_BPix3"); - if (NumberOfBarrelLayers>=4){thePixelChipEfficiency[i++] = conf.getParameter("thePixelChipEfficiency_BPix4");} - // The next is needed for Phase2 Tracker studies - if (NumberOfBarrelLayers>=5){ - if (NumberOfTotLayers>20){throw cms::Exception("Configuration") <<"MyDigitizer was given more layers than it can handle";} - // For Phase2 tracker layers just set the outermost BPix inefficiency to 99.9% - for (int j=5 ; j<=NumberOfBarrelLayers ; j++){ - thePixelColEfficiency[j-1]=0.999; - thePixelEfficiency[j-1]=0.999; - thePixelChipEfficiency[j-1]=0.999; - } - } - // - i=FPixIndex; - thePixelColEfficiency[i++] = conf.getParameter("thePixelColEfficiency_FPix1"); - thePixelColEfficiency[i++] = conf.getParameter("thePixelColEfficiency_FPix2"); - if (NumberOfEndcapDisks>=3){thePixelColEfficiency[i++] = conf.getParameter("thePixelColEfficiency_FPix3");} - i=FPixIndex; - thePixelEfficiency[i++] = conf.getParameter("thePixelEfficiency_FPix1"); - thePixelEfficiency[i++] = conf.getParameter("thePixelEfficiency_FPix2"); - if (NumberOfEndcapDisks>=3){thePixelEfficiency[i++] = conf.getParameter("thePixelEfficiency_FPix3");} - i=FPixIndex; - thePixelChipEfficiency[i++] = conf.getParameter("thePixelChipEfficiency_FPix1"); - thePixelChipEfficiency[i++] = conf.getParameter("thePixelChipEfficiency_FPix2"); - if (NumberOfEndcapDisks>=3){thePixelChipEfficiency[i++] = conf.getParameter("thePixelChipEfficiency_FPix3");} - // The next is needed for Phase2 Tracker studies - if (NumberOfEndcapDisks>=4){ - if (NumberOfTotLayers>20){throw cms::Exception("Configuration") <<"MyDigitizer was given more layers than it can handle";} - // For Phase2 tracker layers just set the extra FPix disk inefficiency to 99.9% - for (int j=4+FPixIndex ; j<=NumberOfEndcapDisks+NumberOfBarrelLayers ; j++){ - thePixelColEfficiency[j-1]=0.999; - thePixelEfficiency[j-1]=0.999; - thePixelChipEfficiency[j-1]=0.999; - } - } - } - // the first "NumberOfBarrelLayers" settings [0],[1], ... , [NumberOfBarrelLayers-1] are for the barrel pixels - // the next "NumberOfEndcapDisks" settings [NumberOfBarrelLayers],[NumberOfBarrelLayers+1], ... [NumberOfEndcapDisks+NumberOfBarrelLayers-1] - if(!AddPixelInefficiency) { // No inefficiency, all 100% efficient - for (int i=0; i >("EfficiencyFactors_Barrel"); + endcap_efficiencies = conf.getParameter< std::vector >("EfficiencyFactors_Endcap"); } //========================================================================= @@ -445,7 +217,6 @@ void SiPhase2DigitizerAlgorithm::accumulateSimHits(std::vector::const_i const GlobalVector& bfield) { // produce SignalPoint's for all SimHit's in detector // Loop over hits - uint32_t detId = pixdet->geographicalId().rawId(); for (std::vector::const_iterator ssbegin = inputBegin; ssbegin != inputEnd; ++ssbegin) { // skip hits not in this detector. @@ -476,7 +247,6 @@ void SiPhase2DigitizerAlgorithm::accumulateSimHits(std::vector::const_i induce_signal(*ssbegin, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link } // end if } // end for - } //============================================================================ @@ -487,7 +257,6 @@ void SiPhase2DigitizerAlgorithm::digitize(const PixelGeomDetUnit* pixdet, // Pixel Efficiency moved from the constructor to this method because // the information of the det are not available in the constructor // Effciency parameters. 0 - no inefficiency, 1-low lumi, 10-high lumi - uint32_t detID = pixdet->geographicalId().rawId(); const signal_map_type& theSignal = _signal[detID]; @@ -501,34 +270,18 @@ void SiPhase2DigitizerAlgorithm::digitize(const PixelGeomDetUnit* pixdet, unsigned int Sub_detid=DetId(detID).subdetId(); - float thePixelThresholdInE = 0.; + float theThresholdInE = 0.; if(theNoiseInElectrons>0.){ if(Sub_detid == PixelSubdetector::PixelBarrel){ // Barrel modules - int lay = tTopo->pxbLayer(detID); - if(addThresholdSmearing) { - if(lay==1) { - thePixelThresholdInE = smearedThreshold_BPix_L1_->fire(); // gaussian smearing - } else { - thePixelThresholdInE = smearedThreshold_BPix_->fire(); // gaussian smearing - } - } else { - if(lay==1) { - thePixelThresholdInE = theThresholdInE_BPix_L1; - } else { - thePixelThresholdInE = theThresholdInE_BPix; // no smearing - } - } + if(addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing } else { // Forward disks modules - if(addThresholdSmearing) { - thePixelThresholdInE = smearedThreshold_FPix_->fire(); // gaussian smearing - } else { - thePixelThresholdInE = theThresholdInE_FPix; // no smearing - } + if(addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing } } - #ifdef TP_DEBUG // full detector thickness float moduleThickness = pixdet->specificSurface().bounds().thickness(); @@ -537,15 +290,14 @@ void SiPhase2DigitizerAlgorithm::digitize(const PixelGeomDetUnit* pixdet, << numColumns << " " << numRows << " " << moduleThickness; #endif - if(addNoise) add_noise(pixdet, thePixelThresholdInE/theNoiseInElectrons); // generate noise + if(addNoise) add_noise(pixdet, theThresholdInE/theNoiseInElectrons); // generate noise // Do only if needed - if((AddPixelInefficiency) && (theSignal.size()>0)) - pixel_inefficiency(pixelEfficiencies_, pixdet, tTopo); // Kill some pixels - - if(use_ineff_from_db_ && (theSignal.size()>0)) - pixel_inefficiency_db(detID); + if((AddPixelInefficiency) && (theSignal.size()>0)) { + if (use_ineff_from_db_) pixel_inefficiency_db(detID); + else pixel_inefficiency(subdetEfficiencies_, pixdet, tTopo); + } if(use_module_killing_) { if (use_deadmodule_DB_) { // remove dead modules using DB @@ -555,7 +307,7 @@ void SiPhase2DigitizerAlgorithm::digitize(const PixelGeomDetUnit* pixdet, } } - make_digis(thePixelThresholdInE, detID, digis, simlinks, tTopo); + make_digis(theThresholdInE, detID, digis, simlinks, tTopo); #ifdef TP_DEBUG LogDebug ("PixelDigitizer") << "[SiPhase2DigitizerAlgorithm] converted " << digis.size() << " PixelDigis in DetUnit" << detID; @@ -580,7 +332,6 @@ void SiPhase2DigitizerAlgorithm::primary_ionization(const PSimHit& hit, std::vec int NumberOfSegments = int ( length / SegmentLength); // Number of segments if(NumberOfSegments < 1) NumberOfSegments = 1; - #ifdef TP_DEBUG LogDebug ("Pixel Digitizer") << " enter primary_ionzation " << NumberOfSegments @@ -605,13 +356,11 @@ void SiPhase2DigitizerAlgorithm::primary_ionization(const PSimHit& hit, std::vec } ionization_points.resize( NumberOfSegments); // set size - // loop over segments for ( int i = 0; i != NumberOfSegments; i++) { // Divide the segment into equal length subsegments Local3DPoint point = hit.entryPoint() + float((i+0.5)/NumberOfSegments) * direction; - if( fluctuateCharge ) energy = elossVector[i]/GeVperElectron; // Convert charge to elec. else @@ -629,7 +378,6 @@ void SiPhase2DigitizerAlgorithm::primary_ionization(const PSimHit& hit, std::vec #endif } // end for loop - delete[] elossVector; } @@ -656,7 +404,6 @@ void SiPhase2DigitizerAlgorithm::fluctuateEloss(int pid, float particleMomentum, } // What is the track segment length. float segmentLength = length/NumberOfSegs; - // Generate charge fluctuations. float de=0.; float sum=0.; @@ -676,7 +423,6 @@ void SiPhase2DigitizerAlgorithm::fluctuateEloss(int pid, float particleMomentum, elossVector[i]=de; sum +=de; } - if(sum>0.) { // If fluctuations give eloss>0. // Rescale to the same total eloss float ratio = eloss/sum; @@ -703,13 +449,12 @@ void SiPhase2DigitizerAlgorithm::drift(const PSimHit& hit, #endif collection_points.resize(ionization_points.size()); // set size - LocalVector driftDir=DriftDirection(pixdet, bfield, hit.detUnitId()); // get the charge drift direction if(driftDir.z() ==0.) { LogWarning("Magnetic field") << " pxlx: drift in z is zero "; return; } - + // tangent of Lorentz angle //float TanLorenzAngleX = driftDir.x()/driftDir.z(); //float TanLorenzAngleY = 0.; // force to 0, driftDir.y()/driftDir.z(); @@ -755,7 +500,6 @@ void SiPhase2DigitizerAlgorithm::drift(const PSimHit& hit, float DriftLength; // Actual Drift Lentgh float Sigma; - for (unsigned int i = 0; i != ionization_points.size(); i++) { float SegX, SegY, SegZ; // position @@ -811,18 +555,18 @@ void SiPhase2DigitizerAlgorithm::drift(const PSimHit& hit, float energyOnCollector = ionization_points[i].energy(); // The energy that reaches the collector // pseudoRadDamage if (pseudoRadDamage>=0.001){ - float moduleRadius = pixdet->surface().position().perp(); - if (moduleRadius<=pseudoRadDamageRadius){ - float kValue = pseudoRadDamage /(moduleRadius*moduleRadius); - //std::cout <<"\nmoduleRadius= "<surface().position().perp(); + if (moduleRadius<=pseudoRadDamageRadius){ + float kValue = pseudoRadDamage /(moduleRadius*moduleRadius); + //std::cout <<"\nmoduleRadius= "<position().x() << " " << i->position().y() << " " @@ -891,6 +634,7 @@ void SiPhase2DigitizerAlgorithm::induce_signal(const PSimHit& hit, float CloudUp = CloudCenterY + ClusterWidth*SigmaY; float CloudDown = CloudCenterY - ClusterWidth*SigmaY; + // Define 2D cloud limit points LocalPoint PointRightUp = LocalPoint(CloudRight,CloudUp); LocalPoint PointLeftDown = LocalPoint(CloudLeft,CloudDown); @@ -952,7 +696,7 @@ void SiPhase2DigitizerAlgorithm::induce_signal(const PSimHit& hit, xLB = topol->localPosition(mp).x(); LowerBound = 1-calcQ((xLB-CloudCenterX)/SigmaX); } - + if(ix == numRows-1 || SigmaX==0. ) UpperBound = 1.; else { @@ -960,7 +704,6 @@ void SiPhase2DigitizerAlgorithm::induce_signal(const PSimHit& hit, xUB = topol->localPosition(mp).x(); UpperBound = 1. - calcQ((xUB-CloudCenterX)/SigmaX); } - float TotalIntegrationRange = UpperBound - LowerBound; // get strip x[ix] = TotalIntegrationRange; // save strip integral //if(SigmaX==0 || SigmaY==0) @@ -1001,14 +744,12 @@ void SiPhase2DigitizerAlgorithm::induce_signal(const PSimHit& hit, for (iy=IPixLeftDownY; iy<=IPixRightUpY; iy++) { //loope over y ind float ChargeFraction = Charge*x[ix]*y[iy]; - if( ChargeFraction > 0. ) { chan = PixelDigi::pixelToChannel( ix, iy); // Get index // Load the amplitude hit_signal[chan] += ChargeFraction; } // endif - mp = MeasurementPoint( float(ix), float(iy) ); LocalPoint lp = topol->localPosition(mp); chan = topol->channel(lp); @@ -1021,11 +762,12 @@ void SiPhase2DigitizerAlgorithm::induce_signal(const PSimHit& hit, << lp.x() << " " << lp.y() << " " // givex edge position << chan; // edge belongs to previous ? #endif - + ESum += ChargeFraction; + } // endfor iy } //endfor ix - - + + // Test conversions (THIS IS FOR TESTING ONLY) comment-out. // mp = topol->measurementPosition( i->position() ); //OK // LocalPoint lp = topol->localPosition(mp); //OK @@ -1042,10 +784,9 @@ void SiPhase2DigitizerAlgorithm::induce_signal(const PSimHit& hit, // << topol->localPosition(mp1).x() << " " //OK // << topol->localPosition(mp1).y() << " " // << topol->channel( i->position() ); //OK - - - } // loop over charge distributions - + + + } // loop over charge distributions // Fill the global map with all hit pixels from this event for ( hit_map_type::const_iterator im = hit_signal.begin(); @@ -1066,7 +807,7 @@ void SiPhase2DigitizerAlgorithm::induce_signal(const PSimHit& hit, /***********************************************************************/ // Build pixels, check threshold, add misscalibration, ... -void SiPhase2DigitizerAlgorithm::make_digis(float thePixelThresholdInE, +void SiPhase2DigitizerAlgorithm::make_digis(float theThresholdInE, uint32_t detID, std::vector& digis, std::vector& simlinks, @@ -1074,9 +815,8 @@ void SiPhase2DigitizerAlgorithm::make_digis(float thePixelThresholdInE, #ifdef TP_DEBUG LogDebug ("Pixel Digitizer") << " make digis "<<" " - << " pixel threshold FPix" << theThresholdInE_FPix << " " - << " pixel threshold BPix" << theThresholdInE_BPix << " " - << " pixel threshold BPix Layer1" << theThresholdInE_BPix_L1 << " " + << " pixel threshold Endcap" << theThresholdInE_Endcap << " " + << " pixel threshold Barrel" << theThresholdInE_Barrel << " " << " List pixels passing threshold "; #endif @@ -1091,51 +831,25 @@ void SiPhase2DigitizerAlgorithm::make_digis(float thePixelThresholdInE, for (signal_map_const_iterator i = theSignal.begin(); i != theSignal.end(); ++i) { - float signalInElectrons = (*i).second ; // signal in electrons - - // Do the miss calibration for calibration studies only. - //if(doMissCalibrate) signalInElectrons = missCalibrate(signalInElectrons) + float signalInElectrons = (*i).second.ampl() ; // signal in electrons // Do only for pixels above threshold - if( signalInElectrons >= thePixelThresholdInE) { // check threshold + if( signalInElectrons >= theThresholdInE) { // check threshold int chan = (*i).first; // channel number std::pair ip = PixelDigi::channelToPixel(chan); -// int adc=0; // ADC count as integer - - int adc=255; // D.B.:changed for CBC - -/* //D.B. - // Do the miss calibration for calibration studies only. - if(doMissCalibrate) { - int row = ip.first; // X in row - int col = ip.second; // Y is in col - adc = int(missCalibrate(detID, col, row, signalInElectrons)); //full misscalib. - } else { // Just do a simple electron->adc conversion - adc = int( signalInElectrons / theElectronPerADC ); // calibrate gain - } - adc = std::min(adc, theAdcFullScale); // Check maximum value -// Calculate layerIndex - if (theAdcFullScale!=theAdcFullScaleStack){ - unsigned int Sub_detid=DetId(detID).subdetId(); - if(Sub_detid == PixelSubdetector::PixelBarrel){ // Barrel modules - int lay = tTopo->pxbLayer(detID); - if (lay>=theFirstStackLayer) { - // Set to 1 if over the threshold - if (theAdcFullScaleStack==1) {adc=1;} - // Make it a linear fit to the full scale of the normal adc count. Start new adc from 1 not zero. - if (theAdcFullScaleStack!=1&&theAdcFullScaleStack!=theAdcFullScale) {adc = int (1 + adc * (theAdcFullScaleStack-1)/float(theAdcFullScale) );} - } - } - } // Only enter this if the Adc changes for the outer layers -*/ + + int adc = 0; + #ifdef TP_DEBUG LogDebug ("Pixel Digitizer") << (*i).first << " " << (*i).second << " " << signalInElectrons << " " << adc << ip.first << " " << ip.second ; #endif - + if (doDigitalReadout) adc = theAdcFullScale; + else adc = int( signalInElectrons / theElectronPerADC ); + // Load digis digis.emplace_back(ip.first, ip.second, adc); @@ -1174,7 +888,6 @@ void SiPhase2DigitizerAlgorithm::make_digis(float thePixelThresholdInE, // Add electronic noise to pixel charge void SiPhase2DigitizerAlgorithm::add_noise(const PixelGeomDetUnit* pixdet, float thePixelThreshold) { - #ifdef TP_DEBUG LogDebug ("Pixel Digitizer") << " enter add_noise " << theNoiseInElectrons; #endif @@ -1185,53 +898,20 @@ void SiPhase2DigitizerAlgorithm::add_noise(const PixelGeomDetUnit* pixdet, int numColumns = topol->ncolumns(); // det module number of cols&rows int numRows = topol->nrows(); - // First add noise to hit pixels - float theSmearedChargeRMS = 0.0; - + // First add Readout noise to hit cells for ( signal_map_iterator i = theSignal.begin(); i != theSignal.end(); i++) { - - if(addChargeVCALSmearing) - { - if((*i).second < 3000) - { - theSmearedChargeRMS = 543.6 - (*i).second * 0.093; - } else if((*i).second < 6000){ - theSmearedChargeRMS = 307.6 - (*i).second * 0.01; - } else{ - theSmearedChargeRMS = -432.4 +(*i).second * 0.123; - } - - // Noise from Vcal smearing: - float noise_ChargeVCALSmearing = theSmearedChargeRMS * gaussDistributionVCALNoise_->fire() ; - // Noise from full readout: - float noise = gaussDistribution_->fire() ; - - if(((*i).second + Amplitude(noise+noise_ChargeVCALSmearing, -1.)) < 0. ) { - (*i).second.set(0);} - else{ - (*i).second +=Amplitude(noise+noise_ChargeVCALSmearing, -1.); - } - - } // End if addChargeVCalSmearing - else - { - // Noise: ONLY full READOUT Noise. - // Use here the FULL readout noise, including TBM,ALT,AOH,OPT-REC. - float noise = gaussDistribution_->fire() ; - - if(((*i).second + Amplitude(noise, -1.)) < 0. ) { - (*i).second.set(0);} - else{ - (*i).second +=Amplitude(noise, -1.); - } - } // end if only Noise from full readout - + float noise = gaussDistribution_->fire() ; + if(((*i).second.ampl() + noise) < 0. ) { + (*i).second.set(0);} + else{ + (*i).second += noise; + } } if (addXtalk) { signal_map_type signalNew; for (signal_map_iterator i = theSignal.begin(); i != theSignal.end(); i++) { - float signalInElectrons = (*i).second; // signal in electrons + float signalInElectrons = (*i).second.ampl(); // signal in electrons std::pair hitChan = PixelDigi::channelToPixel((*i).first); float signalInElectrons_Xtalk = signalInElectrons * interstripCoupling; @@ -1239,28 +919,28 @@ void SiPhase2DigitizerAlgorithm::add_noise(const PixelGeomDetUnit* pixdet, if (hitChan.first != 0) { std::pair XtalkPrev = std::pair(hitChan.first-1, hitChan.second); int chanXtalkPrev = PixelDigi::pixelToChannel(XtalkPrev.first, XtalkPrev.second); - signalNew[chanXtalkPrev] += Amplitude (signalInElectrons_Xtalk, -1.); + signalNew.insert(std::pair(chanXtalkPrev, Amplitude (signalInElectrons_Xtalk, -1.0))); } if (hitChan.first < (numRows-1)) { std::pair XtalkNext = std::pair(hitChan.first+1, hitChan.second); int chanXtalkNext = PixelDigi::pixelToChannel(XtalkNext.first, XtalkNext.second); - signalNew[chanXtalkNext] += Amplitude (signalInElectrons_Xtalk, -1.); + signalNew.insert(std::pair(chanXtalkNext, Amplitude (signalInElectrons_Xtalk, -1.0))); } } for (signal_map_iterator l = signalNew.begin(); l != signalNew.end(); l++) { - std::pair lala = theSignal.insert(std::pair((*l).first,(*l).second)); - // insert returns a pair, the boolean is true if the key was not there already - // and the element added to the list, false otherwise - if (!lala.second) theSignal[lala.first->first] += lala.first->second; // if the key is not unique - } + int chan = l->first; + signal_map_iterator iter = theSignal.find(chan); + if (iter != theSignal.end()) { + theSignal[chan] += l->second.ampl(); + } else theSignal.insert(std::pair(chan, Amplitude(l->second.ampl(),-1.0))); + } #if 0 for (signal_map_iterator l = theSignal.begin(); l != theSignal.end(); l++) { std::pair hc = PixelDigi::channelToPixel((*l).first); - std::cout << hc.first << " " << hc.second << " " << (*l).second << " " << std::endl; + std::cout << (*l).first << " " << hc.first << " " << hc.second << " " << (*l).second << " " << std::endl; } #endif } - if (!addNoisyPixels) // Option to skip noise in non-hit pixels return; @@ -1279,7 +959,7 @@ void SiPhase2DigitizerAlgorithm::add_noise(const PixelGeomDetUnit* pixdet, LogDebug ("Pixel Digitizer") << " Add noisy pixels " << numRows << " " << numColumns << " " << theNoiseInElectrons << " " - << theThresholdInE_FPix << theThresholdInE_BPix <<" "<< numberOfPixels<<" " + << theThresholdInE_Endcap << " " << theThresholdInE_Barrel <<" "<< numberOfPixels<<" " << otherPixels.size() ; #endif @@ -1287,7 +967,6 @@ void SiPhase2DigitizerAlgorithm::add_noise(const PixelGeomDetUnit* pixdet, for (mapI = otherPixels.begin(); mapI!= otherPixels.end(); mapI++) { int iy = ((*mapI).first) / numRows; int ix = ((*mapI).first) - (iy*numRows); - // Keep for a while for testing. if( iy < 0 || iy > (numColumns-1) ) LogWarning ("Pixel Geometry") << " error in iy " << iy ; @@ -1314,7 +993,7 @@ void SiPhase2DigitizerAlgorithm::add_noise(const PixelGeomDetUnit* pixdet, // Simulate the readout inefficiencies. // Delete a selected number of single pixels, dcols and rocs. -void SiPhase2DigitizerAlgorithm::pixel_inefficiency(const PixelEfficiencies& eff, +void SiPhase2DigitizerAlgorithm::pixel_inefficiency(const SubdetEfficiencies& eff, const PixelGeomDetUnit* pixdet, const TrackerTopology *tTopo) { @@ -1322,203 +1001,36 @@ void SiPhase2DigitizerAlgorithm::pixel_inefficiency(const PixelEfficiencies& eff signal_map_type& theSignal = _signal[detID]; - const PixelTopology* topol=&pixdet->specificTopology(); - int numColumns = topol->ncolumns(); // det module number of cols&rows - int numRows = topol->nrows(); - // Predefined efficiencies - float pixelEfficiency = 1.0; - float columnEfficiency = 1.0; - float chipEfficiency = 1.0; + float subdetEfficiency = 1.0; // setup the chip indices conversion unsigned int Subid=DetId(detID).subdetId(); if (Subid== PixelSubdetector::PixelBarrel){// barrel layers - int layerIndex=tTopo->pxbLayer(detID); - pixelEfficiency = eff.thePixelEfficiency[layerIndex-1]; - columnEfficiency = eff.thePixelColEfficiency[layerIndex-1]; - chipEfficiency = eff.thePixelChipEfficiency[layerIndex-1]; - //std::cout <<"Using BPix columnEfficiency = "<416) LogWarning ("Pixel Geometry") <<" wrong columns in barrel "<160) LogWarning ("Pixel Geometry") <<" wrong rows in barrel "<pxbLayer(detID); + if (layerIndex-1 < eff.barrel_efficiencies.size() ) subdetEfficiency = eff.barrel_efficiencies[layerIndex-1]; + else std::cout << (layerIndex-1) << " " << eff.barrel_efficiencies.size() << std::endl; } else { // forward disks - unsigned int diskIndex=tTopo->pxfDisk(detID)+eff.FPixIndex; // Use diskIndex-1 later to stay consistent with BPix - //if (eff.FPixIndex>diskIndex-1){throw cms::Exception("Configuration") <<"MyDigitizer is using the wrong efficiency value. index = " - // <pxfDisk(detID);} - pixelEfficiency = eff.thePixelEfficiency[diskIndex-1]; - columnEfficiency = eff.thePixelColEfficiency[diskIndex-1]; - chipEfficiency = eff.thePixelChipEfficiency[diskIndex-1]; - //std::cout <<"Using FPix columnEfficiency = "<260 || numRows>160) { - if(numColumns>260) LogWarning ("Pixel Geometry") <<" wrong columns in endcaps "<160) LogWarning ("Pixel Geometry") <<" wrong rows in endcaps "<pxfDisk(detID) - tTopo->pxfSide(detID); + if (diskIndex-1 < eff.endcap_efficiencies.size()) subdetEfficiency = eff.endcap_efficiencies[diskIndex-1]; + else std::cout << diskIndex-1 << " " << eff.barrel_efficiencies.size() << std::endl; } // if barrel/forward #ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " enter pixel_inefficiency " << pixelEfficiency << " " - << columnEfficiency << " " << chipEfficiency; + LogDebug ("Pixel Digitizer") << " enter pixel_inefficiency " << subdetEfficiency; #endif - // Initilize the index converter - //PixelIndices indexConverter(numColumns,numRows); - std::auto_ptr pIndexConverter(new PixelIndices(numColumns,numRows)); - - int chipIndex = 0; - int rowROC = 0; - int colROC = 0; - std::map >chips, columns; - std::map >::iterator iter; - - // Find out the number of columns and rocs hits - // Loop over hit pixels, amplitude in electrons, channel = coded row,col - for (signal_map_const_iterator i = theSignal.begin(); i != theSignal.end(); ++i) { - - int chan = i->first; - std::pair ip = PixelDigi::channelToPixel(chan); - int row = ip.first; // X in row - int col = ip.second; // Y is in col - //transform to ROC index coordinates - pIndexConverter->transformToROC(col,row,chipIndex,colROC,rowROC); - int dColInChip = pIndexConverter->DColumn(colROC); // get ROC dcol from ROC col - //dcol in mod - int dColInDet = pIndexConverter->DColumnInModule(dColInChip,chipIndex); - - chips[chipIndex]++; - columns[dColInDet]++; - } - - // Delete some ROC hits. - for ( iter = chips.begin(); iter != chips.end() ; iter++ ) { - //float rand = RandFlat::shoot(); - float rand = flatDistribution_->fire(); - if( rand > chipEfficiency ) chips[iter->first]=0; - } - - // Delete some Dcol hits. - for ( iter = columns.begin(); iter != columns.end() ; iter++ ) { - //float rand = RandFlat::shoot(); - float rand = flatDistribution_->fire(); - if( rand > columnEfficiency ) columns[iter->first]=0; - } - // Now loop again over pixels to kill some of them. - // Loop over hit pixels, amplitude in electrons, channel = coded row,col + // Loop over hits, amplitude in electrons, channel = coded row,col for(signal_map_iterator i = theSignal.begin();i != theSignal.end(); ++i) { - - // int chan = i->first; - std::pair ip = PixelDigi::channelToPixel(i->first);//get pixel pos - int row = ip.first; // X in row - int col = ip.second; // Y is in col - //transform to ROC index coordinates - pIndexConverter->transformToROC(col,row,chipIndex,colROC,rowROC); - int dColInChip = pIndexConverter->DColumn(colROC); //get ROC dcol from ROC col - //dcol in mod - int dColInDet = pIndexConverter->DColumnInModule(dColInChip,chipIndex); - - - //float rand = RandFlat::shoot(); float rand = flatDistribution_->fire(); - if( chips[chipIndex]==0 || columns[dColInDet]==0 - || rand>pixelEfficiency ) { - // make pixel amplitude =0, pixel will be lost at clusterization + if( rand>subdetEfficiency ) { + // make amplitude =0 i->second.set(0.); // reset amplitude, } // end if - - } // end pixel loop -} // end pixel_indefficiency - + } +} //*********************************************************************** - -// Fluctuate the gain and offset for the amplitude calibration -// Use gaussian smearing. -//float SiPhase2DigitizerAlgorithm::missCalibrate(const float amp) const { - //float gain = RandGaussQ::shoot(1.,theGainSmearing); - //float offset = RandGaussQ::shoot(0.,theOffsetSmearing); - //float newAmp = amp * gain + offset; - // More complex misscalibration -float SiPhase2DigitizerAlgorithm::missCalibrate(uint32_t detID, int col,int row, - const float signalInElectrons) const { - // Central values - //const float p0=0.00352, p1=0.868, p2=112., p3=113.; // pix(0,0,0) - // const float p0=0.00382, p1=0.886, p2=112.7, p3=113.0; // average roc=0 - //const float p0=0.00492, p1=1.998, p2=90.6, p3=134.1; // average roc=6 - // Smeared (rms) - //const float s0=0.00020, s1=0.051, s2=5.4, s3=4.4; // average roc=0 - //const float s0=0.00015, s1=0.043, s2=3.2, s3=3.1; // col average roc=0 - - // Make 2 sets of parameters for Fpix and BPIx: - - float p0=0.0; - float p1=0.0; - float p2=0.0; - float p3=0.0; - - unsigned int Sub_detid=DetId(detID).subdetId(); - - if(Sub_detid == PixelSubdetector::PixelBarrel){// barrel layers - p0 = BPix_p0; - p1 = BPix_p1; - p2 = BPix_p2; - p3 = BPix_p3; - } else {// forward disks - p0 = FPix_p0; - p1 = FPix_p1; - p2 = FPix_p2; - p3 = FPix_p3; - } - - // const float electronsPerVCAL = 65.5; // our present VCAL calibration (feb 2009) - // const float electronsPerVCAL_Offset = -414.0; // our present VCAL calibration (feb 2009) - float newAmp = 0.; //Modified signal - - // Convert electrons to VCAL units - float signal = (signalInElectrons-electronsPerVCAL_Offset)/electronsPerVCAL; - - // Simulate the analog response with fixed parametrization - newAmp = p3 + p2 * tanh(p0*signal - p1); - - - // Use the pixel-by-pixel calibrations - //transform to ROC index coordinates - //int chipIndex=0, colROC=0, rowROC=0; - //std::auto_ptr pIndexConverter(new PixelIndices(numColumns,numRows)); - //pIndexConverter->transformToROC(col,row,chipIndex,colROC,rowROC); - - // Use calibration from a file - //int chanROC = PixelIndices::pixelToChannelROC(rowROC,colROC); // use ROC coordinates - //float pp0=0, pp1=0,pp2=0,pp3=0; - //map >::const_iterator it=calmap.find(chanROC); - //CalParameters y = (*it).second; - //pp0 = y.p0; - //pp1 = y.p1; - //pp2 = y.p2; - //pp3 = y.p3; - - // - // Use random smearing - // Randomize the pixel response - //float pp0 = RandGaussQ::shoot(p0,s0); - //float pp1 = RandGaussQ::shoot(p1,s1); - //float pp2 = RandGaussQ::shoot(p2,s2); - //float pp3 = RandGaussQ::shoot(p3,s3); - - //newAmp = pp3 + pp2 * tanh(pp0*signal - pp1); // Final signal - - //cout<<" misscalibrate "<surface().position(),pixdet->surface().rotation()); LocalVector Bfield=detFrame.toLocal(bfield); - - float alpha2_FPix; - float alpha2_BPix; + float alpha2_Endcap; + float alpha2_Barrel; float alpha2; //float dir_x = -tanLorentzAnglePerTesla * Bfield.y(); @@ -1557,24 +1068,24 @@ LocalVector SiPhase2DigitizerAlgorithm::DriftDirection(const PixelGeomDetUnit* p if(!use_LorentzAngle_DB_){ if( alpha2Order) { - alpha2_FPix = tanLorentzAnglePerTesla_FPix*tanLorentzAnglePerTesla_FPix; - alpha2_BPix = tanLorentzAnglePerTesla_BPix*tanLorentzAnglePerTesla_BPix; + alpha2_Endcap = tanLorentzAnglePerTesla_Endcap*tanLorentzAnglePerTesla_Endcap; + alpha2_Barrel = tanLorentzAnglePerTesla_Barrel*tanLorentzAnglePerTesla_Barrel; }else { - alpha2_FPix = 0.0; - alpha2_BPix = 0.0; + alpha2_Endcap = 0.0; + alpha2_Barrel = 0.0; } if(Sub_detid == PixelSubdetector::PixelBarrel){// barrel layers - dir_x = -( tanLorentzAnglePerTesla_BPix * Bfield.y() + alpha2_BPix* Bfield.z()* Bfield.x() ); - dir_y = +( tanLorentzAnglePerTesla_BPix * Bfield.x() - alpha2_BPix* Bfield.z()* Bfield.y() ); - dir_z = -(1 + alpha2_BPix* Bfield.z()*Bfield.z() ); - scale = (1 + alpha2_BPix* Bfield.z()*Bfield.z() ); + dir_x = -( tanLorentzAnglePerTesla_Barrel * Bfield.y() + alpha2_Barrel* Bfield.z()* Bfield.x() ); + dir_y = +( tanLorentzAnglePerTesla_Barrel * Bfield.x() - alpha2_Barrel* Bfield.z()* Bfield.y() ); + dir_z = -(1 + alpha2_Barrel* Bfield.z()*Bfield.z() ); + scale = (1 + alpha2_Barrel* Bfield.z()*Bfield.z() ); } else {// forward disks - dir_x = -( tanLorentzAnglePerTesla_FPix * Bfield.y() + alpha2_FPix* Bfield.z()* Bfield.x() ); - dir_y = +( tanLorentzAnglePerTesla_FPix * Bfield.x() - alpha2_FPix* Bfield.z()* Bfield.y() ); - dir_z = -(1 + alpha2_FPix* Bfield.z()*Bfield.z() ); - scale = (1 + alpha2_FPix* Bfield.z()*Bfield.z() ); + dir_x = -( tanLorentzAnglePerTesla_Endcap * Bfield.y() + alpha2_Endcap* Bfield.z()* Bfield.x() ); + dir_y = +( tanLorentzAnglePerTesla_Endcap * Bfield.x() - alpha2_Endcap* Bfield.z()* Bfield.y() ); + dir_z = -(1 + alpha2_Endcap* Bfield.z()*Bfield.z() ); + scale = (1 + alpha2_Endcap* Bfield.z()*Bfield.z() ); } } // end: Read LA from cfg file. diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h index bf5747407ae64..aec26f080b55a 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h +++ b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h @@ -113,9 +113,10 @@ class SiPhase2DigitizerAlgorithm { void operator+=( const Amplitude& other) { _amp += other._amp; + //in case of contribution of noise to the digi //the MC information are removed - if (other._frac[0]>-0.5){ + if (other._frac.size() > 0 && other._frac[0]>-0.5){ if (other._hitInfo) { std::vector& otherTrackIds = other._hitInfo->trackIds_; if(_hitInfo) { @@ -147,15 +148,6 @@ class SiPhase2DigitizerAlgorithm { std::shared_ptr _hitInfo; }; // end class Amplitude - // Define a class to hold the calibration parameters per pixel - // Internal - class CalParameters { - public: - float p0; - float p1; - float p2; - float p3; - }; // // Define a class for 3D ionization points and energy // @@ -222,17 +214,15 @@ class SiPhase2DigitizerAlgorithm { }; // - // PixelEfficiencies struct + // SubdetEfficiencies struct // /** * Internal use only. */ - struct PixelEfficiencies { - PixelEfficiencies(const edm::ParameterSet& conf, bool AddPixelInefficiency, int NumberOfBarrelLayers, int NumberOfEndcapDisks); - float thePixelEfficiency[20]; // Single pixel effciency - float thePixelColEfficiency[20]; // Column effciency - float thePixelChipEfficiency[20]; // ROC efficiency - unsigned int FPixIndex; // The Efficiency index for FPix Disks + struct SubdetEfficiencies { + SubdetEfficiencies(const edm::ParameterSet& conf); + std::vector barrel_efficiencies; + std::vector endcap_efficiencies; }; private: @@ -273,48 +263,28 @@ class SiPhase2DigitizerAlgorithm { //-- induce_signal const float ClusterWidth; // Gaussian charge cutoff width in sigma units - //-- Allow for upgrades - const int NumberOfBarrelLayers; // Default = 3 - const int NumberOfEndcapDisks; // Default = 2 - //-- make_digis + const bool doDigitalReadout; // Flag to decide analog or digital readout const float theElectronPerADC; // Gain, number of electrons per adc count. const int theAdcFullScale; // Saturation count, 255=8bit. - const int theAdcFullScaleStack; // Saturation count for stack layers, 1=1bit. - const int theFirstStackLayer; // The first BPix layer to use theAdcFullScaleStack. const float theNoiseInElectrons; // Noise (RMS) in units of electrons. const float theReadoutNoise; // Noise of the readount chain in elec, - //inludes DCOL-Amp,TBM-Amp, Alt, AOH,OptRec. + //inludes DCOL-Amp,TBM-Amp, Alt, AOH,OptRec. - const float theThresholdInE_FPix; // Pixel threshold in electrons FPix. - const float theThresholdInE_BPix; // Pixel threshold in electrons BPix. - const float theThresholdInE_BPix_L1; // In case the BPix layer1 gets a different threshold - const double theThresholdSmearing_FPix; - const double theThresholdSmearing_BPix; - const double theThresholdSmearing_BPix_L1; + const float theThresholdInE_Endcap; // threshold in electrons Endcap. + const float theThresholdInE_Barrel; // threshold in electrons Barrel. - const double electronsPerVCAL; // for electrons - VCAL conversion - const double electronsPerVCAL_Offset; // in misscalibrate() + const double theThresholdSmearing_Endcap; + const double theThresholdSmearing_Barrel; const float theTofLowerCut; // Cut on the particle TOF const float theTofUpperCut; // Cut on the particle TOF - const float tanLorentzAnglePerTesla_FPix; //FPix Lorentz angle tangent per Tesla - const float tanLorentzAnglePerTesla_BPix; //BPix Lorentz angle tangent per Tesla - - const float FPix_p0; - const float FPix_p1; - const float FPix_p2; - const float FPix_p3; - const float BPix_p0; - const float BPix_p1; - const float BPix_p2; - const float BPix_p3; - + const float tanLorentzAnglePerTesla_Endcap; //FPix Lorentz angle tangent per Tesla + const float tanLorentzAnglePerTesla_Barrel; //BPix Lorentz angle tangent per Tesla //-- add_noise const bool addNoise; - const bool addChargeVCALSmearing; const bool addNoisyPixels; const bool fluctuateCharge; //-- pixel efficiency @@ -322,10 +292,6 @@ class SiPhase2DigitizerAlgorithm { const bool addThresholdSmearing; - //-- calibration smearing - const bool doMissCalibrate; // Switch on the calibration smearing - const float theGainSmearing; // The sigma of the gain fluctuation (around 1) - const float theOffsetSmearing; // The sigma of the offset fluct. (around 0) // pseudoRadDamage const double pseudoRadDamage; // Decrease the amount off freed charge that reaches the collector @@ -342,13 +308,8 @@ class SiPhase2DigitizerAlgorithm { const std::unique_ptr fluctuate; // make a pointer const std::unique_ptr theNoiser; - // To store calibration constants - const std::map > calmap; - - //-- additional member functions // Private methods - std::map > initCal() const; void primary_ionization( const PSimHit& hit, std::vector& ionization_points) const; void drift(const PSimHit& hit, const PixelGeomDetUnit *pixdet, @@ -368,7 +329,7 @@ class SiPhase2DigitizerAlgorithm { std::vector& digis, std::vector& simlinks, const TrackerTopology *tTopo) const; - void pixel_inefficiency(const PixelEfficiencies& eff, + void pixel_inefficiency(const SubdetEfficiencies& eff, const PixelGeomDetUnit* pixdet, const TrackerTopology *tTopo); @@ -376,7 +337,6 @@ class SiPhase2DigitizerAlgorithm { // access to the gain calibration payloads in the db. Only gets initialized if check_dead_pixels_ is set to true. const std::unique_ptr theSiPixelGainCalibrationService_; - float missCalibrate(uint32_t detID, int col, int row, float amp) const; LocalVector DriftDirection(const PixelGeomDetUnit* pixdet, const GlobalVector& bfield, const DetId& detId) const; @@ -384,17 +344,15 @@ class SiPhase2DigitizerAlgorithm { void module_killing_conf(uint32_t detID); // remove dead modules using the list in the configuration file PixelDigi_cfi.py void module_killing_DB(uint32_t detID); // remove dead modules uisng the list in the DB - const PixelEfficiencies pixelEfficiencies_; + const SubdetEfficiencies subdetEfficiencies_; // For random numbers const std::unique_ptr flatDistribution_; const std::unique_ptr gaussDistribution_; - const std::unique_ptr gaussDistributionVCALNoise_; // Threshold gaussian smearing: - const std::unique_ptr smearedThreshold_FPix_; - const std::unique_ptr smearedThreshold_BPix_; - const std::unique_ptr smearedThreshold_BPix_L1_; + const std::unique_ptr smearedThreshold_Endcap_; + const std::unique_ptr smearedThreshold_Barrel_; double calcQ(float x) const { // need erf(x/sqrt2) diff --git a/SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py b/SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py index e706479e62536..d3adf47e214b5 100644 --- a/SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py +++ b/SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py @@ -3,6 +3,7 @@ phase2PixelDigitizer = cms.PSet( accumulatorType = cms.string("SiPhase2Digitizer"), hitsProducer = cms.string('g4SimHits'), + GeometryType = cms.string('idealForDigi'), makeDigiSimLinks = cms.untracked.bool(True), #D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm]) ReadoutNoiseInElec = cms.double(1000.0),#D.B.:Fill readout noise, including all readout chain, relevant for smearing @@ -12,70 +13,37 @@ 'TrackerHitsPixelBarrelHighTof', 'TrackerHitsPixelEndcapLowTof', 'TrackerHitsPixelEndcapHighTof'), - OffsetSmearing = cms.double(0.0), - ThresholdInElectrons_FPix = cms.double(4759.8), #D.B.: this should correspond to a threshold of 530mV - ThresholdInElectrons_BPix = cms.double(4759.8), - ThresholdInElectrons_BPix_L1 = cms.double(4759.8), + ThresholdInElectrons_Barrel = cms.double(5800.0), #D.B.: this should correspond to a threshold of 530mV + ThresholdInElectrons_Endcap = cms.double(5800.0), AddThresholdSmearing = cms.bool(True), - ThresholdSmearing_FPix = cms.double(204.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 210.0) - ThresholdSmearing_BPix = cms.double(204.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) - ThresholdSmearing_BPix_L1 = cms.double(204.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) -# NoiseInElectrons = cms.double(1000.0), #D.B.:this was set as the pixel cell noise, relevant for generating noisy pixels (was 175.0). But is should be the same as the total readout noise, ReadoutNoiseInElec - NoiseInElectrons = cms.double(0.1), #D.B.:this was set as the pixel cell noise, relevant for generating noisy pixels (was 175.0). But is should be the same as the total readout noise, ReadoutNoiseInElec NB: does not work if ==0! - MissCalibrate = cms.bool(False), - FPix_SignalResponse_p0 = cms.double(0.0043), #D.B.:for pixel calibration only (not for PS or 2S) - FPix_SignalResponse_p1 = cms.double(1.31), #D.B.:for pixel calibration only (not for PS or 2S) - FPix_SignalResponse_p2 = cms.double(93.6), #D.B.:for pixel calibration only (not for PS or 2S) - FPix_SignalResponse_p3 = cms.double(134.6), #D.B.:for pixel calibration only (not for PS or 2S) - BPix_SignalResponse_p0 = cms.double(0.0035), #D.B.:for pixel calibration only (not for PS or 2S) - BPix_SignalResponse_p1 = cms.double(1.23), #D.B.:for pixel calibration only (not for PS or 2S) - BPix_SignalResponse_p2 = cms.double(97.4), #D.B.:for pixel calibration only (not for PS or 2S) - BPix_SignalResponse_p3 = cms.double(126.5), #D.B.:for pixel calibration only (not for PS or 2S) - ElectronsPerVcal = cms.double(65.5), #D.B.:used for misscalibration - ElectronsPerVcal_Offset = cms.double(-414.0), #D.B.:used for misscalibration + ThresholdSmearing_Barrel = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 210.0) + ThresholdSmearing_Endcap = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) + NoiseInElectrons = cms.double(300), # 30% of the readout noise (should be changed in future) + DigitalReadout = cms.bool(True), # Flag to decide analog or digital readout ElectronPerAdc = cms.double(135.0), #D.B.:used for misscalibration TofUpperCut = cms.double(12.5), AdcFullScale = cms.int32(255), - AdcFullScaleStack = cms.int32(255), - FirstStackLayer = cms.int32(5), #D.B.:not used TofLowerCut = cms.double(-12.5), - TanLorentzAnglePerTesla_FPix = cms.double(0.106), #D.B.:this I have not checked yet - TanLorentzAnglePerTesla_BPix = cms.double(0.106), #D.B.:this I have not checked yet AddNoisyPixels = cms.bool(True), Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described - AddPixelInefficiency = cms.int32(0), # deprecated, use next option - AddPixelInefficiencyFromPython = cms.bool(True), AddNoise = cms.bool(True), -# AddXTalk = cms.bool(True), AddXTalk = cms.bool(True), #D.B. - InterstripCoupling = cms.double(0.08), #D.B. + InterstripCoupling = cms.double(0.05), #D.B. SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas) -## Dist300 = cms.double(0.03), #D.B.: use moduleThickness instead - ChargeVCALSmearing = cms.bool(False), #D.B.:changed from true, this smearing uses a calibration for the pixels, use gaussDistribution_ instead - GainSmearing = cms.double(0.0), #D.B.:is not used in phase2PixelDigitizer - GeometryType = cms.string('idealForDigi'), - useDB = cms.bool(True), - LorentzAngle_DB = cms.bool(True), - DeadModules_DB = cms.bool(True), - killModules = cms.bool(True), - NumPixelBarrel = cms.int32(3), - NumPixelEndcap = cms.int32(2), - thePixelColEfficiency_BPix1 = cms.double(0.999), # Only used when AddPixelInefficiency = true - thePixelColEfficiency_BPix2 = cms.double(0.999), - thePixelColEfficiency_BPix3 = cms.double(0.999), - thePixelColEfficiency_FPix1 = cms.double(0.999), - thePixelColEfficiency_FPix2 = cms.double(0.999), - thePixelEfficiency_BPix1 = cms.double(0.999), # Only used when AddPixelInefficiency = true - thePixelEfficiency_BPix2 = cms.double(0.999), - thePixelEfficiency_BPix3 = cms.double(0.999), - thePixelEfficiency_FPix1 = cms.double(0.999), - thePixelEfficiency_FPix2 = cms.double(0.999), - thePixelChipEfficiency_BPix1 = cms.double(0.999), # Only used when AddPixelInefficiency = true - thePixelChipEfficiency_BPix2 = cms.double(0.999), - thePixelChipEfficiency_BPix3 = cms.double(0.999), - thePixelChipEfficiency_FPix1 = cms.double(0.999), - thePixelChipEfficiency_FPix2 = cms.double(0.999), + + AddInefficiency = cms.bool(False), + Inefficiency_DB = cms.bool(False), + + LorentzAngle_DB = cms.bool(False), + TanLorentzAnglePerTesla_Endcap = cms.double(0.106), #D.B.:this I have not checked yet + TanLorentzAnglePerTesla_Barrel = cms.double(0.106), #D.B.:this I have not checked yet + + KillModules = cms.bool(False), + DeadModules_DB = cms.bool(False), + + EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ), + EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on DeadModules = cms.VPSet() ) diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc index 88f902828b2e6..00e52560d622e 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc @@ -1,5 +1,4 @@ - - // -*- C++ -*- +// -*- C++ -*- // // Package: DigiValidation // Class: DigiValidation @@ -41,6 +40,10 @@ #include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" #include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetType.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerDetUnit.h" +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" + #include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" #include "DataFormats/SiPixelDetId/interface/PXBDetId.h" #include "DataFormats/SiPixelDetId/interface/PXFDetId.h" @@ -55,6 +58,7 @@ #include "DataFormats/SiPixelDigi/interface/PixelDigiCollection.h" #include "DataFormats/DetId/interface/DetId.h" #include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "DataFormats/Math/interface/deltaPhi.h" // For the big pixel recongnition #include "Geometry/TrackerGeometryBuilder/interface/RectangularPixelTopology.h" @@ -127,6 +131,7 @@ class DigiValidation : public edm::EDAnalyzer { TH1F* simTrackPtPEC_; TH1F* simTrackEtaP_; TH1F* simTrackPhiP_; + TH1F* simTrackVxP_; TH1F* simTrackPtS_; TH1F* simTrackPtSBar_; @@ -196,6 +201,19 @@ class DigiValidation : public edm::EDAnalyzer { TH1F* matchedSimTrackEtaS_; TH1F* matchedSimTrackPhiS_; + TH1F* PositionOfCluster; + TH1F* PositionOfClusterP; + TH1F* PositionOfClusterS; + + TH1F* DeltaPhi; + TProfile* ClusterWidthDeltaPhiP; + + TH1F* ELossSimHit; + TH1F* PathLengthSimHit; + TH1F* EntryZSimHit; + TH1F* ExitZSimHit; + TH2F* ExitZVsEntryZSimHit; + int totNDigis; int totNClusters; @@ -207,6 +225,7 @@ class DigiValidation : public edm::EDAnalyzer { int totMatchedSimHitsP; int totMatchedSimHitsS; + std::set simTkIndx; }; @@ -214,9 +233,11 @@ class DigiValidation : public edm::EDAnalyzer { struct MyCluster { float charge; int width; + int position; bool trkType; float trkPt; float trkEta; + float delPhi; std::vector strip_charges; }; @@ -238,8 +259,9 @@ class DigiValidation : public edm::EDAnalyzer { int isPrimary(const SimTrack& simTrk, edm::Handle& simHits); int isPrimary(const SimTrack& simTrk, const PSimHit& simHit); void fillMatchedSimTrackHistos(DigiHistos& digiHistos, const SimTrack& simTk, int ptype, unsigned int layer); + float getELoss(unsigned int trkId, unsigned int rawId, edm::Handle& simHits, Local3DPoint& entry, Local3DPoint& exit); + unsigned int getStackId(const StackedTrackerGeometry* stkgeom, DetId& detid); }; - // // constructors and destructor // @@ -291,6 +313,11 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS iSetup.get().get( geomHandle ); const TrackerGeometry* tkGeom = &(*geomHandle); + // Stacked Tracker Geometry + // edm::ESHandle stackedGeometryHandle; + // iSetup.get().get(stackedGeometryHandle); + // const StackedTrackerGeometry* theStackedGeometry = stackedGeometryHandle.product(); + // Get PSimHits edm::Handle simHits; iEvent.getByLabel("g4SimHits","TrackerHitsPixelBarrelLowTof" ,simHits); @@ -301,7 +328,12 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS // SimVertex edm::Handle simVertices; iEvent.getByLabel("g4SimHits", simVertices); - + + + // for (edm::SimVertexContainer::const_iterator simVtxItr = simVertices->begin(); + // simVtxItr != simVertices->end(); simVtxItr++) { + // std::cout << " Vertex Index " << simVtxItr->vertexId() << " Parent index " << simVtxItr->parentIndex() << " Position : X " << simVtxItr->position().x() << " Y " << simVtxItr->position().y() << " Z " << simVtxItr->position().z() << " r " << sqrt(simVtxItr->position().x()*simVtxItr->position().x() + simVtxItr->position().y()*simVtxItr->position().y()) << std::endl; + //} initializeVariables(); std::vector processTypes; @@ -309,16 +341,27 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS int nTracks = 0; for (edm::SimTrackContainer::const_iterator simTrkItr = simTracks->begin(); simTrkItr != simTracks->end(); ++simTrkItr) { - int type = isPrimary((*simTrkItr), simHits); + int vtxIndex = simTrkItr->vertIndex(); + int vtxParent = -1; + if (vtxIndex > 0) { + SimVertex vtx = (*simVertices)[vtxIndex]; + if (!vtx.noParent()) { + int trkId = vtx.parentIndex(); + vtxParent = (*simTracks)[matchedSimTrack(simTracks, trkId)].vertIndex(); + } + } + int type = -1; + if (vtxIndex == 0 || vtxParent == 0) type = isPrimary((*simTrkItr), simHits); + processTypes.push_back(type); + // std::cout << " SimTrack Id " << simTrkItr->trackId() << " HEP PDT Id " << simTrkItr->type() << " Pt " << simTrkItr->momentum().pt() << " Vertex Index " << simTrkItr->vertIndex() << " Parent Vertex Index " << vtxParent << " Process Type " << type << std::endl; + // remove neutrinos if (simTrkItr->charge() == 0) continue; nTracks++; float simTk_pt = simTrkItr->momentum().pt(); float simTk_eta = simTrkItr->momentum().eta(); - float simTk_phi = simTrkItr->momentum().eta(); - - + float simTk_phi = simTrkItr->momentum().phi(); simTrackPt_->Fill(simTk_pt); simTrackEta_->Fill(simTk_eta); simTrackPhi_->Fill(simTk_phi); @@ -353,6 +396,7 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS } const GeomDetUnit* geomDetUnit = tkGeom->idToDetUnit(detId); // const PixelGeomDetUnit* pixdet = (PixelGeomDetUnit*) geomDetUnit; + // std::cout << " Layer " << layer << " Thickness " << pixdet->specificSurface().bounds().thickness() << " Pitch " << pixdet->specificTopology().pitch().first <::const_iterator di; int col_last = -1; int row_last = -1; @@ -375,65 +419,89 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS unsigned int simTkId = getSimTrackId(pixelSimLinks, detId, channel); MeasurementPoint mp(row+0.5, col+0.5 ); + int iSimTrk = matchedSimTrack(simTracks, simTkId); + float dPhi = 9999.9; + float xpos = 9999.9; + float ypos = 9999.9; if (geomDetUnit) { GlobalPoint pdPos = geomDetUnit->surface().toGlobal( geomDetUnit->topology().localPosition( mp ) ) ; - iPos->second.YposVsXpos->Fill(pdPos.y(), pdPos.x()); + xpos = pdPos.x(); + ypos = pdPos.y(); + iPos->second.YposVsXpos->Fill(ypos, xpos); iPos->second.RVsZpos->Fill(pdPos.z(), pdPos.perp()); + dPhi = reco::deltaPhi((*simTracks)[iSimTrk].momentum().phi(), geomDetUnit->position().phi()); } - int iSimTrk = matchedSimTrack(simTracks, simTkId); - - + iPos->second.DeltaPhi->Fill(dPhi); int primaryTrk = -1; if (iSimTrk != -1) { primaryTrk = processTypes[iSimTrk]; iPos->second.simTkIndx.insert(iSimTrk); } iPos->second.DigiCharge->Fill(adc); - if (primaryTrk == 1) { - iPos->second.DigiChargeP->Fill(adc); - - nDigiP++; + iPos->second.DigiChargeP->Fill(adc); + Local3DPoint entry; + Local3DPoint exit; + float path_length; + float eloss = getELoss(simTkId, rawid, simHits, entry, exit); + iPos->second.ELossSimHit->Fill(eloss*1000000); + path_length = (exit-entry).mag(); + iPos->second.PathLengthSimHit->Fill(path_length*10000); + iPos->second.EntryZSimHit->Fill(entry.z()*10000); + iPos->second.ExitZSimHit->Fill(exit.z()*10000); + iPos->second.ExitZVsEntryZSimHit->Fill(entry.z()*10000, exit.z()*10000); + // std::cout << layer << " rawid " << rawid << " YPosition " << ypos << " Radius " << sqrt(xpos*xpos + ypos*ypos) << " Delta Phi " << dPhi << " Stack Id " << getStackId(theStackedGeometry, detId) << " Eloss " << eloss*1000000 << " Path Length " << path_length*10000 << " Entry Z " << entry.z() << " Exit Z " << exit.z() << std::endl; + nDigiP++; } else if (primaryTrk == 0){ iPos->second.DigiChargeS->Fill(adc); nDigiS++; } if (row_last == -1 ) { - cluster.charge = adc; - cluster.width = 1; - cluster.trkType = primaryTrk; + cluster.charge = adc; + cluster.width = 1; + cluster.position = row+1; + cluster.trkType = primaryTrk; cluster.trkPt = (*simTracks)[iSimTrk].momentum().pt(); cluster.trkEta = (*simTracks)[iSimTrk].momentum().eta(); - cluster.strip_charges.clear(); - cluster.strip_charges.push_back(adc); + cluster.delPhi = dPhi; + cluster.strip_charges.clear(); + cluster.strip_charges.push_back(adc); } else { - + if (abs(row - row_last) == 1 && col == col_last) { cluster.charge += adc; cluster.width++; + cluster.position += row+1; cluster.strip_charges.push_back(adc); } else { + cluster.position /= cluster.width; cluster_vec.push_back(cluster); cluster.charge = adc; cluster.width = 1; + cluster.position = row+1; cluster.trkType = primaryTrk; - cluster.trkPt = (*simTracks)[iSimTrk].momentum().pt(); + cluster.trkPt = (*simTracks)[iSimTrk].momentum().pt(); cluster.trkEta = (*simTracks)[iSimTrk].momentum().eta(); + cluster.delPhi = dPhi; cluster.strip_charges.clear(); cluster.strip_charges.push_back(adc); } } if (PRINT) std::cout << ">>> PType " << primaryTrk - << " SimTkPt " << (*simTracks)[iSimTrk].momentum().pt() - << " column " << col - << " row " << row - << " column_last " << col_last - << " row_last " << row_last - << " nDigi " << nDigiS - << " " << nDigiP - << " nCluster " << cluster_vec.size() - << " Cluster Charge " << cluster.charge - << " Cluster Width " << cluster.width << std::endl; + << " SimTk : Id " << simTkId + << " Index " << iSimTrk + << " Pt " << (*simTracks)[iSimTrk].momentum().pt() + << " Detector : Id "<< DSViter->id + << " column " << col + << " row " << row + << " column_last " << col_last + << " row_last " << row_last + << " nDigi " << nDigiS + << " " << nDigiP + << " nCluster " << cluster_vec.size() + << " Cluster Charge " << cluster.charge + << " Cluster Width " << cluster.width + << " Cluster Position " << cluster.position <second.NumberOfDigisS->Fill(nDigiS); iPos->second.NumberOfDigis->Fill(nDigiP+nDigiS); iPos->second.totNDigis += nDigiP + nDigiS; - + int nClusterP = 0; int nClusterS = 0; - + for (vector::iterator ic = cluster_vec.begin(); ic != cluster_vec.end(); ++ic) { float cl_charge = ic->charge; int cl_width = ic->width; int cl_type = ic->trkType; float trk_pt = ic->trkPt; float trk_eta = ic->trkEta; + int pos = ic->position; std::vector str_charges = ic->strip_charges; unsigned int max_pos = getMaxPosition(str_charges); if (max_pos != 999) { @@ -465,17 +534,21 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS } iPos->second.ClusterCharge->Fill(cl_charge); iPos->second.ClusterWidth->Fill(cl_width); + iPos->second.PositionOfCluster->Fill(pos); iPos->second.ClusterWidthVsSimTrkPt->Fill(trk_pt, cl_width); iPos->second.ClusterWidthVsSimTrkEta->Fill(trk_eta, cl_width); if (cl_type == 1) { iPos->second.ClusterChargeP->Fill(cl_charge); - iPos->second.ClusterWidthP->Fill(cl_width); + iPos->second.ClusterWidthP->Fill(cl_width); + iPos->second.PositionOfClusterP->Fill(pos); iPos->second.ClusterWidthVsSimTrkPtP->Fill(trk_pt, cl_width); iPos->second.ClusterWidthVsSimTrkEtaP->Fill(trk_eta, cl_width); + iPos->second.ClusterWidthDeltaPhiP->Fill(ic->delPhi, cl_width); nClusterP++; } else if (cl_type == 0) { iPos->second.ClusterChargeS->Fill(cl_charge); iPos->second.ClusterWidthS->Fill(cl_width); + iPos->second.PositionOfClusterS->Fill(pos); iPos->second.ClusterWidthVsSimTrkPtS->Fill(trk_pt, cl_width); iPos->second.ClusterWidthVsSimTrkEtaS->Fill(trk_eta, cl_width); nClusterS++; @@ -488,7 +561,7 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS } // Fill Layer Level Histograms for (std::map::iterator iPos = layerHistoMap.begin(); - iPos != layerHistoMap.end(); iPos++) { + iPos != layerHistoMap.end(); iPos++) { DigiHistos local_histos = iPos->second; local_histos.TotalNumberOfClusters->Fill(local_histos.totNClusters); local_histos.TotalNumberOfDigis->Fill(local_histos.totNDigis); @@ -496,7 +569,7 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS local_histos.NumberOfMatchedSimHits->Fill(local_histos.totMatchedSimHits); local_histos.NumberOfMatchedSimHitsP->Fill(local_histos.totMatchedSimHitsP); local_histos.NumberOfMatchedSimHitsS->Fill(local_histos.totMatchedSimHitsS); - + if (local_histos.totSimHits) { float eff; eff = local_histos.totMatchedSimHits*1.0/local_histos.totSimHits; @@ -699,6 +772,44 @@ void DigiValidation::createLayerHistograms(unsigned int ival) { htit18 << "MatchedSimTrackPhiS" << tag.c_str() << id; local_histos.matchedSimTrackPhiS_ = td.make(htit18.str().c_str(), htit18.str().c_str(), 160, -3.2, 3.2); + std::ostringstream htit19; + htit19 << "PositionOfCluster" << tag.c_str() << id; + local_histos.PositionOfCluster = td.make(htit19.str().c_str(), htit19.str().c_str(), 1051, -0.5, 1050.5); + htit19.str(""); + htit19 << "PositionOfClusterP" << tag.c_str() << id; + local_histos.PositionOfClusterP = td.make(htit19.str().c_str(), htit19.str().c_str(), 1051, -0.5, 1050.5); + htit19.str(""); + htit19 << "PositionOfClusterS" << tag.c_str() << id; + local_histos.PositionOfClusterS = td.make(htit19.str().c_str(), htit19.str().c_str(), 1051, -0.5, 1050.5); + + std::ostringstream htit20; + htit20 << "DeltaPhi" << tag.c_str() << id; + local_histos.DeltaPhi = td.make(htit20.str().c_str(), htit20.str().c_str(), 200, 0.0, 3.2); + + std::ostringstream htit21; + htit21 << "ClusterWidthDeltaPhiP" << tag.c_str() << id; + local_histos.ClusterWidthDeltaPhiP = td.make(htit21.str().c_str(), htit21.str().c_str(), 200, 0.0, 3.2, 0.0, 10.0); + + std::ostringstream htit22; + htit22 << "ELossFromSimHit" << tag.c_str() << id; + local_histos.ELossSimHit = td.make(htit22.str().c_str(), htit22.str().c_str(), 100, 0.0, 500.0); + + std::ostringstream htit23; + htit23 << "PathLengthFromSimHit" << tag.c_str() << id; + local_histos.PathLengthSimHit = td.make(htit23.str().c_str(), htit23.str().c_str(), 100, 100.0, 500.0); + + std::ostringstream htit24; + htit24 << "EntryZFromSimHit" << tag.c_str() << id; + local_histos.EntryZSimHit = td.make(htit24.str().c_str(), htit24.str().c_str(), 300, -150.0, 150.0); + + std::ostringstream htit25; + htit25 << "ExitZFromSimHit" << tag.c_str() << id; + local_histos.ExitZSimHit = td.make(htit25.str().c_str(), htit25.str().c_str(), 300, -150.0, 150.0); + + std::ostringstream htit26; + htit26 << "ExitZVsEntryZFromSimHit" << tag.c_str() << id; + local_histos.ExitZVsEntryZSimHit = td.make(htit26.str().c_str(), htit26.str().c_str(), 300, -150., 150., 300, -150., 150.); + layerHistoMap.insert( std::make_pair(ival, local_histos)); fs->file().cd("/"); @@ -858,14 +969,13 @@ unsigned int DigiValidation::getMaxPosition(std::vector& charge_vec) { int DigiValidation::isPrimary(const SimTrack& simTrk, edm::Handle& simHits) { int result = -1; unsigned int trkId = simTrk.trackId(); + int vtxIndx = simTrk.vertIndex(); if (trkId > 0) { - int vtxIndx = simTrk.vertIndex(); + // int vtxIndx = simTrk.vertIndex(); for (edm::PSimHitContainer::const_iterator iHit = simHits->begin(); iHit != simHits->end(); ++iHit) { if (trkId == iHit->trackId()) { int ptype = iHit->processType(); - - - if ( (vtxIndx == 0 ) && (ptype == 2 || ptype == 7 || ptype == 9 || ptype == 11 || ptype == 15)) result = 1; + if ( (vtxIndx == 0 ) && (ptype == 2 || ptype == 7 || ptype == 9 || ptype == 11 || ptype == 13 ||ptype == 15) ) result = 1; else result = 0; break; } @@ -873,6 +983,26 @@ int DigiValidation::isPrimary(const SimTrack& simTrk, edm::Handle& simHits, Local3DPoint & entry, Local3DPoint& exit) { + float eloss = 0.0; + for (edm::PSimHitContainer::const_iterator iHit = simHits->begin(); iHit != simHits->end(); ++iHit) { + if (trkId == iHit->trackId() && rawId == iHit->detUnitId()) { + eloss = iHit->energyLoss(); + entry = iHit->entryPoint(); + exit = iHit->exitPoint(); + // segment =(iHit->exitPoint()-iHit->entryPoint()).mag(); + // if (fabs(iHit->entryPoint().z()) != fabs(iHit->exitPoint().z())) std::cout << " ====> entry " << iHit->exitPoint().x() + // << " " << iHit->exitPoint().y() << " " + // << iHit->exitPoint().z() + // << " exit " << iHit->entryPoint().x() << " " + // << iHit->entryPoint().y() << " " + // << iHit->entryPoint().z() + // << " Length " << segment << std::endl; + break; + } + } + return eloss; +} // // -- Check if the SimTrack is _Primary or not // @@ -912,5 +1042,23 @@ void DigiValidation::fillMatchedSimTrackHistos(DigiHistos& digiHistos, const Sim digiHistos.matchedSimTrackEta_->Fill(eta); digiHistos.matchedSimTrackPhi_->Fill(phi); } +unsigned int DigiValidation::getStackId(const StackedTrackerGeometry* stkgeom, DetId& detid){ + unsigned int id = 9999; + for ( StackedTrackerGeometry::StackContainerIterator stk = stkgeom->stacks().begin(); stk != stkgeom->stacks().end(); + ++stk ) { + StackedTrackerDetUnit* stackDetUnit = *stk; + StackedTrackerDetId stackDetId = stackDetUnit->Id(); + assert(stackDetUnit == stkgeom->idToStack(stackDetId)); + if (detid == stackDetUnit->stackMember(0)) { + id = 0; + break; + } else if (detid == stackDetUnit->stackMember(1)) { + id = 1; + break; + } + } + return id; +} + //define this as a plug-in DEFINE_FWK_MODULE(DigiValidation); diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py index 6d5fb5f430138..e2c5bd9a49a76 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py @@ -2,7 +2,7 @@ process = cms.Process("digiTest") process.maxEvents = cms.untracked.PSet( - input = cms.untracked.int32(5) + input = cms.untracked.int32(-1) ) process.MessageLogger = cms.Service("MessageLogger", debugModules = cms.untracked.vstring('siPixelRawData'), @@ -13,7 +13,7 @@ ) process.source = cms.Source("PoolSource", fileNames = cms.untracked.vstring( - 'file:/afs/cern.ch/work/d/dutta/public/Digitizer/CMSSW_6_2_0_SLHC2/src/prod/SingleElec_TK_BE5D_new.root' + 'file:/tmp/dutta/CMSSW_6_2_0_SLHC12/src/prod/elec_modified.root' ) ) process.load('Configuration.StandardSequences.Services_cff') @@ -21,8 +21,10 @@ process.load('FWCore.MessageService.MessageLogger_cfi') process.load('Configuration.EventContent.EventContent_cff') process.load('SimGeneral.MixingModule.mixNoPU_cfi') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBEReco_cff') -process.load('Configuration.Geometry.GeometryExtendedPhase2TkBE_cff') +process.load('Configuration.Geometry.GeometryExtended2023MuonReco_cff') +process.load('Configuration.Geometry.GeometryExtended2023Muon_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') + process.load('Configuration.StandardSequences.MagneticField_38T_cff') process.load('Configuration.StandardSequences.Generator_cff') process.load('IOMC.EventVertexGenerators.VtxSmearedGauss_cfi') @@ -41,10 +43,10 @@ # Output ROOT file #------------- process.TFileService = cms.Service("TFileService", - fileName = cms.string('./Elec_test.root') + fileName = cms.string('./Electron_modified_n.root') ) process.analysis = cms.EDAnalyzer("DigiValidation", - Verbosity = cms.untracked.bool(True), + Verbosity = cms.untracked.bool(False), # src = cms.InputTag("SiPixelDigis"), src = cms.InputTag("simSiPixelDigis"), simG4 = cms.InputTag("g4SimHits") From 3121e63dfde85a323ec8376c8fb7c277c384b4bc Mon Sep 17 00:00:00 2001 From: Suchandra Date: Mon, 18 Aug 2014 12:43:22 +0200 Subject: [PATCH 079/252] Latest code before integrating within the framework --- .../SiPhase2Digitizer/test/DigiValidation.cc | 39 ++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc index 00e52560d622e..d6c35ef7c204a 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc @@ -48,6 +48,7 @@ #include "DataFormats/SiPixelDetId/interface/PXBDetId.h" #include "DataFormats/SiPixelDetId/interface/PXFDetId.h" #include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" +#include "DataFormats/TrackerCommon/interface/TrackerTopology.h" #include "SimDataFormats/Track/interface/SimTrackContainer.h" #include "SimDataFormats/Vertex/interface/SimVertexContainer.h" @@ -117,6 +118,8 @@ class DigiValidation : public edm::EDAnalyzer { private: // ----------member data --------------------------- bool PRINT; + double phi_min; + double phi_max; TH1F* nSimTracks_; @@ -255,6 +258,7 @@ class DigiValidation : public edm::EDAnalyzer { void initializeVariables(); unsigned int getMaxPosition(std::vector& charge_vec); unsigned int getLayerNumber(const TrackerGeometry* tkgeom, unsigned int& detid); + unsigned int getLayerNumber(unsigned int& detid, const TrackerTopology* topo); unsigned int getLayerNumber(unsigned int& detid); int isPrimary(const SimTrack& simTrk, edm::Handle& simHits); int isPrimary(const SimTrack& simTrk, const PSimHit& simHit); @@ -269,6 +273,8 @@ DigiValidation::DigiValidation(const edm::ParameterSet& iConfig) { PRINT = iConfig.getUntrackedParameter("Verbosity",false); src_ = iConfig.getParameter("src"); simG4_ = iConfig.getParameter("simG4"); + phi_min = iConfig.getParameter("PhiMin"); + phi_max = iConfig.getParameter("PhiMax"); if (PRINT) std::cout << ">>> Construct DigiValidation " << std::endl; } DigiValidation::~DigiValidation() { @@ -318,6 +324,11 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS // iSetup.get().get(stackedGeometryHandle); // const StackedTrackerGeometry* theStackedGeometry = stackedGeometryHandle.product(); + // Tracker Topology + // edm::ESHandle tTopoHandle; + // iSetup.get().get(tTopoHandle); + // const TrackerTopology* tTopo = tTopoHandle.product(); + // Get PSimHits edm::Handle simHits; iEvent.getByLabel("g4SimHits","TrackerHitsPixelBarrelLowTof" ,simHits); @@ -389,14 +400,18 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS unsigned int rawid = DSViter->id; DetId detId(rawid); unsigned int layer = getLayerNumber(rawid); + //=================Temporary ============== + if (layer !=8) continue; + //=================Temporary ============== std::map::iterator iPos = layerHistoMap.find(layer); if (iPos == layerHistoMap.end()) { createLayerHistograms(layer); iPos = layerHistoMap.find(layer); } const GeomDetUnit* geomDetUnit = tkGeom->idToDetUnit(detId); + if (!geomDetUnit) std::cout << " Id " << " Layer " << layer << std::endl; // const PixelGeomDetUnit* pixdet = (PixelGeomDetUnit*) geomDetUnit; - // std::cout << " Layer " << layer << " Thickness " << pixdet->specificSurface().bounds().thickness() << " Pitch " << pixdet->specificTopology().pitch().first <specificSurface().bounds().thickness() << " Pitch " << pixdet->specificTopology().pitch().first <::const_iterator di; int col_last = -1; int row_last = -1; @@ -432,6 +447,10 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS dPhi = reco::deltaPhi((*simTracks)[iSimTrk].momentum().phi(), geomDetUnit->position().phi()); } iPos->second.DeltaPhi->Fill(dPhi); + //=================Temporary ============== + if (fabs(dPhi) <= phi_min || fabs(dPhi) >= phi_max) continue; + //=================Temporary ============== + int primaryTrk = -1; if (iSimTrk != -1) { primaryTrk = processTypes[iSimTrk]; @@ -933,6 +952,24 @@ unsigned int DigiValidation::getLayerNumber(const TrackerGeometry* tkgeom,unsign // // -- Get Layer Number // +unsigned int DigiValidation::getLayerNumber(unsigned int& detid, const TrackerTopology* topo) { + unsigned int layer = 999; + DetId theDetId(detid); + + if (theDetId.det() == DetId::Tracker) { + if (theDetId.subdetId() == PixelSubdetector::PixelBarrel) { + layer = topo->pxbLayer(detid); + } else if (theDetId.subdetId() == PixelSubdetector::PixelEndcap) { + layer = 100 * topo->pxfSide(detid) + topo->pxfDisk(detid); + } else { + std::cout << ">>> Invalid subdetId() = " << theDetId.subdetId() << std::endl; + } + } + return layer; +} +// +// -- Get Layer Number +// unsigned int DigiValidation::getLayerNumber(unsigned int& detid) { unsigned int layer = 999; DetId theDetId(detid); From 06cab252a86bafc70d10e000830f21414f221137 Mon Sep 17 00:00:00 2001 From: Suchandra Date: Tue, 19 Aug 2014 11:14:34 +0200 Subject: [PATCH 080/252] update DigiValidationTest_cfg.py --- SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py index e2c5bd9a49a76..6b45a3904f999 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py @@ -13,7 +13,7 @@ ) process.source = cms.Source("PoolSource", fileNames = cms.untracked.vstring( - 'file:/tmp/dutta/CMSSW_6_2_0_SLHC12/src/prod/elec_modified.root' + 'file:/afs/cern.ch/user/d/dutta/work/public/Digitizer/Devel2/CMSSW_6_2_0_SLHC15/src/prod/electron_updatedcode.root' ) ) process.load('Configuration.StandardSequences.Services_cff') @@ -43,7 +43,7 @@ # Output ROOT file #------------- process.TFileService = cms.Service("TFileService", - fileName = cms.string('./Electron_modified_n.root') + fileName = cms.string('./Electron_Updated.root') ) process.analysis = cms.EDAnalyzer("DigiValidation", Verbosity = cms.untracked.bool(False), From 5b01ebb798f13db649df4c4c3aac7ab69afa7636 Mon Sep 17 00:00:00 2001 From: Suchandra Date: Tue, 19 Aug 2014 11:19:12 +0200 Subject: [PATCH 081/252] First version of the PhaseII Tracker Digitizer with added supoort for Pixel, PS and SS modules --- .../interface/DigitizerUtility.h | 137 +++ .../interface/PSPDigitizerAlgorithm.h | 43 + .../interface/PSSDigitizerAlgorithm.h | 43 + .../interface/Phase2TrackerDigitizer.h | 94 ++ .../Phase2TrackerDigitizerAlgorithm.h | 210 ++++ .../interface/Phase2TrackerDigitizerFwd.h | 15 + .../interface/PixelDigitizerAlgorithm.h | 50 + .../interface/SSDigitizerAlgorithm.h | 41 + .../plugins/PSPDigitizerAlgorithm.cc | 188 ++++ .../plugins/PSSDigitizerAlgorithm.cc | 190 ++++ .../plugins/Phase2TrackerDigitizer.cc | 259 +++++ .../Phase2TrackerDigitizerAlgorithm.cc | 961 ++++++++++++++++++ .../plugins/PixelDigitizerAlgorithm.cc | 183 ++++ .../plugins/SSDigitizerAlgorithm.cc | 184 ++++ .../python/phase2TrackerDigitizer_cfi.py | 156 +++ 15 files changed, 2754 insertions(+) create mode 100644 SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h create mode 100644 SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h create mode 100644 SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h create mode 100644 SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h create mode 100644 SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h create mode 100644 SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h create mode 100644 SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h create mode 100644 SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h create mode 100644 SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc create mode 100644 SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc create mode 100644 SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc create mode 100644 SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc create mode 100644 SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc create mode 100644 SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc create mode 100644 SimTracker/SiPhase2Digitizer/python/phase2TrackerDigitizer_cfi.py diff --git a/SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h b/SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h new file mode 100644 index 0000000000000..89aea23a272e7 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h @@ -0,0 +1,137 @@ +#ifndef __SimTracker_SiPhase2Digitizer_DigitizerUtility_h +#define __SimTracker_SiPhase2Digitizer_DigitizerUtility_h + +#include +#include +#include +#include + +#include "SimDataFormats/TrackingHit/interface/PSimHit.h" +#include "SimTracker/Common/interface/SimHitInfoForLinks.h" +#include "SimDataFormats/EncodedEventId/interface/EncodedEventId.h" + +namespace DigitizerUtility { + class Amplitude { + public: + Amplitude() : _amp(0.0) + {} + Amplitude(float amp, float frac) : + _amp(amp), _frac(1, frac), _hitInfo() + { + // in case of digi from noisypixels + // the MC information are removed + if (_frac[0] < -0.5) + _frac.pop_back(); + } + + Amplitude(float amp, const PSimHit* hitp, float frac) : + _amp(amp), _frac(1, frac), _hitInfo(new SimHitInfoForLinks(hitp)) + { + // in case of digi from noisypixels + // the MC information are removed + if (_frac[0] < -0.5) { + _frac.pop_back(); + _hitInfo->trackIds_.pop_back(); + } + } + + // can be used as a float by convers. + operator float() const {return _amp;} + float ampl() const {return _amp;} + std::vector individualampl() const {return _frac;} + const std::vector& trackIds() const {return _hitInfo->trackIds_;} + const std::shared_ptr& hitInfo() const {return _hitInfo;} + + void operator+= (const Amplitude& other) { + _amp += other._amp; + + // in case of contribution of noise to the digi + // the MC information are removed + if (other._frac.size() > 0 && other._frac[0] >- 0.5) { + if (other._hitInfo) { + std::vector& otherTrackIds = other._hitInfo->trackIds_; + if (_hitInfo) { + std::vector& trackIds = _hitInfo->trackIds_; + trackIds.insert(trackIds.end(), otherTrackIds.begin(), otherTrackIds.end()); + } + else + _hitInfo.reset(new SimHitInfoForLinks(*other._hitInfo)); + } + _frac.insert(_frac.end(), other._frac.begin(), other._frac.end()); + } + } + const EncodedEventId& eventId() const { + return _hitInfo->eventId_; + } + void operator+= (const float& amp) { + _amp += amp; + } + void set (const float amplitude) { // Used to reset the amplitude + _amp = amplitude; + } + // void setind (const float indamplitude) { // Used to reset the amplitude + // _frac = idamplitude; + // } + + private: + float _amp; + std::vector _frac; + std::shared_ptr _hitInfo; + }; + + //********************************************************* + // Define a class for 3D ionization points and energy + //********************************************************* + class EnergyDepositUnit { + public: + EnergyDepositUnit(): _energy(0),_position(0,0,0) {} + EnergyDepositUnit(float energy,float x, float y, float z): + _energy(energy),_position(x,y,z) {} + EnergyDepositUnit(float energy, Local3DPoint position): + _energy(energy),_position(position) {} + float x() const{return _position.x();} + float y() const{return _position.y();} + float z() const{return _position.z();} + float energy() const { return _energy;} + private: + float _energy; + Local3DPoint _position; + }; + + //********************************************************** + // define class to store signals on the collection surface + //********************************************************** + class SignalPoint { + public: + SignalPoint(): _pos(0,0), _time(0), _amplitude(0), + _sigma_x(1.), _sigma_y(1.), _hitp(0) {} + + SignalPoint(float x, float y, float sigma_x, float sigma_y, + float t, float a=1.0): + _pos(x,y), _time(t), _amplitude(a), _sigma_x(sigma_x), + _sigma_y(sigma_y), _hitp(0) {} + + SignalPoint(float x, float y, float sigma_x, float sigma_y, + float t, const PSimHit& hit, float a=1.0): + _pos(x,y), _time(t), _amplitude(a), _sigma_x(sigma_x), + _sigma_y(sigma_y),_hitp(&hit) {} + + const LocalPoint& position() const {return _pos;} + float x() const {return _pos.x();} + float y() const {return _pos.y();} + float sigma_x() const {return _sigma_x;} + float sigma_y() const {return _sigma_y;} + float time() const {return _time;} + float amplitude() const {return _amplitude;} + const PSimHit& hit() {return *_hitp;} + SignalPoint& set_amplitude(float amp) {_amplitude = amp; return *this;} + private: + LocalPoint _pos; + float _time; + float _amplitude; + float _sigma_x; // gaussian sigma in the x direction (cm) + float _sigma_y; // " " y direction (cm) */ + const PSimHit* _hitp; + }; +} +#endif diff --git a/SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h new file mode 100644 index 0000000000000..2dab32a14bfb9 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h @@ -0,0 +1,43 @@ +#ifndef _SimTracker_SiPhase2Digitizer_PSPDigitizerAlgorithm_h +#define _SimTracker_SiPhase2Digitizer_PSPDigitizerAlgorithm_h + +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h" +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" + +// forward declarations +// For the random numbers +//namespace CLHEP { +// class HepRandomEngine; +//} +// +//namespace edm { +// class EventSetup; +// class ParameterSet; +//} + +//class PixelDigi; +//class PixelDigiSimLink; +//class PixelGeomDetUnit; +//class TrackerTopology; + +class PSPDigitizerAlgorithm: public Phase2TrackerDigitizerAlgorithm { + public: + PSPDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine&); + ~PSPDigitizerAlgorithm(); + + // initialization that cannot be done in the constructor + void init(const edm::EventSetup& es); + + // void initializeEvent(); + // run the algorithm to digitize a single det + void accumulateSimHits(const std::vector::const_iterator inputBegin, + const std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield); + void digitize(const PixelGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo); +}; +#endif diff --git a/SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h new file mode 100644 index 0000000000000..258c1febca208 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h @@ -0,0 +1,43 @@ +#ifndef _SimTracker_SiPhase2Digitizer_PSSDigitizerAlgorithm_h +#define _SimTracker_SiPhase2Digitizer_PSSDigitizerAlgorithm_h + +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h" +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" + +// forward declarations +// For the random numbers +//namespace CLHEP { +// class HepRandomEngine; +//} +// +//namespace edm { +// class EventSetup; +// class ParameterSet; +//} +// +//class PixelDigi; +//class PixelDigiSimLink; +//class PixelGeomDetUnit; +//class TrackerTopology; + +class PSSDigitizerAlgorithm :public Phase2TrackerDigitizerAlgorithm { + public: + PSSDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine&); + ~PSSDigitizerAlgorithm(); + + // initialization that cannot be done in the constructor + void init(const edm::EventSetup& es); + + // void initializeEvent(); + // run the algorithm to digitize a single det + void accumulateSimHits(const std::vector::const_iterator inputBegin, + const std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield); + void digitize(const PixelGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo); +}; +#endif diff --git a/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h new file mode 100644 index 0000000000000..518067e5cda8d --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h @@ -0,0 +1,94 @@ +#ifndef __SimTracker_SiPhase2Digitizer_Phase2TrackerDigitizer_h +#define __SimTracker_SiPhase2Digitizer_Phase2TrackerDigitizer_h + +//------------------------------------------------------------- +// class Phase2TrackerDigitizer +// +// Phase2TrackerDigitizer produces digis from SimHits +// The real algorithm is in Phase2TrackerDigitizerAlgorithm +// +// version 1.1 August 18 2014 +// +//-------------------------------------------------------------- + +#include +#include +#include + +#include "SimGeneral/MixingModule/interface/DigiAccumulatorMixMod.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "DataFormats/DetId/interface/DetId.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerGeometry.h" +#include "Geometry/TrackerGeometryBuilder/interface/StackedTrackerDetUnit.h" +#include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" + +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" + +namespace CLHEP { + class HepRandomEngine; +} + +namespace edm { + class EDProducer; + class Event; + class EventSetup; + class ParameterSet; + template class Handle; +} + +class MagneticField; +class PileUpEventPrincipal; +class PixelGeomDetUnit; +//class PixelDigi; +//class PixelDigiSimLink; +class PSimHit; +class Phase2TrackerDigitizerAlgorithm; +class TrackerGeometry; + +namespace cms +{ + class Phase2TrackerDigitizer : public DigiAccumulatorMixMod { + + public: + // typedef to change names of current pixel types to phase 2 types + typedef PixelGeomDetUnit Phase2TrackerGeomDetUnit; + typedef PixelDigi Phase2TrackerDigi; + typedef PixelDigiSimLink Phase2TrackerDigiSimLink; + typedef PixelTopology Phase2TrackerTopology; + + explicit Phase2TrackerDigitizer(const edm::ParameterSet& conf, edm::EDProducer& mixMod); + virtual ~Phase2TrackerDigitizer(); + virtual void initializeEvent(edm::Event const& e, edm::EventSetup const& c) override; + virtual void accumulate(edm::Event const& e, edm::EventSetup const& c) override; + virtual void accumulate(PileUpEventPrincipal const& e, edm::EventSetup const& c) override; + virtual void finalizeEvent(edm::Event& e, edm::EventSetup const& c) override; + virtual void beginJob() {} + void beginRun(edm::Run const& run, edm::EventSetup const& iSetup); + std::string getAlgoType(unsigned int idet); + template + void accumulate_local(T const& iEvent, edm::EventSetup const& iSetup); + + // constants of different algorithm types + const static std::string InnerPixel; + const static std::string PixelinPS; + const static std::string StripinPS; + const static std::string TwoStrip; + + private: + typedef std::vector vstring; + + void accumulatePixelHits(edm::Handle >); + bool first_; + std::map > algomap_; + const std::string hitsProducer_; + const vstring trackerContainers_; + const std::string geometryType_; + edm::ESHandle pDD_; + edm::ESHandle pSetup_; + std::map detectorUnits_; + CLHEP::HepRandomEngine* rndEngine_; + const StackedTrackerGeometry* stkGeom_; + std::map detIdStackDetIdmap_; + }; +} +#endif diff --git a/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h new file mode 100644 index 0000000000000..3c470d2e9ba8a --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h @@ -0,0 +1,210 @@ +#ifndef __SimTracker_SiPhase2Digitizer_Phase2TrackerDigitizerAlgorithm_h +#define __SimTracker_SiPhase2Digitizer_Phase2TrackerDigitizerAlgorithm_h + +#include +#include +#include +#include +#include "DataFormats/GeometrySurface/interface/GloballyPositioned.h" +#include "DataFormats/GeometryVector/interface/LocalPoint.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "SimDataFormats/EncodedEventId/interface/EncodedEventId.h" +#include "SimDataFormats/TrackingHit/interface/PSimHit.h" +#include "SimTracker/Common/interface/SimHitInfoForLinks.h" +#include "DataFormats/Math/interface/approx_exp.h" +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" +#include "SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h" + +// forward declarations +// For the random numbers +namespace CLHEP { + class HepRandomEngine; + class RandGaussQ; + class RandFlat; +} + +namespace edm { + class EventSetup; + class ParameterSet; +} + +class DetId; +class GaussianTailNoiseGenerator; +class PixelDigi; +class PixelDigiSimLink; +class PixelGeomDetUnit; +class PixelTopology; +class SiG4UniversalFluctuation; +class SiPixelFedCablingMap; +class SiPixelGainCalibrationOfflineSimService; +class SiPixelLorentzAngle; +class SiPixelQuality; +class TrackerGeometry; +class TrackerTopology; + +class Phase2TrackerDigitizerAlgorithm { + public: + Phase2TrackerDigitizerAlgorithm(const edm::ParameterSet& conf_common, const edm::ParameterSet& conf_specific, CLHEP::HepRandomEngine&); + ~Phase2TrackerDigitizerAlgorithm(); + + // initialization that cannot be done in the constructor + virtual void init(const edm::EventSetup& es) = 0; + virtual void initializeEvent() { + _signal.clear(); + } + // run the algorithm to digitize a single det + virtual void accumulateSimHits(const std::vector::const_iterator inputBegin, + const std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield) = 0; + virtual void digitize(const Phase2TrackerGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo) = 0; + protected: + // Accessing Lorentz angle from DB: + edm::ESHandle SiPixelLorentzAngle_; + + // Accessing Dead pixel modules from DB: + edm::ESHandle SiPixelBadModule_; + + // Accessing Map and Geom: + edm::ESHandle map_; + edm::ESHandle geom_; + struct SubdetEfficiencies { + SubdetEfficiencies(const edm::ParameterSet& conf); + std::vector barrel_efficiencies; + std::vector endcap_efficiencies; + }; + + // Internal typedefs + typedef std::map > signal_map_type; // from Digi.Skel. + typedef signal_map_type::iterator signal_map_iterator; // from Digi.Skel. + typedef signal_map_type::const_iterator signal_map_const_iterator; // from Digi.Skel. + typedef std::map,std::less > simlink_map; + typedef std::map signalMaps; + typedef GloballyPositioned Frame; + typedef std::vector Parameters; + + // Contains the accumulated hit info. + signalMaps _signal; + + const bool makeDigiSimLinks_; + + const bool use_ineff_from_db_; + const bool use_module_killing_; // remove or not the dead pixel modules + const bool use_deadmodule_DB_; // if we want to get dead pixel modules from the DataBase. + const bool use_LorentzAngle_DB_; // if we want to get Lorentz angle from the DataBase. + + const Parameters DeadModules; + + // Variables + // external parameters + // go from Geant energy GeV to number of electrons + const float GeVperElectron; // 3.7E-09 + + //-- drift + const bool alpha2Order; // Switch on/off of E.B effect + const bool addXtalk; + const float interstripCoupling; + const float Sigma0; //=0.0007 // Charge diffusion in microns for 300 micron Si + const float SigmaCoeff; // delta in the diffusion across the strip pitch + + //-- induce_signal + const float ClusterWidth; // Gaussian charge cutoff width in sigma units + + //-- make_digis + const bool doDigitalReadout; // Flag to decide analog or digital readout + const float theElectronPerADC; // Gain, number of electrons per adc count. + const int theAdcFullScale; // Saturation count, 255=8bit. + const float theNoiseInElectrons; // Noise (RMS) in units of electrons. + const float theReadoutNoise; // Noise of the readount chain in elec, + + // inludes DCOL-Amp,TBM-Amp, Alt, AOH,OptRec. + const float theThresholdInE_Endcap; // threshold in electrons Endcap. + const float theThresholdInE_Barrel; // threshold in electrons Barrel. + + const double theThresholdSmearing_Endcap; + const double theThresholdSmearing_Barrel; + + const float theTofLowerCut; // Cut on the particle TOF + const float theTofUpperCut; // Cut on the particle TOF + const float tanLorentzAnglePerTesla_Endcap; //FPix Lorentz angle tangent per Tesla + const float tanLorentzAnglePerTesla_Barrel; //BPix Lorentz angle tangent per Tesla + + // -- add_noise + const bool addNoise; + const bool addNoisyPixels; + const bool fluctuateCharge; + + //-- pixel efficiency + const bool AddPixelInefficiency; // bool to read in inefficiencies + + const bool addThresholdSmearing; + + // pseudoRadDamage + const double pseudoRadDamage; // Decrease the amount off freed charge that reaches the collector + const double pseudoRadDamageRadius; // Only apply pseudoRadDamage to pixels with radius<=pseudoRadDamageRadius + + // The PDTable + // HepPDTable *particleTable; + // ParticleDataTable *particleTable; + + //-- charge fluctuation + const double tMax; // The delta production cut, should be as in OSCAR = 30keV + + // The eloss fluctuation class from G4. Is the right place? + const std::unique_ptr fluctuate; // make a pointer + const std::unique_ptr theNoiser; + + //-- additional member functions + // Private methods + void primary_ionization( const PSimHit& hit, std::vector& ionization_points) const; + void drift(const PSimHit& hit, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield, + const std::vector& ionization_points, + std::vector& collection_points) const; + void induce_signal(const PSimHit& hit, + const Phase2TrackerGeomDetUnit* pixdet, + const std::vector& collection_points); + void fluctuateEloss(int particleId, float momentum, float eloss, + float length, int NumberOfSegments, + float elossVector[]) const; + void add_noise(const Phase2TrackerGeomDetUnit* pixdet, float thePixelThreshold); + void make_digis(float thePixelThresholdInE, + uint32_t detID, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo) const; + virtual void pixel_inefficiency(const SubdetEfficiencies& eff, + const Phase2TrackerGeomDetUnit* pixdet, + const TrackerTopology* tTopo); + + virtual void pixel_inefficiency_db(uint32_t detID); + + // access to the gain calibration payloads in the db. Only gets initialized if check_dead_pixels_ is set to true. + const std::unique_ptr theSiPixelGainCalibrationService_; + LocalVector DriftDirection(const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield, + const DetId& detId) const; + + virtual void module_killing_conf(uint32_t detID); // remove dead modules using the list in the configuration file PixelDigi_cfi.py + virtual void module_killing_DB(uint32_t detID); // remove dead modules uisng the list in the DB + + const SubdetEfficiencies subdetEfficiencies_; + + // For random numbers + const std::unique_ptr flatDistribution_; + const std::unique_ptr gaussDistribution_; + + // Threshold gaussian smearing: + const std::unique_ptr smearedThreshold_Endcap_; + const std::unique_ptr smearedThreshold_Barrel_; + + double calcQ(float x) const { + auto xx = std::min(0.5f * x * x,12.5f); + return 0.5 * (1.0-std::copysign(std::sqrt(1.f- unsafe_expf<4>(-xx * (1.f + 0.2733f/(1.f + 0.147f * xx)))), x)); + } +}; +#endif diff --git a/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h new file mode 100644 index 0000000000000..8692fae648007 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h @@ -0,0 +1,15 @@ +#ifndef __SimTracker_SiPhase2Digitizer_Phase2TrackerDigitizerFwd_h +#define __SimTracker_SiPhase2Digitizer_Phase2TrackerDigitizerFwd_h + +class PixelDigi; +class PixelDigiSimLink; +class PixelGeomDetUnit; +class PixelTopology; + +typedef PixelDigi Phase2TrackerDigi; +typedef PixelDigiSimLink Phase2TrackerDigiSimLink; +typedef PixelGeomDetUnit Phase2TrackerGeomDetUnit; +typedef PixelTopology Phase2TrackerTopology; + +#endif + diff --git a/SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h new file mode 100644 index 0000000000000..e032e64e4d53b --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h @@ -0,0 +1,50 @@ +#ifndef _SimTracker_SiPhase2Digitizer_PixelDigitizerAlgorithm_h +#define _SimTracker_SiPhase2Digitizer_PixelDigitizerAlgorithm_h + +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h" +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" + +// forward declarations +// For the random numbers +//namespace CLHEP { +// class HepRandomEngine; +//} + +//namespace edm { +// class EventSetup; +// class ParameterSet; +//} + +//class PixelDigi; +//class PixelDigiSimLink; +//class PixelGeomDetUnit; +//class TrackerTopology; + +class PixelDigitizerAlgorithm: public Phase2TrackerDigitizerAlgorithm { + private: + // tpyedef to change names of current pixel types to phase 2 types + typedef PixelGeomDetUnit Phase2TrackerGeomDetUnit; + typedef PixelDigi Phase2TrackerDigi; + typedef PixelDigiSimLink Phase2TrackerDigiSimLink; + typedef PixelTopology Phase2TrackerTopology; + + public: + PixelDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine&); + ~PixelDigitizerAlgorithm(); + + // initialization that cannot be done in the constructor + void init(const edm::EventSetup& es); + + // void initializeEvent(); + // run the algorithm to digitize a single det + void accumulateSimHits(const std::vector::const_iterator inputBegin, + const std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield); + void digitize(const Phase2TrackerGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo); +}; +#endif diff --git a/SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h new file mode 100644 index 0000000000000..791d699824cdd --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h @@ -0,0 +1,41 @@ +#ifndef _SimTracker_SiPhase2Digitizer_SSDigitizerAlgorithm_h +#define _SimTracker_SiPhase2Digitizer_SSDigitizerAlgorithm_h + +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h" +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" + +// forward declarations +// For the random numbers +//namespace CLHEP { +// class HepRandomEngine; +//} +//namespace edm { +// class EventSetup; +// class ParameterSet; +//} +// +//class PixelDigi; +//class PixelDigiSimLink; +//class PixelGeomDetUnit; +//class TrackerTopology; + +class SSDigitizerAlgorithm :public Phase2TrackerDigitizerAlgorithm { + public: + SSDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine&); + ~SSDigitizerAlgorithm(); + + // initialization that cannot be done in the constructor + void init(const edm::EventSetup& es); + + //run the algorithm to digitize a single det + void accumulateSimHits(const std::vector::const_iterator inputBegin, + const std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield); + void digitize(const Phase2TrackerGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo); +}; +#endif diff --git a/SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc new file mode 100644 index 0000000000000..4abfcb3cfe076 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc @@ -0,0 +1,188 @@ +#include +#include + +#include "SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h" +#include "SimTracker/Common/interface/SiG4UniversalFluctuation.h" +#include "SimGeneral/NoiseGenerators/interface/GaussianTailNoiseGenerator.h" + +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" +#include "DataFormats/TrackerCommon/interface/TrackerTopology.h" +#include "DataFormats/DetId/interface/DetId.h" +#include "DataFormats/FEDRawData/interface/FEDNumbering.h" +#include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" +#include "DataFormats/SiPixelDetId/interface/PixelEndcapName.h" + +#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" + +#include +#include "FWCore/Utilities/interface/RandomNumberGenerator.h" +#include "CLHEP/Random/RandGaussQ.h" +#include "CLHEP/Random/RandFlat.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "FWCore/Utilities/interface/Exception.h" +#include "CalibTracker/SiPixelESProducers/interface/SiPixelGainCalibrationOfflineSimService.h" + +#include "CondFormats/SiPixelObjects/interface/GlobalPixel.h" +#include "CondFormats/DataRecord/interface/SiPixelQualityRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelFedCablingMapRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelLorentzAngleSimRcd.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingMap.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingTree.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelIndices.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelLorentzAngle.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelQuality.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" +#include "CondFormats/SiPixelObjects/interface/LocalPixel.h" +#include "CondFormats/SiPixelObjects/interface/CablingPathToDetUnit.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFrameReverter.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDLink.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" + +// Geometry +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/CommonTopologies/interface/PixelTopology.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +using namespace edm; +using namespace sipixelobjects; +//#define TP_DEBUG // protect all LogDebug with ifdef. Takes too much CPU + +void PSPDigitizerAlgorithm::init(const edm::EventSetup& es) { + if (use_ineff_from_db_) // load gain calibration service from db + theSiPixelGainCalibrationService_->setESObjects( es ); + + if (use_deadmodule_DB_) + es.get().get(SiPixelBadModule_); + + if (use_LorentzAngle_DB_) + // Get Lorentz angle from DB record + es.get().get(SiPixelLorentzAngle_); + + // gets the map and geometry from the DB (to kill ROCs) + es.get().get(map_); + es.get().get(geom_); +} +PSPDigitizerAlgorithm::PSPDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine& eng) : + Phase2TrackerDigitizerAlgorithm(conf.getParameter("AlgorithmCommon"), + conf.getParameter("PSPDigitizerAlgorithm"), + eng) +{ + LogInfo("PSPDigitizerAlgorithm") << "PSPDigitizerAlgorithm constructed " + << "Configuration parameters:" + << "Threshold/Gain = " + << "threshold in electron Endcap = " + << theThresholdInE_Endcap + << "threshold in electron Barrel = " + << theThresholdInE_Barrel + << " " << theElectronPerADC << " " << theAdcFullScale + << " The delta cut-off is set to " << tMax + << " pix-inefficiency "<::const_iterator inputBegin, + std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield) { + // produce SignalPoint's for all SimHit's in detector + // Loop over hits + uint32_t detId = pixdet->geographicalId().rawId(); + for (auto it = inputBegin; it != inputEnd; ++it) { + // skip hits not in this detector. + if ((*it).detUnitId() != detId) + continue; + + LogDebug("PSPDigitizerAlgorithm") + << (*it).particleType() << " " << (*it).pabs() << " " + << (*it).energyLoss() << " " << (*it).tof() << " " + << (*it).trackId() << " " << (*it).processType() << " " + << (*it).detUnitId() + << (*it).entryPoint() << " " << (*it).exitPoint() ; + + std::vector ionization_points; + std::vector collection_points; + + // fill collection_points for this SimHit, indpendent of topology + // Check the TOF cut + if (((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) >= theTofLowerCut && + ((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) <= theTofUpperCut) { + primary_ionization(*it, ionization_points); // fills _ionization_points + drift(*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points + + // compute induced signal on readout elements and add to _signal + induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + } + } +} +void PSPDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo) { + + // Pixel Efficiency moved from the constructor to this method because + // the information of the det are not available in the constructor + // Effciency parameters. 0 - no inefficiency, 1-low lumi, 10-high lumi + + uint32_t detID = pixdet->geographicalId().rawId(); + const signal_map_type& theSignal = _signal[detID]; // check validity + + const Phase2TrackerTopology* topol = &pixdet->specificTopology(); + int numColumns = topol->ncolumns(); // det module number of cols&rows + int numRows = topol->nrows(); + + // Noise already defined in electrons + // thePixelThresholdInE = thePixelThreshold * theNoiseInElectrons ; + // Find the threshold in noise units, needed for the noiser. + + unsigned int Sub_detid = DetId(detID).subdetId(); + + float theThresholdInE = 0.; + + // can we generalize it + if (theNoiseInElectrons > 0.) { + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } + else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing + } + } + + // full detector thickness + float moduleThickness = pixdet->specificSurface().bounds().thickness(); + LogDebug("PSPDigitizerAlgorithm") + << numColumns << " " << numRows << " " << moduleThickness; + + if (addNoise) add_noise(pixdet, theThresholdInE/theNoiseInElectrons); // generate noise + + // Do only if needed + if (AddPixelInefficiency && theSignal.size() > 0) { + if (use_ineff_from_db_) + pixel_inefficiency_db(detID); + else + pixel_inefficiency(subdetEfficiencies_, pixdet, tTopo); + } + + if (use_module_killing_) { + if (use_deadmodule_DB_) // remove dead modules using DB + module_killing_DB(detID); + else // remove dead modules using the list in cfg file + module_killing_conf(detID); + } + + make_digis(theThresholdInE, detID, digis, simlinks, tTopo); + + LogDebug("PSPDigitizerAlgorithm") << "[PSPDigitizerAlgorithm] converted " << digis.size() << " PixelDigis in DetUnit" << detID; +} diff --git a/SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc new file mode 100644 index 0000000000000..08e809a8b691f --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc @@ -0,0 +1,190 @@ +#include +#include + +#include "SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h" +#include "SimTracker/Common/interface/SiG4UniversalFluctuation.h" +#include "SimGeneral/NoiseGenerators/interface/GaussianTailNoiseGenerator.h" + +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" +#include "DataFormats/TrackerCommon/interface/TrackerTopology.h" +#include "DataFormats/DetId/interface/DetId.h" +#include "DataFormats/FEDRawData/interface/FEDNumbering.h" +#include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" +#include "DataFormats/SiPixelDetId/interface/PixelEndcapName.h" + +#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" + +#include +#include "FWCore/Utilities/interface/RandomNumberGenerator.h" +#include "CLHEP/Random/RandGaussQ.h" +#include "CLHEP/Random/RandFlat.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "FWCore/Utilities/interface/Exception.h" +#include "CalibTracker/SiPixelESProducers/interface/SiPixelGainCalibrationOfflineSimService.h" + +#include "CondFormats/SiPixelObjects/interface/GlobalPixel.h" +#include "CondFormats/DataRecord/interface/SiPixelQualityRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelFedCablingMapRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelLorentzAngleSimRcd.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingMap.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingTree.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelIndices.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelLorentzAngle.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelQuality.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" +#include "CondFormats/SiPixelObjects/interface/LocalPixel.h" +#include "CondFormats/SiPixelObjects/interface/CablingPathToDetUnit.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFrameReverter.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDLink.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" + +// Geometry +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/CommonTopologies/interface/PixelTopology.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +using namespace edm; +using namespace sipixelobjects; + +void PSSDigitizerAlgorithm::init(const edm::EventSetup& es) { + if (use_ineff_from_db_) // load gain calibration service from db + theSiPixelGainCalibrationService_->setESObjects(es); + + if (use_deadmodule_DB_) + es.get().get(SiPixelBadModule_); + + if (use_LorentzAngle_DB_) + // Get Lorentz angle from DB record + es.get().get(SiPixelLorentzAngle_); + + // gets the map and geometry from the DB (to kill ROCs) + es.get().get(map_); + es.get().get(geom_); +} +PSSDigitizerAlgorithm::PSSDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine& eng): + Phase2TrackerDigitizerAlgorithm(conf.getParameter("AlgorithmCommon"), + conf.getParameter("PSSDigitizerAlgorithm"), + eng) +{ + LogInfo("PSSDigitizerAlgorithm") << "PSSDigitizerAlgorithm constructed " + << "Configuration parameters:" + << "Threshold/Gain = " + << "threshold in electron Endcap = " + << theThresholdInE_Endcap + << "threshold in electron Barrel = " + << theThresholdInE_Barrel + << " " << theElectronPerADC << " " << theAdcFullScale + << " The delta cut-off is set to " << tMax + << " pix-inefficiency "<::const_iterator inputBegin, + std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield) { + // produce SignalPoint's for all SimHit's in detector + // Loop over hits + uint32_t detId = pixdet->geographicalId().rawId(); + for (auto it = inputBegin; it != inputEnd; ++it) { + // skip hits not in this detector. + if ((*it).detUnitId() != detId) + continue; + + LogDebug("PSSDigitizerAlgorithm") + << (*it).particleType() << " " << (*it).pabs() << " " + << (*it).energyLoss() << " " << (*it).tof() << " " + << (*it).trackId() << " " << (*it).processType() << " " + << (*it).detUnitId() + << (*it).entryPoint() << " " << (*it).exitPoint() ; + + std::vector ionization_points; + std::vector collection_points; + + // fill collection_points for this SimHit, indpendent of topology + // Check the TOF cut + if (((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) >= theTofLowerCut && + ((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) <= theTofUpperCut) { + primary_ionization(*it, ionization_points); // fills _ionization_points + drift(*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points + + // compute induced signal on readout elements and add to _signal + induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + } + } +} + +void PSSDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo) { + + // Pixel Efficiency moved from the constructor to this method because + // the information of the det are not available in the constructor + // Effciency parameters. 0 - no inefficiency, 1-low lumi, 10-high lumi + + uint32_t detID = pixdet->geographicalId().rawId(); + const signal_map_type& theSignal = _signal[detID]; // check validity + + const Phase2TrackerTopology* topol = &pixdet->specificTopology(); + int numColumns = topol->ncolumns(); // det module number of cols&rows + int numRows = topol->nrows(); + + // Noise already defined in electrons + // thePixelThresholdInE = thePixelThreshold * theNoiseInElectrons ; + // Find the threshold in noise units, needed for the noiser. + + unsigned int Sub_detid = DetId(detID).subdetId(); + + float theThresholdInE = 0.; + + // can we generalize it + if (theNoiseInElectrons > 0.) { + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } + else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing + } + } + + // full detector thickness + float moduleThickness = pixdet->specificSurface().bounds().thickness(); + LogDebug("PSSDigitizerAlgorithm") + << " PixelDigitizer " + << numColumns << " " << numRows << " " << moduleThickness; + + if (addNoise) add_noise(pixdet, theThresholdInE/theNoiseInElectrons); // generate noise + + // Do only if needed + if (AddPixelInefficiency && theSignal.size() > 0) { + if (use_ineff_from_db_) + pixel_inefficiency_db(detID); + else + pixel_inefficiency(subdetEfficiencies_, pixdet, tTopo); + } + + if (use_module_killing_) { + if (use_deadmodule_DB_) // remove dead modules using DB + module_killing_DB(detID); + else // remove dead modules using the list in cfg file + module_killing_conf(detID); + } + make_digis(theThresholdInE, detID, digis, simlinks, tTopo); + + LogDebug("PSSDigitizerAlgorithm") << "[PSSDigitizerAlgorithm] converted " + << digis.size() << " PixelDigis in DetUnit" + << detID; +} diff --git a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc new file mode 100644 index 0000000000000..c05b64145c719 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc @@ -0,0 +1,259 @@ +// +// +// Package: Phase2TrackerDigitizer +// Class: Phase2TrackerDigitizer +// +// *\class SiPhase2TrackerDigitizer Phase2TrackerDigitizer.cc SimTracker/SiPhase2Digitizer/src/Phase2TrackerDigitizer.cc +// +// Description: +// +// Implementation: +// +// + +#include +#include +#include +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h" +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h" +#include "SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h" +#include "SimDataFormats/TrackingHit/interface/PSimHit.h" +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Framework/interface/EDProducer.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "DataFormats/Common/interface/DetSet.h" +#include "DataFormats/Common/interface/DetSetVector.h" +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "DataFormats/SiPixelDigi/interface/PixelDigiCollection.h" +#include "DataFormats/SiPixelDetId/interface/PXBDetId.h" +#include "DataFormats/SiPixelDetId/interface/PXFDetId.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" +#include "DataFormats/GeometryVector/interface/LocalPoint.h" +#include "DataFormats/GeometryVector/interface/LocalVector.h" +#include "Geometry/CommonDetUnit/interface/GeomDetUnit.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/CommonTopologies/interface/PixelTopology.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetType.h" +#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" + +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDAnalyzer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" + +#include "MagneticField/Engine/interface/MagneticField.h" +#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "SimGeneral/MixingModule/interface/PileUpEventPrincipal.h" + +// Random Number +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "FWCore/Utilities/interface/RandomNumberGenerator.h" +#include "FWCore/Utilities/interface/Exception.h" +#include "CLHEP/Random/RandomEngine.h" + +namespace cms +{ + const std::string Phase2TrackerDigitizer::InnerPixel = "P2Pixel"; + const std::string Phase2TrackerDigitizer::PixelinPS = "PSP"; + const std::string Phase2TrackerDigitizer::StripinPS = "PSS"; + const std::string Phase2TrackerDigitizer::TwoStrip = "SS"; + + Phase2TrackerDigitizer::Phase2TrackerDigitizer(const edm::ParameterSet& iConfig, edm::EDProducer& mixMod) : + first_(true), + hitsProducer_(iConfig.getParameter("hitsProducer")), + trackerContainers_(iConfig.getParameter >("ROUList")), + geometryType_(iConfig.getParameter("GeometryType")) + { + edm::LogInfo("Phase2TrackerDigitizer") << "Initialize Digitizer Algorithms"; + edm::Service rng; + if (!rng.isAvailable()) { + throw cms::Exception("Configuration") + << "Phase2TrackerDigitizer requires the RandomNumberGeneratorService\n" + "which is not present in the configuration file. You must add the service\n" + "in the configuration file or remove the modules that require it."; + } + rndEngine_ = &(rng->getEngine()); + + // one type of Digi and DigiSimLink suffices + // changes in future: InnerPixel -> Tracker + const std::string alias("simSiPixelDigis"); + mixMod.produces >().setBranchAlias(alias); + mixMod.produces >().setBranchAlias(alias + "siPixelDigiSimLink"); + + // creating algorithm objects and pushing them into the map + algomap_[InnerPixel] = std::unique_ptr(new PixelDigitizerAlgorithm(iConfig, (*rndEngine_))); + algomap_[PixelinPS] = std::unique_ptr(new PSPDigitizerAlgorithm(iConfig, (*rndEngine_))); + algomap_[StripinPS] = std::unique_ptr(new PSSDigitizerAlgorithm(iConfig, (*rndEngine_))); + algomap_[TwoStrip] = std::unique_ptr(new SSDigitizerAlgorithm(iConfig, (*rndEngine_))); + } + Phase2TrackerDigitizer::~Phase2TrackerDigitizer() { + edm::LogInfo("Phase2TrackerDigitizer") << "Destroying the Digitizer"; + } + void + Phase2TrackerDigitizer::accumulatePixelHits(edm::Handle > hSimHits) { + if (hSimHits.isValid()) { + std::set detIds; + std::vector const& simHits = *hSimHits.product(); + for (auto it = simHits.begin(), itEnd = simHits.end(); it != itEnd; ++it) { + unsigned int detId_raw = (*it).detUnitId(); + if (detIds.insert(detId_raw).second) { + // The insert succeeded, so this detector element has not yet been processed. + const std::string algotype = getAlgoType(detId_raw); + Phase2TrackerGeomDetUnit* phase2det = detectorUnits_[detId_raw]; + + // access to magnetic field in global coordinates + GlobalVector bfield = pSetup_->inTesla(phase2det->surface().position()); + LogDebug("PixelDigitizer") << "B-field(T) at " << phase2det->surface().position() << "(cm): " + << pSetup_->inTesla(phase2det->surface().position()); + if (algomap_.find(algotype) != algomap_.end()) + algomap_[algotype]->accumulateSimHits(it, itEnd, phase2det, bfield); + else + edm::LogInfo("Phase2TrackerDigitizer") << "Unsupported algorithm"; + } + } + } + } + + void + Phase2TrackerDigitizer::initializeEvent(edm::Event const& e, edm::EventSetup const& iSetup) { + // Must initialize all the algorithms + for (auto it = algomap_.begin(); it != algomap_.end(); ++it) { + if (first_) { + it->second->init(iSetup); + first_ = false; + } + it->second->initializeEvent(); + } + + iSetup.get().get(geometryType_, pDD_); + iSetup.get().get(pSetup_); + + // FIX THIS! We only need to clear and (re)fill this map when the geometry type IOV changes. Use ESWatcher to determine this. + if (true) { // Replace with ESWatcher + detectorUnits_.clear(); + for (auto iu = pDD_->detUnits().begin(); iu != pDD_->detUnits().end(); ++iu) { + unsigned int detId_raw = (*iu)->geographicalId().rawId(); + DetId detId = DetId(detId_raw); + if (DetId(detId).det() == DetId::Detector::Tracker) { + unsigned int isub = detId.subdetId(); + if (isub == PixelSubdetector::PixelBarrel || isub == PixelSubdetector::PixelEndcap) { + Phase2TrackerGeomDetUnit* pixdet = dynamic_cast(*iu); + assert(pixdet); + detectorUnits_.insert(std::make_pair(detId_raw, pixdet)); + } + } + } + } + } + + void + Phase2TrackerDigitizer::accumulate(edm::Event const& iEvent, edm::EventSetup const& iSetup) { + accumulate_local(iEvent, iSetup); + } + + void + Phase2TrackerDigitizer::accumulate(PileUpEventPrincipal const& iEvent, edm::EventSetup const& iSetup) { + accumulate_local(iEvent, iSetup); + } + + template + void Phase2TrackerDigitizer::accumulate_local(T const& iEvent, edm::EventSetup const& iSetup) { + for (auto it = trackerContainers_.begin(); it != trackerContainers_.end(); ++it) { + edm::Handle > simHits; + edm::InputTag tag(hitsProducer_, *it); + iEvent.getByLabel(tag, simHits); + accumulatePixelHits(simHits); + } + } + void + Phase2TrackerDigitizer::finalizeEvent(edm::Event& iEvent, const edm::EventSetup& iSetup) { + edm::ESHandle tTopoHand; + iSetup.get().get(tTopoHand); + const TrackerTopology* tTopo = tTopoHand.product(); + + std::vector > theDigiVector; + std::vector > theDigiLinkVector; + + for (auto iu = pDD_->detUnits().begin(); iu != pDD_->detUnits().end(); ++iu) { + DetId detId_raw = DetId((*iu)->geographicalId().rawId()); + const std::string algotype = getAlgoType(detId_raw); + if (algomap_.find(algotype) != algomap_.end()) { + edm::DetSet collector((*iu)->geographicalId().rawId()); + edm::DetSet linkcollector((*iu)->geographicalId().rawId()); + algomap_[algotype]->digitize(dynamic_cast((*iu)), + collector.data, + linkcollector.data, + tTopo); + if (collector.data.size() > 0) + theDigiVector.push_back(std::move(collector)); + + if (linkcollector.data.size() > 0) + theDigiLinkVector.push_back(std::move(linkcollector)); + } + else + edm::LogInfo("Phase2TrackerDigitizer") << "Unsupported algorithm"; + } + + // Step C: create collection with the cache vector of DetSet + std::auto_ptr > + output(new edm::DetSetVector(theDigiVector)); + std::auto_ptr > + outputlink(new edm::DetSetVector(theDigiLinkVector)); + + // Step D: write output to file + iEvent.put(output); + iEvent.put(outputlink); + } + + // Fill the StackedTrackerDetId to DetId mapping here + void Phase2TrackerDigitizer::beginRun(edm::Run const& run, edm::EventSetup const& iSetup) { + // Get Stack Geometry information + edm::ESHandle stkgeomHandle; + iSetup.get().get(stkgeomHandle); + stkGeom_ = &(*stkgeomHandle); + for (auto stk = stkGeom_->stacks().begin(); stk != stkGeom_->stacks().end(); ++stk) { + StackedTrackerDetUnit* stackDetUnit = (*stk); + detIdStackDetIdmap_[stackDetUnit->stackMember(0)] = stackDetUnit; + detIdStackDetIdmap_[stackDetUnit->stackMember(1)] = stackDetUnit; + } + } + std::string Phase2TrackerDigitizer::getAlgoType(unsigned int detId_raw) { + DetId detId = DetId(detId_raw); + std::string algotype = ""; + if (detId.det() == DetId::Detector::Tracker) { + // Pixel type explicitly mentioned here + if (detId.subdetId() == PixelSubdetector::PixelBarrel || detId.subdetId() == PixelSubdetector::PixelEndcap) { + if (detIdStackDetIdmap_.find(detId) != detIdStackDetIdmap_.end()) { + StackedTrackerDetId stackDetId = detIdStackDetIdmap_[detId]->Id(); + if (stkGeom_->isPSModule(stackDetId)) { + if (detId == detIdStackDetIdmap_[detId]->stackMember(0)) + algotype = PixelinPS; + else if (detId == detIdStackDetIdmap_[detId]->stackMember(1)) + algotype = StripinPS; + } + else algotype = TwoStrip; + } + else algotype = InnerPixel; + } + } + return algotype; + } +} + +#include "FWCore/Framework/interface/MakerMacros.h" +#include "SimGeneral/MixingModule/interface/DigiAccumulatorMixModFactory.h" + +using cms::Phase2TrackerDigitizer; +DEFINE_DIGI_ACCUMULATOR(Phase2TrackerDigitizer); diff --git a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc new file mode 100644 index 0000000000000..a70d84c5e8cc6 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc @@ -0,0 +1,961 @@ +#include +#include + +#include "SimGeneral/NoiseGenerators/interface/GaussianTailNoiseGenerator.h" + +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" +#include "SimTracker/Common/interface/SiG4UniversalFluctuation.h" +#include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h" + +#include +#include "FWCore/Utilities/interface/RandomNumberGenerator.h" +#include "CLHEP/Random/RandGaussQ.h" +#include "CLHEP/Random/RandFlat.h" + +//#include "PixelIndices.h" +#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" +#include "DataFormats/TrackerCommon/interface/TrackerTopology.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "FWCore/Utilities/interface/Exception.h" +#include "CalibTracker/SiPixelESProducers/interface/SiPixelGainCalibrationOfflineSimService.h" + +#include "DataFormats/DetId/interface/DetId.h" +#include "CondFormats/SiPixelObjects/interface/GlobalPixel.h" +#include "CondFormats/DataRecord/interface/SiPixelQualityRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelFedCablingMapRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelLorentzAngleSimRcd.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingMap.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingTree.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelIndices.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelLorentzAngle.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelQuality.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" +#include "CondFormats/SiPixelObjects/interface/LocalPixel.h" +#include "CondFormats/SiPixelObjects/interface/CablingPathToDetUnit.h" + +#include "CondFormats/SiPixelObjects/interface/SiPixelFrameReverter.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDLink.h" +#include "DataFormats/FEDRawData/interface/FEDNumbering.h" +#include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" +#include "DataFormats/SiPixelDetId/interface/PixelEndcapName.h" + +// Geometry +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/CommonTopologies/interface/PixelTopology.h" + +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" + +using namespace edm; +using namespace sipixelobjects; + +Phase2TrackerDigitizerAlgorithm::Phase2TrackerDigitizerAlgorithm(const edm::ParameterSet& conf_common, + const edm::ParameterSet& conf_specific, + CLHEP::HepRandomEngine& eng): + _signal(), + makeDigiSimLinks_(conf_specific.getUntrackedParameter("makeDigiSimLinks", true)), + use_ineff_from_db_(conf_specific.getParameter("Inefficiency_DB")), + use_module_killing_(conf_specific.getParameter("KillModules")), // boolean to kill or not modules + use_deadmodule_DB_(conf_specific.getParameter("DeadModules_DB")), // boolean to access dead modules from DB + use_LorentzAngle_DB_(conf_specific.getParameter("LorentzAngle_DB")), // boolean to access Lorentz angle from DB + + DeadModules(use_deadmodule_DB_ ? Parameters() : conf_specific.getParameter("DeadModules")), // get dead module from cfg file + + // Common pixel parameters + // These are parameters which are not likely to be changed + GeVperElectron(3.61E-09), // 1 electron(3.61eV, 1keV(277e, mod 9/06 d.k. + alpha2Order(conf_specific.getParameter("Alpha2Order")), // switch on/off of E.B effect + addXtalk(conf_specific.getParameter("AddXTalk")), + interstripCoupling(conf_specific.getParameter("InterstripCoupling")), // Interstrip Coupling + + Sigma0(conf_specific.getParameter("SigmaZero")), // Charge diffusion constant 7->3.7 + SigmaCoeff(conf_specific.getParameter("SigmaCoeff")), // delta in the diffusion across the strip pitch + // (set between 0 to 0.9, 0-->flat Sigma0, 1-->Sigma_min=0 & Sigma_max=2*Sigma0 + // D.B.: Dist300 replaced by moduleThickness, may not work with partially depleted sensors but works otherwise + // Dist300(0.0300), // normalized to 300micron Silicon + + ClusterWidth(conf_specific.getParameter("ClusterWidth")), // Charge integration spread on the collection plane + + doDigitalReadout(conf_specific.getParameter("DigitalReadout")), // Flag to decide analog or digital readout + // ADC calibration 1adc count(135e. + // Corresponds to 2adc/kev, 270[e/kev]/135[e/adc](2[adc/kev] + // Be careful, this parameter is also used in SiPixelDet.cc to + // calculate the noise in adc counts from noise in electrons. + // Both defaults should be the same. + theElectronPerADC(conf_common.getParameter("ElectronPerAdc")), + + // ADC saturation value, 255(8bit adc. + theAdcFullScale(conf_common.getParameter("AdcFullScale")), + + // Noise in electrons: + // Pixel cell noise, relevant for generating noisy pixels + theNoiseInElectrons(conf_specific.getParameter("NoiseInElectrons")), + + // Fill readout noise, including all readout chain, relevant for smearing + theReadoutNoise(conf_specific.getParameter("ReadoutNoiseInElec")), + + // Threshold in units of noise: + // thePixelThreshold(conf.getParameter("ThresholdInNoiseUnits")), + // Pixel threshold in electron units. + theThresholdInE_Endcap(conf_specific.getParameter("ThresholdInElectrons_Endcap")), + theThresholdInE_Barrel(conf_specific.getParameter("ThresholdInElectrons_Barrel")), + + // Add threshold gaussian smearing: + theThresholdSmearing_Endcap(conf_specific.getParameter("ThresholdSmearing_Endcap")), + theThresholdSmearing_Barrel(conf_specific.getParameter("ThresholdSmearing_Barrel")), + + // theTofCut 12.5, cut in particle TOD +/- 12.5ns + theTofLowerCut(conf_specific.getParameter("TofLowerCut")), + theTofUpperCut(conf_specific.getParameter("TofUpperCut")), + + // Get the Lorentz angle from the cfg file: + tanLorentzAnglePerTesla_Endcap(use_LorentzAngle_DB_ ? 0.0 : conf_specific.getParameter("TanLorentzAnglePerTesla_Endcap")), + tanLorentzAnglePerTesla_Barrel(use_LorentzAngle_DB_ ? 0.0 : conf_specific.getParameter("TanLorentzAnglePerTesla_Barrel")), + + // Add noise + addNoise(conf_specific.getParameter("AddNoise")), + + // Add noisy pixels + addNoisyPixels(conf_specific.getParameter("AddNoisyPixels")), + + // Fluctuate charge in track subsegments + fluctuateCharge(conf_specific.getUntrackedParameter("FluctuateCharge",true)), + + // Control the pixel inefficiency + AddPixelInefficiency(conf_specific.getParameter("AddInefficiency")), + + // Add threshold gaussian smearing: + addThresholdSmearing(conf_specific.getParameter("AddThresholdSmearing")), + + // Add some pseudo-red damage + pseudoRadDamage(conf_specific.exists("PseudoRadDamage")?conf_specific.getParameter("PseudoRadDamage"):double(0.0)), + pseudoRadDamageRadius(conf_specific.exists("PseudoRadDamageRadius")?conf_specific.getParameter("PseudoRadDamageRadius"):double(0.0)), + + // delta cutoff in MeV, has to be same as in OSCAR(0.030/cmsim=1.0 MeV + // tMax(0.030), // In MeV. + // tMax(conf.getUntrackedParameter("DeltaProductionCut",0.030)), + tMax(conf_common.getParameter("DeltaProductionCut")), + + fluctuate(fluctuateCharge ? new SiG4UniversalFluctuation(eng) : 0), + theNoiser(addNoise ? new GaussianTailNoiseGenerator(eng) : 0), + theSiPixelGainCalibrationService_(use_ineff_from_db_ ? new SiPixelGainCalibrationOfflineSimService(conf_specific) : 0), + subdetEfficiencies_(conf_specific), + flatDistribution_((addNoise || AddPixelInefficiency || fluctuateCharge || addThresholdSmearing) ? new CLHEP::RandFlat(eng, 0., 1.) : 0), + gaussDistribution_((addNoise || AddPixelInefficiency || fluctuateCharge || addThresholdSmearing) ? new CLHEP::RandGaussQ(eng, 0., theReadoutNoise) : 0), + // Threshold smearing with gaussian distribution: + smearedThreshold_Endcap_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_Endcap , theThresholdSmearing_Endcap) : 0), + smearedThreshold_Barrel_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_Barrel , theThresholdSmearing_Barrel) : 0) +{ + LogInfo("Phase2TrackerDigitizerAlgorithm") << "Phase2TrackerDigitizerAlgorithm constructed\n" + << "Configuration parameters:\n" + << "Threshold/Gain = " + << "threshold in electron Endcap = " + << theThresholdInE_Endcap + << "\nthreshold in electron Barrel = " + << theThresholdInE_Barrel + << " " << theElectronPerADC << " " << theAdcFullScale + << " The delta cut-off is set to " << tMax + << " pix-inefficiency " << AddPixelInefficiency; +} + +Phase2TrackerDigitizerAlgorithm::~Phase2TrackerDigitizerAlgorithm() { + LogDebug("Phase2TrackerDigitizerAlgorithm") << "Phase2TrackerDigitizerAlgorithm deleted"; +} + +Phase2TrackerDigitizerAlgorithm::SubdetEfficiencies::SubdetEfficiencies(const edm::ParameterSet& conf) { + barrel_efficiencies = conf.getParameter< std::vector >("EfficiencyFactors_Barrel"); + endcap_efficiencies = conf.getParameter< std::vector >("EfficiencyFactors_Endcap"); +} +// ================================================================= +// +// Generate primary ionization along the track segment. +// Divide the track into small sub-segments +// +// ================================================================= +void Phase2TrackerDigitizerAlgorithm::primary_ionization(const PSimHit& hit, + std::vector& ionization_points) const { + // Straight line approximation for trajectory inside active media + const float SegmentLength = 0.0010; // 10microns in cm + float energy; + + // Get the 3D segment direction vector + LocalVector direction = hit.exitPoint() - hit.entryPoint(); + + float eLoss = hit.energyLoss(); // Eloss in GeV + float length = direction.mag(); // Track length in Silicon + + int NumberOfSegments = int (length / SegmentLength); // Number of segments + if (NumberOfSegments < 1) NumberOfSegments = 1; + LogDebug("Phase2TrackerDigitizerAlgorithm") + << "enter primary_ionzation " << NumberOfSegments + << " shift = " + << hit.exitPoint().x() - hit.entryPoint().x() << " " + << hit.exitPoint().y() - hit.entryPoint().y() << " " + << hit.exitPoint().z() - hit.entryPoint().z() << " " + << hit.particleType() + << " " << hit.pabs(); + + float* elossVector = new float[NumberOfSegments]; // Eloss vector + + if (fluctuateCharge) { + int pid = hit.particleType(); + // int pid=211; // assume it is a pion + + float momentum = hit.pabs(); + // Generate fluctuated charge points + fluctuateEloss(pid, momentum, eLoss, length, NumberOfSegments, elossVector); + } + ionization_points.resize(NumberOfSegments); // set size + + // loop over segments + for (int i = 0; i != NumberOfSegments; ++i) { + // Divide the segment into equal length subsegments + Local3DPoint point = hit.entryPoint() + float((i+0.5)/NumberOfSegments) * direction; + if (fluctuateCharge) + energy = elossVector[i]/GeVperElectron; // Convert charge to elec. + else + energy = hit.energyLoss()/GeVperElectron/float(NumberOfSegments); + + DigitizerUtility::EnergyDepositUnit edu(energy, point); // define position,energy point + ionization_points[i] = edu; // save + + LogDebug ("Phase2 Digitizer") + << i << " " << ionization_points[i].x() << " " + << ionization_points[i].y() << " " + << ionization_points[i].z() << " " + << ionization_points[i].energy(); + } + delete [] elossVector; +} +//============================================================================== +// +// Fluctuate the charge comming from a small (10um) track segment. +// Use the G4 routine. For mip pions for the moment. +// +//============================================================================== +void Phase2TrackerDigitizerAlgorithm::fluctuateEloss(int pid, + float particleMomentum, + float eloss, + float length, + int NumberOfSegs, + float elossVector[]) const { + + // Get dedx for this track + //float dedx; + //if( length > 0.) dedx = eloss/length; + //else dedx = eloss; + + double particleMass = 139.6; // Mass in MeV, Assume pion + pid = std::abs(pid); + if (pid != 211) { // Mass in MeV + if (pid == 11) particleMass = 0.511; + else if (pid == 13) particleMass = 105.7; + else if (pid == 321) particleMass = 493.7; + else if (pid == 2212) particleMass = 938.3; + } + // What is the track segment length. + float segmentLength = length/NumberOfSegs; + + // Generate charge fluctuations. + float de = 0.; + float sum = 0.; + double segmentEloss = (1000. * eloss)/NumberOfSegs; //eloss in MeV + for (int i = 0; i < NumberOfSegs; ++i) { + // material,*, momentum,energy,*, *, mass + //myglandz_(14.,segmentLength,2.,2.,dedx,de,0.14); + // The G4 routine needs momentum in MeV, mass in Mev, delta-cut in MeV, + // track segment length in mm, segment eloss in MeV + // Returns fluctuated eloss in MeV + double deltaCutoff = tMax; // the cutoff is sometimes redefined inside, so fix it. + de = fluctuate->SampleFluctuations(double(particleMomentum*1000.), + particleMass, deltaCutoff, + double(segmentLength*10.), + segmentEloss )/1000.; //convert to GeV + elossVector[i] = de; + sum += de; + } + if (sum > 0.) { // If fluctuations give eloss>0. + // Rescale to the same total eloss + float ratio = eloss/sum; + for (int ii = 0; ii < NumberOfSegs; ++ii) elossVector[ii] = ratio*elossVector[ii]; + } + else { // If fluctuations gives 0 eloss + float averageEloss = eloss/NumberOfSegs; + for (int ii = 0; ii < NumberOfSegs; ++ii) elossVector[ii] = averageEloss; + } +} + +// ====================================================================== +// +// Drift the charge segments to the sensor surface (collection plane) +// Include the effect of E-field and B-field +// +// ===================================================================== +void Phase2TrackerDigitizerAlgorithm::drift(const PSimHit& hit, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield, + const std::vector& ionization_points, + std::vector& collection_points) const { + LogDebug("Phase2TrackerDigitizerAlgorithm") << "enter drift "; + + collection_points.resize(ionization_points.size()); // set size + LocalVector driftDir = DriftDirection(pixdet, bfield, hit.detUnitId()); // get the charge drift direction + if (driftDir.z() == 0.) { + LogWarning("Magnetic field") << " pxlx: drift in z is zero "; + return; + } + + float TanLorenzAngleX, + TanLorenzAngleY, + dir_z, + CosLorenzAngleX, + CosLorenzAngleY; + if (alpha2Order) { + TanLorenzAngleX = driftDir.x(); // tangen of Lorentz angle + TanLorenzAngleY = driftDir.y(); + dir_z = driftDir.z(); // The z drift direction + CosLorenzAngleX = 1./std::sqrt(1. + TanLorenzAngleX * TanLorenzAngleX); // cosine + CosLorenzAngleY = 1./std::sqrt(1. + TanLorenzAngleY * TanLorenzAngleY); // cosine; + } + else { + TanLorenzAngleX = driftDir.x(); + TanLorenzAngleY = 0.; // force to 0, driftDir.y()/driftDir.z(); + dir_z = driftDir.z(); // The z drift direction + CosLorenzAngleX = 1./std::sqrt(1. + TanLorenzAngleX * TanLorenzAngleX); // cosine to estimate the path length + CosLorenzAngleY = 1.; + } + + float moduleThickness = pixdet->specificSurface().bounds().thickness(); + float stripPitch = pixdet->specificTopology().pitch().first; + + LogDebug("Phase2TrackerDigitizerAlgorithm") + << " Lorentz Tan " << TanLorenzAngleX << " " << TanLorenzAngleY <<" " + << CosLorenzAngleX << " " << CosLorenzAngleY << " " + << moduleThickness*TanLorenzAngleX << " " << driftDir; + + float Sigma_x = 1.; // Charge spread + float Sigma_y = 1.; + float DriftDistance; // Distance between charge generation and collection + float DriftLength; // Actual Drift Lentgh + float Sigma; + + for (unsigned int i = 0; i != ionization_points.size(); ++i) { + float SegX, SegY, SegZ; // position + SegX = ionization_points[i].x(); + SegY = ionization_points[i].y(); + SegZ = ionization_points[i].z(); + + // Distance from the collection plane + // DriftDistance = (moduleThickness/2. + SegZ); // Drift to -z + // Include explixitely the E drift direction (for CMS dir_z=-1) + DriftDistance = moduleThickness/2. - (dir_z * SegZ); // Drift to -z + + if (DriftDistance < 0.) + DriftDistance = 0.; + else if (DriftDistance > moduleThickness) + DriftDistance = moduleThickness; + + // Assume full depletion now, partial depletion will come later. + float XDriftDueToMagField = DriftDistance * TanLorenzAngleX; + float YDriftDueToMagField = DriftDistance * TanLorenzAngleY; + + // Shift cloud center + float CloudCenterX = SegX + XDriftDueToMagField; + float CloudCenterY = SegY + YDriftDueToMagField; + + // Calculate how long is the charge drift path + DriftLength = std::sqrt(DriftDistance*DriftDistance + + XDriftDueToMagField*XDriftDueToMagField + + YDriftDueToMagField*YDriftDueToMagField); + + // What is the charge diffusion after this path + // Sigma0=0.00037 is for 300um thickness (make sure moduleThickness is in [cm]) + Sigma = std::sqrt(DriftLength/moduleThickness) * (Sigma0 * moduleThickness/0.0300); + // D.B.: sigmaCoeff=0 means no modulation + if (SigmaCoeff) Sigma *= (SigmaCoeff * cos(SegX*M_PI/stripPitch) * cos(SegX*M_PI/stripPitch) + 1); + // NB: divided by 4 to get a periodicity of stripPitch + + // Project the diffusion sigma on the collection plane + Sigma_x = Sigma / CosLorenzAngleX; + Sigma_y = Sigma / CosLorenzAngleY; + + // Insert a charge loss due to Rad Damage here + float energyOnCollector = ionization_points[i].energy(); // The energy that reaches the collector + + // pseudoRadDamage + if (pseudoRadDamage >= 0.001) { + float moduleRadius = pixdet->surface().position().perp(); + if (moduleRadius <= pseudoRadDamageRadius) { + float kValue = pseudoRadDamage/(moduleRadius * moduleRadius); + energyOnCollector = energyOnCollector * exp(-1 * kValue * DriftDistance/moduleThickness); + } + } + LogDebug("Phase2TrackerDigitizerAlgorithm") + << "Dift DistanceZ = " << DriftDistance << " module thickness = " << moduleThickness + << " Start Energy = " <pitch().first << " " << topol->pitch().second; //OK + + // local map to store pixels hit by 1 Hit. + typedef std::map > hit_map_type; + hit_map_type hit_signal; + + // map to store pixel integrals in the x and in the y directions + std::map > x,y; + + // Assign signals to readout channels and store sorted by channel number + int iseg = 0; + float ESum = 0.0; + + // Iterate over collection points on the collection plane + for (auto i = collection_points.begin(); i != collection_points.end(); ++i) { + iseg++; + float CloudCenterX = i->position().x(); // Charge position in x + float CloudCenterY = i->position().y(); // in y + float SigmaX = i->sigma_x(); // Charge spread in x + float SigmaY = i->sigma_y(); // in y + float Charge = i->amplitude(); // Charge amplitude + + LogDebug ("Phase2TrackerDigitizerAlgorithm") + << " cloud " << i->position().x() << " " << i->position().y() << " " + << i->sigma_x() << " " << i->sigma_y() << " " << i->amplitude(); + + // Find the maximum cloud spread in 2D plane , assume 3*sigma + float CloudRight = CloudCenterX + ClusterWidth * SigmaX; + float CloudLeft = CloudCenterX - ClusterWidth * SigmaX; + float CloudUp = CloudCenterY + ClusterWidth * SigmaY; + float CloudDown = CloudCenterY - ClusterWidth * SigmaY; + + // Define 2D cloud limit points + LocalPoint PointRightUp = LocalPoint(CloudRight,CloudUp); + LocalPoint PointLeftDown = LocalPoint(CloudLeft,CloudDown); + + // This points can be located outside the sensor area. + // The conversion to measurement point does not check for that + // so the returned pixel index might be wrong (outside range). + // We rely on the limits check below to fix this. + // But remember whatever we do here THE CHARGE OUTSIDE THE ACTIVE + // PIXEL ARE IS LOST, it should not be collected. + + // Convert the 2D points to pixel indices + MeasurementPoint mp = topol->measurementPosition(PointRightUp ); //OK + + int IPixRightUpX = int(floor( mp.x())); + int IPixRightUpY = int(floor( mp.y())); + + LogDebug ("Phase2TrackerDigitizerAlgorithm") << " right-up " << PointRightUp << " " + << mp.x() << " " << mp.y() << " " + << IPixRightUpX << " " << IPixRightUpY ; + + mp = topol->measurementPosition(PointLeftDown ); //OK + + int IPixLeftDownX = int(floor( mp.x())); + int IPixLeftDownY = int(floor( mp.y())); + + LogDebug("Phase2TrackerDigitizerAlgorithm") << " left-down " << PointLeftDown << " " + << mp.x() << " " << mp.y() << " " + << IPixLeftDownX << " " << IPixLeftDownY ; + + // Check detector limits to correct for pixels outside range. + int numColumns = topol->ncolumns(); // det module number of cols&rows + int numRows = topol->nrows(); + + IPixRightUpX = numRows > IPixRightUpX ? IPixRightUpX : numRows-1; + IPixRightUpY = numColumns > IPixRightUpY ? IPixRightUpY : numColumns-1; + IPixLeftDownX = 0 < IPixLeftDownX ? IPixLeftDownX : 0; + IPixLeftDownY = 0 < IPixLeftDownY ? IPixLeftDownY : 0; + + x.clear(); // clear temporary integration array + y.clear(); + + // First integrate cahrge strips in x + int ix; // TT for compatibility + for (ix = IPixLeftDownX; ix <= IPixRightUpX; ix++) { // loop over x index + float xUB, xLB, UpperBound, LowerBound; + + // Why is set to 0 if ix=0, does it meen that we accept charge + // outside the sensor? + if (ix == 0 || SigmaX==0.) // skip for surface segemnts + LowerBound = 0.; + else { + mp = MeasurementPoint( float(ix), 0.0); + xLB = topol->localPosition(mp).x(); + LowerBound = 1-calcQ((xLB-CloudCenterX)/SigmaX); + } + + if (ix == numRows-1 || SigmaX == 0.) + UpperBound = 1.; + else { + mp = MeasurementPoint(float(ix+1), 0.0); + xUB = topol->localPosition(mp).x(); + UpperBound = 1. - calcQ((xUB-CloudCenterX)/SigmaX); + } + float TotalIntegrationRange = UpperBound - LowerBound; // get strip + x[ix] = TotalIntegrationRange; // save strip integral + } + + // Now integarte strips in y + int iy; // TT for compatibility + for (iy = IPixLeftDownY; iy <= IPixRightUpY; iy++) { //loope over y ind + float yUB, yLB, UpperBound, LowerBound; + + if (iy == 0 || SigmaY==0.) + LowerBound = 0.; + else { + mp = MeasurementPoint(0.0, float(iy)); + yLB = topol->localPosition(mp).y(); + LowerBound = 1. - calcQ((yLB-CloudCenterY)/SigmaY); + } + + if (iy == numColumns-1 || SigmaY==0. ) + UpperBound = 1.; + else { + mp = MeasurementPoint(0.0, float(iy+1)); + yUB = topol->localPosition(mp).y(); + UpperBound = 1. - calcQ((yUB-CloudCenterY)/SigmaY); + } + + float TotalIntegrationRange = UpperBound - LowerBound; + y[iy] = TotalIntegrationRange; // save strip integral + } + + // Get the 2D charge integrals by folding x and y strips + int chan; + for (ix = IPixLeftDownX; ix <= IPixRightUpX; ix++) { // loop over x index + for (iy = IPixLeftDownY; iy <= IPixRightUpY; iy++) { //loope over y ind + float ChargeFraction = Charge*x[ix]*y[iy]; + if (ChargeFraction > 0.) { + chan = Phase2TrackerDigi::pixelToChannel(ix, iy); // Get index + // Load the amplitude + hit_signal[chan] += ChargeFraction; + } + + mp = MeasurementPoint(float(ix), float(iy)); + LocalPoint lp = topol->localPosition(mp); + chan = topol->channel(lp); + + LogDebug("Phase2TrackerDigitizerAlgorithm") + << " pixel " << ix << " " << iy << " - "<<" " + << chan << " " << ChargeFraction<<" " + << mp.x() << " " << mp.y() <<" " + << lp.x() << " " << lp.y() << " " // givex edge position + << chan; // edge belongs to previous ? + ESum += ChargeFraction; + } + } + } + // Fill the global map with all hit pixels from this event + for (auto im = hit_signal.begin();im != hit_signal.end(); ++im) { + int chan = (*im).first; + theSignal[chan] += (makeDigiSimLinks_ ? DigitizerUtility::Amplitude( (*im).second, &hit, (*im).second) : DigitizerUtility::Amplitude( (*im).second, (*im).second)); + } +} + +//***********************************************************************/ +// +// Build pixels, check threshold, add misscalibration, ... +// +//***********************************************************************/ +void Phase2TrackerDigitizerAlgorithm::make_digis(float theThresholdInE, + uint32_t detID, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology *tTopo) const { + LogDebug("Phase2TrackerDigitizerAlgorithm") << " make digis "<<" " + << " pixel threshold Endcap" << theThresholdInE_Endcap << " " + << " pixel threshold Barrel" << theThresholdInE_Barrel << " " + << " List pixels passing threshold "; + // Loop over hit pixels + auto it = _signal.find(detID); + if (it == _signal.end()) return; + + const signal_map_type& theSignal = (*it).second; + for (auto i = theSignal.begin(); i != theSignal.end(); ++i) { + float signalInElectrons = (*i).second.ampl() ; // signal in electrons + + // Do only for pixels above threshold + if (signalInElectrons >= theThresholdInE) { // check threshold + int chan = (*i).first; // channel number + std::pair ip = Phase2TrackerDigi::channelToPixel(chan); + + int adc = 0; + + LogDebug("Phase2TrackerDigitizerAlgorithm") + << (*i).first << " " << (*i).second << " " << signalInElectrons + << " " << adc << ip.first << " " << ip.second ; + if (doDigitalReadout) adc = theAdcFullScale; + else adc = int(signalInElectrons / theElectronPerADC); + // Load digis + digis.emplace_back(ip.first, ip.second, adc); + if (makeDigiSimLinks_ && (*i).second.hitInfo() != 0) { + // digilink + if ((*i).second.trackIds().size() >0 ) { + simlink_map simi; + unsigned int il = 0; + for (auto itid = (*i).second.trackIds().begin(); + itid != (*i).second.trackIds().end(); ++itid) { + simi[*itid].push_back((*i).second.individualampl()[il]); + il++; + } + // sum the contribution of the same trackid + for (auto simiiter=simi.begin(); simiiter!=simi.end(); simiiter++) { + float sum_samechannel = 0; + for (unsigned int iii = 0; iii < (*simiiter).second.size(); iii++) { + sum_samechannel += (*simiiter).second[iii]; + } + float fraction = sum_samechannel/(*i).second; + if (fraction>1.) fraction = 1.; + simlinks.emplace_back((*i).first, (*simiiter).first, (*i).second.eventId(), fraction); + } + } + } + } + } +} + +// ====================================================================== +// +// Add electronic noise to pixel charge +// +// ====================================================================== +void Phase2TrackerDigitizerAlgorithm::add_noise(const Phase2TrackerGeomDetUnit* pixdet, + float thePixelThreshold) { + LogDebug("Phase2TrackerDigitizerAlgorithm") << " enter add_noise " << theNoiseInElectrons; + uint32_t detID = pixdet->geographicalId().rawId(); + signal_map_type& theSignal = _signal[detID]; + const Phase2TrackerTopology* topol=&pixdet->specificTopology(); + int numColumns = topol->ncolumns(); // det module number of cols&rows + int numRows = topol->nrows(); + + // First add Readout noise to hit cells + for (auto i = theSignal.begin(); i != theSignal.end(); i++) { + float noise = gaussDistribution_->fire(); + if (((*i).second.ampl() + noise) < 0.) + (*i).second.set(0); + else + (*i).second += noise; + } + + if (addXtalk) { + signal_map_type signalNew; + for (auto i = theSignal.begin(); i != theSignal.end(); i++) { + float signalInElectrons = (*i).second.ampl(); // signal in electrons + std::pair hitChan = Phase2TrackerDigi::channelToPixel((*i).first); + + float signalInElectrons_Xtalk = signalInElectrons * interstripCoupling; + + if (hitChan.first != 0) { + std::pair XtalkPrev = std::pair(hitChan.first-1, hitChan.second); + int chanXtalkPrev = Phase2TrackerDigi::pixelToChannel(XtalkPrev.first, XtalkPrev.second); + signalNew.insert(std::pair(chanXtalkPrev, DigitizerUtility::Amplitude (signalInElectrons_Xtalk, -1.0))); + } + if (hitChan.first < (numRows-1)) { + std::pair XtalkNext = std::pair(hitChan.first+1, hitChan.second); + int chanXtalkNext = Phase2TrackerDigi::pixelToChannel(XtalkNext.first, XtalkNext.second); + signalNew.insert(std::pair(chanXtalkNext, DigitizerUtility::Amplitude (signalInElectrons_Xtalk, -1.0))); + } + } + for (auto l = signalNew.begin(); l != signalNew.end(); l++) { + int chan = l->first; + auto iter = theSignal.find(chan); + if (iter != theSignal.end()) + theSignal[chan] += l->second.ampl(); + else + theSignal.insert(std::pair(chan, DigitizerUtility::Amplitude(l->second.ampl(),-1.0))); + } + } + if (!addNoisyPixels) // Option to skip noise in non-hit pixels + return; + + // Add noise on non-hit pixels + // Use here the pixel noise + int numberOfPixels = numRows * numColumns; + std::map > otherPixels; + std::map >::iterator mapI; + + theNoiser->generate(numberOfPixels, + thePixelThreshold, //thr. in un. of nois + theNoiseInElectrons, // noise in elec. + otherPixels ); + + LogDebug ("Phase2TrackerDigitizerAlgorithm") + << " Add noisy pixels " << numRows << " " + << numColumns << " " << theNoiseInElectrons << " " + << theThresholdInE_Endcap << " " << theThresholdInE_Barrel <<" "<< numberOfPixels<<" " + << otherPixels.size() ; + + // Add noisy pixels + for (mapI = otherPixels.begin(); mapI!= otherPixels.end(); mapI++) { + int iy = ((*mapI).first) / numRows; + int ix = ((*mapI).first) - (iy*numRows); + // Keep for a while for testing. + if( iy < 0 || iy > (numColumns-1) ) + LogWarning ("Pixel Geometry") << " error in iy " << iy ; + if( ix < 0 || ix > (numRows-1) ) + LogWarning ("Pixel Geometry") << " error in ix " << ix ; + + int chan = Phase2TrackerDigi::pixelToChannel(ix, iy); + + LogDebug ("Phase2TrackerDigitizerAlgorithm") + <<" Storing noise = " << (*mapI).first << " " << (*mapI).second + << " " << ix << " " << iy << " " << chan ; + + if (theSignal[chan] == 0) { + int noise = int((*mapI).second); + theSignal[chan] = DigitizerUtility::Amplitude (noise, -1.); + } + } +} + +// ============================================================================ +// +// Simulate the readout inefficiencies. +// Delete a selected number of single pixels, dcols and rocs. +void Phase2TrackerDigitizerAlgorithm::pixel_inefficiency(const SubdetEfficiencies& eff, + const Phase2TrackerGeomDetUnit* pixdet, + const TrackerTopology *tTopo) { + + uint32_t detID = pixdet->geographicalId().rawId(); + + signal_map_type& theSignal = _signal[detID]; // check validity + + // Predefined efficiencies + float subdetEfficiency = 1.0; + + // setup the chip indices conversion + unsigned int Subid=DetId(detID).subdetId(); + if (Subid == PixelSubdetector::PixelBarrel) { // barrel layers + unsigned int layerIndex = tTopo->pxbLayer(detID); + if (layerIndex-1 < eff.barrel_efficiencies.size()) subdetEfficiency = eff.barrel_efficiencies[layerIndex-1]; + else std::cout << layerIndex-1 << " " << eff.barrel_efficiencies.size() << std::endl; + } else { // forward disks + unsigned int diskIndex = 2 * tTopo->pxfDisk(detID) - tTopo->pxfSide(detID); + if (diskIndex-1 < eff.endcap_efficiencies.size()) subdetEfficiency = eff.endcap_efficiencies[diskIndex-1]; + else std::cout << diskIndex-1 << " " << eff.barrel_efficiencies.size() << std::endl; + } + + LogDebug ("Phase2TrackerDigitizerAlgorithm") << " enter pixel_inefficiency " << subdetEfficiency; + + // Now loop again over pixels to kill some of them. + // Loop over hits, amplitude in electrons, channel = coded row,col + for (auto i = theSignal.begin(); i != theSignal.end(); ++i) { + float rand = flatDistribution_->fire(); + if( rand>subdetEfficiency ) { + // make amplitude =0 + i->second.set(0.); // reset amplitude, + } + } +} +// ======================================================================================= +// +// Set the drift direction accoring to the Bfield in local det-unit frame +// Works for both barrel and forward pixels. +// Replace the sign convention to fit M.Swartz's formulaes. +// Configurations for barrel and foward pixels possess different tanLorentzAngleperTesla +// parameter value + +LocalVector Phase2TrackerDigitizerAlgorithm::DriftDirection(const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield, + const DetId& detId) const { + Frame detFrame(pixdet->surface().position(),pixdet->surface().rotation()); + LocalVector Bfield = detFrame.toLocal(bfield); + float alpha2_Endcap; + float alpha2_Barrel; + float alpha2; + + float dir_x = 0.0; + float dir_y = 0.0; + float dir_z = 0.0; + float scale = 0.0; + + uint32_t detID = pixdet->geographicalId().rawId(); + unsigned int Sub_detid = DetId(detID).subdetId(); + + // Read Lorentz angle from cfg file: + if (!use_LorentzAngle_DB_) { + if (alpha2Order) { + alpha2_Endcap = tanLorentzAnglePerTesla_Endcap*tanLorentzAnglePerTesla_Endcap; + alpha2_Barrel = tanLorentzAnglePerTesla_Barrel*tanLorentzAnglePerTesla_Barrel; + } else { + alpha2_Endcap = 0.0; + alpha2_Barrel = 0.0; + } + + if (Sub_detid == PixelSubdetector::PixelBarrel) { // barrel layers + dir_x = -( tanLorentzAnglePerTesla_Barrel * Bfield.y() + alpha2_Barrel* Bfield.z()* Bfield.x() ); + dir_y = +( tanLorentzAnglePerTesla_Barrel * Bfield.x() - alpha2_Barrel* Bfield.z()* Bfield.y() ); + dir_z = -(1 + alpha2_Barrel* Bfield.z()*Bfield.z() ); + scale = (1 + alpha2_Barrel* Bfield.z()*Bfield.z() ); + + } else { // forward disks + dir_x = -( tanLorentzAnglePerTesla_Endcap * Bfield.y() + alpha2_Endcap* Bfield.z()* Bfield.x() ); + dir_y = +( tanLorentzAnglePerTesla_Endcap * Bfield.x() - alpha2_Endcap* Bfield.z()* Bfield.y() ); + dir_z = -(1 + alpha2_Endcap* Bfield.z()*Bfield.z() ); + scale = (1 + alpha2_Endcap* Bfield.z()*Bfield.z() ); + } + } + + // Read Lorentz angle from DB: + if (use_LorentzAngle_DB_) { + float lorentzAngle = SiPixelLorentzAngle_->getLorentzAngle(detId); + alpha2 = lorentzAngle * lorentzAngle; + + dir_x = -( lorentzAngle * Bfield.y() + alpha2 * Bfield.z()* Bfield.x() ); + dir_y = +( lorentzAngle * Bfield.x() - alpha2 * Bfield.z()* Bfield.y() ); + dir_z = -(1 + alpha2 * Bfield.z()*Bfield.z() ); + scale = (1 + alpha2 * Bfield.z()*Bfield.z() ); + } + + LocalVector theDriftDirection = LocalVector(dir_x/scale, dir_y/scale, dir_z/scale ); + + LogDebug ("Phase2TrackerDigitizerAlgorithm") << " The drift direction in local coordinate is " + << theDriftDirection ; + return theDriftDirection; +} + +// ============================================================================= + +void Phase2TrackerDigitizerAlgorithm::pixel_inefficiency_db(uint32_t detID) { + signal_map_type& theSignal = _signal[detID]; // check validity + + // Loop over hit pixels, amplitude in electrons, channel = coded row,col + for (auto i = theSignal.begin();i != theSignal.end(); ++i) { + std::pair ip = Phase2TrackerDigi::channelToPixel(i->first);//get pixel pos + int row = ip.first; // X in row + int col = ip.second; // Y is in col + //transform to ROC index coordinates + if (theSiPixelGainCalibrationService_->isDead(detID, col, row)) { + i->second.set(0.); // reset amplitude, + } + } +} + +// ========================================================================== + +void Phase2TrackerDigitizerAlgorithm::module_killing_conf(uint32_t detID) { + bool isbad = false; + int detid = detID; + auto itDeadModules = DeadModules.begin(); + for (; itDeadModules != DeadModules.end(); ++itDeadModules) { + int Dead_detID = itDeadModules->getParameter("Dead_detID"); + if (detid == Dead_detID){ + isbad = true; + break; + } + } + + if (!isbad) + return; + + signal_map_type& theSignal = _signal[detID]; // check validity + + std::string Module = itDeadModules->getParameter("Module"); + + if (Module == "whole"){ + for (auto i = theSignal.begin(); i != theSignal.end(); ++i) { + i->second.set(0.); // reset amplitude + } + } + + for (auto i = theSignal.begin(); i != theSignal.end(); ++i) { + std::pair ip = Phase2TrackerDigi::channelToPixel(i->first);//get pixel pos + + if (Module == "tbmA" && ip.first >= 80 && ip.first <= 159) + i->second.set(0.); + + if (Module == "tbmB" && ip.first <= 79) + i->second.set(0.); + } +} +// ========================================================================== +void Phase2TrackerDigitizerAlgorithm::module_killing_DB(uint32_t detID) { + bool isbad = false; + + std::vectordisabledModules = SiPixelBadModule_->getBadComponentList(); + + SiPixelQuality::disabledModuleType badmodule; + for (size_t id = 0;id < disabledModules.size(); id++) { + if (detID == disabledModules[id].DetID) { + isbad = true; + badmodule = disabledModules[id]; + break; + } + } + + if (!isbad) + return; + + signal_map_type& theSignal = _signal[detID]; // check validity + + if (badmodule.errorType == 0) { // this is a whole dead module. + for (auto i = theSignal.begin(); i != theSignal.end(); ++i) { + i->second.set(0.); // reset amplitude + } + } + else { // all other module types: half-modules and single ROCs. + // Get Bad ROC position: + // follow the example of getBadRocPositions in CondFormats/SiPixelObjects/src/SiPixelQuality.cc + std::vector badrocpositions (0); + for (unsigned int j = 0; j < 16; j++) { + if (SiPixelBadModule_->IsRocBad(detID, j) == true) { + std::vector path = map_.product()->pathToDetUnit(detID); + for (auto it = path.begin(); it != path.end(); ++it) { + const PixelROC* myroc = map_.product()->findItem(*it); + if (myroc->idInDetUnit() == j) { + LocalPixel::RocRowCol local = {39, 25}; //corresponding to center of ROC row, col + GlobalPixel global = myroc->toGlobal(LocalPixel(local)); + badrocpositions.push_back(global); + break; + } + } + } + } + + for (auto i = theSignal.begin();i != theSignal.end(); ++i) { + std::pair ip = Phase2TrackerDigi::channelToPixel(i->first);//get pixel pos + + for (auto it = badrocpositions.begin(); it != badrocpositions.end(); ++it) { + if (it->row >= 80 && ip.first >= 80) { + if ((fabs(ip.second - it->col) < 26) ) {i->second.set(0.);} + else if (it->row == 120 && ip.second-it->col == 26) {i->second.set(0.);} + else if (it->row == 119 && it->col-ip.second == 26) {i->second.set(0.);} + } + else if (it->row < 80 && ip.first < 80 ) { + if ((fabs(ip.second - it->col) < 26) ) {i->second.set(0.);} + else if(it->row == 40 && ip.second-it->col == 26) {i->second.set(0.);} + else if(it->row == 39 && it->col-ip.second == 26) {i->second.set(0.);} + } + } + } + } +} diff --git a/SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc new file mode 100644 index 0000000000000..a5006ae881f63 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc @@ -0,0 +1,183 @@ +#include +#include + +#include "SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h" +#include "SimTracker/Common/interface/SiG4UniversalFluctuation.h" +#include "SimGeneral/NoiseGenerators/interface/GaussianTailNoiseGenerator.h" + +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" +#include "DataFormats/TrackerCommon/interface/TrackerTopology.h" +#include "DataFormats/DetId/interface/DetId.h" +#include "DataFormats/FEDRawData/interface/FEDNumbering.h" +#include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" +#include "DataFormats/SiPixelDetId/interface/PixelEndcapName.h" + +#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" + +#include +#include "FWCore/Utilities/interface/RandomNumberGenerator.h" +#include "CLHEP/Random/RandGaussQ.h" +#include "CLHEP/Random/RandFlat.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "FWCore/Utilities/interface/Exception.h" +#include "CalibTracker/SiPixelESProducers/interface/SiPixelGainCalibrationOfflineSimService.h" + +#include "CondFormats/SiPixelObjects/interface/GlobalPixel.h" +#include "CondFormats/DataRecord/interface/SiPixelQualityRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelFedCablingMapRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelLorentzAngleSimRcd.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingMap.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingTree.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelIndices.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelLorentzAngle.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelQuality.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" +#include "CondFormats/SiPixelObjects/interface/LocalPixel.h" +#include "CondFormats/SiPixelObjects/interface/CablingPathToDetUnit.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFrameReverter.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDLink.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" + +// Geometry +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/CommonTopologies/interface/PixelTopology.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +using namespace edm; +using namespace sipixelobjects; + +void PixelDigitizerAlgorithm::init(const edm::EventSetup& es) { + if (use_ineff_from_db_) // load gain calibration service fromdb... + theSiPixelGainCalibrationService_->setESObjects(es); + + if (use_deadmodule_DB_) + es.get().get(SiPixelBadModule_); + + if (use_LorentzAngle_DB_) // Get Lorentz angle from DB record + es.get().get(SiPixelLorentzAngle_); + + // gets the map and geometry from the DB (to kill ROCs) + es.get().get(map_); + es.get().get(geom_); +} + +PixelDigitizerAlgorithm::PixelDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine& eng) : + Phase2TrackerDigitizerAlgorithm(conf.getParameter("AlgorithmCommon"), + conf.getParameter("PixelDigitizerAlgorithm"), + eng) +{ + LogInfo("PixelDigitizerAlgorithm ") << "PixelDigitizerAlgorithm constructed " + << "Configuration parameters:" + << "Threshold/Gain = " + << "threshold in electron Endcap = " + << theThresholdInE_Endcap + << "threshold in electron Barrel = " + << theThresholdInE_Barrel + << " " << theElectronPerADC << " " << theAdcFullScale + << " The delta cut-off is set to " << tMax + << " pix-inefficiency "<::const_iterator inputBegin, + std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield) { + // produce SignalPoint's for all SimHit's in detector + // Loop over hits + uint32_t detId = pixdet->geographicalId().rawId(); + for (auto it = inputBegin; it != inputEnd; ++it) { + // skip hits not in this detector. + if ((*it).detUnitId() != detId) + continue; + + LogDebug ("Pixel Digitizer") + << (*it).particleType() << " " << (*it).pabs() << " " + << (*it).energyLoss() << " " << (*it).tof() << " " + << (*it).trackId() << " " << (*it).processType() << " " + << (*it).detUnitId() + << (*it).entryPoint() << " " << (*it).exitPoint() ; + + std::vector ionization_points; + std::vector collection_points; + + // fill collection_points for this SimHit, indpendent of topology + // Check the TOF cut + if (((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) >= theTofLowerCut && + ((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) <= theTofUpperCut) { + primary_ionization(*it, ionization_points); // fills _ionization_points + drift (*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points + + // compute induced signal on readout elements and add to _signal + induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + } + } +} +void PixelDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology *tTopo) +{ + // Pixel Efficiency moved from the constructor to this method because + // the information of the det are not available in the constructor + // Effciency parameters. 0 - no inefficiency, 1-low lumi, 10-high lumi + + uint32_t detID = pixdet->geographicalId().rawId(); + const signal_map_type& theSignal = _signal[detID]; // ** please check detID exists!!! + + const Phase2TrackerTopology* topol = &pixdet->specificTopology(); + int numColumns = topol->ncolumns(); // det module number of cols&rows + int numRows = topol->nrows(); + + // Noise already defined in electrons + // thePixelThresholdInE = thePixelThreshold * theNoiseInElectrons ; + // Find the threshold in noise units, needed for the noiser. + + unsigned int Sub_detid = DetId(detID).subdetId(); + + float theThresholdInE = 0.; + // can we generalize it + if (theNoiseInElectrons > 0.) { + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing + } + } + // full detector thickness + float moduleThickness = pixdet->specificSurface().bounds().thickness(); + LogDebug("PixelDigitizerAlgorithm") + << numColumns << " " << numRows << " " << moduleThickness; + + if (addNoise) add_noise(pixdet, theThresholdInE/theNoiseInElectrons); // generate noise + + // Do only if needed + if (AddPixelInefficiency && theSignal.size() > 0) { + if (use_ineff_from_db_) + pixel_inefficiency_db(detID); + else + pixel_inefficiency(subdetEfficiencies_, pixdet, tTopo); + } + + if (use_module_killing_) { + if (use_deadmodule_DB_) // remove dead modules using DB + module_killing_DB(detID); + else // remove dead modules using the list in cfg file + module_killing_conf(detID); + } + make_digis(theThresholdInE, detID, digis, simlinks, tTopo); + + LogDebug("PixelDigitizerAlgorithm") << "[PixelDigitizerAlgorithm] converted " << digis.size() << " PixelDigis in DetUnit" << detID; +} diff --git a/SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc new file mode 100644 index 0000000000000..1197a7bc70da0 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc @@ -0,0 +1,184 @@ +#include +#include + +#include "SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h" +#include "SimTracker/Common/interface/SiG4UniversalFluctuation.h" +#include "SimGeneral/NoiseGenerators/interface/GaussianTailNoiseGenerator.h" + +#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" +#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" +#include "DataFormats/TrackerCommon/interface/TrackerTopology.h" +#include "DataFormats/DetId/interface/DetId.h" +#include "DataFormats/FEDRawData/interface/FEDNumbering.h" +#include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" +#include "DataFormats/SiPixelDetId/interface/PixelEndcapName.h" + +#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" +#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" + +#include +#include "FWCore/Utilities/interface/RandomNumberGenerator.h" +#include "CLHEP/Random/RandGaussQ.h" +#include "CLHEP/Random/RandFlat.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "FWCore/Utilities/interface/Exception.h" +#include "CalibTracker/SiPixelESProducers/interface/SiPixelGainCalibrationOfflineSimService.h" + +#include "CondFormats/SiPixelObjects/interface/GlobalPixel.h" +#include "CondFormats/DataRecord/interface/SiPixelQualityRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelFedCablingMapRcd.h" +#include "CondFormats/DataRecord/interface/SiPixelLorentzAngleSimRcd.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingMap.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingTree.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFedCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelIndices.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelLorentzAngle.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelQuality.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" +#include "CondFormats/SiPixelObjects/interface/LocalPixel.h" +#include "CondFormats/SiPixelObjects/interface/CablingPathToDetUnit.h" +#include "CondFormats/SiPixelObjects/interface/SiPixelFrameReverter.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDCabling.h" +#include "CondFormats/SiPixelObjects/interface/PixelFEDLink.h" +#include "CondFormats/SiPixelObjects/interface/PixelROC.h" + +// Geometry +#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" +#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" +#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" +#include "Geometry/CommonTopologies/interface/PixelTopology.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +using namespace edm; +using namespace sipixelobjects; + +void SSDigitizerAlgorithm::init(const edm::EventSetup& es) { + if (use_ineff_from_db_) // load gain calibration service fromdb... + theSiPixelGainCalibrationService_->setESObjects( es ); + + if (use_deadmodule_DB_) + es.get().get(SiPixelBadModule_); + + if (use_LorentzAngle_DB_) // Get Lorentz angle from DB record + es.get().get(SiPixelLorentzAngle_); + + // gets the map and geometry from the DB (to kill ROCs) + es.get().get(map_); + es.get().get(geom_); +} +SSDigitizerAlgorithm::SSDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine& eng) : + Phase2TrackerDigitizerAlgorithm(conf.getParameter("AlgorithmCommon"), + conf.getParameter("SSDigitizerAlgorithm"), + eng) +{ + LogInfo("SSDigitizerAlgorithm ") << "SSDigitizerAlgorithm constructed " + << "Configuration parameters:" + << "Threshold/Gain = " + << "threshold in electron Endcap = " + << theThresholdInE_Endcap + << "threshold in electron Barrel = " + << theThresholdInE_Barrel + <<" " << theElectronPerADC << " " << theAdcFullScale + << " The delta cut-off is set to " << tMax + << " pix-inefficiency "<::const_iterator inputBegin, + std::vector::const_iterator inputEnd, + const Phase2TrackerGeomDetUnit* pixdet, + const GlobalVector& bfield) { + // produce SignalPoint's for all SimHit's in detector + // Loop over hits + uint32_t detId = pixdet->geographicalId().rawId(); + for (auto it = inputBegin; it != inputEnd; ++it) { + // skip hits not in this detector. + if ((*it).detUnitId() != detId) + continue; + + LogDebug("SSDigitizerAlgorithm") + << (*it).particleType() << " " << (*it).pabs() << " " + << (*it).energyLoss() << " " << (*it).tof() << " " + << (*it).trackId() << " " << (*it).processType() << " " + << (*it).detUnitId() + << (*it).entryPoint() << " " << (*it).exitPoint() ; + + std::vector ionization_points; + std::vector collection_points; + + // fill collection_points for this SimHit, indpendent of topology + // Check the TOF cut + if (((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) >= theTofLowerCut && + ((*it).tof() - pixdet->surface().toGlobal((*it).localPosition()).mag()/30.) <= theTofUpperCut) { + primary_ionization(*it, ionization_points); // fills _ionization_points + drift(*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points + + // compute induced signal on readout elements and add to _signal + induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + } + } +} +void SSDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, + std::vector& digis, + std::vector& simlinks, + const TrackerTopology* tTopo) { + // Pixel Efficiency moved from the constructor to this method because + // the information of the det are not available in the constructor + // Effciency parameters. 0 - no inefficiency, 1-low lumi, 10-high lumi + + uint32_t detID = pixdet->geographicalId().rawId(); + // check validity before query + const signal_map_type& theSignal = _signal[detID]; + + const Phase2TrackerTopology* topol = &pixdet->specificTopology(); + int numColumns = topol->ncolumns(); // det module number of cols&rows + int numRows = topol->nrows(); + + // Noise already defined in electrons + // thePixelThresholdInE = thePixelThreshold * theNoiseInElectrons ; + // Find the threshold in noise units, needed for the noiser. + + unsigned int Sub_detid = DetId(detID).subdetId(); + + float theThresholdInE = 0.; + if (theNoiseInElectrons > 0.) { + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } + else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing + } + } + + // full detector thickness + float moduleThickness = pixdet->specificSurface().bounds().thickness(); + LogDebug("SSDigitizerAlgorithm") + << " PixelDigitizer " + << numColumns << " " << numRows << " " << moduleThickness; + + if (addNoise) add_noise(pixdet, theThresholdInE/theNoiseInElectrons); // generate noise + + // Do only if needed + if (AddPixelInefficiency && theSignal.size() > 0) { + if (use_ineff_from_db_) + pixel_inefficiency_db(detID); + else + pixel_inefficiency(subdetEfficiencies_, pixdet, tTopo); + } + + if (use_module_killing_) { + if (use_deadmodule_DB_) // remove dead modules using DB + module_killing_DB(detID); + else // remove dead modules using the list in cfg file + module_killing_conf(detID); + } + make_digis(theThresholdInE, detID, digis, simlinks, tTopo); + + LogDebug("SSDigitizerAlgorithm") << "[SSDigitizerAlgorithm] converted " << digis.size() << " PixelDigis in DetUnit" << detID; +} diff --git a/SimTracker/SiPhase2Digitizer/python/phase2TrackerDigitizer_cfi.py b/SimTracker/SiPhase2Digitizer/python/phase2TrackerDigitizer_cfi.py new file mode 100644 index 0000000000000..347e34ca65983 --- /dev/null +++ b/SimTracker/SiPhase2Digitizer/python/phase2TrackerDigitizer_cfi.py @@ -0,0 +1,156 @@ +import FWCore.ParameterSet.Config as cms + +phase2TrackerDigitizer = cms.PSet( +# For the Digitizer + accumulatorType = cms.string("Phase2TrackerDigitizer"), + hitsProducer = cms.string('g4SimHits'), + ROUList = cms.vstring( + 'TrackerHitsPixelBarrelLowTof', + 'TrackerHitsPixelBarrelHighTof', + 'TrackerHitsPixelEndcapLowTof', + 'TrackerHitsPixelEndcapHighTof'), + GeometryType = cms.string('idealForDigi'), +# Common for Algos + AlgorithmCommon = cms.PSet( + DeltaProductionCut = cms.double(0.03), + ElectronPerAdc = cms.double(135.0), #D.B.:used for misscalibration + AdcFullScale = cms.int32(255) + ), +# Specific parameters +#Pixel Digitizer Algorithm + PixelDigitizerAlgorithm = cms.PSet( + makeDigiSimLinks = cms.untracked.bool(True), +#D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm]) + ReadoutNoiseInElec = cms.double(1000.0),#D.B.:Fill readout noise, including all readout chain, relevant for smearing + ThresholdInElectrons_Barrel = cms.double(5800.), #D.B.: this should correspond to a threshold of 530mV + ThresholdInElectrons_Endcap = cms.double(5800.), + AddThresholdSmearing = cms.bool(True), + ThresholdSmearing_Barrel = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 210.0) + ThresholdSmearing_Endcap = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) + NoiseInElectrons = cms.double(300), # 30% of the readout noise (should be changed in future) + DigitalReadout = cms.bool(True), # Flag to decide analog or digital readout + TofUpperCut = cms.double(12.5), + TofLowerCut = cms.double(-12.5), + AddNoisyPixels = cms.bool(True), + Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described + AddNoise = cms.bool(True), + AddXTalk = cms.bool(True), #D.B. + InterstripCoupling = cms.double(0.05), #D.B. + SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo + SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X + ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas) + LorentzAngle_DB = cms.bool(False), + TanLorentzAnglePerTesla_Endcap = cms.double(0.106), #D.B.:this I have not checked yet + TanLorentzAnglePerTesla_Barrel = cms.double(0.106), #D.B.:this I have not checked yet + KillModules = cms.bool(False), + DeadModules_DB = cms.bool(False), + DeadModules = cms.VPSet(), + AddInefficiency = cms.bool(False), + Inefficiency_DB = cms.bool(False), + EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ), + EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, + 0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on + ), +#Pixel in PS Module + PSPDigitizerAlgorithm = cms.PSet( + makeDigiSimLinks = cms.untracked.bool(True), +#D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm]) + ReadoutNoiseInElec = cms.double(1000.0),#D.B.:Fill readout noise, including all readout chain, relevant for smearing + ThresholdInElectrons_Barrel = cms.double(5800.), #D.B.: this should correspond to a threshold of 530mV + ThresholdInElectrons_Endcap = cms.double(5800.), + AddThresholdSmearing = cms.bool(True), + ThresholdSmearing_Barrel = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 210.0) + ThresholdSmearing_Endcap = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) + NoiseInElectrons = cms.double(300), # 30% of the readout noise (should be changed in future) + DigitalReadout = cms.bool(True), # Flag to decide analog or digital readout + TofUpperCut = cms.double(12.5), + TofLowerCut = cms.double(-12.5), + AddNoisyPixels = cms.bool(True), + Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described + AddNoise = cms.bool(True), + AddXTalk = cms.bool(True), #D.B. + InterstripCoupling = cms.double(0.05), #D.B. + SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo + SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X + ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas) + LorentzAngle_DB = cms.bool(False), + TanLorentzAnglePerTesla_Endcap = cms.double(0.106), #D.B.:this I have not checked yet + TanLorentzAnglePerTesla_Barrel = cms.double(0.106), #D.B.:this I have not checked yet + KillModules = cms.bool(False), + DeadModules_DB = cms.bool(False), + DeadModules = cms.VPSet(), + AddInefficiency = cms.bool(False), + Inefficiency_DB = cms.bool(False), + EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ), + EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, + 0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on + ), +#Strip in PS module + PSSDigitizerAlgorithm = cms.PSet( + makeDigiSimLinks = cms.untracked.bool(True), +#D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm]) + ReadoutNoiseInElec = cms.double(1000.0),#D.B.:Fill readout noise, including all readout chain, relevant for smearing + ThresholdInElectrons_Barrel = cms.double(5800.), #D.B.: this should correspond to a threshold of 530mV + ThresholdInElectrons_Endcap = cms.double(5800.), + AddThresholdSmearing = cms.bool(True), + ThresholdSmearing_Barrel = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 210.0) + ThresholdSmearing_Endcap = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) + NoiseInElectrons = cms.double(300), # 30% of the readout noise (should be changed in future) + DigitalReadout = cms.bool(True), # Flag to decide analog or digital readout + TofUpperCut = cms.double(12.5), + TofLowerCut = cms.double(-12.5), + AddNoisyPixels = cms.bool(True), + Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described + AddNoise = cms.bool(True), + AddXTalk = cms.bool(True), #D.B. + InterstripCoupling = cms.double(0.05), #D.B. + SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo + SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X + ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas) + LorentzAngle_DB = cms.bool(False), + TanLorentzAnglePerTesla_Endcap = cms.double(0.106), #D.B.:this I have not checked yet + TanLorentzAnglePerTesla_Barrel = cms.double(0.106), #D.B.:this I have not checked yet + KillModules = cms.bool(False), + DeadModules_DB = cms.bool(False), + DeadModules = cms.VPSet(), + AddInefficiency = cms.bool(False), + Inefficiency_DB = cms.bool(False), + EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ), + EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, + 0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on + ), +#Two Strip Module + SSDigitizerAlgorithm = cms.PSet( + makeDigiSimLinks = cms.untracked.bool(True), +#D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm]) + ReadoutNoiseInElec = cms.double(1000.0),#D.B.:Fill readout noise, including all readout chain, relevant for smearing + ThresholdInElectrons_Barrel = cms.double(5800.), #D.B.: this should correspond to a threshold of 530mV + ThresholdInElectrons_Endcap = cms.double(5800.), + AddThresholdSmearing = cms.bool(True), + ThresholdSmearing_Barrel = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 210.0) + ThresholdSmearing_Endcap = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) + NoiseInElectrons = cms.double(300), # 30% of the readout noise (should be changed in future) + DigitalReadout = cms.bool(True), # Flag to decide analog or digital readout + TofUpperCut = cms.double(12.5), + TofLowerCut = cms.double(-12.5), + AddNoisyPixels = cms.bool(True), + Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described + AddNoise = cms.bool(True), + AddXTalk = cms.bool(True), #D.B. + InterstripCoupling = cms.double(0.05), #D.B. + SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo + SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X + ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas) + LorentzAngle_DB = cms.bool(False), + TanLorentzAnglePerTesla_Endcap = cms.double(0.106), #D.B.:this I have not checked yet + TanLorentzAnglePerTesla_Barrel = cms.double(0.106), #D.B.:this I have not checked yet + KillModules = cms.bool(False), + DeadModules_DB = cms.bool(False), + DeadModules = cms.VPSet(), + AddInefficiency = cms.bool(False), + Inefficiency_DB = cms.bool(False), + EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ), + EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, + 0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on + ) +) From ef121ab23db57d3ac7b0ff339bfc0f7804508bfe Mon Sep 17 00:00:00 2001 From: Suchandra Date: Tue, 19 Aug 2014 12:22:46 +0200 Subject: [PATCH 082/252] removing unwanted files .... --- .../plugins/SiPhase2Digitizer.cc | 245 ---- .../plugins/SiPhase2Digitizer.h | 75 - .../plugins/SiPhase2DigitizerAlgorithm.cc | 1255 ----------------- .../plugins/SiPhase2DigitizerAlgorithm.h | 372 ----- .../SiPhase2Digitizer/test/DigiValidation.cc | 7 - .../test/DigiValidationTest_cfg.py | 4 +- 6 files changed, 2 insertions(+), 1956 deletions(-) delete mode 100644 SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc delete mode 100644 SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h delete mode 100644 SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc delete mode 100644 SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc deleted file mode 100644 index 50b9dd03be475..0000000000000 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc +++ /dev/null @@ -1,245 +0,0 @@ -// -*- C++ -*- -// -// Package: SiPhase2Digitizer -// Class: SiPhase2Digitizer -// -/**\class SiPhase2Digitizer SiPhase2Digitizer.cc SimTracker/SiPhase2Digitizer/src/SiPhase2Digitizer.cc - - Description: - - Implementation: - -*/ - -// system include files -#include -#include - -// user include files -#include "SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h" -#include "SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h" -#include "SimDataFormats/TrackingHit/interface/PSimHit.h" -#include "DataFormats/Common/interface/Handle.h" -#include "FWCore/Framework/interface/EDProducer.h" -#include "FWCore/Framework/interface/ESHandle.h" -#include "FWCore/Framework/interface/EventSetup.h" -#include "FWCore/ParameterSet/interface/ParameterSet.h" -#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" -#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" -#include "DataFormats/Common/interface/DetSet.h" -#include "DataFormats/Common/interface/DetSetVector.h" -#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" -#include "DataFormats/SiPixelDigi/interface/PixelDigiCollection.h" -#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" -#include "DataFormats/GeometryVector/interface/LocalPoint.h" -#include "DataFormats/GeometryVector/interface/LocalVector.h" -#include "Geometry/CommonDetUnit/interface/GeomDetUnit.h" -#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" -#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" -#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" - -#include "Geometry/CommonTopologies/interface/PixelTopology.h" -#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetType.h" - -#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" -// user include files -#include "FWCore/Framework/interface/Frameworkfwd.h" -#include "FWCore/Framework/interface/EDAnalyzer.h" - -#include "FWCore/Framework/interface/Event.h" -#include "FWCore/Framework/interface/MakerMacros.h" - -#include "MagneticField/Engine/interface/MagneticField.h" -#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" - -#include "FWCore/MessageLogger/interface/MessageLogger.h" -#include "SimGeneral/MixingModule/interface/PileUpEventPrincipal.h" - -//Random Number -#include "FWCore/ServiceRegistry/interface/Service.h" -#include "FWCore/Utilities/interface/RandomNumberGenerator.h" -#include "FWCore/Utilities/interface/Exception.h" -#include "CLHEP/Random/RandomEngine.h" - -// -// constants, enums and typedefs -// - -// -// static data member definitions -// - -// -// constructors and destructor -// -//using namespace std; - - -namespace cms -{ - SiPhase2Digitizer::SiPhase2Digitizer(const edm::ParameterSet& iConfig, edm::EDProducer& mixMod): - first(true), - _pixeldigialgo(), - hitsProducer(iConfig.getParameter("hitsProducer")), - trackerContainers(iConfig.getParameter >("ROUList")), - geometryType(iConfig.getParameter("GeometryType")) - { - edm::LogInfo ("PixelDigitizer ") <<"Enter the Pixel Digitizer"; - - const std::string alias ("simSiPixelDigis"); - - mixMod.produces >().setBranchAlias(alias); - mixMod.produces >().setBranchAlias(alias + "siPixelDigiSimLink"); - edm::Service rng; - if ( ! rng.isAvailable()) { - throw cms::Exception("Configuration") - << "SiPhase2Digitizer requires the RandomNumberGeneratorService\n" - "which is not present in the configuration file. You must add the service\n" - "in the configuration file or remove the modules that require it."; - } - - rndEngine = &(rng->getEngine()); - _pixeldigialgo.reset(new SiPhase2DigitizerAlgorithm(iConfig,(*rndEngine))); - - } - - SiPhase2Digitizer::~SiPhase2Digitizer(){ - edm::LogInfo ("PixelDigitizer ") <<"Destruct the Pixel Digitizer"; - } - - - // - // member functions - // - - void - SiPhase2Digitizer::accumulatePixelHits(edm::Handle > hSimHits) { - if(hSimHits.isValid()) { - std::set detIds; - std::vector const& simHits = *hSimHits.product(); - for(std::vector::const_iterator it = simHits.begin(), itEnd = simHits.end(); it != itEnd; ++it) { - unsigned int detId = (*it).detUnitId(); - if(detIds.insert(detId).second) { - // The insert succeeded, so this detector element has not yet been processed. - unsigned int isub = DetId(detId).subdetId(); - if((isub == PixelSubdetector::PixelBarrel) || (isub == PixelSubdetector::PixelEndcap)) { - PixelGeomDetUnit* pixdet = detectorUnits[detId]; - //access to magnetic field in global coordinates - GlobalVector bfield = pSetup->inTesla(pixdet->surface().position()); - LogDebug ("PixelDigitizer ") << "B-field(T) at " << pixdet->surface().position() << "(cm): " - << pSetup->inTesla(pixdet->surface().position()); - _pixeldigialgo->accumulateSimHits(it, itEnd, pixdet, bfield); - } - } - } - } - } - - void - SiPhase2Digitizer::initializeEvent(edm::Event const& e, edm::EventSetup const& iSetup) { - if(first){ - _pixeldigialgo->init(iSetup); - first = false; - } - _pixeldigialgo->initializeEvent(); - iSetup.get().get(geometryType, pDD); - iSetup.get().get(pSetup); - - // FIX THIS! We only need to clear and (re)fill this map when the geometry type IOV changes. Use ESWatcher to determine this. - if(true) { // Replace with ESWatcher - detectorUnits.clear(); - for(TrackingGeometry::DetUnitContainer::const_iterator iu = pDD->detUnits().begin(); iu != pDD->detUnits().end(); ++iu) { - unsigned int detId = (*iu)->geographicalId().rawId(); - DetId idet=DetId(detId); - unsigned int isub=idet.subdetId(); - if((isub == PixelSubdetector::PixelBarrel) || (isub == PixelSubdetector::PixelEndcap)) { - PixelGeomDetUnit* pixdet = dynamic_cast((*iu)); - assert(pixdet != 0); - detectorUnits.insert(std::make_pair(detId, pixdet)); - } - } - } - } - - void - SiPhase2Digitizer::accumulate(edm::Event const& iEvent, edm::EventSetup const& iSetup) { - // Step A: Get Inputs - for(vstring::const_iterator i = trackerContainers.begin(), iEnd = trackerContainers.end(); i != iEnd; ++i) { - edm::Handle > simHits; - edm::InputTag tag(hitsProducer, *i); - - iEvent.getByLabel(tag, simHits); - accumulatePixelHits(simHits); - } - } - - void - SiPhase2Digitizer::accumulate(PileUpEventPrincipal const& iEvent, edm::EventSetup const& iSetup) { - // Step A: Get Inputs - for(vstring::const_iterator i = trackerContainers.begin(), iEnd = trackerContainers.end(); i != iEnd; ++i) { - edm::Handle > simHits; - edm::InputTag tag(hitsProducer, *i); - - iEvent.getByLabel(tag, simHits); - accumulatePixelHits(simHits); - } - } - - // ------------ method called to produce the data ------------ - void - SiPhase2Digitizer::finalizeEvent(edm::Event& iEvent, const edm::EventSetup& iSetup) { - - edm::ESHandle tTopoHand; - iSetup.get().get(tTopoHand); - const TrackerTopology *tTopo=tTopoHand.product(); - - std::vector > theDigiVector; - std::vector > theDigiLinkVector; - - for(TrackingGeometry::DetUnitContainer::const_iterator iu = pDD->detUnits().begin(); iu != pDD->detUnits().end(); iu ++){ - DetId idet=DetId((*iu)->geographicalId().rawId()); - unsigned int isub=idet.subdetId(); - - if((isub == PixelSubdetector::PixelBarrel) || (isub == PixelSubdetector::PixelEndcap)) { - - // - - edm::DetSet collector((*iu)->geographicalId().rawId()); - edm::DetSet linkcollector((*iu)->geographicalId().rawId()); - - - _pixeldigialgo->digitize(dynamic_cast((*iu)), - collector.data, - linkcollector.data, - tTopo); - if(collector.data.size() > 0) { - theDigiVector.push_back(std::move(collector)); - } - if(linkcollector.data.size() > 0) { - theDigiLinkVector.push_back(std::move(linkcollector)); - } - } - } - - // Step C: create collection with the cache vector of DetSet - std::auto_ptr > - output(new edm::DetSetVector(theDigiVector) ); - std::auto_ptr > - outputlink(new edm::DetSetVector(theDigiLinkVector) ); - - // Step D: write output to file - iEvent.put(output); - iEvent.put(outputlink); - } - - - - -}// end namespace cms:: - -#include "FWCore/Framework/interface/MakerMacros.h" -#include "SimGeneral/MixingModule/interface/DigiAccumulatorMixModFactory.h" - -using cms::SiPhase2Digitizer; -DEFINE_DIGI_ACCUMULATOR(SiPhase2Digitizer); - diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h deleted file mode 100644 index 34a400ee25ee6..0000000000000 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h +++ /dev/null @@ -1,75 +0,0 @@ -#ifndef SiPhase2Digitizer_h -#define SiPhase2Digitizer_h - -/** \class SiPhase2Digitizer - * - * SiPhase2Digitizer produces digis from SimHits - * The real algorithm is in SiPhase2DigitizerAlgorithm - * - * \author Michele Pioppi-INFN Perugia - * - * \version Sep 26 2005 - - * - ************************************************************/ - -#include -#include -#include -#include - -#include "SimGeneral/MixingModule/interface/DigiAccumulatorMixMod.h" -#include "FWCore/Framework/interface/ESHandle.h" - -namespace CLHEP { - class HepRandomEngine; -} - -namespace edm { - class EDProducer; - class Event; - class EventSetup; - class ParameterSet; - template class Handle; -} - -class MagneticField; -class PileUpEventPrincipal; -class PixelGeomDetUnit; -class PSimHit; -class SiPhase2DigitizerAlgorithm; -class TrackerGeometry; - -namespace cms { - class SiPhase2Digitizer : public DigiAccumulatorMixMod { - public: - - explicit SiPhase2Digitizer(const edm::ParameterSet& conf, edm::EDProducer& mixMod); - - virtual ~SiPhase2Digitizer(); - - virtual void initializeEvent(edm::Event const& e, edm::EventSetup const& c) override; - virtual void accumulate(edm::Event const& e, edm::EventSetup const& c) override; - virtual void accumulate(PileUpEventPrincipal const& e, edm::EventSetup const& c) override; - virtual void finalizeEvent(edm::Event& e, edm::EventSetup const& c) override; - - virtual void beginJob() {} - private: - void accumulatePixelHits(edm::Handle >); - bool first; - std::unique_ptr _pixeldigialgo; - typedef std::vector vstring; - const std::string hitsProducer; - const vstring trackerContainers; - const std::string geometryType; - edm::ESHandle pDD; - edm::ESHandle pSetup; - std::map detectorUnits; - CLHEP::HepRandomEngine* rndEngine; - - // infrastructure to reject dead pixels as defined in db (added by F.Blekman) - }; -} - - -#endif diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc deleted file mode 100644 index 834d665890199..0000000000000 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.cc +++ /dev/null @@ -1,1255 +0,0 @@ -#include -#include - -#include "SimGeneral/NoiseGenerators/interface/GaussianTailNoiseGenerator.h" - -#include "DataFormats/SiPixelDigi/interface/PixelDigi.h" -#include "SimDataFormats/TrackerDigiSimLink/interface/PixelDigiSimLink.h" -#include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" -#include "SimTracker/Common/interface/SiG4UniversalFluctuation.h" -#include "SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h" - -#include -#include "FWCore/Utilities/interface/RandomNumberGenerator.h" -#include "CLHEP/Random/RandGaussQ.h" -#include "CLHEP/Random/RandFlat.h" - -//#include "PixelIndices.h" -#include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" -#include "DataFormats/TrackerCommon/interface/TrackerTopology.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" - -#include "FWCore/MessageLogger/interface/MessageLogger.h" -#include "FWCore/ParameterSet/interface/ParameterSet.h" -#include "FWCore/ServiceRegistry/interface/Service.h" -#include "FWCore/Utilities/interface/Exception.h" -#include "CalibTracker/SiPixelESProducers/interface/SiPixelGainCalibrationOfflineSimService.h" - -// Accessing dead pixel modules from the DB: -#include "DataFormats/DetId/interface/DetId.h" - -#include "CondFormats/SiPixelObjects/interface/GlobalPixel.h" - -#include "CondFormats/DataRecord/interface/SiPixelQualityRcd.h" -#include "CondFormats/DataRecord/interface/SiPixelFedCablingMapRcd.h" -#include "CondFormats/DataRecord/interface/SiPixelLorentzAngleSimRcd.h" -#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingMap.h" -#include "CondFormats/SiPixelObjects/interface/SiPixelFedCablingTree.h" -#include "CondFormats/SiPixelObjects/interface/SiPixelFedCabling.h" -#include "CondFormats/SiPixelObjects/interface/PixelIndices.h" -#include "CondFormats/SiPixelObjects/interface/SiPixelLorentzAngle.h" -#include "CondFormats/SiPixelObjects/interface/SiPixelQuality.h" -#include "CondFormats/SiPixelObjects/interface/PixelROC.h" -#include "CondFormats/SiPixelObjects/interface/LocalPixel.h" -#include "CondFormats/SiPixelObjects/interface/CablingPathToDetUnit.h" - -#include "CondFormats/SiPixelObjects/interface/SiPixelFrameReverter.h" -#include "CondFormats/SiPixelObjects/interface/PixelFEDCabling.h" -#include "CondFormats/SiPixelObjects/interface/PixelFEDLink.h" -#include "DataFormats/FEDRawData/interface/FEDNumbering.h" -#include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" -#include "DataFormats/SiPixelDetId/interface/PixelEndcapName.h" - -// Geometry -#include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" -#include "Geometry/Records/interface/TrackerDigiGeometryRecord.h" -#include "Geometry/TrackerGeometryBuilder/interface/PixelGeomDetUnit.h" -#include "Geometry/CommonTopologies/interface/PixelTopology.h" - -#include "CondFormats/SiPixelObjects/interface/PixelROC.h" - -using namespace edm; -using namespace sipixelobjects; - -#define TP_DEBUG // protect all LogDebug with ifdef. Takes too much CPU - - -void SiPhase2DigitizerAlgorithm::init(const edm::EventSetup& es) { - if(use_ineff_from_db_){// load gain calibration service fromdb... - theSiPixelGainCalibrationService_->setESObjects( es ); - } - if(use_deadmodule_DB_) { - es.get().get(SiPixelBadModule_); - } - if(use_LorentzAngle_DB_) { - // Get Lorentz angle from DB record - es.get().get(SiPixelLorentzAngle_); - } - //gets the map and geometry from the DB (to kill ROCs) - es.get().get(map_); - es.get().get(geom_); -} - -//========================================================================= - -SiPhase2DigitizerAlgorithm::SiPhase2DigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine& eng) : - - _signal(), - makeDigiSimLinks_(conf.getUntrackedParameter("makeDigiSimLinks", true)), - use_ineff_from_db_(conf.getParameter("Inefficiency_DB")), - use_module_killing_(conf.getParameter("KillModules")), // boolean to kill or not modules - use_deadmodule_DB_(conf.getParameter("DeadModules_DB")), // boolean to access dead modules from DB - use_LorentzAngle_DB_(conf.getParameter("LorentzAngle_DB")), // boolean to access Lorentz angle from DB - - DeadModules(use_deadmodule_DB_ ? Parameters() : conf.getParameter("DeadModules")), // get dead module from cfg file - - // Common pixel parameters - // These are parameters which are not likely to be changed - GeVperElectron(3.61E-09), // 1 electron(3.61eV, 1keV(277e, mod 9/06 d.k. - alpha2Order(conf.getParameter("Alpha2Order")), // switch on/off of E.B effect - addXtalk(conf.getParameter("AddXTalk")), - interstripCoupling(conf.getParameter("InterstripCoupling")), // Interstrip Coupling - - Sigma0(conf.getParameter("SigmaZero")), // Charge diffusion constant 7->3.7 - SigmaCoeff(conf.getParameter("SigmaCoeff")), // delta in the diffusion across the strip pitch - // (set between 0 to 0.9, 0-->flat Sigma0, 1-->Sigma_min=0 & Sigma_max=2*Sigma0 - //D.B.: Dist300 replaced by moduleThickness, may not work with partially depleted sensors but works otherwise - //Dist300(0.0300), // normalized to 300micron Silicon - - ClusterWidth(conf.getParameter("ClusterWidth")), // Charge integration spread on the collection plane - - doDigitalReadout(conf.getParameter("DigitalReadout")), // Flag to decide analog or digital readout - // ADC calibration 1adc count(135e. - // Corresponds to 2adc/kev, 270[e/kev]/135[e/adc](2[adc/kev] - // Be carefull, this parameter is also used in SiPixelDet.cc to - // calculate the noise in adc counts from noise in electrons. - // Both defaults should be the same. - theElectronPerADC(conf.getParameter("ElectronPerAdc")), - - // ADC saturation value, 255(8bit adc. - theAdcFullScale(conf.getParameter("AdcFullScale")), - - // Noise in electrons: - // Pixel cell noise, relevant for generating noisy pixels - theNoiseInElectrons(conf.getParameter("NoiseInElectrons")), - - // Fill readout noise, including all readout chain, relevant for smearing - //theReadoutNoise(conf.getUntrackedParameter("ReadoutNoiseInElec",500.)), - theReadoutNoise(conf.getParameter("ReadoutNoiseInElec")), - - // Threshold in units of noise: - // thePixelThreshold(conf.getParameter("ThresholdInNoiseUnits")), - // Pixel threshold in electron units. - theThresholdInE_Endcap(conf.getParameter("ThresholdInElectrons_Endcap")), - theThresholdInE_Barrel(conf.getParameter("ThresholdInElectrons_Barrel")), - - // Add threshold gaussian smearing: - theThresholdSmearing_Endcap(conf.getParameter("ThresholdSmearing_Endcap")), - theThresholdSmearing_Barrel(conf.getParameter("ThresholdSmearing_Barrel")), - - //theTofCut 12.5, cut in particle TOD +/- 12.5ns - //theTofCut(conf.getUntrackedParameter("TofCut",12.5)), - theTofLowerCut(conf.getParameter("TofLowerCut")), - theTofUpperCut(conf.getParameter("TofUpperCut")), - - // Get the Lorentz angle from the cfg file: - tanLorentzAnglePerTesla_Endcap(use_LorentzAngle_DB_ ? 0.0 : conf.getParameter("TanLorentzAnglePerTesla_Endcap")), - tanLorentzAnglePerTesla_Barrel(use_LorentzAngle_DB_ ? 0.0 : conf.getParameter("TanLorentzAnglePerTesla_Barrel")), - - // Add noise - addNoise(conf.getParameter("AddNoise")), - - // Add noisy pixels - addNoisyPixels(conf.getParameter("AddNoisyPixels")), - - // Fluctuate charge in track subsegments - fluctuateCharge(conf.getUntrackedParameter("FluctuateCharge",true)), - - // Control the pixel inefficiency - AddPixelInefficiency(conf.getParameter("AddInefficiency")), - - // Add threshold gaussian smearing: - addThresholdSmearing(conf.getParameter("AddThresholdSmearing")), - - // Add some pseudo-red damage - pseudoRadDamage(conf.exists("PseudoRadDamage")?conf.getParameter("PseudoRadDamage"):double(0.0)), - pseudoRadDamageRadius(conf.exists("PseudoRadDamageRadius")?conf.getParameter("PseudoRadDamageRadius"):double(0.0)), - - // delta cutoff in MeV, has to be same as in OSCAR(0.030/cmsim=1.0 MeV - //tMax(0.030), // In MeV. - //tMax(conf.getUntrackedParameter("DeltaProductionCut",0.030)), - tMax(conf.getParameter("DeltaProductionCut")), - - fluctuate(fluctuateCharge ? new SiG4UniversalFluctuation(eng) : 0), - theNoiser(addNoise ? new GaussianTailNoiseGenerator(eng) : 0), - theSiPixelGainCalibrationService_(use_ineff_from_db_ ? new SiPixelGainCalibrationOfflineSimService(conf) : 0), - subdetEfficiencies_(conf), - flatDistribution_((addNoise || AddPixelInefficiency || fluctuateCharge || addThresholdSmearing) ? new CLHEP::RandFlat(eng, 0., 1.) : 0), - gaussDistribution_((addNoise || AddPixelInefficiency || fluctuateCharge || addThresholdSmearing) ? new CLHEP::RandGaussQ(eng, 0., theReadoutNoise) : 0), - // Threshold smearing with gaussian distribution: - smearedThreshold_Endcap_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_Endcap , theThresholdSmearing_Endcap) : 0), - smearedThreshold_Barrel_(addThresholdSmearing ? new CLHEP::RandGaussQ(eng, theThresholdInE_Barrel , theThresholdSmearing_Barrel) : 0) -{ - LogInfo ("PixelDigitizer ") <<"SiPhase2DigitizerAlgorithm constructed" - <<"Configuration parameters:" - << "Threshold/Gain = " - << "threshold in electron Endcap = " - << theThresholdInE_Endcap - << "threshold in electron Barrel = " - << theThresholdInE_Barrel - <<" " << theElectronPerADC << " " << theAdcFullScale - << " The delta cut-off is set to " << tMax - << " pix-inefficiency "< >("EfficiencyFactors_Barrel"); - endcap_efficiencies = conf.getParameter< std::vector >("EfficiencyFactors_Endcap"); -} - -//========================================================================= -void SiPhase2DigitizerAlgorithm::accumulateSimHits(std::vector::const_iterator inputBegin, - std::vector::const_iterator inputEnd, - const PixelGeomDetUnit* pixdet, - const GlobalVector& bfield) { - // produce SignalPoint's for all SimHit's in detector - // Loop over hits - uint32_t detId = pixdet->geographicalId().rawId(); - for (std::vector::const_iterator ssbegin = inputBegin; ssbegin != inputEnd; ++ssbegin) { - // skip hits not in this detector. - if((*ssbegin).detUnitId() != detId) { - continue; - } - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - << (*ssbegin).particleType() << " " << (*ssbegin).pabs() << " " - << (*ssbegin).energyLoss() << " " << (*ssbegin).tof() << " " - << (*ssbegin).trackId() << " " << (*ssbegin).processType() << " " - << (*ssbegin).detUnitId() - << (*ssbegin).entryPoint() << " " << (*ssbegin).exitPoint() ; -#endif - - - std::vector ionization_points; - std::vector collection_points; - - // fill collection_points for this SimHit, indpendent of topology - // Check the TOF cut - if ( ((*ssbegin).tof() - pixdet->surface().toGlobal((*ssbegin).localPosition()).mag()/30.)>= theTofLowerCut && - ((*ssbegin).tof()- pixdet->surface().toGlobal((*ssbegin).localPosition()).mag()/30.) <= theTofUpperCut ) { - primary_ionization(*ssbegin, ionization_points); // fills _ionization_points - drift (*ssbegin, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points - // compute induced signal on readout elements and add to _signal - induce_signal(*ssbegin, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link - } // end if - } // end for -} - -//============================================================================ -void SiPhase2DigitizerAlgorithm::digitize(const PixelGeomDetUnit* pixdet, - std::vector& digis, - std::vector& simlinks, const TrackerTopology *tTopo) { - - // Pixel Efficiency moved from the constructor to this method because - // the information of the det are not available in the constructor - // Effciency parameters. 0 - no inefficiency, 1-low lumi, 10-high lumi - uint32_t detID = pixdet->geographicalId().rawId(); - const signal_map_type& theSignal = _signal[detID]; - - const PixelTopology* topol=&pixdet->specificTopology(); - int numColumns = topol->ncolumns(); // det module number of cols&rows - int numRows = topol->nrows(); - - // Noise already defined in electrons - //thePixelThresholdInE = thePixelThreshold * theNoiseInElectrons ; - // Find the threshold in noise units, needed for the noiser. - - unsigned int Sub_detid=DetId(detID).subdetId(); - - float theThresholdInE = 0.; - - if(theNoiseInElectrons>0.){ - if(Sub_detid == PixelSubdetector::PixelBarrel){ // Barrel modules - if(addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Barrel; // no smearing - } else { // Forward disks modules - if(addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Endcap; // no smearing - } - } - -#ifdef TP_DEBUG - // full detector thickness - float moduleThickness = pixdet->specificSurface().bounds().thickness(); - LogDebug ("PixelDigitizer") - << " PixelDigitizer " - << numColumns << " " << numRows << " " << moduleThickness; -#endif - - if(addNoise) add_noise(pixdet, theThresholdInE/theNoiseInElectrons); // generate noise - - // Do only if needed - - if((AddPixelInefficiency) && (theSignal.size()>0)) { - if (use_ineff_from_db_) pixel_inefficiency_db(detID); - else pixel_inefficiency(subdetEfficiencies_, pixdet, tTopo); - } - - if(use_module_killing_) { - if (use_deadmodule_DB_) { // remove dead modules using DB - module_killing_DB(detID); - } else { // remove dead modules using the list in cfg file - module_killing_conf(detID); - } - } - - make_digis(theThresholdInE, detID, digis, simlinks, tTopo); - -#ifdef TP_DEBUG - LogDebug ("PixelDigitizer") << "[SiPhase2DigitizerAlgorithm] converted " << digis.size() << " PixelDigis in DetUnit" << detID; -#endif -} - -//***********************************************************************/ -// Generate primary ionization along the track segment. -// Divide the track into small sub-segments -void SiPhase2DigitizerAlgorithm::primary_ionization(const PSimHit& hit, std::vector& ionization_points) const { - -// Straight line approximation for trajectory inside active media - - const float SegmentLength = 0.0010; //10microns in cm - float energy; - - // Get the 3D segment direction vector - LocalVector direction = hit.exitPoint() - hit.entryPoint(); - - float eLoss = hit.energyLoss(); // Eloss in GeV - float length = direction.mag(); // Track length in Silicon - - int NumberOfSegments = int ( length / SegmentLength); // Number of segments - if(NumberOfSegments < 1) NumberOfSegments = 1; -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - << " enter primary_ionzation " << NumberOfSegments - << " shift = " - << (hit.exitPoint().x()-hit.entryPoint().x()) << " " - << (hit.exitPoint().y()-hit.entryPoint().y()) << " " - << (hit.exitPoint().z()-hit.entryPoint().z()) << " " - << hit.particleType() <<" "<< hit.pabs() ; -#endif - - float* elossVector = new float[NumberOfSegments]; // Eloss vector - - if( fluctuateCharge ) { - //MP DA RIMUOVERE ASSOLUTAMENTE - int pid = hit.particleType(); - //int pid=211; // assume it is a pion - - float momentum = hit.pabs(); - // Generate fluctuated charge points - fluctuateEloss(pid, momentum, eLoss, length, NumberOfSegments, - elossVector); - } - - ionization_points.resize( NumberOfSegments); // set size - // loop over segments - for ( int i = 0; i != NumberOfSegments; i++) { - // Divide the segment into equal length subsegments - Local3DPoint point = hit.entryPoint() + - float((i+0.5)/NumberOfSegments) * direction; - if( fluctuateCharge ) - energy = elossVector[i]/GeVperElectron; // Convert charge to elec. - else - energy = hit.energyLoss()/GeVperElectron/float(NumberOfSegments); - - EnergyDepositUnit edu( energy, point); //define position,energy point - ionization_points[i] = edu; // save - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - << i << " " << ionization_points[i].x() << " " - << ionization_points[i].y() << " " - << ionization_points[i].z() << " " - << ionization_points[i].energy(); -#endif - - } // end for loop - delete[] elossVector; - -} -//****************************************************************************** - -// Fluctuate the charge comming from a small (10um) track segment. -// Use the G4 routine. For mip pions for the moment. -void SiPhase2DigitizerAlgorithm::fluctuateEloss(int pid, float particleMomentum, - float eloss, float length, - int NumberOfSegs,float elossVector[]) const { - - // Get dedx for this track - //float dedx; - //if( length > 0.) dedx = eloss/length; - //else dedx = eloss; - - double particleMass = 139.6; // Mass in MeV, Assume pion - pid = std::abs(pid); - if(pid!=211) { // Mass in MeV - if(pid==11) particleMass = 0.511; - else if(pid==13) particleMass = 105.7; - else if(pid==321) particleMass = 493.7; - else if(pid==2212) particleMass = 938.3; - } - // What is the track segment length. - float segmentLength = length/NumberOfSegs; - // Generate charge fluctuations. - float de=0.; - float sum=0.; - double segmentEloss = (1000.*eloss)/NumberOfSegs; //eloss in MeV - for (int i=0;iSampleFluctuations(double(particleMomentum*1000.), - particleMass, deltaCutoff, - double(segmentLength*10.), - segmentEloss )/1000.; //convert to GeV - - elossVector[i]=de; - sum +=de; - } - if(sum>0.) { // If fluctuations give eloss>0. - // Rescale to the same total eloss - float ratio = eloss/sum; - - for (int ii=0;ii& ionization_points, - std::vector& collection_points) const { - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " enter drift " ; -#endif - - collection_points.resize(ionization_points.size()); // set size - LocalVector driftDir=DriftDirection(pixdet, bfield, hit.detUnitId()); // get the charge drift direction - if(driftDir.z() ==0.) { - LogWarning("Magnetic field") << " pxlx: drift in z is zero "; - return; - } - - // tangent of Lorentz angle - //float TanLorenzAngleX = driftDir.x()/driftDir.z(); - //float TanLorenzAngleY = 0.; // force to 0, driftDir.y()/driftDir.z(); - - float TanLorenzAngleX, TanLorenzAngleY,dir_z, CosLorenzAngleX, - CosLorenzAngleY; - if( alpha2Order) { - - TanLorenzAngleX = driftDir.x(); // tangen of Lorentz angle - TanLorenzAngleY = driftDir.y(); - dir_z = driftDir.z(); // The z drift direction - CosLorenzAngleX = 1./sqrt(1.+TanLorenzAngleX*TanLorenzAngleX); //cosine - CosLorenzAngleY = 1./sqrt(1.+TanLorenzAngleY*TanLorenzAngleY); //cosine; - - } else{ - - TanLorenzAngleX = driftDir.x(); - TanLorenzAngleY = 0.; // force to 0, driftDir.y()/driftDir.z(); - dir_z = driftDir.z(); // The z drift direction - CosLorenzAngleX = 1./sqrt(1.+TanLorenzAngleX*TanLorenzAngleX); //cosine to estimate the path length - CosLorenzAngleY = 1.; - } - - float moduleThickness = pixdet->specificSurface().bounds().thickness(); - float stripPitch = pixdet->specificTopology().pitch().first; - - - // int rowsPerRoc = pixdet->specificTopology().rowsperroc(); //D.B.:debug - // int colsPerRoc = pixdet->specificTopology().colsperroc(); //D.B.:debug - // int nColumns = pixdet->specificTopology().ncolumns(); //D.B.:debug - // int nRows = pixdet->specificTopology().nrows(); //D.B.:debug - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - << " Lorentz Tan " << TanLorenzAngleX << " " << TanLorenzAngleY <<" " - << CosLorenzAngleX << " " << CosLorenzAngleY << " " - << moduleThickness*TanLorenzAngleX << " " << driftDir; -#endif - - float Sigma_x = 1.; // Charge spread - float Sigma_y = 1.; - float DriftDistance; // Distance between charge generation and collection - float DriftLength; // Actual Drift Lentgh - float Sigma; - - for (unsigned int i = 0; i != ionization_points.size(); i++) { - - float SegX, SegY, SegZ; // position - SegX = ionization_points[i].x(); - SegY = ionization_points[i].y(); - SegZ = ionization_points[i].z(); - - // Distance from the collection plane - //DriftDistance = (moduleThickness/2. + SegZ); // Drift to -z - // Include explixitely the E drift direction (for CMS dir_z=-1) - DriftDistance = moduleThickness/2. - (dir_z * SegZ); // Drift to -z - - //if( DriftDistance <= 0.) - //cout<<" <=0 "< moduleThickness ) - DriftDistance = moduleThickness; - - // Assume full depletion now, partial depletion will come later. - float XDriftDueToMagField = DriftDistance * TanLorenzAngleX; - float YDriftDueToMagField = DriftDistance * TanLorenzAngleY; - - // Shift cloud center - float CloudCenterX = SegX + XDriftDueToMagField; - float CloudCenterY = SegY + YDriftDueToMagField; - - // Calculate how long is the charge drift path - DriftLength = sqrt( DriftDistance*DriftDistance + - XDriftDueToMagField*XDriftDueToMagField + - YDriftDueToMagField*YDriftDueToMagField ); - - // What is the charge diffusion after this path - Sigma = sqrt(DriftLength/moduleThickness) * (Sigma0 * moduleThickness/0.0300); //Sigma0=0.00037 is for 300um thickness (make sure moduleThickness is in [cm]) - //D.B.: sigmaCoeff=0 means no modulation - if (SigmaCoeff) Sigma *= (SigmaCoeff*cos(SegX*M_PI/stripPitch)*cos(SegX*M_PI/stripPitch)+1); - //NB: divided by 4 to get a periodicity of stripPitch - - // Project the diffusion sigma on the collection plane - Sigma_x = Sigma / CosLorenzAngleX ; - Sigma_y = Sigma / CosLorenzAngleY ; - // if (rowsPerRoc==143) {//D.B.:debug - // std::cout<<" stripPitch="<=0.001){ - float moduleRadius = pixdet->surface().position().perp(); - if (moduleRadius<=pseudoRadDamageRadius){ - float kValue = pseudoRadDamage /(moduleRadius*moduleRadius); - //std::cout <<"\nmoduleRadius= "<pitch().first << " " << topol->pitch().second; //OK -#endif - - // local map to store pixels hit by 1 Hit. - typedef std::map< int, float, std::less > hit_map_type; - hit_map_type hit_signal; - - // map to store pixel integrals in the x and in the y directions - std::map > x,y; - - // Assign signals to readout channels and store sorted by channel number - int iseg = 0; - float ESum = 0.0; - // Iterate over collection points on the collection plane - for ( std::vector::const_iterator i=collection_points.begin(); - i != collection_points.end(); ++i) { - iseg++; - float CloudCenterX = i->position().x(); // Charge position in x - float CloudCenterY = i->position().y(); // in y - float SigmaX = i->sigma_x(); // Charge spread in x - float SigmaY = i->sigma_y(); // in y - float Charge = i->amplitude(); // Charge amplitude - - //if(SigmaX==0 || SigmaY==0) { - //cout<position().x() << " " << i->position().y() << " " - // << i->sigma_x() << " " << i->sigma_y() << " " << i->amplitude()<position().x() << " " << i->position().y() << " " - << i->sigma_x() << " " << i->sigma_y() << " " << i->amplitude(); -#endif - - // Find the maximum cloud spread in 2D plane , assume 3*sigma - float CloudRight = CloudCenterX + ClusterWidth*SigmaX; - float CloudLeft = CloudCenterX - ClusterWidth*SigmaX; - float CloudUp = CloudCenterY + ClusterWidth*SigmaY; - float CloudDown = CloudCenterY - ClusterWidth*SigmaY; - - - // Define 2D cloud limit points - LocalPoint PointRightUp = LocalPoint(CloudRight,CloudUp); - LocalPoint PointLeftDown = LocalPoint(CloudLeft,CloudDown); - - // This points can be located outside the sensor area. - // The conversion to measurement point does not check for that - // so the returned pixel index might be wrong (outside range). - // We rely on the limits check below to fix this. - // But remember whatever we do here THE CHARGE OUTSIDE THE ACTIVE - // PIXEL ARE IS LOST, it should not be collected. - - // Convert the 2D points to pixel indices - MeasurementPoint mp = topol->measurementPosition(PointRightUp ); //OK - - int IPixRightUpX = int( floor( mp.x())); - int IPixRightUpY = int( floor( mp.y())); - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " right-up " << PointRightUp << " " - << mp.x() << " " << mp.y() << " " - << IPixRightUpX << " " << IPixRightUpY ; -#endif - - mp = topol->measurementPosition(PointLeftDown ); //OK - - int IPixLeftDownX = int( floor( mp.x())); - int IPixLeftDownY = int( floor( mp.y())); - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " left-down " << PointLeftDown << " " - << mp.x() << " " << mp.y() << " " - << IPixLeftDownX << " " << IPixLeftDownY ; -#endif - - // Check detector limits to correct for pixels outside range. - int numColumns = topol->ncolumns(); // det module number of cols&rows - int numRows = topol->nrows(); - - IPixRightUpX = numRows>IPixRightUpX ? IPixRightUpX : numRows-1 ; - IPixRightUpY = numColumns>IPixRightUpY ? IPixRightUpY : numColumns-1 ; - IPixLeftDownX = 0localPosition(mp).x(); - LowerBound = 1-calcQ((xLB-CloudCenterX)/SigmaX); - } - - if(ix == numRows-1 || SigmaX==0. ) - UpperBound = 1.; - else { - mp = MeasurementPoint( float(ix+1), 0.0); - xUB = topol->localPosition(mp).x(); - UpperBound = 1. - calcQ((xUB-CloudCenterX)/SigmaX); - } - float TotalIntegrationRange = UpperBound - LowerBound; // get strip - x[ix] = TotalIntegrationRange; // save strip integral - //if(SigmaX==0 || SigmaY==0) - //cout<localPosition(mp).y(); - LowerBound = 1. - calcQ((yLB-CloudCenterY)/SigmaY); - } - - if(iy == numColumns-1 || SigmaY==0. ) - UpperBound = 1.; - else { - mp = MeasurementPoint( 0.0, float(iy+1) ); - yUB = topol->localPosition(mp).y(); - UpperBound = 1. - calcQ((yUB-CloudCenterY)/SigmaY); - } - - float TotalIntegrationRange = UpperBound - LowerBound; - y[iy] = TotalIntegrationRange; // save strip integral - //if(SigmaX==0 || SigmaY==0) - //cout< 0. ) { - chan = PixelDigi::pixelToChannel( ix, iy); // Get index - // Load the amplitude - hit_signal[chan] += ChargeFraction; - } // endif - - mp = MeasurementPoint( float(ix), float(iy) ); - LocalPoint lp = topol->localPosition(mp); - chan = topol->channel(lp); - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - << " pixel " << ix << " " << iy << " - "<<" " - << chan << " " << ChargeFraction<<" " - << mp.x() << " " << mp.y() <<" " - << lp.x() << " " << lp.y() << " " // givex edge position - << chan; // edge belongs to previous ? -#endif - ESum += ChargeFraction; - - } // endfor iy - } //endfor ix - - - // Test conversions (THIS IS FOR TESTING ONLY) comment-out. - // mp = topol->measurementPosition( i->position() ); //OK - // LocalPoint lp = topol->localPosition(mp); //OK - // std::pair p = topol->pixel( i->position() ); //OK - // chan = PixelDigi::pixelToChannel( int(p.first), int(p.second)); - // std::pair ip = PixelDigi::channelToPixel(chan); - // MeasurementPoint mp1 = MeasurementPoint( float(ip.first), - // float(ip.second) ); - // LogDebug ("Pixel Digitizer") << " Test "<< mp.x() << " " << mp.y() - // << " "<< lp.x() << " " << lp.y() << " "<<" " - // <localPosition(mp1).x() << " " //OK - // << topol->localPosition(mp1).y() << " " - // << topol->channel( i->position() ); //OK - - - } // loop over charge distributions - // Fill the global map with all hit pixels from this event - - for ( hit_map_type::const_iterator im = hit_signal.begin(); - im != hit_signal.end(); ++im) { - int chan = (*im).first; - theSignal[chan] += (makeDigiSimLinks_ ? Amplitude( (*im).second, &hit, (*im).second) : Amplitude( (*im).second, (*im).second) ) ; - -#ifdef TP_DEBUG - std::pair ip = PixelDigi::channelToPixel(chan); - LogDebug ("Pixel Digitizer") - << " pixel " << ip.first << " " << ip.second << " " - << theSignal[chan]; -#endif - } - -} // end induce_signal - -/***********************************************************************/ - -// Build pixels, check threshold, add misscalibration, ... -void SiPhase2DigitizerAlgorithm::make_digis(float theThresholdInE, - uint32_t detID, - std::vector& digis, - std::vector& simlinks, - const TrackerTopology *tTopo) const { - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " make digis "<<" " - << " pixel threshold Endcap" << theThresholdInE_Endcap << " " - << " pixel threshold Barrel" << theThresholdInE_Barrel << " " - << " List pixels passing threshold "; -#endif - - // Loop over hit pixels - - signalMaps::const_iterator it = _signal.find(detID); - if (it == _signal.end()) { - return; - } - - const signal_map_type& theSignal = (*it).second; - - for (signal_map_const_iterator i = theSignal.begin(); i != theSignal.end(); ++i) { - - float signalInElectrons = (*i).second.ampl() ; // signal in electrons - - // Do only for pixels above threshold - - if( signalInElectrons >= theThresholdInE) { // check threshold - - int chan = (*i).first; // channel number - std::pair ip = PixelDigi::channelToPixel(chan); - - int adc = 0; - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - << (*i).first << " " << (*i).second << " " << signalInElectrons - << " " << adc << ip.first << " " << ip.second ; -#endif - if (doDigitalReadout) adc = theAdcFullScale; - else adc = int( signalInElectrons / theElectronPerADC ); - - // Load digis - digis.emplace_back(ip.first, ip.second, adc); - - if (makeDigiSimLinks_ && (*i).second.hitInfo()!=0) { - //digilink - if((*i).second.trackIds().size()>0){ - simlink_map simi; - unsigned int il=0; - for( std::vector::const_iterator itid = (*i).second.trackIds().begin(); - itid != (*i).second.trackIds().end(); ++itid) { - simi[*itid].push_back((*i).second.individualampl()[il]); - il++; - } - - //sum the contribution of the same trackid - for( simlink_map::iterator simiiter=simi.begin(); - simiiter!=simi.end(); - simiiter++){ - - float sum_samechannel=0; - for (unsigned int iii=0;iii<(*simiiter).second.size();iii++){ - sum_samechannel+=(*simiiter).second[iii]; - } - float fraction=sum_samechannel/(*i).second; - if(fraction>1.) fraction=1.; - simlinks.emplace_back((*i).first, (*simiiter).first, (*i).second.eventId(), fraction); - } - } - } - } - } -} - -/***********************************************************************/ - -// Add electronic noise to pixel charge -void SiPhase2DigitizerAlgorithm::add_noise(const PixelGeomDetUnit* pixdet, - float thePixelThreshold) { -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " enter add_noise " << theNoiseInElectrons; -#endif - - uint32_t detID= pixdet->geographicalId().rawId(); - signal_map_type& theSignal = _signal[detID]; - const PixelTopology* topol=&pixdet->specificTopology(); - int numColumns = topol->ncolumns(); // det module number of cols&rows - int numRows = topol->nrows(); - - // First add Readout noise to hit cells - for ( signal_map_iterator i = theSignal.begin(); i != theSignal.end(); i++) { - float noise = gaussDistribution_->fire() ; - if(((*i).second.ampl() + noise) < 0. ) { - (*i).second.set(0);} - else{ - (*i).second += noise; - } - } - - if (addXtalk) { - signal_map_type signalNew; - for (signal_map_iterator i = theSignal.begin(); i != theSignal.end(); i++) { - float signalInElectrons = (*i).second.ampl(); // signal in electrons - std::pair hitChan = PixelDigi::channelToPixel((*i).first); - - float signalInElectrons_Xtalk = signalInElectrons * interstripCoupling; - - if (hitChan.first != 0) { - std::pair XtalkPrev = std::pair(hitChan.first-1, hitChan.second); - int chanXtalkPrev = PixelDigi::pixelToChannel(XtalkPrev.first, XtalkPrev.second); - signalNew.insert(std::pair(chanXtalkPrev, Amplitude (signalInElectrons_Xtalk, -1.0))); - } - if (hitChan.first < (numRows-1)) { - std::pair XtalkNext = std::pair(hitChan.first+1, hitChan.second); - int chanXtalkNext = PixelDigi::pixelToChannel(XtalkNext.first, XtalkNext.second); - signalNew.insert(std::pair(chanXtalkNext, Amplitude (signalInElectrons_Xtalk, -1.0))); - } - } - for (signal_map_iterator l = signalNew.begin(); l != signalNew.end(); l++) { - int chan = l->first; - signal_map_iterator iter = theSignal.find(chan); - if (iter != theSignal.end()) { - theSignal[chan] += l->second.ampl(); - } else theSignal.insert(std::pair(chan, Amplitude(l->second.ampl(),-1.0))); - } -#if 0 - for (signal_map_iterator l = theSignal.begin(); l != theSignal.end(); l++) { - std::pair hc = PixelDigi::channelToPixel((*l).first); - std::cout << (*l).first << " " << hc.first << " " << hc.second << " " << (*l).second << " " << std::endl; - } -#endif - } - if (!addNoisyPixels) // Option to skip noise in non-hit pixels - return; - - // Add noise on non-hit pixels - // Use here the pixel noise - int numberOfPixels = numRows * numColumns; - std::map > otherPixels; - std::map >::iterator mapI; - - theNoiser->generate(numberOfPixels, - thePixelThreshold, //thr. in un. of nois - theNoiseInElectrons, // noise in elec. - otherPixels ); - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - << " Add noisy pixels " << numRows << " " - << numColumns << " " << theNoiseInElectrons << " " - << theThresholdInE_Endcap << " " << theThresholdInE_Barrel <<" "<< numberOfPixels<<" " - << otherPixels.size() ; -#endif - - // Add noisy pixels - for (mapI = otherPixels.begin(); mapI!= otherPixels.end(); mapI++) { - int iy = ((*mapI).first) / numRows; - int ix = ((*mapI).first) - (iy*numRows); - // Keep for a while for testing. - if( iy < 0 || iy > (numColumns-1) ) - LogWarning ("Pixel Geometry") << " error in iy " << iy ; - if( ix < 0 || ix > (numRows-1) ) - LogWarning ("Pixel Geometry") << " error in ix " << ix ; - - int chan = PixelDigi::pixelToChannel(ix, iy); - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") - <<" Storing noise = " << (*mapI).first << " " << (*mapI).second - << " " << ix << " " << iy << " " << chan ; -#endif - - if (theSignal[chan] == 0) { - // float noise = float( (*mapI).second ); - int noise=int( (*mapI).second ); - theSignal[chan] = Amplitude (noise, -1.); - } - } -} - -/***********************************************************************/ - -// Simulate the readout inefficiencies. -// Delete a selected number of single pixels, dcols and rocs. -void SiPhase2DigitizerAlgorithm::pixel_inefficiency(const SubdetEfficiencies& eff, - const PixelGeomDetUnit* pixdet, - const TrackerTopology *tTopo) { - - uint32_t detID= pixdet->geographicalId().rawId(); - - signal_map_type& theSignal = _signal[detID]; - - // Predefined efficiencies - float subdetEfficiency = 1.0; - - // setup the chip indices conversion - unsigned int Subid=DetId(detID).subdetId(); - if (Subid== PixelSubdetector::PixelBarrel){// barrel layers - unsigned int layerIndex=tTopo->pxbLayer(detID); - if (layerIndex-1 < eff.barrel_efficiencies.size() ) subdetEfficiency = eff.barrel_efficiencies[layerIndex-1]; - else std::cout << (layerIndex-1) << " " << eff.barrel_efficiencies.size() << std::endl; - } else { // forward disks - unsigned int diskIndex = 2 * tTopo->pxfDisk(detID) - tTopo->pxfSide(detID); - if (diskIndex-1 < eff.endcap_efficiencies.size()) subdetEfficiency = eff.endcap_efficiencies[diskIndex-1]; - else std::cout << diskIndex-1 << " " << eff.barrel_efficiencies.size() << std::endl; - } // if barrel/forward - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " enter pixel_inefficiency " << subdetEfficiency; -#endif - - // Now loop again over pixels to kill some of them. - // Loop over hits, amplitude in electrons, channel = coded row,col - for(signal_map_iterator i = theSignal.begin();i != theSignal.end(); ++i) { - float rand = flatDistribution_->fire(); - if( rand>subdetEfficiency ) { - // make amplitude =0 - i->second.set(0.); // reset amplitude, - } // end if - } -} -//*********************************************************************** -//****************************************************************************** - -// Set the drift direction accoring to the Bfield in local det-unit frame -// Works for both barrel and forward pixels. -// Replace the sign convention to fit M.Swartz's formulaes. -// Configurations for barrel and foward pixels possess different tanLorentzAngleperTesla -// parameter value - -LocalVector SiPhase2DigitizerAlgorithm::DriftDirection(const PixelGeomDetUnit* pixdet, - const GlobalVector& bfield, - const DetId& detId) const { - Frame detFrame(pixdet->surface().position(),pixdet->surface().rotation()); - LocalVector Bfield=detFrame.toLocal(bfield); - float alpha2_Endcap; - float alpha2_Barrel; - float alpha2; - - //float dir_x = -tanLorentzAnglePerTesla * Bfield.y(); - //float dir_y = +tanLorentzAnglePerTesla * Bfield.x(); - //float dir_z = -1.; // E field always in z direction, so electrons go to -z - // The dir_z has to be +/- 1. ! - // LocalVector theDriftDirection = LocalVector(dir_x,dir_y,dir_z); - - float dir_x = 0.0; - float dir_y = 0.0; - float dir_z = 0.0; - float scale = 0.0; - - uint32_t detID= pixdet->geographicalId().rawId(); - - unsigned int Sub_detid=DetId(detID).subdetId(); - - // Read Lorentz angle from cfg file:************************************************************** - - if(!use_LorentzAngle_DB_){ - - if( alpha2Order) { - alpha2_Endcap = tanLorentzAnglePerTesla_Endcap*tanLorentzAnglePerTesla_Endcap; - alpha2_Barrel = tanLorentzAnglePerTesla_Barrel*tanLorentzAnglePerTesla_Barrel; - }else { - alpha2_Endcap = 0.0; - alpha2_Barrel = 0.0; - } - - if(Sub_detid == PixelSubdetector::PixelBarrel){// barrel layers - dir_x = -( tanLorentzAnglePerTesla_Barrel * Bfield.y() + alpha2_Barrel* Bfield.z()* Bfield.x() ); - dir_y = +( tanLorentzAnglePerTesla_Barrel * Bfield.x() - alpha2_Barrel* Bfield.z()* Bfield.y() ); - dir_z = -(1 + alpha2_Barrel* Bfield.z()*Bfield.z() ); - scale = (1 + alpha2_Barrel* Bfield.z()*Bfield.z() ); - - } else {// forward disks - dir_x = -( tanLorentzAnglePerTesla_Endcap * Bfield.y() + alpha2_Endcap* Bfield.z()* Bfield.x() ); - dir_y = +( tanLorentzAnglePerTesla_Endcap * Bfield.x() - alpha2_Endcap* Bfield.z()* Bfield.y() ); - dir_z = -(1 + alpha2_Endcap* Bfield.z()*Bfield.z() ); - scale = (1 + alpha2_Endcap* Bfield.z()*Bfield.z() ); - } - } // end: Read LA from cfg file. - - //Read Lorentz angle from DB:******************************************************************** - if(use_LorentzAngle_DB_){ - float lorentzAngle = SiPixelLorentzAngle_->getLorentzAngle(detId); - alpha2 = lorentzAngle * lorentzAngle; - //std::cout << "detID is: "<< it->first <<"The LA per tesla is: "<< it->second << std::std::endl; - dir_x = -( lorentzAngle * Bfield.y() + alpha2 * Bfield.z()* Bfield.x() ); - dir_y = +( lorentzAngle * Bfield.x() - alpha2 * Bfield.z()* Bfield.y() ); - dir_z = -(1 + alpha2 * Bfield.z()*Bfield.z() ); - scale = (1 + alpha2 * Bfield.z()*Bfield.z() ); - }// end: Read LA from DataBase. - - LocalVector theDriftDirection = LocalVector(dir_x/scale, dir_y/scale, dir_z/scale ); - -#ifdef TP_DEBUG - LogDebug ("Pixel Digitizer") << " The drift direction in local coordinate is " - << theDriftDirection ; -#endif - - return theDriftDirection; -} - -//**************************************************************************************************** - -void SiPhase2DigitizerAlgorithm::pixel_inefficiency_db(uint32_t detID) { - if(!use_ineff_from_db_) - return; - - signal_map_type& theSignal = _signal[detID]; - - // Loop over hit pixels, amplitude in electrons, channel = coded row,col - for(signal_map_iterator i = theSignal.begin();i != theSignal.end(); ++i) { - - // int chan = i->first; - std::pair ip = PixelDigi::channelToPixel(i->first);//get pixel pos - int row = ip.first; // X in row - int col = ip.second; // Y is in col - //transform to ROC index coordinates - if(theSiPixelGainCalibrationService_->isDead(detID, col, row)){ - // std::cout << "now in isdead check, row " << detID << " " << col << "," << row << std::std::endl; - // make pixel amplitude =0, pixel will be lost at clusterization - i->second.set(0.); // reset amplitude, - } // end if - } // end pixel loop -} // end pixel_indefficiency - - -//**************************************************************************************************** - -void SiPhase2DigitizerAlgorithm::module_killing_conf(uint32_t detID) { - if(!use_module_killing_) - return; - - bool isbad=false; - - Parameters::const_iterator itDeadModules=DeadModules.begin(); - - int detid = detID; - for(; itDeadModules != DeadModules.end(); ++itDeadModules){ - int Dead_detID = itDeadModules->getParameter("Dead_detID"); - if(detid == Dead_detID){ - isbad=true; - break; - } - } - - if(!isbad) - return; - - signal_map_type& theSignal = _signal[detID]; - - std::string Module = itDeadModules->getParameter("Module"); - - if(Module=="whole"){ - for(signal_map_iterator i = theSignal.begin();i != theSignal.end(); ++i) { - i->second.set(0.); // reset amplitude - } - } - - for(signal_map_iterator i = theSignal.begin();i != theSignal.end(); ++i) { - std::pair ip = PixelDigi::channelToPixel(i->first);//get pixel pos - - if(Module=="tbmA" && ip.first>=80 && ip.first<=159){ - i->second.set(0.); - } - - if( Module=="tbmB" && ip.first<=79){ - i->second.set(0.); - } - } -} -//**************************************************************************************************** -void SiPhase2DigitizerAlgorithm::module_killing_DB(uint32_t detID) { -// Not SLHC safe for now - if(!use_module_killing_) - return; - - bool isbad=false; - - std::vectordisabledModules = SiPixelBadModule_->getBadComponentList(); - - SiPixelQuality::disabledModuleType badmodule; - - for (size_t id=0;idsecond.set(0.); // reset amplitude - } - } - else { // all other module types: half-modules and single ROCs. - // Get Bad ROC position: - //follow the example of getBadRocPositions in CondFormats/SiPixelObjects/src/SiPixelQuality.cc - std::vector badrocpositions (0); - for(unsigned int j = 0; j < 16; j++){ - if(SiPixelBadModule_->IsRocBad(detID, j) == true){ - - std::vector path = map_.product()->pathToDetUnit(detID); - typedef std::vector::const_iterator IT; - for (IT it = path.begin(); it != path.end(); ++it) { - const PixelROC* myroc = map_.product()->findItem(*it); - if( myroc->idInDetUnit() == j) { - LocalPixel::RocRowCol local = { 39, 25}; //corresponding to center of ROC row, col - GlobalPixel global = myroc->toGlobal( LocalPixel(local) ); - badrocpositions.push_back(global); - break; - } - } - } - }// end of getBadRocPositions - - - for(signal_map_iterator i = theSignal.begin();i != theSignal.end(); ++i) { - std::pair ip = PixelDigi::channelToPixel(i->first);//get pixel pos - - for(std::vector::const_iterator it = badrocpositions.begin(); it != badrocpositions.end(); ++it){ - if(it->row >= 80 && ip.first >= 80 ){ - if((fabs(ip.second - it->col) < 26) ) {i->second.set(0.);} - else if(it->row==120 && ip.second-it->col==26){i->second.set(0.);} - else if(it->row==119 && it->col-ip.second==26){i->second.set(0.);} - } - else if(it->row < 80 && ip.first < 80 ){ - if((fabs(ip.second - it->col) < 26) ){i->second.set(0.);} - else if(it->row==40 && ip.second-it->col==26){i->second.set(0.);} - else if(it->row==39 && it->col-ip.second==26){i->second.set(0.);} - } - } - } - } -} - diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h deleted file mode 100644 index aec26f080b55a..0000000000000 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2DigitizerAlgorithm.h +++ /dev/null @@ -1,372 +0,0 @@ -#ifndef SiPhase2DigitizerAlgorithm_h -#define SiPhase2DigitizerAlgorithm_h - -#include -#include -#include -#include -#include "DataFormats/GeometrySurface/interface/GloballyPositioned.h" -#include "DataFormats/GeometryVector/interface/LocalPoint.h" -#include "FWCore/Framework/interface/ESHandle.h" -#include "SimDataFormats/EncodedEventId/interface/EncodedEventId.h" -#include "SimDataFormats/TrackingHit/interface/PSimHit.h" -#include "SimTracker/Common/interface/SimHitInfoForLinks.h" -#include "DataFormats/Math/interface/approx_exp.h" - -// forward declarations - - -// For the random numbers -namespace CLHEP { - class HepRandomEngine; - class RandGaussQ; - class RandFlat; -} - -namespace edm { - class EventSetup; - class ParameterSet; -} - -class DetId; -class GaussianTailNoiseGenerator; -class PixelDigi; -class PixelDigiSimLink; -class PixelGeomDetUnit; -class SiG4UniversalFluctuation; -class SiPixelFedCablingMap; -class SiPixelGainCalibrationOfflineSimService; -class SiPixelLorentzAngle; -class SiPixelQuality; -class TrackerGeometry; -class TrackerTopology; - -class SiPhase2DigitizerAlgorithm { - public: - SiPhase2DigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine&); - ~SiPhase2DigitizerAlgorithm(); - - // initialization that cannot be done in the constructor - void init(const edm::EventSetup& es); - - void initializeEvent() { - _signal.clear(); - } - - //run the algorithm to digitize a single det - void accumulateSimHits(const std::vector::const_iterator inputBegin, - const std::vector::const_iterator inputEnd, - const PixelGeomDetUnit *pixdet, - const GlobalVector& bfield); - void digitize(const PixelGeomDetUnit *pixdet, - std::vector& digis, - std::vector& simlinks, - const TrackerTopology *tTopo); - - private: - - //Accessing Lorentz angle from DB: - edm::ESHandle SiPixelLorentzAngle_; - - //Accessing Dead pixel modules from DB: - edm::ESHandle SiPixelBadModule_; - - //Accessing Map and Geom: - edm::ESHandle map_; - edm::ESHandle geom_; - - // Define internal classes - - // definition class - // - class Amplitude { - public: - Amplitude() : _amp(0.0) {} - Amplitude( float amp, float frac) : - _amp(amp), _frac(1, frac), _hitInfo() { - //in case of digi from noisypixels - //the MC information are removed - if (_frac[0]<-0.5) { - _frac.pop_back(); - } - } - - Amplitude( float amp, const PSimHit* hitp, float frac) : - _amp(amp), _frac(1, frac), _hitInfo(new SimHitInfoForLinks(hitp)) { - - //in case of digi from noisypixels - //the MC information are removed - if (_frac[0]<-0.5) { - _frac.pop_back(); - _hitInfo->trackIds_.pop_back(); - } - } - - // can be used as a float by convers. - operator float() const { return _amp;} - float ampl() const {return _amp;} - std::vector individualampl() const {return _frac;} - const std::vector& trackIds() const { - return _hitInfo->trackIds_; - } - const std::shared_ptr& hitInfo() const {return _hitInfo;} - - void operator+=( const Amplitude& other) { - _amp += other._amp; - - //in case of contribution of noise to the digi - //the MC information are removed - if (other._frac.size() > 0 && other._frac[0]>-0.5){ - if (other._hitInfo) { - std::vector& otherTrackIds = other._hitInfo->trackIds_; - if(_hitInfo) { - std::vector& trackIds = _hitInfo->trackIds_; - trackIds.insert(trackIds.end(), otherTrackIds.begin(), otherTrackIds.end()); - } else { - _hitInfo.reset(new SimHitInfoForLinks(*other._hitInfo)); - } - } - _frac.insert(_frac.end(), other._frac.begin(), other._frac.end()); - } - } - const EncodedEventId& eventId() const { - return _hitInfo->eventId_; - } - void operator+=( const float& amp) { - _amp += amp; - } - - void set (const float amplitude) { // Used to reset the amplitude - _amp = amplitude; - } -/* void setind (const float indamplitude) { // Used to reset the amplitude */ -/* _frac = idamplitude; */ -/* } */ - private: - float _amp; - std::vector _frac; - std::shared_ptr _hitInfo; - }; // end class Amplitude - - // - // Define a class for 3D ionization points and energy - // - /** - * Internal use only. - */ - class EnergyDepositUnit{ - public: - EnergyDepositUnit(): _energy(0),_position(0,0,0){} - EnergyDepositUnit(float energy,float x, float y, float z): - _energy(energy),_position(x,y,z){} - EnergyDepositUnit(float energy, Local3DPoint position): - _energy(energy),_position(position){} - float x() const{return _position.x();} - float y() const{return _position.y();} - float z() const{return _position.z();} - float energy() const { return _energy;} - private: - float _energy; - Local3DPoint _position; - }; - - // - // define class to store signals on the collection surface - // - /** - * Internal use only. - */ - - class SignalPoint { - public: - SignalPoint() : _pos(0,0), _time(0), _amplitude(0), - _sigma_x(1.), _sigma_y(1.), _hitp(0) {} - - SignalPoint( float x, float y, float sigma_x, float sigma_y, - float t, float a=1.0) : - _pos(x,y), _time(t), _amplitude(a), _sigma_x(sigma_x), - _sigma_y(sigma_y), _hitp(0) {} - - SignalPoint( float x, float y, float sigma_x, float sigma_y, - float t, const PSimHit& hit, float a=1.0) : - _pos(x,y), _time(t), _amplitude(a), _sigma_x(sigma_x), - _sigma_y(sigma_y),_hitp(&hit) {} - - const LocalPoint& position() const { return _pos;} - float x() const { return _pos.x();} - float y() const { return _pos.y();} - float sigma_x() const { return _sigma_x;} - float sigma_y() const { return _sigma_y;} - float time() const { return _time;} - float amplitude() const { return _amplitude;} - const PSimHit& hit() { return *_hitp;} - SignalPoint& set_amplitude( float amp) { _amplitude = amp; return *this;} - - - - private: - LocalPoint _pos; - float _time; - float _amplitude; - float _sigma_x; // gaussian sigma in the x direction (cm) - float _sigma_y; // " " y direction (cm) */ - const PSimHit* _hitp; - }; - - // - // SubdetEfficiencies struct - // - /** - * Internal use only. - */ - struct SubdetEfficiencies { - SubdetEfficiencies(const edm::ParameterSet& conf); - std::vector barrel_efficiencies; - std::vector endcap_efficiencies; - }; - - private: - - // Internal typedefs - typedef std::map > signal_map_type; // from Digi.Skel. - typedef signal_map_type::iterator signal_map_iterator; // from Digi.Skel. - typedef signal_map_type::const_iterator signal_map_const_iterator; // from Digi.Skel. - typedef std::map,std::less > simlink_map; - typedef std::map signalMaps; - typedef GloballyPositioned Frame; - typedef std::vector Parameters; - - // Contains the accumulated hit info. - signalMaps _signal; - - const bool makeDigiSimLinks_; - - const bool use_ineff_from_db_; - const bool use_module_killing_; // remove or not the dead pixel modules - const bool use_deadmodule_DB_; // if we want to get dead pixel modules from the DataBase. - const bool use_LorentzAngle_DB_; // if we want to get Lorentz angle from the DataBase. - - const Parameters DeadModules; - - // Variables - //external parameters - // go from Geant energy GeV to number of electrons - const float GeVperElectron; // 3.7E-09 - - //-- drift - const bool alpha2Order; // Switch on/off of E.B effect - const bool addXtalk; - const float interstripCoupling; - const float Sigma0; //=0.0007 // Charge diffusion in microns for 300 micron Si - const float SigmaCoeff; // delta in the diffusion across the strip pitch - - //-- induce_signal - const float ClusterWidth; // Gaussian charge cutoff width in sigma units - - //-- make_digis - const bool doDigitalReadout; // Flag to decide analog or digital readout - const float theElectronPerADC; // Gain, number of electrons per adc count. - const int theAdcFullScale; // Saturation count, 255=8bit. - const float theNoiseInElectrons; // Noise (RMS) in units of electrons. - const float theReadoutNoise; // Noise of the readount chain in elec, - //inludes DCOL-Amp,TBM-Amp, Alt, AOH,OptRec. - - - const float theThresholdInE_Endcap; // threshold in electrons Endcap. - const float theThresholdInE_Barrel; // threshold in electrons Barrel. - - const double theThresholdSmearing_Endcap; - const double theThresholdSmearing_Barrel; - - const float theTofLowerCut; // Cut on the particle TOF - const float theTofUpperCut; // Cut on the particle TOF - const float tanLorentzAnglePerTesla_Endcap; //FPix Lorentz angle tangent per Tesla - const float tanLorentzAnglePerTesla_Barrel; //BPix Lorentz angle tangent per Tesla - - //-- add_noise - const bool addNoise; - const bool addNoisyPixels; - const bool fluctuateCharge; - //-- pixel efficiency - const bool AddPixelInefficiency; // bool to read in inefficiencies - - const bool addThresholdSmearing; - - - // pseudoRadDamage - const double pseudoRadDamage; // Decrease the amount off freed charge that reaches the collector - const double pseudoRadDamageRadius; // Only apply pseudoRadDamage to pixels with radius<=pseudoRadDamageRadius - // The PDTable - //HepPDTable *particleTable; - //ParticleDataTable *particleTable; - - //-- charge fluctuation - const double tMax; // The delta production cut, should be as in OSCAR = 30keV - // cmsim = 100keV - - // The eloss fluctuation class from G4. Is the right place? - const std::unique_ptr fluctuate; // make a pointer - const std::unique_ptr theNoiser; - - //-- additional member functions - // Private methods - void primary_ionization( const PSimHit& hit, std::vector& ionization_points) const; - void drift(const PSimHit& hit, - const PixelGeomDetUnit *pixdet, - const GlobalVector& bfield, - const std::vector& ionization_points, - std::vector& collection_points) const; - void induce_signal(const PSimHit& hit, - const PixelGeomDetUnit *pixdet, - const std::vector& collection_points); - void fluctuateEloss(int particleId, float momentum, float eloss, - float length, int NumberOfSegments, - float elossVector[]) const; - void add_noise(const PixelGeomDetUnit *pixdet, - float thePixelThreshold); - void make_digis(float thePixelThresholdInE, - uint32_t detID, - std::vector& digis, - std::vector& simlinks, - const TrackerTopology *tTopo) const; - void pixel_inefficiency(const SubdetEfficiencies& eff, - const PixelGeomDetUnit* pixdet, - const TrackerTopology *tTopo); - - void pixel_inefficiency_db(uint32_t detID); - - // access to the gain calibration payloads in the db. Only gets initialized if check_dead_pixels_ is set to true. - const std::unique_ptr theSiPixelGainCalibrationService_; - LocalVector DriftDirection(const PixelGeomDetUnit* pixdet, - const GlobalVector& bfield, - const DetId& detId) const; - - void module_killing_conf(uint32_t detID); // remove dead modules using the list in the configuration file PixelDigi_cfi.py - void module_killing_DB(uint32_t detID); // remove dead modules uisng the list in the DB - - const SubdetEfficiencies subdetEfficiencies_; - - // For random numbers - const std::unique_ptr flatDistribution_; - const std::unique_ptr gaussDistribution_; - - // Threshold gaussian smearing: - const std::unique_ptr smearedThreshold_Endcap_; - const std::unique_ptr smearedThreshold_Barrel_; - - double calcQ(float x) const { - // need erf(x/sqrt2) - //float x2=0.5*x*x; - //float a=0.147; - //double erf=sqrt(1.0f-exp( -1.0f*x2*( (4/M_PI)+a*x2)/(1.0+a*x2))); - //if (x<0.) erf*=-1.0; - //return 0.5*(1.0-erf); - - auto xx=std::min(0.5f*x*x,12.5f); - return 0.5*(1.0-std::copysign(std::sqrt(1.f- unsafe_expf<4>(-xx*(1.f+0.2733f/(1.f+0.147f*xx)) )),x)); - } - - -}; - -#endif diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc index d6c35ef7c204a..6a7029c908071 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc @@ -400,9 +400,6 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS unsigned int rawid = DSViter->id; DetId detId(rawid); unsigned int layer = getLayerNumber(rawid); - //=================Temporary ============== - if (layer !=8) continue; - //=================Temporary ============== std::map::iterator iPos = layerHistoMap.find(layer); if (iPos == layerHistoMap.end()) { createLayerHistograms(layer); @@ -447,10 +444,6 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS dPhi = reco::deltaPhi((*simTracks)[iSimTrk].momentum().phi(), geomDetUnit->position().phi()); } iPos->second.DeltaPhi->Fill(dPhi); - //=================Temporary ============== - if (fabs(dPhi) <= phi_min || fabs(dPhi) >= phi_max) continue; - //=================Temporary ============== - int primaryTrk = -1; if (iSimTrk != -1) { primaryTrk = processTypes[iSimTrk]; diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py index 6b45a3904f999..4a33cf82d99dd 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py @@ -13,7 +13,7 @@ ) process.source = cms.Source("PoolSource", fileNames = cms.untracked.vstring( - 'file:/afs/cern.ch/user/d/dutta/work/public/Digitizer/Devel2/CMSSW_6_2_0_SLHC15/src/prod/electron_updatedcode.root' + 'file:SingleElectron.root' ) ) process.load('Configuration.StandardSequences.Services_cff') @@ -43,7 +43,7 @@ # Output ROOT file #------------- process.TFileService = cms.Service("TFileService", - fileName = cms.string('./Electron_Updated.root') + fileName = cms.string('./Electron_DigiTest.root') ) process.analysis = cms.EDAnalyzer("DigiValidation", Verbosity = cms.untracked.bool(False), From 23444230cae98f3bdae6b1df94cb40cd19085baf Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Mon, 1 Sep 2014 20:59:13 +0200 Subject: [PATCH 083/252] HGCAL deadzoneSimHits removal --- .../HGCalCommonData/src/HGCalDDDConstants.cc | 92 ++++++++++++++----- 1 file changed, 67 insertions(+), 25 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 932997187e1d6..03a6102907e32 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -35,19 +35,28 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, int lay, int i = index.first; if (i < 0) return std::pair(-1,-1); float alpha, h, bl, tl; - if (reco) { - h = moduler_[i].h; - bl = moduler_[i].bl; - tl = moduler_[i].tl; - alpha= moduler_[i].alpha; - if ((subSec>0 && alpha<0) || (subSec<=0 && alpha>0)) alpha = -alpha; - } else { - h = modules_[i].h; - bl = modules_[i].bl; - tl = modules_[i].tl; - alpha= modules_[i].alpha; - } - return assignCell(x, y, h, bl, tl, alpha, index.second); + + //set default values + std::pair cellAssignment( (x>0)?1:0, -1 ); + if (reco) + { + h = moduler_[i].h; + bl = moduler_[i].bl; + tl = moduler_[i].tl; + alpha= moduler_[i].alpha; + if ((subSec>0 && alpha<0) || (subSec<=0 && alpha>0)) alpha = -alpha; + cellAssignment=assignCell(x, y, h, bl, tl, alpha, index.second); + } + else + { + h = modules_[i].h; + bl = modules_[i].bl; + tl = modules_[i].tl; + alpha= modules_[i].alpha; + cellAssignment=assignCell(x, y, h, bl, tl, alpha, index.second); + } + + return cellAssignment; } std::pair HGCalDDDConstants::assignCell(float x, float y, float h, @@ -56,17 +65,33 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, float h, float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); + float x0(x); int phiSector = (x0 > 0) ? 1 : 0; if (alpha < 0) {x0 -= 0.5*(tl+bl); phiSector = 0;} else if (alpha > 0) {x0 += 0.5*(tl+bl); phiSector = 1;} - int kx = floor(fabs(x0)/cellSize); + //determine the i-y int ky = floor((y+h)/cellSize); - int icell(kx); + int max_ky_allowed=floor(2*h/cellSize); + if((y+h)> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); + + //determine the i-x + //notice we substitute y by the bottom of the candidate cell + int kx = floor(fabs(x0)/cellSize); + int max_kx_allowed=floor( (ky*cellSize+b)/(a*cellSize) ); + if(fabs(x)>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); + + //count cells summing in rows until required height + //notice the bottom of the cell must be used + int icell(0); for (int iky=0; iky(phiSector,icell); } @@ -96,17 +121,28 @@ std::pair HGCalDDDConstants::findCell(int cell, float h, float bl, float tl, float alpha, float cellSize) const { + //check if cell number is meaningful + if(cell<0) return std::pair(-1,-1); + + //parameterization of the boundary of the trapezoid float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); - int kymax = floor((2*h)/cellSize); - int ky(0), testCell(0); + + int kx(cell), ky(0); + int kymax( floor((2*h)/cellSize) ); + int testCell(0); for (int iky=0; iky= cell) break; - testCell += deltay; + + //check if adding all the cells in this row is above the required cell + //notice the center of the cell must be used + //int cellsInRow( floor( ((iky+0.5)*cellSize+b)/(a*cellSize) ) ); + int cellsInRow( floor( (iky*cellSize+b)/(a*cellSize) ) ); + if (testCell+cellsInRow > cell) break; + testCell += cellsInRow; ky++; + kx -= cellsInRow; } - int kx = (cell-testCell); + return std::pair(kx,ky); } @@ -115,6 +151,7 @@ bool HGCalDDDConstants::isValid(int lay, int mod, int cell, bool reco) const { bool ok = ((lay > 0 && lay <= (int)(layers(reco))) && (mod > 0 && mod <= sectors()) && (cell >=0 && cell <= maxCells(lay,reco))); + #ifdef DebugLog if (!ok) std::cout << "HGCalDDDConstants: Layer " << lay << ":" << (lay > 0 && (lay <= (int)(layers(reco)))) << " Module " @@ -189,11 +226,16 @@ int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); - int ncell(0); + + int ncells(0); int kymax = floor((2*h)/cellSize); for (int iky=0; iky<=kymax; ++iky) - ncell += floor((iky*cellSize+b)/(a*cellSize)); - return ncell; + { + int cellsInRow=floor((iky*cellSize+b)/(a*cellSize)); + ncells += cellsInRow; + } + + return ncells; } int HGCalDDDConstants::maxRows(int lay, bool reco) const { From 470bb75484553b053f860b23cd2d685829907bee Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Mon, 1 Sep 2014 20:59:36 +0200 Subject: [PATCH 084/252] HGCAL deadzoneSimHits removal --- SimG4CMS/Calo/src/HGCNumberingScheme.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SimG4CMS/Calo/src/HGCNumberingScheme.cc b/SimG4CMS/Calo/src/HGCNumberingScheme.cc index 4130177a2cbe6..8aea799dd3322 100644 --- a/SimG4CMS/Calo/src/HGCNumberingScheme.cc +++ b/SimG4CMS/Calo/src/HGCNumberingScheme.cc @@ -35,7 +35,7 @@ uint32_t HGCNumberingScheme::getUnitID(ForwardSubdetector &subdet, int &layer, i if ((!HGCalDetId::isValid(subdet,iz,layer,sector,phiSector,icell)) || (!hgcons->isValid(layer,sector,icell,false))) { index = 0; - if (check_) { + if (check_ && icell != -2) { edm::LogError("HGCSim") << "[HGCNumberingScheme] ID out of bounds :" << " Subdet= " << subdet << " Zside= " << iz << " Layer= " << layer << " Sector= " << sector From 3e3b49c54f745233e7febb8591c16cc2fd0957da Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Mon, 1 Sep 2014 21:55:48 +0200 Subject: [PATCH 085/252] synchronizing maxCells method --- Geometry/HGCalCommonData/src/HGCalDDDConstants.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 03a6102907e32..fdf34f6c51324 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -229,7 +229,7 @@ int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, int ncells(0); int kymax = floor((2*h)/cellSize); - for (int iky=0; iky<=kymax; ++iky) + for (int iky=0; iky Date: Mon, 1 Sep 2014 22:01:42 +0200 Subject: [PATCH 086/252] fixing some comments,nothing special --- Geometry/HGCalCommonData/src/HGCalDDDConstants.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index fdf34f6c51324..1eee143853804 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -134,8 +134,7 @@ std::pair HGCalDDDConstants::findCell(int cell, float h, float bl, for (int iky=0; iky cell) break; testCell += cellsInRow; @@ -228,6 +227,7 @@ int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, float b = 2*h*bl/(tl-bl); int ncells(0); + //always use the bottom of the cell... int kymax = floor((2*h)/cellSize); for (int iky=0; iky Date: Thu, 4 Sep 2014 12:03:44 +0200 Subject: [PATCH 087/252] adding new version with timing --- .../interface/HGCDigitizerBase.h | 47 +++++----- .../HGCSimProducers/src/HGCDigitizer.cc | 47 +++++----- .../HGCSimProducers/src/HGCHEbackDigitizer.cc | 88 +++++++++---------- 3 files changed, 88 insertions(+), 94 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index f0567c817ed22..0a7a1c55d80a0 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -32,7 +32,6 @@ class HGCDigitizerBase { lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); adcThreshold_ = myCfg_.getParameter< uint32_t >("adcThreshold"); - doTimeSamples_ = myCfg_.getParameter< bool >("doTimeSamples"); } /** @@ -62,32 +61,31 @@ class HGCDigitizerBase { it!=simData.end(); it++) { - //convert total energy GeV->keV->ADC counts - double totalEn(0); - size_t maxSampleToInteg(doTimeSamples_ ? 1 : it->second.size()); - for(size_t i=0; isecond)[i]; - } - totalEn*=1e6; - - //add noise (in keV) - double noiseEn=simpleNoiseGen_->fire(); - totalEn += noiseEn; - if(totalEn<0) totalEn=0; - //round to integer (sample will saturate the value according to available bits) - uint16_t totalEnInt = floor( (totalEn/mipInKeV_) / lsbInMIP_ ); + //create a new data frame + D newDataFrame( it->first ); - //0 gain for the moment - HGCSample singleSample; - singleSample.set(0, totalEnInt ); + for(size_t i=0; isecond.size(); i++) + { - if(singleSample.adc()first ); - newDataFrame.setSample(0, singleSample); + //convert total energy GeV->keV->ADC counts + double totalEn=(it->second)[i]*1e6; + //add noise (in keV) + double noiseEn=simpleNoiseGen_->fire(); + totalEn += noiseEn; + if(totalEn<0) totalEn=0; + + //round to integer (sample will saturate the value according to available bits) + uint16_t totalEnInt = floor( (totalEn/mipInKeV_) / lsbInMIP_ ); + + //0 gain for the moment + HGCSample singleSample; + singleSample.set(0, totalEnInt); + + newDataFrame.setSample(i, singleSample); + } + //add to collection to produce coll->push_back(newDataFrame); } @@ -115,9 +113,6 @@ class HGCDigitizerBase { //minimum ADC counts to produce DIGIs uint32_t adcThreshold_; - //flag to apply or not time sampling (if false digitize the full energy from SimHit) - bool doTimeSamples_; - //a simple noise generator mutable CLHEP::RandGauss *simpleNoiseGen_; diff --git a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc index ca44ac7a683b9..bf37edeef82dd 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc @@ -130,35 +130,36 @@ void HGCDigitizer::accumulate(PileUpEventPrincipal const& e, edm::EventSetup con // void HGCDigitizer::accumulate(edm::Handle const &hits, int bxCrossing,const edm::ESHandle &geom) { + + if(!geom.isValid()) return; + const HGCalTopology &topo=geom->topology(); + const HGCalDDDConstants &dddConst=topo.dddConstants(); + for(edm::PCaloHitContainer::const_iterator hit_it = hits->begin(); hit_it != hits->end(); ++hit_it) { HGCalDetId simId( hit_it->id() ); - //gang SIM->RECO cells + //skip this hit if after ganging it is not valid int layer(simId.layer()), cell(simId.cell()); - float zPos(0.); - if(geom.isValid()) - { - const HGCalTopology &topo=geom->topology(); - const HGCalDDDConstants &dddConst=topo.dddConstants(); - zPos=dddConst.getFirstTrForm()->h3v.z(); - std::pair recoLayerCell=dddConst.simToReco(cell,layer,topo.detectorType()); - cell = recoLayerCell.first; - layer = recoLayerCell.second; - if(layer<0) continue; - } - + std::pair recoLayerCell=dddConst.simToReco(cell,layer,topo.detectorType()); + cell = recoLayerCell.first; + layer = recoLayerCell.second; + if(layer<0 || cell<0) continue; + //assign the RECO DetId DetId id( producesEEDigis() ? (uint32_t)HGCEEDetId(mySubDet_,simId.zside(),layer,simId.sector(),simId.subsector(),cell): (uint32_t)HGCHEDetId(mySubDet_,simId.zside(),layer,simId.sector(),simId.subsector(),cell) ); - //hit time: [time()]=ns [zPos]=cm [CLHEP::c_light]=mm/ns - //for now accumulate in buckets of bxTime_ - int itime=floor( (hit_it->time()-zPos/(0.1*CLHEP::c_light))/bxTime_); - itime += bxCrossing; - if(itime<0) continue; - + //distance to the center of the detector + float dist2center( geom->getPosition(id).mag() ); + + //hit time: [time()]=ns [centerDist]=cm [CLHEP::c_light]=mm/ns + //for now accumulate in buckets of 5ns and save 3 pre-samples+5 in-time samples+1 post-sample + int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/5 ) + 1; + itime += bxCrossing*bxTime_; + if(itime<-3 || itime>6) continue; + //energy deposited HGCSimEn_t ien( hit_it->energy() ); @@ -172,10 +173,10 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i simHitIt=simHitAccumulator_->find(id); } - //check if time is ok - if( itime >= (int)(simHitIt->second.size()) ) continue; - - (simHitIt->second)[itime] += ien; + //check if time index is ok and store energy + int itimeIdx(itime+3); + if( itimeIdx<0 || itimeIdx >= (int)simHitIt->second.size() ) continue; + (simHitIt->second)[itimeIdx] += ien; } //add base data for noise simulation diff --git a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc index 4b99518d14444..db112fc4b1d73 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc @@ -43,53 +43,51 @@ void HGCHEbackDigitizer::runCaliceLikeDigitizer(std::auto_ptrkeV->ADC counts - double totalEn(0); - size_t maxSampleToInteg(doTimeSamples_ ? 1 : it->second.size()); - for(size_t i=0; isecond)[i]; - totalEn*=1e6; + //init a new data frame + HGCHEDataFrame newDataFrame( it->first ); - //convert energy to MIP - double totalMIPs = totalEn/mipInKeV_; - - //generate random number of photon electrons - float npe = peGen_->fire(totalMIPs*nPEperMIP_); - - //number of pixels - float x=exp(-npe/nTotalPE_); - float nPixel(0); - if(xTalk_*x!=1) nPixel=std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); - - //update signal - nPixel=std::max( float(sigGen_->fire(nPixel,sdPixels_)), float(0.) ); - - //convert to MIP again - if(nTotalPE_!=nPixel && (nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)>0 ) - totalMIPs = (nTotalPE_/nPEperMIP_)*log((nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)); - else - totalMIPs = 0; - - //add noise (in MIPs) - double noiseMIPs=simpleNoiseGen_->fire(0.,1./mip2noise_); - totalMIPs=std::max(float(totalMIPs+noiseMIPs),float(0.)); - - //round to integer (sample will saturate the value according to available bits) - uint16_t totalEnInt = floor( totalMIPs / lsbInMIP_ ); - - //0 gain for the moment - HGCSample singleSample; - singleSample.set(0, totalEnInt ); - - if(singleSample.adc()first ); - newDataFrame.setSample(0, singleSample); - - //add to collection to produce - digiColl->push_back(newDataFrame); - } + for(size_t i=0; isecond.size(); i++) + { + //convert total energy GeV->keV->ADC counts + float totalEn( (it->second)[i]*1e6 ); + + //convert energy to MIP + float totalMIPs = totalEn/mipInKeV_; + + //generate random number of photon electrons + float npe = peGen_->fire(totalMIPs*nPEperMIP_); + + //number of pixels + float x=(int)exp(-npe/nTotalPE_); + float nPixel(0); + if(xTalk_*x!=1) nPixel=std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); + + //update signal + nPixel=std::max( float(sigGen_->fire(nPixel,sdPixels_)), float(0.) ); + + //convert to MIP again + if(nTotalPE_!=nPixel && (nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)>0 ) + totalMIPs = (nTotalPE_/nPEperMIP_)*log((nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)); + else + totalMIPs = 0; + + //add noise (in MIPs) + double noiseMIPs=simpleNoiseGen_->fire(0.,1./mip2noise_); + totalMIPs=std::max(float(totalMIPs+noiseMIPs),float(0.)); + + //round to integer (sample will saturate the value according to available bits) + uint16_t totalEnInt = floor( totalMIPs / lsbInMIP_ ); + + //0 gain for the moment + HGCSample singleSample; + singleSample.set(0, totalEnInt ); + newDataFrame.setSample(i, singleSample); + } + + //add to collection to produce + digiColl->push_back(newDataFrame); + } } // From ef005954098abb1cd9a50f293212dfcadc56b272 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Thu, 4 Sep 2014 16:42:56 +0200 Subject: [PATCH 088/252] moving to 3x25ns time frames, accumulating sim hits in 3x25ns time frames, defining 3 samples dataframes --- DataFormats/HGCDigi/interface/HGCDataFrame.h | 4 ++-- .../HGCSimProducers/interface/HGCDigitizerBase.h | 2 +- SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc | 13 ++++++------- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/DataFormats/HGCDigi/interface/HGCDataFrame.h b/DataFormats/HGCDigi/interface/HGCDataFrame.h index 7d027a3b9b23f..eaa92af068607 100644 --- a/DataFormats/HGCDigi/interface/HGCDataFrame.h +++ b/DataFormats/HGCDigi/interface/HGCDataFrame.h @@ -21,8 +21,8 @@ class HGCDataFrame { /** @short CTOR */ - HGCDataFrame() : id_(0), maxSampleSize_(1) { data_.resize(maxSampleSize_); } - explicit HGCDataFrame(const D& id) : id_(id), maxSampleSize_(1) { data_.resize(maxSampleSize_); } + HGCDataFrame() : id_(0), maxSampleSize_(3) { data_.resize(maxSampleSize_); } + explicit HGCDataFrame(const D& id) : id_(id), maxSampleSize_(3) { data_.resize(maxSampleSize_); } /** diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 0a7a1c55d80a0..78adcfa12e3fe 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -13,7 +13,7 @@ #include "CLHEP/Random/RandGauss.h" typedef float HGCSimEn_t; -typedef std::array HGCSimHitData; +typedef std::array HGCSimHitData; typedef std::unordered_map HGCSimHitDataAccumulator; template diff --git a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc index bf37edeef82dd..aaef44679d3f5 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc @@ -155,11 +155,11 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i float dist2center( geom->getPosition(id).mag() ); //hit time: [time()]=ns [centerDist]=cm [CLHEP::c_light]=mm/ns - //for now accumulate in buckets of 5ns and save 3 pre-samples+5 in-time samples+1 post-sample - int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/5 ) + 1; + //for now accumulate in 3 buckets of 25ns + int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/bxTime_ ) + 1; itime += bxCrossing*bxTime_; - if(itime<-3 || itime>6) continue; - + if(itime<0) continue; + //energy deposited HGCSimEn_t ien( hit_it->energy() ); @@ -174,9 +174,8 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i } //check if time index is ok and store energy - int itimeIdx(itime+3); - if( itimeIdx<0 || itimeIdx >= (int)simHitIt->second.size() ) continue; - (simHitIt->second)[itimeIdx] += ien; + if(itime >= (int)simHitIt->second.size() ) continue; + (simHitIt->second)[itime] += ien; } //add base data for noise simulation From a7009240cec83d7ef13d593d45d8bb86066d16bb Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Mon, 8 Sep 2014 14:22:07 +0200 Subject: [PATCH 089/252] updated L1TrackDegraded.cc to degrade the PT resolution --- .../L1TrackTrigger/plugins/L1TrackDegraded.cc | 31 ++++++++++- .../L1TrackTrigger/test/testDegrader_cfg.py | 53 +++++++++++++++---- 2 files changed, 72 insertions(+), 12 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc index 0f314f748dcdb..20054a18549cd 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc @@ -31,6 +31,7 @@ #include "TRandom.h" #include "TMath.h" +#include using namespace edm; @@ -139,13 +140,39 @@ void L1TrackDegrader::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) float pz = trackIter->getMomentum().z(); float Phi = trackIter->getMomentum().phi(); - float NewPt = Pt; // the NewPt would be smeared + //float NewPt = Pt; // the NewPt would be smeared /* typically something like : depending on Pt and eta, pick up the resolution (sigma) from Louise's histogram float deltaPt = ran.Gaus(0., sigma); float NewPt = Pt + NsigmaPT * deltaPt : */ - + float sigma = 0; + + if(Pt >= 2 && Pt < 5) + { + if(Eta < 1) sigma = 0.00227539 * Eta + 0.0070669; + else if(Eta >= 1 && Eta < 1.75) sigma = 0.0111468 * Eta - 0.00141026; + else if(Eta >= 1.75 && Eta < 2.2) sigma = 0.00932418 * Eta + 0.0034399; + else if(Eta >= 2.2 && Eta < 2.5) sigma = 0.00817958 * Eta + 0.0127676; + } + else if(Pt >= 5 && Pt < 10) + { + if(Eta < 1) sigma = 0.00397676 * Eta + 0.00574204; + else if(Eta >= 1 && Eta < 1.6) sigma = 0.00503657 * Eta + 0.00507166; + else if(Eta >= 1.6 && Eta < 2.1) sigma = 0.0133589 * Eta - 0.00680838; + else if(Eta >= 2.1 && Eta < 2.4) sigma = 0.0352536 * Eta - 0.0480062; + else if(Eta >= 2.4 && Eta < 2.5) sigma = 0.0332331; + } + else if(Pt >= 10 && Pt < 100) + { + if(Eta < 1) sigma = 0.00376492 * Eta + 0.00920416; + else if(Eta >= 1 && Eta < 1.5) sigma = 0.00566646 * Eta + 0.00861003; + else if(Eta >= 1.65 && Eta < 2) sigma = 0.0406278 * Eta - 0.0509663; + else if(Eta >= 2 && Eta < 2.5) sigma = 0.110813 * Eta - 0.194005; + } + float deltaPt = ran.Gaus(0., sigma); + float NewPt = Pt + NsigmaPT * deltaPt * Pt; + //std::cout << "deltaPt: " << deltaPt << std::endl << "NsigmaPT: " << NsigmaPT << std::endl << "Pt: " << Pt << std::endl << "sigma: " << sigma << std::endl << NewPt << std::endl; float NewPz = pz * NewPt / Pt; GlobalVector smearedMomentum(GlobalVector::Cylindrical( NewPt, Phi, NewPz )); diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py index 0140ecf9a0e16..bdc7384e104d8 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/testDegrader_cfg.py @@ -1,10 +1,11 @@ import FWCore.ParameterSet.Config as cms -process = cms.Process("VTX") +process = cms.Process("DEG") # -# This runs over a file containing L1Tracks, and determines the -# event primary vertex by running the L1TkFastVertexProducer. +# Produces collections of L1Tracks with degraded resolutions +# - in z0 (to reproduce the z resolutions expected with the tilted tracer) +# - in PT (to look at the impact of a worse PT resolution) # @@ -15,7 +16,6 @@ from SLHCUpgradeSimulations.L1TrackTrigger.ttbarFiles_cfi import * - process.source = cms.Source("PoolSource", fileNames = ttbarFiles ) @@ -27,17 +27,50 @@ process.GlobalTag = GlobalTag(process.GlobalTag, 'PH2_1K_FB_V3::All', '') -process.L1TrackDegrader = cms.EDProducer("L1TrackDegrader", - L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks"), +# --------------------------------------------------------------------------- +# +# --- First, recreate the L1Tracks to benefit from the latest updates + +process.load('Configuration.Geometry.GeometryExtended2023TTIReco_cff') +process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') +process.load('Configuration.Geometry.GeometryExtended2023TTI_cff') + +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') + +process.load("SLHCUpgradeSimulations.L1TrackTrigger.L1TrackingSequence_cfi") +process.pTracking = cms.Path( process.DefaultTrackingSequence ) + + +# --------------------------------------------------------------------------- + + +# --------------------------------------------------------------------------- +# +# --- Now, produce two collections of degraded tracks + + + # worse z0 as for the tilted tracker: +process.L1TrackDegraderZ0 = cms.EDProducer("L1TrackDegrader", + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks","DEG"), degradeZ0 = cms.bool( True ), degradeMomentum = cms.bool( False ), - NsigmaPT = cms.int32( 3 ) + NsigmaPT = cms.int32( 3 ) # dummy here +) +process.pZ0 = cms.Path( process.L1TrackDegraderZ0 ) + + + # degrade the PT resolustion by approx. a factor of 3 +process.L1TrackDegraderPT3 = cms.EDProducer("L1TrackDegrader", + L1TrackInputTag = cms.InputTag("TTTracksFromPixelDigis","Level1TTTracks","DEG"), + degradeZ0 = cms.bool( False ), + degradeMomentum = cms.bool( True ), + NsigmaPT = cms.int32( 3 ) ) +process.pPT3 = cms.Path( process.L1TrackDegraderPT3 ) -process.p = cms.Path( process.L1TrackDegrader ) process.Out = cms.OutputModule( "PoolOutputModule", - fileName = cms.untracked.string( "example.root" ), + fileName = cms.untracked.string( "example_degrader.root" ), fastCloning = cms.untracked.bool( False ), outputCommands = cms.untracked.vstring( 'drop *') @@ -45,7 +78,7 @@ # the degraded tracks -process.Out.outputCommands.append('keep *_L1TrackDegrader_*_*') +process.Out.outputCommands.append('keep *_L1TrackDegrader*_*_*') # the L1Tracks, clusters and stubs process.Out.outputCommands.append('keep *_TTTracksFromPixelDigis_Level1TTTracks_*') From f278e9d8561233461a88da2bdda267096ecde91f Mon Sep 17 00:00:00 2001 From: Gaelle Date: Mon, 8 Sep 2014 15:22:06 +0200 Subject: [PATCH 090/252] no need to have backward compatibility for old gensim(<=SLHC11) --- SimTracker/SiPhase2Digitizer/BuildFile.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/SimTracker/SiPhase2Digitizer/BuildFile.xml b/SimTracker/SiPhase2Digitizer/BuildFile.xml index 7dc80cbe19ea7..d9e4bd4d5fa4a 100644 --- a/SimTracker/SiPhase2Digitizer/BuildFile.xml +++ b/SimTracker/SiPhase2Digitizer/BuildFile.xml @@ -16,7 +16,6 @@ - From b431581ab2d260b4de9a7a022b9c9b1153a41025 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Mon, 8 Sep 2014 15:29:38 +0200 Subject: [PATCH 091/252] no need to have backward compatibility for old gensim(<=SLHC11) --- .../plugins/SiPhase2Digitizer.cc | 16 ++++------------ .../plugins/SiPhase2Digitizer.h | 6 ------ 2 files changed, 4 insertions(+), 18 deletions(-) diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc index c274c31a8fdf2..66f760d1ea694 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.cc @@ -176,12 +176,8 @@ namespace cms edm::Handle > simHits; edm::InputTag tag(hitsProducer, *i); - // MODIFIED Mark Grimes 05/Jul/2014 - There was a problem reading back production samples made with - // SLHC11 because the DetId numbering changed in SLHC13. This is a horrible temporary hack to allow - // those samples to be read in newer versions of CMSSW. As soon as this ability is no longer required - // the next (i.e. original) line should be uncommented and the one after removed. Forever. - //iEvent.getByLabel(tag, simHits); - detIdRemapService_->getByLabel( iEvent, tag, simHits ); + // MODIFIED G. Boudoul 08/Sept/2014 - Removing Mark's hack, this package will not use old GENSIM. + iEvent.getByLabel(tag, simHits); unsigned int tofBin = PixelDigiSimLink::LowTof; if ((*i).find(std::string("HighTof")) != std::string::npos) tofBin = PixelDigiSimLink::HighTof; accumulatePixelHits(simHits, crossingSimHitIndexOffset_[tag.encode()], tofBin); @@ -200,12 +196,8 @@ namespace cms edm::Handle > simHits; edm::InputTag tag(hitsProducer, *i); - // MODIFIED Mark Grimes 05/Jul/2014 - There was a problem reading back production samples made with - // SLHC11 because the DetId numbering changed in SLHC13. This is a horrible temporary hack to allow - // those samples to be read in newer versions of CMSSW. As soon as this ability is no longer required - // the next (i.e. original) line should be uncommented and the one after removed. Forever. - //iEvent.getByLabel(tag, simHits); - detIdRemapService_->getByLabel( iEvent, tag, simHits ); + // MODIFIED G. Boudoul 08/Sept/2014 - Removing Mark's hack, this package will not use old GENSIM. + iEvent.getByLabel(tag, simHits); unsigned int tofBin = PixelDigiSimLink::LowTof; if ((*i).find(std::string("HighTof")) != std::string::npos) tofBin = PixelDigiSimLink::HighTof; accumulatePixelHits(simHits, crossingSimHitIndexOffset_[tag.encode()], tofBin); diff --git a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h index a9563bbecc230..6349f9a7d1f88 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h +++ b/SimTracker/SiPhase2Digitizer/plugins/SiPhase2Digitizer.h @@ -21,10 +21,6 @@ #include "SimGeneral/MixingModule/interface/DigiAccumulatorMixMod.h" #include "FWCore/Framework/interface/ESHandle.h" -// Take these next two lines out as soon as SLHC11 samples no longer need to be processed -#include -#include - namespace CLHEP { class HepRandomEngine; } @@ -83,8 +79,6 @@ namespace cms { std::map detectorUnits; CLHEP::HepRandomEngine* rndEngine; - // Take this member out as soon as SLHC11 files no longer need to be processed - edm::Service detIdRemapService_; // infrastructure to reject dead pixels as defined in db (added by F.Blekman) }; } From 4bd9190b769ddc102e5ddabea7d018ce4f271867 Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Mon, 8 Sep 2014 16:40:28 +0200 Subject: [PATCH 092/252] hgcal heb simgeometry modification --- Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc b/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc index 4fb420943e812..6a9bb1293959d 100644 --- a/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc +++ b/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc @@ -102,11 +102,17 @@ void DDHGCalHEAlgo::constructLayers(DDLogicalPart module, DDCompactView& cpv) { double zi = zMinBlock[ii]; zMinBlock[ii] += thickModule; if (heightType[i] == 0) zz = zi; - double zlayer = zz + thickModule; + + double zlayer = zz + 2*thickModule; + if((i % 6)>2) zlayer = zz + thickModule; + double zo = zi + thick[ii]; double rinF = zi * slopeB; double rinB = zlayer * slopeB; + double routF = (heightType[i] == 0) ? rMax(zi) : rMax(zz); + if((i % 6)>2) routF = (heightType[i] == 0) ? rMax(zi-thickModule) : rMax(zz-thickModule); + double routB = rMax(zo); std::string name = "HGCal"+names[ii]+dbl_to_string(copy); edm::LogInfo("HGCalGeom") << "DDHGCalEEAlgo test: Layer " << i << ":" @@ -126,7 +132,7 @@ void DDHGCalHEAlgo::constructLayers(DDLogicalPart module, DDCompactView& cpv) { DDSplit(materials[ii]).second); DDMaterial matter(matName); DDLogicalPart glog = DDLogicalPart(solid.ddname(), matter, solid); - edm::LogInfo("HGCalGeom") << "DDHGCalHEAlgo test: " + edm::LogInfo("HGCalGeom") << "DDHGCalHEAlgo test: " << solid.name() << " Trap made of " << matName << " of dimensions " << 0.5*thick[ii] << ", " << parm.theta/CLHEP::deg << ", " @@ -134,7 +140,7 @@ void DDHGCalHEAlgo::constructLayers(DDLogicalPart module, DDCompactView& cpv) { << ", " << parm.bl1 << ", " << parm.tl1 << ", " << parm.alp/CLHEP::deg << ", " << parm.yh2 << ", " << parm.bl2 << ", " - << parm.tl2 << ", " << parm.alp/CLHEP::deg; + << parm.tl2 << ", " << parm.alp/CLHEP::deg; DDTranslation r1(parm.xpos, parm.ypos, parm.zpos); cpv.position(glog, module, copy, r1, rot); edm::LogInfo("HGCalGeom") << "DDHGCalHEAlgo test: " << glog.name() From 807dbe8003ca5121ebcc1a1df5eee673850a2727 Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Mon, 8 Sep 2014 20:45:58 +0200 Subject: [PATCH 093/252] hgc boundary cell location fix --- .../HGCalCommonData/src/HGCalDDDConstants.cc | 94 ++++++++++++++----- 1 file changed, 68 insertions(+), 26 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 932997187e1d6..3294d6c36ccab 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -35,19 +35,28 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, int lay, int i = index.first; if (i < 0) return std::pair(-1,-1); float alpha, h, bl, tl; - if (reco) { - h = moduler_[i].h; - bl = moduler_[i].bl; - tl = moduler_[i].tl; - alpha= moduler_[i].alpha; - if ((subSec>0 && alpha<0) || (subSec<=0 && alpha>0)) alpha = -alpha; - } else { - h = modules_[i].h; - bl = modules_[i].bl; - tl = modules_[i].tl; - alpha= modules_[i].alpha; - } - return assignCell(x, y, h, bl, tl, alpha, index.second); + + //set default values + std::pair cellAssignment( (x>0)?1:0, -1 ); + if (reco) + { + h = moduler_[i].h; + bl = moduler_[i].bl; + tl = moduler_[i].tl; + alpha= moduler_[i].alpha; + if ((subSec>0 && alpha<0) || (subSec<=0 && alpha>0)) alpha = -alpha; + cellAssignment=assignCell(x, y, h, bl, tl, alpha, index.second); + } + else + { + h = modules_[i].h; + bl = modules_[i].bl; + tl = modules_[i].tl; + alpha= modules_[i].alpha; + cellAssignment=assignCell(x, y, h, bl, tl, alpha, index.second); + } + + return cellAssignment; } std::pair HGCalDDDConstants::assignCell(float x, float y, float h, @@ -56,17 +65,33 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, float h, float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); + float x0(x); int phiSector = (x0 > 0) ? 1 : 0; if (alpha < 0) {x0 -= 0.5*(tl+bl); phiSector = 0;} else if (alpha > 0) {x0 += 0.5*(tl+bl); phiSector = 1;} - int kx = floor(fabs(x0)/cellSize); + //determine the i-y int ky = floor((y+h)/cellSize); - int icell(kx); + int max_ky_allowed=floor(2*h/cellSize); + if((y+h)> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); + + //determine the i-x + //notice we substitute y by the bottom of the candidate cell + int kx = floor(fabs(x0)/cellSize); + int max_kx_allowed=floor( (ky*cellSize+b)/(a*cellSize) ); + if(fabs(x)>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); + + //count cells summing in rows until required height + //notice the bottom of the cell must be used + int icell(0); for (int iky=0; iky(phiSector,icell); } @@ -96,17 +121,28 @@ std::pair HGCalDDDConstants::findCell(int cell, float h, float bl, float tl, float alpha, float cellSize) const { + //check if cell number is meaningful + if(cell<0) return std::pair(-1,-1); + + //parameterization of the boundary of the trapezoid float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); - int kymax = floor((2*h)/cellSize); - int ky(0), testCell(0); + + int kx(cell), ky(0); + int kymax( floor((2*h)/cellSize) ); + int testCell(0); for (int iky=0; iky= cell) break; - testCell += deltay; + + //check if adding all the cells in this row is above the required cell + //notice the center of the cell must be used + //int cellsInRow( floor( ((iky+0.5)*cellSize+b)/(a*cellSize) ) ); + int cellsInRow( floor( (iky*cellSize+b)/(a*cellSize) ) ); + if (testCell+cellsInRow >= cell) break; + testCell += cellsInRow; ky++; + kx -= cellsInRow; } - int kx = (cell-testCell); + return std::pair(kx,ky); } @@ -115,6 +151,7 @@ bool HGCalDDDConstants::isValid(int lay, int mod, int cell, bool reco) const { bool ok = ((lay > 0 && lay <= (int)(layers(reco))) && (mod > 0 && mod <= sectors()) && (cell >=0 && cell <= maxCells(lay,reco))); + #ifdef DebugLog if (!ok) std::cout << "HGCalDDDConstants: Layer " << lay << ":" << (lay > 0 && (lay <= (int)(layers(reco)))) << " Module " @@ -189,11 +226,16 @@ int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); - int ncell(0); + + int ncells(0); int kymax = floor((2*h)/cellSize); - for (int iky=0; iky<=kymax; ++iky) - ncell += floor((iky*cellSize+b)/(a*cellSize)); - return ncell; + for (int iky=0; iky Date: Mon, 8 Sep 2014 21:59:53 +0200 Subject: [PATCH 094/252] heb fix --- .../HGCalCommonData/src/HGCalDDDConstants.cc | 49 ++++++++++++------- 1 file changed, 30 insertions(+), 19 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 4ac0cf72f9555..df3c107ab0324 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -63,30 +63,41 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, float h, float bl,float tl,float alpha, float cellSize) const { - float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = 2*h*bl/(tl-bl); - - float x0(x); - int phiSector = (x0 > 0) ? 1 : 0; - if (alpha < 0) {x0 -= 0.5*(tl+bl); phiSector = 0;} - else if (alpha > 0) {x0 += 0.5*(tl+bl); phiSector = 1;} + float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); + float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); + + int phiSector = (x > 0) ? 1 : 0; + //shift local coordinate to bottom left corner + if(alpha!=0) + { + x=fabs( x + (alpha<0 ? -0.5 : 0.5)*(tl-bl) ); + y=y+h; + } + else + { + x=fabs(x); + y=y+h; + } + //determine the i-y - int ky = floor((y+h)/cellSize); + int ky = floor(y/cellSize); int max_ky_allowed=floor(2*h/cellSize); - if((y+h)> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); - + if(ky>=max_ky_allowed) return std::pair(phiSector,-2); + // if(y> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); + //determine the i-x //notice we substitute y by the bottom of the candidate cell - int kx = floor(fabs(x0)/cellSize); - int max_kx_allowed=floor( (ky*cellSize+b)/(a*cellSize) ); - if(fabs(x)>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); - + int kx = floor(x/cellSize); + int max_kx_allowed=floor((ky*cellSize-b)/(a*cellSize)); + if(kx>=max_kx_allowed) return std::pair(phiSector,-2); + //if(x>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); + //count cells summing in rows until required height //notice the bottom of the cell must be used int icell(0); for (int iky=0; iky HGCalDDDConstants::findCell(int cell, float h, float bl, int testCell(0); for (int iky=0; iky= cell) break; - + if (testCell+cellsInRow > cell) break; testCell += cellsInRow; ky++; kx -= cellsInRow; @@ -228,6 +238,7 @@ int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, float b = 2*h*bl/(tl-bl); int ncells(0); + //always use the bottom of the cell... int kymax = floor((2*h)/cellSize); for (int iky=0; iky Date: Mon, 8 Sep 2014 22:57:40 +0200 Subject: [PATCH 095/252] minor fixes --- .../HGCalCommonData/src/HGCalDDDConstants.cc | 30 ++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index df3c107ab0324..626a29ddfd31b 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -136,17 +136,17 @@ std::pair HGCalDDDConstants::findCell(int cell, float h, float bl, if(cell<0) return std::pair(-1,-1); //parameterization of the boundary of the trapezoid - float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = 2*h*bl/(tl-bl); + float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); + float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); int kx(cell), ky(0); int kymax( floor((2*h)/cellSize) ); int testCell(0); for (int iky=0; iky cell) break; testCell += cellsInRow; ky++; @@ -234,15 +234,15 @@ int HGCalDDDConstants::maxCells(int lay, bool reco) const { int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, float cellSize) const { - float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = 2*h*bl/(tl-bl); + float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); + float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); int ncells(0); //always use the bottom of the cell... int kymax = floor((2*h)/cellSize); for (int iky=0; iky HGCalDDDConstants::numberCells(float h, float bl, float cellSize) const { float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = 2*h*bl/(tl-bl); + float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); int kymax = floor((2*h)/cellSize); std::vector ncell; for (int iky=0; iky HGCalDDDConstants::simToReco(int cell, int lay, int kx = kxy.first/cellFactor_[i]; int ky = kxy.second/cellFactor_[i]; float a = (half) ? (h/(tl-bl)) : (2*h/(tl-bl)); - float b = 2*h*bl/(tl-bl); + float b = (half) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); for (int iky=0; iky Date: Tue, 9 Sep 2014 00:11:31 +0200 Subject: [PATCH 096/252] reverting ddd constants --- .../HGCalCommonData/src/HGCalDDDConstants.cc | 71 ++++++++----------- 1 file changed, 29 insertions(+), 42 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 626a29ddfd31b..1eee143853804 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -63,41 +63,30 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, float h, float bl,float tl,float alpha, float cellSize) const { - float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); - - int phiSector = (x > 0) ? 1 : 0; + float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); + float b = 2*h*bl/(tl-bl); + + float x0(x); + int phiSector = (x0 > 0) ? 1 : 0; + if (alpha < 0) {x0 -= 0.5*(tl+bl); phiSector = 0;} + else if (alpha > 0) {x0 += 0.5*(tl+bl); phiSector = 1;} - //shift local coordinate to bottom left corner - if(alpha!=0) - { - x=fabs( x + (alpha<0 ? -0.5 : 0.5)*(tl-bl) ); - y=y+h; - } - else - { - x=fabs(x); - y=y+h; - } - //determine the i-y - int ky = floor(y/cellSize); + int ky = floor((y+h)/cellSize); int max_ky_allowed=floor(2*h/cellSize); - if(ky>=max_ky_allowed) return std::pair(phiSector,-2); - // if(y> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); - + if((y+h)> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); + //determine the i-x //notice we substitute y by the bottom of the candidate cell - int kx = floor(x/cellSize); - int max_kx_allowed=floor((ky*cellSize-b)/(a*cellSize)); - if(kx>=max_kx_allowed) return std::pair(phiSector,-2); - //if(x>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); - + int kx = floor(fabs(x0)/cellSize); + int max_kx_allowed=floor( (ky*cellSize+b)/(a*cellSize) ); + if(fabs(x)>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); + //count cells summing in rows until required height //notice the bottom of the cell must be used int icell(0); for (int iky=0; iky HGCalDDDConstants::findCell(int cell, float h, float bl, if(cell<0) return std::pair(-1,-1); //parameterization of the boundary of the trapezoid - float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); + float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); + float b = 2*h*bl/(tl-bl); int kx(cell), ky(0); int kymax( floor((2*h)/cellSize) ); int testCell(0); for (int iky=0; iky cell) break; testCell += cellsInRow; ky++; @@ -234,15 +223,15 @@ int HGCalDDDConstants::maxCells(int lay, bool reco) const { int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, float cellSize) const { - float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); + float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); + float b = 2*h*bl/(tl-bl); int ncells(0); //always use the bottom of the cell... int kymax = floor((2*h)/cellSize); for (int iky=0; iky HGCalDDDConstants::numberCells(float h, float bl, float cellSize) const { float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); - float b = (alpha==0) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); + float b = 2*h*bl/(tl-bl); int kymax = floor((2*h)/cellSize); std::vector ncell; for (int iky=0; iky HGCalDDDConstants::simToReco(int cell, int lay, int kx = kxy.first/cellFactor_[i]; int ky = kxy.second/cellFactor_[i]; float a = (half) ? (h/(tl-bl)) : (2*h/(tl-bl)); - float b = (half) ? -2*h*bl/(tl-bl) : -2*h*bl/(tl-bl); + float b = 2*h*bl/(tl-bl); for (int iky=0; iky Date: Tue, 9 Sep 2014 09:08:12 +0200 Subject: [PATCH 097/252] updating digitizer --- .../HGCSimProducers/interface/HGCDigitizer.h | 5 +++ .../interface/HGCDigitizerBase.h | 33 +++++++++++++++++++ .../HGCSimProducers/src/HGCDigitizer.cc | 14 ++++---- .../MixingModule/python/hgcalDigitizer_cfi.py | 11 +++++-- 4 files changed, 55 insertions(+), 8 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h index 23bc55555133e..f04500c8c749e 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h @@ -79,6 +79,11 @@ private : //subdetector id ForwardSubdetector mySubDet_; + + //reference speed to evaluate time of arrival + //at the sensititive detector + //assuming the center of CMS + float refSpeed_; }; #endif diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 78adcfa12e3fe..6527b1a790f83 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -32,6 +32,9 @@ class HGCDigitizerBase { lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); adcThreshold_ = myCfg_.getParameter< uint32_t >("adcThreshold"); + shaperN_ = myCfg_.getParameter< double >("shaperN"); + shaperTau_ = myCfg_.getParameter< double >("shaperTau"); + bxTime_ = ps.getParameter("bxTime"); } /** @@ -86,11 +89,35 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } + runShaper(newDataFrame); + //add to collection to produce coll->push_back(newDataFrame); } } + /** + @short applies a shape to each time sample and propagates the tails to the subsequent time samples + */ + void runShaper(D &dataFrame) + { + std::vector adcToCarry(dataFrame.size()); + for(int it=0; it("hitCollection"); @@ -154,11 +155,12 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i //distance to the center of the detector float dist2center( geom->getPosition(id).mag() ); - //hit time: [time()]=ns [centerDist]=cm [CLHEP::c_light]=mm/ns - //for now accumulate in 3 buckets of 25ns - int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/bxTime_ ) + 1; - itime += bxCrossing*bxTime_; - if(itime<0) continue; + //hit time: [time()]=ns [centerDist]=cm [refSpeed_]=cm/ns + //accumulate in 6 buckets of 25ns (4 pre-samples, 1 in-time, 1 post-sample) + int itime=floor( (hit_it->time()-dist2center/refSpeed_)/bxTime_ ) ; + itime += bxCrossing; + itime += 4; + if(itime<0 || itime>5) continue; //energy deposited HGCSimEn_t ien( hit_it->energy() ); diff --git a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py index 9619a70279fb5..53f2824349654 100644 --- a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py +++ b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py @@ -14,7 +14,9 @@ lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True) + doTimeSamples = cms.bool(True), + shaperN = cms.double(1.), + shaperTau = cms.double(20.) ) ) @@ -30,7 +32,10 @@ lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True) ) + doTimeSamples = cms.bool(True), + shaperN = cms.double(1.), + shaperTau = cms.double(20.) + ) ) @@ -47,6 +52,8 @@ mip2noise = cms.double(5.0), adcThreshold = cms.uint32(4), doTimeSamples = cms.bool(True), + shaperN = cms.double(1.), + shaperTau = cms.double(20.), caliceSpecific = cms.PSet( nPEperMIP = cms.double(11.0), nTotalPE = cms.double(1156), xTalk = cms.double(0.25), From 2374642f5c5d7bf8f57792f4014d3a4881020b5a Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Tue, 9 Sep 2014 09:20:30 +0200 Subject: [PATCH 098/252] updates from Anders (Sep 8) of L1TrackProducer.cc and L1PixelTrackFit.cc --- .../L1TrackTrigger/plugins/L1PixelTrackFit.cc | 113 +++++++++++------- .../L1TrackTrigger/plugins/L1TrackProducer.cc | 2 +- 2 files changed, 68 insertions(+), 47 deletions(-) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc index c822c1c6ff688..af6a0246ac6d9 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc @@ -236,7 +236,7 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) GlobalPoint gp = ( (geom.product())->idToDet(detId) )->surface().toGlobal(lp); if ( gp.perp() < 20.0 && fabs(gp.z()) < 55.0){ // reject outer tracker cl_pos.push_back(gp); - std::cout << "r z : "<28.0) type=-1; if (fabs(gp.z())>35.0) type=-2; if (fabs(gp.z())>45.0) type=-3; - std::cout << "r z type : "<getMomentum(npar).phi(); double z0=iterL1Track->getPOCA(npar).z(); double eta=iterL1Track->getMomentum(npar).eta(); - double d0=-iterL1Track->getPOCA(npar).perp(); - if (cos(phi0)*iterL1Track->getPOCA(npar).x()<0.0) d0=-d0; + //if (fabs(eta)>1.0) continue; + double d0=charge*iterL1Track->getPOCA(npar).perp(); + if (cos(phi0)*iterL1Track->getPOCA(npar).y()<0.0) d0=-d0; + //double d0=0.1; + //static int count=0; + //count++; + //if (count%2==1) d0=-d0; double t=tan(2.0*atan(1.0)-2.0*atan(exp(-eta))); + //std::cout << "Track: " + // << " invr="<1.0) continue; // 1 cm cut in z!!! + //std::cout<<" rhit zhit z_proj : "<0.5) continue; // 1 cm cut in z!!! double dphi=phi_proj-cl_pos[i].phi(); if (dphi>m_pi) dphi-=2.0*m_pi; if (dphi<-m_pi) dphi+=2.0*m_pi; if (fabs(dphi*rhit)>0.3) continue; // 3 mm cut in phi!!! //found matching hit + //std::cout << "Barrel Pixel hit: r=" + // << rhit + // << " dz="<<(z_proj-cl_pos[i].z())*10000.0<<" um" + // << " rdphi="<0.5) continue; // 5 mm cut in r!!! double dphi=phi_proj-cl_pos[i].phi(); if (dphi>m_pi) dphi-=2.0*m_pi; if (dphi<-m_pi) dphi+=2.0*m_pi; - if (fabs(dphi*cl_pos[i].perp())>0.3) continue; // 3 mm cut in phi!!! + if (fabs(dphi*rhit)>0.3) continue; // 3 mm cut in phi!!! //found matching hit + //std::cout << "Disk Pixel hit: zhit="<getMomentum().perp(); //FIXME using old pt @@ -476,8 +496,8 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double d0, if (i1!=hits[1].size()) npixel++; if (i2!=hits[2].size()) npixel++; if (i3!=hits[3].size()) npixel++; - std::cout << "npixel i0 i1 i2 i3 : "< fithits; std::vector fitbarrel; @@ -514,16 +534,17 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double d0, tbest=tfit; z0best=z0fit; } - std::cout << "Original: rinv="< HGCSimHitData; +typedef std::array HGCSimHitData; typedef std::unordered_map HGCSimHitDataAccumulator; template @@ -88,9 +88,13 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } - + + //run the shaper runShaper(newDataFrame); + //check if 5th time sample is above threshold + if( newDataFrame[4].adc() < adcThreshold_ ) continue; + //add to collection to produce coll->push_back(newDataFrame); } @@ -106,14 +110,16 @@ class HGCDigitizerBase { { HGCSample sample=dataFrame[it]; - adcToCarry[it] += sample.adc(); uint16_t newADC=sample.adc(); - for(int jt=0; jt0){ + adcToCarry[it] = sample.adc(); + for(int jt=0; jtpush_back(newDataFrame); } From f6319f9f312163a85244f85fe9b96d84328b90bd Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Tue, 9 Sep 2014 12:13:35 +0200 Subject: [PATCH 100/252] fixing ootpu propagation --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 7 +++---- SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 047f5d35150f5..d4a2ac833ed64 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -105,18 +105,17 @@ class HGCDigitizerBase { */ void runShaper(D &dataFrame) { - std::vector adcToCarry(dataFrame.size()); for(int it=0; it0){ - adcToCarry[it] = sample.adc(); for(int jt=0; jt Date: Tue, 9 Sep 2014 14:11:01 +0200 Subject: [PATCH 101/252] removing comparisons with floats --- Geometry/HGCalCommonData/src/HGCalDDDConstants.cc | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 1eee143853804..20e9c89b5107c 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -74,13 +74,15 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, float h, //determine the i-y int ky = floor((y+h)/cellSize); int max_ky_allowed=floor(2*h/cellSize); - if((y+h)> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); + if(ky>max_ky_allowed-1) return std::pair(phiSector,-2); + //if((y+h)> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); //determine the i-x //notice we substitute y by the bottom of the candidate cell int kx = floor(fabs(x0)/cellSize); int max_kx_allowed=floor( (ky*cellSize+b)/(a*cellSize) ); - if(fabs(x)>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); + if(kx>max_kx_allowed-1) return std::pair(phiSector,-2); + //if(fabs(x)>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); //count cells summing in rows until required height //notice the bottom of the cell must be used @@ -350,11 +352,12 @@ std::pair HGCalDDDConstants::simToReco(int cell, int lay, float bl = modules_[i].bl; float tl = modules_[i].tl; float cellSize = cellFactor_[i]*index.second; - std::pair kxy = findCell(cell, h, bl, tl, modules_[i].alpha, - index.second); + + std::pair kxy = findCell(cell, h, bl, tl, modules_[i].alpha, index.second); int depth = layerGroup_[i]; int kx = kxy.first/cellFactor_[i]; int ky = kxy.second/cellFactor_[i]; + float a = (half) ? (h/(tl-bl)) : (2*h/(tl-bl)); float b = 2*h*bl/(tl-bl); for (int iky=0; iky HGCalDDDConstants::simToReco(int cell, int lay, #ifdef DebugLog std::cout << "simToReco: input " << cell << ":" << lay << ":" << half << " kxy " << kxy.first << ":" << kxy.second << " output " - << kx << ":" << depth << std::endl; + << kx << ":" << depth << " cell factor=" << cellFactor_[i] << std::endl; #endif return std::pair(kx,depth); } From 94e2f1cfeadbac5d39aee41d2cd5639125f3480f Mon Sep 17 00:00:00 2001 From: Alja Mrak-Tadel Date: Tue, 9 Sep 2014 09:19:20 -0700 Subject: [PATCH 102/252] Fix crash on save of configuration when output file is invalid. --- Fireworks/Core/src/FWConfigurationManager.cc | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/Fireworks/Core/src/FWConfigurationManager.cc b/Fireworks/Core/src/FWConfigurationManager.cc index 88ea602f8e044..fc8f0c8752c81 100644 --- a/Fireworks/Core/src/FWConfigurationManager.cc +++ b/Fireworks/Core/src/FWConfigurationManager.cc @@ -8,7 +8,6 @@ // // Original Author: Chris Jones // Created: Sun Feb 24 14:42:32 EST 2008 -// $Id: FWConfigurationManager.cc,v 1.16 2011/02/22 18:37:31 amraktad Exp $ // // system include files @@ -107,10 +106,9 @@ FWConfigurationManager::writeToFile(const std::string& iName) const { try { - ofstream file(iName.c_str()); + std::ofstream file(iName.c_str()); if(not file) { - std::string message("unable to open file %s ", iName.c_str()); - fflush(stdout); + std::string message = "unable to open file " + iName; message += iName; throw std::runtime_error(message.c_str()); } @@ -121,7 +119,10 @@ FWConfigurationManager::writeToFile(const std::string& iName) const streamTo(file, top, "top"); } - catch (std::runtime_error &e) { std::cout << e.what() << std::endl; } + catch (std::runtime_error &e) + { + fwLog(fwlog::kError) << "FWConfigurationManager::writeToFile() " << e.what() << std::endl; + } } void @@ -241,7 +242,7 @@ class FWXMLConfigParser : public SimpleSAXParser /** Executes any transaction in the state machine which happens when the xml parser finds an new element. */ - virtual void startElement(const std::string &tag, Attributes &attributes) + virtual void startElement(const std::string &tag, Attributes &attributes) override { debug_config_state_machine("start", tag, m_state); if (m_state == IN_BEGIN_DOCUMENT) @@ -280,7 +281,7 @@ class FWXMLConfigParser : public SimpleSAXParser policy of addKeyValue addition which would add empty FWConfiguration objects if done on startElement. */ - virtual void endElement(const std::string &tag) + virtual void endElement(const std::string &tag) override { debug_config_state_machine("end", tag, m_state); if (m_state == IN_PUSHED_CONFIG || m_state == IN_POPPED_CONFIG) @@ -311,7 +312,7 @@ class FWXMLConfigParser : public SimpleSAXParser This is mainly used to handle element contents but also whitespace between tags. */ - virtual void data(const std::string &data) + virtual void data(const std::string &data) override { debug_config_state_machine("data", data, m_state); // We ignore whitespace but complain about any text which is not From f3cbe4527a2262facac35d376cecd1d6bc10b6e8 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 10 Sep 2014 14:22:51 +0200 Subject: [PATCH 103/252] fixing shape in the code --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index d4a2ac833ed64..f0d5de06a5cbf 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -108,14 +108,18 @@ class HGCDigitizerBase { for(int it=0; it0){ for(int jt=0; jt Date: Wed, 10 Sep 2014 17:29:16 +0200 Subject: [PATCH 105/252] added SLHCCaloTrigger_forTTI_cff.py and updated all example config files to make use of it --- .../python/SLHCCaloTrigger_forTTI_cff.py | 58 +++++++++++++++++++ .../test/produce_L1TkObjects_cfg.py | 2 +- .../test/runL1Simulation_cfg.py | 2 +- .../L1TrackTrigger/test/test_L1PixelTrack.py | 2 +- .../L1TrackTrigger/test/test_L1TkCalo_cfg.py | 2 +- .../test/test_L1TkEGamma_cfg.py | 2 +- .../test/test_L1TkEGamma_with_crystal_cfg.py | 2 +- .../L1TrackTrigger/test/test_L1TkEmTau_cfg.py | 2 +- .../L1TrackTrigger/test/test_L1TkJets_cfg.py | 2 +- .../test/test_L1TkTauFromCalo_cfg.py | 2 +- .../L1TrackTrigger/test/test_L1TkTau_cfg.py | 2 +- 11 files changed, 68 insertions(+), 10 deletions(-) create mode 100644 SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_forTTI_cff.py diff --git a/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_forTTI_cff.py b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_forTTI_cff.py new file mode 100644 index 0000000000000..637c6ae9f6bbc --- /dev/null +++ b/SLHCUpgradeSimulations/L1CaloTrigger/python/SLHCCaloTrigger_forTTI_cff.py @@ -0,0 +1,58 @@ +import FWCore.ParameterSet.Config as cms + +from SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cfi import * + +# use the old H/E cut (as in 620_SLHC10, i.e. seed = 3x3 cluster)), +# since the new one (seed tower) is inefficient at PU140 + +L1CaloProtoClusterSharing.oeCutMode = cms.int32(1) # 0 = seed tower H/E, 1 = 3x3 cluster H/E + + +SLHCCaloTrigger = cms.Sequence(#L1TestPatternCaloTowerProducer+ + L1CaloTowerProducer+ + #L1RingSubtractionProducer+ + L1CaloRegionProducer+ + L1CaloClusterProducer+ + L1CaloClusterFilter+ + L1CaloClusterIsolator+ + L1CaloClusterEGFilter+ + L1CaloClusterEGIsolator+ + ## New e/g clustering + L1CaloProtoClusterProducer+ + L1CaloProtoClusterFilter+ + L1CaloProtoClusterSharing+ + L1CaloEgammaClusterProducer+ + L1CaloEgammaClusterIsolator+ + ## End new e/g clustering + L1CaloJetProducer+ + L1CaloJetFilter+ + L1TowerJetProducer+ + L1TowerJetCentralityFilter+ + #L1TowerJetFilter1D+ + #L1TowerJetFilter2D+ + L1TowerJetPUEstimator+ + L1TowerJetPUSubtractedProducer+ + L1CalibFilterTowerJetProducer+ + L1EnergySumProducer+ + + # L1TowerFwdJetProducer+ + # L1TowerFwdJetFilter1D+ + # L1TowerFwdJetFilter2D+ + L1CaloJetExpander+ + rawSLHCL1ExtraParticles+ + rawSLHCL1ExtraParticlesNewClustering+ + SLHCL1ExtraParticles+ + SLHCL1ExtraParticlesNewClustering + + #l1extraParticlesCalibrated +) + +#uncomment the lines below for verbose (Huge amount of printouts!) +#L1CaloClusterProducer.verbosity = cms.untracked.bool(True) +#L1CaloClusterFilter.verbosity = cms.untracked.bool(True) +#L1CaloJetProducer.verbosity = cms.untracked.bool(True) +#L1CaloJetFilter.verbosity = cms.untracked.bool(True) +#L1CaloJetExpander.verbosity = cms.untracked.bool(True) + + + diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py index a9d6d81444227..26d295e9d32db 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/produce_L1TkObjects_cfg.py @@ -58,7 +58,7 @@ process.load('Configuration/StandardSequences/L1HwVal_cff') process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") # bug fix for missing HCAL TPs in MC RAW from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py index bbd7a399ef534..67ffe4731ebcb 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/runL1Simulation_cfg.py @@ -63,7 +63,7 @@ # --- Run the SLHCCaloSequence process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py index 50023e1554342..a41936d1e01fa 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1PixelTrack.py @@ -10,7 +10,7 @@ process.load('Configuration.StandardSequences.RawToDigi_cff') process.load('Configuration.StandardSequences.Reconstruction_cff') process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') -process.load('SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff') +process.load('SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff') process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) ) diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py index 820500fc65df8..4e8c49a7c1664 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkCalo_cfg.py @@ -54,7 +54,7 @@ # --- Run the SLHCCaloSequence to produce the L1Jets process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") #process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py index 6faa8c6ca2e4d..0fbc36d7a7a45 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_cfg.py @@ -71,7 +71,7 @@ process.load('Configuration/StandardSequences/L1HwVal_cff') process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") # bug fix for missing HCAL TPs in MC RAW from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py index ce25bf218b423..a12faedd227df 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEGamma_with_crystal_cfg.py @@ -70,7 +70,7 @@ process.load('Configuration/StandardSequences/L1HwVal_cff') process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") # bug fix for missing HCAL TPs in MC RAW from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py index efebb8c4e58ce..67669939e7800 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkEmTau_cfg.py @@ -87,7 +87,7 @@ process.load('Configuration/StandardSequences/L1HwVal_cff') process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") # bug fix for missing HCAL TPs in MC RAW from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py index c0af59a539850..627e6ec95ea9f 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkJets_cfg.py @@ -55,7 +55,7 @@ # --- Run the SLHCCaloSequence to produce the L1Jets process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") #process.L1CalibFilterTowerJetProducer.pTCalibrationThreshold = cms.double(40) # applies calibration only to > 40GeV L1 jets diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py index 38c6722f3ba86..d943f69ed733c 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTauFromCalo_cfg.py @@ -68,7 +68,7 @@ process.load('Configuration/StandardSequences/L1HwVal_cff') # Run the SLHCCaloSequence to produce the L1Jets process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") # The sequence SLHCCaloTrigger creates "stage-2" L1Taus. # Two collections are created: diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py index 50d7768e9f680..8167f53aae00e 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py +++ b/SLHCUpgradeSimulations/L1TrackTrigger/test/test_L1TkTau_cfg.py @@ -58,7 +58,7 @@ process.load('Configuration/StandardSequences/L1HwVal_cff') process.load('Configuration.StandardSequences.RawToDigi_cff') -process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_cff") +process.load("SLHCUpgradeSimulations.L1CaloTrigger.SLHCCaloTrigger_forTTI_cff") # bug fix for missing HCAL TPs in MC RAW from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cff import HcalTPGCoderULUT From 319e0ab8284947bfb62603aac7acd1519cdb8520 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Mon, 15 Sep 2014 16:13:01 +0200 Subject: [PATCH 106/252] fixing saturation in HEB digitizer --- .../interface/HGCDigitizerBase.h | 8 ++++---- .../HGCSimProducers/src/HGCHEbackDigitizer.cc | 17 +++++++++-------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index f0d5de06a5cbf..d18123380fbf2 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -105,25 +105,25 @@ class HGCDigitizerBase { */ void runShaper(D &dataFrame) { + //bool doDebug(dataFrame[4].adc()>adcThreshold_); for(int it=0; it "; if(shaperN_*shaperTau_>0){ for(int jt=0; jtsecond)[i]*1e6 ); //convert energy to MIP - float totalMIPs = totalEn/mipInKeV_; + float totalIniMIPs = totalEn/mipInKeV_; //generate random number of photon electrons - float npe = peGen_->fire(totalMIPs*nPEperMIP_); + uint32_t npe = (uint32_t)peGen_->fire(totalIniMIPs*nPEperMIP_); //number of pixels - float x=(int)exp(-npe/nTotalPE_); - float nPixel(0); - if(xTalk_*x!=1) nPixel=std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); + float x=exp(-(float)(npe)/(float)(nTotalPE_)); + uint32_t nPixel(0); + if(xTalk_*x!=1) nPixel=(uint32_t) std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); //update signal - nPixel=std::max( float(sigGen_->fire(nPixel,sdPixels_)), float(0.) ); + nPixel=(uint32_t)std::max( float(sigGen_->fire((float)nPixel,(float)sdPixels_)), float(0.) ); - //convert to MIP again + //convert to MIP again and saturate + float totalMIPs(totalIniMIPs); if(nTotalPE_!=nPixel && (nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)>0 ) totalMIPs = (nTotalPE_/nPEperMIP_)*log((nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)); else @@ -77,7 +78,7 @@ void HGCHEbackDigitizer::runCaliceLikeDigitizer(std::auto_ptr Date: Mon, 15 Sep 2014 16:39:46 +0200 Subject: [PATCH 107/252] fixing shaper --- .../interface/HGCDigitizerBase.h | 22 +++++++++++++------ 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index d18123380fbf2..d3d0a5b1336d2 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -89,8 +89,13 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } + //bool doDebug(newDataFrame[4].adc()>4); + //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << " -> "; + //run the shaper - runShaper(newDataFrame); + newDataFrame=runShaper(newDataFrame); + + //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << std::endl; //check if 5th time sample is above threshold if( newDataFrame[4].adc() < adcThreshold_ ) continue; @@ -103,14 +108,15 @@ class HGCDigitizerBase { /** @short applies a shape to each time sample and propagates the tails to the subsequent time samples */ - void runShaper(D &dataFrame) + D runShaper(D &dataFrame) { + D newDataFrame; + //bool doDebug(dataFrame[4].adc()>adcThreshold_); for(int it=0; it "; if(shaperN_*shaperTau_>0){ for(int jt=0; jt Date: Mon, 15 Sep 2014 17:16:44 +0200 Subject: [PATCH 108/252] fixing initialization ug --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index d3d0a5b1336d2..61de8cbf229ad 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -88,7 +88,7 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } - + //bool doDebug(newDataFrame[4].adc()>4); //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << " -> "; @@ -99,6 +99,8 @@ class HGCDigitizerBase { //check if 5th time sample is above threshold if( newDataFrame[4].adc() < adcThreshold_ ) continue; + + //if(doDebug) std::cout << "Accept" << std::endl; //add to collection to produce coll->push_back(newDataFrame); @@ -110,14 +112,17 @@ class HGCDigitizerBase { */ D runShaper(D &dataFrame) { - D newDataFrame; + D newDataFrame(dataFrame.id()); //bool doDebug(dataFrame[4].adc()>adcThreshold_); + for(int it=0; it "; + if(shaperN_*shaperTau_>0){ for(int jt=0; jt Date: Mon, 15 Sep 2014 21:28:57 +0200 Subject: [PATCH 109/252] fixing tof delay... --- .../HGCSimProducers/interface/HGCDigitizer.h | 7 ++- .../interface/HGCDigitizerBase.h | 55 +++++++++---------- .../HGCSimProducers/src/HGCDigitizer.cc | 12 ++-- .../MixingModule/python/hgcalDigitizer_cfi.py | 3 + 4 files changed, 42 insertions(+), 35 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h index f04500c8c749e..bd26f5b287ee7 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h @@ -80,10 +80,11 @@ private : //subdetector id ForwardSubdetector mySubDet_; - //reference speed to evaluate time of arrival - //at the sensititive detector - //assuming the center of CMS + //reference speed to evaluate time of arrival at the sensititive detector, assuming the center of CMS float refSpeed_; + + //delay to apply after evaluating time of arrival at the sensitive detector + float tofDelay_; }; #endif diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 61de8cbf229ad..df3f3d81880e9 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -66,11 +66,10 @@ class HGCDigitizerBase { { //create a new data frame - D newDataFrame( it->first ); + D rawDataFrame( it->first ); for(size_t i=0; isecond.size(); i++) { - //convert total energy GeV->keV->ADC counts double totalEn=(it->second)[i]*1e6; @@ -86,59 +85,59 @@ class HGCDigitizerBase { HGCSample singleSample; singleSample.set(0, totalEnInt); - newDataFrame.setSample(i, singleSample); + rawDataFrame.setSample(i, singleSample); } - //bool doDebug(newDataFrame[4].adc()>4); - //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << " -> "; + /* bool doDebug(rawDataFrame[3].adc()>2); */ + /* if(doDebug) */ + /* { */ + /* for(size_t iti=0;iti<6; iti++) */ + /* std::cout << rawDataFrame[iti].adc() << "(" << (it->second)[iti]*1e6 << ") ,"; */ + /* std::cout << "->"; */ + /* } */ //run the shaper - newDataFrame=runShaper(newDataFrame); - - //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << std::endl; - + runShaper(rawDataFrame); + + /* if(doDebug) */ + /* { */ + /* for(size_t iti=0;iti<6; iti++) */ + /* std::cout << rawDataFrame[iti].adc() << ","; */ + /* std::cout << std::endl; */ + /* } */ + //check if 5th time sample is above threshold - if( newDataFrame[4].adc() < adcThreshold_ ) continue; + if( rawDataFrame[4].adc() < adcThreshold_ ) continue; - //if(doDebug) std::cout << "Accept" << std::endl; - //add to collection to produce - coll->push_back(newDataFrame); + coll->push_back(rawDataFrame); } } /** @short applies a shape to each time sample and propagates the tails to the subsequent time samples */ - D runShaper(D &dataFrame) + void runShaper(D &dataFrame) { - D newDataFrame(dataFrame.id()); - - //bool doDebug(dataFrame[4].adc()>adcThreshold_); - + std::vector oldADC(dataFrame.size()); for(int it=0; it "; + oldADC[it]=dataFrame[it].adc(); + uint16_t newADC(oldADC[it]); if(shaperN_*shaperTau_>0){ for(int jt=0; jt("hitCollection"); @@ -27,7 +27,8 @@ HGCDigitizer::HGCDigitizer(const edm::ParameterSet& ps) : maxSimHitsAccTime_ = ps.getParameter< uint32_t >("maxSimHitsAccTime"); bxTime_ = ps.getParameter< int32_t >("bxTime"); digitizationType_ = ps.getParameter< uint32_t >("digitizationType"); - + tofDelay_ = ps.getParameter< double >("tofDelay"); + //get the random number generator edm::Service rng; if ( ! rng.isAvailable()) { @@ -155,11 +156,14 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i //distance to the center of the detector float dist2center( geom->getPosition(id).mag() ); - //hit time: [time()]=ns [centerDist]=cm [refSpeed_]=cm/ns + //hit time: [time()]=ns [centerDist]=cm [refSpeed_]=cm/ns + delay by 1ns //accumulate in 6 buckets of 25ns (4 pre-samples, 1 in-time, 1 post-sample) - int itime=floor( (hit_it->time()-dist2center/refSpeed_)/bxTime_ ) ; + float tof(hit_it->time()-dist2center/refSpeed_+tofDelay_); + int itime=floor( tof/bxTime_ ) ; + itime += bxCrossing; itime += 4; + if(itime<0 || itime>5) continue; //energy deposited diff --git a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py index 53f2824349654..2ed75dadad815 100644 --- a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py +++ b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py @@ -8,6 +8,7 @@ digiCollection = cms.string("HGCDigisEE"), maxSimHitsAccTime = cms.uint32(100), bxTime = cms.int32(25), + tofDelay = cms.double(1), digitizationType = cms.uint32(0), makeDigiSimLinks = cms.bool(False), digiCfg = cms.PSet( mipInKeV = cms.double(55.1), @@ -26,6 +27,7 @@ digiCollection = cms.string("HGCDigisHEfront"), maxSimHitsAccTime = cms.uint32(100), bxTime = cms.int32(25), + tofDelay = cms.double(1), digitizationType = cms.uint32(0), makeDigiSimLinks = cms.bool(False), digiCfg = cms.PSet( mipInKeV = cms.double(85.0), @@ -45,6 +47,7 @@ digiCollection = cms.string("HGCDigisHEback"), maxSimHitsAccTime = cms.uint32(100), bxTime = cms.int32(25), + tofDelay = cms.double(1), digitizationType = cms.uint32(1), makeDigiSimLinks = cms.bool(False), digiCfg = cms.PSet( mipInKeV = cms.double(1498.4), From ba2e4d267a396c6090538d5c541186590505bc98 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Mon, 15 Sep 2014 22:57:46 +0200 Subject: [PATCH 110/252] removing bx time subtraction - mix module takes care of it --- SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc index 0ffb8ac8b7272..abf3a4e5e9173 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc @@ -132,7 +132,6 @@ void HGCDigitizer::accumulate(PileUpEventPrincipal const& e, edm::EventSetup con // void HGCDigitizer::accumulate(edm::Handle const &hits, int bxCrossing,const edm::ESHandle &geom) { - if(!geom.isValid()) return; const HGCalTopology &topo=geom->topology(); const HGCalDDDConstants &dddConst=topo.dddConstants(); @@ -161,9 +160,10 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i float tof(hit_it->time()-dist2center/refSpeed_+tofDelay_); int itime=floor( tof/bxTime_ ) ; - itime += bxCrossing; + //no need to add bx crossing - tof comes already corrected from the mixing module + //itime += bxCrossing; itime += 4; - + if(itime<0 || itime>5) continue; //energy deposited From a8a24af52da1ada56d70ea6ada2e3831df74a7d3 Mon Sep 17 00:00:00 2001 From: Alja Mrak-Tadel Date: Tue, 16 Sep 2014 10:55:16 -0700 Subject: [PATCH 111/252] Revert previous commit. --- .../interface/FWRecoGeometryESProducer.h | 3 + .../Geometry/src/FWRecoGeometryESProducer.cc | 197 +++++++++++------- 2 files changed, 128 insertions(+), 72 deletions(-) diff --git a/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h b/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h index a0e0877df3973..c9423611f6032 100644 --- a/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h +++ b/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h @@ -13,6 +13,7 @@ namespace edm } class CaloGeometry; +class HGCalGeometry; class GlobalTrackingGeometry; class TrackerGeometry; class FWRecoGeometry; @@ -35,6 +36,7 @@ class FWRecoGeometryESProducer : public edm::ESProducer void addDTGeometry( void ); void addRPCGeometry( void ); void addGEMGeometry( void ); + void addME0Geometry( void ); void addPixelBarrelGeometry( void ); void addPixelForwardGeometry( void ); void addTIBGeometry( void ); @@ -49,6 +51,7 @@ class FWRecoGeometryESProducer : public edm::ESProducer edm::ESHandle m_geomRecord; edm::ESHandle m_caloGeom; + std::vector > m_hgcGeom; const TrackerGeometry* m_trackerGeom; boost::shared_ptr m_fwGeometry; diff --git a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc index b6de44336e206..6749f7a3db3e8 100644 --- a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc +++ b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc @@ -7,6 +7,7 @@ #include "Geometry/CommonDetUnit/interface/GlobalTrackingGeometry.h" #include "Geometry/CaloGeometry/interface/CaloGeometry.h" #include "Geometry/CaloGeometry/interface/CaloCellGeometry.h" +#include "Geometry/FCalGeometry/interface/HGCalGeometry.h" #include "Geometry/CSCGeometry/interface/CSCGeometry.h" #include "Geometry/DTGeometry/interface/DTGeometry.h" #include "Geometry/CSCGeometry/interface/CSCChamber.h" @@ -15,6 +16,7 @@ #include "Geometry/DTGeometry/interface/DTLayer.h" #include "Geometry/RPCGeometry/interface/RPCGeometry.h" #include "Geometry/GEMGeometry/interface/GEMGeometry.h" +#include "Geometry/GEMGeometry/interface/ME0Geometry.h" #include "Geometry/Records/interface/CaloGeometryRecord.h" #include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" #include "Geometry/TrackerGeometryBuilder/interface/RectangularPixelTopology.h" @@ -25,7 +27,6 @@ #include "Geometry/CommonTopologies/interface/RectangularStripTopology.h" #include "Geometry/CommonTopologies/interface/TrapezoidalStripTopology.h" -#include "TNamed.h" # define ADD_PIXEL_TOPOLOGY( rawid, detUnit ) \ const PixelGeomDetUnit* det = dynamic_cast( detUnit ); \ if( det ) \ @@ -63,7 +64,7 @@ } \ } \ -FWRecoGeometryESProducer::FWRecoGeometryESProducer( const edm::ParameterSet& ) +FWRecoGeometryESProducer::FWRecoGeometryESProducer( const edm::ParameterSet& ps ) : m_current( -1 ) { setWhatProduced( this ); @@ -85,6 +86,13 @@ FWRecoGeometryESProducer::produce( const FWRecoGeometryRecord& record ) m_trackerGeom = (const TrackerGeometry*) m_geomRecord->slaveGeometry( detId ); record.getRecord().get( m_caloGeom ); + + // m_hgcGeom.push_back(edm::ESHandle()); + // record.getRecord().get( "HGCalEESensitive", m_hgcGeom.back() ); + // m_hgcGeom.push_back(edm::ESHandle()); + // record.getRecord().get( "HGCalHESiliconSensitive", m_hgcGeom.back() ); + // m_hgcGeom.push_back(edm::ESHandle()); + // record.getRecord().get( "HGCalHEScintillatorSensitive", m_hgcGeom.back() ); addPixelBarrelGeometry( ); addPixelForwardGeometry(); @@ -95,18 +103,8 @@ FWRecoGeometryESProducer::produce( const FWRecoGeometryRecord& record ) addDTGeometry(); addCSCGeometry(); addRPCGeometry(); - - try - { - addGEMGeometry(); - } - catch( cms::Exception& exception ) - { - edm::LogWarning("FWRecoGeometryProducerException") - << "Exception caught while building GEM geometry: " << exception.what() - << std::endl; - } - + addGEMGeometry(); + addME0Geometry(); addCaloGeometry(); m_fwGeometry->idToName.resize( m_current + 1 ); @@ -121,12 +119,8 @@ FWRecoGeometryESProducer::addCSCGeometry( void ) { DetId detId( DetId::Muon, 2 ); const CSCGeometry* cscGeometry = (const CSCGeometry*) m_geomRecord->slaveGeometry( detId ); - for( auto it = cscGeometry->chambers().begin(), - end = cscGeometry->chambers().end(); - it != end; ++it ) + for(auto chamber : cscGeometry->chambers()) { - const CSCChamber *chamber = *it; - if( chamber ) { unsigned int rawid = chamber->geographicalId(); @@ -135,12 +129,8 @@ FWRecoGeometryESProducer::addCSCGeometry( void ) // // CSC layers geometry // - for( std::vector< const CSCLayer* >::const_iterator lit = chamber->layers().begin(), - lend = chamber->layers().end(); - lit != lend; ++lit ) + for(auto layer : chamber->layers()) { - const CSCLayer* layer = *lit; - if( layer ) { unsigned int rawid = layer->geographicalId(); @@ -173,12 +163,8 @@ FWRecoGeometryESProducer::addDTGeometry( void ) // // DT chambers geometry // - for( auto it = dtGeometry->chambers().begin(), - end = dtGeometry->chambers().end(); - it != end; ++it ) + for(auto chamber : dtGeometry->chambers()) { - const DTChamber *chamber = *it; - if( chamber ) { unsigned int rawid = chamber->geographicalId().rawId(); @@ -188,12 +174,8 @@ FWRecoGeometryESProducer::addDTGeometry( void ) } // Fill in DT layer parameters - for( auto it = dtGeometry->layers().begin(), - end = dtGeometry->layers().end(); - it != end; ++it ) + for(auto layer : dtGeometry->layers()) { - const DTLayer* layer = *it; - if( layer ) { unsigned int rawid = layer->id().rawId(); @@ -225,32 +207,29 @@ FWRecoGeometryESProducer::addRPCGeometry( void ) // RPC rolls geometry // DetId detId( DetId::Muon, 3 ); - const RPCGeometry* rpcGeom = (const RPCGeometry*) m_geomRecord->slaveGeometry( detId ); - for( auto it = rpcGeom->rolls().begin(), - end = rpcGeom->rolls().end(); - it != end; ++it ) + + try { - const RPCRoll* roll = (*it); - if( roll ) + const RPCGeometry* rpcGeom = (const RPCGeometry*) m_geomRecord->slaveGeometry( detId ); + for(auto roll : rpcGeom->rolls()) { - unsigned int rawid = roll->geographicalId().rawId(); - unsigned int current = insert_id( rawid ); - fillShapeAndPlacement( current, roll ); - - const StripTopology& topo = roll->specificTopology(); - m_fwGeometry->idToName[current].topology[0] = topo.nstrips(); - m_fwGeometry->idToName[current].topology[1] = topo.stripLength(); - m_fwGeometry->idToName[current].topology[2] = topo.pitch(); + if( roll ) + { + unsigned int rawid = roll->geographicalId().rawId(); + unsigned int current = insert_id( rawid ); + fillShapeAndPlacement( current, roll ); + + const StripTopology& topo = roll->specificTopology(); + m_fwGeometry->idToName[current].topology[0] = topo.nstrips(); + m_fwGeometry->idToName[current].topology[1] = topo.stripLength(); + m_fwGeometry->idToName[current].topology[2] = topo.pitch(); + } } } - - - try { - RPCDetId id(1, 1, 4, 1, 1, 1, 1 ); - m_geomRecord->slaveGeometry( detId ); - m_fwGeometry->extraDet.Add(new TNamed("RE4", "RPC endcap station 4")); + catch( cms::Exception &exception ) + { + edm::LogInfo("FWRecoGeometry") << "failed to produce RPC geometry " << exception.what() << std::endl; } - catch (...) {} } void @@ -260,29 +239,79 @@ FWRecoGeometryESProducer::addGEMGeometry( void ) // GEM geometry // DetId detId( DetId::Muon, 4 ); - const GEMGeometry* gemGeom = (const GEMGeometry*) m_geomRecord->slaveGeometry( detId ); - for( auto it = gemGeom->etaPartitions().begin(), - end = gemGeom->etaPartitions().end(); - it != end; ++it ) - { - const GEMEtaPartition* roll = (*it); - if( roll ) - { - unsigned int rawid = (*it)->geographicalId().rawId(); - unsigned int current = insert_id( rawid ); - fillShapeAndPlacement( current, roll ); - const StripTopology& topo = roll->specificTopology(); - m_fwGeometry->idToName[current].topology[0] = topo.nstrips(); - m_fwGeometry->idToName[current].topology[1] = topo.stripLength(); - m_fwGeometry->idToName[current].topology[2] = topo.pitch(); + try + { + const GEMGeometry* gemGeom = (const GEMGeometry*) m_geomRecord->slaveGeometry( detId ); + + for(auto roll : gemGeom->etaPartitions()) + { + if( roll ) + { + unsigned int rawid = roll->geographicalId().rawId(); + unsigned int current = insert_id( rawid ); + fillShapeAndPlacement( current, roll ); + + const StripTopology& topo = roll->specificTopology(); + m_fwGeometry->idToName[current].topology[0] = topo.nstrips(); + m_fwGeometry->idToName[current].topology[1] = topo.stripLength(); + m_fwGeometry->idToName[current].topology[2] = topo.pitch(); + + float height = topo.stripLength()/2; + LocalPoint lTop( 0., height, 0.); + LocalPoint lBottom( 0., -height, 0.); + m_fwGeometry->idToName[current].topology[3] = roll->localPitch(lTop); + m_fwGeometry->idToName[current].topology[4] = roll->localPitch(lBottom); + m_fwGeometry->idToName[current].topology[5] = roll->npads(); + } } } - - m_fwGeometry->extraDet.Add(new TNamed("GEM", "GEM muon detector")); + catch( cms::Exception &exception ) + { + edm::LogInfo("FWRecoGeometry") << "failed to produce GEM geometry " << exception.what() << std::endl; + } } +void +FWRecoGeometryESProducer::addME0Geometry( void ) +{ + // + // ME0 geometry + // + DetId detId( DetId::Muon, 5 ); + try + { + const ME0Geometry* me0Geom = (const ME0Geometry*) m_geomRecord->slaveGeometry( detId ); + + for(auto roll : me0Geom->etaPartitions()) + { + if( roll ) + { + unsigned int rawid = roll->geographicalId().rawId(); + unsigned int current = insert_id( rawid ); + fillShapeAndPlacement( current, roll ); + + const StripTopology& topo = roll->specificTopology(); + m_fwGeometry->idToName[current].topology[0] = topo.nstrips(); + m_fwGeometry->idToName[current].topology[1] = topo.stripLength(); + m_fwGeometry->idToName[current].topology[2] = topo.pitch(); + + float height = topo.stripLength()/2; + LocalPoint lTop( 0., height, 0.); + LocalPoint lBottom( 0., -height, 0.); + m_fwGeometry->idToName[current].topology[3] = roll->localPitch(lTop); + m_fwGeometry->idToName[current].topology[4] = roll->localPitch(lBottom); + m_fwGeometry->idToName[current].topology[5] = roll->npads(); + } + } + } + catch( cms::Exception &exception ) + { + edm::LogInfo("FWRecoGeometry") << "failed to produce ME0 geometry " << exception.what() << std::endl; + } +} + void FWRecoGeometryESProducer::addPixelBarrelGeometry( void ) { @@ -421,6 +450,30 @@ FWRecoGeometryESProducer::addCaloGeometry( void ) unsigned int id = insert_id( it->rawId()); fillPoints( id, cor.begin(), cor.end()); } + + // do the HGCal if we actually got it + for( const auto& hgcGeom : m_hgcGeom ){ + if( hgcGeom.product() ) { + float minZ = 1e6, maxZ = 0; + float minRho = 1e6, maxRho = 0; + const std::vector& hids = hgcGeom->getValidDetIds(); + std::cout << "Processing: " << hgcGeom->cellElement() << std::endl; + std::cout << "got hgc detector with " << hids.size() << " valid det ids!" << std::endl; + for( const auto& hid : hids ) { + const HGCalGeometry::CornersVec cor( std::move( hgcGeom->getCorners( hid ) ) ); + for( const auto& corner : cor ) { + minZ = std::min(std::abs(corner.z()),minZ); + maxZ = std::max(std::abs(corner.z()),maxZ); + minRho = std::min(std::hypot(corner.x(),corner.y()), minRho); + maxRho = std::max(std::hypot(corner.x(),corner.y()), maxRho); + } + unsigned int id = insert_id( hid.rawId() ); + fillPoints( id, cor.begin(), cor.end() ); + } + std::cout << "Got minZ = " << minZ << " got maxZ = " << maxZ + << " minRho = " << minRho << " maxRho = " << maxRho << std::endl; + } + } } unsigned int From 34fbcff80c640df3a366e0eee18140401b3b358e Mon Sep 17 00:00:00 2001 From: Alja Mrak-Tadel Date: Tue, 16 Sep 2014 11:02:45 -0700 Subject: [PATCH 112/252] Write extra detectors RE4 and GEM. --- Fireworks/Geometry/src/FWRecoGeometryESProducer.cc | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc index 6749f7a3db3e8..975bda5d7799e 100644 --- a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc +++ b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc @@ -1,3 +1,4 @@ +#include "TNamed.h" #include "Fireworks/Geometry/interface/FWRecoGeometryESProducer.h" #include "Fireworks/Geometry/interface/FWRecoGeometry.h" #include "Fireworks/Geometry/interface/FWRecoGeometryRecord.h" @@ -230,6 +231,14 @@ FWRecoGeometryESProducer::addRPCGeometry( void ) { edm::LogInfo("FWRecoGeometry") << "failed to produce RPC geometry " << exception.what() << std::endl; } + + + try { + RPCDetId id(1, 1, 4, 1, 1, 1, 1 ); + m_geomRecord->slaveGeometry( detId ); + m_fwGeometry->extraDet.Add(new TNamed("RE4", "RPC endcap station 4")); + } + catch (...) {} } void @@ -265,6 +274,8 @@ FWRecoGeometryESProducer::addGEMGeometry( void ) m_fwGeometry->idToName[current].topology[5] = roll->npads(); } } + + m_fwGeometry->extraDet.Add(new TNamed("GEM", "GEM muon detector")); } catch( cms::Exception &exception ) { From 2f0356754d3c342d42b9fc915aeb20b4235abfc6 Mon Sep 17 00:00:00 2001 From: Alja Mrak-Tadel Date: Tue, 16 Sep 2014 13:39:09 -0700 Subject: [PATCH 113/252] Add ME0 to tgeo reco. Organise TGeoManager colors. --- .../interface/FWTGeoRecoGeometryESProducer.h | 3 +- .../src/FWTGeoRecoGeometryESProducer.cc | 168 ++++++++++++------ 2 files changed, 119 insertions(+), 52 deletions(-) diff --git a/Fireworks/Geometry/interface/FWTGeoRecoGeometryESProducer.h b/Fireworks/Geometry/interface/FWTGeoRecoGeometryESProducer.h index a24d363628f0d..05b2d547d9d2c 100644 --- a/Fireworks/Geometry/interface/FWTGeoRecoGeometryESProducer.h +++ b/Fireworks/Geometry/interface/FWTGeoRecoGeometryESProducer.h @@ -31,7 +31,7 @@ class FWTGeoRecoGeometryESProducer : public edm::ESProducer { enum ERecoDet {kDummy, kSiPixel, kSiStrip, - kMuonDT, kMuonRPC, kMuonCSC, kMuonGEM, + kMuonDT, kMuonRPC, kMuonCSC, kMuonGEM, kMuonME0, kECal, kHCal, kHGCE, kHGCH }; public: @@ -65,6 +65,7 @@ class FWTGeoRecoGeometryESProducer : public edm::ESProducer void addDTGeometry(); void addRPCGeometry(); void addGEMGeometry(); + void addME0Geometry(); void addEcalCaloGeometry(); void addHcalCaloGeometryBarrel(); void addHcalCaloGeometryEndcap(); diff --git a/Fireworks/Geometry/src/FWTGeoRecoGeometryESProducer.cc b/Fireworks/Geometry/src/FWTGeoRecoGeometryESProducer.cc index 1df097d55fcde..096d7f740e09c 100644 --- a/Fireworks/Geometry/src/FWTGeoRecoGeometryESProducer.cc +++ b/Fireworks/Geometry/src/FWTGeoRecoGeometryESProducer.cc @@ -12,6 +12,7 @@ #include "DataFormats/SiStripDetId/interface/TECDetId.h" #include "DataFormats/MuonDetId/interface/RPCDetId.h" #include "DataFormats/MuonDetId/interface/GEMDetId.h" +#include "DataFormats/MuonDetId/interface/ME0DetId.h" #include "DataFormats/EcalDetId/interface/EcalSubdetector.h" #include "DataFormats/HcalDetId/interface/HcalSubdetector.h" #include "DataFormats/EcalDetId/interface/EBDetId.h" @@ -34,6 +35,7 @@ #include "Geometry/RPCGeometry/interface/RPCGeometry.h" #include "Geometry/GEMGeometry/interface/GEMEtaPartition.h" #include "Geometry/GEMGeometry/interface/GEMGeometry.h" +#include "Geometry/GEMGeometry/interface/ME0Geometry.h" #include "Geometry/Records/interface/CaloGeometryRecord.h" #include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h" #include "Geometry/TrackerGeometryBuilder/interface/RectangularPixelTopology.h" @@ -158,6 +160,19 @@ TGeoVolume* FWTGeoRecoGeometryESProducer::GetTopHolder(const char* prefix, EReco return res; } +namespace { + +enum GMCol { Green = 4, + Blue0 = 13, Blue1 = 24, Blue2 = 6, + Yellow0 = 3, Yellow1 = 16, + Pink = 10, + Red = 29, Orange0 = 79, Orange1 = 14, + Magenta = 8, + Gray = 12 +}; + +} + TGeoMedium* FWTGeoRecoGeometryESProducer::GetMedium(ERecoDet det) @@ -168,48 +183,62 @@ FWTGeoRecoGeometryESProducer::GetMedium(ERecoDet det) std::string name; int color; - // see TGeoManager::DefaultColors() + + switch (det) { + // TRACKER case kSiPixel: name = "SiPixel"; - color = 4;//kGreen-10 + color = GMCol::Green; break; + case kSiStrip: name = "SiStrip"; - color = 29; // kOrange+9 + color = GMCol::Gray; break; + // MUON case kMuonDT: name = "MuonDT"; - color = 13; // kBlue -10 - break; - case kMuonGEM: - name = "MuonGEM"; - color = 16; //kYellow+1 + color = GMCol::Blue2; break; + case kMuonRPC: name = "MuonRPC"; - color = 10; //kRed-10 + color = GMCol::Red; + break; + + case kMuonGEM: + name = "MuonGEM"; + color = GMCol::Yellow1; break; + case kMuonCSC: - name = "MuonCSC"; // kMagenta - color = 9; + name = "MuonCSC"; + color = GMCol::Gray; break; + + case kMuonME0: + name = "MuonME0"; + color = GMCol::Yellow0; + break; + + // CALO case kECal: name = "ECal"; - color = 6; + color = GMCol::Blue2; break; case kHCal: name = "HCal"; - color = 10; // kRed-10 + color = GMCol::Orange1; break; case kHGCE: name = "HGCEE"; - color = 10; + color = GMCol::Blue2; break; case kHGCH: name = "HGCEH"; - color = 6; // kBlue -7 + color = GMCol::Blue1; break; default: printf("invalid medium id \n"); @@ -278,33 +307,26 @@ FWTGeoRecoGeometryESProducer::produce( const FWTGeoRecoGeometryRecord& record ) top->SetLineColor( kBlue ); addPixelBarrelGeometry(); - addPixelForwardGeometry(); + addTIBGeometry(); addTIDGeometry(); addTOBGeometry(); addTECGeometry(); addDTGeometry(); + addCSCGeometry(); addRPCGeometry(); - try { - addGEMGeometry(); - } - catch ( cms::Exception& exception ) { - edm::LogWarning("FWRecoGeometryProducerException") - << "addGEMGeometry() Exception caught while building GEM geometry: " << exception.what() - << std::endl; - } + addME0Geometry(); + addGEMGeometry(); - - addEcalCaloGeometry(); - + addEcalCaloGeometry(); addHcalCaloGeometryBarrel(); addHcalCaloGeometryEndcap(); - addHGCal(); - + geom->DefaultColors(); + // printf("==== geo manager NNodes = %d \n", geom->GetNNodes()); geom->CloseGeometry(); return m_fwGeometry; @@ -722,35 +744,39 @@ FWTGeoRecoGeometryESProducer::addCSCGeometry() void FWTGeoRecoGeometryESProducer::addGEMGeometry() { - - DetId detId( DetId::Muon, MuonSubdetId::GEM ); - const GEMGeometry* gemGeom = (const GEMGeometry*) m_geomRecord->slaveGeometry( detId ); + try { + DetId detId( DetId::Muon, MuonSubdetId::GEM ); + const GEMGeometry* gemGeom = (const GEMGeometry*) m_geomRecord->slaveGeometry( detId ); - TGeoVolume* tv = GetTopHolder("Muon", kMuonRPC); - TGeoVolume *assembly = GetDaughter(tv, "GEM", kMuonGEM); + TGeoVolume* tv = GetTopHolder("Muon", kMuonRPC); + TGeoVolume *assembly = GetDaughter(tv, "GEM", kMuonGEM); - for( auto it = gemGeom->etaPartitions().begin(), - end = gemGeom->etaPartitions().end(); - it != end; ++it ) - { - const GEMEtaPartition* roll = (*it); - if( roll ) + for( auto it = gemGeom->etaPartitions().begin(), + end = gemGeom->etaPartitions().end(); + it != end; ++it ) { - GEMDetId detid = roll->geographicalId(); - std::stringstream s; - s << detid; - std::string name = s.str(); + const GEMEtaPartition* roll = (*it); + if( roll ) + { + GEMDetId detid = roll->geographicalId(); + std::stringstream s; + s << detid; + std::string name = s.str(); - TGeoVolume* child = createVolume( name, roll, kMuonGEM ); + TGeoVolume* child = createVolume( name, roll, kMuonGEM ); - TGeoVolume* holder = GetDaughter(assembly, "ROLL Region", kMuonGEM , detid.region()); - holder = GetDaughter(holder, "Ring", kMuonGEM , detid.ring()); - holder = GetDaughter(holder, "Station", kMuonGEM , detid.station()); - holder = GetDaughter(holder, "Layer", kMuonGEM , detid.layer()); - holder = GetDaughter(holder, "Chamber", kMuonGEM , detid.chamber()); + TGeoVolume* holder = GetDaughter(assembly, "ROLL Region", kMuonGEM , detid.region()); + holder = GetDaughter(holder, "Ring", kMuonGEM , detid.ring()); + holder = GetDaughter(holder, "Station", kMuonGEM , detid.station()); + holder = GetDaughter(holder, "Layer", kMuonGEM , detid.layer()); + holder = GetDaughter(holder, "Chamber", kMuonGEM , detid.chamber()); - AddLeafNode(holder, child, name.c_str(), createPlacement(*it)); + AddLeafNode(holder, child, name.c_str(), createPlacement(*it)); + } } + }catch (cms::Exception &exception) { + edm::LogInfo("FWRecoGeometry") << "failed to produce GEM geometry " << exception.what() << std::endl; + } } @@ -792,6 +818,46 @@ FWTGeoRecoGeometryESProducer::addRPCGeometry( ) } + +void +FWTGeoRecoGeometryESProducer::addME0Geometry( ) +{ + TGeoVolume* tv = GetTopHolder("Muon", kMuonCSC); + TGeoVolume *assembly = GetDaughter(tv, "ME0", kMuonME0); + + DetId detId( DetId::Muon, 5 ); + try + { + const ME0Geometry* me0Geom = (const ME0Geometry*) m_geomRecord->slaveGeometry( detId ); + + for(auto roll : me0Geom->etaPartitions()) + { + if( roll ) + { + unsigned int rawid = roll->geographicalId().rawId(); + // std::cout << "AMT FWTTTTRecoGeometryES\n" << rawid ; + + ME0DetId detid(rawid); + std::stringstream s; + s << detid; + std::string name = s.str(); + TGeoVolume* child = createVolume( name, roll, kMuonME0 ); + + TGeoVolume* holder = GetDaughter(assembly, "Region", kMuonME0, detid.region()); + holder = GetDaughter(holder, "Layer", kMuonME0, detid.layer()); + holder = GetDaughter(holder, "Chamber", kMuonME0, detid.chamber()); + AddLeafNode(holder, child, name.c_str(), createPlacement(roll)); + + + } + } + } + catch( cms::Exception &exception ) + { + edm::LogInfo("FWRecoGeometry") << "failed to produce ME0 geometry " << exception.what() << std::endl; + } +} + namespace { double etatotheta(double eta) From eed00590ad7508027fd2b645fdcacf42a0017a1a Mon Sep 17 00:00:00 2001 From: Matthias Wolf Date: Thu, 1 May 2014 16:26:01 -0400 Subject: [PATCH 114/252] Fix setting the # of presamples for HcalUpgradeDataFrame. One of the constructors will use an uninitialized value of the presamples and modify it with a target presample size. --- DataFormats/HcalDigi/src/HcalUpgradeDataFrame.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DataFormats/HcalDigi/src/HcalUpgradeDataFrame.cc b/DataFormats/HcalDigi/src/HcalUpgradeDataFrame.cc index 0ae0fa4a70a9f..d7bf416b40d50 100644 --- a/DataFormats/HcalDigi/src/HcalUpgradeDataFrame.cc +++ b/DataFormats/HcalDigi/src/HcalUpgradeDataFrame.cc @@ -32,9 +32,9 @@ void HcalUpgradeDataFrame::setSize(int size) { } void HcalUpgradeDataFrame::setPresamples(int presamples) { - if (presamples>MAXSAMPLES) presamples_|=MAXSAMPLES&0xF; + if (presamples>MAXSAMPLES) presamples_=MAXSAMPLES&0xF; else if (presamples<=0) presamples_=0; - else presamples_|=presamples&0xF; + else presamples_=presamples&0xF; } void HcalUpgradeDataFrame::setReadoutIds(const HcalElectronicsId& eid) { From 96e306018ee1ae6bf809fd5453a42939013dfbf9 Mon Sep 17 00:00:00 2001 From: Suchandra Date: Fri, 19 Sep 2014 09:41:45 +0200 Subject: [PATCH 115/252] updating the package to adopt to the cganged made by @wmtford in the pixel digitiser --- .../interface/DigitizerUtility.h | 11 ++- .../interface/PSPDigitizerAlgorithm.h | 19 +---- .../interface/PSSDigitizerAlgorithm.h | 19 +---- .../interface/Phase2TrackerDigitizer.h | 26 ++++--- .../Phase2TrackerDigitizerAlgorithm.h | 8 +- .../interface/PixelDigitizerAlgorithm.h | 24 +----- .../interface/SSDigitizerAlgorithm.h | 16 +--- .../plugins/PSPDigitizerAlgorithm.cc | 39 +++++----- .../plugins/PSSDigitizerAlgorithm.cc | 49 ++++++------ .../plugins/Phase2TrackerDigitizer.cc | 76 +++++++++++-------- .../Phase2TrackerDigitizerAlgorithm.cc | 34 +++++---- .../plugins/PixelDigitizerAlgorithm.cc | 55 ++++++++------ .../plugins/SSDigitizerAlgorithm.cc | 26 ++++--- 13 files changed, 194 insertions(+), 208 deletions(-) diff --git a/SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h b/SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h index 89aea23a272e7..76c64c2002e96 100644 --- a/SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h +++ b/SimTracker/SiPhase2Digitizer/interface/DigitizerUtility.h @@ -24,9 +24,8 @@ namespace DigitizerUtility { _frac.pop_back(); } - Amplitude(float amp, const PSimHit* hitp, float frac) : - _amp(amp), _frac(1, frac), _hitInfo(new SimHitInfoForLinks(hitp)) - { + Amplitude( float amp, const PSimHit* hitp, size_t hitIndex, unsigned int tofBin, float frac) : + _amp(amp), _frac(1, frac), _hitInfo(new SimHitInfoForLinks(hitp, hitIndex, tofBin)) { // in case of digi from noisypixels // the MC information are removed if (_frac[0] < -0.5) { @@ -63,6 +62,12 @@ namespace DigitizerUtility { const EncodedEventId& eventId() const { return _hitInfo->eventId_; } + const unsigned int hitIndex() const { + return _hitInfo->hitIndex_; + } + const unsigned int tofBin() const { + return _hitInfo->tofBin_; + } void operator+= (const float& amp) { _amp += amp; } diff --git a/SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h index 2dab32a14bfb9..4a32fed8ee972 100644 --- a/SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h +++ b/SimTracker/SiPhase2Digitizer/interface/PSPDigitizerAlgorithm.h @@ -6,20 +6,7 @@ #include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" // forward declarations -// For the random numbers -//namespace CLHEP { -// class HepRandomEngine; -//} -// -//namespace edm { -// class EventSetup; -// class ParameterSet; -//} - -//class PixelDigi; -//class PixelDigiSimLink; -//class PixelGeomDetUnit; -//class TrackerTopology; +class TrackerTopology; class PSPDigitizerAlgorithm: public Phase2TrackerDigitizerAlgorithm { public: @@ -33,9 +20,11 @@ class PSPDigitizerAlgorithm: public Phase2TrackerDigitizerAlgorithm { // run the algorithm to digitize a single det void accumulateSimHits(const std::vector::const_iterator inputBegin, const std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield); - void digitize(const PixelGeomDetUnit* pixdet, + void digitize(const Phase2TrackerGeomDetUnit* pixdet, std::vector& digis, std::vector& simlinks, const TrackerTopology* tTopo); diff --git a/SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h index 258c1febca208..fde5f4fcccca8 100644 --- a/SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h +++ b/SimTracker/SiPhase2Digitizer/interface/PSSDigitizerAlgorithm.h @@ -6,20 +6,7 @@ #include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" // forward declarations -// For the random numbers -//namespace CLHEP { -// class HepRandomEngine; -//} -// -//namespace edm { -// class EventSetup; -// class ParameterSet; -//} -// -//class PixelDigi; -//class PixelDigiSimLink; -//class PixelGeomDetUnit; -//class TrackerTopology; +class TrackerTopology; class PSSDigitizerAlgorithm :public Phase2TrackerDigitizerAlgorithm { public: @@ -33,9 +20,11 @@ class PSSDigitizerAlgorithm :public Phase2TrackerDigitizerAlgorithm { // run the algorithm to digitize a single det void accumulateSimHits(const std::vector::const_iterator inputBegin, const std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield); - void digitize(const PixelGeomDetUnit* pixdet, + void digitize(const Phase2TrackerGeomDetUnit* pixdet, std::vector& digis, std::vector& simlinks, const TrackerTopology* tTopo); diff --git a/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h index 518067e5cda8d..696f1cd249310 100644 --- a/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h +++ b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizer.h @@ -24,6 +24,7 @@ #include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" +// Forward declaration namespace CLHEP { class HepRandomEngine; } @@ -38,24 +39,15 @@ namespace edm { class MagneticField; class PileUpEventPrincipal; -class PixelGeomDetUnit; -//class PixelDigi; -//class PixelDigiSimLink; class PSimHit; class Phase2TrackerDigitizerAlgorithm; class TrackerGeometry; namespace cms { - class Phase2TrackerDigitizer : public DigiAccumulatorMixMod { + class Phase2TrackerDigitizer: public DigiAccumulatorMixMod { public: - // typedef to change names of current pixel types to phase 2 types - typedef PixelGeomDetUnit Phase2TrackerGeomDetUnit; - typedef PixelDigi Phase2TrackerDigi; - typedef PixelDigiSimLink Phase2TrackerDigiSimLink; - typedef PixelTopology Phase2TrackerTopology; - explicit Phase2TrackerDigitizer(const edm::ParameterSet& conf, edm::EDProducer& mixMod); virtual ~Phase2TrackerDigitizer(); virtual void initializeEvent(edm::Event const& e, edm::EventSetup const& c) override; @@ -77,8 +69,20 @@ namespace cms private: typedef std::vector vstring; - void accumulatePixelHits(edm::Handle >); + void accumulatePixelHits(edm::Handle >, + size_t globalSimHitIndex, + const unsigned int tofBin); + bool first_; + /** @brief Offset to add to the index of each sim hit to account for which crossing it's in. + * + * I need to know what each sim hit index will be when the hits from all crossing frames are merged into + * one collection (assuming the MixingModule is configured to create the crossing frame for all sim hits). + * To do this I'll record how many hits were in each crossing, and then add that on to the index for a given + * hit in a given crossing. This assumes that the crossings are processed in the same order here as they are + * put into the crossing frame, which I'm pretty sure is true.
+ * The key is the name of the sim hit collection. */ + std::map crossingSimHitIndexOffset_; std::map > algomap_; const std::string hitsProducer_; const vstring trackerContainers_; diff --git a/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h index 3c470d2e9ba8a..f0a9d17dfcd9a 100644 --- a/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h +++ b/SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerAlgorithm.h @@ -30,10 +30,6 @@ namespace edm { class DetId; class GaussianTailNoiseGenerator; -class PixelDigi; -class PixelDigiSimLink; -class PixelGeomDetUnit; -class PixelTopology; class SiG4UniversalFluctuation; class SiPixelFedCablingMap; class SiPixelGainCalibrationOfflineSimService; @@ -55,6 +51,8 @@ class Phase2TrackerDigitizerAlgorithm { // run the algorithm to digitize a single det virtual void accumulateSimHits(const std::vector::const_iterator inputBegin, const std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield) = 0; virtual void digitize(const Phase2TrackerGeomDetUnit* pixdet, @@ -166,6 +164,8 @@ class Phase2TrackerDigitizerAlgorithm { const std::vector& ionization_points, std::vector& collection_points) const; void induce_signal(const PSimHit& hit, + const size_t hitIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const std::vector& collection_points); void fluctuateEloss(int particleId, float momentum, float eloss, diff --git a/SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h index e032e64e4d53b..b18a83fba40d1 100644 --- a/SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h +++ b/SimTracker/SiPhase2Digitizer/interface/PixelDigitizerAlgorithm.h @@ -6,29 +6,9 @@ #include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" // forward declarations -// For the random numbers -//namespace CLHEP { -// class HepRandomEngine; -//} - -//namespace edm { -// class EventSetup; -// class ParameterSet; -//} - -//class PixelDigi; -//class PixelDigiSimLink; -//class PixelGeomDetUnit; -//class TrackerTopology; +class TrackerTopology; class PixelDigitizerAlgorithm: public Phase2TrackerDigitizerAlgorithm { - private: - // tpyedef to change names of current pixel types to phase 2 types - typedef PixelGeomDetUnit Phase2TrackerGeomDetUnit; - typedef PixelDigi Phase2TrackerDigi; - typedef PixelDigiSimLink Phase2TrackerDigiSimLink; - typedef PixelTopology Phase2TrackerTopology; - public: PixelDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine&); ~PixelDigitizerAlgorithm(); @@ -40,6 +20,8 @@ class PixelDigitizerAlgorithm: public Phase2TrackerDigitizerAlgorithm { // run the algorithm to digitize a single det void accumulateSimHits(const std::vector::const_iterator inputBegin, const std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield); void digitize(const Phase2TrackerGeomDetUnit* pixdet, diff --git a/SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h b/SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h index 791d699824cdd..5bf4e6adc7caa 100644 --- a/SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h +++ b/SimTracker/SiPhase2Digitizer/interface/SSDigitizerAlgorithm.h @@ -6,19 +6,7 @@ #include "SimTracker/SiPhase2Digitizer/interface/Phase2TrackerDigitizerFwd.h" // forward declarations -// For the random numbers -//namespace CLHEP { -// class HepRandomEngine; -//} -//namespace edm { -// class EventSetup; -// class ParameterSet; -//} -// -//class PixelDigi; -//class PixelDigiSimLink; -//class PixelGeomDetUnit; -//class TrackerTopology; +class TrackerTopology; class SSDigitizerAlgorithm :public Phase2TrackerDigitizerAlgorithm { public: @@ -31,6 +19,8 @@ class SSDigitizerAlgorithm :public Phase2TrackerDigitizerAlgorithm { //run the algorithm to digitize a single det void accumulateSimHits(const std::vector::const_iterator inputBegin, const std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield); void digitize(const Phase2TrackerGeomDetUnit* pixdet, diff --git a/SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc index 4abfcb3cfe076..5348e8565c969 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/PSPDigitizerAlgorithm.cc @@ -58,7 +58,7 @@ using namespace sipixelobjects; void PSPDigitizerAlgorithm::init(const edm::EventSetup& es) { if (use_ineff_from_db_) // load gain calibration service from db - theSiPixelGainCalibrationService_->setESObjects( es ); + theSiPixelGainCalibrationService_->setESObjects(es); if (use_deadmodule_DB_) es.get().get(SiPixelBadModule_); @@ -71,12 +71,12 @@ void PSPDigitizerAlgorithm::init(const edm::EventSetup& es) { es.get().get(map_); es.get().get(geom_); } -PSPDigitizerAlgorithm::PSPDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine& eng) : +PSPDigitizerAlgorithm::PSPDigitizerAlgorithm(const edm::ParameterSet& conf, CLHEP::HepRandomEngine& eng): Phase2TrackerDigitizerAlgorithm(conf.getParameter("AlgorithmCommon"), conf.getParameter("PSPDigitizerAlgorithm"), eng) { - LogInfo("PSPDigitizerAlgorithm") << "PSPDigitizerAlgorithm constructed " + LogInfo("PSPDigitizerAlgorithm") << "Algorithm constructed " << "Configuration parameters:" << "Threshold/Gain = " << "threshold in electron Endcap = " @@ -85,19 +85,22 @@ PSPDigitizerAlgorithm::PSPDigitizerAlgorithm(const edm::ParameterSet& conf, CLHE << theThresholdInE_Barrel << " " << theElectronPerADC << " " << theAdcFullScale << " The delta cut-off is set to " << tMax - << " pix-inefficiency "<::const_iterator inputBegin, std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield) { // produce SignalPoint's for all SimHit's in detector // Loop over hits uint32_t detId = pixdet->geographicalId().rawId(); - for (auto it = inputBegin; it != inputEnd; ++it) { + size_t simHitGlobalIndex = inputBeginGlobalIndex; // This needs to be stored to create the digi-sim link later + for (auto it = inputBegin; it != inputEnd; ++it, ++simHitGlobalIndex) { // skip hits not in this detector. if ((*it).detUnitId() != detId) continue; @@ -107,7 +110,7 @@ void PSPDigitizerAlgorithm::accumulateSimHits(std::vector::const_iterat << (*it).energyLoss() << " " << (*it).tof() << " " << (*it).trackId() << " " << (*it).processType() << " " << (*it).detUnitId() - << (*it).entryPoint() << " " << (*it).exitPoint() ; + << (*it).entryPoint() << " " << (*it).exitPoint(); std::vector ionization_points; std::vector collection_points; @@ -120,7 +123,7 @@ void PSPDigitizerAlgorithm::accumulateSimHits(std::vector::const_iterat drift(*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points // compute induced signal on readout elements and add to _signal - induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + induce_signal(*it, simHitGlobalIndex, tofBin, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link } } } @@ -149,15 +152,13 @@ void PSPDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, float theThresholdInE = 0.; // can we generalize it - if (theNoiseInElectrons > 0.) { - if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Barrel; // no smearing - } - else { // Forward disks modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Endcap; // no smearing - } + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } + else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing } // full detector thickness @@ -184,5 +185,7 @@ void PSPDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, make_digis(theThresholdInE, detID, digis, simlinks, tTopo); - LogDebug("PSPDigitizerAlgorithm") << "[PSPDigitizerAlgorithm] converted " << digis.size() << " PixelDigis in DetUnit" << detID; + LogDebug("PSPDigitizerAlgorithm") << "converted " << digis.size() + << " PixelDigis in DetUnit" + << detID; } diff --git a/SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc index 08e809a8b691f..5caff0534a320 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/PSSDigitizerAlgorithm.cc @@ -75,28 +75,31 @@ PSSDigitizerAlgorithm::PSSDigitizerAlgorithm(const edm::ParameterSet& conf, CLHE conf.getParameter("PSSDigitizerAlgorithm"), eng) { - LogInfo("PSSDigitizerAlgorithm") << "PSSDigitizerAlgorithm constructed " - << "Configuration parameters:" - << "Threshold/Gain = " - << "threshold in electron Endcap = " - << theThresholdInE_Endcap - << "threshold in electron Barrel = " - << theThresholdInE_Barrel - << " " << theElectronPerADC << " " << theAdcFullScale - << " The delta cut-off is set to " << tMax - << " pix-inefficiency "<::const_iterator inputBegin, std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield) { // produce SignalPoint's for all SimHit's in detector // Loop over hits uint32_t detId = pixdet->geographicalId().rawId(); - for (auto it = inputBegin; it != inputEnd; ++it) { + size_t simHitGlobalIndex = inputBeginGlobalIndex; // This needs to be stored to create the digi-sim link later + for (auto it = inputBegin; it != inputEnd; ++it, ++simHitGlobalIndex) { // skip hits not in this detector. if ((*it).detUnitId() != detId) continue; @@ -106,7 +109,7 @@ void PSSDigitizerAlgorithm::accumulateSimHits(std::vector::const_iterat << (*it).energyLoss() << " " << (*it).tof() << " " << (*it).trackId() << " " << (*it).processType() << " " << (*it).detUnitId() - << (*it).entryPoint() << " " << (*it).exitPoint() ; + << (*it).entryPoint() << " " << (*it).exitPoint(); std::vector ionization_points; std::vector collection_points; @@ -119,7 +122,7 @@ void PSSDigitizerAlgorithm::accumulateSimHits(std::vector::const_iterat drift(*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points // compute induced signal on readout elements and add to _signal - induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + induce_signal(*it, simHitGlobalIndex, tofBin, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link } } } @@ -149,15 +152,13 @@ void PSSDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, float theThresholdInE = 0.; // can we generalize it - if (theNoiseInElectrons > 0.) { - if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Barrel; // no smearing - } - else { // Forward disks modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Endcap; // no smearing - } + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } + else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing } // full detector thickness @@ -184,7 +185,7 @@ void PSSDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, } make_digis(theThresholdInE, detID, digis, simlinks, tTopo); - LogDebug("PSSDigitizerAlgorithm") << "[PSSDigitizerAlgorithm] converted " + LogDebug("PSSDigitizerAlgorithm") << "converted " << digis.size() << " PixelDigis in DetUnit" << detID; } diff --git a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc index c05b64145c719..8d1b2ea795282 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc @@ -70,7 +70,7 @@ namespace cms const std::string Phase2TrackerDigitizer::StripinPS = "PSS"; const std::string Phase2TrackerDigitizer::TwoStrip = "SS"; - Phase2TrackerDigitizer::Phase2TrackerDigitizer(const edm::ParameterSet& iConfig, edm::EDProducer& mixMod) : + Phase2TrackerDigitizer::Phase2TrackerDigitizer(const edm::ParameterSet& iConfig, edm::EDProducer& mixMod): first_(true), hitsProducer_(iConfig.getParameter("hitsProducer")), trackerContainers_(iConfig.getParameter >("ROUList")), @@ -102,62 +102,66 @@ namespace cms edm::LogInfo("Phase2TrackerDigitizer") << "Destroying the Digitizer"; } void - Phase2TrackerDigitizer::accumulatePixelHits(edm::Handle > hSimHits) { + Phase2TrackerDigitizer::accumulatePixelHits(edm::Handle > hSimHits, + size_t globalSimHitIndex,const unsigned int tofBin) { if (hSimHits.isValid()) { std::set detIds; std::vector const& simHits = *hSimHits.product(); - for (auto it = simHits.begin(), itEnd = simHits.end(); it != itEnd; ++it) { + for (auto it = simHits.begin(), itEnd = simHits.end(); it != itEnd; ++it, ++globalSimHitIndex) { unsigned int detId_raw = (*it).detUnitId(); if (detIds.insert(detId_raw).second) { - // The insert succeeded, so this detector element has not yet been processed. + // The insert succeeded, so this detector element has not yet been processed. const std::string algotype = getAlgoType(detId_raw); Phase2TrackerGeomDetUnit* phase2det = detectorUnits_[detId_raw]; // access to magnetic field in global coordinates GlobalVector bfield = pSetup_->inTesla(phase2det->surface().position()); LogDebug("PixelDigitizer") << "B-field(T) at " << phase2det->surface().position() << "(cm): " - << pSetup_->inTesla(phase2det->surface().position()); + << pSetup_->inTesla(phase2det->surface().position()); if (algomap_.find(algotype) != algomap_.end()) - algomap_[algotype]->accumulateSimHits(it, itEnd, phase2det, bfield); + algomap_[algotype]->accumulateSimHits(it, itEnd, globalSimHitIndex, tofBin, phase2det, bfield); else - edm::LogInfo("Phase2TrackerDigitizer") << "Unsupported algorithm"; + edm::LogInfo("Phase2TrackerDigitizer") << "Unsupported algorithm: " << algotype; } } } } - + void Phase2TrackerDigitizer::initializeEvent(edm::Event const& e, edm::EventSetup const& iSetup) { + // Must initialize all the algorithms for (auto it = algomap_.begin(); it != algomap_.end(); ++it) { - if (first_) { - it->second->init(iSetup); - first_ = false; - } + if (first_) it->second->init(iSetup); it->second->initializeEvent(); } - + first_ = false; + // Make sure that the first crossing processed starts indexing the sim hits from zero. + // This variable is used so that the sim hits from all crossing frames have sequential + // indices used to create the digi-sim link (if configured to do so) rather than starting + // from zero for each crossing. + crossingSimHitIndexOffset_.clear(); + iSetup.get().get(geometryType_, pDD_); iSetup.get().get(pSetup_); - + // FIX THIS! We only need to clear and (re)fill this map when the geometry type IOV changes. Use ESWatcher to determine this. if (true) { // Replace with ESWatcher detectorUnits_.clear(); for (auto iu = pDD_->detUnits().begin(); iu != pDD_->detUnits().end(); ++iu) { - unsigned int detId_raw = (*iu)->geographicalId().rawId(); + unsigned int detId_raw = (*iu)->geographicalId().rawId(); DetId detId = DetId(detId_raw); - if (DetId(detId).det() == DetId::Detector::Tracker) { - unsigned int isub = detId.subdetId(); - if (isub == PixelSubdetector::PixelBarrel || isub == PixelSubdetector::PixelEndcap) { - Phase2TrackerGeomDetUnit* pixdet = dynamic_cast(*iu); - assert(pixdet); - detectorUnits_.insert(std::make_pair(detId_raw, pixdet)); - } - } + if (DetId(detId).det() == DetId::Detector::Tracker) { + unsigned int isub = detId.subdetId(); + if (isub == PixelSubdetector::PixelBarrel || isub == PixelSubdetector::PixelEndcap) { + Phase2TrackerGeomDetUnit* pixdet = dynamic_cast(*iu); + assert(pixdet); + detectorUnits_.insert(std::make_pair(detId_raw, pixdet)); + } + } } } - } - + } void Phase2TrackerDigitizer::accumulate(edm::Event const& iEvent, edm::EventSetup const& iSetup) { accumulate_local(iEvent, iSetup); @@ -173,9 +177,17 @@ namespace cms for (auto it = trackerContainers_.begin(); it != trackerContainers_.end(); ++it) { edm::Handle > simHits; edm::InputTag tag(hitsProducer_, *it); + iEvent.getByLabel(tag, simHits); - accumulatePixelHits(simHits); - } + unsigned int tofBin = PixelDigiSimLink::LowTof; + if ((*it).find(std::string("HighTof")) != std::string::npos) tofBin = PixelDigiSimLink::HighTof; + accumulatePixelHits(simHits, crossingSimHitIndexOffset_[tag.encode()], tofBin); + // Now that the hits have been processed, I'll add the amount of hits in this crossing on to + // the global counter. Next time accumulateStripHits() is called it will count the sim hits + // as though they were on the end of this collection. + // Note that this is only used for creating digi-sim links (if configured to do so). + if (simHits.isValid()) crossingSimHitIndexOffset_[tag.encode()] += simHits->size(); + } } void Phase2TrackerDigitizer::finalizeEvent(edm::Event& iEvent, const edm::EventSetup& iSetup) { @@ -193,9 +205,9 @@ namespace cms edm::DetSet collector((*iu)->geographicalId().rawId()); edm::DetSet linkcollector((*iu)->geographicalId().rawId()); algomap_[algotype]->digitize(dynamic_cast((*iu)), - collector.data, - linkcollector.data, - tTopo); + collector.data, + linkcollector.data, + tTopo); if (collector.data.size() > 0) theDigiVector.push_back(std::move(collector)); @@ -203,7 +215,7 @@ namespace cms theDigiLinkVector.push_back(std::move(linkcollector)); } else - edm::LogInfo("Phase2TrackerDigitizer") << "Unsupported algorithm"; + edm::LogInfo("Phase2TrackerDigitizer") << "Unsupported algorithm: " << algotype; } // Step C: create collection with the cache vector of DetSet @@ -217,7 +229,7 @@ namespace cms iEvent.put(outputlink); } - // Fill the StackedTrackerDetId to DetId mapping here + // Fill the StackedTrackerDetId to DetId mapping here void Phase2TrackerDigitizer::beginRun(edm::Run const& run, edm::EventSetup const& iSetup) { // Get Stack Geometry information edm::ESHandle stkgeomHandle; diff --git a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc index a70d84c5e8cc6..e2fc336c14fc2 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizerAlgorithm.cc @@ -228,7 +228,7 @@ void Phase2TrackerDigitizerAlgorithm::primary_ionization(const PSimHit& hit, DigitizerUtility::EnergyDepositUnit edu(energy, point); // define position,energy point ionization_points[i] = edu; // save - LogDebug ("Phase2 Digitizer") + LogDebug("Phase2TrackerDigitizerAlgorithm") << i << " " << ionization_points[i].x() << " " << ionization_points[i].y() << " " << ionization_points[i].z() << " " @@ -310,7 +310,7 @@ void Phase2TrackerDigitizerAlgorithm::drift(const PSimHit& hit, collection_points.resize(ionization_points.size()); // set size LocalVector driftDir = DriftDirection(pixdet, bfield, hit.detUnitId()); // get the charge drift direction if (driftDir.z() == 0.) { - LogWarning("Magnetic field") << " pxlx: drift in z is zero "; + LogWarning("Phase2TrackerDigitizerAlgorithm") << " pxlx: drift in z is zero "; return; } @@ -401,7 +401,7 @@ void Phase2TrackerDigitizerAlgorithm::drift(const PSimHit& hit, } LogDebug("Phase2TrackerDigitizerAlgorithm") << "Dift DistanceZ = " << DriftDistance << " module thickness = " << moduleThickness - << " Start Energy = " <pitch().first << " " << topol->pitch().second; //OK @@ -446,7 +448,7 @@ void Phase2TrackerDigitizerAlgorithm::induce_signal(const PSimHit& hit, float SigmaY = i->sigma_y(); // in y float Charge = i->amplitude(); // Charge amplitude - LogDebug ("Phase2TrackerDigitizerAlgorithm") + LogDebug("Phase2TrackerDigitizerAlgorithm") << " cloud " << i->position().x() << " " << i->position().y() << " " << i->sigma_x() << " " << i->sigma_y() << " " << i->amplitude(); @@ -473,11 +475,11 @@ void Phase2TrackerDigitizerAlgorithm::induce_signal(const PSimHit& hit, int IPixRightUpX = int(floor( mp.x())); int IPixRightUpY = int(floor( mp.y())); - LogDebug ("Phase2TrackerDigitizerAlgorithm") << " right-up " << PointRightUp << " " - << mp.x() << " " << mp.y() << " " - << IPixRightUpX << " " << IPixRightUpY ; + LogDebug("Phase2TrackerDigitizerAlgorithm") << " right-up " << PointRightUp << " " + << mp.x() << " " << mp.y() << " " + << IPixRightUpX << " " << IPixRightUpY ; - mp = topol->measurementPosition(PointLeftDown ); //OK + mp = topol->measurementPosition(PointLeftDown); // OK int IPixLeftDownX = int(floor( mp.x())); int IPixLeftDownY = int(floor( mp.y())); @@ -577,7 +579,7 @@ void Phase2TrackerDigitizerAlgorithm::induce_signal(const PSimHit& hit, // Fill the global map with all hit pixels from this event for (auto im = hit_signal.begin();im != hit_signal.end(); ++im) { int chan = (*im).first; - theSignal[chan] += (makeDigiSimLinks_ ? DigitizerUtility::Amplitude( (*im).second, &hit, (*im).second) : DigitizerUtility::Amplitude( (*im).second, (*im).second)); + theSignal[chan] += (makeDigiSimLinks_ ? DigitizerUtility::Amplitude( (*im).second, &hit, hitIndex, tofBin, (*im).second) : DigitizerUtility::Amplitude( (*im).second, (*im).second) ) ; } } @@ -635,7 +637,7 @@ void Phase2TrackerDigitizerAlgorithm::make_digis(float theThresholdInE, } float fraction = sum_samechannel/(*i).second; if (fraction>1.) fraction = 1.; - simlinks.emplace_back((*i).first, (*simiiter).first, (*i).second.eventId(), fraction); + simlinks.emplace_back((*i).first, (*simiiter).first, (*i).second.hitIndex(), (*i).second.tofBin(), (*i).second.eventId(), fraction); } } } @@ -653,7 +655,7 @@ void Phase2TrackerDigitizerAlgorithm::add_noise(const Phase2TrackerGeomDetUnit* LogDebug("Phase2TrackerDigitizerAlgorithm") << " enter add_noise " << theNoiseInElectrons; uint32_t detID = pixdet->geographicalId().rawId(); signal_map_type& theSignal = _signal[detID]; - const Phase2TrackerTopology* topol=&pixdet->specificTopology(); + const Phase2TrackerTopology* topol = &pixdet->specificTopology(); int numColumns = topol->ncolumns(); // det module number of cols&rows int numRows = topol->nrows(); @@ -708,10 +710,10 @@ void Phase2TrackerDigitizerAlgorithm::add_noise(const Phase2TrackerGeomDetUnit* theNoiseInElectrons, // noise in elec. otherPixels ); - LogDebug ("Phase2TrackerDigitizerAlgorithm") + LogDebug("Phase2TrackerDigitizerAlgorithm") << " Add noisy pixels " << numRows << " " << numColumns << " " << theNoiseInElectrons << " " - << theThresholdInE_Endcap << " " << theThresholdInE_Barrel <<" "<< numberOfPixels<<" " + << theThresholdInE_Endcap << " " << theThresholdInE_Barrel << " " << numberOfPixels << " " << otherPixels.size() ; // Add noisy pixels @@ -720,9 +722,9 @@ void Phase2TrackerDigitizerAlgorithm::add_noise(const Phase2TrackerGeomDetUnit* int ix = ((*mapI).first) - (iy*numRows); // Keep for a while for testing. if( iy < 0 || iy > (numColumns-1) ) - LogWarning ("Pixel Geometry") << " error in iy " << iy ; + LogWarning("Phase2TrackerDigitizerAlgorithm") << " error in iy " << iy; if( ix < 0 || ix > (numRows-1) ) - LogWarning ("Pixel Geometry") << " error in ix " << ix ; + LogWarning("Phase2TrackerDigitizerAlgorithm") << " error in ix " << ix; int chan = Phase2TrackerDigi::pixelToChannel(ix, iy); diff --git a/SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc index a5006ae881f63..5f4e234deb765 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/PixelDigitizerAlgorithm.cc @@ -75,38 +75,41 @@ PixelDigitizerAlgorithm::PixelDigitizerAlgorithm(const edm::ParameterSet& conf, conf.getParameter("PixelDigitizerAlgorithm"), eng) { - LogInfo("PixelDigitizerAlgorithm ") << "PixelDigitizerAlgorithm constructed " - << "Configuration parameters:" - << "Threshold/Gain = " - << "threshold in electron Endcap = " - << theThresholdInE_Endcap - << "threshold in electron Barrel = " - << theThresholdInE_Barrel - << " " << theElectronPerADC << " " << theAdcFullScale - << " The delta cut-off is set to " << tMax - << " pix-inefficiency "<::const_iterator inputBegin, std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield) { // produce SignalPoint's for all SimHit's in detector // Loop over hits uint32_t detId = pixdet->geographicalId().rawId(); - for (auto it = inputBegin; it != inputEnd; ++it) { + size_t simHitGlobalIndex = inputBeginGlobalIndex; // This needs to be stored to create the digi-sim link later + for (auto it = inputBegin; it != inputEnd; ++it, ++simHitGlobalIndex) { // skip hits not in this detector. if ((*it).detUnitId() != detId) continue; - LogDebug ("Pixel Digitizer") + LogDebug ("PixelDigitizerAlgorithm") << (*it).particleType() << " " << (*it).pabs() << " " << (*it).energyLoss() << " " << (*it).tof() << " " << (*it).trackId() << " " << (*it).processType() << " " << (*it).detUnitId() - << (*it).entryPoint() << " " << (*it).exitPoint() ; + << (*it).entryPoint() << " " << (*it).exitPoint(); std::vector ionization_points; std::vector collection_points; @@ -119,14 +122,14 @@ void PixelDigitizerAlgorithm::accumulateSimHits(std::vector::const_iter drift (*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points // compute induced signal on readout elements and add to _signal - induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + induce_signal(*it, simHitGlobalIndex, tofBin, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link } } } void PixelDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, std::vector& digis, std::vector& simlinks, - const TrackerTopology *tTopo) + const TrackerTopology* tTopo) { // Pixel Efficiency moved from the constructor to this method because // the information of the det are not available in the constructor @@ -146,16 +149,16 @@ void PixelDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, unsigned int Sub_detid = DetId(detID).subdetId(); float theThresholdInE = 0.; + // can we generalize it - if (theNoiseInElectrons > 0.) { - if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Barrel; // no smearing - } else { // Forward disks modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Endcap; // no smearing - } + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing } + // full detector thickness float moduleThickness = pixdet->specificSurface().bounds().thickness(); LogDebug("PixelDigitizerAlgorithm") @@ -179,5 +182,7 @@ void PixelDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, } make_digis(theThresholdInE, detID, digis, simlinks, tTopo); - LogDebug("PixelDigitizerAlgorithm") << "[PixelDigitizerAlgorithm] converted " << digis.size() << " PixelDigis in DetUnit" << detID; + LogDebug("PixelDigitizerAlgorithm") << " converted " << digis.size() + << " PixelDigis in DetUnit" + << detID; } diff --git a/SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc b/SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc index 1197a7bc70da0..365a2e054c4a7 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/SSDigitizerAlgorithm.cc @@ -90,12 +90,15 @@ SSDigitizerAlgorithm::~SSDigitizerAlgorithm() { } void SSDigitizerAlgorithm::accumulateSimHits(std::vector::const_iterator inputBegin, std::vector::const_iterator inputEnd, + const size_t inputBeginGlobalIndex, + const unsigned int tofBin, const Phase2TrackerGeomDetUnit* pixdet, const GlobalVector& bfield) { // produce SignalPoint's for all SimHit's in detector // Loop over hits uint32_t detId = pixdet->geographicalId().rawId(); - for (auto it = inputBegin; it != inputEnd; ++it) { + size_t simHitGlobalIndex = inputBeginGlobalIndex; // This needs to be stored to create the digi-sim link later + for (auto it = inputBegin; it != inputEnd; ++it, ++simHitGlobalIndex) { // skip hits not in this detector. if ((*it).detUnitId() != detId) continue; @@ -118,7 +121,8 @@ void SSDigitizerAlgorithm::accumulateSimHits(std::vector::const_iterato drift(*it, pixdet, bfield, ionization_points, collection_points); // transforms _ionization_points to collection_points // compute induced signal on readout elements and add to _signal - induce_signal(*it, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link + + induce_signal(*it, simHitGlobalIndex, tofBin, pixdet, collection_points); // *ihit needed only for SimHit<-->Digi link } } } @@ -145,15 +149,15 @@ void SSDigitizerAlgorithm::digitize(const Phase2TrackerGeomDetUnit* pixdet, unsigned int Sub_detid = DetId(detID).subdetId(); float theThresholdInE = 0.; - if (theNoiseInElectrons > 0.) { - if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Barrel; // no smearing - } - else { // Forward disks modules - if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing - else theThresholdInE = theThresholdInE_Endcap; // no smearing - } + + // can we generalize it + if (Sub_detid == PixelSubdetector::PixelBarrel) { // Barrel modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Barrel_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Barrel; // no smearing + } + else { // Forward disks modules + if (addThresholdSmearing) theThresholdInE = smearedThreshold_Endcap_->fire(); // gaussian smearing + else theThresholdInE = theThresholdInE_Endcap; // no smearing } // full detector thickness From c41e5069467061b57e3c9cf031deeb73181081a4 Mon Sep 17 00:00:00 2001 From: Suchandra Date: Fri, 19 Sep 2014 10:45:45 +0200 Subject: [PATCH 116/252] removed unwanted configuration file --- .../python/phase2PixelDigitizer_cfi.py | 49 ------------------- 1 file changed, 49 deletions(-) delete mode 100644 SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py diff --git a/SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py b/SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py deleted file mode 100644 index d3adf47e214b5..0000000000000 --- a/SimTracker/SiPhase2Digitizer/python/phase2PixelDigitizer_cfi.py +++ /dev/null @@ -1,49 +0,0 @@ -import FWCore.ParameterSet.Config as cms - -phase2PixelDigitizer = cms.PSet( - accumulatorType = cms.string("SiPhase2Digitizer"), - hitsProducer = cms.string('g4SimHits'), - GeometryType = cms.string('idealForDigi'), - makeDigiSimLinks = cms.untracked.bool(True), -#D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm]) - ReadoutNoiseInElec = cms.double(1000.0),#D.B.:Fill readout noise, including all readout chain, relevant for smearing - DeltaProductionCut = cms.double(0.03), - ROUList = cms.vstring( - 'TrackerHitsPixelBarrelLowTof', - 'TrackerHitsPixelBarrelHighTof', - 'TrackerHitsPixelEndcapLowTof', - 'TrackerHitsPixelEndcapHighTof'), - ThresholdInElectrons_Barrel = cms.double(5800.0), #D.B.: this should correspond to a threshold of 530mV - ThresholdInElectrons_Endcap = cms.double(5800.0), - AddThresholdSmearing = cms.bool(True), - ThresholdSmearing_Barrel = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 210.0) - ThresholdSmearing_Endcap = cms.double(580.0),#D.B.: changed (~5mV peakToPeak --> 1.76mV rms) (was 245.0) - NoiseInElectrons = cms.double(300), # 30% of the readout noise (should be changed in future) - DigitalReadout = cms.bool(True), # Flag to decide analog or digital readout - ElectronPerAdc = cms.double(135.0), #D.B.:used for misscalibration - TofUpperCut = cms.double(12.5), - AdcFullScale = cms.int32(255), - TofLowerCut = cms.double(-12.5), - AddNoisyPixels = cms.bool(True), - Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described - AddNoise = cms.bool(True), - AddXTalk = cms.bool(True), #D.B. - InterstripCoupling = cms.double(0.05), #D.B. - SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo - SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X - ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas) - - AddInefficiency = cms.bool(False), - Inefficiency_DB = cms.bool(False), - - LorentzAngle_DB = cms.bool(False), - TanLorentzAnglePerTesla_Endcap = cms.double(0.106), #D.B.:this I have not checked yet - TanLorentzAnglePerTesla_Barrel = cms.double(0.106), #D.B.:this I have not checked yet - - KillModules = cms.bool(False), - DeadModules_DB = cms.bool(False), - - EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ), - EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on - DeadModules = cms.VPSet() -) From ad073465bce1e0f321b030d2525d728b86038396 Mon Sep 17 00:00:00 2001 From: Emmanuelle Perez Date: Mon, 22 Sep 2014 14:07:50 +0200 Subject: [PATCH 117/252] updates of TTPixelTrack.h and L1PixelTrackFit.cc (Anders, Sep 17) --- .../L1TrackTrigger/interface/TTPixelTrack.h | 38 ++++++++++- .../L1TrackTrigger/plugins/L1PixelTrackFit.cc | 66 +++++++++++++++++-- .../L1TrackTrigger/plugins/L1TrackDegraded.cc | 2 + 3 files changed, 98 insertions(+), 8 deletions(-) diff --git a/DataFormats/L1TrackTrigger/interface/TTPixelTrack.h b/DataFormats/L1TrackTrigger/interface/TTPixelTrack.h index a2fa3351dcd6c..2a24aac60aca0 100644 --- a/DataFormats/L1TrackTrigger/interface/TTPixelTrack.h +++ b/DataFormats/L1TrackTrigger/interface/TTPixelTrack.h @@ -45,11 +45,26 @@ class TTPixelTrack double getChi2() const; double getChi2Red() const; - void init(const edm::Ref >, TTTrack >& aL1Track, + /// Errors + + double getSigmaRInv() const {return theSigmaRInv;} + double getSigmaPhi0() const {return theSigmaPhi0;} + double getSigmaD0() const {return theSigmaD0;} + double getSigmaT() const {return theSigmaT;} + double getSigmaZ0() const {return theSigmaZ0;} + + + void init(const edm::Ref >, + TTTrack >& aL1Track, const GlobalVector& aMomentum, const GlobalPoint& aPOCA, double aRInv, - double aChi2); + double aChi2, + double sigmarinv, + double sigmad0, + double sigmaphi0, + double sigmat, + double sigmaz0); /// Information std::string print( unsigned int i = 0 ) const; @@ -64,6 +79,12 @@ class TTPixelTrack GlobalPoint thePOCA; double theRInv; double theChi2; + double theSigmaRInv; + double theSigmaPhi0; + double theSigmaD0; + double theSigmaT; + double theSigmaZ0; + }; /// Close class @@ -89,13 +110,24 @@ void TTPixelTrack::init(const edm::Ref >, TT const GlobalVector& aMomentum, const GlobalPoint& aPOCA, double aRInv, - double aChi2){ + double aChi2, + double sigmarinv, + double sigmad0, + double sigmaphi0, + double sigmat, + double sigmaz0){ theL1Track=aL1Track; theMomentum=aMomentum; thePOCA=aPOCA; theRInv=aRInv; theChi2=aChi2; + theSigmaRInv=sigmarinv; + theSigmaPhi0=sigmad0; + theSigmaD0=sigmaphi0; + theSigmaT=sigmat; + theSigmaZ0=sigmaz0; + } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc index af6a0246ac6d9..3b0de954c5c00 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1PixelTrackFit.cc @@ -142,7 +142,13 @@ class L1PixelTrackFit : public edm::EDProducer double& d0fit, double& tfit, double& z0fit, - double& chisqfit); + double& chisqfit, + double& sigmainvr, + double& sigmaphi0, + double& sigmad0, + double& sigmat, + double& sigmaz0 + ); /// ///////////////// /// /// MANDATORY METHODS /// @@ -158,6 +164,8 @@ class L1PixelTrackFit : public edm::EDProducer void linearTrackFit(double rinv, double phi0, double d0, double t, double z0, double& rinvfit, double& phi0fit, double& d0fit, double& tfit, double& z0fit, double& chisqfit, + double& sigmarinv, double& sigmaphi0, double& sigmad0, + double& sigmat, double& sigmaz0, std::vector fithits, std::vector fitbarrel, double D[5][8], double MinvDt[5][8]); @@ -165,6 +173,8 @@ class L1PixelTrackFit : public edm::EDProducer void trackfit(double rinv, double phi0, double d0, double t, double z0, double& rinvfit, double& phi0fit, double& d0fit, double& tfit, double& z0fit, double& chisqfit, + double& sigmarinv, double& sigmaphi0, double& sigmad0, + double& sigmat, double& sigmaz0, std::vector fithits, std::vector fitbarrel); @@ -345,8 +355,9 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) bool success=false; double invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit; + double sigmainvr,sigmaphi0,sigmad0,sigmat,sigmaz0; - multifit(invr,phi0,d0,t,z0,hitL1,hitL2,hitL3,hitL4,hitD1,hitD2,hitD3,success,invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit); + multifit(invr,phi0,d0,t,z0,hitL1,hitL2,hitL3,hitL4,hitD1,hitD2,hitD3,success,invrfit,phi0fit,d0fit,tfit,z0fit,chisqfit,sigmainvr,sigmaphi0,sigmad0,sigmat,sigmaz0); if (success) { @@ -361,8 +372,10 @@ void L1PixelTrackFit::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) GlobalVector theMomentum(GlobalVector::Cylindrical(pt,phi0fit,pt*tfit)); edm::Ref< L1TkTrackCollectionType > L1TrackPtr( L1TrackHandle, itrack) ; + //std::cout << "chisqfit : " << chisqfit << std::endl; - aTrack.init(L1TrackPtr,theMomentum,thePOCA,invrfit,chisqfit); + aTrack.init(L1TrackPtr,theMomentum,thePOCA,invrfit,chisqfit, + sigmainvr,sigmaphi0,sigmad0,sigmat,sigmaz0); L1PixelTracksForOutput->push_back(aTrack); @@ -396,7 +409,13 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double d0, double& d0final, double& tfinal, double& z0final, - double& chisqfinal) { + double& chisqfinal, + double& sigmainvr, + double& sigmaphi0, + double& sigmad0, + double& sigmat, + double& sigmaz0 + ) { success=false; @@ -485,6 +504,7 @@ void L1PixelTrackFit::multifit(double rinv, double phi0, double d0, double d0best=9999.9; double tbest=9999.9; double z0best=9999.9; + double chisqbest=9999.9; for(unsigned int i0=0;i0 fithits, std::vector fitbarrel){ @@ -968,6 +1023,7 @@ void L1PixelTrackFit::trackfit(double rinv, double phi0, double d0, calculateDerivatives(rinv, phi0, t, z0,fithits,fitbarrel,D,MinvDt); linearTrackFit(rinv, phi0, d0, t, z0, rinvfit, phi0fit, d0fit, tfit, z0fit, chisqfit, + sigmarinv, sigmaphi0, sigmad0, sigmat, sigmaz0, fithits,fitbarrel,D,MinvDt); } diff --git a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc index 20054a18549cd..0f0e7dc95051a 100644 --- a/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc +++ b/SLHCUpgradeSimulations/L1TrackTrigger/plugins/L1TrackDegraded.cc @@ -29,6 +29,7 @@ //#include "SimDataFormats/SLHC/interface/L1TDisk.hh" //#include "SimDataFormats/SLHC/interface/L1TStub.hh" + #include "TRandom.h" #include "TMath.h" #include @@ -174,6 +175,7 @@ void L1TrackDegrader::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) float NewPt = Pt + NsigmaPT * deltaPt * Pt; //std::cout << "deltaPt: " << deltaPt << std::endl << "NsigmaPT: " << NsigmaPT << std::endl << "Pt: " << Pt << std::endl << "sigma: " << sigma << std::endl << NewPt << std::endl; float NewPz = pz * NewPt / Pt; + GlobalVector smearedMomentum(GlobalVector::Cylindrical( NewPt, Phi, NewPz )); smearedTrack.setMomentum( smearedMomentum, Npar ); From 2fc19e96d8ee6d32999b8e8fa0a65bb641a8f1b1 Mon Sep 17 00:00:00 2001 From: Sunanda Date: Tue, 23 Sep 2014 06:41:49 +0200 Subject: [PATCH 118/252] Add the validation tools for digi and rechits --- .../HGCalValidation/plugins/BuildFile.xml | 1 + .../plugins/HGCalDigiClient.cc | 190 +++++++++ .../HGCalValidation/plugins/HGCalDigiClient.h | 59 +++ .../plugins/HGCalDigiValidation.cc | 271 +++++++++++++ .../plugins/HGCalDigiValidation.h | 96 +++++ .../plugins/HGCalRecHitValidation.cc | 197 +++++++++ .../plugins/HGCalRecHitValidation.h | 109 +++++ .../plugins/HGCalRecHitsClient.cc | 196 +++++++++ .../plugins/HGCalRecHitsClient.h | 68 ++++ .../plugins/HGCalSimHitValidation.cc | 382 +++++++++--------- .../plugins/HGCalSimHitValidation.h | 33 +- .../plugins/HGCalSimHitsClient.cc | 42 +- .../plugins/HGCalSimHitsClient.h | 10 +- .../python/HGCalDigiClient_cfi.py | 7 + .../python/HGCalRecHitsClient_cfi.py | 7 + .../python/HGCalSimHitsClient_cfi.py | 7 + .../python/digiValidation_cfi.py | 8 + .../python/rechitValidation_cfi.py | 7 + .../python/simhitValidation_cfi.py | 4 +- .../HGCalValidation/test/digiClient_cfg.py | 59 +++ .../test/digiValidation_cfg.py | 137 +++++++ .../HGCalValidation/test/recHitClient_cfg.py | 58 +++ .../test/rechitValidation_cfg.py | 153 +++++++ .../HGCalValidation/test/simHitClient_cfg.py | 23 +- .../test/simHitValidation_cfg.py | 16 +- 25 files changed, 1889 insertions(+), 251 deletions(-) create mode 100644 Validation/HGCalValidation/plugins/HGCalDigiClient.cc create mode 100644 Validation/HGCalValidation/plugins/HGCalDigiClient.h create mode 100644 Validation/HGCalValidation/plugins/HGCalDigiValidation.cc create mode 100644 Validation/HGCalValidation/plugins/HGCalDigiValidation.h create mode 100644 Validation/HGCalValidation/plugins/HGCalRecHitValidation.cc create mode 100644 Validation/HGCalValidation/plugins/HGCalRecHitValidation.h create mode 100644 Validation/HGCalValidation/plugins/HGCalRecHitsClient.cc create mode 100644 Validation/HGCalValidation/plugins/HGCalRecHitsClient.h create mode 100644 Validation/HGCalValidation/python/HGCalDigiClient_cfi.py create mode 100644 Validation/HGCalValidation/python/HGCalRecHitsClient_cfi.py create mode 100644 Validation/HGCalValidation/python/HGCalSimHitsClient_cfi.py create mode 100644 Validation/HGCalValidation/python/digiValidation_cfi.py create mode 100644 Validation/HGCalValidation/python/rechitValidation_cfi.py create mode 100644 Validation/HGCalValidation/test/digiClient_cfg.py create mode 100644 Validation/HGCalValidation/test/digiValidation_cfg.py create mode 100644 Validation/HGCalValidation/test/recHitClient_cfg.py create mode 100644 Validation/HGCalValidation/test/rechitValidation_cfg.py diff --git a/Validation/HGCalValidation/plugins/BuildFile.xml b/Validation/HGCalValidation/plugins/BuildFile.xml index 3705aa772fd20..e8ab4d91e3c03 100644 --- a/Validation/HGCalValidation/plugins/BuildFile.xml +++ b/Validation/HGCalValidation/plugins/BuildFile.xml @@ -1,6 +1,7 @@ + diff --git a/Validation/HGCalValidation/plugins/HGCalDigiClient.cc b/Validation/HGCalValidation/plugins/HGCalDigiClient.cc new file mode 100644 index 0000000000000..18d42e01c1173 --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalDigiClient.cc @@ -0,0 +1,190 @@ +#include "Validation/HGCalValidation/plugins/HGCalDigiClient.h" +#include "FWCore/Framework/interface/Run.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "DQMServices/Core/interface/DQMStore.h" +#include "DQMServices/Core/interface/MonitorElement.h" +#include "DetectorDescription/Core/interface/DDFilteredView.h" +#include "DetectorDescription/Core/interface/DDSolid.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +HGCalDigiClient::HGCalDigiClient(const edm::ParameterSet& iConfig) { + + dbe_ = edm::Service().operator->(); + nameDetector_ = iConfig.getParameter("DetectorName"); + outputFile_ = iConfig.getUntrackedParameter("outputFile", "myfile.root"); + verbosity_ = iConfig.getUntrackedParameter("Verbosity",0); + + if (!dbe_) { + edm::LogError("HGCalDigiClient") << "unable to get DQMStore service, upshot is no client histograms will be made"; + } + if (iConfig.getUntrackedParameter("DQMStore", false)) { + if (dbe_) dbe_->setVerbose(0); + } + if (dbe_) dbe_->setCurrentFolder("/"); +} + +HGCalDigiClient::~HGCalDigiClient() { } + +void HGCalDigiClient::beginJob() { } + +void HGCalDigiClient::endJob() { + if ( outputFile_.size() != 0 && dbe_ ) dbe_->save(outputFile_); +} + +void HGCalDigiClient::beginRun(const edm::Run& run, const edm::EventSetup& iSetup) { + edm::ESTransientHandle pDD; + iSetup.get().get( pDD ); + const DDCompactView & cview = *pDD; + hgcons_ = new HGCalDDDConstants(cview, nameDetector_); +} + +void HGCalDigiClient::endRun(const edm::Run& , const edm::EventSetup& ) { + runClient_(); +} + +//dummy analysis function +void HGCalDigiClient::analyze(const edm::Event& , const edm::EventSetup&) { } +void HGCalDigiClient::endLuminosityBlock(const edm::LuminosityBlock&, const edm::EventSetup& ) { } + +void HGCalDigiClient::runClient_() { + if (!dbe_) return; + dbe_->setCurrentFolder("/"); + if (verbosity_) std::cout << "\nrunClient" << std::endl; + std::vector hgcalMEs; + std::vector fullDirPath = dbe_->getSubdirs(); + + for (unsigned int i=0; isetCurrentFolder(fullDirPath.at(i)); + std::vector fullSubDirPath = dbe_->getSubdirs(); + + for (unsigned int j=0; jgetContents(fullSubDirPath.at(j)); + if (verbosity_) std::cout << "hgcalMES size : " << hgcalMEs.size() <& hgcalMEs) { + + std::vector charge_; + std::vector DigiOccupancy_XY_; + std::vector ADC_; + std::vector DigiOccupancy_Plus_; + std::vector DigiOccupancy_Minus_; + std::vector MeanDigiOccupancy_Plus_; + std::vector MeanDigiOccupancy_Minus_; + std::ostringstream name; + double nevent; + int nbinsx, nbinsy; + + int layers_ = hgcons_->layers(true); + + for (int ilayer = 0; ilayer < layers_; ilayer++ ){ + //charge + name.str(""); name << "charge_layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0) + charge_.push_back(hgcalMEs[ih]); + } + //normalization + nevent = charge_.at(ilayer)->getEntries(); + nbinsx = charge_.at(ilayer)->getNbinsX(); + for(int i=1; i <= nbinsx; i++) { + double binValue = charge_.at(ilayer)->getBinContent(i)/nevent; + charge_.at(ilayer)->setBinContent(i,binValue); + } + + //XY 2d plots + name.str(""); name << "DigiOccupancy_XY_" << "layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0) + DigiOccupancy_XY_.push_back(hgcalMEs[ih]); + } + + //normalization of XY 2d + nevent = DigiOccupancy_XY_.at(ilayer)->getEntries(); + nbinsx = DigiOccupancy_XY_.at(ilayer)->getNbinsX(); + nbinsy = DigiOccupancy_XY_.at(ilayer)->getNbinsY(); + for(int i=1; i<= nbinsx; ++i) { + for(int j=1; j<= nbinsy; ++j) { + double binValue = DigiOccupancy_XY_.at(ilayer)->getBinContent(i, j)/nevent; + DigiOccupancy_XY_.at(ilayer)->setBinContent(i, j, binValue); + } + } + + //ADC + name.str(""); name << "ADC_layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0) + ADC_.push_back(hgcalMEs[ih]); + } + + //normalization of ADC Histos + nevent = ADC_.at(ilayer)->getEntries(); + nbinsx = ADC_.at(ilayer)->getNbinsX(); + for(int i=1; i<= nbinsx; ++i) { + double binValue = ADC_.at(ilayer)->getBinContent(i)/nevent; + ADC_.at(ilayer)->setBinContent(i, binValue); + } + + //Digi Occupancy + name.str(""); name << "DigiOccupancy_Plus_layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + DigiOccupancy_Plus_.push_back(hgcalMEs[ih]); + } + } + + name.str(""); name << "DigiOccupancy_Minus_layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + DigiOccupancy_Minus_.push_back(hgcalMEs[ih]); + } + } + + //normalization of Digi Occupancy histos + nevent = DigiOccupancy_Plus_.at(ilayer)->getEntries(); + nbinsx = DigiOccupancy_Plus_.at(ilayer)->getNbinsX(); + for(int i=1; i<= nbinsx; ++i) { + double binValue = DigiOccupancy_Plus_.at(ilayer)->getBinContent(i)/nevent; + DigiOccupancy_Plus_.at(ilayer)->setBinContent(i, binValue); + } + + nevent = DigiOccupancy_Minus_.at(ilayer)->getEntries(); + nbinsx = DigiOccupancy_Minus_.at(ilayer)->getNbinsX(); + for(int i=1; i<= nbinsx; ++i) { + double binValue = DigiOccupancy_Minus_.at(ilayer)->getBinContent(i)/nevent; + DigiOccupancy_Minus_.at(ilayer)->setBinContent(i, binValue); + } + + }//loop over layers + + name.str(""); name << "SUMOfDigiOccupancy_Plus"; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + MeanDigiOccupancy_Plus_.push_back(hgcalMEs[ih]); + } + } + + name.str(""); name << "SUMOfDigiOccupancy_Plus"; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + MeanDigiOccupancy_Minus_.push_back(hgcalMEs[ih]); + } + } + return 1; +} + +#include "FWCore/Framework/interface/MakerMacros.h" + +DEFINE_FWK_MODULE(HGCalDigiClient); diff --git a/Validation/HGCalValidation/plugins/HGCalDigiClient.h b/Validation/HGCalValidation/plugins/HGCalDigiClient.h new file mode 100644 index 0000000000000..005a564dfce20 --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalDigiClient.h @@ -0,0 +1,59 @@ +#ifndef ValidationHGCalDigiClient_H +#define ValidationHGCalDigiClient_H + +// -*- C++ -*- +/* + Description: This is a SImHit CLient code +*/ +// +// Originally create by: Kalyanmoy Chatterjee +// and Raman Khurana +// + +#include +#include +#include +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "DQMServices/Core/interface/MonitorElement.h" +#include "DQMServices/Core/interface/DQMStore.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "DetectorDescription/Core/interface/DDCompactView.h" +#include "FWCore/Framework/interface/ESTransientHandle.h" +#include "Geometry/HGCalCommonData/interface/HGCalDDDConstants.h" + +#include +#include +#include + +class DQMStore; +class MonitorElement; + +class HGCalDigiClient : public edm::EDAnalyzer { + +private: + DQMStore* dbe_; + std::string outputFile_; + // edm::ParameterSet conf_; + std::string nameDetector_; + int verbosity_; + HGCalDDDConstants *hgcons_; + +public: + explicit HGCalDigiClient(const edm::ParameterSet& ); + virtual ~HGCalDigiClient(); + + virtual void beginJob(void); + virtual void endJob(); + virtual void beginRun(const edm::Run& run, const edm::EventSetup& c); + virtual void endRun(const edm::Run& run, const edm::EventSetup& c); + virtual void analyze(const edm::Event&, const edm::EventSetup&); + virtual void endLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& c); + void runClient_(); + int DigisEndjob(const std::vector &hcalMEs); +}; + +#endif diff --git a/Validation/HGCalValidation/plugins/HGCalDigiValidation.cc b/Validation/HGCalValidation/plugins/HGCalDigiValidation.cc new file mode 100644 index 0000000000000..558cd68579b41 --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalDigiValidation.cc @@ -0,0 +1,271 @@ +// -*- C++ -*- +// +// Package: HGCalDigiValidation +// Class: HGCalDigiValidation +// +/**\class HGCalDigiValidation HGCalDigiValidation.cc Validaion/HGCalValidation/plugins/HGCalDigiValidation.cc + Description: Validates SimHits of High Granularity Calorimeter + Implementation: + [Notes on implementation] +*/ +// +// Original Author: Raman Khurana +//// and Kalyanmoy Chatterjee +// Created: Fri, 31 Jan 2014 18:35:18 GMT +// $Id$ + +// system include files +#include "Validation/HGCalValidation/plugins/HGCalDigiValidation.h" +#include "DataFormats/ForwardDetId/interface/ForwardSubdetector.h" +#include "FWCore/Framework/interface/ESTransientHandle.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/MakerMacros.h" +///// +#include "DetectorDescription/Core/interface/DDExpandedView.h" +#include "DetectorDescription/Core/interface/DDSpecifics.h" +#include "DetectorDescription/Core/interface/DDSolid.h" +#include "DetectorDescription/Core/interface/DDFilter.h" +#include "DetectorDescription/Core/interface/DDFilteredView.h" +#include "DetectorDescription/Core/interface/DDSolid.h" +//// +#include "FWCore/Utilities/interface/InputTag.h" // included to header also, have to remove from here + +#include "DataFormats/HGCDigi/interface/HGCDigiCollections.h" + +#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "DataFormats/ForwardDetId/interface/HGCEEDetId.h" +#include "DataFormats/ForwardDetId/interface/HGCHEDetId.h" + +#include "CLHEP/Units/GlobalSystemOfUnits.h" +#include + +HGCalDigiValidation::HGCalDigiValidation(const edm::ParameterSet& iConfig){ + dbe_ = edm::Service().operator->(); + nameDetector_ = iConfig.getParameter("DetectorName"); + DigiSource_ = iConfig.getParameter("DigiSource"); + verbosity_ = iConfig.getUntrackedParameter("Verbosity",0); + SampleIndx_ = iConfig.getUntrackedParameter("SampleIndx",5); +} + + +HGCalDigiValidation::~HGCalDigiValidation() { } + +void HGCalDigiValidation::analyze(const edm::Event& iEvent, + const edm::EventSetup& iSetup) { + OccupancyMap_plus_.clear(); + OccupancyMap_minus_.clear(); + + edm::ESHandle geom; + iSetup.get().get(nameDetector_, geom); + const HGCalGeometry& geom0 = *geom; + + if (!geom.isValid()) + std::cout << "Cannot get valid HGCalGeometry Object for " << nameDetector_ << std::endl; + + if (nameDetector_ == "HGCalEESensitive") { + //HGCalEE + edm::Handle theHGCEEDigiContainers; + + if (theHGCEEDigiContainers.isValid()) { + if (verbosity_>0) std::cout << nameDetector_ << " with " + << theHGCEEDigiContainers->size() + << " element(s)" << std::endl; + + iEvent.getByLabel("mix", DigiSource_, theHGCEEDigiContainers); + for(HGCEEDigiCollection::const_iterator it =theHGCEEDigiContainers->begin(); + it !=theHGCEEDigiContainers->end(); ++it) { + HGCEEDetId detId = it->id(); + HGCDigiValidation(detId, geom0, it); + } + FillDigiInfo(); + } else if (verbosity_>0) { + std::cout << "HGCEEDigiCollection handle does not exist !!!" << std::endl; + } + } else if ((nameDetector_ == "HGCalHESiliconSensitive") || + (nameDetector_ == "HGCalHEScintillatorSensitive")){ + //HGCalHE + edm::Handle theHGCHEDigiContainers; + if (theHGCHEDigiContainers.isValid()) { + if (verbosity_>0) std::cout << nameDetector_ << " with " + << theHGCHEDigiContainers->size() + << " element(s)" << std::endl; + + iEvent.getByLabel("mix", DigiSource_, theHGCHEDigiContainers); + for(HGCHEDigiCollection::const_iterator it =theHGCHEDigiContainers->begin(); + it !=theHGCHEDigiContainers->end(); ++it) { + HGCHEDetId detId = it->id(); + HGCDigiValidation(detId, geom0, it); + } + FillDigiInfo(); + } else if (verbosity_>0) { + std::cout << "HGCHEDigiCollection handle does not exist !!!" << std::endl; + } + } else { + std::cout << "invalid detector name !!" << std::endl; + } +} + + +template +void HGCalDigiValidation::HGCDigiValidation(T1 detId, const HGCalGeometry& geom0, const T2 it) { + + // std::vector charges; + int cell = detId.cell(); + int subsector = detId.subsector(); + int sector = detId.sector(); + int layer = detId.layer(); + int zside = detId.zside(); + ForwardSubdetector subdet = detId.subdet(); + + DetId id1= ((subdet == HGCEE) ? (DetId)(HGCEEDetId(subdet,zside,layer,sector,subsector,cell)) + : (DetId)(HGCHEDetId(subdet,zside,layer,sector,subsector,cell))); + GlobalPoint global1 = geom0.getPosition(id1); + + std::cout<< " >>>>>>>> nameDetector : " << nameDetector_ << " >>>>>>>> subsector: " << subsector << std::endl; + if (verbosity_>1) std::cout << "cell = " << cell + << " subsector = " << subsector + << " sector = " << sector + << " layer = " << layer + << " zside = " << zside << std::endl; + + HGCSample hgcSample = it->sample(SampleIndx_); + uint16_t gain = hgcSample.gain(); + uint16_t adc = hgcSample.adc(); + int charge = adc*gain; + + if (verbosity_>1) std::cout << "nSample = " << it->size() + << " SampleIndx = " << SampleIndx_ + << " gain = " << gain + << " adc = " << adc + << " charge = " << charge << std::endl; + + digiInfo hinfo; + hinfo.x = global1.x(); + hinfo.y = global1.y(); + hinfo.z = global1.z(); + hinfo.adc = adc; + hinfo.charge = charge; //charges[0]; + hinfo.layer = layer; + + if (verbosity_>1) std::cout << "gx = " << hinfo.x + << " gy = " << hinfo.y + << " gz = " << hinfo.z << std::endl; + + FillDigiInfo(hinfo); + + if (global1.eta() > 0) fillOccupancyMap(OccupancyMap_plus_, layer -1); + else fillOccupancyMap(OccupancyMap_minus_, layer -1); + +} + +void HGCalDigiValidation::fillOccupancyMap(std::map& OccupancyMap, int layer) { + if (OccupancyMap.find(layer) != OccupancyMap.end()) OccupancyMap[layer] ++; + else OccupancyMap[layer] = 1; +} + +void HGCalDigiValidation::FillDigiInfo(digiInfo& hinfo) { + int ilayer = hinfo.layer -1; + charge_.at(ilayer)->Fill(hinfo.charge); + DigiOccupancy_XY_.at(ilayer)->Fill(hinfo.x, hinfo.y); + ADC_.at(ilayer)->Fill(hinfo.adc); +} + +void HGCalDigiValidation::FillDigiInfo() { + if(!dbe_) return; + for (auto itr = OccupancyMap_plus_.begin(); + itr != OccupancyMap_plus_.end(); ++itr) { + int layer = (*itr).first; + int occupancy = (*itr).second; + DigiOccupancy_Plus_.at(layer)->Fill(occupancy); + } + for (auto itr = OccupancyMap_minus_.begin(); + itr != OccupancyMap_minus_.end(); ++itr) { + int layer = (*itr).first; + int occupancy = (*itr).second; + DigiOccupancy_Minus_.at(layer)->Fill(occupancy); + } +} + +void HGCalDigiValidation::beginJob() { } + +void HGCalDigiValidation::endJob() { } + +void HGCalDigiValidation::beginRun(edm::Run const& iRun, + edm::EventSetup const& iSetup) { + + edm::ESTransientHandle pDD; + iSetup.get().get( pDD ); + const DDCompactView & cview = *pDD; + hgcons_ = new HGCalDDDConstants(cview, nameDetector_); + + if (dbe_) { + layers_ = hgcons_->layers(true); + dbe_->setCurrentFolder("HGCalDigiV/"+nameDetector_); + + if (verbosity_>0) std::cout << "current DQM directory: " + << "HGCalDigiV/" << nameDetector_ + << " layer = "<< layers_ << std::endl; + std::ostringstream histoname; + for (int ilayer = 0; ilayer < layers_; ilayer++ ) { + histoname.str(""); histoname << "charge_"<< "layer_" << ilayer; + charge_.push_back(dbe_->book1D(histoname.str().c_str(),"charge_",1000,-25,25)); + + histoname.str(""); histoname << "ADC_" << "layer_" << ilayer; + ADC_.push_back(dbe_->book1D(histoname.str().c_str(), "DigiOccupancy", 1000, 0, 1000)); + + histoname.str(""); histoname << "DigiOccupancy_XY_" << "layer_" << ilayer; + DigiOccupancy_XY_.push_back(dbe_->book2D(histoname.str().c_str(), "DigiOccupancy", 1000, -500, 500, 1000, -500, 500)); + + histoname.str(""); histoname << "DigiOccupancy_Plus_" << "layer_" << ilayer; + DigiOccupancy_Plus_.push_back(dbe_->book1D(histoname.str().c_str(), "DigiOccupancy +z", 1000, 0, 1000)); + histoname.str(""); histoname << "DigiOccupancy_Minus_" << "layer_" << ilayer; + DigiOccupancy_Minus_.push_back(dbe_->book1D(histoname.str().c_str(), "DigiOccupancy -z", 1000, 0, 1000)); + } + + histoname.str(""); histoname << "SUMOfDigiOccupancy_Plus"; + // MeanDigiOccupancy_Plus_.push_back(dbe_->book1D( histoname.str().c_str(), "SUMOfDigiOccupancy_Plus", + MeanDigiOccupancy_Plus_ = dbe_->book1D( histoname.str().c_str(), "SUMOfDigiOccupancy_Plus", layers_, -0.5, layers_-0.5); + histoname.str(""); histoname << "SUMOfRecDigiOccupancy_Minus"; + MeanDigiOccupancy_Minus_ = dbe_->book1D( histoname.str().c_str(), "SUMOfDigiOccupancy_Minus", layers_, -0.5,layers_-0.5); + } + +} + +// ------------ method called when ending the processing of a run ------------ + +void HGCalDigiValidation::endRun(edm::Run const&, edm::EventSetup const&) { + if (!dbe_) return; + for(int ilayer=0; ilayer < (int)layers_; ++ilayer) { + double meanVal = DigiOccupancy_Plus_.at(ilayer)->getMean(); + MeanDigiOccupancy_Plus_->setBinContent(ilayer+1, meanVal); + meanVal = DigiOccupancy_Minus_.at(ilayer)->getMean(); + MeanDigiOccupancy_Minus_->setBinContent(ilayer+1, meanVal); + } +} + + +// ------------ method called when starting to processes a luminosity block ------------ +/* +void HGCalDigiValidation::beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) { +} +*/ + +// ------------ method called when ending the processing of a luminosity block ------------ +/* +void HGCalDigiValidation::endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) { +} +*/ + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void HGCalDigiValidation::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + //The following says we do not know what parameters are allowed so do no validation + // Please change this to state exactly what you do use, even if it is no parameters + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +#include "FWCore/Framework/interface/MakerMacros.h" + +//define this as a plug-in +DEFINE_FWK_MODULE(HGCalDigiValidation); diff --git a/Validation/HGCalValidation/plugins/HGCalDigiValidation.h b/Validation/HGCalValidation/plugins/HGCalDigiValidation.h new file mode 100644 index 0000000000000..2e1f2710a5146 --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalDigiValidation.h @@ -0,0 +1,96 @@ +#ifndef HGCalDigiValidation_h +#define HGCalDigiValidation_h +// -*- C++ -*- +// +// Package: HGCalDigiValidation +// Class: HGCalDigiValidation +// +/**\class HGCalDigiValidation HGCalDigiValidation.cc Validation/HGCalValidation/plugins/HGCalDigiValidation.cc + + Description: Validates SimHits of High Granularity Calorimeter + + Implementation: + [Notes on implementation] +*/ +// +// Original Author: Raman Khurana +// Created: Fri, 31 Jan 2014 18:35:18 GMT +// $Id$ +// +// + + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDAnalyzer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "DQMServices/Core/interface/DQMStore.h" +#include "DQMServices/Core/interface/MonitorElement.h" + +#include "Geometry/FCalGeometry/interface/HGCalGeometry.h" +#include "Geometry/HGCalCommonData/interface/HGCalDDDConstants.h" +#include + +#include +#include +#include +#include +#include + +class HGCalDigiValidation : public edm::EDAnalyzer { + +public: + struct digiInfo{ + digiInfo() { + x = y = z = 0.0; + layer = adc = charge = 0; + } + double x, y, z; + int layer, charge, adc; + }; + + explicit HGCalDigiValidation(const edm::ParameterSet&); + ~HGCalDigiValidation(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + void FillDigiInfo(digiInfo& hinfo); + void FillDigiInfo(); + void fillOccupancyMap(std::map& OccupancyMap, int layer); + template + void HGCDigiValidation(T1 detId, const HGCalGeometry& geom0, const T2 it); + +private: + virtual void beginJob() override; + virtual void analyze(const edm::Event&, const edm::EventSetup&) override; + virtual void endJob() override; + virtual void beginRun(edm::Run const&, edm::EventSetup const&) override; + virtual void endRun(edm::Run const&, edm::EventSetup const&) override; + + // ----------member data --------------------------- + std::string nameDetector_, DigiSource_; + int verbosity_, SampleIndx_; + DQMStore *dbe_; + HGCalDDDConstants *hgcons_; + int layers_; + + std::map OccupancyMap_plus_; + std::map OccupancyMap_minus_; + + std::vector charge_; + std::vector DigiOccupancy_XY_; + std::vector ADC_; + std::vector DigiOccupancy_Plus_; + std::vector DigiOccupancy_Minus_; + MonitorElement* MeanDigiOccupancy_Plus_; + MonitorElement* MeanDigiOccupancy_Minus_; + +}; +#endif diff --git a/Validation/HGCalValidation/plugins/HGCalRecHitValidation.cc b/Validation/HGCalValidation/plugins/HGCalRecHitValidation.cc new file mode 100644 index 0000000000000..46c0128d45f94 --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalRecHitValidation.cc @@ -0,0 +1,197 @@ +// -*- C++ -*- +// +// Package: HGCalRecHitValidation +// Class: HGCalRecHitValidation +// +/**\class HGCalRecHitValidation HGCalRecHitValidation.cc Validaion/HGCalValidation/plugins/HGCalRecHitValidation.cc + Description: Validates SimHits of High Granularity Calorimeter + Implementation: + [Notes on implementation] +*/ +// +// Original Author: Raman Khurana +//// and Kalyanmoy Chatterjee +// Created: Sunday, 17th Augst 2014 11:30:15 GMT +// $Id$ + +// system include files +#include "Validation/HGCalValidation/plugins/HGCalRecHitValidation.h" +#include "DataFormats/ForwardDetId/interface/ForwardSubdetector.h" +#include "FWCore/Framework/interface/ESTransientHandle.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/MakerMacros.h" +#include "DataFormats/HGCRecHit/interface/HGCRecHitCollections.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +#include "DetectorDescription/Core/interface/DDExpandedView.h" +#include "DetectorDescription/Core/interface/DDSpecifics.h" +#include "DetectorDescription/Core/interface/DDSolid.h" +#include "DetectorDescription/Core/interface/DDFilter.h" +#include "DetectorDescription/Core/interface/DDFilteredView.h" +#include "DetectorDescription/Core/interface/DDSolid.h" + +#include "CLHEP/Units/GlobalSystemOfUnits.h" +#include "TVector3.h" +#include + + +HGCalRecHitValidation::HGCalRecHitValidation(const edm::ParameterSet& iConfig){ + dbe_ = edm::Service().operator->(); + nameDetector_ = iConfig.getParameter("DetectorName"); + HGCRecHitSource_ = iConfig.getParameter("RecHitSource"); + verbosity_ = iConfig.getUntrackedParameter("Verbosity",0); +} + + +HGCalRecHitValidation::~HGCalRecHitValidation() { } + +void HGCalRecHitValidation::analyze(const edm::Event& iEvent, + const edm::EventSetup& iSetup) { + OccupancyMap_plus.clear(); + OccupancyMap_minus.clear(); + + edm::ESHandle geom; + iSetup.get().get(nameDetector_,geom); + const HGCalGeometry& geom0 = *geom; + + //get the HGC RecHit Collection + edm::Handle theRecHitContainers; + iEvent.getByLabel("HGCalRecHit", HGCRecHitSource_, theRecHitContainers); + if (theRecHitContainers.isValid()) { + if (verbosity_>0) std::cout << nameDetector_ << " with " << theRecHitContainers->size() + << " HGCRecHit element(s)"<< std::endl; + + for(HGCRecHitCollection::const_iterator it = theRecHitContainers->begin(); + it !=theRecHitContainers->end(); ++it) { + + DetId detId = it->id(); + + int layer = (detId.subdetId() == HGCEE) ? (HGCEEDetId(detId).layer()) : (HGCHEDetId(detId).layer()); + layer = layer; + + GlobalPoint global1 = geom0.getPosition(detId); + float globalx = global1.x(); + float globaly = global1.y(); + float globalz = global1.z(); + + double energy = it->energy(); + + HitsInfo hinfo; + hinfo.energy = energy; + hinfo.x = globalx; + hinfo.y = globaly; + hinfo.z = globalz; + hinfo.layer = layer; + hinfo.phi = global1.phi(); + hinfo.eta = global1.eta(); + + if (verbosity_>1) std::cout << " -------------------------- gx = " + << globalx << " gy = " << globaly << " gz = " + << globalz << " phi = " << hinfo.phi << " eta = " + << hinfo.eta << std::endl; + + FillHitsInfo(hinfo); + + double eta = hinfo.eta; + if (eta > 0) fillOccupancyMap(OccupancyMap_plus, layer -1); + else fillOccupancyMap(OccupancyMap_minus, layer -1); + + + }// loop over hits ends here + + FillHitsInfo(); + } + else if(verbosity_ > 0) + std::cout << "HGCRecHitCollection Handle does not exist !!!" <& OccupancyMap, int layer){ + if (OccupancyMap.find(layer) != OccupancyMap.end()) OccupancyMap[layer]++; + else OccupancyMap[layer] = 1; +} + +void HGCalRecHitValidation::FillHitsInfo() { + + for (auto itr = OccupancyMap_plus.begin() ; itr != OccupancyMap_plus.end(); ++itr) { + int layer = (*itr).first; + int occupancy = (*itr).second; + HitOccupancy_Plus_.at(layer)->Fill(occupancy); + } + + for (auto itr = OccupancyMap_minus.begin() ; itr != OccupancyMap_minus.end(); ++itr) { + int layer = (*itr).first; + int occupancy = (*itr).second; + HitOccupancy_Minus_.at(layer)->Fill(occupancy); + } + +} + +void HGCalRecHitValidation::FillHitsInfo(HitsInfo& hits) { + + unsigned int ilayer = hits.layer -1; + energy_.at(ilayer)->Fill(hits.energy); + + EtaPhi_Plus_.at(ilayer)->Fill(hits.eta , hits.phi); + EtaPhi_Minus_.at(ilayer)->Fill(hits.eta, hits.phi); + +} + +void HGCalRecHitValidation::beginJob() {} + +void HGCalRecHitValidation::endJob() { } + +void HGCalRecHitValidation::beginRun(edm::Run const& iRun, + edm::EventSetup const& iSetup) { + + edm::ESTransientHandle pDD; + iSetup.get().get( pDD ); + const DDCompactView & cview = *pDD; + hgcons_ = new HGCalDDDConstants(cview, nameDetector_); + + if (dbe_) { + layers_ = hgcons_->layers(true); + dbe_->setCurrentFolder("HGCalRecHitsV/"+nameDetector_); + std::ostringstream histoname; + + for (unsigned int ilayer = 0; ilayer < layers_; ilayer++ ) { + histoname.str(""); histoname << "HitOccupancy_Plus_layer_" << ilayer; + HitOccupancy_Plus_.push_back(dbe_->book1D( histoname.str().c_str(), "RecHitOccupancy_Plus", 2000, 0, 10000)); + histoname.str(""); histoname << "HitOccupancy_Minus_layer_" << ilayer; + HitOccupancy_Minus_.push_back(dbe_->book1D( histoname.str().c_str(), "RecHitOccupancy_Minus", 2000, 0, 10000)); + + histoname.str(""); histoname << "EtaPhi_Plus_" << "layer_" << ilayer; + EtaPhi_Plus_.push_back(dbe_->book2D(histoname.str().c_str(), "Occupancy", 100, 0, 2.5, 72, -3.15, 3.15)); + histoname.str(""); histoname << "EtaPhi_Minus_" << "layer_" << ilayer; + EtaPhi_Minus_.push_back(dbe_->book2D(histoname.str().c_str(), "Occupancy", 100, -2.5, 0, 72, -3.15, 3.15)); + + histoname.str(""); histoname << "energy_layer_" << ilayer; + energy_.push_back(dbe_->book1D(histoname.str().c_str(),"energy_",5000,0,0.002)); + }//loop over layers ends here + + histoname.str(""); histoname << "SUMOfRecHitOccupancy_Plus"; + MeanHitOccupancy_Plus_= dbe_->book1D( histoname.str().c_str(), "SUMOfRecHitOccupancy_Plus", layers_, -0.5, layers_-0.5); + histoname.str(""); histoname << "SUMOfRecHitOccupancy_Minus"; + MeanHitOccupancy_Minus_ = dbe_->book1D( histoname.str().c_str(), "SUMOfRecHitOccupancy_Minus", layers_, -0.5,layers_-0.5); + } +} + +void HGCalRecHitValidation::endRun(edm::Run const&, edm::EventSetup const&) { + for(int ilayer=0; ilayer < (int)layers_; ++ilayer) { + double meanVal = HitOccupancy_Plus_.at(ilayer)->getMean(); + MeanHitOccupancy_Plus_->setBinContent(ilayer+1, meanVal); + meanVal = HitOccupancy_Minus_.at(ilayer)->getMean(); + MeanHitOccupancy_Minus_->setBinContent(ilayer+1, meanVal); + } +} + + +// ------------ method fills 'descriptions' with the allowed parameters for the module ------------ +void HGCalRecHitValidation::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { + edm::ParameterSetDescription desc; + desc.setUnknown(); + descriptions.addDefault(desc); +} + +#include "FWCore/Framework/interface/MakerMacros.h" + +//define this as a plug-in +DEFINE_FWK_MODULE(HGCalRecHitValidation); diff --git a/Validation/HGCalValidation/plugins/HGCalRecHitValidation.h b/Validation/HGCalValidation/plugins/HGCalRecHitValidation.h new file mode 100644 index 0000000000000..83a9a5b6da9d9 --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalRecHitValidation.h @@ -0,0 +1,109 @@ +#ifndef HGCalRecHitValidation_h +#define HGCalRecHitValidation_h +// -*- C++ -*- +// +// Package: HGCalRecHitValidation +// Class: HGCalRecHitValidation +// +/**\class HGCalRecHitValidation HGCalRecHitValidation.cc Validation/HGCalValidation/plugins/HGCalRecHitValidation.cc + + Description: Validates SimHits of High Granularity Calorimeter + + Implementation: + [Notes on implementation] +*/ +// +// Original Author: Raman Khurana +// Created: Sunday, 17th Augst 2014 11:30:15 GMT +// $Id$ +// +// + + +// system include files +#include + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDAnalyzer.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/Utilities/interface/InputTag.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h" + +#include "DataFormats/ForwardDetId/interface/HGCalDetId.h" +//#include "DetectorDescription/Core/interface/DDCompactView.h" +//#include "FWCore/Framework/interface/ESTransientHandle.h" + +#include "DQMServices/Core/interface/DQMStore.h" +#include "DQMServices/Core/interface/MonitorElement.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "Geometry/FCalGeometry/interface/HGCalGeometry.h" +#include "Geometry/HGCalCommonData/interface/HGCalDDDConstants.h" +#include + +#include +#include +#include +#include +#include + +class HGCalRecHitValidation : public edm::EDAnalyzer { + +public: + struct energysum{ + energysum() {e15=e25=e50=e100=e250=e1000=0.0;} + double e15, e25, e50, e100, e250, e1000; + }; + + struct HitsInfo{ + HitsInfo() { + x=y=z=time=energy=phi=eta=0.0; + //cell=sector= + layer=0; + } + float x, y, z, time, energy, phi, eta ; + float layer; + // int cell, sector, layer; + }; + + + explicit HGCalRecHitValidation(const edm::ParameterSet&); + ~HGCalRecHitValidation(); + + static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); + + //void FillHitsInfo(std::pair hit_, unsigned int itimeslice, double esum); + void FillHitsInfo(); + void FillHitsInfo(HitsInfo& hits); + void fillOccupancyMap(std::map& OccupancyMap, int layer); + // static const int netaBins = 4; + + +private: + virtual void beginJob() override; + virtual void analyze(const edm::Event&, const edm::EventSetup&) override; + virtual void endJob() override; + // bool defineGeometry(edm::ESTransientHandle &ddViewH); + virtual void beginRun(edm::Run const&, edm::EventSetup const&) override; + virtual void endRun(edm::Run const&, edm::EventSetup const&) override; + + // ----------member data --------------------------- + std::string nameDetector_, HGCRecHitSource_; + DQMStore *dbe_; + HGCalDDDConstants *hgcons_; + int verbosity_; + unsigned int layers_; + std::map OccupancyMap_plus; + std::map OccupancyMap_minus; + + std::vector EtaPhi_Plus_; + std::vector EtaPhi_Minus_; + std::vector energy_; + std::vector HitOccupancy_Plus_; + std::vector HitOccupancy_Minus_; + MonitorElement* MeanHitOccupancy_Plus_; + MonitorElement* MeanHitOccupancy_Minus_; +}; +#endif diff --git a/Validation/HGCalValidation/plugins/HGCalRecHitsClient.cc b/Validation/HGCalValidation/plugins/HGCalRecHitsClient.cc new file mode 100644 index 0000000000000..027186275e21f --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalRecHitsClient.cc @@ -0,0 +1,196 @@ +#include "Validation/HGCalValidation/plugins/HGCalRecHitsClient.h" +#include "FWCore/Framework/interface/Run.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/ServiceRegistry/interface/Service.h" + +#include "DQMServices/Core/interface/DQMStore.h" +#include "DQMServices/Core/interface/MonitorElement.h" +#include"DetectorDescription/Core/interface/DDFilteredView.h" +#include "DetectorDescription/Core/interface/DDSolid.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" + +HGCalRecHitsClient::HGCalRecHitsClient(const edm::ParameterSet& iConfig) { + + dbe_ = edm::Service().operator->(); + verbosity_ = iConfig.getUntrackedParameter("Verbosity",0); + nameDetector_ = iConfig.getParameter("DetectorName"); + outputFile_ = iConfig.getUntrackedParameter("outputFile", "myfile.root"); + + if (!dbe_) { + edm::LogError("HGCalRecHitsClient") << "unable to get DQMStore service, upshot is no client histograms will be made"; + } + if (iConfig.getUntrackedParameter("DQMStore", false)) { + if (dbe_) dbe_->setVerbose(0); + } + + if (dbe_) dbe_->setCurrentFolder("/"); +} + +HGCalRecHitsClient::~HGCalRecHitsClient() { } + +void HGCalRecHitsClient::beginJob() { } + +void HGCalRecHitsClient::endJob() { + if ( outputFile_.size() != 0 && dbe_ ) dbe_->save(outputFile_); +} + +void HGCalRecHitsClient::beginRun(const edm::Run& run, const edm::EventSetup& iSetup) { + edm::ESTransientHandle pDD; + iSetup.get().get( pDD ); + const DDCompactView & cview = *pDD; + hgcons_ = new HGCalDDDConstants(cview, nameDetector_); +} + +void HGCalRecHitsClient::endRun(const edm::Run& , const edm::EventSetup& ) { + runClient_(); +} + +//dummy analysis function +void HGCalRecHitsClient::analyze(const edm::Event& , const edm::EventSetup&) { } +void HGCalRecHitsClient::endLuminosityBlock(const edm::LuminosityBlock&, const edm::EventSetup& ) { } + +void HGCalRecHitsClient::runClient_() { + if (!dbe_) return; + dbe_->setCurrentFolder("/"); + if (verbosity_>0) std::cout << "\nrunClient" << std::endl; + std::vector hgcalMEs; + std::vector fullDirPath = dbe_->getSubdirs(); + + for (unsigned int i=0; i0) std::cout << "\nfullPath: " << fullDirPath.at(i) << std::endl; + dbe_->setCurrentFolder(fullDirPath.at(i)); + std::vector fullSubDirPath = dbe_->getSubdirs(); + + for (unsigned int j=0; j1) std::cout << "fullSubPath: " << fullSubDirPath.at(j) << std::endl; + std::string nameDirectory = "HGCalRecHitsV/"+nameDetector_; + if (strcmp(fullSubDirPath.at(j).c_str(), nameDirectory.c_str()) == 0) { + hgcalMEs = dbe_->getContents(fullSubDirPath.at(j)); + if (verbosity_>1) std::cout << "hgcalMES size : " << hgcalMEs.size() <& hgcalMEs) { + std::vector energy_; + std::vector EtaPhi_Plus_; + std::vector EtaPhi_Minus_; + std::vector HitOccupancy_Plus_; + std::vector HitOccupancy_Minus_; + std::vector MeanHitOccupancy_Plus_; + std::vector MeanHitOccupancy_Minus_; + + std::ostringstream name; + double nevent; + int nbinsx, nbinsy; + + unsigned int layers_ = hgcons_->layers(true); + + for (unsigned int ilayer = 0; ilayer < layers_; ilayer++ ){ + name.str(""); name << "energy_layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + energy_.push_back(hgcalMEs[ih]); + } + } + + //normalization + nevent = energy_.at(ilayer)->getEntries(); + nbinsx = energy_.at(ilayer)->getNbinsX(); + for(int i=1; i <= nbinsx; i++) { + double binValue = energy_.at(ilayer)->getBinContent(i)/nevent; + energy_.at(ilayer)->setBinContent(i,binValue); + } + + //EtaPhi 2d plots + name.str(""); name << "EtaPhi_Plus_" << "layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + EtaPhi_Plus_.push_back(hgcalMEs[ih]); + } + } + + name.str(""); name << "EtaPhi_Minus_" << "layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + EtaPhi_Minus_.push_back(hgcalMEs[ih]); + } + } + + //normalization EtaPhi + nevent = EtaPhi_Plus_.at(ilayer)->getEntries(); + nbinsx = EtaPhi_Plus_.at(ilayer)->getNbinsX(); + nbinsy = EtaPhi_Plus_.at(ilayer)->getNbinsY(); + for(int i=1; i<= nbinsx; ++i) { + for(int j=1; j<= nbinsy; ++j) { + double binValue = EtaPhi_Plus_.at(ilayer)->getBinContent(i, j)/nevent; + EtaPhi_Plus_.at(ilayer)->setBinContent(i, j, binValue); + } + } + + nevent = EtaPhi_Minus_.at(ilayer)->getEntries(); + nbinsx = EtaPhi_Minus_.at(ilayer)->getNbinsX(); + nbinsy = EtaPhi_Plus_.at(ilayer)->getNbinsY(); + for(int i=1; i<= nbinsx; ++i) { + for(int j=1; j<= nbinsy; ++j) { + double binValue = EtaPhi_Minus_.at(ilayer)->getBinContent(i, j)/nevent; + EtaPhi_Minus_.at(ilayer)->setBinContent(i, j, binValue); + } + } + + //HitOccupancy + name.str(""); name << "HitOccupancy_Plus_layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + HitOccupancy_Plus_.push_back(hgcalMEs[ih]); + } + } + + name.str(""); name << "HitOccupancy_Minus_layer_" << ilayer; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + HitOccupancy_Minus_.push_back(hgcalMEs[ih]); + } + } + + //normalization of hit occupancy histos + nevent = HitOccupancy_Plus_.at(ilayer)->getEntries(); + nbinsx = HitOccupancy_Plus_.at(ilayer)->getNbinsX(); + for(int i=1; i<= nbinsx; ++i) { + double binValue = HitOccupancy_Plus_.at(ilayer)->getBinContent(i)/nevent; + HitOccupancy_Plus_.at(ilayer)->setBinContent(i, binValue); + } + + nevent = HitOccupancy_Minus_.at(ilayer)->getEntries(); + nbinsx = HitOccupancy_Minus_.at(ilayer)->getNbinsX(); + for(int i=1; i<= nbinsx; ++i) { + double binValue = HitOccupancy_Minus_.at(ilayer)->getBinContent(i)/nevent; + HitOccupancy_Minus_.at(ilayer)->setBinContent(i, binValue); + } + + }//loop over layers + + name.str(""); name << "SUMOfRecHitOccupancy_Plus"; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + MeanHitOccupancy_Plus_.push_back(hgcalMEs[ih]); + } + } + + name.str(""); name << "SUMOfRecHitOccupancy_Plus"; + for(unsigned int ih=0; ihgetName().c_str(), name.str().c_str()) == 0){ + MeanHitOccupancy_Minus_.push_back(hgcalMEs[ih]); + } + } + + return 1; +} + +#include "FWCore/Framework/interface/MakerMacros.h" + +DEFINE_FWK_MODULE(HGCalRecHitsClient); diff --git a/Validation/HGCalValidation/plugins/HGCalRecHitsClient.h b/Validation/HGCalValidation/plugins/HGCalRecHitsClient.h new file mode 100644 index 0000000000000..0349851141a78 --- /dev/null +++ b/Validation/HGCalValidation/plugins/HGCalRecHitsClient.h @@ -0,0 +1,68 @@ +#ifndef ValidationHGCalRecHitsClient_H +#define ValidationHGCalRecHitsClient_H + +// -*- C++ -*- +/* + Description: This is a HGCRecHit CLient code +*/ +// +// Originally create by: Kalyanmoy Chatterjee +// and Raman Khurana +// + +#include +#include +#include +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "DQMServices/Core/interface/MonitorElement.h" +#include "DQMServices/Core/interface/DQMStore.h" +#include "DataFormats/Common/interface/Handle.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "DataFormats/Math/interface/LorentzVector.h" + +#include "DetectorDescription/Core/interface/DDCompactView.h" +#include "FWCore/Framework/interface/ESTransientHandle.h" +#include "Geometry/HGCalCommonData/interface/HGCalDDDConstants.h" +#include "DataFormats/ForwardDetId/interface/HGCalDetId.h" + +#include +#include +#include + +class DQMStore; +class MonitorElement; + +class HGCalRecHitsClient : public edm::EDAnalyzer { + +private: + DQMStore* dbe_; //dbe seems to be the standard name for this, I dont know why. We of course dont own it + std::string outputFile_; + edm::ParameterSet conf_; + + int verbosity_; + + //member data + std::string dirName_; + std::string nameDetector_; + HGCalDDDConstants *hgcons_; + // std::map transMap_; + +public: + explicit HGCalRecHitsClient(const edm::ParameterSet& ); + virtual ~HGCalRecHitsClient(); + + virtual void beginJob(void); + virtual void endJob(); + virtual void beginRun(const edm::Run& run, const edm::EventSetup& c); + virtual void endRun(const edm::Run& run, const edm::EventSetup& c); + virtual void analyze(const edm::Event&, const edm::EventSetup&); + virtual void endLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& c); + virtual void runClient_(); + + int RecHitsEndjob(const std::vector &hcalMEs); +}; + +#endif diff --git a/Validation/HGCalValidation/plugins/HGCalSimHitValidation.cc b/Validation/HGCalValidation/plugins/HGCalSimHitValidation.cc index 03df20c82d70b..7034b6c9e6f74 100644 --- a/Validation/HGCalValidation/plugins/HGCalSimHitValidation.cc +++ b/Validation/HGCalValidation/plugins/HGCalSimHitValidation.cc @@ -15,7 +15,7 @@ // $Id$ // system include files -#include "HGCalSimHitValidation.h" +#include "Validation/HGCalValidation/plugins/HGCalSimHitValidation.h" #include "DataFormats/ForwardDetId/interface/ForwardSubdetector.h" #include "DetectorDescription/Core/interface/DDExpandedView.h" #include "DetectorDescription/Core/interface/DDSpecifics.h" @@ -30,183 +30,203 @@ #include "CLHEP/Geometry/Plane3D.h" #include "CLHEP/Geometry/Vector3D.h" #include "CLHEP/Units/GlobalSystemOfUnits.h" -#include "TVector3.h" +#include "CLHEP/Units/GlobalPhysicalConstants.h" #include HGCalSimHitValidation::HGCalSimHitValidation(const edm::ParameterSet& iConfig){ - //now do what ever initialization is needed dbe_ = edm::Service().operator->(); nameDetector_ = iConfig.getParameter("DetectorName"); caloHitSource_ = iConfig.getParameter("CaloHitSource"); verbosity_ = iConfig.getUntrackedParameter("Verbosity",0); - for(int i=0; i theCaloHitContainers; iEvent.getByLabel("g4SimHits", caloHitSource_, theCaloHitContainers); - if (verbosity_>0) std::cout << " PcalohitItr = " - << theCaloHitContainers->size() << std::endl; - std::vector caloHits; - caloHits.insert(caloHits.end(), theCaloHitContainers->begin(), - theCaloHitContainers->end()); - analyzeHits(caloHits); + if (theCaloHitContainers.isValid()) { + if (verbosity_>0) std::cout << " PcalohitItr = " + << theCaloHitContainers->size() << std::endl; + std::vector caloHits; + caloHits.insert(caloHits.end(), theCaloHitContainers->begin(), + theCaloHitContainers->end()); + analyzeHits(caloHits); + } else if (verbosity_>0) { + std::cout << "PCaloHitContainer does not exist !!!" << std::endl; + } } void HGCalSimHitValidation::analyzeHits (std::vector& hits) { - for(int i=0; i > map_hits; + map_hits.clear(); + + if (verbosity_ > 0) std::cout << nameDetector_ << " with " << hits.size() + << " PcaloHit elements" << std::endl; + for (unsigned int i=0; i1) std::cout << " energy = " << energy - << " energyem = "< gcoord( transMap_[id]*lcoord ); - - float globalx = gcoord.x(); - float globaly = gcoord.y(); - float globalz = gcoord.z(); - hitsinfo hinfo; - TVector3 HitGlobalCo; - HitGlobalCo.SetXYZ(globalx, globalx, globalz); - double velocity = 3*pow(10,11); - double tof = HitGlobalCo.Mag()/velocity; + time -= tof; - hinfo.x = globalx;//xy.first; - hinfo.y = globaly;//xy.second; - hinfo.z = globalz; - hinfo.time = time - tof; - hinfo.energy = energy; - hinfo.sector = sector; - hinfo.cell = cell; - hinfo.layer = layer; - hinfo.phi = atan2(globaly,globalx); - double theta = acos(globalz/sqrt(globalx*globalx+globaly*globaly+globalz*globalz)); - hinfo.eta = -log(tan(theta/2)); - + energysum esum; + hitsinfo hinfo; + if (map_hits.count(detId) != 0) { + hinfo = map_hits[detId].first; + esum = map_hits[detId].second; + } else { + hinfo.x = gcoord.x(); + hinfo.y = gcoord.y(); + hinfo.z = gcoord.z(); + hinfo.sector = sector; + hinfo.cell = cell; + hinfo.layer = layer; + hinfo.phi = gcoord.getPhi(); + hinfo.eta = gcoord.getEta(); + esum.etotal += energy; + if (time > 0 && time < 1000) { + esum.e1000 += energy; + if (time < 250) { + esum.e250 += energy; + if (time < 100) { + esum.e100 += energy; + if (time < 50) { + esum.e50 += energy; + if (time < 25) { + esum.e25 += energy; + if (time < 15) { + esum.e15 += energy; + } + } + } + } + } + } + } if (verbosity_>1) std::cout << " -------------------------- gx = " - << globalx << " gy = " << globaly << " gz = " - << globalz << " phi = " << hinfo.phi << " eta = " - << hinfo.eta << std::endl; + << hinfo.x << " gy = " << hinfo.y << " gz = " + << hinfo.z << " phi = " << hinfo.phi + << " eta = " << hinfo.eta << std::endl; std::pair pair_tmp(hinfo,esum); - - for(unsigned int itimeslice = 0; itimeslice < esumVector.size(); itimeslice++ ) { - FillHitsInfo(pair_tmp, itimeslice, esumVector.at(itimeslice)); - } + map_hits[detId] = pair_tmp; + } + if (verbosity_>0) std::cout << nameDetector_ << " with " << map_hits.size() + << " detector elements being hit" << std::endl; - double eta = hinfo.eta; - if(eta >= 1.75 && eta <= 2.5) - hitsPerLayerPlus[0][layer -1] = hitsPerLayerPlus[0][layer -1] +1; - if(eta >= 1.75 && eta <= 2.0) - hitsPerLayerPlus[1][layer -1] = hitsPerLayerPlus[1][layer -1] +1; - else if(eta >= 2.0 && eta <= 2.25) - hitsPerLayerPlus[2][layer -1] = hitsPerLayerPlus[2][layer -1] +1; - else if(eta >= 2.25 && eta <= 2.5) - hitsPerLayerPlus[3][layer -1] = hitsPerLayerPlus[3][layer -1] +1; - - if(eta >= -2.5 && eta <= -1.75) - hitsPerLayerMinus[0][layer -1] = hitsPerLayerMinus[0][layer -1] +1; - if(eta >= -2.0 && eta <= -1.75) - hitsPerLayerMinus[1][layer -1] = hitsPerLayerMinus[1][layer -1] +1; - else if(eta >= -2.25 && eta <= -2.0) - hitsPerLayerMinus[2][layer -1] = hitsPerLayerMinus[2][layer -1] +1; - else if(eta >= -2.5 && eta <= -2.25) - hitsPerLayerMinus[3][layer -1] = hitsPerLayerMinus[3][layer -1] +1; + std::map >::iterator itr; + for (itr = map_hits.begin() ; itr != map_hits.end(); ++itr) { + hitsinfo hinfo = (*itr).second.first; + energysum esum = (*itr).second.second; + int layer = hinfo.layer; + + + std::vector esumVector; + esumVector.push_back(esum.e15); + esumVector.push_back(esum.e25); + esumVector.push_back(esum.e50); + esumVector.push_back(esum.e100); + esumVector.push_back(esum.e250); + esumVector.push_back(esum.e1000); + + for(unsigned int itimeslice = 0; itimeslice < esumVector.size(); + itimeslice++ ) { + FillHitsInfo((*itr).second, itimeslice, esumVector.at(itimeslice)); + } + + double eta = hinfo.eta; + + if (eta >= 1.75 && eta <= 2.5) fillOccupancyMap(OccupancyMap_plus[0], layer-1); + if (eta >= 1.75 && eta <= 2.0) fillOccupancyMap(OccupancyMap_plus[1], layer-1); + else if (eta >= 2.0 && eta <= 2.25) fillOccupancyMap(OccupancyMap_plus[2], layer-1); + else if(eta >= 2.25 && eta <= 2.5) fillOccupancyMap(OccupancyMap_plus[3], layer-1); + + if (eta >= -2.5 && eta <= -1.75) fillOccupancyMap(OccupancyMap_minus[0], layer-1); + if (eta >= -2.0 && eta <= -1.75) fillOccupancyMap(OccupancyMap_minus[1], layer-1); + else if (eta >= -2.25 && eta <= -2.0) fillOccupancyMap(OccupancyMap_minus[2], layer-1); + else if (eta >= -2.5 && eta <= -2.25) fillOccupancyMap(OccupancyMap_minus[3], layer-1); } - + FillHitsInfo(); } +void HGCalSimHitValidation::fillOccupancyMap(std::map& OccupancyMap, int layer){ + if ( OccupancyMap.find(layer) != OccupancyMap.end() ) + OccupancyMap[layer] ++; + else OccupancyMap[layer] = 1; +} + void HGCalSimHitValidation::FillHitsInfo() { - if (!geometrydefined_) return; - if (!dbe_) return; - for(int ilayer =0; ilayer <(int)layers; ++ilayer) { - for(int indx=0; indxFill(hitsPerLayerPlus[indx][ilayer]); - HitOccupancy_Minus_[indx].at(ilayer)->Fill(hitsPerLayerMinus[indx][ilayer]); + if (geometrydefined_ && dbe_) { + + for(int indx=0; indxFill(occupancy); + } + for (auto itr = OccupancyMap_minus[indx].begin() ; itr != OccupancyMap_minus[indx].end(); ++itr) { + int layer = (*itr).first; + int occupancy = (*itr).second; + HitOccupancy_Minus_[indx].at(layer)->Fill(occupancy); + } } } } -void HGCalSimHitValidation::FillHitsInfo(std::pair hits, unsigned int itimeslice, double esum) { - if (!geometrydefined_) return; - unsigned int ilayer = hits.first.layer -1; - energy_[itimeslice].at(ilayer)->Fill(esum); - if(itimeslice==1) { - EtaPhi_Plus_.at(ilayer)->Fill(hits.first.eta , hits.first.phi); - EtaPhi_Minus_.at(ilayer)->Fill(hits.first.eta , hits.first.phi); + +void HGCalSimHitValidation::FillHitsInfo(std::pair hits, + unsigned int itimeslice, double esum) { + if (geometrydefined_ && dbe_) { + unsigned int ilayer = hits.first.layer - 1; + if (ilayer < layers_) { + energy_[itimeslice].at(ilayer)->Fill(esum); + if (itimeslice==1) { + EtaPhi_Plus_.at(ilayer)->Fill(hits.first.eta , hits.first.phi); + EtaPhi_Minus_.at(ilayer)->Fill(hits.first.eta , hits.first.phi); + } + } else { + if (verbosity_>0) std::cout << "Problematic Hit for " << nameDetector_ + << " at sector " << hits.first.sector + << " layer " << hits.first.layer + << " cell " << hits.first.cell << " energy " + << hits.second.etotal << std::endl; + } } } @@ -215,7 +235,7 @@ bool HGCalSimHitValidation::defineGeometry(edm::ESTransientHandle hgcons_ = new HGCalDDDConstants(cview, nameDetector_); if (verbosity_>0) std::cout << "Initialize HGCalDDDConstants for " << nameDetector_ << " : " << hgcons_ < DDFilteredView fv(cview); fv.addFilter(filter); bool dodet = fv.firstChild(); - + while (dodet) { const DDSolid & sol = fv.logicalPart().solid(); std::string name = sol.name(); @@ -252,7 +272,7 @@ bool HGCalSimHitValidation::defineGeometry(edm::ESTransientHandle fv.translation().Z() ) ; const HepGeom::Transform3D ht3d (hr, h3v); transMap_.insert(std::make_pair(id,ht3d)); - if (verbosity_>1) std::cout << HGCalDetId(id) << " Transform using " + if (verbosity_>2) std::cout << HGCalDetId(id) << " Transform using " << h3v << " and " << hr; } dodet = fv.next(); @@ -276,79 +296,66 @@ void HGCalSimHitValidation::endJob() { } void HGCalSimHitValidation::beginRun(edm::Run const& iRun, edm::EventSetup const& iSetup) { - if (!geometrydefined_) { + if (!geometrydefined_ && dbe_) { edm::ESTransientHandle pDD; iSetup.get().get( pDD ); geometrydefined_ = defineGeometry(pDD); - - if (dbe_) { - layers = hgcons_->layers(false); - dbe_->setCurrentFolder("HGCalSimHitsV/"+nameDetector_); - - std::ostringstream histoname; - for (unsigned int ilayer = 0; ilayer < layers; ilayer++ ) { - for(int indx=0; indxbook1D( histoname.str().c_str(), "HitOccupancy_Plus", 2000, 0, 2000)); - histoname.str(""); histoname << "HitOccupancy_Minus" << indx << "_layer_" << ilayer; - HitOccupancy_Minus_[indx].push_back(dbe_->book1D( histoname.str().c_str(), "HitOccupancy_Minus", 2000, 0, 2000)); - } - - histoname.str(""); histoname << "EtaPhi_Plus_" << "layer_" << ilayer; - EtaPhi_Plus_.push_back(dbe_->book2D(histoname.str().c_str(), "Occupancy", 100, 1.75, 2.5, 72, -3.14, 3.14)); - histoname.str(""); histoname << "EtaPhi_Minus_" << "layer_" << ilayer; - EtaPhi_Minus_.push_back(dbe_->book2D(histoname.str().c_str(), "Occupancy", 100, -2.5, -1.75, 72, -3.14, 3.14)); - - for (int itimeslice = 0; itimeslice < 6 ; itimeslice++ ) { - histoname.str(""); histoname << "energy_time_"<< itimeslice << "_layer_" << ilayer; - energy_[itimeslice].push_back(dbe_->book1D(histoname.str().c_str(),"energy_",500,0,0.1)); - } - + + layers_ = hgcons_->layers(false); + if (verbosity_>0) std::cout << nameDetector_ << " defined with " + << layers_ << " Layers" << std::endl; + dbe_->setCurrentFolder("HGCalSimHitsV/"+nameDetector_); + + std::ostringstream histoname; + for (unsigned int ilayer = 0; ilayer < layers_; ilayer++ ) { + for(int indx=0; indxbook1D( histoname.str().c_str(), "HitOccupancy_Plus", 501, -0.5, 500.5)); + histoname.str(""); histoname << "HitOccupancy_Minus" << indx << "_layer_" << ilayer; + HitOccupancy_Minus_[indx].push_back(dbe_->book1D( histoname.str().c_str(), "HitOccupancy_Minus", 501, -0.5, 500.5)); } - for(int indx=0; indxbook1D( histoname.str().c_str(), "MeanHitOccupancy_Plus", 93, 0.5, 92.5); - histoname.str(""); histoname << "MeanHitOccupancy_Minus"<< indx ; - MeanHitOccupancy_Minus_[indx] = dbe_->book1D( histoname.str().c_str(), "MeanHitOccupancy_Minus", 93, 0.5, 92.5); + + histoname.str(""); histoname << "EtaPhi_Plus_" << "layer_" << ilayer; + EtaPhi_Plus_.push_back(dbe_->book2D(histoname.str().c_str(), "Occupancy", 155, 1.45, 3.0, 72, -3.14, 3.14)); + histoname.str(""); histoname << "EtaPhi_Minus_" << "layer_" << ilayer; + EtaPhi_Minus_.push_back(dbe_->book2D(histoname.str().c_str(), "Occupancy", 155, -3.0, -1.45, 72, -3.14, 3.14)); + + for (int itimeslice = 0; itimeslice < 6 ; itimeslice++ ) { + histoname.str(""); histoname << "energy_time_"<< itimeslice << "_layer_" << ilayer; + energy_[itimeslice].push_back(dbe_->book1D(histoname.str().c_str(),"energy_",500,0,0.1)); } - + + } + for(int indx=0; indxbook1D( histoname.str().c_str(), "MeanHitOccupancy_Plus", layers_, 0.5, layers_ + 0.5); + histoname.str(""); histoname << "MeanHitOccupancy_Minus"<< indx ; + MeanHitOccupancy_Minus_[indx] = dbe_->book1D( histoname.str().c_str(), "MeanHitOccupancy_Minus", layers_, 0.5, layers_ + 0.5); } + } - } + + // ------------ method called when ending the processing of a run ------------ void HGCalSimHitValidation::endRun(edm::Run const&, edm::EventSetup const&) { - if (geometrydefined_) { - if (dbe_) { - for(int ilayer=0; ilayer < (int)layers; ++ilayer) { - for(int indx=0; indx<4; ++indx){ - double meanVal = HitOccupancy_Plus_[indx].at(ilayer)->getMean(); - MeanHitOccupancy_Plus_[indx]->setBinContent(ilayer+1, meanVal); - meanVal = HitOccupancy_Minus_[indx].at(ilayer)->getMean(); - MeanHitOccupancy_Minus_[indx]->setBinContent(ilayer+1, meanVal); - } + if (geometrydefined_ && dbe_) { + for(int ilayer=0; ilayer < (int)layers_; ++ilayer) { + for(int indx=0; indx<4; ++indx){ + double meanVal = HitOccupancy_Plus_[indx].at(ilayer)->getMean(); + MeanHitOccupancy_Plus_[indx]->setBinContent(ilayer+1, meanVal); + meanVal = HitOccupancy_Minus_[indx].at(ilayer)->getMean(); + MeanHitOccupancy_Minus_[indx]->setBinContent(ilayer+1, meanVal); } - } + } } -// ------------ method called when starting to processes a luminosity block ------------ -/* -void HGCalSimHitValidation::beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) { -} -*/ - -// ------------ method called when ending the processing of a luminosity block ------------ -/* -void HGCalSimHitValidation::endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) { -} -*/ - // ------------ method fills 'descriptions' with the allowed parameters for the module ------------ void HGCalSimHitValidation::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { //The following says we do not know what parameters are allowed so do no validation @@ -359,6 +366,5 @@ void HGCalSimHitValidation::fillDescriptions(edm::ConfigurationDescriptions& des } #include "FWCore/Framework/interface/MakerMacros.h" - //define this as a plug-in DEFINE_FWK_MODULE(HGCalSimHitValidation); diff --git a/Validation/HGCalValidation/plugins/HGCalSimHitValidation.h b/Validation/HGCalValidation/plugins/HGCalSimHitValidation.h index 4b47b77734eba..a1eba5560ed9a 100644 --- a/Validation/HGCalValidation/plugins/HGCalSimHitValidation.h +++ b/Validation/HGCalValidation/plugins/HGCalSimHitValidation.h @@ -51,35 +51,35 @@ #include class HGCalSimHitValidation : public edm::EDAnalyzer { - + public: struct energysum{ - energysum() {e15=e25=e50=e100=e250=e1000=0.0;} - double e15, e25, e50, e100, e250, e1000; + energysum() {e15=e25=e50=e100=e250=e1000=etotal=0;} + double e15, e25, e50, e100, e250, e1000, etotal; }; - + struct hitsinfo{ hitsinfo() { - x=y=z=time=energy=phi=eta=0.0; + x=y=z=phi=eta=0.0; cell=sector=layer=0; } - double x, y, z, time, energy, phi, eta ; + double x, y, z, phi, eta; int cell, sector, layer; }; - + explicit HGCalSimHitValidation(const edm::ParameterSet&); ~HGCalSimHitValidation(); static void fillDescriptions(edm::ConfigurationDescriptions& descriptions); void analyzeHits (std::vector& hits); - - void FillHitsInfo(std::pair hit_, unsigned int itimeslice, double esum); + + void fillOccupancyMap(std::map& OccupancyMap, int layer); void FillHitsInfo(); + void FillHitsInfo(std::pair hit_, unsigned int itimeslice, double esum); static const int netaBins = 4; - private: virtual void beginJob() override; virtual void analyze(const edm::Event&, const edm::EventSetup&) override; @@ -90,15 +90,16 @@ class HGCalSimHitValidation : public edm::EDAnalyzer { // ----------member data --------------------------- std::string nameDetector_, caloHitSource_; - DQMStore *dbe_; - HGCalDDDConstants *hgcons_; + DQMStore *dbe_; + HGCalDDDConstants *hgcons_; int verbosity_; bool geometrydefined_, symmDet_; - unsigned int layers; + unsigned int layers_; std::map transMap_; - std::vector hitsPerLayerPlus[netaBins]; - std::vector hitsPerLayerMinus[netaBins]; - + + std::map OccupancyMap_plus[netaBins]; + std::map OccupancyMap_minus[netaBins]; + std::vector HitOccupancy_Plus_[netaBins]; std::vector HitOccupancy_Minus_[netaBins]; std::vector EtaPhi_Plus_; diff --git a/Validation/HGCalValidation/plugins/HGCalSimHitsClient.cc b/Validation/HGCalValidation/plugins/HGCalSimHitsClient.cc index 057b270bbccde..6287269f0c971 100644 --- a/Validation/HGCalValidation/plugins/HGCalSimHitsClient.cc +++ b/Validation/HGCalValidation/plugins/HGCalSimHitsClient.cc @@ -11,14 +11,13 @@ #include"DetectorDescription/Core/interface/DDFilteredView.h" #include "DetectorDescription/Core/interface/DDSolid.h" #include "Geometry/Records/interface/IdealGeometryRecord.h" -//#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -//#include "SimDataFormats/CaloTest/interface/HcalTestNumbering.h" HGCalSimHitsClient::HGCalSimHitsClient(const edm::ParameterSet& iConfig) { dbe_ = edm::Service().operator->(); outputFile_ = iConfig.getUntrackedParameter("outputFile", "myfile.root"); nameDetector_ = iConfig.getParameter("DetectorName"); + verbosity_ = iConfig.getUntrackedParameter("Verbosity",0); if (!dbe_) { edm::LogError("HGCalSimHitsClient") << "unable to get DQMStore service, upshot is no client histograms will be made"; @@ -27,16 +26,16 @@ HGCalSimHitsClient::HGCalSimHitsClient(const edm::ParameterSet& iConfig) { if (dbe_) dbe_->setVerbose(0); } - debug_ = false; - verbose_ = true; - //dirName_= iConfig.getParameter("DQMDirName"); if (dbe_) dbe_->setCurrentFolder("/"); } HGCalSimHitsClient::~HGCalSimHitsClient() { } -void HGCalSimHitsClient::beginJob() { } +void HGCalSimHitsClient::beginJob() { + geometrydefined_ = false; + symmDet_ = true; +} void HGCalSimHitsClient::endJob() { if ( outputFile_.size() != 0 && dbe_ ) dbe_->save(outputFile_); @@ -61,29 +60,30 @@ void HGCalSimHitsClient::endLuminosityBlock(const edm::LuminosityBlock&, const e void HGCalSimHitsClient::runClient_() { if (!dbe_) return; dbe_->setCurrentFolder("/"); - if (verbose_) std::cout << "\nrunClient" << std::endl; + if (verbosity_>0) std::cout << "\nrunClient" << std::endl; std::vector hgcalMEs; std::vector fullDirPath = dbe_->getSubdirs(); for (unsigned int i=0; i0) std::cout << "\nfullPath: " << fullDirPath.at(i) << std::endl; dbe_->setCurrentFolder(fullDirPath.at(i)); std::vector fullSubDirPath = dbe_->getSubdirs(); for (unsigned int j=0; j0) std::cout << "fullSubPath: " << fullSubDirPath.at(j) << std::endl; std::string nameDirectory = "HGCalSimHitsV/"+nameDetector_; + if (strcmp(fullSubDirPath.at(j).c_str(), nameDirectory.c_str()) == 0) { hgcalMEs = dbe_->getContents(fullSubDirPath.at(j)); - if (verbose_) std::cout << "hgcalMES size : " << hgcalMEs.size() <0) std::cout << "hgcalMES size : " << hgcalMEs.size() <& hgcalMEs) { + if(!geometrydefined_) return 0; std::vector energy_[6]; std::vector EtaPhi_Plus_; std::vector EtaPhi_Minus_; @@ -95,8 +95,7 @@ int HGCalSimHitsClient::SimHitsEndjob(const std::vector& hgcalM std::ostringstream name; double nevent; int nbinsx, nbinsy; - - layers_ = hgcons_->layers(false); + unsigned int layers_ = hgcons_->layers(false); for (unsigned int ilayer = 0; ilayer < layers_; ilayer++ ){ for (int itimeslice = 0; itimeslice < 6 ; itimeslice++ ) { //Energy @@ -114,7 +113,7 @@ int HGCalSimHitsClient::SimHitsEndjob(const std::vector& hgcalM energy_[itimeslice].at(ilayer)->setBinContent(i,binValue); } }///loop over timeslice - + //EtaPhi 2d plots name.str(""); name << "EtaPhi_Plus_" << "layer_" << ilayer; for(unsigned int ih=0; ih& hgcalM } bool HGCalSimHitsClient::defineGeometry(edm::ESTransientHandle &ddViewH){ - const DDCompactView & cview = *ddViewH; hgcons_ = new HGCalDDDConstants(cview, nameDetector_); - if (verbose_>0) std::cout << "Initialize HGCalDDDConstants for " + if (verbosity_>0) std::cout << "Initialize HGCalDDDConstants for " << nameDetector_ << " : " << hgcons_ < &d DD3Vector x, y, z; fv.rotation().GetComponents( x, y, z ) ; const CLHEP::HepRep3x3 rotation ( x.X(), y.X(), z.X(), - x.Y(), y.Y(), z.Y(), - x.Z(), y.Z(), z.Z() ); - + x.Y(), y.Y(), z.Y(), + x.Z(), y.Z(), z.Z() ); const CLHEP::HepRotation hr ( rotation ); const CLHEP::Hep3Vector h3v ( fv.translation().X(), fv.translation().Y(), fv.translation().Z() ) ; const HepGeom::Transform3D ht3d (hr, h3v); transMap_.insert(std::make_pair(id,ht3d)); - if (verbose_>1) std::cout << HGCalDetId(id) << " Transform using " + if (verbosity_>2) std::cout << HGCalDetId(id) << " Transform using " << h3v << " and " << hr; } dodet = fv.next(); } - - if (verbose_>0) std::cout << "Finds " << transMap_.size() << " elements" + if (verbosity_>0) std::cout << "Finds " << transMap_.size() << " elements" << " and SymmDet_ = " << symmDet_ << std::endl; return true; } diff --git a/Validation/HGCalValidation/plugins/HGCalSimHitsClient.h b/Validation/HGCalValidation/plugins/HGCalSimHitsClient.h index d13a9bb33f71c..dc44fd53f5ed4 100644 --- a/Validation/HGCalValidation/plugins/HGCalSimHitsClient.h +++ b/Validation/HGCalValidation/plugins/HGCalSimHitsClient.h @@ -27,7 +27,6 @@ #include "FWCore/Framework/interface/ESTransientHandle.h" #include "Geometry/HGCalCommonData/interface/HGCalDDDConstants.h" #include "DataFormats/ForwardDetId/interface/HGCalDetId.h" -//#include "Geometry/HcalCommonData/interface/HcalDDDRecConstants.h" #include #include @@ -38,22 +37,21 @@ class MonitorElement; class HGCalSimHitsClient : public edm::EDAnalyzer { - private: +private: DQMStore* dbe_; //dbe seems to be the standard name for this, I dont know why. We of course dont own it std::string outputFile_; edm::ParameterSet conf_; - bool verbose_; - bool debug_; //member data std::string dirName_; std::string nameDetector_; + int verbosity_; HGCalDDDConstants *hgcons_; bool geometrydefined_, symmDet_; - unsigned int layers_; + // unsigned int layers_; std::map transMap_; - public: +public: explicit HGCalSimHitsClient(const edm::ParameterSet& ); virtual ~HGCalSimHitsClient(); diff --git a/Validation/HGCalValidation/python/HGCalDigiClient_cfi.py b/Validation/HGCalValidation/python/HGCalDigiClient_cfi.py new file mode 100644 index 0000000000000..02b6d486c5f88 --- /dev/null +++ b/Validation/HGCalValidation/python/HGCalDigiClient_cfi.py @@ -0,0 +1,7 @@ +import FWCore.ParameterSet.Config as cms + +hgcalDigiClientEE = cms.EDAnalyzer("HGCalDigiClient", + outputFile = cms.untracked.string(''), + DetectorName = cms.string("HGCalEESensitive"), + Verbosity = cms.untracked.int32(0) + ) diff --git a/Validation/HGCalValidation/python/HGCalRecHitsClient_cfi.py b/Validation/HGCalValidation/python/HGCalRecHitsClient_cfi.py new file mode 100644 index 0000000000000..d2017b7094b5e --- /dev/null +++ b/Validation/HGCalValidation/python/HGCalRecHitsClient_cfi.py @@ -0,0 +1,7 @@ +import FWCore.ParameterSet.Config as cms + +hgcalRecHitClientEE = cms.EDAnalyzer("HGCalRecHitsClient", + outputFile = cms.untracked.string(''), + DetectorName = cms.string("HGCalEESensitive"), + Verbosity = cms.untracked.int32(0) + ) diff --git a/Validation/HGCalValidation/python/HGCalSimHitsClient_cfi.py b/Validation/HGCalValidation/python/HGCalSimHitsClient_cfi.py new file mode 100644 index 0000000000000..e3676c8d72ca0 --- /dev/null +++ b/Validation/HGCalValidation/python/HGCalSimHitsClient_cfi.py @@ -0,0 +1,7 @@ +import FWCore.ParameterSet.Config as cms + +hgcalSimHitClientEE = cms.EDAnalyzer("HGCalSimHitsClient", + outputFile = cms.untracked.string(''), + DetectorName = cms.string("HGCalEESensitive"), + Verbosity = cms.untracked.int32(0) + ) diff --git a/Validation/HGCalValidation/python/digiValidation_cfi.py b/Validation/HGCalValidation/python/digiValidation_cfi.py new file mode 100644 index 0000000000000..ef894ba25c859 --- /dev/null +++ b/Validation/HGCalValidation/python/digiValidation_cfi.py @@ -0,0 +1,8 @@ +import FWCore.ParameterSet.Config as cms + +hgcalDigiValidationEE = cms.EDAnalyzer('HGCalDigiValidation', + DetectorName = cms.string("HGCalEESensitive"), + DigiSource = cms.string("HGCDigisEE"), + Verbosity = cms.untracked.int32(0), + SampleIndx = cms.untracked.int32(5) + ) diff --git a/Validation/HGCalValidation/python/rechitValidation_cfi.py b/Validation/HGCalValidation/python/rechitValidation_cfi.py new file mode 100644 index 0000000000000..a6c3c9f525cd3 --- /dev/null +++ b/Validation/HGCalValidation/python/rechitValidation_cfi.py @@ -0,0 +1,7 @@ +import FWCore.ParameterSet.Config as cms + +hgcalRecHitValidationEE = cms.EDAnalyzer('HGCalRecHitValidation', + DetectorName = cms.string("HGCalEESensitive"), + RecHitSource = cms.string("HGCEERecHits"), + Verbosity = cms.untracked.int32(0) + ) diff --git a/Validation/HGCalValidation/python/simhitValidation_cfi.py b/Validation/HGCalValidation/python/simhitValidation_cfi.py index 9e8ecc1c66ce2..49d43fa1a35d3 100644 --- a/Validation/HGCalValidation/python/simhitValidation_cfi.py +++ b/Validation/HGCalValidation/python/simhitValidation_cfi.py @@ -3,5 +3,5 @@ hgcalSimHitValidationEE = cms.EDAnalyzer('HGCalSimHitValidation', DetectorName = cms.string("HGCalEESensitive"), CaloHitSource = cms.string("HGCHitsEE"), - Verbosity = cms.untracked.int32(1) -) + Verbosity = cms.untracked.int32(0) + ) diff --git a/Validation/HGCalValidation/test/digiClient_cfg.py b/Validation/HGCalValidation/test/digiClient_cfg.py new file mode 100644 index 0000000000000..0a249d768fe3e --- /dev/null +++ b/Validation/HGCalValidation/test/digiClient_cfg.py @@ -0,0 +1,59 @@ +import FWCore.ParameterSet.Config as cms +import os + +process = cms.Process("CLIENT") + +process.load("Configuration.StandardSequences.Reconstruction_cff") +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff') +process.load ('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff') +process.load('Configuration.StandardSequences.EndOfProcess_cff') + +process.load('FWCore.MessageService.MessageLogger_cfi') +process.MessageLogger.cerr.FwkReport.reportEvery = 1 + +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.autoCond import autoCond +process.GlobalTag.globaltag = autoCond['upgradePLS3'] + + +process.load("Validation.HGCalValidation.HGCalDigiClient_cfi") +process.hgcalDigiClientEE.Verbosity = 2 +process.hgcalDigiClientHEF = process.hgcalDigiClientEE.clone( + DetectorName = cms.string("HGCalHESiliconSensitive")) +process.hgcalDigiClientHEB = process.hgcalDigiClientEE.clone( + DetectorName = cms.string("HGCalHEScintillatorSensitive")) + + +process.load("DQMServices.Core.DQM_cfg") +process.DQM.collectorHost = '' + +# summary +process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(True) ) ## ?????? + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(1) + ) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring( + 'file:./DigiVal_pi.root' + ) + ) + +process.load("Configuration.StandardSequences.EDMtoMEAtRunEnd_cff") +process.dqmSaver.referenceHandling = cms.untracked.string('all') + +cmssw_version = os.environ.get('CMSSW_VERSION','CMSSW_X_Y_Z') +Workflow = '/HGCalValidation/'+'Harvesting/'+str(cmssw_version) +process.dqmSaver.workflow = Workflow + +process.load("Validation.HGCalValidation.HGCalDigiClient_cfi") +process.hgcalDigiClientEE.outputFile = 'HGCalDigiHarvestingEE.root' +process.hgcalDigiClientHEF.outputFile = 'HGCalDigiHarvestingHEF.root' +process.hgcalDigiClientHEB.outputFile = 'HGCalDigiHarvestingHEB.root' + +process.p = cms.Path(process.EDMtoME * + process.hgcalDigiClientEE * + process.hgcalDigiClientHEF * + process.hgcalDigiClientHEB * + process.dqmSaver) diff --git a/Validation/HGCalValidation/test/digiValidation_cfg.py b/Validation/HGCalValidation/test/digiValidation_cfg.py new file mode 100644 index 0000000000000..48399e7748678 --- /dev/null +++ b/Validation/HGCalValidation/test/digiValidation_cfg.py @@ -0,0 +1,137 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process('SIM') + +# import of standard configurations +process.load('Configuration.StandardSequences.Services_cff') +process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi') +process.load('FWCore.MessageService.MessageLogger_cfi') +process.load('Configuration.EventContent.EventContent_cff') +process.load('FWCore.MessageService.MessageLogger_cfi') +process.load('Configuration.EventContent.EventContent_cff') +process.load('SimGeneral.MixingModule.mixNoPU_cfi') +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff') +process.load ('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff') +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') +process.load('Configuration.StandardSequences.Generator_cff') +process.load('IOMC.EventVertexGenerators.VtxSmearedGauss_cfi') +process.load('GeneratorInterface.Core.genFilterSummary_cff') +process.load('Configuration.StandardSequences.SimIdeal_cff') +process.load('Configuration.StandardSequences.Digi_cff') +process.load('Configuration.StandardSequences.SimL1Emulator_cff') +process.load('Configuration.StandardSequences.DigiToRaw_cff') +process.load('Configuration.StandardSequences.EndOfProcess_cff') +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(5) + ) + +# Input source +process.source = cms.Source("EmptySource") + +process.options = cms.untracked.PSet() + +# Production Info +process.configurationMetadata = cms.untracked.PSet( + version = cms.untracked.string('$Revision: 1.20 $'), + annotation = cms.untracked.string('SingleElectronPt10_cfi nevts:10'), + name = cms.untracked.string('Applications') + ) + +# Output definition + +process.FEVTDEBUGHLToutput = cms.OutputModule("PoolOutputModule", + splitLevel = cms.untracked.int32(0), + eventAutoFlushCompressedSize = cms.untracked.int32(5242880), + outputCommands = process.FEVTDEBUGHLTEventContent.outputCommands, + fileName = cms.untracked.string('file:digi_input_5000evts.root'), + dataset = cms.untracked.PSet( + filterName = cms.untracked.string(''), + dataTier = cms.untracked.string('GEN-SIM-DIGI-RAW') + ), + SelectEvents = cms.untracked.PSet(SelectEvents = cms.vstring('generation_step')) + ) + +# Additional output definition + +# Other statements +process.genstepfilter.triggerConditions=cms.vstring("generation_step") +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') + +process.generator = cms.EDProducer("FlatRandomPtGunProducer", + PGunParameters = cms.PSet( + MaxPt = cms.double(10.01), + MinPt = cms.double(9.99), + PartID = cms.vint32(11), + MaxEta = cms.double(2.5), + MaxPhi = cms.double(3.14159265359), + MinEta = cms.double(-2.5), + MinPhi = cms.double(-3.14159265359) + ), + Verbosity = cms.untracked.int32(0), + psethack = cms.string('single electron pt 10'), + AddAntiParticle = cms.bool(True), + firstRun = cms.untracked.uint32(1) +) + +process.mix.digitizers = cms.PSet(process.theDigitizersValid) + +# Path and EndPath definitions +process.generation_step = cms.Path(process.pgen) +process.simulation_step = cms.Path(process.psim) +process.genfiltersummary_step = cms.EndPath(process.genFilterSummary) +process.digitisation_step = cms.Path(process.pdigi_valid) +process.L1simulation_step = cms.Path(process.SimL1Emulator) +process.digi2raw_step = cms.Path(process.DigiToRaw) +process.endjob_step = cms.EndPath(process.endOfProcess) +process.FEVTDEBUGHLToutput_step = cms.EndPath(process.FEVTDEBUGHLToutput) + +# Output definition +process.ValidationOutput = cms.OutputModule("PoolOutputModule", + outputCommands = cms.untracked.vstring('drop *', 'keep *_MEtoEDMConverter_*_*'), + fileName = cms.untracked.string('file:output_digiVal_test.root'), +) + +process.load("DQMServices.Core.DQM_cfg") +process.DQM.collectorHost = '' +process.load("DQMServices.Components.MEtoEDMConverter_cfi") + +process.load("Validation.HGCalValidation.digiValidation_cfi") +process.hgcalDigiValidationEE.Verbosity = 0 +process.hgcalDigiValidationEE.SampleIndx = 0 # 0 to 5 +process.hgcalDigiValidationHEF = process.hgcalDigiValidationEE.clone( + DetectorName = cms.string("HGCalHESiliconSensitive"), + DigiSource = cms.string("HGCDigisHEfront")) +process.hgcalDigiValidationHEB = process.hgcalDigiValidationEE.clone( + DetectorName = cms.string("HGCalHEScintillatorSensitive"), + DigiSource = cms.string("HGCDigisHEback")) + +## path and endpath deffinition +process.p1 = cms.Path(process.hgcalDigiValidationEE+ + process.hgcalDigiValidationHEF+ + process.hgcalDigiValidationHEB) +process.p2 = cms.Path(process.MEtoEDMConverter) +process.output_step = cms.EndPath(process.ValidationOutput) + +# Schedule definition +process.schedule = cms.Schedule(process.generation_step,process.genfiltersummary_step, + process.simulation_step,process.digitisation_step, + process.L1simulation_step,process.digi2raw_step, + process.endjob_step,process.p1,process.p2,process.output_step) + +# filter all path with the production filter sequence +for path in process.paths: + getattr(process,path)._seq = process.generator * getattr(process,path)._seq + + # customisation of the process. + # Automatic addition of the customisation function from SLHCUpgradeSimulations.Configuration.combinedCustoms + from SLHCUpgradeSimulations.Configuration.combinedCustoms import cust_2023HGCalMuon + +#call to customisation function cust_2023HGCalMuon imported from SLHCUpgradeSimulations.Configuration.combinedCustoms +process = cust_2023HGCalMuon(process) + +# End of customisation functions +#outfile = open("EdmDumpPyhon.py","w") +#outfile.write(process.dumpPython()) diff --git a/Validation/HGCalValidation/test/recHitClient_cfg.py b/Validation/HGCalValidation/test/recHitClient_cfg.py new file mode 100644 index 0000000000000..68c3c97395e59 --- /dev/null +++ b/Validation/HGCalValidation/test/recHitClient_cfg.py @@ -0,0 +1,58 @@ +import FWCore.ParameterSet.Config as cms +import os + +process = cms.Process("CLIENT") + +process.load("Configuration.StandardSequences.Reconstruction_cff") #### ??????? +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff') +process.load ('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff') +process.load('Configuration.StandardSequences.EndOfProcess_cff') + +process.load('FWCore.MessageService.MessageLogger_cfi') +process.MessageLogger.cerr.FwkReport.reportEvery = 1 + +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +from Configuration.AlCa.autoCond import autoCond +process.GlobalTag.globaltag = autoCond['upgradePLS3'] + + +process.load("Validation.HGCalValidation.HGCalRecHitsClient_cfi") +process.hgcalRecHitClientEE.Verbosity = 2 +process.hgcalRecHitClientHEF = process.hgcalRecHitClientEE.clone( + DetectorName = cms.string("HGCalHESiliconSensitive")) +process.hgcalRecHitClientHEB = process.hgcalRecHitClientEE.clone( + DetectorName = cms.string("HGCalHEScintillatorSensitive")) + + +process.load("DQMServices.Core.DQM_cfg") +process.DQM.collectorHost = '' + +# summary +process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(True) ) ## ?????? + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(1) + ) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:./test_output_rechitVal.root') + ) + + +process.load("Configuration.StandardSequences.EDMtoMEAtRunEnd_cff") +process.dqmSaver.referenceHandling = cms.untracked.string('all') + +cmssw_version = os.environ.get('CMSSW_VERSION','CMSSW_X_Y_Z') +Workflow = '/HGCalValidation/'+'Harvesting/'+str(cmssw_version) +process.dqmSaver.workflow = Workflow + +process.load("Validation.HGCalValidation.HGCalRecHitsClient_cfi") +process.hgcalRecHitClientEE.outputFile = 'HGCalRecHitsHarvestingEE.root' +process.hgcalRecHitClientHEF.outputFile = 'HGCalRecHitsHarvestingHEF.root' +process.hgcalRecHitClientHEB.outputFile = 'HGCalRecHitsHarvestingHEB.root' + +process.p = cms.Path(process.EDMtoME * + process.hgcalRecHitClientEE * + process.hgcalRecHitClientHEF * + process.hgcalRecHitClientHEB * + process.dqmSaver) diff --git a/Validation/HGCalValidation/test/rechitValidation_cfg.py b/Validation/HGCalValidation/test/rechitValidation_cfg.py new file mode 100644 index 0000000000000..78d4a1fd3b85b --- /dev/null +++ b/Validation/HGCalValidation/test/rechitValidation_cfg.py @@ -0,0 +1,153 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process('SIMDIGIRECO') + +# import of standard configurations +process.load('Configuration.StandardSequences.Services_cff') +process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi') +process.load('FWCore.MessageService.MessageLogger_cfi') +process.load('Configuration.EventContent.EventContent_cff') +process.load('FWCore.MessageService.MessageLogger_cfi') +process.load('Configuration.EventContent.EventContent_cff') +process.load('SimGeneral.MixingModule.mixNoPU_cfi') +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff')## +process.load ('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff')## +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff')## +process.load('Configuration.StandardSequences.Generator_cff') +process.load('IOMC.EventVertexGenerators.VtxSmearedGauss_cfi')## +process.load('GeneratorInterface.Core.genFilterSummary_cff') +process.load('Configuration.StandardSequences.SimIdeal_cff') +process.load('Configuration.StandardSequences.Digi_cff')## +process.load('Configuration.StandardSequences.SimL1Emulator_cff')## +process.load('Configuration.StandardSequences.DigiToRaw_cff')## +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load('Configuration.StandardSequences.L1Reco_cff') +process.load('Configuration.StandardSequences.Reconstruction_cff') +process.load('Configuration.StandardSequences.EndOfProcess_cff') +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(1) +) + +# Input source +process.source = cms.Source("EmptySource") + +process.options = cms.untracked.PSet( + +) + +# Production Info +process.configurationMetadata = cms.untracked.PSet( + version = cms.untracked.string('$Revision: 1.20 $'), + annotation = cms.untracked.string('SingleElectronPt10_cfi nevts:10'), + name = cms.untracked.string('Applications') +) + +# Output definition + +process.FEVTDEBUGHLToutput = cms.OutputModule("PoolOutputModule", + splitLevel = cms.untracked.int32(0), + eventAutoFlushCompressedSize = cms.untracked.int32(5242880), + outputCommands = process.FEVTDEBUGHLTEventContent.outputCommands, + fileName = cms.untracked.string('file:junk.root'), + dataset = cms.untracked.PSet( + filterName = cms.untracked.string(''), + dataTier = cms.untracked.string('GEN-SIM-DIGI-RECO') + ), + SelectEvents = cms.untracked.PSet( + SelectEvents = cms.vstring('generation_step') + ) +) + +# Additional output definition + +# Other statements +process.genstepfilter.triggerConditions=cms.vstring("generation_step") +from Configuration.AlCa.GlobalTag import GlobalTag +process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') + +process.generator = cms.EDProducer("FlatRandomPtGunProducer", + PGunParameters = cms.PSet( + MaxPt = cms.double(10.01), + MinPt = cms.double(9.99), + PartID = cms.vint32(11), + MaxEta = cms.double(2.5), + MaxPhi = cms.double(3.14159265359), + MinEta = cms.double(-2.5), + MinPhi = cms.double(-3.14159265359) + ), + Verbosity = cms.untracked.int32(0), + psethack = cms.string('single electron pt 10'), + AddAntiParticle = cms.bool(True), + firstRun = cms.untracked.uint32(1) +) + +process.mix.digitizers = cms.PSet(process.theDigitizersValid) + +# Path and EndPath definitions +process.generation_step = cms.Path(process.pgen) +process.simulation_step = cms.Path(process.psim) +process.genfiltersummary_step = cms.EndPath(process.genFilterSummary) +process.digitisation_step = cms.Path(process.pdigi_valid) +process.L1simulation_step = cms.Path(process.SimL1Emulator) +process.digi2raw_step = cms.Path(process.DigiToRaw) +process.raw2digi_step = cms.Path(process.RawToDigi) +process.L1Reco_step = cms.Path(process.L1Reco) +process.reconstruction_step = cms.Path(process.reconstruction) +process.endjob_step = cms.EndPath(process.endOfProcess) +process.FEVTDEBUGHLToutput_step = cms.EndPath(process.FEVTDEBUGHLToutput) + +################################################################################################# +################################################################################################# +# Output definition +process.ValidationOutput = cms.OutputModule("PoolOutputModule", + outputCommands = cms.untracked.vstring('drop *', 'keep *_MEtoEDMConverter_*_*'), + fileName = cms.untracked.string('file:output_rechitVal.root'), + ) + +process.load("DQMServices.Core.DQM_cfg") +process.DQM.collectorHost = '' +process.load("DQMServices.Components.MEtoEDMConverter_cfi") +process.load("Validation.HGCalValidation.rechitValidation_cfi") +process.hgcalRecHitValidationEE.Verbosity = 0 +### +process.hgcalRecHitValidationHEF = process.hgcalRecHitValidationEE.clone( + DetectorName = cms.string("HGCalHESiliconSensitive"), + RecHitSource = cms.string("HGCHEFRecHits")) +process.hgcalRecHitValidationHEB = process.hgcalRecHitValidationEE.clone( + DetectorName = cms.string("HGCalHEScintillatorSensitive"), + RecHitSource = cms.string("HGCHEBRecHits")) + +## path and endpath deffinition +process.p1 = cms.Path(process.hgcalRecHitValidationEE+process.hgcalRecHitValidationHEF+process.hgcalRecHitValidationHEB) +process.p2 = cms.Path(process.MEtoEDMConverter) +process.output_step = cms.EndPath(process.ValidationOutput) +################################################################################################ +################################################################################################ + +# Schedule definition +process.schedule = cms.Schedule(process.generation_step,process.genfiltersummary_step, + process.simulation_step,process.digitisation_step, + process.L1simulation_step,process.digi2raw_step, + process.raw2digi_step,process.L1Reco_step,process.reconstruction_step, + process.endjob_step,process.p1,process.p2,process.output_step) + +#process.schedule = cms.Schedule(process.p1,process.p2,process.output_step) + +# filter all path with the production filter sequence +for path in process.paths: + getattr(process,path)._seq = process.generator * getattr(process,path)._seq + +# customisation of the process. + +# Automatic addition of the customisation function from SLHCUpgradeSimulations.Configuration.combinedCustoms +from SLHCUpgradeSimulations.Configuration.combinedCustoms import cust_2023HGCalMuon + +#call to customisation function cust_2023HGCalMuon imported from SLHCUpgradeSimulations.Configuration.combinedCustoms +process = cust_2023HGCalMuon(process) + +# End of customisation functions + +#outfile = open("EdmDumpPyhon.py","w") +#outfile.write(process.dumpPython()) diff --git a/Validation/HGCalValidation/test/simHitClient_cfg.py b/Validation/HGCalValidation/test/simHitClient_cfg.py index b47d2e2326166..da339f598bbaf 100644 --- a/Validation/HGCalValidation/test/simHitClient_cfg.py +++ b/Validation/HGCalValidation/test/simHitClient_cfg.py @@ -4,8 +4,10 @@ process = cms.Process("CLIENT") process.load("Configuration.StandardSequences.Reconstruction_cff") #### ??????? -process.load('Configuration.Geometry.GeometryExtended2023HGCalReco_cff') -process.load('Configuration.Geometry.GeometryExtended2023HGCal_cff') +#process.load('Configuration.Geometry.GeometryExtended2023HGCalReco_cff') +#process.load('Configuration.Geometry.GeometryExtended2023HGCal_cff') +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff') +process.load ('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff') process.load('Configuration.StandardSequences.EndOfProcess_cff') process.load('FWCore.MessageService.MessageLogger_cfi') @@ -16,7 +18,8 @@ process.GlobalTag.globaltag = autoCond['upgradePLS3'] -process.load("Validation.HGCalValidation.simhitClient_cfi") +process.load("Validation.HGCalValidation.HGCalSimHitsClient_cfi") +process.hgcalSimHitClientEE.Verbosity = 0 process.hgcalSimHitClientHEF = process.hgcalSimHitClientEE.clone( DetectorName = cms.string("HGCalHESiliconSensitive")) process.hgcalSimHitClientHEB = process.hgcalSimHitClientEE.clone( @@ -30,14 +33,14 @@ process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(True) ) ## ?????? process.maxEvents = cms.untracked.PSet( - input = cms.untracked.int32(-1) -) + input = cms.untracked.int32(1) + ) process.source = cms.Source("PoolSource", - fileNames = cms.untracked.vstring( - 'file:output.root' - ) -) + fileNames = cms.untracked.vstring('file:./output_test.root') + ) + +#process.source = cms.Source("EmptySource") process.load("Configuration.StandardSequences.EDMtoMEAtRunEnd_cff") process.dqmSaver.referenceHandling = cms.untracked.string('all') @@ -46,7 +49,7 @@ Workflow = '/HGCalValidation/'+'Harvesting/'+str(cmssw_version) process.dqmSaver.workflow = Workflow -process.load("Validation.HGCalValidation.simhitClient_cfi") +process.load("Validation.HGCalValidation.HGCalSimHitsClient_cfi") process.hgcalSimHitClientEE.outputFile = 'HGCalSimHitsHarvestingEE.root' process.hgcalSimHitClientHEF.outputFile = 'HGCalSimHitsHarvestingHEF.root' process.hgcalSimHitClientHEB.outputFile = 'HGCalSimHitsHarvestingHEB.root' diff --git a/Validation/HGCalValidation/test/simHitValidation_cfg.py b/Validation/HGCalValidation/test/simHitValidation_cfg.py index d72193243fd19..0f740ef11c792 100644 --- a/Validation/HGCalValidation/test/simHitValidation_cfg.py +++ b/Validation/HGCalValidation/test/simHitValidation_cfg.py @@ -8,11 +8,15 @@ process.load('FWCore.MessageService.MessageLogger_cfi') process.load('Configuration.EventContent.EventContent_cff') process.load('SimGeneral.MixingModule.mixNoPU_cfi') -process.load('Configuration.Geometry.GeometryExtended2023HGCalReco_cff') -process.load('Configuration.Geometry.GeometryExtended2023HGCal_cff') -process.load('Configuration.StandardSequences.MagneticField_38T_cff') +#process.load('Configuration.Geometry.GeometryExtended2023HGCalReco_cff') +#process.load('Configuration.Geometry.GeometryExtended2023HGCal_cff') +#process.load('Configuration.StandardSequences.MagneticField_38T_cff') +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff')## +process.load ('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff')## +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff')## process.load('Configuration.StandardSequences.Generator_cff') -process.load('IOMC.EventVertexGenerators.VtxSmearedRealistic8TeVCollision_cfi') +#process.load('IOMC.EventVertexGenerators.VtxSmearedRealistic8TeVCollision_cfi') +process.load('IOMC.EventVertexGenerators.VtxSmearedGauss_cfi')## process.load('GeneratorInterface.Core.genFilterSummary_cff') process.load('Configuration.StandardSequences.SimIdeal_cff') process.load('Configuration.StandardSequences.EndOfProcess_cff') @@ -41,8 +45,8 @@ MaxEta = cms.double(2.50), MinPhi = cms.double(-3.1415926), MaxPhi = cms.double(3.1415926), - MinE = cms.double(100.00), - MaxE = cms.double(100.00) + MinE = cms.double(10.00), + MaxE = cms.double(10.00) ), Verbosity = cms.untracked.int32(0), AddAntiParticle = cms.bool(False) From aee0795b83413cea6b8baa092152dbdd43f0328e Mon Sep 17 00:00:00 2001 From: Giovanni Franzoni Date: Tue, 23 Sep 2014 08:35:35 +0200 Subject: [PATCH 119/252] RequestType RequestPriority are now set for all relvals submissions; as agreed with dcompops/dataops; this change affects only relval production submission --- Configuration/PyReleaseValidation/python/MatrixInjector.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Configuration/PyReleaseValidation/python/MatrixInjector.py b/Configuration/PyReleaseValidation/python/MatrixInjector.py index 50e935a442895..07d44e2affb1f 100644 --- a/Configuration/PyReleaseValidation/python/MatrixInjector.py +++ b/Configuration/PyReleaseValidation/python/MatrixInjector.py @@ -79,7 +79,9 @@ def __init__(self,opt,mode='init',options=''): print '\n\tFound wmclient\n' self.defaultChain={ - "RequestType" : "TaskChain", #this is how we handle relvals + "RequestType" : "TaskChain", #this is how we handle relvals + "SubRequestType" : "RelVal", #this is how we handle relvals, now that TaskChain is also used for central MC production + "RequestPriority": 110000, "Requestor": self.user, #Person responsible "Group": self.group, #group for the request "CMSSWVersion": os.getenv('CMSSW_VERSION'), #CMSSW Version (used for all tasks in chain) From 31bb71ab14519f12626133f4da7bd7c1464190b4 Mon Sep 17 00:00:00 2001 From: Giovanni Franzoni Date: Tue, 23 Sep 2014 10:27:58 +0200 Subject: [PATCH 120/252] RequestType RequestPriority are now set for all relvals submissions; as agreed with dcompops/dataops; this change affects only relval production submission --- Configuration/PyReleaseValidation/python/MatrixInjector.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Configuration/PyReleaseValidation/python/MatrixInjector.py b/Configuration/PyReleaseValidation/python/MatrixInjector.py index 07d44e2affb1f..d08dd1e0b0d43 100644 --- a/Configuration/PyReleaseValidation/python/MatrixInjector.py +++ b/Configuration/PyReleaseValidation/python/MatrixInjector.py @@ -81,7 +81,7 @@ def __init__(self,opt,mode='init',options=''): self.defaultChain={ "RequestType" : "TaskChain", #this is how we handle relvals "SubRequestType" : "RelVal", #this is how we handle relvals, now that TaskChain is also used for central MC production - "RequestPriority": 110000, + "RequestPriority": 1000000, "Requestor": self.user, #Person responsible "Group": self.group, #group for the request "CMSSWVersion": os.getenv('CMSSW_VERSION'), #CMSSW Version (used for all tasks in chain) From a88ad41a7adb862633e4822a49f3cb331356e53d Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Tue, 23 Sep 2014 15:00:01 +0200 Subject: [PATCH 121/252] HGCAL V5 geometry matching to TC drawings --- Geometry/HGCalCommonData/data/v5/hgcal.xml | 27 +++++++++---------- .../HGCalCommonData/data/v5/hgcalHEsci.xml | 4 +-- .../HGCalCommonData/data/v5/hgcalHEsil.xml | 4 +-- 3 files changed, 17 insertions(+), 18 deletions(-) diff --git a/Geometry/HGCalCommonData/data/v5/hgcal.xml b/Geometry/HGCalCommonData/data/v5/hgcal.xml index 2d1d02b3cb935..298c854bf2b43 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcal.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcal.xml @@ -2,21 +2,20 @@ - - + - - - - - - - - + + + + + + + + - + @@ -28,9 +27,9 @@ - - - + + + diff --git a/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml b/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml index 90a03a4fe8d26..84d407bd43586 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml @@ -2,11 +2,11 @@ - + - + diff --git a/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml b/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml index 0ff15ed87ec36..6ec67b33bfae9 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml @@ -2,9 +2,9 @@ - + - + From d9d8bbdf3c981c7d462922f53fcaff594151736e Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 24 Sep 2014 10:59:49 +0200 Subject: [PATCH 122/252] merging with useAllChannels --- .../HGCSimProducers/interface/HGCDigitizer.h | 4 ++++ .../HGCSimProducers/src/HGCDigitizer.cc | 19 ++++++++++++++++--- 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h index bd26f5b287ee7..90d924efcd9e7 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h @@ -80,6 +80,10 @@ private : //subdetector id ForwardSubdetector mySubDet_; + //misc switches + bool useAllChannels_; + int verbosity_; + //reference speed to evaluate time of arrival at the sensititive detector, assuming the center of CMS float refSpeed_; diff --git a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc index abf3a4e5e9173..1b1edde3bdc4e 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc @@ -27,6 +27,8 @@ HGCDigitizer::HGCDigitizer(const edm::ParameterSet& ps) : maxSimHitsAccTime_ = ps.getParameter< uint32_t >("maxSimHitsAccTime"); bxTime_ = ps.getParameter< int32_t >("bxTime"); digitizationType_ = ps.getParameter< uint32_t >("digitizationType"); + useAllChannels_ = ps.getParameter< bool >("useAllChannels"); + verbosity_ = ps.getUntrackedParameter< int32_t >("verbosity",0); tofDelay_ = ps.getParameter< double >("tofDelay"); //get the random number generator @@ -152,6 +154,13 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i (uint32_t)HGCEEDetId(mySubDet_,simId.zside(),layer,simId.sector(),simId.subsector(),cell): (uint32_t)HGCHEDetId(mySubDet_,simId.zside(),layer,simId.sector(),simId.subsector(),cell) ); + if (verbosity_>0) { + if (producesEEDigis()) + std::cout << "HGCDigitizer: i/p " << simId << " o/p " << HGCEEDetId(id) << std::endl; + else + std::cout << "HGCDigitizer: i/p " << simId << " o/p " << HGCHEDetId(id) << std::endl; + } + //distance to the center of the detector float dist2center( geom->getPosition(id).mag() ); @@ -191,14 +200,18 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i baseData.fill(0.); const std::vector &validIds=geom->getValidDetIds(); int nadded(0); - for(std::vector::const_iterator it=validIds.begin(); it!=validIds.end(); it++) - { + if (useAllChannels_) { + for(std::vector::const_iterator it=validIds.begin(); it!=validIds.end(); it++) { uint32_t id(it->rawId()); if(simHitAccumulator_->find(id)!=simHitAccumulator_->end()) continue; simHitAccumulator_->insert( std::make_pair(id,baseData) ); nadded++; } - std::cout << "Added " << nadded << " detIds without " << hitCollection_ << " in first event processed" << std::endl; + } + if (verbosity_ > 0) + std::cout << "HGCDigitizer:Added " << nadded << ":" << validIds.size() + << " detIds without " << hitCollection_ + << " in first event processed" << std::endl; checkValidDetIds_=false; } From fda51cbaa2bfeac830320f700029d501ed06a9b6 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 24 Sep 2014 21:38:38 +0200 Subject: [PATCH 123/252] updating dataframe with a resize method, fixing production of single samples using the doTimeSamples parameter which was unused so far --- DataFormats/HGCDigi/interface/HGCDataFrame.h | 5 ++ .../interface/HGCDigitizerBase.h | 53 ++++++++++++------- .../HGCSimProducers/src/HGCHEbackDigitizer.cc | 7 +-- .../MixingModule/python/hgcalDigitizer_cfi.py | 18 ++++--- 4 files changed, 52 insertions(+), 31 deletions(-) diff --git a/DataFormats/HGCDigi/interface/HGCDataFrame.h b/DataFormats/HGCDigi/interface/HGCDataFrame.h index d5107a0f7a9cf..1af5ddf93bd1e 100644 --- a/DataFormats/HGCDigi/interface/HGCDataFrame.h +++ b/DataFormats/HGCDigi/interface/HGCDataFrame.h @@ -34,6 +34,11 @@ class HGCDataFrame { */ int size() const { return data_.size() & 0xf; } + /** + @short allow to set size + */ + void resize(size_t s) { data_.resize(s); } + /** @short assess/set specific samples */ diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index df3f3d81880e9..91b42ae41afd1 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -28,6 +28,7 @@ class HGCDigitizerBase { HGCDigitizerBase(const edm::ParameterSet &ps) : simpleNoiseGen_(0) { myCfg_ = ps.getParameter("digiCfg"); + doTimeSamples_ = ps.getParameter< bool >("doTimeSamples"); mipInKeV_ = myCfg_.getParameter("mipInKeV"); lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); @@ -88,30 +89,39 @@ class HGCDigitizerBase { rawDataFrame.setSample(i, singleSample); } - /* bool doDebug(rawDataFrame[3].adc()>2); */ - /* if(doDebug) */ - /* { */ - /* for(size_t iti=0;iti<6; iti++) */ - /* std::cout << rawDataFrame[iti].adc() << "(" << (it->second)[iti]*1e6 << ") ,"; */ - /* std::cout << "->"; */ - /* } */ - //run the shaper runShaper(rawDataFrame); + } + } - /* if(doDebug) */ - /* { */ - /* for(size_t iti=0;iti<6; iti++) */ - /* std::cout << rawDataFrame[iti].adc() << ","; */ - /* std::cout << std::endl; */ - /* } */ - - //check if 5th time sample is above threshold - if( rawDataFrame[4].adc() < adcThreshold_ ) continue; - - //add to collection to produce + /** + @short prepares the output according to the number of time samples to produce + */ + void updateOutput(std::auto_ptr &coll,D rawDataFrame) + { + size_t itIdx(4); //index to the in-time digi + + std::cout << "[updateOutput] doTimeSamples=" << doTimeSamples_ << std::endl; + + //check if in-time sample is above threshold and put result into the event + if(doTimeSamples_) + { + if(rawDataFrame[itIdx].adc() < adcThreshold_ ) return; coll->push_back(rawDataFrame); } + else + { + //create a new data frame containing only the in-time digi + D singleRawDataFrame( rawDataFrame.id() ); + singleRawDataFrame.resize(1); + + HGCSample singleSample; + singleSample.set(rawDataFrame[itIdx].gain(),rawDataFrame[itIdx].adc()); + singleRawDataFrame.setSample(0, singleSample); + std::cout << "Producing single time sample from itIdx=" << itIdx << " " << rawDataFrame[itIdx].adc() << " " << singleRawDataFrame[0].adc() << std::endl; + if(singleRawDataFrame[0].adc() < adcThreshold_ ) return; + coll->push_back(singleRawDataFrame); + } } /** @@ -133,7 +143,7 @@ class HGCDigitizerBase { newADC += uint16_t(oldADC[jt]*pow(relTime/(shaperN_*shaperTau_),shaperN_)*exp(-(relTime-shaperN_*shaperTau_)/shaperTau_)); } } - + HGCSample newSample; newSample.set(gain,newADC); dataFrame.setSample(it,newSample); @@ -174,6 +184,9 @@ class HGCDigitizerBase { //bunch time int bxTime_; + + //if true will put both in time and out-of-time samples in the event + bool doTimeSamples_; private: diff --git a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc index 6f63d72a6ba32..6db693adc1e5f 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc @@ -88,12 +88,9 @@ void HGCHEbackDigitizer::runCaliceLikeDigitizer(std::auto_ptrpush_back(newDataFrame); + //prepare the output + updateOutput(digiColl,newDataFrame); } } diff --git a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py index 2ed75dadad815..0c79b3c86a841 100644 --- a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py +++ b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py @@ -11,13 +11,15 @@ tofDelay = cms.double(1), digitizationType = cms.uint32(0), makeDigiSimLinks = cms.bool(False), + useAllChannels = cms.bool(True), + verbosity = cms.untracked.int32(0), digiCfg = cms.PSet( mipInKeV = cms.double(55.1), lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True), + doTimeSamples = cms.bool(False), shaperN = cms.double(1.), - shaperTau = cms.double(20.) + shaperTau = cms.double(0.) ) ) @@ -30,13 +32,15 @@ tofDelay = cms.double(1), digitizationType = cms.uint32(0), makeDigiSimLinks = cms.bool(False), + useAllChannels = cms.bool(True), + verbosity = cms.untracked.int32(0), digiCfg = cms.PSet( mipInKeV = cms.double(85.0), lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True), + doTimeSamples = cms.bool(False), shaperN = cms.double(1.), - shaperTau = cms.double(20.) + shaperTau = cms.double(0.) ) ) @@ -50,13 +54,15 @@ tofDelay = cms.double(1), digitizationType = cms.uint32(1), makeDigiSimLinks = cms.bool(False), + useAllChannels = cms.bool(True), + verbosity = cms.untracked.int32(0), digiCfg = cms.PSet( mipInKeV = cms.double(1498.4), lsbInMIP = cms.double(0.25), mip2noise = cms.double(5.0), adcThreshold = cms.uint32(4), - doTimeSamples = cms.bool(True), + doTimeSamples = cms.bool(False), shaperN = cms.double(1.), - shaperTau = cms.double(20.), + shaperTau = cms.double(0.), caliceSpecific = cms.PSet( nPEperMIP = cms.double(11.0), nTotalPE = cms.double(1156), xTalk = cms.double(0.25), From 415023abbc3dd1df809aa4fb27261cd8962e2b3f Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 24 Sep 2014 21:50:00 +0200 Subject: [PATCH 124/252] default set without pulse shape and only 1 time sample --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 91b42ae41afd1..97bb7689fd1e8 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -28,14 +28,14 @@ class HGCDigitizerBase { HGCDigitizerBase(const edm::ParameterSet &ps) : simpleNoiseGen_(0) { myCfg_ = ps.getParameter("digiCfg"); - doTimeSamples_ = ps.getParameter< bool >("doTimeSamples"); + bxTime_ = ps.getParameter("bxTime"); + doTimeSamples_ = myCfg_.getParameter< bool >("doTimeSamples"); mipInKeV_ = myCfg_.getParameter("mipInKeV"); lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); adcThreshold_ = myCfg_.getParameter< uint32_t >("adcThreshold"); shaperN_ = myCfg_.getParameter< double >("shaperN"); shaperTau_ = myCfg_.getParameter< double >("shaperTau"); - bxTime_ = ps.getParameter("bxTime"); } /** @@ -99,9 +99,7 @@ class HGCDigitizerBase { */ void updateOutput(std::auto_ptr &coll,D rawDataFrame) { - size_t itIdx(4); //index to the in-time digi - - std::cout << "[updateOutput] doTimeSamples=" << doTimeSamples_ << std::endl; + size_t itIdx(4); //index to the in-time digi - this could be configurable in a future version //check if in-time sample is above threshold and put result into the event if(doTimeSamples_) @@ -118,7 +116,6 @@ class HGCDigitizerBase { HGCSample singleSample; singleSample.set(rawDataFrame[itIdx].gain(),rawDataFrame[itIdx].adc()); singleRawDataFrame.setSample(0, singleSample); - std::cout << "Producing single time sample from itIdx=" << itIdx << " " << rawDataFrame[itIdx].adc() << " " << singleRawDataFrame[0].adc() << std::endl; if(singleRawDataFrame[0].adc() < adcThreshold_ ) return; coll->push_back(singleRawDataFrame); } From 3c8ebb413fc52672ed7964fcb208578c8dc41a61 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 24 Sep 2014 23:28:24 +0200 Subject: [PATCH 125/252] forgot to update the output for the trivial digitizer --- SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 97bb7689fd1e8..abf29c4906c32 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -65,7 +65,7 @@ class HGCDigitizerBase { it!=simData.end(); it++) { - + //create a new data frame D rawDataFrame( it->first ); @@ -91,6 +91,9 @@ class HGCDigitizerBase { //run the shaper runShaper(rawDataFrame); + + //update the output according to the final shape + updateOutput(coll,rawDataFrame); } } From 11c12658bca134419a047694ab166ff69bec5d93 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Thu, 25 Sep 2014 12:46:00 +0200 Subject: [PATCH 126/252] moving evaluation to top of the cell --- .../HGCalCommonData/src/HGCalDDDConstants.cc | 48 ++++++++++--------- 1 file changed, 26 insertions(+), 22 deletions(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 20e9c89b5107c..b8e1970f964cb 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -71,24 +71,29 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, float h, if (alpha < 0) {x0 -= 0.5*(tl+bl); phiSector = 0;} else if (alpha > 0) {x0 += 0.5*(tl+bl); phiSector = 1;} + //determine the i-y int ky = floor((y+h)/cellSize); + if( ky*cellSize> y+h) ky--; + if(ky<0) return std::pair(phiSector,-2); + if( (ky+1)*cellSize < (y+h) ) ky++; int max_ky_allowed=floor(2*h/cellSize); if(ky>max_ky_allowed-1) return std::pair(phiSector,-2); - //if((y+h)> (max_ky_allowed*cellSize)) return std::pair(phiSector,-2); - + //determine the i-x - //notice we substitute y by the bottom of the candidate cell + //notice we substitute y by the top of the candidate cell to reduce the dead zones int kx = floor(fabs(x0)/cellSize); - int max_kx_allowed=floor( (ky*cellSize+b)/(a*cellSize) ); + if( kx*cellSize > fabs(x0) ) kx--; + if(kx<0) return std::pair(phiSector,-2); + if( (kx+1)*cellSize < fabs(x0) ) kx++; + int max_kx_allowed=floor( ((ky+1)*cellSize+b)/(a*cellSize) ); if(kx>max_kx_allowed-1) return std::pair(phiSector,-2); - //if(fabs(x)>(max_kx_allowed*cellSize)) return std::pair(phiSector,-2); - + //count cells summing in rows until required height //notice the bottom of the cell must be used int icell(0); for (int iky=0; iky HGCalDDDConstants::findCell(int cell, float h, float bl, //parameterization of the boundary of the trapezoid float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); - int kx(cell), ky(0); int kymax( floor((2*h)/cellSize) ); int testCell(0); for (int iky=0; iky cell) break; testCell += cellsInRow; ky++; @@ -227,13 +231,13 @@ int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, float a = (alpha==0) ? (2*h/(tl-bl)) : (h/(tl-bl)); float b = 2*h*bl/(tl-bl); - + int ncells(0); - //always use the bottom of the cell... + //always use the top of the cell to maximize space int kymax = floor((2*h)/cellSize); for (int iky=0; iky HGCalDDDConstants::numberCells(float h, float bl, int kymax = floor((2*h)/cellSize); std::vector ncell; for (int iky=0; iky HGCalDDDConstants::simToReco(int cell, int lay, bool half) const { - + std::pair index = getIndex(lay, false); int i = index.first; if (i < 0) return std::pair(-1,-1); @@ -352,7 +356,7 @@ std::pair HGCalDDDConstants::simToReco(int cell, int lay, float bl = modules_[i].bl; float tl = modules_[i].tl; float cellSize = cellFactor_[i]*index.second; - + std::pair kxy = findCell(cell, h, bl, tl, modules_[i].alpha, index.second); int depth = layerGroup_[i]; int kx = kxy.first/cellFactor_[i]; @@ -361,8 +365,8 @@ std::pair HGCalDDDConstants::simToReco(int cell, int lay, float a = (half) ? (h/(tl-bl)) : (2*h/(tl-bl)); float b = 2*h*bl/(tl-bl); for (int iky=0; iky HGCalDDDConstants::simToReco(int cell, int lay, } void HGCalDDDConstants::initialize(const DDCompactView& cpv, std::string name){ - + nSectors = nCells = 0; - + std::string attribute = "Volume"; std::string value = name; DDValue val(attribute, value, 0); @@ -384,7 +388,7 @@ void HGCalDDDConstants::initialize(const DDCompactView& cpv, std::string name){ DDFilteredView fv(cpv); fv.addFilter(filter); bool ok = fv.firstChild(); - + if (ok) { //Load the SpecPars loadSpecPars(fv); From 324140dad192a7efe4508d0bc30c11d86a7beeca Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Thu, 4 Sep 2014 12:03:44 +0200 Subject: [PATCH 127/252] adding new version with timing --- .../interface/HGCDigitizerBase.h | 47 +++++----- .../HGCSimProducers/src/HGCDigitizer.cc | 48 +++++----- .../HGCSimProducers/src/HGCHEbackDigitizer.cc | 88 +++++++++---------- 3 files changed, 89 insertions(+), 94 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index f0567c817ed22..0a7a1c55d80a0 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -32,7 +32,6 @@ class HGCDigitizerBase { lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); adcThreshold_ = myCfg_.getParameter< uint32_t >("adcThreshold"); - doTimeSamples_ = myCfg_.getParameter< bool >("doTimeSamples"); } /** @@ -62,32 +61,31 @@ class HGCDigitizerBase { it!=simData.end(); it++) { - //convert total energy GeV->keV->ADC counts - double totalEn(0); - size_t maxSampleToInteg(doTimeSamples_ ? 1 : it->second.size()); - for(size_t i=0; isecond)[i]; - } - totalEn*=1e6; - - //add noise (in keV) - double noiseEn=simpleNoiseGen_->fire(); - totalEn += noiseEn; - if(totalEn<0) totalEn=0; - //round to integer (sample will saturate the value according to available bits) - uint16_t totalEnInt = floor( (totalEn/mipInKeV_) / lsbInMIP_ ); + //create a new data frame + D newDataFrame( it->first ); - //0 gain for the moment - HGCSample singleSample; - singleSample.set(0, totalEnInt ); + for(size_t i=0; isecond.size(); i++) + { - if(singleSample.adc()first ); - newDataFrame.setSample(0, singleSample); + //convert total energy GeV->keV->ADC counts + double totalEn=(it->second)[i]*1e6; + //add noise (in keV) + double noiseEn=simpleNoiseGen_->fire(); + totalEn += noiseEn; + if(totalEn<0) totalEn=0; + + //round to integer (sample will saturate the value according to available bits) + uint16_t totalEnInt = floor( (totalEn/mipInKeV_) / lsbInMIP_ ); + + //0 gain for the moment + HGCSample singleSample; + singleSample.set(0, totalEnInt); + + newDataFrame.setSample(i, singleSample); + } + //add to collection to produce coll->push_back(newDataFrame); } @@ -115,9 +113,6 @@ class HGCDigitizerBase { //minimum ADC counts to produce DIGIs uint32_t adcThreshold_; - //flag to apply or not time sampling (if false digitize the full energy from SimHit) - bool doTimeSamples_; - //a simple noise generator mutable CLHEP::RandGauss *simpleNoiseGen_; diff --git a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc index 7139d69ccd4a2..bd8e1ccf26000 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc @@ -132,24 +132,22 @@ void HGCDigitizer::accumulate(PileUpEventPrincipal const& e, edm::EventSetup con // void HGCDigitizer::accumulate(edm::Handle const &hits, int bxCrossing,const edm::ESHandle &geom) { + + if(!geom.isValid()) return; + const HGCalTopology &topo=geom->topology(); + const HGCalDDDConstants &dddConst=topo.dddConstants(); + for(edm::PCaloHitContainer::const_iterator hit_it = hits->begin(); hit_it != hits->end(); ++hit_it) { HGCalDetId simId( hit_it->id() ); - //gang SIM->RECO cells + //skip this hit if after ganging it is not valid int layer(simId.layer()), cell(simId.cell()); - float zPos(0.); - if(geom.isValid()) - { - const HGCalTopology &topo=geom->topology(); - const HGCalDDDConstants &dddConst=topo.dddConstants(); - zPos=dddConst.getFirstTrForm()->h3v.z(); - std::pair recoLayerCell=dddConst.simToReco(cell,layer,topo.detectorType()); - cell = recoLayerCell.first; - layer = recoLayerCell.second; - if(layer<0) continue; - } - + std::pair recoLayerCell=dddConst.simToReco(cell,layer,topo.detectorType()); + cell = recoLayerCell.first; + layer = recoLayerCell.second; + if(layer<0 || cell<0) continue; + //assign the RECO DetId DetId id( producesEEDigis() ? (uint32_t)HGCEEDetId(mySubDet_,simId.zside(),layer,simId.sector(),simId.subsector(),cell): @@ -161,12 +159,16 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i else std::cout << "HGCDigitizer: i/p " << simId << " o/p " << HGCHEDetId(id) << std::endl; } - //hit time: [time()]=ns [zPos]=cm [CLHEP::c_light]=mm/ns - //for now accumulate in buckets of bxTime_ - int itime=floor( (hit_it->time()-zPos/(0.1*CLHEP::c_light))/bxTime_); - itime += bxCrossing; - if(itime<0) continue; - + + //distance to the center of the detector + float dist2center( geom->getPosition(id).mag() ); + + //hit time: [time()]=ns [centerDist]=cm [CLHEP::c_light]=mm/ns + //for now accumulate in buckets of 5ns and save 3 pre-samples+5 in-time samples+1 post-sample + int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/5 ) + 1; + itime += bxCrossing*bxTime_; + if(itime<-3 || itime>6) continue; + //energy deposited HGCSimEn_t ien( hit_it->energy() ); @@ -180,10 +182,10 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i simHitIt=simHitAccumulator_->find(id); } - //check if time is ok - if( itime >= (int)(simHitIt->second.size()) ) continue; - - (simHitIt->second)[itime] += ien; + //check if time index is ok and store energy + int itimeIdx(itime+3); + if( itimeIdx<0 || itimeIdx >= (int)simHitIt->second.size() ) continue; + (simHitIt->second)[itimeIdx] += ien; } //add base data for noise simulation diff --git a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc index 4b99518d14444..db112fc4b1d73 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc @@ -43,53 +43,51 @@ void HGCHEbackDigitizer::runCaliceLikeDigitizer(std::auto_ptrkeV->ADC counts - double totalEn(0); - size_t maxSampleToInteg(doTimeSamples_ ? 1 : it->second.size()); - for(size_t i=0; isecond)[i]; - totalEn*=1e6; + //init a new data frame + HGCHEDataFrame newDataFrame( it->first ); - //convert energy to MIP - double totalMIPs = totalEn/mipInKeV_; - - //generate random number of photon electrons - float npe = peGen_->fire(totalMIPs*nPEperMIP_); - - //number of pixels - float x=exp(-npe/nTotalPE_); - float nPixel(0); - if(xTalk_*x!=1) nPixel=std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); - - //update signal - nPixel=std::max( float(sigGen_->fire(nPixel,sdPixels_)), float(0.) ); - - //convert to MIP again - if(nTotalPE_!=nPixel && (nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)>0 ) - totalMIPs = (nTotalPE_/nPEperMIP_)*log((nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)); - else - totalMIPs = 0; - - //add noise (in MIPs) - double noiseMIPs=simpleNoiseGen_->fire(0.,1./mip2noise_); - totalMIPs=std::max(float(totalMIPs+noiseMIPs),float(0.)); - - //round to integer (sample will saturate the value according to available bits) - uint16_t totalEnInt = floor( totalMIPs / lsbInMIP_ ); - - //0 gain for the moment - HGCSample singleSample; - singleSample.set(0, totalEnInt ); - - if(singleSample.adc()first ); - newDataFrame.setSample(0, singleSample); - - //add to collection to produce - digiColl->push_back(newDataFrame); - } + for(size_t i=0; isecond.size(); i++) + { + //convert total energy GeV->keV->ADC counts + float totalEn( (it->second)[i]*1e6 ); + + //convert energy to MIP + float totalMIPs = totalEn/mipInKeV_; + + //generate random number of photon electrons + float npe = peGen_->fire(totalMIPs*nPEperMIP_); + + //number of pixels + float x=(int)exp(-npe/nTotalPE_); + float nPixel(0); + if(xTalk_*x!=1) nPixel=std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); + + //update signal + nPixel=std::max( float(sigGen_->fire(nPixel,sdPixels_)), float(0.) ); + + //convert to MIP again + if(nTotalPE_!=nPixel && (nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)>0 ) + totalMIPs = (nTotalPE_/nPEperMIP_)*log((nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)); + else + totalMIPs = 0; + + //add noise (in MIPs) + double noiseMIPs=simpleNoiseGen_->fire(0.,1./mip2noise_); + totalMIPs=std::max(float(totalMIPs+noiseMIPs),float(0.)); + + //round to integer (sample will saturate the value according to available bits) + uint16_t totalEnInt = floor( totalMIPs / lsbInMIP_ ); + + //0 gain for the moment + HGCSample singleSample; + singleSample.set(0, totalEnInt ); + newDataFrame.setSample(i, singleSample); + } + + //add to collection to produce + digiColl->push_back(newDataFrame); + } } // From b8cf534daed3d239525490d05dee35c2a7c347cd Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Thu, 4 Sep 2014 16:42:56 +0200 Subject: [PATCH 128/252] moving to 3x25ns time frames, accumulating sim hits in 3x25ns time frames, defining 3 samples dataframes --- DataFormats/HGCDigi/interface/HGCDataFrame.h | 4 ++-- .../HGCSimProducers/interface/HGCDigitizerBase.h | 2 +- SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc | 13 ++++++------- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/DataFormats/HGCDigi/interface/HGCDataFrame.h b/DataFormats/HGCDigi/interface/HGCDataFrame.h index 7d027a3b9b23f..eaa92af068607 100644 --- a/DataFormats/HGCDigi/interface/HGCDataFrame.h +++ b/DataFormats/HGCDigi/interface/HGCDataFrame.h @@ -21,8 +21,8 @@ class HGCDataFrame { /** @short CTOR */ - HGCDataFrame() : id_(0), maxSampleSize_(1) { data_.resize(maxSampleSize_); } - explicit HGCDataFrame(const D& id) : id_(id), maxSampleSize_(1) { data_.resize(maxSampleSize_); } + HGCDataFrame() : id_(0), maxSampleSize_(3) { data_.resize(maxSampleSize_); } + explicit HGCDataFrame(const D& id) : id_(id), maxSampleSize_(3) { data_.resize(maxSampleSize_); } /** diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 0a7a1c55d80a0..78adcfa12e3fe 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -13,7 +13,7 @@ #include "CLHEP/Random/RandGauss.h" typedef float HGCSimEn_t; -typedef std::array HGCSimHitData; +typedef std::array HGCSimHitData; typedef std::unordered_map HGCSimHitDataAccumulator; template diff --git a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc index bd8e1ccf26000..c07d0d98fc3c4 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc @@ -164,11 +164,11 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i float dist2center( geom->getPosition(id).mag() ); //hit time: [time()]=ns [centerDist]=cm [CLHEP::c_light]=mm/ns - //for now accumulate in buckets of 5ns and save 3 pre-samples+5 in-time samples+1 post-sample - int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/5 ) + 1; + //for now accumulate in 3 buckets of 25ns + int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/bxTime_ ) + 1; itime += bxCrossing*bxTime_; - if(itime<-3 || itime>6) continue; - + if(itime<0) continue; + //energy deposited HGCSimEn_t ien( hit_it->energy() ); @@ -183,9 +183,8 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i } //check if time index is ok and store energy - int itimeIdx(itime+3); - if( itimeIdx<0 || itimeIdx >= (int)simHitIt->second.size() ) continue; - (simHitIt->second)[itimeIdx] += ien; + if(itime >= (int)simHitIt->second.size() ) continue; + (simHitIt->second)[itime] += ien; } //add base data for noise simulation From 64d30b96cd0148035ae8d33e7c12d9660c255791 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Tue, 9 Sep 2014 09:08:12 +0200 Subject: [PATCH 129/252] updating digitizer --- .../HGCSimProducers/interface/HGCDigitizer.h | 5 +++ .../interface/HGCDigitizerBase.h | 33 +++++++++++++++++++ .../HGCSimProducers/src/HGCDigitizer.cc | 14 ++++---- .../MixingModule/python/hgcalDigitizer_cfi.py | 11 +++++-- 4 files changed, 55 insertions(+), 8 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h index 392ecd01479e7..ce6b5adca9248 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h @@ -83,6 +83,11 @@ private : //misc switches bool useAllChannels_; int verbosity_; + + //reference speed to evaluate time of arrival + //at the sensititive detector + //assuming the center of CMS + float refSpeed_; }; #endif diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 78adcfa12e3fe..6527b1a790f83 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -32,6 +32,9 @@ class HGCDigitizerBase { lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); adcThreshold_ = myCfg_.getParameter< uint32_t >("adcThreshold"); + shaperN_ = myCfg_.getParameter< double >("shaperN"); + shaperTau_ = myCfg_.getParameter< double >("shaperTau"); + bxTime_ = ps.getParameter("bxTime"); } /** @@ -86,11 +89,35 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } + runShaper(newDataFrame); + //add to collection to produce coll->push_back(newDataFrame); } } + /** + @short applies a shape to each time sample and propagates the tails to the subsequent time samples + */ + void runShaper(D &dataFrame) + { + std::vector adcToCarry(dataFrame.size()); + for(int it=0; it("hitCollection"); @@ -163,11 +164,12 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i //distance to the center of the detector float dist2center( geom->getPosition(id).mag() ); - //hit time: [time()]=ns [centerDist]=cm [CLHEP::c_light]=mm/ns - //for now accumulate in 3 buckets of 25ns - int itime=floor( (hit_it->time()-dist2center/(0.1*CLHEP::c_light))/bxTime_ ) + 1; - itime += bxCrossing*bxTime_; - if(itime<0) continue; + //hit time: [time()]=ns [centerDist]=cm [refSpeed_]=cm/ns + //accumulate in 6 buckets of 25ns (4 pre-samples, 1 in-time, 1 post-sample) + int itime=floor( (hit_it->time()-dist2center/refSpeed_)/bxTime_ ) ; + itime += bxCrossing; + itime += 4; + if(itime<0 || itime>5) continue; //energy deposited HGCSimEn_t ien( hit_it->energy() ); diff --git a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py index 0f14120e228b8..7b16cee5f5db2 100644 --- a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py +++ b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py @@ -16,7 +16,9 @@ lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True) + doTimeSamples = cms.bool(True), + shaperN = cms.double(1.), + shaperTau = cms.double(20.) ) ) @@ -34,7 +36,10 @@ lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True) ) + doTimeSamples = cms.bool(True), + shaperN = cms.double(1.), + shaperTau = cms.double(20.) + ) ) @@ -53,6 +58,8 @@ mip2noise = cms.double(5.0), adcThreshold = cms.uint32(4), doTimeSamples = cms.bool(True), + shaperN = cms.double(1.), + shaperTau = cms.double(20.), caliceSpecific = cms.PSet( nPEperMIP = cms.double(11.0), nTotalPE = cms.double(1156), xTalk = cms.double(0.25), From b85e8c86146a95034e8276dfaf35420db7a3068d Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Tue, 9 Sep 2014 09:54:01 +0200 Subject: [PATCH 130/252] fixing time assignment, re-adding ADC thresholds, increasing time samples to 6 --- DataFormats/HGCDigi/interface/HGCDataFrame.h | 11 ++++----- .../interface/HGCDigitizerBase.h | 24 ++++++++++++------- .../HGCSimProducers/src/HGCHEbackDigitizer.cc | 6 +++++ 3 files changed, 26 insertions(+), 15 deletions(-) diff --git a/DataFormats/HGCDigi/interface/HGCDataFrame.h b/DataFormats/HGCDigi/interface/HGCDataFrame.h index eaa92af068607..d5107a0f7a9cf 100644 --- a/DataFormats/HGCDigi/interface/HGCDataFrame.h +++ b/DataFormats/HGCDigi/interface/HGCDataFrame.h @@ -21,17 +21,16 @@ class HGCDataFrame { /** @short CTOR */ - HGCDataFrame() : id_(0), maxSampleSize_(3) { data_.resize(maxSampleSize_); } - explicit HGCDataFrame(const D& id) : id_(id), maxSampleSize_(3) { data_.resize(maxSampleSize_); } - + HGCDataFrame() : id_(0), maxSampleSize_(6) { data_.resize(maxSampleSize_); } + explicit HGCDataFrame(const D& id) : id_(id), maxSampleSize_(6) { data_.resize(maxSampleSize_); } /** - @short det id + @short det id */ const D& id() const { return id_; } - + /** - @short total number of samples in the digi + @short total number of samples in the digi */ int size() const { return data_.size() & 0xf; } diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 6527b1a790f83..047f5d35150f5 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -13,7 +13,7 @@ #include "CLHEP/Random/RandGauss.h" typedef float HGCSimEn_t; -typedef std::array HGCSimHitData; +typedef std::array HGCSimHitData; typedef std::unordered_map HGCSimHitDataAccumulator; template @@ -88,9 +88,13 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } - + + //run the shaper runShaper(newDataFrame); + //check if 5th time sample is above threshold + if( newDataFrame[4].adc() < adcThreshold_ ) continue; + //add to collection to produce coll->push_back(newDataFrame); } @@ -106,14 +110,16 @@ class HGCDigitizerBase { { HGCSample sample=dataFrame[it]; - adcToCarry[it] += sample.adc(); uint16_t newADC=sample.adc(); - for(int jt=0; jt0){ + adcToCarry[it] = sample.adc(); + for(int jt=0; jtpush_back(newDataFrame); } From af3334085aa4402878d013b8e6e4f2deaa0defad Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Tue, 9 Sep 2014 12:13:35 +0200 Subject: [PATCH 131/252] fixing ootpu propagation --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 7 +++---- SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 047f5d35150f5..d4a2ac833ed64 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -105,18 +105,17 @@ class HGCDigitizerBase { */ void runShaper(D &dataFrame) { - std::vector adcToCarry(dataFrame.size()); for(int it=0; it0){ - adcToCarry[it] = sample.adc(); for(int jt=0; jt Date: Wed, 10 Sep 2014 14:22:51 +0200 Subject: [PATCH 132/252] fixing shape in the code --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index d4a2ac833ed64..f0d5de06a5cbf 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -108,14 +108,18 @@ class HGCDigitizerBase { for(int it=0; it0){ for(int jt=0; jt "; if(shaperN_*shaperTau_>0){ for(int jt=0; jtsecond)[i]*1e6 ); //convert energy to MIP - float totalMIPs = totalEn/mipInKeV_; + float totalIniMIPs = totalEn/mipInKeV_; //generate random number of photon electrons - float npe = peGen_->fire(totalMIPs*nPEperMIP_); + uint32_t npe = (uint32_t)peGen_->fire(totalIniMIPs*nPEperMIP_); //number of pixels - float x=(int)exp(-npe/nTotalPE_); - float nPixel(0); - if(xTalk_*x!=1) nPixel=std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); + float x=exp(-(float)(npe)/(float)(nTotalPE_)); + uint32_t nPixel(0); + if(xTalk_*x!=1) nPixel=(uint32_t) std::max( float(nTotalPE_*(1-x)/(1-xTalk_*x)), float(0.) ); //update signal - nPixel=std::max( float(sigGen_->fire(nPixel,sdPixels_)), float(0.) ); + nPixel=(uint32_t)std::max( float(sigGen_->fire((float)nPixel,(float)sdPixels_)), float(0.) ); - //convert to MIP again + //convert to MIP again and saturate + float totalMIPs(totalIniMIPs); if(nTotalPE_!=nPixel && (nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)>0 ) totalMIPs = (nTotalPE_/nPEperMIP_)*log((nTotalPE_-xTalk_*nPixel)/(nTotalPE_-nPixel)); else @@ -77,7 +78,7 @@ void HGCHEbackDigitizer::runCaliceLikeDigitizer(std::auto_ptr Date: Mon, 15 Sep 2014 16:39:46 +0200 Subject: [PATCH 134/252] fixing shaper --- .../interface/HGCDigitizerBase.h | 22 +++++++++++++------ 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index d18123380fbf2..d3d0a5b1336d2 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -89,8 +89,13 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } + //bool doDebug(newDataFrame[4].adc()>4); + //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << " -> "; + //run the shaper - runShaper(newDataFrame); + newDataFrame=runShaper(newDataFrame); + + //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << std::endl; //check if 5th time sample is above threshold if( newDataFrame[4].adc() < adcThreshold_ ) continue; @@ -103,14 +108,15 @@ class HGCDigitizerBase { /** @short applies a shape to each time sample and propagates the tails to the subsequent time samples */ - void runShaper(D &dataFrame) + D runShaper(D &dataFrame) { + D newDataFrame; + //bool doDebug(dataFrame[4].adc()>adcThreshold_); for(int it=0; it "; if(shaperN_*shaperTau_>0){ for(int jt=0; jt Date: Mon, 15 Sep 2014 17:16:44 +0200 Subject: [PATCH 135/252] fixing initialization ug --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index d3d0a5b1336d2..61de8cbf229ad 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -88,7 +88,7 @@ class HGCDigitizerBase { newDataFrame.setSample(i, singleSample); } - + //bool doDebug(newDataFrame[4].adc()>4); //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << " -> "; @@ -99,6 +99,8 @@ class HGCDigitizerBase { //check if 5th time sample is above threshold if( newDataFrame[4].adc() < adcThreshold_ ) continue; + + //if(doDebug) std::cout << "Accept" << std::endl; //add to collection to produce coll->push_back(newDataFrame); @@ -110,14 +112,17 @@ class HGCDigitizerBase { */ D runShaper(D &dataFrame) { - D newDataFrame; + D newDataFrame(dataFrame.id()); //bool doDebug(dataFrame[4].adc()>adcThreshold_); + for(int it=0; it "; + if(shaperN_*shaperTau_>0){ for(int jt=0; jt Date: Mon, 15 Sep 2014 21:28:57 +0200 Subject: [PATCH 136/252] fixing tof delay... --- .../HGCSimProducers/interface/HGCDigitizer.h | 7 ++- .../interface/HGCDigitizerBase.h | 55 +++++++++---------- .../HGCSimProducers/src/HGCDigitizer.cc | 12 ++-- .../MixingModule/python/hgcalDigitizer_cfi.py | 3 + 4 files changed, 42 insertions(+), 35 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h index ce6b5adca9248..90d924efcd9e7 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizer.h @@ -84,10 +84,11 @@ private : bool useAllChannels_; int verbosity_; - //reference speed to evaluate time of arrival - //at the sensititive detector - //assuming the center of CMS + //reference speed to evaluate time of arrival at the sensititive detector, assuming the center of CMS float refSpeed_; + + //delay to apply after evaluating time of arrival at the sensitive detector + float tofDelay_; }; #endif diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 61de8cbf229ad..df3f3d81880e9 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -66,11 +66,10 @@ class HGCDigitizerBase { { //create a new data frame - D newDataFrame( it->first ); + D rawDataFrame( it->first ); for(size_t i=0; isecond.size(); i++) { - //convert total energy GeV->keV->ADC counts double totalEn=(it->second)[i]*1e6; @@ -86,59 +85,59 @@ class HGCDigitizerBase { HGCSample singleSample; singleSample.set(0, totalEnInt); - newDataFrame.setSample(i, singleSample); + rawDataFrame.setSample(i, singleSample); } - //bool doDebug(newDataFrame[4].adc()>4); - //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << " -> "; + /* bool doDebug(rawDataFrame[3].adc()>2); */ + /* if(doDebug) */ + /* { */ + /* for(size_t iti=0;iti<6; iti++) */ + /* std::cout << rawDataFrame[iti].adc() << "(" << (it->second)[iti]*1e6 << ") ,"; */ + /* std::cout << "->"; */ + /* } */ //run the shaper - newDataFrame=runShaper(newDataFrame); - - //if(doDebug) std::cout << newDataFrame[4].adc() << "," << newDataFrame[5].adc() << std::endl; - + runShaper(rawDataFrame); + + /* if(doDebug) */ + /* { */ + /* for(size_t iti=0;iti<6; iti++) */ + /* std::cout << rawDataFrame[iti].adc() << ","; */ + /* std::cout << std::endl; */ + /* } */ + //check if 5th time sample is above threshold - if( newDataFrame[4].adc() < adcThreshold_ ) continue; + if( rawDataFrame[4].adc() < adcThreshold_ ) continue; - //if(doDebug) std::cout << "Accept" << std::endl; - //add to collection to produce - coll->push_back(newDataFrame); + coll->push_back(rawDataFrame); } } /** @short applies a shape to each time sample and propagates the tails to the subsequent time samples */ - D runShaper(D &dataFrame) + void runShaper(D &dataFrame) { - D newDataFrame(dataFrame.id()); - - //bool doDebug(dataFrame[4].adc()>adcThreshold_); - + std::vector oldADC(dataFrame.size()); for(int it=0; it "; + oldADC[it]=dataFrame[it].adc(); + uint16_t newADC(oldADC[it]); if(shaperN_*shaperTau_>0){ for(int jt=0; jt("hitCollection"); @@ -29,7 +29,8 @@ HGCDigitizer::HGCDigitizer(const edm::ParameterSet& ps) : digitizationType_ = ps.getParameter< uint32_t >("digitizationType"); useAllChannels_ = ps.getParameter< bool >("useAllChannels"); verbosity_ = ps.getUntrackedParameter< int32_t >("verbosity",0); - + tofDelay_ = ps.getParameter< double >("tofDelay"); + //get the random number generator edm::Service rng; if ( ! rng.isAvailable()) { @@ -164,11 +165,14 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i //distance to the center of the detector float dist2center( geom->getPosition(id).mag() ); - //hit time: [time()]=ns [centerDist]=cm [refSpeed_]=cm/ns + //hit time: [time()]=ns [centerDist]=cm [refSpeed_]=cm/ns + delay by 1ns //accumulate in 6 buckets of 25ns (4 pre-samples, 1 in-time, 1 post-sample) - int itime=floor( (hit_it->time()-dist2center/refSpeed_)/bxTime_ ) ; + float tof(hit_it->time()-dist2center/refSpeed_+tofDelay_); + int itime=floor( tof/bxTime_ ) ; + itime += bxCrossing; itime += 4; + if(itime<0 || itime>5) continue; //energy deposited diff --git a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py index 7b16cee5f5db2..cd04acc907814 100644 --- a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py +++ b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py @@ -8,6 +8,7 @@ digiCollection = cms.string("HGCDigisEE"), maxSimHitsAccTime = cms.uint32(100), bxTime = cms.int32(25), + tofDelay = cms.double(1), digitizationType = cms.uint32(0), makeDigiSimLinks = cms.bool(False), useAllChannels = cms.bool(True), @@ -28,6 +29,7 @@ digiCollection = cms.string("HGCDigisHEfront"), maxSimHitsAccTime = cms.uint32(100), bxTime = cms.int32(25), + tofDelay = cms.double(1), digitizationType = cms.uint32(0), makeDigiSimLinks = cms.bool(False), useAllChannels = cms.bool(True), @@ -49,6 +51,7 @@ digiCollection = cms.string("HGCDigisHEback"), maxSimHitsAccTime = cms.uint32(100), bxTime = cms.int32(25), + tofDelay = cms.double(1), digitizationType = cms.uint32(1), makeDigiSimLinks = cms.bool(False), useAllChannels = cms.bool(True), From 2b8a5d1f50b1febbf90d639773fddd69c611a4a0 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Mon, 15 Sep 2014 22:57:46 +0200 Subject: [PATCH 137/252] removing bx time subtraction - mix module takes care of it --- SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc index 52f716563eb21..1b1edde3bdc4e 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCDigitizer.cc @@ -134,7 +134,6 @@ void HGCDigitizer::accumulate(PileUpEventPrincipal const& e, edm::EventSetup con // void HGCDigitizer::accumulate(edm::Handle const &hits, int bxCrossing,const edm::ESHandle &geom) { - if(!geom.isValid()) return; const HGCalTopology &topo=geom->topology(); const HGCalDDDConstants &dddConst=topo.dddConstants(); @@ -170,9 +169,10 @@ void HGCDigitizer::accumulate(edm::Handle const &hits, i float tof(hit_it->time()-dist2center/refSpeed_+tofDelay_); int itime=floor( tof/bxTime_ ) ; - itime += bxCrossing; + //no need to add bx crossing - tof comes already corrected from the mixing module + //itime += bxCrossing; itime += 4; - + if(itime<0 || itime>5) continue; //energy deposited From dce57f029ad2cbec2ad5dd4c37f628b2683a2f28 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 24 Sep 2014 21:38:38 +0200 Subject: [PATCH 138/252] updating dataframe with a resize method, fixing production of single samples using the doTimeSamples parameter which was unused so far --- DataFormats/HGCDigi/interface/HGCDataFrame.h | 5 ++ .../interface/HGCDigitizerBase.h | 53 ++++++++++++------- .../HGCSimProducers/src/HGCHEbackDigitizer.cc | 7 +-- .../MixingModule/python/hgcalDigitizer_cfi.py | 12 ++--- 4 files changed, 46 insertions(+), 31 deletions(-) diff --git a/DataFormats/HGCDigi/interface/HGCDataFrame.h b/DataFormats/HGCDigi/interface/HGCDataFrame.h index d5107a0f7a9cf..1af5ddf93bd1e 100644 --- a/DataFormats/HGCDigi/interface/HGCDataFrame.h +++ b/DataFormats/HGCDigi/interface/HGCDataFrame.h @@ -34,6 +34,11 @@ class HGCDataFrame { */ int size() const { return data_.size() & 0xf; } + /** + @short allow to set size + */ + void resize(size_t s) { data_.resize(s); } + /** @short assess/set specific samples */ diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index df3f3d81880e9..91b42ae41afd1 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -28,6 +28,7 @@ class HGCDigitizerBase { HGCDigitizerBase(const edm::ParameterSet &ps) : simpleNoiseGen_(0) { myCfg_ = ps.getParameter("digiCfg"); + doTimeSamples_ = ps.getParameter< bool >("doTimeSamples"); mipInKeV_ = myCfg_.getParameter("mipInKeV"); lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); @@ -88,30 +89,39 @@ class HGCDigitizerBase { rawDataFrame.setSample(i, singleSample); } - /* bool doDebug(rawDataFrame[3].adc()>2); */ - /* if(doDebug) */ - /* { */ - /* for(size_t iti=0;iti<6; iti++) */ - /* std::cout << rawDataFrame[iti].adc() << "(" << (it->second)[iti]*1e6 << ") ,"; */ - /* std::cout << "->"; */ - /* } */ - //run the shaper runShaper(rawDataFrame); + } + } - /* if(doDebug) */ - /* { */ - /* for(size_t iti=0;iti<6; iti++) */ - /* std::cout << rawDataFrame[iti].adc() << ","; */ - /* std::cout << std::endl; */ - /* } */ - - //check if 5th time sample is above threshold - if( rawDataFrame[4].adc() < adcThreshold_ ) continue; - - //add to collection to produce + /** + @short prepares the output according to the number of time samples to produce + */ + void updateOutput(std::auto_ptr &coll,D rawDataFrame) + { + size_t itIdx(4); //index to the in-time digi + + std::cout << "[updateOutput] doTimeSamples=" << doTimeSamples_ << std::endl; + + //check if in-time sample is above threshold and put result into the event + if(doTimeSamples_) + { + if(rawDataFrame[itIdx].adc() < adcThreshold_ ) return; coll->push_back(rawDataFrame); } + else + { + //create a new data frame containing only the in-time digi + D singleRawDataFrame( rawDataFrame.id() ); + singleRawDataFrame.resize(1); + + HGCSample singleSample; + singleSample.set(rawDataFrame[itIdx].gain(),rawDataFrame[itIdx].adc()); + singleRawDataFrame.setSample(0, singleSample); + std::cout << "Producing single time sample from itIdx=" << itIdx << " " << rawDataFrame[itIdx].adc() << " " << singleRawDataFrame[0].adc() << std::endl; + if(singleRawDataFrame[0].adc() < adcThreshold_ ) return; + coll->push_back(singleRawDataFrame); + } } /** @@ -133,7 +143,7 @@ class HGCDigitizerBase { newADC += uint16_t(oldADC[jt]*pow(relTime/(shaperN_*shaperTau_),shaperN_)*exp(-(relTime-shaperN_*shaperTau_)/shaperTau_)); } } - + HGCSample newSample; newSample.set(gain,newADC); dataFrame.setSample(it,newSample); @@ -174,6 +184,9 @@ class HGCDigitizerBase { //bunch time int bxTime_; + + //if true will put both in time and out-of-time samples in the event + bool doTimeSamples_; private: diff --git a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc index 6f63d72a6ba32..6db693adc1e5f 100644 --- a/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc +++ b/SimCalorimetry/HGCSimProducers/src/HGCHEbackDigitizer.cc @@ -88,12 +88,9 @@ void HGCHEbackDigitizer::runCaliceLikeDigitizer(std::auto_ptrpush_back(newDataFrame); + //prepare the output + updateOutput(digiColl,newDataFrame); } } diff --git a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py index cd04acc907814..0c79b3c86a841 100644 --- a/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py +++ b/SimGeneral/MixingModule/python/hgcalDigitizer_cfi.py @@ -17,9 +17,9 @@ lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True), + doTimeSamples = cms.bool(False), shaperN = cms.double(1.), - shaperTau = cms.double(20.) + shaperTau = cms.double(0.) ) ) @@ -38,9 +38,9 @@ lsbInMIP = cms.double(0.25), mip2noise = cms.double(7.0), adcThreshold = cms.uint32(2), - doTimeSamples = cms.bool(True), + doTimeSamples = cms.bool(False), shaperN = cms.double(1.), - shaperTau = cms.double(20.) + shaperTau = cms.double(0.) ) ) @@ -60,9 +60,9 @@ lsbInMIP = cms.double(0.25), mip2noise = cms.double(5.0), adcThreshold = cms.uint32(4), - doTimeSamples = cms.bool(True), + doTimeSamples = cms.bool(False), shaperN = cms.double(1.), - shaperTau = cms.double(20.), + shaperTau = cms.double(0.), caliceSpecific = cms.PSet( nPEperMIP = cms.double(11.0), nTotalPE = cms.double(1156), xTalk = cms.double(0.25), From a7401c1b8cb5080a1c58a2be5851353851e7df8a Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 24 Sep 2014 21:50:00 +0200 Subject: [PATCH 139/252] default set without pulse shape and only 1 time sample --- .../HGCSimProducers/interface/HGCDigitizerBase.h | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 91b42ae41afd1..97bb7689fd1e8 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -28,14 +28,14 @@ class HGCDigitizerBase { HGCDigitizerBase(const edm::ParameterSet &ps) : simpleNoiseGen_(0) { myCfg_ = ps.getParameter("digiCfg"); - doTimeSamples_ = ps.getParameter< bool >("doTimeSamples"); + bxTime_ = ps.getParameter("bxTime"); + doTimeSamples_ = myCfg_.getParameter< bool >("doTimeSamples"); mipInKeV_ = myCfg_.getParameter("mipInKeV"); lsbInMIP_ = myCfg_.getParameter("lsbInMIP"); mip2noise_ = myCfg_.getParameter("mip2noise"); adcThreshold_ = myCfg_.getParameter< uint32_t >("adcThreshold"); shaperN_ = myCfg_.getParameter< double >("shaperN"); shaperTau_ = myCfg_.getParameter< double >("shaperTau"); - bxTime_ = ps.getParameter("bxTime"); } /** @@ -99,9 +99,7 @@ class HGCDigitizerBase { */ void updateOutput(std::auto_ptr &coll,D rawDataFrame) { - size_t itIdx(4); //index to the in-time digi - - std::cout << "[updateOutput] doTimeSamples=" << doTimeSamples_ << std::endl; + size_t itIdx(4); //index to the in-time digi - this could be configurable in a future version //check if in-time sample is above threshold and put result into the event if(doTimeSamples_) @@ -118,7 +116,6 @@ class HGCDigitizerBase { HGCSample singleSample; singleSample.set(rawDataFrame[itIdx].gain(),rawDataFrame[itIdx].adc()); singleRawDataFrame.setSample(0, singleSample); - std::cout << "Producing single time sample from itIdx=" << itIdx << " " << rawDataFrame[itIdx].adc() << " " << singleRawDataFrame[0].adc() << std::endl; if(singleRawDataFrame[0].adc() < adcThreshold_ ) return; coll->push_back(singleRawDataFrame); } From 3671360155dec166ad084d07e4f3cb26e24a400a Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Wed, 24 Sep 2014 23:28:24 +0200 Subject: [PATCH 140/252] forgot to update the output for the trivial digitizer --- SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h index 97bb7689fd1e8..abf29c4906c32 100644 --- a/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h +++ b/SimCalorimetry/HGCSimProducers/interface/HGCDigitizerBase.h @@ -65,7 +65,7 @@ class HGCDigitizerBase { it!=simData.end(); it++) { - + //create a new data frame D rawDataFrame( it->first ); @@ -91,6 +91,9 @@ class HGCDigitizerBase { //run the shaper runShaper(rawDataFrame); + + //update the output according to the final shape + updateOutput(coll,rawDataFrame); } } From 25d3a04d7ae70ada1679bf32df9a1e58076827b2 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Fri, 26 Sep 2014 11:08:01 +0200 Subject: [PATCH 141/252] adding further protections for unexisting cells, making some arguments const --- Geometry/FCalGeometry/src/HGCalGeometry.cc | 9 ++++--- .../interface/HGCalDDDConstants.h | 2 +- .../HGCalCommonData/src/HGCalDDDConstants.cc | 26 ++++++++++--------- SimG4CMS/Calo/interface/HGCNumberingScheme.h | 2 +- SimG4CMS/Calo/src/HGCNumberingScheme.cc | 2 +- 5 files changed, 23 insertions(+), 18 deletions(-) diff --git a/Geometry/FCalGeometry/src/HGCalGeometry.cc b/Geometry/FCalGeometry/src/HGCalGeometry.cc index c0b2e14719c6f..7f301a19bc42a 100644 --- a/Geometry/FCalGeometry/src/HGCalGeometry.cc +++ b/Geometry/FCalGeometry/src/HGCalGeometry.cc @@ -148,10 +148,13 @@ DetId HGCalGeometry::getClosestCell( const GlobalPoint& r ) const { << ":" << id_.iLay << ":" << id_.iSec << ":" << id_.iSubSec << ":" << id_.iCell << " Cell " << m_cellVec[cellIndex]; #endif - return topology().encode(id_); - } else { - return DetId(); + + //check if returned cell is valid + if(id_.iCell>=0) return topology().encode(id_); } + + //if not valid or out of bounds return a null DetId + return DetId(); } HGCalGeometry::DetIdSet HGCalGeometry::getCells( const GlobalPoint& r, double dR ) const { diff --git a/Geometry/HGCalCommonData/interface/HGCalDDDConstants.h b/Geometry/HGCalCommonData/interface/HGCalDDDConstants.h index e2757645640b8..f8935e01e574b 100644 --- a/Geometry/HGCalCommonData/interface/HGCalDDDConstants.h +++ b/Geometry/HGCalCommonData/interface/HGCalDDDConstants.h @@ -77,7 +77,7 @@ class HGCalDDDConstants { private: void initialize(const DDCompactView& cpv, std::string name); - void loadGeometry(const DDFilteredView& fv, std::string& tag); + void loadGeometry(const DDFilteredView& fv, const std::string& tag); void loadSpecPars(const DDFilteredView& fv); std::vector getDDDArray(const std::string &, const DDsvalues_type &, int &) const; diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index b8e1970f964cb..36f3afe6ae244 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -14,6 +14,7 @@ //#define DebugLog const double k_ScaleFromDDD = 0.1; +const double k_horizontalShift = 1.0; HGCalDDDConstants::HGCalDDDConstants(const DDCompactView& cpv, std::string& nam) { @@ -75,25 +76,25 @@ std::pair HGCalDDDConstants::assignCell(float x, float y, float h, //determine the i-y int ky = floor((y+h)/cellSize); if( ky*cellSize> y+h) ky--; - if(ky<0) return std::pair(phiSector,-2); + if(ky<0) return std::pair(-1,-1); if( (ky+1)*cellSize < (y+h) ) ky++; int max_ky_allowed=floor(2*h/cellSize); - if(ky>max_ky_allowed-1) return std::pair(phiSector,-2); + if(ky>max_ky_allowed-1) return std::pair(-1,-1); //determine the i-x //notice we substitute y by the top of the candidate cell to reduce the dead zones int kx = floor(fabs(x0)/cellSize); if( kx*cellSize > fabs(x0) ) kx--; - if(kx<0) return std::pair(phiSector,-2); + if(kx<0) return std::pair(-1,-1); if( (kx+1)*cellSize < fabs(x0) ) kx++; - int max_kx_allowed=floor( ((ky+1)*cellSize+b)/(a*cellSize) ); - if(kx>max_kx_allowed-1) return std::pair(phiSector,-2); + int max_kx_allowed=floor( ((ky+1)*cellSize+b+k_horizontalShift*cellSize)/(a*cellSize) ); + if(kx>max_kx_allowed-1) return std::pair(-1,-1); //count cells summing in rows until required height //notice the bottom of the cell must be used int icell(0); for (int iky=0; iky HGCalDDDConstants::findCell(int cell, float h, float bl, //check if adding all the cells in this row is above the required cell //notice the top of the cell is used to maximize space - int cellsInRow( floor( ((iky+1)*cellSize+b)/(a*cellSize) ) ); + int cellsInRow( floor( ((iky+1)*cellSize+b+k_horizontalShift*cellSize)/(a*cellSize) ) ); if (testCell+cellsInRow > cell) break; testCell += cellsInRow; ky++; @@ -237,7 +238,7 @@ int HGCalDDDConstants::maxCells(float h, float bl, float tl, float alpha, int kymax = floor((2*h)/cellSize); for (int iky=0; iky HGCalDDDConstants::numberCells(float h, float bl, int kymax = floor((2*h)/cellSize); std::vector ncell; for (int iky=0; iky HGCalDDDConstants::simToReco(int cell, int lay, std::pair kxy = findCell(cell, h, bl, tl, modules_[i].alpha, index.second); int depth = layerGroup_[i]; + if(depth<0) return std::pair(-1,-1); int kx = kxy.first/cellFactor_[i]; int ky = kxy.second/cellFactor_[i]; float a = (half) ? (h/(tl-bl)) : (2*h/(tl-bl)); float b = 2*h*bl/(tl-bl); for (int iky=0; iky phicell = hgcons->assignCell(pos.x(),pos.y(),layer,0,false); int phiSector = phicell.first; From 5af873b6b883818ad28449e5402dab4db3f44be2 Mon Sep 17 00:00:00 2001 From: Aaron Levine Date: Fri, 26 Sep 2014 05:04:40 -0500 Subject: [PATCH 142/252] change tau veto definition (greater than sign -> greater than or equal to sign) --- L1Trigger/RegionalCaloTrigger/src/L1RCTLookupTables.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/L1Trigger/RegionalCaloTrigger/src/L1RCTLookupTables.cc b/L1Trigger/RegionalCaloTrigger/src/L1RCTLookupTables.cc index 11c4b0107f024..8b7ee99feac9a 100644 --- a/L1Trigger/RegionalCaloTrigger/src/L1RCTLookupTables.cc +++ b/L1Trigger/RegionalCaloTrigger/src/L1RCTLookupTables.cc @@ -230,8 +230,8 @@ bool L1RCTLookupTables::activityBit(float ecal, float hcal,bool fgbit) const bool aBit = false; if(rctParameters_->eMinForHoECut() < rctParameters_->eMaxForHoECut()) { // For RCT operations HoE cut and tauVeto are used - aBit = ((ecal > rctParameters_->eActivityCut()) || - (hcal > rctParameters_->hActivityCut())); + aBit = ((ecal >= rctParameters_->eActivityCut()) || + (hcal >= rctParameters_->hActivityCut())); } else { // We redefine tauVeto() for upgrade as EM activity only -- From fb05ef16bf06464b4917417605efc6df450ce53d Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Fri, 26 Sep 2014 12:27:57 +0200 Subject: [PATCH 143/252] HGC V5 geometry cell size modification, no hanging in XY --- .../HGCalCommonData/data/v5/hgcalCons.xml | 252 +++++++++--------- Geometry/HGCalCommonData/data/v5/hgcalEE.xml | 180 ++++++------- .../HGCalCommonData/data/v5/hgcalHEsil.xml | 72 ++--- 3 files changed, 252 insertions(+), 252 deletions(-) diff --git a/Geometry/HGCalCommonData/data/v5/hgcalCons.xml b/Geometry/HGCalCommonData/data/v5/hgcalCons.xml index f16d8e64864ce..a8f3f8687d995 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalCons.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalCons.xml @@ -5,96 +5,96 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -189,42 +189,42 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/HGCalCommonData/data/v5/hgcalEE.xml b/Geometry/HGCalCommonData/data/v5/hgcalEE.xml index 83eeba5530024..f027f6f4773c5 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalEE.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalEE.xml @@ -127,96 +127,96 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml b/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml index 6ec67b33bfae9..ccc4596a122b9 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml @@ -94,42 +94,42 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 31f5ef4e9c44e5e659931ed83c863456665396e3 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Fri, 26 Sep 2014 15:15:55 +0200 Subject: [PATCH 144/252] fixing code for cross check --- SimG4CMS/Calo/src/HGCNumberingScheme.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SimG4CMS/Calo/src/HGCNumberingScheme.cc b/SimG4CMS/Calo/src/HGCNumberingScheme.cc index c526a8651ca17..32630aadfd7b7 100644 --- a/SimG4CMS/Calo/src/HGCNumberingScheme.cc +++ b/SimG4CMS/Calo/src/HGCNumberingScheme.cc @@ -35,7 +35,7 @@ uint32_t HGCNumberingScheme::getUnitID(ForwardSubdetector &subdet, int &layer, i if ((!HGCalDetId::isValid(subdet,iz,layer,sector,phiSector,icell)) || (!hgcons->isValid(layer,sector,icell,false))) { index = 0; - if (check_ && icell != -2) { + if (check_ && icell != -1) { edm::LogError("HGCSim") << "[HGCNumberingScheme] ID out of bounds :" << " Subdet= " << subdet << " Zside= " << iz << " Layer= " << layer << " Sector= " << sector From d348486b1b4f96cc72a9abb35f3dc0d048a96982 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Fri, 26 Sep 2014 16:49:51 +0200 Subject: [PATCH 145/252] removing parameters passed by reference in getUnitID --- SimG4CMS/Calo/interface/HGCNumberingScheme.h | 2 +- SimG4CMS/Calo/src/HGCNumberingScheme.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/SimG4CMS/Calo/interface/HGCNumberingScheme.h b/SimG4CMS/Calo/interface/HGCNumberingScheme.h index bd0b1bc3b75c2..8f953818a6bc5 100644 --- a/SimG4CMS/Calo/interface/HGCNumberingScheme.h +++ b/SimG4CMS/Calo/interface/HGCNumberingScheme.h @@ -29,7 +29,7 @@ class HGCNumberingScheme : public CaloNumberingScheme { /** @short assigns the det id to a hit */ - virtual uint32_t getUnitID(ForwardSubdetector &subdet, int &layer, int &module, int &iz, const G4ThreeVector &pos); + virtual uint32_t getUnitID(ForwardSubdetector subdet, int layer, int module, int iz, const G4ThreeVector &pos); /** @short maps a hit position to a sequential cell in a trapezoid surface defined by h,b,t diff --git a/SimG4CMS/Calo/src/HGCNumberingScheme.cc b/SimG4CMS/Calo/src/HGCNumberingScheme.cc index 32630aadfd7b7..e4f63c025945d 100644 --- a/SimG4CMS/Calo/src/HGCNumberingScheme.cc +++ b/SimG4CMS/Calo/src/HGCNumberingScheme.cc @@ -22,7 +22,7 @@ HGCNumberingScheme::~HGCNumberingScheme() { } // -uint32_t HGCNumberingScheme::getUnitID(ForwardSubdetector &subdet, int &layer, int §or, int &iz, const G4ThreeVector &pos) { +uint32_t HGCNumberingScheme::getUnitID(ForwardSubdetector subdet, int layer, int sector, int iz, const G4ThreeVector &pos) { std::pair phicell = hgcons->assignCell(pos.x(),pos.y(),layer,0,false); int phiSector = phicell.first; From 3f42c66f0853e042d323f50bf2f7c93366710f49 Mon Sep 17 00:00:00 2001 From: Suchandra Date: Mon, 29 Sep 2014 08:20:38 +0200 Subject: [PATCH 146/252] DigiValidation updated to have complete migration to use TrackerTopology --- .../plugins/Phase2TrackerDigitizer.cc | 2 - .../SiPhase2Digitizer/test/DigiValidation.cc | 40 ++++--------------- .../test/DigiValidationTest_cfg.py | 2 +- 3 files changed, 9 insertions(+), 35 deletions(-) diff --git a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc index 8d1b2ea795282..7c4508fa0291d 100644 --- a/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc +++ b/SimTracker/SiPhase2Digitizer/plugins/Phase2TrackerDigitizer.cc @@ -32,8 +32,6 @@ #include "DataFormats/Common/interface/DetSetVector.h" #include "DataFormats/SiPixelDigi/interface/PixelDigi.h" #include "DataFormats/SiPixelDigi/interface/PixelDigiCollection.h" -#include "DataFormats/SiPixelDetId/interface/PXBDetId.h" -#include "DataFormats/SiPixelDetId/interface/PXFDetId.h" #include "SimDataFormats/TrackingHit/interface/PSimHitContainer.h" #include "DataFormats/GeometryVector/interface/LocalPoint.h" #include "DataFormats/GeometryVector/interface/LocalVector.h" diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc index 6a7029c908071..d2fb1730487fb 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidation.cc @@ -45,8 +45,6 @@ #include "Geometry/Records/interface/StackedTrackerGeometryRecord.h" #include "DataFormats/SiPixelDetId/interface/PixelSubdetector.h" -#include "DataFormats/SiPixelDetId/interface/PXBDetId.h" -#include "DataFormats/SiPixelDetId/interface/PXFDetId.h" #include "DataFormats/SiPixelDetId/interface/PixelBarrelName.h" #include "DataFormats/TrackerCommon/interface/TrackerTopology.h" @@ -257,9 +255,8 @@ class DigiValidation : public edm::EDAnalyzer { int matchedSimTrack(edm::Handle& SimTk, unsigned int simTrkId); void initializeVariables(); unsigned int getMaxPosition(std::vector& charge_vec); - unsigned int getLayerNumber(const TrackerGeometry* tkgeom, unsigned int& detid); + unsigned int getLayerNumber(const TrackerGeometry* tkgeom, unsigned int& detid, const TrackerTopology* topo); unsigned int getLayerNumber(unsigned int& detid, const TrackerTopology* topo); - unsigned int getLayerNumber(unsigned int& detid); int isPrimary(const SimTrack& simTrk, edm::Handle& simHits); int isPrimary(const SimTrack& simTrk, const PSimHit& simHit); void fillMatchedSimTrackHistos(DigiHistos& digiHistos, const SimTrack& simTk, int ptype, unsigned int layer); @@ -325,9 +322,9 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS // const StackedTrackerGeometry* theStackedGeometry = stackedGeometryHandle.product(); // Tracker Topology - // edm::ESHandle tTopoHandle; - // iSetup.get().get(tTopoHandle); - // const TrackerTopology* tTopo = tTopoHandle.product(); + edm::ESHandle tTopoHandle; + iSetup.get().get(tTopoHandle); + const TrackerTopology* tTopo = tTopoHandle.product(); // Get PSimHits edm::Handle simHits; @@ -399,7 +396,7 @@ void DigiValidation::analyze(const edm::Event& iEvent, const edm::EventSetup& iS for(DSViter = pixelDigis->begin(); DSViter != pixelDigis->end(); DSViter++) { unsigned int rawid = DSViter->id; DetId detId(rawid); - unsigned int layer = getLayerNumber(rawid); + unsigned int layer = getLayerNumber(rawid, tTopo); std::map::iterator iPos = layerHistoMap.find(layer); if (iPos == layerHistoMap.end()) { createLayerHistograms(layer); @@ -915,7 +912,7 @@ void DigiValidation::initializeVariables() { // // -- Get Layer Number // -unsigned int DigiValidation::getLayerNumber(const TrackerGeometry* tkgeom,unsigned int& detid) { +unsigned int DigiValidation::getLayerNumber(const TrackerGeometry* tkgeom,unsigned int& detid, const TrackerTopology* topo) { unsigned int layer = 999; DetId theDetId(detid); if (theDetId.subdetId() != 1) @@ -933,11 +930,9 @@ unsigned int DigiValidation::getLayerNumber(const TrackerGeometry* tkgeom,unsign if (it && it->type().isTracker()) { if (it->type().isBarrel()) { - PXBDetId pb_detId = PXBDetId(detid); - layer = pb_detId.layer(); + layer = topo->pxbLayer(detid); } else if (it->type().isEndcap()) { - PXFDetId pf_detId = PXFDetId(detid); - layer = 100*pf_detId.side() + pf_detId.disk(); + layer = 100 * topo->pxfSide(detid) + topo->pxfDisk(detid); } } return layer; @@ -961,25 +956,6 @@ unsigned int DigiValidation::getLayerNumber(unsigned int& detid, const TrackerTo return layer; } // -// -- Get Layer Number -// -unsigned int DigiValidation::getLayerNumber(unsigned int& detid) { - unsigned int layer = 999; - DetId theDetId(detid); - if (theDetId.det() == DetId::Tracker) { - if (theDetId.subdetId() == PixelSubdetector::PixelBarrel) { - PXBDetId pb_detId = PXBDetId(detid); - layer = pb_detId.layer(); - } else if (theDetId.subdetId() == PixelSubdetector::PixelEndcap) { - PXFDetId pf_detId = PXFDetId(detid); - layer = 100*pf_detId.side() + pf_detId.disk(); - } else { - std::cout << ">>> Invalid subdetId() = " << theDetId.subdetId() << std::endl; - } - } - return layer; -} -// // -- Get Maximun position of a vector // unsigned int DigiValidation::getMaxPosition(std::vector& charge_vec) { diff --git a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py index 4a33cf82d99dd..39ee9fc04c4a2 100644 --- a/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py +++ b/SimTracker/SiPhase2Digitizer/test/DigiValidationTest_cfg.py @@ -37,7 +37,7 @@ # Other statements process.genstepfilter.triggerConditions=cms.vstring("generation_step") from Configuration.AlCa.GlobalTag import GlobalTag -process.GlobalTag = GlobalTag(process.GlobalTag, 'POSTLS161_V15::All', '') +process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '') #------------- # Output ROOT file From 83ffa6b173beffa1832032b74c183a5d2c5d37ba Mon Sep 17 00:00:00 2001 From: Giovanni Franzoni Date: Tue, 30 Sep 2014 11:39:37 +0200 Subject: [PATCH 147/252] set prio withing wma valid range; affects only relval injection, no impact on IB --- Configuration/PyReleaseValidation/python/MatrixInjector.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Configuration/PyReleaseValidation/python/MatrixInjector.py b/Configuration/PyReleaseValidation/python/MatrixInjector.py index d08dd1e0b0d43..e2f9b19a22274 100644 --- a/Configuration/PyReleaseValidation/python/MatrixInjector.py +++ b/Configuration/PyReleaseValidation/python/MatrixInjector.py @@ -81,7 +81,7 @@ def __init__(self,opt,mode='init',options=''): self.defaultChain={ "RequestType" : "TaskChain", #this is how we handle relvals "SubRequestType" : "RelVal", #this is how we handle relvals, now that TaskChain is also used for central MC production - "RequestPriority": 1000000, + "RequestPriority": 999999, "Requestor": self.user, #Person responsible "Group": self.group, #group for the request "CMSSWVersion": os.getenv('CMSSW_VERSION'), #CMSSW Version (used for all tasks in chain) From f03a5d1b972888955c8f199f497c99eae8d093d8 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Wed, 24 Sep 2014 12:42:23 +0200 Subject: [PATCH 148/252] tuning up clustering based on initial geometry fixes Conflicts: RecoParticleFlow/PFClusterProducer/test/run_display.sh --- .../python/particleFlowClusterHGCEE_cfi.py | 4 +-- .../python/particleFlowClusterHGCHEB_cfi.py | 4 +-- .../python/particleFlowClusterHGCHEF_cfi.py | 6 ++-- .../PFClusterProducer/test/hgcal_rechits.fwc | 34 +++++++++---------- .../PFClusterProducer/test/run_display.sh | 3 +- .../plugins/kdtrees/KDTreeLinkerTrackHGC.h | 9 +++-- 6 files changed, 32 insertions(+), 28 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py index 50bb5301bed76..df7362265294c 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py @@ -26,8 +26,8 @@ _manqiArborClusterizer_HGCEE = cms.PSet( algoName = cms.string("SimpleArborClusterizer"), # use basic pad sizes in HGCEE - cellSize = cms.double(10.0), - layerThickness = cms.double(16.0), + cellSize = cms.double(16.0), + layerThickness = cms.double(18.0), distSeedForMerge = cms.double(20.0), killNoiseClusters = cms.bool(True), maxNoiseClusterSize = cms.uint32(3), diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py index c74a8e068b2aa..68e2aabd180bf 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py @@ -23,8 +23,8 @@ _manqiArborClusterizer_HGCHEB = cms.PSet( algoName = cms.string("SimpleArborClusterizer"), # use basic pad sizes in HGCEE - cellSize = cms.double(30.0), - layerThickness = cms.double(55.0), + cellSize = cms.double(35.0), + layerThickness = cms.double(65.0), distSeedForMerge = cms.double(20.0), killNoiseClusters = cms.bool(True), maxNoiseClusterSize = cms.uint32(3), diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py index 1b45cd31973e6..1fb91a182e124 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py @@ -23,9 +23,9 @@ _manqiArborClusterizer_HGCHEF = cms.PSet( algoName = cms.string("SimpleArborClusterizer"), # use basic pad sizes in HGCEE - cellSize = cms.double(10.0), - layerThickness = cms.double(45.0), - distSeedForMerge = cms.double(20.0), + cellSize = cms.double(15.0), + layerThickness = cms.double(55.0), + distSeedForMerge = cms.double(30.0), killNoiseClusters = cms.bool(True), maxNoiseClusterSize = cms.uint32(3), thresholdsByDetector = cms.VPSet( ) diff --git a/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc b/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc index 6fb000b21c9a1..8e45338d548dc 100644 --- a/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc +++ b/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc @@ -894,10 +894,10 @@ - 54 + 106 - 44 + 23 1263 @@ -1011,22 +1011,22 @@ 1 - -0.401173 + 0.769709 - -0.563483 + 0.13655 - 0.722185 + 0.623623 0 - 0.814632 + -0.174677 - -0.579978 + 0.984626 0 @@ -1035,25 +1035,25 @@ 0 - 0.41885 + -0.614034 - 0.588315 + -0.108934 - 0.691701 + 0.781726 0 - -1458.17 + 2877.96 - -2016.83 + 498.315 - 2612.92 + 2219.76 1 @@ -1095,19 +1095,19 @@ 0 - -52.4547 + 0.281389 - -37.8377 + 0.577909 - 317.74 + 6.85455 1 - 3.09973 + 5.46292 diff --git a/RecoParticleFlow/PFClusterProducer/test/run_display.sh b/RecoParticleFlow/PFClusterProducer/test/run_display.sh index f36f11d10a0e0..45f194a88c37e 100755 --- a/RecoParticleFlow/PFClusterProducer/test/run_display.sh +++ b/RecoParticleFlow/PFClusterProducer/test/run_display.sh @@ -1,6 +1,7 @@ #!/bin/bash -cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g /home/lgray/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file /home/lgray/xHGCAL/cmsSimGeom-14-HGCAL.root /home/lgray/CMSSW_6_2_0_SLHC16/src/matrix_tests/simple_jet_gun/step3.root +cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g ~/work/public/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file ~/work/public/xHGCAL/cmsSimGeom-14-HGCAL.root ${CMSSW_BASE}/src/matrix_tests/14801_FourMuPt1_200+FourMuPt_1_200_Extended2023HGCalV4_GenSimFull+DigiFull_Extended2023HGCalV4+RecoFull_Extended2023HGCalV4+HARVESTFull_Extended2023HGCalV4/step3.root + #12202_SinglePionPt35+SinglePionPt35_Extended2023HGCalMuon_GenSimFull+DigiFull_Extended2023HGCalMuon+RecoFull_Extended2023HGCalMuon+HARVESTFull_Extended2023HGCalMuon diff --git a/RecoParticleFlow/PFProducer/plugins/kdtrees/KDTreeLinkerTrackHGC.h b/RecoParticleFlow/PFProducer/plugins/kdtrees/KDTreeLinkerTrackHGC.h index a9d49e131db53..203d3b52c2353 100644 --- a/RecoParticleFlow/PFProducer/plugins/kdtrees/KDTreeLinkerTrackHGC.h +++ b/RecoParticleFlow/PFProducer/plugins/kdtrees/KDTreeLinkerTrackHGC.h @@ -99,6 +99,7 @@ KDTreeLinkerTrackHGC::insertFieldClusterElt(reco::PFBlockEl // We create a list of hgcCluster fieldClusterSet_.insert(hgcCluster); + /* DetId seedId( clusterref->seed() ); unsigned seedLayer = 1000; if( seedId.det() == DetId::Forward ) { @@ -111,10 +112,12 @@ KDTreeLinkerTrackHGC::insertFieldClusterElt(reco::PFBlockEl throw cms::Exception("BadSeedRecHit") << "HGC KDTree Linker only accepts HGC DetIds! got: " << seedId.det(); } + */ for(size_t rhit = 0; rhit < fraction.size(); ++rhit) { const reco::PFRecHitRef& rh = fraction[rhit].recHitRef(); double fract = fraction[rhit].fraction(); + /* DetId rhId( rh->detId() ); unsigned rhLayer = 1000; @@ -128,8 +131,8 @@ KDTreeLinkerTrackHGC::insertFieldClusterElt(reco::PFBlockEl throw cms::Exception("BadRecHit") << "HGC KDTree Linker only accepts HGC DetIds! got: " << rhId.det(); } - - if ( (rh.isNull()) || (fract < 1E-4) || rhLayer != seedLayer ) + */ + if ( (rh.isNull()) || (fract < 1E-4) ) // || rhLayer != seedLayer ) continue; const reco::PFRecHit& rechit = *rh; @@ -233,7 +236,7 @@ void // Estimate the maximal envelope in phi/eta that will be used to find rechit candidates. // Same envelope for cap et barrel rechits. - double range = getCristalPhiEtaMaxSize() * (2.0 + 1.0 / std::min(1., trackPt / 2.)); + double range = getCristalPhiEtaMaxSize() * (2.0 + 1.0 / std::min(1., 0.5*trackPt )); // We search for all candidate recHits, ie all recHits contained in the maximal size envelope. std::vector recHits; From ef7e8b803347075dfcae47172d8f5af6d6d07d07 Mon Sep 17 00:00:00 2001 From: Giovanni Franzoni Date: Wed, 1 Oct 2014 17:11:50 +0200 Subject: [PATCH 149/252] back-port of configBuilder to handle DQMIO --- Configuration/Applications/python/ConfigBuilder.py | 10 +++++----- Configuration/Applications/python/cmsDriverOptions.py | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Configuration/Applications/python/ConfigBuilder.py b/Configuration/Applications/python/ConfigBuilder.py index c393e45f2fc64..2cdeda1014be5 100644 --- a/Configuration/Applications/python/ConfigBuilder.py +++ b/Configuration/Applications/python/ConfigBuilder.py @@ -170,7 +170,7 @@ def __init__(self, options, process = None, with_output = False, with_input = Fa #if not self._options.conditions: # raise Exception("ERROR: No conditions given!\nPlease specify conditions. E.g. via --conditions=IDEAL_30X::All") - if hasattr(self._options,"datatier") and self._options.datatier and 'DQMROOT' in self._options.datatier and 'ENDJOB' in self._options.step: + if hasattr(self._options,"datatier") and self._options.datatier and 'DQMIO' in self._options.datatier and 'ENDJOB' in self._options.step: self._options.step=self._options.step.replace(',ENDJOB','') # what steps are provided by this class? @@ -492,7 +492,7 @@ def anyOf(listOfKeys,dict,opt=None): if len(outDefDict.keys()): raise Exception("unused keys from --output options: "+','.join(outDefDict.keys())) - if theStreamType=='DQMROOT': theStreamType='DQM' + if theStreamType=='DQMIO': theStreamType='DQM' if theStreamType=='ALL': theEventContent = cms.PSet(outputCommands = cms.untracked.vstring('keep *')) else: @@ -502,7 +502,7 @@ def anyOf(listOfKeys,dict,opt=None): theFilterName='StreamALCACombined' CppType='PoolOutputModule' - if theStreamType=='DQM' and theTier=='DQMROOT': CppType='DQMRootOutputModule' + if theStreamType=='DQM' and theTier=='DQMIO': CppType='DQMRootOutputModule' output = cms.OutputModule(CppType, theEventContent.clone(), fileName = cms.untracked.string(theFileName), @@ -554,7 +554,7 @@ def doNotInlineEventContent(instance,label = "cms.untracked.vstring(process."+th for i,(streamType,tier) in enumerate(zip(streamTypes,tiers)): if streamType=='': continue - if streamType=='DQMROOT': streamType='DQM' + if streamType=='DQMIO': streamType='DQM' theEventContent = getattr(self.process, streamType+"EventContent") if i==0: theFileName=self._options.outfile_name @@ -563,7 +563,7 @@ def doNotInlineEventContent(instance,label = "cms.untracked.vstring(process."+th theFileName=self._options.outfile_name.replace('.root','_in'+streamType+'.root') theFilterName=self._options.filtername CppType='PoolOutputModule' - if streamType=='DQM' and tier=='DQMROOT': CppType='DQMRootOutputModule' + if streamType=='DQM' and tier=='DQMIO': CppType='DQMRootOutputModule' output = cms.OutputModule(CppType, theEventContent, fileName = cms.untracked.string(theFileName), diff --git a/Configuration/Applications/python/cmsDriverOptions.py b/Configuration/Applications/python/cmsDriverOptions.py index 637559b3b0ba9..81070df1fd26a 100755 --- a/Configuration/Applications/python/cmsDriverOptions.py +++ b/Configuration/Applications/python/cmsDriverOptions.py @@ -127,7 +127,7 @@ def OptionsFromItems(items): addEndJob = False if ("ENDJOB" in options.step): addEndJob = False - if ('DQMROOT' in options.datatier): + if ('DQMIO' in options.datatier): addEndJob = False if addEndJob: options.step=options.step+',ENDJOB' From 7b937766201dfdd79220f5a25181f3b153981c01 Mon Sep 17 00:00:00 2001 From: Giovanni Franzoni Date: Wed, 1 Oct 2014 17:54:01 +0200 Subject: [PATCH 150/252] relval matrix uses DQMIO for workflow injection to production. --revertDqmio=yes available if one needs to use old DQM --- .../python/MatrixReader.py | 11 +++--- .../python/relval_steps.py | 36 +++++++++---------- .../scripts/runTheMatrix.py | 6 ++++ 3 files changed, 31 insertions(+), 22 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/MatrixReader.py b/Configuration/PyReleaseValidation/python/MatrixReader.py index 14b0fe814c591..4f2d9053d2b64 100644 --- a/Configuration/PyReleaseValidation/python/MatrixReader.py +++ b/Configuration/PyReleaseValidation/python/MatrixReader.py @@ -21,6 +21,7 @@ def __init__(self, opt): self.wm=opt.wmcontrol self.addCommand=opt.command + self.revertDqmio=opt.revertDqmio self.apply=opt.apply self.commandLineWf=opt.workflow self.overWrite=opt.overWrite @@ -245,8 +246,8 @@ def readMatrix(self, fileNameIn, useInput=None, refRel=None, fromScratch=None): cmd +=' '+self.addCommand else: cmd +=' '+self.addCommand - if self.wm: - cmd=cmd.replace('DQMROOT','DQM') + if self.wm and self.revertDqmio=='yes': + cmd=cmd.replace('DQMIO','DQM') cmd=cmd.replace('--filetype DQM','') commands.append(cmd) ranStepList.append(stepName) @@ -335,7 +336,8 @@ def showRaw(self, useInput, refRel=None, fromScratch=None, what='all',step1Only= line += ' @@@' else: line += ' @@@ '+commands[0] - line=line.replace('DQMROOT','DQM') + if self.revertDqmio=='yes': + line=line.replace('DQMIO','DQM') writtenWF+=1 outFile.write(line+'\n') @@ -348,7 +350,8 @@ def showRaw(self, useInput, refRel=None, fromScratch=None, what='all',step1Only= stepIndex=index+1 if 'dasquery.log' in cmd: continue line = 'STEP%d ++ '%(stepIndex,) +stepName + ' @@@ '+cmd - line=line.replace('DQMROOT','DQM') + if self.revertDqmio=='yes': + line=line.replace('DQMIO','DQM') outFile.write(line+'\n') outFile.write('\n'+'\n') outFile.close() diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index b17a875dded3c..26523046f1dfb 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -561,7 +561,7 @@ def addForAll(steps,d): step1FastDefaults =merge([{'-s':'GEN,SIM,RECO,EI,HLT:@relval,VALIDATION', '--fast':'', '--eventcontent':'FEVTDEBUGHLT,DQM', - '--datatier':'GEN-SIM-DIGI-RECO,DQM', + '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', '--relval':'27000,3000'}, step1Defaults]) @@ -652,7 +652,7 @@ def genvalid(fragment,d,suffix='all',fi=''): ##no forseen to do things in two steps GEN-SIM then FASTIM->end: maybe later step1FastDefaultsP1 =merge([{'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', - '--datatier':'GEN-SIM-DIGI-RECO,DQM', + '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', '--conditions':'auto:upgradePLS3', '--fast':'', '--geometry' : 'Extended2017', @@ -670,7 +670,7 @@ def genvalid(fragment,d,suffix='all',fi=''): step1FastDefaultsP1PU =merge([{'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', - '--datatier':'GEN-SIM-DIGI-RECO,DQM', + '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', '--conditions':'auto:upgradePLS3', '--fast':'', '--pileup':'default', @@ -683,7 +683,7 @@ def genvalid(fragment,d,suffix='all',fi=''): step1FastDefaultsP2 =merge([{'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', - '--datatier':'GEN-SIM-DIGI-RECO,DQM', + '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', '--fast':'', '--conditions':'auto:upgradePLS3', '--geometry' : 'ExtendedPhase2TkBE', @@ -702,7 +702,7 @@ def genvalid(fragment,d,suffix='all',fi=''): step1FastDefaultsP2PU =merge([{'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', - '--datatier':'GEN-SIM-DIGI-RECO,DQM', + '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', '--fast':'', '--pileup':'default', '--conditions':'auto:upgradePLS3', @@ -714,7 +714,7 @@ def genvalid(fragment,d,suffix='all',fi=''): step1FastDefaultsP2Forw =merge([{'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', - '--datatier':'GEN-SIM-DIGI-RECO,DQM', + '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', '--conditions':'auto:upgradePLS3', '--geometry' : 'ExtendedPhase2TkBEForward', '--fast':'', @@ -774,8 +774,8 @@ def genvalid(fragment,d,suffix='all',fi=''): dataReco={'--conditions':'auto:com10', '-s':'RAW2DIGI,L1Reco,RECO,ALCA:SiStripCalZeroBias+SiStripCalMinBias+TkAlMinBias,DQM', - '--datatier':'RECO,DQMROOT', - '--eventcontent':'RECO,DQMROOT', + '--datatier':'RECO,DQMIO', + '--eventcontent':'RECO,DQM', '--data':'', '--process':'reRECO', '--scenario':'pp', @@ -784,8 +784,8 @@ def genvalid(fragment,d,suffix='all',fi=''): dataReco={'--conditions':'auto:com10', '-s':'RAW2DIGI,L1Reco,RECO,EI,ALCA:SiStripCalZeroBias+SiStripCalMinBias+TkAlMinBias,DQM', - '--datatier':'RECO,DQMROOT', - '--eventcontent':'RECO,DQMROOT', + '--datatier':'RECO,DQMIO', + '--eventcontent':'RECO,DQM', '--data':'', '--process':'reRECO', '--scenario':'pp', @@ -815,8 +815,8 @@ def genvalid(fragment,d,suffix='all',fi=''): steps['RECOD']]) steps['RECOHID10']=merge([{'--scenario':'HeavyIons', '-s':'RAW2DIGI,L1Reco,RECO,ALCA:SiStripCalZeroBias+SiStripCalMinBias+TkAlMinBiasHI+HcalCalMinBias,DQM', - '--datatier':'RECO,DQMROOT', - '--eventcontent':'RECO,DQMROOT'}, + '--datatier':'RECO,DQMIO', + '--eventcontent':'RECO,DQM'}, steps['RECOD']]) steps['RECOHID11']=merge([{'--repacked':''}, steps['RECOHID10']]) @@ -826,12 +826,12 @@ def genvalid(fragment,d,suffix='all',fi=''): steps['TIER0']=merge([{'--customise':'Configuration/DataProcessing/RecoTLR.customisePrompt', '-s':'RAW2DIGI,L1Reco,RECO,EI,ALCAPRODUCER:@allForPrompt,DQM,ENDJOB', - '--datatier':'RECO,AOD,ALCARECO,DQMROOT', - '--eventcontent':'RECO,AOD,ALCARECO,DQMROOT', + '--datatier':'RECO,AOD,ALCARECO,DQMIO', + '--eventcontent':'RECO,AOD,ALCARECO,DQM', '--process':'RECO' },dataReco]) steps['TIER0EXP']=merge([{'-s':'RAW2DIGI,L1Reco,RECO,EI,ALCAPRODUCER:@allForExpress,DQM,ENDJOB', - '--datatier':'ALCARECO,DQM', + '--datatier':'ALCARECO,DQMIO', '--eventcontent':'ALCARECO,DQM', '--customise':'Configuration/DataProcessing/RecoTLR.customiseExpress', },steps['TIER0']]) @@ -855,7 +855,7 @@ def genvalid(fragment,d,suffix='all',fi=''): '-s' : 'RAW2DIGI,L1Reco,RECO,EI,VALIDATION,DQM', '--conditions' : 'auto:startup', '--no_exec' : '', - '--datatier' : 'GEN-SIM-RECO,DQM', + '--datatier' : 'GEN-SIM-RECO,DQMIO', '--eventcontent': 'RECOSIM,DQM' } @@ -1290,7 +1290,7 @@ def genvalid(fragment,d,suffix='all',fi=''): upgradeStepDict['RecoFull'][k] = {'-s':'RAW2DIGI,L1Reco,RECO,VALIDATION,DQM', '--conditions':upgradeGTs[k], - '--datatier':'GEN-SIM-RECO,DQM', + '--datatier':'GEN-SIM-RECO,DQMIO', '-n':'10', '--eventcontent':'FEVTDEBUGHLT,DQM', '--magField' : '38T_PostLS1', @@ -1309,7 +1309,7 @@ def genvalid(fragment,d,suffix='all',fi=''): upgradeStepDict['FastSim'][k]={'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', - '--datatier':'GEN-SIM-DIGI-RECO,DQM', + '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', '--conditions':upgradeGTs[k], '--fast':'', '--geometry' : upgradeGeoms[k], diff --git a/Configuration/PyReleaseValidation/scripts/runTheMatrix.py b/Configuration/PyReleaseValidation/scripts/runTheMatrix.py index 038e26134ec3f..b0102d8b1fc51 100755 --- a/Configuration/PyReleaseValidation/scripts/runTheMatrix.py +++ b/Configuration/PyReleaseValidation/scripts/runTheMatrix.py @@ -132,6 +132,12 @@ def runSelected(opt): dest='wmcontrol', default=None, ) + parser.add_option('--revertDqmio', + help='When submitting workflows to wmcontrol, force DQM outout to use pool and not DQMIO', + choices=['yes','no'], + dest='revertDqmio', + default='no', + ) parser.add_option('--optionswm', help='Specify a few things for wm injection', default='', From 787494fdc1a3434588f1307952aed111c676cf59 Mon Sep 17 00:00:00 2001 From: Giovanni Franzoni Date: Thu, 2 Oct 2014 09:21:16 +0200 Subject: [PATCH 151/252] DQMIO in upgradeKeys for upgrade-specific HARVESRTING step --- Configuration/PyReleaseValidation/python/relval_steps.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 26523046f1dfb..564203d116c2c 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1303,7 +1303,8 @@ def genvalid(fragment,d,suffix='all',fi=''): '--mc':'', '--magField' : '38T_PostLS1', '--geometry' : upgradeGeoms[k], - '--scenario' : 'pp' + '--scenario' : 'pp', + '--filetype':'DQM' } if upgradeCustoms[k]!=None : upgradeStepDict['HARVESTFull'][k]['--customise']=upgradeCustoms[k] From 4b1575bd20fa8986cb4ca1329d66cb8405039d4d Mon Sep 17 00:00:00 2001 From: federico de guio Date: Wed, 1 Oct 2014 15:45:01 +0200 Subject: [PATCH 152/252] back port the last DQMIO features to 620_SLHC --- DQMServices/Core/interface/MonitorElement.h | 3 ++ DQMServices/Core/src/DQMStore.cc | 5 ++- DQMServices/Core/src/MonitorElement.cc | 29 ++++++++++++++++ DQMServices/FwkIO/plugins/DQMRootSource.cc | 38 +++++++++++++++------ 4 files changed, 64 insertions(+), 11 deletions(-) diff --git a/DQMServices/Core/interface/MonitorElement.h b/DQMServices/Core/interface/MonitorElement.h index d1d38b6e220a3..a2a714341c3c5 100755 --- a/DQMServices/Core/interface/MonitorElement.h +++ b/DQMServices/Core/interface/MonitorElement.h @@ -87,6 +87,9 @@ class MonitorElement return DQMNet::setOrder(data_, x.data_); } + /// Check the consistency of the axis labels + static bool CheckBinLabels(const TAxis* a1, const TAxis * a2); + /// Get the type of the monitor element. Kind kind(void) const { return Kind(data_.flags & DQMNet::DQM_PROP_TYPE_MASK); } diff --git a/DQMServices/Core/src/DQMStore.cc b/DQMServices/Core/src/DQMStore.cc index b556d3462b82c..59b1a647233f1 100644 --- a/DQMServices/Core/src/DQMStore.cc +++ b/DQMServices/Core/src/DQMStore.cc @@ -1269,7 +1269,10 @@ DQMStore::checkBinningMatches(MonitorElement *me, TH1 *h) || me->getTH1()->GetZaxis()->GetXmin() != h->GetZaxis()->GetXmin() || me->getTH1()->GetXaxis()->GetXmax() != h->GetXaxis()->GetXmax() || me->getTH1()->GetYaxis()->GetXmax() != h->GetYaxis()->GetXmax() - || me->getTH1()->GetZaxis()->GetXmax() != h->GetZaxis()->GetXmax()) + || me->getTH1()->GetZaxis()->GetXmax() != h->GetZaxis()->GetXmax() + || !MonitorElement::CheckBinLabels((TAxis*)me->getTH1()->GetXaxis(),(TAxis*)h->GetXaxis()) + || !MonitorElement::CheckBinLabels((TAxis*)me->getTH1()->GetYaxis(),(TAxis*)h->GetYaxis()) + || !MonitorElement::CheckBinLabels((TAxis*)me->getTH1()->GetZaxis(),(TAxis*)h->GetZaxis()) ) { // edm::LogWarning ("DQMStore") std::cout << "*** DQMStore: WARNING:" diff --git a/DQMServices/Core/src/MonitorElement.cc b/DQMServices/Core/src/MonitorElement.cc index f5b169b9b055c..83b7f351f38d7 100755 --- a/DQMServices/Core/src/MonitorElement.cc +++ b/DQMServices/Core/src/MonitorElement.cc @@ -6,6 +6,7 @@ #include "TClass.h" #include "TMath.h" #include "TList.h" +#include "THashList.h" #include #include #include @@ -216,6 +217,34 @@ MonitorElement::~MonitorElement(void) delete refvalue_; } +//utility function to check the consistency of the axis labels +//taken from TH1::CheckBinLabels which is not public +bool +MonitorElement::CheckBinLabels(const TAxis* a1, const TAxis * a2) +{ + // check that axis have same labels + THashList *l1 = (const_cast(a1))->GetLabels(); + THashList *l2 = (const_cast(a2))->GetLabels(); + + if (!l1 && !l2 ) + return true; + if (!l1 || !l2 ) { + return false; + } + // check now labels sizes are the same + if (l1->GetSize() != l2->GetSize() ) { + return false; + } + for (int i = 1; i <= a1->GetNbins(); ++i) { + TString label1 = a1->GetBinLabel(i); + TString label2 = a2->GetBinLabel(i); + if (label1 != label2) { + return false; + } + } + return true; +} + /// "Fill" ME methods for string void MonitorElement::Fill(std::string &value) diff --git a/DQMServices/FwkIO/plugins/DQMRootSource.cc b/DQMServices/FwkIO/plugins/DQMRootSource.cc index b16ba6e4620e4..2f9ff41ffc021 100644 --- a/DQMServices/FwkIO/plugins/DQMRootSource.cc +++ b/DQMServices/FwkIO/plugins/DQMRootSource.cc @@ -87,10 +87,13 @@ namespace { iOriginal->GetYaxis()->GetXmax() == iToAdd->GetYaxis()->GetXmax() && iOriginal->GetNbinsZ() == iToAdd->GetNbinsZ() && iOriginal->GetZaxis()->GetXmin() == iToAdd->GetZaxis()->GetXmin() && - iOriginal->GetZaxis()->GetXmax() == iToAdd->GetZaxis()->GetXmax()) { - iOriginal->Add(iToAdd); + iOriginal->GetZaxis()->GetXmax() == iToAdd->GetZaxis()->GetXmax() && + MonitorElement::CheckBinLabels(iOriginal->GetXaxis(),iToAdd->GetXaxis()) && + MonitorElement::CheckBinLabels(iOriginal->GetYaxis(),iToAdd->GetYaxis()) && + MonitorElement::CheckBinLabels(iOriginal->GetZaxis(),iToAdd->GetZaxis())) { + iOriginal->Add(iToAdd); } else { - edm::LogError("MergeFailure")<<"Found histograms with different axis limits '"<GetName()<<"' not merged."; + edm::LogError("MergeFailure")<<"Found histograms with different axis limits or different labels'"<GetName()<<"' not merged."; } } } @@ -158,13 +161,14 @@ namespace { const std::string& name = iElement->getFullname(); if(name.find("EventInfo/processedEvents") != std::string::npos) { iElement->Fill(iValue+iElement->getIntValue()); - } else { - if(name.find("EventInfo/iEvent") != std::string::npos || + } else if(name.find("EventInfo/iEvent") != std::string::npos || name.find("EventInfo/iLumiSection") != std::string::npos) { if(iValue > iElement->getIntValue()) { iElement->Fill(iValue); } - } + } + else { + iElement->Fill(iValue); } } @@ -174,13 +178,15 @@ namespace { return e; } void mergeWithElement(MonitorElement* iElement, double& iValue) { - //no merging + //no merging, take the last one + iElement->Fill(iValue); } MonitorElement* createElement(DQMStore& iStore, const char* iName, std::string* iValue) { return iStore.bookString(iName,*iValue); } - void mergeWithElement(MonitorElement* , std::string* ) { - //no merging + void mergeWithElement(MonitorElement* iElement, std::string* iValue) { + //no merging, take the last one + iElement->Fill(*iValue); } void splitName(const std::string& iFullName, std::string& oPath,const char*& oName) { @@ -257,7 +263,7 @@ namespace { template class TreeSimpleReader : public TreeReaderBase { public: - TreeSimpleReader():m_tree(0),m_fullName(0),m_buffer(),m_tag(0){ + TreeSimpleReader():m_tree(0),m_fullName(0),m_buffer(0),m_tag(0){ } virtual MonitorElement* doRead(ULong64_t iIndex, DQMStore& iStore,bool iIsLumi) { m_tree->GetEntry(iIndex); @@ -393,6 +399,7 @@ class DQMRootSource : public edm::InputSource unsigned int m_filterOnRun; bool m_skipBadFiles; std::vector m_lumisToProcess; + std::vector m_runsToProcess; bool m_justOpenedFileSoNeedToGenerateRunTransition; bool m_shouldReadMEs; @@ -453,6 +460,9 @@ DQMRootSource::DQMRootSource(edm::ParameterSet const& iPSet, const edm::InputSou m_shouldReadMEs(true) { edm::sortAndRemoveOverlaps(m_lumisToProcess); + for(std::vector::const_iterator itr = m_lumisToProcess.begin(); itr!=m_lumisToProcess.end(); ++itr) + m_runsToProcess.push_back(itr->startRun()); + if(m_fileIndex ==m_catalog.fileNames().size()) { m_nextItemType=edm::InputSource::IsStop; } else{ @@ -651,6 +661,8 @@ DQMRootSource::readFile_() { } readNextItemType(); + while (m_presentIndexItr != m_orderedIndices.end() && skipIt(m_runlumiToRange[*m_presentIndexItr].m_run,m_runlumiToRange[*m_presentIndexItr].m_lumi)) + ++m_presentIndexItr; edm::Service jr; m_jrToken = jr->inputFileOpened(m_catalog.fileNames()[m_fileIndex-1], @@ -681,6 +693,9 @@ void DQMRootSource::readElements() { { shouldContinue = false; ++m_presentIndexItr; + while (m_presentIndexItr != m_orderedIndices.end() && skipIt(m_runlumiToRange[*m_presentIndexItr].m_run,m_runlumiToRange[*m_presentIndexItr].m_lumi)) + ++m_presentIndexItr; + if(runLumiRange.m_type == kNoTypesStored) {continue;} boost::shared_ptr reader = m_treeReaders[runLumiRange.m_type]; ULong64_t index = runLumiRange.m_firstIndex; @@ -1028,6 +1043,9 @@ DQMRootSource::setupFile(unsigned int iIndex) bool DQMRootSource::skipIt(edm::RunNumber_t run, edm::LuminosityBlockNumber_t lumi) const { + if(!m_runsToProcess.empty() && edm::search_all(m_runsToProcess, run) && lumi==0) { + return false; + } edm::LuminosityBlockID lumiID = edm::LuminosityBlockID(run, lumi); edm::LuminosityBlockRange lumiRange = edm::LuminosityBlockRange(lumiID, lumiID); bool(*lt)(edm::LuminosityBlockRange const&, edm::LuminosityBlockRange const&) = &edm::lessThan; From 6dc74ccdd66e77db5b25b7b9717e678770e8f3f7 Mon Sep 17 00:00:00 2001 From: Roberta Monge Date: Thu, 2 Oct 2014 16:35:05 +0200 Subject: [PATCH 153/252] changes for phase1 material budget plots --- .../Geometry/test/runP_BeamPipePhase1_cfg.py | 67 +++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 Validation/Geometry/test/runP_BeamPipePhase1_cfg.py diff --git a/Validation/Geometry/test/runP_BeamPipePhase1_cfg.py b/Validation/Geometry/test/runP_BeamPipePhase1_cfg.py new file mode 100644 index 0000000000000..ec34998016e48 --- /dev/null +++ b/Validation/Geometry/test/runP_BeamPipePhase1_cfg.py @@ -0,0 +1,67 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_BeamPipe.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('BEAM'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_BeamPipe.txt" + TextFile = cms.string('None') + ) +)) + + From d8344e3a0cb85460442e1911ebcaa362c07d4dc9 Mon Sep 17 00:00:00 2001 From: Roberta Monge Date: Thu, 2 Oct 2014 16:48:15 +0200 Subject: [PATCH 154/252] changes for phase1 material budget plots --- .../test/runP_InnerServicesPhase1_cfg.py | 69 +++++++++++++++++++ .../Geometry/test/runP_PixBarPhase1_cfg.py | 68 ++++++++++++++++++ .../test/runP_PixFwdPlusPhase1_cfg.py | 68 ++++++++++++++++++ .../Geometry/test/runP_TECPhase1_cfg.py | 68 ++++++++++++++++++ .../Geometry/test/runP_TIBPhase1_cfg.py | 67 ++++++++++++++++++ .../Geometry/test/runP_TIDBPhase1_cfg.py | 67 ++++++++++++++++++ .../Geometry/test/runP_TIDFPhase1_cfg.py | 67 ++++++++++++++++++ .../Geometry/test/runP_TOBPhase1_cfg.py | 67 ++++++++++++++++++ .../Geometry/test/runP_TkStrctPhase1_cfg.py | 68 ++++++++++++++++++ 9 files changed, 609 insertions(+) create mode 100644 Validation/Geometry/test/runP_InnerServicesPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_PixBarPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_PixFwdPlusPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_TECPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_TIBPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_TIDBPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_TIDFPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_TOBPhase1_cfg.py create mode 100644 Validation/Geometry/test/runP_TkStrctPhase1_cfg.py diff --git a/Validation/Geometry/test/runP_InnerServicesPhase1_cfg.py b/Validation/Geometry/test/runP_InnerServicesPhase1_cfg.py new file mode 100644 index 0000000000000..8ec90a6bebff6 --- /dev/null +++ b/Validation/Geometry/test/runP_InnerServicesPhase1_cfg.py @@ -0,0 +1,69 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_InnerServices.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('TIBTIDServicesF', + 'TIBTIDServicesB'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_InnerServices.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_PixBarPhase1_cfg.py b/Validation/Geometry/test/runP_PixBarPhase1_cfg.py new file mode 100644 index 0000000000000..1078d6df18474 --- /dev/null +++ b/Validation/Geometry/test/runP_PixBarPhase1_cfg.py @@ -0,0 +1,68 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_PixBar.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('PixelBarrel'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_PixBar.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_PixFwdPlusPhase1_cfg.py b/Validation/Geometry/test/runP_PixFwdPlusPhase1_cfg.py new file mode 100644 index 0000000000000..faa7ab8cf22b2 --- /dev/null +++ b/Validation/Geometry/test/runP_PixFwdPlusPhase1_cfg.py @@ -0,0 +1,68 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_PixFwdPlus.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('PixelForwardZPlus'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_PixFwdPlus.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_TECPhase1_cfg.py b/Validation/Geometry/test/runP_TECPhase1_cfg.py new file mode 100644 index 0000000000000..bba806f81fb4a --- /dev/null +++ b/Validation/Geometry/test/runP_TECPhase1_cfg.py @@ -0,0 +1,68 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_TEC.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('TEC'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_TEC.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_TIBPhase1_cfg.py b/Validation/Geometry/test/runP_TIBPhase1_cfg.py new file mode 100644 index 0000000000000..88aa121c7b0b2 --- /dev/null +++ b/Validation/Geometry/test/runP_TIBPhase1_cfg.py @@ -0,0 +1,67 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_TIB.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('TIB'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_TIB.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_TIDBPhase1_cfg.py b/Validation/Geometry/test/runP_TIDBPhase1_cfg.py new file mode 100644 index 0000000000000..ab2a636fee71e --- /dev/null +++ b/Validation/Geometry/test/runP_TIDBPhase1_cfg.py @@ -0,0 +1,67 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_TIDB.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('TIDB'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_TIDB.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_TIDFPhase1_cfg.py b/Validation/Geometry/test/runP_TIDFPhase1_cfg.py new file mode 100644 index 0000000000000..9635e80bccfa3 --- /dev/null +++ b/Validation/Geometry/test/runP_TIDFPhase1_cfg.py @@ -0,0 +1,67 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_TIDF.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('TIDF'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_TIDF.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_TOBPhase1_cfg.py b/Validation/Geometry/test/runP_TOBPhase1_cfg.py new file mode 100644 index 0000000000000..c5bb5647ea4af --- /dev/null +++ b/Validation/Geometry/test/runP_TOBPhase1_cfg.py @@ -0,0 +1,67 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_TOB.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('TOB'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_TOB.txt" + TextFile = cms.string('None') + ) +)) + + diff --git a/Validation/Geometry/test/runP_TkStrctPhase1_cfg.py b/Validation/Geometry/test/runP_TkStrctPhase1_cfg.py new file mode 100644 index 0000000000000..4b87178e53546 --- /dev/null +++ b/Validation/Geometry/test/runP_TkStrctPhase1_cfg.py @@ -0,0 +1,68 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_TkStrct.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('TrackerOuterCylinder', + 'TrackerBulkhead'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_TkStrct.txt" + TextFile = cms.string('None') + ) +)) + + From 89ac0001e579ead2e053dc44d8a8ccb2f36a5876 Mon Sep 17 00:00:00 2001 From: Roberta Monge Date: Thu, 2 Oct 2014 17:14:18 +0200 Subject: [PATCH 155/252] changes for phase1 material budget plots --- .../test/runP_PixFwdMinusPhase1_cfg.py | 68 +++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 Validation/Geometry/test/runP_PixFwdMinusPhase1_cfg.py diff --git a/Validation/Geometry/test/runP_PixFwdMinusPhase1_cfg.py b/Validation/Geometry/test/runP_PixFwdMinusPhase1_cfg.py new file mode 100644 index 0000000000000..fe1c3fffb8a2a --- /dev/null +++ b/Validation/Geometry/test/runP_PixFwdMinusPhase1_cfg.py @@ -0,0 +1,68 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load("Configuration.Geometry.GeometryExtended2017_cff") + + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_PostLS1_cff") + +# Output of events, etc... +# +# Explicit note : since some histos/tree might be dumped directly, +# better NOT use PoolOutputModule ! +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted + limit = cms.untracked.int32(-1) + ) + ), + categories = cms.untracked.vstring('FwkJob'), + destinations = cms.untracked.vstring('cout') +) + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + type = cms.string('MaterialBudgetAction'), + MaterialBudgetAction = cms.PSet( + HistosFile = cms.string('matbdg_PixFwdMinus.root'), + AllStepsToTree = cms.bool(True), + HistogramList = cms.string('Tracker'), + SelectedVolumes = cms.vstring('PixelForwardZMinus'), + TreeFile = cms.string('None'), ## is NOT requested + + StopAfterProcess = cms.string('None'), + # string TextFile = "matbdg_PixFwdMinus.txt" + TextFile = cms.string('None') + ) +)) + + From a984930ffeb4afcf49ddffd072882610f6581893 Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Fri, 3 Oct 2014 13:15:30 +0200 Subject: [PATCH 156/252] Add an extra check that histogram minimum is less than maximum when merging --- DataFormats/Histograms/interface/MEtoEDMFormat.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/DataFormats/Histograms/interface/MEtoEDMFormat.h b/DataFormats/Histograms/interface/MEtoEDMFormat.h index 28277b481ba66..b376a94fee45e 100644 --- a/DataFormats/Histograms/interface/MEtoEDMFormat.h +++ b/DataFormats/Histograms/interface/MEtoEDMFormat.h @@ -113,10 +113,15 @@ class MEtoEDM MEtoEdmObject[j].object.GetYaxis()->GetXmax() == newMEtoEDMObject[i].object.GetYaxis()->GetXmax() && MEtoEdmObject[j].object.GetNbinsZ() == newMEtoEDMObject[i].object.GetNbinsZ() && MEtoEdmObject[j].object.GetZaxis()->GetXmin() == newMEtoEDMObject[i].object.GetZaxis()->GetXmin() && - MEtoEdmObject[j].object.GetZaxis()->GetXmax() == newMEtoEDMObject[i].object.GetZaxis()->GetXmax()) { + MEtoEdmObject[j].object.GetZaxis()->GetXmax() == newMEtoEDMObject[i].object.GetZaxis()->GetXmax() && + // Also check that the min is less than the max. Root allows this to be booked but then + // crashes when it adds them. + (MEtoEdmObject[j].object.GetXaxis()->GetXmin() < MEtoEdmObject[j].object.GetXaxis()->GetXmax()) && + (MEtoEdmObject[j].object.GetYaxis()->GetXmin() < MEtoEdmObject[j].object.GetYaxis()->GetXmax()) && + (MEtoEdmObject[j].object.GetZaxis()->GetXmin() < MEtoEdmObject[j].object.GetZaxis()->GetXmax())) { MEtoEdmObject[j].object.Add(&newMEtoEDMObject[i].object); } else { - std::cout << "ERROR MEtoEDM::mergeProducts(): found histograms with different axis limits, '" << name << "' not merged" << std::endl; + std::cout << "ERROR MEtoEDM::mergeProducts(): found histograms with different or invalid axis limits, '" << name << "' not merged" << std::endl; #if debug std::cout << MEtoEdmObject[j].name << " " << newMEtoEDMObject[i].name << std::endl; std::cout << MEtoEdmObject[j].object.GetNbinsX() << " " << newMEtoEDMObject[i].object.GetNbinsX() << std::endl; From 5f24da3902e86809bbe64302a33d49d724e44b3d Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Fri, 3 Oct 2014 13:34:41 +0200 Subject: [PATCH 157/252] Convert some tabs to spaces to preserve formatting style --- DataFormats/Histograms/interface/MEtoEDMFormat.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DataFormats/Histograms/interface/MEtoEDMFormat.h b/DataFormats/Histograms/interface/MEtoEDMFormat.h index b376a94fee45e..b4d9d6e4649aa 100644 --- a/DataFormats/Histograms/interface/MEtoEDMFormat.h +++ b/DataFormats/Histograms/interface/MEtoEDMFormat.h @@ -114,8 +114,8 @@ class MEtoEDM MEtoEdmObject[j].object.GetNbinsZ() == newMEtoEDMObject[i].object.GetNbinsZ() && MEtoEdmObject[j].object.GetZaxis()->GetXmin() == newMEtoEDMObject[i].object.GetZaxis()->GetXmin() && MEtoEdmObject[j].object.GetZaxis()->GetXmax() == newMEtoEDMObject[i].object.GetZaxis()->GetXmax() && - // Also check that the min is less than the max. Root allows this to be booked but then - // crashes when it adds them. + // Also check that the min is less than the max. Root allows this to be booked but then + // crashes when it adds them. (MEtoEdmObject[j].object.GetXaxis()->GetXmin() < MEtoEdmObject[j].object.GetXaxis()->GetXmax()) && (MEtoEdmObject[j].object.GetYaxis()->GetXmin() < MEtoEdmObject[j].object.GetYaxis()->GetXmax()) && (MEtoEdmObject[j].object.GetZaxis()->GetXmin() < MEtoEdmObject[j].object.GetZaxis()->GetXmax())) { From 52fff5b69c39f6928e06d8ec17107e64a9f12f92 Mon Sep 17 00:00:00 2001 From: federico de guio Date: Fri, 3 Oct 2014 18:42:08 +0200 Subject: [PATCH 158/252] temporary fix to a failure when merging histograms --- DQMServices/FwkIO/plugins/DQMRootSource.cc | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/DQMServices/FwkIO/plugins/DQMRootSource.cc b/DQMServices/FwkIO/plugins/DQMRootSource.cc index 2f9ff41ffc021..d5ea9105852c7 100644 --- a/DQMServices/FwkIO/plugins/DQMRootSource.cc +++ b/DQMServices/FwkIO/plugins/DQMRootSource.cc @@ -88,12 +88,17 @@ namespace { iOriginal->GetNbinsZ() == iToAdd->GetNbinsZ() && iOriginal->GetZaxis()->GetXmin() == iToAdd->GetZaxis()->GetXmin() && iOriginal->GetZaxis()->GetXmax() == iToAdd->GetZaxis()->GetXmax() && + // Also check that the min is less than the max. Root allows this to be booked but then + // crashes when it adds them. + iOriginal->GetXaxis()->GetXmin() < iToAdd->GetXaxis()->GetXmax() && + iOriginal->GetYaxis()->GetXmin() < iToAdd->GetYaxis()->GetXmax() && + iOriginal->GetZaxis()->GetXmin() < iToAdd->GetZaxis()->GetXmax() && MonitorElement::CheckBinLabels(iOriginal->GetXaxis(),iToAdd->GetXaxis()) && MonitorElement::CheckBinLabels(iOriginal->GetYaxis(),iToAdd->GetYaxis()) && MonitorElement::CheckBinLabels(iOriginal->GetZaxis(),iToAdd->GetZaxis())) { iOriginal->Add(iToAdd); } else { - edm::LogError("MergeFailure")<<"Found histograms with different axis limits or different labels'"<GetName()<<"' not merged."; + edm::LogError("MergeFailure")<<"Found histograms with different or invalid axis limits or different labels'"<GetName()<<"' not merged."; } } } From 4b795c4b30f009acdc25e07123c9f12986dfb27c Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Fri, 26 Sep 2014 09:42:55 +0200 Subject: [PATCH 159/252] add cleaning for pathlogical shashlik reco --- .../interface/PFRecHitQTests.h | 57 +++++++++++++++++++ .../python/particleFlowRecHitShashlik_cfi.py | 7 ++- .../src/RecHitQualityTests.cc | 1 + 3 files changed, 64 insertions(+), 1 deletion(-) diff --git a/RecoParticleFlow/PFClusterProducer/interface/PFRecHitQTests.h b/RecoParticleFlow/PFClusterProducer/interface/PFRecHitQTests.h index 8ab3909c13c06..19f0eae9e503c 100644 --- a/RecoParticleFlow/PFClusterProducer/interface/PFRecHitQTests.h +++ b/RecoParticleFlow/PFClusterProducer/interface/PFRecHitQTests.h @@ -573,6 +573,63 @@ class PFRecHitQTestHCALCalib29 : public PFRecHitQTestBase { float calibFactor_; }; +// +// Quality test to clean Shashlik rechits with bad timing reco +// +class PFRecHitQTestShashlikTiming : public PFRecHitQTestBase { + public: + PFRecHitQTestShashlikTiming() { + + } + + PFRecHitQTestShashlikTiming(const edm::ParameterSet& iConfig): + PFRecHitQTestBase(iConfig) + { + badTimingEThreshold_ =iConfig.getParameter("BadTimingEThreshold"); + useSafetyCuts_ = iConfig.getParameter("UseSafetyCuts"); + } + + void beginEvent(const edm::Event& event,const edm::EventSetup& iSetup) { + } + + bool test(reco::PFRecHit& hit,const EcalRecHit& rh,bool& cleanit) { + if( useSafetyCuts_ && + ( rh.timeError() < 1e5 || !rh.isTimeValid() || + rh.isTimeErrorValid() ) ) { + // never clean safe rechits + return true; + } + const bool toclean = ( std::abs(rh.time()+2.112) < 1e-5 && + rh.energy() < badTimingEThreshold_ ); + cleanit *= toclean; + return !toclean; // should return + } + bool test(reco::PFRecHit& hit,const HBHERecHit& rh,bool& clean) { + return true; + + } + + bool test(reco::PFRecHit& hit,const HFRecHit& rh,bool& clean) { + return true; + + } + bool test(reco::PFRecHit& hit,const HORecHit& rh,bool& clean) { + return true; + } + + bool test(reco::PFRecHit& hit,const CaloTower& rh,bool& clean) { + return true; + + } + + bool test(reco::PFRecHit& hit,const HGCRecHit& rh,bool& clean) { + return true; + } + + protected: + float badTimingEThreshold_; + bool useSafetyCuts_; +}; #endif diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py index 90f8dfbeae7cd..7a7d90a2d96bc 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py @@ -19,7 +19,12 @@ name = cms.string("PFRecHitQTestThreshold"), threshold = cms.double(0.08) ), - ) + cms.PSet( + name = cms.string("PFRecHitQTestShashlikTiming"), + UseSafetyCuts = cms.bool(True), + BadTimingEThreshold = cms.double(0.250) + ) + ) ) ) ) diff --git a/RecoParticleFlow/PFClusterProducer/src/RecHitQualityTests.cc b/RecoParticleFlow/PFClusterProducer/src/RecHitQualityTests.cc index e97cffd4bf99e..0b8f829752f1f 100644 --- a/RecoParticleFlow/PFClusterProducer/src/RecHitQualityTests.cc +++ b/RecoParticleFlow/PFClusterProducer/src/RecHitQualityTests.cc @@ -13,4 +13,5 @@ DEFINE_EDM_PLUGIN(PFRecHitQTestFactory, PFRecHitQTestHCALCalib29, "PFRecHitQTest DEFINE_EDM_PLUGIN(PFRecHitQTestFactory, PFRecHitQTestHCALChannel, "PFRecHitQTestHCALChannel"); DEFINE_EDM_PLUGIN(PFRecHitQTestFactory, PFRecHitQTestHCALTimeVsDepth, "PFRecHitQTestHCALTimeVsDepth"); DEFINE_EDM_PLUGIN(PFRecHitQTestFactory, PFRecHitQTestHCALThresholdVsDepth, "PFRecHitQTestHCALThresholdVsDepth"); +DEFINE_EDM_PLUGIN(PFRecHitQTestFactory, PFRecHitQTestShashlikTiming, "PFRecHitQTestShashlikTiming"); From 2c4777032f62b67d74029c70d15583cf6fb2b0f3 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Sun, 28 Sep 2014 00:39:37 +0200 Subject: [PATCH 160/252] use the correct PFRecHit navigator for shashlik --- .../python/particleFlowRecHitShashlik_cfi.py | 9 ++++++++- .../PFClusterProducer/src/Navigators.cc | 16 ++++++++++++++++ .../Configuration/python/combinedCustoms.py | 13 ++++++++----- 3 files changed, 32 insertions(+), 6 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py index 7a7d90a2d96bc..2ece842e14b70 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py @@ -1,12 +1,19 @@ import FWCore.ParameterSet.Config as cms +#for now Shashlik uses EE timing +from particleFlowClusterECALTimeResolutionParameters_cfi import _timeResolutionECALEndcap #until we are actually clustering across the EB/EE boundary #it is faster to cluster EB and EE as separate particleFlowRecHitEK = cms.EDProducer("PFRecHitProducer", navigator = cms.PSet( - name = cms.string("PFRecHitShashlikNavigator"), + name = cms.string("PFRecHitShashlikNavigatorWithTime"), + noiseLevel = cms.double(0.14), + noiseTerm = cms.double(36.1), + constantTerm = cms.double(10), + sigmaCut = cms.double(5.0), + timeResolutionCalc = _timeResolutionECALEndcap, barrel = cms.PSet( ), endcap = cms.PSet( ) ), diff --git a/RecoParticleFlow/PFClusterProducer/src/Navigators.cc b/RecoParticleFlow/PFClusterProducer/src/Navigators.cc index 0cd4a5cf29979..3e10ebdc01469 100644 --- a/RecoParticleFlow/PFClusterProducer/src/Navigators.cc +++ b/RecoParticleFlow/PFClusterProducer/src/Navigators.cc @@ -152,6 +152,21 @@ class PFRecHitShashlikNavigator : public PFRecHitCaloNavigator { + public: + PFRecHitShashlikNavigatorWithTime(const edm::ParameterSet& iConfig): + PFRecHitCaloNavigatorWithTime(iConfig) + { + + } + + void beginEvent(const edm::EventSetup& iSetup) { + edm::ESHandle topoHandle; + iSetup.get().get(topoHandle); + topology_.release(); + topology_.reset( topoHandle.product() ); + } +}; typedef PFRecHitDualNavigator Date: Mon, 29 Sep 2014 18:28:38 +0200 Subject: [PATCH 161/252] use measurements from Sasha for Shashlik timing cuts --- ...ticleFlowClusterECALTimeResolutionParameters_cfi.py | 10 ++++++++++ .../python/particleFlowClusterShashlik_cfi.py | 4 ++-- .../python/particleFlowRecHitShashlik_cfi.py | 6 +++--- 3 files changed, 15 insertions(+), 5 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py index ace084a52fd9a..200e20e4c60af 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py @@ -20,3 +20,13 @@ threshLowE = cms.double(1.), threshHighE = cms.double(10.) ) + +_timeResolutionShashlikEndcap = cms.PSet( + noiseTerm = cms.double(36.1 * 0.027), + constantTerm = cms.double(0.), + noiseTermLowE = cms.double(42.96 * 0.027), + corrTermLowE = cms.double(0.), + constantTermLowE = cms.double(0.), + threshLowE = cms.double(1.), + threshHighE = cms.double(10.) + ) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py index fcee02f355398..6e091f4ce1734 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py @@ -2,7 +2,7 @@ #### PF CLUSTER SHASHLIK #### -from particleFlowClusterECALTimeResolutionParameters_cfi import _timeResolutionECALBarrel, _timeResolutionECALEndcap +from particleFlowClusterECALTimeResolutionParameters_cfi import _timeResolutionECALBarrel, _timeResolutionShashlikEndcap #cleaning ## no cleaning for Shashlik yet @@ -83,7 +83,7 @@ ), #can use ECAL timing here since Shashlik is forced to be the same as EE timeResolutionCalcBarrel = _timeResolutionECALBarrel, - timeResolutionCalcEndcap = _timeResolutionECALEndcap + timeResolutionCalcEndcap = _timeResolutionShashlikEndcap ) particleFlowClusterEKUncorrected = cms.EDProducer( diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py index 2ece842e14b70..cbb226b879cb4 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py @@ -2,18 +2,18 @@ import FWCore.ParameterSet.Config as cms #for now Shashlik uses EE timing -from particleFlowClusterECALTimeResolutionParameters_cfi import _timeResolutionECALEndcap +from particleFlowClusterECALTimeResolutionParameters_cfi import _timeResolutionShashlikEndcap #until we are actually clustering across the EB/EE boundary #it is faster to cluster EB and EE as separate particleFlowRecHitEK = cms.EDProducer("PFRecHitProducer", navigator = cms.PSet( name = cms.string("PFRecHitShashlikNavigatorWithTime"), - noiseLevel = cms.double(0.14), + noiseLevel = cms.double(0.027), noiseTerm = cms.double(36.1), constantTerm = cms.double(10), sigmaCut = cms.double(5.0), - timeResolutionCalc = _timeResolutionECALEndcap, + timeResolutionCalc = _timeResolutionShashlikEndcap, barrel = cms.PSet( ), endcap = cms.PSet( ) ), From 5e5673397aa98b7d36cb3801f96a98befb5e008f Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Tue, 30 Sep 2014 11:14:10 +0200 Subject: [PATCH 162/252] add conservative constant term to shashlik timing model --- .../particleFlowClusterECALTimeResolutionParameters_cfi.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py index 200e20e4c60af..712d1c468f162 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterECALTimeResolutionParameters_cfi.py @@ -23,10 +23,10 @@ _timeResolutionShashlikEndcap = cms.PSet( noiseTerm = cms.double(36.1 * 0.027), - constantTerm = cms.double(0.), + constantTerm = cms.double(0.2), noiseTermLowE = cms.double(42.96 * 0.027), corrTermLowE = cms.double(0.), - constantTermLowE = cms.double(0.), + constantTermLowE = cms.double(0.2), threshLowE = cms.double(1.), threshHighE = cms.double(10.) ) From ecd615fd8bf6abbb05d16d467f5e1a8d7877b43b Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 5 Sep 2014 12:23:56 +0200 Subject: [PATCH 163/252] Changed Scenario 3 cuts --- ...lowClusterHBHEMaxSampleTimeSelected_cfi.py | 203 +++++++ .../python/tools/pfClusteringCustoms.py | 499 ++++++++++++++++++ 2 files changed, 702 insertions(+) create mode 100644 RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHEMaxSampleTimeSelected_cfi.py create mode 100644 RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHEMaxSampleTimeSelected_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHEMaxSampleTimeSelected_cfi.py new file mode 100644 index 0000000000000..ef4b82ad8767e --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHEMaxSampleTimeSelected_cfi.py @@ -0,0 +1,203 @@ +import FWCore.ParameterSet.Config as cms +particleFlowClusterHBHETimeSelected = cms.EDProducer( + "PFClusterTimeSelector", + src = cms.InputTag('particleFlowClusterHBHE'), + + cuts = cms.VPSet( + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(0.0), + maxEnergy = cms.double(1.0), + endcap = cms.bool(False), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(0.0), + maxEnergy = cms.double(1.0), + endcap = cms.bool(True), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(0.0), + maxEnergy = cms.double(1.0), + endcap = cms.bool(False), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(0.0), + maxEnergy = cms.double(1.0), + endcap = cms.bool(True), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(0.0), + maxEnergy = cms.double(1.0), + endcap = cms.bool(False), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(0.0), + maxEnergy = cms.double(1.0), + endcap = cms.bool(True), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(1.0), + maxEnergy = cms.double(2.0), + endcap = cms.bool(False), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(1.0), + maxEnergy = cms.double(2.0), + endcap = cms.bool(True), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(1.0), + maxEnergy = cms.double(2.0), + endcap = cms.bool(False), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(1.0), + maxEnergy = cms.double(2.0), + endcap = cms.bool(True), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(1.0), + maxEnergy = cms.double(2.0), + endcap = cms.bool(False), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(1.0), + maxEnergy = cms.double(2.0), + endcap = cms.bool(True), + minTime = cms.double(-30.), + maxTime = cms.double(50.) + ), + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(2.), + maxEnergy = cms.double(5.0), + endcap = cms.bool(False), + minTime = cms.double(-5.), + maxTime = cms.double(40.) + ), + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(2.0), + maxEnergy = cms.double(5.0), + endcap = cms.bool(True), + minTime = cms.double(-5.), + maxTime = cms.double(40.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(2.), + maxEnergy = cms.double(5.0), + endcap = cms.bool(False), + minTime = cms.double(-5.), + maxTime = cms.double(40.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(2.0), + maxEnergy = cms.double(5.0), + endcap = cms.bool(True), + minTime = cms.double(-5.), + maxTime = cms.double(40.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(2.), + maxEnergy = cms.double(5.0), + endcap = cms.bool(False), + minTime = cms.double(-5.), + maxTime = cms.double(40.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(2.0), + maxEnergy = cms.double(5.0), + endcap = cms.bool(True), + minTime = cms.double(-5.), + maxTime = cms.double(40.) + ), + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(5.), + maxEnergy = cms.double(9999999.), + endcap = cms.bool(False), + minTime = cms.double(0.), + maxTime = cms.double(25.) + ), + cms.PSet( + depth=cms.double(1.0), + minEnergy = cms.double(5.0), + maxEnergy = cms.double(9999999.), + endcap = cms.bool(True), + minTime = cms.double(0.), + maxTime = cms.double(25.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(5.), + maxEnergy = cms.double(9999999.), + endcap = cms.bool(False), + minTime = cms.double(0.), + maxTime = cms.double(25.) + ), + cms.PSet( + depth=cms.double(2.0), + minEnergy = cms.double(5.0), + maxEnergy = cms.double(9999999.), + endcap = cms.bool(True), + minTime = cms.double(0.), + maxTime = cms.double(25.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(5.), + maxEnergy = cms.double(9999999.), + endcap = cms.bool(False), + minTime = cms.double(0.), + maxTime = cms.double(25.) + ), + cms.PSet( + depth=cms.double(3.0), + minEnergy = cms.double(5.0), + maxEnergy = cms.double(9999999.), + endcap = cms.bool(True), + minTime = cms.double(0.), + maxTime = cms.double(25.) + ) + + ) +) + + diff --git a/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py b/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py new file mode 100644 index 0000000000000..59fd50ac87d86 --- /dev/null +++ b/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py @@ -0,0 +1,499 @@ + +import FWCore.ParameterSet.Config as cms + + +def customizePFECALClustering(process,scenario): + + if scenario ==1: + print '-------------ECAL CLUSTERING-------------' + print 'SCENARIO 1: Default ECAL clustering & ECAL time reconstruction' + print 'Timing cuts are applied to the PF cluster level' + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterECALTimeSelected_cfi') + process.particleFlowClusterECALTimeSelected.src = cms.InputTag('particleFlowClusterECALUncorrected') + process.particleFlowClusterECAL.inputECAL = cms.InputTag('particleFlowClusterECALTimeSelected') + i = process.pfClusteringECAL.index(process.particleFlowClusterECALUncorrected) + process.pfClusteringECAL.insert(i+1,process.particleFlowClusterECALTimeSelected) + + elif scenario ==2: + print '-------------ECAL CLUSTERING-------------' + print 'SCENARIO 2: ECAL clustering with time & default ECAL time reconstruction' + print 'Timing cuts are applied to the PF cluster level' + + from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionECALBarrel,_timeResolutionECALEndcap + + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterECALTimeSelected_cfi') + + process.particleFlowRecHitECAL.navigator.name = "PFRecHitECALNavigatorWithTime" + process.particleFlowRecHitECAL.navigator.barrel = cms.PSet( + sigmaCut = cms.double(5.0), + timeResolutionCalc = _timeResolutionECALBarrel + ) + process.particleFlowRecHitECAL.navigator.endcap = cms.PSet( + sigmaCut = cms.double(5.0), + timeResolutionCalc = _timeResolutionECALEndcap + ) + + for p in process.particleFlowRecHitECAL.producers: + for t in p.qualityTests: + if t.name == 'PFRecHitQTestECAL': + t.timingCleaning = cms.bool(False) + + process.particleFlowClusterECALUncorrected.recHitsSource = cms.InputTag("particleFlowRecHitECAL") + process.particleFlowClusterECALTimeSelected.src = cms.InputTag('particleFlowClusterECALUncorrected') + process.particleFlowClusterECAL.inputECAL = cms.InputTag('particleFlowClusterECALTimeSelected') + + i = process.pfClusteringECAL.index(process.particleFlowClusterECALUncorrected) + process.pfClusteringECAL.insert(i+1,process.particleFlowClusterECALTimeSelected) + process.particleFlowClusterECALUncorrected.pfClusterBuilder.algoName = cms.string("PFlow2DClusterizerWithTime") + + process.particleFlowClusterECALUncorrected.pfClusterBuilder.showerSigma = cms.double(1.5) + process.particleFlowClusterECALUncorrected.pfClusterBuilder.timeSigmaEB = cms.double(10.) + process.particleFlowClusterECALUncorrected.pfClusterBuilder.timeSigmaEE = cms.double(10.) + process.particleFlowClusterECALUncorrected.pfClusterBuilder.maxNSigmaTime = cms.double(10.) + process.particleFlowClusterECALUncorrected.pfClusterBuilder.minChi2Prob = cms.double(0.) + process.particleFlowClusterECALUncorrected.pfClusterBuilder.clusterTimeResFromSeed = cms.bool(False) + process.particleFlowClusterECALUncorrected.pfClusterBuilder.timeResolutionCalcBarrel = _timeResolutionECALBarrel + process.particleFlowClusterECALUncorrected.pfClusterBuilder.timeResolutionCalcEndcap = _timeResolutionECALEndcap + + + + +def customizePFHCALClustering(process,scenario,data = False): + + if scenario ==0: + print '-------------HCAL CLUSTERING-------------' + print 'SCENARIO 0: HCAL clustering from hits+old HCAL time reconstruction' + print 'Timing cuts are N OTapplied' + if not data: + print 'You are trying to run on MC, if not set data to True' + else: + print 'You are trying to run on data, if not set data to False' + + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHETimeSelected_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') + + process.pfClusteringHBHEHF.remove(process.towerMakerPF) + process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) + + process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE + process.pfClusteringHBHEHF+=process.particleFlowRecHitHF + process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE + process.pfClusteringHBHEHF+=process.particleFlowClusterHF + + + process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', + clustersSource = cms.InputTag("particleFlowClusterHBHE"), + pfClusterBuilder =cms.PSet( + algoName = cms.string("PFMultiDepthClusterizer"), + nSigmaEta = cms.double(2.), + nSigmaPhi = cms.double(2.), + #pf clustering parameters + minFractionToKeep = cms.double(1e-7), + allCellsPositionCalc = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(-1), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) + ) + ), + positionReCalc = cms.PSet( + ), + energyCorrector = cms.PSet() + ) + + process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL + + process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) + + ##customize block since we have only one HF cluster collection now + importers = process.particleFlowBlock.elementImporters + newImporters = cms.VPSet() + + for pset in importers: + if pset.importerName =="GenericClusterImporter": + + if pset.source.moduleLabel == 'particleFlowClusterHFEM': + pset.source = cms.InputTag('particleFlowClusterHF') + newImporters.append(pset) + elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': + newImporters.append(pset) + else: + newImporters.append(pset) + + + process.particleFlowBlock.elementImporters = newImporters + + + for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: + if norm.detector.value() == 'HCAL_BARREL1': + norm.seedingThreshold = 0.80 + if norm.detector.value() == 'HCAL_ENDCAP': + norm.seedingThreshold = 0.80 + + + + # Enable OOT pileup corrections for HBHE in MC processing + process.hbheprereco.mcOOTCorrectionName = cms.string("HBHE") + + # Uncomment next line to enable OOT pileup corrections in data processing + if data: + process.hbheprereco.dataOOTCorrectionName = cms.string("HBHE") + + # Configure database access for the OOT pileup corrections + import os + process.load("CondCore.CondDB.CondDBboost_cfi") + process.CondDBboost.connect = "sqlite_file:%s/src/CondTools/Hcal/data/testOOTPileupCorrection.db" % os.environ["CMSSW_RELEASE_BASE"] + + process.PoolDBESSource = cms.ESSource("PoolDBESSource", + process.CondDBboost, + toGet = cms.VPSet(cms.PSet( + record = cms.string("HcalOOTPileupCorrectionRcd"), + tag = cms.string("test") + ) + ) + ) + + + + if scenario ==1: + print '-------------HCAL CLUSTERING-------------' + print 'SCENARIO 1: HCAL clustering from hits' + print 'Timing cuts are applied' + if not data: + print 'You are trying to run on MC, if not set data to True' + else: + print 'You are trying to run on data, if not set data to False' + + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHETimeSelected_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') + + process.pfClusteringHBHEHF.remove(process.towerMakerPF) + process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) + + process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE + process.pfClusteringHBHEHF+=process.particleFlowRecHitHF + process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE +# process.pfClusteringHBHEHF+=process.particleFlowClusterHBHETimeSelected + process.pfClusteringHBHEHF+=process.particleFlowClusterHF + + + process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', + clustersSource = cms.InputTag("particleFlowClusterHBHE"), + pfClusterBuilder =cms.PSet( + algoName = cms.string("PFMultiDepthClusterizer"), + nSigmaEta = cms.double(2.), + nSigmaPhi = cms.double(2.), + #pf clustering parameters + minFractionToKeep = cms.double(1e-7), + allCellsPositionCalc = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(-1), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) + ) + ), + positionReCalc = cms.PSet( + ), + energyCorrector = cms.PSet() + ) + + process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL + + process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) + + ##customize block since we have only one HF cluster collection now + importers = process.particleFlowBlock.elementImporters + newImporters = cms.VPSet() + + for pset in importers: + if pset.importerName =="GenericClusterImporter": + + if pset.source.moduleLabel == 'particleFlowClusterHFEM': + pset.source = cms.InputTag('particleFlowClusterHF') + newImporters.append(pset) + elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': + newImporters.append(pset) + else: + newImporters.append(pset) + + + process.particleFlowBlock.elementImporters = newImporters + + + for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: + if norm.detector.value() == 'HCAL_BARREL1': + norm.seedingThreshold = 0.80 + if norm.detector.value() == 'HCAL_ENDCAP': + norm.seedingThreshold = 0.80 + + + + # Enable OOT pileup corrections for HBHE in MC processing + process.hbheprereco.mcOOTCorrectionName = cms.string("HBHE") + + # Uncomment next line to enable OOT pileup corrections in data processing + if data: + process.hbheprereco.dataOOTCorrectionName = cms.string("HBHE") + + # Configure database access for the OOT pileup corrections + import os + process.load("CondCore.CondDB.CondDBboost_cfi") + process.CondDBboost.connect = "sqlite_file:%s/src/CondTools/Hcal/data/testOOTPileupCorrection.db" % os.environ["CMSSW_RELEASE_BASE"] + + process.PoolDBESSource = cms.ESSource("PoolDBESSource", + process.CondDBboost, + toGet = cms.VPSet(cms.PSet( + record = cms.string("HcalOOTPileupCorrectionRcd"), + tag = cms.string("test") + ) + ) + ) + + + if scenario ==2: + print '-------------HCAL CLUSTERING-------------' + print 'SCENARIO 2: HCAL clustering from hits +3D clustering with time ' + print 'Timing cuts are applied' + if not data: + print 'You are trying to run on MC, if not set data to True' + else: + print 'You are trying to run on data, if not set data to False' + + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHETimeSelected_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') + + from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCAL + + + process.pfClusteringHBHEHF.remove(process.towerMakerPF) + process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) + + process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE + process.pfClusteringHBHEHF+=process.particleFlowRecHitHF + process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE + process.pfClusteringHBHEHF+=process.particleFlowClusterHBHETimeSelected + process.pfClusteringHBHEHF+=process.particleFlowClusterHF + + + process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', + clustersSource = cms.InputTag("particleFlowClusterHBHETimeSelected"), + pfClusterBuilder =cms.PSet( + algoName = cms.string("PFMultiDepthClusterizer"), + nSigmaEta = cms.double(2.), + nSigmaPhi = cms.double(2.), + #pf clustering parameters + minFractionToKeep = cms.double(1e-7), + allCellsPositionCalc = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(-1), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) + ) + ), + positionReCalc = cms.PSet( + ), + energyCorrector = cms.PSet() + ) + + process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL + + ##customize block since we have only one HF cluster collection now + importers = process.particleFlowBlock.elementImporters + newImporters = cms.VPSet() + + for pset in importers: + if pset.importerName =="GenericClusterImporter": + + if pset.source.moduleLabel == 'particleFlowClusterHFEM': + pset.source = cms.InputTag('particleFlowClusterHF') + newImporters.append(pset) + elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': + newImporters.append(pset) + else: + newImporters.append(pset) + + + process.particleFlowBlock.elementImporters = newImporters + + + + + for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: + if norm.detector.value() == 'HCAL_BARREL1': + norm.seedingThreshold = 0.80 + if norm.detector.value() == 'HCAL_ENDCAP': + norm.seedingThreshold = 0.80 + + + + # Enable OOT pileup corrections for HBHE in MC processing + process.hbheprereco.mcOOTCorrectionName = cms.string("HBHE") + + # Uncomment next line to enable OOT pileup corrections in data processing + if data: + process.hbheprereco.dataOOTCorrectionName = cms.string("HBHE") + + # Configure database access for the OOT pileup corrections + import os + process.load("CondCore.CondDB.CondDBboost_cfi") + process.CondDBboost.connect = "sqlite_file:%s/src/CondTools/Hcal/data/testOOTPileupCorrection.db" % os.environ["CMSSW_RELEASE_BASE"] + + process.PoolDBESSource = cms.ESSource("PoolDBESSource", + process.CondDBboost, + toGet = cms.VPSet(cms.PSet( + record = cms.string("HcalOOTPileupCorrectionRcd"), + tag = cms.string("test") + ) + ) + ) + + process.particleFlowRecHitHBHE.navigator = cms.PSet( + name = cms.string("PFRecHitHCALNavigatorWithTime"), + sigmaCut = cms.double(5.0), + timeResolutionCalc = _timeResolutionHCAL + ) + process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEB = cms.double(10.) + process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEE = cms.double(10.) + process.particleFlowClusterHBHE.pfClusterBuilder.maxNSigmaTime = cms.double(10.) + process.particleFlowClusterHBHE.pfClusterBuilder.minChi2Prob = cms.double(0.) + process.particleFlowClusterHBHE.pfClusterBuilder.clusterTimeResFromSeed = cms.bool(False) + process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcBarrel = _timeResolutionHCAL + process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcEndcap = _timeResolutionHCAL + process.particleFlowClusterHBHE.pfClusterBuilder.algoName = cms.string("PFlow2DClusterizerWithTime") + process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) + + + + if scenario ==3: + print '-------------HCAL CLUSTERING-------------' + print 'SCENARIO 3: Max time sample + HCAL clustering from hits +3D clustering with time ' + print 'Timing cuts are applied' + if not data: + print 'You are trying to run on MC, if not set data to True' + else: + print 'You are trying to run on data, if not set data to False' + + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHEMaxSampleTimeSelected_cfi') + process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') + + from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample + + + process.pfClusteringHBHEHF.remove(process.towerMakerPF) + process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) + + process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE + process.pfClusteringHBHEHF+=process.particleFlowRecHitHF + process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE + process.pfClusteringHBHEHF+=process.particleFlowClusterHBHETimeSelected + process.pfClusteringHBHEHF+=process.particleFlowClusterHF + + + + for p in process.particleFlowRecHitHBHE.producers: + p.name = cms.string(p.name.value()+'MaxSample') + + + + process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', +# clustersSource = cms.InputTag("particleFlowClusterHBHE"), + + clustersSource = cms.InputTag("particleFlowClusterHBHETimeSelected"), + pfClusterBuilder =cms.PSet( + algoName = cms.string("PFMultiDepthClusterizer"), + nSigmaEta = cms.double(2.), + nSigmaPhi = cms.double(2.), + #pf clustering parameters + minFractionToKeep = cms.double(1e-7), + allCellsPositionCalc = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(-1), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) + ) + ), + positionReCalc = cms.PSet( + ), + energyCorrector = cms.PSet() + ) + + process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL + + ##customize block since we have only one HF cluster collection now + importers = process.particleFlowBlock.elementImporters + newImporters = cms.VPSet() + + for pset in importers: + if pset.importerName =="GenericClusterImporter": + + if pset.source.moduleLabel == 'particleFlowClusterHFEM': + pset.source = cms.InputTag('particleFlowClusterHF') + newImporters.append(pset) + elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': + newImporters.append(pset) + else: + newImporters.append(pset) + + + process.particleFlowBlock.elementImporters = newImporters + + + + process.particleFlowRecHitHBHE.navigator = cms.PSet( + name = cms.string("PFRecHitHCALNavigatorWithTime"), + sigmaCut = cms.double(5.0), + timeResolutionCalc = _timeResolutionHCALMaxSample + ) + + + + + + process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEB = cms.double(10.) + process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEE = cms.double(10.) + process.particleFlowClusterHBHE.pfClusterBuilder.maxNSigmaTime = cms.double(10.) + process.particleFlowClusterHBHE.pfClusterBuilder.minChi2Prob = cms.double(0.) + process.particleFlowClusterHBHE.pfClusterBuilder.clusterTimeResFromSeed = cms.bool(False) + process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcBarrel = _timeResolutionHCALMaxSample + process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcEndcap = _timeResolutionHCALMaxSample + process.particleFlowClusterHBHE.pfClusterBuilder.algoName = cms.string("PFlow2DClusterizerWithTime") + + + + for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: + if norm.detector.value() == 'HCAL_BARREL1': + norm.seedingThreshold = 0.80 + if norm.detector.value() == 'HCAL_ENDCAP': + norm.seedingThreshold = 0.80 + + + + process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) From ffe492005418c42613e4991536c1cf3638086cec Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 5 Sep 2014 14:12:34 +0200 Subject: [PATCH 164/252] Changing default config to 3D clustering for HCAL plus Max samples --- .../python/particleFlowClusterHBHE_cfi.py | 82 ++++++++++++++ .../particleFlowClusterHCALLegacy_cfi.py | 88 +++++++++++++++ .../python/particleFlowClusterHCAL_cfi.py | 103 +++--------------- .../python/particleFlowCluster_cff.py | 27 ++++- .../python/particleFlowRecHitHBHE_cfi.py | 33 ++++++ .../python/particleFlowBlock_cfi.py | 4 +- .../PFProducer/python/particleFlow_cfi.py | 5 +- 7 files changed, 245 insertions(+), 97 deletions(-) create mode 100644 RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py create mode 100644 RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCALLegacy_cfi.py create mode 100644 RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py new file mode 100644 index 0000000000000..510429679d870 --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py @@ -0,0 +1,82 @@ +import FWCore.ParameterSet.Config as cms +from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample + +#### PF CLUSTER HCAL #### +particleFlowClusterHBHE = cms.EDProducer( + "PFClusterProducer", + recHitsSource = cms.InputTag("particleFlowRecHitHBHE"), + recHitCleaners = cms.VPSet(), + seedFinder = cms.PSet( + algoName = cms.string("LocalMaximumSeedFinder"), + thresholdsByDetector = cms.VPSet( + cms.PSet( detector = cms.string("HCAL_BARREL1"), + seedingThreshold = cms.double(0.8), + seedingThresholdPt = cms.double(0.0) + ), + cms.PSet( detector = cms.string("HCAL_ENDCAP"), + seedingThreshold = cms.double(0.8), + seedingThresholdPt = cms.double(0.0) + ) + ), + nNeighbours = cms.int32(4) + ), + initialClusteringStep = cms.PSet( + algoName = cms.string("Basic2DGenericTopoClusterizer"), + thresholdsByDetector = cms.VPSet( + cms.PSet( detector = cms.string("HCAL_BARREL1"), + gatheringThreshold = cms.double(0.8), + gatheringThresholdPt = cms.double(0.0) + ), + cms.PSet( detector = cms.string("HCAL_ENDCAP"), + gatheringThreshold = cms.double(0.8), + gatheringThresholdPt = cms.double(0.0) + ) + ), + useCornerCells = cms.bool(True) + ), + + pfClusterBuilder = cms.PSet( + algoName = cms.string("PFlow2DClusterizerWithTime"), + #pf clustering parameters + minFractionToKeep = cms.double(1e-7), + positionCalc = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(5), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) + ), + allCellsPositionCalc =cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(-1), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) + ), + + + timeSigmaEB = cms.double(10.), + timeSigmaEE = cms.double(10.), + maxNSigmaTime = cms.double(10.), + minChi2Prob = cms.double(0.), + clusterTimeResFromSeed = cms.bool(False), + timeResolutionCalcBarrel = _timeResolutionHCALMaxSample, + timeResolutionCalcEndcap = _timeResolutionHCALMaxSample, + showerSigma = cms.double(10.0), + stoppingTolerance = cms.double(1e-8), + maxIterations = cms.uint32(50), + excludeOtherSeeds = cms.bool(True), + minFracTot = cms.double(1e-20), ## numerical stabilization + recHitEnergyNorms = cms.VPSet( + cms.PSet( detector = cms.string("HCAL_BARREL1"), + recHitEnergyNorm = cms.double(0.8) + ), + cms.PSet( detector = cms.string("HCAL_ENDCAP"), + recHitEnergyNorm = cms.double(0.8) + ) + ) + ), + positionReCalc = cms.PSet(), + energyCorrector = cms.PSet() +) + diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCALLegacy_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCALLegacy_cfi.py new file mode 100644 index 0000000000000..c0857c5b902fa --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCALLegacy_cfi.py @@ -0,0 +1,88 @@ +import FWCore.ParameterSet.Config as cms + +#### PF CLUSTER HCAL #### + +#cleaning +_rbxAndHPDCleaner = cms.PSet( + algoName = cms.string("RBXAndHPDCleaner") +) + +#seeding +_localMaxSeeds_HCAL = cms.PSet( + algoName = cms.string("LocalMaximumSeedFinder"), + thresholdsByDetector = cms.VPSet( + cms.PSet( detector = cms.string("HCAL_BARREL1"), + seedingThreshold = cms.double(0.8), + seedingThresholdPt = cms.double(0.0) + ), + cms.PSet( detector = cms.string("HCAL_ENDCAP"), + seedingThreshold = cms.double(1.1), + seedingThresholdPt = cms.double(0.0) + ) + ), + nNeighbours = cms.int32(4) +) + +#topo clusters +_topoClusterizer_HCAL = cms.PSet( + algoName = cms.string("Basic2DGenericTopoClusterizer"), + thresholdsByDetector = cms.VPSet( + cms.PSet( detector = cms.string("HCAL_BARREL1"), + gatheringThreshold = cms.double(0.8), + gatheringThresholdPt = cms.double(0.0) + ), + cms.PSet( detector = cms.string("HCAL_ENDCAP"), + gatheringThreshold = cms.double(0.8), + gatheringThresholdPt = cms.double(0.0) + ) + ), + useCornerCells = cms.bool(True) +) + +#position calc +_positionCalcHCAL_cross_nodepth = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + ## + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(5), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) +) + +_positionCalcHCAL_all_nodepth = _positionCalcHCAL_cross_nodepth.clone( + posCalcNCrystals = cms.int32(-1) +) + +#pf clusterizer +_pfClusterizer_HCAL = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowClusterizer"), + #pf clustering parameters + minFractionToKeep = cms.double(1e-7), + positionCalc = _positionCalcHCAL_cross_nodepth, + allCellsPositionCalc = _positionCalcHCAL_all_nodepth, + showerSigma = cms.double(10.0), + stoppingTolerance = cms.double(1e-8), + maxIterations = cms.uint32(50), + excludeOtherSeeds = cms.bool(True), + minFracTot = cms.double(1e-20), ## numerical stabilization + recHitEnergyNorms = cms.VPSet( + cms.PSet( detector = cms.string("HCAL_BARREL1"), + recHitEnergyNorm = cms.double(0.8) + ), + cms.PSet( detector = cms.string("HCAL_ENDCAP"), + recHitEnergyNorm = cms.double(0.8) + ) + ) +) + +particleFlowClusterHCAL = cms.EDProducer( + "PFClusterProducer", + recHitsSource = cms.InputTag("particleFlowRecHitHCAL"), + recHitCleaners = cms.VPSet(_rbxAndHPDCleaner), + seedFinder = _localMaxSeeds_HCAL, + initialClusteringStep = _topoClusterizer_HCAL, + pfClusterBuilder = _pfClusterizer_HCAL, + positionReCalc = cms.PSet(), + energyCorrector = cms.PSet() +) + diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py index c0857c5b902fa..9613b2af4fe15 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py @@ -1,88 +1,21 @@ import FWCore.ParameterSet.Config as cms -#### PF CLUSTER HCAL #### - -#cleaning -_rbxAndHPDCleaner = cms.PSet( - algoName = cms.string("RBXAndHPDCleaner") -) - -#seeding -_localMaxSeeds_HCAL = cms.PSet( - algoName = cms.string("LocalMaximumSeedFinder"), - thresholdsByDetector = cms.VPSet( - cms.PSet( detector = cms.string("HCAL_BARREL1"), - seedingThreshold = cms.double(0.8), - seedingThresholdPt = cms.double(0.0) - ), - cms.PSet( detector = cms.string("HCAL_ENDCAP"), - seedingThreshold = cms.double(1.1), - seedingThresholdPt = cms.double(0.0) - ) - ), - nNeighbours = cms.int32(4) -) - -#topo clusters -_topoClusterizer_HCAL = cms.PSet( - algoName = cms.string("Basic2DGenericTopoClusterizer"), - thresholdsByDetector = cms.VPSet( - cms.PSet( detector = cms.string("HCAL_BARREL1"), - gatheringThreshold = cms.double(0.8), - gatheringThresholdPt = cms.double(0.0) - ), - cms.PSet( detector = cms.string("HCAL_ENDCAP"), - gatheringThreshold = cms.double(0.8), - gatheringThresholdPt = cms.double(0.0) - ) - ), - useCornerCells = cms.bool(True) -) - -#position calc -_positionCalcHCAL_cross_nodepth = cms.PSet( - algoName = cms.string("Basic2DGenericPFlowPositionCalc"), - ## - minFractionInCalc = cms.double(1e-9), - posCalcNCrystals = cms.int32(5), - logWeightDenominator = cms.double(0.8),#same as gathering threshold - minAllowedNormalization = cms.double(1e-9) +particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', + clustersSource = cms.InputTag("particleFlowClusterHBHETimeSelected"), + pfClusterBuilder =cms.PSet( + algoName = cms.string("PFMultiDepthClusterizer"), + nSigmaEta = cms.double(2.), + nSigmaPhi = cms.double(2.), + #pf clustering parameters + minFractionToKeep = cms.double(1e-7), + allCellsPositionCalc = cms.PSet( + algoName = cms.string("Basic2DGenericPFlowPositionCalc"), + minFractionInCalc = cms.double(1e-9), + posCalcNCrystals = cms.int32(-1), + logWeightDenominator = cms.double(0.8),#same as gathering threshold + minAllowedNormalization = cms.double(1e-9) + ) + ), + positionReCalc = cms.PSet(), + energyCorrector = cms.PSet() ) - -_positionCalcHCAL_all_nodepth = _positionCalcHCAL_cross_nodepth.clone( - posCalcNCrystals = cms.int32(-1) -) - -#pf clusterizer -_pfClusterizer_HCAL = cms.PSet( - algoName = cms.string("Basic2DGenericPFlowClusterizer"), - #pf clustering parameters - minFractionToKeep = cms.double(1e-7), - positionCalc = _positionCalcHCAL_cross_nodepth, - allCellsPositionCalc = _positionCalcHCAL_all_nodepth, - showerSigma = cms.double(10.0), - stoppingTolerance = cms.double(1e-8), - maxIterations = cms.uint32(50), - excludeOtherSeeds = cms.bool(True), - minFracTot = cms.double(1e-20), ## numerical stabilization - recHitEnergyNorms = cms.VPSet( - cms.PSet( detector = cms.string("HCAL_BARREL1"), - recHitEnergyNorm = cms.double(0.8) - ), - cms.PSet( detector = cms.string("HCAL_ENDCAP"), - recHitEnergyNorm = cms.double(0.8) - ) - ) -) - -particleFlowClusterHCAL = cms.EDProducer( - "PFClusterProducer", - recHitsSource = cms.InputTag("particleFlowRecHitHCAL"), - recHitCleaners = cms.VPSet(_rbxAndHPDCleaner), - seedFinder = _localMaxSeeds_HCAL, - initialClusteringStep = _topoClusterizer_HCAL, - pfClusterBuilder = _pfClusterizer_HCAL, - positionReCalc = cms.PSet(), - energyCorrector = cms.PSet() -) - diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py index 8b40969cf2695..22ee07646944c 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py @@ -2,19 +2,30 @@ import Geometry.HcalEventSetup.hcalTopologyIdeal_cfi -from RecoLocalCalo.CaloTowersCreator.calotowermaker_cfi import * -from RecoJets.Configuration.CaloTowersRec_cff import * + +#from RecoLocalCalo.CaloTowersCreator.calotowermaker_cfi import * +#from RecoJets.Configuration.CaloTowersRec_cff import * +#from RecoParticleFlow.PFClusterProducer.towerMakerPF_cfi import * +from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample + from RecoParticleFlow.PFClusterProducer.particleFlowRecHitECAL_cfi import * -from RecoParticleFlow.PFClusterProducer.particleFlowRecHitHCAL_cfi import * +from RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi import * +from RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowRecHitHO_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowRecHitPS_cfi import * -from RecoParticleFlow.PFClusterProducer.particleFlowClusterECAL_cff import * +from RecoParticleFlow.PFClusterProducer.particleFlowClusterECALUncorrected_cfi import * +from RecoParticleFlow.PFClusterProducer.particleFlowClusterECAL_cfi import * + + +from RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi import * +from RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHEMaxSampleTimeSelected_cfi import * +from RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi import * + from RecoParticleFlow.PFClusterProducer.particleFlowClusterHCAL_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowClusterHO_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowClusterPS_cfi import * -from RecoParticleFlow.PFClusterProducer.particleFlowClusterHFEM_cfi import * -from RecoParticleFlow.PFClusterProducer.particleFlowClusterHFHAD_cfi import * + #multi-depth from RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHEHO_cfi import * @@ -77,6 +88,10 @@ pfClusteringPS = cms.Sequence(particleFlowRecHitPS*particleFlowClusterPS) +#pfClusteringHBHEHF = cms.Sequence(towerMakerPF*particleFlowRecHitHCAL*particleFlowClusterHCAL+particleFlowClusterHFHAD+particleFlowClusterHFEM) +pfClusteringHBHEHF = cms.Sequence(particleFlowRecHitHBHE*particleFlowRecHitHF*particleFlowClusterHBHE*particleFlowClusterHBHETimeSelected*particleFlowClusterHF*particleFlowClusterHCAL) +pfClusteringHO = cms.Sequence(particleFlowRecHitHO*particleFlowClusterHO) + # Changed values # Don't use calotowers for HO, instead we use RecHits directly, and perform the links with tracks and HCAL clusters. diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py new file mode 100644 index 0000000000000..f765d0afa5e9c --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py @@ -0,0 +1,33 @@ +import FWCore.ParameterSet.Config as cms +from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample + +particleFlowRecHitHBHE = cms.EDProducer("PFRecHitProducer", + navigator = cms.PSet( + name = cms.string("PFRecHitHCALNavigatorWithTime"), + sigmaCut = cms.double(5.0), + timeResolutionCalc = _timeResolutionHCALMaxSample + ), + producers = cms.VPSet( + cms.PSet( + name = cms.string("PFHBHERecHitCreatorMaxSample"), + src = cms.InputTag("hbhereco",""), + qualityTests = cms.VPSet( + cms.PSet( + name = cms.string("PFRecHitQTestThreshold"), + threshold = cms.double(0.4) + ), + cms.PSet( + name = cms.string("PFRecHitQTestHCALChannel"), + maxSeverities = cms.vint32(11), + cleaningThresholds = cms.vdouble(0.0), + flags = cms.vstring('Standard') + ) + + + ) + ), + + ) + +) + diff --git a/RecoParticleFlow/PFProducer/python/particleFlowBlock_cfi.py b/RecoParticleFlow/PFProducer/python/particleFlowBlock_cfi.py index 2052028968997..1f8a4ffa27da9 100644 --- a/RecoParticleFlow/PFProducer/python/particleFlowBlock_cfi.py +++ b/RecoParticleFlow/PFProducer/python/particleFlowBlock_cfi.py @@ -70,9 +70,7 @@ cms.PSet( importerName = cms.string("GenericClusterImporter"), source = cms.InputTag("particleFlowClusterHO") ), cms.PSet( importerName = cms.string("GenericClusterImporter"), - source = cms.InputTag("particleFlowClusterHFEM") ), - cms.PSet( importerName = cms.string("GenericClusterImporter"), - source = cms.InputTag("particleFlowClusterHFHAD") ), + source = cms.InputTag("particleFlowClusterHF") ), cms.PSet( importerName = cms.string("GenericClusterImporter"), source = cms.InputTag("particleFlowClusterPS") ), diff --git a/RecoParticleFlow/PFProducer/python/particleFlow_cfi.py b/RecoParticleFlow/PFProducer/python/particleFlow_cfi.py index b544dc92ec701..14751c59b922c 100644 --- a/RecoParticleFlow/PFProducer/python/particleFlow_cfi.py +++ b/RecoParticleFlow/PFProducer/python/particleFlow_cfi.py @@ -160,9 +160,8 @@ # Check HF cleaning cleanedHF = cms.VInputTag( - cms.InputTag("particleFlowRecHitHCAL","Cleaned"), - cms.InputTag("particleFlowClusterHFHAD","Cleaned"), - cms.InputTag("particleFlowClusterHFEM","Cleaned") + cms.InputTag("particleFlowRecHitHF","Cleaned"), + cms.InputTag("particleFlowClusterHF","Cleaned") ), # number of sigmas for neutral energy detection From 138bae35b2a78ae49612ad8caa2790f6f056941b Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 5 Sep 2014 14:46:18 +0200 Subject: [PATCH 165/252] HO new threshold postLS1 --- .../Configuration/python/postLS1Customs.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/SLHCUpgradeSimulations/Configuration/python/postLS1Customs.py b/SLHCUpgradeSimulations/Configuration/python/postLS1Customs.py index 12fd5e67c14a6..cd18f2eade502 100644 --- a/SLHCUpgradeSimulations/Configuration/python/postLS1Customs.py +++ b/SLHCUpgradeSimulations/Configuration/python/postLS1Customs.py @@ -82,6 +82,21 @@ def customise_HLT(process): def customise_Reco(process): + #lowering HO threshold with SiPM + for prod in process.particleFlowRecHitHO.producers: + prod.qualityTests = cms.VPSet( + cms.PSet( + name = cms.string("PFRecHitQTestThreshold"), + threshold = cms.double(0.05) # new threshold for SiPM HO + ), + cms.PSet( + name = cms.string("PFRecHitQTestHCALChannel"), + maxSeverities = cms.vint32(11), + cleaningThresholds = cms.vdouble(0.0), + flags = cms.vstring('Standard') + ) + ) + return process From 74e785ad81dc4b4e9729f4062fa1d04e28434d98 Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 5 Sep 2014 16:16:53 +0200 Subject: [PATCH 166/252] Adding customizations for data in the new scheme --- .../python/Reconstruction_Data_cff.py | 34 +- .../python/tools/pfClusteringCustoms.py | 436 +----------------- 2 files changed, 40 insertions(+), 430 deletions(-) diff --git a/Configuration/StandardSequences/python/Reconstruction_Data_cff.py b/Configuration/StandardSequences/python/Reconstruction_Data_cff.py index c5330b40e905b..7750e9f2deadd 100644 --- a/Configuration/StandardSequences/python/Reconstruction_Data_cff.py +++ b/Configuration/StandardSequences/python/Reconstruction_Data_cff.py @@ -2,9 +2,39 @@ from Configuration.StandardSequences.Reconstruction_cff import * -particleFlowRecHitHCAL.LongShortFibre_Cut = 30. -particleFlowRecHitHCAL.ApplyPulseDPG = True + +#HF cleaning for data in the new design +# adding q tests for those lines +#particleFlowRecHitHCAL.LongShortFibre_Cut = 30. +#particleFlowRecHitHCAL.ApplyPulseDPG = True + + +for qTest in particleFlowRecHitHF.producers[0].qualityTests: + if qTest.name == 'PFRecHitQTestHCALChannel': + qTest.maxSeverities.append(9) + qTest.cleaningThresholds.append(30.) + qTest.flags.append('HFDigi') + +particleFlowRecHitHF.producers[0].qualityTests.append( + cms.PSet( + name = cms.string("PFRecHitQTestHCALTimeVsDepth"), + cuts = cms.VPSet( + cms.PSet( + depth = cms.int32(1), + threshold = cms.double(30.), + minTime = cms.double(-5.), + maxTime = cms.double(+5.), + ), + cms.PSet( + depth = cms.int32(2), + threshold = cms.double(30.), + minTime = cms.double(-5.), + maxTime = cms.double(+5.), + ) + ) + ) +) import RecoLocalCalo.HcalRecAlgos.RemoveAddSevLevel as HcalRemoveAddSevLevel HcalRemoveAddSevLevel.AddFlag(hcalRecAlgos,"HFDigiTime",11) HcalRemoveAddSevLevel.AddFlag(hcalRecAlgos,"HBHEFlatNoise",12) diff --git a/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py b/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py index 59fd50ac87d86..06527e0043cca 100644 --- a/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py +++ b/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py @@ -58,442 +58,22 @@ def customizePFECALClustering(process,scenario): -def customizePFHCALClustering(process,scenario,data = False): - +def customizePFHCALClustering(process,scenario): if scenario ==0: print '-------------HCAL CLUSTERING-------------' - print 'SCENARIO 0: HCAL clustering from hits+old HCAL time reconstruction' - print 'Timing cuts are N OTapplied' - if not data: - print 'You are trying to run on MC, if not set data to True' - else: - print 'You are trying to run on data, if not set data to False' - - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHETimeSelected_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') - - process.pfClusteringHBHEHF.remove(process.towerMakerPF) - process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) - - process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE - process.pfClusteringHBHEHF+=process.particleFlowRecHitHF - process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE - process.pfClusteringHBHEHF+=process.particleFlowClusterHF - - - process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', - clustersSource = cms.InputTag("particleFlowClusterHBHE"), - pfClusterBuilder =cms.PSet( - algoName = cms.string("PFMultiDepthClusterizer"), - nSigmaEta = cms.double(2.), - nSigmaPhi = cms.double(2.), - #pf clustering parameters - minFractionToKeep = cms.double(1e-7), - allCellsPositionCalc = cms.PSet( - algoName = cms.string("Basic2DGenericPFlowPositionCalc"), - minFractionInCalc = cms.double(1e-9), - posCalcNCrystals = cms.int32(-1), - logWeightDenominator = cms.double(0.8),#same as gathering threshold - minAllowedNormalization = cms.double(1e-9) - ) - ), - positionReCalc = cms.PSet( - ), - energyCorrector = cms.PSet() - ) - - process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL - - process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) - - ##customize block since we have only one HF cluster collection now - importers = process.particleFlowBlock.elementImporters - newImporters = cms.VPSet() - - for pset in importers: - if pset.importerName =="GenericClusterImporter": - - if pset.source.moduleLabel == 'particleFlowClusterHFEM': - pset.source = cms.InputTag('particleFlowClusterHF') - newImporters.append(pset) - elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': - newImporters.append(pset) - else: - newImporters.append(pset) - - - process.particleFlowBlock.elementImporters = newImporters - - - for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: - if norm.detector.value() == 'HCAL_BARREL1': - norm.seedingThreshold = 0.80 - if norm.detector.value() == 'HCAL_ENDCAP': - norm.seedingThreshold = 0.80 - - - - # Enable OOT pileup corrections for HBHE in MC processing - process.hbheprereco.mcOOTCorrectionName = cms.string("HBHE") - - # Uncomment next line to enable OOT pileup corrections in data processing - if data: - process.hbheprereco.dataOOTCorrectionName = cms.string("HBHE") - - # Configure database access for the OOT pileup corrections - import os - process.load("CondCore.CondDB.CondDBboost_cfi") - process.CondDBboost.connect = "sqlite_file:%s/src/CondTools/Hcal/data/testOOTPileupCorrection.db" % os.environ["CMSSW_RELEASE_BASE"] - - process.PoolDBESSource = cms.ESSource("PoolDBESSource", - process.CondDBboost, - toGet = cms.VPSet(cms.PSet( - record = cms.string("HcalOOTPileupCorrectionRcd"), - tag = cms.string("test") - ) - ) - ) - - - - if scenario ==1: - print '-------------HCAL CLUSTERING-------------' - print 'SCENARIO 1: HCAL clustering from hits' - print 'Timing cuts are applied' - if not data: - print 'You are trying to run on MC, if not set data to True' - else: - print 'You are trying to run on data, if not set data to False' - - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHETimeSelected_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') - - process.pfClusteringHBHEHF.remove(process.towerMakerPF) - process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) - - process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE - process.pfClusteringHBHEHF+=process.particleFlowRecHitHF - process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE -# process.pfClusteringHBHEHF+=process.particleFlowClusterHBHETimeSelected - process.pfClusteringHBHEHF+=process.particleFlowClusterHF - - - process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', - clustersSource = cms.InputTag("particleFlowClusterHBHE"), - pfClusterBuilder =cms.PSet( - algoName = cms.string("PFMultiDepthClusterizer"), - nSigmaEta = cms.double(2.), - nSigmaPhi = cms.double(2.), - #pf clustering parameters - minFractionToKeep = cms.double(1e-7), - allCellsPositionCalc = cms.PSet( - algoName = cms.string("Basic2DGenericPFlowPositionCalc"), - minFractionInCalc = cms.double(1e-9), - posCalcNCrystals = cms.int32(-1), - logWeightDenominator = cms.double(0.8),#same as gathering threshold - minAllowedNormalization = cms.double(1e-9) - ) - ), - positionReCalc = cms.PSet( - ), - energyCorrector = cms.PSet() - ) - - process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL - - process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) - - ##customize block since we have only one HF cluster collection now - importers = process.particleFlowBlock.elementImporters - newImporters = cms.VPSet() - - for pset in importers: - if pset.importerName =="GenericClusterImporter": - - if pset.source.moduleLabel == 'particleFlowClusterHFEM': - pset.source = cms.InputTag('particleFlowClusterHF') - newImporters.append(pset) - elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': - newImporters.append(pset) - else: - newImporters.append(pset) - - - process.particleFlowBlock.elementImporters = newImporters - - - for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: - if norm.detector.value() == 'HCAL_BARREL1': - norm.seedingThreshold = 0.80 - if norm.detector.value() == 'HCAL_ENDCAP': - norm.seedingThreshold = 0.80 - - - - # Enable OOT pileup corrections for HBHE in MC processing - process.hbheprereco.mcOOTCorrectionName = cms.string("HBHE") - - # Uncomment next line to enable OOT pileup corrections in data processing - if data: - process.hbheprereco.dataOOTCorrectionName = cms.string("HBHE") - - # Configure database access for the OOT pileup corrections - import os - process.load("CondCore.CondDB.CondDBboost_cfi") - process.CondDBboost.connect = "sqlite_file:%s/src/CondTools/Hcal/data/testOOTPileupCorrection.db" % os.environ["CMSSW_RELEASE_BASE"] - - process.PoolDBESSource = cms.ESSource("PoolDBESSource", - process.CondDBboost, - toGet = cms.VPSet(cms.PSet( - record = cms.string("HcalOOTPileupCorrectionRcd"), - tag = cms.string("test") - ) - ) - ) - - - if scenario ==2: - print '-------------HCAL CLUSTERING-------------' - print 'SCENARIO 2: HCAL clustering from hits +3D clustering with time ' - print 'Timing cuts are applied' - if not data: - print 'You are trying to run on MC, if not set data to True' - else: - print 'You are trying to run on data, if not set data to False' - - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHETimeSelected_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') - - from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCAL - - - process.pfClusteringHBHEHF.remove(process.towerMakerPF) - process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) - - process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE - process.pfClusteringHBHEHF+=process.particleFlowRecHitHF - process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE - process.pfClusteringHBHEHF+=process.particleFlowClusterHBHETimeSelected - process.pfClusteringHBHEHF+=process.particleFlowClusterHF - - - process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', - clustersSource = cms.InputTag("particleFlowClusterHBHETimeSelected"), - pfClusterBuilder =cms.PSet( - algoName = cms.string("PFMultiDepthClusterizer"), - nSigmaEta = cms.double(2.), - nSigmaPhi = cms.double(2.), - #pf clustering parameters - minFractionToKeep = cms.double(1e-7), - allCellsPositionCalc = cms.PSet( - algoName = cms.string("Basic2DGenericPFlowPositionCalc"), - minFractionInCalc = cms.double(1e-9), - posCalcNCrystals = cms.int32(-1), - logWeightDenominator = cms.double(0.8),#same as gathering threshold - minAllowedNormalization = cms.double(1e-9) - ) - ), - positionReCalc = cms.PSet( - ), - energyCorrector = cms.PSet() - ) - - process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL - - ##customize block since we have only one HF cluster collection now - importers = process.particleFlowBlock.elementImporters - newImporters = cms.VPSet() - - for pset in importers: - if pset.importerName =="GenericClusterImporter": - - if pset.source.moduleLabel == 'particleFlowClusterHFEM': - pset.source = cms.InputTag('particleFlowClusterHF') - newImporters.append(pset) - elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': - newImporters.append(pset) - else: - newImporters.append(pset) - - - process.particleFlowBlock.elementImporters = newImporters - - - - - for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: - if norm.detector.value() == 'HCAL_BARREL1': - norm.seedingThreshold = 0.80 - if norm.detector.value() == 'HCAL_ENDCAP': - norm.seedingThreshold = 0.80 - - - - # Enable OOT pileup corrections for HBHE in MC processing - process.hbheprereco.mcOOTCorrectionName = cms.string("HBHE") - - # Uncomment next line to enable OOT pileup corrections in data processing - if data: - process.hbheprereco.dataOOTCorrectionName = cms.string("HBHE") - - # Configure database access for the OOT pileup corrections - import os - process.load("CondCore.CondDB.CondDBboost_cfi") - process.CondDBboost.connect = "sqlite_file:%s/src/CondTools/Hcal/data/testOOTPileupCorrection.db" % os.environ["CMSSW_RELEASE_BASE"] - - process.PoolDBESSource = cms.ESSource("PoolDBESSource", - process.CondDBboost, - toGet = cms.VPSet(cms.PSet( - record = cms.string("HcalOOTPileupCorrectionRcd"), - tag = cms.string("test") - ) - ) - ) - - process.particleFlowRecHitHBHE.navigator = cms.PSet( - name = cms.string("PFRecHitHCALNavigatorWithTime"), - sigmaCut = cms.double(5.0), - timeResolutionCalc = _timeResolutionHCAL - ) - process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEB = cms.double(10.) - process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEE = cms.double(10.) - process.particleFlowClusterHBHE.pfClusterBuilder.maxNSigmaTime = cms.double(10.) - process.particleFlowClusterHBHE.pfClusterBuilder.minChi2Prob = cms.double(0.) - process.particleFlowClusterHBHE.pfClusterBuilder.clusterTimeResFromSeed = cms.bool(False) - process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcBarrel = _timeResolutionHCAL - process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcEndcap = _timeResolutionHCAL - process.particleFlowClusterHBHE.pfClusterBuilder.algoName = cms.string("PFlow2DClusterizerWithTime") - process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) - - - - if scenario ==3: - print '-------------HCAL CLUSTERING-------------' - print 'SCENARIO 3: Max time sample + HCAL clustering from hits +3D clustering with time ' - print 'Timing cuts are applied' - if not data: - print 'You are trying to run on MC, if not set data to True' - else: - print 'You are trying to run on data, if not set data to False' - - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowRecHitHF_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHEMaxSampleTimeSelected_cfi') - process.load('RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi') - - from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample - - - process.pfClusteringHBHEHF.remove(process.towerMakerPF) - process.pfClusteringHBHEHF.remove(process.particleFlowRecHitHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHCAL) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFHAD) - process.pfClusteringHBHEHF.remove(process.particleFlowClusterHFEM) - - process.pfClusteringHBHEHF+=process.particleFlowRecHitHBHE - process.pfClusteringHBHEHF+=process.particleFlowRecHitHF - process.pfClusteringHBHEHF+=process.particleFlowClusterHBHE - process.pfClusteringHBHEHF+=process.particleFlowClusterHBHETimeSelected - process.pfClusteringHBHEHF+=process.particleFlowClusterHF + print 'Default HCAL reconstruction and no 3D clustering with time in PF' + print 'but clustering 3D in space from layers' + process.pfClusteringHBHEHF.remove(process.particleFlowClusterHBHETimeSelected) for p in process.particleFlowRecHitHBHE.producers: - p.name = cms.string(p.name.value()+'MaxSample') - - - - process.particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', -# clustersSource = cms.InputTag("particleFlowClusterHBHE"), - - clustersSource = cms.InputTag("particleFlowClusterHBHETimeSelected"), - pfClusterBuilder =cms.PSet( - algoName = cms.string("PFMultiDepthClusterizer"), - nSigmaEta = cms.double(2.), - nSigmaPhi = cms.double(2.), - #pf clustering parameters - minFractionToKeep = cms.double(1e-7), - allCellsPositionCalc = cms.PSet( - algoName = cms.string("Basic2DGenericPFlowPositionCalc"), - minFractionInCalc = cms.double(1e-9), - posCalcNCrystals = cms.int32(-1), - logWeightDenominator = cms.double(0.8),#same as gathering threshold - minAllowedNormalization = cms.double(1e-9) - ) - ), - positionReCalc = cms.PSet( - ), - energyCorrector = cms.PSet() - ) - - process.pfClusteringHBHEHF+=process.particleFlowClusterHCAL - - ##customize block since we have only one HF cluster collection now - importers = process.particleFlowBlock.elementImporters - newImporters = cms.VPSet() - - for pset in importers: - if pset.importerName =="GenericClusterImporter": - - if pset.source.moduleLabel == 'particleFlowClusterHFEM': - pset.source = cms.InputTag('particleFlowClusterHF') - newImporters.append(pset) - elif pset.source.moduleLabel != 'particleFlowClusterHFHAD': - newImporters.append(pset) - else: - newImporters.append(pset) - - - process.particleFlowBlock.elementImporters = newImporters - + p.name = cms.string('PFHBHERecHitCreator') + process.particleFlowClusterHCAL.clustersSource = cms.InputTag("particleFlowClusterHBHE"), process.particleFlowRecHitHBHE.navigator = cms.PSet( - name = cms.string("PFRecHitHCALNavigatorWithTime"), - sigmaCut = cms.double(5.0), - timeResolutionCalc = _timeResolutionHCALMaxSample + name = cms.string("PFRecHitHCALNavigator") ) + process.particleFlowClusterHBHE.pfClusterBuilder.algoName = cms.string("Basic2DGenericPFlowClusterizer") - - - - - process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEB = cms.double(10.) - process.particleFlowClusterHBHE.pfClusterBuilder.timeSigmaEE = cms.double(10.) - process.particleFlowClusterHBHE.pfClusterBuilder.maxNSigmaTime = cms.double(10.) - process.particleFlowClusterHBHE.pfClusterBuilder.minChi2Prob = cms.double(0.) - process.particleFlowClusterHBHE.pfClusterBuilder.clusterTimeResFromSeed = cms.bool(False) - process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcBarrel = _timeResolutionHCALMaxSample - process.particleFlowClusterHBHE.pfClusterBuilder.timeResolutionCalcEndcap = _timeResolutionHCALMaxSample - process.particleFlowClusterHBHE.pfClusterBuilder.algoName = cms.string("PFlow2DClusterizerWithTime") - - - - for norm in process.particleFlowClusterHBHE.seedFinder.thresholdsByDetector: - if norm.detector.value() == 'HCAL_BARREL1': - norm.seedingThreshold = 0.80 - if norm.detector.value() == 'HCAL_ENDCAP': - norm.seedingThreshold = 0.80 - - - - process.particleFlowTmp.cleanedHF = cms.VInputTag(cms.InputTag("particleFlowRecHitHF","Cleaned"), cms.InputTag("particleFlowClusterHF","Cleaned")) From a6fa93aa83dccb6ad338baae71050247d47b336d Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 5 Sep 2014 16:30:13 +0200 Subject: [PATCH 167/252] Remove cleaning for FastSim in the new scheme --- .../ParticleFlowFastSimNeutralHadron_cff.py | 25 ++++++++++++------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py b/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py index 4a74e14152420..7e82692cea9ac 100644 --- a/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py +++ b/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py @@ -22,16 +22,23 @@ particleFlowSimParticle.sim = 'famosSimHits' #Deactivate the recovery of dead towers since dead towers are not simulated -particleFlowRecHitHCAL.ECAL_Compensate = cms.bool(False) + #Similarly, deactivate HF cleaning for spikes -particleFlowRecHitHCAL.ShortFibre_Cut = cms.double(1E5) -particleFlowRecHitHCAL.LongFibre_Cut = cms.double(1E5) -particleFlowRecHitHCAL.LongShortFibre_Cut = cms.double(1E5) -particleFlowRecHitHCAL.ApplyLongShortDPG = cms.bool(False) -particleFlowClusterHFEM.thresh_Clean_Barrel = cms.double(1E5) -particleFlowClusterHFEM.thresh_Clean_Endcap = cms.double(1E5) -particleFlowClusterHFHAD.thresh_Clean_Barrel = cms.double(1E5) -particleFlowClusterHFHAD.thresh_Clean_Endcap = cms.double(1E5) +particleFlowClusterHF.recHitCleaners = cvs.VPSet() +particleFlowRecHitHF.producers[0].qualityTests =cms.VPSet( + cms.PSet( + name = cms.string("PFRecHitQTestHCALThresholdVsDepth"), + cuts = cms.VPSet( + cms.PSet( + depth = cms.int32(1), + threshold = cms.double(1.2)), + cms.PSet( + depth = cms.int32(2), + threshold = cms.double(1.8)) + ) + ) + +) #particleFlowBlock.useNuclear = cms.bool(True) #particleFlowBlock.useConversions = cms.bool(True) From eb4d064b2c842c7c4c681cf8b1cce34691205edc Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 5 Sep 2014 17:13:57 +0200 Subject: [PATCH 168/252] Fixed Fastsim --- .../python/ParticleFlowFastSimNeutralHadron_cff.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py b/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py index 7e82692cea9ac..54738f325ba81 100644 --- a/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py +++ b/FastSimulation/ParticleFlow/python/ParticleFlowFastSimNeutralHadron_cff.py @@ -12,6 +12,7 @@ from RecoParticleFlow.PFTracking.trackerDrivenElectronSeeds_cff import * from RecoParticleFlow.PFTracking.mergedElectronSeeds_cfi import * from FastSimulation.ParticleFlow.FSparticleFlow_cfi import * +from RecoParticleFlow.PFClusterProducer.towerMakerPF_cfi import * # The following is replaced by the MVA-based #from RecoParticleFlow.PFProducer.pfGsfElectronCiCSelector_cff import * from RecoParticleFlow.PFProducer.pfGsfElectronMVASelector_cff import * @@ -24,7 +25,7 @@ #Deactivate the recovery of dead towers since dead towers are not simulated #Similarly, deactivate HF cleaning for spikes -particleFlowClusterHF.recHitCleaners = cvs.VPSet() +particleFlowClusterHF.recHitCleaners = cms.VPSet() particleFlowRecHitHF.producers[0].qualityTests =cms.VPSet( cms.PSet( name = cms.string("PFRecHitQTestHCALThresholdVsDepth"), From 70972987da50e87d4b45f4f6e74b81eee5d4c50a Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 5 Sep 2014 18:10:55 +0200 Subject: [PATCH 169/252] Changing the customs to activate the default HCAL Reco for studies and comparisons in 72 --- RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py b/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py index 06527e0043cca..21596bd7e1762 100644 --- a/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py +++ b/RecoParticleFlow/PFProducer/python/tools/pfClusteringCustoms.py @@ -71,7 +71,7 @@ def customizePFHCALClustering(process,scenario): p.name = cms.string('PFHBHERecHitCreator') - process.particleFlowClusterHCAL.clustersSource = cms.InputTag("particleFlowClusterHBHE"), + process.particleFlowClusterHCAL.clustersSource = cms.InputTag("particleFlowClusterHBHE") process.particleFlowRecHitHBHE.navigator = cms.PSet( name = cms.string("PFRecHitHCALNavigator") ) From 1fd5ae54a64bc40cf64aa5b63edeace60124e4b0 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Sat, 4 Oct 2014 19:44:49 +0200 Subject: [PATCH 170/252] hcal depth clustering in working order --- .../PFClusterProducer/python/particleFlowClusterHCAL_cfi.py | 2 +- SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py index 9613b2af4fe15..82d141828ffb3 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHCAL_cfi.py @@ -1,7 +1,7 @@ import FWCore.ParameterSet.Config as cms particleFlowClusterHCAL = cms.EDProducer('PFMultiDepthClusterProducer', - clustersSource = cms.InputTag("particleFlowClusterHBHETimeSelected"), + clustersSource = cms.InputTag("particleFlowClusterHBHE"), pfClusterBuilder =cms.PSet( algoName = cms.string("PFMultiDepthClusterizer"), nSigmaEta = cms.double(2.), diff --git a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py index 37993e36ac805..517024cf6b2a0 100644 --- a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py @@ -164,6 +164,9 @@ def cust_2023SHCal(process): process.pfClusteringECAL += process.particleFlowClusterECAL #process.particleFlowCluster += process.pfClusteringEK + process.tcMetWithPFclusters.PFClustersHFEM = cms.InputTag('particleFlowClusterHF') + process.tcMetWithPFclusters.PFClustersHFHAD = cms.InputTag('particleFlowClusterHF') + #clone photons to mustache photons so we can compare back to old reco process.mustachePhotonCore = process.photonCore.clone(scHybridBarrelProducer = cms.InputTag("particleFlowSuperClusterECAL","particleFlowSuperClusterECALBarrel"),scIslandEndcapProducer = cms.InputTag("particleFlowSuperClusterECAL","particleFlowSuperClusterECALEndcapWithPreshower")) process.mustachePhotons = process.photons.clone(photonCoreProducer = cms.InputTag('mustachePhotonCore'), endcapEcalHits = cms.InputTag("ecalRecHit","EcalRecHitsEK")) From a4c3254e4d6c5afdcdda00fc54d24d46c59a8b0a Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Sat, 4 Oct 2014 18:52:50 +0200 Subject: [PATCH 171/252] remove timing from HCAL sequence --- DataFormats/ParticleFlowReco/interface/PFCluster.h | 3 +++ DataFormats/ParticleFlowReco/src/classes_def_2.xml | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/DataFormats/ParticleFlowReco/interface/PFCluster.h b/DataFormats/ParticleFlowReco/interface/PFCluster.h index e0ea75d3c9387..ae6acde269d1e 100644 --- a/DataFormats/ParticleFlowReco/interface/PFCluster.h +++ b/DataFormats/ParticleFlowReco/interface/PFCluster.h @@ -81,8 +81,10 @@ namespace reco { /// cluster time double time() const {return time_;} + double depth() const {return depth_;} void setTime(double time) {time_ = time;} + void setDepth(double depth) {depth_ = depth;} /// cluster position: rho, eta, phi const REPPoint& positionREP() const {return posrep_;} @@ -172,6 +174,7 @@ namespace reco { ///Michalis :Add timing information double time_; + double depth_; /// transient layer PFLayer::Layer layer_; diff --git a/DataFormats/ParticleFlowReco/src/classes_def_2.xml b/DataFormats/ParticleFlowReco/src/classes_def_2.xml index 4a8f7a4929130..9685a07272c4d 100644 --- a/DataFormats/ParticleFlowReco/src/classes_def_2.xml +++ b/DataFormats/ParticleFlowReco/src/classes_def_2.xml @@ -1,7 +1,8 @@ - + + From 6ac171ca4084eb9aefdbcd319e0d459c58334e53 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Mon, 6 Oct 2014 12:29:27 +0200 Subject: [PATCH 172/252] backport it again, I think I encountered some sort of topological defect in gitspace --- .../plugins/PFMultiDepthClusterProducer.cc | 61 ++++ .../plugins/PFMultiDepthClusterProducer.h | 44 +++ .../python/particleFlowClusterHBHE_cfi.py | 8 +- .../python/particleFlowCluster_cff.py | 31 +- .../python/particleFlowRecHitHBHE_cfi.py | 10 +- .../src/PFMultiDepthClusterizer.cc | 270 ++++++++++++++++++ .../src/PFMultiDepthClusterizer.h | 79 +++++ .../Configuration/python/HCalCustoms.py | 4 +- 8 files changed, 480 insertions(+), 27 deletions(-) create mode 100644 RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.cc create mode 100644 RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.h create mode 100644 RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.cc create mode 100644 RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.h diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.cc b/RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.cc new file mode 100644 index 0000000000000..460b3187d3054 --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.cc @@ -0,0 +1,61 @@ +#include "PFMultiDepthClusterProducer.h" + +#ifdef PFLOW_DEBUG +#define LOGVERB(x) edm::LogVerbatim(x) +#define LOGWARN(x) edm::LogWarning(x) +#define LOGERR(x) edm::LogError(x) +#define LOGDRESSED(x) edm::LogInfo(x) +#else +#define LOGVERB(x) LogTrace(x) +#define LOGWARN(x) edm::LogWarning(x) +#define LOGERR(x) edm::LogError(x) +#define LOGDRESSED(x) LogDebug(x) +#endif + +PFMultiDepthClusterProducer::PFMultiDepthClusterProducer(const edm::ParameterSet& conf) +{ + _clustersLabel = consumes(conf.getParameter("clustersSource")); + _pfClusterBuilder.reset(NULL); + const edm::ParameterSet& pfcConf = conf.getParameterSet("pfClusterBuilder"); + if( !pfcConf.empty() ) { + const std::string& pfcName = pfcConf.getParameter("algoName"); + PFCBB* pfcb = PFClusterBuilderFactory::get()->create(pfcName,pfcConf); + _pfClusterBuilder.reset(pfcb); + } + // see if new need to apply corrections, setup if there. + const edm::ParameterSet& cConf = conf.getParameterSet("energyCorrector"); + if( !cConf.empty() ) { + const std::string& cName = cConf.getParameter("algoName"); + PFClusterEnergyCorrectorBase* eCorr = + PFClusterEnergyCorrectorFactory::get()->create(cName,cConf); + _energyCorrector.reset(eCorr); + } + + produces(); +} + +void PFMultiDepthClusterProducer::beginLuminosityBlock(const edm::LuminosityBlock& lumi, + const edm::EventSetup& es) { + _pfClusterBuilder->update(es); + +} + +void PFMultiDepthClusterProducer::produce(edm::Event& e, const edm::EventSetup& es) { + _pfClusterBuilder->reset(); + + edm::Handle inputClusters; + e.getByToken(_clustersLabel,inputClusters); + + std::vector seedable; + + std::auto_ptr pfClusters; + pfClusters.reset(new reco::PFClusterCollection); + _pfClusterBuilder->buildClusters(*inputClusters, seedable, *pfClusters); + LOGVERB("PFMultiDepthClusterProducer::produce()") << *_pfClusterBuilder; + + if( _energyCorrector ) { + _energyCorrector->correctEnergies(*pfClusters); + } + e.put(pfClusters); + +} diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.h b/RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.h new file mode 100644 index 0000000000000..bd9a17972fb86 --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFMultiDepthClusterProducer.h @@ -0,0 +1,44 @@ +#ifndef __newpf_PFMultiDepthClusterProducer_H__ +#define __newpf_PFMultiDepthClusterProducer_H__ + +// user include files +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDProducer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/MakerMacros.h" + +#include "RecoParticleFlow/PFClusterProducer/interface/RecHitTopologicalCleanerBase.h" +#include "RecoParticleFlow/PFClusterProducer/interface/SeedFinderBase.h" +#include "RecoParticleFlow/PFClusterProducer/interface/InitialClusteringStepBase.h" +#include "RecoParticleFlow/PFClusterProducer/interface/PFClusterBuilderBase.h" +#include "RecoParticleFlow/PFClusterProducer/interface/PFCPositionCalculatorBase.h" +#include "RecoParticleFlow/PFClusterProducer/interface/PFClusterEnergyCorrectorBase.h" + +#include + + +class PFMultiDepthClusterProducer : public edm::EDProducer { + typedef InitialClusteringStepBase ICSB; + typedef PFClusterBuilderBase PFCBB; + typedef PFCPositionCalculatorBase PosCalc; + public: + PFMultiDepthClusterProducer(const edm::ParameterSet&); + ~PFMultiDepthClusterProducer() { } + + virtual void beginLuminosityBlock(const edm::LuminosityBlock&, + const edm::EventSetup&); + virtual void produce(edm::Event&, const edm::EventSetup&); + + private: + // inputs + edm::EDGetTokenT _clustersLabel; + // options + // the actual algorithm + std::unique_ptr _pfClusterBuilder; + std::unique_ptr _energyCorrector; +}; + +DEFINE_FWK_MODULE(PFMultiDepthClusterProducer); + +#endif diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py index 510429679d870..b1d81eb45061a 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHBHE_cfi.py @@ -1,5 +1,5 @@ import FWCore.ParameterSet.Config as cms -from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample +#from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample #### PF CLUSTER HCAL #### particleFlowClusterHBHE = cms.EDProducer( @@ -36,7 +36,7 @@ ), pfClusterBuilder = cms.PSet( - algoName = cms.string("PFlow2DClusterizerWithTime"), + algoName = cms.string("Basic2DGenericPFlowClusterizer"), #pf clustering parameters minFractionToKeep = cms.double(1e-7), positionCalc = cms.PSet( @@ -60,8 +60,8 @@ maxNSigmaTime = cms.double(10.), minChi2Prob = cms.double(0.), clusterTimeResFromSeed = cms.bool(False), - timeResolutionCalcBarrel = _timeResolutionHCALMaxSample, - timeResolutionCalcEndcap = _timeResolutionHCALMaxSample, + #timeResolutionCalcBarrel = _timeResolutionHCALMaxSample, + #timeResolutionCalcEndcap = _timeResolutionHCALMaxSample, showerSigma = cms.double(10.0), stoppingTolerance = cms.double(1e-8), maxIterations = cms.uint32(50), diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py index 22ee07646944c..df63b0d7cb9f3 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py @@ -3,10 +3,10 @@ import Geometry.HcalEventSetup.hcalTopologyIdeal_cfi -#from RecoLocalCalo.CaloTowersCreator.calotowermaker_cfi import * -#from RecoJets.Configuration.CaloTowersRec_cff import * +from RecoLocalCalo.CaloTowersCreator.calotowermaker_cfi import * +from RecoJets.Configuration.CaloTowersRec_cff import * #from RecoParticleFlow.PFClusterProducer.towerMakerPF_cfi import * -from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample +#from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample from RecoParticleFlow.PFClusterProducer.particleFlowRecHitECAL_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHE_cfi import * @@ -19,14 +19,13 @@ from RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHE_cfi import * -from RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHEMaxSampleTimeSelected_cfi import * +#from RecoParticleFlow.PFClusterProducer.particleFlowClusterHBHEMaxSampleTimeSelected_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowClusterHF_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowClusterHCAL_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowClusterHO_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowClusterPS_cfi import * - #multi-depth from RecoParticleFlow.PFClusterProducer.particleFlowRecHitHBHEHO_cfi import * from RecoParticleFlow.PFClusterProducer.particleFlowClusterHCALSemi3D_cfi import * @@ -70,13 +69,13 @@ #else: towerMakerPF = calotowermaker.clone() -pfClusteringHCAL = cms.Sequence( towerMakerPF + - particleFlowRecHitHCAL + - particleFlowRecHitHO + - particleFlowClusterHCAL + - particleFlowClusterHFHAD + - particleFlowClusterHFEM + - particleFlowClusterHO ) +#pfClusteringHCAL = cms.Sequence( towerMakerPF + +# particleFlowRecHitHCAL + +# particleFlowRecHitHO + +# particleFlowClusterHCAL + +# particleFlowClusterHFHAD + +# particleFlowClusterHFEM + +# particleFlowClusterHO ) #pfClusteringHCAL = cms.Sequence(particleFlowRecHitHCAL*particleFlowClusterHCAL) #pfClusteringHCALall = cms.Sequence(particleFlowClusterHCAL+particleFlowClusterHFHAD+particleFlowClusterHFEM) @@ -89,7 +88,7 @@ #pfClusteringHBHEHF = cms.Sequence(towerMakerPF*particleFlowRecHitHCAL*particleFlowClusterHCAL+particleFlowClusterHFHAD+particleFlowClusterHFEM) -pfClusteringHBHEHF = cms.Sequence(particleFlowRecHitHBHE*particleFlowRecHitHF*particleFlowClusterHBHE*particleFlowClusterHBHETimeSelected*particleFlowClusterHF*particleFlowClusterHCAL) +pfClusteringHBHEHF = cms.Sequence(particleFlowRecHitHBHE*particleFlowRecHitHF*particleFlowClusterHBHE*particleFlowClusterHF*particleFlowClusterHCAL) pfClusteringHO = cms.Sequence(particleFlowRecHitHO*particleFlowClusterHO) @@ -148,7 +147,7 @@ #towerMakerPF* pfClusteringPS* pfClusteringECAL* - pfClusteringHCAL + pfClusteringHBHEHF ) particleFlowCluster = cms.Sequence( @@ -156,8 +155,8 @@ #towerMakerPF* pfClusteringPS* pfClusteringECAL* - pfClusteringHCAL - #pfClusteringHO + pfClusteringHBHEHF* + pfClusteringHO ) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py index f765d0afa5e9c..684862554ab8f 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHBHE_cfi.py @@ -1,15 +1,15 @@ import FWCore.ParameterSet.Config as cms -from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample +#from RecoParticleFlow.PFClusterProducer.particleFlowCaloResolution_cfi import _timeResolutionHCALMaxSample particleFlowRecHitHBHE = cms.EDProducer("PFRecHitProducer", navigator = cms.PSet( - name = cms.string("PFRecHitHCALNavigatorWithTime"), - sigmaCut = cms.double(5.0), - timeResolutionCalc = _timeResolutionHCALMaxSample + name = cms.string("PFRecHitHCALNavigator"), + #sigmaCut = cms.double(5.0), + #timeResolutionCalc = _timeResolutionHCALMaxSample ), producers = cms.VPSet( cms.PSet( - name = cms.string("PFHBHERecHitCreatorMaxSample"), + name = cms.string("PFHBHERecHitCreator"), src = cms.InputTag("hbhereco",""), qualityTests = cms.VPSet( cms.PSet( diff --git a/RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.cc b/RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.cc new file mode 100644 index 0000000000000..3fe4a04c6cf63 --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.cc @@ -0,0 +1,270 @@ +#include "PFMultiDepthClusterizer.h" +#include "DataFormats/ParticleFlowReco/interface/PFRecHit.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "DataFormats/Math/interface/deltaR.h" +#include "DataFormats/Math/interface/deltaPhi.h" +#include "Math/GenVector/VectorUtil.h" + +#include "vdt/vdtMath.h" + +#include + + + +PFMultiDepthClusterizer:: +PFMultiDepthClusterizer(const edm::ParameterSet& conf) : + PFClusterBuilderBase(conf) +{ + + _allCellsPosCalc.reset(NULL); + if( conf.exists("allCellsPositionCalc") ) { + const edm::ParameterSet& acConf = + conf.getParameterSet("allCellsPositionCalc"); + const std::string& algoac = + acConf.getParameter("algoName"); + PosCalc* accalc = + PFCPositionCalculatorFactory::get()->create(algoac, acConf); + _allCellsPosCalc.reset(accalc); + } + + nSigmaEta_ = pow(conf.getParameter("nSigmaEta"),2); + nSigmaPhi_ = pow(conf.getParameter("nSigmaPhi"),2); + +} + +void PFMultiDepthClusterizer:: +buildClusters(const reco::PFClusterCollection& input, + const std::vector& seedable, + reco::PFClusterCollection& output) { + + std::vector etaRMS(input.size(),0.0); + std::vector phiRMS(input.size(),0.0); + + //We need to sort the clusters for smaller to larger depth + // for (unsigned int i=0;i links = link(input,etaRMS,phiRMS); + // for (const auto& link: links) + // printf("link %d %d %f %f\n",link.from(),link.to(),link.dR(),link.dZ()); + + + + std::vector mask(input.size(),false); + std::vector linked(input.size(),false); + + //prune + std::vector prunedLinks; + if (links.size()) + prunedLinks = prune(links,linked); + + //printf("Pruned links\n") + // for (const auto& link: prunedLinks) + // printf("link %d %d %f %f\n",link.from(),link.to(),link.dR(),link.dZ()); + + + + //now we need to build clusters + for (unsigned int i=0;icalculateAndSetPosition(cluster); + output.push_back(cluster); + // printf("Added linked cluster with energy =%f\n",cluster.energy()); + + } +} + + +void PFMultiDepthClusterizer:: +calculateShowerShapes(const reco::PFClusterCollection& clusters,std::vector& etaRMS,std::vector& phiRMS) { + float etaSum; + float phiSum; + + //shower shapes. here do not use the fractions + + for( unsigned int i=0;ienergy()*fabs(frac.recHitRef()->position().Eta() -cluster.position().Eta() ); + phiSum +=frac.fraction()*frac.recHitRef()->energy()*fabs(deltaPhi(frac.recHitRef()->position().Phi(),cluster.position().Phi())); + } + //protection for single line : assign ~ tower + etaRMS[i] = std::max(etaSum/cluster.energy(),0.1); + phiRMS[i] = std::max(phiSum/cluster.energy(),0.1); + + } + +} + + +std::vector PFMultiDepthClusterizer:: +link(const reco::PFClusterCollection& clusters ,const std::vector& etaRMS,const std::vector& phiRMS) { + + std::vector links; + //loop on all pairs + for (unsigned int i=0;i %d (%f %f %f %f ) \n",i,j,deta,dphi,cluster1.position().Eta()-cluster2.position().Eta(),deltaPhi(cluster1.position().Phi(),cluster2.position().Phi())); + + if (deta PFMultiDepthClusterizer:: +prune(std::vector& links,std::vector& linkedClusters) { + std::vector goodLinks ; + std::vector mask(links.size(),false); + + for (unsigned int i=0;i link2.dZ()) { + mask[i] = true; + } + else if (fabs(link1.dZ()-link2.dZ())<0.2) { //if same layer-pick based on transverse compatibility + if (link1.dR()link2.dR()) { + mask[i] = true; + } + else { + //same distance as well -> can happen !!!!! Pick the highest SUME + if (link1.energy()detId() == main.seed()) { + e1=fraction.recHitRef()->energy(); + } + + for ( const auto& fraction : added.recHitFractions()) { + main.addRecHitFraction(fraction); + if (fraction.recHitRef()->detId() == added.seed()) { + e2=fraction.recHitRef()->energy(); + } + } + if (e2>e1) + main.setSeed(added.seed()); + +} + + +void +PFMultiDepthClusterizer:: +expandCluster(reco::PFCluster& cluster,unsigned int point,std::vector& mask,const reco::PFClusterCollection& clusters, const std::vector& links) { + for (const auto& link : links) { + if (link.from() == point) { + //found link that starts from this guy if not masked absorb + if (!mask[link.from()]) { + absorbCluster(cluster,clusters[link.from()]); + mask[link.from()] = true; + } + + if (!mask[link.to()]) { + absorbCluster(cluster,clusters[link.to()]); + mask[link.to()]=true; + expandCluster(cluster,link.to(),mask,clusters,links); + } + } + if (link.to() == point) { + //found link that starts from this guy if not masked absorb + if (!mask[link.to()]) { + absorbCluster(cluster,clusters[link.to()]); + mask[link.to()] = true; + } + + if (!mask[link.from()]) { + absorbCluster(cluster,clusters[link.from()]); + mask[link.from()]=true; + expandCluster(cluster,link.from(),mask,clusters,links); + } + } + + + + } + +} diff --git a/RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.h b/RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.h new file mode 100644 index 0000000000000..4f0aa7bf3f71d --- /dev/null +++ b/RecoParticleFlow/PFClusterProducer/src/PFMultiDepthClusterizer.h @@ -0,0 +1,79 @@ +#ifndef __PFMultiDepthClusterizer_H__ +#define __PFMultiDepthClusterizer_H__ + +#include "RecoParticleFlow/PFClusterProducer/interface/PFClusterBuilderBase.h" +#include "DataFormats/ParticleFlowReco/interface/PFRecHitFraction.h" + +#include + +class PFMultiDepthClusterizer : public PFClusterBuilderBase { + typedef PFMultiDepthClusterizer B2DGPF; + public: + PFMultiDepthClusterizer(const edm::ParameterSet& conf); + + virtual ~PFMultiDepthClusterizer() {} + PFMultiDepthClusterizer(const B2DGPF&) = delete; + B2DGPF& operator=(const B2DGPF&) = delete; + + void update(const edm::EventSetup& es) { + _allCellsPosCalc->update(es); + } + + void buildClusters(const reco::PFClusterCollection&, + const std::vector&, + reco::PFClusterCollection& outclus); + + private: + std::unique_ptr _allCellsPosCalc; + double nSigmaEta_; + double nSigmaPhi_; + + + class ClusterLink { + public: + ClusterLink(unsigned int i,unsigned int j,double DR,double DZ,double energy) { + from_ = i; + to_ = j; + linkDR_ =DR; + linkDZ_ =DZ; + linkE_ =energy; + } + + ~ClusterLink() { + + } + + unsigned int from() const {return from_;} + unsigned int to() const {return to_;} + double dR() const {return linkDR_;} + double dZ() const {return linkDZ_;} + double energy() const {return linkE_;} + + private: + unsigned int from_; + unsigned int to_; + double linkDR_; + double linkDZ_; + double linkE_; + + }; + + + void calculateShowerShapes(const reco::PFClusterCollection&,std::vector&,std::vector&); + std::vector link(const reco::PFClusterCollection&,const std::vector&,const std::vector&); + std::vector prune(std::vector&,std::vector& linkedClusters); + + + void expandCluster(reco::PFCluster&,unsigned int point, std::vector& mask,const reco::PFClusterCollection& , const std::vector& links); + + void absorbCluster(reco::PFCluster&, const reco::PFCluster&) ; + + + +}; + +DEFINE_EDM_PLUGIN(PFClusterBuilderFactory, + PFMultiDepthClusterizer, + "PFMultiDepthClusterizer"); + +#endif diff --git a/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py b/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py index 389a0b3bccb76..6fc8fef641f58 100644 --- a/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py @@ -148,8 +148,8 @@ def customise_Reco(process): process.towerMaker.HcalPhase = cms.int32(1) process.towerMakerPF.HcalPhase = cms.int32(1) process.towerMakerWithHO.HcalPhase = cms.int32(1) - process.particleFlowRecHitHCAL.hcalRecHitsHBHE = cms.InputTag("hbheUpgradeReco") - process.particleFlowRecHitHCAL.hcalRecHitsHF = cms.InputTag("hfUpgradeReco") + process.particleFlowRecHitHBHE.producers[0].src = cms.InputTag("hbheUpgradeReco") + process.particleFlowRecHitHF.producers[0].src = cms.InputTag("hfUpgradeReco") process.ak5JetID.hfRecHitsColl = cms.InputTag("hfUpgradeReco") process.ak5JetID.hbheRecHitsColl = cms.InputTag("hbheUpgradeReco") process.ak7JetID.hfRecHitsColl = cms.InputTag("hfUpgradeReco") From a6d50568d8c9acc9cdf9be37e23481518c4dcbb9 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:10:00 +0200 Subject: [PATCH 173/252] adding the 2017dev and 2023muondev + removing LongBarrel (LB) obsolete for 1.5years --- .../Configuration/python/Phase2Tk.cmsdriver | 67 ---- .../python/phase1TkCustomsdev.py | 275 +++++++++++++++ .../python/phase2TkCustomsBE5DPixel10Ddev.py | 331 ++++++++++++++++++ .../python/phase2TkCustoms_LB_4LPS_2L2S.py | 265 -------------- .../python/phase2TkCustoms_LB_6PS.py | 264 -------------- 5 files changed, 606 insertions(+), 596 deletions(-) delete mode 100644 SLHCUpgradeSimulations/Configuration/python/Phase2Tk.cmsdriver create mode 100644 SLHCUpgradeSimulations/Configuration/python/phase1TkCustomsdev.py create mode 100644 SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py delete mode 100644 SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_4LPS_2L2S.py delete mode 100644 SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_6PS.py diff --git a/SLHCUpgradeSimulations/Configuration/python/Phase2Tk.cmsdriver b/SLHCUpgradeSimulations/Configuration/python/Phase2Tk.cmsdriver deleted file mode 100644 index db2f4d22f80da..0000000000000 --- a/SLHCUpgradeSimulations/Configuration/python/Phase2Tk.cmsdriver +++ /dev/null @@ -1,67 +0,0 @@ -##GEN_SIM cmsdriver for BarrelEndCap5Disks -cmsDriver.py FourMuPt_1_200_cfi \ ---conditions auto:upgradePLS3 -n 10 \ ---eventcontent FEVTDEBUG --relval 10000,100 \ --s GEN,SIM --datatier GEN-SIM --beamspot HLLHC \ ---customise SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_phase2_BE5D \ ---geometry ExtendedPhase2TkBE5D --fileout file:step1BE5D.root - -##DIGI-LOCAL RECO for BarrelEndCap5Disks -cmsDriver.py step2_BE5D \ ---conditions auto:upgradePLS3 -n -1 \ ---eventcontent FEVTDEBUG \ --s DIGI,L1,DIGI2RAW,L1TrackTrigger,RECO:pixeltrackerlocalreco --datatier GEN-SIM-DIGI-RAW \ ---customise SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_phase2_BE5D \ ---geometry ExtendedPhase2TkBE5D --filein file:step1BE5D.root --fileout file:step2BE5D.root - -##GEN_SIM cmsdriver for BarrelEndCap -cmsDriver.py FourMuPt_1_200_cfi \ ---conditions auto:upgradePLS3 -n 10 \ ---eventcontent FEVTDEBUG --relval 10000,100 \ --s GEN,SIM --datatier GEN-SIM --beamspot HLLHC \ ---customise SLHCUpgradeSimulations/Configuration/postLS1Customs.customisePostLS1,SLHCUpgradeSimulations/Configuration/phase2TkCustomsBE.customise \ ---geometry ExtendedPhase2TkBE --fileout file:step1BE.root - -##DIGI-LOCAL RECO for BarrelEndCap -cmsDriver.py step2_BE \ ---conditions auto:upgradePLS3 -n -1 \ ---eventcontent FEVTDEBUG \ --s DIGI,L1,DIGI2RAW,L1TrackTrigger,RECO:pixeltrackerlocalreco --datatier GEN-SIM-DIGI-RAW \ ---customise SLHCUpgradeSimulations/Configuration/postLS1Customs.customisePostLS1,SLHCUpgradeSimulations/Configuration/phase2TkCustomsBE.customise,SLHCUpgradeSimulations/Configuration/phase2TkCustomsBE.l1EventContent \ ---geometry ExtendedPhase2TkBE --filein file:step1BE.root --fileout file:step2BE.root - - -##GEN_SIM cmsdriver for LongBarrel_6PS -cmsDriver.py FourMuPt_1_200_cfi \ ---conditions auto:upgradePLS3 -n 10 \ ---eventcontent FEVTDEBUG --relval 10000,100 \ --s GEN,SIM --datatier GEN-SIM --beamspot HLLHC \ ---customise SLHCUpgradeSimulations/Configuration/postLS1Customs.customisePostLS1,SLHCUpgradeSimulations/Configuration/phase2TkCustoms_LB_6PS.customise \ ---geometry ExtendedPhase2TkLB_6PS --fileout file:stepLB1.root - -##DIGI-LOCAL RECO for LongBarrel_6PS -cmsDriver.py step2_LB1 \ ---conditions auto:upgradePLS3::All -n -1 \ ---eventcontent FEVTDEBUG \ --s DIGI,L1,DIGI2RAW,L1TrackTrigger,RECO:pixeltrackerlocalreco --datatier GEN-SIM-DIGI-RAW \ ---customise SLHCUpgradeSimulations/Configuration/postLS1Customs.customisePostLS1,SLHCUpgradeSimulations/Configuration/phase2TkCustoms_LB_6PS.customise,SLHCUpgradeSimulations/Configuration/phase2TkCustoms_LB_6PS.l1EventContent \ ---geometry ExtendedPhase2TkLB_6PS --filein file:step1LB1.root --fileout file:step2LB1.root - - -##GEN_SIM cmsdriver for LongBarrel_4LPS_2L2S -cmsDriver.py FourMuPt_1_200_cfi \ ---conditions auto:upgradePLS3 -n 10 \ ---eventcontent FEVTDEBUG --relval 10000,100 \ --s GEN,SIM --datatier GEN-SIM --beamspot HLLHC \ ---customise SLHCUpgradeSimulations/Configuration/postLS1Customs.customisePostLS1,SLHCUpgradeSimulations/Configuration/phase2TkCustoms_LB_4LPS_2L2S.customise \ ---geometry ExtendedPhase2TkLB_4LPS_2L2S --fileout file:step1LB2.root - - -##DIGI-LOCAL RECO for LongBarrel_4LPS_2L2S - -cmsDriver.py step2_LB2 \ ---conditions auto:upgradePLS3 -n -1 \ ---eventcontent FEVTDEBUG \ --s DIGI,L1,DIGI2RAW,L1TrackTrigger,RECO:pixeltrackerlocalreco --datatier GEN-SIM-DIGI-RAW \ ---customise SLHCUpgradeSimulations/Configuration/postLS1Customs.customisePostLS1,SLHCUpgradeSimulations/Configuration/phase2TkCustoms_LB_4LPS_2L2S.customise,SLHCUpgradeSimulations/Configuration/phase2TkCustoms_LB_4LPS_2L2S.l1EventContent \ ---geometry ExtendedPhase2TkLB_4LPS_2L2S --filein file:step1LB2.root --fileout file:step2LB2.root diff --git a/SLHCUpgradeSimulations/Configuration/python/phase1TkCustomsdev.py b/SLHCUpgradeSimulations/Configuration/python/phase1TkCustomsdev.py new file mode 100644 index 0000000000000..b8d8f84638555 --- /dev/null +++ b/SLHCUpgradeSimulations/Configuration/python/phase1TkCustomsdev.py @@ -0,0 +1,275 @@ +import FWCore.ParameterSet.Config as cms + +from RecoTracker.IterativeTracking.iterativeTk_cff import * +from RecoTracker.IterativeTracking.ElectronSeeds_cff import * +from SLHCUpgradeSimulations.Configuration.customise_mixing import customise_pixelMixing_PU + +def customise(process): + if hasattr(process,'DigiToRaw'): + process=customise_DigiToRaw(process) + if hasattr(process,'RawToDigi'): + process=customise_RawToDigi(process) + n=0 + if hasattr(process,'reconstruction') or hasattr(process,'dqmoffline_step'): + if hasattr(process,'mix'): + if hasattr(process.mix,'input'): + n=process.mix.input.nbPileupEvents.averageNumber.value() + else: + print 'phase1TkCustoms requires a --pileup option to cmsDriver to run the reconstruction/dqm' + print 'Please provide one!' + sys.exit(1) + if hasattr(process,'reconstruction'): + process=customise_Reco(process,float(n)) + + if hasattr(process,'digitisation_step'): + process=customise_Digi(process) + if hasattr(process,'dqmoffline_step'): + process=customise_DQM(process,n) + if hasattr(process,'dqmHarvesting'): + process=customise_harvesting(process) + if hasattr(process,'validation_step'): + process=customise_Validation(process) + process=customise_condOverRides(process) + + return process + +def customise_DigiToRaw(process): + process.digi2raw_step.remove(process.siPixelRawData) + process.digi2raw_step.remove(process.castorRawData) + return process + +def customise_RawToDigi(process): + process.raw2digi_step.remove(process.siPixelDigis) + process.raw2digi_step.remove(process.castorDigis) + return process + +def customise_Digi(process): + process.mix.digitizers.pixel.MissCalibrate = False + process.mix.digitizers.pixel.LorentzAngle_DB = False + process.mix.digitizers.pixel.killModules = False + process.mix.digitizers.pixel.useDB = False + process.mix.digitizers.pixel.DeadModules_DB = False + process.mix.digitizers.pixel.NumPixelBarrel = cms.int32(4) + process.mix.digitizers.pixel.NumPixelEndcap = cms.int32(3) + process.mix.digitizers.pixel.ThresholdInElectrons_FPix = cms.double(2000.0) + process.mix.digitizers.pixel.ThresholdInElectrons_BPix = cms.double(2000.0) + process.mix.digitizers.pixel.ThresholdInElectrons_BPix_L1 = cms.double(2000.0) + process.mix.digitizers.pixel.thePixelColEfficiency_BPix4 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelEfficiency_BPix4 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelChipEfficiency_BPix4 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelColEfficiency_FPix3 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelEfficiency_FPix3 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelChipEfficiency_FPix3 = cms.double(0.999) + process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(True) + + process=customise_pixelMixing_PU(process) + return process + + +# DQM steps change +def customise_DQM(process,pileup): + # We cut down the number of iterative tracking steps + process.dqmoffline_step.remove(process.muonAnalyzer) + process.dqmoffline_step.remove(process.jetMETAnalyzer) + + #put isUpgrade flag==true + process.SiPixelRawDataErrorSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelDigiSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelClusterSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelRecHitSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelTrackResidualSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelHitEfficiencySource.isUpgrade = cms.untracked.bool(True) + + from DQM.TrackingMonitor.customizeTrackingMonitorSeedNumber import customise_trackMon_IterativeTracking_PHASE1PU140 + from DQM.TrackingMonitor.customizeTrackingMonitorSeedNumber import customise_trackMon_IterativeTracking_PHASE1PU70 + + if pileup>100: + process=customise_trackMon_IterativeTracking_PHASE1PU140(process) + else: + process=customise_trackMon_IterativeTracking_PHASE1PU70(process) + return process + +def customise_Validation(process): + process.validation_step.remove(process.PixelTrackingRecHitsValid) + # We don't run the HLT + process.validation_step.remove(process.HLTSusyExoVal) + process.validation_step.remove(process.hltHiggsValidator) + process.validation_step.remove(process.relvalMuonBits) + return process + +def customise_Validation_Trackingonly(process): + + #To allow Tracking to perform special tracking only validation + process.trackValidator.label=cms.VInputTag(cms.InputTag("cutsRecoTracksHp")) + process.tracksValidationSelectors = cms.Sequence(process.cutsRecoTracksHp) + process.globalValidation.remove(process.recoMuonValidation) + process.validation.remove(process.recoMuonValidation) + process.validation_preprod.remove(process.recoMuonValidation) + process.validation_step.remove(process.recoMuonValidation) + process.validation.remove(process.globalrechitsanalyze) + process.validation_prod.remove(process.globalrechitsanalyze) + process.validation_step.remove(process.globalrechitsanalyze) + process.validation.remove(process.stripRecHitsValid) + process.validation_step.remove(process.stripRecHitsValid) + process.validation_step.remove(process.StripTrackingRecHitsValid) + process.globalValidation.remove(process.vertexValidation) + process.validation.remove(process.vertexValidation) + process.validation_step.remove(process.vertexValidation) + process.mix.input.nbPileupEvents.averageNumber = cms.double(0.0) + process.mix.minBunch = cms.int32(0) + process.mix.maxBunch = cms.int32(0) + return process + +def customise_harvesting(process): + process.dqmHarvesting.remove(process.jetMETDQMOfflineClient) + process.dqmHarvesting.remove(process.dataCertificationJetMET) + #######process.dqmHarvesting.remove(process.sipixelEDAClient) + process.sipixelEDAClient.isUpgrade = cms.untracked.bool(True) + process.dqmHarvesting.remove(process.sipixelCertification) + return (process) + +def customise_condOverRides(process): + process.trackerTopologyConstants.pxb_layerStartBit = cms.uint32(20) + process.trackerTopologyConstants.pxb_ladderStartBit = cms.uint32(12) + process.trackerTopologyConstants.pxb_moduleStartBit = cms.uint32(2) + process.trackerTopologyConstants.pxb_layerMask = cms.uint32(15) + process.trackerTopologyConstants.pxb_ladderMask = cms.uint32(255) + process.trackerTopologyConstants.pxb_moduleMask = cms.uint32(1023) + process.trackerTopologyConstants.pxf_diskStartBit = cms.uint32(18) + process.trackerTopologyConstants.pxf_bladeStartBit = cms.uint32(12) + process.trackerTopologyConstants.pxf_panelStartBit = cms.uint32(10) + process.trackerTopologyConstants.pxf_moduleMask = cms.uint32(255) + return process + +def add_detailed_pixel_dqm(process): + #enable modOn + process.SiPixelRawDataErrorSource.modOn = cms.untracked.bool(True) + process.SiPixelDigiSource.modOn = cms.untracked.bool(True) + process.SiPixelClusterSource.modOn = cms.untracked.bool(True) + process.SiPixelRecHitSource.modOn = cms.untracked.bool(True) + process.SiPixelTrackResidualSource.modOn = cms.untracked.bool(True) + process.SiPixelHitEfficiencySource.modOn = cms.untracked.bool(True) + + return process + + +def remove_pixel_ineff(process): + if hasattr(process,'mix'): + process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(False) + + return process + + +def customise_Reco(process,pileup): + + #this code supports either 70 or 140 pileup configurations - should fix as to support 0 + nPU=70 + if pileup>100: nPU=140 + + #use with latest pixel geometry + process.ClusterShapeHitFilterESProducer.PixelShapeFile = cms.string('RecoPixelVertexing/PixelLowPtUtilities/data/pixelShape_Phase1Tk.par') + # Need this line to stop error about missing siPixelDigis. + process.MeasurementTracker.inactivePixelDetectorLabels = cms.VInputTag() + + # new layer list (3/4 pixel seeding) in InitialStep and pixelTracks + process.pixellayertriplets.layerList = cms.vstring( 'BPix1+BPix2+BPix3', + 'BPix2+BPix3+BPix4', + 'BPix1+BPix3+BPix4', + 'BPix1+BPix2+BPix4', + 'BPix2+BPix3+FPix1_pos', + 'BPix2+BPix3+FPix1_neg', + 'BPix1+BPix2+FPix1_pos', + 'BPix1+BPix2+FPix1_neg', + 'BPix2+FPix1_pos+FPix2_pos', + 'BPix2+FPix1_neg+FPix2_neg', + 'BPix1+FPix1_pos+FPix2_pos', + 'BPix1+FPix1_neg+FPix2_neg', + 'FPix1_pos+FPix2_pos+FPix3_pos', + 'FPix1_neg+FPix2_neg+FPix3_neg' ) + + # New tracking. This is really ugly because it redefines globalreco and reconstruction. + # It can be removed if change one line in Configuration/StandardSequences/python/Reconstruction_cff.py + # from RecoTracker_cff.py to RecoTrackerPhase1PU140_cff.py + + # remove all the tracking first + itIndex=process.globalreco.index(process.trackingGlobalReco) + grIndex=process.reconstruction.index(process.globalreco) + + process.reconstruction.remove(process.globalreco) + process.globalreco.remove(process.iterTracking) + process.globalreco.remove(process.electronSeedsSeq) + process.reconstruction_fromRECO.remove(process.trackingGlobalReco) + del process.iterTracking + del process.ckftracks + del process.ckftracks_woBH + del process.ckftracks_wodEdX + del process.ckftracks_plus_pixelless + del process.trackingGlobalReco + del process.electronSeedsSeq + del process.InitialStep + del process.LowPtTripletStep + del process.PixelPairStep + del process.DetachedTripletStep + del process.MixedTripletStep + del process.PixelLessStep + del process.TobTecStep + del process.earlyGeneralTracks + del process.ConvStep + # add the correct tracking back in + process.load("RecoTracker.Configuration.RecoTrackerPhase1PU"+str(nPU)+"_cff") + + process.globalreco.insert(itIndex,process.trackingGlobalReco) + process.reconstruction.insert(grIndex,process.globalreco) + #Note process.reconstruction_fromRECO is broken + + # End of new tracking configuration which can be removed if new Reconstruction is used. + + + process.reconstruction.remove(process.castorreco) + process.reconstruction.remove(process.CastorTowerReco) + process.reconstruction.remove(process.ak7BasicJets) + process.reconstruction.remove(process.ak7CastorJetID) + + #the quadruplet merger configuration + process.load("RecoPixelVertexing.PixelTriplets.quadrupletseedmerging_cff") + process.pixelseedmergerlayers.BPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) + process.pixelseedmergerlayers.BPix.HitProducer = cms.string("siPixelRecHits" ) + process.pixelseedmergerlayers.FPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) + process.pixelseedmergerlayers.FPix.HitProducer = cms.string("siPixelRecHits" ) + + # Need these until pixel templates are used + process.load("SLHCUpgradeSimulations.Geometry.recoFromSimDigis_cff") + # PixelCPEGeneric # + process.PixelCPEGenericESProducer.Upgrade = cms.bool(True) + process.PixelCPEGenericESProducer.UseErrorsFromTemplates = cms.bool(False) + process.PixelCPEGenericESProducer.LoadTemplatesFromDB = cms.bool(False) + process.PixelCPEGenericESProducer.TruncatePixelCharge = cms.bool(False) + process.PixelCPEGenericESProducer.IrradiationBiasCorrection = False + process.PixelCPEGenericESProducer.DoCosmics = False + # CPE for other steps + process.siPixelRecHits.CPE = cms.string('PixelCPEGeneric') + # Turn of template use in tracking (iterative steps handled inside their configs) + process.mergedDuplicateTracks.TTRHBuilder = 'WithTrackAngle' + process.ctfWithMaterialTracks.TTRHBuilder = 'WithTrackAngle' + process.muonSeededSeedsInOut.TrackerRecHitBuilder=cms.string('WithTrackAngle') + process.muonSeededTracksInOut.TTRHBuilder=cms.string('WithTrackAngle') + process.muonSeededTracksOutIn.TTRHBuilder=cms.string('WithTrackAngle') + process.muons1stStep.TrackerKinkFinderParameters.TrackerRecHitBuilder=cms.string('WithTrackAngle') + process.regionalCosmicTracks.TTRHBuilder=cms.string('WithTrackAngle') + process.cosmicsVetoTracksRaw.TTRHBuilder=cms.string('WithTrackAngle') + # End of pixel template needed section + + # Make pixelTracks use quadruplets + process.pixelTracks.SeedMergerPSet = cms.PSet( + layerListName = cms.string('PixelSeedMergerQuadruplets'), + addRemainingTriplets = cms.bool(False), + mergeTriplets = cms.bool(True), + ttrhBuilderLabel = cms.string('PixelTTRHBuilderWithoutAngle') + ) + process.pixelTracks.FilterPSet.chi2 = cms.double(50.0) + process.pixelTracks.FilterPSet.tipMax = cms.double(0.05) + process.pixelTracks.RegionFactoryPSet.RegionPSet.originRadius = cms.double(0.02) + + + + return process diff --git a/SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py b/SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py new file mode 100644 index 0000000000000..446173222895c --- /dev/null +++ b/SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py @@ -0,0 +1,331 @@ +import FWCore.ParameterSet.Config as cms +import SLHCUpgradeSimulations.Configuration.customise_PFlow as customise_PFlow + +#GEN-SIM so far... +def customise(process): + if hasattr(process,'DigiToRaw'): + process=customise_DigiToRaw(process) + if hasattr(process,'RawToDigi'): + process=customise_RawToDigi(process) + n=0 + if hasattr(process,'reconstruction') or hasattr(process,'dqmoffline_step'): + if hasattr(process,'mix'): + if hasattr(process.mix,'input'): + n=process.mix.input.nbPileupEvents.averageNumber.value() + else: + print 'phase1TkCustoms requires a --pileup option to cmsDriver to run the reconstruction/dqm' + print 'Please provide one!' + sys.exit(1) + if hasattr(process,'reconstruction'): + process=customise_Reco(process,float(n)) + if hasattr(process,'digitisation_step'): + process=customise_Digi(process) + if hasattr(process,'dqmoffline_step'): + process=customise_DQM(process,n) + if hasattr(process,'dqmHarvesting'): + process=customise_harvesting(process) + if hasattr(process,'validation_step'): + process=customise_Validation(process,float(n)) + process=customise_condOverRides(process) + + return process + +def customise_Digi(process): + process.mix.digitizers.pixel.MissCalibrate = False + process.mix.digitizers.pixel.LorentzAngle_DB = False + process.mix.digitizers.pixel.killModules = False + process.mix.digitizers.pixel.useDB = False + process.mix.digitizers.pixel.DeadModules_DB = False + process.mix.digitizers.pixel.NumPixelBarrel = cms.int32(10) + process.mix.digitizers.pixel.NumPixelEndcap = cms.int32(14) + process.mix.digitizers.pixel.ThresholdInElectrons_FPix = cms.double(2000.0) + process.mix.digitizers.pixel.ThresholdInElectrons_BPix = cms.double(2000.0) + process.mix.digitizers.pixel.ThresholdInElectrons_BPix_L1 = cms.double(2000.0) + process.mix.digitizers.pixel.thePixelColEfficiency_BPix4 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelEfficiency_BPix4 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelChipEfficiency_BPix4 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelColEfficiency_FPix3 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelEfficiency_FPix3 = cms.double(0.999) + process.mix.digitizers.pixel.thePixelChipEfficiency_FPix3 = cms.double(0.999) + process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(False) + process.mix.digitizers.strip.ROUList = cms.vstring("g4SimHitsTrackerHitsPixelBarrelLowTof", + 'g4SimHitsTrackerHitsPixelEndcapLowTof') + # Check if mergedtruth is in the sequence first, could be taken out depending on cmsDriver options + if hasattr(process.mix.digitizers,"mergedtruth") : + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTIBLowTof")) + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTIBHighTof")) + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTOBLowTof")) + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTOBHighTof")) + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTECLowTof")) + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTECHighTof")) + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTIDLowTof")) + process.mix.digitizers.mergedtruth.simHitCollections.tracker.remove( cms.InputTag("g4SimHits","TrackerHitsTIDHighTof")) + + return process + + +def customise_DigiToRaw(process): + process.digi2raw_step.remove(process.siPixelRawData) + process.digi2raw_step.remove(process.rpcpacker) + return process + +def customise_RawToDigi(process): + process.raw2digi_step.remove(process.siPixelDigis) + return process + +def customise_Reco(process,pileup): + + + + #use with latest pixel geometry + process.ClusterShapeHitFilterESProducer.PixelShapeFile = cms.string('RecoPixelVertexing/PixelLowPtUtilities/data/pixelShape_Phase1Tk.par') + # Need this line to stop error about missing siPixelDigis. + process.MeasurementTracker.inactivePixelDetectorLabels = cms.VInputTag() + + # new layer list (3/4 pixel seeding) in InitialStep and pixelTracks + process.pixellayertriplets.layerList = cms.vstring('BPix1+BPix2+BPix3', 'BPix2+BPix3+BPix4', + 'BPix2+BPix3+FPix1_pos', 'BPix2+BPix3+FPix1_neg', + 'BPix1+BPix2+FPix1_pos', 'BPix1+BPix2+FPix1_neg', + 'BPix2+FPix1_pos+FPix2_pos', 'BPix2+FPix1_neg+FPix2_neg', + 'BPix1+FPix1_pos+FPix2_pos', 'BPix1+FPix1_neg+FPix2_neg', + 'BPix1+FPix2_pos+FPix3_pos', 'BPix1+FPix2_neg+FPix3_neg', + 'FPix1_pos+FPix2_pos+FPix3_pos', 'FPix1_neg+FPix2_neg+FPix3_neg', + 'FPix2_pos+FPix3_pos+FPix4_pos', 'FPix2_neg+FPix3_neg+FPix4_neg', + 'FPix3_pos+FPix4_pos+FPix5_pos', 'FPix3_neg+FPix4_neg+FPix5_neg', + 'FPix4_pos+FPix5_pos+FPix6_pos', 'FPix4_neg+FPix5_neg+FPix6_neg', + 'FPix5_pos+FPix6_pos+FPix7_pos', 'FPix5_neg+FPix6_neg+FPix7_neg', + 'FPix6_pos+FPix7_pos+FPix8_pos', 'FPix6_neg+FPix7_neg+FPix8_neg', + 'FPix6_pos+FPix7_pos+FPix9_pos', 'FPix6_neg+FPix7_neg+FPix9_neg') + + # New tracking. This is really ugly because it redefines globalreco and reconstruction. + # It can be removed if change one line in Configuration/StandardSequences/python/Reconstruction_cff.py + # from RecoTracker_cff.py to RecoTrackerPhase1PU140_cff.py + + # remove all the tracking first + itIndex=process.globalreco.index(process.trackingGlobalReco) + grIndex=process.reconstruction.index(process.globalreco) + + process.reconstruction.remove(process.globalreco) + process.globalreco.remove(process.iterTracking) + process.globalreco.remove(process.electronSeedsSeq) + process.reconstruction_fromRECO.remove(process.trackingGlobalReco) + del process.iterTracking + del process.ckftracks + del process.ckftracks_woBH + del process.ckftracks_wodEdX + del process.ckftracks_plus_pixelless + del process.trackingGlobalReco + del process.electronSeedsSeq + del process.InitialStep + del process.LowPtTripletStep + del process.PixelPairStep + del process.DetachedTripletStep + del process.MixedTripletStep + del process.PixelLessStep + del process.TobTecStep + del process.earlyGeneralTracks + del process.ConvStep + del process.earlyMuons + del process.muonSeededStepCore + del process.muonSeededStepExtra + del process.muonSeededStep + del process.muonSeededStepDebug + + # add the correct tracking back in + process.load("RecoTracker.Configuration.RecoTrackerPhase2BEPixel10D_cff") + + process.globalreco.insert(itIndex,process.trackingGlobalReco) + process.reconstruction.insert(grIndex,process.globalreco) + #Note process.reconstruction_fromRECO is broken + + # End of new tracking configuration which can be removed if new Reconstruction is used. + + + process.reconstruction.remove(process.castorreco) + process.reconstruction.remove(process.CastorTowerReco) + process.reconstruction.remove(process.ak7BasicJets) + process.reconstruction.remove(process.ak7CastorJetID) + + #the quadruplet merger configuration + process.load("RecoPixelVertexing.PixelTriplets.quadrupletseedmerging_cff") + process.pixelseedmergerlayers.BPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) + process.pixelseedmergerlayers.BPix.HitProducer = cms.string("siPixelRecHits" ) + process.pixelseedmergerlayers.FPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) + process.pixelseedmergerlayers.FPix.HitProducer = cms.string("siPixelRecHits" ) + process.pixelseedmergerlayers.layerList = cms.vstring('BPix1+BPix2+BPix3+BPix4', + 'BPix1+BPix2+BPix3+FPix1_pos','BPix1+BPix2+BPix3+FPix1_neg', + 'BPix1+BPix2+FPix1_pos+FPix2_pos', 'BPix1+BPix2+FPix1_neg+FPix2_neg', + 'BPix1+FPix1_pos+FPix2_pos+FPix3_pos', 'BPix1+FPix1_neg+FPix2_neg+FPix3_neg', + 'FPix1_pos+FPix2_pos+FPix3_pos+FPix4_pos', 'FPix1_neg+FPix2_neg+FPix3_neg+FPix4_neg', + 'FPix2_pos+FPix3_pos+FPix4_pos+FPix5_pos', 'FPix2_neg+FPix3_neg+FPix4_neg+FPix5_neg', + 'FPix3_pos+FPix4_pos+FPix5_pos+FPix6_pos', 'FPix3_neg+FPix4_neg+FPix5_neg+FPix6_pos', + 'FPix4_pos+FPix5_pos+FPix6_pos+FPix7_pos', 'FPix4_neg+FPix5_neg+FPix6_neg+FPix7_neg', + 'FPix5_pos+FPix6_pos+FPix7_pos+FPix8_pos', 'FPix5_neg+FPix6_neg+FPix7_neg+FPix8_neg', + 'FPix5_pos+FPix6_pos+FPix7_pos+FPix9_pos', 'FPix5_neg+FPix6_neg+FPix7_neg+FPix9_neg', + 'FPix6_pos+FPix7_pos+FPix8_pos+FPix9_pos', 'FPix6_neg+FPix7_neg+FPix8_neg+FPix9_neg') + + + # Need these until pixel templates are used + process.load("SLHCUpgradeSimulations.Geometry.recoFromSimDigis_cff") + # PixelCPEGeneric # + process.PixelCPEGenericESProducer.Upgrade = cms.bool(True) + process.PixelCPEGenericESProducer.UseErrorsFromTemplates = cms.bool(False) + process.PixelCPEGenericESProducer.LoadTemplatesFromDB = cms.bool(False) + process.PixelCPEGenericESProducer.TruncatePixelCharge = cms.bool(False) + process.PixelCPEGenericESProducer.IrradiationBiasCorrection = False + process.PixelCPEGenericESProducer.DoCosmics = False + # CPE for other steps + process.siPixelRecHits.CPE = cms.string('PixelCPEGeneric') + # Turn of template use in tracking (iterative steps handled inside their configs) + process.mergedDuplicateTracks.TTRHBuilder = 'WithTrackAngle' + process.ctfWithMaterialTracks.TTRHBuilder = 'WithTrackAngle' + process.muonSeededSeedsInOut.TrackerRecHitBuilder=cms.string('WithTrackAngle') + process.muonSeededTracksInOut.TTRHBuilder=cms.string('WithTrackAngle') + process.muons1stStep.TrackerKinkFinderParameters.TrackerRecHitBuilder=cms.string('WithTrackAngle') + process.regionalCosmicTracks.TTRHBuilder=cms.string('WithTrackAngle') + process.cosmicsVetoTracksRaw.TTRHBuilder=cms.string('WithTrackAngle') + # End of pixel template needed section + + process.regionalCosmicTrackerSeeds.OrderedHitsFactoryPSet.LayerPSet.layerList = cms.vstring('BPix9+BPix8') # Optimize later + process.regionalCosmicTrackerSeeds.OrderedHitsFactoryPSet.LayerPSet.BPix = cms.PSet( + HitProducer = cms.string('siPixelRecHits'), + hitErrorRZ = cms.double(0.006), + useErrorsFromParam = cms.bool(True), + TTRHBuilder = cms.string('TTRHBuilderWithoutAngle4PixelPairs'), + skipClusters = cms.InputTag("pixelPairStepClusters"), + hitErrorRPhi = cms.double(0.0027) + ) + # Make pixelTracks use quadruplets + process.pixelTracks.SeedMergerPSet = cms.PSet( + layerListName = cms.string('PixelSeedMergerQuadruplets'), + addRemainingTriplets = cms.bool(False), + mergeTriplets = cms.bool(True), + ttrhBuilderLabel = cms.string('PixelTTRHBuilderWithoutAngle') + ) + process.pixelTracks.OrderedHitsFactoryPSet.GeneratorPSet.maxElement = cms.uint32(0) + process.pixelTracks.FilterPSet.chi2 = cms.double(50.0) + process.pixelTracks.FilterPSet.tipMax = cms.double(0.05) + process.pixelTracks.RegionFactoryPSet.RegionPSet.originRadius = cms.double(0.02) + + # Particle flow needs to know that the eta range has increased, for + # when linking tracks to HF clusters + process=customise_PFlow.customise_extendedTrackerBarrel( process ) + + return process + +def customise_condOverRides(process): + process.load('SLHCUpgradeSimulations.Geometry.fakeConditions_BarrelEndcap5DPixel10D_cff') + process.trackerNumberingSLHCGeometry.layerNumberPXB = cms.uint32(20) + process.trackerTopologyConstants.pxb_layerStartBit = cms.uint32(20) + process.trackerTopologyConstants.pxb_ladderStartBit = cms.uint32(12) + process.trackerTopologyConstants.pxb_moduleStartBit = cms.uint32(2) + process.trackerTopologyConstants.pxb_layerMask = cms.uint32(15) + process.trackerTopologyConstants.pxb_ladderMask = cms.uint32(255) + process.trackerTopologyConstants.pxb_moduleMask = cms.uint32(1023) + process.trackerTopologyConstants.pxf_diskStartBit = cms.uint32(18) + process.trackerTopologyConstants.pxf_bladeStartBit = cms.uint32(12) + process.trackerTopologyConstants.pxf_panelStartBit = cms.uint32(10) + process.trackerTopologyConstants.pxf_moduleMask = cms.uint32(255) + return process + + +def l1EventContent(process): + #extend the event content + + alist=['RAWSIM','FEVTDEBUG','FEVTDEBUGHLT','GENRAW','RAWSIMHLT','FEVT'] + for a in alist: + b=a+'output' + if hasattr(process,b): + + getattr(process,b).outputCommands.append('keep *_TTClustersFromPixelDigis_*_*') + getattr(process,b).outputCommands.append('keep *_TTStubsFromPixelDigis_*_*') + getattr(process,b).outputCommands.append('keep *_TTTracksFromPixelDigis_*_*') + + getattr(process,b).outputCommands.append('keep *_TTClusterAssociatorFromPixelDigis_*_*') + getattr(process,b).outputCommands.append('keep *_TTStubAssociatorFromPixelDigis_*_*') + getattr(process,b).outputCommands.append('keep *_TTTrackAssociatorFromPixelDigis_*_*') + + getattr(process,b).outputCommands.append('drop PixelDigiSimLinkedmDetSetVector_mix_*_*') + getattr(process,b).outputCommands.append('drop PixelDigiedmDetSetVector_mix_*_*') + + getattr(process,b).outputCommands.append('keep *_simSiPixelDigis_*_*') + + return process + +def customise_DQM(process,pileup): + # We cut down the number of iterative tracking steps +# process.dqmoffline_step.remove(process.TrackMonStep3) +# process.dqmoffline_step.remove(process.TrackMonStep4) +# process.dqmoffline_step.remove(process.TrackMonStep5) +# process.dqmoffline_step.remove(process.TrackMonStep6) + #The following two steps were removed + #process.PixelLessStep* + #process.TobTecStep* +# process.dqmoffline_step.remove(process.muonAnalyzer) + process.dqmoffline_step.remove(process.jetMETAnalyzer) +# process.dqmoffline_step.remove(process.TrackMonStep9) +# process.dqmoffline_step.remove(process.TrackMonStep10) +# process.dqmoffline_step.remove(process.PixelTrackingRecHitsValid) + + #put isUpgrade flag==true + process.SiPixelRawDataErrorSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelDigiSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelClusterSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelRecHitSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelTrackResidualSource.isUpgrade = cms.untracked.bool(True) + process.SiPixelHitEfficiencySource.isUpgrade = cms.untracked.bool(True) + + from DQM.TrackingMonitor.customizeTrackingMonitorSeedNumber import customise_trackMon_IterativeTracking_PHASE1PU140 + process=customise_trackMon_IterativeTracking_PHASE1PU140(process) + process.dqmoffline_step.remove(process.Phase1Pu70TrackMonStep2) + process.dqmoffline_step.remove(process.Phase1Pu70TrackMonStep4) + if hasattr(process,"globalrechitsanalyze") : # Validation takes this out if pileup is more than 30 + process.globalrechitsanalyze.ROUList = cms.vstring( + 'g4SimHitsTrackerHitsPixelBarrelLowTof', + 'g4SimHitsTrackerHitsPixelBarrelHighTof', + 'g4SimHitsTrackerHitsPixelEndcapLowTof', + 'g4SimHitsTrackerHitsPixelEndcapHighTof') + return process + +def customise_Validation(process,pileup): + process.validation_step.remove(process.PixelTrackingRecHitsValid) + process.validation_step.remove(process.stripRecHitsValid) + process.validation_step.remove(process.trackerHitsValid) + process.validation_step.remove(process.StripTrackingRecHitsValid) + # We don't run the HLT + process.validation_step.remove(process.HLTSusyExoVal) + process.validation_step.remove(process.hltHiggsValidator) + process.validation_step.remove(process.relvalMuonBits) + if pileup>30: + process.trackValidator.label=cms.VInputTag(cms.InputTag("cutsRecoTracksHp")) + process.tracksValidationSelectors = cms.Sequence(process.cutsRecoTracksHp) + process.globalValidation.remove(process.recoMuonValidation) + process.validation.remove(process.recoMuonValidation) + process.validation_preprod.remove(process.recoMuonValidation) + process.validation_step.remove(process.recoMuonValidation) + process.validation.remove(process.globalrechitsanalyze) + process.validation_prod.remove(process.globalrechitsanalyze) + process.validation_step.remove(process.globalrechitsanalyze) + process.validation.remove(process.stripRecHitsValid) + process.validation_step.remove(process.stripRecHitsValid) + process.validation_step.remove(process.StripTrackingRecHitsValid) + process.globalValidation.remove(process.vertexValidation) + process.validation.remove(process.vertexValidation) + process.validation_step.remove(process.vertexValidation) + process.mix.input.nbPileupEvents.averageNumber = cms.double(0.0) + process.mix.minBunch = cms.int32(0) + process.mix.maxBunch = cms.int32(0) + + if hasattr(process,'simHitTPAssocProducer'): + process.simHitTPAssocProducer.simHitSrc=cms.VInputTag(cms.InputTag("g4SimHits","TrackerHitsPixelBarrelLowTof"), + cms.InputTag("g4SimHits","TrackerHitsPixelEndcapLowTof")) + + return process + +def customise_harvesting(process): + process.dqmHarvesting.remove(process.jetMETDQMOfflineClient) + process.dqmHarvesting.remove(process.dataCertificationJetMET) + process.dqmHarvesting.remove(process.sipixelEDAClient) + process.dqmHarvesting.remove(process.sipixelCertification) + return (process) + diff --git a/SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_4LPS_2L2S.py b/SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_4LPS_2L2S.py deleted file mode 100644 index 88c2897ebbbec..0000000000000 --- a/SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_4LPS_2L2S.py +++ /dev/null @@ -1,265 +0,0 @@ -import FWCore.ParameterSet.Config as cms -#GEN-SIM so far... -def customise(process): - if hasattr(process,'DigiToRaw'): - process=customise_DigiToRaw(process) - if hasattr(process,'RawToDigi'): - process=customise_RawToDigi(process) - if hasattr(process,'reconstruction'): - process=customise_Reco(process) - if hasattr(process,'digitisation_step'): - process=customise_Digi(process) - if hasattr(process,'dqmoffline_step'): - process=customise_DQM(process) - if hasattr(process,'dqmHarvesting'): - process=customise_harvesting(process) - if hasattr(process,'validation_step'): - process=customise_Validation(process) - process=customise_condOverRides(process) - if hasattr(process,'L1TrackTrigger_step'): - process=customise_TrackTrigger(process) - - return process - -def customise_Digi(process): - process.mix.digitizers.pixel.MissCalibrate = False - process.mix.digitizers.pixel.LorentzAngle_DB = False - process.mix.digitizers.pixel.killModules = False - process.mix.digitizers.pixel.useDB = False - process.mix.digitizers.pixel.DeadModules_DB = False - process.mix.digitizers.pixel.NumPixelBarrel = cms.int32(12) - process.mix.digitizers.pixel.NumPixelEndcap = cms.int32(2) - process.mix.digitizers.pixel.ThresholdInElectrons_FPix = cms.double(2000.0) - process.mix.digitizers.pixel.ThresholdInElectrons_BPix = cms.double(2000.0) - process.mix.digitizers.pixel.ThresholdInElectrons_BPix_L1 = cms.double(2000.0) - process.mix.digitizers.pixel.thePixelColEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelChipEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelColEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelChipEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(False) - process.mix.digitizers.strip.ROUList = cms.vstring("g4SimHitsTrackerHitsPixelBarrelLowTof", - 'g4SimHitsTrackerHitsPixelEndcapLowTof') - process.digitisation_step.remove(process.simSiStripDigiSimLink) - process.mergedtruth.simHitCollections.tracker = [] - return process - - -def customise_DigiToRaw(process): - process.digi2raw_step.remove(process.siPixelRawData) - process.digi2raw_step.remove(process.rpcpacker) - return process - -def customise_RawToDigi(process): - process.raw2digi_step.remove(process.siPixelDigis) - return process - -def customise_Reco(process): - ## need changes to mixedtriplets step to use for imcreasing high eta efficiency - process.reconstruction.remove(process.pixelLessStepSeedClusterMask) - process.reconstruction.remove(process.castorreco) - process.reconstruction.remove(process.CastorTowerReco) - process.reconstruction.remove(process.ak7BasicJets) - process.reconstruction.remove(process.ak7CastorJetID) - #process.iterTracking.remove(process.PixelLessStep) - #process.iterTracking.remove(process.TobTecStep) - process.MixedTripletStep.remove(process.mixedTripletStepSeedsB) - process.mixedTripletStepSeeds = cms.EDProducer("SeedCombiner", - seedCollections = cms.VInputTag(cms.InputTag("mixedTripletStepSeedsA")) - ) - process.load("RecoTracker.IterativeTracking.HighPtTripletStep_cff") - from RecoTracker.IterativeTracking.HighPtTripletStep_cff import HighPtTripletStep - process.iterTracking = cms.Sequence(process.InitialStep* - process.HighPtTripletStep* - process.LowPtTripletStep* - process.PixelPairStep* - process.DetachedTripletStep* - process.MixedTripletStep* - #process.PixelLessStep* - #process.TobTecStep* - process.earlyGeneralTracks* - process.muonSeededStep* - process.preDuplicateMergingGeneralTracks* - process.generalTracksSequence* - process.ConvStep* - process.conversionStepTracks - ) - - - - - process.convClusters.oldClusterRemovalInfo=cms.InputTag("mixedTripletStepClusters") - process.convClusters.trajectories=cms.InputTag("mixedTripletStepTracks") - process.convClusters.overrideTrkQuals= cms.InputTag("mixedTripletStep") - process.mixedTripletStepSeedLayersA.layerList = cms.vstring('BPix1+BPix2+BPix3', - 'BPix1+BPix2+FPix1_pos', - 'BPix1+BPix2+FPix1_neg', - 'BPix1+FPix1_pos+FPix2_pos', - 'BPix1+FPix1_neg+FPix2_neg', - 'BPix2+FPix1_pos+FPix2_pos', - 'BPix2+FPix1_neg+FPix2_neg') - - process.earlyGeneralTracks.setsToMerge = cms.VPSet( cms.PSet( tLists=cms.vint32(0,1,2,3,4), pQual=cms.bool(True) )) - process.earlyGeneralTracks.hasSelector=cms.vint32(1,1,1,1,1) - process.earlyGeneralTracks.selectedTrackQuals = cms.VInputTag( - cms.InputTag("initialStepSelector","initialStep"), - cms.InputTag("highPtTripletStepSelector","highPtTripletStep"), - cms.InputTag("lowPtTripletStepSelector","lowPtTripletStep"), - cms.InputTag("pixelPairStepSelector","pixelPairStep"), - cms.InputTag("mixedTripletStep") - ) - process.earlyGeneralTracks.TrackProducers = cms.VInputTag( - cms.InputTag("initialStepTracks"), - cms.InputTag("highPtTripletStepTracks"), - cms.InputTag("lowPtTripletStepTracks"), - cms.InputTag("pixelPairStepTracks"), - cms.InputTag("mixedTripletStepTracks") - ) - - process.tripletElectronSeedLayers.BPix.skipClusters=cms.InputTag('mixedTripletStepSeedClusterMask') - process.tripletElectronSeedLayers.FPix.skipClusters=cms.InputTag('mixedTripletStepSeedClusterMask') - process.tripletElectronClusterMask.oldClusterRemovalInfo=cms.InputTag('mixedTripletStepSeedClusterMask') - - process.initialStepSeedClusterMask.oldClusterRemovalInfo=cms.InputTag("mixedTripletStepClusters") - process.newCombinedSeeds.seedCollections = cms.VInputTag(cms.InputTag('initialStepSeeds'), - cms.InputTag("highPtTripletStepSeeds"), - cms.InputTag('pixelPairStepSeeds'), - cms.InputTag('mixedTripletStepSeeds'), - cms.InputTag('tripletElectronSeeds'), - cms.InputTag('pixelPairElectronSeeds'), - cms.InputTag('stripPairElectronSeeds') ) - process.stripPairElectronSeedLayers.layerList = cms.vstring('BPix4+BPix5') # Optimize later - process.stripPairElectronSeedLayers.BPix = cms.PSet( - HitProducer = cms.string('siPixelRecHits'), - hitErrorRZ = cms.double(0.006), - useErrorsFromParam = cms.bool(True), - TTRHBuilder = cms.string('TTRHBuilderWithoutAngle4PixelPairs'), - skipClusters = cms.InputTag("pixelPairStepClusters"), - hitErrorRPhi = cms.double(0.0027) - ) - process.regionalCosmicTrackerSeeds.OrderedHitsFactoryPSet.LayerPSet.layerList = cms.vstring('BPix10+BPix9') # Optimize later - process.regionalCosmicTrackerSeeds.OrderedHitsFactoryPSet.LayerPSet.BPix = cms.PSet( - HitProducer = cms.string('siPixelRecHits'), - hitErrorRZ = cms.double(0.006), - useErrorsFromParam = cms.bool(True), - TTRHBuilder = cms.string('TTRHBuilderWithoutAngle4PixelPairs'), - skipClusters = cms.InputTag("pixelPairStepClusters"), - hitErrorRPhi = cms.double(0.0027) - ) - process.pixelTracks.SeedMergerPSet = cms.PSet( - layerListName = cms.string('PixelSeedMergerQuadruplets'), - addRemainingTriplets = cms.bool(False), - mergeTriplets = cms.bool(True), - ttrhBuilderLabel = cms.string('PixelTTRHBuilderWithoutAngle') - ) - process.initialStepSeedClusterMask.oldClusterRemovalInfo=cms.InputTag("mixedTripletStepClusters") - - # Need this line to stop error about missing siPixelDigis. - process.MeasurementTracker.inactivePixelDetectorLabels = cms.VInputTag() - process.load("SLHCUpgradeSimulations.Geometry.recoFromSimDigis_cff") - # Use with latest pixel geometry. Only used for seeds, so we can use the Phase1Tk file. - # We will need to turn it off for any steps that use the outer pixels as seeds. - process.ClusterShapeHitFilterESProducer.PixelShapeFile = cms.string('RecoPixelVertexing/PixelLowPtUtilities/data/pixelShape_Phase1Tk.par') - # Now make sure we us CPE Generic - process.mergedDuplicateTracks.TTRHBuilder = 'WithTrackAngle' - process.ctfWithMaterialTracks.TTRHBuilder = 'WithTrackAngle' - process.PixelCPEGenericESProducer.UseErrorsFromTemplates = cms.bool(False) - process.PixelCPEGenericESProducer.TruncatePixelCharge = cms.bool(False) - process.PixelCPEGenericESProducer.LoadTemplatesFromDB = cms.bool(False) - process.PixelCPEGenericESProducer.Upgrade = cms.bool(True) - process.PixelCPEGenericESProducer.IrradiationBiasCorrection = False - process.PixelCPEGenericESProducer.DoCosmics = False - process.siPixelRecHits.CPE = cms.string('PixelCPEGeneric') - #the quadruplet merger configuration - process.load("RecoPixelVertexing.PixelTriplets.quadrupletseedmerging_cff") - process.pixelseedmergerlayers.BPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) - process.pixelseedmergerlayers.BPix.HitProducer = cms.string("siPixelRecHits" ) - process.pixelseedmergerlayers.FPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) - process.pixelseedmergerlayers.FPix.HitProducer = cms.string("siPixelRecHits" ) - - process.highPtTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.detachedTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.initialStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.pixelPairStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.lowPtTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.convStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.mixedTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.muonSeededSeedsInOut.TrackerRecHitBuilder = cms.string('WithTrackAngle') - process.muonSeededTracksInOut.TTRHBuilder = cms.string('WithTrackAngle') - process.muons1stStep.TrackerKinkFinderParameters.TrackerRecHitBuilder=cms.string('WithTrackAngle') - process.regionalCosmicTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.cosmicsVetoTracksRaw.TTRHBuilder=cms.string('WithTrackAngle') - - return process - -def customise_condOverRides(process): - process.load('SLHCUpgradeSimulations.Geometry.fakeConditions_LongBarrel4LPS_2L2S_cff') - process.trackerNumberingSLHCGeometry.layerNumberPXB = cms.uint32(20) - process.trackerTopologyConstants.pxb_layerStartBit = cms.uint32(20) - process.trackerTopologyConstants.pxb_ladderStartBit = cms.uint32(12) - process.trackerTopologyConstants.pxb_moduleStartBit = cms.uint32(2) - process.trackerTopologyConstants.pxb_layerMask = cms.uint32(15) - process.trackerTopologyConstants.pxb_ladderMask = cms.uint32(255) - process.trackerTopologyConstants.pxb_moduleMask = cms.uint32(1023) - process.trackerTopologyConstants.pxf_diskStartBit = cms.uint32(18) - process.trackerTopologyConstants.pxf_bladeStartBit = cms.uint32(12) - process.trackerTopologyConstants.pxf_panelStartBit = cms.uint32(10) - process.trackerTopologyConstants.pxf_moduleMask = cms.uint32(255) - return process - - -def l1EventContent(process): - #extend the event content - - alist=['RAWSIM','FEVTDEBUG','FEVTDEBUGHLT','GENRAW','RAWSIMHLT','FEVT'] - for a in alist: - b=a+'output' - if hasattr(process,b): - getattr(process,b).outputCommands.append('keep PSimHits_g4SimHits_*_*') - getattr(process,b).outputCommands.append('keep SimTracks_g4SimHits_*_*') - getattr(process,b).outputCommands.append('keep SimVertexs_g4SimHits_*_*') - getattr(process,b).outputCommands.append('keep *_simSiPixelDigis_*_*') - getattr(process,b).outputCommands.append('keep *_genParticles_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkBeams_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkClustersFromPixelDigis_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkClustersFromSimHits_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkStubsFromPixelDigis_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkStubsFromSimHits_*_*') - getattr(process,b).outputCommands.append('keep *_siPixelRecHits_*_*') - #drop some bigger collections we don't think we need - getattr(process,b).outputCommands.append('drop PSimHits_g4SimHits_EcalHitsEB_*') - getattr(process,b).outputCommands.append('drop PSimHits_g4SimHits_EcalHitsEE_*') - getattr(process,b).outputCommands.append('drop *_L1TkStubsFromSimHits_StubsFail_*') - return process - -def customise_TrackTrigger(process): - process.TTStubAlgorithm_tab2013_PixelDigi_ = cms.ESProducer("TTStubAlgorithm_tab2013_PixelDigi_", - zMatchingPS = cms.bool(False), - zMatching2S = cms.bool(True), - BarrelCut = cms.vdouble( 0, 2.5, 2.5, 3, 3, 4.5, 4.5, 5.5, 5.5, 7, 7 ), #Use 0 as dummy to have direct access using DetId to the correct element - EndcapCutSet = cms.VPSet( - cms.PSet( EndcapCut = cms.vdouble( 0 ) ), #Use 0 as dummy to have direct access using DetId to the correct element - ) - ) - - process.StackedTrackerGeometryESModule = cms.ESProducer( "StackedTrackerGeometryESModule", - truncation_precision = cms.uint32(2), - z_window = cms.double(4.0), - phi_window = cms.double(0.015), - radial_window = cms.double(1.0), - make_debug_file = cms.bool(True), - - # Extras for CBC3 chip - partitionsPerRoc = cms.int32(4), - CBC3_MaxStubs = cms.uint32(3), - # Double tab2013 table as CBC3 chip uses full width -- this table for LB's (not verified numbers) design - BarrelCut = cms.vdouble( 0, 5, 5, 6, 6, 9, 9, 11, 11, 14, 14 ), #Use 0 as dummy to have direct access using DetId to the correct element - EndcapCutSet = cms.VPSet( - cms.PSet( EndcapCut = cms.vdouble( 0 ) ), #Use 0 as dummy to have direct access using DetId to the correct element - ) - ) - - - return process - diff --git a/SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_6PS.py b/SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_6PS.py deleted file mode 100644 index 7b4d6526e49e0..0000000000000 --- a/SLHCUpgradeSimulations/Configuration/python/phase2TkCustoms_LB_6PS.py +++ /dev/null @@ -1,264 +0,0 @@ -import FWCore.ParameterSet.Config as cms -#GEN-SIM so far... -def customise(process): - if hasattr(process,'DigiToRaw'): - process=customise_DigiToRaw(process) - if hasattr(process,'RawToDigi'): - process=customise_RawToDigi(process) - if hasattr(process,'reconstruction'): - process=customise_Reco(process) - if hasattr(process,'digitisation_step'): - process=customise_Digi(process) - if hasattr(process,'dqmoffline_step'): - process=customise_DQM(process) - if hasattr(process,'dqmHarvesting'): - process=customise_harvesting(process) - if hasattr(process,'validation_step'): - process=customise_Validation(process) - process=customise_condOverRides(process) - if hasattr(process,'L1TrackTrigger_step'): - process=customise_TrackTrigger(process) - - return process - -def customise_Digi(process): - process.mix.digitizers.pixel.MissCalibrate = False - process.mix.digitizers.pixel.LorentzAngle_DB = False - process.mix.digitizers.pixel.killModules = False - process.mix.digitizers.pixel.useDB = False - process.mix.digitizers.pixel.DeadModules_DB = False - process.mix.digitizers.pixel.NumPixelBarrel = cms.int32(12) - process.mix.digitizers.pixel.NumPixelEndcap = cms.int32(3) - process.mix.digitizers.pixel.ThresholdInElectrons_FPix = cms.double(2000.0) - process.mix.digitizers.pixel.ThresholdInElectrons_BPix = cms.double(2000.0) - process.mix.digitizers.pixel.ThresholdInElectrons_BPix_L1 = cms.double(2000.0) - process.mix.digitizers.pixel.thePixelColEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelChipEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelColEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelChipEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(False) - process.mix.digitizers.strip.ROUList = cms.vstring("g4SimHitsTrackerHitsPixelBarrelLowTof", - 'g4SimHitsTrackerHitsPixelEndcapLowTof') - process.digitisation_step.remove(process.simSiStripDigiSimLink) - process.mergedtruth.simHitCollections.tracker = [] - return process - - -def customise_DigiToRaw(process): - process.digi2raw_step.remove(process.siPixelRawData) - process.digi2raw_step.remove(process.rpcpacker) - return process - -def customise_RawToDigi(process): - process.raw2digi_step.remove(process.siPixelDigis) - return process - -def customise_Reco(process): - ## need changes to mixedtriplets step to use for imcreasing high eta efficiency - process.reconstruction.remove(process.pixelLessStepSeedClusterMask) - process.reconstruction.remove(process.castorreco) - process.reconstruction.remove(process.CastorTowerReco) - process.reconstruction.remove(process.ak7BasicJets) - process.reconstruction.remove(process.ak7CastorJetID) - #process.iterTracking.remove(process.PixelLessStep) - #process.iterTracking.remove(process.TobTecStep) - process.MixedTripletStep.remove(process.mixedTripletStepSeedsB) - process.mixedTripletStepSeeds = cms.EDProducer("SeedCombiner", - seedCollections = cms.VInputTag(cms.InputTag("mixedTripletStepSeedsA")) - ) - process.load("RecoTracker.IterativeTracking.HighPtTripletStep_cff") - from RecoTracker.IterativeTracking.HighPtTripletStep_cff import HighPtTripletStep - process.iterTracking = cms.Sequence(process.InitialStep* - process.HighPtTripletStep* - process.LowPtTripletStep* - process.PixelPairStep* - process.DetachedTripletStep* - process.MixedTripletStep* - #process.PixelLessStep* - #process.TobTecStep* - process.earlyGeneralTracks* - process.muonSeededStep* - process.preDuplicateMergingGeneralTracks* - process.generalTracksSequence* - process.ConvStep* - process.conversionStepTracks - ) - - - - - process.convClusters.oldClusterRemovalInfo=cms.InputTag("mixedTripletStepClusters") - process.convClusters.trajectories=cms.InputTag("mixedTripletStepTracks") - process.convClusters.overrideTrkQuals= cms.InputTag("mixedTripletStep") - process.mixedTripletStepSeedLayersA.layerList = cms.vstring('BPix1+BPix2+BPix3', - 'BPix1+BPix2+FPix1_pos', - 'BPix1+BPix2+FPix1_neg', - 'BPix1+FPix1_pos+FPix2_pos', - 'BPix1+FPix1_neg+FPix2_neg', - 'BPix2+FPix1_pos+FPix2_pos', - 'BPix2+FPix1_neg+FPix2_neg') - - process.earlyGeneralTracks.setsToMerge = cms.VPSet( cms.PSet( tLists=cms.vint32(0,1,2,3,4), pQual=cms.bool(True) )) - process.earlyGeneralTracks.hasSelector=cms.vint32(1,1,1,1,1) - process.earlyGeneralTracks.selectedTrackQuals = cms.VInputTag( - cms.InputTag("initialStepSelector","initialStep"), - cms.InputTag("highPtTripletStepSelector","highPtTripletStep"), - cms.InputTag("lowPtTripletStepSelector","lowPtTripletStep"), - cms.InputTag("pixelPairStepSelector","pixelPairStep"), - cms.InputTag("mixedTripletStep") - ) - process.earlyGeneralTracks.TrackProducers = cms.VInputTag( - cms.InputTag("initialStepTracks"), - cms.InputTag("highPtTripletStepTracks"), - cms.InputTag("lowPtTripletStepTracks"), - cms.InputTag("pixelPairStepTracks"), - cms.InputTag("mixedTripletStepTracks") - ) - - process.tripletElectronSeedLayers.BPix.skipClusters=cms.InputTag('mixedTripletStepSeedClusterMask') - process.tripletElectronSeedLayers.FPix.skipClusters=cms.InputTag('mixedTripletStepSeedClusterMask') - process.tripletElectronClusterMask.oldClusterRemovalInfo=cms.InputTag('mixedTripletStepSeedClusterMask') - - process.initialStepSeedClusterMask.oldClusterRemovalInfo=cms.InputTag("mixedTripletStepClusters") - process.newCombinedSeeds.seedCollections = cms.VInputTag(cms.InputTag('initialStepSeeds'), - cms.InputTag("highPtTripletStepSeeds"), - cms.InputTag('pixelPairStepSeeds'), - cms.InputTag('mixedTripletStepSeeds'), - cms.InputTag('tripletElectronSeeds'), - cms.InputTag('pixelPairElectronSeeds'), - cms.InputTag('stripPairElectronSeeds') ) - process.stripPairElectronSeedLayers.layerList = cms.vstring('BPix4+BPix5') # Optimize later - process.stripPairElectronSeedLayers.BPix = cms.PSet( - HitProducer = cms.string('siPixelRecHits'), - hitErrorRZ = cms.double(0.006), - useErrorsFromParam = cms.bool(True), - TTRHBuilder = cms.string('TTRHBuilderWithoutAngle4PixelPairs'), - skipClusters = cms.InputTag("pixelPairStepClusters"), - hitErrorRPhi = cms.double(0.0027) - ) - process.regionalCosmicTrackerSeeds.OrderedHitsFactoryPSet.LayerPSet.layerList = cms.vstring('BPix12+BPix11') # Optimize later - process.regionalCosmicTrackerSeeds.OrderedHitsFactoryPSet.LayerPSet.BPix = cms.PSet( - HitProducer = cms.string('siPixelRecHits'), - hitErrorRZ = cms.double(0.006), - useErrorsFromParam = cms.bool(True), - TTRHBuilder = cms.string('TTRHBuilderWithoutAngle4PixelPairs'), - skipClusters = cms.InputTag("pixelPairStepClusters"), - hitErrorRPhi = cms.double(0.0027) - ) - process.pixelTracks.SeedMergerPSet = cms.PSet( - layerListName = cms.string('PixelSeedMergerQuadruplets'), - addRemainingTriplets = cms.bool(False), - mergeTriplets = cms.bool(True), - ttrhBuilderLabel = cms.string('PixelTTRHBuilderWithoutAngle') - ) - process.initialStepSeedClusterMask.oldClusterRemovalInfo=cms.InputTag("mixedTripletStepClusters") - - # Need this line to stop error about missing siPixelDigis. - process.MeasurementTracker.inactivePixelDetectorLabels = cms.VInputTag() - process.load("SLHCUpgradeSimulations.Geometry.recoFromSimDigis_cff") - # Use with latest pixel geometry. Only used for seeds, so we can use the Phase1Tk file. - # We will need to turn it off for any steps that use the outer pixels as seeds. - process.ClusterShapeHitFilterESProducer.PixelShapeFile = cms.string('RecoPixelVertexing/PixelLowPtUtilities/data/pixelShape_Phase1Tk.par') - # Now make sure we us CPE Generic - process.mergedDuplicateTracks.TTRHBuilder = 'WithTrackAngle' - process.ctfWithMaterialTracks.TTRHBuilder = 'WithTrackAngle' - process.PixelCPEGenericESProducer.UseErrorsFromTemplates = cms.bool(False) - process.PixelCPEGenericESProducer.TruncatePixelCharge = cms.bool(False) - process.PixelCPEGenericESProducer.LoadTemplatesFromDB = cms.bool(False) - process.PixelCPEGenericESProducer.Upgrade = cms.bool(True) - process.PixelCPEGenericESProducer.IrradiationBiasCorrection = False - process.PixelCPEGenericESProducer.DoCosmics = False - process.siPixelRecHits.CPE = cms.string('PixelCPEGeneric') - #the quadruplet merger configuration - process.load("RecoPixelVertexing.PixelTriplets.quadrupletseedmerging_cff") - process.pixelseedmergerlayers.BPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) - process.pixelseedmergerlayers.BPix.HitProducer = cms.string("siPixelRecHits" ) - process.pixelseedmergerlayers.FPix.TTRHBuilder = cms.string("PixelTTRHBuilderWithoutAngle" ) - process.pixelseedmergerlayers.FPix.HitProducer = cms.string("siPixelRecHits" ) - - process.highPtTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.detachedTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.initialStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.pixelPairStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.lowPtTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.convStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.mixedTripletStepTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.muonSeededSeedsInOut.TrackerRecHitBuilder = cms.string('WithTrackAngle') - process.muonSeededTracksInOut.TTRHBuilder = cms.string('WithTrackAngle') - process.muons1stStep.TrackerKinkFinderParameters.TrackerRecHitBuilder=cms.string('WithTrackAngle') - process.regionalCosmicTracks.TTRHBuilder=cms.string('WithTrackAngle') - process.cosmicsVetoTracksRaw.TTRHBuilder=cms.string('WithTrackAngle') - - return process - -def customise_condOverRides(process): - process.load('SLHCUpgradeSimulations.Geometry.fakeConditions_LongBarrel6PS_cff') - process.trackerNumberingSLHCGeometry.layerNumberPXB = cms.uint32(20) - process.trackerTopologyConstants.pxb_layerStartBit = cms.uint32(20) - process.trackerTopologyConstants.pxb_ladderStartBit = cms.uint32(12) - process.trackerTopologyConstants.pxb_moduleStartBit = cms.uint32(2) - process.trackerTopologyConstants.pxb_layerMask = cms.uint32(15) - process.trackerTopologyConstants.pxb_ladderMask = cms.uint32(255) - process.trackerTopologyConstants.pxb_moduleMask = cms.uint32(1023) - process.trackerTopologyConstants.pxf_diskStartBit = cms.uint32(18) - process.trackerTopologyConstants.pxf_bladeStartBit = cms.uint32(12) - process.trackerTopologyConstants.pxf_panelStartBit = cms.uint32(10) - process.trackerTopologyConstants.pxf_moduleMask = cms.uint32(255) - return process - - -def l1EventContent(process): - #extend the event content - - alist=['RAWSIM','FEVTDEBUG','FEVTDEBUGHLT','GENRAW','RAWSIMHLT','FEVT'] - for a in alist: - b=a+'output' - if hasattr(process,b): - getattr(process,b).outputCommands.append('keep PSimHits_g4SimHits_*_*') - getattr(process,b).outputCommands.append('keep SimTracks_g4SimHits_*_*') - getattr(process,b).outputCommands.append('keep SimVertexs_g4SimHits_*_*') - getattr(process,b).outputCommands.append('keep *_simSiPixelDigis_*_*') - getattr(process,b).outputCommands.append('keep *_genParticles_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkBeams_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkClustersFromPixelDigis_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkClustersFromSimHits_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkStubsFromPixelDigis_*_*') - getattr(process,b).outputCommands.append('keep *_L1TkStubsFromSimHits_*_*') - getattr(process,b).outputCommands.append('keep *_siPixelRecHits_*_*') - #drop some bigger collections we don't think we need - getattr(process,b).outputCommands.append('drop PSimHits_g4SimHits_EcalHitsEB_*') - getattr(process,b).outputCommands.append('drop PSimHits_g4SimHits_EcalHitsEE_*') - getattr(process,b).outputCommands.append('drop *_L1TkStubsFromSimHits_StubsFail_*') - return process - -def customise_TrackTrigger(process): - process.TTStubAlgorithm_tab2013_PixelDigi_ = cms.ESProducer("TTStubAlgorithm_tab2013_PixelDigi_", - zMatchingPS = cms.bool(False), - zMatching2S = cms.bool(True), - BarrelCut = cms.vdouble( 0, 2.5, 2.5, 3, 3, 4.5, 4.5, 5.5, 5.5, 7, 7 ), #Use 0 as dummy to have direct access using DetId to the correct element - EndcapCutSet = cms.VPSet( - cms.PSet( EndcapCut = cms.vdouble( 0 ) ), #Use 0 as dummy to have direct access using DetId to the correct element - ) - ) - - process.StackedTrackerGeometryESModule = cms.ESProducer( "StackedTrackerGeometryESModule", - truncation_precision = cms.uint32(2), - z_window = cms.double(4.0), - phi_window = cms.double(0.015), - radial_window = cms.double(1.0), - make_debug_file = cms.bool(True), - - # Extras for CBC3 chip - partitionsPerRoc = cms.int32(4), - CBC3_MaxStubs = cms.uint32(3), - # Double tab2013 table as CBC3 chip uses full width -- this table for LB's (not verified numbers) design - BarrelCut = cms.vdouble( 0, 5, 5, 6, 6, 9, 9, 11, 11, 14, 14 ), #Use 0 as dummy to have direct access using DetId to the correct element - EndcapCutSet = cms.VPSet( - cms.PSet( EndcapCut = cms.vdouble( 0 ) ), #Use 0 as dummy to have direct access using DetId to the correct element - ) - ) - - - return process From e741be703ee1dab3b623d280f1a141e42c98bada Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:14:31 +0200 Subject: [PATCH 174/252] adding the 2017dev and 2023muondev in CombinedCustom --- .../Configuration/python/combinedCustoms.py | 35 ++++++++++--------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py index 1a4207a33300f..a5a76c9b02615 100644 --- a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py @@ -3,22 +3,19 @@ from SLHCUpgradeSimulations.Configuration.phase2TkCustomsBE import customise as customiseBE from SLHCUpgradeSimulations.Configuration.phase2TkCustomsBE5D import customise as customiseBE5D from SLHCUpgradeSimulations.Configuration.phase2TkCustomsBE5DPixel10D import customise as customiseBE5DPixel10D +from SLHCUpgradeSimulations.Configuration.phase2TkCustomsBE5DPixel10Ddev import customise as customiseBE5DPixel10Ddev from SLHCUpgradeSimulations.Configuration.phase2TkCustomsBE import l1EventContent as customise_ev_BE from SLHCUpgradeSimulations.Configuration.phase2TkCustomsBE5D import l1EventContent as customise_ev_BE5D from SLHCUpgradeSimulations.Configuration.phase2TkCustomsBE5DPixel10D import l1EventContent as customise_ev_BE5DPixel10D -from SLHCUpgradeSimulations.Configuration.phase2TkCustoms_LB_6PS import customise as customiseLB6PS -from SLHCUpgradeSimulations.Configuration.phase2TkCustoms_LB_4LPS_2L2S import customise as customiseLB4LPS_2L2S -from SLHCUpgradeSimulations.Configuration.phase2TkCustoms_LB_6PS import l1EventContent as customise_ev_LB6PS -from SLHCUpgradeSimulations.Configuration.phase2TkCustoms_LB_4LPS_2L2S import l1EventContent as customise_ev_LB4LPS_2L2S from SLHCUpgradeSimulations.Configuration.phase1TkCustomsPixel10D import customise as customisePhase1TkPixel10D from SLHCUpgradeSimulations.Configuration.combinedCustoms_TTI import customise as customiseTTI from SLHCUpgradeSimulations.Configuration.combinedCustoms_TTI import l1EventContent_TTI as customise_ev_l1tracker from SLHCUpgradeSimulations.Configuration.combinedCustoms_TTI import l1EventContent_TTI_forHLT from SLHCUpgradeSimulations.Configuration.customise_mixing import customise_NoCrossing -from SLHCUpgradeSimulations.Configuration.phase1TkCustoms import customise as customisePhase1Tk +from SLHCUpgradeSimulations.Configuration.phase1TkCustomsdev import customise as customisePhase1Tkdev from SLHCUpgradeSimulations.Configuration.HCalCustoms import customise_HcalPhase1, customise_HcalPhase0, customise_HcalPhase2 from SLHCUpgradeSimulations.Configuration.gemCustoms import customise2019 as customise_gem2019 from SLHCUpgradeSimulations.Configuration.gemCustoms import customise2023 as customise_gem2023 @@ -62,21 +59,16 @@ def cust_phase2_BE(process): process=jetCustoms.customise_jets(process) return process -def cust_phase2_LB6PS(process): #obsolete - process=customisePostLS1(process) - process=customiseLB6PS(process) - process=customise_ev_LB6PS(process) - return process - -def cust_phase2_LB4LPS_2L2S(process):#obsolete +def cust_2017(process): process=customisePostLS1(process) - process=customiseLB4LPS_2L2S(process) - process=customise_ev_LB4LPS_2L2S(process) + process=customisePhase1Tk(process) + process=customise_HcalPhase0(process) +# process=fixRPCConditions(process) return process -def cust_2017(process): +def cust_2017dev(process): process=customisePostLS1(process) - process=customisePhase1Tk(process) + process=customisePhase1Tkdev(process) process=customise_HcalPhase0(process) # process=fixRPCConditions(process) return process @@ -379,6 +371,17 @@ def cust_2023Muon(process): process=jetCustoms.customise_jets(process) return process +def cust_2023Muondev(process): + process=customisePostLS1(process) + process=customiseBE5DPixel10Ddev(process) + process=customise_HcalPhase2(process) + process=customise_ev_BE5DPixel10D(process) + process=customise_gem2023(process) + process=customise_rpc(process) + process=customise_me0(process) + process=jetCustoms.customise_jets(process) + return process + def cust_2023TTI(process): process=customisePostLS1(process) process=customiseTTI(process) From 214c0dee7aea27a04398eaa31a0a2c81e1114a02 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:15:55 +0200 Subject: [PATCH 175/252] adding the 2017dev and 2023muondev in runThematrix --- .../python/relval_steps.py | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 564203d116c2c..53bd57fe85aed 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1098,8 +1098,8 @@ def genvalid(fragment,d,suffix='all',fi=''): upgradeKeys=['2017', '2019', 'BE5D', - '2017Fast', - 'BE5DFast', + '2017dev', + 'Extended2023Muondev', 'BE5DForwardFast', '2019WithGEM', 'BE5DPixel10D', @@ -1128,8 +1128,8 @@ def genvalid(fragment,d,suffix='all',fi=''): '2019Aging' : 'Extended2019', 'BE5D' : 'ExtendedPhase2TkBE5D', 'BE5DPixel10D' : 'ExtendedPhase2TkBE5DPixel10D', - '2017Fast' : 'Extended2017', - 'BE5DFast' : 'ExtendedPhase2TkBE', + '2017dev' : 'Extended2017', + 'Extended2023Muondev' : 'Extended2023Muon,Extended2023MuonReco', 'BE5DForwardFast' : 'ExtendedPhase2TkBEForward', 'Extended2023' : 'Extended2023,Extended2023Reco', 'Extended2023HGCalMuon' : 'Extended2023HGCalMuon,Extended2023HGCalMuonReco', @@ -1154,8 +1154,8 @@ def genvalid(fragment,d,suffix='all',fi=''): '2019Aging' : 'W19_300_62E2::All', 'BE5D' : 'auto:upgradePLS3', 'BE5DPixel10D' : 'auto:upgradePLS3', - '2017Fast' : 'auto:upgrade2017', - 'BE5DFast' : 'auto:upgrade2019', + '2017dev' : 'auto:upgrade2017', + 'Extended2023Muondev' : 'auto:upgradePLS3', 'BE5DForwardFast' : 'auto:upgrade2019', 'Extended2023' : 'auto:upgradePLS3', 'Extended2023HGCalMuon' : 'auto:upgradePLS3', @@ -1180,8 +1180,8 @@ def genvalid(fragment,d,suffix='all',fi=''): '2019Aging' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_2019,SLHCUpgradeSimulations/Configuration/aging.customise_aging_300', 'BE5D' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_phase2_BE5D', 'BE5DPixel10D' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_phase2_BE5DPixel10D', - '2017Fast' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.fastsimDefault', - 'BE5DFast' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.fastsimPhase2', + '2017dev' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_2017dev', + 'Extended2023Muondev' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_2023Muondev', 'BE5DForwardFast' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.fastsimPhase2', 'Extended2023' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_2023', 'Extended2023HGCalMuon' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_2023HGCalMuon', @@ -1219,8 +1219,8 @@ def genvalid(fragment,d,suffix='all',fi=''): '2019Aging':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'BE5D':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'BE5DPixel10D':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - '2017Fast':['FastSim','HARVESTFast'], - 'BE5DFast':['FastSim','HARVESTFast'], + '2017dev':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023Muondev':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'BE5DForwardFast':['FastSim','HARVESTFast'], 'Extended2023':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCalMuon':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], From 4e80d05d23cd4799eff2caee8b7412a09d1dc6ac Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:30:33 +0200 Subject: [PATCH 176/252] 2017dev scenario --- .../python/GeometryExtended2017devReco_cff.py | 33 +++++++++++++++++++ .../python/GeometryExtended2017dev_cff.py | 9 +++++ 2 files changed, 42 insertions(+) create mode 100644 Configuration/Geometry/python/GeometryExtended2017devReco_cff.py create mode 100644 Configuration/Geometry/python/GeometryExtended2017dev_cff.py diff --git a/Configuration/Geometry/python/GeometryExtended2017devReco_cff.py b/Configuration/Geometry/python/GeometryExtended2017devReco_cff.py new file mode 100644 index 0000000000000..cbc45770bbda8 --- /dev/null +++ b/Configuration/Geometry/python/GeometryExtended2017devReco_cff.py @@ -0,0 +1,33 @@ +import FWCore.ParameterSet.Config as cms + +# Ideal geometry, needed for transient ECAL alignement +from Configuration.Geometry.GeometryExtended2017_cff import * + + +# Reconstruction geometry services +# Tracking Geometry +#bah - well, this is not a cfi! +from Geometry.CommonDetUnit.globalTrackingSLHCGeometry_cfi import * + +#Tracker +from RecoTracker.GeometryESProducer.TrackerRecoGeometryESProducer_cfi import * +from Geometry.TrackerNumberingBuilder.trackerTopologyConstants_cfi import * + +#Muon +from Geometry.MuonNumbering.muonNumberingInitialization_cfi import * +from RecoMuon.DetLayers.muonDetLayerGeometry_cfi import * + +# Alignment +from Geometry.TrackerGeometryBuilder.idealForDigiTrackerSLHCGeometry_cff import * +from Geometry.CSCGeometryBuilder.idealForDigiCscGeometry_cff import * +from Geometry.DTGeometryBuilder.idealForDigiDtGeometry_cff import * +trackerSLHCGeometry.applyAlignment = cms.bool(False) + +# Calorimeters +from Geometry.CaloEventSetup.CaloTopology_cfi import * +from Geometry.CaloEventSetup.CaloGeometry_cff import * +from Geometry.CaloEventSetup.EcalTrigTowerConstituents_cfi import * +from Geometry.EcalMapping.EcalMapping_cfi import * +from Geometry.EcalMapping.EcalMappingRecord_cfi import * +from Geometry.HcalCommonData.hcalRecNumberingInitialization_cfi import * + diff --git a/Configuration/Geometry/python/GeometryExtended2017dev_cff.py b/Configuration/Geometry/python/GeometryExtended2017dev_cff.py new file mode 100644 index 0000000000000..4d61fa017c196 --- /dev/null +++ b/Configuration/Geometry/python/GeometryExtended2017dev_cff.py @@ -0,0 +1,9 @@ +import FWCore.ParameterSet.Config as cms + +# +# Geometry master configuration +# +# Ideal geometry, needed for simulation +from Geometry.CMSCommonData.cmsExtendedGeometry2017XML_cfi import * +from Geometry.TrackerNumberingBuilder.trackerNumberingSLHCGeometry_cfi import * +from Geometry.HcalCommonData.hcalSimNumberingInitialization_cfi import * From bfb5300d2e5f1a62830f94558fbdf42b8861e6a5 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:33:48 +0200 Subject: [PATCH 177/252] 2023Muondev scenario --- .../GeometryExtended2023MuondevReco_cff.py | 53 +++++++++++++++++++ .../python/GeometryExtended2023Muondev_cff.py | 8 +++ 2 files changed, 61 insertions(+) create mode 100644 Configuration/Geometry/python/GeometryExtended2023MuondevReco_cff.py create mode 100644 Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py diff --git a/Configuration/Geometry/python/GeometryExtended2023MuondevReco_cff.py b/Configuration/Geometry/python/GeometryExtended2023MuondevReco_cff.py new file mode 100644 index 0000000000000..d30373e1e622d --- /dev/null +++ b/Configuration/Geometry/python/GeometryExtended2023MuondevReco_cff.py @@ -0,0 +1,53 @@ +import FWCore.ParameterSet.Config as cms + +# Ideal geometry, needed for transient ECAL alignement +from Configuration.Geometry.GeometryExtended2023Muon_cff import * + +# Reconstruction geometry services +# Tracking Geometry +#bah - well, this is not a cfi! +from Geometry.CommonDetUnit.globalTrackingSLHCGeometry_cfi import * + +#Tracker +from RecoTracker.GeometryESProducer.TrackerRecoGeometryESProducer_cfi import * +from Geometry.TrackerNumberingBuilder.trackerTopologyConstants_cfi import * + +#Muon +from Geometry.MuonNumbering.muonNumberingInitialization_cfi import * +from RecoMuon.DetLayers.muonDetLayerGeometry_cfi import * +from Geometry.GEMGeometryBuilder.gemGeometry_cfi import * +from Geometry.GEMGeometryBuilder.me0Geometry_cfi import * + +# Alignment +from Geometry.TrackerGeometryBuilder.idealForDigiTrackerSLHCGeometry_cff import * +from Geometry.CSCGeometryBuilder.idealForDigiCscGeometry_cff import * +from Geometry.DTGeometryBuilder.idealForDigiDtGeometry_cff import * +trackerSLHCGeometry.applyAlignment = cms.bool(False) + +# Calorimeters +from Geometry.CaloEventSetup.CaloTopology_cfi import * + +from Geometry.CaloEventSetup.CaloGeometryBuilder_cfi import * + +CaloGeometryBuilder = cms.ESProducer("CaloGeometryBuilder", + SelectedCalos = cms.vstring('HCAL' , + 'ZDC' , + 'CASTOR' , + 'EcalBarrel' , + 'TOWER' ) +) + +from Geometry.EcalAlgo.EcalBarrelGeometry_cfi import * + +## Include EE and ES back temporarily +from Geometry.CaloEventSetup.CaloGeometry_cff import * + +from Geometry.HcalEventSetup.HcalGeometry_cfi import * +from Geometry.HcalEventSetup.CaloTowerGeometry_cfi import * +from Geometry.HcalEventSetup.HcalTopology_cfi import * +from Geometry.ForwardGeometry.ForwardGeometry_cfi import * +from Geometry.CaloEventSetup.EcalTrigTowerConstituents_cfi import * +from Geometry.EcalMapping.EcalMapping_cfi import * +from Geometry.EcalMapping.EcalMappingRecord_cfi import * +from Geometry.HcalCommonData.hcalRecNumberingInitialization_cfi import * + diff --git a/Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py b/Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py new file mode 100644 index 0000000000000..1be5749a59065 --- /dev/null +++ b/Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py @@ -0,0 +1,8 @@ +import FWCore.ParameterSet.Config as cms +# +# Geometry master configuration +# +# Ideal geometry, needed for simulation +from Geometry.CMSCommonData.cmsExtendedGeometry2023MuonXML_cfi import * +from Geometry.TrackerNumberingBuilder.trackerNumberingSLHCGeometry_cfi import * +from Geometry.HcalCommonData.hcalSimNumberingInitialization_cfi import * From 02b9406417a42bdcc1515ed0cff7bf0fc029ff68 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:49:08 +0200 Subject: [PATCH 178/252] updating runthematrix accordingly --- Configuration/PyReleaseValidation/python/relval_steps.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 53bd57fe85aed..3cba12972434c 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1128,8 +1128,8 @@ def genvalid(fragment,d,suffix='all',fi=''): '2019Aging' : 'Extended2019', 'BE5D' : 'ExtendedPhase2TkBE5D', 'BE5DPixel10D' : 'ExtendedPhase2TkBE5DPixel10D', - '2017dev' : 'Extended2017', - 'Extended2023Muondev' : 'Extended2023Muon,Extended2023MuonReco', + '2017dev' : 'Extended2017dev,Extended2017devReco', + 'Extended2023Muondev' : 'Extended2023Muondev,Extended2023MuondevReco', 'BE5DForwardFast' : 'ExtendedPhase2TkBEForward', 'Extended2023' : 'Extended2023,Extended2023Reco', 'Extended2023HGCalMuon' : 'Extended2023HGCalMuon,Extended2023HGCalMuonReco', From a369f69f1fca364c82d7452a7989b696733fa3a2 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:52:23 +0200 Subject: [PATCH 179/252] 2017dev + 2023Muondev scenario --- .../cmsExtendedGeometry2017devXML_cfi.py | 283 ++++++++++++++++++ .../cmsExtendedGeometry2023MuondevXML_cfi.py | 157 ++++++++++ 2 files changed, 440 insertions(+) create mode 100644 Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py create mode 100644 Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py new file mode 100644 index 0000000000000..872b60160b8a8 --- /dev/null +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py @@ -0,0 +1,283 @@ +import FWCore.ParameterSet.Config as cms + +## 2015 + new phase 1 pixel detector + +XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", + geomXMLFiles = cms.vstring('Geometry/CMSCommonData/data/materials.xml', + 'Geometry/CMSCommonData/data/rotations.xml', + 'Geometry/CMSCommonData/data/extend/cmsextent.xml', + 'Geometry/CMSCommonData/data/PhaseI/cms.xml', + 'Geometry/CMSCommonData/data/cmsMother.xml', + 'Geometry/CMSCommonData/data/eta3/etaMax.xml', + 'Geometry/CMSCommonData/data/cmsTracker.xml', + 'Geometry/CMSCommonData/data/caloBase.xml', + 'Geometry/CMSCommonData/data/cmsCalo.xml', + 'Geometry/CMSCommonData/data/muonBase.xml', + 'Geometry/CMSCommonData/data/cmsMuon.xml', + 'Geometry/CMSCommonData/data/mgnt.xml', + 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/cmsBeam.xml', + 'Geometry/CMSCommonData/data/muonMB.xml', + 'Geometry/CMSCommonData/data/muonMagnet.xml', + 'Geometry/CMSCommonData/data/cavern.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdMaterials.xml', + 'Geometry/TrackerCommonData/data/pixfwdCommon.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdCylinder.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdDisks.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdInnerDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdInnerDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdInnerDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdOuterDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdOuterDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdOuterDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdblade1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdblade2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixfwdblade3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarmaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladder.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbar.xml', + 'Geometry/TrackerCommonData/data/tibtidcommonmaterial.xml', + 'Geometry/TrackerCommonData/data/tibmaterial.xml', + 'Geometry/TrackerCommonData/data/tibmodpar.xml', + 'Geometry/TrackerCommonData/data/tibmodule0.xml', + 'Geometry/TrackerCommonData/data/tibmodule0a.xml', + 'Geometry/TrackerCommonData/data/tibmodule0b.xml', + 'Geometry/TrackerCommonData/data/tibmodule2.xml', + 'Geometry/TrackerCommonData/data/tibstringpar.xml', + 'Geometry/TrackerCommonData/data/tibstring0ll.xml', + 'Geometry/TrackerCommonData/data/tibstring0lr.xml', + 'Geometry/TrackerCommonData/data/tibstring0ul.xml', + 'Geometry/TrackerCommonData/data/tibstring0ur.xml', + 'Geometry/TrackerCommonData/data/tibstring0.xml', + 'Geometry/TrackerCommonData/data/tibstring1ll.xml', + 'Geometry/TrackerCommonData/data/tibstring1lr.xml', + 'Geometry/TrackerCommonData/data/tibstring1ul.xml', + 'Geometry/TrackerCommonData/data/tibstring1ur.xml', + 'Geometry/TrackerCommonData/data/tibstring1.xml', + 'Geometry/TrackerCommonData/data/tibstring2ll.xml', + 'Geometry/TrackerCommonData/data/tibstring2lr.xml', + 'Geometry/TrackerCommonData/data/tibstring2ul.xml', + 'Geometry/TrackerCommonData/data/tibstring2ur.xml', + 'Geometry/TrackerCommonData/data/tibstring2.xml', + 'Geometry/TrackerCommonData/data/tibstring3ll.xml', + 'Geometry/TrackerCommonData/data/tibstring3lr.xml', + 'Geometry/TrackerCommonData/data/tibstring3ul.xml', + 'Geometry/TrackerCommonData/data/tibstring3ur.xml', + 'Geometry/TrackerCommonData/data/tibstring3.xml', + 'Geometry/TrackerCommonData/data/tiblayerpar.xml', + 'Geometry/TrackerCommonData/data/tiblayer0.xml', + 'Geometry/TrackerCommonData/data/tiblayer1.xml', + 'Geometry/TrackerCommonData/data/tiblayer2.xml', + 'Geometry/TrackerCommonData/data/tiblayer3.xml', + 'Geometry/TrackerCommonData/data/tib.xml', + 'Geometry/TrackerCommonData/data/tidmaterial.xml', + 'Geometry/TrackerCommonData/data/tidmodpar.xml', + 'Geometry/TrackerCommonData/data/tidmodule0.xml', + 'Geometry/TrackerCommonData/data/tidmodule0r.xml', + 'Geometry/TrackerCommonData/data/tidmodule0l.xml', + 'Geometry/TrackerCommonData/data/tidmodule1.xml', + 'Geometry/TrackerCommonData/data/tidmodule1r.xml', + 'Geometry/TrackerCommonData/data/tidmodule1l.xml', + 'Geometry/TrackerCommonData/data/tidmodule2.xml', + 'Geometry/TrackerCommonData/data/tidringpar.xml', + 'Geometry/TrackerCommonData/data/tidring0.xml', + 'Geometry/TrackerCommonData/data/tidring0f.xml', + 'Geometry/TrackerCommonData/data/tidring0b.xml', + 'Geometry/TrackerCommonData/data/tidring1.xml', + 'Geometry/TrackerCommonData/data/tidring1f.xml', + 'Geometry/TrackerCommonData/data/tidring1b.xml', + 'Geometry/TrackerCommonData/data/tidring2.xml', + 'Geometry/TrackerCommonData/data/tid.xml', + 'Geometry/TrackerCommonData/data/tidf.xml', + 'Geometry/TrackerCommonData/data/tidb.xml', + 'Geometry/TrackerCommonData/data/tibtidservices.xml', + 'Geometry/TrackerCommonData/data/tibtidservicesf.xml', + 'Geometry/TrackerCommonData/data/tibtidservicesb.xml', + 'Geometry/TrackerCommonData/data/tobmaterial.xml', + 'Geometry/TrackerCommonData/data/tobmodpar.xml', + 'Geometry/TrackerCommonData/data/tobmodule0.xml', + 'Geometry/TrackerCommonData/data/tobmodule2.xml', + 'Geometry/TrackerCommonData/data/tobmodule4.xml', + 'Geometry/TrackerCommonData/data/tobrodpar.xml', + 'Geometry/TrackerCommonData/data/tobrod0c.xml', + 'Geometry/TrackerCommonData/data/tobrod0l.xml', + 'Geometry/TrackerCommonData/data/tobrod0h.xml', + 'Geometry/TrackerCommonData/data/tobrod0.xml', + 'Geometry/TrackerCommonData/data/tobrod1l.xml', + 'Geometry/TrackerCommonData/data/tobrod1h.xml', + 'Geometry/TrackerCommonData/data/tobrod1.xml', + 'Geometry/TrackerCommonData/data/tobrod2c.xml', + 'Geometry/TrackerCommonData/data/tobrod2l.xml', + 'Geometry/TrackerCommonData/data/tobrod2h.xml', + 'Geometry/TrackerCommonData/data/tobrod2.xml', + 'Geometry/TrackerCommonData/data/tobrod3l.xml', + 'Geometry/TrackerCommonData/data/tobrod3h.xml', + 'Geometry/TrackerCommonData/data/tobrod3.xml', + 'Geometry/TrackerCommonData/data/tobrod4c.xml', + 'Geometry/TrackerCommonData/data/tobrod4l.xml', + 'Geometry/TrackerCommonData/data/tobrod4h.xml', + 'Geometry/TrackerCommonData/data/tobrod4.xml', + 'Geometry/TrackerCommonData/data/tobrod5l.xml', + 'Geometry/TrackerCommonData/data/tobrod5h.xml', + 'Geometry/TrackerCommonData/data/tobrod5.xml', + 'Geometry/TrackerCommonData/data/tob.xml', + 'Geometry/TrackerCommonData/data/tecmaterial.xml', + 'Geometry/TrackerCommonData/data/tecmodpar.xml', + 'Geometry/TrackerCommonData/data/tecmodule0.xml', + 'Geometry/TrackerCommonData/data/tecmodule0r.xml', + 'Geometry/TrackerCommonData/data/tecmodule0s.xml', + 'Geometry/TrackerCommonData/data/tecmodule1.xml', + 'Geometry/TrackerCommonData/data/tecmodule1r.xml', + 'Geometry/TrackerCommonData/data/tecmodule1s.xml', + 'Geometry/TrackerCommonData/data/tecmodule2.xml', + 'Geometry/TrackerCommonData/data/tecmodule3.xml', + 'Geometry/TrackerCommonData/data/tecmodule4.xml', + 'Geometry/TrackerCommonData/data/tecmodule4r.xml', + 'Geometry/TrackerCommonData/data/tecmodule4s.xml', + 'Geometry/TrackerCommonData/data/tecmodule5.xml', + 'Geometry/TrackerCommonData/data/tecmodule6.xml', + 'Geometry/TrackerCommonData/data/tecpetpar.xml', + 'Geometry/TrackerCommonData/data/tecring0.xml', + 'Geometry/TrackerCommonData/data/tecring1.xml', + 'Geometry/TrackerCommonData/data/tecring2.xml', + 'Geometry/TrackerCommonData/data/tecring3.xml', + 'Geometry/TrackerCommonData/data/tecring4.xml', + 'Geometry/TrackerCommonData/data/tecring5.xml', + 'Geometry/TrackerCommonData/data/tecring6.xml', + 'Geometry/TrackerCommonData/data/tecring0f.xml', + 'Geometry/TrackerCommonData/data/tecring1f.xml', + 'Geometry/TrackerCommonData/data/tecring2f.xml', + 'Geometry/TrackerCommonData/data/tecring3f.xml', + 'Geometry/TrackerCommonData/data/tecring4f.xml', + 'Geometry/TrackerCommonData/data/tecring5f.xml', + 'Geometry/TrackerCommonData/data/tecring6f.xml', + 'Geometry/TrackerCommonData/data/tecring0b.xml', + 'Geometry/TrackerCommonData/data/tecring1b.xml', + 'Geometry/TrackerCommonData/data/tecring2b.xml', + 'Geometry/TrackerCommonData/data/tecring3b.xml', + 'Geometry/TrackerCommonData/data/tecring4b.xml', + 'Geometry/TrackerCommonData/data/tecring5b.xml', + 'Geometry/TrackerCommonData/data/tecring6b.xml', + 'Geometry/TrackerCommonData/data/tecpetalf.xml', + 'Geometry/TrackerCommonData/data/tecpetalb.xml', + 'Geometry/TrackerCommonData/data/tecpetal0.xml', + 'Geometry/TrackerCommonData/data/tecpetal0f.xml', + 'Geometry/TrackerCommonData/data/tecpetal0b.xml', + 'Geometry/TrackerCommonData/data/tecpetal3.xml', + 'Geometry/TrackerCommonData/data/tecpetal3f.xml', + 'Geometry/TrackerCommonData/data/tecpetal3b.xml', + 'Geometry/TrackerCommonData/data/tecpetal6f.xml', + 'Geometry/TrackerCommonData/data/tecpetal6b.xml', + 'Geometry/TrackerCommonData/data/tecpetal8f.xml', + 'Geometry/TrackerCommonData/data/tecpetal8b.xml', + 'Geometry/TrackerCommonData/data/tecwheel.xml', + 'Geometry/TrackerCommonData/data/tecwheela.xml', + 'Geometry/TrackerCommonData/data/tecwheelb.xml', + 'Geometry/TrackerCommonData/data/tecwheelc.xml', + 'Geometry/TrackerCommonData/data/tecwheeld.xml', + 'Geometry/TrackerCommonData/data/tecwheel6.xml', + 'Geometry/TrackerCommonData/data/tecservices.xml', + 'Geometry/TrackerCommonData/data/tecbackplate.xml', + 'Geometry/TrackerCommonData/data/tec.xml', + 'Geometry/TrackerCommonData/data/trackermaterial.xml', + 'Geometry/TrackerCommonData/data/tracker.xml', + 'Geometry/TrackerCommonData/data/trackerpixbar.xml', + 'Geometry/TrackerCommonData/data/PhaseI/trackerpixfwd.xml', + 'Geometry/TrackerCommonData/data/trackertibtidservices.xml', + 'Geometry/TrackerCommonData/data/trackertib.xml', + 'Geometry/TrackerCommonData/data/trackertid.xml', + 'Geometry/TrackerCommonData/data/trackertob.xml', + 'Geometry/TrackerCommonData/data/trackertec.xml', + 'Geometry/TrackerCommonData/data/trackerbulkhead.xml', + 'Geometry/TrackerCommonData/data/trackerother.xml', + 'Geometry/EcalCommonData/data/eregalgo.xml', + 'Geometry/EcalCommonData/data/ebalgo.xml', + 'Geometry/EcalCommonData/data/ebcon.xml', + 'Geometry/EcalCommonData/data/ebrot.xml', + 'Geometry/EcalCommonData/data/eecon.xml', + 'Geometry/EcalCommonData/data/eefixed.xml', + 'Geometry/EcalCommonData/data/eehier.xml', + 'Geometry/EcalCommonData/data/ectkcable.xml', + 'Geometry/EcalCommonData/data/eealgo.xml', + 'Geometry/EcalCommonData/data/escon.xml', + 'Geometry/EcalCommonData/data/esalgo.xml', + 'Geometry/EcalCommonData/data/eeF.xml', + 'Geometry/EcalCommonData/data/eeB.xml', + 'Geometry/HcalCommonData/data/hcalrotations.xml', + 'Geometry/HcalCommonData/data/PhaseI/hcalalgo.xml', + 'Geometry/HcalCommonData/data/hcalbarrelalgo.xml', + 'Geometry/HcalCommonData/data/PhaseI/hcalendcapalgo.xml', + 'Geometry/HcalCommonData/data/hcalouteralgo.xml', + 'Geometry/HcalCommonData/data/hcalforwardalgo.xml', + 'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalSimNumbering.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalRecNumbering.xml', + 'Geometry/MuonCommonData/data/v1/mbCommon.xml', + 'Geometry/MuonCommonData/data/v1/mb1.xml', + 'Geometry/MuonCommonData/data/v1/mb2.xml', + 'Geometry/MuonCommonData/data/v1/mb3.xml', + 'Geometry/MuonCommonData/data/v1/mb4.xml', + 'Geometry/MuonCommonData/data/design/muonYoke.xml', + 'Geometry/MuonCommonData/data/v2/mf.xml', + 'Geometry/MuonCommonData/data/v2/rpcf.xml', + 'Geometry/MuonCommonData/data/v2/csc.xml', + 'Geometry/MuonCommonData/data/v2/mfshield.xml', + 'Geometry/ForwardCommonData/data/forward.xml', + 'Geometry/ForwardCommonData/data/v2/forwardshield.xml', + 'Geometry/ForwardCommonData/data/brmrotations.xml', + 'Geometry/ForwardCommonData/data/brm.xml', + 'Geometry/ForwardCommonData/data/totemMaterials.xml', + 'Geometry/ForwardCommonData/data/totemRotations.xml', + 'Geometry/ForwardCommonData/data/totemt1.xml', + 'Geometry/ForwardCommonData/data/totemt2.xml', + 'Geometry/ForwardCommonData/data/ionpump.xml', + 'Geometry/ForwardCommonData/data/castor.xml', + 'Geometry/ForwardCommonData/data/zdcmaterials.xml', + 'Geometry/ForwardCommonData/data/lumimaterials.xml', + 'Geometry/ForwardCommonData/data/zdcrotations.xml', + 'Geometry/ForwardCommonData/data/lumirotations.xml', + 'Geometry/ForwardCommonData/data/zdc.xml', + 'Geometry/ForwardCommonData/data/zdclumi.xml', + 'Geometry/ForwardCommonData/data/cmszdc.xml')+cms.vstring( + 'Geometry/MuonCommonData/data/v2/muonNumbering.xml', + 'Geometry/TrackerCommonData/data/PhaseI/trackerStructureTopology.xml', + 'Geometry/TrackerSimData/data/PhaseI/trackersens.xml', + 'Geometry/TrackerRecoData/data/PhaseI/trackerRecoMaterial.xml', + 'Geometry/EcalSimData/data/ecalsens.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalsenspmf.xml', + 'Geometry/HcalSimData/data/hf.xml', + 'Geometry/HcalSimData/data/hfpmt.xml', + 'Geometry/HcalSimData/data/hffibrebundle.xml', + 'Geometry/HcalSimData/data/CaloUtil.xml', + 'Geometry/MuonSimData/data/muonSens.xml', + 'Geometry/DTGeometryBuilder/data/dtSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecs.xml', + 'Geometry/RPCGeometryBuilder/data/RPCSpecs.xml', + 'Geometry/ForwardCommonData/data/brmsens.xml', + 'Geometry/ForwardSimData/data/castorsens.xml', + 'Geometry/ForwardSimData/data/zdcsens.xml', + 'Geometry/HcalSimData/data/HcalProdCuts.xml', + 'Geometry/EcalSimData/data/EcalProdCuts.xml', + 'Geometry/EcalSimData/data/ESProdCuts.xml', + 'Geometry/TrackerSimData/data/PhaseI/trackerProdCuts.xml', + 'Geometry/TrackerSimData/data/trackerProdCutsBEAM.xml', + 'Geometry/MuonSimData/data/muonProdCuts.xml', + 'Geometry/ForwardSimData/data/CastorProdCuts.xml', + 'Geometry/ForwardSimData/data/zdcProdCuts.xml', + 'Geometry/ForwardSimData/data/ForwardShieldProdCuts.xml', + 'Geometry/CMSCommonData/data/FieldParameters.xml'), + rootNodeName = cms.string('cms:OCMS') +) + + diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py new file mode 100644 index 0000000000000..062e479f16229 --- /dev/null +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py @@ -0,0 +1,157 @@ +import FWCore.ParameterSet.Config as cms + +## 2015 + new phase 1 pixel detector + Tracker BarrelEndcap5Dv(described as a pixel detector before the detid migration) + +XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", + geomXMLFiles = cms.vstring('Geometry/CMSCommonData/data/materials.xml', + 'Geometry/CMSCommonData/data/rotations.xml', + 'Geometry/CMSCommonData/data/extend/cmsextent.xml', + 'Geometry/CMSCommonData/data/PhaseI/cms.xml', + 'Geometry/CMSCommonData/data/cmsMother.xml', + 'Geometry/CMSCommonData/data/cmsTracker.xml', + 'Geometry/CMSCommonData/data/eta3/etaMax.xml', + 'Geometry/CMSCommonData/data/PhaseII/caloBase.xml', + 'Geometry/CMSCommonData/data/cmsCalo.xml', + 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', + 'Geometry/CMSCommonData/data/cmsMuon.xml', + 'Geometry/CMSCommonData/data/mgnt.xml', + 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/cmsBeam.xml', + 'Geometry/CMSCommonData/data/muonMB.xml', + 'Geometry/CMSCommonData/data/muonMagnet.xml', + 'Geometry/CMSCommonData/data/cavern.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdMaterials.xml', + 'Geometry/TrackerCommonData/data/pixfwdCommon.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdCylinder.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdDisks.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk4.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk5.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk6.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk7.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk4.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk5.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk6.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk7.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk8.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk9.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk10.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade1.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade2.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade4.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade5.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade6.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade7.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade8.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade9.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade10.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarmaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladder.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/pixbar.xml', + 'Geometry/TrackerCommonData/data/trackermaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/tracker.xml', + 'Geometry/TrackerCommonData/data/trackerpixbar.xml', + 'Geometry/TrackerCommonData/data/PhaseI/trackerpixfwd.xml', + 'Geometry/EcalCommonData/data/PhaseII/ShortEE/eregalgo.xml', + 'Geometry/EcalCommonData/data/ebalgo.xml', + 'Geometry/EcalCommonData/data/ebcon.xml', + 'Geometry/EcalCommonData/data/ebrot.xml', + 'Geometry/EcalCommonData/data/eecon.xml', + 'Geometry/EcalCommonData/data/ectkcable.xml', + 'Geometry/EcalCommonData/data/PhaseII/ShortEE/eefixed.xml', + 'Geometry/EcalCommonData/data/PhaseII/ShortEE/eehier.xml', + 'Geometry/EcalCommonData/data/eealgo.xml', + 'Geometry/EcalCommonData/data/escon.xml', + 'Geometry/EcalCommonData/data/esalgo.xml', + 'Geometry/EcalCommonData/data/eeF.xml', + 'Geometry/EcalCommonData/data/eeB.xml', + 'Geometry/HcalCommonData/data/hcalrotations.xml', + 'Geometry/HcalCommonData/data/PhaseII/hcalalgo.xml', + 'Geometry/HcalCommonData/data/hcalcablealgo.xml', + 'Geometry/HcalCommonData/data/hcalbarrelalgo.xml', + 'Geometry/HcalCommonData/data/PhaseII/hcalendcapalgo.xml', + 'Geometry/HcalCommonData/data/hcalouteralgo.xml', + 'Geometry/HcalCommonData/data/hcalforwardalgo.xml', + 'Geometry/HcalCommonData/data/PhaseII/hcalSimNumberingRebuildHE.xml', + 'Geometry/HcalCommonData/data/PhaseII/hcalRecNumberingRebuildHE.xml', + 'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', + 'Geometry/MuonCommonData/data/v1/mbCommon.xml', + 'Geometry/MuonCommonData/data/v1/mb1.xml', + 'Geometry/MuonCommonData/data/v1/mb2.xml', + 'Geometry/MuonCommonData/data/v1/mb3.xml', + 'Geometry/MuonCommonData/data/v1/mb4.xml', + 'Geometry/MuonCommonData/data/design/muonYoke.xml', + 'Geometry/MuonCommonData/data/PhaseII/mf.xml', + 'Geometry/MuonCommonData/data/PhaseII/rpcf.xml', + 'Geometry/MuonCommonData/data/v2/gemf.xml', + 'Geometry/MuonCommonData/data/v4/gem11.xml', + 'Geometry/MuonCommonData/data/v6/gem21.xml', + 'Geometry/MuonCommonData/data/v2/csc.xml', + 'Geometry/MuonCommonData/data/PhaseII/mfshield.xml', + 'Geometry/MuonCommonData/data/PhaseII/me0.xml', + 'Geometry/ForwardCommonData/data/forward.xml', + 'Geometry/ForwardCommonData/data/v2/forwardshield.xml', + 'Geometry/ForwardCommonData/data/brmrotations.xml', + 'Geometry/ForwardCommonData/data/brm.xml', + 'Geometry/ForwardCommonData/data/totemMaterials.xml', + 'Geometry/ForwardCommonData/data/totemRotations.xml', + 'Geometry/ForwardCommonData/data/totemt1.xml', + 'Geometry/ForwardCommonData/data/totemt2.xml', + 'Geometry/ForwardCommonData/data/ionpump.xml', + 'Geometry/ForwardCommonData/data/castor.xml', + 'Geometry/ForwardCommonData/data/zdcmaterials.xml', + 'Geometry/ForwardCommonData/data/lumimaterials.xml', + 'Geometry/ForwardCommonData/data/zdcrotations.xml', + 'Geometry/ForwardCommonData/data/lumirotations.xml', + 'Geometry/ForwardCommonData/data/zdc.xml', + 'Geometry/ForwardCommonData/data/zdclumi.xml', + 'Geometry/ForwardCommonData/data/cmszdc.xml')+cms.vstring( + 'Geometry/MuonCommonData/data/PhaseII/muonNumbering.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/trackerStructureTopology.xml', + 'Geometry/TrackerSimData/data/PhaseII/Pixel10D/trackersens.xml', + 'Geometry/TrackerRecoData/data/PhaseII/Pixel10D/trackerRecoMaterial.xml', + 'Geometry/EcalSimData/data/ecalsens.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalsenspmf.xml', + 'Geometry/HcalSimData/data/hf.xml', + 'Geometry/HcalSimData/data/hfpmt.xml', + 'Geometry/HcalSimData/data/hffibrebundle.xml', + 'Geometry/HcalSimData/data/CaloUtil.xml', + 'Geometry/MuonSimData/data/PhaseII/muonSens.xml', + 'Geometry/DTGeometryBuilder/data/dtSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecs.xml', + 'Geometry/RPCGeometryBuilder/data/PhaseII/RPCSpecs.xml', + 'Geometry/GEMGeometryBuilder/data/v5/GEMSpecs.xml', + 'Geometry/ForwardCommonData/data/brmsens.xml', + 'Geometry/ForwardSimData/data/castorsens.xml', + 'Geometry/ForwardSimData/data/zdcsens.xml', + 'Geometry/HcalSimData/data/HcalProdCuts.xml', + 'Geometry/EcalSimData/data/EcalProdCuts.xml', + 'Geometry/EcalSimData/data/ESProdCuts.xml', + 'Geometry/TrackerSimData/data/PhaseII/Pixel10D/trackerProdCuts.xml', + 'Geometry/TrackerSimData/data/trackerProdCutsBEAM.xml', + 'Geometry/MuonSimData/data/PhaseII/muonProdCuts.xml', + 'Geometry/ForwardSimData/data/CastorProdCuts.xml', + 'Geometry/ForwardSimData/data/zdcProdCuts.xml', + 'Geometry/ForwardSimData/data/ForwardShieldProdCuts.xml', + 'Geometry/CMSCommonData/data/FieldParameters.xml'), + rootNodeName = cms.string('cms:OCMS') +) + + From 067990592d398e157e684e2788ace36bd4edd7b7 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 13:54:24 +0200 Subject: [PATCH 180/252] 2017dev + 2023Muondev scenario --- Configuration/Geometry/python/GeometryExtended2017dev_cff.py | 2 +- .../Geometry/python/GeometryExtended2023Muondev_cff.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Configuration/Geometry/python/GeometryExtended2017dev_cff.py b/Configuration/Geometry/python/GeometryExtended2017dev_cff.py index 4d61fa017c196..8856ff8e84756 100644 --- a/Configuration/Geometry/python/GeometryExtended2017dev_cff.py +++ b/Configuration/Geometry/python/GeometryExtended2017dev_cff.py @@ -4,6 +4,6 @@ # Geometry master configuration # # Ideal geometry, needed for simulation -from Geometry.CMSCommonData.cmsExtendedGeometry2017XML_cfi import * +from Geometry.CMSCommonData.cmsExtendedGeometry2017devXML_cfi import * from Geometry.TrackerNumberingBuilder.trackerNumberingSLHCGeometry_cfi import * from Geometry.HcalCommonData.hcalSimNumberingInitialization_cfi import * diff --git a/Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py b/Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py index 1be5749a59065..0459d4a6be0d0 100644 --- a/Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py +++ b/Configuration/Geometry/python/GeometryExtended2023Muondev_cff.py @@ -3,6 +3,6 @@ # Geometry master configuration # # Ideal geometry, needed for simulation -from Geometry.CMSCommonData.cmsExtendedGeometry2023MuonXML_cfi import * +from Geometry.CMSCommonData.cmsExtendedGeometry2023MuondevXML_cfi import * from Geometry.TrackerNumberingBuilder.trackerNumberingSLHCGeometry_cfi import * from Geometry.HcalCommonData.hcalSimNumberingInitialization_cfi import * From 593caed0e013d1a1e26bf4d353a71a4555a68b0c Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 14:03:36 +0200 Subject: [PATCH 181/252] dev section in trackercommondata --- .../data/PhaseIIdev/BarrelEndcap5D/pixbar.xml | 803 + .../data/PhaseIIdev/BarrelEndcap5D/pixfwd.xml | 200 + .../PhaseIIdev/BarrelEndcap5D/tracker.xml | 24596 ++++++++++++++++ .../trackerStructureTopology.xml | 3444 +++ .../data/PhaseIIdev/Pixel10D/pixfwd.xml | 228 + .../PhaseIIdev/Pixel10D/pixfwdCylinder.xml | 446 + .../data/PhaseIIdev/Pixel10D/pixfwdDisks.xml | 103 + .../PhaseIIdev/Pixel10D/pixfwdInnerDisk1.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdInnerDisk2.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdInnerDisk3.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdInnerDisk4.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdInnerDisk5.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdInnerDisk6.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdInnerDisk7.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdMaterials.xml | 444 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk1.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk10.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk2.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk3.xml | 110 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk4.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk5.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk6.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk7.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk8.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwdOuterDisk9.xml | 109 + .../PhaseIIdev/Pixel10D/pixfwd_original.xml | 148 + .../data/PhaseIIdev/Pixel10D/pixfwdblade1.xml | 337 + .../PhaseIIdev/Pixel10D/pixfwdblade10.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade2.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade3.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade4.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade5.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade6.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade7.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade8.xml | 337 + .../data/PhaseIIdev/Pixel10D/pixfwdblade9.xml | 337 + .../Pixel10D/trackerStructureTopology.xml | 3577 +++ .../data/PhaseIdev/pixbar.xml | 1050 + .../data/PhaseIdev/pixbarladder.xml | 69 + .../data/PhaseIdev/pixbarladderfull0.xml | 446 + .../data/PhaseIdev/pixbarladderfull1.xml | 447 + .../data/PhaseIdev/pixbarladderfull2.xml | 398 + .../data/PhaseIdev/pixbarladderfull3.xml | 397 + .../data/PhaseIdev/pixbarlayer.xml | 11 + .../data/PhaseIdev/pixbarlayer0.xml | 35 + .../data/PhaseIdev/pixbarlayer1.xml | 35 + .../data/PhaseIdev/pixbarlayer2.xml | 35 + .../data/PhaseIdev/pixbarlayer3.xml | 35 + .../data/PhaseIdev/pixbarmaterial.xml | 736 + .../data/PhaseIdev/pixfwd.xml | 91 + .../data/PhaseIdev/pixfwdCylinder.xml | 444 + .../data/PhaseIdev/pixfwdDisks.xml | 35 + .../data/PhaseIdev/pixfwdInnerDisk1.xml | 110 + .../data/PhaseIdev/pixfwdInnerDisk2.xml | 110 + .../data/PhaseIdev/pixfwdInnerDisk3.xml | 110 + .../data/PhaseIdev/pixfwdMaterials.xml | 444 + .../data/PhaseIdev/pixfwdOuterDisk1.xml | 109 + .../data/PhaseIdev/pixfwdOuterDisk2.xml | 110 + .../data/PhaseIdev/pixfwdOuterDisk3.xml | 110 + .../data/PhaseIdev/pixfwdblade1.xml | 337 + .../data/PhaseIdev/pixfwdblade2.xml | 337 + .../data/PhaseIdev/pixfwdblade3.xml | 337 + .../PhaseIdev/trackerStructureTopology.xml | 441 + .../data/PhaseIdev/trackerpixfwd.xml | 23 + 64 files changed, 46063 insertions(+) create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixbar.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixfwd.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/tracker.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/trackerStructureTopology.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdCylinder.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdDisks.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk3.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk4.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk5.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk6.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk7.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdMaterials.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk10.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk3.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk4.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk5.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk6.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk7.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk8.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk9.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd_original.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade10.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade3.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade4.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade5.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade6.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade7.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade8.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade9.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/trackerStructureTopology.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbar.xml create mode 100755 Geometry/TrackerCommonData/data/PhaseIdev/pixbarladder.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull0.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull3.xml create mode 100755 Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer0.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer3.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixbarmaterial.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwd.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdCylinder.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdDisks.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk3.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdMaterials.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk3.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade1.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade2.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade3.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/trackerStructureTopology.xml create mode 100644 Geometry/TrackerCommonData/data/PhaseIdev/trackerpixfwd.xml diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixbar.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixbar.xml new file mode 100644 index 0000000000000..4904142b547ed --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixbar.xml @@ -0,0 +1,803 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixfwd.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixfwd.xml new file mode 100644 index 0000000000000..6f9d08221a4d7 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixfwd.xml @@ -0,0 +1,200 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/tracker.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/tracker.xml new file mode 100644 index 0000000000000..e975780d303bc --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/tracker.xml @@ -0,0 +1,24596 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,7.9 + + + + + + + + + + +0,0,-7.9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + + + + + + + + +0,0,9 + + + + + + + + + + +0,0,-9 + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/trackerStructureTopology.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/trackerStructureTopology.xml new file mode 100644 index 0000000000000..672eeee264fbe --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/trackerStructureTopology.xml @@ -0,0 +1,3444 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd.xml new file mode 100644 index 0000000000000..8e86e4c1e2b02 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd.xml @@ -0,0 +1,228 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdCylinder.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdCylinder.xml new file mode 100644 index 0000000000000..5b7bde55c1b3f --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdCylinder.xml @@ -0,0 +1,446 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdDisks.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdDisks.xml new file mode 100644 index 0000000000000..15609f535a7aa --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdDisks.xml @@ -0,0 +1,103 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk1.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk1.xml new file mode 100644 index 0000000000000..141c7c5112752 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk1.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk2.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk2.xml new file mode 100644 index 0000000000000..feedde6fb6355 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk2.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk3.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk3.xml new file mode 100644 index 0000000000000..e6654a4ec9f40 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk3.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk4.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk4.xml new file mode 100644 index 0000000000000..5a22a42f3448d --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk4.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk5.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk5.xml new file mode 100644 index 0000000000000..c0b2874840179 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk5.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk6.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk6.xml new file mode 100644 index 0000000000000..d4b1d788a7fa1 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk6.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk7.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk7.xml new file mode 100644 index 0000000000000..a7cea1490d990 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk7.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdMaterials.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdMaterials.xml new file mode 100644 index 0000000000000..15cf56f3116b6 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdMaterials.xml @@ -0,0 +1,444 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk1.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk1.xml new file mode 100644 index 0000000000000..aa1a3224a10d7 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk1.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk10.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk10.xml new file mode 100644 index 0000000000000..a754171fdd583 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk10.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk2.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk2.xml new file mode 100644 index 0000000000000..11a7049047648 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk2.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk3.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk3.xml new file mode 100644 index 0000000000000..a83bc73637555 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk3.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk4.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk4.xml new file mode 100644 index 0000000000000..f7a3b09ec754b --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk4.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk5.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk5.xml new file mode 100644 index 0000000000000..3177a903b5bb0 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk5.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk6.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk6.xml new file mode 100644 index 0000000000000..83f024ee671db --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk6.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk7.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk7.xml new file mode 100644 index 0000000000000..9b713ec72b4fe --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk7.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk8.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk8.xml new file mode 100644 index 0000000000000..1bdd96b4b2fc5 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk8.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk9.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk9.xml new file mode 100644 index 0000000000000..b7e1789947e73 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk9.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd_original.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd_original.xml new file mode 100644 index 0000000000000..530f741d4b2c8 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd_original.xml @@ -0,0 +1,148 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade1.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade1.xml new file mode 100644 index 0000000000000..1bbcb4e6b428c --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade1.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade10.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade10.xml new file mode 100644 index 0000000000000..1edff4339fd91 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade10.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade2.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade2.xml new file mode 100644 index 0000000000000..881db9f66136a --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade2.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade3.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade3.xml new file mode 100644 index 0000000000000..fa84376156828 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade3.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade4.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade4.xml new file mode 100644 index 0000000000000..a2439c9781fd2 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade4.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade5.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade5.xml new file mode 100644 index 0000000000000..2a15324253837 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade5.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade6.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade6.xml new file mode 100644 index 0000000000000..9b9f8c4b0306a --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade6.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade7.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade7.xml new file mode 100644 index 0000000000000..aa21de3de7af4 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade7.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade8.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade8.xml new file mode 100644 index 0000000000000..bf588d28db160 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade8.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade9.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade9.xml new file mode 100644 index 0000000000000..26b4544d9330d --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade9.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/trackerStructureTopology.xml b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/trackerStructureTopology.xml new file mode 100644 index 0000000000000..6ac1f3517ff4e --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/trackerStructureTopology.xml @@ -0,0 +1,3577 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbar.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbar.xml new file mode 100644 index 0000000000000..07cf6496df34b --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbar.xml @@ -0,0 +1,1050 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladder.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladder.xml new file mode 100755 index 0000000000000..9928a32f0d948 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladder.xml @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + --> + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull0.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull0.xml new file mode 100644 index 0000000000000..a6b1de67a73a1 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull0.xml @@ -0,0 +1,446 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + + [zero], [zero], [zero] + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull1.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull1.xml new file mode 100644 index 0000000000000..a15e754c43ade --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull1.xml @@ -0,0 +1,447 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + + [zero], [zero], [zero] + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull2.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull2.xml new file mode 100644 index 0000000000000..208dca9b83ca2 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull2.xml @@ -0,0 +1,398 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + + [zero], [zero], [zero] + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull3.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull3.xml new file mode 100644 index 0000000000000..78126ce8dea10 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull3.xml @@ -0,0 +1,397 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + [zero], [zero], [zero] + + + + + + + + + + + + + [zero], [zero], [zero] + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer.xml new file mode 100755 index 0000000000000..2227fe8164657 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer.xml @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer0.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer0.xml new file mode 100644 index 0000000000000..2a5f40343774a --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer0.xml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer1.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer1.xml new file mode 100644 index 0000000000000..e67ae44221ba8 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer1.xml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer2.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer2.xml new file mode 100644 index 0000000000000..a36fae87cfc82 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer2.xml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer3.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer3.xml new file mode 100644 index 0000000000000..7e0d599d2c447 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer3.xml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixbarmaterial.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarmaterial.xml new file mode 100644 index 0000000000000..6d45c7af27a3d --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixbarmaterial.xml @@ -0,0 +1,736 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwd.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwd.xml new file mode 100644 index 0000000000000..615179e428b40 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwd.xml @@ -0,0 +1,91 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdCylinder.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdCylinder.xml new file mode 100644 index 0000000000000..0333644e922d0 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdCylinder.xml @@ -0,0 +1,444 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdDisks.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdDisks.xml new file mode 100644 index 0000000000000..4600035d67328 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdDisks.xml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk1.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk1.xml new file mode 100644 index 0000000000000..141c7c5112752 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk1.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk2.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk2.xml new file mode 100644 index 0000000000000..feedde6fb6355 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk2.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk3.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk3.xml new file mode 100644 index 0000000000000..e6654a4ec9f40 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk3.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm, + 11.62*mm, 7.12*mm, 2.62*mm, -1.88*mm, -6.38*mm, -10.88*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdMaterials.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdMaterials.xml new file mode 100644 index 0000000000000..15cf56f3116b6 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdMaterials.xml @@ -0,0 +1,444 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk1.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk1.xml new file mode 100644 index 0000000000000..aa1a3224a10d7 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk1.xml @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk2.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk2.xml new file mode 100644 index 0000000000000..11a7049047648 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk2.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk3.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk3.xml new file mode 100644 index 0000000000000..a83bc73637555 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk3.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm, + -7.42*mm, -9.92*mm, -12.42*mm,-14.92*mm,-17.42*mm,-19.92*mm,-22.42*mm,-24.92*mm, -27.42*mm + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade1.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade1.xml new file mode 100644 index 0000000000000..1bbcb4e6b428c --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade1.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade2.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade2.xml new file mode 100644 index 0000000000000..881db9f66136a --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade2.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade3.xml b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade3.xml new file mode 100644 index 0000000000000..fa84376156828 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade3.xml @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/trackerStructureTopology.xml b/Geometry/TrackerCommonData/data/PhaseIdev/trackerStructureTopology.xml new file mode 100644 index 0000000000000..81eb9d2df2dce --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/trackerStructureTopology.xml @@ -0,0 +1,441 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerCommonData/data/PhaseIdev/trackerpixfwd.xml b/Geometry/TrackerCommonData/data/PhaseIdev/trackerpixfwd.xml new file mode 100644 index 0000000000000..2b7084488c802 --- /dev/null +++ b/Geometry/TrackerCommonData/data/PhaseIdev/trackerpixfwd.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + From 4f507f4d4960714a456fdec0dc76492cdaba80c8 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 14:14:43 +0200 Subject: [PATCH 182/252] dev section in trackerrecodata --- .../data/PhaseIdev/trackerRecoMaterial.xml | 688 ++++++++++++++++++ 1 file changed, 688 insertions(+) create mode 100644 Geometry/TrackerRecoData/data/PhaseIdev/trackerRecoMaterial.xml diff --git a/Geometry/TrackerRecoData/data/PhaseIdev/trackerRecoMaterial.xml b/Geometry/TrackerRecoData/data/PhaseIdev/trackerRecoMaterial.xml new file mode 100644 index 0000000000000..0db53473997fd --- /dev/null +++ b/Geometry/TrackerRecoData/data/PhaseIdev/trackerRecoMaterial.xml @@ -0,0 +1,688 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 6b0f1e74bbbca9390b41edd3504e8e9e071e090d Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 14:19:47 +0200 Subject: [PATCH 183/252] dev section in trackersimdata --- .../BarrelEndcap5D/trackerProdCuts.xml | 438 +++++++++++++++++ .../PhaseIIdev/BarrelEndcap5D/trackersens.xml | 418 ++++++++++++++++ .../PhaseIIdev/Pixel10D/trackerProdCuts.xml | 445 ++++++++++++++++++ .../data/PhaseIIdev/Pixel10D/trackersens.xml | 425 +++++++++++++++++ .../data/PhaseIdev/trackerProdCuts.xml | 94 ++++ .../data/PhaseIdev/trackersens.xml | 69 +++ 6 files changed, 1889 insertions(+) create mode 100644 Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackerProdCuts.xml create mode 100644 Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackersens.xml create mode 100644 Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackerProdCuts.xml create mode 100644 Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackersens.xml create mode 100644 Geometry/TrackerSimData/data/PhaseIdev/trackerProdCuts.xml create mode 100644 Geometry/TrackerSimData/data/PhaseIdev/trackersens.xml diff --git a/Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackerProdCuts.xml b/Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackerProdCuts.xml new file mode 100644 index 0000000000000..dd3f9886e7a21 --- /dev/null +++ b/Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackerProdCuts.xml @@ -0,0 +1,438 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackersens.xml b/Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackersens.xml new file mode 100644 index 0000000000000..abe900e06b8a4 --- /dev/null +++ b/Geometry/TrackerSimData/data/PhaseIIdev/BarrelEndcap5D/trackersens.xml @@ -0,0 +1,418 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackerProdCuts.xml b/Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackerProdCuts.xml new file mode 100644 index 0000000000000..bf9f5031dd81a --- /dev/null +++ b/Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackerProdCuts.xml @@ -0,0 +1,445 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackersens.xml b/Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackersens.xml new file mode 100644 index 0000000000000..5234972c5e181 --- /dev/null +++ b/Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackersens.xml @@ -0,0 +1,425 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerSimData/data/PhaseIdev/trackerProdCuts.xml b/Geometry/TrackerSimData/data/PhaseIdev/trackerProdCuts.xml new file mode 100644 index 0000000000000..b896a0a5e57fc --- /dev/null +++ b/Geometry/TrackerSimData/data/PhaseIdev/trackerProdCuts.xml @@ -0,0 +1,94 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerSimData/data/PhaseIdev/trackersens.xml b/Geometry/TrackerSimData/data/PhaseIdev/trackersens.xml new file mode 100644 index 0000000000000..878d49e26efbf --- /dev/null +++ b/Geometry/TrackerSimData/data/PhaseIdev/trackersens.xml @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 2fd59eb9f52166bd4fa7d9c3efe21783e7d8f7d8 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 7 Oct 2014 14:23:46 +0200 Subject: [PATCH 184/252] loading the dev xml --- .../cmsExtendedGeometry2017devXML_cfi.py | 50 +++++----- .../cmsExtendedGeometry2023MuondevXML_cfi.py | 98 +++++++++---------- 2 files changed, 74 insertions(+), 74 deletions(-) diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py index 872b60160b8a8..ece80879d6a66 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py @@ -20,32 +20,32 @@ 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', 'Geometry/CMSCommonData/data/cavern.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdMaterials.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdMaterials.xml', 'Geometry/TrackerCommonData/data/pixfwdCommon.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdCylinder.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwd.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdDisks.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdInnerDisk1.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdInnerDisk2.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdInnerDisk3.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdOuterDisk1.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdOuterDisk2.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdOuterDisk3.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdblade1.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdblade2.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixfwdblade3.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarmaterial.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladder.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull0.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull1.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull2.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull3.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer0.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer1.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer2.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer3.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbar.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdCylinder.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdDisks.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdInnerDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdOuterDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade1.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade2.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixfwdblade3.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarmaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladder.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull0.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull1.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull2.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull3.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer0.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer1.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer2.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer3.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbar.xml', 'Geometry/TrackerCommonData/data/tibtidcommonmaterial.xml', 'Geometry/TrackerCommonData/data/tibmaterial.xml', 'Geometry/TrackerCommonData/data/tibmodpar.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py index 062e479f16229..0a6752ce1358e 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuondevXML_cfi.py @@ -20,54 +20,54 @@ 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', 'Geometry/CMSCommonData/data/cavern.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdMaterials.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdMaterials.xml', 'Geometry/TrackerCommonData/data/pixfwdCommon.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdCylinder.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwd.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdDisks.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk1.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk2.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk3.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk4.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk5.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk6.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk7.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk1.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk2.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk3.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk4.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk5.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk6.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk7.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk8.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk9.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk10.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade1.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade2.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade3.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade4.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade5.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade6.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade7.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade8.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade9.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade10.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarmaterial.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladder.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull0.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull1.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull2.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull3.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer0.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer1.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer2.xml', - 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer3.xml', - 'Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/pixbar.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdCylinder.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdDisks.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk4.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk5.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk6.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdInnerDisk7.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk4.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk5.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk6.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk7.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk8.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk9.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdOuterDisk10.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade1.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade2.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade3.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade4.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade5.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade6.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade7.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade8.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade9.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/pixfwdblade10.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarmaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladder.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull0.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull1.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull2.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarladderfull3.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer0.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer1.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer2.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/pixbarlayer3.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/pixbar.xml', 'Geometry/TrackerCommonData/data/trackermaterial.xml', - 'Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/tracker.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/BarrelEndcap5D/tracker.xml', 'Geometry/TrackerCommonData/data/trackerpixbar.xml', - 'Geometry/TrackerCommonData/data/PhaseI/trackerpixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/trackerpixfwd.xml', 'Geometry/EcalCommonData/data/PhaseII/ShortEE/eregalgo.xml', 'Geometry/EcalCommonData/data/ebalgo.xml', 'Geometry/EcalCommonData/data/ebcon.xml', @@ -123,9 +123,9 @@ 'Geometry/ForwardCommonData/data/zdclumi.xml', 'Geometry/ForwardCommonData/data/cmszdc.xml')+cms.vstring( 'Geometry/MuonCommonData/data/PhaseII/muonNumbering.xml', - 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/trackerStructureTopology.xml', - 'Geometry/TrackerSimData/data/PhaseII/Pixel10D/trackersens.xml', - 'Geometry/TrackerRecoData/data/PhaseII/Pixel10D/trackerRecoMaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseIIdev/Pixel10D/trackerStructureTopology.xml', + 'Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackersens.xml', + 'Geometry/TrackerRecoData/data/PhaseIIdev/Pixel10D/trackerRecoMaterial.xml', 'Geometry/EcalSimData/data/ecalsens.xml', 'Geometry/HcalCommonData/data/Phase0/hcalsenspmf.xml', 'Geometry/HcalSimData/data/hf.xml', @@ -144,7 +144,7 @@ 'Geometry/HcalSimData/data/HcalProdCuts.xml', 'Geometry/EcalSimData/data/EcalProdCuts.xml', 'Geometry/EcalSimData/data/ESProdCuts.xml', - 'Geometry/TrackerSimData/data/PhaseII/Pixel10D/trackerProdCuts.xml', + 'Geometry/TrackerSimData/data/PhaseIIdev/Pixel10D/trackerProdCuts.xml', 'Geometry/TrackerSimData/data/trackerProdCutsBEAM.xml', 'Geometry/MuonSimData/data/PhaseII/muonProdCuts.xml', 'Geometry/ForwardSimData/data/CastorProdCuts.xml', From c00ea7ba4d00dead2ccf9d6c83feee85eb957644 Mon Sep 17 00:00:00 2001 From: Fedor Date: Wed, 8 Oct 2014 00:46:52 +0200 Subject: [PATCH 185/252] introduce different scenarios for HE darkening --- .../HcalCalibObjects/interface/HEDarkening.h | 24 +++++-- .../HcalCalibObjects/src/HEDarkening.cc | 69 ++++++++++++------- .../Configuration/python/aging.py | 4 +- .../python/hcalUnsuppressedDigis_cfi.py | 2 +- .../HcalSimProducers/src/HcalDigitizer.cc | 4 +- SimG4CMS/Calo/src/HCalSD.cc | 5 +- SimG4Core/Application/python/g4SimHits_cfi.py | 2 +- 7 files changed, 69 insertions(+), 41 deletions(-) diff --git a/DataFormats/HcalCalibObjects/interface/HEDarkening.h b/DataFormats/HcalCalibObjects/interface/HEDarkening.h index 5e095ad4722d4..7d37e03ed9a71 100644 --- a/DataFormats/HcalCalibObjects/interface/HEDarkening.h +++ b/DataFormats/HcalCalibObjects/interface/HEDarkening.h @@ -4,25 +4,35 @@ // Simple class with parameterizaed function to get darkening attenuation // coefficiant for SLHC conditions // = degradation(int_lumi(intlumi) * dose(layer,Radius)), where -// intlumi is integrated luminosity (fb-1), +// intlumi is integrated luminosity (fb-1), // layer is HE layer number (from -1 up// to 17), NB: 1-19 in HcalTestNumbering // Radius is radius from the beam line (cm) // - -#define maxEta 14 -#define maxLay 19 +// scenario = 0 - full replacement of HE scintillators +// scenario = 1 - no replacement, full stage darkening +// scenario = 2 - only replace scintillators with expected light yield < 20% for 500 fb-1 +// scenario = 3 - replace complete megatiles only in the front 4 layers +// class HEDarkening { public: - HEDarkening(); + HEDarkening(unsigned int scenario = 3); ~HEDarkening(); - float degradation(float intlumi, int ieta, int lay); + float degradation(float intlumi, int ieta, int lay) const; + + static const char* scenarioDescription (unsigned int scenario); + + // 2 contsants below are used in CalibCalorimetry/HcalPlugins HERecalibration + // (1) number of HE ieta bins for darkening + static const unsigned int nEtaBins = 14; + // (2) max. number of HE scint. layers + static const unsigned int nScintLayers = 19; private: int ieta_shift; - float lumiscale[maxEta][maxLay]; + float lumiscale[nEtaBins][nScintLayers]; }; diff --git a/DataFormats/HcalCalibObjects/src/HEDarkening.cc b/DataFormats/HcalCalibObjects/src/HEDarkening.cc index 41dbd34e4ce1b..be617fc4e8260 100644 --- a/DataFormats/HcalCalibObjects/src/HEDarkening.cc +++ b/DataFormats/HcalCalibObjects/src/HEDarkening.cc @@ -10,7 +10,7 @@ //#define DebugLog -HEDarkening::HEDarkening() { +HEDarkening::HEDarkening(unsigned int scenario) { //HE starts at tower 16 ieta_shift = 16; @@ -18,38 +18,44 @@ HEDarkening::HEDarkening() { //fits from laser data for L1 and L7 //L0,Lm1 = L1, L2-L6 interpolated, L8-L17 extrapolated //from Vladimir Epshteyn - float _lumiscale[maxEta][maxLay] = { - {1194.9, 1194.9, 1194.9, 1651.5, 2282.7, 3155.2, 4361.0, 6027.8, 8331.5, 11515.7, 15916.8, 22000.0, 30408.2, 42029.8, 58093.1, 80295.6, 110983.5, 153400.1, 212027.7}, - {952.8, 952.8, 952.8, 1293.9, 1757.1, 2386.1, 3240.3, 4400.3, 5975.4, 8114.5, 11019.3, 14963.9, 20320.6, 27594.9, 37473.2, 50887.7, 69104.3, 93841.9, 127435.0}, - {759.8, 759.8, 759.8, 1013.8, 1352.5, 1804.5, 2407.6, 3212.2, 4285.7, 5717.9, 7628.7, 10178.1, 13579.5, 18117.6, 24172.3, 32250.4, 43028.0, 57407.4, 76592.2}, - {605.9, 605.9, 605.9, 794.2, 1041.1, 1364.7, 1788.9, 2344.9, 3073.7, 4029.1, 5281.4, 6922.9, 9074.7, 11895.2, 15592.4, 20438.8, 26791.5, 35118.8, 46034.2}, - {483.2, 483.2, 483.2, 622.3, 801.4, 1032.1, 1329.2, 1711.8, 2204.5, 2839.1, 3656.3, 4708.8, 6064.3, 7809.9, 10058.0, 12953.2, 16681.8, 21483.8, 27667.9}, - {385.3, 385.3, 385.3, 487.5, 616.9, 780.5, 987.6, 1249.6, 1581.1, 2000.6, 2531.3, 3202.8, 4052.5, 5127.6, 6487.9, 8209.2, 10387.0, 13142.6, 16629.3}, - {307.3, 307.3, 307.3, 382.0, 474.8, 590.3, 733.8, 912.2, 1134.0, 1409.7, 1752.4, 2178.5, 2708.1, 3366.6, 4185.1, 5202.6, 6467.5, 8039.9, 9994.7}, - {245.0, 245.0, 245.0, 299.3, 365.5, 446.4, 545.2, 665.9, 813.3, 993.3, 1213.2, 1481.8, 1809.7, 2210.3, 2699.6, 3297.2, 4027.0, 4918.4, 6007.1}, - {195.4, 195.4, 195.4, 234.5, 281.3, 337.6, 405.1, 486.1, 583.3, 700.0, 839.9, 1007.9, 1209.4, 1451.2, 1741.4, 2089.6, 2507.4, 3008.8, 3610.5}, - {155.8, 155.8, 155.8, 183.7, 216.6, 255.3, 301.0, 354.9, 418.4, 493.2, 581.5, 685.5, 808.2, 952.8, 1123.3, 1324.3, 1561.3, 1840.6, 2170.0}, - {124.3, 124.3, 124.3, 143.9, 166.7, 193.1, 223.6, 259.0, 300.1, 347.5, 402.6, 466.3, 540.1, 625.6, 724.6, 839.3, 972.1, 1126.0, 1304.2}, - {99.1, 99.1, 99.1, 112.8, 128.3, 146.0, 166.2, 189.1, 215.2, 244.9, 278.7, 317.2, 360.9, 410.7, 467.4, 531.9, 605.3, 688.8, 783.9}, - {79.0, 79.0, 79.0, 88.3, 98.8, 110.4, 123.5, 138.0, 154.3, 172.6, 192.9, 215.7, 241.2, 269.7, 301.5, 337.1, 376.9, 421.4, 471.1}, - {63.0, 63.0, 63.0, 69.2, 76.0, 83.5, 91.7, 100.8, 110.7, 121.6, 133.6, 146.7, 161.2, 177.0, 194.5, 213.6, 234.7, 257.8, 283.2} - }; + const float _lumiscale[nEtaBins][nScintLayers] = { + {1194.9, 1194.9, 1194.9, 1651.5, 2282.7, 3155.2, 4361.0, 6027.8, 8331.5, 11515.7, 15916.8, 22000.0, 30408.2, 42029.8, 58093.1, 80295.6, 110983.5, 153400.1, 212027.7}, + {952.8, 952.8, 952.8, 1293.9, 1757.1, 2386.1, 3240.3, 4400.3, 5975.4, 8114.5, 11019.3, 14963.9, 20320.6, 27594.9, 37473.2, 50887.7, 69104.3, 93841.9, 127435.0}, + {759.8, 759.8, 759.8, 1013.8, 1352.5, 1804.5, 2407.6, 3212.2, 4285.7, 5717.9, 7628.7, 10178.1, 13579.5, 18117.6, 24172.3, 32250.4, 43028.0, 57407.4, 76592.2}, + {605.9, 605.9, 605.9, 794.2, 1041.1, 1364.7, 1788.9, 2344.9, 3073.7, 4029.1, 5281.4, 6922.9, 9074.7, 11895.2, 15592.4, 20438.8, 26791.5, 35118.8, 46034.2}, + {483.2, 483.2, 483.2, 622.3, 801.4, 1032.1, 1329.2, 1711.8, 2204.5, 2839.1, 3656.3, 4708.8, 6064.3, 7809.9, 10058.0, 12953.2, 16681.8, 21483.8, 27667.9}, + {385.3, 385.3, 385.3, 487.5, 616.9, 780.5, 987.6, 1249.6, 1581.1, 2000.6, 2531.3, 3202.8, 4052.5, 5127.6, 6487.9, 8209.2, 10387.0, 13142.6, 16629.3}, + {307.3, 307.3, 307.3, 382.0, 474.8, 590.3, 733.8, 912.2, 1134.0, 1409.7, 1752.4, 2178.5, 2708.1, 3366.6, 4185.1, 5202.6, 6467.5, 8039.9, 9994.7}, + {245.0, 245.0, 245.0, 299.3, 365.5, 446.4, 545.2, 665.9, 813.3, 993.3, 1213.2, 1481.8, 1809.7, 2210.3, 2699.6, 3297.2, 4027.0, 4918.4, 6007.1}, + {195.4, 195.4, 195.4, 234.5, 281.3, 337.6, 405.1, 486.1, 583.3, 700.0, 839.9, 1007.9, 1209.4, 1451.2, 1741.4, 2089.6, 2507.4, 3008.8, 3610.5}, + {155.8, 155.8, 155.8, 183.7, 216.6, 255.3, 301.0, 354.9, 418.4, 493.2, 581.5, 685.5, 808.2, 952.8, 1123.3, 1324.3, 1561.3, 1840.6, 2170.0}, + {124.3, 124.3, 124.3, 143.9, 166.7, 193.1, 223.6, 259.0, 300.1, 347.5, 402.6, 466.3, 540.1, 625.6, 724.6, 839.3, 972.1, 1126.0, 1304.2}, + {99.1, 99.1, 99.1, 112.8, 128.3, 146.0, 166.2, 189.1, 215.2, 244.9, 278.7, 317.2, 360.9, 410.7, 467.4, 531.9, 605.3, 688.8, 783.9}, + {79.0, 79.0, 79.0, 88.3, 98.8, 110.4, 123.5, 138.0, 154.3, 172.6, 192.9, 215.7, 241.2, 269.7, 301.5, 337.1, 376.9, 421.4, 471.1}, + {63.0, 63.0, 63.0, 69.2, 76.0, 83.5, 91.7, 100.8, 110.7, 121.6, 133.6, 146.7, 161.2, 177.0, 194.5, 213.6, 234.7, 257.8, 283.2} + }; //store array //flux_factor: to account for increased flux at 14 TeV vs 7-8 TeV (approximate) //*divide* lumiscale params by this since increased flux -> faster darkening double flux_factor = 1.2; - for(int j = 0; j < maxEta; j++){ - for(int i = 0; i < maxLay; i++){ - lumiscale[j][i] = _lumiscale[j][i]/flux_factor; - } + for(unsigned int j = 0; j < nEtaBins; j++){ + for(unsigned int i = 0; i < nScintLayers; i++){ + if (scenario == 0 || + (scenario == 2 && exp(-500./_lumiscale[j][i])<0.2) || + (scenario == 3 && i<4)) { + lumiscale[j][i] = 0; + } + else { + lumiscale[j][i] = _lumiscale[j][i]/flux_factor; + } + } } - } HEDarkening::~HEDarkening() { } -float HEDarkening::degradation(float intlumi, int ieta, int lay) { +float HEDarkening::degradation(float intlumi, int ieta, int lay) const { //no lumi, no darkening if(intlumi <= 0) return 1.; @@ -57,14 +63,25 @@ float HEDarkening::degradation(float intlumi, int ieta, int lay) { ieta -= ieta_shift; //if outside eta range, no darkening - if(ieta < 0 || ieta >= maxEta) return 1.; + if(ieta < 0 || ieta >= (int)nEtaBins) return 1.; //shift layer index by 1 to act as array index lay += 1; //if outside layer range, no darkening - if(lay < 0 || lay >= maxLay) return 1.; + if(lay < 0 || lay >= (int)nScintLayers) return 1.; + + // if replaced tile by scenario + if (lumiscale[ieta][lay] == 0) return 1.; //return darkening factor return (exp(-intlumi/lumiscale[ieta][lay])); -} \ No newline at end of file +} + +const char* HEDarkening::scenarioDescription (unsigned int scenario) { + if (scenario == 0) return "full replacement of HE scintillators, no darkening"; + else if (scenario == 1) return "no replacement, full stage darkening"; + else if (scenario == 2) return "only replace scintillators with expected light yield < 20% for 500 fb-1"; + else if (scenario == 3) return "replace complete megatiles only in the front 4 layers"; + return "undefined scenario: assume no replacement, full stage darkening"; +} diff --git a/SLHCUpgradeSimulations/Configuration/python/aging.py b/SLHCUpgradeSimulations/Configuration/python/aging.py index c1429daae5316..4b75a14e11eb1 100644 --- a/SLHCUpgradeSimulations/Configuration/python/aging.py +++ b/SLHCUpgradeSimulations/Configuration/python/aging.py @@ -74,7 +74,7 @@ def ageHcal(process,lumi): if hasattr(process,'mix') and hasattr(process.mix,'digitizers') and hasattr(process.mix.digitizers,'hcal'): process.mix.digitizers.hcal.DelivLuminosity = cms.double(float(lumi)) # integrated lumi in fb-1 - process.mix.digitizers.hcal.HEDarkening = cms.bool(True) + process.mix.digitizers.hcal.HEDarkening = cms.uint32(1) process.mix.digitizers.hcal.HFDarkening = cms.bool(True) #these lines need to be further activated by tuning on 'complete' aging for HF @@ -225,7 +225,7 @@ def ecal_complete_aging(process): def turn_off_HE_aging(process): if hasattr(process,'mix') and hasattr(process.mix,'digitizers') and hasattr(process.mix.digitizers,'hcal'): - process.mix.digitizers.hcal.HEDarkening = cms.bool(False) + process.mix.digitizers.hcal.HEDarkening = cms.uint32(0) if hasattr(process,'es_hardcode'): process.es_hardcode.HERecalibration = cms.bool(False) if hasattr(process,'simHcalDigis'): diff --git a/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py b/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py index 1b1824b569112..a2f4603012247 100644 --- a/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py +++ b/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py @@ -38,7 +38,7 @@ CorrFactorFile = cms.FileInPath("SimCalorimetry/HcalSimProducers/data/calor_corr01.txt"), HcalReLabel = HcalReLabel, DelivLuminosity = cms.double(0), - HEDarkening = cms.bool(False), + HEDarkening = cms.uint32(0), HFDarkening = cms.bool(False) ) diff --git a/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc b/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc index 46bf06e671fe7..b8ec01fb824d2 100644 --- a/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc +++ b/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc @@ -148,7 +148,7 @@ HcalDigitizer::HcalDigitizer(const edm::ParameterSet& ps) : bool doHBHEUpgrade = ps.getParameter("HBHEUpgradeQIE"); bool doHFUpgrade = ps.getParameter("HFUpgradeQIE"); deliveredLumi = ps.getParameter("DelivLuminosity"); - bool agingFlagHE = ps.getParameter("HEDarkening"); + unsigned int agingFlagHE = ps.getParameter("HEDarkening"); bool agingFlagHF = ps.getParameter("HFDarkening"); // need to make copies, because they might get different noise generators @@ -327,7 +327,7 @@ HcalDigitizer::HcalDigitizer(const edm::ParameterSet& ps) : hitsProducer_ = ps.getParameter("hitsProducer"); - if(agingFlagHE) m_HEDarkening = new HEDarkening(); + if(agingFlagHE) m_HEDarkening = new HEDarkening(agingFlagHE); if(agingFlagHF) m_HFRecalibration = new HFRecalibration(); } diff --git a/SimG4CMS/Calo/src/HCalSD.cc b/SimG4CMS/Calo/src/HCalSD.cc index 785108d2fedbd..7d78950d9598c 100644 --- a/SimG4CMS/Calo/src/HCalSD.cc +++ b/SimG4CMS/Calo/src/HCalSD.cc @@ -64,7 +64,7 @@ HCalSD::HCalSD(G4String name, const DDCompactView & cpv, eminHitHF = m_HC.getParameter("EminHitHF")*MeV; useFibreBundle = m_HC.getParameter("UseFibreBundleHits"); deliveredLumi = m_HC.getParameter("DelivLuminosity"); - bool ageingFlagHE= m_HC.getParameter("HEDarkening"); + unsigned int ageingFlagHE= m_HC.getParameter("HEDarkening"); bool ageingFlagHF= m_HC.getParameter("HFDarkening"); useHF = m_HC.getUntrackedParameter("UseHF",true); bool forTBH2 = m_HC.getUntrackedParameter("ForTBH2",false); @@ -101,6 +101,7 @@ HCalSD::HCalSD(G4String name, const DDCompactView & cpv, << eminHitHO << " HF: " << eminHitHF << "\n" << "Delivered luminosity for Darkening " << deliveredLumi << " Flag (HE) " << ageingFlagHE + << " (" << HEDarkening::scenarioDescription(ageingFlagHE) << ")" << " Flag (HF) " << ageingFlagHF << "\n" << "Application of Fiducial Cut " << applyFidCut; @@ -323,7 +324,7 @@ HCalSD::HCalSD(G4String name, const DDCompactView & cpv, for (int i=0; i<9; ++i) hit_[i] = time_[i]= dist_[i] = 0; hzvem = hzvhad = 0; - if (ageingFlagHE) m_HEDarkening = new HEDarkening(); + if (ageingFlagHE) m_HEDarkening = new HEDarkening(ageingFlagHE); if (ageingFlagHF) m_HFDarkening = new HFDarkening(); #ifdef plotDebug edm::Service tfile; diff --git a/SimG4Core/Application/python/g4SimHits_cfi.py b/SimG4Core/Application/python/g4SimHits_cfi.py index fea5e6a8e948e..11569ad8b7edb 100644 --- a/SimG4Core/Application/python/g4SimHits_cfi.py +++ b/SimG4Core/Application/python/g4SimHits_cfi.py @@ -269,7 +269,7 @@ BetaThreshold = cms.double(0.7), TimeSliceUnit = cms.double(1), IgnoreTrackID = cms.bool(False), - HEDarkening = cms.bool(False), + HEDarkening = cms.uint32(0), HFDarkening = cms.bool(False), UseHF = cms.untracked.bool(True), ForTBH2 = cms.untracked.bool(False), From ac68e69eebd730b62d0103a9a1515261487d9821 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Wed, 8 Oct 2014 13:13:54 +0200 Subject: [PATCH 186/252] bunches of xml forgotten --- .../BarrelEndcap5D/trackerRecoMaterial.xml | 520 ++++++++++++++ .../Pixel10D/trackerRecoMaterial.xml | 632 ++++++++++++++++++ 2 files changed, 1152 insertions(+) create mode 100644 Geometry/TrackerRecoData/data/PhaseIIdev/BarrelEndcap5D/trackerRecoMaterial.xml create mode 100644 Geometry/TrackerRecoData/data/PhaseIIdev/Pixel10D/trackerRecoMaterial.xml diff --git a/Geometry/TrackerRecoData/data/PhaseIIdev/BarrelEndcap5D/trackerRecoMaterial.xml b/Geometry/TrackerRecoData/data/PhaseIIdev/BarrelEndcap5D/trackerRecoMaterial.xml new file mode 100644 index 0000000000000..bd6f6f72c4948 --- /dev/null +++ b/Geometry/TrackerRecoData/data/PhaseIIdev/BarrelEndcap5D/trackerRecoMaterial.xml @@ -0,0 +1,520 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/TrackerRecoData/data/PhaseIIdev/Pixel10D/trackerRecoMaterial.xml b/Geometry/TrackerRecoData/data/PhaseIIdev/Pixel10D/trackerRecoMaterial.xml new file mode 100644 index 0000000000000..5c0e43bdc49d8 --- /dev/null +++ b/Geometry/TrackerRecoData/data/PhaseIIdev/Pixel10D/trackerRecoMaterial.xml @@ -0,0 +1,632 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 007ab4a8c4fe84fdbbc3976ea84400883db3a21d Mon Sep 17 00:00:00 2001 From: Brian Bockelman Date: Mon, 6 Oct 2014 21:47:56 -0500 Subject: [PATCH 187/252] Implement timeouts for the Xrootd client. The default timeout is now set to 10 minutes; previously, it varied between 3 minutes and 8 hours, depending on the operation. Further, the timeout can now be set by the CMSSW pset and the site local config service. It appears that timeouts were never set for fallback files; this issue is now fixed. Whenever a ReadV error occurs, raise a CMSSW exception; do not allow this to be cast down to a ROOT warning. Exception information is improved so the last Xrootd server message (or timeouts) are recorded. Finally, this fixes an older bug in XrdReadv.cc which causes the transaction timeout to not be reset at the beginning of ReadV calls. This causes the XrdAdaptor to throw an exception on ReadV calls if it has been more than the timeout (default, 8 hours) between Read calls (which did reset the transaction timeout). Conflicts: IOPool/Input/src/RootInputFileSequence.cc --- IOPool/Input/src/RootInputFileSequence.cc | 5 +++- .../XrdAdaptor/plugins/XrdStorageMaker.cc | 25 ++++++++++++++++ Utilities/XrdAdaptor/src/XrdFile.cc | 16 ++++++++++ Utilities/XrdAdaptor/src/XrdReadv.cc | 29 +++++++++++++++++-- 4 files changed, 71 insertions(+), 4 deletions(-) diff --git a/IOPool/Input/src/RootInputFileSequence.cc b/IOPool/Input/src/RootInputFileSequence.cc index c27e53bd95a3c..6352d1aa081a9 100644 --- a/IOPool/Input/src/RootInputFileSequence.cc +++ b/IOPool/Input/src/RootInputFileSequence.cc @@ -225,7 +225,10 @@ namespace edm { try { std::unique_ptr sentry(inputType_ == InputType::Primary ? new InputSource::FileOpenSentry(input_) : 0); - filePtr.reset(new InputFile(gSystem->ExpandPathName(fallbackName.c_str()), " Fallback request to file ")); + std::string fallbackFullName = gSystem->ExpandPathName(fallbackName.c_str()); + StorageFactory *factory = StorageFactory::get(); + if (factory) {factory->activateTimeout(fallbackFullName);} + filePtr.reset(new InputFile(fallbackFullName.c_str(), " Fallback request to file ")); usedFallback_ = true; } catch (cms::Exception const& e) { diff --git a/Utilities/XrdAdaptor/plugins/XrdStorageMaker.cc b/Utilities/XrdAdaptor/plugins/XrdStorageMaker.cc index 6c1493f27a918..da1d553528781 100644 --- a/Utilities/XrdAdaptor/plugins/XrdStorageMaker.cc +++ b/Utilities/XrdAdaptor/plugins/XrdStorageMaker.cc @@ -8,6 +8,9 @@ class XrdStorageMaker : public StorageMaker { +private: + unsigned int timeout_ = 0; + public: /** Open a storage object for the given URL (protocol + path), using the @a mode bits. No temporary files are downloaded. */ @@ -21,6 +24,11 @@ class XrdStorageMaker : public StorageMaker // completely disabled, resulting in poor performance. EnvPutInt(NAME_READCACHESIZE, 20*1024*1024); + // XrdClient has various timeouts which vary from 3 minutes to 8 hours. + // This enforces an even default (10 minutes) more appropriate for the + // cmsRun case. + if (timeout_ <= 0) {setTimeout(600);} + StorageFactory *f = StorageFactory::get(); StorageFactory::ReadHint readHint = f->readHint(); StorageFactory::CacheHint cacheHint = f->cacheHint(); @@ -76,6 +84,23 @@ class XrdStorageMaker : public StorageMaker { EnvPutInt("DebugLevel", level); } + + virtual void setTimeout(unsigned int timeout) override + { + timeout_ = timeout; + if (timeout == 0) {return;} + EnvPutInt("ConnectTimeout", timeout/3+1); // Default 120. This should allow multiple connections to timeout before the open fails. + EnvPutInt("RequestTimeout", timeout/3+1); // Default 300. This should allow almost three requests to be performed before the transaction times out. + EnvPutInt("TransactionTimeout", timeout); // Default 28800 + + // Safety mechanism - if client is redirected more than 255 times in 600 + // seconds, then we abort the interaction. + EnvPutInt("RedirCntTimeout", 600); // Default 36000 + + // Enforce some CMS defaults. + EnvPutInt("MaxRedirectcount", 32); // Default 16 + EnvPutInt("ReconnectWait", 5); // Default 5 + } }; DEFINE_EDM_PLUGIN (StorageMakerFactory, XrdStorageMaker, "root"); diff --git a/Utilities/XrdAdaptor/src/XrdFile.cc b/Utilities/XrdAdaptor/src/XrdFile.cc index 7f4066329752f..1177fdb8cf470 100644 --- a/Utilities/XrdAdaptor/src/XrdFile.cc +++ b/Utilities/XrdAdaptor/src/XrdFile.cc @@ -409,6 +409,22 @@ XrdFile::addConnection (cms::Exception &ex) std::stringstream ss; ss << "Current server connection: " << conn->GetCurrentUrl().GetUrl().c_str(); ex.addAdditionalInfo(ss.str()); + if (conn->IsOpTimeLimitElapsed(time(NULL))) + { + ex.addAdditionalInfo("Operation timeout expired. This is possibly a temporary issue which may go away on retry."); + } + } + struct ServerResponseBody_Error * lastError = m_client->LastServerError(); + if (lastError && lastError->errnum != kXR_noErrorYet) + { + std::stringstream ss; + // Note: I see no guarantee that the errmsg from the server is null-terminated. + // Hence, I'm adding the extra guarantee below. + char errmsg[4097]; errmsg[4096] = '\0'; + strncpy(errmsg, lastError->errmsg, 4096); + ss << "Last server error (code=" << lastError->errnum << ")"; + if (strlen(errmsg)) {ss << ": " << errmsg;} + ex.addAdditionalInfo(ss.str()); } } diff --git a/Utilities/XrdAdaptor/src/XrdReadv.cc b/Utilities/XrdAdaptor/src/XrdReadv.cc index 26c32d4ea56a5..27d78de14ee6a 100644 --- a/Utilities/XrdAdaptor/src/XrdReadv.cc +++ b/Utilities/XrdAdaptor/src/XrdReadv.cc @@ -19,6 +19,7 @@ #include "XrdClient/XrdClientProtocol.hh" #include "XrdClient/XrdClientConst.hh" #include "XrdClient/XrdClientSid.hh" +#include "XrdClient/XrdClientEnv.hh" #include "FWCore/Utilities/interface/EDMException.h" #include "FWCore/Utilities/interface/Likely.h" @@ -69,6 +70,9 @@ XrdFile::readv (IOPosBuffer *into, IOSize n) return read(into[0].data(), into[0].size(), into[0].offset()); } + XrdClientConn *xrdc = m_client->GetClientConn(); + if (xrdc) {xrdc->SetOpTimeLimit(EnvGetLong(NAME_TRANSACTIONTIMEOUT));} + // The main challenge here is to turn the request into a form that can be // fed to the Xrootd connection. In particular, Xrootd has a limit on the // maximum number of chunks and the maximum size of each chunk. Hence, the @@ -111,8 +115,16 @@ XrdFile::readv (IOPosBuffer *into, IOSize n) // readv_send will also parse the response and place the data into the result_list buffers. IOSize tmp_total_len = readv_send(result_list, *read_chunk_list, chunk_off, readv_total_len); total_len += tmp_total_len; - if (tmp_total_len != readv_total_len) - return total_len; + if (unlikely(tmp_total_len != readv_total_len)) + { + edm::Exception ex(edm::errors::FileReadError); + ex << "XrdFile::readv(name='" << m_name << "')" + << ".size=" << n << " Chunk of " << readv_total_len << " requested but " + << tmp_total_len << " bytes returned by server."; + ex.addContext("Calling XrdFile::readv()"); + addConnection(ex); + throw ex; + } readv_total_len = 0; chunk_off = 0; } @@ -120,7 +132,18 @@ XrdFile::readv (IOPosBuffer *into, IOSize n) } // Do the actual readv for all remaining chunks. if (chunk_off) { - total_len += readv_send(result_list, *read_chunk_list, chunk_off, readv_total_len); + IOSize tmp_total_len = readv_send(result_list, *read_chunk_list, chunk_off, readv_total_len); + if (unlikely(tmp_total_len != readv_total_len)) + { + edm::Exception ex(edm::errors::FileReadError); + ex << "XrdFile::readv(name='" << m_name << "')" + << ".size=" << n << " Chunk of " << readv_total_len << " requested but " + << tmp_total_len << " bytes returned by server."; + ex.addContext("Calling XrdFile::readv()"); + addConnection(ex); + throw ex; + } + total_len += tmp_total_len; } return total_len; } From 86db4b49f1e1a4ec68d327c2f4707f572d756bb5 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Thu, 9 Oct 2014 16:39:55 +0200 Subject: [PATCH 188/252] new phase2 digitizer --- .../python/phase2TkCustomsBE5DPixel10Ddev.py | 21 ++++--------------- 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py b/SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py index 446173222895c..a5f98fe47db85 100644 --- a/SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py +++ b/SLHCUpgradeSimulations/Configuration/python/phase2TkCustomsBE5DPixel10Ddev.py @@ -31,23 +31,10 @@ def customise(process): return process def customise_Digi(process): - process.mix.digitizers.pixel.MissCalibrate = False - process.mix.digitizers.pixel.LorentzAngle_DB = False - process.mix.digitizers.pixel.killModules = False - process.mix.digitizers.pixel.useDB = False - process.mix.digitizers.pixel.DeadModules_DB = False - process.mix.digitizers.pixel.NumPixelBarrel = cms.int32(10) - process.mix.digitizers.pixel.NumPixelEndcap = cms.int32(14) - process.mix.digitizers.pixel.ThresholdInElectrons_FPix = cms.double(2000.0) - process.mix.digitizers.pixel.ThresholdInElectrons_BPix = cms.double(2000.0) - process.mix.digitizers.pixel.ThresholdInElectrons_BPix_L1 = cms.double(2000.0) - process.mix.digitizers.pixel.thePixelColEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelChipEfficiency_BPix4 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelColEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.thePixelChipEfficiency_FPix3 = cms.double(0.999) - process.mix.digitizers.pixel.AddPixelInefficiencyFromPython = cms.bool(False) + process.digitisation_step.remove(process.mix.digitizers.pixel) + process.load('Geometry.TrackerGeometryBuilder.StackedTrackerGeometry_cfi') + process.load('SimTracker.SiPhase2Digitizer.phase2TrackerDigitizer_cfi') + process.mix.digitizers.pixel=process.phase2TrackerDigitizer process.mix.digitizers.strip.ROUList = cms.vstring("g4SimHitsTrackerHitsPixelBarrelLowTof", 'g4SimHitsTrackerHitsPixelEndcapLowTof') # Check if mergedtruth is in the sequence first, could be taken out depending on cmsDriver options From 1e9d19e4520d1700cb77cc006f9ee31ed3b374ee Mon Sep 17 00:00:00 2001 From: David Lange Date: Tue, 9 Sep 2014 20:56:29 +0200 Subject: [PATCH 189/252] Merge pull request #5197 from bendavid/ecalMultifit_minimal720p4 Backport of ecal multifit reconstruction to SLHC New Ecal Local Reconstruction with Multifit (Resolved) Conflicts: DQM/EcalMonitorTasks/python/CollectionTags_cfi.py DQM/EcalMonitorTasks/src/EnergyTask.cc DQM/Integration/python/test/ecal_dqm_sourceclient-live_cfg.py DQM/Integration/rcms/eb_dqm_sourceclient-live_cfg.py DQM/Integration/rcms/ee_dqm_sourceclient-live_cfg.py DataFormats/EcalRecHit/interface/EcalRecHit.h DataFormats/EcalRecHit/interface/EcalUncalibratedRecHit.h DataFormats/EcalRecHit/src/EcalUncalibratedRecHit.cc DataFormats/EcalRecHit/src/classes_def.xml DataFormats/EcalRecHit/test/testEcalRecHit.cppunit.cc RecoLocalCalo/Configuration/python/ecalLocalRecoSequence_cff.py RecoLocalCalo/EcalRecAlgos/BuildFile.xml RecoLocalCalo/EcalRecAlgos/interface/EcalRecHitSimpleAlgo.h RecoLocalCalo/EcalRecAlgos/src/ESRecHitSimAlgo.cc RecoLocalCalo/EcalRecProducers/test/plugins/EcalUncalibRecHitDump.cc RecoParticleFlow/PFClusterProducer/interface/PFEcalRecHitCreatorMaxSample.h SLHCUpgradeSimulations/Configuration/python/customise_phase1_hcal.py Validation/EcalRecHits/python/ecalRecHitsValidation_cfi.py --- .../python/Reconstruction_cff.py | 3 +- DataFormats/EcalRecHit/interface/EcalRecHit.h | 4 +- .../interface/EcalUncalibratedRecHit.h | 28 +- DataFormats/EcalRecHit/src/EcalRecHit.cc | 4 +- .../EcalRecHit/src/EcalUncalibratedRecHit.cc | 17 +- .../testEcalUncalibratedRecHit.cppunit.cc | 51 +- .../python/EcalDigisPlusRecHits_cff.py | 4 +- .../python/FullDigisPlusRecHits_cff.py | 4 +- .../python/ecalLocalRecoSequence_cff.py | 10 +- .../python/ecalLocalReco_EventContent_cff.py | 2 +- RecoLocalCalo/EcalRecAlgos/BuildFile.xml | 1 + .../interface/EcalRecHitSimpleAlgo.h | 5 +- .../interface/EcalUncalibRecHitMultiFitAlgo.h | 37 + .../EcalUncalibRecHitTimeWeightsAlgo.h | 108 ++ .../EcalRecAlgos/interface/PulseChiSqSNNLS.h | 72 ++ .../EcalRecAlgos/interface/TDecompCholFast.h | 13 + .../EcalRecAlgos/src/ESRecHitSimAlgo.cc | 5 +- .../src/EcalUncalibRecHitMultiFitAlgo.cc | 103 ++ .../EcalRecAlgos/src/PulseChiSqSNNLS.cc | 313 +++++ .../EcalRecAlgos/src/TDecompCholFast.cc | 25 + .../plugins/EcalUncalibRecHitWorkerGlobal.cc | 11 +- .../EcalUncalibRecHitWorkerMultiFit.cc | 479 ++++++++ .../plugins/EcalUncalibRecHitWorkerMultiFit.h | 128 ++ .../python/ecalMultiFitUncalibRecHit_cfi.py | 42 + .../python/ecalPulseShapeParameters_cff.py | 51 + .../EcalRecProducers/python/ecalRecHit_cfi.py | 4 +- .../test/testMultipleEcalRecoLocal_cfg.py | 191 +++ .../python/customise_phase1_hcal.py | 1074 +++++++++++------ .../HSCP/src/BetaCalculatorECAL.cc | 4 +- Validation/Configuration/python/ECALHCAL.py | 4 +- .../python/ecalBarrelRecHitsValidation_cfi.py | 2 +- .../python/ecalEndcapRecHitsValidation_cfi.py | 2 +- .../ecalPreshowerRecHitsValidation_cfi.py | 2 +- .../python/ecalRecHitsValidation_cfi.py | 6 +- 34 files changed, 2349 insertions(+), 460 deletions(-) create mode 100644 RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h create mode 100644 RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h create mode 100644 RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h create mode 100644 RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h create mode 100644 RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc create mode 100644 RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc create mode 100644 RecoLocalCalo/EcalRecAlgos/src/TDecompCholFast.cc create mode 100644 RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc create mode 100644 RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h create mode 100644 RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py create mode 100644 RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py create mode 100644 RecoLocalCalo/EcalRecProducers/test/testMultipleEcalRecoLocal_cfg.py diff --git a/Configuration/StandardSequences/python/Reconstruction_cff.py b/Configuration/StandardSequences/python/Reconstruction_cff.py index 9fc1ccd707d07..3eba04479ddec 100644 --- a/Configuration/StandardSequences/python/Reconstruction_cff.py +++ b/Configuration/StandardSequences/python/Reconstruction_cff.py @@ -97,7 +97,8 @@ modulesToRemove.append(dt1DCosmicRecHits) modulesToRemove.append(csc2DRecHits) modulesToRemove.append(rpcRecHits) -modulesToRemove.append(ecalGlobalUncalibRecHit) +#modulesToRemove.append(ecalGlobalUncalibRecHit) +modulesToRemove.append(ecalMultiFitUncalibRecHit) modulesToRemove.append(ecalDetIdToBeRecovered) modulesToRemove.append(ecalRecHit) modulesToRemove.append(ecalCompactTrigPrim) diff --git a/DataFormats/EcalRecHit/interface/EcalRecHit.h b/DataFormats/EcalRecHit/interface/EcalRecHit.h index a57b59bce52aa..036f60afca29f 100644 --- a/DataFormats/EcalRecHit/interface/EcalRecHit.h +++ b/DataFormats/EcalRecHit/interface/EcalRecHit.h @@ -85,12 +85,12 @@ class EcalRecHit : public CaloRecHit { // set the energy for out of time events // (only energy >= 0 will be stored) - float outOfTimeEnergy() const; + float energyError() const; float timeError() const; void setChi2( float chi2 ); void setOutOfTimeChi2( float chi2 ); - void setOutOfTimeEnergy( float energy ); + void setEnergyError( float energy ); void setTimeError( uint8_t timeErrBits ); diff --git a/DataFormats/EcalRecHit/interface/EcalUncalibratedRecHit.h b/DataFormats/EcalRecHit/interface/EcalUncalibratedRecHit.h index 71c210496a5e2..a8a76f5aed3fd 100644 --- a/DataFormats/EcalRecHit/interface/EcalUncalibratedRecHit.h +++ b/DataFormats/EcalRecHit/interface/EcalUncalibratedRecHit.h @@ -3,6 +3,7 @@ #include #include "DataFormats/DetId/interface/DetId.h" +#include "DataFormats/EcalDigi/interface/EcalDataFrame.h" class EcalUncalibratedRecHit { @@ -27,11 +28,11 @@ class EcalUncalibratedRecHit { virtual ~EcalUncalibratedRecHit(); float amplitude() const { return amplitude_; } + float amplitudeError() const { return amplitudeError_; } float pedestal() const { return pedestal_; } float jitter() const { return jitter_; } float chi2() const { return chi2_; } - float outOfTimeEnergy() const { return OOTamplitude_; } - float outOfTimeChi2() const { return OOTchi2_; } + float outOfTimeAmplitude(int bx) const { return OOTamplitudes_[bx]; } uint32_t flags() const { return flags_; } float jitterError() const; @@ -39,11 +40,11 @@ class EcalUncalibratedRecHit { DetId id() const { return id_; } void setAmplitude( float amplitude ) { amplitude_ = amplitude; } + void setAmplitudeError( float amplitudeerror ) { amplitudeError_ = amplitudeerror; } void setPedestal( float pedestal ) { pedestal_ = pedestal; } void setJitter( float jitter ) { jitter_ = jitter; } void setChi2( float chi2 ) { chi2_ = chi2; } - void setOutOfTimeEnergy( float energy ) { OOTamplitude_ = energy; } - void setOutOfTimeChi2( float chi2 ){ OOTchi2_ = chi2; } + void setOutOfTimeAmplitude( int bx, float amplitude ) { OOTamplitudes_[bx] = amplitude; } void setJitterError( float jitterErr ); void setFlags( uint32_t flags ) { flags_ = flags; } @@ -57,15 +58,16 @@ class EcalUncalibratedRecHit { bool isJitterErrorValid() const; private: - float amplitude_; //< Reconstructed amplitude - float pedestal_; //< Reconstructed pedestal - float jitter_; //< Reconstructed time jitter - float chi2_; //< Chi2 of the pulse - float OOTamplitude_; //< Out-Of-Time reconstructed amplitude - float OOTchi2_; //< Out-Of-Time Chi2 - uint32_t flags_; //< flag to be propagated to RecHit - uint32_t aux_; //< aux word; first 8 bits contain time (jitter) error - DetId id_; //< Detector ID + float amplitude_; //< Reconstructed amplitude + float amplitudeError_; //< Reconstructed amplitude uncertainty + float pedestal_; //< Reconstructed pedestal + float jitter_; //< Reconstructed time jitter + float chi2_; //< Chi2 of the pulse + float OOTamplitudes_[EcalDataFrame::MAXSAMPLES]; //< Out-Of-Time reconstructed amplitude, one for each active BX, from readout sample 0 to 9 + float OOTchi2_; //< Out-Of-Time Chi2 + uint32_t flags_; //< flag to be propagated to RecHit + uint32_t aux_; //< aux word; first 8 bits contain time (jitter) error + DetId id_; //< Detector ID }; #endif diff --git a/DataFormats/EcalRecHit/src/EcalRecHit.cc b/DataFormats/EcalRecHit/src/EcalRecHit.cc index a28f6044395ff..c7521f8f0736d 100644 --- a/DataFormats/EcalRecHit/src/EcalRecHit.cc +++ b/DataFormats/EcalRecHit/src/EcalRecHit.cc @@ -37,7 +37,7 @@ float EcalRecHit::outOfTimeChi2() const return (float)rawChi2Prob / (float)((1<<7)-1) * 64.; } -float EcalRecHit::outOfTimeEnergy() const +float EcalRecHit::EnergyError() const { uint32_t rawEnergy = (0x1FFF & flags()>>11); uint16_t exponent = rawEnergy>>10; @@ -59,7 +59,7 @@ void EcalRecHit::setChi2( float chi2 ) setFlags( (~(0x7F<<4) & flags()) | ((rawChi2 & 0x7F)<<4) ); } -void EcalRecHit::setOutOfTimeEnergy( float energy ) +void EcalRecHit::setEnergyError( float energy ) { if ( energy > 0.001 ) { uint16_t exponent = lround(floor(log10(energy)))+3; diff --git a/DataFormats/EcalRecHit/src/EcalUncalibratedRecHit.cc b/DataFormats/EcalRecHit/src/EcalUncalibratedRecHit.cc index ba9dabfd775d1..60ab9e52dfa5e 100644 --- a/DataFormats/EcalRecHit/src/EcalUncalibratedRecHit.cc +++ b/DataFormats/EcalRecHit/src/EcalUncalibratedRecHit.cc @@ -2,14 +2,19 @@ #include "FWCore/MessageLogger/interface/MessageLogger.h" #include -EcalUncalibratedRecHit::EcalUncalibratedRecHit() : - amplitude_(0.), pedestal_(0.), jitter_(0.), chi2_(10000.), OOTamplitude_(0.), OOTchi2_(10000.), flags_(0), aux_(0) { } +EcalUncalibratedRecHit::~EcalUncalibratedRecHit() {} -EcalUncalibratedRecHit::EcalUncalibratedRecHit(const DetId& id, float ampl, float ped, - float jit, float chi2, uint32_t flags, uint32_t aux) : - amplitude_(ampl), pedestal_(ped), jitter_(jit), chi2_(chi2), OOTamplitude_(0.), OOTchi2_(10000.), flags_(flags), aux_(aux), id_(id) { } +EcalUncalibratedRecHit::EcalUncalibratedRecHit() : + amplitude_(0.), amplitudeError_(0.), pedestal_(0.), jitter_(0.), chi2_(10000.), flags_(0), aux_(0) { + const unsigned int nsample = EcalDataFrame::MAXSAMPLES; + for(unsigned int ibx=0; ibx + diff --git a/RecoLocalCalo/EcalRecAlgos/interface/EcalRecHitSimpleAlgo.h b/RecoLocalCalo/EcalRecAlgos/interface/EcalRecHitSimpleAlgo.h index f9e7176230591..4703d34ce5f6a 100644 --- a/RecoLocalCalo/EcalRecAlgos/interface/EcalRecHitSimpleAlgo.h +++ b/RecoLocalCalo/EcalRecAlgos/interface/EcalRecHitSimpleAlgo.h @@ -49,8 +49,9 @@ class EcalRecHitSimpleAlgo : public EcalRecHitAbsAlgo { EcalRecHit rh( uncalibRH.id(), energy, time ); rh.setChi2( uncalibRH.chi2() ); - rh.setOutOfTimeEnergy( uncalibRH.outOfTimeEnergy() * adcToGeVConstant_ * intercalibConstant ); - rh.setOutOfTimeChi2( uncalibRH.outOfTimeChi2() ); + rh.setEnergyError( uncalibRH.amplitudeError()*adcToGeVConstant_*intercalibConstant); + /* rh.setOutOfTimeEnergy( uncalibRH.outOfTimeEnergy() * adcToGeVConstant_ * intercalibConstant ); */ + /* rh.setOutOfTimeChi2( uncalibRH.outOfTimeChi2() ); */ rh.setTimeError(uncalibRH.jitterErrorBits()); // Now fill flags diff --git a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h new file mode 100644 index 0000000000000..e7af495a2b351 --- /dev/null +++ b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h @@ -0,0 +1,37 @@ +#ifndef RecoLocalCalo_EcalRecAlgos_EcalUncalibRecHitMultiFitAlgo_HH +#define RecoLocalCalo_EcalRecAlgos_EcalUncalibRecHitMultiFitAlgo_HH + +/** \class EcalUncalibRecHitMultiFitAlgo + * Amplitude reconstucted by the multi-template fit + * + * \author J.Bendavid, E.Di Marco + */ + +#include "RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitRecAbsAlgo.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" + +#include "CondFormats/EcalObjects/interface/EcalPedestals.h" +#include "CondFormats/EcalObjects/interface/EcalGainRatios.h" +#include "RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h" + + +#include "TMatrixDSym.h" +#include "TVectorD.h" + +class EcalUncalibRecHitMultiFitAlgo +{ + + public: + + EcalUncalibRecHitMultiFitAlgo(); + ~EcalUncalibRecHitMultiFitAlgo() { }; + EcalUncalibratedRecHit makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const TMatrixDSym &noisecor, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov, const std::set &activeBX); + void disableErrorCalculation() { _computeErrors = false; } + + private: + PulseChiSqSNNLS _pulsefunc; + bool _computeErrors; + +}; + +#endif diff --git a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h new file mode 100644 index 0000000000000..cb5a6168b6fc0 --- /dev/null +++ b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h @@ -0,0 +1,108 @@ +#ifndef RecoLocalCalo_EcalRecAlgos_EcalUncalibRecHitTimeWeightsAlgo_HH +#define RecoLocalCalo_EcalRecAlgos_EcalUncalibRecHitTimeWeightsAlgo_HH + +/** \class EcalUncalibRecHitTimeWeightsAlgo + * Template used to compute amplitude, pedestal, time jitter, chi2 of a pulse + * using a weights method + * + * \author J. Bendavid, E. Di Marco + * + * The chi2 computation with matrix is replaced by the chi2express which is moved outside the weight algo + * (need to clean up the interface in next iteration so that we do not pass-by useless arrays) + * + */ + +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "CondFormats/EcalObjects/interface/EcalPedestals.h" +#include "CondFormats/EcalObjects/interface/EcalGainRatios.h" +#include "CondFormats/EcalObjects/interface/EcalWeightSet.h" + +#include "TVectorD.h" +#include + +template class EcalUncalibRecHitTimeWeightsAlgo +{ + public: + + EcalUncalibRecHitTimeWeightsAlgo() { }; + virtual ~EcalUncalibRecHitTimeWeightsAlgo() { }; + + /// Compute time + double time(const C& dataFrame, const std::vector &litudes, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const TVectorD &fullpulse, const EcalWeightSet::EcalWeightMatrix** weights) { + + const unsigned int nsample = EcalDataFrame::MAXSAMPLES; + + double maxamplitude = -std::numeric_limits::max(); + + double pulsenorm = 0.; + int iGainSwitch = 0; + + ROOT::Math::SVector pedSubSamples; + for(unsigned int iSample = 0; iSample < nsample; iSample++) { + + const EcalMGPASample &sample = dataFrame.sample(iSample); + + double amplitude = 0.; + int gainId = sample.gainId(); + + double pedestal = 0.; + double gainratio = 1.; + + if (gainId==0 || gainId==3) { + pedestal = aped->mean_x1; + gainratio = aGain->gain6Over1()*aGain->gain12Over6(); + iGainSwitch = 1; + } + else if (gainId==1) { + pedestal = aped->mean_x12; + gainratio = 1.; + iGainSwitch = 0; + } + else if (gainId==2) { + pedestal = aped->mean_x6; + gainratio = aGain->gain12Over6(); + iGainSwitch = 1; + } + + amplitude = ((double)(sample.adc()) - pedestal) * gainratio; + + if (gainId == 0) { + //saturation + amplitude = (4095. - pedestal) * gainratio; + } + + pedSubSamples(iSample) = amplitude; + + if (amplitude>maxamplitude) { + maxamplitude = amplitude; + } + pulsenorm += fullpulse(iSample); + } + + std::vector::const_iterator amplit; + for(amplit=amplitudes.begin(); amplit param = (*(weights[iGainSwitch])) * pedSubSamples; + amplitude_ = param(EcalUncalibRecHitRecAbsAlgo::iAmplitude); + if (amplitude_) jitter_ = -param(EcalUncalibRecHitRecAbsAlgo::iTime) / amplitude_; + else jitter_ = 0.; + + return jitter_; + } + +}; +#endif diff --git a/RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h b/RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h new file mode 100644 index 0000000000000..21d89f0ffd663 --- /dev/null +++ b/RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h @@ -0,0 +1,72 @@ +#ifndef PulseChiSqSNNLS_h +#define PulseChiSqSNNLS_h + +#include "TMatrixD.h" +#include "TVectorD.h" +#include "TMatrixDSym.h" +#include "Math/Minimizer.h" +#include "Math/IFunction.h" +#include "RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h" + +#include +#include + +class PulseChiSqSNNLS { + public: + PulseChiSqSNNLS(); + ~PulseChiSqSNNLS(); + + + bool DoFit(const std::vector &samples, const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov); + + const TMatrixD &pulsemat() const { return _pulsemat; } + const TMatrixDSym &invcov() const { return _invcov; } + + const TVectorD &X() const { return _ampvecmin; } + const TVectorD &Errors() const { return _errvec; } + + double ChiSq() const { return _chisq; } + void disableErrorCalculation() { _computeErrors = false; } + + protected: + + bool Minimize(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov); + bool NNLS(); + bool updateCov(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov); + double ComputeChiSq(); + + TVectorD _sampvec; + TMatrixDSym _invcov; + TVectorD _workvec; + TMatrixD _pulsemat; + TVectorD _ampvec; + TVectorD _ampvecmin; + TVectorD _errvec; + TMatrixD _workmat; + TMatrixD _aTamat; + TVectorD _wvec; + TVectorD _aTbvec; + TVectorD _aTbcorvec; + TMatrixDSym _aPmat; + TVectorD _sPvec; + TDecompCholFast _decompP; + std::array _pulsematstorage; + std::array _ampvecstorage; + std::array _ampvecminstorage; + std::array _errvecstorage; + std::array _workmatstorage; + std::array _aTamatstorage; + std::array _wvecstorage; + std::array _aTbvecstorage; + std::array _aTbcorvecstorage; + std::array _aPstorage; + std::array _sPstorage; + std::array _decompPstorage; + std::set _idxsP; + std::set _idxsFixed; + + double _chisq; + bool _computeErrors; +}; + +#endif diff --git a/RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h b/RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h new file mode 100644 index 0000000000000..de505e77d9da9 --- /dev/null +++ b/RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h @@ -0,0 +1,13 @@ +#ifndef TDecompCholFast_h +#define TDecompCholFast_h + +#include "TDecompChol.h" + +class TDecompCholFast : public TDecompChol { + public: + TDecompCholFast() {} + + void SetMatrixFast(const TMatrixDSym& a, double *data); +}; + +#endif diff --git a/RecoLocalCalo/EcalRecAlgos/src/ESRecHitSimAlgo.cc b/RecoLocalCalo/EcalRecAlgos/src/ESRecHitSimAlgo.cc index afe466d391997..44c4b78a3e4c8 100644 --- a/RecoLocalCalo/EcalRecAlgos/src/ESRecHitSimAlgo.cc +++ b/RecoLocalCalo/EcalRecAlgos/src/ESRecHitSimAlgo.cc @@ -92,7 +92,10 @@ EcalRecHit ESRecHitSimAlgo::reconstruct(const ESDataFrame& digi) const { LogDebug("ESRecHitSimAlgo") << "ESRecHitSimAlgo : reconstructed energy "<getStatusCode() == 1) { rechit.setFlag(EcalRecHit::kESDead); diff --git a/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc b/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc new file mode 100644 index 0000000000000..7b60af435701d --- /dev/null +++ b/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc @@ -0,0 +1,103 @@ +#include "RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h" + +#include "FWCore/MessageLogger/interface/MessageLogger.h" + +#include "CondFormats/EcalObjects/interface/EcalPedestals.h" +#include "CondFormats/EcalObjects/interface/EcalGainRatios.h" + +EcalUncalibRecHitMultiFitAlgo::EcalUncalibRecHitMultiFitAlgo() : + _computeErrors(true) { +} + +/// compute rechits +EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const TMatrixDSym &noisecor, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov, const std::set &activeBX) { + + uint32_t flags = 0; + + const unsigned int nsample = EcalDataFrame::MAXSAMPLES; + + double maxamplitude = -std::numeric_limits::max(); + + double pedval = 0.; + double pedrms = 0.; + + std::vector amplitudes(nsample); + for(unsigned int iSample = 0; iSample < nsample; iSample++) { + + const EcalMGPASample &sample = dataFrame.sample(iSample); + + double amplitude = 0.; + int gainId = sample.gainId(); + + double pedestal = 0.; + double pederr = 0.; + double gainratio = 1.; + + if (gainId==0 || gainId==3) { + pedestal = aped->mean_x1; + pederr = aped->rms_x1; + gainratio = aGain->gain6Over1()*aGain->gain12Over6(); + } + else if (gainId==1) { + pedestal = aped->mean_x12; + pederr = aped->rms_x12; + gainratio = 1.; + } + else if (gainId==2) { + pedestal = aped->mean_x6; + pederr = aped->rms_x6; + gainratio = aGain->gain12Over6(); + } + + amplitude = ((double)(sample.adc()) - pedestal) * gainratio; + + if (gainId == 0) { + //saturation + amplitude = (4095. - pedestal) * gainratio; + } + + amplitudes[iSample] = amplitude; + + if (amplitude>maxamplitude) { + //if (iSample==5) { + maxamplitude = amplitude; + pedval = pedestal; + pedrms = pederr*gainratio; + } + + } + + + std::vector fitvals; + std::vector fiterrs; + + if(!_computeErrors) _pulsefunc.disableErrorCalculation(); + bool status = _pulsefunc.DoFit(amplitudes,noisecor,pedrms,activeBX,fullpulse,fullpulsecov); + double chisq = _pulsefunc.ChiSq(); + + if (!status) { + edm::LogWarning("EcalUncalibRecHitMultiFitAlgo::makeRecHit") << "Failed Fit" << std::endl; + } + + unsigned int ipulseintime = std::distance(activeBX.begin(),activeBX.find(0)); + double amplitude = status ? _pulsefunc.X()[ipulseintime] : 0.; + double amperr = status ? _pulsefunc.Errors()[ipulseintime] : 0.; + + double jitter = 0.; + + //printf("amplitude = %5f +- %5f, chisq = %5f\n",amplitude,amperr,chisq); + + EcalUncalibratedRecHit rh( dataFrame.id(), amplitude , pedval, jitter, chisq, flags ); + rh.setAmplitudeError(amperr); + for (std::set::const_iterator bxit = activeBX.begin(); bxit!=activeBX.end(); ++bxit) { + int ipulse = std::distance(activeBX.begin(),bxit); + if(*bxit==0) { + rh.setOutOfTimeAmplitude(*bxit+5,0.); + } else { + rh.setOutOfTimeAmplitude(*bxit+5, status ? _pulsefunc.X()[ipulse] : 0.); + } + } + + return rh; +} + diff --git a/RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc b/RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc new file mode 100644 index 0000000000000..a1ad6e53b4581 --- /dev/null +++ b/RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc @@ -0,0 +1,313 @@ +#include "RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h" +#include +#include "FWCore/MessageLogger/interface/MessageLogger.h" + +PulseChiSqSNNLS::PulseChiSqSNNLS() : + _sampvec(10), + _invcov(10), + _workvec(10), + _chisq(0.), + _computeErrors(true) +{ + +} + +PulseChiSqSNNLS::~PulseChiSqSNNLS() { + +} + +bool PulseChiSqSNNLS::DoFit(const std::vector &samples, const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov) { + + const unsigned int nsample = samples.size(); + const unsigned int npulse = bxs.size(); + + //resize matrices using reserved memory on the stack + _pulsemat.Use(nsample,npulse,_pulsematstorage.data()); + _ampvec.Use(npulse,_ampvecstorage.data()); + _ampvecmin.Use(npulse,_ampvecminstorage.data()); + _errvec.Use(npulse,_errvecstorage.data()); + _workmat.Use(npulse,nsample,_workmatstorage.data()); + _aTamat.Use(npulse,npulse,_aTamatstorage.data()); + _wvec.Use(npulse,_wvecstorage.data()); + _aTbvec.Use(npulse,_aTbvecstorage.data()); + _aTbcorvec.Use(npulse,_aTbcorvecstorage.data()); + + //initialize parameters and index index set + _sampvec.SetElements(samples.data()); + _ampvec.Zero(); + _idxsP.clear(); + _idxsFixed.clear(); + _chisq = 0.; + + //initialize pulse template matrix + for (std::set::const_iterator bxit = bxs.begin(); bxit!=bxs.end(); ++bxit) { + int ipulse = std::distance(bxs.begin(),bxit); + int bx = *bxit; + int firstsamplet = std::max(0,bx + 3); + int offset = -3-bx; + + for (unsigned int isample = firstsamplet; isample::const_iterator itintime = _idxsP.find(ipulseintime); + if (itintime != _idxsP.end()) { + _idxsP.erase(itintime); + } + + //two point interpolation for upper uncertainty when amplitude is away from boundary + double xplus100 = x0 + _errvec[ipulseintime]; + _ampvec[ipulseintime] = xplus100; + status &= Minimize(samplecor,pederr,bxs,fullpulsecov); + if (!status) return status; + double chisqplus100 = ComputeChiSq(); + + double sigmaplus = std::abs(xplus100-x0)/sqrt(chisqplus100-chisq0); + + //if amplitude is sufficiently far from the boundary, compute also the lower uncertainty and average them + if ( (x0/sigmaplus) > 0.5 ) { + double xminus100 = std::max(0.,x0-_errvec[ipulseintime]); + _ampvec[ipulseintime] = xminus100; + status &= Minimize(samplecor,pederr,bxs,fullpulsecov); + if (!status) return status; + double chisqminus100 = ComputeChiSq(); + + double sigmaminus = std::abs(xminus100-x0)/sqrt(chisqminus100-chisq0); + _errvec[ipulseintime] = 0.5*(sigmaplus + sigmaminus); + + } + else { + _errvec[ipulseintime] = sigmaplus; + } + + _chisq = chisq0; + } + + return status; + +} + +bool PulseChiSqSNNLS::Minimize(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov) { + + + const int maxiter = 50; + int iter = 0; + bool status = false; + while (true) { + + if (iter>=maxiter) { + edm::LogWarning("PulseChiSqSNNLS::Minimize") << "Max Iterations reached at iter " << iter << std::endl; + break; + } + + status = updateCov(samplecor,pederr,bxs,fullpulsecov); + if (!status) break; + status = NNLS(); + if (!status) break; + + double chisqnow = ComputeChiSq(); + double deltachisq = chisqnow-_chisq; + + _chisq = chisqnow; + if (std::abs(deltachisq)<1e-3) { + break; + } + ++iter; + } + + return status; + +} + +bool PulseChiSqSNNLS::updateCov(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov) { + + const unsigned int nsample = _sampvec.GetNrows(); + + _invcov = samplecor; + _invcov *= pederr*pederr; + + for (std::set::const_iterator bxit = bxs.begin(); bxit!=bxs.end(); ++bxit) { + int ipulse = std::distance(bxs.begin(),bxit); + if (_ampvec[ipulse]==0.) continue; + int bx = *bxit; + int firstsamplet = std::max(0,bx + 3); + int offset = -3-bx; + + double ampsq = _ampvec[ipulse]*_ampvec[ipulse]; + for (unsigned int isample = firstsamplet; isample::const_iterator itidx=_idxsFixed.begin(); itidx!=_idxsFixed.end(); ++itidx) { + for (unsigned int isample=0; isample0 || !_idxsP.size()) { + if ( (_idxsP.size()+_idxsFixed.size())==npulse ) break; + + //compute derivatives + _wvec = _ampvec; + _wvec *= _aTamat; + _wvec -= _aTbvec; + _wvec *= -1.0; + + //find wmax in active set + double wmax = -std::numeric_limits::max(); + unsigned int idxwmax = 0; + for (unsigned int idx=0; idxwmax) { + wmax = _wvec[idx]; + idxwmax = idx; + } + } + + //convergence + if (wmax<1e-11) break; + + //unconstrain parameter + _idxsP.insert(idxwmax); + } + + + while (true) { + //printf("iter in, idxsP = %i\n",int(_idxsP.size())); + + if (_idxsP.size()==0) break; + + //trick: resize matrices without reallocating memory + const unsigned int npulseP = _idxsP.size(); + _aPmat.Use(npulseP,_aPstorage.data()); + _sPvec.Use(npulseP,_sPstorage.data()); + + //fill reduced matrix AP + for (std::set::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { + unsigned int iidx = std::distance(_idxsP.begin(),itidx); + _sPvec(iidx) = _aTbcorvec(*itidx); + for (std::set::const_iterator jtidx=_idxsP.begin(); jtidx!=_idxsP.end(); ++jtidx) { + unsigned int jidx = std::distance(_idxsP.begin(),jtidx); + _aPmat(iidx,jidx) = _aTamat(*itidx,*jtidx); + } + } + + //solve for unconstrained parameters + _decompP.SetMatrixFast(_aPmat,_decompPstorage.data()); + bool status = _decompP.Solve(_sPvec); + if (!status) return false; + + //check solution + if (_sPvec.Min()>0.) { + //_ampvec.Zero(); + for (std::set::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { + unsigned int iidx = std::distance(_idxsP.begin(),itidx); + _ampvec[*itidx] = _sPvec[iidx]; + } + + break; + } + + //update parameter vector + double minratio = std::numeric_limits::max(); + unsigned int minratioidx = 0; + for (std::set::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { + unsigned int iidx = std::distance(_idxsP.begin(),itidx); + double ratio = _ampvec[*itidx]/(_ampvec[*itidx]-_sPvec[iidx]); + if (_sPvec[iidx]<=0. && ratio::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { + unsigned int iidx = std::distance(_idxsP.begin(),itidx); + _ampvec[*itidx] += minratio*(_sPvec[iidx] - _ampvec[*itidx]); + } + + + //printf("fixing indexes\n"); + for (unsigned int ipulse = 0; ipulse::const_iterator itpulse = _idxsP.find(ipulse); + if (itpulse!=_idxsP.end()) { + _ampvec[ipulse] = 0.; + _idxsP.erase(itpulse); + } + } + } + + } + ++iter; + } + + //compute approximate uncertainties + //(using 1/second derivative since full Hessian is not meaningful in + //presence of positive amplitude boundaries.) + for (unsigned int ipulse=0; ipulse pedRMSVec[0] * amplitudeThreshEE_){ float outOfTimeThreshP = outOfTimeThreshG12pEE_; @@ -478,7 +476,6 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEB); uncalibRecHit.setJitterError( std::sqrt(std::pow(crh.timeError,2) + std::pow(EBtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); - uncalibRecHit.setOutOfTimeEnergy( crh.amplitudeMax ); // consider flagging as kOutOfTime only if above noise if (uncalibRecHit.amplitude() > pedRMSVec[0] * amplitudeThreshEB_){ float outOfTimeThreshP = outOfTimeThreshG12pEB_; @@ -509,7 +506,7 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, if (detid.subdetId()==EcalEndcap) { double amplitude = uncalibRecHit.amplitude(); - double amplitudeOutOfTime = uncalibRecHit.outOfTimeEnergy(); + double amplitudeOutOfTime = 0.; double jitter= uncalibRecHit.jitter(); @@ -528,8 +525,6 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, ); double chi2 = chi2expressEE_.chi2(); uncalibRecHit.setChi2(chi2); - double chi2OutOfTime = chi2expressEE_.chi2OutOfTime(); - uncalibRecHit.setOutOfTimeChi2(chi2OutOfTime); if(kPoorRecoFlagEE_) { @@ -591,7 +586,7 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, } } else { double amplitude = uncalibRecHit.amplitude(); - double amplitudeOutOfTime = uncalibRecHit.outOfTimeEnergy(); + double amplitudeOutOfTime = 0.; double jitter= uncalibRecHit.jitter(); EcalUncalibRecHitRecChi2Algochi2expressEB_( @@ -608,8 +603,6 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, ); double chi2 = chi2expressEB_.chi2(); uncalibRecHit.setChi2(chi2); - double chi2OutOfTime = chi2expressEB_.chi2OutOfTime(); - uncalibRecHit.setOutOfTimeChi2(chi2OutOfTime); if(kPoorRecoFlagEB_) { diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc new file mode 100644 index 0000000000000..7e3b9ca534e87 --- /dev/null +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc @@ -0,0 +1,479 @@ +#include "RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h" + +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "CondFormats/DataRecord/interface/EcalGainRatiosRcd.h" +#include "CondFormats/DataRecord/interface/EcalPedestalsRcd.h" +#include "CondFormats/DataRecord/interface/EcalWeightXtalGroupsRcd.h" +#include "CondFormats/DataRecord/interface/EcalTBWeightsRcd.h" +#include "CondFormats/DataRecord/interface/EcalSampleMaskRcd.h" +#include "CondFormats/DataRecord/interface/EcalTimeCalibConstantsRcd.h" +#include "CondFormats/DataRecord/interface/EcalTimeOffsetConstantRcd.h" +#include "CondFormats/DataRecord/interface/EcalTimeBiasCorrectionsRcd.h" + + +EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&ps,edm::ConsumesCollector& c) : + EcalUncalibRecHitWorkerBaseClass(ps,c), + noisecorEBg12(10), noisecorEEg12(10), + noisecorEBg6(10), noisecorEEg6(10), + noisecorEBg1(10), noisecorEEg1(10), + fullpulseEB(12),fullpulseEE(12),fullpulsecovEB(12),fullpulsecovEE(12) { + + // get the pulse shape, amplitude covariances and noise correlations + EcalPulseShapeParameters_ = ps.getParameter("EcalPulseShapeParameters"); + fillInputs(EcalPulseShapeParameters_); + + // get the BX for the pulses to be activated + std::vector activeBXs = ps.getParameter< std::vector >("activeBXs"); + for(unsigned int ibx=0; ibx("ampErrorCalculation"); + + // algorithm to be used for timing + timealgo_ = ps.getParameter("timealgo"); + + // ratio method parameters + EBtimeFitParameters_ = ps.getParameter >("EBtimeFitParameters"); + EEtimeFitParameters_ = ps.getParameter >("EEtimeFitParameters"); + EBamplitudeFitParameters_ = ps.getParameter >("EBamplitudeFitParameters"); + EEamplitudeFitParameters_ = ps.getParameter >("EEamplitudeFitParameters"); + EBtimeFitLimits_.first = ps.getParameter("EBtimeFitLimits_Lower"); + EBtimeFitLimits_.second = ps.getParameter("EBtimeFitLimits_Upper"); + EEtimeFitLimits_.first = ps.getParameter("EEtimeFitLimits_Lower"); + EEtimeFitLimits_.second = ps.getParameter("EEtimeFitLimits_Upper"); + EBtimeConstantTerm_=ps.getParameter("EBtimeConstantTerm"); + EEtimeConstantTerm_=ps.getParameter("EEtimeConstantTerm"); + + // leading edge parameters + ebPulseShape_ = ps.getParameter >("ebPulseShape"); + eePulseShape_ = ps.getParameter >("eePulseShape"); + + // chi2 parameters for flags determination + kPoorRecoFlagEB_ = ps.getParameter("kPoorRecoFlagEB"); + kPoorRecoFlagEE_ = ps.getParameter("kPoorRecoFlagEE");; + chi2ThreshEB_=ps.getParameter("chi2ThreshEB_"); + chi2ThreshEE_=ps.getParameter("chi2ThreshEE_"); + +} + + + +// EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&ps) : +// EcalUncalibRecHitWorkerBaseClass(ps) +// { +// // ratio method parameters +// EBtimeFitParameters_ = ps.getParameter >("EBtimeFitParameters"); +// EEtimeFitParameters_ = ps.getParameter >("EEtimeFitParameters"); +// EBamplitudeFitParameters_ = ps.getParameter >("EBamplitudeFitParameters"); +// EEamplitudeFitParameters_ = ps.getParameter >("EEamplitudeFitParameters"); +// EBtimeFitLimits_.first = ps.getParameter("EBtimeFitLimits_Lower"); +// EBtimeFitLimits_.second = ps.getParameter("EBtimeFitLimits_Upper"); +// EEtimeFitLimits_.first = ps.getParameter("EEtimeFitLimits_Lower"); +// EEtimeFitLimits_.second = ps.getParameter("EEtimeFitLimits_Upper"); +// EBtimeConstantTerm_=ps.getParameter("EBtimeConstantTerm"); +// EEtimeConstantTerm_=ps.getParameter("EEtimeConstantTerm"); +// +// // leading edge parameters +// ebPulseShape_ = ps.getParameter >("ebPulseShape"); +// eePulseShape_ = ps.getParameter >("eePulseShape"); +// +// } + + + + + + + + + + + + + +void +EcalUncalibRecHitWorkerMultiFit::set(const edm::EventSetup& es) +{ + + // common setup + es.get().get(gains); + es.get().get(peds); + + // for the multifit method + if(!ampErrorCalculation_) multiFitMethod_.disableErrorCalculation(); + + // weights parameters for the time + es.get().get(grps); + es.get().get(wgts); + + // which of the samples need be used + es.get().get(sampleMaskHand_); + + // for the ratio method + + // for the leading edge method + es.get().get(itime); + es.get().get(offtime); + + // for the time correction methods + es.get().get(timeCorrBias_); +} + +/** + * Amplitude-dependent time corrections; EE and EB have separate corrections: + * EXtimeCorrAmplitudes (ADC) and EXtimeCorrShifts (ns) need to have the same number of elements + * Bins must be ordered in amplitude. First-last bins take care of under-overflows. + * + * The algorithm is the same for EE and EB, only the correction vectors are different. + * + * @return Jitter (in clock cycles) which will be added to UncalibRechit.setJitter(), 0 if no correction is applied. + */ +double EcalUncalibRecHitWorkerMultiFit::timeCorrection( + float ampli, + const std::vector& amplitudeBins, + const std::vector& shiftBins) { + + // computed initially in ns. Than turned in the BX's, as + // EcalUncalibratedRecHit need be. + double theCorrection = 0; + + // sanity check for arrays + if (amplitudeBins.size() == 0) { + edm::LogError("EcalRecHitError") + << "timeCorrAmplitudeBins is empty, forcing no time bias corrections."; + + return 0; + } + + if (amplitudeBins.size() != shiftBins.size()) { + edm::LogError("EcalRecHitError") + << "Size of timeCorrAmplitudeBins different from " + "timeCorrShiftBins. Forcing no time bias corrections. "; + + return 0; + } + + int myBin = -1; + for (int bin = 0; bin < (int) amplitudeBins.size(); bin++) { + if (ampli > amplitudeBins.at(bin)) { + myBin = bin; + } else { + break; + } + } + + if (myBin == -1) { + theCorrection = shiftBins.at(0); + } else if (myBin == ((int)(amplitudeBins.size() - 1))) { + theCorrection = shiftBins.at(myBin); + } else if (-1 < myBin && myBin < ((int) amplitudeBins.size() - 1)) { + // interpolate linearly between two assingned points + theCorrection = (shiftBins.at(myBin + 1) - shiftBins.at(myBin)); + theCorrection *= (((double) ampli) - amplitudeBins.at(myBin)) / + (amplitudeBins.at(myBin + 1) - amplitudeBins.at(myBin)); + theCorrection += shiftBins.at(myBin); + } else { + edm::LogError("EcalRecHitError") + << "Assigning time correction impossible. Setting it to 0 "; + theCorrection = 0.; + } + + // convert ns into clocks + return theCorrection / 25.; +} + + + +bool +EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, + const EcalDigiCollection::const_iterator & itdg, + EcalUncalibratedRecHitCollection & result ) +{ + DetId detid(itdg->id()); + + const EcalSampleMask *sampleMask_ = sampleMaskHand_.product(); + + // intelligence for recHit computation + EcalUncalibratedRecHit uncalibRecHit; + + + const EcalPedestals::Item * aped = 0; + const EcalMGPAGainRatio * aGain = 0; + const EcalXtalGroupId * gid = 0; + + if (detid.subdetId()==EcalEndcap) { + unsigned int hashedIndex = EEDetId(detid).hashedIndex(); + aped = &peds->endcap(hashedIndex); + aGain = &gains->endcap(hashedIndex); + gid = &grps->endcap(hashedIndex); + } else { + unsigned int hashedIndex = EBDetId(detid).hashedIndex(); + aped = &peds->barrel(hashedIndex); + aGain = &gains->barrel(hashedIndex); + gid = &grps->barrel(hashedIndex); + } + + pedVec[0] = aped->mean_x12; + pedVec[1] = aped->mean_x6; + pedVec[2] = aped->mean_x1; + pedRMSVec[0] = aped->rms_x12; + pedRMSVec[1] = aped->rms_x6; + pedRMSVec[2] = aped->rms_x1; + gainRatios[0] = 1.; + gainRatios[1] = aGain->gain12Over6(); + gainRatios[2] = aGain->gain6Over1()*aGain->gain12Over6(); + + + // === amplitude computation === + int leadingSample = ((EcalDataFrame)(*itdg)).lastUnsaturatedSample(); + + if ( leadingSample >= 0 ) { // saturation + if ( leadingSample != 4 ) { + // all samples different from the fifth are not reliable for the amplitude estimation + // put by default the energy at the saturation threshold and flag as saturated + float sratio = 1; + if ( detid.subdetId()==EcalBarrel) { + sratio = ebPulseShape_[5] / ebPulseShape_[4]; + } else { + sratio = eePulseShape_[5] / eePulseShape_[4]; + } + uncalibRecHit = EcalUncalibratedRecHit( (*itdg).id(), 4095*12*sratio, 0, 0, 0); + uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kSaturated ); + } else { + // float clockToNsConstant = 25.; + // reconstruct the rechit + if (detid.subdetId()==EcalEndcap) { + leadingEdgeMethod_endcap_.setPulseShape( eePulseShape_ ); + // float mult = (float)eePulseShape_.size() / (float)(*itdg).size(); + // bin (or some analogous mapping) will be used instead of the leadingSample + //int bin = (int)(( (mult * leadingSample + mult/2) * clockToNsConstant + itimeconst ) / clockToNsConstant); + // bin is not uset for the moment + leadingEdgeMethod_endcap_.setLeadingEdgeSample( leadingSample ); + uncalibRecHit = leadingEdgeMethod_endcap_.makeRecHit(*itdg, pedVec, gainRatios, 0, 0); + uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kLeadingEdgeRecovered ); + leadingEdgeMethod_endcap_.setLeadingEdgeSample( -1 ); + } else { + leadingEdgeMethod_barrel_.setPulseShape( ebPulseShape_ ); + // float mult = (float)ebPulseShape_.size() / (float)(*itdg).size(); + // bin (or some analogous mapping) will be used instead of the leadingSample + //int bin = (int)(( (mult * leadingSample + mult/2) * clockToNsConstant + itimeconst ) / clockToNsConstant); + // bin is not uset for the moment + leadingEdgeMethod_barrel_.setLeadingEdgeSample( leadingSample ); + uncalibRecHit = leadingEdgeMethod_barrel_.makeRecHit(*itdg, pedVec, gainRatios, 0, 0); + uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kLeadingEdgeRecovered ); + leadingEdgeMethod_barrel_.setLeadingEdgeSample( -1 ); + } + } + // do not propagate the default chi2 = -1 value to the calib rechit (mapped to 64), set it to 0 when saturation + uncalibRecHit.setChi2(0); + } else { + // multifit + bool barrel = detid.subdetId()==EcalBarrel; + int gain = 12; + if (((EcalDataFrame)(*itdg)).hasSwitchToGain6()) { + gain = 6; + } + if (((EcalDataFrame)(*itdg)).hasSwitchToGain1()) { + gain = 1; + } + const TMatrixDSym &noisecormat = noisecor(barrel,gain); + const TVectorD &fullpulse = barrel ? fullpulseEB : fullpulseEE; + const TMatrixDSym &fullpulsecov = barrel ? fullpulsecovEB : fullpulsecovEE; + + uncalibRecHit = multiFitMethod_.makeRecHit(*itdg, aped, aGain, noisecormat,fullpulse,fullpulsecov,activeBX); + + // === time computation === + if(timealgo_.compare("RatioMethod")==0) { + // ratio method + float const clockToNsConstant = 25.; + if (detid.subdetId()==EcalEndcap) { + ratioMethod_endcap_.init( *itdg, *sampleMask_, pedVec, pedRMSVec, gainRatios ); + ratioMethod_endcap_.computeTime( EEtimeFitParameters_, EEtimeFitLimits_, EEamplitudeFitParameters_ ); + ratioMethod_endcap_.computeAmplitude( EEamplitudeFitParameters_); + EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_endcap_.getCalculatedRecHit(); + double theTimeCorrectionEE = timeCorrection(uncalibRecHit.amplitude(), + timeCorrBias_->EETimeCorrAmplitudeBins, timeCorrBias_->EETimeCorrShiftBins); + + uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEE); + uncalibRecHit.setJitterError( std::sqrt(pow(crh.timeError,2) + std::pow(EEtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); + + } else { + ratioMethod_barrel_.init( *itdg, *sampleMask_, pedVec, pedRMSVec, gainRatios ); + ratioMethod_barrel_.fixMGPAslew(*itdg); + ratioMethod_barrel_.computeTime( EBtimeFitParameters_, EBtimeFitLimits_, EBamplitudeFitParameters_ ); + ratioMethod_barrel_.computeAmplitude( EBamplitudeFitParameters_); + EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_barrel_.getCalculatedRecHit(); + + double theTimeCorrectionEB = timeCorrection(uncalibRecHit.amplitude(), + timeCorrBias_->EBTimeCorrAmplitudeBins, timeCorrBias_->EBTimeCorrShiftBins); + + uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEB); + + uncalibRecHit.setJitterError( std::sqrt(std::pow(crh.timeError,2) + std::pow(EBtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); + } + } else if(timealgo_.compare("WeightsMethod")==0) { + // weights method on the PU subtracted pulse shape + std::vector amplitudes; + for(unsigned int ibx=0; ibxgetMap(); + EcalTBWeights::EcalTBWeightMap::const_iterator wit; + wit = wgtsMap.find( std::make_pair(*gid,tdcid) ); + if( wit == wgtsMap.end() ) { + edm::LogError("EcalUncalibRecHitError") << "No weights found for EcalGroupId: " + << gid->id() << " and EcalTDCId: " << tdcid + << "\n skipping digi with id: " << detid.rawId(); + + return false; + } + const EcalWeightSet& wset = wit->second; // this is the EcalWeightSet + + const EcalWeightSet::EcalWeightMatrix& mat1 = wset.getWeightsBeforeGainSwitch(); + const EcalWeightSet::EcalWeightMatrix& mat2 = wset.getWeightsAfterGainSwitch(); + + weights[0] = &mat1; + weights[1] = &mat2; + + double timerh; + if (detid.subdetId()==EcalEndcap) { + timerh = weightsMethod_endcap_.time( *itdg, amplitudes, aped, aGain, fullpulse, weights); + } else { + timerh = weightsMethod_barrel_.time( *itdg, amplitudes, aped, aGain, fullpulse, weights); + } + uncalibRecHit.setJitter( timerh ); + uncalibRecHit.setJitterError( 0. ); // not computed with weights + } else if(timealgo_.compare("None")==0) { + uncalibRecHit.setJitter( 0. ); + uncalibRecHit.setJitterError( 0. ); + } else { + edm::LogError("EcalUncalibRecHitError") << "No time estimation algorithm called " + << timealgo_ + << "\n setting jitter to 0. and jitter uncertainty to 10000. "; + + uncalibRecHit.setJitter( 0. ); + uncalibRecHit.setJitterError( 10000. ); + } + } + + // set flags if gain switch has occurred + if( ((EcalDataFrame)(*itdg)).hasSwitchToGain6() ) uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kHasSwitchToGain6 ); + if( ((EcalDataFrame)(*itdg)).hasSwitchToGain1() ) uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kHasSwitchToGain1 ); + + // set quality flags based on chi2 of the the fit + /* + if(detid.subdetId()==EcalEndcap) { + if(kPoorRecoFlagEE_ && uncalibRecHit.chi2()>chi2ThreshEE_) { + bool samplesok = true; + for (int sample =0; sample < EcalDataFrame::MAXSAMPLES; ++sample) { + if (!sampleMask_->useSampleEE(sample)) { + samplesok = false; + break; + } + } + if (samplesok) uncalibRecHit.setFlagBit(EcalUncalibratedRecHit::kPoorReco); + } + } else { + if(kPoorRecoFlagEB_ && uncalibRecHit.chi2()>chi2ThreshEB_) { + bool samplesok = true; + for (int sample =0; sample < EcalDataFrame::MAXSAMPLES; ++sample) { + if (!sampleMask_->useSampleEB(sample)) { + samplesok = false; + break; + } + } + if (samplesok) uncalibRecHit.setFlagBit(EcalUncalibratedRecHit::kPoorReco); + } + } + */ + + // put the recHit in the collection + if (detid.subdetId()==EcalEndcap) { + result.push_back( uncalibRecHit ); + } else { + result.push_back( uncalibRecHit ); + } + + return true; +} + + +const TMatrixDSym &EcalUncalibRecHitWorkerMultiFit::noisecor(bool barrel, int gain) const { + if (barrel) { + if (gain==6) { + return noisecorEBg6; + } + else if (gain==1) { + return noisecorEBg1; + } + else { + return noisecorEBg12; + } + } + else { + if (gain==6) { + return noisecorEEg6; + } + else if (gain==1) { + return noisecorEEg1; + } + else { + return noisecorEEg12; + } + } + + return noisecorEBg12; + +} + +void EcalUncalibRecHitWorkerMultiFit::fillInputs(const edm::ParameterSet& params) { + + const std::vector ebCorMatG12 = params.getParameter< std::vector >("EBCorrNoiseMatrixG12"); + const std::vector eeCorMatG12 = params.getParameter< std::vector >("EECorrNoiseMatrixG12"); + const std::vector ebCorMatG06 = params.getParameter< std::vector >("EBCorrNoiseMatrixG06"); + const std::vector eeCorMatG06 = params.getParameter< std::vector >("EECorrNoiseMatrixG06"); + const std::vector ebCorMatG01 = params.getParameter< std::vector >("EBCorrNoiseMatrixG01"); + const std::vector eeCorMatG01 = params.getParameter< std::vector >("EECorrNoiseMatrixG01"); + + int nnoise = ebCorMatG12.size(); + + // fill correlation matrices: noise (HF (+) LF) + for (int i=0; i ebPulse = params.getParameter< std::vector >("EBPulseShapeTemplate"); + const std::vector eePulse = params.getParameter< std::vector >("EEPulseShapeTemplate"); + int nShapeSamples = ebPulse.size(); + for (int i=0; i ebPulseCov = params.getParameter< std::vector >("EBPulseShapeCovariance"); + const std::vector eePulseCov = params.getParameter< std::vector >("EEPulseShapeCovariance"); + for(int k=0; k peds; + edm::ESHandle gains; + + double timeCorrection(float ampli, + const std::vector& amplitudeBins, const std::vector& shiftBins); + + const TMatrixDSym &noisecor(bool barrel, int gain) const; + + // multifit method + TMatrixDSym noisecorEBg12; + TMatrixDSym noisecorEEg12; + TMatrixDSym noisecorEBg6; + TMatrixDSym noisecorEEg6; + TMatrixDSym noisecorEBg1; + TMatrixDSym noisecorEEg1; + TVectorD fullpulseEB; + TVectorD fullpulseEE; + TMatrixDSym fullpulsecovEB; + TMatrixDSym fullpulsecovEE; + std::set activeBX; + bool ampErrorCalculation_; + EcalUncalibRecHitMultiFitAlgo multiFitMethod_; + + + // determine which of the samples must actually be used by ECAL local reco + edm::ESHandle sampleMaskHand_; + + // time algorithm to be used to set the jitter and its uncertainty + std::string timealgo_; + + // time weights method + edm::ESHandle grps; + edm::ESHandle wgts; + const EcalWeightSet::EcalWeightMatrix* weights[2]; + EcalUncalibRecHitTimeWeightsAlgo weightsMethod_barrel_; + EcalUncalibRecHitTimeWeightsAlgo weightsMethod_endcap_; + + // ratio method + std::vector EBtimeFitParameters_; + std::vector EEtimeFitParameters_; + std::vector EBamplitudeFitParameters_; + std::vector EEamplitudeFitParameters_; + std::pair EBtimeFitLimits_; + std::pair EEtimeFitLimits_; + + EcalUncalibRecHitRatioMethodAlgo ratioMethod_barrel_; + EcalUncalibRecHitRatioMethodAlgo ratioMethod_endcap_; + + double EBtimeConstantTerm_; + double EEtimeConstantTerm_; + + edm::ESHandle timeCorrBias_; + + // leading edge method + edm::ESHandle itime; + edm::ESHandle offtime; + std::vector ebPulseShape_; + std::vector eePulseShape_; + EcalUncalibRecHitLeadingEdgeAlgo leadingEdgeMethod_barrel_; + EcalUncalibRecHitLeadingEdgeAlgo leadingEdgeMethod_endcap_; + + + // chi2 thresholds for flags settings + bool kPoorRecoFlagEB_; + bool kPoorRecoFlagEE_; + double chi2ThreshEB_; + double chi2ThreshEE_; + + + private: + void fillInputs(const edm::ParameterSet& params); + +}; + +#endif diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py b/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py new file mode 100644 index 0000000000000..3ba32ad9c59f4 --- /dev/null +++ b/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py @@ -0,0 +1,42 @@ +import FWCore.ParameterSet.Config as cms + +from RecoLocalCalo.EcalRecProducers.ecalPulseShapeParameters_cff import * + +ecalMultiFitUncalibRecHit = cms.EDProducer("EcalUncalibRecHitProducer", + EBdigiCollection = cms.InputTag("ecalDigis","ebDigis"), + EEdigiCollection = cms.InputTag("ecalDigis","eeDigis"), + EBhitCollection = cms.string("EcalUncalibRecHitsEB"), + EEhitCollection = cms.string('EcalUncalibRecHitsEE'), + + # for multifit method + EcalPulseShapeParameters = cms.PSet( ecal_pulse_shape_parameters ), + activeBXs = cms.vint32(-5,-4,-3,-2,-1,0,1,2,3,4), + ampErrorCalculation = cms.bool(True), + + # decide which algorithm to be use to calculate the jitter + timealgo = cms.string("RatioMethod"), + + # for ratio method + EBtimeFitParameters = cms.vdouble(-2.015452e+00, 3.130702e+00, -1.234730e+01, 4.188921e+01, -8.283944e+01, 9.101147e+01, -5.035761e+01, 1.105621e+01), + EEtimeFitParameters = cms.vdouble(-2.390548e+00, 3.553628e+00, -1.762341e+01, 6.767538e+01, -1.332130e+02, 1.407432e+02, -7.541106e+01, 1.620277e+01), + EBamplitudeFitParameters = cms.vdouble(1.138,1.652), + EEamplitudeFitParameters = cms.vdouble(1.890,1.400), + EBtimeFitLimits_Lower = cms.double(0.2), + EBtimeFitLimits_Upper = cms.double(1.4), + EEtimeFitLimits_Lower = cms.double(0.2), + EEtimeFitLimits_Upper = cms.double(1.4), + # for time error + EBtimeConstantTerm= cms.double(.6), + EEtimeConstantTerm= cms.double(1.0), + + ebPulseShape = cms.vdouble( 5.2e-05,-5.26e-05 , 6.66e-05, 0.1168, 0.7575, 1., 0.8876, 0.6732, 0.4741, 0.3194 ), + eePulseShape = cms.vdouble( 5.2e-05,-5.26e-05 , 6.66e-05, 0.1168, 0.7575, 1., 0.8876, 0.6732, 0.4741, 0.3194 ), + + # for kPoorReco flag + kPoorRecoFlagEB = cms.bool(True), + kPoorRecoFlagEE = cms.bool(False), + chi2ThreshEB_ = cms.double(65.0), + chi2ThreshEE_ = cms.double(50.0), + + algo = cms.string("EcalUncalibRecHitWorkerMultiFit") +) diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py new file mode 100644 index 0000000000000..9b02d1bf29f8d --- /dev/null +++ b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py @@ -0,0 +1,51 @@ +import FWCore.ParameterSet.Config as cms + +ecal_pulse_shape_templates = cms.PSet( + EBPulseShapeTemplate = cms.vdouble ( + 1.13979e-02, 7.58151e-01, 1.00000e+00, 8.87744e-01, 6.73548e-01, 4.74332e-01, 3.19561e-01, 2.15144e-01, 1.47464e-01, 1.01087e-01, 6.93181e-02, 4.75044e-02 + ) , + + EEPulseShapeTemplate = cms.vdouble ( + 1.16442e-01, 7.56246e-01, 1.00000e+00, 8.97182e-01, 6.86831e-01, 4.91506e-01, 3.44111e-01, 2.45731e-01, 1.74115e-01, 1.23361e-01, 8.74288e-02, 6.19570e-02 + ) +) + +ecal_pulse_shape_covariances = cms.PSet( + EBPulseShapeCovariance = cms.vdouble ( + 3.001e-06, 1.233e-05, 0.000e+00, -4.416e-06, -4.571e-06, -3.614e-06, -2.636e-06, -1.286e-06, -8.410e-07, -5.296e-07, 0.000e+00, 0.000e+00, + 1.233e-05, 6.154e-05, 0.000e+00, -2.200e-05, -2.309e-05, -1.838e-05, -1.373e-05, -7.334e-06, -5.088e-06, -3.745e-06, -2.428e-06, 0.000e+00, + 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, + -4.416e-06, -2.200e-05, 0.000e+00, 8.319e-06, 8.545e-06, 6.792e-06, 5.059e-06, 2.678e-06, 1.816e-06, 1.223e-06, 8.245e-07, 5.589e-07, + -4.571e-06, -2.309e-05, 0.000e+00, 8.545e-06, 9.182e-06, 7.219e-06, 5.388e-06, 2.853e-06, 1.944e-06, 1.324e-06, 9.083e-07, 6.335e-07, + -3.614e-06, -1.838e-05, 0.000e+00, 6.792e-06, 7.219e-06, 6.016e-06, 4.437e-06, 2.385e-06, 1.636e-06, 1.118e-06, 7.754e-07, 5.556e-07, + -2.636e-06, -1.373e-05, 0.000e+00, 5.059e-06, 5.388e-06, 4.437e-06, 3.602e-06, 1.917e-06, 1.322e-06, 9.079e-07, 6.529e-07, 4.752e-07, + -1.286e-06, -7.334e-06, 0.000e+00, 2.678e-06, 2.853e-06, 2.385e-06, 1.917e-06, 1.375e-06, 9.100e-07, 6.455e-07, 4.693e-07, 3.657e-07, + -8.410e-07, -5.088e-06, 0.000e+00, 1.816e-06, 1.944e-06, 1.636e-06, 1.322e-06, 9.100e-07, 9.115e-07, 6.062e-07, 4.436e-07, 3.422e-07, + -5.296e-07, -3.745e-06, 0.000e+00, 1.223e-06, 1.324e-06, 1.118e-06, 9.079e-07, 6.455e-07, 6.062e-07, 7.217e-07, 4.862e-07, 3.768e-07, + 0.000e+00, -2.428e-06, 0.000e+00, 8.245e-07, 9.083e-07, 7.754e-07, 6.529e-07, 4.693e-07, 4.436e-07, 4.862e-07, 6.509e-07, 4.418e-07, + 0.000e+00, 0.000e+00, 0.000e+00, 5.589e-07, 6.335e-07, 5.556e-07, 4.752e-07, 3.657e-07, 3.422e-07, 3.768e-07, 4.418e-07, 6.142e-07, + ), + + EEPulseShapeCovariance = cms.vdouble ( + 3.941e-05, 3.333e-05, 0.000e+00, -1.449e-05, -1.661e-05, -1.424e-05, -1.183e-05, -6.842e-06, -4.915e-06, -3.411e-06, 0.000e+00, 0.000e+00, + 3.333e-05, 2.862e-05, 0.000e+00, -1.244e-05, -1.431e-05, -1.233e-05, -1.032e-05, -5.883e-06, -4.154e-06, -2.902e-06, -2.128e-06, 0.000e+00, + 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, + -1.449e-05, -1.244e-05, 0.000e+00, 5.840e-06, 6.649e-06, 5.720e-06, 4.812e-06, 2.708e-06, 1.869e-06, 1.330e-06, 9.186e-07, 6.446e-07, + -1.661e-05, -1.431e-05, 0.000e+00, 6.649e-06, 7.966e-06, 6.898e-06, 5.794e-06, 3.157e-06, 2.184e-06, 1.567e-06, 1.084e-06, 7.575e-07, + -1.424e-05, -1.233e-05, 0.000e+00, 5.720e-06, 6.898e-06, 6.341e-06, 5.347e-06, 2.859e-06, 1.991e-06, 1.431e-06, 9.839e-07, 6.886e-07, + -1.183e-05, -1.032e-05, 0.000e+00, 4.812e-06, 5.794e-06, 5.347e-06, 4.854e-06, 2.628e-06, 1.809e-06, 1.289e-06, 9.020e-07, 6.146e-07, + -6.842e-06, -5.883e-06, 0.000e+00, 2.708e-06, 3.157e-06, 2.859e-06, 2.628e-06, 1.863e-06, 1.296e-06, 8.882e-07, 6.108e-07, 4.283e-07, + -4.915e-06, -4.154e-06, 0.000e+00, 1.869e-06, 2.184e-06, 1.991e-06, 1.809e-06, 1.296e-06, 1.217e-06, 8.669e-07, 5.751e-07, 3.882e-07, + -3.411e-06, -2.902e-06, 0.000e+00, 1.330e-06, 1.567e-06, 1.431e-06, 1.289e-06, 8.882e-07, 8.669e-07, 9.522e-07, 6.717e-07, 4.293e-07, + 0.000e+00, -2.128e-06, 0.000e+00, 9.186e-07, 1.084e-06, 9.839e-07, 9.020e-07, 6.108e-07, 5.751e-07, 6.717e-07, 7.911e-07, 5.493e-07, + 0.000e+00, 0.000e+00, 0.000e+00, 6.446e-07, 7.575e-07, 6.886e-07, 6.146e-07, 4.283e-07, 3.882e-07, 4.293e-07, 5.493e-07, 7.027e-07, + ) +) + +from SimCalorimetry.EcalSimProducers.ecalDigiParameters_cff import * + +ecal_pulse_shape_parameters = cms.PSet( + ecal_pulse_shape_templates, + ecal_digi_parameters, + ecal_pulse_shape_covariances +) diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py b/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py index b38dd33f68d62..fc0ff47f6c1fb 100644 --- a/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py +++ b/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py @@ -5,8 +5,8 @@ # rechit producer ecalRecHit = cms.EDProducer("EcalRecHitProducer", EErechitCollection = cms.string('EcalRecHitsEE'), - EEuncalibRecHitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEE"), - EBuncalibRecHitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEB"), + EEuncalibRecHitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEE"), + EBuncalibRecHitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEB"), EBrechitCollection = cms.string('EcalRecHitsEB'), EKrechitCollection = cms.string('EcalRecHitsEK'), EKuncalibRecHitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEK"), diff --git a/RecoLocalCalo/EcalRecProducers/test/testMultipleEcalRecoLocal_cfg.py b/RecoLocalCalo/EcalRecProducers/test/testMultipleEcalRecoLocal_cfg.py new file mode 100644 index 0000000000000..90f1461509f34 --- /dev/null +++ b/RecoLocalCalo/EcalRecProducers/test/testMultipleEcalRecoLocal_cfg.py @@ -0,0 +1,191 @@ +import FWCore.ParameterSet.Config as cms +process = cms.Process("RECO2") + +process.load('Configuration.StandardSequences.Services_cff') +process.load('FWCore.MessageService.MessageLogger_cfi') +process.load('Configuration.EventContent.EventContent_cff') +process.load('Configuration.StandardSequences.GeometryRecoDB_cff') +process.load('Configuration.Geometry.GeometrySimDB_cff') +process.load('Configuration.StandardSequences.MagneticField_38T_PostLS1_cff') +process.load('Configuration.StandardSequences.EndOfProcess_cff') +process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff') +process.load('Configuration.StandardSequences.RawToDigi_cff') +process.load('Configuration.StandardSequences.Reconstruction_cff') + +process.GlobalTag.globaltag = 'POSTLS172_V1::All' +process.GlobalTag.toGet = cms.VPSet( + cms.PSet(record = cms.string("GeometryFileRcd"), + tag = cms.string("XMLFILE_Geometry_2015_72YV2_Extended2015ZeroMaterial_mc"), + connect = cms.untracked.string("frontier://FrontierProd/CMS_COND_GEOMETRY_000"), +# label = cms.untracked.string("Extended2015ZeroMaterial") + ), + cms.PSet(record = cms.string("EcalTBWeightsRcd"), + tag = cms.string("EcalTBWeights_3p5_time_mc"), + connect = cms.untracked.string("frontier://FrontierPrep/CMS_COND_ECAL") + ) + ) + +#### CONFIGURE IT HERE +isMC = True +##################### +process.MessageLogger.cerr.FwkReport.reportEvery = 1 + +# start from RAW format for more flexibility +process.raw2digi_step = cms.Sequence(process.RawToDigi) + +# get uncalibrechits with global method / time from ratio +import RecoLocalCalo.EcalRecProducers.ecalGlobalUncalibRecHit_cfi +process.ecalGlobalUncalibRecHit = RecoLocalCalo.EcalRecProducers.ecalGlobalUncalibRecHit_cfi.ecalGlobalUncalibRecHit.clone() +# get uncalib rechits from multifit method / time from ratio +import RecoLocalCalo.EcalRecProducers.ecalMultiFitUncalibRecHit_cfi +process.ecalMultiFitUncalibRecHit = RecoLocalCalo.EcalRecProducers.ecalMultiFitUncalibRecHit_cfi.ecalMultiFitUncalibRecHit.clone() +# get uncalib rechits from multifit method / time from weights +process.ecalMultiFit2UncalibRecHit = RecoLocalCalo.EcalRecProducers.ecalMultiFitUncalibRecHit_cfi.ecalMultiFitUncalibRecHit.clone() +process.ecalMultiFit2UncalibRecHit.timealgo = cms.string("WeightsMethod") + +# get the recovered digis +if isMC: + process.ecalDetIdToBeRecovered.ebSrFlagCollection = 'simEcalDigis:ebSrFlags' + process.ecalDetIdToBeRecovered.eeSrFlagCollection = 'simEcalDigis:eeSrFlags' + process.ecalRecHit.recoverEBFE = False + process.ecalRecHit.recoverEEFE = False + process.ecalRecHit.killDeadChannels = False + process.ecalRecHit.ebDetIdToBeRecovered = '' + process.ecalRecHit.eeDetIdToBeRecovered = '' + process.ecalRecHit.ebFEToBeRecovered = '' + process.ecalRecHit.eeFEToBeRecovered = '' + + +process.ecalRecHitGlobal = process.ecalRecHit.clone() +process.ecalRecHitGlobal.EBuncalibRecHitCollection = 'ecalGlobalUncalibRecHit:EcalUncalibRecHitsEB' +process.ecalRecHitGlobal.EEuncalibRecHitCollection = 'ecalGlobalUncalibRecHit:EcalUncalibRecHitsEE' +process.ecalRecHitGlobal.EBrechitCollection = 'EcalRecHitsGlobalEB' +process.ecalRecHitGlobal.EErechitCollection = 'EcalRecHitsGlobalEE' + +process.ecalRecHitMultiFit = process.ecalRecHit.clone() +process.ecalRecHitMultiFit.EBuncalibRecHitCollection = 'ecalMultiFitUncalibRecHit:EcalUncalibRecHitsEB' +process.ecalRecHitMultiFit.EEuncalibRecHitCollection = 'ecalMultiFitUncalibRecHit:EcalUncalibRecHitsEE' +process.ecalRecHitMultiFit.EBrechitCollection = 'EcalRecHitsMultiFitEB' +process.ecalRecHitMultiFit.EErechitCollection = 'EcalRecHitsMultiFitEE' + +process.ecalRecHitMultiFit2 = process.ecalRecHit.clone() +process.ecalRecHitMultiFit2.EBuncalibRecHitCollection = 'ecalMultiFit2UncalibRecHit:EcalUncalibRecHitsEB' +process.ecalRecHitMultiFit2.EEuncalibRecHitCollection = 'ecalMultiFit2UncalibRecHit:EcalUncalibRecHitsEE' +process.ecalRecHitMultiFit2.EBrechitCollection = 'EcalRecHitsMultiFit2EB' +process.ecalRecHitMultiFit2.EErechitCollection = 'EcalRecHitsMultiFit2EE' + +process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(1000) ) +path = '/store/group/comm_ecal/localreco/cmssw_720p4/photongun_pu25_ave40/' +process.source = cms.Source("PoolSource", + duplicateCheckMode = cms.untracked.string("noDuplicateCheck"), + fileNames = cms.untracked.vstring(path+'photongun_pu25_ave40_lsfext2_990.root', + path+'photongun_pu25_ave40_lsfext2_991.root', + path+'photongun_pu25_ave40_lsfext2_992.root', + path+'photongun_pu25_ave40_lsfext2_993.root', + path+'photongun_pu25_ave40_lsfext2_994.root', + path+'photongun_pu25_ave40_lsfext2_995.root', + path+'photongun_pu25_ave40_lsfext2_996.root', + path+'photongun_pu25_ave40_lsfext2_997.root', + path+'photongun_pu25_ave40_lsfext2_998.root', + path+'photongun_pu25_ave40_lsfext2_999.root' + )) + + +process.out = cms.OutputModule("PoolOutputModule", + outputCommands = cms.untracked.vstring('drop *', + 'keep *_ecalUncalib*_*_RECO2', + 'keep *_ecalRecHit*_*_RECO2', + 'keep *_offlineBeamSpot_*_*', + 'keep *_addPileupInfo_*_*' + ), + fileName = cms.untracked.string('reco2_pu40.root') + ) + + +process.ecalAmplitudeReco = cms.Sequence( process.ecalGlobalUncalibRecHit * + process.ecalMultiFitUncalibRecHit * + process.ecalMultiFit2UncalibRecHit + ) + +process.ecalRecHitsReco = cms.Sequence( process.ecalRecHitGlobal * + process.ecalRecHitMultiFit * + process.ecalRecHitMultiFit2 ) + +process.ecalTestRecoLocal = cms.Sequence( process.raw2digi_step * + process.ecalAmplitudeReco * + process.ecalRecHitsReco ) + +from PhysicsTools.PatAlgos.tools.helpers import * + +process.p = cms.Path(process.ecalTestRecoLocal) +process.outpath = cms.EndPath(process.out) + + +######################### +# Time Profiling # +######################### + +#https://twiki.cern.ch/twiki/bin/viewauth/CMS/FastTimerService +process.MessageLogger.categories.append('FastReport') +process.MessageLogger.cerr.FastReport = cms.untracked.PSet( limit = cms.untracked.int32( 10000000 ) ) + +# remove any instance of the FastTimerService +if 'FastTimerService' in process.__dict__: + del process.FastTimerService + +# instrument the menu with the FastTimerService +process.load( "HLTrigger.Timer.FastTimerService_cfi" ) + +# this is currently ignored in 7.x, and alway uses the real tim clock +process.FastTimerService.useRealTimeClock = True + +# enable specific features +process.FastTimerService.enableTimingPaths = True +process.FastTimerService.enableTimingModules = True +process.FastTimerService.enableTimingExclusive = True + +# print a text summary at the end of the job +process.FastTimerService.enableTimingSummary = True + +# skip the first path (useful for HLT timing studies to disregard the time spent loading event and conditions data) +process.FastTimerService.skipFirstPath = False + +# enable per-event DQM plots +process.FastTimerService.enableDQM = True + +# enable per-path DQM plots +process.FastTimerService.enableDQMbyPathActive = True +process.FastTimerService.enableDQMbyPathTotal = True +process.FastTimerService.enableDQMbyPathOverhead = True +process.FastTimerService.enableDQMbyPathDetails = True +process.FastTimerService.enableDQMbyPathCounters = True +process.FastTimerService.enableDQMbyPathExclusive = True + +# enable per-module DQM plots +process.FastTimerService.enableDQMbyModule = True +process.FastTimerService.enableDQMbyModuleType = True + +# enable per-event DQM sumary plots +process.FastTimerService.enableDQMSummary = True + +# enable per-event DQM plots by lumisection +process.FastTimerService.enableDQMbyLumiSection = True +process.FastTimerService.dqmLumiSectionsRange = 2500 # lumisections (23.31 s) + +# set the time resolution of the DQM plots +process.FastTimerService.dqmTimeRange = 1000. # ms +process.FastTimerService.dqmTimeResolution = 5. # ms +process.FastTimerService.dqmPathTimeRange = 100. # ms +process.FastTimerService.dqmPathTimeResolution = 0.5 # ms +process.FastTimerService.dqmModuleTimeRange = 1000. # ms +process.FastTimerService.dqmModuleTimeResolution = 0.5 # ms + +# set the base DQM folder for the plots +process.FastTimerService.dqmPath = "HLT/TimerService" +process.FastTimerService.enableDQMbyProcesses = True + +# save the DQM plots in the DQMIO format +process.dqmOutput = cms.OutputModule("DQMRootOutputModule", + fileName = cms.untracked.string("DQM_pu40.root") + ) +process.FastTimerOutput = cms.EndPath( process.dqmOutput ) diff --git a/SLHCUpgradeSimulations/Configuration/python/customise_phase1_hcal.py b/SLHCUpgradeSimulations/Configuration/python/customise_phase1_hcal.py index 63b41fc91abd9..1823c5b0aef6f 100644 --- a/SLHCUpgradeSimulations/Configuration/python/customise_phase1_hcal.py +++ b/SLHCUpgradeSimulations/Configuration/python/customise_phase1_hcal.py @@ -1,364 +1,722 @@ -import FWCore.ParameterSet.Config as cms - -#common stuff here -def customise(process): - process.load("SLHCUpgradeSimulations.Geometry.recoFromSimDigis_cff") - process.load("SLHCUpgradeSimulations.Geometry.upgradeTracking_phase1_cff") - - process.ctfWithMaterialTracks.TTRHBuilder = 'WithTrackAngle' - process.PixelCPEGenericESProducer.UseErrorsFromTemplates = cms.bool(False) - process.PixelCPEGenericESProducer.TruncatePixelCharge = cms.bool(False) - process.PixelCPEGenericESProducer.LoadTemplatesFromDB = cms.bool(False) - process.PixelCPEGenericESProducer.Upgrade = cms.bool(True) - process.PixelCPEGenericESProducer.SmallPitch = False - process.PixelCPEGenericESProducer.IrradiationBiasCorrection = False - process.PixelCPEGenericESProducer.DoCosmics = False - - ## CPE for other steps - process.siPixelRecHits.CPE = cms.string('PixelCPEGeneric') - process.initialStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - process.lowPtTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - process.pixelPairStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - process.detachedTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - process.mixedTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - process.pixelLessStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - process.tobTecStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - process.highPtTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') - - # Need these lines to stop some errors about missing siStripDigis collections. - # should add them to fakeConditions_Phase1_cff - process.MeasurementTracker.inactiveStripDetectorLabels = cms.VInputTag() - process.MeasurementTracker.UseStripModuleQualityDB = cms.bool(False) - process.MeasurementTracker.UseStripAPVFiberQualityDB = cms.bool(False) - process.MeasurementTracker.UseStripStripQualityDB = cms.bool(False) - process.MeasurementTracker.UsePixelModuleQualityDB = cms.bool(False) - process.MeasurementTracker.UsePixelROCQualityDB = cms.bool(False) - - process.muons.TrackerKinkFinderParameters.TrackerRecHitBuilder = cms.string('WithTrackAngle') - # The SeedMergerPSet should be added to the following file for Phase 1 - # RecoTracker/SpecialSeedGenerators/python/CombinatorialSeedGeneratorForCosmicsRegionalReconstruction_cfi.py - # but pixel layers are not used here for cosmic TODO: need Maria and Jan to do appropriate thing here - process.regionalCosmicTrackerSeeds.SeedMergerPSet = cms.PSet( - mergeTriplets = cms.bool(False), - ttrhBuilderLabel = cms.string( "PixelTTRHBuilderWithoutAngle" ), - addRemainingTriplets = cms.bool(False), - layerListName = cms.string( "PixelSeedMergerQuadruplets" ) - ) - process.regionalCosmicTracks.TTRHBuilder = cms.string('WithTrackAngle') - - - ### back to standard job commands ################################################## - process.DigiToRaw.remove(process.castorRawData) - - process.DigiToRaw.remove(process.siPixelRawData) - process.RawToDigi.remove(process.siPixelDigis) - - - if hasattr(process,'dqmoffline_step'): - process.dqmoffline_step.remove(process.SiPixelTrackResidualSource) - process.dqmoffline_step.remove(process.jetMETAnalyzer) - process.dqmoffline_step.remove(process.hltMonMuBits) - process.dqmoffline_step.remove(process.vbtfAnalyzer) - process.dqmoffline_step.remove(process.hltResults) - process.dqmoffline_step.remove(process.egHLTOffDQMSource) - process.dqmoffline_step.remove(process.globalAnalyzer) - process.dqmoffline_step.remove(process.jetMETHLTOfflineSource) - ## - process.dqmoffline_step.remove(process.TrackerCollisionTrackMon) - if hasattr(process,'validation_step'): - process.validation_step.remove(process.hltHITval) - process.validation_step.remove(process.HLTSusyExoVal) - process.validation_step.remove(process.relvalMuonBits) - process.validation_step.remove(process.hltMuonValidator) - #this takes forever - seems like an infinite loop that I didnt debug yet - process.validation_step.remove(process.pixelDigisValid) - else: - ## removing large memory usage module if we don't need it - process.pdigi.remove(process.mergedtruth) - -# HCAL Upgrade Geometry - - process.load("RecoLocalCalo.HcalRecProducers.HcalUpgradeReconstructor_cff") - process.load("RecoJets.Configuration.CaloTowersRec_cff") - process.load("RecoLocalCalo.HcalRecAlgos.hcalRecAlgoESProd_cfi") - process.load("RecoLocalCalo.Configuration.RecoLocalCalo_cff") - - process.ecalGlobalUncalibRecHit.EBdigiCollection = cms.InputTag("simEcalDigis","ebDigis") - process.ecalGlobalUncalibRecHit.EEdigiCollection = cms.InputTag("simEcalDigis","eeDigis") - process.ecalRecHit.ebDetIdToBeRecovered = cms.InputTag("","") - process.ecalRecHit.eeDetIdToBeRecovered = cms.InputTag("","") - process.ecalRecHit.eeFEToBeRecovered = cms.InputTag("","") - process.ecalRecHit.ebFEToBeRecovered = cms.InputTag("","") - process.ecalRecHit.recoverEBFE = cms.bool(False) - process.ecalRecHit.recoverEEFE = cms.bool(False) - - process.load("RecoLocalCalo.HcalRecProducers.HcalSimpleReconstructor_hbhe_cfi") - process.load("RecoLocalCalo.HcalRecProducers.HcalSimpleReconstructor_ho_cfi") - process.load("RecoLocalCalo.HcalRecProducers.HcalSimpleReconstructor_hf_cfi") - - process.hbheprereco.digiLabel = "simHcalUnsuppressedDigis" - process.horeco.digiLabel = "simHcalUnsuppressedDigis" - process.hfreco.digiLabel = "simHcalUnsuppressedDigis" - process.hcalupgradereco.digiLabel = "simHcalUnsuppressedDigis" - -### Known alterations for Reco ##################################################### - delattr(process,"hbhereco") - process.hbhereco = process.hbheprereco.clone() - - process.metrecoPlusHCALNoise.remove(process.BeamHaloSummary) - process.metrecoPlusHCALNoise.remove(process.GlobalHaloData) - process.metrecoPlusHCALNoise.remove(process.HcalHaloData) - - process.metrecoPlusHCALNoise.remove(process.hcalnoise) - process.jetGlobalReco = cms.Sequence(process.recoJets*process.recoTrackJets) - process.jetHighLevelReco = cms.Sequence(process.recoJetAssociations*process.recoPFJets*process.recoJPTJets) - -### Place to add in the reco steps one by one ###################################### - process.calolocalreco = cms.Sequence(process.ecalGlobalUncalibRecHit+ - process.ecalDetIdToBeRecovered+ - process.ecalRecHit+ - process.ecalCompactTrigPrim+ - process.ecalTPSkim+ - process.ecalPreshowerRecHit+ - #process.hbheprereco+ - process.hbhereco+ - process.horeco+process.hfreco+process.hcalupgradereco+process.towerMaker - #+process.zdcreco - ) - process.localreco = cms.Sequence(process.trackerlocalreco+ - process.muonlocalreco+ - process.calolocalreco+ - process.castorreco+ - process.lumiProducer - ) - process.globalreco = cms.Sequence(process.offlineBeamSpot - *process.recopixelvertexing - *process.trackingGlobalReco - #*process.hcalGlobalRecoSequence - *process.particleFlowCluster - *process.ecalClusters - *process.caloTowersRec - *process.vertexreco - *process.egammaGlobalReco - *process.pfTrackingGlobalReco - *process.jetGlobalReco - *process.muonrecoComplete - *process.muoncosmicreco - *process.CastorFullReco - ) - process.highlevelreco = cms.Sequence(process.egammaHighLevelRecoPrePF - *process.particleFlowReco - *process.egammaHighLevelRecoPostPF - *process.jetHighLevelReco - *process.tautagging - *process.metrecoPlusHCALNoise - *process.btagging - *process.recoPFMET - *process.PFTau - *process.regionalCosmicTracksSeq - *process.muoncosmichighlevelreco - *process.reducedRecHits - ) - process.reconstruction = cms.Sequence( process.localreco * - process.globalreco * - process.highlevelreco * - process.logErrorHarvester - ) - # Clean out some unused sequences - process.hcalLocalRecoSequence=cms.Sequence() - process.hcalGlobalRecoSequence=cms.Sequence() - - return(process) - - -def customise_pu15_25ns(process): - - process=customise(process) - - process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") - -### set the number of pileup - process.mix.input.nbPileupEvents = cms.PSet( - averageNumber = cms.double(15.0) - ) - return (process) - -def customise_3bx(process): - process.mix.maxBunch=1 - process.mix.minBunch=-1 - return process - -def customise_pu15_25ns_3bx(process): - process=customise_pu15_25ns(process) - process=customise_3bx(process) - return process - -#pileup specific stuff here -def customise_pu50_25ns(process): - - process=customise(process) - - process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") - -### set the number of pileup - process.mix.input.nbPileupEvents = cms.PSet( - averageNumber = cms.double(50.0) - ) - -### if doing inefficiency at =50 - process.simSiPixelDigis.AddPixelInefficiency = 20 - ## also for strips TIB inefficiency if we want - ## TIB1,2 inefficiency at 20% - #process.simSiStripDigis.Inefficiency = 20 - ## TIB1,2 inefficiency at 50% - #process.simSiStripDigis.Inefficiency = 30 - ## TIB1,2 inefficiency at 99% (i.e. dead) - #process.simSiStripDigis.Inefficiency = 40 - - return (process) - -def customise_pu50_25ns_3bx(process): - process=customise_pu50_25ns(process) - process=customise_3bx(process) - return process - -def customise_wo_pairs(process): - - process=customise(process) - - process.generalTracks.TrackProducers = (cms.InputTag('initialStepTracks'), - cms.InputTag('highPtTripletStepTracks'), - cms.InputTag('lowPtTripletStepTracks'), - cms.InputTag('mixedTripletStepTracks')) - process.generalTracks.hasSelector=cms.vint32(1,1,1,1) - process.generalTracks.selectedTrackQuals = cms.VInputTag(cms.InputTag("initialStepSelector","initialStep"), - cms.InputTag("highPtTripletStepSelector","highPtTripletStep"), - cms.InputTag("lowPtTripletStepSelector","lowPtTripletStep"), - cms.InputTag("mixedTripletStep") - ) - process.generalTracks.setsToMerge = cms.VPSet( cms.PSet( tLists=cms.vint32(0,1,2,3), pQual=cms.bool(True) ) - ) - - process.newCombinedSeeds.seedCollections = cms.VInputTag( - cms.InputTag('initialStepSeeds'), - cms.InputTag('highPtTripletStepSeeds'), - cms.InputTag('lowPtTripletStepSeeds') - ) - - process.mixedTripletStepClusters.oldClusterRemovalInfo = cms.InputTag("lowPtTripletStepClusters") - process.mixedTripletStepClusters.trajectories = cms.InputTag("lowPtTripletStepTracks") - process.mixedTripletStepClusters.overrideTrkQuals = cms.InputTag('lowPtTripletStepSelector','lowPtTripletStep') - - process.iterTracking.remove(process.PixelPairStep) - return (process) - +import FWCore.ParameterSet.Config as cms + + + +#common stuff here + +def customise(process): + + process.load("SLHCUpgradeSimulations.Geometry.recoFromSimDigis_cff") + + process.load("SLHCUpgradeSimulations.Geometry.upgradeTracking_phase1_cff") + + + + process.ctfWithMaterialTracks.TTRHBuilder = 'WithTrackAngle' + + process.PixelCPEGenericESProducer.UseErrorsFromTemplates = cms.bool(False) + + process.PixelCPEGenericESProducer.TruncatePixelCharge = cms.bool(False) + + process.PixelCPEGenericESProducer.LoadTemplatesFromDB = cms.bool(False) + + process.PixelCPEGenericESProducer.Upgrade = cms.bool(True) + + process.PixelCPEGenericESProducer.SmallPitch = False + + process.PixelCPEGenericESProducer.IrradiationBiasCorrection = False + + process.PixelCPEGenericESProducer.DoCosmics = False + + + + ## CPE for other steps + + process.siPixelRecHits.CPE = cms.string('PixelCPEGeneric') + + process.initialStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + process.lowPtTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + process.pixelPairStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + process.detachedTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + process.mixedTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + process.pixelLessStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + process.tobTecStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + process.highPtTripletStepTracks.TTRHBuilder = cms.string('WithTrackAngle') + + + + # Need these lines to stop some errors about missing siStripDigis collections. + + # should add them to fakeConditions_Phase1_cff + + process.MeasurementTracker.inactiveStripDetectorLabels = cms.VInputTag() + + process.MeasurementTracker.UseStripModuleQualityDB = cms.bool(False) + + process.MeasurementTracker.UseStripAPVFiberQualityDB = cms.bool(False) + + process.MeasurementTracker.UseStripStripQualityDB = cms.bool(False) + + process.MeasurementTracker.UsePixelModuleQualityDB = cms.bool(False) + + process.MeasurementTracker.UsePixelROCQualityDB = cms.bool(False) + + + + process.muons.TrackerKinkFinderParameters.TrackerRecHitBuilder = cms.string('WithTrackAngle') + + # The SeedMergerPSet should be added to the following file for Phase 1 + + # RecoTracker/SpecialSeedGenerators/python/CombinatorialSeedGeneratorForCosmicsRegionalReconstruction_cfi.py + + # but pixel layers are not used here for cosmic TODO: need Maria and Jan to do appropriate thing here + + process.regionalCosmicTrackerSeeds.SeedMergerPSet = cms.PSet( + + mergeTriplets = cms.bool(False), + + ttrhBuilderLabel = cms.string( "PixelTTRHBuilderWithoutAngle" ), + + addRemainingTriplets = cms.bool(False), + + layerListName = cms.string( "PixelSeedMergerQuadruplets" ) + + ) + + process.regionalCosmicTracks.TTRHBuilder = cms.string('WithTrackAngle') + + + + + + ### back to standard job commands ################################################## + + process.DigiToRaw.remove(process.castorRawData) + + + + process.DigiToRaw.remove(process.siPixelRawData) + + process.RawToDigi.remove(process.siPixelDigis) + + + + + + if hasattr(process,'dqmoffline_step'): + + process.dqmoffline_step.remove(process.SiPixelTrackResidualSource) + + process.dqmoffline_step.remove(process.jetMETAnalyzer) + + process.dqmoffline_step.remove(process.hltMonMuBits) + + process.dqmoffline_step.remove(process.vbtfAnalyzer) + + process.dqmoffline_step.remove(process.hltResults) + + process.dqmoffline_step.remove(process.egHLTOffDQMSource) + + process.dqmoffline_step.remove(process.globalAnalyzer) + + process.dqmoffline_step.remove(process.jetMETHLTOfflineSource) + + ## + + process.dqmoffline_step.remove(process.TrackerCollisionTrackMon) + + if hasattr(process,'validation_step'): + + process.validation_step.remove(process.hltHITval) + + process.validation_step.remove(process.HLTSusyExoVal) + + process.validation_step.remove(process.relvalMuonBits) + + process.validation_step.remove(process.hltMuonValidator) + + #this takes forever - seems like an infinite loop that I didnt debug yet + + process.validation_step.remove(process.pixelDigisValid) + + else: + + ## removing large memory usage module if we don't need it + + process.pdigi.remove(process.mergedtruth) + + + +# HCAL Upgrade Geometry + + + + process.load("RecoLocalCalo.HcalRecProducers.HcalUpgradeReconstructor_cff") + + process.load("RecoJets.Configuration.CaloTowersRec_cff") + + process.load("RecoLocalCalo.HcalRecAlgos.hcalRecAlgoESProd_cfi") + + process.load("RecoLocalCalo.Configuration.RecoLocalCalo_cff") + + + + process.ecalMultiFitUncalibRecHit.EBdigiCollection = cms.InputTag("simEcalDigis","ebDigis") + + process.ecalMultiFitUncalibRecHit.EEdigiCollection = cms.InputTag("simEcalDigis","eeDigis") + + process.ecalRecHit.ebDetIdToBeRecovered = cms.InputTag("","") + + process.ecalRecHit.eeDetIdToBeRecovered = cms.InputTag("","") + + process.ecalRecHit.eeFEToBeRecovered = cms.InputTag("","") + + process.ecalRecHit.ebFEToBeRecovered = cms.InputTag("","") + + process.ecalRecHit.recoverEBFE = cms.bool(False) + + process.ecalRecHit.recoverEEFE = cms.bool(False) + + + + process.load("RecoLocalCalo.HcalRecProducers.HcalSimpleReconstructor_hbhe_cfi") + + process.load("RecoLocalCalo.HcalRecProducers.HcalSimpleReconstructor_ho_cfi") + + process.load("RecoLocalCalo.HcalRecProducers.HcalSimpleReconstructor_hf_cfi") + + + + process.hbheprereco.digiLabel = "simHcalUnsuppressedDigis" + + process.horeco.digiLabel = "simHcalUnsuppressedDigis" + + process.hfreco.digiLabel = "simHcalUnsuppressedDigis" + + process.hcalupgradereco.digiLabel = "simHcalUnsuppressedDigis" + + + +### Known alterations for Reco ##################################################### + + delattr(process,"hbhereco") + + process.hbhereco = process.hbheprereco.clone() + + + + process.metrecoPlusHCALNoise.remove(process.BeamHaloSummary) + + process.metrecoPlusHCALNoise.remove(process.GlobalHaloData) + + process.metrecoPlusHCALNoise.remove(process.HcalHaloData) + + + + process.metrecoPlusHCALNoise.remove(process.hcalnoise) + + process.jetGlobalReco = cms.Sequence(process.recoJets*process.recoTrackJets) + + process.jetHighLevelReco = cms.Sequence(process.recoJetAssociations*process.recoPFJets*process.recoJPTJets) + + + +### Place to add in the reco steps one by one ###################################### + + process.calolocalreco = cms.Sequence(process.ecalMultiFitUncalibRecHit+ + + process.ecalDetIdToBeRecovered+ + + process.ecalRecHit+ + + process.ecalCompactTrigPrim+ + + process.ecalTPSkim+ + + process.ecalPreshowerRecHit+ + + #process.hbheprereco+ + + process.hbhereco+ + + process.horeco+process.hfreco+process.hcalupgradereco+process.towerMaker + + #+process.zdcreco + + ) + + process.localreco = cms.Sequence(process.trackerlocalreco+ + + process.muonlocalreco+ + + process.calolocalreco+ + + process.castorreco+ + + process.lumiProducer + + ) + + process.globalreco = cms.Sequence(process.offlineBeamSpot + + *process.recopixelvertexing + + *process.trackingGlobalReco + + #*process.hcalGlobalRecoSequence + + *process.particleFlowCluster + + *process.ecalClusters + + *process.caloTowersRec + + *process.vertexreco + + *process.egammaGlobalReco + + *process.pfTrackingGlobalReco + + *process.jetGlobalReco + + *process.muonrecoComplete + + *process.muoncosmicreco + + *process.CastorFullReco + + ) + + process.highlevelreco = cms.Sequence(process.egammaHighLevelRecoPrePF + + *process.particleFlowReco + + *process.egammaHighLevelRecoPostPF + + *process.jetHighLevelReco + + *process.tautagging + + *process.metrecoPlusHCALNoise + + *process.btagging + + *process.recoPFMET + + *process.PFTau + + *process.regionalCosmicTracksSeq + + *process.muoncosmichighlevelreco + + *process.reducedRecHits + + ) + + process.reconstruction = cms.Sequence( process.localreco * + + process.globalreco * + + process.highlevelreco * + + process.logErrorHarvester + + ) + + # Clean out some unused sequences + + process.hcalLocalRecoSequence=cms.Sequence() + + process.hcalGlobalRecoSequence=cms.Sequence() + + + + return(process) + + + + + +def customise_pu15_25ns(process): + + + + process=customise(process) + + + + process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") + + + +### set the number of pileup + + process.mix.input.nbPileupEvents = cms.PSet( + + averageNumber = cms.double(15.0) + + ) + + return (process) + + + +def customise_3bx(process): + + process.mix.maxBunch=1 + + process.mix.minBunch=-1 + + return process + + + +def customise_pu15_25ns_3bx(process): + + process=customise_pu15_25ns(process) + + process=customise_3bx(process) + + return process + + + +#pileup specific stuff here + +def customise_pu50_25ns(process): + + + + process=customise(process) + + + + process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") + + + +### set the number of pileup + + process.mix.input.nbPileupEvents = cms.PSet( + + averageNumber = cms.double(50.0) + + ) + + + +### if doing inefficiency at =50 + + process.simSiPixelDigis.AddPixelInefficiency = 20 + + ## also for strips TIB inefficiency if we want + + ## TIB1,2 inefficiency at 20% + + #process.simSiStripDigis.Inefficiency = 20 + + ## TIB1,2 inefficiency at 50% + + #process.simSiStripDigis.Inefficiency = 30 + + ## TIB1,2 inefficiency at 99% (i.e. dead) + + #process.simSiStripDigis.Inefficiency = 40 + + + + return (process) + + + +def customise_pu50_25ns_3bx(process): + + process=customise_pu50_25ns(process) + + process=customise_3bx(process) + + return process + + + +def customise_wo_pairs(process): + + + + process=customise(process) + + + + process.generalTracks.TrackProducers = (cms.InputTag('initialStepTracks'), + + cms.InputTag('highPtTripletStepTracks'), + + cms.InputTag('lowPtTripletStepTracks'), + + cms.InputTag('mixedTripletStepTracks')) + + process.generalTracks.hasSelector=cms.vint32(1,1,1,1) + + process.generalTracks.selectedTrackQuals = cms.VInputTag(cms.InputTag("initialStepSelector","initialStep"), + + cms.InputTag("highPtTripletStepSelector","highPtTripletStep"), + + cms.InputTag("lowPtTripletStepSelector","lowPtTripletStep"), + + cms.InputTag("mixedTripletStep") + + ) + + process.generalTracks.setsToMerge = cms.VPSet( cms.PSet( tLists=cms.vint32(0,1,2,3), pQual=cms.bool(True) ) + + ) + + + + process.newCombinedSeeds.seedCollections = cms.VInputTag( + + cms.InputTag('initialStepSeeds'), + + cms.InputTag('highPtTripletStepSeeds'), + + cms.InputTag('lowPtTripletStepSeeds') + + ) + + + + process.mixedTripletStepClusters.oldClusterRemovalInfo = cms.InputTag("lowPtTripletStepClusters") + + process.mixedTripletStepClusters.trajectories = cms.InputTag("lowPtTripletStepTracks") + + process.mixedTripletStepClusters.overrideTrkQuals = cms.InputTag('lowPtTripletStepSelector','lowPtTripletStep') + + + + process.iterTracking.remove(process.PixelPairStep) + + return (process) + + + def turnOffLegacyPhiCorrection(process): process.simHcalUnsuppressedDigis.HcalReLabel.RelabelRules.CorrectPhi = cms.untracked.bool(False) process.HcalHardcodeGeometryEP.HcalReLabel.RelabelRules.CorrectPhi = cms.untracked.bool(False) process.HcalReLabel.RelabelRules.CorrectPhi = cms.untracked.bool(False) return (process) -def customise_pu15_25ns_wo_pairs(process): - - process=customise_wo_pairs(process) - - process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") - -### set the number of pileup - process.mix.input.nbPileupEvents = cms.PSet( - averageNumber = cms.double(15.0) - ) - return (process) - - -#pileup specific stuff here -def customise_pu50_25ns_wo_pairs(process): - - process=customise_wo_pairs(process) - - process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") - -### set the number of pileup - process.mix.input.nbPileupEvents = cms.PSet( - averageNumber = cms.double(50.0) - ) - - -### if doing inefficiency at =50 - process.simSiPixelDigis.AddPixelInefficiency = 20 - ## also for strips TIB inefficiency if we want - ## TIB1,2 inefficiency at 20% - #process.simSiStripDigis.Inefficiency = 20 - ## TIB1,2 inefficiency at 50% - #process.simSiStripDigis.Inefficiency = 30 - ## TIB1,2 inefficiency at 99% (i.e. dead) - #process.simSiStripDigis.Inefficiency = 40 - - return (process) - -def saveAllProds(process): - keys=process.outputModules.keys() - for k in keys: - mod=getattr(process,k) - mod.outputCommands.extend(['keep *_simHcalUnsuppressedDigis_*_*', - 'keep *_hcalupgradereco_*_*', - 'keep *_hbhereco_*_*', - 'keep recoPFRecHits_particleFlowRecHitPS_*_*', - 'keep recoPFRecHits_particleFlowRecHitECAL_*_*', - 'keep recoPFBlocks_particleFlowBlock_*_*', - 'keep recoPFRecTracks_pfTrack_*_*', - 'keep recoPFClusters_particleFlowClusterPS_*_*', - 'keep recoPFClusters_particleFlowClusterECAL_*_*', - 'keep recoPFDisplacedVertexCandidates_particleFlowDisplacedVertexCandidate_*_*', - 'keep recoPFCandidates_particleFlow_*_*', - 'keep recoPFClusters_particleFlowClusterHCAL_*_*', - 'keep recoPFClusters_particleFlowClusterHCALUpgrade_*_*', - 'keep recoPFClusters_particleFlowClusterHO_*_*', - 'keep CaloTowersSorted_towerMakerPF_*_*', - 'keep recoPFCandidates_pfNoPileUp_*_*', - 'keep recoPFCandidates_pfAllPhotons_*_*', - 'keep recoPFRecHits_particleFlowRecHitHCAL_*_*', - 'keep recoPFRecHits_particleFlowRecHitHCALUpgrade_*_*', - 'keep recoPFRecHits_particleFlowRecHitHO_*_*', - 'keep recoPileUpPFCandidates_pfPileUp_*_*', - 'keep recoGsfPFRecTracks_pfTrackElec_*_*', - 'keep recoGsfPFRecTracks_pfTrackElec_Secondary_*', - 'keep recoPFCandidates_pfAllNeutralHadrons_*_*', - 'keep recoPFCandidates_pfAllChargedHadrons_*_*', - 'keep recoPFCandidates_particleFlow_electrons_*', - 'keep recoPFRecTracks_pfV0_*_*', - 'keep recoJetedmRefToBaseProdrecoTracksrecoTrackrecoTracksTorecoTrackedmrefhelperFindUsingAdvanceedmRefVectorsAssociationVector_ak5PFJetTracksAssociatorAtVertex_*_*', - 'keep recoPFRecTracks_pfConversions_*_*', - 'keep recoPFCandidateElectronExtras_particleFlow_*_*', - 'keep recoPFRecHits_particleFlowRecHitECAL_Cleaned_*', - 'keep recoPFV0s_pfV0_*_*', - 'keep recoPFCandidates_pfSelectedElectrons_*_*', - 'keep recoPFDisplacedVertexs_particleFlowDisplacedVertex_*_*', - 'keep recoPFRecTracks_pfDisplacedTrackerVertex_*_*', - 'keep recoPFConversions_pfConversions_*_*', - 'keep recoPFCandidates_particleFlow_CleanedPunchThroughNeutralHadrons_*', - 'keep recoPFDisplacedTrackerVertexs_pfDisplacedTrackerVertex_*_*', - 'keep recoPFCandidates_particleFlow_CleanedTrackerAndGlobalMuons_*', - 'keep recoPFCandidates_particleFlow_CleanedPunchThroughMuons_*', - 'keep recoPFCandidates_particleFlow_AddedMuonsAndHadrons_*', - 'keep recoPFMETs_pfMet_*_*', - 'keep recoPFCandidates_particleFlow_CleanedCosmicsMuons_*', - 'keep recoPFRecHits_particleFlowClusterHFHAD_Cleaned_*', - 'keep recoPFCandidates_particleFlow_CleanedFakeMuons_*', - 'keep recoPFRecHits_particleFlowClusterECAL_Cleaned_*', - 'keep recoPFRecHits_particleFlowClusterHFEM_Cleaned_*', - 'keep recoPFRecHits_particleFlowClusterHCAL_Cleaned_*', - 'keep recoPFRecHits_particleFlowRecHitHCAL_Cleaned_*', - 'keep recoPFRecHits_particleFlowClusterHCALUpgrade_Cleaned_*', - 'keep recoPFRecHits_particleFlowRecHitHCALUpgrade_Cleaned_*', - 'keep recoPFRecHits_particleFlowClusterHO_Cleaned_*', - 'keep recoPFRecHits_particleFlowRecHitHO_Cleaned_*', - 'keep recoPFRecHits_particleFlowClusterPS_Cleaned_*', - 'keep recoPFRecHits_particleFlowRecHitHCAL_HFHAD_*', - 'keep recoPFRecHits_particleFlowRecHitPS_Cleaned_*', - 'keep recoPFRecHits_particleFlowRecHitHCAL_HFEM_*', - 'keep recoPFClusters_particleFlowClusterHFHAD_*_*', - 'keep recoPFClusters_particleFlowClusterHFEM_*_*', - 'keep recoPFCandidates_particleFlow_CleanedHF_*', - 'keep recoPFCandidates_pfSelectedPhotons_*_*']) - return process +def customise_pu15_25ns_wo_pairs(process): + + + + process=customise_wo_pairs(process) + + + + process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") + + + +### set the number of pileup + + process.mix.input.nbPileupEvents = cms.PSet( + + averageNumber = cms.double(15.0) + + ) + + return (process) + + + + + +#pileup specific stuff here + +def customise_pu50_25ns_wo_pairs(process): + + + + process=customise_wo_pairs(process) + + + + process.load("SLHCUpgradeSimulations.Geometry.mixLowLumPU_Phase1_R30F12_HCal_cff") + + + +### set the number of pileup + + process.mix.input.nbPileupEvents = cms.PSet( + + averageNumber = cms.double(50.0) + + ) + + + + + +### if doing inefficiency at =50 + + process.simSiPixelDigis.AddPixelInefficiency = 20 + + ## also for strips TIB inefficiency if we want + + ## TIB1,2 inefficiency at 20% + + #process.simSiStripDigis.Inefficiency = 20 + + ## TIB1,2 inefficiency at 50% + + #process.simSiStripDigis.Inefficiency = 30 + + ## TIB1,2 inefficiency at 99% (i.e. dead) + + #process.simSiStripDigis.Inefficiency = 40 + + + + return (process) + + + +def saveAllProds(process): + + keys=process.outputModules.keys() + + for k in keys: + + mod=getattr(process,k) + + mod.outputCommands.extend(['keep *_simHcalUnsuppressedDigis_*_*', + + 'keep *_hcalupgradereco_*_*', + + 'keep *_hbhereco_*_*', + + 'keep recoPFRecHits_particleFlowRecHitPS_*_*', + + 'keep recoPFRecHits_particleFlowRecHitECAL_*_*', + + 'keep recoPFBlocks_particleFlowBlock_*_*', + + 'keep recoPFRecTracks_pfTrack_*_*', + + 'keep recoPFClusters_particleFlowClusterPS_*_*', + + 'keep recoPFClusters_particleFlowClusterECAL_*_*', + + 'keep recoPFDisplacedVertexCandidates_particleFlowDisplacedVertexCandidate_*_*', + + 'keep recoPFCandidates_particleFlow_*_*', + + 'keep recoPFClusters_particleFlowClusterHCAL_*_*', + + 'keep recoPFClusters_particleFlowClusterHCALUpgrade_*_*', + + 'keep recoPFClusters_particleFlowClusterHO_*_*', + + 'keep CaloTowersSorted_towerMakerPF_*_*', + + 'keep recoPFCandidates_pfNoPileUp_*_*', + + 'keep recoPFCandidates_pfAllPhotons_*_*', + + 'keep recoPFRecHits_particleFlowRecHitHCAL_*_*', + + 'keep recoPFRecHits_particleFlowRecHitHCALUpgrade_*_*', + + 'keep recoPFRecHits_particleFlowRecHitHO_*_*', + + 'keep recoPileUpPFCandidates_pfPileUp_*_*', + + 'keep recoGsfPFRecTracks_pfTrackElec_*_*', + + 'keep recoGsfPFRecTracks_pfTrackElec_Secondary_*', + + 'keep recoPFCandidates_pfAllNeutralHadrons_*_*', + + 'keep recoPFCandidates_pfAllChargedHadrons_*_*', + + 'keep recoPFCandidates_particleFlow_electrons_*', + + 'keep recoPFRecTracks_pfV0_*_*', + + 'keep recoJetedmRefToBaseProdrecoTracksrecoTrackrecoTracksTorecoTrackedmrefhelperFindUsingAdvanceedmRefVectorsAssociationVector_ak5PFJetTracksAssociatorAtVertex_*_*', + + 'keep recoPFRecTracks_pfConversions_*_*', + + 'keep recoPFCandidateElectronExtras_particleFlow_*_*', + + 'keep recoPFRecHits_particleFlowRecHitECAL_Cleaned_*', + + 'keep recoPFV0s_pfV0_*_*', + + 'keep recoPFCandidates_pfSelectedElectrons_*_*', + + 'keep recoPFDisplacedVertexs_particleFlowDisplacedVertex_*_*', + + 'keep recoPFRecTracks_pfDisplacedTrackerVertex_*_*', + + 'keep recoPFConversions_pfConversions_*_*', + + 'keep recoPFCandidates_particleFlow_CleanedPunchThroughNeutralHadrons_*', + + 'keep recoPFDisplacedTrackerVertexs_pfDisplacedTrackerVertex_*_*', + + 'keep recoPFCandidates_particleFlow_CleanedTrackerAndGlobalMuons_*', + + 'keep recoPFCandidates_particleFlow_CleanedPunchThroughMuons_*', + + 'keep recoPFCandidates_particleFlow_AddedMuonsAndHadrons_*', + + 'keep recoPFMETs_pfMet_*_*', + + 'keep recoPFCandidates_particleFlow_CleanedCosmicsMuons_*', + + 'keep recoPFRecHits_particleFlowClusterHFHAD_Cleaned_*', + + 'keep recoPFCandidates_particleFlow_CleanedFakeMuons_*', + + 'keep recoPFRecHits_particleFlowClusterECAL_Cleaned_*', + + 'keep recoPFRecHits_particleFlowClusterHFEM_Cleaned_*', + + 'keep recoPFRecHits_particleFlowClusterHCAL_Cleaned_*', + + 'keep recoPFRecHits_particleFlowRecHitHCAL_Cleaned_*', + + 'keep recoPFRecHits_particleFlowClusterHCALUpgrade_Cleaned_*', + + 'keep recoPFRecHits_particleFlowRecHitHCALUpgrade_Cleaned_*', + + 'keep recoPFRecHits_particleFlowClusterHO_Cleaned_*', + + 'keep recoPFRecHits_particleFlowRecHitHO_Cleaned_*', + + 'keep recoPFRecHits_particleFlowClusterPS_Cleaned_*', + + 'keep recoPFRecHits_particleFlowRecHitHCAL_HFHAD_*', + + 'keep recoPFRecHits_particleFlowRecHitPS_Cleaned_*', + + 'keep recoPFRecHits_particleFlowRecHitHCAL_HFEM_*', + + 'keep recoPFClusters_particleFlowClusterHFHAD_*_*', + + 'keep recoPFClusters_particleFlowClusterHFEM_*_*', + + 'keep recoPFCandidates_particleFlow_CleanedHF_*', + + 'keep recoPFCandidates_pfSelectedPhotons_*_*']) + + return process + diff --git a/SUSYBSMAnalysis/HSCP/src/BetaCalculatorECAL.cc b/SUSYBSMAnalysis/HSCP/src/BetaCalculatorECAL.cc index 442a14860e38f..a21c2a3677b44 100644 --- a/SUSYBSMAnalysis/HSCP/src/BetaCalculatorECAL.cc +++ b/SUSYBSMAnalysis/HSCP/src/BetaCalculatorECAL.cc @@ -131,8 +131,8 @@ void BetaCalculatorECAL::addInfoToCandidate(HSCParticle& candidate, edm::Handle< result.ecalEnergies.push_back(hit.energy()); result.ecalTimes.push_back(hit.time()); result.ecalTimeErrors.push_back(hit.timeError()); - result.ecalOutOfTimeEnergies.push_back(hit.outOfTimeEnergy()); - result.ecalOutOfTimeChi2s.push_back(hit.outOfTimeChi2()); + result.ecalOutOfTimeEnergies.push_back(0.); + result.ecalOutOfTimeChi2s.push_back(0.); result.ecalChi2s.push_back(hit.chi2()); result.ecalDetIds.push_back(ebDetId); // SIC DEBUG diff --git a/Validation/Configuration/python/ECALHCAL.py b/Validation/Configuration/python/ECALHCAL.py index 4ff22d48bc7e2..92abc9c92961c 100644 --- a/Validation/Configuration/python/ECALHCAL.py +++ b/Validation/Configuration/python/ECALHCAL.py @@ -38,8 +38,8 @@ def customise(process): process.schedule.append(process.generation_step) process.schedule.append(process.simulation_step) - process.ecalGlobalUncalibRecHit.EBdigiCollection = cms.InputTag("simEcalDigis","ebDigis") - process.ecalGlobalUncalibRecHit.EEdigiCollection = cms.InputTag("simEcalDigis","eeDigis") + process.ecalMultiFitUncalibRecHit.EBdigiCollection = cms.InputTag("simEcalDigis","ebDigis") + process.ecalMultiFitUncalibRecHit.EEdigiCollection = cms.InputTag("simEcalDigis","eeDigis") process.ecalPreshowerRecHit.ESdigiCollection = cms.InputTag("simEcalPreshowerDigis") delattr(process,"hbhereco") diff --git a/Validation/EcalRecHits/python/ecalBarrelRecHitsValidation_cfi.py b/Validation/EcalRecHits/python/ecalBarrelRecHitsValidation_cfi.py index d2fe62f197e18..27c0df8df70ad 100644 --- a/Validation/EcalRecHits/python/ecalBarrelRecHitsValidation_cfi.py +++ b/Validation/EcalRecHits/python/ecalBarrelRecHitsValidation_cfi.py @@ -2,7 +2,7 @@ ecalBarrelRecHitsValidation = cms.EDAnalyzer("EcalBarrelRecHitsValidation", EBdigiCollection = cms.InputTag("simEcalDigis","ebDigis"), - EBuncalibrechitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEB"), + EBuncalibrechitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEB"), verbose = cms.untracked.bool(False) ) diff --git a/Validation/EcalRecHits/python/ecalEndcapRecHitsValidation_cfi.py b/Validation/EcalRecHits/python/ecalEndcapRecHitsValidation_cfi.py index b16e5a383f463..447e1accc6e96 100644 --- a/Validation/EcalRecHits/python/ecalEndcapRecHitsValidation_cfi.py +++ b/Validation/EcalRecHits/python/ecalEndcapRecHitsValidation_cfi.py @@ -2,7 +2,7 @@ ecalEndcapRecHitsValidation = cms.EDAnalyzer("EcalEndcapRecHitsValidation", EEdigiCollection = cms.InputTag("simEcalDigis","eeDigis"), - EEuncalibrechitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEE"), + EEuncalibrechitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEE"), verbose = cms.untracked.bool(False) ) diff --git a/Validation/EcalRecHits/python/ecalPreshowerRecHitsValidation_cfi.py b/Validation/EcalRecHits/python/ecalPreshowerRecHitsValidation_cfi.py index ad96dfd069883..b49a6262600ab 100644 --- a/Validation/EcalRecHits/python/ecalPreshowerRecHitsValidation_cfi.py +++ b/Validation/EcalRecHits/python/ecalPreshowerRecHitsValidation_cfi.py @@ -3,7 +3,7 @@ ecalPreshowerRecHitsValidation = cms.EDAnalyzer("EcalPreshowerRecHitsValidation", EErechitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEE"), ESrechitCollection = cms.InputTag("ecalPreshowerRecHit","EcalRecHitsES"), - EEuncalibrechitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEE"), + EEuncalibrechitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEE"), verbose = cms.untracked.bool(False) ) diff --git a/Validation/EcalRecHits/python/ecalRecHitsValidation_cfi.py b/Validation/EcalRecHits/python/ecalRecHitsValidation_cfi.py index 81693e70c1ab2..e3820a4e54d94 100644 --- a/Validation/EcalRecHits/python/ecalRecHitsValidation_cfi.py +++ b/Validation/EcalRecHits/python/ecalRecHitsValidation_cfi.py @@ -3,9 +3,9 @@ ecalRecHitsValidation = cms.EDAnalyzer("EcalRecHitsValidation", hitsProducer = cms.string('g4SimHits'), outputFile = cms.untracked.string(''), - EBuncalibrechitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEB"), - EEuncalibrechitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEE"), - EKuncalibrechitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEK"), + EBuncalibrechitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEB"), + EEuncalibrechitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEE"), + EKuncalibrechitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEK"), verbose = cms.untracked.bool(False), EBrechitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEB"), EErechitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEE"), From f21f415f3c7b364586ea8ba83e166da13bcf6930 Mon Sep 17 00:00:00 2001 From: Josh Bendavid Date: Mon, 13 Oct 2014 22:48:56 +0200 Subject: [PATCH 190/252] minimal fixes to compile multifit backport in 62x --- DQM/EcalBarrelMonitorTasks/src/EnergyTask.cc | 4 ++-- DataFormats/EcalRecHit/src/EcalRecHit.cc | 2 +- DataFormats/EcalRecHit/src/classes_def.xml | 3 ++- .../plugins/EcalUncalibRecHitWorkerGlobal.cc | 6 ++---- .../plugins/EcalUncalibRecHitWorkerMultiFit.cc | 13 ++++--------- .../plugins/EcalUncalibRecHitWorkerMultiFit.h | 5 +---- 6 files changed, 12 insertions(+), 21 deletions(-) diff --git a/DQM/EcalBarrelMonitorTasks/src/EnergyTask.cc b/DQM/EcalBarrelMonitorTasks/src/EnergyTask.cc index d025ca16b1bd2..74ce98c239ed7 100644 --- a/DQM/EcalBarrelMonitorTasks/src/EnergyTask.cc +++ b/DQM/EcalBarrelMonitorTasks/src/EnergyTask.cc @@ -70,7 +70,7 @@ namespace ecaldqm { if(isPhysicsRun_ && hitItr->checkFlagMask(mask)) continue; - float energy(isPhysicsRun_ ? hitItr->energy() : hitItr->outOfTimeEnergy()); + float energy = hitItr->energy(); if ( energy < 0. ) energy = 0.0; @@ -91,7 +91,7 @@ namespace ecaldqm { for(std::vector::iterator idItr(window.begin()); idItr != window.end(); ++idItr){ if((neighborItr = _hits.find(*idItr)) == _hits.end()) continue; if(isPhysicsRun_ && neighborItr->checkFlagMask(mask)) continue; - neighborE = isPhysicsRun_ ? neighborItr->energy() : neighborItr->outOfTimeEnergy(); + neighborE = neighborItr->energy(); if(neighborE > energy){ isSeed = false; break; diff --git a/DataFormats/EcalRecHit/src/EcalRecHit.cc b/DataFormats/EcalRecHit/src/EcalRecHit.cc index c7521f8f0736d..173a2a18da383 100644 --- a/DataFormats/EcalRecHit/src/EcalRecHit.cc +++ b/DataFormats/EcalRecHit/src/EcalRecHit.cc @@ -37,7 +37,7 @@ float EcalRecHit::outOfTimeChi2() const return (float)rawChi2Prob / (float)((1<<7)-1) * 64.; } -float EcalRecHit::EnergyError() const +float EcalRecHit::energyError() const { uint32_t rawEnergy = (0x1FFF & flags()>>11); uint16_t exponent = rawEnergy>>10; diff --git a/DataFormats/EcalRecHit/src/classes_def.xml b/DataFormats/EcalRecHit/src/classes_def.xml index 4b2d9a8e9f6d6..fdf7361032e42 100644 --- a/DataFormats/EcalRecHit/src/classes_def.xml +++ b/DataFormats/EcalRecHit/src/classes_def.xml @@ -1,5 +1,6 @@ - + + diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerGlobal.cc b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerGlobal.cc index 2ebdbffa039f4..6608fcde784ce 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerGlobal.cc +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerGlobal.cc @@ -438,7 +438,7 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, if(doEKtimeCorrection_) theTimeCorrectionEK = timeCorrectionEK( uncalibRecHit.amplitude() ); uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEK); uncalibRecHit.setJitterError( std::sqrt(pow(crh.timeError,2) + std::pow(EKtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); - uncalibRecHit.setOutOfTimeEnergy( crh.amplitudeMax ); + //uncalibRecHit.setOutOfTimeEnergy( crh.amplitudeMax ); // consider flagging as kOutOfTime only if above noise if (uncalibRecHit.amplitude() > pedRMSVec[0] * amplitudeThreshEK_){ float outOfTimeThreshP = outOfTimeThreshG12pEK_; @@ -546,7 +546,7 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, } } else if (detid.subdetId()==EcalShashlik) { double amplitude = uncalibRecHit.amplitude(); - double amplitudeOutOfTime = uncalibRecHit.outOfTimeEnergy(); + double amplitudeOutOfTime = 0.; double jitter= uncalibRecHit.jitter(); EcalUncalibRecHitRecChi2Algochi2expressEK_( @@ -563,8 +563,6 @@ EcalUncalibRecHitWorkerGlobal::run( const edm::Event & evt, ); double chi2 = chi2expressEK_.chi2(); uncalibRecHit.setChi2(chi2); - double chi2OutOfTime = chi2expressEK_.chi2OutOfTime(); - uncalibRecHit.setOutOfTimeChi2(chi2OutOfTime); if(kPoorRecoFlagEK_) { diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc index 7e3b9ca534e87..ecfe68fd87973 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc @@ -12,11 +12,10 @@ #include "CondFormats/DataRecord/interface/EcalSampleMaskRcd.h" #include "CondFormats/DataRecord/interface/EcalTimeCalibConstantsRcd.h" #include "CondFormats/DataRecord/interface/EcalTimeOffsetConstantRcd.h" -#include "CondFormats/DataRecord/interface/EcalTimeBiasCorrectionsRcd.h" -EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&ps,edm::ConsumesCollector& c) : - EcalUncalibRecHitWorkerBaseClass(ps,c), +EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&ps) : + EcalUncalibRecHitWorkerBaseClass(ps), noisecorEBg12(10), noisecorEEg12(10), noisecorEBg6(10), noisecorEEg6(10), noisecorEBg1(10), noisecorEEg1(10), @@ -119,8 +118,6 @@ EcalUncalibRecHitWorkerMultiFit::set(const edm::EventSetup& es) es.get().get(itime); es.get().get(offtime); - // for the time correction methods - es.get().get(timeCorrBias_); } /** @@ -295,8 +292,7 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, ratioMethod_endcap_.computeTime( EEtimeFitParameters_, EEtimeFitLimits_, EEamplitudeFitParameters_ ); ratioMethod_endcap_.computeAmplitude( EEamplitudeFitParameters_); EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_endcap_.getCalculatedRecHit(); - double theTimeCorrectionEE = timeCorrection(uncalibRecHit.amplitude(), - timeCorrBias_->EETimeCorrAmplitudeBins, timeCorrBias_->EETimeCorrShiftBins); + double theTimeCorrectionEE = 0.; uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEE); uncalibRecHit.setJitterError( std::sqrt(pow(crh.timeError,2) + std::pow(EEtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); @@ -308,8 +304,7 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, ratioMethod_barrel_.computeAmplitude( EBamplitudeFitParameters_); EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_barrel_.getCalculatedRecHit(); - double theTimeCorrectionEB = timeCorrection(uncalibRecHit.amplitude(), - timeCorrBias_->EBTimeCorrAmplitudeBins, timeCorrBias_->EBTimeCorrShiftBins); + double theTimeCorrectionEB = 0.; uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEB); diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h index 0b1d1c11a48c2..2e4ca07a020e2 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h @@ -24,7 +24,6 @@ #include "CondFormats/EcalObjects/interface/EcalWeightXtalGroups.h" #include "CondFormats/EcalObjects/interface/EcalTBWeights.h" #include "CondFormats/EcalObjects/interface/EcalSampleMask.h" -#include "CondFormats/EcalObjects/interface/EcalTimeBiasCorrections.h" namespace edm { @@ -36,7 +35,7 @@ namespace edm { class EcalUncalibRecHitWorkerMultiFit : public EcalUncalibRecHitWorkerBaseClass { public: - EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&, edm::ConsumesCollector& c); + EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&); //EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&); virtual ~EcalUncalibRecHitWorkerMultiFit() {}; @@ -102,8 +101,6 @@ class EcalUncalibRecHitWorkerMultiFit : public EcalUncalibRecHitWorkerBaseClass double EBtimeConstantTerm_; double EEtimeConstantTerm_; - edm::ESHandle timeCorrBias_; - // leading edge method edm::ESHandle itime; edm::ESHandle offtime; From 2f2ac449a8888c719ede66e24fd1bc85727714fd Mon Sep 17 00:00:00 2001 From: David Lange Date: Tue, 23 Sep 2014 19:11:47 +0200 Subject: [PATCH 191/252] Merge pull request #5321 from bendavid/ecalMultifit_optimized Ecal multifit optimized Resolved Conflicts: RecoLocalCalo/EcalRecAlgos/BuildFile.xml RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitProducer.h RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h --- RecoLocalCalo/EcalRecAlgos/BuildFile.xml | 1 + .../interface/EcalUncalibRecHitMultiFitAlgo.h | 2 +- .../EcalUncalibRecHitTimeWeightsAlgo.h | 7 +- .../EcalRecAlgos/interface/EigenMatrixTypes.h | 11 + .../EcalRecAlgos/interface/PulseChiSqSNNLS.h | 68 ++-- .../EcalRecAlgos/interface/TDecompCholFast.h | 13 - .../src/EcalUncalibRecHitMultiFitAlgo.cc | 31 +- .../EcalRecAlgos/src/PulseChiSqSNNLS.cc | 363 +++++++++--------- .../EcalRecAlgos/src/TDecompCholFast.cc | 25 -- .../plugins/EcalUncalibRecHitProducer.h | 2 +- .../EcalUncalibRecHitWorkerMultiFit.cc | 32 +- .../plugins/EcalUncalibRecHitWorkerMultiFit.h | 25 +- 12 files changed, 265 insertions(+), 315 deletions(-) create mode 100644 RecoLocalCalo/EcalRecAlgos/interface/EigenMatrixTypes.h delete mode 100644 RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h delete mode 100644 RecoLocalCalo/EcalRecAlgos/src/TDecompCholFast.cc diff --git a/RecoLocalCalo/EcalRecAlgos/BuildFile.xml b/RecoLocalCalo/EcalRecAlgos/BuildFile.xml index 12a45490b79ad..36bdc4cbbff38 100644 --- a/RecoLocalCalo/EcalRecAlgos/BuildFile.xml +++ b/RecoLocalCalo/EcalRecAlgos/BuildFile.xml @@ -9,6 +9,7 @@ + diff --git a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h index e7af495a2b351..ad9c4f687b1cf 100644 --- a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h +++ b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h @@ -25,7 +25,7 @@ class EcalUncalibRecHitMultiFitAlgo EcalUncalibRecHitMultiFitAlgo(); ~EcalUncalibRecHitMultiFitAlgo() { }; - EcalUncalibratedRecHit makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const TMatrixDSym &noisecor, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov, const std::set &activeBX); + EcalUncalibratedRecHit makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const SampleMatrix &noisecor, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov, const BXVector &activeBX); void disableErrorCalculation() { _computeErrors = false; } private: diff --git a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h index cb5a6168b6fc0..ff5c58f528c13 100644 --- a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h +++ b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitTimeWeightsAlgo.h @@ -17,6 +17,9 @@ #include "CondFormats/EcalObjects/interface/EcalGainRatios.h" #include "CondFormats/EcalObjects/interface/EcalWeightSet.h" +#include "RecoLocalCalo/EcalRecAlgos/interface/EigenMatrixTypes.h" + + #include "TVectorD.h" #include @@ -28,7 +31,7 @@ template class EcalUncalibRecHitTimeWeightsAlgo virtual ~EcalUncalibRecHitTimeWeightsAlgo() { }; /// Compute time - double time(const C& dataFrame, const std::vector &litudes, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const TVectorD &fullpulse, const EcalWeightSet::EcalWeightMatrix** weights) { + double time(const C& dataFrame, const std::vector &litudes, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const FullSampleVector &fullpulse, const EcalWeightSet::EcalWeightMatrix** weights) { const unsigned int nsample = EcalDataFrame::MAXSAMPLES; @@ -84,7 +87,7 @@ template class EcalUncalibRecHitTimeWeightsAlgo int ipulse = std::distance(amplitudes.begin(),amplit); int bx = ipulse - 5; int firstsamplet = std::max(0,bx + 3); - int offset = -3-bx; + int offset = 7-3-bx; TVectorD pulse; pulse.ResizeTo(nsample); diff --git a/RecoLocalCalo/EcalRecAlgos/interface/EigenMatrixTypes.h b/RecoLocalCalo/EcalRecAlgos/interface/EigenMatrixTypes.h new file mode 100644 index 0000000000000..97adb60648a34 --- /dev/null +++ b/RecoLocalCalo/EcalRecAlgos/interface/EigenMatrixTypes.h @@ -0,0 +1,11 @@ +#include + +typedef Eigen::Matrix SampleVector; +typedef Eigen::Matrix FullSampleVector; +typedef Eigen::Matrix PulseVector; +typedef Eigen::Matrix BXVector; +typedef Eigen::Matrix SampleMatrix; +typedef Eigen::Matrix FullSampleMatrix; +typedef Eigen::Matrix PulseMatrix; +typedef Eigen::Matrix SamplePulseMatrix; +typedef Eigen::LLT SampleDecompLLT; diff --git a/RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h b/RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h index 21d89f0ffd663..acedca00a9a3a 100644 --- a/RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h +++ b/RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h @@ -1,69 +1,53 @@ #ifndef PulseChiSqSNNLS_h #define PulseChiSqSNNLS_h -#include "TMatrixD.h" -#include "TVectorD.h" -#include "TMatrixDSym.h" -#include "Math/Minimizer.h" -#include "Math/IFunction.h" -#include "RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h" +#include "RecoLocalCalo/EcalRecAlgos/interface/EigenMatrixTypes.h" #include #include class PulseChiSqSNNLS { public: + + typedef BXVector::Index Index; + PulseChiSqSNNLS(); ~PulseChiSqSNNLS(); - bool DoFit(const std::vector &samples, const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov); + bool DoFit(const SampleVector &samples, const SampleMatrix &samplecor, double pederr, const BXVector &bxs, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov); - const TMatrixD &pulsemat() const { return _pulsemat; } - const TMatrixDSym &invcov() const { return _invcov; } + const SamplePulseMatrix &pulsemat() const { return _pulsemat; } + const SampleMatrix &invcov() const { return _invcov; } - const TVectorD &X() const { return _ampvecmin; } - const TVectorD &Errors() const { return _errvec; } + const PulseVector &X() const { return _ampvecmin; } + const PulseVector &Errors() const { return _errvec; } + const BXVector &BXs() const { return _bxsmin; } double ChiSq() const { return _chisq; } void disableErrorCalculation() { _computeErrors = false; } protected: - bool Minimize(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov); + bool Minimize(const SampleMatrix &samplecor, double pederr, const FullSampleMatrix &fullpulsecov); bool NNLS(); - bool updateCov(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov); + bool updateCov(const SampleMatrix &samplecor, double pederr, const FullSampleMatrix &fullpulsecov); double ComputeChiSq(); + double ComputeApproxUncertainty(unsigned int ipulse); + - TVectorD _sampvec; - TMatrixDSym _invcov; - TVectorD _workvec; - TMatrixD _pulsemat; - TVectorD _ampvec; - TVectorD _ampvecmin; - TVectorD _errvec; - TMatrixD _workmat; - TMatrixD _aTamat; - TVectorD _wvec; - TVectorD _aTbvec; - TVectorD _aTbcorvec; - TMatrixDSym _aPmat; - TVectorD _sPvec; - TDecompCholFast _decompP; - std::array _pulsematstorage; - std::array _ampvecstorage; - std::array _ampvecminstorage; - std::array _errvecstorage; - std::array _workmatstorage; - std::array _aTamatstorage; - std::array _wvecstorage; - std::array _aTbvecstorage; - std::array _aTbcorvecstorage; - std::array _aPstorage; - std::array _sPstorage; - std::array _decompPstorage; - std::set _idxsP; - std::set _idxsFixed; + SampleVector _sampvec; + SampleMatrix _invcov; + SamplePulseMatrix _pulsemat; + PulseVector _ampvec; + PulseVector _errvec; + PulseVector _ampvecmin; + + SampleDecompLLT _covdecomp; + + BXVector _bxs; + BXVector _bxsmin; + unsigned int _nP; double _chisq; bool _computeErrors; diff --git a/RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h b/RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h deleted file mode 100644 index de505e77d9da9..0000000000000 --- a/RecoLocalCalo/EcalRecAlgos/interface/TDecompCholFast.h +++ /dev/null @@ -1,13 +0,0 @@ -#ifndef TDecompCholFast_h -#define TDecompCholFast_h - -#include "TDecompChol.h" - -class TDecompCholFast : public TDecompChol { - public: - TDecompCholFast() {} - - void SetMatrixFast(const TMatrixDSym& a, double *data); -}; - -#endif diff --git a/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc b/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc index 7b60af435701d..050317c411e06 100644 --- a/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc +++ b/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc @@ -10,7 +10,7 @@ EcalUncalibRecHitMultiFitAlgo::EcalUncalibRecHitMultiFitAlgo() : } /// compute rechits -EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const TMatrixDSym &noisecor, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov, const std::set &activeBX) { +EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const SampleMatrix &noisecor, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov, const BXVector &activeBX) { uint32_t flags = 0; @@ -21,7 +21,7 @@ EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataF double pedval = 0.; double pedrms = 0.; - std::vector amplitudes(nsample); + SampleVector amplitudes; for(unsigned int iSample = 0; iSample < nsample; iSample++) { const EcalMGPASample &sample = dataFrame.sample(iSample); @@ -66,10 +66,6 @@ EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataF } } - - - std::vector fitvals; - std::vector fiterrs; if(!_computeErrors) _pulsefunc.disableErrorCalculation(); bool status = _pulsefunc.DoFit(amplitudes,noisecor,pedrms,activeBX,fullpulse,fullpulsecov); @@ -79,25 +75,32 @@ EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataF edm::LogWarning("EcalUncalibRecHitMultiFitAlgo::makeRecHit") << "Failed Fit" << std::endl; } - unsigned int ipulseintime = std::distance(activeBX.begin(),activeBX.find(0)); + unsigned int ipulseintime = 0; + for (unsigned int ipulse=0; ipulse<_pulsefunc.BXs().rows(); ++ipulse) { + if (_pulsefunc.BXs().coeff(ipulse)==0) { + ipulseintime = ipulse; + break; + } + } + double amplitude = status ? _pulsefunc.X()[ipulseintime] : 0.; double amperr = status ? _pulsefunc.Errors()[ipulseintime] : 0.; double jitter = 0.; + //printf("status = %i\n",int(status)); //printf("amplitude = %5f +- %5f, chisq = %5f\n",amplitude,amperr,chisq); EcalUncalibratedRecHit rh( dataFrame.id(), amplitude , pedval, jitter, chisq, flags ); rh.setAmplitudeError(amperr); - for (std::set::const_iterator bxit = activeBX.begin(); bxit!=activeBX.end(); ++bxit) { - int ipulse = std::distance(activeBX.begin(),bxit); - if(*bxit==0) { - rh.setOutOfTimeAmplitude(*bxit+5,0.); - } else { - rh.setOutOfTimeAmplitude(*bxit+5, status ? _pulsefunc.X()[ipulse] : 0.); + + for (unsigned int ipulse=0; ipulse<_pulsefunc.BXs().rows(); ++ipulse) { + int bx = _pulsefunc.BXs().coeff(ipulse); + if (bx!=0) { + rh.setOutOfTimeAmplitude(bx+5, status ? _pulsefunc.X().coeff(ipulse) : 0.); } } - + return rh; } diff --git a/RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc b/RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc index a1ad6e53b4581..043870e7f826c 100644 --- a/RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc +++ b/RecoLocalCalo/EcalRecAlgos/src/PulseChiSqSNNLS.cc @@ -1,14 +1,14 @@ #include "RecoLocalCalo/EcalRecAlgos/interface/PulseChiSqSNNLS.h" #include #include "FWCore/MessageLogger/interface/MessageLogger.h" +#include PulseChiSqSNNLS::PulseChiSqSNNLS() : - _sampvec(10), - _invcov(10), - _workvec(10), _chisq(0.), _computeErrors(true) { + + Eigen::initParallel(); } @@ -16,94 +16,110 @@ PulseChiSqSNNLS::~PulseChiSqSNNLS() { } -bool PulseChiSqSNNLS::DoFit(const std::vector &samples, const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TVectorD &fullpulse, const TMatrixDSym &fullpulsecov) { +bool PulseChiSqSNNLS::DoFit(const SampleVector &samples, const SampleMatrix &samplecor, double pederr, const BXVector &bxs, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov) { - const unsigned int nsample = samples.size(); - const unsigned int npulse = bxs.size(); - - //resize matrices using reserved memory on the stack - _pulsemat.Use(nsample,npulse,_pulsematstorage.data()); - _ampvec.Use(npulse,_ampvecstorage.data()); - _ampvecmin.Use(npulse,_ampvecminstorage.data()); - _errvec.Use(npulse,_errvecstorage.data()); - _workmat.Use(npulse,nsample,_workmatstorage.data()); - _aTamat.Use(npulse,npulse,_aTamatstorage.data()); - _wvec.Use(npulse,_wvecstorage.data()); - _aTbvec.Use(npulse,_aTbvecstorage.data()); - _aTbcorvec.Use(npulse,_aTbcorvecstorage.data()); - - //initialize parameters and index index set - _sampvec.SetElements(samples.data()); - _ampvec.Zero(); - _idxsP.clear(); - _idxsFixed.clear(); - _chisq = 0.; + const unsigned int nsample = SampleVector::RowsAtCompileTime; + const unsigned int npulse = bxs.rows(); + + _sampvec = samples; + _bxs = bxs; + _pulsemat = SamplePulseMatrix::Zero(nsample,npulse); + _ampvec = PulseVector::Zero(npulse); + _errvec = PulseVector::Zero(npulse); + _nP = 0; + _chisq = 0.; + //initialize pulse template matrix - for (std::set::const_iterator bxit = bxs.begin(); bxit!=bxs.end(); ++bxit) { - int ipulse = std::distance(bxs.begin(),bxit); - int bx = *bxit; + for (unsigned int ipulse=0; ipulse::const_iterator itintime = _idxsP.find(ipulseintime); - if (itintime != _idxsP.end()) { - _idxsP.erase(itintime); + //compute MINOS-like uncertainties for in-time amplitude + bool foundintime = false; + unsigned int ipulseintime = 0; + for (unsigned int ipulse=0; ipulse 0.5 ) { + for (unsigned int ipulse=0; ipulse 0.5 ) { - double xminus100 = std::max(0.,x0-_errvec[ipulseintime]); - _ampvec[ipulseintime] = xminus100; - status &= Minimize(samplecor,pederr,bxs,fullpulsecov); - if (!status) return status; - double chisqminus100 = ComputeChiSq(); - - double sigmaminus = std::abs(xminus100-x0)/sqrt(chisqminus100-chisq0); - _errvec[ipulseintime] = 0.5*(sigmaplus + sigmaminus); - - } - else { - _errvec[ipulseintime] = sigmaplus; - } - - _chisq = chisq0; } - + else { + _errvec[ipulseintimemin] = sigmaplus; + } + + _chisq = chisq0; + return status; } -bool PulseChiSqSNNLS::Minimize(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov) { +bool PulseChiSqSNNLS::Minimize(const SampleMatrix &samplecor, double pederr, const FullSampleMatrix &fullpulsecov) { const int maxiter = 50; @@ -116,7 +132,7 @@ bool PulseChiSqSNNLS::Minimize(const TMatrixDSym &samplecor, double pederr, cons break; } - status = updateCov(samplecor,pederr,bxs,fullpulsecov); + status = updateCov(samplecor,pederr,fullpulsecov); if (!status) break; status = NNLS(); if (!status) break; @@ -135,42 +151,47 @@ bool PulseChiSqSNNLS::Minimize(const TMatrixDSym &samplecor, double pederr, cons } -bool PulseChiSqSNNLS::updateCov(const TMatrixDSym &samplecor, double pederr, const std::set &bxs, const TMatrixDSym &fullpulsecov) { +bool PulseChiSqSNNLS::updateCov(const SampleMatrix &samplecor, double pederr, const FullSampleMatrix &fullpulsecov) { - const unsigned int nsample = _sampvec.GetNrows(); + const unsigned int nsample = SampleVector::RowsAtCompileTime; + const unsigned int npulse = _bxs.rows(); - _invcov = samplecor; - _invcov *= pederr*pederr; + _invcov.triangularView() = (pederr*pederr)*samplecor; - for (std::set::const_iterator bxit = bxs.begin(); bxit!=bxs.end(); ++bxit) { - int ipulse = std::distance(bxs.begin(),bxit); - if (_ampvec[ipulse]==0.) continue; - int bx = *bxit; + for (unsigned int ipulse=0; ipulse() += ampsq*fullpulsecov.block(firstsamplet+offset,firstsamplet+offset,nsamplepulse,nsamplepulse); + } + + _covdecomp.compute(_invcov); + bool status = true; return status; } double PulseChiSqSNNLS::ComputeChiSq() { - - //compute chi square after fit - _workvec = _pulsemat*_ampvec; - _workvec -= _sampvec; - _workvec *= -1.; - return _invcov.Similarity(_workvec); + +// SampleVector resvec = _pulsemat*_ampvec - _sampvec; +// return resvec.transpose()*_covdecomp.solve(resvec); + + return _covdecomp.matrixL().solve(_pulsemat*_ampvec - _sampvec).squaredNorm(); + +} + +double PulseChiSqSNNLS::ComputeApproxUncertainty(unsigned int ipulse) { + //compute approximate uncertainties + //(using 1/second derivative since full Hessian is not meaningful in + //presence of positive amplitude boundaries.) + + return 1./_covdecomp.matrixL().solve(_pulsemat.col(ipulse)).norm(); } @@ -178,135 +199,95 @@ bool PulseChiSqSNNLS::NNLS() { //Fast NNLS (fnnls) algorithm as per http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.157.9203&rep=rep1&type=pdf - unsigned int nsample = _sampvec.GetNrows(); + const unsigned int npulse = _bxs.rows(); - _workmat.TMult(_pulsemat,_invcov); - _aTamat.Mult(_workmat,_pulsemat); - _aTbvec = _workmat*_sampvec; + SamplePulseMatrix invcovp = _covdecomp.matrixL().solve(_pulsemat); + PulseMatrix aTamat(npulse,npulse); + aTamat.triangularView() = invcovp.transpose()*invcovp; + aTamat = aTamat.selfadjointView(); + PulseVector aTbvec = invcovp.transpose()*_covdecomp.matrixL().solve(_sampvec); + + + PulseVector wvec(npulse); - //correct for possible effect of non-zero fixed amplitudes - _workvec = _sampvec; - for (std::set::const_iterator itidx=_idxsFixed.begin(); itidx!=_idxsFixed.end(); ++itidx) { - for (unsigned int isample=0; isample0 || !_idxsP.size()) { - if ( (_idxsP.size()+_idxsFixed.size())==npulse ) break; + if (iter>0 || _nP==0) { + if ( _nP==npulse ) break; - //compute derivatives - _wvec = _ampvec; - _wvec *= _aTamat; - _wvec -= _aTbvec; - _wvec *= -1.0; + const unsigned int nActive = npulse - _nP; + + wvec.tail(nActive) = aTbvec.tail(nActive) - (aTamat.selfadjointView()*_ampvec).tail(nActive); - //find wmax in active set - double wmax = -std::numeric_limits::max(); - unsigned int idxwmax = 0; - for (unsigned int idx=0; idxwmax) { - wmax = _wvec[idx]; - idxwmax = idx; - } - } + Index idxwmax; + double wmax = wvec.tail(nActive).maxCoeff(&idxwmax); //convergence if (wmax<1e-11) break; //unconstrain parameter - _idxsP.insert(idxwmax); + Index idxp = _nP + idxwmax; + //printf("adding index %i, orig index %i\n",int(idxp),int(_bxs.coeff(idxp))); + aTamat.col(_nP).swap(aTamat.col(idxp)); + aTamat.row(_nP).swap(aTamat.row(idxp)); + _pulsemat.col(_nP).swap(_pulsemat.col(idxp)); + std::swap(aTbvec.coeffRef(_nP),aTbvec.coeffRef(idxp)); + std::swap(_ampvec.coeffRef(_nP),_ampvec.coeffRef(idxp)); + std::swap(_bxs.coeffRef(_nP),_bxs.coeffRef(idxp)); + ++_nP; } while (true) { //printf("iter in, idxsP = %i\n",int(_idxsP.size())); - if (_idxsP.size()==0) break; + if (_nP==0) break; - //trick: resize matrices without reallocating memory - const unsigned int npulseP = _idxsP.size(); - _aPmat.Use(npulseP,_aPstorage.data()); - _sPvec.Use(npulseP,_sPstorage.data()); + PulseVector ampvecpermtest = _ampvec; - //fill reduced matrix AP - for (std::set::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { - unsigned int iidx = std::distance(_idxsP.begin(),itidx); - _sPvec(iidx) = _aTbcorvec(*itidx); - for (std::set::const_iterator jtidx=_idxsP.begin(); jtidx!=_idxsP.end(); ++jtidx) { - unsigned int jidx = std::distance(_idxsP.begin(),jtidx); - _aPmat(iidx,jidx) = _aTamat(*itidx,*jtidx); - } - } - - //solve for unconstrained parameters - _decompP.SetMatrixFast(_aPmat,_decompPstorage.data()); - bool status = _decompP.Solve(_sPvec); - if (!status) return false; + //solve for unconstrained parameters + ampvecpermtest.head(_nP) = aTamat.topLeftCorner(_nP,_nP).ldlt().solve(aTbvec.head(_nP)); //check solution - if (_sPvec.Min()>0.) { - //_ampvec.Zero(); - for (std::set::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { - unsigned int iidx = std::distance(_idxsP.begin(),itidx); - _ampvec[*itidx] = _sPvec[iidx]; - } - + if (ampvecpermtest.head(_nP).minCoeff()>0.) { + _ampvec.head(_nP) = ampvecpermtest.head(_nP); break; } - + //update parameter vector + Index minratioidx=0; + double minratio = std::numeric_limits::max(); - unsigned int minratioidx = 0; - for (std::set::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { - unsigned int iidx = std::distance(_idxsP.begin(),itidx); - double ratio = _ampvec[*itidx]/(_ampvec[*itidx]-_sPvec[iidx]); - if (_sPvec[iidx]<=0. && ratio::const_iterator itidx=_idxsP.begin(); itidx!=_idxsP.end(); ++itidx) { - unsigned int iidx = std::distance(_idxsP.begin(),itidx); - _ampvec[*itidx] += minratio*(_sPvec[iidx] - _ampvec[*itidx]); - } - - - //printf("fixing indexes\n"); - for (unsigned int ipulse = 0; ipulse::const_iterator itpulse = _idxsP.find(ipulse); - if (itpulse!=_idxsP.end()) { - _ampvec[ipulse] = 0.; - _idxsP.erase(itpulse); - } - } - } + //avoid numerical problems with later ==0. check + _ampvec.coeffRef(minratioidx) = 0.; + + //printf("removing index %i, orig idx %i\n",int(minratioidx),int(_bxs.coeff(minratioidx))); + aTamat.col(_nP-1).swap(aTamat.col(minratioidx)); + aTamat.row(_nP-1).swap(aTamat.row(minratioidx)); + _pulsemat.col(_nP-1).swap(_pulsemat.col(minratioidx)); + std::swap(aTbvec.coeffRef(_nP-1),aTbvec.coeffRef(minratioidx)); + std::swap(_ampvec.coeffRef(_nP-1),_ampvec.coeffRef(minratioidx)); + std::swap(_bxs.coeffRef(_nP-1),_bxs.coeffRef(minratioidx)); + --_nP; } ++iter; } - //compute approximate uncertainties - //(using 1/second derivative since full Hessian is not meaningful in - //presence of positive amplitude boundaries.) - for (unsigned int ipulse=0; ipulse("EcalPulseShapeParameters"); @@ -27,7 +28,10 @@ EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::Para // get the BX for the pulses to be activated std::vector activeBXs = ps.getParameter< std::vector >("activeBXs"); - for(unsigned int ibx=0; ibx("ampErrorCalculation"); @@ -277,9 +281,9 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, if (((EcalDataFrame)(*itdg)).hasSwitchToGain1()) { gain = 1; } - const TMatrixDSym &noisecormat = noisecor(barrel,gain); - const TVectorD &fullpulse = barrel ? fullpulseEB : fullpulseEE; - const TMatrixDSym &fullpulsecov = barrel ? fullpulsecovEB : fullpulsecovEE; + const SampleMatrix &noisecormat = noisecor(barrel,gain); + const FullSampleVector &fullpulse = barrel ? fullpulseEB : fullpulseEE; + const FullSampleMatrix &fullpulsecov = barrel ? fullpulsecovEB : fullpulsecovEE; uncalibRecHit = multiFitMethod_.makeRecHit(*itdg, aped, aGain, noisecormat,fullpulse,fullpulsecov,activeBX); @@ -397,7 +401,7 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, } -const TMatrixDSym &EcalUncalibRecHitWorkerMultiFit::noisecor(bool barrel, int gain) const { +const SampleMatrix &EcalUncalibRecHitWorkerMultiFit::noisecor(bool barrel, int gain) const { if (barrel) { if (gain==6) { return noisecorEBg6; @@ -454,8 +458,8 @@ void EcalUncalibRecHitWorkerMultiFit::fillInputs(const edm::ParameterSet& params const std::vector eePulse = params.getParameter< std::vector >("EEPulseShapeTemplate"); int nShapeSamples = ebPulse.size(); for (int i=0; i ebPulseCov = params.getParameter< std::vector >("EBPulseShapeCovariance"); @@ -463,8 +467,8 @@ void EcalUncalibRecHitWorkerMultiFit::fillInputs(const edm::ParameterSet& params for(int k=0; k& amplitudeBins, const std::vector& shiftBins); - const TMatrixDSym &noisecor(bool barrel, int gain) const; + const SampleMatrix &noisecor(bool barrel, int gain) const; // multifit method - TMatrixDSym noisecorEBg12; - TMatrixDSym noisecorEEg12; - TMatrixDSym noisecorEBg6; - TMatrixDSym noisecorEEg6; - TMatrixDSym noisecorEBg1; - TMatrixDSym noisecorEEg1; - TVectorD fullpulseEB; - TVectorD fullpulseEE; - TMatrixDSym fullpulsecovEB; - TMatrixDSym fullpulsecovEE; - std::set activeBX; + SampleMatrix noisecorEBg12; + SampleMatrix noisecorEEg12; + SampleMatrix noisecorEBg6; + SampleMatrix noisecorEEg6; + SampleMatrix noisecorEBg1; + SampleMatrix noisecorEEg1; + FullSampleVector fullpulseEB; + FullSampleVector fullpulseEE; + FullSampleMatrix fullpulsecovEB; + FullSampleMatrix fullpulsecovEE; + BXVector activeBX; bool ampErrorCalculation_; EcalUncalibRecHitMultiFitAlgo multiFitMethod_; From f47ea0faf077e72e3db9920af4cbe7d050cc41fd Mon Sep 17 00:00:00 2001 From: Josh Bendavid Date: Mon, 13 Oct 2014 23:39:10 +0200 Subject: [PATCH 192/252] minimal compilation fixes for multifit optimized backport --- .../EcalRecProducers/plugins/EcalUncalibRecHitProducer.h | 2 +- .../EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitProducer.h b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitProducer.h index 13f0d91d05d33..0ffb9e02bd65c 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitProducer.h +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitProducer.h @@ -1,7 +1,7 @@ #ifndef RecoLocalCalo_EcalRecProducers_EcalUncalibRecHitProducer_hh #define RecoLocalCalo_EcalRecProducers_EcalUncalibRecHitProducer_hh -#include "FWCore/Framework/interface/stream/EDProducer.h" +#include "FWCore/Framework/interface/EDProducer.h" #include "FWCore/ParameterSet/interface/ParameterSet.h" #include "FWCore/Framework/interface/Event.h" #include "FWCore/Framework/interface/EventSetup.h" diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc index c88ac106b2e1d..297713c23ccd0 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc @@ -15,7 +15,7 @@ EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&ps) : - EcalUncalibRecHitWorkerBaseClass(ps,c), + EcalUncalibRecHitWorkerBaseClass(ps), noisecorEBg12(SampleMatrix::Zero()), noisecorEEg12(SampleMatrix::Zero()), noisecorEBg6(SampleMatrix::Zero()), noisecorEEg6(SampleMatrix::Zero()), noisecorEBg1(SampleMatrix::Zero()), noisecorEEg1(SampleMatrix::Zero()), From 5e7cdbe16c73927ecc05363a5999a452e552a512 Mon Sep 17 00:00:00 2001 From: Josh Bendavid Date: Tue, 14 Oct 2014 01:10:13 +0200 Subject: [PATCH 193/252] bring multifit reconstruction in line with EB/EE/EK paradigm for shashlik --- .../EcalUncalibRecHitWorkerMultiFit.cc | 297 ++++++++++++------ .../plugins/EcalUncalibRecHitWorkerMultiFit.h | 32 +- .../python/ecalMultiFitUncalibRecHit_cfi.py | 55 ++++ .../python/ecalPulseShapeParameters_cff.py | 21 +- .../EcalRecProducers/python/ecalRecHit_cfi.py | 2 +- 5 files changed, 313 insertions(+), 94 deletions(-) diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc index 297713c23ccd0..d88dc822b9b1d 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc @@ -16,11 +16,11 @@ EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::ParameterSet&ps) : EcalUncalibRecHitWorkerBaseClass(ps), - noisecorEBg12(SampleMatrix::Zero()), noisecorEEg12(SampleMatrix::Zero()), - noisecorEBg6(SampleMatrix::Zero()), noisecorEEg6(SampleMatrix::Zero()), - noisecorEBg1(SampleMatrix::Zero()), noisecorEEg1(SampleMatrix::Zero()), - fullpulseEB(FullSampleVector::Zero()),fullpulseEE(FullSampleVector::Zero()), - fullpulsecovEB(FullSampleMatrix::Zero()),fullpulsecovEE(FullSampleMatrix::Zero()) { + noisecorEBg12(SampleMatrix::Zero()), noisecorEEg12(SampleMatrix::Zero()), noisecorEKg12(SampleMatrix::Zero()), + noisecorEBg6(SampleMatrix::Zero()), noisecorEEg6(SampleMatrix::Zero()), noisecorEKg6(SampleMatrix::Zero()), + noisecorEBg1(SampleMatrix::Zero()), noisecorEEg1(SampleMatrix::Zero()), noisecorEKg1(SampleMatrix::Zero()), + fullpulseEB(FullSampleVector::Zero()),fullpulseEE(FullSampleVector::Zero()),fullpulseEK(FullSampleVector::Zero()), + fullpulsecovEB(FullSampleMatrix::Zero()),fullpulsecovEE(FullSampleMatrix::Zero()),fullpulsecovEK(FullSampleMatrix::Zero()) { // get the pulse shape, amplitude covariances and noise correlations EcalPulseShapeParameters_ = ps.getParameter("EcalPulseShapeParameters"); @@ -42,24 +42,55 @@ EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::Para // ratio method parameters EBtimeFitParameters_ = ps.getParameter >("EBtimeFitParameters"); EEtimeFitParameters_ = ps.getParameter >("EEtimeFitParameters"); + EKtimeFitParameters_ = ps.getParameter >("EKtimeFitParameters"); EBamplitudeFitParameters_ = ps.getParameter >("EBamplitudeFitParameters"); EEamplitudeFitParameters_ = ps.getParameter >("EEamplitudeFitParameters"); + EKamplitudeFitParameters_ = ps.getParameter >("EKamplitudeFitParameters"); EBtimeFitLimits_.first = ps.getParameter("EBtimeFitLimits_Lower"); EBtimeFitLimits_.second = ps.getParameter("EBtimeFitLimits_Upper"); EEtimeFitLimits_.first = ps.getParameter("EEtimeFitLimits_Lower"); EEtimeFitLimits_.second = ps.getParameter("EEtimeFitLimits_Upper"); + EKtimeFitLimits_.first = ps.getParameter("EKtimeFitLimits_Lower"); + EKtimeFitLimits_.second = ps.getParameter("EKtimeFitLimits_Upper"); EBtimeConstantTerm_=ps.getParameter("EBtimeConstantTerm"); EEtimeConstantTerm_=ps.getParameter("EEtimeConstantTerm"); - + EKtimeConstantTerm_=ps.getParameter("EKtimeConstantTerm"); + + // amplitude-dependent correction of time + doEBtimeCorrection_ = ps.getParameter("doEBtimeCorrection"); + doEEtimeCorrection_ = ps.getParameter("doEEtimeCorrection"); + doEKtimeCorrection_ = ps.getParameter("doEKtimeCorrection"); + EBtimeCorrAmplitudeBins_ = ps.getParameter >("EBtimeCorrAmplitudeBins"); + EBtimeCorrShiftBins_ = ps.getParameter >("EBtimeCorrShiftBins"); + EEtimeCorrAmplitudeBins_ = ps.getParameter >("EEtimeCorrAmplitudeBins"); + EEtimeCorrShiftBins_ = ps.getParameter >("EEtimeCorrShiftBins"); + EKtimeCorrAmplitudeBins_ = ps.getParameter >("EKtimeCorrAmplitudeBins"); + EKtimeCorrShiftBins_ = ps.getParameter >("EKtimeCorrShiftBins"); + if(EBtimeCorrAmplitudeBins_.size() != EBtimeCorrShiftBins_.size()) { + doEBtimeCorrection_ = false; + edm::LogError("EcalRecHitError") << "Size of EBtimeCorrAmplitudeBins different from EBtimeCorrShiftBins. Forcing no time corrections for EB. "; + } + if(EEtimeCorrAmplitudeBins_.size() != EEtimeCorrShiftBins_.size()) { + doEEtimeCorrection_ = false; + edm::LogError("EcalRecHitError") << "Size of EEtimeCorrAmplitudeBins different from EEtimeCorrShiftBins. Forcing no time corrections for EE. "; + } + if(EKtimeCorrAmplitudeBins_.size() != EKtimeCorrShiftBins_.size()) { + doEKtimeCorrection_ = false; + edm::LogError("EcalRecHitError") << "Size of EKtimeCorrAmplitudeBins different from EKtimeCorrShiftBins. Forcing no time corrections for EK. "; + } + // leading edge parameters ebPulseShape_ = ps.getParameter >("ebPulseShape"); eePulseShape_ = ps.getParameter >("eePulseShape"); + ekPulseShape_ = ps.getParameter >("ekPulseShape"); // chi2 parameters for flags determination kPoorRecoFlagEB_ = ps.getParameter("kPoorRecoFlagEB"); kPoorRecoFlagEE_ = ps.getParameter("kPoorRecoFlagEE");; + kPoorRecoFlagEK_ = ps.getParameter("kPoorRecoFlagEK");; chi2ThreshEB_=ps.getParameter("chi2ThreshEB_"); chi2ThreshEE_=ps.getParameter("chi2ThreshEE_"); + chi2ThreshEK_=ps.getParameter("chi2ThreshEK_"); } @@ -124,67 +155,114 @@ EcalUncalibRecHitWorkerMultiFit::set(const edm::EventSetup& es) } -/** - * Amplitude-dependent time corrections; EE and EB have separate corrections: - * EXtimeCorrAmplitudes (ADC) and EXtimeCorrShifts (ns) need to have the same number of elements - * Bins must be ordered in amplitude. First-last bins take care of under-overflows. - * - * The algorithm is the same for EE and EB, only the correction vectors are different. - * - * @return Jitter (in clock cycles) which will be added to UncalibRechit.setJitter(), 0 if no correction is applied. - */ -double EcalUncalibRecHitWorkerMultiFit::timeCorrection( - float ampli, - const std::vector& amplitudeBins, - const std::vector& shiftBins) { - - // computed initially in ns. Than turned in the BX's, as - // EcalUncalibratedRecHit need be. - double theCorrection = 0; - - // sanity check for arrays - if (amplitudeBins.size() == 0) { - edm::LogError("EcalRecHitError") - << "timeCorrAmplitudeBins is empty, forcing no time bias corrections."; - - return 0; +double EcalUncalibRecHitWorkerMultiFit::timeCorrectionEB(float ampliEB){ + // computed initially in ns. Than turned in the BX's, as EcalUncalibratedRecHit need be. + double theCorrection=0; + + + int myBin = -1; + for (int bin=0; bin<(int)EBtimeCorrAmplitudeBins_.size(); bin++ ){ + if(ampliEB > EBtimeCorrAmplitudeBins_.at(bin)) { + myBin = bin; } + else break; } + + if (myBin == -1) + { + theCorrection = EBtimeCorrShiftBins_.at(0); + } + else if ( myBin == ((int)(EBtimeCorrAmplitudeBins_.size()-1)) ) + { + theCorrection = EBtimeCorrShiftBins_.at( myBin ); + } + else if ( -1 < myBin && myBin < ((int)EBtimeCorrAmplitudeBins_.size()-1) ) + { + // interpolate linearly between two assingned points + theCorrection = ( EBtimeCorrShiftBins_.at(myBin+1) - EBtimeCorrShiftBins_.at(myBin) ); + theCorrection *= ( ((double)ampliEB) - EBtimeCorrAmplitudeBins_.at(myBin) ) / ( EBtimeCorrAmplitudeBins_.at(myBin+1) - EBtimeCorrAmplitudeBins_.at(myBin) ); + theCorrection += EBtimeCorrShiftBins_.at(myBin); + } + else + { + edm::LogError("EcalRecHitError") << "Assigning time correction impossible. Setting it to 0 "; + theCorrection = 0.; + } - if (amplitudeBins.size() != shiftBins.size()) { - edm::LogError("EcalRecHitError") - << "Size of timeCorrAmplitudeBins different from " - "timeCorrShiftBins. Forcing no time bias corrections. "; + // convert ns into clocks + return theCorrection/25.; +} - return 0; - } +double EcalUncalibRecHitWorkerMultiFit::timeCorrectionEE(float ampliEE){ + // computed initially in ns. Than turned in the BX's, as EcalUncalibratedRecHit need be. + double theCorrection=0; + int myBin = -1; - for (int bin = 0; bin < (int) amplitudeBins.size(); bin++) { - if (ampli > amplitudeBins.at(bin)) { - myBin = bin; - } else { - break; - } + for (int bin=0; bin<(int)EEtimeCorrAmplitudeBins_.size(); bin++ ){ + if(ampliEE > EEtimeCorrAmplitudeBins_.at(bin)) { + myBin = bin; } + else break; } + + if (myBin == -1) + { + theCorrection = EEtimeCorrShiftBins_.at(0); + } + else if ( myBin == ((int)(EEtimeCorrAmplitudeBins_.size()-1)) ) + { + theCorrection = EEtimeCorrShiftBins_.at( myBin ); + } + else if ( -1 < myBin && myBin < ((int)EEtimeCorrAmplitudeBins_.size()-1) ) + { + // interpolate linearly between two assingned points + theCorrection = ( EEtimeCorrShiftBins_.at(myBin+1) - EEtimeCorrShiftBins_.at(myBin) ); + theCorrection *= ( ((double)ampliEE) - EEtimeCorrAmplitudeBins_.at(myBin) ) / ( EEtimeCorrAmplitudeBins_.at(myBin+1) - EEtimeCorrAmplitudeBins_.at(myBin) ); + theCorrection += EEtimeCorrShiftBins_.at(myBin); + } + else + { + edm::LogError("EcalRecHitError") << "Assigning time correction impossible. Setting it to 0 "; + theCorrection = 0.; + } + + // convert ns into clocks + return theCorrection/25.; +} - if (myBin == -1) { - theCorrection = shiftBins.at(0); - } else if (myBin == ((int)(amplitudeBins.size() - 1))) { - theCorrection = shiftBins.at(myBin); - } else if (-1 < myBin && myBin < ((int) amplitudeBins.size() - 1)) { - // interpolate linearly between two assingned points - theCorrection = (shiftBins.at(myBin + 1) - shiftBins.at(myBin)); - theCorrection *= (((double) ampli) - amplitudeBins.at(myBin)) / - (amplitudeBins.at(myBin + 1) - amplitudeBins.at(myBin)); - theCorrection += shiftBins.at(myBin); - } else { - edm::LogError("EcalRecHitError") - << "Assigning time correction impossible. Setting it to 0 "; - theCorrection = 0.; +double EcalUncalibRecHitWorkerMultiFit::timeCorrectionEK(float ampliEK){ + // computed initially in ns. Than turned in the BX's, as EcalUncalibratedRecHit need be. + double theCorrection=0; + + int myBin = -1; + for (int bin=0; bin<(int)EKtimeCorrAmplitudeBins_.size(); bin++ ){ + if(ampliEK > EKtimeCorrAmplitudeBins_.at(bin)) { + myBin = bin; } + else break; } - + + if (myBin == -1) + { + theCorrection = EKtimeCorrShiftBins_.at(0); + } + else if ( myBin == ((int)(EKtimeCorrAmplitudeBins_.size()-1)) ) + { + theCorrection = EKtimeCorrShiftBins_.at( myBin ); + } + else if ( -1 < myBin && myBin < ((int)EKtimeCorrAmplitudeBins_.size()-1) ) + { + // interpolate linearly between two assingned points + theCorrection = ( EKtimeCorrShiftBins_.at(myBin+1) - EKtimeCorrShiftBins_.at(myBin) ); + theCorrection *= ( ((double)ampliEK) - EKtimeCorrAmplitudeBins_.at(myBin) ) / ( EKtimeCorrAmplitudeBins_.at(myBin+1) - EKtimeCorrAmplitudeBins_.at(myBin) ); + theCorrection += EKtimeCorrShiftBins_.at(myBin); + } + else + { + edm::LogError("EcalRecHitError") << "Assigning time correction impossible. Setting it to 0 "; + theCorrection = 0.; + } + // convert ns into clocks - return theCorrection / 25.; + return theCorrection/25.; } @@ -207,15 +285,20 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, const EcalXtalGroupId * gid = 0; if (detid.subdetId()==EcalEndcap) { - unsigned int hashedIndex = EEDetId(detid).hashedIndex(); - aped = &peds->endcap(hashedIndex); - aGain = &gains->endcap(hashedIndex); - gid = &grps->endcap(hashedIndex); + unsigned int hashedIndex = EEDetId(detid).hashedIndex(); + aped = &peds->endcap(hashedIndex); + aGain = &gains->endcap(hashedIndex); + gid = &grps->endcap(hashedIndex); + } else if (detid.subdetId()==EcalShashlik){ + unsigned int hashedIndex = 10; + aped = &peds->shashlik(hashedIndex); + aGain = &gains->shashlik(hashedIndex); + gid = &grps->shashlik(hashedIndex); } else { - unsigned int hashedIndex = EBDetId(detid).hashedIndex(); - aped = &peds->barrel(hashedIndex); - aGain = &gains->barrel(hashedIndex); - gid = &grps->barrel(hashedIndex); + unsigned int hashedIndex = EBDetId(detid).hashedIndex(); + aped = &peds->barrel(hashedIndex); + aGain = &gains->barrel(hashedIndex); + gid = &grps->barrel(hashedIndex); } pedVec[0] = aped->mean_x12; @@ -230,7 +313,14 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, // === amplitude computation === + //int leadingSample = -1; + // if (detid.subdetId()==EcalEndcap) { int leadingSample = ((EcalDataFrame)(*itdg)).lastUnsaturatedSample(); + //} else if(detid.subdetId()==EcalShashlik) { + // leadingSample = ((EcalDataFrame)(*itdg)).lastUnsaturatedSample(); + //} else { + //leadingSample = ((EcalDataFrame)(*itdg)).lastUnsaturatedSample(); + //} if ( leadingSample >= 0 ) { // saturation if ( leadingSample != 4 ) { @@ -239,10 +329,12 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, float sratio = 1; if ( detid.subdetId()==EcalBarrel) { sratio = ebPulseShape_[5] / ebPulseShape_[4]; + } else if( detid.subdetId()==EcalShashlik) { + sratio = ekPulseShape_[5] / ekPulseShape_[4]; } else { sratio = eePulseShape_[5] / eePulseShape_[4]; } - uncalibRecHit = EcalUncalibratedRecHit( (*itdg).id(), 4095*12*sratio, 0, 0, 0); + uncalibRecHit = EcalUncalibratedRecHit( (*itdg).id(), 4095*12*sratio, 0, 0, 0); //Shervin 4095 hardcoded!!!! uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kSaturated ); } else { // float clockToNsConstant = 25.; @@ -257,6 +349,16 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, uncalibRecHit = leadingEdgeMethod_endcap_.makeRecHit(*itdg, pedVec, gainRatios, 0, 0); uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kLeadingEdgeRecovered ); leadingEdgeMethod_endcap_.setLeadingEdgeSample( -1 ); + } else if (detid.subdetId()==EcalShashlik) { + leadingEdgeMethod_shashlik_.setPulseShape( ekPulseShape_ ); + // float mult = (float)eePulseShape_.size() / (float)(*itdg).size(); + // bin (or some analogous mapping) will be used instead of the leadingSample + //int bin = (int)(( (mult * leadingSample + mult/2) * clockToNsConstant + itimeconst ) / clockToNsConstant); + // bin is not uset for the moment + leadingEdgeMethod_shashlik_.setLeadingEdgeSample( leadingSample ); + uncalibRecHit = leadingEdgeMethod_shashlik_.makeRecHit(*itdg, pedVec, gainRatios, 0, 0); + uncalibRecHit.setFlagBit( EcalUncalibratedRecHit::kLeadingEdgeRecovered ); + leadingEdgeMethod_shashlik_.setLeadingEdgeSample( -1 ); } else { leadingEdgeMethod_barrel_.setPulseShape( ebPulseShape_ ); // float mult = (float)ebPulseShape_.size() / (float)(*itdg).size(); @@ -269,7 +371,7 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, leadingEdgeMethod_barrel_.setLeadingEdgeSample( -1 ); } } - // do not propagate the default chi2 = -1 value to the calib rechit (mapped to 64), set it to 0 when saturation + // do not propagate the default chi2 = -1 value to the calib rechit (mapped to 64), set it to 0 when saturation uncalibRecHit.setChi2(0); } else { // multifit @@ -292,27 +394,34 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, // ratio method float const clockToNsConstant = 25.; if (detid.subdetId()==EcalEndcap) { - ratioMethod_endcap_.init( *itdg, *sampleMask_, pedVec, pedRMSVec, gainRatios ); - ratioMethod_endcap_.computeTime( EEtimeFitParameters_, EEtimeFitLimits_, EEamplitudeFitParameters_ ); - ratioMethod_endcap_.computeAmplitude( EEamplitudeFitParameters_); - EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_endcap_.getCalculatedRecHit(); - double theTimeCorrectionEE = 0.; - - uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEE); - uncalibRecHit.setJitterError( std::sqrt(pow(crh.timeError,2) + std::pow(EEtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); - + ratioMethod_endcap_.init( *itdg, *sampleMask_, pedVec, pedRMSVec, gainRatios ); + ratioMethod_endcap_.computeTime( EEtimeFitParameters_, EEtimeFitLimits_, EEamplitudeFitParameters_ ); + ratioMethod_endcap_.computeAmplitude( EEamplitudeFitParameters_); + EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_endcap_.getCalculatedRecHit(); + double theTimeCorrectionEE=0; + if(doEEtimeCorrection_) theTimeCorrectionEE = timeCorrectionEE( uncalibRecHit.amplitude() ); + uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEE); + uncalibRecHit.setJitterError( std::sqrt(pow(crh.timeError,2) + std::pow(EEtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); + }else if (detid.subdetId()==EcalShashlik) { + ratioMethod_shashlik_.init( *itdg, *sampleMask_, pedVec, pedRMSVec, gainRatios ); + ratioMethod_shashlik_.computeTime( EKtimeFitParameters_, EKtimeFitLimits_, EKamplitudeFitParameters_ ); + ratioMethod_shashlik_.computeAmplitude( EKamplitudeFitParameters_); + EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_shashlik_.getCalculatedRecHit(); + double theTimeCorrectionEK=0; + if(doEKtimeCorrection_) theTimeCorrectionEK = timeCorrectionEK( uncalibRecHit.amplitude() ); + uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEK); + uncalibRecHit.setJitterError( std::sqrt(pow(crh.timeError,2) + std::pow(EKtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); } else { - ratioMethod_barrel_.init( *itdg, *sampleMask_, pedVec, pedRMSVec, gainRatios ); - ratioMethod_barrel_.fixMGPAslew(*itdg); - ratioMethod_barrel_.computeTime( EBtimeFitParameters_, EBtimeFitLimits_, EBamplitudeFitParameters_ ); - ratioMethod_barrel_.computeAmplitude( EBamplitudeFitParameters_); - EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_barrel_.getCalculatedRecHit(); - - double theTimeCorrectionEB = 0.; - - uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEB); - - uncalibRecHit.setJitterError( std::sqrt(std::pow(crh.timeError,2) + std::pow(EBtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); + ratioMethod_barrel_.init( *itdg, *sampleMask_, pedVec, pedRMSVec, gainRatios ); + ratioMethod_barrel_.fixMGPAslew(*itdg); + ratioMethod_barrel_.computeTime( EBtimeFitParameters_, EBtimeFitLimits_, EBamplitudeFitParameters_ ); + ratioMethod_barrel_.computeAmplitude( EBamplitudeFitParameters_); + EcalUncalibRecHitRatioMethodAlgo::CalculatedRecHit crh = ratioMethod_barrel_.getCalculatedRecHit(); + double theTimeCorrectionEB=0; + if(doEBtimeCorrection_) theTimeCorrectionEB = timeCorrectionEB( uncalibRecHit.amplitude() ); + + uncalibRecHit.setJitter( crh.timeMax - 5 + theTimeCorrectionEB); + uncalibRecHit.setJitterError( std::sqrt(std::pow(crh.timeError,2) + std::pow(EBtimeConstantTerm_,2)/std::pow(clockToNsConstant,2)) ); } } else if(timealgo_.compare("WeightsMethod")==0) { // weights method on the PU subtracted pulse shape @@ -341,6 +450,8 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, double timerh; if (detid.subdetId()==EcalEndcap) { timerh = weightsMethod_endcap_.time( *itdg, amplitudes, aped, aGain, fullpulse, weights); + } else if (detid.subdetId()==EcalShashlik) { + timerh = weightsMethod_shashlik_.time( *itdg, amplitudes, aped, aGain, fullpulse, weights); } else { timerh = weightsMethod_barrel_.time( *itdg, amplitudes, aped, aGain, fullpulse, weights); } @@ -433,10 +544,13 @@ void EcalUncalibRecHitWorkerMultiFit::fillInputs(const edm::ParameterSet& params const std::vector ebCorMatG12 = params.getParameter< std::vector >("EBCorrNoiseMatrixG12"); const std::vector eeCorMatG12 = params.getParameter< std::vector >("EECorrNoiseMatrixG12"); + const std::vector ekCorMatG12 = params.getParameter< std::vector >("EKCorrNoiseMatrixG12"); const std::vector ebCorMatG06 = params.getParameter< std::vector >("EBCorrNoiseMatrixG06"); const std::vector eeCorMatG06 = params.getParameter< std::vector >("EECorrNoiseMatrixG06"); + const std::vector ekCorMatG06 = params.getParameter< std::vector >("EKCorrNoiseMatrixG06"); const std::vector ebCorMatG01 = params.getParameter< std::vector >("EBCorrNoiseMatrixG01"); const std::vector eeCorMatG01 = params.getParameter< std::vector >("EECorrNoiseMatrixG01"); + const std::vector ekCorMatG01 = params.getParameter< std::vector >("EKCorrNoiseMatrixG01"); int nnoise = ebCorMatG12.size(); @@ -446,29 +560,36 @@ void EcalUncalibRecHitWorkerMultiFit::fillInputs(const edm::ParameterSet& params int vidx = std::abs(j-i); noisecorEBg12(i,j) = ebCorMatG12[vidx]; noisecorEEg12(i,j) = eeCorMatG12[vidx]; + noisecorEKg12(i,j) = ekCorMatG12[vidx]; noisecorEBg6(i,j) = ebCorMatG06[vidx]; noisecorEEg6(i,j) = eeCorMatG06[vidx]; + noisecorEKg6(i,j) = ekCorMatG06[vidx]; noisecorEBg1(i,j) = ebCorMatG01[vidx]; noisecorEEg1(i,j) = eeCorMatG01[vidx]; + noisecorEKg1(i,j) = ekCorMatG01[vidx]; } } // fill shape: from simulation for samples 3-9, from alpha/beta shape for 10-14 const std::vector ebPulse = params.getParameter< std::vector >("EBPulseShapeTemplate"); const std::vector eePulse = params.getParameter< std::vector >("EEPulseShapeTemplate"); + const std::vector ekPulse = params.getParameter< std::vector >("EKPulseShapeTemplate"); int nShapeSamples = ebPulse.size(); for (int i=0; i ebPulseCov = params.getParameter< std::vector >("EBPulseShapeCovariance"); const std::vector eePulseCov = params.getParameter< std::vector >("EEPulseShapeCovariance"); + const std::vector ekPulseCov = params.getParameter< std::vector >("EKPulseShapeCovariance"); for(int k=0; k peds; edm::ESHandle gains; - double timeCorrection(float ampli, - const std::vector& amplitudeBins, const std::vector& shiftBins); + double timeCorrectionEB(float ampliEB); + double timeCorrectionEE(float ampliEE); + double timeCorrectionEK(float ampliEE); const SampleMatrix &noisecor(bool barrel, int gain) const; // multifit method SampleMatrix noisecorEBg12; SampleMatrix noisecorEEg12; + SampleMatrix noisecorEKg12; SampleMatrix noisecorEBg6; SampleMatrix noisecorEEg6; + SampleMatrix noisecorEKg6; SampleMatrix noisecorEBg1; SampleMatrix noisecorEEg1; + SampleMatrix noisecorEKg1; FullSampleVector fullpulseEB; FullSampleVector fullpulseEE; + FullSampleVector fullpulseEK; FullSampleMatrix fullpulsecovEB; FullSampleMatrix fullpulsecovEE; + FullSampleMatrix fullpulsecovEK; BXVector activeBX; bool ampErrorCalculation_; EcalUncalibRecHitMultiFitAlgo multiFitMethod_; @@ -87,35 +93,53 @@ class EcalUncalibRecHitWorkerMultiFit : public EcalUncalibRecHitWorkerBaseClass const EcalWeightSet::EcalWeightMatrix* weights[2]; EcalUncalibRecHitTimeWeightsAlgo weightsMethod_barrel_; EcalUncalibRecHitTimeWeightsAlgo weightsMethod_endcap_; + EcalUncalibRecHitTimeWeightsAlgo weightsMethod_shashlik_; // ratio method std::vector EBtimeFitParameters_; std::vector EEtimeFitParameters_; + std::vector EKtimeFitParameters_; std::vector EBamplitudeFitParameters_; std::vector EEamplitudeFitParameters_; + std::vector EKamplitudeFitParameters_; std::pair EBtimeFitLimits_; std::pair EEtimeFitLimits_; - + std::pair EKtimeFitLimits_; + bool doEBtimeCorrection_; + bool doEEtimeCorrection_; + bool doEKtimeCorrection_; + std::vector EBtimeCorrAmplitudeBins_; + std::vector EBtimeCorrShiftBins_; + std::vector EEtimeCorrAmplitudeBins_; + std::vector EEtimeCorrShiftBins_; + std::vector EKtimeCorrAmplitudeBins_; + std::vector EKtimeCorrShiftBins_; EcalUncalibRecHitRatioMethodAlgo ratioMethod_barrel_; EcalUncalibRecHitRatioMethodAlgo ratioMethod_endcap_; + EcalUncalibRecHitRatioMethodAlgo ratioMethod_shashlik_; double EBtimeConstantTerm_; double EEtimeConstantTerm_; + double EKtimeConstantTerm_; // leading edge method edm::ESHandle itime; - edm::ESHandle offtime; + edm::ESHandle offtime; std::vector ebPulseShape_; std::vector eePulseShape_; + std::vector ekPulseShape_; EcalUncalibRecHitLeadingEdgeAlgo leadingEdgeMethod_barrel_; EcalUncalibRecHitLeadingEdgeAlgo leadingEdgeMethod_endcap_; + EcalUncalibRecHitLeadingEdgeAlgo leadingEdgeMethod_shashlik_; // chi2 thresholds for flags settings bool kPoorRecoFlagEB_; bool kPoorRecoFlagEE_; + bool kPoorRecoFlagEK_; double chi2ThreshEB_; double chi2ThreshEE_; + double chi2ThreshEK_; private: diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py b/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py index 3ba32ad9c59f4..3eb7d97b4c76b 100644 --- a/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py +++ b/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py @@ -5,8 +5,10 @@ ecalMultiFitUncalibRecHit = cms.EDProducer("EcalUncalibRecHitProducer", EBdigiCollection = cms.InputTag("ecalDigis","ebDigis"), EEdigiCollection = cms.InputTag("ecalDigis","eeDigis"), + EKdigiCollection = cms.InputTag("ecalDigis","ekDigis"), EBhitCollection = cms.string("EcalUncalibRecHitsEB"), EEhitCollection = cms.string('EcalUncalibRecHitsEE'), + EKhitCollection = cms.string('EcalUncalibRecHitsEK'), # for multifit method EcalPulseShapeParameters = cms.PSet( ecal_pulse_shape_parameters ), @@ -19,24 +21,77 @@ # for ratio method EBtimeFitParameters = cms.vdouble(-2.015452e+00, 3.130702e+00, -1.234730e+01, 4.188921e+01, -8.283944e+01, 9.101147e+01, -5.035761e+01, 1.105621e+01), EEtimeFitParameters = cms.vdouble(-2.390548e+00, 3.553628e+00, -1.762341e+01, 6.767538e+01, -1.332130e+02, 1.407432e+02, -7.541106e+01, 1.620277e+01), + EKtimeFitParameters = cms.vdouble(-2.390548e+00, 3.553628e+00, -1.762341e+01, 6.767538e+01, -1.332130e+02, 1.407432e+02, -7.541106e+01, 1.620277e+01), EBamplitudeFitParameters = cms.vdouble(1.138,1.652), EEamplitudeFitParameters = cms.vdouble(1.890,1.400), + EKamplitudeFitParameters = cms.vdouble(1.890,1.400), EBtimeFitLimits_Lower = cms.double(0.2), EBtimeFitLimits_Upper = cms.double(1.4), EEtimeFitLimits_Lower = cms.double(0.2), EEtimeFitLimits_Upper = cms.double(1.4), + EKtimeFitLimits_Lower = cms.double(0.2), + EKtimeFitLimits_Upper = cms.double(1.4), # for time error EBtimeConstantTerm= cms.double(.6), EEtimeConstantTerm= cms.double(1.0), + EKtimeConstantTerm= cms.double(1.0), + + #amplitude-dependent time corrections; EE and EB have separate corrections + #EXtimeCorrAmplitudes (ADC) and EXtimeCorrShifts (ns) need to have the same number of elements + #Bins must be ordered in amplitude. First-last bins take care of under-overflows. + doEBtimeCorrection = cms.bool(False), + doEEtimeCorrection = cms.bool(False), + doEKtimeCorrection = cms.bool(False), + + EBtimeCorrAmplitudeBins = cms.vdouble( + 7.9, 8.9, 10, 11.2, 12.5, 14.1, 15.8, 17.7, 19.9, 22.3, 25, 28.1, 31.5, 35.3, 39.7, + 44.5, 49.9, 56, 62.8, 70.5, 79.1, 88.8, 99.6, 111.7, 125.4, 140.7, 157.9, 177.1, 198.7, 223, + 250.2, 280.7, 315, 353.4, 396.5, 444.9, 499.2, 560.1, 628.4, 705.1, 791.1, 887.7, 996, 1117.5, 1253.9, + 1406.8, 1578.5, 1771.1, 1987.2, 2229.7, 2501.8, 2807, 3149.5, 3533.8, 3895.9, 3896, 4311.8, 4837.9, 5428.2, 6090.6, + 6833.7, 7667.5, 8603.1, 9652.9, 10830, 12152, 13635, 15298, 17165, 19260, 21610), + + EBtimeCorrShiftBins = cms.vdouble( + -1.770, -1.770, -1.770, -1.770, -1.666, -1.430, -1.233, -1.012, -0.866, -0.736, -0.640, -0.561, -0.505, -0.452, -0.405, + -0.363, -0.335, -0.305, -0.279, -0.260, -0.239, -0.220, -0.204, -0.191, -0.186, -0.177, -0.158, -0.137, -0.126, -0.115, + -0.104, -0.096, -0.085, -0.064, -0.056, -0.036, -0.020, -0.006, -0.020, -0.009, -0.020, 0.005, 0.053, 0.076, 0.093, + 0.137, 0.143, 0.171, 0.222, 0.229, 0.271, 0.298, 0.312, 0.307, 0.254 , -0.997 ,-0.859 , -0.819, -0.775, -0.589, + -0.428, -0.288, -0.434, -0.277, -0.210, -0.179, -0.134, 0.362, 0.152, -0.282, -0.382), + + EEtimeCorrAmplitudeBins = cms.vdouble( + 15.7, 17.6, 19.7, 22.1, 24.8, 27.9, 31.3, 35.1, 39.4, 44.2, 49.6, 55.6, 62.4, 70, 78.6, + 88.1, 98.9, 111, 124.5, 139.7, 156.7, 175.9, 197.3, 221.4, 248.4, 278.7, 312.7, 350.9, 393.7, 441.7, + 495.6, 556.1, 624, 700.1, 785.5, 881.4, 988.9, 1109.6, 1245, 1396.9, 1567.3, 1758.6, 1973.1, 2213.9, 2484, + 2787.1, 3127.2, 3508.8, 3936.9, 4417.3, 4956.3, 5561.1, 6239.6, 7001, 7522.8, 8440.7, 9470.6, 10626), + + EEtimeCorrShiftBins = cms.vdouble( + -0.896, -0.896, -0.896, -0.896, -0.563, -0.392, -0.287, -0.203, -0.135, -0.100, -0.068, -0.050, -0.060, -0.052, -0.055, + -0.050, -0.052, -0.056, -0.055, -0.056, -0.048, -0.037, -0.038, -0.037, -0.025, -0.026, -0.024, -0.013, -0.003, 0.005, + 0.020, 0.026, 0.008, 0.007, -0.006, 0.024, 0.045, 0.062, 0.085, 0.088 , 0.111 , 0.139, 0.156, 0.176, 0.210, + 0.242, 0.267, 0.301, 0.318, 0.278, 0.287, 0.218, 0.305, 0.245, 0.184, -0.159, -0.095, 0.037), + + EKtimeCorrAmplitudeBins = cms.vdouble( + 15.7, 17.6, 19.7, 22.1, 24.8, 27.9, 31.3, 35.1, 39.4, 44.2, 49.6, 55.6, 62.4, 70, 78.6, + 88.1, 98.9, 111, 124.5, 139.7, 156.7, 175.9, 197.3, 221.4, 248.4, 278.7, 312.7, 350.9, 393.7, 441.7, + 495.6, 556.1, 624, 700.1, 785.5, 881.4, 988.9, 1109.6, 1245, 1396.9, 1567.3, 1758.6, 1973.1, 2213.9, 2484, + 2787.1, 3127.2, 3508.8, 3936.9, 4417.3, 4956.3, 5561.1, 6239.6, 7001, 7522.8, 8440.7, 9470.6, 10626), + + EKtimeCorrShiftBins = cms.vdouble( + -0.896, -0.896, -0.896, -0.896, -0.563, -0.392, -0.287, -0.203, -0.135, -0.100, -0.068, -0.050, -0.060, -0.052, -0.055, + -0.050, -0.052, -0.056, -0.055, -0.056, -0.048, -0.037, -0.038, -0.037, -0.025, -0.026, -0.024, -0.013, -0.003, 0.005, + 0.020, 0.026, 0.008, 0.007, -0.006, 0.024, 0.045, 0.062, 0.085, 0.088 , 0.111 , 0.139, 0.156, 0.176, 0.210, + 0.242, 0.267, 0.301, 0.318, 0.278, 0.287, 0.218, 0.305, 0.245, 0.184, -0.159, -0.095, 0.037), ebPulseShape = cms.vdouble( 5.2e-05,-5.26e-05 , 6.66e-05, 0.1168, 0.7575, 1., 0.8876, 0.6732, 0.4741, 0.3194 ), eePulseShape = cms.vdouble( 5.2e-05,-5.26e-05 , 6.66e-05, 0.1168, 0.7575, 1., 0.8876, 0.6732, 0.4741, 0.3194 ), + ekPulseShape = cms.vdouble( 5.2e-05,-5.26e-05 , 6.66e-05, 0.1168, 0.7575, 1., 0.8876, 0.6732, 0.4741, 0.3194 ), # for kPoorReco flag kPoorRecoFlagEB = cms.bool(True), kPoorRecoFlagEE = cms.bool(False), + kPoorRecoFlagEK = cms.bool(False), chi2ThreshEB_ = cms.double(65.0), chi2ThreshEE_ = cms.double(50.0), + chi2ThreshEK_ = cms.double(50.0), algo = cms.string("EcalUncalibRecHitWorkerMultiFit") ) diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py index 9b02d1bf29f8d..7e887972fe5fc 100644 --- a/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py +++ b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py @@ -7,6 +7,10 @@ EEPulseShapeTemplate = cms.vdouble ( 1.16442e-01, 7.56246e-01, 1.00000e+00, 8.97182e-01, 6.86831e-01, 4.91506e-01, 3.44111e-01, 2.45731e-01, 1.74115e-01, 1.23361e-01, 8.74288e-02, 6.19570e-02 + ), + + EKPulseShapeTemplate = cms.vdouble ( + 1.16442e-01, 7.56246e-01, 1.00000e+00, 8.97182e-01, 6.86831e-01, 4.91506e-01, 3.44111e-01, 2.45731e-01, 1.74115e-01, 1.23361e-01, 8.74288e-02, 6.19570e-02 ) ) @@ -39,7 +43,22 @@ -3.411e-06, -2.902e-06, 0.000e+00, 1.330e-06, 1.567e-06, 1.431e-06, 1.289e-06, 8.882e-07, 8.669e-07, 9.522e-07, 6.717e-07, 4.293e-07, 0.000e+00, -2.128e-06, 0.000e+00, 9.186e-07, 1.084e-06, 9.839e-07, 9.020e-07, 6.108e-07, 5.751e-07, 6.717e-07, 7.911e-07, 5.493e-07, 0.000e+00, 0.000e+00, 0.000e+00, 6.446e-07, 7.575e-07, 6.886e-07, 6.146e-07, 4.283e-07, 3.882e-07, 4.293e-07, 5.493e-07, 7.027e-07, - ) + ), + + EKPulseShapeCovariance = cms.vdouble ( + 3.941e-05, 3.333e-05, 0.000e+00, -1.449e-05, -1.661e-05, -1.424e-05, -1.183e-05, -6.842e-06, -4.915e-06, -3.411e-06, 0.000e+00, 0.000e+00, + 3.333e-05, 2.862e-05, 0.000e+00, -1.244e-05, -1.431e-05, -1.233e-05, -1.032e-05, -5.883e-06, -4.154e-06, -2.902e-06, -2.128e-06, 0.000e+00, + 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, 0.000e+00, + -1.449e-05, -1.244e-05, 0.000e+00, 5.840e-06, 6.649e-06, 5.720e-06, 4.812e-06, 2.708e-06, 1.869e-06, 1.330e-06, 9.186e-07, 6.446e-07, + -1.661e-05, -1.431e-05, 0.000e+00, 6.649e-06, 7.966e-06, 6.898e-06, 5.794e-06, 3.157e-06, 2.184e-06, 1.567e-06, 1.084e-06, 7.575e-07, + -1.424e-05, -1.233e-05, 0.000e+00, 5.720e-06, 6.898e-06, 6.341e-06, 5.347e-06, 2.859e-06, 1.991e-06, 1.431e-06, 9.839e-07, 6.886e-07, + -1.183e-05, -1.032e-05, 0.000e+00, 4.812e-06, 5.794e-06, 5.347e-06, 4.854e-06, 2.628e-06, 1.809e-06, 1.289e-06, 9.020e-07, 6.146e-07, + -6.842e-06, -5.883e-06, 0.000e+00, 2.708e-06, 3.157e-06, 2.859e-06, 2.628e-06, 1.863e-06, 1.296e-06, 8.882e-07, 6.108e-07, 4.283e-07, + -4.915e-06, -4.154e-06, 0.000e+00, 1.869e-06, 2.184e-06, 1.991e-06, 1.809e-06, 1.296e-06, 1.217e-06, 8.669e-07, 5.751e-07, 3.882e-07, + -3.411e-06, -2.902e-06, 0.000e+00, 1.330e-06, 1.567e-06, 1.431e-06, 1.289e-06, 8.882e-07, 8.669e-07, 9.522e-07, 6.717e-07, 4.293e-07, + 0.000e+00, -2.128e-06, 0.000e+00, 9.186e-07, 1.084e-06, 9.839e-07, 9.020e-07, 6.108e-07, 5.751e-07, 6.717e-07, 7.911e-07, 5.493e-07, + 0.000e+00, 0.000e+00, 0.000e+00, 6.446e-07, 7.575e-07, 6.886e-07, 6.146e-07, 4.283e-07, 3.882e-07, 4.293e-07, 5.493e-07, 7.027e-07, + ) ) from SimCalorimetry.EcalSimProducers.ecalDigiParameters_cff import * diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py b/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py index fc0ff47f6c1fb..bb50c25c6e9d3 100644 --- a/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py +++ b/RecoLocalCalo/EcalRecProducers/python/ecalRecHit_cfi.py @@ -9,7 +9,7 @@ EBuncalibRecHitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEB"), EBrechitCollection = cms.string('EcalRecHitsEB'), EKrechitCollection = cms.string('EcalRecHitsEK'), - EKuncalibRecHitCollection = cms.InputTag("ecalGlobalUncalibRecHit","EcalUncalibRecHitsEK"), + EKuncalibRecHitCollection = cms.InputTag("ecalMultiFitUncalibRecHit","EcalUncalibRecHitsEK"), # channel flags to be exluded from reconstruction, e.g { 1, 2 } ChannelStatusToBeExcluded = cms.vint32(), From 386bacb6c2b1fe734bfb64ee4975940ee54c57b1 Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Tue, 14 Oct 2014 10:38:15 +0200 Subject: [PATCH 194/252] HGCalHEB V5 geometry fix --- Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml | 2 +- Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml b/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml index 84d407bd43586..5934aae54fc3f 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml @@ -53,7 +53,7 @@ 34.5*mm, 9.0*mm, 9.0*mm - 4175.0*mm, 4209.5*mm, 4209.5*mm + 4174.85*mm, 4209.35*mm, 4209.35*mm 1, 1, 1 diff --git a/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc b/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc index 6a9bb1293959d..946897c4c6443 100644 --- a/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc +++ b/Geometry/HGCalCommonData/plugins/DDHGCalHEAlgo.cc @@ -159,7 +159,7 @@ DDHGCalHEAlgo::parameterLayer(double rinF, double routF, double rinB, //Given rin, rout compute parameters of the trapezoid and //position of the trapezoid for a standrd layer double alpha = CLHEP::pi/sectors; - double rout = ((routF > routB) ? routB : routF); + double rout = routF; edm::LogInfo("HGCalGeom") << "Input: Front " << rinF << " " << routF << " " << zi << " Back " << rinB << " " << routB << " " << zo << " Alpha " << alpha/CLHEP::deg << " Rout " @@ -189,7 +189,7 @@ DDHGCalHEAlgo::parameterLayer(int type, double rinF, double routF, double rinB, //Given rin, rout compute parameters of the trapezoid and //position of the trapezoid for a standrd layer double alpha = CLHEP::pi/sectors; - double rout = ((routF > routB) ? routB : routF); + double rout = routF; edm::LogInfo("HGCalGeom") << "Input " << type << " Front " << rinF << " " << routF << " " << zi << " Back " << rinB << " " << routB << " " << zo <<" Alpha " From daa69313f7f6ad1d8edf411a2ad0dd4a9deb4837 Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Tue, 14 Oct 2014 14:11:11 +0200 Subject: [PATCH 195/252] Put back the line for the non-dev phase1TkCustoms import --- SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py | 1 + 1 file changed, 1 insertion(+) diff --git a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py index a5a76c9b02615..4b4d295c6b514 100644 --- a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py @@ -15,6 +15,7 @@ from SLHCUpgradeSimulations.Configuration.combinedCustoms_TTI import l1EventContent_TTI_forHLT from SLHCUpgradeSimulations.Configuration.customise_mixing import customise_NoCrossing +from SLHCUpgradeSimulations.Configuration.phase1TkCustoms import customise as customisePhase1Tk from SLHCUpgradeSimulations.Configuration.phase1TkCustomsdev import customise as customisePhase1Tkdev from SLHCUpgradeSimulations.Configuration.HCalCustoms import customise_HcalPhase1, customise_HcalPhase0, customise_HcalPhase2 from SLHCUpgradeSimulations.Configuration.gemCustoms import customise2019 as customise_gem2019 From 5ab01606417432ab5fd4868e1457680efda2cf15 Mon Sep 17 00:00:00 2001 From: Josh Bendavid Date: Wed, 15 Oct 2014 01:16:17 +0200 Subject: [PATCH 196/252] add option to override pedestal rms from db by providing directly the noise covariance instead of correlation. Provide vaguely sensible numbers for Shashlik. --- .../interface/EcalUncalibRecHitMultiFitAlgo.h | 2 +- .../src/EcalUncalibRecHitMultiFitAlgo.cc | 7 ++- .../EcalUncalibRecHitWorkerMultiFit.cc | 12 ++++- .../plugins/EcalUncalibRecHitWorkerMultiFit.h | 5 +- .../python/ecalMultiFitUncalibRecHit_cfi.py | 5 ++ .../python/ecalPulseShapeParameters_cff.py | 46 ++++++++++++++++++- 6 files changed, 70 insertions(+), 7 deletions(-) diff --git a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h index ad9c4f687b1cf..377334dc139d5 100644 --- a/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h +++ b/RecoLocalCalo/EcalRecAlgos/interface/EcalUncalibRecHitMultiFitAlgo.h @@ -25,7 +25,7 @@ class EcalUncalibRecHitMultiFitAlgo EcalUncalibRecHitMultiFitAlgo(); ~EcalUncalibRecHitMultiFitAlgo() { }; - EcalUncalibratedRecHit makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const SampleMatrix &noisecor, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov, const BXVector &activeBX); + EcalUncalibratedRecHit makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const SampleMatrix &noisecor, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov, const BXVector &activeBX, bool noiseMatrixAsCovariance); void disableErrorCalculation() { _computeErrors = false; } private: diff --git a/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc b/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc index 050317c411e06..a718f6f0dde96 100644 --- a/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc +++ b/RecoLocalCalo/EcalRecAlgos/src/EcalUncalibRecHitMultiFitAlgo.cc @@ -10,7 +10,7 @@ EcalUncalibRecHitMultiFitAlgo::EcalUncalibRecHitMultiFitAlgo() : } /// compute rechits -EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const SampleMatrix &noisecor, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov, const BXVector &activeBX) { +EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataFrame& dataFrame, const EcalPedestals::Item * aped, const EcalMGPAGainRatio * aGain, const SampleMatrix &noisecor, const FullSampleVector &fullpulse, const FullSampleMatrix &fullpulsecov, const BXVector &activeBX, bool noiseMatrixAsCovariance) { uint32_t flags = 0; @@ -48,6 +48,11 @@ EcalUncalibratedRecHit EcalUncalibRecHitMultiFitAlgo::makeRecHit(const EcalDataF pederr = aped->rms_x6; gainratio = aGain->gain12Over6(); } + + //treat provided noise matrix directly as covariance (set multiplicative rms to 1.0 adc count) + if (noiseMatrixAsCovariance) { + pederr = 1.0; + } amplitude = ((double)(sample.adc()) - pedestal) * gainratio; diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc index d88dc822b9b1d..1d46dde4e0fa6 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.cc @@ -32,6 +32,10 @@ EcalUncalibRecHitWorkerMultiFit::EcalUncalibRecHitWorkerMultiFit(const edm::Para for (unsigned int ibx=0; ibx("noiseMatrixAsCovarianceEB"); + noiseMatrixAsCovarianceEE_ = ps.getParameter("noiseMatrixAsCovarianceEE"); + noiseMatrixAsCovarianceEK_ = ps.getParameter("noiseMatrixAsCovarianceEK"); // uncertainty calculation (CPU intensive) ampErrorCalculation_ = ps.getParameter("ampErrorCalculation"); @@ -283,22 +287,26 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, const EcalPedestals::Item * aped = 0; const EcalMGPAGainRatio * aGain = 0; const EcalXtalGroupId * gid = 0; - + bool noiseMatrixAsCovariance = false; + if (detid.subdetId()==EcalEndcap) { unsigned int hashedIndex = EEDetId(detid).hashedIndex(); aped = &peds->endcap(hashedIndex); aGain = &gains->endcap(hashedIndex); gid = &grps->endcap(hashedIndex); + noiseMatrixAsCovariance = noiseMatrixAsCovarianceEE_; } else if (detid.subdetId()==EcalShashlik){ unsigned int hashedIndex = 10; aped = &peds->shashlik(hashedIndex); aGain = &gains->shashlik(hashedIndex); gid = &grps->shashlik(hashedIndex); + noiseMatrixAsCovariance = noiseMatrixAsCovarianceEK_; } else { unsigned int hashedIndex = EBDetId(detid).hashedIndex(); aped = &peds->barrel(hashedIndex); aGain = &gains->barrel(hashedIndex); gid = &grps->barrel(hashedIndex); + noiseMatrixAsCovariance = noiseMatrixAsCovarianceEB_; } pedVec[0] = aped->mean_x12; @@ -387,7 +395,7 @@ EcalUncalibRecHitWorkerMultiFit::run( const edm::Event & evt, const FullSampleVector &fullpulse = barrel ? fullpulseEB : fullpulseEE; const FullSampleMatrix &fullpulsecov = barrel ? fullpulsecovEB : fullpulsecovEE; - uncalibRecHit = multiFitMethod_.makeRecHit(*itdg, aped, aGain, noisecormat,fullpulse,fullpulsecov,activeBX); + uncalibRecHit = multiFitMethod_.makeRecHit(*itdg, aped, aGain, noisecormat,fullpulse,fullpulsecov,activeBX,noiseMatrixAsCovariance); // === time computation === if(timealgo_.compare("RatioMethod")==0) { diff --git a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h index 216854189bf33..725689bcac349 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h +++ b/RecoLocalCalo/EcalRecProducers/plugins/EcalUncalibRecHitWorkerMultiFit.h @@ -80,7 +80,10 @@ class EcalUncalibRecHitWorkerMultiFit : public EcalUncalibRecHitWorkerBaseClass bool ampErrorCalculation_; EcalUncalibRecHitMultiFitAlgo multiFitMethod_; - + bool noiseMatrixAsCovarianceEB_; + bool noiseMatrixAsCovarianceEE_; + bool noiseMatrixAsCovarianceEK_; + // determine which of the samples must actually be used by ECAL local reco edm::ESHandle sampleMaskHand_; diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py b/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py index 3eb7d97b4c76b..dcd0345fe0d44 100644 --- a/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py +++ b/RecoLocalCalo/EcalRecProducers/python/ecalMultiFitUncalibRecHit_cfi.py @@ -13,8 +13,13 @@ # for multifit method EcalPulseShapeParameters = cms.PSet( ecal_pulse_shape_parameters ), activeBXs = cms.vint32(-5,-4,-3,-2,-1,0,1,2,3,4), + noiseMatrixAsCovarianceEB = cms.bool(False), + noiseMatrixAsCovarianceEE = cms.bool(False), + noiseMatrixAsCovarianceEK = cms.bool(True), ampErrorCalculation = cms.bool(True), + + # decide which algorithm to be use to calculate the jitter timealgo = cms.string("RatioMethod"), diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py index 7e887972fe5fc..71ac0f2179943 100644 --- a/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py +++ b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py @@ -61,10 +61,52 @@ ) ) -from SimCalorimetry.EcalSimProducers.ecalDigiParameters_cff import * +ecal_noise_correlation = cms.PSet( + #these are correlation matrix elements + EBCorrNoiseMatrixG12 = cms.vdouble ( + 1.00000, 0.71073, 0.55721, 0.46089, 0.40449, + 0.35931, 0.33924, 0.32439, 0.31581, 0.30481 ) , + + EECorrNoiseMatrixG12 = cms.vdouble ( + 1.00000, 0.71373, 0.44825, 0.30152, 0.21609, + 0.14786, 0.11772, 0.10165, 0.09465, 0.08098 ) , + + EBCorrNoiseMatrixG06 = cms.vdouble ( + 1.00000, 0.70946, 0.58021, 0.49846, 0.45006, + 0.41366, 0.39699, 0.38478, 0.37847, 0.37055 ) , + + EECorrNoiseMatrixG06 = cms.vdouble ( + 1.00000, 0.71217, 0.47464, 0.34056, 0.26282, + 0.20287, 0.17734, 0.16256, 0.15618, 0.14443 ), + + EBCorrNoiseMatrixG01 = cms.vdouble ( + 1.00000, 0.73354, 0.64442, 0.58851, 0.55425, + 0.53082, 0.51916, 0.51097, 0.50732, 0.50409 ) , + + EECorrNoiseMatrixG01 = cms.vdouble ( + 1.00000, 0.72698, 0.62048, 0.55691, 0.51848, + 0.49147, 0.47813, 0.47007, 0.46621, 0.46265 ), + + #these are covariance matrix elements + #covariance = 0.03^2*cor_digi + (1/12) + #treating quantization as fully correlated noise term + #on top of 0.03 adc counts "magic number" for Shashlik + #Yes this is almost just a matrix filled with 1/12, + #but that could cause undesirable numerical problems + #downstream if taken too literally + EKCorrNoiseMatrixG12 = cms.vdouble ( + 0.084233, 0.083976, 0.083737, 0.083605, 0.083528, + 0.083466, 0.083439, 0.083425, 0.083419, 0.083406 ) , + EKCorrNoiseMatrixG06 = cms.vdouble ( + 0.084233, 0.083974, 0.083761, 0.083640, 0.083570, + 0.083516, 0.083493, 0.083480, 0.083474, 0.083463 ), + EKCorrNoiseMatrixG01 = cms.vdouble ( + 0.084233, 0.083988, 0.083892, 0.083835, 0.083800, + 0.083776, 0.083764, 0.083756, 0.083753, 0.083750 ) +) ecal_pulse_shape_parameters = cms.PSet( ecal_pulse_shape_templates, - ecal_digi_parameters, + ecal_noise_correlation, ecal_pulse_shape_covariances ) From 3ace3e894c2b702ee5f1b6321a19faa1990625f8 Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Wed, 15 Oct 2014 21:47:37 +0200 Subject: [PATCH 197/252] HGCAL V5 geometry modifications2 --- Geometry/HGCalCommonData/data/v5/hgcal.xml | 6 ++--- Geometry/HGCalCommonData/data/v5/hgcalEE.xml | 20 ++++++++-------- .../HGCalCommonData/data/v5/hgcalHEsci.xml | 2 +- .../HGCalCommonData/data/v5/hgcalHEsil.xml | 24 +++++++++---------- 4 files changed, 26 insertions(+), 26 deletions(-) diff --git a/Geometry/HGCalCommonData/data/v5/hgcal.xml b/Geometry/HGCalCommonData/data/v5/hgcal.xml index 298c854bf2b43..20e5ac4ed5f7b 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcal.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcal.xml @@ -2,16 +2,16 @@ - + - + - + diff --git a/Geometry/HGCalCommonData/data/v5/hgcalEE.xml b/Geometry/HGCalCommonData/data/v5/hgcalEE.xml index f027f6f4773c5..4aaf7815ea4bb 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalEE.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalEE.xml @@ -30,20 +30,20 @@
- + materials:Tungsten, materials:Tungsten, materials:Tungsten, materials:Lead, materials:Lead, materials:Lead, materials:Copper, materials:Copper, materials:Silicon, materials:M_NEMA FR4 plate, materials:Air, - materials:Foam, materials:Aluminium - + materials:Foam, materials:Aluminium, materials:Air + EEAbsorber1, EEAbsorber2, EEAbsorber3, EEAbsorber4, EEAbsorber5, EEAbsorber6, EECuFrame, EEHeatShield, EESensitive, EEPCB, - EEAirGap, EEThermalScreen, EEScreenCover - + EEAirGap, EEThermalScreen, EEScreenCover, EEThermalGap + 1.75*mm, 2.8*mm, 4.2*mm, 1.0*mm, 2.1*mm, 4.4*mm, - 0.5*mm, 3.0*mm, 0.1*mm, 1.2*mm, 2.0*mm, 26.0*mm, 2.0*mm + 0.5*mm, 3.0*mm, 0.1*mm, 1.2*mm, 2.0*mm, 16.0*mm, 2.0*mm, 10.0*mm - 12, 11, 12, + 12, 11, 12, 13, 6, 10, 9, 8, 8, 8, 7, 3, 0, 6, 10, 9, 8, 8, 8, 7, 3, 7, 8, 8, 8, 9, 10, 6, 0, 6, 10, 9, 8, 8, 8, 7, 3, 7, 8, 8, 8, 9, 10, 6, @@ -61,8 +61,8 @@ 2, 6, 10, 9, 8, 8, 8, 7, 5, 7, 8, 8, 8, 9, 10, 6, 2, 6, 10, 9, 8, 8, 8, 7, 3 - - 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, + + 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -79,7 +79,7 @@ 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1 - 30*mm, 30*mm, 30*mm, + 30*mm, 30*mm, 30*mm, 30*mm, 8.00*mm, 8.00*mm, 8.00*mm, 8.00*mm, 8.00*mm, 8.00*mm, 8.00*mm, 8.00*mm, 16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm, 16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm,16.75*mm, diff --git a/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml b/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml index 84d407bd43586..5934aae54fc3f 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml @@ -53,7 +53,7 @@ 34.5*mm, 9.0*mm, 9.0*mm - 4175.0*mm, 4209.5*mm, 4209.5*mm + 4174.85*mm, 4209.35*mm, 4209.35*mm 1, 1, 1 diff --git a/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml b/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml index ccc4596a122b9..2ce3e676e74af 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml @@ -38,32 +38,32 @@ - + materials:H_Brass, materials:Lead, materials:Copper, materials:Copper, materials:Silicon, materials:M_NEMA FR4 plate, materials:Air, - materials:StainlessSteel, materials:Foam, materials:Aluminium - + materials:StainlessSteel, materials:Foam, materials:Aluminium, materials:Air + HESiliconAbsorber1, HESiliconAbsorber2, HESiliconShield, HESiliconHeatShield, HESiliconSensitive, HESiliconPCB, HESiliconAirGap, HESiliconSupport, - HEThermalScreen, HEScreenCover - - 40.0*mm, 1.0*mm, 0.5*mm, 3.0*mm, 0.1*mm, 1.2*mm, 2.0*mm, 15*mm, 26.0*mm, 2.0*mm + HEThermalScreen, HEScreenCover, HEThermalGap + + 40.0*mm, 1.0*mm, 0.5*mm, 3.0*mm, 0.1*mm, 1.2*mm, 2.0*mm, 15*mm, 16.0*mm, 2.0*mm, 10.0*mm - 7, + 7, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, - 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 9, 8, 9 - 0, + 0, 2, 6, 5, 4, 4, 4, 3, 1, 0, 2, 6, 5, 4, 4, 4, 3, 1, 10, 9, 8, 9 + 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, - 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1 - + 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1 + 15.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, @@ -77,7 +77,7 @@ 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, 48.0*mm, - 30.0*mm, 30.0*mm, 30.0*mm + 30.0*mm, 30.0*mm, 30.0*mm, 30.0*mm From ac934a16985122cb4d986009ba34d3844628d92e Mon Sep 17 00:00:00 2001 From: Alja Mrak-Tadel Date: Wed, 15 Oct 2014 14:45:21 -0700 Subject: [PATCH 198/252] Workaround for problem with remoteX connections using Quartz 2.7.7. --- Fireworks/Core/src/CmsShowMain.cc | 12 ++++++------ Fireworks/FWInterface/src/FWFFHelper.cc | 21 +++++++++++++++++---- 2 files changed, 23 insertions(+), 10 deletions(-) diff --git a/Fireworks/Core/src/CmsShowMain.cc b/Fireworks/Core/src/CmsShowMain.cc index 4bce71a5b9a7d..1e5c3c42be2a7 100644 --- a/Fireworks/Core/src/CmsShowMain.cc +++ b/Fireworks/Core/src/CmsShowMain.cc @@ -8,7 +8,6 @@ // // Original Author: // Created: Mon Dec 3 08:38:38 PST 2007 -// $Id: CmsShowMain.cc,v 1.204 2012/11/16 02:20:14 amraktad Exp $ // // system include files @@ -65,6 +64,7 @@ #if defined(R__LINUX) #include "TGX11.h" // !!!! AMT has to be at the end to pass build +#include "X11/Xlib.h" #endif // // constants, enums and typedefs @@ -153,8 +153,8 @@ CmsShowMain::CmsShowMain(int argc, char *argv[]) (kConfigFileCommandOpt, po::value(), "Include configuration file") (kNoConfigFileCommandOpt, "Empty configuration") (kNoVersionCheck, "No file version check") - (kGeomFileCommandOpt, po::value(), "Include geometry file") - (kSimGeomFileCommandOpt,po::value(), "Set simulation geometry file to browser") + (kGeomFileCommandOpt, po::value(), "Reco geometry file. Default is cmsGeom10.root") + (kSimGeomFileCommandOpt,po::value(), "Geometry file for browsing in table view. Default is CmsSimGeom-14.root. Can be simulation or reco geometry in TGeo format") (kFieldCommandOpt, po::value(), "Set magnetic field value explicitly. Default is auto-field estimation") (kRootInteractiveCommandOpt, "Enable root interactive prompt") (kSoftCommandOpt, "Try to force software rendering to avoid problems with bad hardware drivers") @@ -262,11 +262,11 @@ CmsShowMain::CmsShowMain(int argc, char *argv[]) // geometry if (vm.count(kGeomFileOpt)) { setGeometryFilename(vm[kGeomFileOpt].as()); + fwLog(fwlog::kInfo) << "Geometry file " << geometryFilename() << "\n"; } else { // fwLog(fwlog::kInfo) << "No geom file name. Choosing default.\n"; setGeometryFilename("cmsGeom10.root"); } - fwLog(fwlog::kInfo) << "Geometry file " << geometryFilename() << "\n"; if (vm.count(kSimGeomFileOpt)) { setSimGeometryFilename(vm[kSimGeomFileOpt].as()); @@ -284,7 +284,7 @@ CmsShowMain::CmsShowMain(int argc, char *argv[]) // open any graphics or build dictionaries AutoLibraryLoader::enable(); - TEveManager::Create(kFALSE, "FIV"); + TEveManager::Create(kFALSE, eveMode ? "FIV" : "FI"); setup(m_navigator.get(), m_context.get(), m_metadataManager.get()); @@ -384,7 +384,7 @@ class DieTimer : public TTimer Start(0, kTRUE); } - virtual Bool_t Notify() + virtual Bool_t Notify() override { TurnOff(); fApp->doExit(); diff --git a/Fireworks/FWInterface/src/FWFFHelper.cc b/Fireworks/FWInterface/src/FWFFHelper.cc index d751b165fe3f7..05585b619ce40 100644 --- a/Fireworks/FWInterface/src/FWFFHelper.cc +++ b/Fireworks/FWInterface/src/FWFFHelper.cc @@ -2,9 +2,12 @@ #include "FWCore/ParameterSet/interface/ParameterSet.h" #include "FWCore/ServiceRegistry/interface/ActivityRegistry.h" +#define private public #include "TROOT.h" #include "TSystem.h" -#define private public +#include "TColor.h" +#include "TStyle.h" +#include "TEnv.h" #include "TRint.h" #include "TEveManager.h" #include "TEveEventManager.h" @@ -29,7 +32,7 @@ class FWFFTRint : public TRint fInputHandler->Remove(); } - Bool_t HandleTermInput() + Bool_t HandleTermInput() override { if (m_rootPrompt) return TRint::HandleTermInput(); @@ -61,7 +64,17 @@ FWFFHelper::FWFFHelper(const edm::ParameterSet &ps, const edm::ActivityRegistry std::cerr <<"Insufficient GL support. " << iException.what() << std::endl; throw; } - - TEveManager::Create(kFALSE, "FIV"); +// AMT workaround for an agressive clenup in 5.43.18 +#if ROOT_VERSION_CODE >= ROOT_VERSION(5,34,18) + if (!gStyle) { + TColor::fgInitDone=false; + TColor::InitializeColors(); + TStyle::BuildStyles(); + gROOT->SetStyle(gEnv->GetValue("Canvas.Style", "Modern")); + gStyle = gROOT->GetStyle("Classic"); + } +#endif + + TEveManager::Create(kFALSE, "FI"); } From 5ab7c934e65f3157b96c6718f14f279c9c3ffc1f Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Tue, 2 Sep 2014 10:17:02 +0200 Subject: [PATCH 199/252] fireworks adaptations to HGC Conflicts: Fireworks/Geometry/src/FWRecoGeometryESProducer.cc --- Fireworks/Geometry/interface/FWRecoGeometryESProducer.h | 1 + Fireworks/Geometry/interface/FWRecoGeometryRecord.h | 2 +- Fireworks/Geometry/src/FWRecoGeometryESProducer.cc | 9 ++++++++- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h b/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h index c9423611f6032..a2018ec42307b 100644 --- a/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h +++ b/Fireworks/Geometry/interface/FWRecoGeometryESProducer.h @@ -6,6 +6,7 @@ # include "FWCore/Framework/interface/ESProducer.h" # include "FWCore/Framework/interface/ESHandle.h" # include "DataFormats/GeometryVector/interface/GlobalPoint.h" +#include "Geometry/FCalGeometry/interface/HGCalGeometry.h" namespace edm { diff --git a/Fireworks/Geometry/interface/FWRecoGeometryRecord.h b/Fireworks/Geometry/interface/FWRecoGeometryRecord.h index 858c5c1d8ea8a..a630490814b8d 100644 --- a/Fireworks/Geometry/interface/FWRecoGeometryRecord.h +++ b/Fireworks/Geometry/interface/FWRecoGeometryRecord.h @@ -5,6 +5,6 @@ # include "Geometry/Records/interface/GlobalTrackingGeometryRecord.h" # include "Geometry/Records/interface/CaloGeometryRecord.h" -class FWRecoGeometryRecord : public edm::eventsetup::DependentRecordImplementation > {}; +class FWRecoGeometryRecord : public edm::eventsetup::DependentRecordImplementation > {}; #endif // GEOMETRY_FWRECO_GEOMETRY_RECORD_H diff --git a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc index 975bda5d7799e..73092845e3700 100644 --- a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc +++ b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc @@ -95,6 +95,13 @@ FWRecoGeometryESProducer::produce( const FWRecoGeometryRecord& record ) // m_hgcGeom.push_back(edm::ESHandle()); // record.getRecord().get( "HGCalHEScintillatorSensitive", m_hgcGeom.back() ); + m_hgcGeom.push_back(edm::ESHandle()); + record.getRecord().get( "HGCalEESensitive", m_hgcGeom.back() ); + m_hgcGeom.push_back(edm::ESHandle()); + record.getRecord().get( "HGCalHESiliconSensitive", m_hgcGeom.back() ); + m_hgcGeom.push_back(edm::ESHandle()); + record.getRecord().get( "HGCalHEScintillatorSensitive", m_hgcGeom.back() ); + addPixelBarrelGeometry( ); addPixelForwardGeometry(); addTIBGeometry(); @@ -462,7 +469,7 @@ FWRecoGeometryESProducer::addCaloGeometry( void ) fillPoints( id, cor.begin(), cor.end()); } - // do the HGCal if we actually got it + // do the HGCal if we actually got it for( const auto& hgcGeom : m_hgcGeom ){ if( hgcGeom.product() ) { float minZ = 1e6, maxZ = 0; From 81cf8454e0460ee7d04faf80f8e060554fda23a4 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Mon, 6 Oct 2014 15:05:14 +0200 Subject: [PATCH 200/252] never allow linking in the same layer, use seed merging only collect seeds deeper/shallower than what is being tested --- RecoParticleFlow/PFClusterProducer/src/Arbor.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RecoParticleFlow/PFClusterProducer/src/Arbor.cc b/RecoParticleFlow/PFClusterProducer/src/Arbor.cc index 3405ec5e40032..0aba0aba7db70 100644 --- a/RecoParticleFlow/PFClusterProducer/src/Arbor.cc +++ b/RecoParticleFlow/PFClusterProducer/src/Arbor.cc @@ -767,7 +767,7 @@ void BranchBuilding(const float distSeedForMerge) kdtree.search(searchcube,found); for(unsigned j7 = 0; j7 < found.size(); j7++) { DisSeed = seedpos - cleanedHits[ found[j7].data ]; - if( DisSeed.Mag2() < distSeedForMerge2 ) { + if( std::abs(DisSeed.Z()) > 1e-3 && DisSeed.Mag2() < distSeedForMerge2 ) { auto seed_branches = seedToBranchesMap.equal_range(found[j7].data); for( auto itr = seed_branches.first; itr != seed_branches.second; ++itr ){ const auto foundSortedIdx = itr->second; From dce694820e181cb00a339b2a4d94fd96d64ee02f Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Mon, 6 Oct 2014 17:21:38 +0200 Subject: [PATCH 201/252] retune HEF/HEB clustering --- RecoParticleFlow/PFClusterProducer/interface/Arbor.hh | 4 ++-- .../PFClusterProducer/plugins/PFArborLinker.cc | 2 +- .../python/particleFlowClusterHGCEE_cfi.py | 1 + .../python/particleFlowClusterHGCHEB_cfi.py | 1 + .../python/particleFlowClusterHGCHEF_cfi.py | 1 + RecoParticleFlow/PFClusterProducer/src/Arbor.cc | 11 +++++++---- .../PFClusterProducer/src/SimpleArborClusterizer.cc | 4 ++-- .../PFClusterProducer/src/SimpleArborClusterizer.h | 5 +++-- .../PFClusterProducer/test/run_display.sh | 2 +- 9 files changed, 19 insertions(+), 12 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/interface/Arbor.hh b/RecoParticleFlow/PFClusterProducer/interface/Arbor.hh index 139ace8ac46a9..079177729b802 100644 --- a/RecoParticleFlow/PFClusterProducer/interface/Arbor.hh +++ b/RecoParticleFlow/PFClusterProducer/interface/Arbor.hh @@ -18,7 +18,7 @@ namespace arbor { void LinkIteration(float Threshold); - void BranchBuilding(const float distSeedForMerge); + void BranchBuilding(const float distSeedForMerge, const bool allowSameLayerSeedMerge); void BushMerging(); @@ -26,7 +26,7 @@ namespace arbor { void MakingCMSCluster(); - branchcoll Arbor( std::vector, const float CellSize, const float LayerThickness, const float distSeedForMerge ); + branchcoll Arbor( std::vector, const float CellSize, const float LayerThickness, const float distSeedForMerge, const bool allowSameLayerSeedMerge ); } #endif diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFArborLinker.cc b/RecoParticleFlow/PFClusterProducer/plugins/PFArborLinker.cc index a677cc4ddff97..f4af23e502611 100644 --- a/RecoParticleFlow/PFClusterProducer/plugins/PFArborLinker.cc +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFArborLinker.cc @@ -69,7 +69,7 @@ void PFArborLinker::produce(edm::Event& iEvent, } } - ArborBranch = arbor::Arbor(ArborIntegralHits, 2, 1,20.0); + ArborBranch = arbor::Arbor(ArborIntegralHits, 2, 1,20.0,true); int NBranch = ArborBranch.size(); int BranchSize = 0; // int currhitindex = 0; diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py index df7362265294c..cb48093e7e64a 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py @@ -31,6 +31,7 @@ distSeedForMerge = cms.double(20.0), killNoiseClusters = cms.bool(True), maxNoiseClusterSize = cms.uint32(3), + allowSameLayerSeedMerge = cms.bool(False), thresholdsByDetector = cms.VPSet( ) ) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py index 68e2aabd180bf..7f0a9de38924d 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py @@ -28,6 +28,7 @@ distSeedForMerge = cms.double(20.0), killNoiseClusters = cms.bool(True), maxNoiseClusterSize = cms.uint32(3), + allowSameLayerSeedMerge = cms.bool(True), thresholdsByDetector = cms.VPSet( ) ) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py index 1fb91a182e124..a8b5b8c577837 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py @@ -28,6 +28,7 @@ distSeedForMerge = cms.double(30.0), killNoiseClusters = cms.bool(True), maxNoiseClusterSize = cms.uint32(3), + allowSameLayerSeedMerge = cms.bool(True), thresholdsByDetector = cms.VPSet( ) ) diff --git a/RecoParticleFlow/PFClusterProducer/src/Arbor.cc b/RecoParticleFlow/PFClusterProducer/src/Arbor.cc index 0aba0aba7db70..ed6a1dcf6ea29 100644 --- a/RecoParticleFlow/PFClusterProducer/src/Arbor.cc +++ b/RecoParticleFlow/PFClusterProducer/src/Arbor.cc @@ -542,7 +542,8 @@ void LinkIteration() //Energy corrections, semi-local correction } -void BranchBuilding(const float distSeedForMerge) +void BranchBuilding(const float distSeedForMerge, + const bool allowSameLayerSeedMerge) { edm::LogInfo("ArborInfo") <<"Build Branch"< 1e-3 && DisSeed.Mag2() < distSeedForMerge2 ) { + if( ( allowSameLayerSeedMerge || std::abs(DisSeed.Z()) > 1e-3 ) && + DisSeed.Mag2() < distSeedForMerge2 ) { auto seed_branches = seedToBranchesMap.equal_range(found[j7].data); for( auto itr = seed_branches.first; itr != seed_branches.second; ++itr ){ const auto foundSortedIdx = itr->second; @@ -865,7 +867,8 @@ void MakingCMSCluster() // edm::Event& Event, const edm::EventSetup& Setup ) std::vector< std::vector > Arbor(std::vector inputHits, const float CellSize, const float LayerThickness, - const float distSeedForMerge ) { + const float distSeedForMerge, + const bool allowSameLayerSeedMerge) { init(CellSize, LayerThickness); HitsCleaning( std::move(inputHits) ); @@ -882,7 +885,7 @@ void MakingCMSCluster() // edm::Event& Event, const edm::EventSetup& Setup ) //IterLinks = InitLinks; - BranchBuilding(distSeedForMerge); + BranchBuilding(distSeedForMerge,allowSameLayerSeedMerge); BushMerging(); return Trees; diff --git a/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.cc b/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.cc index 4421a9fdb032c..9e57868f1007c 100644 --- a/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.cc +++ b/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.cc @@ -53,9 +53,9 @@ buildClusters(const edm::Handle& input, << "arbor loaded: " << arbor_points[1].size() << " in positive endcap!"; - the_branches[0] = arbor::Arbor(arbor_points[0],_cellSize,_layerThickness,_distSeedForMerge); + the_branches[0] = arbor::Arbor(arbor_points[0],_cellSize,_layerThickness,_distSeedForMerge,_allowSameLayerSeedMerge); edm::LogInfo("ArborProgress") << "arbor clustered negative endcap!"; - the_branches[1] = arbor::Arbor(arbor_points[1],_cellSize,_layerThickness,_distSeedForMerge); + the_branches[1] = arbor::Arbor(arbor_points[1],_cellSize,_layerThickness,_distSeedForMerge,_allowSameLayerSeedMerge); edm::LogInfo("ArborProgress") << "arbor clustered positive endcap!"; output.reserve(the_branches[0].size()+the_branches[1].size()); diff --git a/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.h b/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.h index 2a816a569b3a7..5ed0f1bd82e88 100644 --- a/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.h +++ b/RecoParticleFlow/PFClusterProducer/src/SimpleArborClusterizer.h @@ -11,8 +11,9 @@ class SimpleArborClusterizer : public InitialClusteringStepBase { InitialClusteringStepBase(conf), _cellSize(conf.getParameter("cellSize")), _layerThickness(conf.getParameter("layerThickness")), - _distSeedForMerge(conf.getParameter("distSeedForMerge")), + _distSeedForMerge(conf.getParameter("distSeedForMerge")), _killNoiseClusters(conf.getParameter("killNoiseClusters")), + _allowSameLayerSeedMerge(conf.getParameter("allowSameLayerSeedMerge")), _maxNoiseClusterSize(conf.getParameter("maxNoiseClusterSize")) { } virtual ~SimpleArborClusterizer() {} SimpleArborClusterizer(const B2DGT&) = delete; @@ -25,7 +26,7 @@ class SimpleArborClusterizer : public InitialClusteringStepBase { private: double _cellSize,_layerThickness,_distSeedForMerge; - bool _killNoiseClusters; + bool _killNoiseClusters,_allowSameLayerSeedMerge; unsigned _maxNoiseClusterSize; }; diff --git a/RecoParticleFlow/PFClusterProducer/test/run_display.sh b/RecoParticleFlow/PFClusterProducer/test/run_display.sh index 45f194a88c37e..7b57dca0590d1 100755 --- a/RecoParticleFlow/PFClusterProducer/test/run_display.sh +++ b/RecoParticleFlow/PFClusterProducer/test/run_display.sh @@ -1,6 +1,6 @@ #!/bin/bash -cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g ~/work/public/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file ~/work/public/xHGCAL/cmsSimGeom-14-HGCAL.root ${CMSSW_BASE}/src/matrix_tests/14801_FourMuPt1_200+FourMuPt_1_200_Extended2023HGCalV4_GenSimFull+DigiFull_Extended2023HGCalV4+RecoFull_Extended2023HGCalV4+HARVESTFull_Extended2023HGCalV4/step3.root +cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g ~/work/public/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file ~/work/public/xHGCAL/cmsSimGeom-14-HGCAL.root /afs/cern.ch/user/l/lgray/work/public/CMSSW_6_2_0_SLHC18/src/step3.root #${CMSSW_BASE}/src/matrix_tests/14802_SingleElectronPt35+SingleElectronPt35_Extended2023HGCalV4_GenSimFull+DigiFull_Extended2023HGCalV4+RecoFull_Extended2023HGCalV4+HARVESTFull_Extended2023HGCalV4/step3.root #12202_SinglePionPt35+SinglePionPt35_Extended2023HGCalMuon_GenSimFull+DigiFull_Extended2023HGCalMuon+RecoFull_Extended2023HGCalMuon+HARVESTFull_Extended2023HGCalMuon From c44fc053efffc850ea645895896add5e9fe7b010 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Wed, 8 Oct 2014 10:39:19 +0200 Subject: [PATCH 202/252] working on rechit view stuff --- .../Calo/plugins/FWHGCEERecHitProxyBuilder.cc | 1 - .../Geometry/src/FWRecoGeometryESProducer.cc | 16 ++++++++++------ .../PFClusterProducer/test/run_display.sh | 5 ++++- 3 files changed, 14 insertions(+), 8 deletions(-) diff --git a/Fireworks/Calo/plugins/FWHGCEERecHitProxyBuilder.cc b/Fireworks/Calo/plugins/FWHGCEERecHitProxyBuilder.cc index 5bf95bd55f359..6dc32a19bec75 100644 --- a/Fireworks/Calo/plugins/FWHGCEERecHitProxyBuilder.cc +++ b/Fireworks/Calo/plugins/FWHGCEERecHitProxyBuilder.cc @@ -16,7 +16,6 @@ class FWHGCEERecHitProxyBuilder : public FWCaloRecHitDigitSetProxyBuilder REGISTER_FWPROXYBUILDER( FWHGCEERecHitProxyBuilder, HGCRecHitCollection, "HGCEE RecHit", FWViewType::kISpyBit ); - // AMT: Refelct box. Previously used energyScaledBox3DCorners() /* diff --git a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc index 73092845e3700..e5f91df66660d 100644 --- a/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc +++ b/Fireworks/Geometry/src/FWRecoGeometryESProducer.cc @@ -88,12 +88,12 @@ FWRecoGeometryESProducer::produce( const FWRecoGeometryRecord& record ) record.getRecord().get( m_caloGeom ); - // m_hgcGeom.push_back(edm::ESHandle()); - // record.getRecord().get( "HGCalEESensitive", m_hgcGeom.back() ); - // m_hgcGeom.push_back(edm::ESHandle()); - // record.getRecord().get( "HGCalHESiliconSensitive", m_hgcGeom.back() ); - // m_hgcGeom.push_back(edm::ESHandle()); - // record.getRecord().get( "HGCalHEScintillatorSensitive", m_hgcGeom.back() ); + m_hgcGeom.push_back(edm::ESHandle()); + record.getRecord().get( "HGCalEESensitive", m_hgcGeom.back() ); + m_hgcGeom.push_back(edm::ESHandle()); + record.getRecord().get( "HGCalHESiliconSensitive", m_hgcGeom.back() ); + m_hgcGeom.push_back(edm::ESHandle()); + record.getRecord().get( "HGCalHEScintillatorSensitive", m_hgcGeom.back() ); m_hgcGeom.push_back(edm::ESHandle()); record.getRecord().get( "HGCalEESensitive", m_hgcGeom.back() ); @@ -480,6 +480,10 @@ FWRecoGeometryESProducer::addCaloGeometry( void ) for( const auto& hid : hids ) { const HGCalGeometry::CornersVec cor( std::move( hgcGeom->getCorners( hid ) ) ); for( const auto& corner : cor ) { + if( std::abs(corner.eta()) >3.0 ) { + std::cout << "THIS IS VERY BAD RECHIT CORNER IS PAST ETA 3.0 BOUNDARY FOR: " + << std::hex << hid.rawId() << std::dec << " : eta=" << corner.eta() << std::endl; + } minZ = std::min(std::abs(corner.z()),minZ); maxZ = std::max(std::abs(corner.z()),maxZ); minRho = std::min(std::hypot(corner.x(),corner.y()), minRho); diff --git a/RecoParticleFlow/PFClusterProducer/test/run_display.sh b/RecoParticleFlow/PFClusterProducer/test/run_display.sh index 7b57dca0590d1..2dfd12cb0f49a 100755 --- a/RecoParticleFlow/PFClusterProducer/test/run_display.sh +++ b/RecoParticleFlow/PFClusterProducer/test/run_display.sh @@ -1,6 +1,9 @@ #!/bin/bash -cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g ~/work/public/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file ~/work/public/xHGCAL/cmsSimGeom-14-HGCAL.root /afs/cern.ch/user/l/lgray/work/public/CMSSW_6_2_0_SLHC18/src/step3.root #${CMSSW_BASE}/src/matrix_tests/14802_SingleElectronPt35+SingleElectronPt35_Extended2023HGCalV4_GenSimFull+DigiFull_Extended2023HGCalV4+RecoFull_Extended2023HGCalV4+HARVESTFull_Extended2023HGCalV4/step3.root +cmsShow -c ${CMSSW_BASE}/src/RecoParticleFlow/PFClusterProducer/test/hgcal_rechits.fwc -g ~/work/public/xHGCAL/cmsRecoGeom1-HGCAL.root --sim-geom-file ~/work/public/xHGCAL/cmsSimGeom-14-HGCAL.root ${CMSSW_BASE}/src/step3.root + + +#/afs/cern.ch/work/v/vandreev/public/pileup/SLHC18patch2/step3_v4_QCD_Pt_80_120_14TeV_PU.root #12202_SinglePionPt35+SinglePionPt35_Extended2023HGCalMuon_GenSimFull+DigiFull_Extended2023HGCalMuon+RecoFull_Extended2023HGCalMuon+HARVESTFull_Extended2023HGCalMuon From c5dff9550f84e769c74519dd880c91b31b2c1191 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Fri, 17 Oct 2014 14:41:49 +0200 Subject: [PATCH 203/252] Remove shielding around beampipe. --- .../EcalCommonData/data/PhaseII/eregalgo.xml | 30 ++++--------------- .../EcalCommonData/data/PhaseII/esalgo.xml | 20 ------------- 2 files changed, 5 insertions(+), 45 deletions(-) diff --git a/Geometry/EcalCommonData/data/PhaseII/eregalgo.xml b/Geometry/EcalCommonData/data/PhaseII/eregalgo.xml index 9cf056bc5c1df..31af2abc429a5 100644 --- a/Geometry/EcalCommonData/data/PhaseII/eregalgo.xml +++ b/Geometry/EcalCommonData/data/PhaseII/eregalgo.xml @@ -6,41 +6,21 @@ - + - - + + - - - - - - - - - - - - - - - - - - - - - - + + diff --git a/Geometry/EcalCommonData/data/PhaseII/esalgo.xml b/Geometry/EcalCommonData/data/PhaseII/esalgo.xml index 87f0bfbe65072..560710d8f63f9 100644 --- a/Geometry/EcalCommonData/data/PhaseII/esalgo.xml +++ b/Geometry/EcalCommonData/data/PhaseII/esalgo.xml @@ -6,8 +6,6 @@ - - @@ -15,14 +13,6 @@ - - - - - - - - @@ -30,16 +20,6 @@ - - - - - - - - - - From 7e4aa9530f4aceeb96ba0d91397b0f513b2b50b1 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Fri, 17 Oct 2014 17:38:49 +0200 Subject: [PATCH 204/252] Fix beampipe geometry and overlaps with Tracker --- .../CMSCommonData/data/PhaseI/beampipe.xml | 18 ++++++++++-------- Geometry/CMSCommonData/data/PhaseI/cms.xml | 2 ++ Geometry/ForwardCommonData/data/forward.xml | 2 +- .../data/PhaseII/BarrelEndcap5D/tracker.xml | 18 ++++++++++++------ .../data/PhaseII/Pixel10D/pixfwd.xml | 5 ++--- 5 files changed, 27 insertions(+), 18 deletions(-) diff --git a/Geometry/CMSCommonData/data/PhaseI/beampipe.xml b/Geometry/CMSCommonData/data/PhaseI/beampipe.xml index bac428fc9673f..9c33bfd3e995e 100644 --- a/Geometry/CMSCommonData/data/PhaseI/beampipe.xml +++ b/Geometry/CMSCommonData/data/PhaseI/beampipe.xml @@ -50,8 +50,8 @@ - - + + @@ -104,7 +104,7 @@ - + @@ -147,7 +147,9 @@ - + + + @@ -203,12 +205,12 @@ - + - - - + + + diff --git a/Geometry/CMSCommonData/data/PhaseI/cms.xml b/Geometry/CMSCommonData/data/PhaseI/cms.xml index e786d906dcdaa..1aa9af6b3c999 100644 --- a/Geometry/CMSCommonData/data/PhaseI/cms.xml +++ b/Geometry/CMSCommonData/data/PhaseI/cms.xml @@ -19,6 +19,8 @@ + + diff --git a/Geometry/ForwardCommonData/data/forward.xml b/Geometry/ForwardCommonData/data/forward.xml index 48c5df46818d1..b21a800ad32ca 100644 --- a/Geometry/ForwardCommonData/data/forward.xml +++ b/Geometry/ForwardCommonData/data/forward.xml @@ -33,7 +33,7 @@ - + diff --git a/Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/tracker.xml b/Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/tracker.xml index e975780d303bc..e52d90c764d85 100644 --- a/Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/tracker.xml +++ b/Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/tracker.xml @@ -16030,16 +16030,22 @@ - - + - - + + + + + + + + + + - - + diff --git a/Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwd.xml b/Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwd.xml index 8e86e4c1e2b02..5e3ccc4e11ed3 100644 --- a/Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwd.xml +++ b/Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwd.xml @@ -59,11 +59,10 @@ - + - - + From 38a93d2b830a2d345f03bae1ff9deb08cb7d1a25 Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 17 Oct 2014 17:40:42 +0200 Subject: [PATCH 205/252] 2D clustering for Shashlik with multifit --- .../python/particleFlowClusterShashlik_cfi.py | 2 +- .../python/particleFlowCluster_cff.py | 9 +-------- .../python/particleFlowRecHitShashlik_cfi.py | 19 ++++++------------- .../Configuration/python/combinedCustoms.py | 9 ++++----- 4 files changed, 12 insertions(+), 27 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py index 6e091f4ce1734..fdf8b2b5fb184 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterShashlik_cfi.py @@ -58,7 +58,7 @@ # pf clustering _pfClusterizer_EK = cms.PSet( - algoName = cms.string("PFlow2DClusterizerWithTime"), + algoName = cms.string("Basic2DGenericPFlowClusterizer"), #pf clustering parameters minFractionToKeep = cms.double(1e-7), positionCalc = _positionCalcECAL_3x3_nodepth, diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py index df63b0d7cb9f3..ebba2806b714d 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowCluster_cff.py @@ -46,14 +46,7 @@ pfClusteringECAL = cms.Sequence() -withTime = True -if withTime: - pfClusteringECAL = cms.Sequence(particleFlowRecHitECALWithTime* - particleFlowClusterECALWithTimeSequence) - particleFlowClusterECAL.inputECAL = cms.InputTag('particleFlowClusterECALWithTimeSelected') -else: - pfClusteringECAL = cms.Sequence(particleFlowRecHitECAL* - particleFlowClusterECALSequence) +pfClusteringECAL = cms.Sequence(particleFlowRecHitECAL*particleFlowClusterECALUncorrected*particleFlowClusterECAL) pfClusteringEK = cms.Sequence( particleFlowRecHitEK + particleFlowClusterEKUncorrected ) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py index cbb226b879cb4..63e6fc15f8966 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitShashlik_cfi.py @@ -8,14 +8,7 @@ particleFlowRecHitEK = cms.EDProducer("PFRecHitProducer", navigator = cms.PSet( - name = cms.string("PFRecHitShashlikNavigatorWithTime"), - noiseLevel = cms.double(0.027), - noiseTerm = cms.double(36.1), - constantTerm = cms.double(10), - sigmaCut = cms.double(5.0), - timeResolutionCalc = _timeResolutionShashlikEndcap, - barrel = cms.PSet( ), - endcap = cms.PSet( ) + name = cms.string("PFRecHitShashlikNavigator"), ), producers = cms.VPSet( cms.PSet( @@ -25,12 +18,12 @@ cms.PSet( name = cms.string("PFRecHitQTestThreshold"), threshold = cms.double(0.08) - ), - cms.PSet( - name = cms.string("PFRecHitQTestShashlikTiming"), - UseSafetyCuts = cms.bool(True), - BadTimingEThreshold = cms.double(0.250) ) +# cms.PSet( +# name = cms.string("PFRecHitQTestShashlikTiming"), +# UseSafetyCuts = cms.bool(True), +# BadTimingEThreshold = cms.double(0.250) +# ) ) ) ) diff --git a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py index 517024cf6b2a0..c137e24187738 100644 --- a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py @@ -148,19 +148,18 @@ def cust_2023SHCal(process): if hasattr(process,'reconstruction_step'): process.ecalRecHit.EEuncalibRecHitCollection = cms.InputTag("","") #remove the old EE pfrechit producer - del process.particleFlowRecHitECALWithTime.producers[1] del process.particleFlowRecHitECAL.producers[1] process.particleFlowClusterEBEKMerger = cms.EDProducer('PFClusterCollectionMerger', - inputs = cms.VInputTag(cms.InputTag('particleFlowClusterECALWithTimeUncorrected'), + inputs = cms.VInputTag(cms.InputTag('particleFlowClusterECALUncorrected'), cms.InputTag('particleFlowClusterEKUncorrected') ) ) process.pfClusteringECAL.remove(process.particleFlowClusterECAL) - process.pfClusteringECAL.remove(process.particleFlowClusterECALWithTimeSelected) +# process.pfClusteringECAL.remove(process.particleFlowClusterECALWithTimeSelected) process.pfClusteringECAL += process.pfClusteringEK process.pfClusteringECAL += process.particleFlowClusterEBEKMerger - process.pfClusteringECAL += process.particleFlowClusterECALWithTimeSelected - process.particleFlowClusterECALWithTimeSelected.src = cms.InputTag('particleFlowClusterEBEKMerger') + process.pfClusteringECAL += process.particleFlowClusterECAL + process.particleFlowClusterECAL.inputECAL = cms.InputTag('particleFlowClusterEBEKMerger') process.pfClusteringECAL += process.particleFlowClusterECAL #process.particleFlowCluster += process.pfClusteringEK From 5d27374d162bb7cfaca8595bacc6daa13b803096 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Fri, 17 Oct 2014 18:04:27 +0200 Subject: [PATCH 206/252] Phase II beampipe --- .../CMSCommonData/data/PhaseII/beampipe.xml | 898 ++++++++++++++++++ Geometry/CMSCommonData/data/materials.xml | 44 +- 2 files changed, 939 insertions(+), 3 deletions(-) create mode 100644 Geometry/CMSCommonData/data/PhaseII/beampipe.xml diff --git a/Geometry/CMSCommonData/data/PhaseII/beampipe.xml b/Geometry/CMSCommonData/data/PhaseII/beampipe.xml new file mode 100644 index 0000000000000..496c74e733526 --- /dev/null +++ b/Geometry/CMSCommonData/data/PhaseII/beampipe.xml @@ -0,0 +1,898 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/CMSCommonData/data/materials.xml b/Geometry/CMSCommonData/data/materials.xml index 8c9cbb6dfd6a8..e69216458e619 100644 --- a/Geometry/CMSCommonData/data/materials.xml +++ b/Geometry/CMSCommonData/data/materials.xml @@ -286,13 +286,51 @@ - - + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 3b408385a17c6f473d7d7aa26e97568f932f92ad Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Fri, 17 Oct 2014 18:16:52 +0200 Subject: [PATCH 207/252] Take the EE- and EE+ FEDs out of the HGCal raw-to-digi sequences --- .../Configuration/python/combinedCustoms.py | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py index 1a4207a33300f..7391076c747e3 100644 --- a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py @@ -256,6 +256,24 @@ def cust_2023HGCal(process): process.mix.mixObjects.mixCH.subdets.append( process.hgceeDigitizer.hitCollection.value() ) process.mix.mixObjects.mixCH.subdets.append( process.hgchebackDigitizer.hitCollection.value() ) process.mix.mixObjects.mixCH.subdets.append( process.hgchefrontDigitizer.hitCollection.value() ) + if hasattr(process,'raw2digi_step'): + process.ecalDigis.FEDs = cms.vint32( + # EE-: + #601, 602, 603, 604, 605, + #606, 607, 608, 609, + # EB-: + 610, 611, 612, 613, 614, 615, + 616, 617, 618, 619, 620, 621, + 622, 623, 624, 625, 626, 627, + # EB+: + 628, 629, 630, 631, 632, 633, + 634, 635, 636, 637, 638, 639, + 640, 641, 642, 643, 644, 645, + # EE+: + #646, 647, 648, 649, 650, + #651, 652, 653, 654 + ) + print "RAW2DIGI only for EB FEDs" if hasattr(process,'reconstruction_step'): process.particleFlowCluster += process.particleFlowRecHitHGC process.particleFlowCluster += process.particleFlowClusterHGC @@ -319,6 +337,24 @@ def cust_2023HGCalMuon(process): process.mix.mixObjects.mixCH.subdets.append( process.hgceeDigitizer.hitCollection.value() ) process.mix.mixObjects.mixCH.subdets.append( process.hgchebackDigitizer.hitCollection.value() ) process.mix.mixObjects.mixCH.subdets.append( process.hgchefrontDigitizer.hitCollection.value() ) + if hasattr(process,'raw2digi_step'): + process.ecalDigis.FEDs = cms.vint32( + # EE-: + #601, 602, 603, 604, 605, + #606, 607, 608, 609, + # EB-: + 610, 611, 612, 613, 614, 615, + 616, 617, 618, 619, 620, 621, + 622, 623, 624, 625, 626, 627, + # EB+: + 628, 629, 630, 631, 632, 633, + 634, 635, 636, 637, 638, 639, + 640, 641, 642, 643, 644, 645, + # EE+: + #646, 647, 648, 649, 650, + #651, 652, 653, 654 + ) + print "RAW2DIGI only for EB FEDs" if hasattr(process,'reconstruction_step'): process.particleFlowCluster += process.particleFlowRecHitHGC process.particleFlowCluster += process.particleFlowClusterHGC From d4b54530db6c490699c9e042c3b6810949765fae Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Fri, 17 Oct 2014 23:31:35 +0200 Subject: [PATCH 208/252] Correct fractions --- Geometry/CMSCommonData/data/materials.xml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/Geometry/CMSCommonData/data/materials.xml b/Geometry/CMSCommonData/data/materials.xml index e69216458e619..79db3a3f51c14 100644 --- a/Geometry/CMSCommonData/data/materials.xml +++ b/Geometry/CMSCommonData/data/materials.xml @@ -301,34 +301,34 @@ - + - + - + - + - + - + - + - + - + - + From e1b481576f1b55505eadb7d83faa5521f1c69c37 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Fri, 17 Oct 2014 23:32:01 +0200 Subject: [PATCH 209/252] Update beampipe --- .../python/cmsExtendedGeometry2023HGCalMuonXML_cfi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonXML_cfi.py index 3ed8f73aec5cd..fc419f3466802 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonXML_cfi.py @@ -14,7 +14,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', From efa9f3656566e4f6109b12e1b2d10e02702c8b26 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Mon, 20 Oct 2014 16:22:32 +0200 Subject: [PATCH 210/252] Update beampipe geometry and material. Make it default for 2023 scenarios. --- .../CMSCommonData/data/PhaseII/beampipe.xml | 29 +++++++------------ Geometry/CMSCommonData/data/materials.xml | 8 +++++ ...cmsExtendedGeometry2023CFCal4EtaXML_cfi.py | 2 +- .../cmsExtendedGeometry2023CFCalXML_cfi.py | 2 +- ...msExtendedGeometry2023FastTimingXML_cfi.py | 2 +- ...ExtendedGeometry2023HGCalConceptXML_cfi.py | 2 +- ...xtendedGeometry2023HGCalMuon4EtaXML_cfi.py | 2 +- ...sExtendedGeometry2023HGCalV4MuonXML_cfi.py | 2 +- .../cmsExtendedGeometry2023HGCalV4XML_cfi.py | 2 +- .../cmsExtendedGeometry2023HGCalXML_cfi.py | 2 +- .../cmsExtendedGeometry2023Muon4EtaXML_cfi.py | 2 +- .../cmsExtendedGeometry2023MuonXML_cfi.py | 2 +- .../cmsExtendedGeometry2023PixelXML_cfi.py | 2 +- ...cmsExtendedGeometry2023SHCal4EtaXML_cfi.py | 2 +- ...ndedGeometry2023SHCalNoTaper4EtaXML_cfi.py | 2 +- ...dGeometry2023SHCalNoTaperRebuildXML_cfi.py | 2 +- ...ExtendedGeometry2023SHCalNoTaperXML_cfi.py | 2 +- .../cmsExtendedGeometry2023SHCalXML_cfi.py | 2 +- .../cmsExtendedGeometry2023TTIXML_cfi.py | 2 +- .../python/cmsExtendedGeometry2023XML_cfi.py | 2 +- 20 files changed, 36 insertions(+), 37 deletions(-) diff --git a/Geometry/CMSCommonData/data/PhaseII/beampipe.xml b/Geometry/CMSCommonData/data/PhaseII/beampipe.xml index 496c74e733526..0449a7eedfafc 100644 --- a/Geometry/CMSCommonData/data/PhaseII/beampipe.xml +++ b/Geometry/CMSCommonData/data/PhaseII/beampipe.xml @@ -50,7 +50,7 @@ - + @@ -208,16 +208,15 @@ - - + - - + + @@ -227,8 +226,8 @@ - - + + @@ -240,19 +239,11 @@ - - - - - - - + + - - - @@ -615,11 +606,11 @@ - + - + diff --git a/Geometry/CMSCommonData/data/materials.xml b/Geometry/CMSCommonData/data/materials.xml index 79db3a3f51c14..1e2a709647703 100644 --- a/Geometry/CMSCommonData/data/materials.xml +++ b/Geometry/CMSCommonData/data/materials.xml @@ -332,6 +332,14 @@ + + + + + + + + diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCal4EtaXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCal4EtaXML_cfi.py index 25323218031a9..60962de5f1861 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCal4EtaXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCal4EtaXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCalXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCalXML_cfi.py index e543b6ef4463a..6f46050fe50ee 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCalXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023CFCalXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023FastTimingXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023FastTimingXML_cfi.py index e7c697bb2ec5e..9f54bf768580f 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023FastTimingXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023FastTimingXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalConceptXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalConceptXML_cfi.py index 61b698231e281..41e049462999d 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalConceptXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalConceptXML_cfi.py @@ -14,7 +14,7 @@ 'Geometry/CMSCommonData/data/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/eta3/etaMax.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuon4EtaXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuon4EtaXML_cfi.py index 5553fbb811975..53daf0d3b0a3d 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuon4EtaXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuon4EtaXML_cfi.py @@ -14,7 +14,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4MuonXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4MuonXML_cfi.py index eef0588e0d630..ecac0f1032df4 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4MuonXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4MuonXML_cfi.py @@ -14,7 +14,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4XML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4XML_cfi.py index eef0588e0d630..ecac0f1032df4 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4XML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalV4XML_cfi.py @@ -14,7 +14,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalXML_cfi.py index 251566c34b420..349f67b58d8b4 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023Muon4EtaXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023Muon4EtaXML_cfi.py index da109b1c86e3e..6be4ba3a72b62 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023Muon4EtaXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023Muon4EtaXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuonXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuonXML_cfi.py index 062e479f16229..d6df34acf7e05 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuonXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023MuonXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023PixelXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023PixelXML_cfi.py index 6298d1efa0164..c285753037dca 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023PixelXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023PixelXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCal4EtaXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCal4EtaXML_cfi.py index dbe3b2bff911c..f799209689246 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCal4EtaXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCal4EtaXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaper4EtaXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaper4EtaXML_cfi.py index 9997a7f8af17b..0d57e4f64ce07 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaper4EtaXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaper4EtaXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperRebuildXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperRebuildXML_cfi.py index 4719e8fe1b4fd..83d4077c5927d 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperRebuildXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperRebuildXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperXML_cfi.py index 3b62d55449d10..c7c4ce009d36c 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalNoTaperXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalXML_cfi.py index 64e8acec32655..f3e5efd589b66 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023SHCalXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023TTIXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023TTIXML_cfi.py index 00aec730622a6..e7520db5d87e2 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023TTIXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023TTIXML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023XML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023XML_cfi.py index cae2b0ec88601..0312f32622be4 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023XML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023XML_cfi.py @@ -15,7 +15,7 @@ 'Geometry/CMSCommonData/data/muonBase.xml', 'Geometry/CMSCommonData/data/cmsMuon.xml', 'Geometry/CMSCommonData/data/mgnt.xml', - 'Geometry/CMSCommonData/data/PhaseI/beampipe.xml', + 'Geometry/CMSCommonData/data/PhaseII/beampipe.xml', 'Geometry/CMSCommonData/data/cmsBeam.xml', 'Geometry/CMSCommonData/data/muonMB.xml', 'Geometry/CMSCommonData/data/muonMagnet.xml', From f1f247976d09d1f6446db190e17cee87aa3dff7d Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Tue, 21 Oct 2014 12:22:36 +0200 Subject: [PATCH 211/252] Pilot beampipe with AlBe composition. HGCal thermal screen at the bottom. --- .../data/PhaseII/Pilot/beampipe.xml | 889 ++++++++++++++++++ ...tendedGeometry2023HGCalMuonPilotXML_cfi.py | 156 +++ .../HGCalCommonData/data/v5/Pilot/hgcal.xml | 146 +++ 3 files changed, 1191 insertions(+) create mode 100644 Geometry/CMSCommonData/data/PhaseII/Pilot/beampipe.xml create mode 100644 Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py create mode 100644 Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml diff --git a/Geometry/CMSCommonData/data/PhaseII/Pilot/beampipe.xml b/Geometry/CMSCommonData/data/PhaseII/Pilot/beampipe.xml new file mode 100644 index 0000000000000..026aabce78423 --- /dev/null +++ b/Geometry/CMSCommonData/data/PhaseII/Pilot/beampipe.xml @@ -0,0 +1,889 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py new file mode 100644 index 0000000000000..60bf88e41149c --- /dev/null +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py @@ -0,0 +1,156 @@ +import FWCore.ParameterSet.Config as cms + +## 2015 + new phase 1 pixel detector + Tracker BarrelEndcap5Dv(described as a pixel detector before the detid migration) + Full PhaseII Muon +XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", + geomXMLFiles = cms.vstring('Geometry/CMSCommonData/data/materials.xml', + 'Geometry/CMSCommonData/data/rotations.xml', + 'Geometry/CMSCommonData/data/extend/cmsextent.xml', + 'Geometry/CMSCommonData/data/PhaseI/cms.xml', + 'Geometry/CMSCommonData/data/cmsMother.xml', + 'Geometry/CMSCommonData/data/cmsTracker.xml', + 'Geometry/CMSCommonData/data/eta3/etaMax.xml', + 'Geometry/CMSCommonData/data/PhaseII/caloBase.xml', + 'Geometry/CMSCommonData/data/cmsCalo.xml', + 'Geometry/CMSCommonData/data/PhaseII/muonBase.xml', + 'Geometry/CMSCommonData/data/cmsMuon.xml', + 'Geometry/CMSCommonData/data/mgnt.xml', + 'Geometry/CMSCommonData/data/PhaseII/Pilot/beampipe.xml', + 'Geometry/CMSCommonData/data/cmsBeam.xml', + 'Geometry/CMSCommonData/data/muonMB.xml', + 'Geometry/CMSCommonData/data/muonMagnet.xml', + 'Geometry/CMSCommonData/data/cavern.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdMaterials.xml', + 'Geometry/TrackerCommonData/data/pixfwdCommon.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdCylinder.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdDisks.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk4.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk5.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk6.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdInnerDisk7.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk1.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk2.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk4.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk5.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk6.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk7.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk8.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk9.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdOuterDisk10.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade1.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade2.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade4.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade5.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade6.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade7.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade8.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade9.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/pixfwdblade10.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarmaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladder.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarladderfull3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/pixbarlayer3.xml', + 'Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/pixbar.xml', + 'Geometry/TrackerCommonData/data/trackermaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseII/BarrelEndcap5D/tracker.xml', + 'Geometry/TrackerCommonData/data/trackerpixbar.xml', + 'Geometry/TrackerCommonData/data/PhaseI/trackerpixfwd.xml', + 'Geometry/EcalCommonData/data/ectkcable.xml', + 'Geometry/EcalCommonData/data/PhaseII/eregalgo.xml', + 'Geometry/EcalCommonData/data/ebalgo.xml', + 'Geometry/EcalCommonData/data/ebcon.xml', + 'Geometry/EcalCommonData/data/ebrot.xml', + 'Geometry/EcalCommonData/data/eecon.xml', + 'Geometry/EcalCommonData/data/PhaseII/escon.xml', + 'Geometry/EcalCommonData/data/PhaseII/esalgo.xml', + 'Geometry/HcalCommonData/data/hcalrotations.xml', + 'Geometry/HcalCommonData/data/PhaseII/NoHE/hcalalgo.xml', + 'Geometry/HcalCommonData/data/hcalbarrelalgo.xml', + 'Geometry/HcalCommonData/data/hcalouteralgo.xml', + 'Geometry/HcalCommonData/data/hcalforwardalgo.xml', + 'Geometry/HcalCommonData/data/PhaseII/NoHE/hcalSimNumbering.xml', + 'Geometry/HcalCommonData/data/PhaseII/NoHE/hcalRecNumbering.xml', + 'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', + 'Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml', + 'Geometry/HGCalCommonData/data/v5/hgcalEE.xml', + 'Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml', + 'Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml', + 'Geometry/HGCalCommonData/data/v5/hgcalCons.xml', + 'Geometry/MuonCommonData/data/v1/mbCommon.xml', + 'Geometry/MuonCommonData/data/v1/mb1.xml', + 'Geometry/MuonCommonData/data/v1/mb2.xml', + 'Geometry/MuonCommonData/data/v1/mb3.xml', + 'Geometry/MuonCommonData/data/v1/mb4.xml', + 'Geometry/MuonCommonData/data/design/muonYoke.xml', + 'Geometry/MuonCommonData/data/PhaseII/mf.xml', + 'Geometry/MuonCommonData/data/PhaseII/rpcf.xml', + 'Geometry/MuonCommonData/data/v2/gemf.xml', + 'Geometry/MuonCommonData/data/v4/gem11.xml', + 'Geometry/MuonCommonData/data/v6/gem21.xml', + 'Geometry/MuonCommonData/data/v2/csc.xml', + 'Geometry/MuonCommonData/data/PhaseII/mfshield.xml', + 'Geometry/MuonCommonData/data/PhaseII/me0.xml', + 'Geometry/ForwardCommonData/data/forward.xml', + 'Geometry/ForwardCommonData/data/v2/forwardshield.xml', + 'Geometry/ForwardCommonData/data/brmrotations.xml', + 'Geometry/ForwardCommonData/data/brm.xml', + 'Geometry/ForwardCommonData/data/totemMaterials.xml', + 'Geometry/ForwardCommonData/data/totemRotations.xml', + 'Geometry/ForwardCommonData/data/totemt1.xml', + 'Geometry/ForwardCommonData/data/totemt2.xml', + 'Geometry/ForwardCommonData/data/ionpump.xml', + 'Geometry/ForwardCommonData/data/castor.xml', + 'Geometry/ForwardCommonData/data/zdcmaterials.xml', + 'Geometry/ForwardCommonData/data/lumimaterials.xml', + 'Geometry/ForwardCommonData/data/zdcrotations.xml', + 'Geometry/ForwardCommonData/data/lumirotations.xml', + 'Geometry/ForwardCommonData/data/zdc.xml', + 'Geometry/ForwardCommonData/data/zdclumi.xml', + 'Geometry/ForwardCommonData/data/cmszdc.xml')+cms.vstring( + 'Geometry/MuonCommonData/data/PhaseII/muonNumbering.xml', + 'Geometry/TrackerCommonData/data/PhaseII/Pixel10D/trackerStructureTopology.xml', + 'Geometry/TrackerSimData/data/PhaseII/Pixel10D/trackersens.xml', + 'Geometry/TrackerRecoData/data/PhaseII/Pixel10D/trackerRecoMaterial.xml', + 'Geometry/EcalSimData/data/PhaseII/ecalsens.xml', + 'Geometry/HcalCommonData/data/PhaseII/NoHE/hcalsenspmf.xml', + 'Geometry/HcalSimData/data/hf.xml', + 'Geometry/HcalSimData/data/hfpmt.xml', + 'Geometry/HcalSimData/data/hffibrebundle.xml', + 'Geometry/HcalSimData/data/CaloUtil.xml', + 'Geometry/HGCalSimData/data/hgcsens.xml', + 'Geometry/HGCalSimData/data/hgccons.xml', + 'Geometry/HGCalSimData/data/hgcProdCuts.xml', + 'Geometry/MuonSimData/data/PhaseII/muonSens.xml', + 'Geometry/DTGeometryBuilder/data/dtSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecs.xml', + 'Geometry/RPCGeometryBuilder/data/PhaseII/RPCSpecs.xml', + 'Geometry/GEMGeometryBuilder/data/v5/GEMSpecs.xml', + 'Geometry/ForwardCommonData/data/brmsens.xml', + 'Geometry/ForwardSimData/data/castorsens.xml', + 'Geometry/ForwardSimData/data/zdcsens.xml', + 'Geometry/HcalSimData/data/HcalProdCuts.xml', + 'Geometry/EcalSimData/data/EcalProdCuts.xml', + 'Geometry/TrackerSimData/data/PhaseII/Pixel10D/trackerProdCuts.xml', + 'Geometry/TrackerSimData/data/trackerProdCutsBEAM.xml', + 'Geometry/MuonSimData/data/PhaseII/muonProdCuts.xml', + 'Geometry/ForwardSimData/data/CastorProdCuts.xml', + 'Geometry/ForwardSimData/data/zdcProdCuts.xml', + 'Geometry/ForwardSimData/data/ForwardShieldProdCuts.xml', + 'Geometry/CMSCommonData/data/FieldParameters.xml'), + rootNodeName = cms.string('cms:OCMS') +) + + diff --git a/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml b/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml new file mode 100644 index 0000000000000..15e6b00bc8620 --- /dev/null +++ b/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml @@ -0,0 +1,146 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From af3318330e94324e2f6971598eec7a7baa90d296 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Tue, 21 Oct 2014 15:15:57 +0200 Subject: [PATCH 212/252] Include HGCal support. --- Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml b/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml index 15e6b00bc8620..8b24e80ad771e 100644 --- a/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml +++ b/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml @@ -77,6 +77,11 @@ + + + + + @@ -104,6 +109,10 @@ + + + + @@ -142,5 +151,10 @@ + + + + + From 6dc233aa8ae200472d9a489bdf246e93ec5ad172 Mon Sep 17 00:00:00 2001 From: David Date: Tue, 21 Oct 2014 17:32:08 +0200 Subject: [PATCH 213/252] Fixed me0segment box size --- RecoLocalMuon/GEMRecHit/python/me0Segments_cfi.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/RecoLocalMuon/GEMRecHit/python/me0Segments_cfi.py b/RecoLocalMuon/GEMRecHit/python/me0Segments_cfi.py index 59e68ce26c7cd..fc57fb970bc24 100644 --- a/RecoLocalMuon/GEMRecHit/python/me0Segments_cfi.py +++ b/RecoLocalMuon/GEMRecHit/python/me0Segments_cfi.py @@ -10,8 +10,8 @@ dXclusBoxMax = cms.double(1.), dYclusBoxMax = cms.double(5.), preClusteringUseChaining = cms.bool(True), - dPhiChainBoxMax = cms.double(1.), - dEtaChainBoxMax = cms.double(1.), + dPhiChainBoxMax = cms.double(.02), + dEtaChainBoxMax = cms.double(.05), maxRecHitsInCluster = cms.int32(6) ) ) From 5e1aea9322b443ff1f50961b4847375ba1f899db Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Wed, 22 Oct 2014 01:04:38 +0200 Subject: [PATCH 214/252] Fix classe_def files --- DataFormats/L1TrackTrigger/src/classes_def.xml | 12 +++++++----- DataFormats/L1Trigger/src/classes_def.xml | 3 ++- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/DataFormats/L1TrackTrigger/src/classes_def.xml b/DataFormats/L1TrackTrigger/src/classes_def.xml index 9b4b5def861c5..ac6927931d2e5 100644 --- a/DataFormats/L1TrackTrigger/src/classes_def.xml +++ b/DataFormats/L1TrackTrigger/src/classes_def.xml @@ -77,8 +77,9 @@ - - + + + @@ -93,9 +94,10 @@ - - - + + + + diff --git a/DataFormats/L1Trigger/src/classes_def.xml b/DataFormats/L1Trigger/src/classes_def.xml index f8eff615bf793..7ca781f63b039 100644 --- a/DataFormats/L1Trigger/src/classes_def.xml +++ b/DataFormats/L1Trigger/src/classes_def.xml @@ -11,7 +11,8 @@ - + + From dc1f51e9a7ef24760d5cfc37636ddf0919bdb228 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Wed, 22 Oct 2014 10:35:33 +0200 Subject: [PATCH 215/252] Correct thickness of thermal screen and material. --- Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml b/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml index 8b24e80ad771e..7eb7d8bb548ae 100644 --- a/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml +++ b/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml @@ -54,16 +54,16 @@ - - + + - - + + - - + + @@ -111,7 +111,7 @@ - + From b9d4dc12b06f0f3e4fb8b9872d35fca3fbda7e77 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Wed, 22 Oct 2014 12:51:26 +0200 Subject: [PATCH 216/252] fix 2017dev scenario --- .../python/cmsExtendedGeometry2017devXML_cfi.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py index ece80879d6a66..4982f421454b5 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017devXML_cfi.py @@ -192,7 +192,7 @@ 'Geometry/TrackerCommonData/data/trackermaterial.xml', 'Geometry/TrackerCommonData/data/tracker.xml', 'Geometry/TrackerCommonData/data/trackerpixbar.xml', - 'Geometry/TrackerCommonData/data/PhaseI/trackerpixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/trackerpixfwd.xml', 'Geometry/TrackerCommonData/data/trackertibtidservices.xml', 'Geometry/TrackerCommonData/data/trackertib.xml', 'Geometry/TrackerCommonData/data/trackertid.xml', @@ -250,9 +250,9 @@ 'Geometry/ForwardCommonData/data/zdclumi.xml', 'Geometry/ForwardCommonData/data/cmszdc.xml')+cms.vstring( 'Geometry/MuonCommonData/data/v2/muonNumbering.xml', - 'Geometry/TrackerCommonData/data/PhaseI/trackerStructureTopology.xml', - 'Geometry/TrackerSimData/data/PhaseI/trackersens.xml', - 'Geometry/TrackerRecoData/data/PhaseI/trackerRecoMaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseIdev/trackerStructureTopology.xml', + 'Geometry/TrackerSimData/data/PhaseIdev/trackersens.xml', + 'Geometry/TrackerRecoData/data/PhaseIdev/trackerRecoMaterial.xml', 'Geometry/EcalSimData/data/ecalsens.xml', 'Geometry/HcalCommonData/data/Phase0/hcalsenspmf.xml', 'Geometry/HcalSimData/data/hf.xml', @@ -270,7 +270,7 @@ 'Geometry/HcalSimData/data/HcalProdCuts.xml', 'Geometry/EcalSimData/data/EcalProdCuts.xml', 'Geometry/EcalSimData/data/ESProdCuts.xml', - 'Geometry/TrackerSimData/data/PhaseI/trackerProdCuts.xml', + 'Geometry/TrackerSimData/data/PhaseIdev/trackerProdCuts.xml', 'Geometry/TrackerSimData/data/trackerProdCutsBEAM.xml', 'Geometry/MuonSimData/data/muonProdCuts.xml', 'Geometry/ForwardSimData/data/CastorProdCuts.xml', From 548b7be8720c209eb1f5df66c62b8e879f3d6930 Mon Sep 17 00:00:00 2001 From: vandreev11 Date: Wed, 22 Oct 2014 16:23:22 +0200 Subject: [PATCH 217/252] HGC V5 geometry modification to include inner thermal screen and support structure --- Geometry/HGCalCommonData/data/v5/hgcal.xml | 67 ++++++++++++++++++++-- 1 file changed, 61 insertions(+), 6 deletions(-) diff --git a/Geometry/HGCalCommonData/data/v5/hgcal.xml b/Geometry/HGCalCommonData/data/v5/hgcal.xml index 298c854bf2b43..7eb7d8bb548ae 100644 --- a/Geometry/HGCalCommonData/data/v5/hgcal.xml +++ b/Geometry/HGCalCommonData/data/v5/hgcal.xml @@ -13,6 +13,7 @@ + @@ -22,6 +23,7 @@ + @@ -44,12 +46,24 @@ - - - - - - + + + + + + + + + + + + + + + + + + @@ -63,6 +77,11 @@ + + + + + @@ -70,6 +89,18 @@ + + + + + + + + + + + + @@ -78,6 +109,10 @@ + + + + @@ -91,6 +126,21 @@ + + + + + + + + + + + + + + + @@ -101,5 +151,10 @@ + + + + + From 7f40db71bfaf4a441e0abfd12d0fff9385df01ca Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Wed, 22 Oct 2014 16:27:18 +0200 Subject: [PATCH 218/252] HGCal material budget validation. --- .../Geometry/interface/MaterialBudgetHGCal.h | 46 +++ .../interface/MaterialBudgetHGCalHistos.h | 58 ++++ .../Geometry/src/MaterialBudgetHGCal.cc | 86 +++++ .../Geometry/src/MaterialBudgetHGCalHistos.cc | 323 ++++++++++++++++++ Validation/Geometry/src/module.cc | 2 + Validation/Geometry/test/runP_HGCAL_cfg.py | 79 +++++ 6 files changed, 594 insertions(+) create mode 100644 Validation/Geometry/interface/MaterialBudgetHGCal.h create mode 100644 Validation/Geometry/interface/MaterialBudgetHGCalHistos.h create mode 100644 Validation/Geometry/src/MaterialBudgetHGCal.cc create mode 100644 Validation/Geometry/src/MaterialBudgetHGCalHistos.cc create mode 100644 Validation/Geometry/test/runP_HGCAL_cfg.py diff --git a/Validation/Geometry/interface/MaterialBudgetHGCal.h b/Validation/Geometry/interface/MaterialBudgetHGCal.h new file mode 100644 index 0000000000000..f7082c9941cce --- /dev/null +++ b/Validation/Geometry/interface/MaterialBudgetHGCal.h @@ -0,0 +1,46 @@ +#ifndef Validation_Geometry_MaterialBudgetHGCal_h +#define Validation_Geometry_MaterialBudgetHGCal_h + +#include "Validation/Geometry/interface/MaterialBudgetHGCalHistos.h" + +#include "SimG4Core/Watcher/interface/SimWatcher.h" +#include "SimG4Core/Notification/interface/Observer.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include + +class BeginOfJob; +class BeginOfTrack; +class G4Step; +class EndOfTrack; + +class MaterialBudgetHGCal +: public SimWatcher, + public Observer, + public Observer, + public Observer, + public Observer +{ + public: + + MaterialBudgetHGCal( const edm::ParameterSet& ); + virtual ~MaterialBudgetHGCal( void ); + + private: + + MaterialBudgetHGCal( const MaterialBudgetHGCal& ); + const MaterialBudgetHGCal& operator=( const MaterialBudgetHGCal& ); + + void update( const BeginOfJob* ); + void update( const BeginOfTrack* ); + void update( const G4Step* ); + void update( const EndOfTrack* ); + + bool stopAfter( const G4Step* ); + + MaterialBudgetHGCalHistos* m_HistoHGCal; + double m_rMax; + double m_zMax; +}; + +#endif diff --git a/Validation/Geometry/interface/MaterialBudgetHGCalHistos.h b/Validation/Geometry/interface/MaterialBudgetHGCalHistos.h new file mode 100644 index 0000000000000..2668941e8b9cf --- /dev/null +++ b/Validation/Geometry/interface/MaterialBudgetHGCalHistos.h @@ -0,0 +1,58 @@ +#ifndef Validation_Geometry_MaterialBudgetHGCalHistos_h +#define Validation_Geometry_MaterialBudgetHGCalHistos_h + +#include "DetectorDescription/Core/interface/DDFilteredView.h" +#include "DetectorDescription/Core/interface/DDsvalues.h" +#include "FWCore/ParameterSet/interface/ParameterSet.h" + +#include "G4Step.hh" +#include "G4Track.hh" + +#include +#include +#include +#include + +#include +#include + +class MaterialBudgetHGCalHistos +{ + public: + + MaterialBudgetHGCalHistos( const edm::ParameterSet & ); + virtual ~MaterialBudgetHGCalHistos( void ) {} + + void fillBeginJob( const DDCompactView & ); + void fillStartTrack( const G4Track* ); + void fillPerStep( const G4Step * ); + void fillEndTrack( void ); + + private: + + void book( void ); + void fillHisto( int ); + std::vector getNames( DDFilteredView& ); + bool isItHGC( const std::string & ); + + static const int maxSet = 5; + std::vector sensitives, hgcNames, sensitiveHGC; + bool m_fillHistos; + bool m_printSum; + int binEta, binPhi; + double maxEta, etaLow, etaHigh; + std::vector matList; + std::vector stepLength, radLength, intLength; + TH1F *me400[maxSet], *me800[maxSet]; + TH2F *me1200[maxSet]; + TProfile *me100[maxSet], *me200[maxSet], *me300[maxSet]; + TProfile *me500[maxSet], *me600[maxSet], *me700[maxSet]; + TProfile2D *me900[maxSet], *me1000[maxSet],*me1100[maxSet]; + int m_id; + int layer, steps; + double radLen, intLen, stepLen; + double eta, phi; +}; + + +#endif diff --git a/Validation/Geometry/src/MaterialBudgetHGCal.cc b/Validation/Geometry/src/MaterialBudgetHGCal.cc new file mode 100644 index 0000000000000..179d869215a00 --- /dev/null +++ b/Validation/Geometry/src/MaterialBudgetHGCal.cc @@ -0,0 +1,86 @@ +#include "Validation/Geometry/interface/MaterialBudgetHGCal.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/Framework/interface/ESTransientHandle.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" + +#include "SimG4Core/Notification/interface/BeginOfJob.h" +#include "SimG4Core/Notification/interface/BeginOfTrack.h" +#include "SimG4Core/Notification/interface/EndOfTrack.h" + +#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "DetectorDescription/Core/interface/DDCompactView.h" + +#include "G4Step.hh" +#include "G4Track.hh" + +#include + +MaterialBudgetHGCal::MaterialBudgetHGCal( const edm::ParameterSet& p ) + : m_HistoHGCal(0) +{ + edm::ParameterSet pSet = p.getParameter( "MaterialBudgetHGCal" ); + m_rMax = pSet.getUntrackedParameter( "RMax", 4.5 )*m; + m_zMax = pSet.getUntrackedParameter( "ZMax", 13.0 )*m; + edm::LogInfo( "MaterialBudget" ) << "MaterialBudgetHGCal initialized with rMax " + << m_rMax << " mm and zMax " << m_zMax << " mm"; + m_HistoHGCal = new MaterialBudgetHGCalHistos( pSet ); +} + +MaterialBudgetHGCal::~MaterialBudgetHGCal( void ) +{ + if( m_HistoHGCal) delete m_HistoHGCal; +} + +void +MaterialBudgetHGCal::update( const BeginOfJob* job ) +{ + edm::ESTransientHandle pDD; + (*job)()->get().get(pDD); + if( m_HistoHGCal ) m_HistoHGCal->fillBeginJob((*pDD)); +} + +void +MaterialBudgetHGCal::update( const BeginOfTrack* trk ) +{ + const G4Track * aTrack = ( *trk )(); // recover G4 pointer if wanted + if( m_HistoHGCal ) m_HistoHGCal->fillStartTrack( aTrack ); +} + +void +MaterialBudgetHGCal::update( const G4Step* aStep ) +{ + if( m_HistoHGCal ) m_HistoHGCal->fillPerStep( aStep ); + + if( stopAfter( aStep )) + { + G4Track* track = aStep->GetTrack(); + track->SetTrackStatus( fStopAndKill ); + } +} + +void +MaterialBudgetHGCal::update( const EndOfTrack* ) +{ + if( m_HistoHGCal ) m_HistoHGCal->fillEndTrack(); +} + +bool +MaterialBudgetHGCal::stopAfter( const G4Step* aStep ) +{ + G4ThreeVector hitPoint = aStep->GetPreStepPoint()->GetPosition(); + double rr = hitPoint.perp(); + double zz = std::abs( hitPoint.z()); + + if( rr > m_rMax || zz > m_zMax ) + { + LogDebug("MaterialBudget") << " MaterialBudgetHGCal::StopAfter R = " << rr + << " and Z = " << zz; + return true; + } + else + { + return false; + } +} diff --git a/Validation/Geometry/src/MaterialBudgetHGCalHistos.cc b/Validation/Geometry/src/MaterialBudgetHGCalHistos.cc new file mode 100644 index 0000000000000..0d0e993314f27 --- /dev/null +++ b/Validation/Geometry/src/MaterialBudgetHGCalHistos.cc @@ -0,0 +1,323 @@ +#include "Validation/Geometry/interface/MaterialBudgetHGCalHistos.h" + +#include "DetectorDescription/Core/interface/DDFilter.h" +#include "DetectorDescription/Core/interface/DDLogicalPart.h" +#include "DetectorDescription/Core/interface/DDSplit.h" +#include "DetectorDescription/Core/interface/DDValue.h" +#include "FWCore/Utilities/interface/Exception.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" +#include "FWCore/ServiceRegistry/interface/Service.h" +#include "CommonTools/UtilAlgos/interface/TFileService.h" + +#include "CLHEP/Units/GlobalPhysicalConstants.h" +#include "CLHEP/Units/GlobalSystemOfUnits.h" + +MaterialBudgetHGCalHistos::MaterialBudgetHGCalHistos( const edm::ParameterSet &p ) +{ + binEta = p.getUntrackedParameter( "NBinEta", 260 ); + binPhi = p.getUntrackedParameter( "NBinPhi", 180 ); + maxEta = p.getUntrackedParameter( "MaxEta", 5.2 ); + etaLow = p.getUntrackedParameter( "EtaLow", -5.2 ); + etaHigh = p.getUntrackedParameter( "EtaHigh", 5.2 ); + m_fillHistos = p.getUntrackedParameter( "FillHisto", true ); + m_printSum = p.getUntrackedParameter( "PrintSummary", false ); + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos: FillHisto : " + << m_fillHistos << " PrintSummary " << m_printSum + << " == Eta plot: NX " << binEta << " Range " + << -maxEta << ":" << maxEta <<" Phi plot: NX " + << binPhi << " Range " << -pi << ":" << pi + << " (Eta limit " << etaLow << ":" << etaHigh + <<")"; + if( m_fillHistos) book(); +} + +void +MaterialBudgetHGCalHistos::fillBeginJob( const DDCompactView & cpv ) +{ + if( m_fillHistos ) + { + std::string attribute = "ReadOutName"; + std::string value = "HGCHits"; + DDSpecificsFilter filter1; + DDValue ddv1( attribute, value, 0 ); + filter1.setCriteria( ddv1, DDSpecificsFilter::equals ); + DDFilteredView fv1( cpv ); + fv1.addFilter( filter1 ); + sensitives = getNames( fv1 ); + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos: Names to be " + << "tested for " << attribute << " = " + << value << " has " << sensitives.size() + << " elements"; + for( unsigned int i = 0; i < sensitives.size(); i++ ) + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos: sensitives[" + << i << "] = " << sensitives[i]; + + attribute = "Volume"; + value = "HGC"; + DDSpecificsFilter filter2; + DDValue ddv2( attribute, value, 0 ); + filter2.setCriteria( ddv2, DDSpecificsFilter::equals ); + DDFilteredView fv2( cpv ); + fv2.addFilter( filter2 ); + hgcNames = getNames( fv2 ); + fv2.firstChild(); + DDsvalues_type sv( fv2.mergedSpecifics()); + + std::string hgcalRO[3] = {"HGCHitsEE", "HGCHitsHEfront", "HGCHitsHEback"}; + attribute = "ReadOutName"; + for( int k = 0; k < 3; k++ ) + { + value = hgcalRO[k]; + DDSpecificsFilter filter3; + DDValue ddv3( attribute, value, 0 ); + filter3.setCriteria( ddv3, DDSpecificsFilter::equals ); + DDFilteredView fv3( cpv ); + fv3.addFilter( filter3 ); + std::vector senstmp = getNames( fv3 ); + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos: Names to be" + << " tested for " << attribute << " = " + << value << " has " << senstmp.size() + << " elements"; + for( unsigned int i = 0; i < senstmp.size(); i++ ) + sensitiveHGC.push_back( senstmp[i] ); + } + for( unsigned int i = 0; i < sensitiveHGC.size(); i++ ) + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos:sensitiveHGC[" + << i << "] = " << sensitiveHGC[i]; + } +} + +void +MaterialBudgetHGCalHistos::fillStartTrack( const G4Track* aTrack ) +{ + m_id = layer = steps = 0; + radLen = intLen = stepLen = 0; + + const G4ThreeVector& dir = aTrack->GetMomentum() ; + if (dir.theta() != 0 ) { + eta = dir.eta(); + } else { + eta = -99; + } + phi = dir.phi(); + double theEnergy = aTrack->GetTotalEnergy(); + int theID = (int)(aTrack->GetDefinition()->GetPDGEncoding()); + + if( m_printSum ) { + matList.clear(); + stepLength.clear(); + radLength.clear(); + intLength.clear(); + } + + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos: Track " + << aTrack->GetTrackID() << " Code " << theID + << " Energy " << theEnergy/GeV << " GeV; Eta " + << eta << " Phi " << phi/deg << " PT " + << dir.perp()/GeV << " GeV *****"; +} + +void +MaterialBudgetHGCalHistos::fillPerStep( const G4Step* aStep ) +{ + G4Material * material = aStep->GetPreStepPoint()->GetMaterial(); + double step = aStep->GetStepLength(); + double radl = material->GetRadlen(); + double intl = material->GetNuclearInterLength(); + double density = material->GetDensity() / (g/cm3); + + const G4VTouchable* touch = aStep->GetPreStepPoint()->GetTouchable(); + std::string name = touch->GetVolume(0)->GetName(); + std::string matName = material->GetName(); + if( m_printSum ) + { + bool found = false; + for( unsigned int ii = 0; ii < matList.size(); ii++ ) + { + if( matList[ii] == matName ) + { + stepLength[ii] += step; + radLength[ii] += (step/radl); + intLength[ii] += (step/intl); + found = true; + break; + } + } + if( !found ) + { + matList.push_back( matName ); + stepLength.push_back( step ); + radLength.push_back( step / radl ); + intLength.push_back( step / intl ); + } + edm::LogInfo("MaterialBudget") << name << " " << step << " " << matName + << " " << stepLen << " " << step/radl << " " + << radLen << " " <GetPreStepPoint()->GetPosition() + << " Cylindrical R " + <GetPreStepPoint()->GetPosition().perp() + << " Length (so far) " << stepLen << " L/X0 " + << step/radl << "/" << radLen << " L/Lambda " + << step/intl << "/" << intLen; + } + + if( m_fillHistos && isItHGC( name )) + { + m_id = 1; + fillHisto(m_id-1); + } + + stepLen += step; + radLen += step/radl; + intLen += step/intl; +} + +void +MaterialBudgetHGCalHistos::fillEndTrack( void ) +{ + if( m_fillHistos ) + { + fillHisto( maxSet - 1 ); + } + if( m_printSum ) + { + for( unsigned int ii = 0; ii < matList.size(); ii++ ) + { + edm::LogInfo("MaterialBudget") << matList[ii] << "\t" << stepLength[ii] + << "\t" << radLength[ii] << "\t" + << intLength[ii]; + } + } +} + +void +MaterialBudgetHGCalHistos::book( void ) +{ + edm::Service tfile; + + if( !tfile.isAvailable() ) + throw cms::Exception("BadConfig") << "TFileService unavailable: " + << "please add it to config file"; + + double maxPhi = pi; + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos: Booking user " + << "histos === with " << binEta << " bins " + << "in eta from " << -maxEta << " to " + << maxEta << " and " << binPhi << " bins " + << "in phi from " << -maxPhi << " to " + << maxPhi; + + char name[10], title[40]; + // total X0 + for( int i = 0; i < maxSet; i++ ) + { + sprintf(name, "%d", i+100); + sprintf(title, "MB(X0) prof Eta in region %d", i); + me100[i] = tfile->make(name, title, binEta, -maxEta, maxEta); + sprintf(name, "%d", i+200); + sprintf(title, "MB(L0) prof Eta in region %d", i); + me200[i] = tfile->make(name, title, binEta, -maxEta, maxEta); + sprintf(name, "%d", i+300); + sprintf(title, "MB(Step) prof Eta in region %d", i); + me300[i] = tfile->make(name, title, binEta, -maxEta, maxEta); + sprintf(name, "%d", i+400); + sprintf(title, "Eta in region %d", i); + me400[i] = tfile->make(name, title, binEta, -maxEta, maxEta); + sprintf(name, "%d", i+500); + sprintf(title, "MB(X0) prof Ph in region %d", i); + me500[i] = tfile->make(name, title, binPhi, -maxPhi, maxPhi); + sprintf(name, "%d", i+600); + sprintf(title, "MB(L0) prof Ph in region %d", i); + me600[i] = tfile->make(name, title, binPhi, -maxPhi, maxPhi); + sprintf(name, "%d", i+700); + sprintf(title, "MB(Step) prof Ph in region %d", i); + me700[i] = tfile->make(name, title, binPhi, -maxPhi, maxPhi); + sprintf(name, "%d", i+800); + sprintf(title, "Phi in region %d", i); + me800[i] = tfile->make(name, title, binPhi, -maxPhi, maxPhi); + sprintf(name, "%d", i+900); + sprintf(title, "MB(X0) prof Eta Phi in region %d", i); + me900[i] = tfile->make(name, title, binEta/2, -maxEta, maxEta, + binPhi/2, -maxPhi, maxPhi); + sprintf(name, "%d", i+1000); + sprintf(title, "MB(L0) prof Eta Phi in region %d", i); + me1000[i]= tfile->make(name, title, binEta/2, -maxEta, maxEta, + binPhi/2, -maxPhi, maxPhi); + sprintf(name, "%d", i+1100); + sprintf(title, "MB(Step) prof Eta Phi in region %d", i); + me1100[i]= tfile->make(name, title, binEta/2, -maxEta, maxEta, + binPhi/2, -maxPhi, maxPhi); + sprintf(name, "%d", i+1200); + sprintf(title, "Eta vs Phi in region %d", i); + me1200[i]= tfile->make(name, title, binEta/2, -maxEta, maxEta, + binPhi/2, -maxPhi, maxPhi); + } + edm::LogInfo("MaterialBudget") << "MaterialBudgetHGCalHistos: Booking user " + << "histos done ==="; +} + +void +MaterialBudgetHGCalHistos::fillHisto( int ii ) +{ + LogDebug("MaterialBudget") << "MaterialBudgetHGCalHistos:FillHisto called " + << "with index " << ii << " integrated step " + << stepLen << " X0 " << radLen << " Lamda " + << intLen; + + if( ii >=0 && ii < maxSet ) + { + me100[ii]->Fill( eta, radLen ); + me200[ii]->Fill( eta, intLen ); + me300[ii]->Fill( eta, stepLen ); + me400[ii]->Fill( eta ); + + if( eta >= etaLow && eta <= etaHigh ) + { + me500[ii]->Fill( phi, radLen ); + me600[ii]->Fill( phi, intLen ); + me700[ii]->Fill( phi, stepLen ); + me800[ii]->Fill( phi ); + } + + me900[ii]->Fill( eta, phi, radLen ); + me1000[ii]->Fill( eta, phi, intLen ); + me1100[ii]->Fill( eta, phi, stepLen ); + me1200[ii]->Fill( eta, phi ); + } +} + +std::vector +MaterialBudgetHGCalHistos::getNames( DDFilteredView& fv ) +{ + std::vector tmp; + bool dodet = fv.firstChild(); + while (dodet) { + const DDLogicalPart & log = fv.logicalPart(); + std::string namx = log.name().name(); + bool ok = true; + for (unsigned int i=0; i::const_iterator it = sensitiveHGC.begin(); + std::vector::const_iterator itEnd = sensitiveHGC.end(); + for( ; it != itEnd; ++it ) + if( name == *it ) return true; + return false; +} diff --git a/Validation/Geometry/src/module.cc b/Validation/Geometry/src/module.cc index c422a6f9c6e44..f8597929436f2 100644 --- a/Validation/Geometry/src/module.cc +++ b/Validation/Geometry/src/module.cc @@ -2,11 +2,13 @@ #include "Validation/Geometry/interface/MaterialBudget.h" #include "Validation/Geometry/interface/MaterialBudgetAction.h" #include "Validation/Geometry/interface/MaterialBudgetHcal.h" +#include "Validation/Geometry/interface/MaterialBudgetHGCal.h" #include "Validation/Geometry/interface/MaterialBudgetForward.h" #include "FWCore/PluginManager/interface/ModuleDef.h" DEFINE_SIMWATCHER (MaterialBudget); DEFINE_SIMWATCHER (MaterialBudgetAction); DEFINE_SIMWATCHER (MaterialBudgetHcal); +DEFINE_SIMWATCHER (MaterialBudgetHGCal); DEFINE_SIMWATCHER (MaterialBudgetForward); diff --git a/Validation/Geometry/test/runP_HGCAL_cfg.py b/Validation/Geometry/test/runP_HGCAL_cfg.py new file mode 100644 index 0000000000000..92b967c3d8e6e --- /dev/null +++ b/Validation/Geometry/test/runP_HGCAL_cfg.py @@ -0,0 +1,79 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff') +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff') + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_cff") + +process.load("Configuration.EventContent.EventContent_cff") + +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.MessageLogger = cms.Service("MessageLogger", + destinations = cms.untracked.vstring('cout'), + categories = cms.untracked.vstring('MaterialBudget'), +# debugModules = cms.untracked.vstring('*'), + cout = cms.untracked.PSet( +# threshold = cms.untracked.string('DEBUG'), + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + MaterialBudget = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ) + ) +) + +process.source = cms.Source("PoolSource", + noEventSort = cms.untracked.bool(True), + duplicateCheckMode = cms.untracked.string("noDuplicateCheck"), + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.TFileService = cms.Service("TFileService", + fileName = cms.string('matbdg_HGCAL.root') +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + MaterialBudgetHGCal = cms.PSet( + FillHisto = cms.untracked.bool(True), + PrintSummary = cms.untracked.bool(False), + NBinPhi = cms.untracked.int32(360), + NBinEta = cms.untracked.int32(260), + MaxEta = cms.untracked.double(5.2), + EtaLow = cms.untracked.double(-5.2), + EtaHigh = cms.untracked.double(5.2), + RMax = cms.untracked.double(5.0), + ZMax = cms.untracked.double(14.0) + ), + type = cms.string('MaterialBudgetHGCal') +)) + + +# Automatic addition of the customisation function from SLHCUpgradeSimulations.Configuration.combinedCustoms +from SLHCUpgradeSimulations.Configuration.combinedCustoms import cust_2023HGCalMuon + +#call to customisation function cust_2023HGCalMuon imported from SLHCUpgradeSimulations.Configuration.combinedCustoms +process = cust_2023HGCalMuon(process) From ee52c0e9e27a6edce5040dfba8d666d735980b15 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Wed, 22 Oct 2014 17:27:37 +0200 Subject: [PATCH 219/252] Cleanup for PR 5935 --- ...tendedGeometry2023HGCalMuonPilotXML_cfi.py | 2 +- .../HGCalCommonData/data/v5/Pilot/hgcal.xml | 160 ------------------ 2 files changed, 1 insertion(+), 161 deletions(-) delete mode 100644 Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py index 60bf88e41149c..10bf16988bb0c 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2023HGCalMuonPilotXML_cfi.py @@ -83,7 +83,7 @@ 'Geometry/HcalCommonData/data/PhaseII/NoHE/hcalSimNumbering.xml', 'Geometry/HcalCommonData/data/PhaseII/NoHE/hcalRecNumbering.xml', 'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', - 'Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml', + 'Geometry/HGCalCommonData/data/v5/hgcal.xml', 'Geometry/HGCalCommonData/data/v5/hgcalEE.xml', 'Geometry/HGCalCommonData/data/v5/hgcalHEsil.xml', 'Geometry/HGCalCommonData/data/v5/hgcalHEsci.xml', diff --git a/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml b/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml deleted file mode 100644 index 7eb7d8bb548ae..0000000000000 --- a/Geometry/HGCalCommonData/data/v5/Pilot/hgcal.xml +++ /dev/null @@ -1,160 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From 94162bdbc2c8db3f15bdbcff89d558778d049ac8 Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Wed, 22 Oct 2014 18:33:35 +0200 Subject: [PATCH 220/252] Moved the tcMetWithPFclusters collection change from a custom to the default, since the sequence is changed in the detault not the custom --- RecoMET/Configuration/python/RecoTCMET_cff.py | 5 ++++- .../Configuration/python/combinedCustoms.py | 3 --- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/RecoMET/Configuration/python/RecoTCMET_cff.py b/RecoMET/Configuration/python/RecoTCMET_cff.py index cdb63a6f64b8c..e48b12246a9d0 100644 --- a/RecoMET/Configuration/python/RecoTCMET_cff.py +++ b/RecoMET/Configuration/python/RecoTCMET_cff.py @@ -2,7 +2,10 @@ from RecoMET.METProducers.TCMET_cfi import * -tcMetWithPFclusters = tcMet.clone() +tcMetWithPFclusters = tcMet.clone( + PFClustersHFEM = cms.InputTag('particleFlowClusterHF'), + PFClustersHFHAD = cms.InputTag('particleFlowClusterHF') + ) tcMetWithPFclusters.usePFClusters = cms.bool(True) diff --git a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py index c137e24187738..e6fbf5f14f953 100644 --- a/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/combinedCustoms.py @@ -163,9 +163,6 @@ def cust_2023SHCal(process): process.pfClusteringECAL += process.particleFlowClusterECAL #process.particleFlowCluster += process.pfClusteringEK - process.tcMetWithPFclusters.PFClustersHFEM = cms.InputTag('particleFlowClusterHF') - process.tcMetWithPFclusters.PFClustersHFHAD = cms.InputTag('particleFlowClusterHF') - #clone photons to mustache photons so we can compare back to old reco process.mustachePhotonCore = process.photonCore.clone(scHybridBarrelProducer = cms.InputTag("particleFlowSuperClusterECAL","particleFlowSuperClusterECALBarrel"),scIslandEndcapProducer = cms.InputTag("particleFlowSuperClusterECAL","particleFlowSuperClusterECALEndcapWithPreshower")) process.mustachePhotons = process.photons.clone(photonCoreProducer = cms.InputTag('mustachePhotonCore'), endcapEcalHits = cms.InputTag("ecalRecHit","EcalRecHitsEK")) From 0000d2962654d60d0fd07aace7ffd5ad3d7e17d3 Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Thu, 23 Oct 2014 18:10:56 +0200 Subject: [PATCH 221/252] Change the default collection to non-upgrade, since Phase1 and Phase2 have this changed in the customisation --- .../PFClusterProducer/python/particleFlowRecHitHF_cfi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHF_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHF_cfi.py index 76357dae9a50a..1e71428ff2e36 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHF_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowRecHitHF_cfi.py @@ -13,7 +13,7 @@ producers = cms.VPSet( cms.PSet( name = cms.string("PFHFRecHitCreator"), - src = cms.InputTag("hfUpgradeReco",""), + src = cms.InputTag("hfreco",""), EMDepthCorrection = cms.double(22.), HADDepthCorrection = cms.double(25.), thresh_HF = cms.double(0.4), From 9eb45ad1edf31dff45470508c49378c0e9910682 Mon Sep 17 00:00:00 2001 From: Roumyana Date: Sat, 25 Oct 2014 17:31:12 +0200 Subject: [PATCH 222/252] Improved GEM cls model, bkg at high lumi, efficiecny for electron, neg strip fix --- .../GEMDigitizer/interface/GEMSimpleModel.h | 73 ++-- .../interface/ME0PreRecoGaussianModel.h | 26 +- .../GEMDigitizer/python/muonGEMDigis_cfi.py | 26 +- .../python/muonME0DigisPreReco_cfi.py | 14 +- SimMuon/GEMDigitizer/src/GEMSimpleModel.cc | 395 +++++++----------- .../src/ME0PreRecoGaussianModel.cc | 180 ++++---- 6 files changed, 288 insertions(+), 426 deletions(-) diff --git a/SimMuon/GEMDigitizer/interface/GEMSimpleModel.h b/SimMuon/GEMDigitizer/interface/GEMSimpleModel.h index 59a53c7980bab..a937ffccd13e1 100644 --- a/SimMuon/GEMDigitizer/interface/GEMSimpleModel.h +++ b/SimMuon/GEMDigitizer/interface/GEMSimpleModel.h @@ -1,7 +1,6 @@ #ifndef GEMDigitizer_GEMSimpleModel_h #define GEMDigitizer_GEMSimpleModel_h - -/** +/** * \class GEMSimpleModel * * Class for the GEM strip response simulation based on a very simple model @@ -9,50 +8,35 @@ * \author Sven Dildick * \modified by Roumyana Hadjiiska */ - #include "SimMuon/GEMDigitizer/interface/GEMDigiModel.h" - class GEMGeometry; - namespace CLHEP { class HepRandomEngine; class RandFlat; class RandPoissonQ; class RandGaussQ; - class RandGamma; + class RandBinomial; } - class GEMSimpleModel: public GEMDigiModel { public: - GEMSimpleModel(const edm::ParameterSet&); - ~GEMSimpleModel(); - void setRandomEngine(CLHEP::HepRandomEngine&); - void setup(); - void simulateSignal(const GEMEtaPartition*, const edm::PSimHitContainer&); - int getSimHitBx(const PSimHit*); - void simulateNoise(const GEMEtaPartition*); - - std::vector > - simulateClustering(const GEMEtaPartition*, const PSimHit*, const int); - + std::vector > + simulateClustering(const GEMEtaPartition*, const PSimHit*, const int); private: - double averageEfficiency_; double averageShapingTime_; double timeResolution_; double timeJitter_; double averageNoiseRate_; -// double averageClusterSize_; - std::vector clsParametrization_; +// std::vector clsParametrization_; double signalPropagationSpeed_; bool cosmics_; int bxwidth_; @@ -62,28 +46,49 @@ class GEMSimpleModel: public GEMDigiModel bool doBkgNoise_; bool doNoiseCLS_; bool fixedRollRadius_; - double minPabsNoiseCLS_; bool simulateIntrinsicNoise_; - double scaleLumi_; bool simulateElectronBkg_; - double constNeuGE11_; - double slopeNeuGE11_; - std::vector GE21NeuBkgParams_; - std::vector GE11ElecBkgParams_; - std::vector GE21ElecBkgParams_; - + bool simulateLowNeutralRate_; CLHEP::RandFlat* flat1_; CLHEP::RandFlat* flat2_; CLHEP::RandFlat* flat3_; CLHEP::RandFlat* flat4_; + CLHEP::RandFlat* flat5_; CLHEP::RandPoissonQ* poisson_; CLHEP::RandGaussQ* gauss1_; CLHEP::RandGaussQ* gauss2_; - CLHEP::RandGamma* gamma1_; - +//parameters from the fit: +//params for pol3 model of electron bkg for GE1/1: + double GE11ElecBkgParam0; + double GE11ElecBkgParam1; + double GE11ElecBkgParam2; + double GE11ElecBkgParam3; +//params for expo of electron bkg for GE2/1: + double constElecGE21; + double slopeElecGE21; +//Neutral Bkg +//Low Rate model L=10^{34}cm^{-2}s^{-1} +//const and slope for expo model of neutral bkg for GE1/1: + double constNeuGE11; + double slopeNeuGE11; +//params for pol5 model of neutral bkg for GE2/1: + double GE21NeuBkgParam0; + double GE21NeuBkgParam1; + double GE21NeuBkgParam2; + double GE21NeuBkgParam3; + double GE21NeuBkgParam4; + double GE21NeuBkgParam5; +//High Rate model L=5x10^{34}cm^{-2}s^{-1} +//params for expo model of neutral bkg for GE1/1: + double constNeuGE11_highRate; + double slopeNeuGE11_highRate; +//params for pol5 model of neutral bkg for GE2/1: + double GE21ModNeuBkgParam0; + double GE21ModNeuBkgParam1; + double GE21ModNeuBkgParam2; + double GE21ModNeuBkgParam3; + double GE21ModNeuBkgParam4; + double GE21ModNeuBkgParam5; }; #endif - - - diff --git a/SimMuon/GEMDigitizer/interface/ME0PreRecoGaussianModel.h b/SimMuon/GEMDigitizer/interface/ME0PreRecoGaussianModel.h index 400dce4b21068..fe215fc52c1c6 100644 --- a/SimMuon/GEMDigitizer/interface/ME0PreRecoGaussianModel.h +++ b/SimMuon/GEMDigitizer/interface/ME0PreRecoGaussianModel.h @@ -1,14 +1,11 @@ #ifndef GEMDigitizer_ME0PreRecoGaussianModel_h #define GEMDigitizer_ME0PreRecoGaussianModel_h - /** * \class ME0PreRecoGaussianModel * - * Class for the ME0 Gaussian response simulation as pre-reco step + * Class for the ME0 Gaussian response simulation as pre-reco step */ - #include "SimMuon/GEMDigitizer/interface/ME0DigiPreRecoModel.h" - class ME0Geometry; namespace CLHEP { @@ -17,23 +14,17 @@ namespace CLHEP class RandGaussQ; class RandPoissonQ; } - class ME0PreRecoGaussianModel: public ME0DigiPreRecoModel { public: - ME0PreRecoGaussianModel(const edm::ParameterSet&); - ~ME0PreRecoGaussianModel(); - void simulateSignal(const ME0EtaPartition*, const edm::PSimHitContainer&); - void setRandomEngine(CLHEP::HepRandomEngine&); - void simulateNoise(const ME0EtaPartition*); - - void setup() {} - + void setup() + { + } private: double sigma_t; double sigma_u; @@ -43,20 +34,16 @@ class ME0PreRecoGaussianModel: public ME0DigiPreRecoModel bool digitizeOnlyMuons_; double averageEfficiency_; bool doBkgNoise_; - bool simulateIntrinsicNoise_; +// bool simulateIntrinsicNoise_; bool simulateElectronBkg_; - double averageNoiseRate_; int bxwidth_; int minBunch_; int maxBunch_; - - CLHEP::RandGaussQ* gauss_; CLHEP::RandFlat* flat1_; CLHEP::RandFlat* flat2_; CLHEP::RandFlat* poisson_; - //params for the simple pol6 model of neutral bkg for ME0: double ME0ModNeuBkgParam0; double ME0ModNeuBkgParam1; @@ -65,7 +52,6 @@ class ME0PreRecoGaussianModel: public ME0DigiPreRecoModel double ME0ModNeuBkgParam4; double ME0ModNeuBkgParam5; double ME0ModNeuBkgParam6; - double ME0ModElecBkgParam0; double ME0ModElecBkgParam1; double ME0ModElecBkgParam2; @@ -74,6 +60,6 @@ class ME0PreRecoGaussianModel: public ME0DigiPreRecoModel double ME0ModElecBkgParam5; double ME0ModElecBkgParam6; double ME0ModElecBkgParam7; - }; #endif + diff --git a/SimMuon/GEMDigitizer/python/muonGEMDigis_cfi.py b/SimMuon/GEMDigitizer/python/muonGEMDigis_cfi.py index 55bfd5b624dab..76731662ed9bb 100644 --- a/SimMuon/GEMDigitizer/python/muonGEMDigis_cfi.py +++ b/SimMuon/GEMDigitizer/python/muonGEMDigis_cfi.py @@ -1,5 +1,4 @@ import FWCore.ParameterSet.Config as cms - # Module to create simulated GEM digis. simMuonGEMDigis = cms.EDProducer("GEMDigiProducer", signalPropagationSpeed = cms.double(0.66), @@ -7,11 +6,7 @@ timeResolution = cms.double(5), timeJitter = cms.double(1.0), averageShapingTime = cms.double(50.0), -# averageClusterSize = cms.double(1.5),#1.5 -#cumulative cls distribution at 771 mkA; experimental results from test pion beam - clsParametrization = cms.vdouble(0.455091, 0.865613, 0.945891, 0.973286, 0.986234, 0.991686, 0.996865, 0.998501, 1.), -#cumulative cls distribution at 752 mkA; experimental results from test pion beam -# clsParametrization = cms.vdouble(0.663634, 0.928571, 0.967544, 0.982665, 0.990288, 0.994222, 0.997541, 0.999016, 1.), +# clsParametrization = cms.vdouble(0.455091, 0.865613, 0.945891, 0.973286, 0.986234, 0.991686, 0.996865, 0.998501, 1.), averageEfficiency = cms.double(0.98), averageNoiseRate = cms.double(0.001), #intrinsic noise bxwidth = cms.int32(25), @@ -19,24 +14,11 @@ maxBunch = cms.int32(3), inputCollection = cms.string('g4SimHitsMuonGEMHits'), digiModelString = cms.string('Simple'), - digitizeOnlyMuons = cms.bool(True), + digitizeOnlyMuons = cms.bool(False), doBkgNoise = cms.bool(True), #False == No background simulation doNoiseCLS = cms.bool(True), fixedRollRadius = cms.bool(True), #Uses fixed radius in the center of the roll - minPabsNoiseCLS = cms.double(0.), simulateIntrinsicNoise = cms.bool(False), - scaleLumi = cms.double(1.), -#Parameters for background model - simulateElectronBkg = cms.bool(False), #False=simulate only neutral Bkg -#const and slope for the expo model of neutral bkg for GE1/1: - constNeuGE11 = cms.double(807.1), - slopeNeuGE11 = cms.double(-0.01443), -#params for the simple pol5 model of neutral bkg for GE2/1: - GE21NeuBkgParams = cms.vdouble(2954.04, -58.7558, 0.473481, -0.00188292, 3.67041e-06, -2.80261e-09), -#params for the simple pol3 model of electron bkg for GE1/1: - GE11ElecBkgParams = cms.vdouble(2135.93, -33.1251, 0.177738, -0.000319334), -#params for the simple pol6 model of electron bkg for GE2/1: - GE21ElecBkgParams = cms.vdouble(-43642.2, 1335.98, -16.476, 0.105281, -0.000368758, 6.72937e-07, -5.00872e-10) - + simulateElectronBkg = cms.bool(True), #False=simulate only neutral Bkg + simulateLowNeutralRate = cms.bool(False) #True=neutral_Bkg at L=1x10^{34}, False at L=5x10^{34}cm^{-2}s^{-1} ) - diff --git a/SimMuon/GEMDigitizer/python/muonME0DigisPreReco_cfi.py b/SimMuon/GEMDigitizer/python/muonME0DigisPreReco_cfi.py index 8cccef0309a1f..7204ef83a3c68 100644 --- a/SimMuon/GEMDigitizer/python/muonME0DigisPreReco_cfi.py +++ b/SimMuon/GEMDigitizer/python/muonME0DigisPreReco_cfi.py @@ -4,20 +4,18 @@ simMuonME0Digis = cms.EDProducer("ME0DigiPreRecoProducer", inputCollection = cms.string('g4SimHitsMuonME0Hits'), digiPreRecoModelString = cms.string('PreRecoGaussian'), - timeResolution = cms.double(0.001), # in ns + timeResolution = cms.double(0.001), # in ns phiResolution = cms.double(0.05), # in cm average resoltion along local x in case of no correlation etaResolution = cms.double(1.),# in cm average resoltion along local y in case of no correlation - useCorrelation = cms.bool(False), - useEtaProjectiveGEO = cms.bool(False), + useCorrelation = cms.bool(False), + useEtaProjectiveGEO = cms.bool(False), averageEfficiency = cms.double(0.98), - doBkgNoise = cms.bool(False), #False == No background simulation + doBkgNoise = cms.bool(True), #False == No background simulation digitizeOnlyMuons = cms.bool(False), - simulateIntrinsicNoise = cms.bool(False), - simulateElectronBkg = cms.bool(False), #True - will simulate electron background - +# simulateIntrinsicNoise = cms.bool(False), + simulateElectronBkg = cms.bool(True), #True - will simulate electron background averageNoiseRate = cms.double(0.001), #intrinsic noise bxwidth = cms.int32(25), minBunch = cms.int32(-5), ## in terms of 25 ns maxBunch = cms.int32(3) - ) diff --git a/SimMuon/GEMDigitizer/src/GEMSimpleModel.cc b/SimMuon/GEMDigitizer/src/GEMSimpleModel.cc index fdfc1e0975767..ba69505252f5f 100644 --- a/SimMuon/GEMDigitizer/src/GEMSimpleModel.cc +++ b/SimMuon/GEMDigitizer/src/GEMSimpleModel.cc @@ -1,61 +1,69 @@ #include "SimMuon/GEMDigitizer/interface/GEMSimpleModel.h" - #include "Geometry/GEMGeometry/interface/GEMEtaPartitionSpecs.h" #include "Geometry/CommonTopologies/interface/TrapezoidalStripTopology.h" #include "Geometry/GEMGeometry/interface/GEMGeometry.h" - #include "FWCore/Utilities/interface/RandomNumberGenerator.h" #include "FWCore/Utilities/interface/Exception.h" - #include "CLHEP/Random/RandomEngine.h" #include "CLHEP/Random/RandFlat.h" #include "CLHEP/Random/RandPoissonQ.h" #include "CLHEP/Random/RandGaussQ.h" -#include "CLHEP/Random/RandGamma.h" - #include #include #include - -#include "TMath.h" /* exp */ - - +#include "TMath.h" /* exp */ namespace { - // "magic" parameter for cosmics +// "magic" parameter for cosmics const double COSMIC_PAR(37.62); } - GEMSimpleModel::GEMSimpleModel(const edm::ParameterSet& config) : -GEMDigiModel(config) -, averageEfficiency_(config.getParameter ("averageEfficiency")) -, averageShapingTime_(config.getParameter ("averageShapingTime")) -, timeResolution_(config.getParameter ("timeResolution")) -, timeJitter_(config.getParameter ("timeJitter")) -, averageNoiseRate_(config.getParameter ("averageNoiseRate")) -//, averageClusterSize_(config.getParameter ("averageClusterSize")) -, clsParametrization_(config.getParameter>("clsParametrization")) -, signalPropagationSpeed_(config.getParameter ("signalPropagationSpeed")) -, cosmics_(config.getParameter ("cosmics")) -, bxwidth_(config.getParameter ("bxwidth")) -, minBunch_(config.getParameter ("minBunch")) -, maxBunch_(config.getParameter ("maxBunch")) -, digitizeOnlyMuons_(config.getParameter ("digitizeOnlyMuons")) -, doBkgNoise_(config.getParameter ("doBkgNoise")) -, doNoiseCLS_(config.getParameter ("doNoiseCLS")) -, fixedRollRadius_(config.getParameter ("fixedRollRadius")) -, scaleLumi_(config.getParameter ("scaleLumi")) -, simulateElectronBkg_(config.getParameter ("simulateElectronBkg")) -, constNeuGE11_(config.getParameter ("constNeuGE11")) -, slopeNeuGE11_(config.getParameter ("slopeNeuGE11")) -, GE21NeuBkgParams_(config.getParameter>("GE21NeuBkgParams")) -, GE11ElecBkgParams_(config.getParameter>("GE11ElecBkgParams")) -, GE21ElecBkgParams_(config.getParameter>("GE21ElecBkgParams")) - + GEMDigiModel(config), averageEfficiency_(config.getParameter("averageEfficiency")), averageShapingTime_( + config.getParameter("averageShapingTime")), timeResolution_( + config.getParameter("timeResolution")), timeJitter_(config.getParameter("timeJitter")), averageNoiseRate_( + config.getParameter("averageNoiseRate")) +//, clsParametrization_(config.getParameter>("clsParametrization")) + , signalPropagationSpeed_(config.getParameter("signalPropagationSpeed")), cosmics_( + config.getParameter("cosmics")), bxwidth_(config.getParameter("bxwidth")), minBunch_( + config.getParameter("minBunch")), maxBunch_(config.getParameter("maxBunch")), digitizeOnlyMuons_( + config.getParameter("digitizeOnlyMuons")), doBkgNoise_(config.getParameter("doBkgNoise")), doNoiseCLS_( + config.getParameter("doNoiseCLS")), fixedRollRadius_(config.getParameter("fixedRollRadius")), simulateElectronBkg_( + config.getParameter("simulateElectronBkg")), simulateLowNeutralRate_( + config.getParameter("simulateLowNeutralRate")) { - +//initialise parameters from the fit: +//params for pol3 model of electron bkg for GE1/1: + GE11ElecBkgParam0 = 3402.63; + GE11ElecBkgParam1 = -42.9979; + GE11ElecBkgParam2 = 0.188475; + GE11ElecBkgParam3 = -0.0002822; +//params for expo model of electron bkg for GE2/1: + constElecGE21 = 9.74156e+02; + slopeElecGE21 = -1.18398e-02; +//Neutral Bkg +//Low Rate model L=10^{34}cm^{-2}s^{-1} +//const and slope for the expo model of neutral bkg for GE1/1: + constNeuGE11 = 807.; + slopeNeuGE11 = -0.01443; +//params for the simple pol5 model of neutral bkg for GE2/1: + GE21NeuBkgParam0 = 2954.04; + GE21NeuBkgParam1 = -58.7558; + GE21NeuBkgParam2 = 0.473481; + GE21NeuBkgParam3 = -0.00188292; + GE21NeuBkgParam4 = 3.67041e-06; + GE21NeuBkgParam5 = -2.80261e-09; +//High Rate model L=5x10^{34}cm^{-2}s^{-1} +//params for expo model of neutral bkg for GE1/1: + constNeuGE11_highRate = 1.02603e+04; + slopeNeuGE11_highRate = -1.62806e-02; +//params for pol5 model of neutral bkg for GE2/1: + GE21ModNeuBkgParam0 = 21583.2; + GE21ModNeuBkgParam1 = -476.59; + GE21ModNeuBkgParam2 = 4.24037; + GE21ModNeuBkgParam3 = -0.0185558; + GE21ModNeuBkgParam4 = 3.97809e-05; + GE21ModNeuBkgParam5 = -3.34575e-08; } - GEMSimpleModel::~GEMSimpleModel() { if (flat1_) @@ -66,268 +74,228 @@ GEMSimpleModel::~GEMSimpleModel() delete flat3_; if (flat4_) delete flat4_; + if (flat5_) + delete flat5_; if (poisson_) delete poisson_; if (gauss1_) delete gauss1_; if (gauss2_) delete gauss2_; - if (gamma1_) - delete gamma1_; } - void GEMSimpleModel::setRandomEngine(CLHEP::HepRandomEngine& eng) { flat1_ = new CLHEP::RandFlat(eng); flat2_ = new CLHEP::RandFlat(eng); flat3_ = new CLHEP::RandFlat(eng); flat4_ = new CLHEP::RandFlat(eng); + flat5_ = new CLHEP::RandFlat(eng); poisson_ = new CLHEP::RandPoissonQ(eng); gauss1_ = new CLHEP::RandGaussQ(eng); gauss2_ = new CLHEP::RandGaussQ(eng); - gamma1_ = new CLHEP::RandGamma(eng); } - void GEMSimpleModel::setup() { return; } - void GEMSimpleModel::simulateSignal(const GEMEtaPartition* roll, const edm::PSimHitContainer& simHits) { stripDigiSimLinks_.clear(); detectorHitMap_.clear(); stripDigiSimLinks_ = StripDigiSimLinks(roll->id().rawId()); - + bool digiMuon = false; + bool digiElec = false; for (edm::PSimHitContainer::const_iterator hit = simHits.begin(); hit != simHits.end(); ++hit) { if (std::abs(hit->particleType()) != 13 && digitizeOnlyMuons_) continue; - - // Check GEM efficiency - if (flat1_->fire(1) > averageEfficiency_) +// Check GEM efficiency for muons and electrons + double elecEff = 0.; + double partMom = hit->pabs(); + double checkMuonEff = flat1_->fire(1); + double checkElecEff = flat5_->fire(1); + if (std::abs(hit->particleType()) == 13 && checkMuonEff < averageEfficiency_) + digiMuon = true; +// if (std::abs(hit->particleType()) == 11) + if (std::abs(hit->particleType()) != 13) //consider all non muon particles with gem efficiency to electrons + { + if (partMom <= 1.95e-03) + elecEff = 1.7e-05 * TMath::Exp(2.1 * partMom * 1000.); + if (partMom > 1.95e-03 && partMom < 10.e-03) + elecEff = 1.34 * log(7.96e-01 * partMom * 1000. - 5.75e-01) + / (1.34 + log(7.96e-01 * partMom * 1000. - 5.75e-01)); + if (partMom > 10.e-03) + elecEff = 1.; + if (checkElecEff < elecEff) + digiElec = true; + } +// if (flat1_->fire(1) > averageEfficiency_) + if (!(digiMuon || digiElec)) continue; const int bx(getSimHitBx(&(*hit))); const std::vector > cluster(simulateClustering(roll, &(*hit), bx)); - for (auto & digi : cluster) + for (auto & digi : cluster) { - detectorHitMap_.insert(DetectorHitMap::value_type(digi,&*(hit))); + detectorHitMap_.insert(DetectorHitMap::value_type(digi, &*(hit))); strips_.insert(digi); } } } - int GEMSimpleModel::getSimHitBx(const PSimHit* simhit) { int bx = -999; const LocalPoint simHitPos(simhit->localPosition()); const float tof(simhit->timeOfFlight()); - // random Gaussian time correction due to electronics jitter +// random Gaussian time correction due to electronics jitter const float randomJitterTime(gauss1_->fire(0., timeJitter_)); - const GEMDetId id(simhit->detUnitId()); const GEMEtaPartition* roll(geometry_->etaPartition(id)); - if (!roll) { - throw cms::Exception("Geometry")<< "GEMSimpleModel::getSimHitBx() - GEM simhit id does not match any GEM roll id: " << id << "\n"; + throw cms::Exception("Geometry") << "GEMSimpleModel::getSimHitBx() - GEM simhit id does not match any GEM roll id: " + << id << "\n"; return 999; } - if (roll->id().region() == 0) { - throw cms::Exception("Geometry") << "GEMSimpleModel::getSimHitBx() - this GEM id is from barrel, which cannot happen: " << roll->id() << "\n"; + throw cms::Exception("Geometry") + << "GEMSimpleModel::getSimHitBx() - this GEM id is from barrel, which cannot happen: " << roll->id() << "\n"; } - - // signal propagation speed in vacuum in [m/s] - const double cspeed = 299792458; +// signal propagation speed in vacuum in [m/s] + const double cspeed = 299792458; // const int nstrips = roll->nstrips(); - float middleStrip = nstrips/2.; + float middleStrip = nstrips / 2.; LocalPoint middleOfRoll = roll->centreOfStrip(middleStrip); GlobalPoint globMiddleRol = roll->toGlobal(middleOfRoll); - double muRadius = sqrt(globMiddleRol.x()*globMiddleRol.x() + globMiddleRol.y()*globMiddleRol.y() +globMiddleRol.z()*globMiddleRol.z()); - double timeCalibrationOffset_ = (muRadius *1e+9)/(cspeed*1e+2); //[ns] - - const TrapezoidalStripTopology* top(dynamic_cast (&(roll->topology()))); + double muRadius = sqrt( + globMiddleRol.x() * globMiddleRol.x() + globMiddleRol.y() * globMiddleRol.y() + + globMiddleRol.z() * globMiddleRol.z()); + double timeCalibrationOffset_ = (muRadius * 1e+9) / (cspeed * 1e+2); //[ns] + const TrapezoidalStripTopology* top(dynamic_cast(&(roll->topology()))); const float halfStripLength(0.5 * top->stripLength()); const float distanceFromEdge(halfStripLength - simHitPos.y()); - - // signal propagation speed in material in [cm/ns] +// signal propagation speed in material in [cm/ns] double signalPropagationSpeedTrue = signalPropagationSpeed_ * cspeed * 1e+2 * 1e-9; - - // average time for the signal to propagate from the SimHit to the top of a strip +// average time for the signal to propagate from the SimHit to the top of a strip const float averagePropagationTime(distanceFromEdge / signalPropagationSpeedTrue); - // random Gaussian time correction due to the finite timing resolution of the detector +// random Gaussian time correction due to the finite timing resolution of the detector const float randomResolutionTime(gauss2_->fire(0., timeResolution_)); - const float simhitTime(tof + averageShapingTime_ + randomResolutionTime + averagePropagationTime + randomJitterTime); - float referenceTime = 0.; referenceTime = timeCalibrationOffset_ + halfStripLength / signalPropagationSpeedTrue + averageShapingTime_; const float timeDifference(cosmics_ ? (simhitTime - referenceTime) / COSMIC_PAR : simhitTime - referenceTime); - - // assign the bunch crossing - bx = static_cast (std::round((timeDifference) / bxwidth_)); - - // check time +// assign the bunch crossing + bx = static_cast(std::round((timeDifference) / bxwidth_)); +// check time const bool debug(false); if (debug) { - std::cout << "checktime " << "bx = " << bx << "\tdeltaT = " << timeDifference << "\tsimT = " << simhitTime - << "\trefT = " << referenceTime << "\ttof = " << tof << "\tavePropT = " << averagePropagationTime + std::cout << "checktime " << "bx = " << bx << "\tdeltaT = " << timeDifference << "\tsimT = " << simhitTime + << "\trefT = " << referenceTime << "\ttof = " << tof << "\tavePropT = " << averagePropagationTime << "\taveRefPropT = " << halfStripLength / signalPropagationSpeedTrue << std::endl; } return bx; } - void GEMSimpleModel::simulateNoise(const GEMEtaPartition* roll) { if (!doBkgNoise_) - return; - + return; const GEMDetId gemId(roll->id()); const int nstrips(roll->nstrips()); double trArea(0.0); double trStripArea(0.0); - if (gemId.region() == 0) { throw cms::Exception("Geometry") << "GEMSynchronizer::simulateNoise() - this GEM id is from barrel, which cannot happen."; } - const TrapezoidalStripTopology* top_(dynamic_cast (&(roll->topology()))); + const TrapezoidalStripTopology* top_(dynamic_cast(&(roll->topology()))); const float striplength(top_->stripLength()); trStripArea = (roll->pitch()) * striplength; trArea = trStripArea * nstrips; const int nBxing(maxBunch_ - minBunch_ + 1); - float rollRadius = 0; - if(fixedRollRadius_) + if (fixedRollRadius_) { rollRadius = top_->radius(); } else { - double varRad = flat3_->fire(-1.*top_->stripLength()/2., top_->stripLength()/2.); + double varRad = flat3_->fire(-1. * top_->stripLength() / 2., top_->stripLength() / 2.); rollRadius = top_->radius() + varRad; } - //calculate noise from model double averageNeutralNoiseRatePerRoll = 0.; double averageNoiseElectronRatePerRoll = 0.; double averageNoiseRatePerRoll = 0.; - - if(gemId.station() == 1) + if (gemId.station() == 1) { //simulate neutral background for GE1/1 - averageNeutralNoiseRatePerRoll = constNeuGE11_ * TMath::Exp(slopeNeuGE11_*rollRadius); - -//simulate eletron background for GE1/1 -//the product is faster than Power or pow: - if(simulateElectronBkg_) - averageNoiseElectronRatePerRoll = GE11ElecBkgParams_[0] - + GE11ElecBkgParams_[1]*rollRadius - + GE11ElecBkgParams_[2]*rollRadius*rollRadius - + GE11ElecBkgParams_[3]*rollRadius*rollRadius*rollRadius; - + if (simulateLowNeutralRate_) + averageNeutralNoiseRatePerRoll = constNeuGE11 * TMath::Exp(slopeNeuGE11 * rollRadius); + else + averageNeutralNoiseRatePerRoll = constNeuGE11_highRate * TMath::Exp(slopeNeuGE11_highRate * rollRadius); +//simulate electron background for GE1/1 + if (simulateElectronBkg_) + averageNoiseElectronRatePerRoll = GE11ElecBkgParam0 + GE11ElecBkgParam1 * rollRadius + + GE11ElecBkgParam2 * rollRadius * rollRadius + GE11ElecBkgParam3 * rollRadius * rollRadius * rollRadius; averageNoiseRatePerRoll = averageNeutralNoiseRatePerRoll + averageNoiseElectronRatePerRoll; } - - if(gemId.station() == 2 || gemId.station() == 3) + if (gemId.station() == 2 || gemId.station() == 3) { //simulate neutral background for GE2/1 - averageNeutralNoiseRatePerRoll = GE21NeuBkgParams_[0] - + GE21NeuBkgParams_[1]*rollRadius - + GE21NeuBkgParams_[2]*rollRadius*rollRadius - + GE21NeuBkgParams_[3]*rollRadius*rollRadius*rollRadius - + GE21NeuBkgParams_[4]*rollRadius*rollRadius*rollRadius*rollRadius - + GE21NeuBkgParams_[5]*rollRadius*rollRadius*rollRadius*rollRadius*rollRadius; - - -//simulate eletron background for GE2/1 - if(simulateElectronBkg_) - averageNoiseElectronRatePerRoll = GE21ElecBkgParams_[0] - + GE21ElecBkgParams_[1]*rollRadius - + GE21ElecBkgParams_[2]*rollRadius*rollRadius - + GE21ElecBkgParams_[3]*rollRadius*rollRadius*rollRadius - + GE21ElecBkgParams_[4]*rollRadius*rollRadius*rollRadius*rollRadius - + GE21ElecBkgParams_[5]*rollRadius*rollRadius*rollRadius*rollRadius*rollRadius - + GE21ElecBkgParams_[6]*rollRadius*rollRadius*rollRadius*rollRadius*rollRadius*rollRadius; - + if (simulateLowNeutralRate_) + averageNeutralNoiseRatePerRoll = GE21NeuBkgParam0 + GE21NeuBkgParam1 * rollRadius + + GE21NeuBkgParam2 * rollRadius * rollRadius + GE21NeuBkgParam3 * rollRadius * rollRadius * rollRadius + + GE21NeuBkgParam4 * rollRadius * rollRadius * rollRadius * rollRadius + + GE21NeuBkgParam5 * rollRadius * rollRadius * rollRadius * rollRadius * rollRadius; + else + averageNeutralNoiseRatePerRoll = GE21ModNeuBkgParam0 + GE21ModNeuBkgParam1 * rollRadius + + GE21ModNeuBkgParam2 * rollRadius * rollRadius + GE21ModNeuBkgParam3 * rollRadius * rollRadius * rollRadius + + GE21ModNeuBkgParam4 * rollRadius * rollRadius * rollRadius * rollRadius + + GE21ModNeuBkgParam5 * rollRadius * rollRadius * rollRadius * rollRadius * rollRadius; +//simulate electron background for GE2/1 + if (simulateElectronBkg_) + averageNoiseElectronRatePerRoll = constElecGE21 * TMath::Exp(slopeElecGE21 * rollRadius); averageNoiseRatePerRoll = averageNeutralNoiseRatePerRoll + averageNoiseElectronRatePerRoll; } - - //simulate intrinsic noise - if(simulateIntrinsicNoise_) +//simulate intrinsic noise + if (simulateIntrinsicNoise_) { double aveIntrinsicNoisPerStrip = averageNoiseRate_ * nBxing * bxwidth_ * trStripArea * 1.0e-9; - for(int j = 0; j < nstrips; ++j) + for (int j = 0; j < nstrips; ++j) { const int n_intrHits = poisson_->fire(aveIntrinsicNoisPerStrip); - - for (int k = 0; k < n_intrHits; k++ ) + for (int k = 0; k < n_intrHits; k++) { - const int time_hit(static_cast (flat2_->fire(nBxing)) + minBunch_); - std::pair digi(k+1,time_hit); + const int time_hit(static_cast(flat2_->fire(nBxing)) + minBunch_); + std::pair digi(k + 1, time_hit); strips_.insert(digi); } } - }//end simulate intrinsic noise - - //simulate bkg contribution - const double averageNoise(averageNoiseRatePerRoll * nBxing * bxwidth_ * trArea * 1.0e-9 * scaleLumi_); + } //end simulate intrinsic noise +//simulate bkg contribution + const double averageNoise(averageNoiseRatePerRoll * nBxing * bxwidth_ * trArea * 1.0e-9); const int n_hits(poisson_->fire(averageNoise)); - for (int i = 0; i < n_hits; ++i) { - const int centralStrip(static_cast (flat1_->fire(1, nstrips))); - const int time_hit(static_cast (flat2_->fire(nBxing)) + minBunch_); - + const int centralStrip(static_cast(flat1_->fire(1, nstrips))); + const int time_hit(static_cast(flat2_->fire(nBxing)) + minBunch_); if (doNoiseCLS_) { - std::vector > cluster_; + std::vector < std::pair > cluster_; cluster_.clear(); cluster_.push_back(std::pair(centralStrip, time_hit)); - int clusterSize = 0; double randForCls = flat4_->fire(1); - - if(randForCls <= clsParametrization_[0] && randForCls >= 0.) + if (randForCls <= 0.53 && randForCls >= 0.) clusterSize = 1; - else if(randForCls <= clsParametrization_[1] && randForCls > clsParametrization_[0]) + else clusterSize = 2; - else if(randForCls <= clsParametrization_[2] && randForCls > clsParametrization_[1]) - clusterSize = 3; - else if(randForCls <= clsParametrization_[3] && randForCls > clsParametrization_[2]) - clusterSize = 4; - else if(randForCls <= clsParametrization_[4] && randForCls > clsParametrization_[3]) - clusterSize = 5; - else if(randForCls <= clsParametrization_[5] && randForCls > clsParametrization_[4]) - clusterSize = 6; - else if(randForCls <= clsParametrization_[6] && randForCls > clsParametrization_[5]) - clusterSize = 7; - else if(randForCls <= clsParametrization_[7] && randForCls > clsParametrization_[6]) - clusterSize = 8; - else if(randForCls <= clsParametrization_[8] && randForCls > clsParametrization_[7]) - clusterSize = 9; - - //odd cls - if (clusterSize % 2 != 0) - { - int clsR = (clusterSize - 1) / 2; - for (int i = 1; i <= clsR; ++i) - { - if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - i > 0)) - cluster_.push_back(std::pair(centralStrip - i, time_hit)); - if (flat1_->fire(1) < averageEfficiency_ && (centralStrip + i <= nstrips)) - cluster_.push_back(std::pair(centralStrip + i, time_hit)); - } - } - //even cls if (clusterSize % 2 == 0) { int clsR = (clusterSize - 2) / 2; - if(flat3_->fire(1) < 0.5) + if (flat3_->fire(1) < 0.5) { if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - 1 > 0)) cluster_.push_back(std::pair(centralStrip - 1, time_hit)); @@ -339,25 +307,24 @@ void GEMSimpleModel::simulateNoise(const GEMEtaPartition* roll) cluster_.push_back(std::pair(centralStrip + i, time_hit)); } } - else { - if (flat1_->fire(1) < averageEfficiency_ && (centralStrip + 1 <= nstrips)) - cluster_.push_back(std::pair(centralStrip + 1, time_hit)); + if (flat1_->fire(1) < averageEfficiency_ && (centralStrip + 1 <= nstrips)) + cluster_.push_back(std::pair(centralStrip + 1, time_hit)); for (int i = 1; i <= clsR; ++i) { if (flat1_->fire(1) < averageEfficiency_ && (centralStrip + 1 + i <= nstrips)) - cluster_.push_back(std::pair(centralStrip + 1 + i, time_hit)); - if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - i < 0)) - cluster_.push_back(std::pair(centralStrip - i, time_hit)); + cluster_.push_back(std::pair(centralStrip + 1 + i, time_hit)); + if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - i > 0)) + cluster_.push_back(std::pair(centralStrip - i, time_hit)); } } } - for(auto & digi : cluster_) + for (auto & digi : cluster_) { strips_.insert(digi); } - }//end doNoiseCLS_ + } //end doNoiseCLS_ else { std::pair digi(centralStrip, time_hit); @@ -366,74 +333,36 @@ void GEMSimpleModel::simulateNoise(const GEMEtaPartition* roll) } return; } - -std::vector > GEMSimpleModel::simulateClustering(const GEMEtaPartition* roll, - const PSimHit* simHit, const int bx) +std::vector > GEMSimpleModel::simulateClustering(const GEMEtaPartition* roll, const PSimHit* simHit, + const int bx) { - // const Topology& topology(roll->specs()->topology()); - const StripTopology& topology = roll->specificTopology(); - // const LocalPoint& entry(simHit->entryPoint()); + const StripTopology& topology = roll->specificTopology(); // const LocalPoint& entry(simHit->entryPoint()); const LocalPoint& hit_position(simHit->localPosition()); const int nstrips(roll->nstrips()); - int centralStrip = 0; if (!(topology.channel(hit_position) + 1 > nstrips)) centralStrip = topology.channel(hit_position) + 1; else centralStrip = topology.channel(hit_position); - GlobalPoint pointSimHit = roll->toGlobal(hit_position); GlobalPoint pointDigiHit = roll->toGlobal(roll->centreOfStrip(centralStrip)); - double deltaphi = pointSimHit.phi() - pointDigiHit.phi(); - - // Add central digi to cluster vector - std::vector > cluster_; + double deltaX = pointSimHit.x() - pointDigiHit.x(); +// Add central digi to cluster vector + std::vector < std::pair > cluster_; cluster_.clear(); cluster_.push_back(std::pair(centralStrip, bx)); - - // get the cluster size - int clusterSize = 0; - double randForCls = flat4_->fire(1); - - if(randForCls <= clsParametrization_[0] && randForCls >= 0.) - clusterSize = 1; - else if(randForCls <= clsParametrization_[1] && randForCls > clsParametrization_[0]) - clusterSize = 2; - else if(randForCls <= clsParametrization_[2] && randForCls > clsParametrization_[1]) - clusterSize = 3; - else if(randForCls <= clsParametrization_[3] && randForCls > clsParametrization_[2]) - clusterSize = 4; - else if(randForCls <= clsParametrization_[4] && randForCls > clsParametrization_[3]) - clusterSize = 5; - else if(randForCls <= clsParametrization_[5] && randForCls > clsParametrization_[4]) - clusterSize = 6; - else if(randForCls <= clsParametrization_[6] && randForCls > clsParametrization_[5]) - clusterSize = 7; - else if(randForCls <= clsParametrization_[7] && randForCls > clsParametrization_[6]) - clusterSize = 8; - else if(randForCls <= clsParametrization_[8] && randForCls > clsParametrization_[7]) - clusterSize = 9; - - if (abs(simHit->particleType()) != 13 && fabs(simHit->pabs()) < minPabsNoiseCLS_) - return cluster_; - - //odd cls - if (clusterSize % 2 != 0) - { - int clsR = (clusterSize - 1) / 2; - for (int i = 1; i <= clsR; ++i) - { - if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - i > 0)) - cluster_.push_back(std::pair(centralStrip - i, bx)); - if (flat1_->fire(1) < averageEfficiency_ && (centralStrip + i <= nstrips)) - cluster_.push_back(std::pair(centralStrip + i, bx)); - } - } - //even cls +//simulate cross talk + int clusterSize = 0; + double randForCls = flat4_->fire(1); + if (randForCls <= 0.525 && randForCls >= 0.) + clusterSize = 1; + else + clusterSize = 2; +//even cls (2) if (clusterSize % 2 == 0) { int clsR = (clusterSize - 2) / 2; - if (deltaphi <= 0) + if (deltaX <= 0) { if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - 1 > 0)) cluster_.push_back(std::pair(centralStrip - 1, bx)); @@ -453,13 +382,11 @@ std::vector > GEMSimpleModel::simulateClustering(const GEMEt { if (flat1_->fire(1) < averageEfficiency_ && (centralStrip + 1 + i <= nstrips)) cluster_.push_back(std::pair(centralStrip + 1 + i, bx)); - if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - i < 0)) + if (flat1_->fire(1) < averageEfficiency_ && (centralStrip - i > 0)) cluster_.push_back(std::pair(centralStrip - i, bx)); } } } return cluster_; - } - diff --git a/SimMuon/GEMDigitizer/src/ME0PreRecoGaussianModel.cc b/SimMuon/GEMDigitizer/src/ME0PreRecoGaussianModel.cc index bb68629de5629..5959e97775068 100644 --- a/SimMuon/GEMDigitizer/src/ME0PreRecoGaussianModel.cc +++ b/SimMuon/GEMDigitizer/src/ME0PreRecoGaussianModel.cc @@ -8,48 +8,36 @@ #include "CLHEP/Random/RandFlat.h" #include "CLHEP/Random/RandGaussQ.h" #include "CLHEP/Random/RandPoissonQ.h" - #include #include #include - ME0PreRecoGaussianModel::ME0PreRecoGaussianModel(const edm::ParameterSet& config) : - ME0DigiPreRecoModel(config) -, sigma_t(config.getParameter ("timeResolution")) -, sigma_u(config.getParameter ("phiResolution")) -, sigma_v(config.getParameter ("etaResolution")) -, corr(config.getParameter ("useCorrelation")) -, etaproj(config.getParameter ("useEtaProjectiveGEO")) -, digitizeOnlyMuons_(config.getParameter ("digitizeOnlyMuons")) -, averageEfficiency_(config.getParameter ("averageEfficiency")) -, doBkgNoise_(config.getParameter ("doBkgNoise")) -, simulateIntrinsicNoise_(config.getParameter ("simulateIntrinsicNoise")) -, simulateElectronBkg_(config.getParameter("simulateElectronBkg")) -, averageNoiseRate_(config.getParameter ("averageNoiseRate")) -, bxwidth_(config.getParameter ("bxwidth")) -, minBunch_(config.getParameter ("minBunch")) -, maxBunch_(config.getParameter ("maxBunch")) - + ME0DigiPreRecoModel(config), sigma_t(config.getParameter("timeResolution")), sigma_u( + config.getParameter("phiResolution")), sigma_v(config.getParameter("etaResolution")), corr( + config.getParameter("useCorrelation")), etaproj(config.getParameter("useEtaProjectiveGEO")), digitizeOnlyMuons_( + config.getParameter("digitizeOnlyMuons")), averageEfficiency_( + config.getParameter("averageEfficiency")), doBkgNoise_(config.getParameter("doBkgNoise")) +//, simulateIntrinsicNoise_(config.getParameter("simulateIntrinsicNoise")) + , simulateElectronBkg_(config.getParameter("simulateElectronBkg")), averageNoiseRate_( + config.getParameter("averageNoiseRate")), bxwidth_(config.getParameter("bxwidth")), minBunch_( + config.getParameter("minBunch")), maxBunch_(config.getParameter("maxBunch")) { - //params for the simple pol6 model of neutral and electron bkg for ME0: - ME0ModNeuBkgParam0 = 5.69e+06; - ME0ModNeuBkgParam1 = -293334; - ME0ModNeuBkgParam2 = 6279.6; - ME0ModNeuBkgParam3 = -71.2928; - ME0ModNeuBkgParam4 = 0.452244; - ME0ModNeuBkgParam5 = -0.0015191; - ME0ModNeuBkgParam6 = 2.1106e-06; - - ME0ModElecBkgParam0 = 3.77712e+06; - ME0ModElecBkgParam1 = -199280; - ME0ModElecBkgParam2 = 4340.69; - ME0ModElecBkgParam3 = -49.922; - ME0ModElecBkgParam4 = 0.319699; - ME0ModElecBkgParam5 = -0.00108113; - ME0ModElecBkgParam6 = 1.50889e-06; - +//params for the simple pol6 model of neutral and electron bkg for ME0: + ME0ModNeuBkgParam0 = 899644; + ME0ModNeuBkgParam1 = -30841; + ME0ModNeuBkgParam2 = 441.28; + ME0ModNeuBkgParam3 = -3.3405; + ME0ModNeuBkgParam4 = 0.0140588; + ME0ModNeuBkgParam5 = -3.11473e-05; + ME0ModNeuBkgParam6 = 2.83736e-08; + ME0ModElecBkgParam0 = 4.68590e+05; + ME0ModElecBkgParam1 = -1.63834e+04; + ME0ModElecBkgParam2 = 2.35700e+02; + ME0ModElecBkgParam3 = -1.77706e+00; + ME0ModElecBkgParam4 = 7.39960e-03; + ME0ModElecBkgParam5 = -1.61448e-05; + ME0ModElecBkgParam6 = 1.44368e-08; } - ME0PreRecoGaussianModel::~ME0PreRecoGaussianModel() { if (flat1_) @@ -61,7 +49,6 @@ ME0PreRecoGaussianModel::~ME0PreRecoGaussianModel() if (poisson_) delete poisson_; } - void ME0PreRecoGaussianModel::setRandomEngine(CLHEP::HepRandomEngine& eng) { flat1_ = new CLHEP::RandFlat(eng); @@ -69,43 +56,40 @@ void ME0PreRecoGaussianModel::setRandomEngine(CLHEP::HepRandomEngine& eng) gauss_ = new CLHEP::RandGaussQ(eng); poisson_ = new CLHEP::RandFlat(eng); } - void ME0PreRecoGaussianModel::simulateSignal(const ME0EtaPartition* roll, const edm::PSimHitContainer& simHits) { -for (const auto & hit: simHits) -{ - if (std::abs(hit.particleType()) != 13 && digitizeOnlyMuons_) continue; - // GEM efficiency - if (flat1_->fire(1) > averageEfficiency_) continue; - - auto entry = hit.entryPoint(); - float x=gauss_->fire(entry.x(),sigma_u); - float y=gauss_->fire(entry.y(),sigma_v); - float ex=sigma_u; - float ey=sigma_v; - float corr=0.; - float tof=gauss_->fire(hit.timeOfFlight(),sigma_t); - int pdgid = hit.particleType(); - // please keep hit time always 0 for this model - ME0DigiPreReco digi(x,y,ex,ey,corr,tof,pdgid); - digi_.insert(digi); -} + for (const auto & hit : simHits) + { + if (std::abs(hit.particleType()) != 13 && digitizeOnlyMuons_) + continue; +// GEM efficiency + if (flat1_->fire(1) > averageEfficiency_) + continue; + auto entry = hit.entryPoint(); + float x = gauss_->fire(entry.x(), sigma_u); + float y = gauss_->fire(entry.y(), sigma_v); + float ex = sigma_u; + float ey = sigma_v; + float corr = 0.; + float tof = gauss_->fire(hit.timeOfFlight(), sigma_t); + int pdgid = hit.particleType(); +// please keep hit time always 0 for this model + ME0DigiPreReco digi(x, y, ex, ey, corr, tof, pdgid); + digi_.insert(digi); + } } - void ME0PreRecoGaussianModel::simulateNoise(const ME0EtaPartition* roll) { const double cspeed = 299792458; double trArea(0.0); const ME0DetId me0Id(roll->id()); - if (me0Id.region() == 0) { throw cms::Exception("Geometry") << "GEMSynchronizer::simulateNoise() - this GEM id is from barrel, which cannot happen."; } - const TrapezoidalStripTopology* top_(dynamic_cast (&(roll->topology()))); - - // base_bottom, base_top, height, strips, pads (all half length) + const TrapezoidalStripTopology* top_(dynamic_cast(&(roll->topology()))); +// base_bottom, base_top, height, strips, pads (all half length) auto& parameters(roll->specs()->parameters()); float semiBottomEdge(parameters[0]); float semiTopEdge(parameters[1]); @@ -114,99 +98,79 @@ void ME0PreRecoGaussianModel::simulateNoise(const ME0EtaPartition* roll) double rollRadius = top_->radius(); const int nBxing(maxBunch_ - minBunch_ + 1); trArea = 2 * semiHeight * (semiTopEdge + semiBottomEdge); - - if (simulateIntrinsicNoise_) - { - } - - //simulate bkg contribution +// if (simulateIntrinsicNoise_) +// { +// } +//simulate bkg contribution if (!doBkgNoise_) return; - double aveNeutrRateBotRoll = 0.; double averageNoiseElectronRatePerRoll = 0.; int pdgid = 0; - float myRand = flat2_->fire(0., 1.); float yy_rand = 2 * semiHeight * (myRand - 0.5); - double radius_rand = rollRadius + yy_rand; - - if(simulateElectronBkg_) - averageNoiseElectronRatePerRoll = ME0ModElecBkgParam0 - + ME0ModElecBkgParam1 * radius_rand - + ME0ModElecBkgParam2 * radius_rand * radius_rand - + ME0ModElecBkgParam3 * radius_rand * radius_rand * radius_rand - + ME0ModElecBkgParam4 * radius_rand * radius_rand * radius_rand * radius_rand - + ME0ModElecBkgParam5 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand - + ME0ModElecBkgParam6 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand; - + if (simulateElectronBkg_) + averageNoiseElectronRatePerRoll = ME0ModElecBkgParam0 + ME0ModElecBkgParam1 * radius_rand + + ME0ModElecBkgParam2 * radius_rand * radius_rand + + ME0ModElecBkgParam3 * radius_rand * radius_rand * radius_rand + + ME0ModElecBkgParam4 * radius_rand * radius_rand * radius_rand * radius_rand + + ME0ModElecBkgParam5 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand + + ME0ModElecBkgParam6 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand; const double averageNoiseElec(averageNoiseElectronRatePerRoll * nBxing * bxwidth_ * trArea * 1.0e-9); int n_elechits(poisson_->fire(averageNoiseElec)); - double xMax = semiTopEdge - (semiHeight - yy_rand) * myTanPhi; for (int i = 0; i < n_elechits; ++i) { - //calculate xx_rand at a given yy_rand +//calculate xx_rand at a given yy_rand float myRandX = flat1_->fire(0., 1.); float xx_rand = 2 * xMax * (myRandX - 0.5); - float ex = sigma_u; float ey = sigma_v; float corr = 0.; - GlobalPoint pointDigiHit = roll->toGlobal(LocalPoint(xx_rand, yy_rand)); - //calc tof to the random estimated point - double stripRadius = sqrt(pointDigiHit.x() * pointDigiHit.x() + pointDigiHit.y() * pointDigiHit.y() - + pointDigiHit.z() * pointDigiHit.z()); +//calc tof to the random estimated point + double stripRadius = sqrt( + pointDigiHit.x() * pointDigiHit.x() + pointDigiHit.y() * pointDigiHit.y() + + pointDigiHit.z() * pointDigiHit.z()); double timeCalibrationOffset_ = (stripRadius * 1e+9) / (cspeed * 1e+2); //[ns] float tof = gauss_->fire(timeCalibrationOffset_, sigma_t); - float myrand = flat1_->fire(0., 1.); if (myrand <= 0.5) pdgid = -11; else pdgid = 11; - ME0DigiPreReco digi(xx_rand, yy_rand, ex, ey, corr, tof, pdgid); digi_.insert(digi); } - - aveNeutrRateBotRoll = ME0ModNeuBkgParam0 - + ME0ModNeuBkgParam1 * radius_rand - + ME0ModNeuBkgParam2 * radius_rand * radius_rand - + ME0ModNeuBkgParam3 * radius_rand * radius_rand * radius_rand - + ME0ModNeuBkgParam4 * radius_rand * radius_rand * radius_rand * radius_rand - + ME0ModNeuBkgParam5 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand - + ME0ModNeuBkgParam6 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand; - + aveNeutrRateBotRoll = ME0ModNeuBkgParam0 + ME0ModNeuBkgParam1 * radius_rand + + ME0ModNeuBkgParam2 * radius_rand * radius_rand + ME0ModNeuBkgParam3 * radius_rand * radius_rand * radius_rand + + ME0ModNeuBkgParam4 * radius_rand * radius_rand * radius_rand * radius_rand + + ME0ModNeuBkgParam5 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand + + ME0ModNeuBkgParam6 * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand * radius_rand; const double averageNoiseNeutrall(aveNeutrRateBotRoll * nBxing * bxwidth_ * trArea * 1.0e-9); int n_hits(poisson_->fire(averageNoiseNeutrall)); - for (int i = 0; i < n_hits; ++i) { - //calculate xx_rand at a given yy_rand +//calculate xx_rand at a given yy_rand float myRandX = flat1_->fire(0., 1.); float xx_rand = 2 * xMax * (myRandX - 0.5); - float ex = sigma_u; float ey = sigma_v; float corr = 0.; - GlobalPoint pointDigiHit = roll->toGlobal(LocalPoint(xx_rand, yy_rand)); - //calc tof to the random estimated point - double stripRadius = sqrt(pointDigiHit.x() * pointDigiHit.x() + pointDigiHit.y() * pointDigiHit.y() - + pointDigiHit.z() * pointDigiHit.z()); +//calc tof to the random estimated point + double stripRadius = sqrt( + pointDigiHit.x() * pointDigiHit.x() + pointDigiHit.y() * pointDigiHit.y() + + pointDigiHit.z() * pointDigiHit.z()); double timeCalibrationOffset_ = (stripRadius * 1e+9) / (cspeed * 1e+2); //[ns] float tof = gauss_->fire(timeCalibrationOffset_, sigma_t); - - //distribute bkg between neutrons and gammas +//distribute bkg between neutrons and gammas float myrand = flat1_->fire(0., 1.); if (myrand <= 0.1) pdgid = 2112; // neutrons else pdgid = 22; - ME0DigiPreReco digi(xx_rand, yy_rand, ex, ey, corr, tof, pdgid); digi_.insert(digi); } From a434eeb9ade14b1ab867bc5783c846dc7cd3e2e4 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Mon, 27 Oct 2014 16:27:58 +0100 Subject: [PATCH 223/252] Add HGCal scenario validation. --- .../Geometry/test/MaterialBudgetCaloPhaseII.C | 177 ++++++++++++++++++ .../Geometry/test/runP_CaloPhaseII_cfg.py | 80 ++++++++ 2 files changed, 257 insertions(+) create mode 100644 Validation/Geometry/test/MaterialBudgetCaloPhaseII.C create mode 100644 Validation/Geometry/test/runP_CaloPhaseII_cfg.py diff --git a/Validation/Geometry/test/MaterialBudgetCaloPhaseII.C b/Validation/Geometry/test/MaterialBudgetCaloPhaseII.C new file mode 100644 index 0000000000000..65eba1da43de9 --- /dev/null +++ b/Validation/Geometry/test/MaterialBudgetCaloPhaseII.C @@ -0,0 +1,177 @@ +// include files +#include +#include +#include +#include +#include + +#include "TCanvas.h" +#include "TDirectory.h" +#include "TFile.h" +#include "TLegend.h" +#include "TPaveText.h" +#include "TProfile.h" +#include "TStyle.h" + + +int colorLayer[7] = { 2, 7, 6, 5, 3, 4, 1}; +std::string dets[7] = {"BeamPipe", "Tracker", "EM Calorimeter", "HG Calorimeter", + "Hadron Calorimeter", "Muon System", "Forward Shield"}; + +void etaPhiPlot(TString fileName="matbdg_Calo.root", TString plot="IntLen", + int ifirst=0, int ilast=5, int drawLeg=1, bool ifEta=true, + double maxEta=-1, bool debug=false); +void etaPhiDiff(TString fileName1="matbdg_Calo1.root", + TString fileName2="matbdg_Calo2.root", TString plot="IntLen", + int itype=2, int drawLeg=1, bool ifEta=true, double maxEta=-1); +void setStyle(); + +void etaPhiPlot(TString fileName, TString plot, int ifirst, int ilast, + int drawLeg, bool ifEta, double maxEta, bool debug) { + + TFile* hcalFile = new TFile(fileName); + hcalFile->cd("g4SimHits"); + setStyle(); + + TString xtit = TString("#eta"); + TString ytit = "none"; + int ymin = 0, ymax = 20, istart = 200; + double xh = 0.90; + if (plot.CompareTo("RadLen") == 0) { + ytit = TString("Material Budget (X_{0})"); + ymin = 0; ymax = 200; istart = 100; + } else if (plot.CompareTo("StepLen") == 0) { + ytit = TString("Material Budget (Step Length)"); + ymin = 0; ymax = 15000; istart = 300; xh = 0.70; + } else { + ytit = TString("Material Budget (#lambda)"); + ymin = 0; ymax = 20; istart = 200; + } + if (!ifEta) { + istart += 300; + xtit = TString("#phi"); + } + + TLegend *leg = new TLegend(xh-0.25, 0.75, xh, 0.90); + leg->SetBorderSize(1); leg->SetFillColor(10); leg->SetMargin(0.25); + leg->SetTextSize(0.018); + + int nplots=0; + TProfile *prof[6]; + for (int ii=ilast; ii>=ifirst; ii--) { + char hname[10], title[50]; + sprintf(hname, "%i", istart+ii); + gDirectory->GetObject(hname,prof[nplots]); + prof[nplots]->GetXaxis()->SetTitle(xtit); + prof[nplots]->GetYaxis()->SetTitle(ytit); + prof[nplots]->GetYaxis()->SetRangeUser(ymin, ymax); + prof[nplots]->SetLineColor(colorLayer[ii]); + prof[nplots]->SetFillColor(colorLayer[ii]); + if (ifEta && maxEta > 0) + prof[nplots]->GetXaxis()->SetRangeUser(-maxEta,maxEta); + if (xh < 0.8) + prof[nplots]->GetYaxis()->SetTitleOffset(1.7); + sprintf(title, "%s", dets[ii].c_str()); + leg->AddEntry(prof[nplots], title, "lf"); + nplots++; + if (ii == ilast && debug) { + int nbinX = prof[0]->GetNbinsX(); + double xmin = prof[0]->GetXaxis()->GetXmin(); + double xmax = prof[0]->GetXaxis()->GetXmax(); + double dx = (xmax - xmin)/nbinX; + std::cout << "Hist " << ii; + for (int ibx=0; ibxGetBinContent(ibx+1); + std::cout << " | " << ibx << "(" << xx1 << ":" << (xx1+dx) << ") " + << cont; + } + std::cout << "\n"; + } + } + + TString cname = "c_" + plot + xtit; + TCanvas *cc1 = new TCanvas(cname, cname, 700, 600); + if (xh < 0.8) { + cc1->SetLeftMargin(0.15); cc1->SetRightMargin(0.05); + } + + prof[0]->Draw("h"); + for(int i=1; iDraw("h sames"); + if (drawLeg > 0) leg->Draw("sames"); +} + +void etaPhiDiff(TString fileName1, TString fileName2, TString plot, + int itype, int drawLeg, bool ifEta, double maxEta) { + + setStyle(); + + TString xtit = TString("#eta"); + TString ytit = "none"; + double xh = 0.90, ymin = -0.5, ymax = 0.5; + int ihist = 200 + itype; + if (plot.CompareTo("RadLen") == 0) { + ytit = TString("Material Budget Difference (X_{0})"); + ymin = -1; ymax = 1; ihist = 100 + itype; + } else if (plot.CompareTo("StepLen") == 0) { + ytit = TString("Material Budget Difference (Step Length)"); + ymin = -20; ymax = 20; ihist = 300 + itype; xh = 0.70; + } else { + ytit = TString("Material Budget Difference (#lambda)"); + } + if (!ifEta) { + ihist += 300; + xtit = TString("#phi"); + } + + TLegend *leg = new TLegend(xh-0.25, 0.84, xh, 0.90); + leg->SetBorderSize(1); leg->SetFillColor(10); leg->SetMargin(0.25); + leg->SetTextSize(0.022); + + TProfile *prof1, *prof2; + char hname[10], title[50]; + sprintf(hname, "%i", ihist); + TFile* file1 = new TFile(fileName1); + file1->cd("g4SimHits"); + gDirectory->GetObject(hname,prof1); + TFile* file2 = new TFile(fileName2); + file2->cd("g4SimHits"); + gDirectory->GetObject(hname,prof2); + TH1D *prof = (TH1D*) prof1->Clone(); + prof->Add(prof2,-1); + prof->GetXaxis()->SetTitle(xtit); + prof->GetYaxis()->SetTitle(ytit); + prof->GetYaxis()->SetRangeUser(ymin, ymax); + prof->SetLineColor(colorLayer[itype]); + for (int k=1; k<=prof->GetNbinsX(); ++k) + prof->SetBinError(k,0); + if (ifEta && maxEta > 0) + prof->GetXaxis()->SetRangeUser(-maxEta,maxEta); + if (xh < 0.8) + prof->GetYaxis()->SetTitleOffset(1.7); + sprintf(title, "%s", dets[itype].c_str()); + leg->AddEntry(prof, title, "lf"); + + TString cname = "c_dif" + plot + xtit; + TCanvas *cc1 = new TCanvas(cname, cname, 700, 600); + if (xh < 0.8) { + cc1->SetLeftMargin(0.15); cc1->SetRightMargin(0.05); + } + + prof->Draw("h"); + if (drawLeg > 0) leg->Draw("sames"); +} + +void setStyle () { + + gStyle->SetCanvasBorderMode(0); gStyle->SetCanvasColor(kWhite); + gStyle->SetPadColor(kWhite); gStyle->SetFrameBorderMode(0); + gStyle->SetFrameBorderSize(1); gStyle->SetFrameFillColor(0); + gStyle->SetFrameFillStyle(0); gStyle->SetFrameLineColor(1); + gStyle->SetFrameLineStyle(1); gStyle->SetFrameLineWidth(1); + gStyle->SetOptStat(0); gStyle->SetLegendBorderSize(1); + gStyle->SetOptTitle(0); gStyle->SetTitleOffset(2.5,"Y"); + +} + diff --git a/Validation/Geometry/test/runP_CaloPhaseII_cfg.py b/Validation/Geometry/test/runP_CaloPhaseII_cfg.py new file mode 100644 index 0000000000000..6f2d78b75b6d6 --- /dev/null +++ b/Validation/Geometry/test/runP_CaloPhaseII_cfg.py @@ -0,0 +1,80 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi") + +#Geometry +# +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuonReco_cff') +process.load('Configuration.Geometry.GeometryExtended2023HGCalMuon_cff') + +#Magnetic Field +# +process.load("Configuration.StandardSequences.MagneticField_38T_cff") + +# Detector simulation (Geant4-based) +# +process.load("SimG4Core.Application.g4SimHits_cfi") + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.generator.initialSeed = 456789 +process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876 + +process.source = cms.Source("PoolSource", + fileNames = cms.untracked.vstring('file:single_neutrino_random.root') +) + +process.MessageLogger = cms.Service("MessageLogger", + destinations = cms.untracked.vstring('cout'), + categories = cms.untracked.vstring('MaterialBudget'), + debugModules = cms.untracked.vstring('*'), + cout = cms.untracked.PSet( + threshold = cms.untracked.string('DEBUG'), + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + MaterialBudget = cms.untracked.PSet( + limit = cms.untracked.int32(-1) + ) + ) +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(-1) +) + +process.TFileService = cms.Service("TFileService", + fileName = cms.string('matbdg_Calo.root') +) + +process.p1 = cms.Path(process.g4SimHits) +process.g4SimHits.UseMagneticField = False +#process.g4SimHits.Physics.type = 'SimG4Core/Physics/DummyPhysics' +process.g4SimHits.Physics.DummyEMPhysics = True +process.g4SimHits.Physics.CutsPerRegion = False +process.g4SimHits.Generator.ApplyEtaCuts = False +process.g4SimHits.Watchers = cms.VPSet(cms.PSet( + MaterialBudget = cms.PSet( + DetectorTypes = cms.vstring('BeamPipe','Tracker','EM Calorimeter','HG Calorimeter', 'Hadron Calorimeter', 'Muon System','Forward Shield'), + Constituents = cms.vint32(4,2,1,1,2,1,1), + StackOrder = cms.vint32(1,2,3,4,5,6,7), + DetectorNames = cms.vstring('BEAM','BEAM1','BEAM2','BEAM3','Tracker','PLT','ECAL','HGCal','CALO','VCAL','MUON','OQUA'), + DetectorLevels= cms.vint32(3,3,3,3,3,3,4,4,3,3,3,3), + EtaBoundaries = cms.vdouble(1.108,2.643,2.780,4.350,4.570,100.0), + RegionTypes = cms.vint32(0,1,0,1,0,1), + Boundaries = cms.vdouble(8050.,10860.,1595.,12800.,330.,16006.5), + NBinEta = cms.untracked.int32(250), + NBinPhi = cms.untracked.int32(180), + MinEta = cms.untracked.double(-5.0), + MaxEta = cms.untracked.double(5.0) + ), + type = cms.string('MaterialBudget') +)) + + +# Automatic addition of the customisation function from SLHCUpgradeSimulations.Configuration.combinedCustoms +from SLHCUpgradeSimulations.Configuration.combinedCustoms import cust_2023HGCalMuon + +#call to customisation function cust_2023HGCalMuon imported from SLHCUpgradeSimulations.Configuration.combinedCustoms +process = cust_2023HGCalMuon(process) From 0f0ff7cd23cdd58e1a7ff4b805e6c8ad0afc2fd3 Mon Sep 17 00:00:00 2001 From: Ianna Osborne Date: Mon, 27 Oct 2014 16:37:10 +0100 Subject: [PATCH 224/252] Add Forward shield to the plot. --- Validation/Geometry/test/MaterialBudgetCaloPhaseII.C | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Validation/Geometry/test/MaterialBudgetCaloPhaseII.C b/Validation/Geometry/test/MaterialBudgetCaloPhaseII.C index 65eba1da43de9..e3d7e61810208 100644 --- a/Validation/Geometry/test/MaterialBudgetCaloPhaseII.C +++ b/Validation/Geometry/test/MaterialBudgetCaloPhaseII.C @@ -19,7 +19,7 @@ std::string dets[7] = {"BeamPipe", "Tracker", "EM Calorimeter", "HG Calorimeter" "Hadron Calorimeter", "Muon System", "Forward Shield"}; void etaPhiPlot(TString fileName="matbdg_Calo.root", TString plot="IntLen", - int ifirst=0, int ilast=5, int drawLeg=1, bool ifEta=true, + int ifirst=0, int ilast=6, int drawLeg=1, bool ifEta=true, double maxEta=-1, bool debug=false); void etaPhiDiff(TString fileName1="matbdg_Calo1.root", TString fileName2="matbdg_Calo2.root", TString plot="IntLen", @@ -57,7 +57,7 @@ void etaPhiPlot(TString fileName, TString plot, int ifirst, int ilast, leg->SetTextSize(0.018); int nplots=0; - TProfile *prof[6]; + TProfile *prof[7]; for (int ii=ilast; ii>=ifirst; ii--) { char hname[10], title[50]; sprintf(hname, "%i", istart+ii); From dc35727b405b7fedebb4563cb3b69081d3dae5e2 Mon Sep 17 00:00:00 2001 From: Kevin Date: Mon, 27 Oct 2014 19:23:11 +0100 Subject: [PATCH 225/252] add HE darkening scenario parameter to HERecalibration --- .../Hcal_Conditions_forGlobalTag_cff.py | 2 +- .../HcalPlugins/src/HERecalibration.cc | 52 +++++++++---------- .../HcalPlugins/src/HERecalibration.h | 16 +++--- .../src/HcalHardcodeCalibrations.cc | 4 +- .../Configuration/python/aging.py | 11 +++- 5 files changed, 45 insertions(+), 40 deletions(-) diff --git a/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py b/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py index 5fef1e4915fe2..6732752777ca5 100644 --- a/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py +++ b/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py @@ -12,7 +12,7 @@ toGet = cms.untracked.vstring('GainWidths'), #--- the following 5 parameters can be omitted in case of regular Geometry iLumi = cms.double(-1.), # for Upgrade: fb-1 - HERecalibration = cms.bool(False), # True for Upgrade + HERecalibration = cms.uint32(0), # 1 for Upgrade (default aging scenario) HEreCalibCutoff = cms.double(20.), # if above is True HFRecalibration = cms.bool(False), # True for Upgrade GainWidthsForTrigPrims = cms.bool(False) # True Upgrade diff --git a/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc b/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc index ea1966a01c624..08a5ed04ea2bd 100644 --- a/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc +++ b/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc @@ -7,20 +7,20 @@ #include "HERecalibration.h" -HERecalibration::HERecalibration(double integrated_lumi, double cutoff): -iLumi(integrated_lumi),cutoff_(cutoff),darkening() +HERecalibration::HERecalibration(double integrated_lumi, double cutoff, unsigned int scenario): +iLumi(integrated_lumi),cutoff_(cutoff),darkening(scenario) { } HERecalibration::~HERecalibration() { } -void HERecalibration::setDsegm( std::vector> m_segmentation) +void HERecalibration::setDsegm( const std::vector>& m_segmentation) { // std::cout << std::endl << " HERecalibration->setDsegm" << std::endl; - for (int ieta = 0; ieta < maxEta; ieta++) { + for (unsigned int ieta = 0; ieta < HEDarkening::nEtaBins; ieta++) { // std::cout << "["<< ieta << "] ieta =" << ieta + 16 << " "; - for(int ilay = 0; ilay < maxLay; ilay++) { + for(unsigned int ilay = 0; ilay < HEDarkening::nScintLayers; ilay++) { dsegm[ieta][ilay] = m_segmentation[ieta+15][ilay]; // 0 not used // std::cout << dsegm [ieta][ilay]; } @@ -43,17 +43,17 @@ double HERecalibration::getCorr(int ieta, int idepth) { void HERecalibration::initialize() { - double dval[maxEta][maxDepth]; // conversion of lval into depths-averaged values - denominator (including degradation for iLumi) - double nval[maxEta][maxDepth]; // conversion of lval into depths-averaged values - numerator (no degradation) + double dval[HEDarkening::nEtaBins][nDepths]; // conversion of lval into depths-averaged values - denominator (including degradation for iLumi) + double nval[HEDarkening::nEtaBins][nDepths]; // conversion of lval into depths-averaged values - numerator (no degradation) - for (int j = 0; j < maxEta; j++) { - for (int k = 0; k < maxDepth; k++) { + for (unsigned int j = 0; j < HEDarkening::nEtaBins; j++) { + for (unsigned int k = 0; k < nDepths; k++) { dval[j][k] = 0.0; nval[j][k] = 0.0; } } - double lval[maxEta][maxLay] // raw table of mean energy in each layer for each ieta at 0 lumi + double lval[HEDarkening::nEtaBins][HEDarkening::nScintLayers] // raw table of mean energy in each layer for each ieta at 0 lumi = { {0.000000,0.000000,0.001078,0.008848,0.014552,0.011611,0.008579,0.003211,0.002964,0.001775,0.001244,0.000194,0.000159,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000}, //tower 16 {0.107991,0.110127,0.081192,0.050552,0.032968,0.022363,0.012158,0.009392,0.006228,0.003650,0.003512,0.001384,0.002693,0.000171,0.000012,0.000000,0.000000,0.000000,0.000000}, //tower 17 @@ -75,10 +75,10 @@ void HERecalibration::initialize() { // std::cout << std::endl << " >>> DVAL evaluation " << std::endl; - for (int ieta = 0; ieta < maxEta; ieta++) { + for (unsigned int ieta = 0; ieta < HEDarkening::nEtaBins; ieta++) { //fill sum(means(layer,0)) and sum(means(layer,lumi)) for each depth - for(int ilay = 0; ilay < maxLay; ilay++) { + for(unsigned int ilay = 0; ilay < HEDarkening::nScintLayers; ilay++) { int idepth = dsegm[ieta][ilay]; // idepth = 0 - not used! nval[ieta][idepth] += lval[ieta][ilay]; dval[ieta][idepth] += lval[ieta][ilay]*darkening.degradation(iLumi,ieta+16,ilay-1); //be careful of eta and layer numbering @@ -91,22 +91,22 @@ void HERecalibration::initialize() { } //compute factors, w/ safety checks - for(int idepth = 0; idepth < maxDepth; idepth++){ - if(dval[ieta][idepth] > 0) corr[ieta][idepth] = nval[ieta][idepth]/dval[ieta][idepth]; - else corr[ieta][idepth] = 1.0; - - if(corr[ieta][idepth] < 1.0) corr[ieta][idepth] = 1.0; - /* - if (idepth > 0 && idepth <= 3) { - std::cout << "nval[" << ieta << "][" << idepth << "]" - << " = " << nval[ieta][idepth] << " - " + for(unsigned int idepth = 0; idepth < nDepths; idepth++){ + if(dval[ieta][idepth] > 0) corr[ieta][idepth] = nval[ieta][idepth]/dval[ieta][idepth]; + else corr[ieta][idepth] = 1.0; + + if(corr[ieta][idepth] < 1.0) corr[ieta][idepth] = 1.0; + /* + if (idepth > 0 && idepth <= 3) { + std::cout << "nval[" << ieta << "][" << idepth << "]" + << " = " << nval[ieta][idepth] << " - " << "dval["<< ieta << "][" << idepth << "]" << " = " << dval[ieta][idepth] - << " corr = " << corr[ieta][idepth] << std::endl; - } - */ - } - + << " corr = " << corr[ieta][idepth] << std::endl; + } + */ + } + } diff --git a/CalibCalorimetry/HcalPlugins/src/HERecalibration.h b/CalibCalorimetry/HcalPlugins/src/HERecalibration.h index e5fe8d7000845..3966313e7e4f7 100644 --- a/CalibCalorimetry/HcalPlugins/src/HERecalibration.h +++ b/CalibCalorimetry/HcalPlugins/src/HERecalibration.h @@ -13,29 +13,27 @@ #include #include "DataFormats/HcalCalibObjects/interface/HEDarkening.h" -#define maxEta 14 // ieta rings for HE -#define maxLay 19 // max.number of layers -#define maxDepth 7 // with some safety margin (wrt 5) - class HERecalibration { public: - HERecalibration(double integrated_lumi, double cutoff); + HERecalibration(double integrated_lumi, double cutoff, unsigned int scenario = 1); ~HERecalibration(); double getCorr(int ieta, int idepth); - void setDsegm(std::vector > m_segmentation); + void setDsegm(const std::vector >& m_segmentation); private: - + // max number of HE recalibration depths + static const unsigned int nDepths = 7; + void initialize(); double iLumi; double cutoff_; HEDarkening darkening; // Tabulated mean energy values per layer and per depth - double dsegm[maxEta][maxLay]; - double corr[maxEta][maxDepth]; + double dsegm[HEDarkening::nEtaBins][HEDarkening::nScintLayers]; + double corr[HEDarkening::nEtaBins][nDepths]; }; diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc index ced4594ea1bb3..506a2f01c874f 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc @@ -123,11 +123,11 @@ HcalHardcodeCalibrations::HcalHardcodeCalibrations ( const edm::ParameterSet& iC iLumi=iConfig.getParameter("iLumi"); if( iLumi > 0.0 ) { - bool he_recalib = iConfig.getParameter("HERecalibration"); + unsigned he_recalib = iConfig.getParameter("HERecalibration"); bool hf_recalib = iConfig.getParameter("HFRecalibration"); if(he_recalib) { double cutoff = iConfig.getParameter("HEreCalibCutoff"); - he_recalibration = new HERecalibration(iLumi,cutoff); + he_recalibration = new HERecalibration(iLumi,cutoff,he_recalib); } if(hf_recalib) hf_recalibration = new HFRecalibration(); diff --git a/SLHCUpgradeSimulations/Configuration/python/aging.py b/SLHCUpgradeSimulations/Configuration/python/aging.py index 4b75a14e11eb1..a0716f0937a29 100644 --- a/SLHCUpgradeSimulations/Configuration/python/aging.py +++ b/SLHCUpgradeSimulations/Configuration/python/aging.py @@ -84,7 +84,7 @@ def ageHcal(process,lumi): #recalibration and darkening always together if hasattr(process,'es_hardcode'): - process.es_hardcode.HERecalibration = cms.bool(True) + process.es_hardcode.HERecalibration = cms.uint32(1) process.es_hardcode.HFRecalibration = cms.bool(True) process.es_hardcode.iLumi = cms.double(float(lumi)) @@ -227,12 +227,19 @@ def turn_off_HE_aging(process): if hasattr(process,'mix') and hasattr(process.mix,'digitizers') and hasattr(process.mix.digitizers,'hcal'): process.mix.digitizers.hcal.HEDarkening = cms.uint32(0) if hasattr(process,'es_hardcode'): - process.es_hardcode.HERecalibration = cms.bool(False) + process.es_hardcode.HERecalibration = cms.uint32(0) if hasattr(process,'simHcalDigis'): process.simHcalDigis.HBlevel=cms.int32(16) process.simHcalDigis.HElevel=cms.int32(16) return process +def set_HE_aging_scenario(process,scenario): + if hasattr(process,'mix') and hasattr(process.mix,'digitizers') and hasattr(process.mix.digitizers,'hcal'): + process.mix.digitizers.hcal.HEDarkening = cms.uint32(scenario) + if hasattr(process,'es_hardcode'): + process.es_hardcode.HERecalibration = cms.uint32(scenario) + return process + def turn_off_HF_aging(process): if hasattr(process,'g4SimHits'): process.g4SimHits.HCalSD.HFDarkening = cms.untracked.bool(False) From f8aae927376f735762e70f436c2a72c68476fb90 Mon Sep 17 00:00:00 2001 From: Kevin Date: Mon, 27 Oct 2014 19:47:10 +0100 Subject: [PATCH 226/252] fix scenario parameter type --- CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc index 506a2f01c874f..bbb2fc8f6e329 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc @@ -123,7 +123,7 @@ HcalHardcodeCalibrations::HcalHardcodeCalibrations ( const edm::ParameterSet& iC iLumi=iConfig.getParameter("iLumi"); if( iLumi > 0.0 ) { - unsigned he_recalib = iConfig.getParameter("HERecalibration"); + unsigned he_recalib = iConfig.getParameter("HERecalibration"); bool hf_recalib = iConfig.getParameter("HFRecalibration"); if(he_recalib) { double cutoff = iConfig.getParameter("HEreCalibCutoff"); From b7f428b29fb3f53061e16b1c002842d551e15613 Mon Sep 17 00:00:00 2001 From: Kevin Date: Mon, 27 Oct 2014 20:24:11 +0100 Subject: [PATCH 227/252] remove default value for scenario --- CalibCalorimetry/HcalPlugins/src/HERecalibration.h | 2 +- DataFormats/HcalCalibObjects/interface/HEDarkening.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CalibCalorimetry/HcalPlugins/src/HERecalibration.h b/CalibCalorimetry/HcalPlugins/src/HERecalibration.h index 3966313e7e4f7..975483afec929 100644 --- a/CalibCalorimetry/HcalPlugins/src/HERecalibration.h +++ b/CalibCalorimetry/HcalPlugins/src/HERecalibration.h @@ -16,7 +16,7 @@ class HERecalibration { public: - HERecalibration(double integrated_lumi, double cutoff, unsigned int scenario = 1); + HERecalibration(double integrated_lumi, double cutoff, unsigned int scenario); ~HERecalibration(); double getCorr(int ieta, int idepth); diff --git a/DataFormats/HcalCalibObjects/interface/HEDarkening.h b/DataFormats/HcalCalibObjects/interface/HEDarkening.h index 7d37e03ed9a71..af0262bde9cd9 100644 --- a/DataFormats/HcalCalibObjects/interface/HEDarkening.h +++ b/DataFormats/HcalCalibObjects/interface/HEDarkening.h @@ -17,7 +17,7 @@ class HEDarkening { public: - HEDarkening(unsigned int scenario = 3); + HEDarkening(unsigned int scenario); ~HEDarkening(); float degradation(float intlumi, int ieta, int lay) const; From a5b74cc0356be864a3b4afe9c4dc4c8e07c5835f Mon Sep 17 00:00:00 2001 From: Kevin Date: Tue, 28 Oct 2014 01:10:15 +0100 Subject: [PATCH 228/252] tweak HE rad dam scenarios --- DataFormats/HcalCalibObjects/src/HEDarkening.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DataFormats/HcalCalibObjects/src/HEDarkening.cc b/DataFormats/HcalCalibObjects/src/HEDarkening.cc index be617fc4e8260..ea5406fb9bd76 100644 --- a/DataFormats/HcalCalibObjects/src/HEDarkening.cc +++ b/DataFormats/HcalCalibObjects/src/HEDarkening.cc @@ -42,8 +42,8 @@ HEDarkening::HEDarkening(unsigned int scenario) { for(unsigned int j = 0; j < nEtaBins; j++){ for(unsigned int i = 0; i < nScintLayers; i++){ if (scenario == 0 || - (scenario == 2 && exp(-500./_lumiscale[j][i])<0.2) || - (scenario == 3 && i<4)) { + (scenario == 2 && exp(-500./(_lumiscale[j][i]/flux_factor))<0.2) || + (scenario == 3 && i<5)) { lumiscale[j][i] = 0; } else { From b0c45cf0075e1e8f20a6c13e5bbd5a86f4a2201e Mon Sep 17 00:00:00 2001 From: Matevz Tadel Date: Mon, 27 Oct 2014 16:26:50 -0700 Subject: [PATCH 229/252] Store ligt/dark TGLColorSet as members in CmsShowCommon, do not rely on default Eve viewer being present. (cherry picked from commit b68729af886b60eb66432c38be2a23ab40d5407a) --- Fireworks/Core/interface/CmsShowCommon.h | 6 ++++++ Fireworks/Core/src/CmsShowCommon.cc | 23 ++++++++++++----------- Fireworks/Core/src/CmsShowCommonPopup.cc | 11 ++++++----- Fireworks/Core/src/FWEveView.cc | 23 ++++++++++++++--------- 4 files changed, 38 insertions(+), 25 deletions(-) diff --git a/Fireworks/Core/interface/CmsShowCommon.h b/Fireworks/Core/interface/CmsShowCommon.h index 393670660c02a..30e69f7939e83 100644 --- a/Fireworks/Core/interface/CmsShowCommon.h +++ b/Fireworks/Core/interface/CmsShowCommon.h @@ -23,6 +23,7 @@ #include #include "Rtypes.h" +#include "TGLUtil.h" #include "Fireworks/Core/interface/FWConfigurableParameterizable.h" #include "Fireworks/Core/interface/FWBoolParameter.h" @@ -66,6 +67,9 @@ class CmsShowCommon : public FWConfigurableParameterizable FWViewEnergyScale* getEnergyScale() const { return m_energyScale.get(); } + const TGLColorSet& getLightColorSet() const { return m_lightColorSet; } + const TGLColorSet& getDarkColorSet() const { return m_darkColorSet; } + UChar_t getProjTrackBreaking() const { return m_trackBreak.value(); } bool getRnrPTBMarkers() const { return m_drawBreakPoints.value(); } @@ -90,6 +94,8 @@ class CmsShowCommon : public FWConfigurableParameterizable FWLongParameter m_geomTransparency3D; FWLongParameter* m_geomColors[kFWGeomColorSize]; + TGLColorSet m_lightColorSet; + TGLColorSet m_darkColorSet; std::auto_ptr m_energyScale; diff --git a/Fireworks/Core/src/CmsShowCommon.cc b/Fireworks/Core/src/CmsShowCommon.cc index fdea96d0ae011..64e922d052f26 100644 --- a/Fireworks/Core/src/CmsShowCommon.cc +++ b/Fireworks/Core/src/CmsShowCommon.cc @@ -56,6 +56,9 @@ CmsShowCommon::CmsShowCommon(fireworks::Context* c): m_trackBreak.changed_.connect(boost::bind(&CmsShowCommon::setTrackBreakMode, this)); m_drawBreakPoints.changed_.connect(boost::bind(&CmsShowCommon::setDrawBreakMarkers, this)); m_gamma.changed_.connect(boost::bind(&CmsShowCommon::setGamma, this)); + + m_lightColorSet.StdLightBackground(); + m_darkColorSet .StdDarkBackground(); } CmsShowCommon::~CmsShowCommon() @@ -132,7 +135,7 @@ CmsShowCommon::setGeomTransparency(int iTransp, bool projected) namespace { - void addGLColorToConfig(const char* cname, TGLColor& c, FWConfiguration& oTo) + void addGLColorToConfig(const char* cname, const TGLColor& c, FWConfiguration& oTo) { FWConfiguration pc; @@ -171,11 +174,10 @@ CmsShowCommon::addTo(FWConfiguration& oTo) const if (gEve) { - TGLViewer* v = gEve->GetDefaultGLViewer(); - addGLColorToConfig("SelectionColorLight", v->RefLightColorSet().Selection(1), oTo); - addGLColorToConfig("HighlightColorLight", v->RefLightColorSet().Selection(3), oTo); - addGLColorToConfig("SelectionColorDark", v->RefDarkColorSet().Selection(1), oTo); - addGLColorToConfig("HighlightColorDark", v->RefDarkColorSet().Selection(3), oTo); + addGLColorToConfig("SelectionColorLight", m_lightColorSet.Selection(1), oTo); + addGLColorToConfig("HighlightColorLight", m_lightColorSet.Selection(3), oTo); + addGLColorToConfig("SelectionColorDark", m_darkColorSet .Selection(1), oTo); + addGLColorToConfig("HighlightColorDark", m_darkColorSet .Selection(3), oTo); } } @@ -222,10 +224,9 @@ CmsShowCommon::setFrom(const FWConfiguration& iFrom) if (gEve) { - TGLViewer* v = gEve->GetDefaultGLViewer(); - setGLColorFromConfig(v->RefLightColorSet().Selection(1), iFrom.valueForKey("SelectionColorLight")); - setGLColorFromConfig(v->RefLightColorSet().Selection(3), iFrom.valueForKey("HighlightColorLight")); - setGLColorFromConfig(v->RefDarkColorSet().Selection(1), iFrom.valueForKey("SelectionColorDark")); - setGLColorFromConfig(v->RefDarkColorSet().Selection(3), iFrom.valueForKey("HighlightColorDark")); + setGLColorFromConfig(m_lightColorSet.Selection(1), iFrom.valueForKey("SelectionColorLight")); + setGLColorFromConfig(m_lightColorSet.Selection(3), iFrom.valueForKey("HighlightColorLight")); + setGLColorFromConfig(m_darkColorSet .Selection(1), iFrom.valueForKey("SelectionColorDark")); + setGLColorFromConfig(m_darkColorSet .Selection(3), iFrom.valueForKey("HighlightColorDark")); } } diff --git a/Fireworks/Core/src/CmsShowCommonPopup.cc b/Fireworks/Core/src/CmsShowCommonPopup.cc index cda977db9815a..ae87e3e6a4ddd 100644 --- a/Fireworks/Core/src/CmsShowCommonPopup.cc +++ b/Fireworks/Core/src/CmsShowCommonPopup.cc @@ -288,16 +288,17 @@ CmsShowCommonPopup::colorSetChanged() void CmsShowCommonPopup::getColorSetColors (int& hci, int& sci) { - TGLColorSet& colorset = m_common->colorManager()->isColorSetDark() ? gEve->GetDefaultGLViewer()->RefDarkColorSet(): - gEve->GetDefaultGLViewer()->RefLightColorSet(); + TGLColorSet& colorset = m_common->colorManager()->isColorSetDark() ? + m_common->m_darkColorSet : m_common->m_lightColorSet; { TGLColor& glc = colorset.Selection(3); hci = TColor::GetColor(glc.GetRed(), glc.GetGreen(), glc.GetBlue()); - // printf("getSHcolors HIGH %d %d %d , [%d]\n", glc.GetRed(), glc.GetGreen(), glc.GetBlue(), hci); - }{ + // printf("getSHcolors HIGH %d %d %d , [%d]\n", glc.GetRed(), glc.GetGreen(), glc.GetBlue(), hci); + } + { TGLColor& glc = colorset.Selection(1); sci = TColor::GetColor(glc.GetRed(), glc.GetGreen(), glc.GetBlue()); - // printf("getSHcolors SEL %d %d %d , [%d]\n", glc.GetRed(), glc.GetGreen(), glc.GetBlue(), sci); + // printf("getSHcolors SEL %d %d %d , [%d]\n", glc.GetRed(), glc.GetGreen(), glc.GetBlue(), sci); } } diff --git a/Fireworks/Core/src/FWEveView.cc b/Fireworks/Core/src/FWEveView.cc index 8f635b1ab0e23..6e7796c084f59 100644 --- a/Fireworks/Core/src/FWEveView.cc +++ b/Fireworks/Core/src/FWEveView.cc @@ -387,15 +387,20 @@ FWEveView::setFrom(const FWConfiguration& iFrom) // selection clors - UChar_t* ca = 0; - ca = gEve->GetDefaultGLViewer()->RefLightColorSet().Selection(1).Arr(); - viewerGL()->RefLightColorSet().Selection(1).SetColor(ca[0], ca[1], ca[2]); - ca = gEve->GetDefaultGLViewer()->RefLightColorSet().Selection(3).Arr(); - viewerGL()->RefLightColorSet().Selection(3).SetColor(ca[0], ca[1], ca[2]); - ca = gEve->GetDefaultGLViewer()->RefDarkColorSet().Selection(1).Arr(); - viewerGL()->RefDarkColorSet().Selection(1).SetColor(ca[0], ca[1], ca[2]); - ca = gEve->GetDefaultGLViewer()->RefDarkColorSet().Selection(3).Arr(); - viewerGL()->RefDarkColorSet().Selection(3).SetColor(ca[0], ca[1], ca[2]); + { + const TGLColorSet& lcs = context().commonPrefs()->getLightColorSet(); + const TGLColorSet& dcs = context().commonPrefs()->getDarkColorSet(); + const UChar_t* ca = 0; + + ca = lcs.Selection(1).CArr(); + viewerGL()->RefLightColorSet().Selection(1).SetColor(ca[0], ca[1], ca[2]); + ca = lcs.Selection(3).CArr(); + viewerGL()->RefLightColorSet().Selection(3).SetColor(ca[0], ca[1], ca[2]); + ca = dcs.Selection(1).CArr(); + viewerGL()->RefDarkColorSet().Selection(1).SetColor(ca[0], ca[1], ca[2]); + ca = dcs.Selection(3).CArr(); + viewerGL()->RefDarkColorSet().Selection(3).SetColor(ca[0], ca[1], ca[2]); + } } //______________________________________________________________________________ From d22f3958ba5bc8662eb02c2c5d5d4dfb21e9bf31 Mon Sep 17 00:00:00 2001 From: Matevz Tadel Date: Mon, 27 Oct 2014 16:23:49 -0700 Subject: [PATCH 230/252] GeometryView -- add context menu entry for applying color to children. (cherry picked from commit 1aaad1cdf96d8246ae6570844d4908ca1de4669b) --- Fireworks/Core/interface/FWGeoTopNode.h | 2 ++ .../interface/FWGeometryTableManagerBase.h | 4 +++ Fireworks/Core/src/FWGeoTopNode.cc | 8 +++-- .../Core/src/FWGeometryTableManagerBase.cc | 30 ++++++++++++++++++- Fireworks/Core/src/FWGeometryTableViewBase.cc | 14 +++++++-- 5 files changed, 52 insertions(+), 6 deletions(-) diff --git a/Fireworks/Core/interface/FWGeoTopNode.h b/Fireworks/Core/interface/FWGeoTopNode.h index b656e8c63abb7..58504b787350d 100644 --- a/Fireworks/Core/interface/FWGeoTopNode.h +++ b/Fireworks/Core/interface/FWGeoTopNode.h @@ -51,6 +51,8 @@ class FWGeoTopNode : public TEveElementList, kVisSelfOff, kVisChldOn, kVisChldOff, + kApplyChldCol, + kApplyChldColRec, kCamera, kPrintMaterial, kPrintPath, diff --git a/Fireworks/Core/interface/FWGeometryTableManagerBase.h b/Fireworks/Core/interface/FWGeometryTableManagerBase.h index 31e4a2a21dbdc..9080ecffbda1b 100644 --- a/Fireworks/Core/interface/FWGeometryTableManagerBase.h +++ b/Fireworks/Core/interface/FWGeometryTableManagerBase.h @@ -79,6 +79,8 @@ class FWGeometryTableManagerBase : public FWTableManagerBase bool testBitAny(UChar_t f) const { return (m_flags & f) != 0; } void switchBit(UChar_t f) { testBit(f) ? resetBit(f) : setBit(f); } + + void copyColorTransparency(const NodeInfo& x) { m_color = x.m_color; m_transparency = x.m_transparency; } }; @@ -162,6 +164,8 @@ class FWGeometryTableManagerBase : public FWTableManagerBase virtual bool getVisibilityChld(const NodeInfo& nodeInfo) const; virtual bool getVisibility (const NodeInfo& nodeInfo) const; + virtual void applyColorTranspToDaughters(int selectedIdx, bool recurse); + bool isNodeRendered(int idx, int top_node_idx) const; static void getNNodesTotal(TGeoNode* geoNode, int& off); diff --git a/Fireworks/Core/src/FWGeoTopNode.cc b/Fireworks/Core/src/FWGeoTopNode.cc index 7a1a5f668ad8f..f52080f5191cc 100644 --- a/Fireworks/Core/src/FWGeoTopNode.cc +++ b/Fireworks/Core/src/FWGeoTopNode.cc @@ -380,13 +380,15 @@ FWPopupMenu* FWGeoTopNode::setPopupMenu(int iX, int iY, TGLViewer* v, bool overl FWPopupMenu* nodePopup = new FWPopupMenu(); nodePopup->AddEntry("Set As Top Node", kSetTopNode); - nodePopup->AddEntry("Set As Top Node And Reset Camera", kSetTopNodeCam); + nodePopup->AddEntry("Set As Top Node and Reset Camera", kSetTopNodeCam); nodePopup->AddSeparator(); if (v) { nodePopup->AddEntry("Rnr Off", kVisSelfOff); } - nodePopup->AddEntry("Rnr Off For All Children", kVisChldOff); - nodePopup->AddEntry("Rnr On For All Children", kVisChldOn); + nodePopup->AddEntry("Turn Render On For Children", kVisChldOn); + nodePopup->AddEntry("Turn Render Off For Children", kVisChldOff); + nodePopup->AddEntry("Apply Color To Children", kApplyChldCol); + nodePopup->AddEntry("Apply Color Recursively", kApplyChldColRec); nodePopup->AddSeparator(); if (overlap) diff --git a/Fireworks/Core/src/FWGeometryTableManagerBase.cc b/Fireworks/Core/src/FWGeometryTableManagerBase.cc index b98e6b5f4e296..8312589ce921e 100644 --- a/Fireworks/Core/src/FWGeometryTableManagerBase.cc +++ b/Fireworks/Core/src/FWGeometryTableManagerBase.cc @@ -324,7 +324,8 @@ void FWGeometryTableManagerBase::setVisibilityChld(NodeInfo& data, bool x) { data.setBitVal(kVisNodeChld, x); } -//______________________________________________________________________________ + +//------------------------------------------------------------------------------ void FWGeometryTableManagerBase::setDaughtersSelfVisibility(int selectedIdx, bool v) { @@ -350,11 +351,38 @@ bool FWGeometryTableManagerBase::getVisibility(const NodeInfo& data) const return data.testBit(kVisNodeSelf); } +//------------------------------------------------------------------------------ + bool FWGeometryTableManagerBase::getVisibilityChld(const NodeInfo& data) const { return data.testBit(kVisNodeChld); } +//------------------------------------------------------------------------------ + +void FWGeometryTableManagerBase::applyColorTranspToDaughters(int selectedIdx, bool recurse) +{ + NodeInfo &nInfo = m_entries[selectedIdx]; + TGeoNode *parentNode = nInfo.m_node; + int nD = parentNode->GetNdaughters(); + int dOff = 0; + for (int n = 0; n != nD; ++n) + { + int idx = selectedIdx + 1 + n + dOff; + NodeInfo& data = m_entries[idx]; + + data.copyColorTransparency(nInfo); + + if (recurse) + { + applyColorTranspToDaughters(idx, recurse); + } + + getNNodesTotal(parentNode->GetDaughter(n), dOff); + } +} + +//------------------------------------------------------------------------------ bool FWGeometryTableManagerBase::isNodeRendered(int idx, int topNodeIdx) const { diff --git a/Fireworks/Core/src/FWGeometryTableViewBase.cc b/Fireworks/Core/src/FWGeometryTableViewBase.cc index 75f7bfa7379c1..026c04a750c18 100644 --- a/Fireworks/Core/src/FWGeometryTableViewBase.cc +++ b/Fireworks/Core/src/FWGeometryTableViewBase.cc @@ -522,10 +522,20 @@ void FWGeometryTableViewBase::chosenItem(int menuIdx) break; case FWGeoTopNode::kVisChldOn: - getTableManager()->setDaughtersSelfVisibility(selectedIdx, true); + getTableManager()->setDaughtersSelfVisibility(selectedIdx, true); refreshTable3D(); break; - + + case FWGeoTopNode::kApplyChldCol: + getTableManager()->applyColorTranspToDaughters(selectedIdx, false); + refreshTable3D(); + break; + + case FWGeoTopNode::kApplyChldColRec: + getTableManager()->applyColorTranspToDaughters(selectedIdx, true); + refreshTable3D(); + break; + case FWGeoTopNode::kPrintMaterial: gv->InspectMaterial(); break; From 895f8781776885638b0d33d3b5b518d35883ed87 Mon Sep 17 00:00:00 2001 From: Nicola Date: Tue, 28 Oct 2014 11:32:40 +0100 Subject: [PATCH 231/252] safety added after new digitizer --- .../plugins/TTClusterAssociator.cc | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/SimTracker/TrackTriggerAssociation/plugins/TTClusterAssociator.cc b/SimTracker/TrackTriggerAssociation/plugins/TTClusterAssociator.cc index 389bf0f50c371..c0dd7bdf27f96 100644 --- a/SimTracker/TrackTriggerAssociation/plugins/TTClusterAssociator.cc +++ b/SimTracker/TrackTriggerAssociation/plugins/TTClusterAssociator.cc @@ -135,6 +135,26 @@ void TTClusterAssociator< Ref_PixelDigi_ >::produce( edm::Event& iEvent, const e const DetId detId = theStackedTrackers->idToDet( tempCluRef->getDetId(), tempCluRef->getStackMember() )->geographicalId(); /// Get the PixelDigiSimLink + /// Safety check added after new digitizer (Oct 2014) + if ( thePixelDigiSimLinkHandle->find(detId.rawId()) == thePixelDigiSimLinkHandle->end() ) + { + /// Sensor is not found in DigiSimLink. + /// Set MC truth to NULL for all hits in this sensor. Period. + + /// Get the Digis and loop over them + std::vector< Ref_PixelDigi_ > theseHits = tempCluRef->getHits(); + for ( unsigned int i = 0; i < theseHits.size(); i++ ) + { + /// No SimLink is found by definition + /// Then store NULL MC truth for all the digis + edm::Ptr< TrackingParticle > tempTPPtr; // = new edm::Ptr< TrackingParticle >(); + clusterToTrackingParticleVectorMap.find( tempCluRef )->second.push_back( tempTPPtr ); + } + + /// Go to the next sensor + continue; + } + edm::DetSet thisDigiSimLink = (*(thePixelDigiSimLinkHandle) )[detId.rawId()]; edm::DetSet::const_iterator iterSimLink; From b73bfb2588df79c7f8488e26dabddea222257a13 Mon Sep 17 00:00:00 2001 From: lgray Date: Tue, 28 Oct 2014 06:04:58 -0500 Subject: [PATCH 232/252] update cluster level weights to V5 (V4 is deprecated with this commit) --- .../python/particleFlowClusterHGCEE_cfi.py | 23 ++++++++++--------- .../python/particleFlowClusterHGCHEB_cfi.py | 10 ++++---- .../python/particleFlowClusterHGCHEF_cfi.py | 8 ++++--- 3 files changed, 23 insertions(+), 18 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py index df7362265294c..c329c302a0fc2 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCEE_cfi.py @@ -47,25 +47,26 @@ minFractionToKeep = cms.double(1e-7) ) -#weights for layers from P.Silva (24 June 2014) -weight_vec = [0.42] -weight_vec.extend([1.00 for x in range(10)]) -weight_vec.extend([1.61 for x in range(10)]) -weight_vec.extend([2.44 for x in range(10)]) +#weights for layers from P.Silva (24 October 2014) +## this is for V5! +weight_vec = [0.080] +weight_vec.extend([0.62 for x in range(9)]) +weight_vec.extend([0.81 for x in range(9)]) +weight_vec.extend([1.19 for x in range(8)]) # MIP effective to 1.0/GeV (from fit to data of P. Silva) #f(x) = a/(1-exp(-bx - c)) # x = cosh(eta) -# a = 168.0 -# b = 0.6871 -# c = 0.9038 +# a = 82.8 +# b = 1e6 +# c = 1e6 _HGCEE_ElectronEnergy = cms.PSet( algoName = cms.string("HGCEEElectronEnergyCalibrator"), weights = cms.vdouble(weight_vec), - effMip_to_InverseGeV_a = cms.double(168.0), - effMip_to_InverseGeV_b = cms.double(0.6871), - effMip_to_InverseGeV_c = cms.double(0.9038), + effMip_to_InverseGeV_a = cms.double(82.8), + effMip_to_InverseGeV_b = cms.double(1e6), + effMip_to_InverseGeV_c = cms.double(1e6), MipValueInGeV = cms.double(55.1*1e-6) ) diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py index 68e2aabd180bf..e321d219c28c0 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEB_cfi.py @@ -31,14 +31,16 @@ thresholdsByDetector = cms.VPSet( ) ) -#weights for layers from P.Silva (26 June 2014) -weight_vec = [0.0902 for x in range(12)] -weight_vec.extend([0.1051 for x in range(10)]) +#weights for layers from P.Silva (24 October 2014) +# this is for V5!!!!! +weight_vec = [0.0464] +weight_vec.extend([0.0474 for x in range(10)]) +weight_vec.extend([0.1215 for x in range(11)]) # MIP effective to 1.0/GeV (from fit to data of P. Silva) for HEF #f(x) = a/(1+exp(-bx - c)) # x = cosh(eta) -# a = 11.33333 <--- from straight average of Pedro's data +# a = 1.0 <--- from straight average of Pedro's data # b = 1e6 # c = 1e6 diff --git a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py index 1fb91a182e124..7971ec942cef0 100644 --- a/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py +++ b/RecoParticleFlow/PFClusterProducer/python/particleFlowClusterHGCHEF_cfi.py @@ -31,9 +31,11 @@ thresholdsByDetector = cms.VPSet( ) ) -#weights for layers from P.Silva (26 June 2014) -weight_vec = [0.0902 for x in range(12)] -weight_vec.extend([0.1051 for x in range(10)]) +#weights for layers from P.Silva (24 October 2014) +# this is for V5!!!!! +weight_vec = [0.0464] +weight_vec.extend([0.0474 for x in range(10)]) +weight_vec.extend([0.1215 for x in range(11)]) # MIP effective to 1.0/GeV (from fit to data of P. Silva) for HEF #f(x) = a/(1-exp(-bx - c)) From 5b1ee133a09b90e0764bcb6e0fbc2983d1aafe72 Mon Sep 17 00:00:00 2001 From: David Mendez Date: Tue, 28 Oct 2014 16:16:04 +0100 Subject: [PATCH 233/252] DataFormats/L1Trigger -- updated class version to l1extra::L1MuonParticleExtended::StationData --- DataFormats/L1Trigger/src/classes_def.xml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/DataFormats/L1Trigger/src/classes_def.xml b/DataFormats/L1Trigger/src/classes_def.xml index 7ca781f63b039..f8eff615bf793 100644 --- a/DataFormats/L1Trigger/src/classes_def.xml +++ b/DataFormats/L1Trigger/src/classes_def.xml @@ -11,8 +11,7 @@ - - + From 39a86f70d1b05fda5a8fc7707861beda70102d07 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Sauvan Date: Tue, 28 Oct 2014 21:13:27 +0100 Subject: [PATCH 234/252] fix layer condition in HGCalDDDConstants::newCell() --- Geometry/HGCalCommonData/src/HGCalDDDConstants.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc index 36f3afe6ae244..0f9df4006af05 100644 --- a/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc +++ b/Geometry/HGCalCommonData/src/HGCalDDDConstants.cc @@ -284,7 +284,7 @@ std::pair HGCalDDDConstants::newCell(int cell, int lay, int subsector, int incrz, bool half) const { int layer = lay + incrz; - if (layer <= 0 || layer < (int)(layers(true))) return std::pair(cell,0); + if (layer <= 0 || layer > (int)(layers(true))) return std::pair(cell,0); int subSec = half ? subsector : 0; std::pair xy = locateCell(cell, lay, subSec, true); std::pair kcell = assignCell(xy.first, xy.second, layer, subSec, From 6e30b5954a3ebd243ff74792873fa45e77a73ffd Mon Sep 17 00:00:00 2001 From: Kevin Date: Tue, 28 Oct 2014 19:43:24 +0100 Subject: [PATCH 235/252] add HB radiation damage model (very rough extrapolation from HE raddam model) and recalibration --- .../Hcal_Conditions_forGlobalTag_cff.py | 6 +- .../HcalPlugins/src/HBRecalibration.cc | 115 ++++++++++++++++++ .../HcalPlugins/src/HBRecalibration.h | 41 +++++++ .../src/HcalHardcodeCalibrations.cc | 5 + .../src/HcalHardcodeCalibrations.h | 2 + .../HcalCalibObjects/interface/HBDarkening.h | 36 ++++++ .../HcalCalibObjects/src/HBDarkening.cc | 81 ++++++++++++ DataFormats/HcalCalibObjects/src/classes.h | 2 + .../HcalCalibObjects/src/classes_def.xml | 3 + .../Configuration/python/HCalCustoms.py | 2 + .../Configuration/python/aging.py | 17 ++- .../interface/HcalDigitizer.h | 2 + .../python/hcalUnsuppressedDigis_cfi.py | 1 + .../HcalSimProducers/src/HcalDigitizer.cc | 13 +- SimG4CMS/Calo/interface/HCalSD.h | 2 + SimG4CMS/Calo/src/HCalSD.cc | 27 ++++ SimG4Core/Application/python/g4SimHits_cfi.py | 1 + 17 files changed, 350 insertions(+), 6 deletions(-) create mode 100644 CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc create mode 100644 CalibCalorimetry/HcalPlugins/src/HBRecalibration.h create mode 100644 DataFormats/HcalCalibObjects/interface/HBDarkening.h create mode 100644 DataFormats/HcalCalibObjects/src/HBDarkening.cc diff --git a/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py b/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py index 6732752777ca5..3bef3f27c16f4 100644 --- a/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py +++ b/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py @@ -12,8 +12,10 @@ toGet = cms.untracked.vstring('GainWidths'), #--- the following 5 parameters can be omitted in case of regular Geometry iLumi = cms.double(-1.), # for Upgrade: fb-1 - HERecalibration = cms.uint32(0), # 1 for Upgrade (default aging scenario) - HEreCalibCutoff = cms.double(20.), # if above is True + HERecalibration = cms.uint32(0), # 1 for Upgrade (default aging scenario) + HEreCalibCutoff = cms.double(20.), # if above is True + HBRecalibration = cms.uint32(0), # 1 for Upgrade (default aging scenario) + HBreCalibCutoff = cms.double(20.), # if above is True HFRecalibration = cms.bool(False), # True for Upgrade GainWidthsForTrigPrims = cms.bool(False) # True Upgrade ) diff --git a/CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc b/CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc new file mode 100644 index 0000000000000..ef87eda0879fd --- /dev/null +++ b/CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc @@ -0,0 +1,115 @@ +/////////////////////////////////////////////////////////////////////////////// +// File: HBRecalibration.cc +// Description: simple helper class containing tabulater/parameterized +// function for HE damage recovery for Upgrade studies +// evaluated using DataFormats/HcalCalibObjects/HBDarkening +/////////////////////////////////////////////////////////////////////////////// + +#include "HBRecalibration.h" + +HBRecalibration::HBRecalibration(double integrated_lumi, double cutoff, unsigned int scenario): +iLumi(integrated_lumi),cutoff_(cutoff),darkening(scenario) +{ } + +HBRecalibration::~HBRecalibration() { } + +void HBRecalibration::setDsegm( const std::vector>& m_segmentation) +{ + + // std::cout << std::endl << " HBRecalibration->setDsegm" << std::endl; + + for (unsigned int ieta = 0; ieta < HBDarkening::nEtaBins; ieta++) { + // std::cout << "["<< ieta << "] ieta =" << ieta + 16 << " "; + for(unsigned int ilay = 0; ilay < HBDarkening::nScintLayers; ilay++) { + dsegm[ieta][ilay] = m_segmentation[ieta][ilay]; // 0 not used + // std::cout << dsegm [ieta][ilay]; + } + // std::cout << std::endl; + } + + initialize(); + +} + +double HBRecalibration::getCorr(int ieta, int idepth) { + + // int init_ieta = ieta; + ieta = abs(ieta)-1; // 0 - 15 + + if(corr[ieta][idepth] > cutoff_) return cutoff_; + else return corr[ieta][idepth]; +} + + +void HBRecalibration::initialize() { + + double dval[HBDarkening::nEtaBins][nDepths]; // conversion of lval into depths-averaged values - denominator (including degradation for iLumi) + double nval[HBDarkening::nEtaBins][nDepths]; // conversion of lval into depths-averaged values - numerator (no degradation) + + for (unsigned int j = 0; j < HBDarkening::nEtaBins; j++) { + for (unsigned int k = 0; k < nDepths; k++) { + dval[j][k] = 0.0; + nval[j][k] = 0.0; + } + } + + double lval[HBDarkening::nEtaBins][HBDarkening::nScintLayers] // raw table of mean energy in each layer for each ieta at 0 lumi + = { + {2.362808,1.575159,1.283007,1.026073,0.834189,0.702393,0.566008,0.484473,0.402106,0.306254,0.251159,0.199382,0.156932,0.132067,0.099506,0.080853,0.118480}, //tower 1 + {2.397443,1.616431,1.301160,1.078375,0.882232,0.705615,0.577277,0.472366,0.383500,0.326740,0.265406,0.208601,0.169150,0.124831,0.103368,0.078420,0.117037}, //tower 2 + {2.475831,1.654173,1.322021,1.033156,0.850223,0.684293,0.551837,0.467637,0.377493,0.329712,0.254339,0.203073,0.165079,0.123208,0.102514,0.079879,0.112186}, //tower 3 + {2.462020,1.606079,1.282836,1.010049,0.855179,0.669815,0.556634,0.452061,0.377653,0.311965,0.255425,0.194654,0.159325,0.117479,0.092718,0.069317,0.105891}, //tower 4 + {2.707523,1.747932,1.373208,1.106487,0.866754,0.728357,0.563662,0.469271,0.374237,0.303459,0.241259,0.187083,0.140809,0.116930,0.081804,0.064648,0.101095}, //tower 5 + {2.678347,1.741005,1.317389,1.013474,0.823785,0.710703,0.551169,0.429373,0.347780,0.274428,0.222277,0.166950,0.131702,0.101153,0.075034,0.060390,0.092811}, //tower 6 + {2.809996,1.729876,1.328158,1.050613,0.820268,0.669393,0.516984,0.411677,0.331940,0.272142,0.197038,0.155147,0.127178,0.094173,0.069392,0.054302,0.071747}, //tower 7 + {2.858155,1.770711,1.355659,1.047950,0.851036,0.657216,0.526521,0.416379,0.319870,0.247920,0.188156,0.145095,0.110619,0.080743,0.063796,0.052655,0.071961}, //tower 8 + {3.041316,1.877900,1.418290,1.082000,0.840637,0.676057,0.505557,0.402506,0.301596,0.231630,0.182558,0.138136,0.106255,0.073500,0.056109,0.041644,0.045892}, //tower 9 + {3.142461,1.817359,1.363827,1.013841,0.768494,0.603310,0.463155,0.368469,0.282965,0.218877,0.152383,0.118167,0.079790,0.053056,0.038893,0.031578,0.040494}, //tower 10 + {3.294945,1.854570,1.367346,1.008908,0.769117,0.594254,0.445583,0.335300,0.248729,0.190494,0.137710,0.099664,0.071549,0.053245,0.037729,0.025820,0.033520}, //tower 11 + {3.579348,1.951865,1.393643,1.009883,0.745045,0.555898,0.424502,0.313736,0.220994,0.156913,0.109682,0.074274,0.052242,0.039518,0.029820,0.016796,0.028697}, //tower 12 + {3.752190,2.001947,1.431959,1.057370,0.750016,0.550919,0.410243,0.300922,0.201059,0.151015,0.111034,0.074270,0.049154,0.034618,0.025749,0.018542,0.025501}, //tower 13 + {4.057676,2.074200,1.423406,1.000701,0.745990,0.536405,0.375057,0.278802,0.192733,0.128711,0.094431,0.062570,0.051008,0.034336,0.026740,0.015083,0.002232}, //tower 14 + {4.252095,2.160939,1.492043,1.021666,0.740503,0.534830,0.378022,0.276588,0.204727,0.156732,0.111826,0.066944,0.045150,0.031974,0.019658,0.001816,0.000000}, //tower 15 + {0.311054,0.185613,2.806550,1.810331,0.996787,0.539745,0.285648,0.136337,0.059499,0.007867,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000} //tower 16 + }; + + // coverting energy values from layers into depths + + // std::cout << std::endl << " >>> DVAL evaluation " << std::endl; + + for (unsigned int ieta = 0; ieta < HBDarkening::nEtaBins; ieta++) { + + //fill sum(means(layer,0)) and sum(means(layer,lumi)) for each depth + for(unsigned int ilay = 0; ilay < HBDarkening::nScintLayers; ilay++) { + int idepth = dsegm[ieta][ilay]; // idepth = 0 - not used! + nval[ieta][idepth] += lval[ieta][ilay]; + dval[ieta][idepth] += lval[ieta][ilay]*darkening.degradation(iLumi,ieta+1,ilay); //be careful of eta and layer numbering + + /* + std::cout << "ilay " << ilay << " -> idepth " << idepth + << " + lval[" << ieta << "][" << ilay << "]" + << " " << lval[ieta][ilay] << std::endl; + */ + } + + //compute factors, w/ safety checks + for(unsigned int idepth = 0; idepth < nDepths; idepth++){ + if(dval[ieta][idepth] > 0) corr[ieta][idepth] = nval[ieta][idepth]/dval[ieta][idepth]; + else corr[ieta][idepth] = 1.0; + + if(corr[ieta][idepth] < 1.0) corr[ieta][idepth] = 1.0; + /* + if (idepth > 0 && idepth <= 3) { + std::cout << "nval[" << ieta << "][" << idepth << "]" + << " = " << nval[ieta][idepth] << " - " + << "dval["<< ieta << "][" << idepth << "]" + << " = " << dval[ieta][idepth] + << " corr = " << corr[ieta][idepth] << std::endl; + } + */ + } + + } + + +} diff --git a/CalibCalorimetry/HcalPlugins/src/HBRecalibration.h b/CalibCalorimetry/HcalPlugins/src/HBRecalibration.h new file mode 100644 index 0000000000000..7846c06e19725 --- /dev/null +++ b/CalibCalorimetry/HcalPlugins/src/HBRecalibration.h @@ -0,0 +1,41 @@ +#ifndef CalibCalorimetry_HBRecalibration_h +#define CalibCalorimetry_HBRecalibration_h +// +// Simple class with tabulated/parameterized function +// to compansate for darkening attenuation of HE scintillators +// in Upgrade conditions +// Evaluated on the basis of DataFormats/HcalCalibObjects/HBDarkening by K.Pedro (Maryland) +// correction = f (integrated lumi, depth, ieta) +// + +#include +#include +#include +#include "DataFormats/HcalCalibObjects/interface/HBDarkening.h" + +class HBRecalibration { + +public: + HBRecalibration(double integrated_lumi, double cutoff, unsigned int scenario); + ~HBRecalibration(); + + double getCorr(int ieta, int idepth); + void setDsegm(const std::vector >& m_segmentation); + +private: + // max number of HB recalibration depths + static const unsigned int nDepths = 7; + + void initialize(); + double iLumi; + double cutoff_; + HBDarkening darkening; + + // Tabulated mean energy values per layer and per depth + double dsegm[HBDarkening::nEtaBins][HBDarkening::nScintLayers]; + double corr[HBDarkening::nEtaBins][nDepths]; + +}; + + +#endif // HBRecalibration_h diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc index bbb2fc8f6e329..30e0ef94160ab 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc @@ -124,11 +124,16 @@ HcalHardcodeCalibrations::HcalHardcodeCalibrations ( const edm::ParameterSet& iC if( iLumi > 0.0 ) { unsigned he_recalib = iConfig.getParameter("HERecalibration"); + unsigned hb_recalib = iConfig.getParameter("HBRecalibration"); bool hf_recalib = iConfig.getParameter("HFRecalibration"); if(he_recalib) { double cutoff = iConfig.getParameter("HEreCalibCutoff"); he_recalibration = new HERecalibration(iLumi,cutoff,he_recalib); } + if(hb_recalib) { + double cutoff = iConfig.getParameter("HBreCalibCutoff"); + hb_recalibration = new HBRecalibration(iLumi,cutoff,hb_recalib); + } if(hf_recalib) hf_recalibration = new HFRecalibration(); // std::cout << " HcalHardcodeCalibrations: iLumi = " << iLumi << std::endl; diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h index 1c478e46a7bc4..764190677b798 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h @@ -13,6 +13,7 @@ #include "Geometry/CaloTopology/interface/HcalTopology.h" #include "CondFormats/HcalObjects/interface/AllObjects.h" #include "HERecalibration.h" +#include "HBRecalibration.h" #include "DataFormats/HcalCalibObjects/interface/HFRecalibration.h" class ParameterSet; @@ -89,6 +90,7 @@ class HcalHardcodeCalibrations : public edm::ESProducer, private: double iLumi; HERecalibration* he_recalibration; + HBRecalibration* hb_recalibration; HFRecalibration* hf_recalibration; bool switchGainWidthsForTrigPrims; bool setHEdsegm; diff --git a/DataFormats/HcalCalibObjects/interface/HBDarkening.h b/DataFormats/HcalCalibObjects/interface/HBDarkening.h new file mode 100644 index 0000000000000..d18b0a7faf891 --- /dev/null +++ b/DataFormats/HcalCalibObjects/interface/HBDarkening.h @@ -0,0 +1,36 @@ +#ifndef HcalCalibObjects_HBDarkening_h +#define HcalCalibObjects_HBDarkening_h +// +// Simple class with parameterizaed function to get darkening attenuation +// coefficiant for SLHC conditions +// intlumi is integrated luminosity (fb-1), +// layer is HB layer number (from 0 up to 16), NB: 1-17 in HcalTestNumbering +// +// scenario = 0 - full replacement of HB scintillators +// scenario = 1 - no replacement, full stage darkening +// + +class HBDarkening { + +public: + HBDarkening(unsigned int scenario); + ~HBDarkening(); + + float degradation(float intlumi, int ieta, int lay) const; + + static const char* scenarioDescription (unsigned int scenario); + + // 2 contsants below are used in CalibCalorimetry/HcalPlugins HERecalibration + // (1) number of HE ieta bins for darkening + static const unsigned int nEtaBins = 16; + // (2) max. number of HE scint. layers + static const unsigned int nScintLayers = 17; + +private: + int ieta_shift; + float lumiscale[nEtaBins][nScintLayers]; + +}; + + +#endif // HBDarkening_h diff --git a/DataFormats/HcalCalibObjects/src/HBDarkening.cc b/DataFormats/HcalCalibObjects/src/HBDarkening.cc new file mode 100644 index 0000000000000..f871fb09f33f5 --- /dev/null +++ b/DataFormats/HcalCalibObjects/src/HBDarkening.cc @@ -0,0 +1,81 @@ +/////////////////////////////////////////////////////////////////////////////// +// File: HBDarkening.cc +// Description: simple helper class containing parameterized function +// to be used for the SLHC darkening calculation in HB +/////////////////////////////////////////////////////////////////////////////// + +#include "DataFormats/HcalCalibObjects/interface/HBDarkening.h" +#include +#include "FWCore/MessageLogger/interface/MessageLogger.h" + +//#define DebugLog + +HBDarkening::HBDarkening(unsigned int scenario) { + //HB starts at tower 1 + ieta_shift = 1; + + //scale parameter in fb-1 for exponential darkening from radiation damage for each tile + //extrapolated from HE radiation damage model (HEDarkening) using FLUKA dose map + //notes: extrapolation ignores geometrical and material differences in HB vs. HE + // which affects the material averaging in the coarse FLUKA dose map + // also, atmosphere in the barrel has more N2 and less O2 vs. HE + //conclusion: very rough extrapolation, caveat emptor! + float _lumiscale[nEtaBins][nScintLayers] = { + {887.1,887.1,1199.3,1314.0,1615.8,1954.0,2504.1,2561.7,3249.6,4553.7,5626.1,5725.6,6777.4,8269.8,10061.8,15253.3,22200.9}, + {990.8,990.8,1140.8,1325.4,1676.9,2036.6,2900.5,2789.1,3460.2,4405.9,4184.0,5794.6,6157.4,7646.0,11116.1,18413.9,26813.3}, + {971.2,971.2,1244.3,1456.2,1760.1,2299.1,2603.2,3012.3,3933.9,4787.3,4503.9,6624.3,7059.4,9369.5,12038.0,20048.8,23541.3}, + {877.3,877.3,1145.2,1322.5,1604.9,1924.0,2893.6,2827.4,4085.0,5320.2,4740.6,5693.5,5715.1,7373.4,8305.1,16079.9,21702.3}, + {919.8,919.8,1223.2,1376.9,1742.6,1964.7,2494.7,3335.6,4520.6,4869.5,4895.6,5740.4,7089.8,8765.9,10045.7,17408.0,24726.7}, + {901.1,901.1,1114.3,1391.2,1733.2,2210.7,2733.8,3399.4,3715.2,3626.3,3371.3,4653.8,5911.6,7204.2,7584.7,4760.1,11156.8}, + {904.0,904.0,1112.9,1351.9,1722.3,2008.2,2709.8,3101.9,3470.5,4679.0,5843.6,6343.8,7883.3,11266.8,16607.2,10882.3,25428.4}, + {930.7,930.7,1225.3,1341.9,1744.0,2253.8,2805.1,3329.9,3665.6,5179.6,5677.8,5753.0,5662.3,9516.5,10769.4,13892.9,16661.1}, + {953.2,953.2,1240.4,1487.3,1719.8,1930.6,2595.7,3172.5,3881.0,5247.5,4934.0,6576.4,6353.7,9259.2,12264.5,13261.8,12222.6}, + {877.4,877.4,1114.1,1346.0,1604.9,1997.6,2708.9,3247.9,3704.4,4568.2,4984.4,7000.8,7896.7,7970.0,12555.6,10062.1,18386.8}, + {876.2,876.2,1127.1,1336.0,1753.1,1944.4,2641.1,3445.1,3810.2,4033.0,5301.2,5170.7,6062.3,9815.8,12854.2,14297.3,20692.1}, + {841.2,841.2,1051.1,1229.5,1576.5,1983.2,2282.2,2981.2,3271.7,4417.1,3765.2,4491.8,4626.6,7173.2,12953.0,7861.2,19338.6}, + {848.2,848.2,1072.8,1228.5,1497.9,1876.1,2279.7,2744.2,3325.9,4021.8,4081.1,3750.6,4584.2,6170.8,9020.5,12058.8,13492.2}, + {780.3,780.3,977.6,1103.2,1323.2,1548.3,1970.1,2217.5,2761.0,3049.0,2913.0,3832.3,4268.6,5242.1,6432.8,5999.5,6973.9}, + {515.2,515.2,662.1,836.5,1110.4,1214.4,1664.4,1919.0,2341.0,2405.2,2647.5,2593.8,2586.3,2814.4,2826.8,0.0,0.0}, + {409.3,409.3,489.2,700.3,960.2,1103.5,909.8,934.6,1148.6,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0} + }; + + //store array + //no factor needed to account for increased flux at 14 TeV vs 7-8 TeV + //already included in extrapolation from HE + for(unsigned int j = 0; j < nEtaBins; j++){ + for(unsigned int i = 0; i < nScintLayers; i++){ + if (scenario == 0) lumiscale[j][i] = 0; + else lumiscale[j][i] = _lumiscale[j][i]; + } + } +} + +HBDarkening::~HBDarkening() { } + +float HBDarkening::degradation(float intlumi, int ieta, int lay) const { + //no lumi, no darkening + if(intlumi <= 0) return 1.; + + //shift ieta tower index + ieta -= ieta_shift; + + //if outside eta range, no darkening + if(ieta < 0 || ieta >= (int)nEtaBins) return 1.; + + //layer index does not need a shift in HB + + //if outside layer range, no darkening + if(lay < 0 || lay >= (int)nScintLayers) return 1.; + + // if replaced tile by scenario + if (lumiscale[ieta][lay] == 0.0) return 1.; + + //return darkening factor + return (exp(-intlumi/lumiscale[ieta][lay])); +} + +const char* HBDarkening::scenarioDescription (unsigned int scenario) { + if (scenario == 0) return "full replacement of HE scintillators, no darkening"; + else if (scenario == 1) return "no replacement, full stage darkening"; + return "undefined scenario: assume no replacement, full stage darkening"; +} diff --git a/DataFormats/HcalCalibObjects/src/classes.h b/DataFormats/HcalCalibObjects/src/classes.h index 115746730f4c9..bd9ef6a57979f 100755 --- a/DataFormats/HcalCalibObjects/src/classes.h +++ b/DataFormats/HcalCalibObjects/src/classes.h @@ -1,5 +1,6 @@ #include "DataFormats/HcalCalibObjects/interface/HOCalibVariables.h" #include "DataFormats/HcalCalibObjects/interface/HEDarkening.h" +#include "DataFormats/HcalCalibObjects/interface/HBDarkening.h" #include "DataFormats/HcalCalibObjects/interface/HFRecalibration.h" // #include "DataFormats/HOCalibHit/interface/HOCalibVariableCollection.h" #include "DataFormats/Common/interface/Wrapper.h" @@ -7,6 +8,7 @@ namespace { struct dictionary { HEDarkening hed; + HEDarkening hbd; HFRecalibration hfr; HOCalibVariables rv1; std::vector v1; diff --git a/DataFormats/HcalCalibObjects/src/classes_def.xml b/DataFormats/HcalCalibObjects/src/classes_def.xml index 2b9c4c3a28f5d..efce567ef9b3f 100755 --- a/DataFormats/HcalCalibObjects/src/classes_def.xml +++ b/DataFormats/HcalCalibObjects/src/classes_def.xml @@ -2,6 +2,9 @@ + + + diff --git a/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py b/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py index 6fc8fef641f58..c28e9ab7daae2 100644 --- a/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py @@ -7,6 +7,7 @@ def customise_HcalPhase0(process): process.mix.digitizers.hcal.HcalReLabel.RelabelHits=cms.untracked.bool(True) process.es_hardcode.HEreCalibCutoff = cms.double(20.) #for aging + process.es_hardcode.HBreCalibCutoff = cms.double(20.) #for aging process.es_hardcode.toGet = cms.untracked.vstring( 'GainWidths', @@ -47,6 +48,7 @@ def customise_HcalPhase1(process): # Special Upgrade trick (if absent - regular case assumed) process.es_hardcode.GainWidthsForTrigPrims = cms.bool(True) process.es_hardcode.HEreCalibCutoff = cms.double(100.) #for aging + process.es_hardcode.HBreCalibCutoff = cms.double(100.) #for aging if hasattr(process,'g4SimHits'): process=customise_Sim(process) diff --git a/SLHCUpgradeSimulations/Configuration/python/aging.py b/SLHCUpgradeSimulations/Configuration/python/aging.py index a0716f0937a29..bff39ae2ad0fd 100644 --- a/SLHCUpgradeSimulations/Configuration/python/aging.py +++ b/SLHCUpgradeSimulations/Configuration/python/aging.py @@ -228,9 +228,6 @@ def turn_off_HE_aging(process): process.mix.digitizers.hcal.HEDarkening = cms.uint32(0) if hasattr(process,'es_hardcode'): process.es_hardcode.HERecalibration = cms.uint32(0) - if hasattr(process,'simHcalDigis'): - process.simHcalDigis.HBlevel=cms.int32(16) - process.simHcalDigis.HElevel=cms.int32(16) return process def set_HE_aging_scenario(process,scenario): @@ -240,6 +237,20 @@ def set_HE_aging_scenario(process,scenario): process.es_hardcode.HERecalibration = cms.uint32(scenario) return process +def turn_off_HB_aging(process): + if hasattr(process,'mix') and hasattr(process.mix,'digitizers') and hasattr(process.mix.digitizers,'hcal'): + process.mix.digitizers.hcal.HBDarkening = cms.uint32(0) + if hasattr(process,'es_hardcode'): + process.es_hardcode.HBRecalibration = cms.uint32(0) + return process + +def set_HB_aging_scenario(process,scenario): + if hasattr(process,'mix') and hasattr(process.mix,'digitizers') and hasattr(process.mix.digitizers,'hcal'): + process.mix.digitizers.hcal.HBDarkening = cms.uint32(scenario) + if hasattr(process,'es_hardcode'): + process.es_hardcode.HBRecalibration = cms.uint32(scenario) + return process + def turn_off_HF_aging(process): if hasattr(process,'g4SimHits'): process.g4SimHits.HCalSD.HFDarkening = cms.untracked.bool(False) diff --git a/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h b/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h index 327c6c79672a8..7856c2066f634 100644 --- a/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h +++ b/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h @@ -15,6 +15,7 @@ #include "DataFormats/DetId/interface/DetId.h" #include "FWCore/Framework/interface/Frameworkfwd.h" #include "DataFormats/HcalCalibObjects/interface/HEDarkening.h" +#include "DataFormats/HcalCalibObjects/interface/HBDarkening.h" #include "DataFormats/HcalCalibObjects/interface/HFRecalibration.h" #include @@ -140,6 +141,7 @@ class HcalDigitizer double deliveredLumi; HEDarkening* m_HEDarkening; + HBDarkening* m_HBDarkening; HFRecalibration* m_HFRecalibration; }; diff --git a/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py b/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py index a2f4603012247..a91bcafda02fe 100644 --- a/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py +++ b/SimCalorimetry/HcalSimProducers/python/hcalUnsuppressedDigis_cfi.py @@ -39,6 +39,7 @@ HcalReLabel = HcalReLabel, DelivLuminosity = cms.double(0), HEDarkening = cms.uint32(0), + HBDarkening = cms.uint32(0), HFDarkening = cms.bool(False) ) diff --git a/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc b/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc index b8ec01fb824d2..c723b2e8947f8 100644 --- a/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc +++ b/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc @@ -133,6 +133,7 @@ HcalDigitizer::HcalDigitizer(const edm::ParameterSet& ps) : theHOSiPMCode(ps.getParameter("ho").getParameter("siPMCode")), deliveredLumi(0.), m_HEDarkening(0), + m_HBDarkening(0), m_HFRecalibration(0) { bool doNoise = ps.getParameter("doNoise"); @@ -149,6 +150,7 @@ HcalDigitizer::HcalDigitizer(const edm::ParameterSet& ps) : bool doHFUpgrade = ps.getParameter("HFUpgradeQIE"); deliveredLumi = ps.getParameter("DelivLuminosity"); unsigned int agingFlagHE = ps.getParameter("HEDarkening"); + unsigned int agingFlagHB = ps.getParameter("HBDarkening"); bool agingFlagHF = ps.getParameter("HFDarkening"); // need to make copies, because they might get different noise generators @@ -326,8 +328,8 @@ HcalDigitizer::HcalDigitizer(const edm::ParameterSet& ps) : if (theHitCorrection!=0) theHitCorrection->setRandomEngine(engine); hitsProducer_ = ps.getParameter("hitsProducer"); - if(agingFlagHE) m_HEDarkening = new HEDarkening(agingFlagHE); + if(agingFlagHB) m_HBDarkening = new HBDarkening(agingFlagHB); if(agingFlagHF) m_HFRecalibration = new HFRecalibration(); } @@ -363,6 +365,9 @@ HcalDigitizer::~HcalDigitizer() { delete theHitCorrection; delete theNoiseGenerator; if (theRelabeller) delete theRelabeller; + if(m_HEDarkening) delete m_HEDarkening; + if(m_HBDarkening) delete m_HBDarkening; + if(m_HFRecalibration) delete m_HFRecalibration; } @@ -717,6 +722,12 @@ void HcalDigitizer::darkening(std::vector& hcalHits){ darkened = true; } + //HB darkening + else if(det==int(HcalBarrel) && m_HBDarkening){ + dweight = m_HBDarkening->degradation(deliveredLumi,ieta,lay-1);//NB:diff. layer count + darkened = true; + } + //HF darkening - approximate: invert recalibration factor else if(det==int(HcalForward) && m_HFRecalibration){ dweight = 1.0/m_HFRecalibration->getCorr(ieta,depth,deliveredLumi); diff --git a/SimG4CMS/Calo/interface/HCalSD.h b/SimG4CMS/Calo/interface/HCalSD.h index 754653e6a989b..ca25308e71480 100644 --- a/SimG4CMS/Calo/interface/HCalSD.h +++ b/SimG4CMS/Calo/interface/HCalSD.h @@ -15,6 +15,7 @@ #include "SimG4CMS/Calo/interface/HFShowerFibreBundle.h" #include "SimG4CMS/Calo/interface/HcalNumberingScheme.h" #include "DataFormats/HcalCalibObjects/interface/HEDarkening.h" +#include "DataFormats/HcalCalibObjects/interface/HBDarkening.h" #include "SimG4CMS/Calo/interface/HFDarkening.h" #include "DetectorDescription/Core/interface/DDsvalues.h" #include "Geometry/HcalCommonData/interface/HcalNumberingFromDDD.h" @@ -83,6 +84,7 @@ class HCalSD : public CaloSD { HFShowerPMT * showerPMT; HFShowerFibreBundle * showerBundle; HEDarkening * m_HEDarkening; + HBDarkening * m_HBDarkening; HFDarkening * m_HFDarkening; bool useBirk, useLayerWt, useFibreBundle, usePMTHit, testNumber; double birk1, birk2, birk3, betaThr; diff --git a/SimG4CMS/Calo/src/HCalSD.cc b/SimG4CMS/Calo/src/HCalSD.cc index 7d78950d9598c..e1f7d8af48465 100644 --- a/SimG4CMS/Calo/src/HCalSD.cc +++ b/SimG4CMS/Calo/src/HCalSD.cc @@ -65,6 +65,7 @@ HCalSD::HCalSD(G4String name, const DDCompactView & cpv, useFibreBundle = m_HC.getParameter("UseFibreBundleHits"); deliveredLumi = m_HC.getParameter("DelivLuminosity"); unsigned int ageingFlagHE= m_HC.getParameter("HEDarkening"); + unsigned int ageingFlagHB= m_HC.getParameter("HBDarkening"); bool ageingFlagHF= m_HC.getParameter("HFDarkening"); useHF = m_HC.getUntrackedParameter("UseHF",true); bool forTBH2 = m_HC.getUntrackedParameter("ForTBH2",false); @@ -102,6 +103,8 @@ HCalSD::HCalSD(G4String name, const DDCompactView & cpv, << "Delivered luminosity for Darkening " << deliveredLumi << " Flag (HE) " << ageingFlagHE << " (" << HEDarkening::scenarioDescription(ageingFlagHE) << ")" + << " Flag (HB) " << ageingFlagHB + << " (" << HBDarkening::scenarioDescription(ageingFlagHB) << ")" << " Flag (HF) " << ageingFlagHF << "\n" << "Application of Fiducial Cut " << applyFidCut; @@ -325,6 +328,7 @@ HCalSD::HCalSD(G4String name, const DDCompactView & cpv, hzvem = hzvhad = 0; if (ageingFlagHE) m_HEDarkening = new HEDarkening(ageingFlagHE); + if (ageingFlagHB) m_HBDarkening = new HBDarkening(ageingFlagHB); if (ageingFlagHF) m_HFDarkening = new HFDarkening(); #ifdef plotDebug edm::Service tfile; @@ -375,6 +379,7 @@ HCalSD::~HCalSD() { if (showerPMT) delete showerPMT; if (showerBundle) delete showerBundle; if (m_HEDarkening) delete m_HEDarkening; + if (m_HBDarkening) delete m_HBDarkening; if (m_HFDarkening) delete m_HFDarkening; } @@ -518,6 +523,28 @@ double HCalSD::getEnergyDeposit(G4Step* aStep) { << " coefficient = " << dweight; #endif } + + else if (m_HBDarkening !=0 && det == 0) { + int lay = (touch->GetReplicaNumber(0)/10)%100 + 1; + int ieta; + uint32_t detid = setDetUnitId(aStep); + if(testNumber) { + int det, z, depth, eta, phi, lay; + HcalTestNumbering::unpackHcalIndex(detid,det,z,depth,eta,phi,lay); + ieta = eta; + } + else ieta = HcalDetId(detid).ietaAbs(); +#ifdef DebugLog + edm::LogInfo("HcalSimDark") << "HCalSD:HB_Darkening >>> ieta: "<< ieta //<< " vs. ietaAbs(): " << HcalDetId(detid).ietaAbs() + << " lay: " << lay-1; +#endif + float dweight = m_HBDarkening->degradation(deliveredLumi,ieta,lay-1);//NB:diff. layer count + weight *= dweight; +#ifdef DebugLog + edm::LogInfo("HcalSimDark") << "HCalSD: >>> Lumi: " << deliveredLumi + << " coefficient = " << dweight; +#endif + } if (suppressHeavy) { TrackInformation * trkInfo = (TrackInformation *)(theTrack->GetUserInformation()); diff --git a/SimG4Core/Application/python/g4SimHits_cfi.py b/SimG4Core/Application/python/g4SimHits_cfi.py index 11569ad8b7edb..b1343cb172585 100644 --- a/SimG4Core/Application/python/g4SimHits_cfi.py +++ b/SimG4Core/Application/python/g4SimHits_cfi.py @@ -270,6 +270,7 @@ TimeSliceUnit = cms.double(1), IgnoreTrackID = cms.bool(False), HEDarkening = cms.uint32(0), + HBDarkening = cms.uint32(0), HFDarkening = cms.bool(False), UseHF = cms.untracked.bool(True), ForTBH2 = cms.untracked.bool(False), From fc914b035591309d9ecf90adcad9f35bc545da44 Mon Sep 17 00:00:00 2001 From: Kevin Date: Tue, 28 Oct 2014 21:03:22 +0100 Subject: [PATCH 236/252] finish implementing HB recalibration --- .../src/HcalHardcodeCalibrations.cc | 29 +++++++++++++++---- .../src/HcalHardcodeCalibrations.h | 1 + 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc index 30e0ef94160ab..58c69fe4112a1 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc @@ -108,7 +108,7 @@ namespace { } -HcalHardcodeCalibrations::HcalHardcodeCalibrations ( const edm::ParameterSet& iConfig ): he_recalibration(0), hf_recalibration(0), setHEdsegm(false) +HcalHardcodeCalibrations::HcalHardcodeCalibrations ( const edm::ParameterSet& iConfig ): he_recalibration(0), hb_recalibration(0), hf_recalibration(0), setHEdsegm(false), setHBdsegm(false) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::HcalHardcodeCalibrations->..."; @@ -364,16 +364,22 @@ std::auto_ptr HcalHardcodeCalibrations::produceRespCorrs (const H rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); - //set depth segmentation for HE recalib - only happens once - if(he_recalibration && !setHEdsegm){ + //set depth segmentation for HB/HE recalib - only happens once + if((he_recalibration && !setHEdsegm) || (hb_recalibration && !setHBdsegm)){ std::vector> m_segmentation; m_segmentation.resize(29); for (int i = 0; i < 29; i++) { if(i>0) topo->getDepthSegmentation(i,m_segmentation[i]); } - he_recalibration->setDsegm(m_segmentation); - setHEdsegm = true; + if(he_recalibration && !setHEdsegm){ + he_recalibration->setDsegm(m_segmentation); + setHEdsegm = true; + } + if(hb_recalibration && !setHBdsegm){ + hb_recalibration->setDsegm(m_segmentation); + setHBdsegm = true; + } } std::auto_ptr result (new HcalRespCorrs (topo)); @@ -394,6 +400,19 @@ std::auto_ptr HcalHardcodeCalibrations::produceRespCorrs (const H << " corr = " << corr << std::endl; */ + } + else if ((hb_recalibration != 0 ) && + ((*cell).genericSubdet() == HcalGenericDetId::HcalGenBarrel)) { + + int depth_ = HcalDetId(*cell).depth(); + int ieta_ = HcalDetId(*cell).ieta(); + corr = hb_recalibration->getCorr(ieta_, depth_); + + /* + std::cout << "HB ieta, depth = " << ieta_ << ", " << depth_ + << " corr = " << corr << std::endl; + */ + } else if ((hf_recalibration != 0 ) && ((*cell).genericSubdet() == HcalGenericDetId::HcalGenForward)) { diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h index 764190677b798..260f56a16c5dc 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.h @@ -94,5 +94,6 @@ class HcalHardcodeCalibrations : public edm::ESProducer, HFRecalibration* hf_recalibration; bool switchGainWidthsForTrigPrims; bool setHEdsegm; + bool setHBdsegm; }; From 50d5233f99e1b2e8a7503687262758647a33bbc4 Mon Sep 17 00:00:00 2001 From: Kevin Date: Tue, 28 Oct 2014 21:41:57 +0100 Subject: [PATCH 237/252] fix index bug in depth segmentation for recalibration --- CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc | 2 +- CalibCalorimetry/HcalPlugins/src/HERecalibration.cc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc b/CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc index ef87eda0879fd..b5c7bbb3cce96 100644 --- a/CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc +++ b/CalibCalorimetry/HcalPlugins/src/HBRecalibration.cc @@ -21,7 +21,7 @@ void HBRecalibration::setDsegm( const std::vector>& m_segmentat for (unsigned int ieta = 0; ieta < HBDarkening::nEtaBins; ieta++) { // std::cout << "["<< ieta << "] ieta =" << ieta + 16 << " "; for(unsigned int ilay = 0; ilay < HBDarkening::nScintLayers; ilay++) { - dsegm[ieta][ilay] = m_segmentation[ieta][ilay]; // 0 not used + dsegm[ieta][ilay] = m_segmentation[ieta+1][ilay]; // 0 not used // std::cout << dsegm [ieta][ilay]; } // std::cout << std::endl; diff --git a/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc b/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc index 08a5ed04ea2bd..92780a89a8b62 100644 --- a/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc +++ b/CalibCalorimetry/HcalPlugins/src/HERecalibration.cc @@ -21,7 +21,7 @@ void HERecalibration::setDsegm( const std::vector>& m_segmentat for (unsigned int ieta = 0; ieta < HEDarkening::nEtaBins; ieta++) { // std::cout << "["<< ieta << "] ieta =" << ieta + 16 << " "; for(unsigned int ilay = 0; ilay < HEDarkening::nScintLayers; ilay++) { - dsegm[ieta][ilay] = m_segmentation[ieta+15][ilay]; // 0 not used + dsegm[ieta][ilay] = m_segmentation[ieta+16][ilay]; // 0 not used // std::cout << dsegm [ieta][ilay]; } // std::cout << std::endl; From ef78ad16ec0a8aba14208ff0a9ac57bc11bd24d8 Mon Sep 17 00:00:00 2001 From: Kevin Date: Tue, 28 Oct 2014 21:56:26 +0100 Subject: [PATCH 238/252] additional fix for prev. bug --- CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc index 58c69fe4112a1..7a32a7e5a28d6 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc @@ -367,8 +367,8 @@ std::auto_ptr HcalHardcodeCalibrations::produceRespCorrs (const H //set depth segmentation for HB/HE recalib - only happens once if((he_recalibration && !setHEdsegm) || (hb_recalibration && !setHBdsegm)){ std::vector> m_segmentation; - m_segmentation.resize(29); - for (int i = 0; i < 29; i++) { + m_segmentation.resize(30); + for (int i = 0; i < 30; i++) { if(i>0) topo->getDepthSegmentation(i,m_segmentation[i]); } From e2328b84f75ddb5add7cdee62e2276aebb37d9bf Mon Sep 17 00:00:00 2001 From: Josh Bendavid Date: Wed, 29 Oct 2014 00:35:59 +0100 Subject: [PATCH 239/252] update noise parameters for shashlik multifit to treat quantization error as uncorrelated noise --- .../python/ecalPulseShapeParameters_cff.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py index 71ac0f2179943..a0a6e23afe248 100644 --- a/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py +++ b/RecoLocalCalo/EcalRecProducers/python/ecalPulseShapeParameters_cff.py @@ -95,14 +95,14 @@ #but that could cause undesirable numerical problems #downstream if taken too literally EKCorrNoiseMatrixG12 = cms.vdouble ( - 0.084233, 0.083976, 0.083737, 0.083605, 0.083528, - 0.083466, 0.083439, 0.083425, 0.083419, 0.083406 ) , + 8.4233E-2, 6.4236E-4, 4.0343E-4, 2.7137E-4, 1.9448E-4, + 1.3307E-4, 1.0595E-4, 9.1485E-5, 8.5185E-5, 7.2882E-5 ), EKCorrNoiseMatrixG06 = cms.vdouble ( - 0.084233, 0.083974, 0.083761, 0.083640, 0.083570, - 0.083516, 0.083493, 0.083480, 0.083474, 0.083463 ), + 8.4233E-2, 6.4095E-4, 4.2718E-4, 3.0650E-4, 2.3654E-4, + 1.8258E-4, 1.5961E-4, 1.4630E-4, 1.4056E-4, 1.2999E-4 ), EKCorrNoiseMatrixG01 = cms.vdouble ( - 0.084233, 0.083988, 0.083892, 0.083835, 0.083800, - 0.083776, 0.083764, 0.083756, 0.083753, 0.083750 ) + 8.4233E-2, 6.5428E-4, 5.5843E-4, 5.0122E-4, 4.6663E-4, + 4.4232E-4, 4.3032E-4, 4.2306E-4, 4.1959E-4, 4.1639E-4 ), ) ecal_pulse_shape_parameters = cms.PSet( From 062bec9aba019ac19bf904c5c575832c827b1739 Mon Sep 17 00:00:00 2001 From: Sven Dildick Date: Wed, 29 Oct 2014 17:12:31 +0100 Subject: [PATCH 240/252] enable CSC-RPC ILT for positive endcap --- L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc | 2 +- .../CSCTriggerPrimitives/src/CSCTriggerPrimitivesBuilder.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc index f886a77cba1de..138dd4d8fb3a9 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc @@ -120,7 +120,7 @@ CSCMotherboard::CSCMotherboard(unsigned endcap, unsigned station, alctParams = conf.getParameter("alctSLHCME21"); clctParams = conf.getParameter("clctSLHCME21"); } - else if ((theStation == 3 or theStation == 4) and theEndcap==2 and runME3141ILT) { + else if ((theStation == 3 or theStation == 4) and runME3141ILT) { tmbParams = me3141tmbRpcParams; alctParams = conf.getParameter("alctSLHCME3141"); clctParams = conf.getParameter("clctSLHCME3141"); diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCTriggerPrimitivesBuilder.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCTriggerPrimitivesBuilder.cc index 5f18e32c2aebb..7fe21c2c330ed 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCTriggerPrimitivesBuilder.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCTriggerPrimitivesBuilder.cc @@ -98,7 +98,7 @@ CSCTriggerPrimitivesBuilder::CSCTriggerPrimitivesBuilder(const edm::ParameterSet tmb_[endc-1][stat-1][sect-1][subs-1][cham-1] = new CSCMotherboardME11GEM(endc, stat, sect, subs, cham, conf); else if (stat==2 && ring==1 && runME21ILT_) tmb_[endc-1][stat-1][sect-1][subs-1][cham-1] = new CSCMotherboardME21GEM(endc, stat, sect, subs, cham, conf); - else if ((stat==3 || stat==4) && ring==1 && runME3141ILT_ and endc==2) + else if ((stat==3 || stat==4) && ring==1 && runME3141ILT_) tmb_[endc-1][stat-1][sect-1][subs-1][cham-1] = new CSCMotherboardME3141RPC(endc, stat, sect, subs, cham, conf); else tmb_[endc-1][stat-1][sect-1][subs-1][cham-1] = new CSCMotherboard(endc, stat, sect, subs, cham, conf); @@ -538,7 +538,7 @@ void CSCTriggerPrimitivesBuilder::build(const CSCBadChambers* badChambers, } // running upgraded ME3/1-ME4/1 TMBs - else if ((stat==3 or stat==4) && ring==1 && runME3141ILT_ and endc==2) + else if ((stat==3 or stat==4) && ring==1 && runME3141ILT_) { CSCMotherboardME3141RPC* tmb3141RPC = static_cast(tmb); tmb3141RPC->setCSCGeometry(csc_g); From b29dc6ee0dfc323166de3e681a59cc138984bacb Mon Sep 17 00:00:00 2001 From: Seb Date: Thu, 30 Oct 2014 14:20:28 +0100 Subject: [PATCH 241/252] AM PR optimisation --- .../TrackFindingAM/interface/PatternTree.h | 12 ++ .../TrackFindingAM/interface/PatternTrunk.h | 6 +- .../TrackFindingAM/interface/SectorTree.h | 2 +- L1Trigger/TrackFindingAM/src/PatternFinder.cc | 6 + L1Trigger/TrackFindingAM/src/PatternTree.cc | 187 +++++++++++++++--- L1Trigger/TrackFindingAM/src/SectorTree.cc | 12 +- 6 files changed, 189 insertions(+), 36 deletions(-) diff --git a/L1Trigger/TrackFindingAM/interface/PatternTree.h b/L1Trigger/TrackFindingAM/interface/PatternTree.h index 608760087487c..1873e29754999 100644 --- a/L1Trigger/TrackFindingAM/interface/PatternTree.h +++ b/L1Trigger/TrackFindingAM/interface/PatternTree.h @@ -99,8 +99,15 @@ class PatternTree{ **/ bool checkPattern(Pattern* lp, Pattern* hp); + /** + \brief Replace the internal map of patterns with a vector of patterns (reduces memory consumption). + \brief If a method searching for a pattern is called, we will automatically switch back to a map. + **/ + void switchToVector(); + private: map patterns; + vector v_patterns; /** \brief Add a pattern and update de DC bits if necessary @@ -108,6 +115,11 @@ class PatternTree{ **/ void addPatternForMerging(GradedPattern* ldp); + /** + \brief Update the internal map and clear the internal vector + **/ + void switchToMap(); + friend class boost::serialization::access; template void save(Archive & ar, const unsigned int version) const{ diff --git a/L1Trigger/TrackFindingAM/interface/PatternTrunk.h b/L1Trigger/TrackFindingAM/interface/PatternTrunk.h index 63db376d32e10..ac1dcf95ca909 100644 --- a/L1Trigger/TrackFindingAM/interface/PatternTrunk.h +++ b/L1Trigger/TrackFindingAM/interface/PatternTrunk.h @@ -147,12 +147,14 @@ class PatternTrunk{ friend class boost::serialization::access; template void save(Archive & ar, const unsigned int version) const{ - ar << lowDefPattern;; + ar << lowDefPattern; ar << fullDefPatterns; } template void load(Archive & ar, const unsigned int version){ - ar >> lowDefPattern;; + if(lowDefPattern!=NULL) + delete lowDefPattern; + ar >> lowDefPattern; ar >> fullDefPatterns; } diff --git a/L1Trigger/TrackFindingAM/interface/SectorTree.h b/L1Trigger/TrackFindingAM/interface/SectorTree.h index f77af83022cbb..118342792a00f 100644 --- a/L1Trigger/TrackFindingAM/interface/SectorTree.h +++ b/L1Trigger/TrackFindingAM/interface/SectorTree.h @@ -34,6 +34,7 @@ class SectorTree{ private: multimap sectors; + bool mapNeedsUpdate; vector sector_list; /** \brief used to know the superstrip size used for the patterns contained in this sectorTree. @@ -53,7 +54,6 @@ class SectorTree{ template void load(Archive & ar, const unsigned int version){ ar >> sector_list; ar >> superStripSize; - updateSectorMap(); } BOOST_SERIALIZATION_SPLIT_MEMBER() diff --git a/L1Trigger/TrackFindingAM/src/PatternFinder.cc b/L1Trigger/TrackFindingAM/src/PatternFinder.cc index 6328cfeaedc34..f76c0f067fd01 100644 --- a/L1Trigger/TrackFindingAM/src/PatternFinder.cc +++ b/L1Trigger/TrackFindingAM/src/PatternFinder.cc @@ -7,6 +7,9 @@ PatternFinder::PatternFinder(int sp, int at, SectorTree* st, string f, string of eventsFilename = f; outputFileName = of; + //we don't need the map of patterns, a vector will be enough and uses less memory + sectors->getAllSectors()[0]->getPatternTree()->switchToVector(); + map< int, vector > detector_config = Sector::readConfig("detector.cfg"); //We add the layers corresponding to the sectors structure @@ -40,6 +43,9 @@ PatternFinder::PatternFinder(int sp, int at, SectorTree* st, string f, string of d_p_bank = p; d_parameters = dp; + //we don't need the map of patterns, a vector will be enough and uses less memory + sectors->getAllSectors()[0]->getPatternTree()->switchToVector(); + //we use 1024 threads and want to compute the number of blocks int nb_patterns = sectors->getAllSectors()[0]->getLDPatternNumber(); nb_threads = 1024; diff --git a/L1Trigger/TrackFindingAM/src/PatternTree.cc b/L1Trigger/TrackFindingAM/src/PatternTree.cc index ea80ed5d04810..b772820ecbdbd 100644 --- a/L1Trigger/TrackFindingAM/src/PatternTree.cc +++ b/L1Trigger/TrackFindingAM/src/PatternTree.cc @@ -4,12 +4,23 @@ PatternTree::PatternTree(){ } PatternTree::~PatternTree(){ - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - delete (itr->second); + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + delete (itr->second); + } + patterns.clear(); + } + if(v_patterns.size()!=0){ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + delete (*itr); + } + v_patterns.clear(); } } void PatternTree::addPattern(Pattern* ldp, Pattern* fdp){ + if(patterns.size()==0) + switchToMap(); string key = ldp->getKey(); map::iterator it = patterns.find(key); if(it==patterns.end()){//not found @@ -23,6 +34,8 @@ void PatternTree::addPattern(Pattern* ldp, Pattern* fdp){ } void PatternTree::addPattern(Pattern* ldp, Pattern* fdp, float new_pt){ + if(patterns.size()==0) + switchToMap(); string key = ldp->getKey(); map::iterator it = patterns.find(key); if(it==patterns.end()){//not found @@ -35,20 +48,53 @@ void PatternTree::addPattern(Pattern* ldp, Pattern* fdp, float new_pt){ } } +void PatternTree::switchToVector(){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + v_patterns.push_back(itr->second); + } + patterns.clear(); +} + +void PatternTree::switchToMap(){ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + GradedPattern* gp = (*itr)->getLDPattern(); + string key = gp->getKey(); + patterns[key]=*itr; + delete gp; + } + v_patterns.clear(); +} + vector PatternTree::getFDPatterns(){ vector res; - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - vector fdp = itr->second->getFDPatterns(); - res.insert(res.end(), fdp.begin(), fdp.end()); + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + vector fdp = itr->second->getFDPatterns(); + res.insert(res.end(), fdp.begin(), fdp.end()); + } + } + if(v_patterns.size()!=0){ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + vector fdp = (*itr)->getFDPatterns(); + res.insert(res.end(),fdp.begin(),fdp.end()); + } } return res; } vector PatternTree::getLDPatterns(){ vector res; - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - GradedPattern* ldp = itr->second->getLDPattern(); - res.push_back(ldp); + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + GradedPattern* ldp = itr->second->getLDPattern(); + res.push_back(ldp); + } + } + if(v_patterns.size()!=0){ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + GradedPattern* ldp = (*itr)->getLDPattern(); + res.push_back(ldp); + } } return res; } @@ -58,13 +104,26 @@ vector PatternTree::getPTHisto(){ for(int i=0;i<150;i++){ h.push_back(0); } - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - float pt = itr->second->getLDPatternPT(); - if(pt>149) - pt=149; - if(pt<0) - pt=0; - h[(int)pt]=h[(int)pt]+1; + + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + float pt = itr->second->getLDPatternPT(); + if(pt>149) + pt=149; + if(pt<0) + pt=0; + h[(int)pt]=h[(int)pt]+1; + } + } + if(v_patterns.size()!=0){ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + float pt = (*itr)->getLDPatternPT(); + if(pt>149) + pt=149; + if(pt<0) + pt=0; + h[(int)pt]=h[(int)pt]+1; + } } return h; } @@ -72,37 +131,103 @@ vector PatternTree::getPTHisto(){ int PatternTree::getFDPatternNumber(){ vector res; int num=0; - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - num += itr->second->getFDPatternNumber(); + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + num += itr->second->getFDPatternNumber(); + } + } + if(v_patterns.size()!=0){ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + num += (*itr)->getFDPatternNumber(); + } } return num; } int PatternTree::getLDPatternNumber(){ - return patterns.size(); + if(patterns.size()!=0) + return patterns.size(); + else + return v_patterns.size(); } void PatternTree::computeAdaptativePatterns(short r){ - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - itr->second->computeAdaptativePattern(r); + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + itr->second->computeAdaptativePattern(r); + } + } + else{ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + (*itr)->computeAdaptativePattern(r); + } } } void PatternTree::link(Detector& d, const vector< vector >& sec, const vector > >& modules){ - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - itr->second->link(d,sec, modules); + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + itr->second->link(d,sec, modules); + } + } + else{ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + (*itr)->link(d,sec, modules); + } } } +#ifdef IPNL_USE_CUDA +void PatternTree::linkCuda(patternBank* p, deviceDetector* d, const vector< vector >& sec, const vector > >& modules, vector layers){ + int counter=0; + unsigned int* cache = new unsigned int[PATTERN_LAYERS*PATTERN_SSTRIPS]; + if(patterns.size()!=0){ + cudaSetNbPatterns(p, patterns.size()); + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + itr->second->linkCuda(p, d, counter, sec, modules, layers, cache); + counter++; + if(counter%10000==0){ + cout<::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + (*itr)->linkCuda(p, d, counter, sec, modules, layers, cache); + counter++; + if(counter%10000==0){ + cout<& active_patterns){ - for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ - GradedPattern* p = itr->second->getActivePattern(active_threshold); - if(p!=NULL) - active_patterns.push_back(p); + if(patterns.size()!=0){ + for(map::iterator itr = patterns.begin(); itr != patterns.end(); ++itr){ + GradedPattern* p = itr->second->getActivePattern(active_threshold); + if(p!=NULL) + active_patterns.push_back(p); + } + } + else{ + for(vector::iterator itr = v_patterns.begin(); itr != v_patterns.end(); ++itr){ + GradedPattern* p = (*itr)->getActivePattern(active_threshold); + if(p!=NULL) + active_patterns.push_back(p); + } } } void PatternTree::addPatternsFromTree(PatternTree* p){ + if(patterns.size()==0) + switchToMap(); vector ld = p->getLDPatterns(); for(unsigned int i=0;igetKey(); map::iterator it = patterns.find(key); if(it==patterns.end()){//not found @@ -126,13 +253,15 @@ void PatternTree::addPatternForMerging(GradedPattern* ldp){ } else{ (it->second)->updateDCBits(ldp); - for(int i=0;igetGrade();i++){ - (it->second)->addFDPattern(NULL, ldp->getAveragePt()); - } + for(int i=0;igetGrade();i++){ + (it->second)->addFDPattern(NULL, ldp->getAveragePt()); + } } } bool PatternTree::checkPattern(Pattern* lp, Pattern* hp){ + if(patterns.size()==0) + switchToMap(); if(lp==NULL || hp==NULL) return false; string key = lp->getKey(); diff --git a/L1Trigger/TrackFindingAM/src/SectorTree.cc b/L1Trigger/TrackFindingAM/src/SectorTree.cc index 839d37d5fa704..dc6a6bb37f334 100644 --- a/L1Trigger/TrackFindingAM/src/SectorTree.cc +++ b/L1Trigger/TrackFindingAM/src/SectorTree.cc @@ -3,6 +3,7 @@ SectorTree::SectorTree(){ srand ( time(NULL) ); superStripSize=-1; + mapNeedsUpdate=true; } SectorTree::~SectorTree(){ @@ -12,6 +13,11 @@ SectorTree::~SectorTree(){ } Sector* SectorTree::getSector(vector ladders, vector modules){ + + // check that the multimap is populated + if(mapNeedsUpdate) + updateSectorMap(); + pair::iterator,multimap::iterator> ret; multimap::iterator first; @@ -63,10 +69,7 @@ Sector* SectorTree::getSector(const Hit& h){ void SectorTree::addSector(Sector s){ Sector* ns = new Sector(s); sector_list.push_back(ns); - vector keys = ns->getKeys(); - for(unsigned int i=0;i(keys[i],ns)); - } + mapNeedsUpdate = true; } void SectorTree::updateSectorMap(){ @@ -78,6 +81,7 @@ void SectorTree::updateSectorMap(){ sectors.insert(pair(keys[i],ns)); } } + mapNeedsUpdate=false; } vector SectorTree::getAllSectors(){ From e10ca0a8466c48043acf77edd5260d36d0c90477 Mon Sep 17 00:00:00 2001 From: Michail Date: Fri, 31 Oct 2014 17:55:29 +0100 Subject: [PATCH 242/252] Putting the depth in the position calculator --- .../src/Basic2DGenericPFlowPositionCalc.cc | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/RecoParticleFlow/PFClusterProducer/src/Basic2DGenericPFlowPositionCalc.cc b/RecoParticleFlow/PFClusterProducer/src/Basic2DGenericPFlowPositionCalc.cc index 9ef85d348d20d..0754385be65a8 100644 --- a/RecoParticleFlow/PFClusterProducer/src/Basic2DGenericPFlowPositionCalc.cc +++ b/RecoParticleFlow/PFClusterProducer/src/Basic2DGenericPFlowPositionCalc.cc @@ -36,6 +36,8 @@ calculateAndSetPositionActual(reco::PFCluster& cluster) const { //Michalis : Even if we dont use timing in clustering here we should fill //the time information for the cluster. This should use the timing resolution(1/E) //so the weight should be fraction*E^2 + //calculate a simplistic depth now. The log weighted will be done + //in different stage for( const reco::PFRecHitFraction& rhf : cluster.recHitFractions() ) { const reco::PFRecHitRef& refhit = rhf.recHitRef(); if( refhit->detId() == cluster.seed() ) refseed = refhit; @@ -48,7 +50,6 @@ calculateAndSetPositionActual(reco::PFCluster& cluster) const { << "The input of the particle flow clustering seems to be corrupted."; } cl_energy += rh_energy; - // If time resolution is given, calculated weighted average if (_timeResolutionCalcBarrel && _timeResolutionCalcEndcap) { double res2 = 10000.; @@ -77,6 +78,8 @@ calculateAndSetPositionActual(reco::PFCluster& cluster) const { cluster.setTime(cl_time/cl_timeweight); cluster.setLayer(max_e_layer); // calculate the position + + double depth = 0.0; double position_norm = 0.0; double x(0.0),y(0.0),z(0.0); const reco::PFRecHitRefVector* seedNeighbours = NULL; @@ -93,9 +96,6 @@ calculateAndSetPositionActual(reco::PFCluster& cluster) const { for( const reco::PFRecHitFraction& rhf : cluster.recHitFractions() ) { const reco::PFRecHitRef& refhit = rhf.recHitRef(); - - // since this is 2D position calc only use neighbours in the same layer - if( refhit->depth() != refseed->depth() ) continue; if( refhit != refseed && _posCalcNCrystals != -1 ) { auto pos = std::find(seedNeighbours->begin(),seedNeighbours->end(), @@ -103,8 +103,6 @@ calculateAndSetPositionActual(reco::PFCluster& cluster) const { if( pos == seedNeighbours->end() ) continue; } - - const double rh_energy = refhit->energy() * ((float)rhf.fraction()); const double norm = ( rhf.fraction() < _minFractionInCalc ? 0.0 : @@ -113,6 +111,8 @@ calculateAndSetPositionActual(reco::PFCluster& cluster) const { x += rhpos_xyz.X() * norm; y += rhpos_xyz.Y() * norm; z += rhpos_xyz.Z() * norm; + depth += refhit->depth()*norm; + position_norm += norm; } if( position_norm < _minAllowedNorm ) { @@ -125,7 +125,9 @@ calculateAndSetPositionActual(reco::PFCluster& cluster) const { x *= norm_inverse; y *= norm_inverse; z *= norm_inverse; + depth *= norm_inverse; cluster.setPosition(math::XYZPoint(x,y,z)); + cluster.setDepth(depth); cluster.calculatePositionREP(); } } From 910a5dbddda2fad82f5620ddf04c588645eb21bc Mon Sep 17 00:00:00 2001 From: Gaelle Date: Sun, 2 Nov 2014 15:08:26 +0100 Subject: [PATCH 243/252] Adding gensim recycling/ hgcalV5 + PU scenario --- .../python/relval_steps.py | 160 ++++++++++++------ 1 file changed, 104 insertions(+), 56 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 3cba12972434c..6cbcfd46c8609 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1119,7 +1119,11 @@ def genvalid(fragment,d,suffix='all',fi=''): 'Extended2023HGCal', 'Extended2023HGCalMuon4Eta', 'Extended2023Muon4Eta', - 'Extended2023HGCalV4' + 'Extended2023HGCalV4', + 'Extended2023HGCalPU', + 'Extended2023SHCalNoTaperPU' + + ] ] upgradeGeoms={ '2017' : 'Extended2017', '2019' : 'Extended2019', @@ -1199,6 +1203,57 @@ def genvalid(fragment,d,suffix='all',fi=''): 'Extended2023HGCalMuon4Eta' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_2023HGCalMuon', 'Extended2023HGCalV4' : 'SLHCUpgradeSimulations/Configuration/combinedCustoms.cust_2023HGCalMuon' } + +upgradeFragments=['FourMuPt_1_200_cfi','SingleElectronPt10_cfi', + 'SingleElectronPt35_cfi','SingleElectronPt1000_cfi', + 'SingleGammaPt10_cfi','SingleGammaPt35_cfi','SingleMuPt1_cfi','SingleMuPt10_cfi', + 'SingleMuPt100_cfi','SingleMuPt1000_cfi','TTbarLepton_Tauola_8TeV_cfi','Wjet_Pt_80_120_8TeV_cfi', + 'Wjet_Pt_3000_3500_8TeV_cfi','LM1_sfts_8TeV_cfi','QCD_Pt_3000_3500_8TeV_cfi','QCD_Pt_600_800_8TeV_cfi', + 'QCD_Pt_80_120_8TeV_cfi','H200ChargedTaus_Tauola_8TeV_cfi','JpsiMM_8TeV_cfi','TTbar_Tauola_8TeV_cfi', + 'WE_8TeV_cfi','ZEE_8TeV_cfi','ZTT_Tauola_All_hadronic_8TeV_cfi','H130GGgluonfusion_8TeV_cfi', + 'PhotonJet_Pt_10_8TeV_cfi','QQH1352T_Tauola_8TeV_cfi','MinBias_TuneZ2star_8TeV_pythia6_cff','WM_8TeV_cfi', + 'ZMM_8TeV_cfi','ADDMonoJet_8TeV_d3MD3_cfi','ZpMM_8TeV_cfi','WpM_8TeV_cfi', + 'Wjet_Pt_80_120_14TeV_cfi','Wjet_Pt_3000_3500_14TeV_cfi','LM1_sfts_14TeV_cfi','QCD_Pt_3000_3500_14TeV_cfi', + 'QCD_Pt_80_120_14TeV_cfi','H200ChargedTaus_Tauola_14TeV_cfi','JpsiMM_14TeV_cfi','TTbar_Tauola_14TeV_cfi', + 'WE_14TeV_cfi','ZEE_14TeV_cfi','ZTT_Tauola_All_hadronic_14TeV_cfi','H130GGgluonfusion_14TeV_cfi', + 'PhotonJet_Pt_10_14TeV_cfi','QQH1352T_Tauola_14TeV_cfi', + 'MinBias_TuneZ2star_14TeV_pythia6_cff','WM_14TeV_cfi','ZMM_14TeV_cfi', + 'FourMuExtendedPt_1_200_cfi', + 'TenMuExtendedE_0_200_cfi', + 'SingleElectronPt10Extended_cfi', + 'SingleElectronPt35Extended_cfi', + 'SingleElectronPt1000Extended_cfi', + 'SingleGammaPt10Extended_cfi', + 'SingleGammaPt35Extended_cfi', + 'SingleMuPt1Extended_cfi', + 'SingleMuPt10Extended_cfi', + 'SingleMuPt100Extended_cfi', + 'SingleMuPt1000Extended_cfi', + 'TenMuE_0_200_cfi', + 'SinglePiE50HCAL_cfi'] + + + +# for each geometry define the GT and processing string here +defaultDataSets={} +defaultDataSets['Extended2023HGCal']='CMSSW_6_2_0_SLHC20-DES23_62_V1_UPGHGCalV5-v' +# sometimes v1 won't be used - override it here - the dictionary key is gen fragment + '_' + geometry +versionOverrides={} + +baseDataSetReleaseBetter={} +for gen in upgradeFragments: + for ds in defaultDataSets: + key=gen[:-4]+'_'+ds + version='1' + if key in versionOverrides: + version = versionOverrides[key] + baseDataSetReleaseBetter[key]=defaultDataSets[ds]+version + +PUDataSets={} +for ds in defaultDataSets: + key='MinBias_TuneZ2star_14TeV_pythia6'+'_'+ds + name=baseDataSetReleaseBetter[key] + PUDataSets[ds]={'-n':10,'--pileup':'AVE_140_BX_25ns','--pileup_input':'das:/RelValMinBias_TuneZ2star_14TeV/%s/GEN-SIM'%(name,)} ### remember that you need to add a new step for phase 2 to include the track trigger ### remember that you need to add fastsim @@ -1210,7 +1265,7 @@ def genvalid(fragment,d,suffix='all',fi=''): # step6 is fastsim # step7 is fastsim harvesting -upgradeSteps=['GenSimFull','GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull','DigiTrkTrigFull','FastSim','HARVESTFast'] +upgradeSteps=['GenSimFull','GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull','DigiTrkTrigFull','FastSim','HARVESTFast','DigiFullPU','RecoFullPU'] upgradeScenToRun={ '2017':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], '2019':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], @@ -1237,6 +1292,7 @@ def genvalid(fragment,d,suffix='all',fi=''): 'Extended2023HGCal':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCalMuon4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCalV4' : ['GenSimFull','DigiFull','RecoFull','HARVESTFull'] + 'Extended2023HGCalPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFull'] } upgradeStepDict={} @@ -1246,114 +1302,99 @@ def genvalid(fragment,d,suffix='all',fi=''): # just make all combinations - yes, some will be nonsense.. but then these are not used unless # specified above for k in upgradeKeys: + k2=k + if 'PU' in k[-2:]: + k2=k[:-2] + geom=upgradeGeoms[k2] + gt=upgradeGTs[k2] + cust=upgradeCustoms[k2] upgradeStepDict['GenSimFull'][k]= {'-s' : 'GEN,SIM', '-n' : 10, - '--conditions' : upgradeGTs[k], + '--conditions' : gt, '--beamspot' : 'Gauss', '--magField' : '38T_PostLS1', '--datatier' : 'GEN-SIM', '--eventcontent': 'FEVTDEBUG', - '--geometry' : upgradeGeoms[k] + '--geometry' : geom } - if upgradeCustoms[k]!=None : upgradeStepDict['GenSimFull'][k]['--customise']=upgradeCustoms[k] - + if cust!=None : upgradeStepDict['GenSimFull'][k]['--customise']=cust + upgradeStepDict['GenSimHLBeamSpotFull'][k]= {'-s' : 'GEN,SIM', '-n' : 10, - '--conditions' : upgradeGTs[k], + '--conditions' : gt, '--beamspot' : 'HLLHC', '--magField' : '38T_PostLS1', '--datatier' : 'GEN-SIM', '--eventcontent': 'FEVTDEBUG', - '--geometry' : upgradeGeoms[k] + '--geometry' : geom } - if upgradeCustoms[k]!=None : upgradeStepDict['GenSimHLBeamSpotFull'][k]['--customise']=upgradeCustoms[k] - + if cust!=None : upgradeStepDict['GenSimHLBeamSpotFull'][k]['--customise']=cust + upgradeStepDict['DigiFull'][k] = {'-s':'DIGI:pdigi_valid,L1,DIGI2RAW', - '--conditions':upgradeGTs[k], + '--conditions':gt, '--datatier':'GEN-SIM-DIGI-RAW', '-n':'10', '--magField' : '38T_PostLS1', '--eventcontent':'FEVTDEBUGHLT', - '--geometry' : upgradeGeoms[k] + '--geometry' : geom } - if upgradeCustoms[k]!=None : upgradeStepDict['DigiFull'][k]['--customise']=upgradeCustoms[k] + if cust!=None : upgradeStepDict['DigiFull'][k]['--customise']=cust + + if k2 in PUDataSets: + upgradeStepDict['DigiFullPU'][k]=merge([PUDataSets[k2],upgradeStepDict['DigiFull'][k]]) upgradeStepDict['DigiTrkTrigFull'][k] = {'-s':'DIGI:pdigi_valid,L1,L1TrackTrigger,DIGI2RAW,RECO:pixeltrackerlocalreco', - '--conditions':upgradeGTs[k], + '--conditions':gt, '--datatier':'GEN-SIM-DIGI-RAW', '-n':'10', '--magField' : '38T_PostLS1', '--eventcontent':'FEVTDEBUGHLT', - '--geometry' : upgradeGeoms[k] + '--geometry' : geom } - if upgradeCustoms[k]!=None : upgradeStepDict['DigiTrkTrigFull'][k]['--customise']=upgradeCustoms[k] + if cust!=None : upgradeStepDict['DigiTrkTrigFull'][k]['--customise']=cust upgradeStepDict['RecoFull'][k] = {'-s':'RAW2DIGI,L1Reco,RECO,VALIDATION,DQM', - '--conditions':upgradeGTs[k], + '--conditions':gt, '--datatier':'GEN-SIM-RECO,DQMIO', '-n':'10', '--eventcontent':'FEVTDEBUGHLT,DQM', '--magField' : '38T_PostLS1', - '--geometry' : upgradeGeoms[k] + '--geometry' : geom } - if upgradeCustoms[k]!=None : upgradeStepDict['RecoFull'][k]['--customise']=upgradeCustoms[k] + if cust!=None : upgradeStepDict['RecoFull'][k]['--customise']=cust + + if k2 in PUDataSets: + upgradeStepDict['RecoFullPU'][k]=merge([PUDataSets[k2],upgradeStepDict['RecoFull'][k],{'-s':'RAW2DIGI,L1Reco,RECO,DQM'}]) upgradeStepDict['HARVESTFull'][k]={'-s':'HARVESTING:validationHarvesting+dqmHarvesting', - '--conditions':upgradeGTs[k], + '--conditions':gt, '--mc':'', '--magField' : '38T_PostLS1', - '--geometry' : upgradeGeoms[k], + '--geometry' : geom, '--scenario' : 'pp', '--filetype':'DQM' } - if upgradeCustoms[k]!=None : upgradeStepDict['HARVESTFull'][k]['--customise']=upgradeCustoms[k] + if cust!=None : upgradeStepDict['HARVESTFull'][k]['--customise']=cust upgradeStepDict['FastSim'][k]={'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', - '--conditions':upgradeGTs[k], + '--conditions':gt, '--fast':'', - '--geometry' : upgradeGeoms[k], + '--geometry' : geom, '--relval':'27000,3000'} - if upgradeCustoms[k]!=None : upgradeStepDict['FastSim'][k]['--customise']=upgradeCustoms[k] + if cust!=None : upgradeStepDict['FastSim'][k]['--customise']=cust upgradeStepDict['HARVESTFast'][k]={'-s':'HARVESTING:validationHarvestingFS', - '--conditions':upgradeGTs[k], + '--conditions':gt, '--mc':'', '--magField' : '38T_PostLS1', - '--geometry' : upgradeGeoms[k], + '--geometry' : geom, '--scenario' : 'pp' } - if upgradeCustoms[k]!=None : upgradeStepDict['HARVESTFast'][k]['--customise']=upgradeCustoms[k] + if cust!=None : upgradeStepDict['HARVESTFast'][k]['--customise']=cust -upgradeFragments=['FourMuPt_1_200_cfi','SingleElectronPt10_cfi', - 'SingleElectronPt35_cfi','SingleElectronPt1000_cfi', - 'SingleGammaPt10_cfi','SingleGammaPt35_cfi','SingleMuPt1_cfi','SingleMuPt10_cfi', - 'SingleMuPt100_cfi','SingleMuPt1000_cfi','TTbarLepton_Tauola_8TeV_cfi','Wjet_Pt_80_120_8TeV_cfi', - 'Wjet_Pt_3000_3500_8TeV_cfi','LM1_sfts_8TeV_cfi','QCD_Pt_3000_3500_8TeV_cfi','QCD_Pt_600_800_8TeV_cfi', - 'QCD_Pt_80_120_8TeV_cfi','H200ChargedTaus_Tauola_8TeV_cfi','JpsiMM_8TeV_cfi','TTbar_Tauola_8TeV_cfi', - 'WE_8TeV_cfi','ZEE_8TeV_cfi','ZTT_Tauola_All_hadronic_8TeV_cfi','H130GGgluonfusion_8TeV_cfi', - 'PhotonJet_Pt_10_8TeV_cfi','QQH1352T_Tauola_8TeV_cfi','MinBias_TuneZ2star_8TeV_pythia6_cff','WM_8TeV_cfi', - 'ZMM_8TeV_cfi','ADDMonoJet_8TeV_d3MD3_cfi','ZpMM_8TeV_cfi','WpM_8TeV_cfi', - 'Wjet_Pt_80_120_14TeV_cfi','Wjet_Pt_3000_3500_14TeV_cfi','LM1_sfts_14TeV_cfi','QCD_Pt_3000_3500_14TeV_cfi', - 'QCD_Pt_80_120_14TeV_cfi','H200ChargedTaus_Tauola_14TeV_cfi','JpsiMM_14TeV_cfi','TTbar_Tauola_14TeV_cfi', - 'WE_14TeV_cfi','ZEE_14TeV_cfi','ZTT_Tauola_All_hadronic_14TeV_cfi','H130GGgluonfusion_14TeV_cfi', - 'PhotonJet_Pt_10_14TeV_cfi','QQH1352T_Tauola_14TeV_cfi', - 'MinBias_TuneZ2star_14TeV_pythia6_cff','WM_14TeV_cfi','ZMM_14TeV_cfi', - 'FourMuExtendedPt_1_200_cfi', - 'TenMuExtendedE_0_200_cfi', - 'SingleElectronPt10Extended_cfi', - 'SingleElectronPt35Extended_cfi', - 'SingleElectronPt1000Extended_cfi', - 'SingleGammaPt10Extended_cfi', - 'SingleGammaPt35Extended_cfi', - 'SingleMuPt1Extended_cfi', - 'SingleMuPt10Extended_cfi', - 'SingleMuPt100Extended_cfi', - 'SingleMuPt1000Extended_cfi', - 'TenMuE_0_200_cfi', - 'SinglePiE50HCAL_cfi'] howMuches={'FourMuPt_1_200_cfi':Kby(10,100), 'TenMuE_0_200_cfi':Kby(10,100), @@ -1495,8 +1536,15 @@ def genvalid(fragment,d,suffix='all',fi=''): for key in upgradeKeys: k=frag[:-4]+'_'+key+'_'+step steps[k]=merge([ {'cfg':frag},howMuch,upgradeStepDict[step][key]]) + #get inputs in case of -i...but no need to specify in great detail + #however, there can be a conflict of beam spots but this is lost in the dataset name + #so please be careful + s=frag[:-4]+'_'+key + if 'FastSim' not in k and s+'INPUT' not in steps and s in baseDataSetReleaseBetter: + steps[k+'INPUT']={'INPUT':InputInfo(dataSet='/RelVal'+frag[:-4]+'/%s/GEN-SIM'%(baseDataSetReleaseBetter[s],),location='STD')} else: for key in upgradeKeys: k=step+'_'+key - steps[k]=merge([upgradeStepDict[step][key]]) + if step in upgradeStepDict and key in upgradeStepDict[step]: + steps[k]=merge([upgradeStepDict[step][key]]) From 2301cef4b067b0871d3d68fda2de3ec8406872f3 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Sun, 2 Nov 2014 15:52:07 +0100 Subject: [PATCH 244/252] Adding gensim recycling hgcalV5/SHCALNoTaper + PU scenario --- .../PyReleaseValidation/python/relval_steps.py | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 6cbcfd46c8609..759af30fdbdd7 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1121,10 +1121,9 @@ def genvalid(fragment,d,suffix='all',fi=''): 'Extended2023Muon4Eta', 'Extended2023HGCalV4', 'Extended2023HGCalPU', - 'Extended2023SHCalNoTaperPU' - - ] + 'Extended2023SHCalNoTaperPU' ] + upgradeGeoms={ '2017' : 'Extended2017', '2019' : 'Extended2019', '2019WithGEM' : 'Extended2019', @@ -1237,6 +1236,7 @@ def genvalid(fragment,d,suffix='all',fi=''): # for each geometry define the GT and processing string here defaultDataSets={} defaultDataSets['Extended2023HGCal']='CMSSW_6_2_0_SLHC20-DES23_62_V1_UPGHGCalV5-v' +defaultDataSets['Extended2023SHCalNoTaper']='CMSSW_6_2_0_SLHC20-DES23_62_V1_UPG2023SHNoTaper-v' # sometimes v1 won't be used - override it here - the dictionary key is gen fragment + '_' + geometry versionOverrides={} @@ -1291,18 +1291,21 @@ def genvalid(fragment,d,suffix='all',fi=''): 'Extended2023SHCalNoTaper4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCal':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCalMuon4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023HGCalV4' : ['GenSimFull','DigiFull','RecoFull','HARVESTFull'] - 'Extended2023HGCalPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFull'] + 'Extended2023HGCalV4' : ['GenSimFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023HGCalPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFull'], + 'Extended2023SHCalNoTaperPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFull'] } upgradeStepDict={} for step in upgradeSteps: upgradeStepDict[step]={} +print PUDataSets # just make all combinations - yes, some will be nonsense.. but then these are not used unless # specified above for k in upgradeKeys: k2=k + print k,k2 if 'PU' in k[-2:]: k2=k[:-2] geom=upgradeGeoms[k2] @@ -1339,10 +1342,11 @@ def genvalid(fragment,d,suffix='all',fi=''): '--geometry' : geom } if cust!=None : upgradeStepDict['DigiFull'][k]['--customise']=cust - + print k2, PUDataSets,'toto' + if k2 in PUDataSets: upgradeStepDict['DigiFullPU'][k]=merge([PUDataSets[k2],upgradeStepDict['DigiFull'][k]]) - + print k2 upgradeStepDict['DigiTrkTrigFull'][k] = {'-s':'DIGI:pdigi_valid,L1,L1TrackTrigger,DIGI2RAW,RECO:pixeltrackerlocalreco', '--conditions':gt, '--datatier':'GEN-SIM-DIGI-RAW', From cb9b288ea403a2e4271072921353664809bec23a Mon Sep 17 00:00:00 2001 From: Gaelle Date: Sun, 2 Nov 2014 16:01:59 +0100 Subject: [PATCH 245/252] Change priority order to allow priorty flexiblity --- Configuration/PyReleaseValidation/python/MatrixInjector.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Configuration/PyReleaseValidation/python/MatrixInjector.py b/Configuration/PyReleaseValidation/python/MatrixInjector.py index e2f9b19a22274..78dac7e3f8776 100644 --- a/Configuration/PyReleaseValidation/python/MatrixInjector.py +++ b/Configuration/PyReleaseValidation/python/MatrixInjector.py @@ -81,7 +81,7 @@ def __init__(self,opt,mode='init',options=''): self.defaultChain={ "RequestType" : "TaskChain", #this is how we handle relvals "SubRequestType" : "RelVal", #this is how we handle relvals, now that TaskChain is also used for central MC production - "RequestPriority": 999999, + "RequestPriority": 500000, "Requestor": self.user, #Person responsible "Group": self.group, #group for the request "CMSSWVersion": os.getenv('CMSSW_VERSION'), #CMSSW Version (used for all tasks in chain) From f91c9ba41afac0d5504a1db984f9958b9c5ba762 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Sun, 2 Nov 2014 16:05:41 +0100 Subject: [PATCH 246/252] Removing Printouts --- Configuration/PyReleaseValidation/python/relval_steps.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 759af30fdbdd7..b3495ce1a5b61 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1300,12 +1300,10 @@ def genvalid(fragment,d,suffix='all',fi=''): for step in upgradeSteps: upgradeStepDict[step]={} -print PUDataSets # just make all combinations - yes, some will be nonsense.. but then these are not used unless # specified above for k in upgradeKeys: k2=k - print k,k2 if 'PU' in k[-2:]: k2=k[:-2] geom=upgradeGeoms[k2] @@ -1342,11 +1340,9 @@ def genvalid(fragment,d,suffix='all',fi=''): '--geometry' : geom } if cust!=None : upgradeStepDict['DigiFull'][k]['--customise']=cust - print k2, PUDataSets,'toto' if k2 in PUDataSets: upgradeStepDict['DigiFullPU'][k]=merge([PUDataSets[k2],upgradeStepDict['DigiFull'][k]]) - print k2 upgradeStepDict['DigiTrkTrigFull'][k] = {'-s':'DIGI:pdigi_valid,L1,L1TrackTrigger,DIGI2RAW,RECO:pixeltrackerlocalreco', '--conditions':gt, '--datatier':'GEN-SIM-DIGI-RAW', From ea72b35b6cc1608c6c1510e73e7613e33754f4c5 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Sun, 2 Nov 2014 18:20:16 +0100 Subject: [PATCH 247/252] Finalizing PU scenarios with GENSIM recycling --- Configuration/PyReleaseValidation/python/relval_steps.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index b3495ce1a5b61..9a0cabeedd4d3 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1237,13 +1237,17 @@ def genvalid(fragment,d,suffix='all',fi=''): defaultDataSets={} defaultDataSets['Extended2023HGCal']='CMSSW_6_2_0_SLHC20-DES23_62_V1_UPGHGCalV5-v' defaultDataSets['Extended2023SHCalNoTaper']='CMSSW_6_2_0_SLHC20-DES23_62_V1_UPG2023SHNoTaper-v' +keys=defaultDataSets.keys() +for key in keys: + defaultDataSets[key+'PU']=defaultDataSets[key] + # sometimes v1 won't be used - override it here - the dictionary key is gen fragment + '_' + geometry versionOverrides={} baseDataSetReleaseBetter={} for gen in upgradeFragments: for ds in defaultDataSets: - key=gen[:-4]+'_'+ds + key=gen[:-4]+'_'+ds version='1' if key in versionOverrides: version = versionOverrides[key] From 57d4c356892226582771daa63e127f5efabf1cf3 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Mon, 3 Nov 2014 11:14:24 +0100 Subject: [PATCH 248/252] Fixing : Really Removing validation sequence (and fixing harvesting too) --- .../PyReleaseValidation/python/relval_steps.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 9a0cabeedd4d3..e2c2c0e7344cd 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1269,7 +1269,7 @@ def genvalid(fragment,d,suffix='all',fi=''): # step6 is fastsim # step7 is fastsim harvesting -upgradeSteps=['GenSimFull','GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull','DigiTrkTrigFull','FastSim','HARVESTFast','DigiFullPU','RecoFullPU'] +upgradeSteps=['GenSimFull','GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull','DigiTrkTrigFull','FastSim','HARVESTFast','DigiFullPU','RecoFullPU','HARVESTFullPU'] upgradeScenToRun={ '2017':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], '2019':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], @@ -1296,8 +1296,8 @@ def genvalid(fragment,d,suffix='all',fi=''): 'Extended2023HGCal':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCalMuon4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCalV4' : ['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023HGCalPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFull'], - 'Extended2023SHCalNoTaperPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFull'] + 'Extended2023HGCalPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFullPU'], + 'Extended2023SHCalNoTaperPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFullPU'] } upgradeStepDict={} @@ -1368,8 +1368,8 @@ def genvalid(fragment,d,suffix='all',fi=''): if cust!=None : upgradeStepDict['RecoFull'][k]['--customise']=cust if k2 in PUDataSets: - upgradeStepDict['RecoFullPU'][k]=merge([PUDataSets[k2],upgradeStepDict['RecoFull'][k],{'-s':'RAW2DIGI,L1Reco,RECO,DQM'}]) - + upgradeStepDict['RecoFullPU'][k]=merge([PUDataSets[k2],{'-s':'RAW2DIGI,L1Reco,RECO,DQM'},upgradeStepDict['RecoFull'][k]]) + upgradeStepDict['HARVESTFull'][k]={'-s':'HARVESTING:validationHarvesting+dqmHarvesting', '--conditions':gt, '--mc':'', @@ -1380,6 +1380,9 @@ def genvalid(fragment,d,suffix='all',fi=''): } if cust!=None : upgradeStepDict['HARVESTFull'][k]['--customise']=cust + if k2 in PUDataSets: + upgradeStepDict['HARVESTFullPU'][k]=merge([PUDataSets[k2],{'-s':'HARVESTING:dqmHarvesting'},upgradeStepDict['HARVESTFull'][k]]) + upgradeStepDict['FastSim'][k]={'-s':'GEN,SIM,RECO,VALIDATION', '--eventcontent':'FEVTDEBUGHLT,DQM', '--datatier':'GEN-SIM-DIGI-RECO,DQMIO', From cd0de883e0114cb193baf60094e9e7fed2e61b73 Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Mon, 3 Nov 2014 11:37:50 +0100 Subject: [PATCH 249/252] Remove unnecessary cout from DQMStore constructor --- DQMServices/Core/src/DQMStore.cc | 1 - 1 file changed, 1 deletion(-) diff --git a/DQMServices/Core/src/DQMStore.cc b/DQMServices/Core/src/DQMStore.cc index 59b1a647233f1..839ac25510051 100644 --- a/DQMServices/Core/src/DQMStore.cc +++ b/DQMServices/Core/src/DQMStore.cc @@ -268,7 +268,6 @@ DQMStore::DQMStore(const edm::ParameterSet &pset, edm::ActivityRegistry& ar) if(pset.getUntrackedParameter("forceResetOnBeginRun",false)) { ar.watchPostSourceRun(this,&DQMStore::forceReset); } - std::cout << __LINE__ << " DQMStore::DQMStore " << std::endl; } DQMStore::DQMStore(const edm::ParameterSet &pset) From 85aa446a72fe1e66215317e1778a2fb0f9431aa9 Mon Sep 17 00:00:00 2001 From: Mark Grimes Date: Mon, 3 Nov 2014 15:59:57 +0100 Subject: [PATCH 250/252] Initialise pointer to null, otherwise it could delete random memory in the destructor --- SimG4CMS/Calo/src/HCalSD.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SimG4CMS/Calo/src/HCalSD.cc b/SimG4CMS/Calo/src/HCalSD.cc index e1f7d8af48465..2558e2ab7a922 100644 --- a/SimG4CMS/Calo/src/HCalSD.cc +++ b/SimG4CMS/Calo/src/HCalSD.cc @@ -40,7 +40,7 @@ HCalSD::HCalSD(G4String name, const DDCompactView & cpv, p.getParameter("HCalSD").getParameter("IgnoreTrackID")), numberingFromDDD(0), numberingScheme(0), showerLibrary(0), hfshower(0), showerParam(0), showerPMT(0), showerBundle(0), m_HEDarkening(0), - m_HFDarkening(0) { + m_HBDarkening(0), m_HFDarkening(0) { //static SimpleConfigurable on1(false, "HCalSD:UseBirkLaw"); //static SimpleConfigurable bk1(0.013, "HCalSD:BirkC1"); From ae1790926ceefa1ca228f844635d6d16d7e06007 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Tue, 4 Nov 2014 12:50:32 +0100 Subject: [PATCH 251/252] updating 2023muondev with L1tracktrigger sequence , breaking 108xx (dev so is ok) waiting for dqm PR --- .../PyReleaseValidation/python/relval_steps.py | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index e2c2c0e7344cd..1b2a4ab1f91b5 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1269,7 +1269,7 @@ def genvalid(fragment,d,suffix='all',fi=''): # step6 is fastsim # step7 is fastsim harvesting -upgradeSteps=['GenSimFull','GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull','DigiTrkTrigFull','FastSim','HARVESTFast','DigiFullPU','RecoFullPU','HARVESTFullPU'] +upgradeSteps=['GenSimFull','GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull','DigiTrkTrigFull','FastSim','HARVESTFast','DigiFullPU','RecoFullPU','HARVESTFullPU','DigiFullTrigger'] upgradeScenToRun={ '2017':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], '2019':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], @@ -1279,7 +1279,7 @@ def genvalid(fragment,d,suffix='all',fi=''): 'BE5D':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'BE5DPixel10D':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], '2017dev':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023Muondev':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023Muondev':['GenSimFull','DigiFullTrigger','RecoFull','HARVESTFull'], 'BE5DForwardFast':['FastSim','HARVESTFast'], 'Extended2023':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023HGCalMuon':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], @@ -1345,6 +1345,17 @@ def genvalid(fragment,d,suffix='all',fi=''): } if cust!=None : upgradeStepDict['DigiFull'][k]['--customise']=cust + upgradeStepDict['DigiFullTrigger'][k] = {'-s':'DIGI:pdigi_valid,L1,L1TrackTrigger,DIGI2RAW', + '--conditions':gt, + '--datatier':'GEN-SIM-DIGI-RAW', + '-n':'10', + '--magField' : '38T_PostLS1', + '--eventcontent':'FEVTDEBUGHLT', + '--geometry' : geom + } + if cust!=None : upgradeStepDict['DigiFullTrigger'][k]['--customise']=cust + + if k2 in PUDataSets: upgradeStepDict['DigiFullPU'][k]=merge([PUDataSets[k2],upgradeStepDict['DigiFull'][k]]) upgradeStepDict['DigiTrkTrigFull'][k] = {'-s':'DIGI:pdigi_valid,L1,L1TrackTrigger,DIGI2RAW,RECO:pixeltrackerlocalreco', From 53c904465be63ad2d09312d1c07b92845a7445d9 Mon Sep 17 00:00:00 2001 From: Gaelle Date: Thu, 6 Nov 2014 17:10:15 +0100 Subject: [PATCH 252/252] HLLHC BS for all phase2 scenarios (like we will have in the MC prod) --- .../python/relval_steps.py | 38 +++++++++---------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/Configuration/PyReleaseValidation/python/relval_steps.py b/Configuration/PyReleaseValidation/python/relval_steps.py index 1b2a4ab1f91b5..f0ffc5352aeb4 100644 --- a/Configuration/PyReleaseValidation/python/relval_steps.py +++ b/Configuration/PyReleaseValidation/python/relval_steps.py @@ -1276,28 +1276,28 @@ def genvalid(fragment,d,suffix='all',fi=''): '2019WithGEM':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], '2017Aging':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], '2019Aging':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'BE5D':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'BE5DPixel10D':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], + 'BE5D':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'BE5DPixel10D':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], '2017dev':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023Muondev':['GenSimFull','DigiFullTrigger','RecoFull','HARVESTFull'], + 'Extended2023Muondev':['GenSimHLBeamSpotFull','DigiFullTrigger','RecoFull','HARVESTFull'], 'BE5DForwardFast':['FastSim','HARVESTFast'], - 'Extended2023':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023HGCalMuon':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023SHCal':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023SHCal4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023HGCalMuon':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023SHCal':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023SHCal4Eta':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], 'Extended2023TTI':['GenSimHLBeamSpotFull','DigiTrkTrigFull'], ##no need to go beyond local reco - 'Extended2023Muon':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023Muon4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023CFCal':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023CFCal4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023Pixel':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023SHCalNoTaper':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023SHCalNoTaper4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023HGCal':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023HGCalMuon4Eta':['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023HGCalV4' : ['GenSimFull','DigiFull','RecoFull','HARVESTFull'], - 'Extended2023HGCalPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFullPU'], - 'Extended2023SHCalNoTaperPU' : ['GenSimFull','DigiFullPU','RecoFullPU','HARVESTFullPU'] + 'Extended2023Muon':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023Muon4Eta':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023CFCal':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023CFCal4Eta':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023Pixel':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023SHCalNoTaper':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023SHCalNoTaper4Eta':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023HGCal':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023HGCalMuon4Eta':['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023HGCalV4' : ['GenSimHLBeamSpotFull','DigiFull','RecoFull','HARVESTFull'], + 'Extended2023HGCalPU' : ['GenSimHLBeamSpotFull','DigiFullPU','RecoFullPU','HARVESTFullPU'], + 'Extended2023SHCalNoTaperPU' : ['GenSimHLBeamSpotFull','DigiFullPU','RecoFullPU','HARVESTFullPU'] } upgradeStepDict={}