66 bool usePhase2_ =
false;
73 int stripQualityFlags = 0;
74 int stripQualityDebugFlags = 0;
76 if (pset.
getParameter<
bool>(
"UseStripModuleQualityDB")) {
82 if (pset.
getParameter<
bool>(
"UseStripAPVFiberQualityDB")) {
97 return std::make_pair(stripQualityFlags, stripQualityDebugFlags);
101 int pixelQualityFlags = 0;
102 int pixelQualityDebugFlags = 0;
104 if (pset.
getParameter<
bool>(
"UsePixelModuleQualityDB")) {
117 return std::make_pair(pixelQualityFlags, pixelQualityDebugFlags);
124 auto c = setWhatProduced(
this, myname);
126 std::tie(pixelQualityFlags_, pixelQualityDebugFlags_) = pixelFlags(p);
127 if (pixelQualityFlags_ != 0) {
129 pixelCablingToken_ = c.consumes();
132 std::tie(stripQualityFlags_, stripQualityDebugFlags_) = stripFlags(p);
133 if (stripQualityFlags_ != 0) {
142 badStripCuts_.tib = makeBadStripCuts(cutPset.getParameter<
edm::ParameterSet>(
"TIB"));
143 badStripCuts_.tob = makeBadStripCuts(cutPset.getParameter<
edm::ParameterSet>(
"TOB"));
144 badStripCuts_.tid = makeBadStripCuts(cutPset.getParameter<
edm::ParameterSet>(
"TID"));
145 badStripCuts_.tec = makeBadStripCuts(cutPset.getParameter<
edm::ParameterSet>(
"TEC"));
152 trackerGeomToken_ = c.consumes();
153 geometricSearchTrackerToken_ = c.consumes();
172 if (pixelQualityFlags_ != 0) {
174 ptr_pixelCabling = &iRecord.
get(pixelCablingToken_);
179 if (stripQualityFlags_ != 0) {
180 ptr_stripQuality = &iRecord.
get(stripQualityToken_);
186 ptr_phase2TrackerCPE = &iRecord.
get(phase2TrackerCPEToken_);
188 ptr_SiStripTrackerCPE = &iRecord.
get(stripCPEToken_);
190 return std::make_unique<MeasurementTrackerImpl>(badStripCuts_,
191 &iRecord.
get(pixelCPEToken_),
192 ptr_SiStripTrackerCPE,
193 &iRecord.
get(hitMatcherToken_),
195 &iRecord.
get(trackerGeomToken_),
196 &iRecord.
get(geometricSearchTrackerToken_),
199 stripQualityDebugFlags_,
203 pixelQualityDebugFlags_,
204 ptr_phase2TrackerCPE);
216 desc.
add<
std::string>(
"Phase2StripCPE",
"")->setComment(
"empty string used to turn off Phase 2");
219 desc.
add<
bool>(
"UseStripModuleQualityDB",
true);
220 desc.
addUntracked<
bool>(
"DebugStripModuleQualityDB",
false)->setComment(
"Dump out info on module status");
221 desc.
add<
bool>(
"UseStripAPVFiberQualityDB",
true)->setComment(
"Read APV and Fiber status from SiStripQuality");
222 desc.
addUntracked<
bool>(
"DebugStripAPVFiberQualityDB",
false)->setComment(
"Dump out info on module status");
223 desc.
add<
bool>(
"MaskBadAPVFibers",
true)
225 "if set to true, clusters with barycenter on bad APV and Fibers are ignored. (UseStripAPVFiberQualityDB must "
226 "also be true for this to work)");
228 desc.
add<
bool>(
"UseStripStripQualityDB",
true)->setComment(
"read Strip status from SiStripQuality");
229 desc.
addUntracked<
bool>(
"DebugStripStripQualityDB",
false)->setComment(
"dump out info on module status");
234 badStripCutsDesc.
add<uint32_t>(
"maxBad", 4);
235 badStripCutsDesc.
add<uint32_t>(
"maxConsecutiveBad", 2);
246 desc.
add<
bool>(
"UsePixelModuleQualityDB",
true)->setComment(
"Use DB info at the module level (that is, detid level)");
247 desc.
addUntracked<
bool>(
"DebugPixelModuleQualityDB",
false)->setComment(
"dump out info on module status");
248 desc.
add<
bool>(
"UsePixelROCQualityDB",
true)->setComment(
"Use DB info at the ROC level");
249 desc.
addUntracked<
bool>(
"DebugPixelROCQualityDB",
false)->setComment(
"dump out info om module status ");
251 descriptions.
add(
"_MeasurementTrackerESProducer_default", desc);
edm::ESGetToken< StripClusterParameterEstimator, TkStripCPERecord > stripCPEToken_
T getUntrackedParameter(std::string const &, T const &) const
int pixelQualityDebugFlags_
const edm::EventSetup & c
ParameterDescriptionBase * addOptional(U const &iLabel, T const &value)
tuple MeasurementTrackerESProducer
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
~MeasurementTrackerESProducer() override
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > trackerGeomToken_
edm::ESGetToken< SiPixelFedCablingMap, SiPixelFedCablingMapRcd > pixelCablingToken_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
edm::ESGetToken< GeometricSearchTracker, TrackerRecoGeometryRecord > geometricSearchTrackerToken_
edm::ESGetToken< SiStripQuality, SiStripQualityRcd > stripQualityToken_
edm::ESGetToken< SiStripRecHitMatcher, TkStripCPERecord > hitMatcherToken_
ParameterDescriptionBase * add(U const &iLabel, T const &value)
std::unique_ptr< MeasurementTracker > produce(const CkfComponentsRecord &)
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerTopologyToken_
pixelQualityToken_(iC.esConsumes())
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
T getParameter(std::string const &) const
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
trackerTopologyToken_(iC.esConsumes())
MeasurementTrackerImpl::BadStripCutsDet badStripCuts_
edm::ESGetToken< ClusterParameterEstimator< Phase2TrackerCluster1D >, TkPhase2OTCPERecord > phase2TrackerCPEToken_
edm::ESGetToken< SiPixelQuality, SiPixelQualityRcd > pixelQualityToken_
edm::ESGetToken< PixelClusterParameterEstimator, TkPixelCPERecord > pixelCPEToken_
MeasurementTrackerESProducer(const edm::ParameterSet &p)
int stripQualityDebugFlags_