Skip to content
Snippets Groups Projects
Commit 7784fb48 authored by Vakhtang Tsulaia's avatar Vakhtang Tsulaia
Browse files

Merge branch 'naming.SemileptonicCorr-20180326' into 'master'

SemileptonicCorr: Comply with ATLAS naming conventions.

See merge request atlas/athena!10026
parents 8711bf61 f5f6b9ac
No related branches found
No related tags found
1 merge request!20779WIP: Migrate DataQualityTools to ToolHandles
......@@ -6,15 +6,15 @@
using namespace std;
semilCorr::semilCorr(TString fIn, string suffix, bool DebugIn){
Debug = DebugIn;
f = TFile::Open(fIn);
etas.push_back(0);
etas.push_back(0.8);
etas.push_back(1.2);
etas.push_back(1.7);
etas.push_back(2.1);
etas.push_back(2.5);
semilCorr::semilCorr(TString fIn, string /*suffix*/, bool DebugIn){
m_Debug = DebugIn;
m_f = TFile::Open(fIn);
m_etas.push_back(0);
m_etas.push_back(0.8);
m_etas.push_back(1.2);
m_etas.push_back(1.7);
m_etas.push_back(2.1);
m_etas.push_back(2.5);
vector<string> etastr;
etastr.push_back("_e0");
......@@ -37,7 +37,7 @@ semilCorr::semilCorr(TString fIn, string suffix, bool DebugIn){
for(unsigned int j = 0; j<prefix.size(); j++){
vector<TH1F*> corr;
for(unsigned int i = 0; i<etastr.size(); i++){
corr.push_back((TH1F*) f->Get((prefix[j]+etastr[i]).c_str()));
corr.push_back((TH1F*) m_f->Get((prefix[j]+etastr[i]).c_str()));
}
m_histos.push_back(corr);
}
......@@ -50,8 +50,8 @@ semilCorr::~semilCorr(){
delete m_histos[i][j]; // TH2F's that store response info
}
}
f->Close();
delete f;
m_f->Close();
delete m_f;
}
float semilCorr::getSemilCorrToIncl(TLorentzVector jet, TLorentzVector mu)
......@@ -105,8 +105,8 @@ float semilCorr::getResponse(float pt, float eta, vector<TH1F*> h)
{
float usePt = pt;
int histbin = -1;
for(unsigned int i = 0; i<etas.size()-1; i++){
if(fabs(eta)>=etas[i] && fabs(eta)<etas[i+1])
for(unsigned int i = 0; i<m_etas.size()-1; i++){
if(fabs(eta)>=m_etas[i] && fabs(eta)<m_etas[i+1])
histbin = i;
}
......
......@@ -2,8 +2,8 @@
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
#ifndef __SEMIL_CORR__
#define __SEMIL_CORR__
#ifndef SEMILEPTONICCORR_SEMILCORR_H
#define SEMILEPTONICCORR_SEMILCORR_H
#include "TH2F.h"
#include "TFile.h"
......@@ -29,11 +29,11 @@ public:
private:
vector<vector<TH1F*> > m_histos;
vector<float> etas;
vector<float> m_etas;
TFile* f;
TFile* m_f;
bool Debug;
bool m_Debug;
float getResponse(float pt, float eta, vector<TH1F*> h);
float getSemilCorrToIncl(TLorentzVector jet, TLorentzVector mu,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment