ATLAS Offline Software
Loading...
Searching...
No Matches
CP::SSVWeightsAlg::EfficiencyMethodBJetBasedClass Class Reference
Collaboration diagram for CP::SSVWeightsAlg::EfficiencyMethodBJetBasedClass:

Public Member Functions

 EfficiencyMethodBJetBasedClass (const nlohmann::json &jsonConfig)
double getPIneff (const int b_jet_count, const int N_missed, const double SF_eff) const

Private Attributes

std::map< std::string, doublem_bjetEfficiencyMap {}
int m_upperboundNbjets = -999

Detailed Description

Definition at line 125 of file SSVWeightsAlg.h.

Constructor & Destructor Documentation

◆ EfficiencyMethodBJetBasedClass()

CP::SSVWeightsAlg::EfficiencyMethodBJetBasedClass::EfficiencyMethodBJetBasedClass ( const nlohmann::json & jsonConfig)

Definition at line 611 of file SSVWeightsAlg.cxx.

612 : m_bjetEfficiencyMap(jsonConfig["efficiency_bjet_based"])
613 {
614 // Extract information from JSON file for EfficiencyMethodBJetBased
615 std::map<std::string, double>::iterator lastItem = std::prev(m_bjetEfficiencyMap.end());
616 std::string lastItemKey = lastItem->first;
617 m_upperboundNbjets = std::stoi(lastItemKey);
618 }
std::map< std::string, double > m_bjetEfficiencyMap

Member Function Documentation

◆ getPIneff()

double CP::SSVWeightsAlg::EfficiencyMethodBJetBasedClass::getPIneff ( const int b_jet_count,
const int N_missed,
const double SF_eff ) const

Definition at line 622 of file SSVWeightsAlg.cxx.

625 {
626
627 double P_ineff = 1;
628
629 // Get the value
630 double epsilon = 1;
631
632 //retrieve efficiency and average number of fake SSV depending on number of jets in event
633 if (b_jet_count < m_upperboundNbjets){
634 // Build the bjets key string
635 std::string bjets_key = std::to_string(b_jet_count) + "_bjets";
636 epsilon = m_bjetEfficiencyMap.at(bjets_key);
637 }
638 else{
639 std::string bjets_key = std::to_string(m_upperboundNbjets) + "p_bjets";
640 epsilon = m_bjetEfficiencyMap.at(bjets_key);
641 }
642
643 P_ineff = std::pow((1-SF_eff*epsilon)/(1-epsilon), N_missed);
644
645 return P_ineff;
646 }

Member Data Documentation

◆ m_bjetEfficiencyMap

std::map<std::string, double> CP::SSVWeightsAlg::EfficiencyMethodBJetBasedClass::m_bjetEfficiencyMap {}
private

Definition at line 133 of file SSVWeightsAlg.h.

133{};

◆ m_upperboundNbjets

int CP::SSVWeightsAlg::EfficiencyMethodBJetBasedClass::m_upperboundNbjets = -999
private

Definition at line 134 of file SSVWeightsAlg.h.


The documentation for this class was generated from the following files: