Project
Loading...
Searching...
No Matches
o2::itsmft::TopologyDictionary Class Reference

#include <TopologyDictionary.h>

Public Member Functions

 TopologyDictionary ()
 Default constructor.
 
 TopologyDictionary (const std::string &fileName)
 Constructor.
 
TopologyDictionaryoperator= (const TopologyDictionary &dict)=default
 
void writeBinaryFile (const std::string &outputFile)
 Prints the dictionary in a binary file.
 
int readBinaryFile (const std::string &fileName)
 Reads the dictionary from a binary file.
 
int readFromFile (const std::string &fileName)
 
float getXCOG (int n) const
 Returns the x position of the COG for the n_th element.
 
float getErrX (int n) const
 Returns the error on the x position of the COG for the n_th element.
 
float getZCOG (int n) const
 Returns the z position of the COG for the n_th element.
 
float getErrZ (int n) const
 Returns the error on the z position of the COG for the n_th element.
 
float getErr2X (int n) const
 Returns the error^2 on the x position of the COG for the n_th element.
 
float getErr2Z (int n) const
 Returns the error^2 on the z position of the COG for the n_th element.
 
unsigned long getHash (int n) const
 Returns the hash of the n_th element.
 
int getNpixels (int n) const
 Returns the number of fired pixels of the n_th element.
 
double getFrequency (int n) const
 Returns the frequency of the n_th element;.
 
bool isGroup (int n) const
 Returns true if the element corresponds to a group of rare topologies.
 
const ClusterPatterngetPattern (int n) const
 Returns the pattern of the topology.
 
int getSize () const
 Returns the number of elements in the dicionary;.
 
template<typename T = float>
std::array< T, 3 > getClusterCoordinatesA (const CompCluster &cl) const
 Returns the local position of a compact cluster.
 
template<typename T = float>
math_utils::Point3D< T > getClusterCoordinates (const CompCluster &cl) const
 

Static Public Member Functions

static void getTopologyDistribution (const TopologyDictionary &dict, TH1F *&histo, const char *histName)
 Fills a hostogram with the distribution of the IDs.
 
template<typename T = float>
static std::array< T, 3 > getClusterCoordinatesA (const CompCluster &cl, const ClusterPattern &patt, bool isGroup=true)
 Returns the local position of a compact cluster.
 
template<typename T = float>
static math_utils::Point3D< T > getClusterCoordinates (const CompCluster &cl, const ClusterPattern &patt, bool isGroup=true)
 Returns the local position of a compact cluster.
 
static TopologyDictionaryloadFrom (const std::string &fileName="", const std::string &objName="ccdb_object")
 

Public Attributes

friend BuildTopologyDictionary
 
friend LookUp
 
friend TopologyFastSimulation
 

Static Public Attributes

static constexpr int RowClassSpan = 4
 Row span of the classes of rare topologies.
 
static constexpr int ColClassSpan = 4
 Column span of the classes of rare topologies.
 
static constexpr int MaxNumberOfRowClasses = 1 + (ClusterPattern::MaxRowSpan - 1) / RowClassSpan
 Maximum number of row classes for the groups of rare topologies.
 
static constexpr int MaxNumberOfColClasses = 1 + (ClusterPattern::MaxColSpan - 1) / ColClassSpan
 Maximum number of col classes for the groups of rare topologies.
 
static constexpr int NumberOfRareGroups = MaxNumberOfRowClasses * MaxNumberOfColClasses
 

Friends

std::ostream & operator<< (std::ostream &os, const TopologyDictionary &dictionary)
 Prints the dictionary.
 

Detailed Description

Definition at line 67 of file TopologyDictionary.h.

Constructor & Destructor Documentation

◆ TopologyDictionary() [1/2]

o2::itsmft::TopologyDictionary::TopologyDictionary ( )

Default constructor.

Definition at line 36 of file TopologyDictionary.cxx.

◆ TopologyDictionary() [2/2]

o2::itsmft::TopologyDictionary::TopologyDictionary ( const std::string &  fileName)

Constructor.

Definition at line 41 of file TopologyDictionary.cxx.

Member Function Documentation

◆ getClusterCoordinates() [1/2]

template<typename T >
template math_utils::Point3D< double > o2::itsmft::TopologyDictionary::getClusterCoordinates< double > ( const CompCluster cl) const

Definition at line 158 of file TopologyDictionary.cxx.

◆ getClusterCoordinates() [2/2]

template<typename T >
template math_utils::Point3D< double > o2::itsmft::TopologyDictionary::getClusterCoordinates< double > ( const CompCluster cl,
const ClusterPattern patt,
bool  isGroup = true 
)
static

Returns the local position of a compact cluster.

Definition at line 168 of file TopologyDictionary.cxx.

◆ getClusterCoordinatesA() [1/2]

template<typename T >
template std::array< double, 3 > o2::itsmft::TopologyDictionary::getClusterCoordinatesA< double > ( const CompCluster cl) const

Returns the local position of a compact cluster.

Definition at line 148 of file TopologyDictionary.cxx.

◆ getClusterCoordinatesA() [2/2]

template<typename T >
template std::array< double, 3 > o2::itsmft::TopologyDictionary::getClusterCoordinatesA< double > ( const CompCluster cl,
const ClusterPattern patt,
bool  isGroup = true 
)
static

Returns the local position of a compact cluster.

Definition at line 184 of file TopologyDictionary.cxx.

◆ getErr2X()

float o2::itsmft::TopologyDictionary::getErr2X ( int  n) const
inline

Returns the error^2 on the x position of the COG for the n_th element.

Definition at line 117 of file TopologyDictionary.h.

◆ getErr2Z()

float o2::itsmft::TopologyDictionary::getErr2Z ( int  n) const
inline

Returns the error^2 on the z position of the COG for the n_th element.

Definition at line 123 of file TopologyDictionary.h.

◆ getErrX()

float o2::itsmft::TopologyDictionary::getErrX ( int  n) const
inline

Returns the error on the x position of the COG for the n_th element.

Definition at line 99 of file TopologyDictionary.h.

◆ getErrZ()

float o2::itsmft::TopologyDictionary::getErrZ ( int  n) const
inline

Returns the error on the z position of the COG for the n_th element.

Definition at line 111 of file TopologyDictionary.h.

◆ getFrequency()

double o2::itsmft::TopologyDictionary::getFrequency ( int  n) const
inline

Returns the frequency of the n_th element;.

Definition at line 141 of file TopologyDictionary.h.

◆ getHash()

unsigned long o2::itsmft::TopologyDictionary::getHash ( int  n) const
inline

Returns the hash of the n_th element.

Definition at line 129 of file TopologyDictionary.h.

◆ getNpixels()

int o2::itsmft::TopologyDictionary::getNpixels ( int  n) const
inline

Returns the number of fired pixels of the n_th element.

Definition at line 135 of file TopologyDictionary.h.

◆ getPattern()

const ClusterPattern & o2::itsmft::TopologyDictionary::getPattern ( int  n) const
inline

Returns the pattern of the topology.

Definition at line 153 of file TopologyDictionary.h.

◆ getSize()

int o2::itsmft::TopologyDictionary::getSize ( ) const
inline

Returns the number of elements in the dicionary;.

Definition at line 162 of file TopologyDictionary.h.

◆ getTopologyDistribution()

void o2::itsmft::TopologyDictionary::getTopologyDistribution ( const TopologyDictionary dict,
TH1F *&  histo,
const char histName 
)
static

Fills a hostogram with the distribution of the IDs.

Definition at line 132 of file TopologyDictionary.cxx.

◆ getXCOG()

float o2::itsmft::TopologyDictionary::getXCOG ( int  n) const
inline

Returns the x position of the COG for the n_th element.

Definition at line 93 of file TopologyDictionary.h.

◆ getZCOG()

float o2::itsmft::TopologyDictionary::getZCOG ( int  n) const
inline

Returns the z position of the COG for the n_th element.

Definition at line 105 of file TopologyDictionary.h.

◆ isGroup()

bool o2::itsmft::TopologyDictionary::isGroup ( int  n) const
inline

Returns true if the element corresponds to a group of rare topologies.

Definition at line 147 of file TopologyDictionary.h.

◆ loadFrom()

TopologyDictionary * o2::itsmft::TopologyDictionary::loadFrom ( const std::string &  fileName = "",
const std::string &  objName = "ccdb_object" 
)
static

Definition at line 200 of file TopologyDictionary.cxx.

◆ operator=()

TopologyDictionary & o2::itsmft::TopologyDictionary::operator= ( const TopologyDictionary dict)
default

◆ readBinaryFile()

int o2::itsmft::TopologyDictionary::readBinaryFile ( const std::string &  fileName)

Reads the dictionary from a binary file.

Definition at line 91 of file TopologyDictionary.cxx.

◆ readFromFile()

int o2::itsmft::TopologyDictionary::readFromFile ( const std::string &  fileName)

Definition at line 78 of file TopologyDictionary.cxx.

◆ writeBinaryFile()

void o2::itsmft::TopologyDictionary::writeBinaryFile ( const std::string &  outputFile)

Prints the dictionary in a binary file.

Definition at line 58 of file TopologyDictionary.cxx.

Friends And Related Symbol Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream &  os,
const TopologyDictionary dictionary 
)
friend

Prints the dictionary.

Definition at line 46 of file TopologyDictionary.cxx.

Member Data Documentation

◆ BuildTopologyDictionary

friend o2::itsmft::TopologyDictionary::BuildTopologyDictionary

Definition at line 180 of file TopologyDictionary.h.

◆ ColClassSpan

constexpr int o2::itsmft::TopologyDictionary::ColClassSpan = 4
staticconstexpr

Column span of the classes of rare topologies.

Definition at line 79 of file TopologyDictionary.h.

◆ LookUp

friend o2::itsmft::TopologyDictionary::LookUp

Definition at line 181 of file TopologyDictionary.h.

◆ MaxNumberOfColClasses

constexpr int o2::itsmft::TopologyDictionary::MaxNumberOfColClasses = 1 + (ClusterPattern::MaxColSpan - 1) / ColClassSpan
staticconstexpr

Maximum number of col classes for the groups of rare topologies.

Definition at line 81 of file TopologyDictionary.h.

◆ MaxNumberOfRowClasses

constexpr int o2::itsmft::TopologyDictionary::MaxNumberOfRowClasses = 1 + (ClusterPattern::MaxRowSpan - 1) / RowClassSpan
staticconstexpr

Maximum number of row classes for the groups of rare topologies.

Definition at line 80 of file TopologyDictionary.h.

◆ NumberOfRareGroups

constexpr int o2::itsmft::TopologyDictionary::NumberOfRareGroups = MaxNumberOfRowClasses * MaxNumberOfColClasses
staticconstexpr

Number of entries corresponding to groups of rare topologies (those whos matrix exceed the max number of bytes are empty).

Definition at line 82 of file TopologyDictionary.h.

◆ RowClassSpan

constexpr int o2::itsmft::TopologyDictionary::RowClassSpan = 4
staticconstexpr

Row span of the classes of rare topologies.

constexpr for the definition of the groups of rare topologies. The attritbution of the group ID is stringly dependent on the following parameters: it must be a power of 2.

Definition at line 78 of file TopologyDictionary.h.

◆ TopologyFastSimulation

friend o2::itsmft::TopologyDictionary::TopologyFastSimulation

Definition at line 182 of file TopologyDictionary.h.


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