Project
Loading...
Searching...
No Matches
o2::tpc::Digitizer Class Reference

#include <Digitizer.h>

Public Types

using SC = SpaceCharge< float >
 

Public Member Functions

 Digitizer ()
 Default constructor.
 
 ~Digitizer ()
 Destructor.
 
 Digitizer (const Digitizer &)=delete
 
Digitizer & operator= (const Digitizer &)=delete
 
void init ()
 Initializer.
 
void process (const std::vector< o2::tpc::HitGroup > &hits, const int eventID, const int sourceID=0)
 
void flush (std::vector< o2::tpc::Digit > &digits, o2::dataformats::MCTruthContainer< o2::MCCompLabel > &labels, std::vector< o2::tpc::CommonMode > &commonModeOutput, bool finalFlush=false)
 
void setSector (Sector sec)
 
void setStartTime (double time)
 
void setOutputDigitTimeOffset (double offset)
 Set mOutputDigitTimeOffset.
 
void setEventTime (double time)
 
void setContinuousReadout (bool isContinuous)
 
bool isContinuousReadout ()
 
void setUseSCDistortions (const SCDistortionType &distortionType, const TH3 *hisInitialSCDensity)
 
void setUseSCDistortions (SC *spaceCharge)
 
void setSCDistortionsDerivative (SC *spaceCharge)
 
void setUseSCDistortions (std::string_view finp)
 
void setVDrift (float v)
 
void setTDriftOffset (float t)
 
void setDistortionScaleType (int distortionScaleType)
 
int getDistortionScaleType () const
 
void setLumiScaleFactor ()
 
void setMeanLumiDistortions (float meanLumi)
 
void setMeanLumiDistortionsDerivative (float meanLumi)
 
void recalculateDistortions ()
 in case of scaled distortions, the distortions can be recalculated to ensure consistent distortions and corrections
 
void setSCDistortionsFrom (const Digitizer &other)
 Use the distortion maps and scaling of another digitizer, which keeps ownership of the maps.
 
void setUseSectorSeeding (ULong64_t seed)
 
void setSeedingTimeframe (ULong64_t timeframe)
 Set the timeframe identifier that enters the sector seeding.
 
void setSectorSeedingFrom (Digitizer &other)
 Use copies of the sector-seeding random rings of another digitizer, which fills them if needed.
 
void setFlushDebugStreamer (bool flush)
 Whether flush() also flushes the process-wide debug streamer.
 

Detailed Description

This is the digitizer for the ALICE GEM TPC. It is the main class and steers all relevant physical processes for the signal formation in the detector.

  1. Transformation of energy deposit of the incident particle to a number of primary electrons
  2. Drift and diffusion of the primary electrons while moving in the active volume towards the readout chambers (ElectronTransport)
  3. Amplification of the electrons in the stack of four GEM foils (GEMAmplification)
  4. Induction of the signal on the pad plane, including a spread of the signal due to the pad response (SignalInduction)
  5. Shaping and further signal processing in the Front-End Cards (SampaProcessing) The such created Digits and then sorted in an intermediate Container (DigitContainer) and after processing of the full event/drift time summed up and sorted as Digits into a vector which is then passed further on

Definition at line 55 of file Digitizer.h.

Member Typedef Documentation

◆ SC

Definition at line 58 of file Digitizer.h.

Constructor & Destructor Documentation

◆ Digitizer() [1/2]

Digitizer::Digitizer ( )
default

Default constructor.

◆ ~Digitizer()

Digitizer::~Digitizer ( )
default

Destructor.

◆ Digitizer() [2/2]

o2::tpc::Digitizer::Digitizer ( const Digitizer &  )
delete

Member Function Documentation

◆ flush()

void Digitizer::flush ( std::vector< o2::tpc::Digit > &  digits,
o2::dataformats::MCTruthContainer< o2::MCCompLabel > &  labels,
std::vector< o2::tpc::CommonMode > &  commonModeOutput,
bool  finalFlush = false 
)

Flush the data

Parameters
digitsContainer for the digits
labelsContainer for the MC labels
commonModeOutputOutput container for the common mode
finalFlushFlag whether the whole container is dumped

Definition at line 252 of file Digitizer.cxx.

◆ getDistortionScaleType()

int o2::tpc::Digitizer::getDistortionScaleType ( ) const
inline

Definition at line 138 of file Digitizer.h.

◆ init()

void Digitizer::init ( )

Initializer.

Definition at line 116 of file Digitizer.cxx.

◆ isContinuousReadout()

bool o2::tpc::Digitizer::isContinuousReadout ( )
inline

Option to retrieve triggered / continuous readout

Returns
true for continuous readout

Definition at line 113 of file Digitizer.h.

◆ operator=()

Digitizer & o2::tpc::Digitizer::operator= ( const Digitizer &  )
delete

◆ process()

void Digitizer::process ( const std::vector< o2::tpc::HitGroup > &  hits,
const int  eventID,
const int  sourceID = 0 
)

Process a single hit group

Parameters
hitsContainer with TPC hit groups
eventIDID of the event to be processed
sourceIDID of the source to be processed

Reserve space in the digit container for the current event

obtain max drift_time + hitTime which can be processed

Remove electrons that end up more than three sigma of the hit's average diffusion away from the current sector boundary

The energy loss stored corresponds to nElectrons

in us

TODO: add primary ions to space-charge density

Loop over electrons

Drift and Diffusion

in us

in us

the absolute time needs to be within the readout limits (otherwise negative times would all be accumulated in the 0-th timebin further below)

Attachment

Remove electrons that end up outside the active volume

When the electron is not in the sector we're processing, abandon

Compute digit position and check for validity

Remove digits the end up outside the currently produced sector

Electron amplification

TODO: add ion backflow to space-charge density

end of loop over electrons

Definition at line 137 of file Digitizer.cxx.

◆ recalculateDistortions()

void Digitizer::recalculateDistortions ( )

in case of scaled distortions, the distortions can be recalculated to ensure consistent distortions and corrections

Definition at line 354 of file Digitizer.cxx.

◆ setContinuousReadout()

void o2::tpc::Digitizer::setContinuousReadout ( bool  isContinuous)
inline

Switch for triggered / continuous readout

Parameters
isContinuous- false for triggered readout, true for continuous readout

Definition at line 109 of file Digitizer.h.

◆ setDistortionScaleType()

void o2::tpc::Digitizer::setDistortionScaleType ( int  distortionScaleType)
inline

Definition at line 137 of file Digitizer.h.

◆ setEventTime()

void o2::tpc::Digitizer::setEventTime ( double  time)
inline

Set the time of the event to be processed

Parameters
timeTime of the event

Definition at line 105 of file Digitizer.h.

◆ setFlushDebugStreamer()

void o2::tpc::Digitizer::setFlushDebugStreamer ( bool  flush)
inline

Whether flush() also flushes the process-wide debug streamer.

Definition at line 162 of file Digitizer.h.

◆ setLumiScaleFactor()

void Digitizer::setLumiScaleFactor ( )

Definition at line 338 of file Digitizer.cxx.

◆ setMeanLumiDistortions()

void Digitizer::setMeanLumiDistortions ( float  meanLumi)

Definition at line 344 of file Digitizer.cxx.

◆ setMeanLumiDistortionsDerivative()

void Digitizer::setMeanLumiDistortionsDerivative ( float  meanLumi)

Definition at line 349 of file Digitizer.cxx.

◆ setOutputDigitTimeOffset()

void o2::tpc::Digitizer::setOutputDigitTimeOffset ( double  offset)
inline

Set mOutputDigitTimeOffset.

Definition at line 101 of file Digitizer.h.

◆ setSCDistortionsDerivative()

void Digitizer::setSCDistortionsDerivative ( SC *  spaceCharge)
Parameters
spaceChargespaceCharge object of the derivative map, not owned: the caller keeps it alive

Definition at line 290 of file Digitizer.cxx.

◆ setSCDistortionsFrom()

void Digitizer::setSCDistortionsFrom ( const Digitizer &  other)

Use the distortion maps and scaling of another digitizer, which keeps ownership of the maps.

Definition at line 328 of file Digitizer.cxx.

◆ setSector()

void o2::tpc::Digitizer::setSector ( Sector  sec)
inline

Set the sector to be processed

Parameters
secSector to be processed

Definition at line 90 of file Digitizer.h.

◆ setSectorSeedingFrom()

void Digitizer::setSectorSeedingFrom ( Digitizer &  other)

Use copies of the sector-seeding random rings of another digitizer, which fills them if needed.

Definition at line 103 of file Digitizer.cxx.

◆ setSeedingTimeframe()

void o2::tpc::Digitizer::setSeedingTimeframe ( ULong64_t  timeframe)
inline

Set the timeframe identifier that enters the sector seeding.

Definition at line 156 of file Digitizer.h.

◆ setStartTime()

void Digitizer::setStartTime ( double  time)

Set the start time of the first event

Parameters
timeTime of the first event

Definition at line 313 of file Digitizer.cxx.

◆ setTDriftOffset()

void o2::tpc::Digitizer::setTDriftOffset ( float  t)
inline

Definition at line 135 of file Digitizer.h.

◆ setUseSCDistortions() [1/3]

void Digitizer::setUseSCDistortions ( const SCDistortionType &  distortionType,
const TH3 *  hisInitialSCDensity 
)

Enable the use of space-charge distortions and provide space-charge density histogram as input

Parameters
distortionTypeselect the type of space-charge distortions (constant or realistic)
hisInitialSCDensityoptional space-charge density histogram to use at the beginning of the simulation
nZSlicesnumber of grid points in z, must be (2**N)+1
nPhiBinsnumber of grid points in phi
nRBinsnumber of grid points in r, must be (2**N)+1

Definition at line 265 of file Digitizer.cxx.

◆ setUseSCDistortions() [2/3]

void Digitizer::setUseSCDistortions ( SC *  spaceCharge)

Enable the use of space-charge distortions and provide SpaceCharge object as input

Parameters
spaceChargespaceCharge object, not owned: the caller (e.g. the DPL CCDB cache) keeps it alive

Definition at line 279 of file Digitizer.cxx.

◆ setUseSCDistortions() [3/3]

void Digitizer::setUseSCDistortions ( std::string_view  finp)

Enable the use of space-charge distortions by providing global distortions and global corrections stored in a ROOT file The storage of the values should be done by the methods provided in the SpaceCharge class

Parameters
filecontaining distortions

Definition at line 297 of file Digitizer.cxx.

◆ setUseSectorSeeding()

void Digitizer::setUseSectorSeeding ( ULong64_t  seed)

Use digitizer-owned random rings filled from seed and positioned per sector and timeframe in init(), so that the digits of a sector do not depend on which sectors were processed before. All sectors share the ring contents and differ in the start positions, as with the singleton rings.

Parameters
seedbase seed, typically DigiParams.seed

Definition at line 85 of file Digitizer.cxx.

◆ setVDrift()

void o2::tpc::Digitizer::setVDrift ( float  v)
inline

Definition at line 134 of file Digitizer.h.


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