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 123 of file SSVWeightsAlg.h.

Constructor & Destructor Documentation

◆ EfficiencyMethodBJetBasedClass()

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

Definition at line 610 of file SSVWeightsAlg.cxx.

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

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

Member Data Documentation

◆ m_bjetEfficiencyMap

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

Definition at line 131 of file SSVWeightsAlg.h.

131{};

◆ m_upperboundNbjets

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

Definition at line 132 of file SSVWeightsAlg.h.


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