28 void addInvalidMeas( std::vector<TrajectoryMeasurement>&
result,
43 std::vector<TrajectoryMeasurement>
47 std::vector<DetWithState>
const& compatDets,
51 std::vector<TrajectoryMeasurement>
result;
56 for (
auto const & ds : compatDets) {
63 for (std::size_t
i=0;
i!=tmps.
size(); ++
i)
71 if ( result.size() > 1) {
76 if ( !result.empty()) {
78 addInvalidMeas( result, result.front().predictedState(), result.front().recHit()->det(),layer);
82 addInvalidMeas( result, compatDets.front().second, compatDets.front().first,layer);
98 auto const & compatDets = layer.
compatibleDets( startingState, prop, est);
99 if (compatDets.empty())
return false;
101 for (
auto const & ds : compatDets) {
102 auto mdet = theDetSystem->idToDet(ds.first->geographicalId(), *theData);
103 ret |=mdet.
recHits(result,ds.second,est);
109 vector<TrajectoryMeasurement>
117 vector<DetWithState>
const & compatDets = layer.
compatibleDets( startingState, prop, est);
119 if (!compatDets.empty())
return get(theDetSystem, theData, layer, compatDets, startingState, prop, est);
121 vector<TrajectoryMeasurement>
result;
122 pair<bool, TrajectoryStateOnSurface> compat = layer.
compatible( startingState, prop, est);
128 LogDebug(
"LayerMeasurements")<<
"adding a missing hit.";
129 }
else LogDebug(
"LayerMeasurements")<<
"adding not measurement.";
137 vector<TrajectoryMeasurementGroup>
142 vector<TrajectoryMeasurementGroup>
result;
145 result.reserve(groups.size());
148 for (
auto& grp : groups) {
149 if ( grp.empty() )
continue;
151 vector<TrajectoryMeasurement> tmpVec;
152 for (
auto const & det : grp) {
157 if (mdet.
measurements( det.trajectoryState(), est,tmps))
158 for (std::size_t
i=0;
i!=tmps.
size(); ++
i)
165 addInvalidMeas( tmpVec, grp,layer);
171 if (result.empty()) {
172 pair<bool, TrajectoryStateOnSurface> compat = layer.
compatible( startingState, prop, est);
174 vector<TrajectoryMeasurement> tmVec;
186 if (!measVec.empty()) {
188 measVec.emplace_back(measVec.front().predictedState(),
192 else if (!group.empty()) {
194 measVec.emplace_back(group.front().trajectoryState(),
virtual std::pair< bool, TrajectoryStateOnSurface > compatible(const TrajectoryStateOnSurface &ts, const Propagator &, const MeasurementEstimator &) const =0
std::vector< TrajectoryMeasurement > measurements(const DetLayer &layer, const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
virtual const BoundSurface & surface() const =0
The surface of the GeometricSearchDet.
virtual std::vector< DetGroup > groupedCompatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
std::vector< BaseTrackerRecHit * > SimpleHitContainer
virtual std::vector< DetWithState > compatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
bool recHits(SimpleHitContainer &result, const DetLayer &layer, const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
RecHitContainer recHits(const TrajectoryStateOnSurface &tsos) const
DetId geographicalId() const
The label of this GeomDet.
std::pair< const GeomDet *, TrajectoryStateOnSurface > DetWithState
void addInvalidMeas(std::vector< TrajectoryMeasurement > &measVec, const DetGroup &group, const DetLayer &layer) const
tuple MeasurementTrackerEvent
std::vector< TrajectoryMeasurementGroup > groupedMeasurements(const DetLayer &layer, const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
std::pair< const GeomDet *, TrajectoryStateOnSurface > DetWithState
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
bool measurements(const TrajectoryStateOnSurface &stateOnThisDet, const MeasurementEstimator &est, TempMeasurements &result) const