diff --git a/DataFormats/Math/interface/private/AVXVec.h b/DataFormats/Math/interface/private/AVXVec.h index 78850716bba21..776387e339743 100644 --- a/DataFormats/Math/interface/private/AVXVec.h +++ b/DataFormats/Math/interface/private/AVXVec.h @@ -29,10 +29,7 @@ namespace mathSSE { arr[3] = f4; } - Vec4(Vec2 ivec0, Vec2 ivec1) { - vec = _mm256_insertf128_pd(vec, ivec0.vec, 0); - vec = _mm256_insertf128_pd(vec, ivec1.vec, 1); - } + Vec4(Vec2 ivec0, Vec2 ivec1) { vec = _mm256_set_m128d(ivec1.vec, ivec0.vec); } Vec4(Vec2 ivec0, double f3, double f4 = 0) { vec = _mm256_insertf128_pd(vec, ivec0.vec, 0); diff --git a/Geometry/HcalCommonData/data/hcalRecNumbering/2021/v1/hcalRecNumbering.xml b/Geometry/HcalCommonData/data/hcalRecNumbering/2021/v1/hcalRecNumbering.xml new file mode 100644 index 0000000000000..0b08d71e4e7ca --- /dev/null +++ b/Geometry/HcalCommonData/data/hcalRecNumbering/2021/v1/hcalRecNumbering.xml @@ -0,0 +1,45 @@ + + + + + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 + + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 + + + 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4 + + + 1, 1, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4 + + + 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3 + + + 1, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5 + + + 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6 + + + 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7 + + + + + + + + + + + + + + + + diff --git a/Geometry/HcalCommonData/data/hcalRecNumbering/NoHE/v2/hcalRecNumbering.xml b/Geometry/HcalCommonData/data/hcalRecNumbering/NoHE/v2/hcalRecNumbering.xml new file mode 100644 index 0000000000000..10e559b850df8 --- /dev/null +++ b/Geometry/HcalCommonData/data/hcalRecNumbering/NoHE/v2/hcalRecNumbering.xml @@ -0,0 +1,30 @@ + + + + + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 + + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 + + + 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4 + + + 1, 1, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4 + + + + + + + + + + + + + + + diff --git a/Geometry/HcalCommonData/data/hcalSimNumbering/2021/v2/hcalSimNumbering.xml b/Geometry/HcalCommonData/data/hcalSimNumbering/2021/v2/hcalSimNumbering.xml new file mode 100644 index 0000000000000..441fed1884c37 --- /dev/null +++ b/Geometry/HcalCommonData/data/hcalSimNumbering/2021/v2/hcalSimNumbering.xml @@ -0,0 +1,101 @@ + + + + + + 0.0*deg, 0.0*deg, 0.0*deg, 10.0*deg, 10.0*deg + + + 0.000, 0.087, 0.174, 0.261, 0.348, 0.435, 0.522, 0.609, 0.696, + 0.783, 0.870, 0.957, 1.044, 1.131, 1.218, 1.305, 1.392, 1.479, + 1.566, 1.653, 1.740, 1.830, 1.930, 2.043, 2.172, 2.322, 2.500, + 2.650, 2.868, 3.000 + + + 12.50*cm, 16.90*cm, 20.10*cm, 24.00*cm, 28.60*cm, 34.00*cm, + 40.60*cm, 48.30*cm, 57.60*cm, 68.60*cm, 81.80*cm, 97.50*cm, + 116.20*cm, 130.00*cm + + + 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, + 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, + 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 10.0*deg, + 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, + 10.0*deg, 10.0*deg + + + 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, + 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 20.0*deg, + 20.0*deg + + + 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4 + + + 1, 1, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4 + + + 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3 + + + 1, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5 + + + 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6 + + + 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7 + + + 1, 16, 29, 1 + + + 16, 29, 41, 15 + + + 4, 7, 4, 4 + + + 1.392, 3.000, 5.500, 1.305 + + + 22.0*cm, 165.0*cm, 30.0*cm, 0.0*cm, 1115.0*cm, 0.375*cm, + 1137.0*cm + + + 15, 29, 4, 10, 5, 2, 4, 18, 19, 11, 12, 13, 14, 3, 4, 3, 1, 0 + + + 0.5, 1.2 + + + 117.0, 117.0, 117.0, 217.0 + + + 0, 0, 0, 0 + + + 178.0, 178.0, 178.0, 178.0, 178.0, 178.0, 178.0 + + + 0, 0, 0, 0, 0, 0, 0 + + + 2.840, 2.090, 2.840, 2.090 + + + 0, 0, 0, 0 + + + + + + + + + + + + + + diff --git a/Geometry/HcalCommonData/data/hcalSimNumbering/NoHE/v2/hcalSimNumbering.xml b/Geometry/HcalCommonData/data/hcalSimNumbering/NoHE/v2/hcalSimNumbering.xml new file mode 100644 index 0000000000000..bd497963e7ec6 --- /dev/null +++ b/Geometry/HcalCommonData/data/hcalSimNumbering/NoHE/v2/hcalSimNumbering.xml @@ -0,0 +1,84 @@ + + + + + + 0.0*deg, 0.0*deg, 0.0*deg, 10.0*deg, 10.0*deg + + + 0.000, 0.087, 0.174, 0.261, 0.348, 0.435, 0.522, 0.609, 0.696, + 0.783, 0.870, 0.957, 1.044, 1.131, 1.218, 1.305, 1.392 + + + 12.50*cm, 16.90*cm, 20.10*cm, 24.00*cm, 28.60*cm, 34.00*cm, + 40.60*cm, 48.30*cm, 57.60*cm, 68.60*cm, 81.80*cm, 97.50*cm, + 116.20*cm, 130.00*cm + + + 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, + 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, 5.0*deg, + 5.0*deg, 5.0*deg + + + 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, + 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 10.0*deg, 20.0*deg, + 20.0*deg + + + 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4 + + + 1, 1, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4 + + + 1, 28, 29, 1 + + + 16, 15, 41, 15 + + + 4, 0, 4, 4 + + + 1.392, 3.000, 5.500, 1.305 + + + 22.0*cm, 165.0*cm, 30.0*cm, 0.0*cm, 1115.0*cm, 0.375*cm, + 1137.0*cm + + + 15, 99, 4, 10, 5, 2, 4, 18, 19, 11, 12, 13, 14, 3, 4, 3, 1, 0 + + + 1.2, 1.2 + + + 117.0, 117.0, 117.0, 217.0 + + + 0, 0, 0, 0 + + + 178.0, 178.0, 178.0, 0.000 + + + 0, 0, 0, 0 + + + 2.840, 2.090, 2.840, 2.090 + + + 0, 0, 0, 0 + + + + + + + + + + + + + diff --git a/Geometry/HcalCommonData/python/GeometryExtended2016Reco_cff.py b/Geometry/HcalCommonData/python/GeometryExtended2016Reco_cff.py index 128e3c0723a11..c87a24fa8ef4d 100644 --- a/Geometry/HcalCommonData/python/GeometryExtended2016Reco_cff.py +++ b/Geometry/HcalCommonData/python/GeometryExtended2016Reco_cff.py @@ -9,6 +9,7 @@ from Geometry.EcalCommonData.ecalSimulationParameters_cff import * from Geometry.HcalCommonData.hcalDDDSimConstants_cff import * from Geometry.MuonNumbering.muonGeometryConstants_cff import * +from Geometry.MuonNumbering.muonOffsetESProducer_cff import * # Reconstruction geometry services # Tracking Geometry diff --git a/Geometry/HcalCommonData/python/GeometryExtended2021Reco_cff.py b/Geometry/HcalCommonData/python/GeometryExtended2021Reco_cff.py new file mode 100644 index 0000000000000..085cae18436d8 --- /dev/null +++ b/Geometry/HcalCommonData/python/GeometryExtended2021Reco_cff.py @@ -0,0 +1,52 @@ +import FWCore.ParameterSet.Config as cms + +# +# Geometry master configuration +# +# Ideal geometry, needed for simulation +from Geometry.HcalCommonData.cmsExtendedGeometry2021XML_cfi import * +from Geometry.TrackerNumberingBuilder.trackerNumberingGeometry_cfi import * +from Geometry.EcalCommonData.ecalSimulationParameters_cff import * +from Geometry.HcalCommonData.hcalDDDSimConstants_cff import * +from Geometry.MuonNumbering.muonGeometryConstants_cff import * +from Geometry.MuonNumbering.muonOffsetESProducer_cff import * + +# Reconstruction geometry services +# tracker +from Geometry.CommonTopologies.globalTrackingGeometry_cfi import * +from RecoTracker.GeometryESProducer.TrackerRecoGeometryESProducer_cfi import * +from Geometry.TrackerGeometryBuilder.trackerParameters_cff import * +from Geometry.TrackerNumberingBuilder.trackerTopology_cfi import * +from Geometry.TrackerGeometryBuilder.idealForDigiTrackerGeometry_cff import * + +#Muon +from Geometry.MuonNumbering.muonNumberingInitialization_cfi import * +from RecoMuon.DetLayers.muonDetLayerGeometry_cfi import * +from Geometry.GEMGeometryBuilder.gemGeometry_cff import * +from Geometry.CSCGeometryBuilder.idealForDigiCscGeometry_cff import * +from Geometry.DTGeometryBuilder.idealForDigiDtGeometry_cff import * +trackerGeometry.applyAlignment = cms.bool(False) + +# Calorimeters +from Geometry.CaloEventSetup.CaloTopology_cfi import * +from Geometry.CaloEventSetup.CaloGeometry_cfi import * +CaloGeometryBuilder = cms.ESProducer("CaloGeometryBuilder", + SelectedCalos = cms.vstring("HCAL", + "ZDC", + "EcalBarrel", + "EcalEndcap", + "EcalPreshower", + "TOWER", + ) +) +from Geometry.EcalAlgo.EcalGeometry_cfi import * +from Geometry.HcalEventSetup.HcalGeometry_cfi import * +from Geometry.HcalEventSetup.CaloTowerGeometry_cfi import * +from Geometry.HcalEventSetup.CaloTowerTopology_cfi import * +from Geometry.HcalCommonData.hcalDDDRecConstants_cfi import * +from Geometry.HcalEventSetup.hcalTopologyIdeal_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 * + diff --git a/Geometry/HcalCommonData/python/cmsExtendedGeometry2021XML_cfi.py b/Geometry/HcalCommonData/python/cmsExtendedGeometry2021XML_cfi.py new file mode 100644 index 0000000000000..0e2d818289cb7 --- /dev/null +++ b/Geometry/HcalCommonData/python/cmsExtendedGeometry2021XML_cfi.py @@ -0,0 +1,386 @@ +import FWCore.ParameterSet.Config as cms + +# This config was generated automatically using generate2021Geometry.py +# If you notice a mistake, please update the generating script, not just this config + +XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", + geomXMLFiles = cms.vstring( + 'Geometry/CMSCommonData/data/materials/2021/v3/materials.xml', + 'Geometry/TrackerCommonData/data/trackermaterial/2021/v2/trackermaterial.xml', + 'Geometry/CMSCommonData/data/rotations.xml', + 'Geometry/CMSCommonData/data/extend/v3/cmsextent.xml', + 'Geometry/CMSCommonData/data/cavernData/2021/v1/cavernData.xml', + 'Geometry/CMSCommonData/data/cms/2021/v3/cms.xml', + 'Geometry/CMSCommonData/data/cmsMother.xml', + 'Geometry/CMSCommonData/data/eta3/etaMax.xml', + 'Geometry/CMSCommonData/data/cmsTracker.xml', + 'Geometry/CMSCommonData/data/caloBase/2017/v1/caloBase.xml', + 'Geometry/CMSCommonData/data/cmsCalo.xml', + 'Geometry/CMSCommonData/data/muonBase/2018/v1/muonBase.xml', + 'Geometry/CMSCommonData/data/cmsMuon.xml', + 'Geometry/CMSCommonData/data/mgnt.xml', + 'Geometry/CMSCommonData/data/beampipe/2021/v1/beampipe.xml', + 'Geometry/CMSCommonData/data/cmsBeam/2021/v1/cmsBeam.xml', + 'Geometry/CMSCommonData/data/muonMB.xml', + 'Geometry/CMSCommonData/data/muonMagnet.xml', + 'Geometry/CMSCommonData/data/cavern/2021/v1/cavern.xml', + 'Geometry/CMSCommonData/data/cavernFloor/2017/v1/cavernFloor.xml', + 'Geometry/TrackerCommonData/data/PhaseI/trackerParameters.xml', + 'Geometry/TrackerCommonData/data/pixfwdMaterials/2021/v3/pixfwdMaterials.xml', + 'Geometry/TrackerCommonData/data/pixfwdCommon.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdCylinder.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdDisks.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v3/pixfwd.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdSupportRingParameters.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdInnerDiskZplus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdInnerDiskZminus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdOuterDiskZplus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdOuterDiskZminus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdbladeInnerZplus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdbladeInnerZminus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdbladeOuterZplus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixfwdbladeOuterZminus.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v3/pixbarmaterial.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarladder.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarladderfull0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarladderfull1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarladderfull2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarladderfull3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarlayer.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarlayer0.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarlayer1.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarlayer2.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbarlayer3.xml', + 'Geometry/TrackerCommonData/data/PhaseI/v2/pixbar.xml', + 'Geometry/TrackerCommonData/data/Run2/trackerpatchpannel.xml', + 'Geometry/TrackerCommonData/data/Run2/trackerpixelnose.xml', + 'Geometry/TrackerCommonData/data/tibtidcommonmaterial/2021/v2/tibtidcommonmaterial.xml', + 'Geometry/TrackerCommonData/data/tibmaterial/2021/v2/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/2021/v2/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/2021/v2/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/v3/tob.xml', + 'Geometry/TrackerCommonData/data/tecmaterial/2021/v1/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/2021/v1/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/Run2/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/v2/trackerbulkhead.xml', + 'Geometry/TrackerCommonData/data/trackerother.xml', + 'Geometry/TrackerCommonData/data/PhaseI/trackerStructureTopology.xml', + 'Geometry/TrackerSimData/data/PhaseI/trackersens.xml', + 'Geometry/TrackerRecoData/data/PhaseI/v1/trackerRecoMaterial.xml', + 'SimTracker/TrackerMaterialAnalysis/data/trackingMaterialGroups_ForPhaseI/v1/trackingMaterialGroups_ForPhaseI.xml', + 'Geometry/TrackerSimData/data/PhaseI/trackerProdCuts.xml', + 'Geometry/TrackerSimData/data/trackerProdCutsBEAM.xml', + 'Geometry/EcalCommonData/data/ebcon/2021/v1/ebcon.xml', + 'Geometry/EcalCommonData/data/eecon.xml', + 'Geometry/EcalCommonData/data/escon.xml', + 'Geometry/EcalCommonData/data/eregalgo/2017/v1/eregalgo.xml', + 'Geometry/EcalCommonData/data/ebalgo.xml', + 'Geometry/EcalCommonData/data/ebrot.xml', + 'Geometry/EcalCommonData/data/eefixed/2021/v1/eefixed.xml', + 'Geometry/EcalCommonData/data/eehier.xml', + 'Geometry/EcalCommonData/data/eealgo.xml', + 'Geometry/EcalCommonData/data/esalgo.xml', + 'Geometry/EcalCommonData/data/eeF.xml', + 'Geometry/EcalCommonData/data/eeB.xml', + 'Geometry/EcalCommonData/data/ectkcable.xml', + 'Geometry/HcalCommonData/data/hcalrotations.xml', + 'Geometry/HcalCommonData/data/hcal/PhaseI/hcalalgo.xml', + 'Geometry/HcalCommonData/data/hcalcablealgo.xml', + 'Geometry/HcalCommonData/data/hcalbarrelalgo.xml', + 'Geometry/HcalCommonData/data/hcalendcap/PhaseI/hcalendcapalgo.xml', + 'Geometry/HcalCommonData/data/hcalouteralgo/v1/hcalouteralgo.xml', + 'Geometry/HcalCommonData/data/hcalforwardalgo.xml', + 'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', + 'Geometry/HcalCommonData/data/hcalSimNumbering/2021/v2/hcalSimNumbering.xml', + 'Geometry/HcalCommonData/data/hcalRecNumbering/2021/v1/hcalRecNumbering.xml', + 'Geometry/MuonCommonData/data/mbCommon/2021/v2/mbCommon.xml', + 'Geometry/MuonCommonData/data/mb1/2021/v1/mb1.xml', + 'Geometry/MuonCommonData/data/mb2/2021/v1/mb2.xml', + 'Geometry/MuonCommonData/data/mb3/2021/v1/mb3.xml', + 'Geometry/MuonCommonData/data/mb4/2015/v2/mb4.xml', + 'Geometry/MuonCommonData/data/mb4Shield/2021/v1/mb4Shield.xml', + 'Geometry/MuonCommonData/data/muonYoke/2021/v5/muonYoke.xml', + 'Geometry/MuonCommonData/data/mf/2021/v3/mf.xml', + 'Geometry/MuonCommonData/data/rpcf/2021/v2/rpcf.xml', + 'Geometry/MuonCommonData/data/gemf/TDR_BaseLine/gemf.xml', + 'Geometry/MuonCommonData/data/gem11/TDR_BaseLine/gem11.xml', + 'Geometry/MuonCommonData/data/gem21/2021/v1/gem21.xml', + 'Geometry/MuonCommonData/data/csc/2021/v3/csc.xml', + 'Geometry/MuonCommonData/data/mfshield/2017/v2/mfshield.xml', + )+ + cms.vstring( + 'Geometry/MuonCommonData/data/muonNumbering/2021/v5/muonNumbering.xml', + 'Geometry/ForwardCommonData/data/forward/2021/v1/forward.xml', + 'Geometry/ForwardCommonData/data/totemt2/2021/v1/totemt2.xml', + 'Geometry/ForwardCommonData/data/forwardshield/2021/v1/forwardshield.xml', + 'Geometry/ForwardCommonData/data/bhm.xml', + 'Geometry/ForwardCommonData/data/pltbcm/2021/v1/pltbcm.xml', + 'Geometry/ForwardCommonData/data/bcm1f/2021/v1/bcm1f.xml', + 'Geometry/ForwardCommonData/data/plt/2021/v1/plt.xml', + 'Geometry/ForwardCommonData/data/zdcmaterials/2021/v1/zdcmaterials.xml', + 'Geometry/ForwardCommonData/data/lumimaterials.xml', + 'Geometry/ForwardCommonData/data/zdcrotations.xml', + 'Geometry/ForwardCommonData/data/lumirotations.xml', + 'Geometry/ForwardCommonData/data/zdc/2021/v2/zdc.xml', + 'Geometry/ForwardCommonData/data/zdclumi/2021/v2/zdclumi.xml', + 'Geometry/ForwardCommonData/data/cmszdc.xml', + 'Geometry/VeryForwardData/data/RP_Box.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_000.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_001.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_002.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_003.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_004.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_005.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_020.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_021.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_022.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_023.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_024.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_025.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_100.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_101.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_102.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_103.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_104.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_105.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_120.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_121.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_122.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_123.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_124.xml', + 'Geometry/VeryForwardData/data/RP_Box/v3/RP_Box_125.xml', + 'Geometry/VeryForwardData/data/RP_Hybrid/v2/RP_Hybrid.xml', + 'Geometry/VeryForwardData/data/RP_Materials/v5/RP_Materials.xml', + 'Geometry/VeryForwardData/data/RP_Transformations.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_000.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_001.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_002.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_004.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_005.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_020.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_021.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_024.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_025.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_100.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_101.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_102.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_104.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_105.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_120.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_121.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_124.xml', + 'Geometry/VeryForwardData/data/RP_Detectors_Assembly/RP_Detectors_Assembly_125.xml', + 'Geometry/VeryForwardData/data/RP_Device/v1/RP_Device.xml', + 'Geometry/VeryForwardData/data/RP_Vertical_Device/2021/Simu/v2/RP_Vertical_Device.xml', + 'Geometry/VeryForwardData/data/RP_Horizontal_Device/2021/Simu/v2/RP_Horizontal_Device.xml', + 'Geometry/VeryForwardData/data/CTPPS_2021/Stations/Simu/v3/CTPPS_220_Right_Station.xml', + 'Geometry/VeryForwardData/data/CTPPS_2021/Stations/Simu/v3/CTPPS_220_Left_Station.xml', + 'Geometry/VeryForwardData/data/CTPPS_2021/Stations/Simu/v3/CTPPS_210_Right_Station.xml', + 'Geometry/VeryForwardData/data/CTPPS_2021/Stations/Simu/v3/CTPPS_210_Left_Station.xml', + 'Geometry/VeryForwardData/data/CTPPS_2021/Stations/Simu/v3/CTPPS_Stations_Assembly.xml', + 'Geometry/VeryForwardData/data/CTPPS_2021/Cuts_Per_Region/Simu/v1/CTPPS_Cuts_Per_Region.xml', + 'Geometry/VeryForwardData/data/RP_Sensitive_Dets.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Transformations.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Parameters.xml', + 'Geometry/VeryForwardData/data/CTPPS_Timing_Station_Parameters.xml', + 'Geometry/VeryForwardData/data/CTPPS_Timing_Horizontal_Pot/v2/CTPPS_Timing_Horizontal_Pot.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern1_Segment1.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern2_Segment1.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern2_Segment2.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern3_Segment1.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern3_Segment2.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern3_Segment3.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern3_Segment4.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern4_Segment1.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern4_Segment2.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern4_Segment3.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern4_Segment4.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Segments/CTPPS_Diamond_Pattern4_Segment5.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_2021/CTPPS_Diamond_Planes/CTPPS_Diamond_Plane1.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_2021/CTPPS_Diamond_Planes/CTPPS_Diamond_Plane2.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_2021/CTPPS_Diamond_Planes/CTPPS_Diamond_Plane3.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_2021/CTPPS_Diamond_Planes/CTPPS_Diamond_Plane4.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_2021/CTPPS_Diamond_Detector_Assembly/v1/CTPPS_Diamond_Detector_Assembly.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_2021/Simu/v1/CTPPS_Detectors_Assembly_022.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_2021/Simu/v1/CTPPS_Detectors_Assembly_122.xml', + 'Geometry/VeryForwardData/data/CTPPS_Diamond_Sensitive_Dets_TimingHits.xml', + 'Geometry/VeryForwardData/data/CTPPS_Pixel_2021/Modules/v3/PPS_Pixel_Module_2x2_Run3.xml', + 'Geometry/VeryForwardData/data/CTPPS_Pixel_2021/Modules/v2/PPS_Pixel_Sens.xml', + 'Geometry/VeryForwardData/data/CTPPS_Pixel_2021/Assembly/v2/CTPPS_Pixel_Assembly_Box_Real_003.xml', + 'Geometry/VeryForwardData/data/CTPPS_Pixel_2021/Assembly/v2/CTPPS_Pixel_Assembly_Box_Real_023.xml', + 'Geometry/VeryForwardData/data/CTPPS_Pixel_2021/Assembly/v2/CTPPS_Pixel_Assembly_Box_Real_103.xml', + 'Geometry/VeryForwardData/data/CTPPS_Pixel_2021/Assembly/v2/CTPPS_Pixel_Assembly_Box_Real_123.xml', + 'Geometry/VeryForwardData/data/CTPPS_2021/RP_Dist_Beam_Cent/Simu/v1/RP_Dist_Beam_Cent.xml', + 'Geometry/EcalSimData/data/ecalsens.xml', + 'Geometry/HcalCommonData/data/hcalsens/2021/v1/hcalsenspmf.xml', + 'Geometry/HcalSimData/data/hf/v1/hf.xml', + 'Geometry/HcalSimData/data/hfpmt.xml', + 'Geometry/HcalSimData/data/hffibrebundle.xml', + 'Geometry/HcalSimData/data/CaloUtil/2021/v1/CaloUtil.xml', + 'Geometry/MuonSimData/data/muonSens/2021/v4/muonSens.xml', + 'Geometry/DTGeometryBuilder/data/dtSpecsFilter/2021/v1/dtSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecsFilter.xml', + 'Geometry/CSCGeometryBuilder/data/cscSpecs.xml', + 'Geometry/RPCGeometryBuilder/data/2021/v1/RPCSpecs.xml', + 'Geometry/GEMGeometryBuilder/data/GEMSpecsFilter/2021/v2/GEMSpecsFilter.xml', + 'Geometry/GEMGeometryBuilder/data/GEMSpecs/2021/v2/GEMSpecs.xml', + 'Geometry/ForwardSimData/data/totemsensT2/2021/totemsensT2.xml', + 'Geometry/ForwardCommonData/data/bhmsens.xml', + 'Geometry/ForwardSimData/data/pltsens.xml', + 'Geometry/ForwardSimData/data/bcm1fsens.xml', + 'Geometry/ForwardSimData/data/zdcsens.xml', + 'Geometry/HcalSimData/data/HcalProdCuts/2021/v2/HcalProdCuts.xml', + 'Geometry/EcalSimData/data/EcalProdCuts.xml', + 'Geometry/EcalSimData/data/ESProdCuts.xml', + 'Geometry/MuonSimData/data/muonProdCuts/2021/v3/muonProdCuts.xml', + 'Geometry/ForwardSimData/data/ForwardShieldProdCuts.xml', + 'Geometry/ForwardSimData/data/bhmProdCuts/2021/v1/bhmProdCuts.xml', + 'Geometry/ForwardSimData/data/zdcProdCuts/2021/v2/zdcProdCuts.xml', + 'Geometry/CMSCommonData/data/FieldParameters.xml', + ), + rootNodeName = cms.string('cms:OCMS') +) diff --git a/Geometry/HcalCommonData/test/python/runOverlap_cfg.py b/Geometry/HcalCommonData/test/python/runOverlap_cfg.py index 095934f9901b6..972698a4ea01c 100644 --- a/Geometry/HcalCommonData/test/python/runOverlap_cfg.py +++ b/Geometry/HcalCommonData/test/python/runOverlap_cfg.py @@ -3,56 +3,39 @@ process = cms.Process("PROD",Run3_DDD) process.load("SimGeneral.HepPDTESSource.pdt_cfi") - -process.load("Geometry.CMSCommonData.hcalOnlyGeometryXML_cfi") - -process.load("SimG4Core.Application.g4SimHits_cfi") process.load('FWCore.MessageService.MessageLogger_cfi') +process.load("Geometry.HcalCommonData.GeometryExtended2021Reco_cff") if 'MessageLogger' in process.__dict__: process.MessageLogger.G4cerr=dict() process.MessageLogger.G4cout=dict() process.MessageLogger.HCalGeom=dict() -process.Timing = cms.Service("Timing") - -process.RandomNumberGeneratorService = cms.Service("RandomNumberGeneratorService", - moduleSeeds = cms.PSet( - generator = cms.untracked.uint32(456789), - g4SimHits = cms.untracked.uint32(9876), - VtxSmeared = cms.untracked.uint32(12345) - ), - sourceSeed = cms.untracked.uint32(98765) -) - -process.source = cms.Source("EmptySource", - firstRun = cms.untracked.uint32(1), - firstEvent = cms.untracked.uint32(1) -) - -process.generator = cms.EDProducer("FlatRandomEGunProducer", - PGunParameters = cms.PSet( - PartID = cms.vint32(211), - MinEta = cms.double(0.5655), - MaxEta = cms.double(0.5655), - MinPhi = cms.double(-0.1309), - MaxPhi = cms.double(-0.1309), - MinE = cms.double(9.99), - MaxE = cms.double(10.01) - ), - Verbosity = cms.untracked.int32(0), - AddAntiParticle = cms.bool(False) -) - -process.maxEvents = cms.untracked.PSet( - input = cms.untracked.int32(1) -) -process.p1 = cms.Path(process.generator*process.g4SimHits) -process.g4SimHits.UseMagneticField = False -process.g4SimHits.Physics.DefaultCutValue = 1. -process.g4SimHits.Watchers = cms.VPSet(cms.PSet( - Resolution = cms.untracked.int32(1000), - type = cms.string('CheckOverlap'), - NodeNames = cms.untracked.vstring('CMSE') -)) +from SimG4Core.PrintGeomInfo.g4TestGeometry_cfi import * +process = checkOverlap(process) +process.Timing = cms.Service("Timing") +# enable Geant4 overlap check +process.g4SimHits.CheckGeometry = True + +# Geant4 geometry check +process.g4SimHits.G4CheckOverlap.OutputBaseName = "Run3" +process.g4SimHits.G4CheckOverlap.OverlapFlag = True +process.g4SimHits.G4CheckOverlap.Tolerance = 0.01 +process.g4SimHits.G4CheckOverlap.Resolution = 10000 +process.g4SimHits.G4CheckOverlap.Depth = -1 +# tells if NodeName is G4Region or G4PhysicalVolume +process.g4SimHits.G4CheckOverlap.RegionFlag = False +# list of names +process.g4SimHits.G4CheckOverlap.NodeNames = ['OCMS'] +# enable dump gdml file +process.g4SimHits.G4CheckOverlap.gdmlFlag = False +# if defined a G4PhysicsVolume info is printed +process.g4SimHits.G4CheckOverlap.PVname = '' +# if defined a list of daughter volumes is printed +process.g4SimHits.G4CheckOverlap.LVname = '' + +# extra output files, created if a name is not empty +process.g4SimHits.FileNameField = '' +process.g4SimHits.FileNameGDML = '' +process.g4SimHits.FileNameRegions = '' diff --git a/Geometry/HcalSimData/data/hf/v1/hf.xml b/Geometry/HcalSimData/data/hf/v1/hf.xml new file mode 100644 index 0000000000000..42b39b759c24e --- /dev/null +++ b/Geometry/HcalSimData/data/hf/v1/hf.xml @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/HLTrigger/Tools/python/convertToRaw.py b/HLTrigger/Tools/python/convertToRaw.py index 5183274a18798..92caf7fbf8587 100644 --- a/HLTrigger/Tools/python/convertToRaw.py +++ b/HLTrigger/Tools/python/convertToRaw.py @@ -6,6 +6,7 @@ # [lumiNumber=NNNN] \ # [eventsPerFile=50] \ # [eventsPerLumi=11650] \ +# [rawDataCollection=rawDataCollector] \ # [outputPath=output_directory] # # The output files will appear as output_directory/runNNNNNN/runNNNNNN_lumiNNNN_indexNNNNNN.raw . @@ -41,7 +42,7 @@ ) process.writer = cms.OutputModule("RawStreamFileWriterForBU", - source = cms.InputTag('rawDataCollector'), + source = cms.InputTag('rawDataCollector'), # to be overwritten after parsing the command line options numEventsPerFile = cms.uint32(0) # to be overwritten after parsing the command line options ) @@ -91,6 +92,12 @@ VarParsing.VarParsing.varType.int, "Split the output into files with at most this number of events") +options.register('rawDataCollection', + 'rawDataCollector', + VarParsing.VarParsing.multiplicity.singleton, + VarParsing.VarParsing.varType.string, + "FEDRawDataCollection to be repacked into RAW format") + options.register('outputPath', os.getcwd(), VarParsing.VarParsing.multiplicity.singleton, @@ -125,6 +132,7 @@ process.EvFDaqDirector.runNumber = options.runNumber process.EvFDaqDirector.baseDir = options.outputPath process.EvFDaqDirector.buBaseDir = options.outputPath +process.writer.source = options.rawDataCollection process.writer.numEventsPerFile = options.eventsPerFile process.MessageLogger.cerr.FwkReport.reportEvery = options.eventsPerFile diff --git a/HLTrigger/Tools/scripts/convertToRaw b/HLTrigger/Tools/scripts/convertToRaw index 1af03633cfa1e..b2aaef2bb3da0 100755 --- a/HLTrigger/Tools/scripts/convertToRaw +++ b/HLTrigger/Tools/scripts/convertToRaw @@ -74,16 +74,17 @@ class LuminosityBlockRange: # default values events_per_file = 100 events_per_lumi = 11655 -output_directory = '' +output_directory = os.getcwd() parser = argparse.ArgumentParser(description='Convert RAW data from .root format to .raw format.', formatter_class = argparse.ArgumentDefaultsHelpFormatter) parser.add_argument('files', type=str, metavar='FILES', nargs='+', help='input files in .root format') -parser.add_argument('-o', '--output', type=str, dest='output_directory', metavar='PATH', default='', help='base path to store the output files; subdirectories based on the run number are automatically created') +parser.add_argument('-s', '--source', type=str, dest='raw_data_collection', metavar='TAG', default='rawDataCollector', help='name of the FEDRawDataCollection to be repacked into RAW format') +parser.add_argument('-o', '--output', type=str, dest='output_directory', metavar='PATH', default=os.getcwd(), help='base path to store the output files; subdirectories based on the run number are automatically created') parser.add_argument('-f', '--events_per_file', type=int, dest='events_per_file', metavar='EVENTS', default=events_per_file, help='split the output into files with at most EVENTS events') parser.add_argument('-l', '--events_per_lumi', type=int, dest='events_per_lumi', metavar='EVENTS', default=events_per_lumi, help='process at most EVENTS events in each lumisection') parser.add_argument('-r', '--range', type=LuminosityBlockRange, dest='range', metavar='[RUN:LUMI-RUN:LUMI]', default='all', help='process only the runs and lumisections in the given range') parser.add_argument('-v', '--verbose', dest='verbose', action='store_true', default=False, help='print additional information while processing the input files') -parser.add_argument('--one-file-per-lumi', action='store_true', dest='one_file_per_lumi', default=False, help='assume that lumisections are not split across files (and disable --events_per_lumi)') +parser.add_argument('-1', '--one-file-per-lumi', action='store_true', dest='one_file_per_lumi', default=False, help='assume that lumisections are not split across files (and disable --events_per_lumi)') # parse the command line arguments and options args = parser.parse_args() @@ -107,10 +108,9 @@ for f in files: # run edmFileUtil --eventsInLumis ... print(f'preprocessing input file {f}') + output = subprocess.run(['edmFileUtil', '--eventsInLumis', f], capture_output=True, text=True) if args.verbose: - output = subprocess.run(['edmFileUtil', '--eventsInLumis', f], stdout=None, stderr=None) - else: - output = subprocess.run(['edmFileUtil', '--eventsInLumis', f], capture_output=True, text=True) + print(output.stdout) # handle error conditions if output.returncode < 0: @@ -195,7 +195,7 @@ for run in sorted(content): # process the whole run lumis = sorted(content[run]) print('found run %d, lumis %d-%d, with %d events' % (run, min(lumis), max(lumis), sum(content[run][lumi].events for lumi in lumis))) - cmsRun(config_py, args.verbose, inputFiles = ','.join(files), runNumber = run, eventsPerFile = args.events_per_file, outputPath = args.output_directory) + cmsRun(config_py, args.verbose, inputFiles = ','.join(files), runNumber = run, eventsPerFile = args.events_per_file, rawDataCollection = args.raw_data_collection, outputPath = args.output_directory) converted_files = glob.glob(run_path + f'/run{run:06d}_ls{lumi:04d}_*.raw') else: @@ -213,7 +213,7 @@ for run in sorted(content): lumi_path = args.output_directory + f'/run{run:06d}_ls{lumi:04d}' shutil.rmtree(lumi_path, ignore_errors=True) os.makedirs(lumi_path) - cmsRun(config_py, args.verbose, inputFiles = ','.join(content[run][lumi].files), runNumber = run, lumiNumber = lumi, eventsPerLumi = args.events_per_lumi, eventsPerFile = args.events_per_file, outputPath = lumi_path) + cmsRun(config_py, args.verbose, inputFiles = ','.join(content[run][lumi].files), runNumber = run, lumiNumber = lumi, eventsPerLumi = args.events_per_lumi, eventsPerFile = args.events_per_file, rawDataCollection = args.raw_data_collection, outputPath = lumi_path) # merge all lumisetions data diff --git a/L1Trigger/L1TNtuples/plugins/L1JetRecoTreeProducer.cc b/L1Trigger/L1TNtuples/plugins/L1JetRecoTreeProducer.cc index 1ea55a694e707..55f9bcf6d58d2 100644 --- a/L1Trigger/L1TNtuples/plugins/L1JetRecoTreeProducer.cc +++ b/L1Trigger/L1TNtuples/plugins/L1JetRecoTreeProducer.cc @@ -80,7 +80,7 @@ class L1JetRecoTreeProducer : public edm::one::EDAnalyzer pfMet, edm::Handle); void doPUPPIMetNoMu(edm::Handle puppiMet, edm::Handle); - void doZPt(edm::Handle); + void doZPt(edm::Handle muons, edm::Handle > corrPuppiJets); bool pfJetID(const reco::PFJet& jet); bool puppiJetID(const pat::Jet& jet); @@ -129,7 +129,6 @@ class L1JetRecoTreeProducer : public edm::one::EDAnalyzer cal met_data->caloSumEtBE = theMet.sumEt(); } -void L1JetRecoTreeProducer::doZPt(edm::Handle muons) { - if (muons->size() < 2) { +void L1JetRecoTreeProducer::doZPt(edm::Handle muons, + edm::Handle > corrPuppiJets) { + bool passPuppiJetPtCut = false; + + for (auto it = corrPuppiJets->begin(); it != corrPuppiJets->end(); ++it) { + if (!puppiJetID(*it)) + continue; + if (it->muonEnergyFraction() > 0.5 || it->chargedEmEnergyFraction() > 0.5) + continue; + if (it->pt() > 30) + passPuppiJetPtCut = true; + } + + if (!passPuppiJetPtCut || muons->size() < 2) { met_data->zPt = -999; return; } diff --git a/RecoEgamma/EgammaMCTools/plugins/BuildFile.xml b/RecoEgamma/EgammaMCTools/plugins/BuildFile.xml index 23dc7d7d8e660..fdc2a9c83e10b 100644 --- a/RecoEgamma/EgammaMCTools/plugins/BuildFile.xml +++ b/RecoEgamma/EgammaMCTools/plugins/BuildFile.xml @@ -7,5 +7,6 @@ + diff --git a/RecoEgamma/EgammaMCTools/plugins/PFClusterMatchedToPhotonsSelector.cc b/RecoEgamma/EgammaMCTools/plugins/PFClusterMatchedToPhotonsSelector.cc index 62d0e8b0ccacb..3909694c86c8a 100644 --- a/RecoEgamma/EgammaMCTools/plugins/PFClusterMatchedToPhotonsSelector.cc +++ b/RecoEgamma/EgammaMCTools/plugins/PFClusterMatchedToPhotonsSelector.cc @@ -29,11 +29,13 @@ #include "DataFormats/Common/interface/ValueMap.h" #include "DataFormats/Common/interface/Ref.h" +#include "DataFormats/EcalRecHit/interface/EcalRecHitCollections.h" #include "DataFormats/Math/interface/deltaR.h" #include "DataFormats/ParticleFlowReco/interface/PFCluster.h" #include "DataFormats/ParticleFlowReco/interface/PFClusterFwd.h" #include "DataFormats/HepMCCandidate/interface/GenParticle.h" #include "DataFormats/HepMCCandidate/interface/GenParticleFwd.h" +#include "RecoEcal/EgammaCoreTools/interface/EcalClusterLazyTools.h" #include "SimDataFormats/TrackingAnalysis/interface/TrackingParticle.h" #include "SimDataFormats/TrackingAnalysis/interface/TrackingParticleFwd.h" @@ -52,6 +54,11 @@ class PFClusterMatchedToPhotonsSelector : public edm::stream::EDProducer<> { edm::EDGetTokenT particleFlowClusterECALToken_; edm::EDGetTokenT associationToken_; edm::EDGetTokenT trackingParticleToken_; + edm::EDGetTokenT recHitsEB_; + edm::EDGetTokenT recHitsEE_; + + const EcalClusterLazyTools::ESGetTokens ecalClusterToolsESGetTokens_; + double matchMaxDR2_; double matchMaxDEDR2_; @@ -60,7 +67,8 @@ class PFClusterMatchedToPhotonsSelector : public edm::stream::EDProducer<> { double volumeZ_EE_; }; -PFClusterMatchedToPhotonsSelector::PFClusterMatchedToPhotonsSelector(const edm::ParameterSet& iConfig) { +PFClusterMatchedToPhotonsSelector::PFClusterMatchedToPhotonsSelector(const edm::ParameterSet& iConfig) + : ecalClusterToolsESGetTokens_{consumesCollector()} { //now do what ever initialization is needed particleFlowClusterECALToken_ = consumes(iConfig.getParameter("pfClustersTag")); @@ -69,6 +77,8 @@ PFClusterMatchedToPhotonsSelector::PFClusterMatchedToPhotonsSelector(const edm:: trackingParticleToken_ = consumes(iConfig.getParameter("trackingParticleTag")); genParticleToken_ = consumes(iConfig.getParameter("genParticleTag")); + recHitsEB_ = consumes(iConfig.getParameter("recHitsEBLabel")); + recHitsEE_ = consumes(iConfig.getParameter("recHitsEELabel")); matchMaxDR2_ = iConfig.getParameter("maxDR2"); matchMaxDEDR2_ = iConfig.getParameter("maxDEDR2"); @@ -77,8 +87,10 @@ PFClusterMatchedToPhotonsSelector::PFClusterMatchedToPhotonsSelector(const edm:: volumeZ_EE_ = iConfig.getParameter("volumeZ_EE"); produces(); - produces(); produces >(); + produces >(); + produces >("PS1"); + produces >("PS2"); } void PFClusterMatchedToPhotonsSelector::fillDescriptions(edm::ConfigurationDescriptions& descriptions) { @@ -86,6 +98,8 @@ void PFClusterMatchedToPhotonsSelector::fillDescriptions(edm::ConfigurationDescr desc.add("pfClustersTag", edm::InputTag("particleFlowClusterECAL")); desc.add("trackingParticleTag", edm::InputTag("mix", "MergedTrackTruth")); desc.add("genParticleTag", edm::InputTag("genParticles")); + desc.add("recHitsEBLabel", edm::InputTag("ecalRecHit", "EcalRecHitsEB")); + desc.add("recHitsEELabel", edm::InputTag("ecalRecHit", "EcalRecHitsEE")); desc.add("maxDR2", 0.1 * 0.1); desc.add("maxDEDR2", 0.5 * 0.5); desc.add("volumeZ_EB", 304.5); @@ -99,20 +113,26 @@ void PFClusterMatchedToPhotonsSelector::produce(edm::Event& iEvent, const edm::E edm::Handle associationHandle_; edm::Handle trackingParticleHandle_; edm::Handle genParticleHandle_; + iEvent.getByToken(particleFlowClusterECALToken_, particleFlowClusterECALHandle_); iEvent.getByToken(trackingParticleToken_, trackingParticleHandle_); iEvent.getByToken(genParticleToken_, genParticleHandle_); iEvent.getByToken(associationToken_, associationHandle_); std::unique_ptr out = std::make_unique(); - std::unique_ptr association_out = - std::make_unique(); std::unique_ptr > genmatching_out = std::make_unique >(); + std::unique_ptr > clustersize_out = std::make_unique >(); + std::unique_ptr > energyPS1_out = std::make_unique >(); + std::unique_ptr > energyPS2_out = std::make_unique >(); std::vector genmatching; + std::vector clustersize; + std::vector energyPS1; + std::vector energyPS2; + + EcalClusterLazyTools lazyTool(iEvent, ecalClusterToolsESGetTokens_.get(iSetup), recHitsEB_, recHitsEE_); - size_t iN(0); for (size_t iP = 0; iP < particleFlowClusterECALHandle_->size(); iP++) { auto&& pfCluster = particleFlowClusterECALHandle_->at(iP); bool isMatched = false; @@ -129,6 +149,7 @@ void PFClusterMatchedToPhotonsSelector::produce(edm::Event& iEvent, const edm::E if (trackingParticle.status() != 1) continue; matchedKey = trackingParticle.genParticles().at(0).key(); + float dR2 = reco::deltaR2(trackingParticle, pfCluster.position()); if (dR2 > matchMaxDR2_) continue; @@ -160,23 +181,54 @@ void PFClusterMatchedToPhotonsSelector::produce(edm::Event& iEvent, const edm::E if (isMatched) { out->push_back(pfCluster); - for (size_t i = 0; i < associationHandle_.product()->size(); i++) { - if (associationHandle_.product()->at(i).first == iP) { - association_out->push_back(std::make_pair(iN, associationHandle_.product()->at(i).second)); + double ePS1 = 0, ePS2 = 0; + if (!(pfCluster.layer() == PFLayer::ECAL_BARREL)) { + auto ee_key_val = std::make_pair(iP, edm::Ptr()); + const auto clustops = std::equal_range( + associationHandle_.product()->begin(), associationHandle_.product()->end(), ee_key_val, sortByKey); + for (auto i_ps = clustops.first; i_ps != clustops.second; ++i_ps) { + edm::Ptr psclus(i_ps->second); + switch (psclus->layer()) { + case PFLayer::PS1: + ePS1 += psclus->energy(); + break; + case PFLayer::PS2: + ePS2 += psclus->energy(); + break; + default: + break; + } } } + genmatching.push_back(edm::Ref(genParticleHandle_, matchedKey)); + clustersize.push_back(lazyTool.n5x5(pfCluster)); + energyPS1.push_back(ePS1); + energyPS2.push_back(ePS2); } } - std::sort(association_out->begin(), association_out->end(), sortByKey); edm::OrphanHandle pfClusterHandle = iEvent.put(std::move(out)); - iEvent.put(std::move(association_out)); edm::ValueMap::Filler mapFiller(*genmatching_out); mapFiller.insert(pfClusterHandle, genmatching.begin(), genmatching.end()); mapFiller.fill(); iEvent.put(std::move(genmatching_out)); + + edm::ValueMap::Filler mapFiller_int(*clustersize_out); + mapFiller_int.insert(pfClusterHandle, clustersize.begin(), clustersize.end()); + mapFiller_int.fill(); + iEvent.put(std::move(clustersize_out)); + + edm::ValueMap::Filler mapFiller_energyPS1(*energyPS1_out); + mapFiller_energyPS1.insert(pfClusterHandle, energyPS1.begin(), energyPS1.end()); + mapFiller_energyPS1.fill(); + iEvent.put(std::move(energyPS1_out), "PS1"); + + edm::ValueMap::Filler mapFiller_energyPS2(*energyPS2_out); + mapFiller_energyPS2.insert(pfClusterHandle, energyPS2.begin(), energyPS2.end()); + mapFiller_energyPS2.fill(); + iEvent.put(std::move(energyPS2_out), "PS2"); } //define this as a plug-in diff --git a/SimG4CMS/Calo/interface/HGCSD.h b/SimG4CMS/Calo/interface/HGCSD.h index b490891db1d89..609fa316407c8 100644 --- a/SimG4CMS/Calo/interface/HGCSD.h +++ b/SimG4CMS/Calo/interface/HGCSD.h @@ -54,6 +54,7 @@ class HGCSD : public CaloSD, public Observer { int levelT_; bool storeAllG4Hits_, rejectMB_, waferRot_; double mouseBiteCut_; + bool dd4hep_; std::vector angles_; TTree *tree_; diff --git a/SimG4CMS/Calo/interface/HGCalSD.h b/SimG4CMS/Calo/interface/HGCalSD.h index 28389d8e40368..e3fe8ffa9918f 100644 --- a/SimG4CMS/Calo/interface/HGCalSD.h +++ b/SimG4CMS/Calo/interface/HGCalSD.h @@ -54,6 +54,7 @@ class HGCalSD : public CaloSD, public Observer { bool storeAllG4Hits_; bool fiducialCut_, rejectMB_, waferRot_, checkID_; int useSimWt_, verbose_; + bool dd4hep_; const double tan30deg_, cos30deg_; std::vector angles_; std::string missingFile_; diff --git a/SimG4CMS/Calo/src/HGCSD.cc b/SimG4CMS/Calo/src/HGCSD.cc index c3450afb97ce0..561adde390b25 100644 --- a/SimG4CMS/Calo/src/HGCSD.cc +++ b/SimG4CMS/Calo/src/HGCSD.cc @@ -56,6 +56,7 @@ HGCSD::HGCSD(const std::string& name, double waferSize = m_HGC.getUntrackedParameter("WaferSize") * CLHEP::mm; double mouseBite = m_HGC.getUntrackedParameter("MouseBite") * CLHEP::mm; mouseBiteCut_ = waferSize * tan(30.0 * CLHEP::deg) - mouseBite; + dd4hep_ = p.getParameter("g4GeometryDD4hepSource"); if (storeAllG4Hits_) { setUseMap(false); @@ -206,6 +207,8 @@ void HGCSD::update(const BeginOfJob* job) { geom_mode_ = hgcons_->geomMode(); slopeMin_ = hgcons_->minSlope(); levelT_ = hgcons_->levelTop(); + if (dd4hep_) + ++levelT_; numberingScheme_ = std::make_unique(*hgcons_, nameX_); if (rejectMB_) mouseBite_ = std::make_unique(*hgcons_, angles_, mouseBiteCut_, waferRot_); @@ -215,7 +218,7 @@ void HGCSD::update(const BeginOfJob* job) { } #ifdef EDM_ML_DEBUG edm::LogVerbatim("HGCSim") << "HGCSD::Initialized with mode " << geom_mode_ << " Slope cut " << slopeMin_ - << " top Level " << levelT_; + << " top Level " << levelT_ << " dd4hep " << dd4hep_; #endif } diff --git a/SimG4CMS/Calo/src/HGCalSD.cc b/SimG4CMS/Calo/src/HGCalSD.cc index cf9bb067f4a86..441b72ba9e261 100644 --- a/SimG4CMS/Calo/src/HGCalSD.cc +++ b/SimG4CMS/Calo/src/HGCalSD.cc @@ -62,6 +62,7 @@ HGCalSD::HGCalSD(const std::string& name, missingFile_ = m_HGC.getUntrackedParameter("MissingWaferFile"); checkID_ = m_HGC.getUntrackedParameter("CheckID"); verbose_ = m_HGC.getUntrackedParameter("Verbosity"); + dd4hep_ = p.getParameter("g4GeometryDD4hepSource"); if (storeAllG4Hits_) { setUseMap(false); @@ -247,6 +248,10 @@ void HGCalSD::update(const BeginOfJob* job) { slopeMin_ = hgcons_->minSlope(); levelT1_ = hgcons_->levelTop(0); levelT2_ = hgcons_->levelTop(1); + if (dd4hep_) { + ++levelT1_; + ++levelT2_; + } useSimWt_ = hgcons_->getParameter()->useSimWt_; int useOffset = hgcons_->getParameter()->useOffset_; double waferSize = hgcons_->waferSize(false); @@ -263,7 +268,8 @@ void HGCalSD::update(const BeginOfJob* job) { edm::LogVerbatim("HGCSim") << "HGCalSD::Initialized with mode " << geom_mode_ << " Slope cut " << slopeMin_ << " top Level " << levelT1_ << ":" << levelT2_ << " useSimWt " << useSimWt_ << " wafer " << waferSize << ":" << mouseBite << ":" << guardRingOffset << ":" << sensorSizeOffset - << ":" << mouseBiteNew << ":" << mouseBiteCut_ << " useOffset " << useOffset; + << ":" << mouseBiteNew << ":" << mouseBiteCut_ << " useOffset " << useOffset + << " dd4hep " << dd4hep_; #endif numberingScheme_ = std::make_unique(*hgcons_, mydet_, nameX_, missingFile_); diff --git a/SimG4CMS/Calo/test/python/Sim2026_cfg.py b/SimG4CMS/Calo/test/python/Sim2026_cfg.py index 7e0a60e0da18f..a4d4b07caa220 100644 --- a/SimG4CMS/Calo/test/python/Sim2026_cfg.py +++ b/SimG4CMS/Calo/test/python/Sim2026_cfg.py @@ -112,6 +112,7 @@ process.analysis_step3 = cms.EndPath(process.hgcalHitCheckHEB) process.g4SimHits.Physics.type = 'SimG4Core/Physics/FTFP_BERT_EMM' +process.g4SimHits.HGCSD.Verbosity = 0 # Schedule definition process.schedule = cms.Schedule(process.simulation_step, diff --git a/SimG4CMS/Forward/interface/MtdSD.h b/SimG4CMS/Forward/interface/MtdSD.h index fd70a399a428f..46830841d2653 100644 --- a/SimG4CMS/Forward/interface/MtdSD.h +++ b/SimG4CMS/Forward/interface/MtdSD.h @@ -28,6 +28,10 @@ class MtdSD : public TimingSD { int getTrackID(const G4Track *) override; private: + static constexpr unsigned int k_idsecOffset = 100000000; + static constexpr unsigned int k_idloopOffset = 200000000; + static constexpr unsigned int k_idFromCaloOffset = 300000000; + double energyCut; double energyHistoryCut; diff --git a/SimG4CMS/Forward/src/MtdSD.cc b/SimG4CMS/Forward/src/MtdSD.cc index 86561f8ded9c4..1c42dee56aefc 100644 --- a/SimG4CMS/Forward/src/MtdSD.cc +++ b/SimG4CMS/Forward/src/MtdSD.cc @@ -106,16 +106,23 @@ int MtdSD::getTrackID(const G4Track* aTrack) { trkInfo->Print(); #endif if (rname == "FastTimerRegionSensBTL") { - if (trkInfo->isBTLdaughter()) { - theID = trkInfo->idAtBTLentrance(); + theID = trkInfo->mcTruthID(); + if (trkInfo->isExtSecondary() && !trkInfo->isInTrkFromBackscattering()) { + theID += k_idsecOffset; + } else if (trkInfo->isInTrkFromBackscattering()) { + theID += k_idFromCaloOffset; + } else if (trkInfo->isBTLlooper()) { + theID += k_idloopOffset; } #ifdef EDM_ML_DEBUG - edm::LogVerbatim("MtdSim") << "BTL Track ID: " << trkInfo->idAtBTLentrance() << ":" << theID; + edm::LogVerbatim("MtdSim") << "MtdSD: Track ID: " << aTrack->GetTrackID() + << " BTL Track ID: " << trkInfo->mcTruthID() << ":" << theID; #endif } else if (rname == "FastTimerRegionSensETL") { theID = trkInfo->getIDonCaloSurface(); #ifdef EDM_ML_DEBUG - edm::LogVerbatim("MtdSim") << "ETL Track ID: " << trkInfo->getIDonCaloSurface() << ":" << theID; + edm::LogVerbatim("MtdSim") << "MtdSD: Track ID: " << aTrack->GetTrackID() + << " ETL Track ID: " << trkInfo->mcTruthID() << ":" << theID; #endif } else { throw cms::Exception("MtdSDError") << "MtdSD called in incorrect region " << rname; diff --git a/SimG4Core/Application/interface/Phase2SteppingAction.h b/SimG4Core/Application/interface/Phase2SteppingAction.h index 9599014fc3c89..c59c97adeebdc 100644 --- a/SimG4Core/Application/interface/Phase2SteppingAction.h +++ b/SimG4Core/Application/interface/Phase2SteppingAction.h @@ -35,6 +35,7 @@ class Phase2SteppingAction : public G4UserSteppingAction { bool isLowEnergy(const G4LogicalVolume*, const G4Track*) const; void PrintKilledTrack(const G4Track*, const TrackStatus&) const; + const G4VPhysicalVolume* cmse{nullptr}; const G4VPhysicalVolume* tracker{nullptr}; const G4VPhysicalVolume* calo{nullptr}; const G4VPhysicalVolume* btl{nullptr}; diff --git a/SimG4Core/Application/src/Phase2SteppingAction.cc b/SimG4Core/Application/src/Phase2SteppingAction.cc index 2fbd412238962..983b050ebd03d 100644 --- a/SimG4Core/Application/src/Phase2SteppingAction.cc +++ b/SimG4Core/Application/src/Phase2SteppingAction.cc @@ -168,17 +168,14 @@ void Phase2SteppingAction::UserSteppingAction(const G4Step* aStep) { TrackInformation* trkinfo = static_cast(theTrack->GetUserInformation()); if (!trkinfo->isFromTtoBTL() && !trkinfo->isFromBTLtoT()) { trkinfo->setFromTtoBTL(); - trkinfo->setIdAtBTLentrance(theTrack->GetTrackID()); #ifdef DebugLog LogDebug("SimG4CoreApplication") << "Setting flag for Tracker -> BTL " << trkinfo->isFromTtoBTL() - << " IdAtBTLentrance = " << trkinfo->idAtBTLentrance(); + << " IdAtBTLentrance = " << trkinfo->mcTruthID(); #endif } else { trkinfo->setBTLlooper(); - trkinfo->setIdAtBTLentrance(theTrack->GetTrackID()); #ifdef DebugLog LogDebug("SimG4CoreApplication") << "Setting flag for BTL looper " << trkinfo->isBTLlooper(); - trkinfo->Print(); #endif } } else if (preStep->GetPhysicalVolume() == btl && postStep->GetPhysicalVolume() == tracker) { @@ -196,6 +193,16 @@ void Phase2SteppingAction::UserSteppingAction(const G4Step* aStep) { if (!trkinfo->crossedBoundary()) { trkinfo->setCrossedBoundary(theTrack); } + } else if (preStep->GetPhysicalVolume() == calo && postStep->GetPhysicalVolume() == cmse) { + // store transition calo -> cmse to tag backscattering + TrackInformation* trkinfo = static_cast(theTrack->GetUserInformation()); + if (!trkinfo->isInTrkFromBackscattering()) { + trkinfo->setInTrkFromBackscattering(); +#ifdef DebugLog + LogDebug("SimG4CoreApplication") << "Setting flag for backscattering from CALO " + << trkinfo->isInTrkFromBackscattering(); +#endif + } } } else { theTrack->SetTrackStatus(fStopAndKill); @@ -236,8 +243,10 @@ bool Phase2SteppingAction::initPointer() { calo = pvcite; } else if (pvname == "BarrelTimingLayer" || pvname == "btl:BarrelTimingLayer_1") { btl = pvcite; + } else if (pvname == "CMSE" || pvname == "cms:CMSE_1") { + cmse = pvcite; } - if (tracker && calo && btl) + if (tracker && calo && btl && cmse) break; } edm::LogVerbatim("SimG4CoreApplication") diff --git a/SimG4Core/Notification/interface/TrackInformation.h b/SimG4Core/Notification/interface/TrackInformation.h index 954675cc09e21..54359b7f8a22f 100644 --- a/SimG4Core/Notification/interface/TrackInformation.h +++ b/SimG4Core/Notification/interface/TrackInformation.h @@ -90,13 +90,12 @@ class TrackInformation : public G4VUserTrackInformation { bool isFromTtoBTL() const { return (mtdStatus_ >> 0) & 1; } void setFromBTLtoT() { mtdStatus_ |= 1 << 1; } // 2nd bit bool isFromBTLtoT() const { return (mtdStatus_ >> 1) & 1; } - void setBTLdaughter() { mtdStatus_ |= 1 << 2; } // 3rd bit - bool isBTLdaughter() const { return (mtdStatus_ >> 2) & 1; } - void setBTLlooper() { mtdStatus_ |= 1 << 3; } // 4th bit - bool isBTLlooper() const { return (mtdStatus_ >> 3) & 1; } - - int idAtBTLentrance() const { return idAtBTLentrance_; } - void setIdAtBTLentrance(int id) { idAtBTLentrance_ = id; } + void setBTLlooper() { mtdStatus_ |= 1 << 2; } // 3th bit + bool isBTLlooper() const { return (mtdStatus_ >> 2) & 1; } + void setInTrkFromBackscattering() { mtdStatus_ |= 1 << 3; } // 4th bit + bool isInTrkFromBackscattering() const { return (mtdStatus_ >> 3) & 1; } + void setExtSecondary() { mtdStatus_ |= 1 << 4; } //5th bit + bool isExtSecondary() const { return (mtdStatus_ >> 4) & 1; } void Print() const override; @@ -119,7 +118,6 @@ class TrackInformation : public G4VUserTrackInformation { int mcTruthID_{-1}; int caloSurfaceParticlePID_{0}; int castorHitPID_{0}; - int idAtBTLentrance_{0}; uint8_t mtdStatus_{0}; double genParticleP_{0.}; double caloSurfaceParticleP_{0.}; diff --git a/SimG4Core/Notification/src/MCTruthUtil.cc b/SimG4Core/Notification/src/MCTruthUtil.cc index 2f8fb2df03589..89ab353951475 100644 --- a/SimG4Core/Notification/src/MCTruthUtil.cc +++ b/SimG4Core/Notification/src/MCTruthUtil.cc @@ -1,4 +1,3 @@ - #include "SimG4Core/Notification/interface/MCTruthUtil.h" #include "SimG4Core/Notification/interface/TrackInformation.h" @@ -18,8 +17,6 @@ void MCTruthUtil::primary(G4Track *aTrack) { void MCTruthUtil::secondary(G4Track *aTrack, const G4Track &mother, int flag) { auto motherInfo = static_cast(mother.GetUserInformation()); auto trkInfo = new TrackInformation(); - LogDebug("SimG4CoreApplication") << "MCTruthUtil called for " << aTrack->GetTrackID() << " mother " - << motherInfo->isPrimary() << " flag " << flag; // Take care of cascade decays if (flag == 1) { @@ -57,17 +54,26 @@ void MCTruthUtil::secondary(G4Track *aTrack, const G4Track &mother, int flag) { trkInfo->setCastorHitPID(motherInfo->getCastorHitPID()); } - // manage ID of tracks in BTL to map them to SimTracks to be stored - if (isInBTL(aTrack)) { - if ((motherInfo->storeTrack() && motherInfo->isFromTtoBTL()) || motherInfo->isBTLdaughter()) { - trkInfo->setBTLdaughter(); - trkInfo->setIdAtBTLentrance(motherInfo->idAtBTLentrance()); - LogDebug("SimG4CoreApplication") << "NewTrackAction: secondary in BTL " << trkInfo->isBTLdaughter() - << " from mother ID " << trkInfo->idAtBTLentrance(); - } + // for MTD + if (!trkInfo->isPrimary() && !isInBTL(aTrack)) { + trkInfo->setExtSecondary(); + } + if (motherInfo->isExtSecondary()) { + trkInfo->setExtSecondary(); + } + if (motherInfo->isBTLlooper()) { + trkInfo->setBTLlooper(); + } + if (motherInfo->isInTrkFromBackscattering()) { + trkInfo->setInTrkFromBackscattering(); } aTrack->SetUserInformation(trkInfo); +#ifdef EDM_ML_DEBUG + LogTrace("SimG4CoreApplication") << "MCTruthUtil called for " << aTrack->GetTrackID() << " mother " + << motherInfo->isPrimary() << " flag " << flag; + trkInfo->Print(); +#endif } bool MCTruthUtil::isInBTL(const G4Track *aTrack) { diff --git a/SimG4Core/Notification/src/TrackInformation.cc b/SimG4Core/Notification/src/TrackInformation.cc index bd6f457879235..7e059f2b42712 100644 --- a/SimG4Core/Notification/src/TrackInformation.cc +++ b/SimG4Core/Notification/src/TrackInformation.cc @@ -26,6 +26,7 @@ void TrackInformation::Print() const { << " hasHits = " << hasHits_ << "\n" << " isPrimary = " << isPrimary_ << "\n" << " isGeneratedSecondary = " << isGeneratedSecondary_ << "\n" + << " mcTruthID = " << mcTruthID_ << "\n" << " isInHistory = " << isInHistory_ << "\n" << " idOnCaloSurface = " << getIDonCaloSurface() << "\n" << " caloIDChecked = " << caloIDChecked() << "\n" @@ -33,7 +34,8 @@ void TrackInformation::Print() const { << " idLastVolume = " << idLastVolume_ << "\n" << " isFromTtoBTL = " << isFromTtoBTL() << "\n" << " isFromBTLtoT = " << isFromBTLtoT() << "\n" - << " isBTLdaughter = " << isBTLdaughter() << "\n" << " isBTLlooper = " << isBTLlooper() << "\n" - << " idAtBTLentrance = " << idAtBTLentrance_; + << " isInTrkFromBackscattering = " << isInTrkFromBackscattering() + << "\n" + << " isExtSecondary = " << isExtSecondary(); }