CASToR  1.1
Tomographic Reconstruction (PET/SPECT)
 All Classes Files Functions Variables Typedefs Macros Groups Pages
oOptimizerManager.hh
Go to the documentation of this file.
1 
8 #ifndef OOPTIMIZERMANAGER_HH
9 #define OOPTIMIZERMANAGER_HH 1
10 
11 #include "gVariables.hh"
12 #include "vOptimizer.hh"
13 #include "vPenalty.hh"
14 #include "oImageSpace.hh"
15 #include "vDataFile.hh"
16 
17 
30 {
31  // -------------------------------------------------------------------
32  // Constructor & Destructor
33  public:
48 
49 
50  // -------------------------------------------------------------------
51  // Public member functions
52  public:
60  int CheckParameters();
70  int Initialize();
80  int PreDataUpdateStep(int a_iteration, int a_nbIterations, int a_subset, int a_nbSubsets);
90  int PostDataUpdateStep(int a_iteration, int a_nbIterations, int a_subset, int a_nbSubsets);
109  int DataUpdateStep( oProjectionLine* ap_Line, oImageSpace* ap_Image, vEvent* ap_Event,
110  int a_bed, int a_timeFrame, int a_respGate, int a_cardGate,
111  int a_iteration, int a_thread );
122  int ImageUpdateStep( oImageSpace* ap_Image, int a_iteration, int a_nbSubsets );
123 
124 
125  // -------------------------------------------------------------------
126  // Private member functions
127  private:
141 
142 
143  // -------------------------------------------------------------------
144  // Public Get & Set functions
145  public:
151  inline void SetVerbose(int a_verboseLevel)
152  {m_verbose = a_verboseLevel;}
158  inline void SetOptionsOptimizer(const string& a_optionsOptimizer)
159  {m_optionsOptimizer = a_optionsOptimizer;}
165  inline void SetOptionsPenalty(const string& a_optionsPenalty)
166  {m_optionsPenalty = a_optionsPenalty;}
172  inline void SetImageDimensionsAndQuantification(oImageDimensionsAndQuantification* ap_ImageDimensionsAndQuantification)
173  {mp_ImageDimensionsAndQuantification = ap_ImageDimensionsAndQuantification;}
179  inline void SetNbTOFBins(int a_nbTOFBins)
180  {m_nbTOFBins = a_nbTOFBins;}
186  inline void SetDataMode(int a_dataMode)
187  {m_dataMode = a_dataMode;}
193  inline void SetDataType(int a_dataType)
194  {m_dataType = a_dataType;}
200  inline void SetOptimizerFOMFlag(bool a_optimizerFOMFlag)
201  {m_optimizerFOMFlag = a_optimizerFOMFlag;}
207  inline void SetOptimizerImageStatFlag(bool a_optimizerImageStatFlag)
208  {m_optimizerImageStatFlag = a_optimizerImageStatFlag;}
213  inline int GetNbBackwardImages()
214  {return mp_Optimizer->GetNbBackwardImages();}
220  {return mp_Optimizer->GetInitialValue();}
221 
222 
223  // -------------------------------------------------------------------
224  // Data members
225  private:
237  int m_verbose;
238 };
239 
240 #endif
oImageDimensionsAndQuantification * mp_ImageDimensionsAndQuantification
This header file is mainly used to declare some macro definitions and all includes needed from the st...
FLTNB GetInitialValue()
Return the initial image value used by the optimizer, explaining why the eponym function of vOptimize...
#define FLTNB
Definition: gVariables.hh:55
void SetOptimizerImageStatFlag(bool a_optimizerImageStatFlag)
Set the optimizer image stat flag that specifies if some basic statistics about image update is compu...
void SetVerbose(int a_verboseLevel)
Set the verbose level.
void SetImageDimensionsAndQuantification(oImageDimensionsAndQuantification *ap_ImageDimensionsAndQuantification)
Set the image dimensions in use.
This class is designed to manage the optimization part of an iterative reconstruction.
int PreDataUpdateStep(int a_iteration, int a_nbIterations, int a_subset, int a_nbSubsets)
A function that simply calls the eponym function from the vOptimizer.
int ImageUpdateStep(oImageSpace *ap_Image, int a_iteration, int a_nbSubsets)
A function dedicated to the update step in the image space (performed after the loop on events) ...
int Initialize()
A function used to initialize the manager and the optimizer it manages.
void SetDataMode(int a_dataMode)
Set the mode of the data (histogram, list-mode)
int ParseOptionsAndInitializeOptimizerAndPenalty()
void SetDataType(int a_dataType)
Set the type of the data (pet, spect, etc)
int GetNbBackwardImages()
Return the number of backward images used by the optimizer, explaining why the eponym function of vOp...
void SetOptionsOptimizer(const string &a_optionsOptimizer)
Set the optimizer projection options contained in the provided string.
int PostDataUpdateStep(int a_iteration, int a_nbIterations, int a_subset, int a_nbSubsets)
A function that simply calls the eponym function from the vOptimizer.
Declaration of class vDataFile.
int DataUpdateStep(oProjectionLine *ap_Line, oImageSpace *ap_Image, vEvent *ap_Event, int a_bed, int a_timeFrame, int a_respGate, int a_cardGate, int a_iteration, int a_thread)
A function dedicated to the update step in the data space (for each event inside the loop) ...
vOptimizer * mp_Optimizer
Declaration of class vOptimizer.
void SetOptionsPenalty(const string &a_optionsPenalty)
Set the penalty projection options contained in the provided string.
Declaration of class vPenalty.
This class is designed to generically described any penalty applied to MAP algorithms.
Definition: vPenalty.hh:23
FLTNB GetInitialValue()
Get the initial image value (for initialization)
Definition: vOptimizer.hh:526
int CheckParameters()
A function used to check the parameters settings.
void SetNbTOFBins(int a_nbTOFBins)
Set the number of TOF bins in use.
This class is designed to generically described any iterative optimizer.
Definition: vOptimizer.hh:36
This class is designed to manage and store system matrix elements associated to a vEvent...
~oOptimizerManager()
The destructor of oOptimizerManager.
Declaration of class oImageSpace.
This class holds all the matrices in the image domain that can be used in the algorithm: image...
Definition: oImageSpace.hh:41
Mother class for the Event objects.
Definition: vEvent.hh:23
This class is designed to manage all dimensions and quantification related stuff. ...
oOptimizerManager()
The constructor of oOptimizerManager.
int GetNbBackwardImages()
Get the number of backward images used by the specific optimizer.
Definition: vOptimizer.hh:519
void SetOptimizerFOMFlag(bool a_optimizerFOMFlag)
Set the optimizer FOM flag that specifies if some figures-of-merit (FOM) will be computed in the data...