23 : theMTDRecHits(), theMTDEventCacheID(0), theEvent(nullptr) {
38 LogDebug(
"Track|RecoMTD|MTDDetLayerMeasurements") <<
"(MTD): " << static_cast<MTDDetId>(detId) << std::endl;
42 auto detset = (*theMTDRecHits)[detId];
44 for (
const auto& rechit : detset)
51 LogDebug(
"Track|RecoMTD|MTDDetLayerMeasurements") <<
"Checking MTD RecHits";
62 throw cms::Exception(
"MTDDetLayerMeasurements") <<
"Cannot get MTD RecHits";
63 LogDebug(
"Track|RecoMTD|MTDDetLayerMeasurements") <<
"Cannot get MTD RecHits";
83 std::vector<DetWithState> dss =
layer->compatibleDets(startingState, prop, est);
84 LogDebug(
"RecoMTD") <<
"compatibleDets: " << dss.size() << std::endl;
86 for (
const auto& dws : dss) {
88 result.insert(
result.end(), detMeasurements.begin(), detMeasurements.end());
110 LogDebug(
"RecoMTD") <<
"Dimension: " << (*rechit)->dimension() <<
" Chi2: " << estimate.second << std::endl;
111 if (estimate.first) {
132 if (estimate.first) {
169 std::vector<TrajectoryMeasurementGroup>
result;
172 std::vector<DetGroup> groups(
layer->groupedCompatibleDets(startingState, prop, est));
174 for (
const auto& grp : groups) {
175 std::vector<TrajectoryMeasurement> groupMeasurements;
176 for (
const auto& detAndStateItr : grp) {
177 std::vector<TrajectoryMeasurement> detMeasurements =
179 groupMeasurements.insert(groupMeasurements.end(), detMeasurements.begin(), detMeasurements.end());
182 if (!groupMeasurements.empty())
196 throw cms::Exception(
"MTDDetLayerMeasurements") <<
"The event has not been set";
202 std::vector<const GeomDet*> gds =
layer->basicComponents();
204 for (
const GeomDet* igd : gds) {
206 rhs.insert(rhs.end(), detHits.begin(), detHits.end());