CMS 3D CMS Logo

MTDPixelTopologyBuilder.cc
Go to the documentation of this file.
1 //#define EDM_ML_DEBUG
2 
3 // Make the change for "big" pixels. 3/06 d.k.
7 
9 
11 
13  int pixelROCRows, // Num of Rows per ROC
14  int pixelROCCols, // Num of Cols per ROC
15  int pixelROCsInX,
16  int pixelROCsInY,
17  int GAPxInterpad,
18  int GAPxBorder,
19  int GAPyInterpad,
20  int GAPyBorder) {
21  float width = bs->width(); // module width = Xsize
22  float length = bs->length(); // module length = Ysize
23 
24  // Number of pixel rows (x) and columns (y) per module
25  int nrows = pixelROCRows * pixelROCsInX;
26  int ncols = pixelROCCols * pixelROCsInY;
27 
28  float pitchX = width / nrows;
29  float pitchY = length / ncols;
30 
31  float micronsTocm = 1e-4;
32  float gapxinterpad = float(GAPxInterpad) * micronsTocm; //Convert to cm
33  float gapyinterpad = float(GAPyInterpad) * micronsTocm; //Convert to cm
34  float gapxborder = float(GAPxBorder) * micronsTocm; //Convert to cm
35  float gapyborder = float(GAPyBorder) * micronsTocm; //Convert to cm
36 
37 #ifdef EDM_ML_DEBUG
38  edm::LogInfo("MTDPixelTopologyBuilder")
39  << std::fixed << "Building topology for module of width(X) = " << std::setw(10) << width
40  << " length(Y) = " << std::setw(10) << length << "\n Rows per ROC = " << std::setw(10) << pixelROCRows
41  << " Cols per ROC = " << std::setw(10) << pixelROCCols << "\n ROCs in X = " << std::setw(10)
42  << pixelROCsInX << " ROCs in Y = " << std::setw(10) << pixelROCsInY
43  << "\n # pixel rows X = " << std::setw(10) << nrows << " # pixel cols Y = " << std::setw(10) << ncols
44  << "\n pitch in X = " << std::setw(10) << pitchX << " # pitch in Y = " << std::setw(10) << pitchY
45  << "\n Interpad gap in X = " << std::setw(10) << gapxinterpad << " # Interpad gap in Y = " << std::setw(10)
46  << gapyinterpad << "\n Border gap in X = " << std::setw(10) << gapxborder
47  << " # Border gap in Y = " << std::setw(10) << gapyborder;
48 #endif
49 
50  return (new RectangularMTDTopology(nrows,
51  ncols,
52  pitchX,
53  pitchY,
54  pixelROCRows, // (int)rocRow
55  pixelROCCols, // (int)rocCol
56  pixelROCsInX,
57  pixelROCsInY,
58  gapxinterpad,
59  gapxborder,
60  gapyinterpad,
61  gapyborder));
62 }
PixelTopology * build(const Bounds *bounds, int ROWS_PER_ROC, int COLS_PER_ROC, int ROCS_X, int ROCS_Y, int GAPxInterpad, int GAPxBorder, int GAPyInterpad, int GAPyBorder)
Log< level::Info, false > LogInfo
Definition: Bounds.h:18