当前位置: 首页>>代码示例>>C++>>正文


C++ Event::luminosityBlock方法代码示例

本文整理汇总了C++中edm::Event::luminosityBlock方法的典型用法代码示例。如果您正苦于以下问题:C++ Event::luminosityBlock方法的具体用法?C++ Event::luminosityBlock怎么用?C++ Event::luminosityBlock使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在edm::Event的用法示例。


在下文中一共展示了Event::luminosityBlock方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: GetEvtId

void ChPartTree::GetEvtId(const edm::Event& iEvent)
{
   using namespace std;

   if ( EvtIdDebug )
   {
     cout << "XJ: EvdId: " << iEvent.id() << endl ;
     cout << "XJ: Run  : " << iEvent.id().run() << endl ;
     cout << "XJ: Evt  : " << iEvent.id().event() << endl ;
     cout << "XJ: Lumbl: " << iEvent.luminosityBlock() << endl ;
//   cout << "XJ: proID: " << iEvent.processHistoryID() << endl;
//   cout << "XJ: GUID : " << iEvent.processGUID() << endl;
     edm::Timestamp Time=iEvent.time();
     cout << "XJ: time : " << Time.value() << endl;
     cout << "XJ: isDa : " << iEvent.isRealData() << endl;
     cout << "XJ: expTy: " << iEvent.experimentType() << endl ;
     cout << "XJ: Bx   : " << iEvent.bunchCrossing() << endl;
     cout << "XJ: Orbit: " << iEvent.orbitNumber() << endl;
//   cout << "XJ: Store: " << iEvent.storeNumber() << endl; 
   }

   EvtId.Reset();

   EvtId.Run       = iEvent.id().run() ;   
   EvtId.Evt       = iEvent.id().event() ;
   EvtId.LumiSect  = iEvent.luminosityBlock();
   edm::Timestamp Time=iEvent.time();
   EvtId.Time      = Time.value(); 
   EvtId.IsData    = iEvent.isRealData();
   EvtId.ExpType   = iEvent.experimentType();
   EvtId.Bunch     = iEvent.bunchCrossing();
   EvtId.Orbit     = iEvent.orbitNumber();

}
开发者ID:UAEDF,项目名称:UAmulti,代码行数:34,代码来源:GetEvtId.C

示例2: analyze

int NeroAll::analyze(const edm::Event&iEvent)
{
    if(isMc_ <0 )
    {
        isMc_ = ( iEvent.isRealData() ) ? 0 : 1;
        isRealData = ( iEvent.isRealData() ) ? 1 : 0;
    }
    if( isSkim() == 0) 
    {
        //TODO FILL all_
        isRealData = ( iEvent.isRealData() ) ? 1 : 0;	
        runNum = iEvent.id().run();
        lumiNum = iEvent.luminosityBlock(); 	
        eventNum = iEvent.id().event();  
        iEvent.getByLabel(edm::InputTag("generator"), info_handle); // USE TOKEN AND INPUT TAG ?
        iEvent.getByLabel(edm::InputTag("addPileupInfo"), pu_handle);
        mcWeight = info_handle->weight();
        //PU
        puTrueInt = 0;
        for(const auto & pu : *pu_handle)
        {
            //Intime
            if (pu.getBunchCrossing() == 0)
                puTrueInt += pu.getTrueNumInteractions();
            //Out-of-time
        }
    }
    return 0;
}
开发者ID:jsalfeld,项目名称:NeroProducer,代码行数:29,代码来源:NeroAll.cpp

示例3: if

EventInfo::EventInfo(const edm::Event& iEvent, const edm::Handle<reco::BeamSpot>& beamSpot, const edm::Handle<HcalNoiseSummary>& hcalNoiseSummary, const edm::Handle< std::vector<PileupSummaryInfo> >& puSummaryInfo, bool firstVertexIsGood_, float rho_):firstVertexIsGood(firstVertexIsGood_),rho(rho_)
{
  
  evt         = iEvent.id().event();
  run         = iEvent.id().run();
  lumiBlock   = iEvent.luminosityBlock();
  
  BSx = beamSpot->x0();
  BSy = beamSpot->y0();
  BSz = beamSpot->z0();
  
 
  if( hcalNoiseSummary.isValid() ){
    hcalnoiseLoose = hcalNoiseSummary->passLooseNoiseFilter();
    hcalnoiseTight = hcalNoiseSummary->passTightNoiseFilter();
  }
  
  if( puSummaryInfo.isValid() ){
    for(std::vector<PileupSummaryInfo>::const_iterator PVI = puSummaryInfo->begin(); PVI != puSummaryInfo->end(); ++PVI) {

      int BX = PVI->getBunchCrossing();

      sumNVtx  += float(PVI->getPU_NumInteractions());
      sumTrueNVtx += float(PVI->getTrueNumInteractions());

      if( BX==0 ){
	      numGenPV = PVI->getPU_NumInteractions();
	      numTruePV = PVI->getTrueNumInteractions();
      }

      if(BX == -1) { 
	      nm1 = PVI->getPU_NumInteractions();
	      nm1_true = PVI->getTrueNumInteractions();
      }
      else if(BX == 0) { 
	      n0 = PVI->getPU_NumInteractions();
	      n0_true = PVI->getTrueNumInteractions();
      }
      else if(BX == 1) { 
	      np1 = PVI->getPU_NumInteractions();
	      np1_true = PVI->getTrueNumInteractions();
      }
    }
  }
    
  
}
开发者ID:okkuntze,项目名称:BoostedTTH,代码行数:47,代码来源:EventInfo.cpp


注:本文中的edm::Event::luminosityBlock方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。