38 debug =
pset.getUntrackedParameter<
bool>(
"debug",
false);
45 cout <<
"[DTTPDeadWriter]Constructor called!" << endl;
51 cout <<
"[DTTPDeadWriter]Destructor called!" << endl;
64 set<DTLayerId> analyzedLayers;
81 if (analyzedLayers.find(layerId) == analyzedLayers.end()) {
82 analyzedLayers.insert(layerId);
91 for (
int wire = firstWire; wire <= nWires; wire++) {
100 cout <<
"Wire id " << wireId <<
" is TP dead" << endl;
110 cout <<
"[DTTPDeadWriter]Writing ttrig object to DB!" << endl;
113 string deadRecord =
"DTDeadFlagRcd";
void beginRun(const edm::Run &, const edm::EventSetup &setup) override
Read t0 map from event.
static void writeToDB(std::string record, const T &payload)
const_iterator end() const
~DTTPDeadWriter() override
Destructor.
std::vector< DTT0Data >::const_iterator const_iterator
Access methods to data.
const_iterator begin() const
int firstChannel() const
Returns the wire number of the first wire.
void analyze(const edm::Event &event, const edm::EventSetup &eventSetup) override
Compute the ttrig by fiting the TB rising edge.
const DTTopology & specificTopology() const
DTTPDeadWriter(const edm::ParameterSet &pset)
Constructor.
int setCellDead_TP(int wheelId, int stationId, int sectorId, int slId, int layerId, int cellId, bool flag)
uint8_t channelId(const VFATFrame &frame)
retrieve this channel identifier
int get(int wheelId, int stationId, int sectorId, int slId, int layerId, int cellId, float &t0mean, float &t0rms, DTTimeUnits::type unit) const
edm::ESHandle< DTGeometry > muonGeom
edm::ESGetToken< DTT0, DTT0Rcd > t0Token_
static const double tzero[3]
const edm::ESGetToken< DTGeometry, MuonGeometryRecord > dtGeomToken_
void endJob() override
Write ttrig in the DB.
int channels() const
Returns the number of wires in the layer.
const DTLayer * layer(const DTLayerId &id) const
Return a layer given its id.