52 log <<
"Known colum names:\n";
53 for (
auto e :
ids) log <<
"+++ column: " <<
e.first
62 assert(trackerTopologyHandle.
isValid());
64 std::vector<ID> geomquantities;
80 std::vector<std::pair<std::string, TTField>> namedPartitions {
93 for (
auto&
e : namedPartitions) {
94 geomquantities.push_back(
intern(
e.first));
105 auto diskid =
intern(
"PXDisk");
108 auto disk = pxdisk(iq);
110 auto endcap = pxendcap(iq);
111 return endcap == 1 ? -disk : disk;
116 uint32_t
id = iq.sourceModule.rawId();
127 bool isUpgrade = phase == 1;
132 assert(trackerGeometryHandle.
isValid());
135 auto detids = trackerGeometryHandle->
detIds();
136 for (
DetId id : detids) {
156 iq.row = 0; iq.col = 0;
158 iq.row = topo->
nrows()-1; iq.col = 0;
160 iq.row = 0; iq.col = topo->
ncolumns()-1;
178 auto coord = std::make_shared<SiPixelCoordinates>(phase);
202 case 1:
return Value(12);
203 case 2:
return Value(11);
204 case 3:
return Value(22);
205 case 4:
return Value(21);
215 case 1:
return Value(12);
216 case 2:
return Value(11);
217 case 3:
return Value(22);
218 case 4:
return Value(21);
227 return from_coord(coord->signed_ladder(iq.
sourceModule()));
232 return from_coord(coord->signed_module(iq.
sourceModule()));
237 return from_coord(coord->signed_blade(iq.
sourceModule()));
246 return from_coord(coord->signed_module_coord(iq.
sourceModule(),
247 std::make_pair(
int(iq.
row),
int(iq.
col))));
252 return from_coord(coord->signed_ladder_coord(iq.
sourceModule(),
253 std::make_pair(
int(iq.
row),
int(iq.
col))));
258 return from_coord(coord->signed_disk_coord(iq.
sourceModule(),
259 std::make_pair(
int(iq.
row),
int(iq.
col))));
264 return from_coord(coord->signed_disk_ring_coord(iq.
sourceModule(),
265 std::make_pair(
int(iq.
row),
int(iq.
col))));
271 return from_coord(coord->signed_blade_coord(
273 }
else if (phase == 1) {
274 return from_coord(coord->signed_blade_panel_coord(
284 return from_coord(coord->signed_blade_coord(
286 }
else if (phase == 1) {
287 return from_coord(coord->signed_shifted_blade_panel_coord(
296 return from_coord(coord->signed_blade_panel_coord(iq.
sourceModule(), std::make_pair(
int(iq.
row),
int(iq.
col))));
302 return from_coord(coord->signed_blade_panel_coord(iq.
sourceModule(), std::make_pair(
int(iq.
row),
int(iq.
col))));
310 std::make_pair(
int(iq.
row),
int(iq.
col))));
320 return from_coord(coord->channel(iq.
sourceModule(), std::make_pair(
int(iq.
row),
int(iq.
col))));
336 int onlineblock = iConfig.
getParameter<
int>(
"onlineblock");
337 int n_onlineblocks = iConfig.
getParameter<
int>(
"n_onlineblocks");
345 onlineblock, onlineblock+n_onlineblocks-1
378 std::shared_ptr<SiPixelFrameReverter> siPixelFrameReverter =
380 std::make_shared<SiPixelFrameReverter>(iSetup, theCablingMap.operator->());
424 if (val == 0) value =
"";
425 if (
name ==
"PXDisk" && val > 0)
426 value =
"_+" + std::to_string(
int(val));
428 std::map<int, std::string> shellname{
429 {11,
"_mI"}, {12,
"_mO"}, {21,
"_pI"}, {22,
"_pO"}};
430 if (
name ==
"HalfCylinder" ||
name ==
"Shell") value = shellname[
int(val)];
431 if (val ==
UNDEFINED) value =
"_UNDEFINED";
std::map< ID, Value > max_value
bool hasField(const DetId &id, DetIdFields idx) const
T getParameter(std::string const &) const
const TrackerGeomDet * idToDetUnit(DetId) const
Return the pointer to the GeomDetUnit corresponding to a given DetId.
virtual int nrows() const =0
std::map< std::pair< Column, Value >, std::string > format_value
std::map< std::string, ID > ids
std::string pretty(Column col)
void addExtractor(ID id, std::function< Value(InterestingQuantities const &iq)> func, Value min=UNDEFINED, Value max=UNDEFINED, Value binwidth=1)
std::string formatValue(Column, Value)
int bunchCrossing() const
edm::LuminosityBlockNumber_t luminosityBlock() const
global coordinates (row and column in DetUnit, as in PixelDigi)
uint32_t rawId() const
get the raw id
void loadFromTopology(edm::EventSetup const &iSetup, const edm::ParameterSet &iConfig)
void load(edm::EventSetup const &iSetup)
const edm::ParameterSet iConfig
std::vector< InterestingQuantities > all_modules
static const Value UNDEFINED
virtual std::string name() const
from base class
virtual const PixelTopology & specificTopology() const
Returns a reference to the pixel proxy topology.
unsigned int getField(const DetId &id, DetIdFields idx) const
void loadFEDCabling(edm::EventSetup const &iSetup, const edm::ParameterSet &iConfig)
virtual std::string name() const
from base class
virtual int ncolumns() const =0
const DetIdContainer & detIds() const
Returm a vector of all GeomDet DetIds (including those of GeomDetUnits)
void loadModuleLevel(edm::EventSetup const &iSetup, const edm::ParameterSet &iConfig)
std::vector< std::function< Value(InterestingQuantities const &iq)> > extractors
const edm::Event * sourceEvent
std::map< ID, Value > min_value
ID intern(std::string const &id)
T mod(const T &a, const T &b)
void loadTimebased(edm::EventSetup const &iSetup, const edm::ParameterSet &iConfig)
void loadFromSiPixelCoordinates(edm::EventSetup const &iSetup, const edm::ParameterSet &iConfig)