97 std::unordered_map<unsigned int, PotPlots>
potPlots_;
125 1. / DISPLAY_RESOLUTION_FOR_HITS_MM;
142 hitDistribution2d = ibooker.
book2D(
"hits in planes",
143 title +
" hits in planes;plane number;x (mm)",
151 recHitTime = ibooker.
book1D(
"recHit time", title +
" time in the recHits; t (ns)", 500, -25, 25);
170 recHitTime = ibooker.
book1D(
"recHit Time", title +
" recHit Time; t (ns)", 500, -25, 25);
181 verbosity_(ps.getUntrackedParameter<unsigned int>(
"verbosity", 0)),
193 for (
auto it =
geom.beginSensor(); it !=
geom.endSensor(); it++) {
202 edm::LogProblem(
"DiamondSampicCalibrationDQMSource") <<
"ERROR: no descriptor for detId";
216 for (
auto it =
geom.beginSensor(); it !=
geom.endSensor(); ++it) {
244 std::unordered_map<uint32_t, uint32_t> detIdToHw;
246 for (
const auto &digis : *timingDigi) {
248 for (
const auto &digi : digis)
249 detIdToHw[detId] = digi.hardwareId();
253 std::set<uint8_t> boardSet;
254 std::unordered_map<unsigned int, unsigned int> channelsPerPlane;
255 std::unordered_map<unsigned int, unsigned int> channelsPerPlaneWithTime;
259 for (
const auto &
rechits : *timingRecHits) {
263 detId_pot.setChannel(0);
267 for (
const auto &rechit :
rechits) {
269 float UFSDShift = 0.0;
270 if (rechit.yWidth() < 3)
273 TH2F *hitHistoTmp =
potPlots_[detId_pot].hitDistribution2d->getTH2F();
274 TAxis *hitHistoTmpYAxis = hitHistoTmp->GetYaxis();
278 for (
int i = 0;
i < numOfBins; ++
i)
279 potPlots_[detId_pot].hitDistribution2d->Fill(detId.plane() + UFSDShift,
280 hitHistoTmpYAxis->GetBinCenter(startBin +
i));
284 int db = (detIdToHw[detId] & 0xE0) >> 5;
285 int sampic = (detIdToHw[detId] & 0x10) >> 4;
286 int channel = (detIdToHw[detId] & 0x0F);
virtual void setCurrentFolder(std::string const &fullpath)
const Translation & translation() const
MonitorElement * hitDistribution2d
void setPlane(uint32_t channel)
#define DEFINE_FWK_MODULE(type)
plots related to one Diamond channel
plots related to one Diamond plane
void setChannel(uint32_t channel)
void channelName(std::string &name, NameFlag flag=nFull) const
const DiamondDimensions & getDiamondDimensions() const
static const double DISPLAY_RESOLUTION_FOR_HITS_MM
edm::EDGetTokenT< edm::DetSetVector< TotemTimingDigi > > totemTimingDigiToken_
edm::EDGetTokenT< edm::DetSetVector< TotemTimingRecHit > > tokenRecHit_
double timeOffset(int key1, int key2, int key3, int key4=-1) const
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
void dqmBeginRun(const edm::Run &, const edm::EventSetup &) override
bool getData(T &iHolder) const
std::unordered_map< unsigned int, double > horizontalShiftOfDiamond_
DiamondSampicCalibrationDQMSource(const edm::ParameterSet &)
edm::TimeValue_t timeOfPreviousEvent_
static const double INV_DISPLAY_RESOLUTION_FOR_HITS_MM
void rpName(std::string &name, NameFlag flag=nFull) const
MonitorElement * recHitTime
unsigned long long TimeValue_t
std::unordered_map< unsigned int, PlanePlots > planePlots_
static bool check(unsigned int raw)
returns true if the raw ID is a PPS-timing one
std::unordered_map< unsigned int, PotPlots > potPlots_
void bookHistograms(DQMStore::IBooker &, const edm::Run &, const edm::EventSetup &) override
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecord > geomEsToken_
~DiamondSampicCalibrationDQMSource() override
MonitorElement * book2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, FUNC onbooking=NOOP())
edm::ESHandle< PPSTimingCalibration > hTimingCalib_
void planeName(std::string &name, NameFlag flag=nFull) const
MonitorElement * recHitTime
plots related to one Diamond detector package
std::unordered_map< unsigned int, ChannelPlots > channelPlots_
edm::ESGetToken< PPSTimingCalibration, PPSTimingCalibrationRcd > timingCalibrationToken_
Detector ID class for CTPPS Timing Diamond detectors. Bits [19:31] : Assigend in CTPPSDetId Calss Bit...
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
plots related to the whole system
void analyze(const edm::Event &, const edm::EventSetup &) override
Log< level::Error, true > LogProblem