Hammer  1.0.0
Helicity Amplitude Module for Matrix Element Reweighting
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Hammer::HistogramSet Class Reference

#include <HistogramSet.hh>

+ Collaboration diagram for Hammer::HistogramSet:

Public Member Functions

 HistogramSet (bool compressed=false)
 
 HistogramSet (const HistogramSet &other, const std::string &newName, const HistogramDefinition &newDef, const std::set< uint16_t > &collapsedIndexPositions)
 
HistogramgetHistogram (const EventUID &id)
 
HistogramgetHistogram (size_t id)
 
size_t addEventId (const EventUID &id, const LabelsList &labels)
 
HistogramaddHistogram (size_t id, std::unique_ptr< Histogram > hist)
 
EventUIDGroup read (const Serial::FBHistogram *msgreader, const HistogramDefinition &def, bool merge)
 
std::unique_ptr
< Serial::FBHistogramBuilder > 
write (flatbuffers::FlatBufferBuilder *msgwriter, const EventUID &id) const
 
EventIdGroupDict< IOHistogramspecializeEventHistograms (const std::vector< Tensor > &externalData) const
 
IOHistogram specializeSumHistogram (const std::vector< Tensor > &externalData) const
 
EventUIDGroup getEventIdsInHistogram () const
 
std::vector< LabelsListgetHistogramLabels () const
 
std::vector< EventUIDgetEventUIDRepresentatives () const
 
void clear ()
 

Private Attributes

EventIdDict< size_t > _compressionDict
 
std::map< size_t, EventUIDGroup_compressionReverseDict
 
std::map< size_t, LabelsList_labelsDict
 
UMap< LabelsList, size_t > _labelsReverseDict
 
std::vector< std::unique_ptr
< Histogram > > 
_data
 
bool _isCompressed
 

Detailed Description

Definition at line 33 of file HistogramSet.hh.

Constructor & Destructor Documentation

Hammer::HistogramSet::HistogramSet ( bool  compressed = false)

Definition at line 26 of file HistogramSet.cc.

Hammer::HistogramSet::HistogramSet ( const HistogramSet other,
const std::string &  newName,
const HistogramDefinition newDef,
const std::set< uint16_t > &  collapsedIndexPositions 
)

Definition at line 29 of file HistogramSet.cc.

Member Function Documentation

size_t Hammer::HistogramSet::addEventId ( const EventUID id,
const LabelsList labels 
)

Definition at line 60 of file HistogramSet.cc.

Histogram * Hammer::HistogramSet::addHistogram ( size_t  id,
std::unique_ptr< Histogram hist 
)

Definition at line 86 of file HistogramSet.cc.

void Hammer::HistogramSet::clear ( )

Definition at line 94 of file HistogramSet.cc.

EventUIDGroup Hammer::HistogramSet::getEventIdsInHistogram ( ) const

Definition at line 231 of file HistogramSet.cc.

vector< EventUID > Hammer::HistogramSet::getEventUIDRepresentatives ( ) const

Definition at line 247 of file HistogramSet.cc.

Histogram * Hammer::HistogramSet::getHistogram ( const EventUID id)

Definition at line 41 of file HistogramSet.cc.

Histogram * Hammer::HistogramSet::getHistogram ( size_t  id)

Definition at line 51 of file HistogramSet.cc.

vector< LabelsList > Hammer::HistogramSet::getHistogramLabels ( ) const

Definition at line 239 of file HistogramSet.cc.

EventUIDGroup Hammer::HistogramSet::read ( const Serial::FBHistogram *  msgreader,
const HistogramDefinition def,
bool  merge 
)

Definition at line 102 of file HistogramSet.cc.

EventIdGroupDict< IOHistogram > Hammer::HistogramSet::specializeEventHistograms ( const std::vector< Tensor > &  externalData) const

Definition at line 210 of file HistogramSet.cc.

IOHistogram Hammer::HistogramSet::specializeSumHistogram ( const std::vector< Tensor > &  externalData) const

Definition at line 220 of file HistogramSet.cc.

unique_ptr< Serial::FBHistogramBuilder > Hammer::HistogramSet::write ( flatbuffers::FlatBufferBuilder *  msgwriter,
const EventUID id 
) const

Definition at line 167 of file HistogramSet.cc.

Member Data Documentation

EventIdDict<size_t> Hammer::HistogramSet::_compressionDict
private

Definition at line 58 of file HistogramSet.hh.

std::map<size_t, EventUIDGroup> Hammer::HistogramSet::_compressionReverseDict
private

Definition at line 59 of file HistogramSet.hh.

std::vector<std::unique_ptr<Histogram> > Hammer::HistogramSet::_data
private

Definition at line 64 of file HistogramSet.hh.

bool Hammer::HistogramSet::_isCompressed
private

Definition at line 66 of file HistogramSet.hh.

std::map<size_t, LabelsList> Hammer::HistogramSet::_labelsDict
private

Definition at line 61 of file HistogramSet.hh.

UMap<LabelsList, size_t> Hammer::HistogramSet::_labelsReverseDict
private

Definition at line 62 of file HistogramSet.hh.


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