28 for (
int i=1;
i!=7;
i++) {
31 end = tg.
endsetDU(det); assert(end>=off);
32 for (
int j=off; j!=
end; ++j) {
33 assert(tg.
detUnits()[j]->geographicalId().subdetId()==
i);
35 assert(tg.
detUnits()[j]->index()==j);
44 int BIG_PIX_PER_ROC_X = ptp.
vpars[2];
45 int BIG_PIX_PER_ROC_Y = ptp.
vpars[3];
51 std::vector<const GeometricDet*>
comp;
61 LogDebug(
"SubDetectorGeometricDetType") <<
"GeometriDet enumerator values of the subdetectors";
62 for(
unsigned int i=0;
i<subdetgd.size();++
i) {
63 assert(subdetgd[
i]->geographicalId().subdetId()>0 && subdetgd[
i]->geographicalId().subdetId()<7);
64 gdsubdetmap[subdetgd[
i]->geographicalId().subdetId()-1]= subdetgd[
i]->type();
65 LogTrace(
"SubDetectorGeometricDetType") <<
"subdet " <<
i 66 <<
" type " << subdetgd[
i]->type()
67 <<
" detid " << subdetgd[
i]->geographicalId().rawId()
68 <<
" subdetid " << subdetgd[
i]->geographicalId().subdetId();
71 std::vector<const GeometricDet*> dets[6];
72 std::vector<const GeometricDet*> & pixB = dets[0]; pixB.reserve(comp.size());
73 std::vector<const GeometricDet*> & pixF = dets[1]; pixF.reserve(comp.size());
74 std::vector<const GeometricDet*> & tib = dets[2]; tib.reserve(comp.size());
75 std::vector<const GeometricDet*> & tid = dets[3]; tid.reserve(comp.size());
76 std::vector<const GeometricDet*> & tob = dets[4]; tob.reserve(comp.size());
77 std::vector<const GeometricDet*> & tec = dets[5]; tec.reserve(comp.size());
80 dets[
i->geographicalID().subdetId()-1].emplace_back(
i);
86 for(
unsigned int i=0;
i<6;++
i) {
131 for(
unsigned int i=0;
i<6;++
i) {
138 for(
unsigned int i=0;
i<6;++
i) {
140 if(!dets[
i].
empty())
throw cms::Exception(
"NotEmptyUnknownSubDet") <<
"Subdetector " <<
i+1 <<
" is unknown but it is not empty: " << dets[
i].size();
146 verifyDUinTG(*tracker);
154 bool upgradeGeometry,
155 int BIG_PIX_PER_ROC_X,
156 int BIG_PIX_PER_ROC_Y)
158 LogDebug(
"BuildingGeomDetUnits") <<
" Pixel type. Size of vector: " << gdv.size()
159 <<
" GeomDetType subdetector: " << det
161 <<
" big pix per ROC x: " << BIG_PIX_PER_ROC_X <<
" y: " << BIG_PIX_PER_ROC_Y
162 <<
" is upgrade: " << upgradeGeometry;
170 std::unique_ptr<const Bounds> bounds(
i->bounds());
179 i->pixROCx(),
i->pixROCy());
199 LogDebug(
"BuildingGeomDetUnits") <<
" Strip type. Size of vector: " << gdv.size()
200 <<
" GeomDetType subdetector: " << det
210 std::unique_ptr<const Bounds> bounds(
i->bounds());
236 auto const & gdu = tracker->
detUnits();
239 for(u_int32_t
i=0;
i<gdu.size();
i++){
243 string gduTypeName = gdu[
i]->type().name();
246 if( (gduTypeName.find(
"Ster")!=std::string::npos ||
247 gduTypeName.find(
"Lower")!=std::string::npos) &&
252 for(u_int32_t
jj=0;
jj<gduId.size();
jj++){
259 throw cms::Exception(
"Configuration") <<
"Module Type is Stereo or Lower but no partner detector found \n" 260 <<
"There is a problem on Tracker geometry configuration\n";
265 std::vector<const GeomDetUnit *> composed(2);
269 if(gduTypeName.find(
"Ster")!=std::string::npos){
277 }
else if (gduTypeName.find(
"Lower")!=std::string::npos){
const DetIdContainer & detUnitIds() const override
Returm a vector of all GeomDetUnit DetIds.
void addDet(GeomDet const *p)
void setEndsetDU(SubDetector sid)
const DetContainer & detUnits() const override
Returm a vector of all GeomDet.
PixelTopology * build(const Bounds *bounds, bool upgradeGeometry, int ROWS_PER_ROC, int COLS_PER_ROC, int BIG_PIX_PER_ROC_X, int BIG_PIX_PER_ROC_Y, int ROCS_X, int ROCS_Y)
void buildGeomDet(TrackerGeometry *)
TrackerGeometry * build(const GeometricDet *gd, const PTrackerParameters &ptp, const TrackerTopology *tTopo)
void buildPixel(std::vector< const GeometricDet * > const &, TrackerGeometry *, GeomDetType::SubDetector det, bool upgradeGeometry, int BIG_PIX_PER_ROC_X, int BIG_PIX_PER_ROC_Y)
ResultType plane(const std::vector< const GeomDetUnit * > &dets) const
DetId partnerDetId(const DetId &id) const
ConstGeometricDetContainer & components()
unsigned int endsetDU(SubDetector sid) const
void setOffsetDU(SubDetector sid)
std::map< std::string, const StripGeomDetType * > theStripDetTypeMap
void buildSilicon(std::vector< const GeometricDet * > const &, TrackerGeometry *, GeomDetType::SubDetector det, const std::string &part)
PlaneBuilderFromGeometricDet::ResultType buildPlaneWithMaterial(const GeometricDet *gd, double scaleFactor=1.) const
void addType(GeomDetType const *p)
unsigned int offsetDU(SubDetector sid) const
ResultType plane(const GeometricDet *gd) const
void addDetUnit(GeomDet const *p)
SubDetector subDetGeom[21]
std::map< std::string, const PixelGeomDetType * > thePixelDetTypeMap
std::vector< GeometricDet const * > ConstGeometricDetContainer
uint32_t stack(const DetId &id) const
void addDetUnitId(DetId p)
ConstGeometricDetContainer deepComponents() const
const TrackerTopology * theTopo
uint32_t glued(const DetId &id) const
StripTopology * build(const Bounds *, double, const std::string &)