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


C++ HiForest::GetJetByAlgo方法代码示例

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


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

示例1: IndResponse


//.........这里部分代码省略.........
    //! testing
    //if(hiBin>4 && strcmp(ksp,"pbpb")==0)continue;

    //! apply vertex cut
    if(fabs(vz)>kVzcut)continue;


    //! Centrality bin
    if(hiBin<0 || hiBin>39)continue;
    int centb=-1;
    double wcen=1;
    double wvz=fVz->Eval(vz);
    if(strcmp(ksp,"pbpb")==0){
      centb=GetCentBin(hiBin);
      wcen = fcen->Eval(hiBin);
    }else{
      centb=ncen-1; //! pp
      wcen=1;
    }

    if(ievt%10000==0)std::cout<<" ********** Event # " <<ievt<<std::endl;
    //std::cout<<" ********** Event # " <<ievt<<"\t vz : "<<vz<<"\t hiBin : "<<hiBin<<"\t wxs : "<<wxs<<std::endl;


    //! Centrality from 0-90% 
    if(centb==-1 || centb==ncen)continue;


    int istat=0;
    for(int nj=0;nj<knj;nj++){ //! loop over different jet algorithms
      
      //! Get the jet object
      //iJet = c->GetJet(nj);
      iJet = c->GetJetByAlgo(cjets[nj]);
      
      //! xsec-weight
      double pthat = iJet->pthat;
      if(pthat > maxpthat)continue;
      istat=1;
      
      //std::cout<<"\t Jet Algorithm : "<<c->GetCjets[Nj](nj)<<"\t # of Jets  : "<<iJet->nref<<"\t pthat : "<<pthat<<std::endl;
      if(nj==0)hTotEve->Fill(1); //! akPu3PF      

      float njets=0.;
      float meanpt=0.;

      int *ljet = new int[2];
      FindLeadSubLeadJets(iJet,ljet);
      if(ljet[0]>=0){
	hratiocorrrefpt_lead[nj][centb]->Fill(iJet->refpt[ljet[0]],iJet->jtpt[ljet[0]]/iJet->refpt[ljet[0]],wxs*wcen*wvz);
      }
      if(ljet[1]>=0){
	hratiocorrrefpt_slead[nj][centb]->Fill(iJet->refpt[ljet[1]],iJet->jtpt[ljet[1]]/iJet->refpt[ljet[1]],wxs*wcen*wvz);
      }

      if(nj>3){
	//! Gen matched jets
	for(int igen=0; igen<iJet->ngen; igen++){
	  if( iJet->gensubid[igen] != 0) continue;
	  int gj = iJet->genmatchindex[igen];
	  
	  float refpt   = iJet->refpt[gj];
	  float recopt  = iJet->jtpt[gj];
	  float recoeta = iJet->jteta[gj];
	  float delr    = iJet->refdrjt[gj];
	  
开发者ID:pawannetrakanti,项目名称:pawan,代码行数:66,代码来源:IndResponse.C


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