CMS 3D CMS Logo

Namespaces | Classes | Typedefs | Enumerations | Functions
HTXS Namespace Reference

Higgs Template Cross Section namespace. More...

Namespaces

 Stage0
 Namespace for Stage0 categorization.
 
 Stage1
 
 Stage1_1
 
 Stage1_1_Fine
 
 Stage1_2
 
 Stage1_2_Fine
 

Classes

struct  HiggsClassification
 

Typedefs

typedef math::XYZTLorentzVectorD TLV
 
typedef std::vector< TLVTLVs
 

Enumerations

enum  ErrorCode {
  UNDEFINED = -99, SUCCESS = 0, PRODMODE_DEFINED = 1, MOMENTUM_CONSERVATION = 2,
  HIGGS_IDENTIFICATION = 3, HIGGS_DECAY_IDENTIFICATION = 4, HS_VTX_IDENTIFICATION = 5, VH_IDENTIFICATION = 6,
  VH_DECAY_IDENTIFICATION = 7, TOP_W_IDENTIFICATION = 8
}
 Error code: whether the classification was successful or failed. More...
 
enum  HiggsProdMode {
  UNKNOWN = 0, GGF = 1, VBF = 2, WH = 3,
  QQ2ZH = 4, GG2ZH = 5, TTH = 6, BBH = 7,
  TH = 8
}
 Higgs production modes, corresponding to input sample. More...
 
enum  tH_type { noTH = 0, THQB = 1, TWH = 2 }
 Additional identifier flag for TH production modes. More...
 

Functions

int HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex (HTXS::Stage1_2_Fine::Category Stage1_2_Fine, HiggsProdMode prodMode, tH_type tH)
 
int HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex (const HiggsClassification &stxs, tH_type tH=noTH, bool jets_pT25=false)
 
int HTXSstage1_2_Fine_to_index (HTXS::Stage1_2_Fine::Category Stage1_2_Fine)
 
int HTXSstage1_2_to_HTXSstage1_2_FineIndex (HTXS::Stage1_2::Category stage1_2, HiggsProdMode prodMode, tH_type tH)
 
int HTXSstage1_2_to_HTXSstage1_2_FineIndex (const HiggsClassification &stxs, tH_type tH=noTH, bool jets_pT25=false)
 
int HTXSstage1_2_to_index (HTXS::Stage1_2::Category stage1_2)
 
int HTXSstage1_to_HTXSstage1FineIndex (HTXS::Stage1::Category stage1, HiggsProdMode prodMode, tH_type tH)
 
int HTXSstage1_to_HTXSstage1FineIndex (const HiggsClassification &stxs, tH_type tH=noTH, bool jets_pT25=false)
 
int HTXSstage1_to_index (HTXS::Stage1::Category stage1)
 
template<class vec4 >
TLV MakeTLV (vec4 const p)
 
template<class Vvec4 >
TLVs MakeTLVs (Vvec4 const &rivet_jets)
 
template<class category >
HTXS::HiggsClassification Rivet2Root (category const &htxs_cat_rivet)
 

Detailed Description

Higgs Template Cross Section namespace.

Typedef Documentation

◆ TLV

Definition at line 495 of file HiggsTemplateCrossSections.h.

◆ TLVs

typedef std::vector<TLV> HTXS::TLVs

Definition at line 496 of file HiggsTemplateCrossSections.h.

Enumeration Type Documentation

◆ ErrorCode

Error code: whether the classification was successful or failed.

Enumerator
UNDEFINED 
SUCCESS 

successful classification

PRODMODE_DEFINED 

production mode not defined

MOMENTUM_CONSERVATION 

failed momentum conservation

HIGGS_IDENTIFICATION 

failed to identify Higgs boson

HIGGS_DECAY_IDENTIFICATION 

failed to identify Higgs boson decay products

HS_VTX_IDENTIFICATION 

failed to identify hard scatter vertex

VH_IDENTIFICATION 

failed to identify associated vector boson

VH_DECAY_IDENTIFICATION 

failed to identify associated vector boson decay products

TOP_W_IDENTIFICATION 

failed to identify top decay

Definition at line 11 of file HiggsTemplateCrossSections.h.

11  {
12  UNDEFINED = -99,
13  SUCCESS = 0,
14  PRODMODE_DEFINED = 1,
19  VH_IDENTIFICATION = 6,
22  };
failed to identify associated vector boson
successful classification
failed to identify Higgs boson decay products
failed momentum conservation
failed to identify associated vector boson decay products
failed to identify Higgs boson
failed to identify hard scatter vertex
production mode not defined
failed to identify top decay

◆ HiggsProdMode

Higgs production modes, corresponding to input sample.

Enumerator
UNKNOWN 
GGF 
VBF 
WH 
QQ2ZH 
GG2ZH 
TTH 
BBH 
TH 

Definition at line 25 of file HiggsTemplateCrossSections.h.

◆ tH_type

Additional identifier flag for TH production modes.

Enumerator
noTH 
THQB 
TWH 

Definition at line 28 of file HiggsTemplateCrossSections.h.

Function Documentation

◆ HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex() [1/2]

int HTXS::HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex ( HTXS::Stage1_2_Fine::Category  Stage1_2_Fine,
HiggsProdMode  prodMode,
tH_type  tH 
)
inline

Definition at line 669 of file HiggsTemplateCrossSections.h.

References F(), GG2ZH, createfilelist::int, noTH, TH, and UNKNOWN.

Referenced by HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex().

671  {
672  if (Stage1_2_Fine == HTXS::Stage1_2_Fine::Category::UNKNOWN)
673  return 0;
674  int P = (int)(Stage1_2_Fine / 100);
675  int F = (int)(Stage1_2_Fine % 100);
676  // 1.a spit tH categories
677  if (prodMode == HiggsProdMode::TH) {
678  // check that tH splitting is valid for Stage-1 FineIndex
679  // else return unknown category
680  if (tH == tH_type::noTH)
681  return 0;
682  // check if forward tH
683  int fwdH = F == 0 ? 0 : 1;
684  return (189 + 2 * (tH - 1) + fwdH);
685  }
686  // 1.b QQ2HQQ --> split into VBF, WH, ZH -> HQQ
687  // offset vector 1: input is the Higgs prodMode
688  // first two indicies are dummies, given that this is only called for prodMode=2,3,4
689  std::vector<int> pMode_offset = {0, 0, 57, 82, 107};
690  if (P == 2)
691  return (F + pMode_offset[prodMode]);
692  // 1.c GG2ZH split into gg->ZH-had and gg->ZH-lep
693  if (prodMode == HiggsProdMode::GG2ZH && P == 1)
694  return F + 29;
695  // 1.d remaining categories
696  // offset vector 2: input is the Stage-1 category P
697  // third index is dummy, given that this is called for category P=0,1,3,4,5,6,7
698  std::vector<int> catP_offset = {0, 1, 0, 132, 148, 164, 180, 187};
699  return (F + catP_offset[P]);
700  }
std::pair< OmniClusterRef, TrackingParticleRef > P
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163

◆ HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex() [2/2]

int HTXS::HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex ( const HiggsClassification stxs,
tH_type  tH = noTH,
bool  jets_pT25 = false 
)
inline

Definition at line 702 of file HiggsTemplateCrossSections.h.

References HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex(), HTXS::HiggsClassification::prodMode, HTXS::HiggsClassification::stage1_2_fine_cat_pTjet25GeV, and HTXS::HiggsClassification::stage1_2_fine_cat_pTjet30GeV.

704  {
705  HTXS::Stage1_2_Fine::Category Stage1_2_Fine =
706  jets_pT25 == false ? stxs.stage1_2_fine_cat_pTjet30GeV : stxs.stage1_2_fine_cat_pTjet25GeV;
707  return HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex(Stage1_2_Fine, stxs.prodMode, tH);
708  }
int HTXSstage1_2_Fine_to_HTXSstage1_2_Fine_FineIndex(const HiggsClassification &stxs, tH_type tH=noTH, bool jets_pT25=false)

◆ HTXSstage1_2_Fine_to_index()

int HTXS::HTXSstage1_2_Fine_to_index ( HTXS::Stage1_2_Fine::Category  Stage1_2_Fine)
inline

Definition at line 710 of file HiggsTemplateCrossSections.h.

References F(), createfilelist::int, and hltrates_dqm_sourceclient-live_cfg::offset.

710  {
711  // the Stage-1_2_Fine categories
712  int P = (int)(Stage1_2_Fine / 100);
713  int F = (int)(Stage1_2_Fine % 100);
714  std::vector<int> offset{0, 1, 29, 54, 70, 86, 102, 109, 111, 113};
715  // convert to linear values
716  return (F + offset[P]);
717  }
std::pair< OmniClusterRef, TrackingParticleRef > P
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163

◆ HTXSstage1_2_to_HTXSstage1_2_FineIndex() [1/2]

int HTXS::HTXSstage1_2_to_HTXSstage1_2_FineIndex ( HTXS::Stage1_2::Category  stage1_2,
HiggsProdMode  prodMode,
tH_type  tH 
)
inline

Definition at line 617 of file HiggsTemplateCrossSections.h.

References F(), GG2ZH, createfilelist::int, noTH, TH, and UNKNOWN.

Referenced by HTXSstage1_2_to_HTXSstage1_2_FineIndex().

619  {
620  if (stage1_2 == HTXS::Stage1_2::Category::UNKNOWN)
621  return 0;
622  int P = (int)(stage1_2 / 100);
623  int F = (int)(stage1_2 % 100);
624  // 1.a spit tH categories
625  if (prodMode == HiggsProdMode::TH) {
626  // check that tH splitting is valid for Stage-1 FineIndex
627  // else return unknown category
628  if (tH == tH_type::noTH)
629  return 0;
630  // check if forward tH
631  int fwdH = F == 0 ? 0 : 1;
632  return (94 + 2 * (tH - 1) + fwdH);
633  }
634  // 1.b QQ2HQQ --> split into VBF, WH, ZH -> HQQ
635  // offset vector 1: input is the Higgs prodMode
636  // first two indicies are dummies, given that this is only called for prodMode=2,3,4
637  std::vector<int> pMode_offset = {0, 0, 35, 46, 57};
638  if (P == 2)
639  return (F + pMode_offset[prodMode]);
640  // 1.c GG2ZH split into gg->ZH-had and gg->ZH-lep
641  if (prodMode == HiggsProdMode::GG2ZH && P == 1)
642  return F + 18;
643  // 1.d remaining categories
644  // offset vector 2: input is the Stage-1 category P
645  // third index is dummy, given that this is called for category P=0,1,3,4,5,6,7
646  std::vector<int> catP_offset = {0, 1, 0, 68, 74, 80, 86, 92};
647  return (F + catP_offset[P]);
648  }
std::pair< OmniClusterRef, TrackingParticleRef > P
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163

◆ HTXSstage1_2_to_HTXSstage1_2_FineIndex() [2/2]

int HTXS::HTXSstage1_2_to_HTXSstage1_2_FineIndex ( const HiggsClassification stxs,
tH_type  tH = noTH,
bool  jets_pT25 = false 
)
inline

Definition at line 650 of file HiggsTemplateCrossSections.h.

References HTXSstage1_2_to_HTXSstage1_2_FineIndex(), HTXS::HiggsClassification::prodMode, HTXS::HiggsClassification::stage1_2_cat_pTjet25GeV, and HTXS::HiggsClassification::stage1_2_cat_pTjet30GeV.

652  {
653  HTXS::Stage1_2::Category stage1_2 =
654  jets_pT25 == false ? stxs.stage1_2_cat_pTjet30GeV : stxs.stage1_2_cat_pTjet25GeV;
655  return HTXSstage1_2_to_HTXSstage1_2_FineIndex(stage1_2, stxs.prodMode, tH);
656  }
int HTXSstage1_2_to_HTXSstage1_2_FineIndex(const HiggsClassification &stxs, tH_type tH=noTH, bool jets_pT25=false)

◆ HTXSstage1_2_to_index()

int HTXS::HTXSstage1_2_to_index ( HTXS::Stage1_2::Category  stage1_2)
inline

Definition at line 658 of file HiggsTemplateCrossSections.h.

References F(), createfilelist::int, and hltrates_dqm_sourceclient-live_cfg::offset.

658  {
659  // the Stage-1 categories
660  int P = (int)(stage1_2 / 100);
661  int F = (int)(stage1_2 % 100);
662  //std::vector<int> offset{0,1,13,19,24,29,33,35,37,39};
663  std::vector<int> offset{0, 1, 18, 29, 35, 41, 47, 53, 55, 57};
664  // convert to linear values
665  return (F + offset[P]);
666  }
std::pair< OmniClusterRef, TrackingParticleRef > P
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163

◆ HTXSstage1_to_HTXSstage1FineIndex() [1/2]

int HTXS::HTXSstage1_to_HTXSstage1FineIndex ( HTXS::Stage1::Category  stage1,
HiggsProdMode  prodMode,
tH_type  tH 
)
inline

Definition at line 573 of file HiggsTemplateCrossSections.h.

References F(), createfilelist::int, noTH, TH, and UNKNOWN.

Referenced by HTXSstage1_to_HTXSstage1FineIndex().

573  {
574  if (stage1 == HTXS::Stage1::Category::UNKNOWN)
575  return 0;
576  int P = (int)(stage1 / 100);
577  int F = (int)(stage1 % 100);
578  // 1.a spit tH categories
579  if (prodMode == HiggsProdMode::TH) {
580  // check that tH splitting is valid for Stage-1 FineIndex
581  // else return unknown category
582  if (tH == tH_type::noTH)
583  return 0;
584  // check if forward tH
585  int fwdH = F == 0 ? 0 : 1;
586  return (49 + 2 * (tH - 1) + fwdH);
587  }
588  // 1.b QQ2HQQ --> split into VBF, WH, ZH -> HQQ
589  // offset vector 1: input is the Higgs prodMode
590  // first two indicies are dummies, given that this is only called for prodMode=2,3,4
591  std::vector<int> pMode_offset = {0, 0, 13, 19, 25};
592  if (P == 2)
593  return (F + pMode_offset[prodMode]);
594  // 1.c remaining categories
595  // offset vector 2: input is the Stage-1 category P
596  // third index is dummy, given that this is called for category P=0,1,3,4,5,6,7
597  std::vector<int> catP_offset = {0, 1, 0, 31, 36, 41, 45, 47};
598  return (F + catP_offset[P]);
599  }
std::pair< OmniClusterRef, TrackingParticleRef > P
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163

◆ HTXSstage1_to_HTXSstage1FineIndex() [2/2]

int HTXS::HTXSstage1_to_HTXSstage1FineIndex ( const HiggsClassification stxs,
tH_type  tH = noTH,
bool  jets_pT25 = false 
)
inline

Definition at line 601 of file HiggsTemplateCrossSections.h.

References HTXSstage1_to_HTXSstage1FineIndex(), HTXS::HiggsClassification::prodMode, HTXS::HiggsClassification::stage1_cat_pTjet25GeV, and HTXS::HiggsClassification::stage1_cat_pTjet30GeV.

603  {
604  HTXS::Stage1::Category stage1 = jets_pT25 == false ? stxs.stage1_cat_pTjet30GeV : stxs.stage1_cat_pTjet25GeV;
605  return HTXSstage1_to_HTXSstage1FineIndex(stage1, stxs.prodMode, tH);
606  }
int HTXSstage1_to_HTXSstage1FineIndex(const HiggsClassification &stxs, tH_type tH=noTH, bool jets_pT25=false)

◆ HTXSstage1_to_index()

int HTXS::HTXSstage1_to_index ( HTXS::Stage1::Category  stage1)
inline

Definition at line 608 of file HiggsTemplateCrossSections.h.

References F(), createfilelist::int, and hltrates_dqm_sourceclient-live_cfg::offset.

608  {
609  // the Stage-1 categories
610  int P = (int)(stage1 / 100);
611  int F = (int)(stage1 % 100);
612  std::vector<int> offset{0, 1, 13, 19, 24, 29, 33, 35, 37, 39};
613  // convert to linear values
614  return (F + offset[P]);
615  }
std::pair< OmniClusterRef, TrackingParticleRef > P
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163

◆ MakeTLV()

template<class vec4 >
TLV HTXS::MakeTLV ( vec4 const  p)

Definition at line 499 of file HiggsTemplateCrossSections.h.

References AlCaHLTBitMon_ParallelJobs::p.

Referenced by MakeTLVs(), and Rivet2Root().

499  {
500  return TLV(p.px(), p.py(), p.pz(), p.E());
501  }
math::XYZTLorentzVectorD TLV

◆ MakeTLVs()

template<class Vvec4 >
TLVs HTXS::MakeTLVs ( Vvec4 const &  rivet_jets)
inline

Definition at line 504 of file HiggsTemplateCrossSections.h.

References metsig::jet, PDWG_EXODelayedJetMET_cff::jets, and MakeTLV().

Referenced by Rivet2Root().

504  {
505  TLVs jets;
506  for (const auto &jet : rivet_jets)
507  jets.push_back(MakeTLV(jet));
508  return jets;
509  }
std::vector< TLV > TLVs
TLV MakeTLV(vec4 const p)

◆ Rivet2Root()

template<class category >
HTXS::HiggsClassification HTXS::Rivet2Root ( category const &  htxs_cat_rivet)
inline

Definition at line 548 of file HiggsTemplateCrossSections.h.

References eostools::cat(), MakeTLV(), and MakeTLVs().

Referenced by HTXSRivetProducer::produce().

548  {
550  cat.prodMode = htxs_cat_rivet.prodMode;
551  cat.errorCode = htxs_cat_rivet.errorCode;
552  cat.higgs = MakeTLV(htxs_cat_rivet.higgs);
553  cat.V = MakeTLV(htxs_cat_rivet.V);
554  cat.p4decay_higgs = MakeTLV(htxs_cat_rivet.p4decay_higgs);
555  cat.p4decay_V = MakeTLV(htxs_cat_rivet.p4decay_V);
556  cat.jets25 = MakeTLVs(htxs_cat_rivet.jets25);
557  cat.jets30 = MakeTLVs(htxs_cat_rivet.jets30);
558  cat.stage0_cat = htxs_cat_rivet.stage0_cat;
559  cat.stage1_cat_pTjet25GeV = htxs_cat_rivet.stage1_cat_pTjet25GeV;
560  cat.stage1_cat_pTjet30GeV = htxs_cat_rivet.stage1_cat_pTjet30GeV;
561  cat.stage1_1_cat_pTjet25GeV = htxs_cat_rivet.stage1_1_cat_pTjet25GeV;
562  cat.stage1_1_cat_pTjet30GeV = htxs_cat_rivet.stage1_1_cat_pTjet30GeV;
563  cat.stage1_1_fine_cat_pTjet25GeV = htxs_cat_rivet.stage1_1_fine_cat_pTjet25GeV;
564  cat.stage1_1_fine_cat_pTjet30GeV = htxs_cat_rivet.stage1_1_fine_cat_pTjet30GeV;
565  cat.stage1_2_cat_pTjet25GeV = htxs_cat_rivet.stage1_2_cat_pTjet25GeV;
566  cat.stage1_2_cat_pTjet30GeV = htxs_cat_rivet.stage1_2_cat_pTjet30GeV;
567  cat.stage1_2_fine_cat_pTjet25GeV = htxs_cat_rivet.stage1_2_fine_cat_pTjet25GeV;
568  cat.stage1_2_fine_cat_pTjet30GeV = htxs_cat_rivet.stage1_2_fine_cat_pTjet30GeV;
569  cat.isZ2vvDecay = htxs_cat_rivet.isZ2vvDecay;
570  return cat;
571  }
def cat(path)
Definition: eostools.py:401
TLV MakeTLV(vec4 const p)
TLVs MakeTLVs(Vvec4 const &rivet_jets)