The Gaudi Framework  v39r0 (5b8b5eda)
CounterHistos.cpp
Go to the documentation of this file.
1 /***********************************************************************************\
2 * (c) Copyright 1998-2024 CERN for the benefit of the LHCb and ATLAS collaborations *
3 * *
4 * This software is distributed under the terms of the Apache version 2 licence, *
5 * copied verbatim in the file "LICENSE". *
6 * *
7 * In applying this licence, CERN does not waive the privileges and immunities *
8 * granted to it by virtue of its status as an Intergovernmental Organization *
9 * or submit itself to any jurisdiction. *
10 \***********************************************************************************/
13 #include <Gaudi/Algorithm.h>
16 
17 #include "../../../GaudiKernel/tests/src/LogHistogram.h"
18 
19 #include <deque>
20 
21 namespace Gaudi {
22  namespace TestSuite {
23  namespace Counter {
24 
26  template <typename Arithmetic, Gaudi::Accumulators::atomicity Atomicity>
28  public:
30  StatusCode initialize() override {
31  // must be called first
32  const StatusCode sc = Algorithm::initialize();
33  if ( sc.isFailure() ) return sc;
34 
35  // random number generator
36  auto randSvc = service<IRndmGenSvc>( "RndmGenSvc", true );
37  if ( !randSvc || !m_rand.initialize( randSvc, Rndm::Flat( 0., 1. ) ) ) {
38  error() << "Unable to create Random generator" << endmsg;
39  return StatusCode::FAILURE;
40  }
41 
42  Gaudi::Accumulators::Axis<Arithmetic> axis{ 100, 0, 1 };
43  for ( unsigned int iH = 0; iH < m_nHistos; ++iH ) {
44  std::ostringstream title;
45  title << "Histogram Number " << iH;
46  m_histos.emplace_back( this, title.str(), title.str(), axis );
47  }
48 
49  return sc;
50  }
51 
52  StatusCode execute( const EventContext& ) const override {
53  for ( unsigned int iT = 0; iT < m_nTracks; ++iT ) {
54  for ( auto& h : m_histos ) { ++h[m_rand()]; }
55  }
56  return StatusCode::SUCCESS;
57  }
58 
59  private:
61 
63 
64  Gaudi::Property<unsigned int> m_nHistos{ this, "NumHistos", 20, "" };
65  Gaudi::Property<unsigned int> m_nTracks{ this, "NumTracks", 30, "" };
66  };
68  DECLARE_COMPONENT_WITH_ID( HistoTimingAlgDA, "HistoTimingAlgDA" )
69  using HistoTimingAlgIA = HistoTimingAlg<unsigned int, Gaudi::Accumulators::atomicity::full>;
71  using HistoTimingAlgD = HistoTimingAlg<double, Gaudi::Accumulators::atomicity::none>;
73  using HistoTimingAlgI = HistoTimingAlg<unsigned int, Gaudi::Accumulators::atomicity::none>;
75 
78  public:
80  using Base::Base;
81 
82  StatusCode initialize() override {
83  return Base::initialize().andThen( [&] { m_custom_gauss_noinit.createHistogram( *this ); } );
84  }
85 
86  StatusCode execute( const EventContext& ) const override {
87  // some random number generators, just to provide numbers
88  static Rndm::Numbers Gauss( randSvc(), Rndm::Gauss( 0.0, 1.0 ) );
89  static Rndm::Numbers Flat( randSvc(), Rndm::Flat( -10.0, 10.0 ) );
90  static Rndm::Numbers Gauss3( randSvc(), Rndm::Gauss( 5.0, 1.0 ) );
91 
92  // cache some numbers
93  const double gauss( Gauss() );
94  const double gauss2( Gauss() );
95  const double flat( Flat() );
96  const double gauss3( Gauss3() );
97 
98  // updating histograms
99  ++m_gauss[gauss];
100  ++m_gaussAbsName[gauss];
101  ++m_gaussVflat[{ flat, gauss }];
102  ++m_gaussVflatVgauss[{ flat, gauss, gauss2 }];
103  ++m_gauss_noato[gauss];
104  ++m_gaussVflat_noato[{ flat, gauss }];
105  ++m_gaussVflatVgauss_noato[{ flat, gauss, gauss2 }];
106  ++m_gauss_int[(int)gauss];
107  ++m_gaussVflat_int[{ (int)flat, (int)gauss }];
108  ++m_gaussVflatVgauss_int[{ (int)flat, (int)gauss, (int)gauss2 }];
109 
110  // weighted cases
111  m_gauss_w[gauss] += .5;
112  m_gaussVflat_w[{ flat, gauss }] += .5;
113  m_gaussVflatVgauss_w[{ flat, gauss, gauss2 }] += .5;
114 
115  // using buffers
116  auto gauss_buf = m_gauss_buf.buffer();
117  auto gaussVflat_buf = m_gaussVflat_buf.buffer();
118  auto gaussVflatVgauss_buf = m_gaussVflatVgauss_buf.buffer();
119  for ( unsigned int i = 0; i < 10; i++ ) {
120  ++gauss_buf[gauss];
121  ++gaussVflat_buf[{ flat, gauss }];
122  ++gaussVflatVgauss_buf[{ flat, gauss, gauss2 }];
123  }
124 
125  // updating profile histograms
126  m_prof_gauss[gauss] += gauss3;
127  m_prof_gaussVflat[{ flat, gauss }] += gauss3;
128  m_prof_gaussVflatVgauss[{ flat, gauss, gauss2 }] += gauss3;
129  m_prof_gauss_noato[gauss] += gauss3;
130  m_prof_gaussVflat_noato[{ flat, gauss }] += gauss3;
131  m_prof_gaussVflatVgauss_noato[{ flat, gauss, gauss2 }] += gauss3;
132  m_prof_gauss_int[(int)gauss] += (int)gauss3;
133  m_prof_gaussVflat_int[{ (int)flat, (int)gauss }] += (int)gauss3;
134  m_prof_gaussVflatVgauss_int[{ (int)flat, (int)gauss, (int)gauss2 }] += (int)gauss3;
135 
136  // weighted profile histograms
137  m_prof_gauss_w[gauss] += { gauss3, .5 };
138  m_prof_gaussVflat_w[{ flat, gauss }] += { gauss3, .5 };
139  m_prof_gaussVflatVgauss_w[{ flat, gauss, gauss2 }] += { gauss3, .5 };
140 
141  // using buffers on profile histograms
142  auto prof_gauss_buf = m_prof_gauss_buf.buffer();
143  auto prof_gaussVflat_buf = m_prof_gaussVflat_buf.buffer();
144  auto prof_gaussVflatVgauss_buf = m_prof_gaussVflatVgauss_buf.buffer();
145  for ( unsigned int i = 0; i < 10; i++ ) {
146  prof_gauss_buf[gauss] += gauss3;
147  prof_gaussVflat_buf[{ flat, gauss }] += gauss3;
148  prof_gaussVflatVgauss_buf[{ flat, gauss, gauss2 }] += gauss3;
149  }
150 
151  // using CaloHistogram
152  m_log_gauss[gauss]++;
153  m_log_gaussVflat[{ flat, gauss }]++;
154 
155  // using Custom histograms, with title and axis defined in python
156  ++m_custom_gauss_noprop[gauss];
157  ++m_custom_gauss[gauss];
158  ++m_custom_gaussVflat[{ flat, gauss }];
159  ++m_custom_gaussVflatVgauss[{ flat, gauss, gauss2 }];
160  m_custom_gauss_w[gauss] += .5;
161  m_custom_gaussVflat_w[{ flat, gauss }] += .5;
162  m_custom_gaussVflatVgauss_w[{ flat, gauss, gauss2 }] += .5;
163  m_custom_prof_gauss[gauss] += gauss3;
164  m_custom_prof_gaussVflat[{ flat, gauss }] += gauss3;
165  m_custom_prof_gaussVflatVgauss[{ flat, gauss, gauss2 }] += gauss3;
166  m_custom_prof_gauss_w[gauss] += { gauss3, .5 };
167  m_custom_prof_gaussVflat_w[{ flat, gauss }] += { gauss3, .5 };
168  m_custom_prof_gaussVflatVgauss_w[{ flat, gauss, gauss2 }] += { gauss3, .5 };
169  ++m_custom_gauss_noinit[gauss];
170 
171  if ( m_nCalls.nEntries() == 0 ) always() << "Filling Histograms...... Please be patient !" << endmsg;
172  ++m_nCalls;
173  return StatusCode::SUCCESS;
174  }
175 
176  private:
177  mutable Gaudi::Accumulators::Counter<> m_nCalls{ this, "calls" };
178 
179  // Testing regular histograms in all dimensions and features
180 
181  // "default" case, that is bins containing doubles and atomic
183  this, "Gauss", "Gaussian mean=0, sigma=1, atomic", { 100, -5, 5, "X" } };
185  this, "GaussFlat", "Gaussian V Flat, atomic", { { 50, -5, 5, "X" }, { 50, -5, 5, "Y" } } };
186  mutable Gaudi::Accumulators::StaticHistogram<3> m_gaussVflatVgauss{
187  this,
188  "GaussFlatGauss",
189  "Gaussian V Flat V Gaussian, atomic",
190  { { 10, -5, 5, "X" }, { 10, -5, 5, "Y" }, { 10, -5, 5, "Z" } } };
191 
192  // non atomic versions
194  this, "GaussNA", "Gaussian mean=0, sigma=1, non atomic", { 100, -5, 5 } };
196  this, "GaussFlatNA", "Gaussian V Flat, non atomic", { { 50, -5, 5 }, { 50, -5, 5 } } };
198  this,
199  "GaussFlatGaussNA",
200  "Gaussian V Flat V Gaussian, non atomic",
201  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
202 
203  // using integers
205  this, "GaussInt", "Gaussian mean=0, sigma=1, integer values", { 10, -5, 5 } };
207  this, "GaussFlatInt", "Gaussian V Flat, integer values", { { 10, -5, 5 }, { 10, -5, 5 } } };
209  m_gaussVflatVgauss_int{ this,
210  "GaussFlatGaussInt",
211  "Gaussian V Flat V Gaussian, interger values",
212  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
213 
214  // weighted version, "default" case
216  this, "GaussW", "Gaussian mean=0, sigma=1, weighted", { 100, -5, 5 } };
218  this, "GaussFlatW", "Gaussian V Flat, weighted", { { 50, -5, 5 }, { 50, -5, 5 } } };
220  this,
221  "GaussFlatGaussW",
222  "Gaussian V Flat V Gaussian, weighted",
223  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
224 
225  // "default" case, dedicated to testing buffers
227  this, "GaussBuf", "Gaussian mean=0, sigma=1, buffered", { 100, -5, 5 } };
228  mutable Gaudi::Accumulators::StaticHistogram<2> m_gaussVflat_buf{
229  this, "GaussFlatBuf", "Gaussian V Flat, buffered", { { 50, -5, 5 }, { 50, -5, 5 } } };
230  mutable Gaudi::Accumulators::StaticHistogram<3> m_gaussVflatVgauss_buf{
231  this,
232  "GaussFlatGaussBuf",
233  "Gaussian V Flat V Gaussian, buffered",
234  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
235 
236  // Testing profiling histograms in all dimensions and features
237 
238  // "default" case, that is bins containing doubles and atomic
240  this, "ProfGauss", "Profile, Gaussian mean=0, sigma=1, atomic", { 100, -5, 5 } };
242  this, "ProfGaussFlat", "Profile, Gaussian V Flat, atomic", { { 50, -5, 5 }, { 50, -5, 5 } } };
243  mutable Gaudi::Accumulators::StaticProfileHistogram<3> m_prof_gaussVflatVgauss{
244  this,
245  "ProfGaussFlatGauss",
246  "Profile, Gaussian V Flat V Gaussian, atomic",
247  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
248 
249  // non atomic versions
251  this, "ProfGaussNA", "Profile, Gaussian mean=0, sigma=1, non atomic", { 100, -5, 5 } };
253  m_prof_gaussVflat_noato{
254  this, "ProfGaussFlatNA", "Profile, Gaussian V Flat, non atomic", { { 50, -5, 5 }, { 50, -5, 5 } } };
256  m_prof_gaussVflatVgauss_noato{ this,
257  "ProfGaussFlatGaussNA",
258  "Profile, Gaussian V Flat V Gaussian, non atomic",
259  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
260 
261  // using integers internally
263  m_prof_gauss_int{
264  this, "ProfGaussInt", "Profile, Gaussian mean=0, sigma=1, integer values", { 10, -5, 5 } };
266  m_prof_gaussVflat_int{ this,
267  "ProfGaussFlatInt",
268  "Profile, Gaussian V Flat, integer values",
269  { { 10, -5, 5 }, { 10, -5, 5 } } };
271  m_prof_gaussVflatVgauss_int{ this,
272  "ProfGaussFlatGaussInt",
273  "Profile, Gaussian V Flat V Gaussian, interger values",
274  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
275 
276  // weighted version, "default" case
278  this, "ProfGaussW", "Profile, Gaussian mean=0, sigma=1, weighted", { 100, -5, 5 } };
280  this, "ProfGaussFlatW", "Profile, Gaussian V Flat, weighted", { { 50, -5, 5 }, { 50, -5, 5 } } };
282  this,
283  "ProfGaussFlatGaussW",
284  "Profile, Gaussian V Flat V Gaussian, weighted",
285  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
286 
287  // "default" case, dedicated to testing buffers
289  this, "ProfGaussBuf", "Profile, Gaussian mean=0, sigma=1, buffered", { 100, -5, 5 } };
290  mutable Gaudi::Accumulators::StaticProfileHistogram<2> m_prof_gaussVflat_buf{
291  this, "ProfGaussFlatBuf", "Profile, Gaussian V Flat, buffered", { { 50, -5, 5 }, { 50, -5, 5 } } };
292  mutable Gaudi::Accumulators::StaticProfileHistogram<3> m_prof_gaussVflatVgauss_buf{
293  this,
294  "ProfGaussFlatGaussBuf",
295  "Profile, Gaussian V Flat V Gaussian, buffered",
296  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
297 
298  // Custom histogram, with log or log log behavior
299  mutable Accumulators::LogHistogram<1> m_log_gauss{ this, "LogGauss", "Log, Gaussian", { 5, 0, 2 } };
300  mutable Accumulators::LogHistogram<2, Accumulators::atomicity::full, float> m_log_gaussVflat{
301  this, "LogGaussFlat", "LogLog, Gaussian V Flat", { { 5, 0, 2 }, { 5, 0, 2 } } };
302 
303  // Histogram in an absolute location
305  this, "/TopDir/SubDir/Gauss", "Gaussian mean=0, sigma=1, atomic", { 100, -5, 5, "X" } };
306 
307  // Custom histograms, specifying title and axis in python
308  mutable Gaudi::Accumulators::Histogram<1> m_custom_gauss_noprop{
309  this, "CustomGaussNoProp", "Gaussian mean=0, sigma=1, atomic", { 100, -5, 5, "X" } };
310  mutable Gaudi::Accumulators::Histogram<1> m_custom_gauss{ this, "CustomGauss" };
311  mutable Gaudi::Accumulators::Histogram<2> m_custom_gaussVflat{ this, "CustomGaussFlat" };
312  mutable Gaudi::Accumulators::Histogram<3> m_custom_gaussVflatVgauss{ this, "CustomGaussFlatGauss" };
313 
314  mutable Gaudi::Accumulators::WeightedHistogram<1> m_custom_gauss_w{ this, "CustomGaussW" };
315  mutable Gaudi::Accumulators::WeightedHistogram<2> m_custom_gaussVflat_w{ this, "CustomGaussFlatW" };
316  mutable Gaudi::Accumulators::WeightedHistogram<3> m_custom_gaussVflatVgauss_w{ this, "CustomGaussFlatGaussW" };
317 
318  mutable Gaudi::Accumulators::ProfileHistogram<1> m_custom_prof_gauss{ this, "CustomProfGauss" };
319  mutable Gaudi::Accumulators::ProfileHistogram<2> m_custom_prof_gaussVflat{ this, "CustomProfGaussFlat" };
320  mutable Gaudi::Accumulators::ProfileHistogram<3> m_custom_prof_gaussVflatVgauss{ this,
321  "CustomProfGaussFlatGauss" };
322 
323  mutable Gaudi::Accumulators::WeightedProfileHistogram<1> m_custom_prof_gauss_w{ this, "CustomProfGaussW" };
324  mutable Gaudi::Accumulators::WeightedProfileHistogram<2> m_custom_prof_gaussVflat_w{ this,
325  "CustomProfGaussFlatW" };
326  mutable Gaudi::Accumulators::WeightedProfileHistogram<3> m_custom_prof_gaussVflatVgauss_w{
327  this, "CustomProfGaussFlatGaussW" };
328 
329  // Checking DoNotInitialize property of CustomHistogram
330  mutable Gaudi::Accumulators::Histogram<1> m_custom_gauss_noinit{ this, "CustomGaussNoInit", "", {}, true };
331  };
332  DECLARE_COMPONENT( GaudiHistoAlgorithm )
333 
334 
336  public:
338  using Base::Base;
339 
340  StatusCode execute( const EventContext& ) const override {
341  // some random number generators, just to provide numbers
342  static Rndm::Numbers Gauss( randSvc(), Rndm::Gauss( 0.0, 1.0 ) );
343  static Rndm::Numbers Flat( randSvc(), Rndm::Flat( -10.0, 10.0 ) );
344 
345  // cache some numbers
346  const double gauss( Gauss() );
347  const double gauss2( Gauss() );
348  const double flat( Flat() );
349 
350  // updating histograms
351  ++m_gauss[gauss];
352  ++m_gaussVflat[{ flat, gauss }];
353  ++m_gaussVflatVgauss[{ flat, gauss, gauss2 }];
354 
355  // using buffers
356  auto gauss_buf = m_gauss_buf.buffer();
357  auto gaussVflat_buf = m_gaussVflat_buf.buffer();
358  auto gaussVflatVgauss_buf = m_gaussVflatVgauss_buf.buffer();
359  for ( unsigned int i = 0; i < 10; i++ ) {
360  ++gauss_buf[gauss];
361  ++gaussVflat_buf[{ flat, gauss }];
362  ++gaussVflatVgauss_buf[{ flat, gauss, gauss2 }];
363  }
364 
365  // custom histograms, with title and axis defined in python
366  ++m_custom_gauss[gauss];
367  ++m_custom_gaussVflat[{ flat, gauss }];
368  ++m_custom_gaussVflatVgauss[{ flat, gauss, gauss2 }];
369 
370  if ( m_nCalls.nEntries() == 0 ) always() << "Filling Histograms...... Please be patient !" << endmsg;
371  ++m_nCalls;
372  return StatusCode::SUCCESS;
373  }
374 
375  private:
376  mutable Gaudi::Accumulators::Counter<> m_nCalls{ this, "calls" };
377 
378  // Testing Root histograms in all dimensions
379 
380  // "default" case, that is bins containing doubles and atomic
382  this, "Gauss", "Gaussian mean=0, sigma=1, atomic", { 100, -5, 5, "X" } };
384  this, "GaussFlat", "Gaussian V Flat, atomic", { { 50, -5, 5, "X" }, { 50, -5, 5, "Y" } } };
386  this,
387  "GaussFlatGauss",
388  "Gaussian V Flat V Gaussian, atomic",
389  { { 10, -5, 5, "X" }, { 10, -5, 5, "Y" }, { 10, -5, 5, "Z" } } };
390 
391  // "default" case, dedicated to testing buffers
393  this, "GaussBuf", "Gaussian mean=0, sigma=1, buffered", { 100, -5, 5 } };
395  this, "GaussFlatBuf", "Gaussian V Flat, buffered", { { 50, -5, 5 }, { 50, -5, 5 } } };
396  mutable Gaudi::Accumulators::StaticRootHistogram<3> m_gaussVflatVgauss_buf{
397  this,
398  "GaussFlatGaussBuf",
399  "Gaussian V Flat V Gaussian, buffered",
400  { { 10, -5, 5 }, { 10, -5, 5 }, { 10, -5, 5 } } };
401 
402  // Custom histogram cases, specifying title and axis in python
403  mutable Gaudi::Accumulators::RootHistogram<1> m_custom_gauss{ this, "CustomGauss",
404  "Gaussian mean=0, sigma=1, atomic" };
405  mutable Gaudi::Accumulators::RootHistogram<2> m_custom_gaussVflat{ this, "CustomGaussFlat",
406  "Gaussian V Flat, atomic" };
407  mutable Gaudi::Accumulators::RootHistogram<3> m_custom_gaussVflatVgauss{ this, "CustomGaussFlatGauss",
408  "Gaussian V Flat V Gaussian, atomic" };
409  };
410  DECLARE_COMPONENT( GaudiRootHistoAlgorithm )
411  } // namespace Counter
412  } // namespace TestSuite
413 } // namespace Gaudi
Gaudi::TestSuite::Counter
Definition: Counter.h:30
RndmGenerators.h
Gaudi::Algorithm::randSvc
SmartIF< IRndmGenSvc > & randSvc() const
The standard RandomGen service, Return a pointer to the service if present.
Definition: Algorithm.cpp:565
StatusCode::andThen
StatusCode andThen(F &&f, ARGS &&... args) const
Chain code blocks making the execution conditional a success result.
Definition: StatusCode.h:163
Gaudi::TestSuite::Counter::GaudiHistoAlgorithm::initialize
StatusCode initialize() override
Definition: CounterHistos.cpp:82
Gaudi::Accumulators::Counter<>
Histogram.h
TestSuite
#define TestSuite
Definition: MakeAndConsume.cpp:634
Gaudi::Accumulators::HistogramingCounterBase
A base counter dealing with Histograms.
Definition: StaticHistogram.h:641
Gaudi::Algorithm::initialize
StatusCode initialize() override
the default (empty) implementation of IStateful::initialize() method
Definition: Algorithm.h:178
Gaudi::TestSuite::Counter::HistoTimingAlg::m_rand
Rndm::Numbers m_rand
Definition: CounterHistos.cpp:60
Gaudi::TestSuite::Counter::HistoTimingAlg::m_nHistos
Gaudi::Property< unsigned int > m_nHistos
Definition: CounterHistos.cpp:64
class
#define class
Definition: HistogramPersistencySvc.cpp:54
Rndm::Flat
Parameters for the flat random number generation within boundaries [minimum, maximum].
Definition: RndmGenerators.h:253
DECLARE_COMPONENT_WITH_ID
#define DECLARE_COMPONENT_WITH_ID(type, id)
Definition: PluginServiceV1.h:47
Gaudi::TestSuite::Counter::HistoTimingAlg::m_nTracks
Gaudi::Property< unsigned int > m_nTracks
Definition: CounterHistos.cpp:65
FSMCallbackHolder.h
Gaudi::TestSuite::Counter::GaudiHistoAlgorithm
Example of algorithm using histograms accumulators.
Definition: CounterHistos.cpp:77
StatusCode
Definition: StatusCode.h:65
Rndm::Gauss
Parameters for the Gauss random number generation.
Definition: RndmGenerators.h:32
Gaudi::FSMCallbackHolder
Helper class to implement the IFSMCallbackHolder interface.
Definition: FSMCallbackHolder.h:37
Rndm::Numbers
Random number accessor This small class encapsulates the use of the random number generator.
Definition: RndmGenerators.h:359
Gaudi::Algorithm
Base class from which all concrete algorithm classes should be derived.
Definition: Algorithm.h:90
AlgSequencer.h
h
Definition: AlgSequencer.py:31
Gaudi::TestSuite::Counter::HistoTimingAlg::initialize
StatusCode initialize() override
Definition: CounterHistos.cpp:30
Algorithm.h
std::deque
STL class.
endmsg
MsgStream & endmsg(MsgStream &s)
MsgStream Modifier: endmsg. Calls the output method of the MsgStream.
Definition: MsgStream.h:203
Gaudi::TestSuite::Counter::GaudiRootHistoAlgorithm
Example of algorithm using root histograms accumulators.
Definition: CounterHistos.cpp:335
Gaudi
This file provides a Grammar for the type Gaudi::Accumulators::Axis It allows to use that type from p...
Definition: __init__.py:1
Rndm::Numbers::initialize
virtual StatusCode initialize(const SmartIF< IRndmGenSvc > &svc, const IRndmGen::Param &par)
Initialization.
Definition: RndmGenerators.cpp:30
std::ostringstream
STL class.
StatusCode::isFailure
bool isFailure() const
Definition: StatusCode.h:129
Gaudi::TestSuite::Counter::HistoTimingAlg::m_histos
std::deque< Gaudi::Accumulators::StaticHistogram< 1, Atomicity, Arithmetic > > m_histos
Definition: CounterHistos.cpp:62
Gaudi::TestSuite::Counter::GaudiHistoAlgorithm::execute
StatusCode execute(const EventContext &) const override
Definition: CounterHistos.cpp:86
Gaudi::Units::gauss
constexpr double gauss
Definition: SystemOfUnits.h:252
StatusCode::SUCCESS
constexpr static const auto SUCCESS
Definition: StatusCode.h:100
Gaudi::Accumulators::HistogramWrapperInternal
A Wrapper of a static Histogram base class using Properties to define title and axis.
Definition: HistogramWrapper.h:41
DECLARE_COMPONENT
#define DECLARE_COMPONENT(type)
Definition: PluginServiceV1.h:46
EventContext
Definition: EventContext.h:34
Gaudi::Accumulators::atomicity
atomicity
Defines atomicity of the accumulators.
Definition: Accumulators.h:263
Gaudi::TestSuite::Counter::HistoTimingAlg
Simple timing of counter based histograms filling.
Definition: CounterHistos.cpp:27
std::ostringstream::str
T str(T... args)
Gaudi::Algorithm::Algorithm
Algorithm(std::string name, ISvcLocator *svcloc, std::string version=PACKAGE_VERSION)
Constructor.
Definition: Algorithm.h:101
StatusCode::FAILURE
constexpr static const auto FAILURE
Definition: StatusCode.h:101
Gaudi::Accumulators::RootHistogramingCounterBase
Extension of the standard Gaudi histogram to provide similar functionnality as ROOT.
Definition: StaticRootHistogram.h:283
Gaudi::Accumulators::Axis
Definition of a default type of Histogram Axis It contains number of bins, min and max value plus a t...
Definition: StaticHistogram.h:218
Gaudi::Property< unsigned int >
RootHistogram.h
Gaudi::TestSuite::Counter::GaudiRootHistoAlgorithm::execute
StatusCode execute(const EventContext &) const override
Definition: CounterHistos.cpp:340
Gaudi::TestSuite::Counter::HistoTimingAlg::execute
StatusCode execute(const EventContext &) const override
Definition: CounterHistos.cpp:52