1 #ifndef TkStripMeasurementDet_H 2 #define TkStripMeasurementDet_H 40 : mdet(&imdet), tsos(&itsos),
data(&idata) {}
47 : mdet(&imdet), tsos(&itsos),
data(&idata), clusterI(ci), clusterE(ce) {}
57 inline void advance();
60 bool empty()
const {
return clusterI == clusterE; }
96 int index()
const {
return index_; }
98 unsigned int rawId()
const {
return conditionSet().id(
index()); }
99 unsigned char subId()
const {
return conditionSet().subId(
index()); }
123 std::vector<SiStripRecHit2D>&
result)
const;
127 std::vector<SiStripRecHit2D>&
result)
const;
140 std::vector<float>& diffs)
const override;
145 TempMeasurements&
result)
const override;
149 template <
class ClusterRefT>
152 LocalValues lv = cpe()->localParameters(*cluster, gdu, ltp);
153 return std::make_shared<SiStripRecHit2D>(lv.first, lv.second,
fastGeomDet(), cluster);
156 template <
class ClusterRefT>
162 VLocalValues vlv = cpe()->localParametersV(*cluster, gdu, ltp);
163 for (VLocalValues::const_iterator it = vlv.begin(); it != vlv.end(); ++it)
164 res.push_back(std::make_shared<SiStripRecHit2D>(it->first, it->second, fastGeomDet(), cluster));
167 template <
class ClusterRefT>
174 std::vector<float>& diffs)
const {
175 if (isMasked(*cluster))
181 auto const& vl = cpe()->localParameters(*cluster, cpepar);
187 LogDebug(
"TkStripMeasurementDet") <<
" chi2=" << diffEst.second;
189 result.push_back(std::make_shared<SiStripRecHit2D>(
recHit));
190 diffs.push_back(diffEst.second);
192 return diffEst.first;
195 template <
class ClusterRefT>
201 std::vector<SiStripRecHit2D>&
result)
const {
202 if (isMasked(*cluster))
208 auto const& vl = cpe()->localParameters(*cluster, cpepar);
209 result.emplace_back(vl.first, vl.second, fastGeomDet(), cluster);
210 std::pair<bool, double> diffEst = est.
estimate(ltp,
result.back());
211 LogDebug(
"TkStripMeasurementDet") <<
" chi2=" << diffEst.second;
214 return diffEst.first;
235 bool testStrips(
float utraj,
float uerr)
const;
240 std::vector<BadStripBlock>
const&
badStripBlocks()
const {
return conditionSet().badStripBlocks(
index()); }
267 std::vector<SiStripRecHit2D>&
res)
const {
271 res.reserve(alv.size());
287 <<
"\n This must be a new cluster, and therefore should not be skiped most likely.";
std::pair< LocalPoint, LocalError > LocalValues
StMeasurementConditionSet::BadStripCuts BadStripCuts
~TkStripMeasurementDet() override
auto const good
min quality of good
new_const_iterator clusterE
bool isActive(const MeasurementTrackerEvent &data) const override
Is this module active in reconstruction? It must be both 'setActiveThisEvent' and 'setActive'...
edm::Ref< typename HandleT::element_type, typename HandleT::element_type::value_type::value_type > makeRefTo(HandleT const &handle, const_iterator ci) const
BadStripCuts const & badStripCuts() const
const StripGeomDetUnit & specificGeomDet() const
unsigned char subId() const
edmNew::DetSet< SiStripCluster > detset
unsigned int rawId() const
const detset & theSet(const StMeasurementDetSet &theDets) const
StripClusterParameterEstimator::VLocalValues VLocalValues
bool operator==(TkStripRecHitIter const &rh)
StripClusterParameterEstimator::LocalValues LocalValues
void buildSimpleRecHits(AClusters const &clusters, const MeasurementTrackerEvent &data, const detset &detSet, const TrajectoryStateOnSurface <p, std::vector< SiStripRecHit2D > &res) const
const StripCPE * cpe() const
virtual bool preFilter(const TrajectoryStateOnSurface &, OpaquePayload const &) const
TkStripRecHitIter(const TkStripMeasurementDet &imdet, const TrajectoryStateOnSurface &itsos, const MeasurementTrackerEvent &idata)
const LocalTrajectoryParameters & localParameters() const
data_type const * const_iterator
bool isEmpty(const StMeasurementDetSet &theDets) const
bool accept(const edm::Event &event, const edm::TriggerResults &triggerTable, const std::string &triggerPath)
void buildRecHits(const ClusterRefT &cluster, const TrajectoryStateOnSurface <p, const RecHitContainer &_res) const
std::vector< BadStripBlock > const & badStripBlocks() const
SiStripRecHit2D buildHit() const
bool accept(SiStripClusterRef const &r, const std::vector< bool > &skipClusters) const
StMeasurementConditionSet & conditionSet()
const StripDetset & detSet(int i) const
bool hasAllGoodChannels() const
does this module have at least one bad strip, APV or channel?
void setActiveThisEvent(int i, bool active)
Turn on/off the module for reconstruction for one events. This per-event flag is cleared by any call ...
bool hasAny128StripBad() const
void advance(TkStripRecHitIter &hi) const
const StMeasurementConditionSet & conditionSet() const
std::vector< LocalValues > VLocalValues
virtual HitReturnType estimate(const TrajectoryStateOnSurface &ts, const TrackingRecHit &hit) const =0
DynArray< LocalValues > ALocalValues
TkStripRecHitIter(new_const_iterator ci, new_const_iterator ce, const TkStripMeasurementDet &imdet, const TrajectoryStateOnSurface &itsos, const MeasurementTrackerEvent &idata)
bool accept(unsigned int key, const std::vector< bool > &skipClusters) const
StMeasurementConditionSet::BadStripBlock BadStripBlock
std::vector< SiStripCluster >::const_iterator const_iterator
bool hasBadComponents(const TrajectoryStateOnSurface &tsos, const MeasurementTrackerEvent &data) const override
bool filteredRecHits(const ClusterRefT &cluster, StripCPE::AlgoParam const &cpepar, const TrajectoryStateOnSurface <p, const MeasurementEstimator &est, const std::vector< bool > &skipClusters, RecHitContainer &result, std::vector< float > &diffs) const
std::shared_ptr< TrackingRecHit const > RecHitPointer
const TkStripMeasurementDet * mdet
virtual RecHitContainer recHits(const TrajectoryStateOnSurface &, const MeasurementTrackerEvent &) const =0
std::vector< BadStripBlock > & getBadStripBlocks()
bool operator<(TkStripRecHitIter const &rh)
void set128StripStatus(bool good, int idx=-1)
Sets the status of a block of 128 strips (or all blocks if idx=-1)
bool maskBad128StripBlocks() const
bool isMasked(const SiStripCluster &cluster) const
TkStripRecHitIter & operator++()
TrackingRecHit::RecHitPointer buildRecHit(const ClusterRefT &cluster, const TrajectoryStateOnSurface <p) const
const detset & detSet(const StMeasurementDetSet &theDets) const
const GeomDet & fastGeomDet() const
void setEmpty(StMeasurementDetSet &theDets) const
void setActiveThisPeriod(StMeasurementDetSet &theDets, bool active)
Turn on/off the module for reconstruction, for the full run or lumi (using info from DB...
new_const_iterator clusterI
DynArray< SiStripCluster const * > AClusters
SiStripRecHit2D operator*() const
TrackingRecHit::ConstRecHitContainer RecHitContainer
SiStripRecHit2D::ClusterRef SiStripClusterRef
char data[epos_bytes_allocation]
bool filteredRecHits(const ClusterRefT &cluster, StripCPE::AlgoParam const &cpepar, const TrajectoryStateOnSurface <p, const MeasurementEstimator &est, const std::vector< bool > &skipClusters, std::vector< SiStripRecHit2D > &result) const
detset::const_iterator new_const_iterator
SiStripRecHit2D hit(TkStripRecHitIter const &hi) const
#define declareDynArray(T, n, x)
detset::const_iterator new_const_iterator
StMeasurementConditionSet * theDetConditions
void setActiveThisEvent(StMeasurementDetSet &theDets, bool active) const
Turn on/off the module for reconstruction for one events. This per-event flag is cleared by any call ...
bool operator!=(TkStripRecHitIter const &rh)
virtual bool measurements(const TrajectoryStateOnSurface &stateOnThisDet, const MeasurementEstimator &est, const MeasurementTrackerEvent &data, TempMeasurements &result) const =0