|
ATLAS Offline Software
|
Go to the documentation of this file.
17 #include "GaudiKernel/MsgStream.h"
18 #include "GaudiKernel/StatusCode.h"
64 ATH_MSG_FATAL(
"ManagedMonitorToolBase::initialize() - Failed" );
85 if (evtInfo.isValid()) {
86 return evtInfo->lumiBlock();
97 return StatusCode::SUCCESS;
108 std::string
hname = hname_prefix + nameOfEgammaType;
109 std::string htitle = htitle_prefix +
" (" + nameOfEgammaType +
")";
115 h =
new TH2F(
hname.c_str(),htitle.c_str(),nbinsx,xlow,xhigh,nbinsy,ylow,yhigh);
119 void egammaMonToolBase::bookTH2F(TH2* &
h,
MonGroup& mygroup,
const std::string& hname_prefix,
const std::string& htitle_prefix,
int nbinsx,
float xlow,
float xhigh,
int nbinsy,
float ylow,
float yhigh, std::string &nameOfEgammaType)
121 std::string
hname = hname_prefix + nameOfEgammaType;
122 std::string htitle = htitle_prefix +
" (" + nameOfEgammaType +
")";
123 bookTH2F(
h, mygroup,
hname, htitle, nbinsx, xlow, xhigh, nbinsy, ylow, yhigh);
138 for(
unsigned int ir=min_region;
ir<=max_region;
ir++) {
148 void egammaMonToolBase::bookTH1FperRegion(std::vector<TH1*> &vhist,
MonGroup& mygroup,
const std::string& hname_prefix,
const std::string& htitle_prefix,
int nbins,
float low,
float high,
unsigned int min_region,
unsigned int max_region, std::string &nameOfEgammaType)
150 std::string
hname = hname_prefix + nameOfEgammaType;
151 std::string htitle = htitle_prefix +
" (" + nameOfEgammaType +
")";
155 void egammaMonToolBase::bookTH2FperRegion(std::vector<TH2*> &vhist,
MonGroup& mygroup,
const std::string&
hname,
const std::string& htitle,
int nbinsx,
float xlow,
float xhigh,
int nbinsy,
float ylow,
float yhigh,
unsigned int min_region,
unsigned int max_region)
161 for(
unsigned int ir=min_region;
ir<=max_region;
ir++) {
165 TH2 *
h =
new TH2F(
name.c_str(),
title.c_str(),nbinsx,xlow,xhigh,nbinsy,ylow,yhigh);
171 void egammaMonToolBase::bookTH2FperRegion(std::vector<TH2*> &vhist,
MonGroup& mygroup,
const std::string& hname_prefix,
const std::string& htitle_prefix,
int nbinsx,
float xlow,
float xhigh,
int nbinsy,
float ylow,
float yhigh,
unsigned int min_region,
unsigned int max_region, std::string &nameOfEgammaType)
173 std::string
hname = hname_prefix + nameOfEgammaType;
174 std::string htitle = htitle_prefix +
" (" + nameOfEgammaType +
")";
175 bookTH2FperRegion(vhist, mygroup,
hname, htitle, nbinsx, xlow, xhigh, nbinsy, ylow, yhigh, min_region, max_region);
180 unsigned int size = vhist.size();
188 unsigned int size = vhist.size();
196 float aeta = fabs(
eta);
197 if( aeta < 3.2 )
return ENDCAP;
203 float aeta = fabs(
eta);
205 if( aeta < 1.37 )
return BARREL;
207 if( aeta > 1.52)
return ENDCAP;
218 return StatusCode::SUCCESS;
226 if (
sc.isFailure()) {
255 return StatusCode::SUCCESS;
260 int nbins =
h->GetNbinsX();
262 ATH_MSG_WARNING(
"egammaMonToolBase::FillEfficiencies(): histograms have different number of bins, can not divide!");
266 ATH_MSG_DEBUG(
"egammaMonToolBase::FillEfficiencies(): start new computation");
271 double Yref =
href->GetBinContent(
i);
273 double A =
h->GetBinContent(
i);
275 err = sqrt(eps*(1-eps)/Yref);
283 h->SetBinContent(
i,eps);
284 h->SetBinError(
i,
err);
291 ATH_MSG_DEBUG(
"No Trigger request for that monitoring tool");
296 bool triggerfound =
false;
310 const std::vector<std::string>&
vec =
m_trigdec->getListOfTriggers();
312 for (
const auto &
i :
vec) {
Scalar eta() const
pseudorapidity method
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
std::vector< size_t > vec
def TH2F(name, title, nxbins, bins_par2, bins_par3, bins_par4, bins_par5=None, bins_par6=None, path='', **kwargs)
@ LAr
The LAr calorimeter.
@ Error
The sub-detector issued an error.
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
def TProfile(*args, **kwargs)
::StatusCode StatusCode
StatusCode definition for legacy code.
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
EventFlagErrorState
States that a given sub-detector could be in.
Class describing the basic event information.
int ir
counter of the current depth
#define ATH_MSG_WARNING(x)
EventFlagErrorState errorState(EventFlagSubDet subDet) const
Get the error state for a particular sub-detector.
def TH1F(name, title, nxbins, bins_par2, bins_par3=None, path='', **kwargs)