CMS 3D CMS Logo

List of all members | Classes | Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
CTPPSDiamondDQMSource Class Reference
Inheritance diagram for CTPPSDiamondDQMSource:
DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > > edm::one::EDProducer< edm::EndRunProducer, edm::one::WatchRuns, edm::Accumulator, Args... > edm::one::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Classes

struct  ChannelPlots
 plots related to one Diamond channel More...
 
struct  DiamondShifts
 
struct  GlobalPlots
 plots related to the whole system More...
 
struct  PlanePlots
 plots related to one Diamond plane More...
 
struct  PotPlots
 plots related to one Diamond detector package More...
 
struct  SectorPlots
 plots related to one sector More...
 

Public Member Functions

 CTPPSDiamondDQMSource (const edm::ParameterSet &)
 
- Public Member Functions inherited from DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > >
void accumulate (edm::Event const &event, edm::EventSetup const &setup) override
 
void beginRun (edm::Run const &run, edm::EventSetup const &setup) final
 
 DQMOneEDAnalyzer ()
 
void endRun (edm::Run const &, edm::EventSetup const &) final
 
void endRunProduce (edm::Run &run, edm::EventSetup const &setup) final
 
virtual bool getCanSaveByLumi ()
 
- Public Member Functions inherited from edm::one::EDProducer< edm::EndRunProducer, edm::one::WatchRuns, edm::Accumulator, Args... >
 EDProducer ()=default
 
 EDProducer (const EDProducer &)=delete
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 
const EDProduceroperator= (const EDProducer &)=delete
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
bool wantsInputProcessBlocks () const final
 
bool wantsProcessBlocks () const final
 
- Public Member Functions inherited from edm::one::EDProducerBase
 EDProducerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const
 
bool wantsStreamRuns () const
 
 ~EDProducerBase () override
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector< edm::ProductResolverIndex > const & putTokenIndexToProductResolverIndex () const
 
std::vector< bool > const & recordProvenanceList () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription const &)> registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
TypeLabelList const & typeLabelList () const
 used by the fwk to register the list of products of this module More...
 
 ~ProducerBase () noexcept(false) override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::array< std::vector< ModuleDescription const *> *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const *> const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Protected Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void bookHistograms (DQMStore::IBooker &, const edm::Run &, const edm::EventSetup &) override
 
void dqmBeginRun (const edm::Run &, const edm::EventSetup &) override
 
void dqmEndRun (edm::Run const &, edm::EventSetup const &) override
 
std::shared_ptr< dds::CacheglobalBeginLuminosityBlock (const edm::LuminosityBlock &, const edm::EventSetup &) const override
 
void globalEndLuminosityBlock (const edm::LuminosityBlock &, const edm::EventSetup &) override
 
- Protected Member Functions inherited from edm::ProducerBase
template<Transition Tr = Transition::Event>
auto produces (std::string instanceName) noexcept
 declare what type of product will make and with which optional label More...
 
template<Transition B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<BranchType B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<class ProductType >
BranchAliasSetterT< ProductType > produces ()
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces ()
 
template<class ProductType >
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces ()
 
template<Transition Tr = Transition::Event>
auto produces () noexcept
 
ProducesCollector producesCollector ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< Bconsumes (edm::InputTag tag) noexcept
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes ()
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag)
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
void resetItemsToGetFrom (BranchType iType)
 

Private Member Functions

void checkEventNumber (const CTPPSDiamondDetId &, const TotemFEDInfo &, const TotemVFATStatus &, PotPlots &, int &) const
 

Private Attributes

int centralOOT_
 
std::unordered_map< unsigned int, ChannelPlotschannelPlots_
 
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecordctppsGeometryEventToken_
 
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecordctppsGeometryRunToken_
 
std::unordered_map< CTPPSDetId, DiamondShiftsdiamShifts_
 
int EC_difference_45_
 
int EC_difference_56_
 
bool excludeMultipleHits_
 
const bool extract_digi_info_
 
GlobalPlots globalPlot_
 
bool perLSsaving_
 
std::unordered_map< unsigned int, PlanePlotsplanePlots_
 
const bool plotOffline_
 
const bool plotOnline_
 
std::unordered_map< unsigned int, PotPlotspotPlots_
 
std::vector< std::pair< edm::EventRange, int > > runParameters_
 
std::unordered_map< unsigned int, SectorPlotssectorPlots_
 
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondRecHit > > tokenDiamondHit_
 
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondLocalTrack > > tokenDiamondTrack_
 
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondDigi > > tokenDigi_
 
edm::EDGetTokenT< std::vector< TotemFEDInfo > > tokenFEDInfo_
 
edm::EDGetTokenT< edm::DetSetVector< CTPPSPixelLocalTrack > > tokenPixelTrack_
 
edm::EDGetTokenT< edm::DetSetVector< TotemVFATStatus > > tokenStatus_
 
unsigned int trackCorrelationThreshold_
 
unsigned int verbosity_
 
unsigned int windowsNum_
 

Static Private Attributes

static constexpr unsigned short CHANNEL_OF_VFAT_CLOCK = 30
 Channel ID of the VFAT that contains clock data. More...
 
static constexpr unsigned short CTPPS_DIAMOND_NUM_OF_CHANNELS = 12
 
static constexpr unsigned short CTPPS_FAR_RP_ID = 3
 
static constexpr unsigned short CTPPS_FED_ID_45 = 583
 
static constexpr unsigned short CTPPS_FED_ID_56 = 582
 
static constexpr unsigned short CTPPS_PIXEL_STATION_ID = 2
 
static constexpr double DISPLAY_RESOLUTION_FOR_HITS_MM = 0.1
 Bin width of histograms showing hits and tracks (in mm) More...
 
static constexpr unsigned int FIRST_RUN_W_PIXELS = 300000
 Number of OOT indices monitored. More...
 
static constexpr unsigned short HPTDC_0_CHANNEL = 6
 
static constexpr unsigned short HPTDC_1_CHANNEL = 7
 
static constexpr double HPTDC_BIN_WIDTH_NS = 25. / 1024
 ns per HPTDC bin More...
 
static constexpr double INV_DISPLAY_RESOLUTION_FOR_HITS_MM = 1. / DISPLAY_RESOLUTION_FOR_HITS_MM
 
static constexpr double SEC_PER_LUMI_SECTION = 23.31
 Number of seconds per lumisection: used to compute hit rates in Hz. More...
 

Additional Inherited Members

- Public Types inherited from DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > >
typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::one::EDProducerBase
typedef EDProducerBase ModuleType
 
- Public Types inherited from edm::ProducerBase
template<typename T >
using BranchAliasSetterT = ProductRegistryHelper::BranchAliasSetterT< T >
 
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex > >
 
typedef ProductRegistryHelper::TypeLabelList TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::one::EDProducerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Attributes inherited from DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > >
edm::EDPutTokenT< DQMTokenrunToken_
 

Detailed Description

Definition at line 72 of file CTPPSDiamondDQMSource.cc.

Constructor & Destructor Documentation

◆ CTPPSDiamondDQMSource()

CTPPSDiamondDQMSource::CTPPSDiamondDQMSource ( const edm::ParameterSet ps)

Definition at line 588 of file CTPPSDiamondDQMSource.cc.

References extract_digi_info_, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), muonDTDigis_cfi::pset, runParameters_, tokenDigi_, tokenFEDInfo_, and tokenStatus_.

589  : perLSsaving_(ps.getUntrackedParameter<bool>("perLSsaving", false)),
591  ps.getUntrackedParameter<edm::InputTag>("tagPixelLocalTracks"))),
593  ps.getUntrackedParameter<edm::InputTag>("tagDiamondRecHits"))),
595  ps.getUntrackedParameter<edm::InputTag>("tagDiamondLocalTracks"))),
596  ctppsGeometryRunToken_(esConsumes<CTPPSGeometry, VeryForwardRealGeometryRecord, edm::Transition::BeginRun>()),
597  ctppsGeometryEventToken_(esConsumes<CTPPSGeometry, VeryForwardRealGeometryRecord>()),
598  // ctppsLhcInfoToken_(esConsumes<LHCInfo, LHCInfoRcd>()),
599  excludeMultipleHits_(ps.getParameter<bool>("excludeMultipleHits")),
600  extract_digi_info_(ps.getParameter<bool>("extractDigiInfo")),
601  centralOOT_(-999),
602  verbosity_(ps.getUntrackedParameter<unsigned int>("verbosity", 0)),
603  plotOnline_(ps.getUntrackedParameter<bool>("plotOnline", true)),
604  plotOffline_(ps.getUntrackedParameter<bool>("plotOffline", false)),
605  windowsNum_(ps.getUntrackedParameter<unsigned int>("windowsNum", 3)),
606  trackCorrelationThreshold_(ps.getUntrackedParameter<unsigned int>("trackCorrelationThreshold", 3)),
607  EC_difference_56_(-500),
608  EC_difference_45_(-500) {
609  if (extract_digi_info_) {
610  tokenStatus_ = consumes<edm::DetSetVector<TotemVFATStatus>>(ps.getUntrackedParameter<edm::InputTag>("tagStatus"));
611  tokenFEDInfo_ = consumes<std::vector<TotemFEDInfo>>(ps.getUntrackedParameter<edm::InputTag>("tagFEDInfo"));
612  tokenDigi_ = consumes<edm::DetSetVector<CTPPSDiamondDigi>>(ps.getUntrackedParameter<edm::InputTag>("tagDigi"));
613  }
614  for (const auto& pset : ps.getParameter<std::vector<edm::ParameterSet>>("offsetsOOT")) {
615  runParameters_.emplace_back(
616  std::make_pair(pset.getParameter<edm::EventRange>("validityRange"), pset.getParameter<int>("centralOOT")));
617  }
618 }
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondRecHit > > tokenDiamondHit_
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecord > ctppsGeometryRunToken_
edm::EDGetTokenT< std::vector< TotemFEDInfo > > tokenFEDInfo_
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecord > ctppsGeometryEventToken_
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondLocalTrack > > tokenDiamondTrack_
edm::EDGetTokenT< edm::DetSetVector< CTPPSPixelLocalTrack > > tokenPixelTrack_
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
T getUntrackedParameter(std::string const &, T const &) const
std::vector< std::pair< edm::EventRange, int > > runParameters_
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondDigi > > tokenDigi_
edm::EDGetTokenT< edm::DetSetVector< TotemVFATStatus > > tokenStatus_

Member Function Documentation

◆ analyze()

void CTPPSDiamondDQMSource::analyze ( const edm::Event event,
const edm::EventSetup iSetup 
)
overrideprotectedvirtual

Reimplemented from DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > >.

Definition at line 707 of file CTPPSDiamondDQMSource.cc.

References CTPPSDetId::arm(), centralOOT_, CTPPSDiamondDetId::channel(), CHANNEL_OF_VFAT_CLOCK, channelAlignedWithTrack(), channelPlots_, checkEventNumber(), CTPPS_FAR_RP_ID, CTPPS_FED_ID_45, CTPPS_FED_ID_56, CTPPS_PIXEL_STATION_ID, ctppsGeometryEventToken_, diamShifts_, EC_difference_45_, EC_difference_56_, HPTDCErrorFlags::errorId(), excludeMultipleHits_, extract_digi_info_, HcalObjRepresent::Fill(), edm::EventSetup::getData(), HPTDC_0_CHANNEL, HPTDC_1_CHANNEL, HPTDC_BIN_WIDTH_NS, mps_fire::i, edm::eventsetup::heterocontainer::insert(), INV_DISPLAY_RESOLUTION_FOR_HITS_MM, edm::HandleBase::isValid(), perLSsaving_, BeamSpotProblemMonitor_cff::pixelTracks, CTPPSDiamondDetId::plane(), planePlots_, plotOffline_, plotOnline_, potPlots_, HI_PhotonSkim_cff::rechits, CTPPSDetId::rpId(), sectorPlots_, edm::shift, mps_update::status, CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING, tokenDiamondHit_, tokenDiamondTrack_, tokenDigi_, tokenFEDInfo_, tokenPixelTrack_, tokenStatus_, HLT_2022v15_cff::track, trackCorrelationThreshold_, pwdgSkimBPark_cfi::tracks, validateGeometry_cfg::valid, verbosity_, windowsNum_, and y.

707  {
708  // get event data
709 
713  if (extract_digi_info_) {
714  event.getByToken(tokenStatus_, diamondVFATStatus);
715  event.getByToken(tokenDigi_, diamondDigis);
716  event.getByToken(tokenFEDInfo_, fedInfo);
717  }
718 
720  event.getByToken(tokenPixelTrack_, pixelTracks);
721 
723  event.getByToken(tokenDiamondHit_, diamondRecHits);
724 
726  event.getByToken(tokenDiamondTrack_, diamondLocalTracks);
727 
728  const CTPPSGeometry* ctppsGeometry = &iSetup.getData(ctppsGeometryEventToken_);
729  // const LHCInfo* hLhcInfo = &iSetup.getData(ctppsLhcInfoToken_);
730 
731  // check validity
732  bool valid = true;
733  if (extract_digi_info_) { // drop DIGI-level validity checks if not monitored
734  valid &= diamondVFATStatus.isValid();
735  valid &= diamondDigis.isValid();
736  valid &= fedInfo.isValid();
737  }
738  valid &= pixelTracks.isValid();
739  valid &= diamondRecHits.isValid();
740  valid &= diamondLocalTracks.isValid();
741 
742  if (!valid) {
743  if (verbosity_)
744  edm::LogProblem("CTPPSDiamondDQMSource")
745  << "ERROR in CTPPSDiamondDQMSource::analyze > some of the required inputs are not valid. Skipping this "
746  "event.\n"
747  << " DIGI-level: (checked? " << std::boolalpha << extract_digi_info_ << ")\n"
748  << " diamondVFATStatus.isValid = " << diamondVFATStatus.isValid() << "\n"
749  << " diamondDigis.isValid = " << diamondDigis.isValid() << "\n"
750  << " fedInfo.isValid = " << fedInfo.isValid() << "\n"
751  << " RECO-level:\n"
752  << " pixelTracks.isValid = " << pixelTracks.isValid() << "\n"
753  << " diamondRecHits.isValid = " << diamondRecHits.isValid() << "\n"
754  << " diamondLocalTracks.isValid = " << diamondLocalTracks.isValid();
755  return;
756  }
757 
758  //------------------------------
759  // Sector Plots
760  //------------------------------
761  // Using CTPPSDiamondLocalTrack
762  if (plotOffline_)
763  for (const auto& tracks : *diamondLocalTracks) {
764  const CTPPSDiamondDetId detId_near(tracks.detId());
765 
766  for (const auto& track : tracks) {
767  if (!track.isValid())
768  continue;
769  if (potPlots_.count(detId_near.rpId()) == 0)
770  continue;
771  TH1F* trackHistoInTimeTmp = potPlots_[detId_near.rpId()].trackDistribution->getTH1F();
772  int startBin_near =
773  trackHistoInTimeTmp->FindBin(track.x0() - diamShifts_[detId_near.rpId()].global - track.x0Sigma());
774  int numOfBins_near = 2 * track.x0Sigma() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
775 
776  for (const auto& tracks_far : *diamondLocalTracks) {
777  CTPPSDiamondDetId detId_far(tracks_far.detId());
778  if (detId_near.arm() != detId_far.arm() || detId_near.station() == detId_far.station())
779  continue;
780  for (const auto& track_far : tracks_far) {
781  if (!track.isValid())
782  continue;
783  if (sectorPlots_.count(detId_far.armId()) == 0)
784  continue;
785  TH2F* trackHistoTmp = sectorPlots_[detId_far.armId()].trackCorrelation->getTH2F();
786  TAxis* trackHistoTmpXAxis = trackHistoTmp->GetXaxis();
787  TAxis* trackHistoTmpYAxis = trackHistoTmp->GetYaxis();
788  int startBin_far = trackHistoTmpYAxis->FindBin(track_far.x0() - diamShifts_[detId_far.rpId()].global -
789  track_far.x0Sigma());
790  int numOfBins_far = 2 * track_far.x0Sigma() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
791  for (int i = 0; i < numOfBins_near; ++i)
792  for (int y = 0; y < numOfBins_far; ++y) {
793  trackHistoTmp->Fill(trackHistoTmpXAxis->GetBinCenter(startBin_near + i),
794  trackHistoTmpYAxis->GetBinCenter(startBin_far + y));
795  if (tracks.size() < 3 && tracks_far.size() < trackCorrelationThreshold_)
796  sectorPlots_[detId_far.armId()].trackCorrelationLowMultiplicity->Fill(
797  trackHistoTmpXAxis->GetBinCenter(startBin_near + i),
798  trackHistoTmpYAxis->GetBinCenter(startBin_far + y));
799  }
800  }
801  }
802  }
803  }
804 
805  //------------------------------
806  // RP Plots
807  //------------------------------
808 
809  //------------------------------
810  // Correlation Plots
811  //------------------------------
812 
813  if (extract_digi_info_) {
814  // Using CTPPSDiamondDigi
815  for (const auto& digis : *diamondDigis) {
816  const CTPPSDiamondDetId detId(digis.detId()), detId_pot(detId.rpId());
817  for (const auto& digi : digis) {
818  if (detId.channel() == CHANNEL_OF_VFAT_CLOCK)
819  continue;
820  if (potPlots_.count(detId_pot) == 0)
821  continue;
822  //Leading without trailing investigation
823  if (digi.leadingEdge() != 0 || digi.trailingEdge() != 0) {
824  ++potPlots_[detId_pot].HitCounter;
825  if (digi.leadingEdge() != 0) {
826  potPlots_[detId_pot].leadingEdgeCumulative_all->Fill(HPTDC_BIN_WIDTH_NS * digi.leadingEdge());
827  }
828  if (digi.leadingEdge() != 0 && digi.trailingEdge() == 0) {
829  ++potPlots_[detId_pot].LeadingOnlyCounter;
830  potPlots_[detId_pot].leadingEdgeCumulative_le->Fill(HPTDC_BIN_WIDTH_NS * digi.leadingEdge());
831  }
832  if (digi.leadingEdge() == 0 && digi.trailingEdge() != 0) {
833  ++potPlots_[detId_pot].TrailingOnlyCounter;
834  potPlots_[detId_pot].trailingEdgeCumulative_te->Fill(HPTDC_BIN_WIDTH_NS * digi.trailingEdge());
835  }
836  if (digi.leadingEdge() != 0 && digi.trailingEdge() != 0) {
837  ++potPlots_[detId_pot].CompleteCounter;
838  // potPlots_[detId_pot].leadingTrailingCorrelationPot->Fill(HPTDC_BIN_WIDTH_NS * digi.leadingEdge(),
839  // HPTDC_BIN_WIDTH_NS * digi.trailingEdge());
840  }
841  }
842 
843  // HPTDC Errors
844  const HPTDCErrorFlags hptdcErrors = digi.hptdcErrorFlags();
845  if (detId.channel() == HPTDC_0_CHANNEL ||
846  detId.channel() == HPTDC_1_CHANNEL) { // ch6 for HPTDC 0 and ch7 for HPTDC 1
847  int verticalIndex = 2 * detId.plane() + (detId.channel() - HPTDC_0_CHANNEL);
848  for (unsigned short hptdcErrorIndex = 1; hptdcErrorIndex < 16; ++hptdcErrorIndex)
849  if (hptdcErrors.errorId(hptdcErrorIndex - 1))
850  potPlots_[detId_pot].HPTDCErrorFlags_2D->Fill(hptdcErrorIndex, verticalIndex);
851  }
852  if (digi.multipleHit())
853  ++potPlots_[detId_pot].MHCounter;
854  }
855  }
856  }
857 
858  // EC Errors
859  if (extract_digi_info_) {
860  for (const auto& vfat_status : *diamondVFATStatus) {
861  const CTPPSDiamondDetId detId(vfat_status.detId());
862  for (const auto& status : vfat_status) {
863  if (!status.isOK())
864  continue;
865  if (potPlots_.count(detId.rpId()) == 0)
866  continue;
867  if (channelPlots_.count(detId) == 0)
868  continue;
869 
870  // Check Event Number
871  for (const auto& optorx : *fedInfo) {
872  if (detId.arm() == 1 && optorx.fedId() == CTPPS_FED_ID_56)
873  checkEventNumber(detId, optorx, status, potPlots_[detId.rpId()], EC_difference_56_);
874  else if (detId.arm() == 0 && optorx.fedId() == CTPPS_FED_ID_45)
875  checkEventNumber(detId, optorx, status, potPlots_[detId.rpId()], EC_difference_45_);
876  }
877  }
878  }
879  }
880 
881  // Using CTPPSDiamondRecHit
882  std::unordered_map<unsigned int, std::set<unsigned int>> planes;
883  std::unordered_map<unsigned int, std::set<unsigned int>> planes_inclusive;
884 
885  auto lumiCache = luminosityBlockCache(event.getLuminosityBlock().index());
886  for (const auto& rechits : *diamondRecHits) {
887  const CTPPSDiamondDetId detId(rechits.detId()), detId_pot(detId.rpId());
888  const auto& x_shift = diamShifts_.at(detId_pot);
889 
890  for (const auto& rechit : rechits) {
891  planes_inclusive[detId_pot].insert(detId.plane());
892  if (excludeMultipleHits_ && rechit.multipleHits() > 0)
893  continue;
894  if (rechit.toT() != 0 && centralOOT_ != -999 && rechit.ootIndex() == centralOOT_)
895  planes[detId_pot].insert(detId.plane());
896 
897  if (potPlots_.count(detId_pot) == 0)
898  continue;
899 
900  potPlots_[detId_pot].recHitTime->Fill(rechit.time());
901 
902  float UFSDShift = 0.0;
903  if (rechit.yWidth() < 3)
904  UFSDShift = 0.5; // Display trick for UFSD that have 2 pixels with same X
905 
906  if (rechit.toT() != 0 && centralOOT_ != -999 && rechit.ootIndex() == centralOOT_) {
907  TH2F* hitHistoTmp = potPlots_[detId_pot].hitDistribution2d->getTH2F();
908  TAxis* hitHistoTmpYAxis = hitHistoTmp->GetYaxis();
909  int startBin = hitHistoTmpYAxis->FindBin(rechit.x() - x_shift.global - 0.5 * rechit.xWidth());
910  int numOfBins = rechit.xWidth() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
911  for (int i = 0; i < numOfBins; ++i)
912  hitHistoTmp->Fill(detId.plane() + UFSDShift, hitHistoTmpYAxis->GetBinCenter(startBin + i));
913 
914  if (!perLSsaving_ && plotOnline_) {
915  hitHistoTmp = lumiCache->hitDistribution2dMap[detId_pot].get();
916  hitHistoTmpYAxis = hitHistoTmp->GetYaxis();
917  startBin = hitHistoTmpYAxis->FindBin(rechit.x() - x_shift.global - 0.5 * rechit.xWidth());
918  numOfBins = rechit.xWidth() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
919  for (int i = 0; i < numOfBins; ++i)
920  hitHistoTmp->Fill(detId.plane() + UFSDShift, hitHistoTmpYAxis->GetBinCenter(startBin + i));
921  }
922  }
923 
924  if (rechit.toT() > 0) {
925  // Both
926  potPlots_[detId_pot].leadingEdgeCumulative_both->Fill(rechit.time() + 25 * rechit.ootIndex());
927  potPlots_[detId_pot].timeOverThresholdCumulativePot->Fill(rechit.toT());
928 
929  TH2F* hitHistoOOTTmp = potPlots_[detId_pot].hitDistribution2dOOT->getTH2F();
930  TAxis* hitHistoOOTTmpYAxis = hitHistoOOTTmp->GetYaxis();
931  int startBin = hitHistoOOTTmpYAxis->FindBin(rechit.x() - x_shift.global - 0.5 * rechit.xWidth());
932  int numOfBins = rechit.xWidth() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
933  for (int i = 0; i < numOfBins; ++i)
934  hitHistoOOTTmp->Fill(detId.plane() + 1. / windowsNum_ * rechit.ootIndex(),
935  hitHistoOOTTmpYAxis->GetBinCenter(startBin + i));
936 
937  } else if (rechit.ootIndex() != CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING && plotOnline_) {
938  // Only leading
939  TH2F* hitHistoOOTTmp = potPlots_[detId_pot].hitDistribution2dOOT_le->getTH2F();
940  TAxis* hitHistoOOTTmpYAxis = hitHistoOOTTmp->GetYaxis();
941  int startBin = hitHistoOOTTmpYAxis->FindBin(rechit.x() - x_shift.global - 0.5 * rechit.xWidth());
942  int numOfBins = rechit.xWidth() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
943  for (int i = 0; i < numOfBins; ++i)
944  hitHistoOOTTmp->Fill(detId.plane() + 1. / windowsNum_ * rechit.ootIndex(),
945  hitHistoOOTTmpYAxis->GetBinCenter(startBin + i));
946  }
947  if (rechit.ootIndex() != CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING &&
948  potPlots_[detId_pot].activity_per_bx.count(rechit.ootIndex()) > 0)
949  potPlots_[detId_pot].activity_per_bx.at(rechit.ootIndex())->Fill(event.bunchCrossing());
950 
951  // if(plotOffline_)
952  // potPlots_[detId_pot].TOTVsLS->Fill(event.luminosityBlock(),rechit.toT());
953  }
954  }
955 
956  for (const auto& plt : potPlots_) {
957  plt.second.activePlanes->Fill(planes[plt.first].size());
958  if (plotOnline_)
959  plt.second.activePlanesInclusive->Fill(planes_inclusive[plt.first].size());
960  }
961 
962  // Using CTPPSDiamondLocalTrack
963  for (const auto& tracks : *diamondLocalTracks) {
964  const CTPPSDiamondDetId detId(tracks.detId()), detId_pot(detId.rpId());
965  const auto& x_shift = diamShifts_.at(detId_pot);
966 
967  for (const auto& track : tracks) {
968  if (!track.isValid())
969  continue;
971  continue;
972  if (excludeMultipleHits_ && track.multipleHits() > 0)
973  continue;
974  if (potPlots_.count(detId_pot) == 0)
975  continue;
976 
977  TH2F* trackHistoOOTTmp = potPlots_[detId_pot].trackDistributionOOT->getTH2F();
978  TAxis* trackHistoOOTTmpYAxis = trackHistoOOTTmp->GetYaxis();
979  int startBin = trackHistoOOTTmpYAxis->FindBin(track.x0() - x_shift.global - track.x0Sigma());
980  int numOfBins = 2 * track.x0Sigma() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
981  for (int i = 0; i < numOfBins; ++i)
982  trackHistoOOTTmp->Fill(track.ootIndex(), trackHistoOOTTmpYAxis->GetBinCenter(startBin + i));
983 
984  if (centralOOT_ != -999 && track.ootIndex() == centralOOT_) {
985  TH1F* trackHistoInTimeTmp = potPlots_[detId_pot].trackDistribution->getTH1F();
986  int startBin = trackHistoInTimeTmp->FindBin(track.x0() - x_shift.global - track.x0Sigma());
987  int numOfBins = 2 * track.x0Sigma() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
988  for (int i = 0; i < numOfBins; ++i)
989  trackHistoInTimeTmp->Fill(trackHistoInTimeTmp->GetBinCenter(startBin + i));
990  }
991  if (plotOffline_ && !perLSsaving_) {
992  // potPlots_[detId_pot].trackTimeVsLS->Fill(event.luminosityBlock(),track.time());
993  potPlots_[detId_pot].trackTimeVsBX->Fill(event.bunchCrossing(), track.time());
994  //potPlots_[detId_pot].trackTimeVsXAngle->Fill(hLhcInfo->crossingAngle(), track.time());
995  }
996  }
997  }
998 
999  // Channel efficiency using CTPPSDiamondLocalTrack
1000  for (const auto& tracks : *diamondLocalTracks) {
1001  const CTPPSDiamondDetId detId(tracks.detId()), detId_pot(detId.rpId());
1002  for (const auto& track : tracks) {
1003  // Find hits and planes in the track
1004  int numOfHits = 0;
1005  std::set<int> planesInTrackSet;
1006  for (const auto& vec : *diamondRecHits) {
1007  const CTPPSDiamondDetId detid(vec.detId());
1008  if (detid.arm() != detId_pot.arm())
1009  continue;
1010 
1011  for (const auto& hit : vec) {
1012  // first check if the hit contributes to the track
1013  if (track.containsHit(hit)) {
1014  ++numOfHits;
1015  planesInTrackSet.insert(detid.plane());
1016  }
1017  }
1018  }
1019 
1020  if (numOfHits > 0 && numOfHits <= 10 && planesInTrackSet.size() > 2) {
1021  for (const auto& plt_vs_ch : channelPlots_) { // loop over all channels registered in geometry
1022  const CTPPSDiamondDetId detId(plt_vs_ch.first);
1023  if (detId.rpId() != detId_pot)
1024  continue;
1025  const unsigned short map_index = detId.plane() * 100 + detId.channel();
1026  if (potPlots_[detId_pot].effDoublecountingChMap.count(map_index) == 0) {
1027  potPlots_[detId_pot].effTriplecountingChMap[map_index] = 0;
1028  potPlots_[detId_pot].effDoublecountingChMap[map_index] = 0;
1029  }
1030  if (channelAlignedWithTrack(ctppsGeometry, detId, track, 0.2)) {
1031  // Channel should fire
1032  ++potPlots_[detId_pot].effDoublecountingChMap[map_index];
1033  for (const auto& rechits : *diamondRecHits) {
1034  const CTPPSDiamondDetId detId_hit(rechits.detId());
1035  if (detId_hit == detId)
1036  for (const auto& rechit : rechits)
1037  if (track.containsHit(rechit, 1)) // Channel fired
1038  ++potPlots_[detId_pot].effTriplecountingChMap[map_index];
1039  }
1040  }
1041  }
1042  }
1043  }
1044  }
1045 
1046  // Tomography of diamonds using pixel
1047  for (const auto& rechits : *diamondRecHits) {
1048  const CTPPSDiamondDetId detId(rechits.detId()), detId_pot(detId.rpId());
1049  const auto pix_shift = diamShifts_.at(detId_pot).withPixels;
1050  for (const auto& rechit : rechits) {
1051  if (excludeMultipleHits_ && rechit.multipleHits() > 0)
1052  continue;
1053  if (rechit.toT() == 0)
1054  continue;
1055  if (!pixelTracks.isValid())
1056  continue;
1057  if (potPlots_.count(detId_pot) == 0)
1058  continue;
1059 
1060  for (const auto& ds : *pixelTracks) {
1061  if (ds.size() > 1)
1062  continue;
1063  const CTPPSPixelDetId pixId(ds.detId());
1064  if (pixId.station() != CTPPS_PIXEL_STATION_ID || pixId.rp() != CTPPS_FAR_RP_ID)
1065  continue;
1066  for (const auto& lt : ds) {
1067  if (lt.isValid() && pixId.arm() == detId_pot.arm()) {
1068  if (rechit.ootIndex() != CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING && rechit.ootIndex() >= 0 &&
1069  potPlots_[detId_pot].pixelTomographyAll.count(rechit.ootIndex()) > 0 && lt.x0() - pix_shift < 24)
1070  potPlots_[detId_pot]
1071  .pixelTomographyAll.at(rechit.ootIndex())
1072  ->Fill(lt.x0() - pix_shift + 25 * detId.plane(), lt.y0());
1073  }
1074  }
1075  }
1076  }
1077  }
1078 
1079  //------------------------------
1080  // Clock Plots
1081  //------------------------------
1082  // Commented out to save space in the DQM files, but code should be kept
1083  // for ( const auto& digis : *diamondDigis ) {
1084  // const CTPPSDiamondDetId detId(digis.detId()), detId_pot(detId.rpId());
1085  // if ( detId.channel() == CHANNEL_OF_VFAT_CLOCK ) {
1086  // for ( const auto& digi : digis ) {
1087  // if ( digi.leadingEdge() != 0 ) {
1088  // if ( detId.plane() == 1 ) {
1089  // potPlots_[detId_pot].clock_Digi1_le->Fill( HPTDC_BIN_WIDTH_NS * digi.leadingEdge() );
1090  // potPlots_[detId_pot].clock_Digi1_te->Fill( HPTDC_BIN_WIDTH_NS * digi.trailingEdge() );
1091  // }
1092  // if ( detId.plane() == 3 ) {
1093  // potPlots_[detId_pot].clock_Digi3_le->Fill( HPTDC_BIN_WIDTH_NS * digi.leadingEdge() );
1094  // potPlots_[detId_pot].clock_Digi3_te->Fill( HPTDC_BIN_WIDTH_NS * digi.trailingEdge() );
1095  // }
1096  // }
1097  // }
1098  // }
1099  // }
1100 
1101  //------------------------------
1102  // Plane Plots
1103  //------------------------------
1104 
1105  // Using CTPPSDiamondDigi
1106  std::unordered_map<unsigned int, unsigned int> channelsPerPlane;
1107  if (extract_digi_info_) {
1108  for (const auto& digis : *diamondDigis) {
1109  const CTPPSDiamondDetId detId(digis.detId()), detId_plane(detId.planeId());
1110  for (const auto& digi : digis) {
1111  if (detId.channel() == CHANNEL_OF_VFAT_CLOCK)
1112  continue;
1113  if (planePlots_.count(detId_plane) == 0)
1114  continue;
1115 
1116  if (digi.leadingEdge() != 0) {
1117  planePlots_[detId_plane].digiProfileCumulativePerPlane->Fill(detId.channel());
1118  channelsPerPlane[detId_plane]++;
1119  }
1120  }
1121  }
1122  }
1123 
1124  for (const auto& plt : channelsPerPlane)
1125  planePlots_[plt.first].hit_multiplicity->Fill(plt.second);
1126 
1127  // Using CTPPSDiamondRecHit
1128  for (const auto& rechits : *diamondRecHits) {
1129  const CTPPSDiamondDetId detId(rechits.detId()), detId_plane(detId.planeId()), detId_pot(detId.rpId());
1130  for (const auto& rechit : rechits) {
1131  if (excludeMultipleHits_ && rechit.multipleHits() > 0)
1132  continue;
1133  if (rechit.toT() == 0)
1134  continue;
1135  if (planePlots_.count(detId_plane) != 0) {
1136  if (centralOOT_ != -999 && rechit.ootIndex() == centralOOT_) {
1137  TH1F* hitHistoTmp = planePlots_[detId_plane].hitProfile->getTH1F();
1138  int startBin = hitHistoTmp->FindBin(rechit.x() - diamShifts_.at(detId_pot).global - 0.5 * rechit.xWidth());
1139  int numOfBins = rechit.xWidth() * INV_DISPLAY_RESOLUTION_FOR_HITS_MM;
1140  for (int i = 0; i < numOfBins; ++i)
1141  hitHistoTmp->Fill(hitHistoTmp->GetBinCenter(startBin + i));
1142  }
1143  }
1144  }
1145  }
1146 
1147  //Tomography of diamonds using pixel and Efficiency WRT Pixels
1148  for (const auto& ds : *pixelTracks) {
1149  const CTPPSPixelDetId pixId(ds.detId());
1150  if (pixId.station() != CTPPS_PIXEL_STATION_ID || pixId.rp() != CTPPS_FAR_RP_ID)
1151  continue;
1152  if (ds.size() > 1)
1153  continue;
1154  for (const auto& lt : ds) {
1155  if (lt.isValid()) {
1156  for (const auto& sh_vs_id : diamShifts_) {
1157  const CTPPSDiamondDetId& detId_pot = sh_vs_id.first;
1158  const auto& shift = sh_vs_id.second;
1159  if (detId_pot.arm() == pixId.arm())
1160  // For efficieny
1161  potPlots_[detId_pot].pixelTracksMap.Fill(lt.x0() - shift.withPixels, lt.y0());
1162  }
1163 
1164  std::set<CTPPSDiamondDetId> planesWitHits_set;
1165  for (const auto& rechits : *diamondRecHits) {
1166  const CTPPSDiamondDetId detId(rechits.detId()), detId_plane(detId.planeId()), detId_pot(detId.rpId());
1167  const auto pix_shift = diamShifts_.at(detId_pot).withPixels;
1168  for (const auto& rechit : rechits) {
1169  if (excludeMultipleHits_ && rechit.multipleHits() > 0)
1170  continue;
1171  if (rechit.ootIndex() == CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING || rechit.toT() == 0)
1172  continue;
1173  if (planePlots_.count(detId_plane) == 0)
1174  continue;
1175  if (pixId.arm() == detId_plane.arm() && lt.x0() - pix_shift < 24) {
1176  planePlots_[detId_plane].pixelTomography_far->Fill(lt.x0() - pix_shift + 25 * rechit.ootIndex(), lt.y0());
1177  if (centralOOT_ != -999 && rechit.ootIndex() == centralOOT_)
1178  planesWitHits_set.insert(detId_plane);
1179  }
1180  }
1181  }
1182 
1183  for (auto& planeId : planesWitHits_set)
1184  planePlots_[planeId].pixelTracksMapWithDiamonds.Fill(lt.x0() - diamShifts_.at(planeId.rpId()).withPixels,
1185  lt.y0());
1186  }
1187  }
1188  }
1189 
1190  //------------------------------
1191  // Channel Plots
1192  //------------------------------
1193 
1194  // digi profile cumulative
1195  if (extract_digi_info_) {
1196  for (const auto& digis : *diamondDigis) {
1197  const CTPPSDiamondDetId detId(digis.detId());
1198  for (const auto& digi : digis) {
1199  if (detId.channel() == CHANNEL_OF_VFAT_CLOCK)
1200  continue;
1201  if (channelPlots_.count(detId) != 0) {
1202  // HPTDC Errors
1203  const HPTDCErrorFlags hptdcErrors = digi.hptdcErrorFlags();
1204  for (unsigned short hptdcErrorIndex = 1; hptdcErrorIndex < 16; ++hptdcErrorIndex)
1205  if (hptdcErrors.errorId(hptdcErrorIndex - 1))
1206  channelPlots_[detId].HPTDCErrorFlags->Fill(hptdcErrorIndex);
1207  if (digi.multipleHit())
1208  ++channelPlots_[detId].MHCounter;
1209 
1210  // Check dropped trailing edges
1211  if (digi.leadingEdge() != 0 || digi.trailingEdge() != 0) {
1212  ++channelPlots_[detId].HitCounter;
1213  if (digi.trailingEdge() == 0) {
1214  ++channelPlots_[detId].LeadingOnlyCounter;
1215  channelPlots_[detId].leadingEdgeCumulative_le->Fill(HPTDC_BIN_WIDTH_NS * digi.leadingEdge());
1216  } else if (digi.leadingEdge() == 0) {
1217  ++channelPlots_[detId].TrailingOnlyCounter;
1218  channelPlots_[detId].trailingEdgeCumulative_te->Fill(HPTDC_BIN_WIDTH_NS * digi.trailingEdge());
1219  } else {
1220  ++channelPlots_[detId].CompleteCounter;
1221  // channelPlots_[detId].LeadingTrailingCorrelationPerChannel->Fill(HPTDC_BIN_WIDTH_NS * digi.leadingEdge(),
1222  // HPTDC_BIN_WIDTH_NS * digi.trailingEdge());
1223  }
1224  }
1225  }
1226  }
1227  }
1228  }
1229 
1230  // Using CTPPSDiamondRecHit
1231 
1232  for (const auto& rechits : *diamondRecHits) {
1233  CTPPSDiamondDetId detId(rechits.detId());
1234  for (const auto& rechit : rechits) {
1235  if (excludeMultipleHits_ && rechit.multipleHits() > 0)
1236  continue;
1237  if (channelPlots_.count(detId) != 0) {
1238  channelPlots_[detId].recHitTime->Fill(rechit.time());
1239  if (rechit.ootIndex() != CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING && rechit.toT() != 0) {
1240  channelPlots_[detId].leadingEdgeCumulative_both->Fill(rechit.time() + 25 * rechit.ootIndex());
1241  channelPlots_[detId].TimeOverThresholdCumulativePerChannel->Fill(rechit.toT());
1242  }
1243  ++lumiCache->hitsCounterMap[detId];
1244 
1245  if (rechit.ootIndex() != CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING &&
1246  channelPlots_[detId].activity_per_bx.count(rechit.ootIndex()) > 0)
1247  channelPlots_[detId].activity_per_bx.at(rechit.ootIndex())->Fill(event.bunchCrossing());
1248  }
1249  }
1250  }
1251 
1252  // Tomography of diamonds using pixel
1253  for (const auto& rechits : *diamondRecHits) {
1254  const CTPPSDiamondDetId detId(rechits.detId()), detId_pot(detId.rpId());
1255  const auto shift_pix = diamShifts_.at(detId_pot).withPixels;
1256  for (const auto& rechit : rechits) {
1257  if (excludeMultipleHits_ && rechit.multipleHits() > 0)
1258  continue;
1259  if (rechit.ootIndex() == CTPPSDiamondRecHit::TIMESLICE_WITHOUT_LEADING || rechit.toT() == 0)
1260  continue;
1261  if (!pixelTracks.isValid())
1262  continue;
1263  if (channelPlots_.count(detId) == 0)
1264  continue;
1265 
1266  for (const auto& ds : *pixelTracks) {
1267  const CTPPSPixelDetId pixId(ds.detId());
1268  if (pixId.station() != CTPPS_PIXEL_STATION_ID || pixId.rp() != CTPPS_FAR_RP_ID)
1269  continue;
1270  if (ds.size() > 1)
1271  continue;
1272  for (const auto& lt : ds) {
1273  if (lt.isValid() && pixId.arm() == detId.arm() && lt.x0() - shift_pix < 24)
1274  channelPlots_[detId].pixelTomography_far->Fill(lt.x0() - shift_pix + 25 * rechit.ootIndex(), lt.y0());
1275  }
1276  }
1277  }
1278  }
1279 }
static constexpr unsigned short CTPPS_FED_ID_45
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondRecHit > > tokenDiamondHit_
edm::EDGetTokenT< std::vector< TotemFEDInfo > > tokenFEDInfo_
std::unordered_map< CTPPSDetId, DiamondShifts > diamShifts_
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
Definition: EventSetup.h:119
static constexpr unsigned short CTPPS_FAR_RP_ID
uint32_t arm() const
Definition: CTPPSDetId.h:57
static constexpr unsigned short CTPPS_PIXEL_STATION_ID
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecord > ctppsGeometryEventToken_
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondLocalTrack > > tokenDiamondTrack_
edm::EDGetTokenT< edm::DetSetVector< CTPPSPixelLocalTrack > > tokenPixelTrack_
static constexpr unsigned short HPTDC_0_CHANNEL
edm::EDGetTokenT< edm::DetSetVector< CTPPSDiamondDigi > > tokenDigi_
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
std::unordered_map< unsigned int, ChannelPlots > channelPlots_
edm::EDGetTokenT< edm::DetSetVector< TotemVFATStatus > > tokenStatus_
static constexpr unsigned short CHANNEL_OF_VFAT_CLOCK
Channel ID of the VFAT that contains clock data.
bool errorId(unsigned short id) const
bool insert(Storage &iStorage, ItemType *iItem, const IdTag &iIdTag)
Definition: HCMethods.h:50
The manager class for TOTEM RP geometry.
Definition: CTPPSGeometry.h:30
std::unordered_map< unsigned int, SectorPlots > sectorPlots_
bool channelAlignedWithTrack(const CTPPSGeometry *geom, const CTPPSDiamondDetId &detid, const CTPPSDiamondLocalTrack &localTrack, const float tolerance=1)
bool isValid() const
Definition: HandleBase.h:70
std::unordered_map< unsigned int, PotPlots > potPlots_
static constexpr int TIMESLICE_WITHOUT_LEADING
void checkEventNumber(const CTPPSDiamondDetId &, const TotemFEDInfo &, const TotemVFATStatus &, PotPlots &, int &) const
static constexpr unsigned short CTPPS_FED_ID_56
static constexpr double HPTDC_BIN_WIDTH_NS
ns per HPTDC bin
static constexpr double INV_DISPLAY_RESOLUTION_FOR_HITS_MM
static unsigned int const shift
Detector ID class for CTPPS Timing Diamond detectors. Bits [19:31] : Assigend in CTPPSDetId Calss Bit...
std::unordered_map< unsigned int, PlanePlots > planePlots_
static constexpr unsigned short HPTDC_1_CHANNEL
Definition: event.py:1
Log< level::Error, true > LogProblem

◆ bookHistograms()

void CTPPSDiamondDQMSource::bookHistograms ( DQMStore::IBooker ibooker,
const edm::Run ,
const edm::EventSetup iSetup 
)
overrideprotectedvirtual

Implements DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > >.

Definition at line 650 of file CTPPSDiamondDQMSource.cc.

References CTPPSDetId::armId(), dqm::implementation::NavigatorBase::cd(), channelPlots_, CTPPSDiamondDetId::check(), ctppsGeometryRunToken_, relativeConstraints::geom, edm::EventSetup::getData(), globalPlot_, perLSsaving_, CTPPSDiamondDetId::planeId(), planePlots_, plotOffline_, plotOnline_, potPlots_, CTPPSDetId::rpId(), sectorPlots_, dqm::implementation::NavigatorBase::setCurrentFolder(), and windowsNum_.

650  {
651  ibooker.cd();
652  ibooker.setCurrentFolder("CTPPS");
653 
654  globalPlot_ = GlobalPlots(ibooker);
655 
656  // book plots from the geometry
658  for (auto it = geom.beginSensor(); it != geom.endSensor(); ++it) {
659  if (!CTPPSDiamondDetId::check(it->first))
660  continue;
661  // per-channel plots
662  const CTPPSDiamondDetId chId(it->first);
663  if (plotOnline_ && channelPlots_.count(chId) == 0)
664  channelPlots_[chId] = ChannelPlots(ibooker, chId, windowsNum_);
665 
666  // per-plane plots
667  const CTPPSDiamondDetId plId(chId.planeId());
668  if (planePlots_.count(plId) == 0)
669  planePlots_[plId] = PlanePlots(ibooker, plId, windowsNum_);
670  // per-pot plots
671  const CTPPSDiamondDetId rpId(chId.rpId());
672  if (potPlots_.count(rpId) == 0)
673  potPlots_[rpId] = PotPlots(ibooker, rpId, windowsNum_, plotOnline_, plotOffline_, perLSsaving_);
674 
675  // per-sector plots
676  const CTPPSDiamondDetId secId(chId.armId());
677  if (plotOffline_ && sectorPlots_.count(secId) == 0)
678  sectorPlots_[secId] = SectorPlots(ibooker, secId, plotOnline_);
679  }
680 }
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecord > ctppsGeometryRunToken_
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
Definition: EventSetup.h:119
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:36
std::unordered_map< unsigned int, ChannelPlots > channelPlots_
static bool check(unsigned int raw)
returns true if the raw ID is a PPS-timing one
The manager class for TOTEM RP geometry.
Definition: CTPPSGeometry.h:30
std::unordered_map< unsigned int, SectorPlots > sectorPlots_
std::unordered_map< unsigned int, PotPlots > potPlots_
Detector ID class for CTPPS Timing Diamond detectors. Bits [19:31] : Assigend in CTPPSDetId Calss Bit...
std::unordered_map< unsigned int, PlanePlots > planePlots_

◆ checkEventNumber()

void CTPPSDiamondDQMSource::checkEventNumber ( const CTPPSDiamondDetId detId,
const TotemFEDInfo optorx,
const TotemVFATStatus status,
CTPPSDiamondDQMSource::PotPlots plots,
int &  EC_difference 
) const
private

Definition at line 1356 of file CTPPSDiamondDQMSource.cc.

References funct::abs(), CTPPSDiamondDetId::channel(), TauDecayModes::dec, TotemFEDInfo::fedId(), HPTDC_0_CHANNEL, HPTDC_1_CHANNEL, TotemFEDInfo::lv1(), CTPPSDiamondDetId::plane(), plotOnline_, HLTObjectsMonitor_cfi::plots, CTPPSDetId::rpId(), mps_update::status, and verbosity_.

Referenced by analyze().

1360  {
1361  const CTPPSDiamondDetId detId_pot(detId.rpId());
1362  if (plotOnline_)
1363  plots.ECCheck->Fill((int)((optorx.lv1() & 0xFF) - ((unsigned int)status.ec() & 0xFF)) & 0xFF);
1364  if ((static_cast<int>((optorx.lv1() & 0xFF) - status.ec()) != EC_difference) &&
1365  (static_cast<uint8_t>((optorx.lv1() & 0xFF) - status.ec()) < 128))
1366  EC_difference = static_cast<int>(optorx.lv1() & 0xFF) - (static_cast<unsigned int>(status.ec()) & 0xFF);
1367  if (EC_difference != 1 && EC_difference != -500 && std::abs(EC_difference) < 127) {
1368  if (detId.channel() == HPTDC_0_CHANNEL || detId.channel() == HPTDC_1_CHANNEL)
1369  plots.HPTDCErrorFlags_2D->Fill(16, 2 * detId.plane() + (detId.channel() - HPTDC_0_CHANNEL));
1370  if (verbosity_)
1371  edm::LogProblem("CTPPSDiamondDQMSource")
1372  << "FED " << optorx.fedId() << ": ECError at EV: 0x" << std::hex << optorx.lv1() << "\t\tVFAT EC: 0x"
1373  << static_cast<unsigned int>(status.ec()) << "\twith ID: " << std::dec << detId
1374  << "\tdiff: " << EC_difference;
1375  }
1376 }
uint32_t plane() const
static constexpr unsigned short HPTDC_0_CHANNEL
CTPPSDetId rpId() const
Definition: CTPPSDetId.h:84
uint32_t channel() const
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
int fedId() const
Definition: TotemFEDInfo.h:22
uint32_t lv1() const
Definition: TotemFEDInfo.h:26
Detector ID class for CTPPS Timing Diamond detectors. Bits [19:31] : Assigend in CTPPSDetId Calss Bit...
static constexpr unsigned short HPTDC_1_CHANNEL
Log< level::Error, true > LogProblem

◆ dqmBeginRun()

void CTPPSDiamondDQMSource::dqmBeginRun ( const edm::Run iRun,
const edm::EventSetup iSetup 
)
overrideprotectedvirtual

Reimplemented from DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > >.

Definition at line 622 of file CTPPSDiamondDQMSource.cc.

References CTPPSDetId::arm(), centralOOT_, CTPPSDiamondDetId::check(), edm::contains(), CTPPS_FAR_RP_ID, CTPPS_PIXEL_STATION_ID, ctppsGeometryRunToken_, diamShifts_, FIRST_RUN_W_PIXELS, relativeConstraints::geom, edm::EventSetup::getData(), edm::RunBase::run(), and runParameters_.

622  {
623  centralOOT_ = -999;
624  for (const auto& oot : runParameters_) {
625  if (edm::contains(oot.first, edm::EventID(iRun.run(), 0, 1))) {
626  centralOOT_ = oot.second;
627  break;
628  }
629  }
630 
631  // Get detector shifts from the geometry
633  for (auto it = geom.beginRP(); it != geom.endRP(); ++it)
634  if (CTPPSDiamondDetId::check(it->first)) {
635  const CTPPSDiamondDetId diam_id(it->first);
636  const auto diam = geom.sensor(it->first);
637  diamShifts_[diam_id].global = diam->translation().x() - diam->getDiamondDimensions().xHalfWidth;
638  if (iRun.run() > FIRST_RUN_W_PIXELS) { // pixel installed
639  const CTPPSPixelDetId pixid(diam_id.arm(), CTPPS_PIXEL_STATION_ID, CTPPS_FAR_RP_ID);
640  auto pix = geom.sensor(pixid);
641  // Rough alignement of pixel detector for diamond tomography
642  diamShifts_[diam_id].withPixels =
643  pix->translation().x() - pix->getDiamondDimensions().xHalfWidth - diamShifts_[diam_id].global - 1.;
644  }
645  }
646 }
edm::ESGetToken< CTPPSGeometry, VeryForwardRealGeometryRecord > ctppsGeometryRunToken_
std::unordered_map< CTPPSDetId, DiamondShifts > diamShifts_
bool contains(EventRange const &lh, EventID const &rh)
Definition: EventRange.cc:37
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
Definition: EventSetup.h:119
static constexpr unsigned short CTPPS_FAR_RP_ID
static constexpr unsigned short CTPPS_PIXEL_STATION_ID
std::vector< std::pair< edm::EventRange, int > > runParameters_
RunNumber_t run() const
Definition: RunBase.h:40
static constexpr unsigned int FIRST_RUN_W_PIXELS
Number of OOT indices monitored.
static bool check(unsigned int raw)
returns true if the raw ID is a PPS-timing one
The manager class for TOTEM RP geometry.
Definition: CTPPSGeometry.h:30
Detector ID class for CTPPS Timing Diamond detectors. Bits [19:31] : Assigend in CTPPSDetId Calss Bit...

◆ dqmEndRun()

void CTPPSDiamondDQMSource::dqmEndRun ( edm::Run const &  ,
edm::EventSetup const &   
)
overrideprotectedvirtual

Reimplemented from DQMOneEDAnalyzer< edm::LuminosityBlockCache< dds::Cache > >.

Definition at line 1380 of file CTPPSDiamondDQMSource.cc.

References perLSsaving_, plotOffline_, HLTObjectsMonitor_cfi::plots, and potPlots_.

1380  {
1381  if (plotOffline_ && !perLSsaving_)
1382  for (const auto& rpPlots : potPlots_) {
1383  auto plots = rpPlots.second;
1384  // *(plots.TOTVsLSProfile->getTProfile())=*plots.TOTVsLS->getTH2F()->ProfileX();
1385  // *(plots.trackTimeVsLSProfile->getTProfile())=*plots.trackTimeVsLS->getTH2F()->ProfileX();
1386  *(plots.trackTimeVsBXProfile->getTProfile()) = *plots.trackTimeVsBX->getTH2F()->ProfileX();
1387  // *(plots.trackTimeVsXAngleProfile->getTProfile()) = *plots.trackTimeVsXAngle->getTH2F()->ProfileX();
1388  }
1389 }
std::unordered_map< unsigned int, PotPlots > potPlots_

◆ globalBeginLuminosityBlock()

std::shared_ptr< dds::Cache > CTPPSDiamondDQMSource::globalBeginLuminosityBlock ( const edm::LuminosityBlock ,
const edm::EventSetup  
) const
overrideprotected

Definition at line 684 of file CTPPSDiamondDQMSource.cc.

References ztail::d, INV_DISPLAY_RESOLUTION_FOR_HITS_MM, perLSsaving_, plotFactory::plot, plotOnline_, potPlots_, and AlCaHLTBitMon_QueryRunRegistry::string.

685  {
686  auto d = std::make_shared<dds::Cache>();
687  d->hitDistribution2dMap.reserve(potPlots_.size());
688  if (!perLSsaving_ && plotOnline_) {
689  for (auto& plot : potPlots_) {
690  d->hitDistribution2dMap[plot.first] = std::make_unique<TH2F>(
691  "hits in planes lumisection",
692  (std::string(plot.second.hitDistribution2d_lumisection->getTH2F()->GetTitle()) + ";plane number;x (mm)")
693  .c_str(),
694  10,
695  -0.5,
696  4.5,
698  -0.5,
699  18.5);
700  }
701  }
702  return d;
703 }
d
Definition: ztail.py:151
std::unordered_map< unsigned int, PotPlots > potPlots_
static constexpr double INV_DISPLAY_RESOLUTION_FOR_HITS_MM

◆ globalEndLuminosityBlock()

void CTPPSDiamondDQMSource::globalEndLuminosityBlock ( const edm::LuminosityBlock iLumi,
const edm::EventSetup  
)
overrideprotected

Definition at line 1283 of file CTPPSDiamondDQMSource.cc.

References CTPPSDetId::arm(), CTPPSDiamondDetId::channel(), channelPlots_, L1TObjectsTimingClient_cff::efficiency, edm::LuminosityBlock::index(), perLSsaving_, CTPPSDiamondDetId::plane(), planePlots_, plotFactory::plot, plotOnline_, potPlots_, CTPPSDetId::rp(), SEC_PER_LUMI_SECTION, and dqmMemoryStats::total.

1283  {
1284  auto lumiCache = luminosityBlockCache(iLumi.index());
1285  if (!perLSsaving_) {
1286  if (plotOnline_)
1287  for (auto& plot : potPlots_)
1288  *(plot.second.hitDistribution2d_lumisection->getTH2F()) = *(lumiCache->hitDistribution2dMap[plot.first]);
1289 
1290  for (auto& plot : channelPlots_) {
1291  auto hitsCounterPerLumisection = lumiCache->hitsCounterMap[plot.first];
1292  if (hitsCounterPerLumisection != 0) {
1293  plot.second.hit_rate->Fill((double)hitsCounterPerLumisection / SEC_PER_LUMI_SECTION);
1294  }
1295 
1296  double HundredOverHitCounter = .0;
1297  if (plot.second.HitCounter != 0)
1298  HundredOverHitCounter = 100. / plot.second.HitCounter;
1299  plot.second.HPTDCErrorFlags->setBinContent(16, HundredOverHitCounter * plot.second.MHCounter);
1300  plot.second.leadingWithoutTrailing->setBinContent(1, HundredOverHitCounter * plot.second.LeadingOnlyCounter);
1301  plot.second.leadingWithoutTrailing->setBinContent(2, HundredOverHitCounter * plot.second.TrailingOnlyCounter);
1302  plot.second.leadingWithoutTrailing->setBinContent(3, HundredOverHitCounter * plot.second.CompleteCounter);
1303  }
1304 
1305  for (auto& plot : potPlots_) {
1306  double HundredOverHitCounterPot = 0.;
1307  if (plot.second.HitCounter != 0)
1308  HundredOverHitCounterPot = 100. / plot.second.HitCounter;
1309  plot.second.leadingWithoutTrailingCumulativePot->setBinContent(
1310  1, HundredOverHitCounterPot * plot.second.LeadingOnlyCounter);
1311  plot.second.leadingWithoutTrailingCumulativePot->setBinContent(
1312  2, HundredOverHitCounterPot * plot.second.TrailingOnlyCounter);
1313  plot.second.leadingWithoutTrailingCumulativePot->setBinContent(
1314  3, HundredOverHitCounterPot * plot.second.CompleteCounter);
1315 
1316  plot.second.MHComprensive->Reset();
1317  const CTPPSDiamondDetId rpId(plot.first);
1318  for (auto& chPlot : channelPlots_) {
1319  const CTPPSDiamondDetId chId(chPlot.first);
1320  if (chId.arm() == rpId.arm() && chId.rp() == rpId.rp()) {
1321  plot.second.MHComprensive->Fill(
1322  chId.plane(), chId.channel(), chPlot.second.HPTDCErrorFlags->getBinContent(16));
1323  }
1324  }
1325  }
1326  // Efficiencies of single channels
1327  if (plotOnline_)
1328  for (auto& plot : potPlots_) {
1329  plot.second.EfficiencyOfChannelsInPot->Reset();
1330  for (auto& element : plot.second.effTriplecountingChMap) {
1331  if (plot.second.effDoublecountingChMap[element.first] > 0) {
1332  int plane = element.first / 100;
1333  int channel = element.first % 100;
1334  double counted = element.second;
1335  double total = plot.second.effDoublecountingChMap[element.first];
1336  double efficiency = counted / total;
1337  // double error = std::sqrt( efficiency * ( 1 - efficiency ) / total );
1338 
1339  plot.second.EfficiencyOfChannelsInPot->Fill(plane, channel, 100 * efficiency);
1340  }
1341  }
1342  }
1343 
1344  // Efficeincy wrt pixels //TODO
1345  for (auto& plot : planePlots_) {
1346  TH2F* hitHistoTmp = plot.second.EfficiencyWRTPixelsInPlane->getTH2F();
1347 
1348  const CTPPSDiamondDetId detId(plot.first), detId_pot(detId.rpId());
1349  hitHistoTmp->Divide(&(plot.second.pixelTracksMapWithDiamonds), &(potPlots_[detId_pot].pixelTracksMap));
1350  }
1351  } //perLSsaving
1352 }
static constexpr double SEC_PER_LUMI_SECTION
Number of seconds per lumisection: used to compute hit rates in Hz.
std::unordered_map< unsigned int, ChannelPlots > channelPlots_
std::unordered_map< unsigned int, PotPlots > potPlots_
LuminosityBlockIndex index() const
Detector ID class for CTPPS Timing Diamond detectors. Bits [19:31] : Assigend in CTPPSDetId Calss Bit...
std::unordered_map< unsigned int, PlanePlots > planePlots_

Member Data Documentation

◆ centralOOT_

int CTPPSDiamondDQMSource::centralOOT_
private

Definition at line 233 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and dqmBeginRun().

◆ CHANNEL_OF_VFAT_CLOCK

constexpr unsigned short CTPPSDiamondDQMSource::CHANNEL_OF_VFAT_CLOCK = 30
staticprivate

Channel ID of the VFAT that contains clock data.

Definition at line 90 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ channelPlots_

std::unordered_map<unsigned int, ChannelPlots> CTPPSDiamondDQMSource::channelPlots_
private

Definition at line 244 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), bookHistograms(), and globalEndLuminosityBlock().

◆ CTPPS_DIAMOND_NUM_OF_CHANNELS

constexpr unsigned short CTPPSDiamondDQMSource::CTPPS_DIAMOND_NUM_OF_CHANNELS = 12
staticprivate

◆ CTPPS_FAR_RP_ID

constexpr unsigned short CTPPSDiamondDQMSource::CTPPS_FAR_RP_ID = 3
staticprivate

Definition at line 97 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and dqmBeginRun().

◆ CTPPS_FED_ID_45

constexpr unsigned short CTPPSDiamondDQMSource::CTPPS_FED_ID_45 = 583
staticprivate

Definition at line 99 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ CTPPS_FED_ID_56

constexpr unsigned short CTPPSDiamondDQMSource::CTPPS_FED_ID_56 = 582
staticprivate

Definition at line 100 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ CTPPS_PIXEL_STATION_ID

constexpr unsigned short CTPPSDiamondDQMSource::CTPPS_PIXEL_STATION_ID = 2
staticprivate

Definition at line 96 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and dqmBeginRun().

◆ ctppsGeometryEventToken_

edm::ESGetToken<CTPPSGeometry, VeryForwardRealGeometryRecord> CTPPSDiamondDQMSource::ctppsGeometryEventToken_
private

Definition at line 223 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ ctppsGeometryRunToken_

edm::ESGetToken<CTPPSGeometry, VeryForwardRealGeometryRecord> CTPPSDiamondDQMSource::ctppsGeometryRunToken_
private

Definition at line 222 of file CTPPSDiamondDQMSource.cc.

Referenced by bookHistograms(), and dqmBeginRun().

◆ diamShifts_

std::unordered_map<CTPPSDetId, DiamondShifts> CTPPSDiamondDQMSource::diamShifts_
private

Definition at line 231 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and dqmBeginRun().

◆ DISPLAY_RESOLUTION_FOR_HITS_MM

constexpr double CTPPSDiamondDQMSource::DISPLAY_RESOLUTION_FOR_HITS_MM = 0.1
staticprivate

Bin width of histograms showing hits and tracks (in mm)

Definition at line 92 of file CTPPSDiamondDQMSource.cc.

◆ EC_difference_45_

int CTPPSDiamondDQMSource::EC_difference_45_
private

Definition at line 246 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ EC_difference_56_

int CTPPSDiamondDQMSource::EC_difference_56_
private

Definition at line 246 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ excludeMultipleHits_

bool CTPPSDiamondDQMSource::excludeMultipleHits_
private

Definition at line 226 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ extract_digi_info_

const bool CTPPSDiamondDQMSource::extract_digi_info_
private

Definition at line 227 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and CTPPSDiamondDQMSource().

◆ FIRST_RUN_W_PIXELS

constexpr unsigned int CTPPSDiamondDQMSource::FIRST_RUN_W_PIXELS = 300000
staticprivate

Number of OOT indices monitored.

Definition at line 104 of file CTPPSDiamondDQMSource.cc.

Referenced by dqmBeginRun().

◆ globalPlot_

GlobalPlots CTPPSDiamondDQMSource::globalPlot_
private

Definition at line 240 of file CTPPSDiamondDQMSource.cc.

Referenced by bookHistograms().

◆ HPTDC_0_CHANNEL

constexpr unsigned short CTPPSDiamondDQMSource::HPTDC_0_CHANNEL = 6
staticprivate

Definition at line 101 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and checkEventNumber().

◆ HPTDC_1_CHANNEL

constexpr unsigned short CTPPSDiamondDQMSource::HPTDC_1_CHANNEL = 7
staticprivate

Definition at line 102 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and checkEventNumber().

◆ HPTDC_BIN_WIDTH_NS

constexpr double CTPPSDiamondDQMSource::HPTDC_BIN_WIDTH_NS = 25. / 1024
staticprivate

ns per HPTDC bin

Definition at line 95 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ INV_DISPLAY_RESOLUTION_FOR_HITS_MM

constexpr double CTPPSDiamondDQMSource::INV_DISPLAY_RESOLUTION_FOR_HITS_MM = 1. / DISPLAY_RESOLUTION_FOR_HITS_MM
staticprivate

◆ perLSsaving_

bool CTPPSDiamondDQMSource::perLSsaving_
private

◆ planePlots_

std::unordered_map<unsigned int, PlanePlots> CTPPSDiamondDQMSource::planePlots_
private

Definition at line 243 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), bookHistograms(), and globalEndLuminosityBlock().

◆ plotOffline_

const bool CTPPSDiamondDQMSource::plotOffline_
private

Definition at line 236 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

◆ plotOnline_

const bool CTPPSDiamondDQMSource::plotOnline_
private

◆ potPlots_

std::unordered_map<unsigned int, PotPlots> CTPPSDiamondDQMSource::potPlots_
private

◆ runParameters_

std::vector<std::pair<edm::EventRange, int> > CTPPSDiamondDQMSource::runParameters_
private

Definition at line 232 of file CTPPSDiamondDQMSource.cc.

Referenced by CTPPSDiamondDQMSource(), and dqmBeginRun().

◆ SEC_PER_LUMI_SECTION

constexpr double CTPPSDiamondDQMSource::SEC_PER_LUMI_SECTION = 23.31
staticprivate

Number of seconds per lumisection: used to compute hit rates in Hz.

Definition at line 88 of file CTPPSDiamondDQMSource.cc.

Referenced by globalEndLuminosityBlock().

◆ sectorPlots_

std::unordered_map<unsigned int, SectorPlots> CTPPSDiamondDQMSource::sectorPlots_
private

Definition at line 242 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and bookHistograms().

◆ tokenDiamondHit_

edm::EDGetTokenT<edm::DetSetVector<CTPPSDiamondRecHit> > CTPPSDiamondDQMSource::tokenDiamondHit_
private

Definition at line 218 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ tokenDiamondTrack_

edm::EDGetTokenT<edm::DetSetVector<CTPPSDiamondLocalTrack> > CTPPSDiamondDQMSource::tokenDiamondTrack_
private

Definition at line 219 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ tokenDigi_

edm::EDGetTokenT<edm::DetSetVector<CTPPSDiamondDigi> > CTPPSDiamondDQMSource::tokenDigi_
private

Definition at line 217 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and CTPPSDiamondDQMSource().

◆ tokenFEDInfo_

edm::EDGetTokenT<std::vector<TotemFEDInfo> > CTPPSDiamondDQMSource::tokenFEDInfo_
private

Definition at line 220 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and CTPPSDiamondDQMSource().

◆ tokenPixelTrack_

edm::EDGetTokenT<edm::DetSetVector<CTPPSPixelLocalTrack> > CTPPSDiamondDQMSource::tokenPixelTrack_
private

Definition at line 216 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ tokenStatus_

edm::EDGetTokenT<edm::DetSetVector<TotemVFATStatus> > CTPPSDiamondDQMSource::tokenStatus_
private

Definition at line 215 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and CTPPSDiamondDQMSource().

◆ trackCorrelationThreshold_

unsigned int CTPPSDiamondDQMSource::trackCorrelationThreshold_
private

Definition at line 238 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze().

◆ verbosity_

unsigned int CTPPSDiamondDQMSource::verbosity_
private

Definition at line 234 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and checkEventNumber().

◆ windowsNum_

unsigned int CTPPSDiamondDQMSource::windowsNum_
private

Definition at line 237 of file CTPPSDiamondDQMSource.cc.

Referenced by analyze(), and bookHistograms().