CASToR  2.0
Tomographic Reconstruction (PET/SPECT/CT)
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
sChronoManager Class Reference

This class is designed to manage some profiling of the code. More...

#include <sChronoManager.hh>

Collaboration diagram for sChronoManager:
Collaboration graph

Public Member Functions

 ~sChronoManager ()
 The destructor of sChronoManager. More...
 
int CheckParameters ()
 Check validity of all parameters. More...
 
int Initialize ()
 Initialize all thread-safe buffers for profiling. More...
 
void Display ()
 Display the results of the duration buffers. More...
 
void StartIterativeDataUpdateStep1 (int a_thread)
 Start the timer for duration of iterative data update step 1. More...
 
void StopIterativeDataUpdateStep1 (int a_thread)
 Stop the timer for duration of iterative data update step 1. More...
 
void StartIterativeDataUpdateStep2 (int a_thread)
 Start the timer for duration of iterative data update step 2. More...
 
void StopIterativeDataUpdateStep2 (int a_thread)
 Stop the timer for duration of iterative data update step 2. More...
 
void StartIterativeDataUpdateStep3 (int a_thread)
 Start the timer for duration of iterative data update step 3. More...
 
void StopIterativeDataUpdateStep3 (int a_thread)
 Stop the timer for duration of iterative data update step 3. More...
 
void StartIterativeDataUpdateStep4 (int a_thread)
 Start the timer for duration of iterative data update step 4. More...
 
void StopIterativeDataUpdateStep4 (int a_thread)
 Stop the timer for duration of iterative data update step 4. More...
 
void StartConvolution ()
 Start the timer for duration of convolution. More...
 
void StopConvolution ()
 Stop the timer for duration of convolution. More...
 
void StartCustomStep (int a_thread, int a_step)
 Start the timer for duration of custom step of the given index for the given thread. More...
 
void StopCustomStep (int a_thread, int a_step)
 Stop the timer for duration of custom step of the given index for the given thread. More...
 
void SetNbThreads (int a_nbThreadsForProjection, int a_nbThreadsForImageComputation)
 Set the number of threads for both projection and image computations. More...
 
void SetNbCustomSteps (int a_nbCustomSteps)
 Set the number of custom steps for profiling. More...
 
void SetVerbose (int a_verbose)
 Set the verbose level. More...
 

Static Public Member Functions

static sChronoManagerGetInstance ()
 Instantiate the singleton if not already done, then return the pointer to its instance. More...
 

Private Member Functions

 sChronoManager ()
 The constructor of sChronoManager. More...
 
 sChronoManager (sChronoManager const &)
 
void operator= (sChronoManager const &)
 

Private Attributes

int m_nbThreadsForProjection
 
int m_nbThreadsForImageComputation
 
int m_nbThreadsMax
 
DurationNanomp_durationIterativeDataUpdateStep1
 
DurationNanomp_durationIterativeDataUpdateStep2
 
DurationNanomp_durationIterativeDataUpdateStep3
 
DurationNanomp_durationIterativeDataUpdateStep4
 
ChronoTimemp_startIterativeDataUpdateStep1
 
ChronoTimemp_startIterativeDataUpdateStep2
 
ChronoTimemp_startIterativeDataUpdateStep3
 
ChronoTimemp_startIterativeDataUpdateStep4
 
DurationNano m_durationConvolution
 
ChronoTime m_startConvolution
 
int m_nbCustomSteps
 
DurationNano ** mpp_durationCustomSteps
 
ChronoTime ** mpp_startCustomSteps
 
int m_verbose
 

Static Private Attributes

static sChronoManagermp_Instance = NULL
 

Detailed Description

This class is designed to manage some profiling of the code.

We'll see for details...

Definition at line 50 of file sChronoManager.hh.

Constructor & Destructor Documentation

public sChronoManager::~sChronoManager ( )
inline

The destructor of sChronoManager.

This is the default and unique destructor. It simply replace the instance pointer by NULL.

Definition at line 70 of file sChronoManager.hh.

sChronoManager::sChronoManager ( )
private

The constructor of sChronoManager.

This is the default and unique constructor. It does nothing.

Definition at line 46 of file sChronoManager.cc.

Here is the caller graph for this function:

sChronoManager::sChronoManager ( sChronoManager const &  )
inlineprivate

Definition at line 216 of file sChronoManager.hh.

Member Function Documentation

int sChronoManager::CheckParameters ( )

Check validity of all parameters.

Returns
0 if success, another value otherwise

Definition at line 75 of file sChronoManager.cc.

Here is the caller graph for this function:

void sChronoManager::Display ( )

Display the results of the duration buffers.

Definition at line 152 of file sChronoManager.cc.

Here is the caller graph for this function:

public static sChronoManager * sChronoManager::GetInstance ( )
inlinestatic

Instantiate the singleton if not already done, then return the pointer to its instance.

Returns
mp_Instance

Definition at line 60 of file sChronoManager.hh.

Here is the call graph for this function:

Here is the caller graph for this function:

int sChronoManager::Initialize ( )

Initialize all thread-safe buffers for profiling.

Returns
0 if success, another value otherwise

Definition at line 109 of file sChronoManager.cc.

Here is the caller graph for this function:

void sChronoManager::operator= ( sChronoManager const &  )
inlineprivate

Definition at line 217 of file sChronoManager.hh.

public sChronoManager::SetNbCustomSteps ( int  a_nbCustomSteps)
inline

Set the number of custom steps for profiling.

Parameters
inta_nbCustomSteps

Definition at line 196 of file sChronoManager.hh.

public sChronoManager::SetNbThreads ( int  a_nbThreadsForProjection,
int  a_nbThreadsForImageComputation 
)
inline

Set the number of threads for both projection and image computations.

Parameters
inta_nbThreadsForProjection
inta_nbThreadsForImageComputation

Definition at line 188 of file sChronoManager.hh.

Here is the caller graph for this function:

public sChronoManager::SetVerbose ( int  a_verbose)
inline

Set the verbose level.

Parameters
inta_verbose

Definition at line 203 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StartConvolution ( )
inline

Start the timer for duration of convolution.

Definition at line 156 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StartCustomStep ( int  a_thread,
int  a_step 
)
inline

Start the timer for duration of custom step of the given index for the given thread.

Parameters
inta_thread
inta_step

Definition at line 170 of file sChronoManager.hh.

public void sChronoManager::StartIterativeDataUpdateStep1 ( int  a_thread)
inline

Start the timer for duration of iterative data update step 1.

Parameters
inta_thread

Definition at line 101 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StartIterativeDataUpdateStep2 ( int  a_thread)
inline

Start the timer for duration of iterative data update step 2.

Parameters
inta_thread

Definition at line 115 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StartIterativeDataUpdateStep3 ( int  a_thread)
inline

Start the timer for duration of iterative data update step 3.

Parameters
inta_thread

Definition at line 129 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StartIterativeDataUpdateStep4 ( int  a_thread)
inline

Start the timer for duration of iterative data update step 4.

Parameters
inta_thread

Definition at line 143 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StopConvolution ( )
inline

Stop the timer for duration of convolution.

Definition at line 162 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StopCustomStep ( int  a_thread,
int  a_step 
)
inline

Stop the timer for duration of custom step of the given index for the given thread.

Definition at line 176 of file sChronoManager.hh.

public void sChronoManager::StopIterativeDataUpdateStep1 ( int  a_thread)
inline

Stop the timer for duration of iterative data update step 1.

Parameters
inta_thread

Definition at line 108 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StopIterativeDataUpdateStep2 ( int  a_thread)
inline

Stop the timer for duration of iterative data update step 2.

Parameters
inta_thread

Definition at line 122 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StopIterativeDataUpdateStep3 ( int  a_thread)
inline

Stop the timer for duration of iterative data update step 3.

Parameters
inta_thread

Definition at line 136 of file sChronoManager.hh.

Here is the caller graph for this function:

public void sChronoManager::StopIterativeDataUpdateStep4 ( int  a_thread)
inline

Stop the timer for duration of iterative data update step 4.

Parameters
inta_thread

Definition at line 150 of file sChronoManager.hh.

Here is the caller graph for this function:

Member Data Documentation

DurationNano sChronoManager::m_durationConvolution
private

Definition at line 236 of file sChronoManager.hh.

int sChronoManager::m_nbCustomSteps
private

Definition at line 239 of file sChronoManager.hh.

int sChronoManager::m_nbThreadsForImageComputation
private

Definition at line 225 of file sChronoManager.hh.

int sChronoManager::m_nbThreadsForProjection
private

Definition at line 224 of file sChronoManager.hh.

int sChronoManager::m_nbThreadsMax
private

Definition at line 226 of file sChronoManager.hh.

ChronoTime sChronoManager::m_startConvolution
private

Definition at line 237 of file sChronoManager.hh.

int sChronoManager::m_verbose
private

Definition at line 243 of file sChronoManager.hh.

DurationNano* sChronoManager::mp_durationIterativeDataUpdateStep1
private

Definition at line 228 of file sChronoManager.hh.

DurationNano* sChronoManager::mp_durationIterativeDataUpdateStep2
private

Definition at line 229 of file sChronoManager.hh.

DurationNano* sChronoManager::mp_durationIterativeDataUpdateStep3
private

Definition at line 230 of file sChronoManager.hh.

DurationNano* sChronoManager::mp_durationIterativeDataUpdateStep4
private

Definition at line 231 of file sChronoManager.hh.

sChronoManager * sChronoManager::mp_Instance = NULL
staticprivate

Pointer to this singleton object

Definition at line 217 of file sChronoManager.hh.

ChronoTime* sChronoManager::mp_startIterativeDataUpdateStep1
private

Definition at line 232 of file sChronoManager.hh.

ChronoTime* sChronoManager::mp_startIterativeDataUpdateStep2
private

Definition at line 233 of file sChronoManager.hh.

ChronoTime* sChronoManager::mp_startIterativeDataUpdateStep3
private

Definition at line 234 of file sChronoManager.hh.

ChronoTime* sChronoManager::mp_startIterativeDataUpdateStep4
private

Definition at line 235 of file sChronoManager.hh.

DurationNano** sChronoManager::mpp_durationCustomSteps
private

Definition at line 240 of file sChronoManager.hh.

ChronoTime** sChronoManager::mpp_startCustomSteps
private

Definition at line 241 of file sChronoManager.hh.


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