The Gaudi Framework  v41r0 (bdbe7744)
Loading...
Searching...
No Matches
Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType > Class Template Reference

Internal Accumulator class dealing with RootHistograming. More...

#include </builds/gaudi/Gaudi/GaudiKernel/include/Gaudi/Accumulators/StaticRootHistogram.h>

Inheritance diagram for Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >:
Collaboration diagram for Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >:

Classes

struct  Proxy
 Small procyclass allowing operator[] to work as expected on the RootHistogram that is to return something having an operator+= updating the histogram properly. More...

Public Member Functions

RootHistogramingAccumulatorInternal & operator+= (typename InputType::ValueType v)
void reset ()
template<atomicity ato>
void mergeAndReset (RootHistogramingAccumulatorInternal< ato, Arithmetic, ND, AxisTupleType > &other)
auto operator[] (typename InputType::ValueType v)
auto sums2 () const
 returns the nbentries, sums and "squared sums" of the inputs Practically we have first the number of entries, then the simple sums of each input dimension followed by all combinasions of product of 2 inputs, in "alphabetical" order, e.g.
Public Member Functions inherited from Gaudi::Accumulators::HistogramingAccumulatorInternal< Atomicity, HistoInputType< AxisToArithmetic_t< AxisTupleType >, ND >, unsigned long, IntegralAccumulator, AxisTupleType >
HistogramingAccumulatorInternal & operator+= (HistoInputType< AxisToArithmetic_t< AxisTupleType >, ND > v)
void reset ()
void mergeAndReset (HistogramingAccumulatorInternal< ato, HistoInputType< AxisToArithmetic_t< AxisTupleType >, ND >, unsigned long, IntegralAccumulator, AxisTupleType > &other)
auto operator[] (typename HistoInputType< AxisToArithmetic_t< AxisTupleType >, ND >::ValueType v)
auto & axis () const
auto binValue (unsigned int i) const
auto nEntries (unsigned int i) const
auto totNBins () const
auto nBins (unsigned int i) const
auto minValue (unsigned int i) const
auto maxValue (unsigned int i) const

Private Types

using InputType = HistoInputType<AxisToArithmetic_t<AxisTupleType>, ND>
using Parent

Private Member Functions

void update (typename InputType::ValueType v)

Private Attributes

SigmaNAccumulator< Arithmetic, Atomicity, ND > m_accumulator

Friends

template<atomicity, typename, unsigned int, typename>
class RootHistogramingAccumulatorInternal
struct Proxy

Additional Inherited Members

Public Types inherited from Gaudi::Accumulators::HistogramingAccumulatorInternal< Atomicity, HistoInputType< AxisToArithmetic_t< AxisTupleType >, ND >, unsigned long, IntegralAccumulator, AxisTupleType >
using ND
using BaseAccumulator
using AxisTupleArithmeticType

Detailed Description

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
class Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >

Internal Accumulator class dealing with RootHistograming.

Actually a simple extention on top of RootHistograming with an extra SigmaCounter embeded

Definition at line 123 of file StaticRootHistogram.h.

Member Typedef Documentation

◆ InputType

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
using Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::InputType = HistoInputType<AxisToArithmetic_t<AxisTupleType>, ND>
private

Definition at line 127 of file StaticRootHistogram.h.

◆ Parent

Member Function Documentation

◆ mergeAndReset()

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
template<atomicity ato>
void Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::mergeAndReset ( RootHistogramingAccumulatorInternal< ato, Arithmetic, ND, AxisTupleType > & other)
inline

Definition at line 162 of file StaticRootHistogram.h.

162 {
163 m_accumulator.mergeAndReset( other.m_accumulator );
165 }
void mergeAndReset(HistogramingAccumulatorInternal< ato, InputType, unsigned long, IntegralAccumulator, AxisTupleType > &other)
Internal Accumulator class dealing with RootHistograming.
SigmaNAccumulator< Arithmetic, Atomicity, ND > m_accumulator

◆ operator+=()

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
RootHistogramingAccumulatorInternal & Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::operator+= ( typename InputType::ValueType v)
inline

Definition at line 153 of file StaticRootHistogram.h.

153 {
154 update( v );
155 return *this;
156 }

◆ operator[]()

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
auto Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::operator[] ( typename InputType::ValueType v)
inlinenodiscard

Definition at line 166 of file StaticRootHistogram.h.

◆ reset()

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
void Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::reset ( )
inline

◆ sums2()

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
auto Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::sums2 ( ) const
inline

returns the nbentries, sums and "squared sums" of the inputs Practically we have first the number of entries, then the simple sums of each input dimension followed by all combinasions of product of 2 inputs, in "alphabetical" order, e.g.

for ND=3 we have sums of n, x, y, z, x^2, xy, xz, y^2, yz, z^2

Definition at line 172 of file StaticRootHistogram.h.

172{ return m_accumulator.sums(); }

◆ update()

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
void Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::update ( typename InputType::ValueType v)
inlineprivate

Definition at line 175 of file StaticRootHistogram.h.

175 {
176 // Do not accumulate in m_accumulator if we are outside the histo range
177 // We mimic here the behavior of ROOT
178 if ( v.inAcceptance( this->axis() ) ) {
179 if constexpr ( ND == 1 ) {
181 } else {
183 }
184 }
186 }

◆ Proxy

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
friend struct Proxy
friend

Definition at line 150 of file StaticRootHistogram.h.

◆ RootHistogramingAccumulatorInternal

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
template<atomicity, typename, unsigned int, typename>
friend class RootHistogramingAccumulatorInternal
friend

Definition at line 132 of file StaticRootHistogram.h.

Member Data Documentation

◆ m_accumulator

template<atomicity Atomicity, typename Arithmetic, unsigned int ND, typename AxisTupleType>
SigmaNAccumulator<Arithmetic, Atomicity, ND> Gaudi::Accumulators::RootHistogramingAccumulatorInternal< Atomicity, Arithmetic, ND, AxisTupleType >::m_accumulator
private

Definition at line 189 of file StaticRootHistogram.h.


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