Skip to content

Commit

Permalink
Merge pull request #5046 from alja/slhc-tgeo-port
Browse files Browse the repository at this point in the history
SLHC conversion of ecal and hcal reco geometry to TGeo format
  • Loading branch information
cmsbuild committed Sep 2, 2014
2 parents 90b52e5 + c078c65 commit 1e6d189
Show file tree
Hide file tree
Showing 4 changed files with 343 additions and 243 deletions.
6 changes: 4 additions & 2 deletions Fireworks/Core/src/FWGeometryTableManager.cc
Expand Up @@ -60,7 +60,6 @@ FWTableCellRendererBase* FWGeometryTableManager::cellRenderer(int iSortedRowNumb
// selection state
//
const NodeInfo& data = m_entries[unsortedRow];
TGeoNode& gn = *data.m_node;
bool isSelected = data.testBit(kHighlighted) || data.testBit(kSelected);
// printf("cell render %s \n", data.name());
if (data.testBit(kSelected))
Expand Down Expand Up @@ -122,7 +121,10 @@ FWTableCellRendererBase* FWGeometryTableManager::cellRenderer(int iSortedRowNumb
}
else if (iCol == kMaterialColumn)
{
renderer->setData( gn.GetVolume()->GetMaterial()->GetName(), isSelected);
if (data.m_node->GetVolume()->IsAssembly())
renderer->setData( "assembly", isSelected);
else
renderer->setData( data.m_node->GetVolume()->GetMaterial()->GetName(), isSelected);
return renderer;
}
else
Expand Down
8 changes: 4 additions & 4 deletions Fireworks/Geometry/interface/FWTGeoRecoGeometryESProducer.h
Expand Up @@ -42,11 +42,9 @@ class FWTGeoRecoGeometryESProducer : public edm::ESProducer
TGeoVolume* createVolume( const std::string& name, const GeomDet *det, const std::string& matname = "Air" );
TGeoMaterial* createMaterial( const std::string& name );

TGeoVolume* getTruncatedPyramidVolume(const CaloCellGeometry* cell);
TGeoVolume* getIdealZPrismVolume(const CaloCellGeometry* cell);
TGeoVolume* getIdealObliquePrismVolume(const CaloCellGeometry* cell);
TGeoVolume* getCalloCellVolume(const CaloCellGeometry* cell);
TGeoVolume* GetDaughter(TGeoVolume* mother, const char* prefix, int id);
TGeoVolume* GetTopHolder(const char* prefix);

void addPixelBarrelGeometry();
void addPixelForwardGeometry();
void addTIBGeometry();
Expand All @@ -58,6 +56,8 @@ class FWTGeoRecoGeometryESProducer : public edm::ESProducer
void addRPCGeometry();
void addGEMGeometry();
void addEcalCaloGeometry();
void addHcalCaloGeometryBarrel();
void addHcalCaloGeometryEndcap();

std::map<std::string, TGeoShape*> m_nameToShape;
std::map<TGeoShape*, TGeoVolume*> m_shapeToVolume;
Expand Down
10 changes: 8 additions & 2 deletions Fireworks/Geometry/python/dumpRecoGeometry_cfg.py
Expand Up @@ -3,7 +3,7 @@
import FWCore.ParameterSet.VarParsing as VarParsing
from FWCore.Utilities.Enumerate import Enumerate

varType = Enumerate ("Run1 2015 2017 2019 PhaseIPixel 2023Muon SLHC SLHCDB")
varType = Enumerate ("Run1 2015 2017 2019 PhaseIPixel 2023Muon 2023HGCal SLHC SLHCDB")

def help():
print "Usage: cmsRun dumpFWRecoGeometry_cfg.py tag=TAG "
Expand Down Expand Up @@ -40,7 +40,7 @@ def recoGeoLoad(score):
process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:mc', '')
process.load('Configuration.Geometry.GeometryExtendedPhaseIPixelReco_cff')

elif score == "2023Muon":
elif score == "2023Muon":
from Configuration.AlCa.GlobalTag import GlobalTag
process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '')
process.load('Configuration.Geometry.GeometryExtended2023MuonReco_cff')
Expand All @@ -49,6 +49,12 @@ def recoGeoLoad(score):
#call to customisation function cust_2023Muon imported from SLHCUpgradeSimulations.Configuration.combinedCustoms
# process = cust_2023Muon(process)

elif score == "2023HGCal":
from Configuration.AlCa.GlobalTag import GlobalTag
process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:upgradePLS3', '')
process.load('Configuration.Geometry.GeometryExtended2023HGCalV4MuonReco_cff')

elif score == "SLHCDB": # orig dumpFWRecoSLHCGeometry_cfg.py
process.GlobalTag.globaltag = 'DESIGN42_V17::All'
process.load("Configuration.StandardSequences.GeometryDB_cff")
Expand Down

0 comments on commit 1e6d189

Please sign in to comment.