CASToR  3.2
Tomographic Reconstruction (PET/SPECT/CT)
include/dynamic/iLinearModel.hh
Go to the documentation of this file.
1 
8 #ifndef ILINEARMODEL_HH
9 #define ILINEARMODEL_HH 1
10 
20 #define OPTIMISATION_METHOD_DR 0
21 
22 #define OPTIMISATION_METHOD_NESTEM 1
23 
24 #define OPTIMISATION_METHOD_NNLS 2
25 
26 #define OPTIMISATION_METHOD_LS 3
27 
32 #include "vDynamicModel.hh"
33 #include "sAddonManager.hh"
34 
40 class iLinearModel : public vDynamicModel
41 {
42  // -----------------------------------------------------------------------------------------
43  // Constructor & Destructor
44  public:
49  iLinearModel();
54  ~iLinearModel();
55 
56 
57  // -----------------------------------------------------------------------------------------
58  // Public member functions related to the initialization of the model
59  public:
60  // Function for automatic insertion (put the class name as the parameters and do not add semi-colon at the end of the line)
87  int ReadAndCheckOptionsList(string a_listOptions);
100  int InitializeSpecific();
101 
113  void ShowBasisFunctions();
114 
120  void ShowHelpModelSpecific();
121 
122 
123  // -----------------------------------------------------------------------------------------
124  // Public member functions called by the main iterative algorithm class
133  int EstimateModelParameters(oImageSpace* ap_Image, int a_ite, int a_sset);
142  int EstimateImageWithModel(oImageSpace* ap_Image, int a_ite, int a_sset);
150  int NestedEM(oImageSpace* ap_ImageS, int a_ite);
158  int EstimateParametersWithNNLS(oImageSpace* ap_ImageS, int a_ite);
166  int Patlak_LS(oImageSpace* ap_ImageS, int a_ite) ;
167 
168 
169  // -----------------------------------------------------------------------------------------
170  // Data members
171  protected:
172 
174  int m_nbRgateBF;
175  int m_nbCgateBF;
176  //int m_nbRGModelParam; /*!< Number of model parameters applied to respiratory gates */
177  //int m_nbCGModelParam; /*!< Number of model parameters applied to cardiac gates */
178 
190  uint32_t m_nbLinearModelCycles;
197 };
198 
199 // Class for automatic insertion (set here the visible dynamic model's name, put the class name as the parameters and do not add semi-colon at the end of the line)
200 CLASS_DYNAMICMODEL(LinearModel,iLinearModel)
201 
202 #endif
int EstimateImageWithModel(oImageSpace *ap_Image, int a_ite, int a_sset)
This is the mother class of dynamic model classes.
int InitializeSpecificToAllLinearModels()
This function is used to initialize the parametric images and basis functions for all Linear Models...
This class implements a general linear dynamic model applied between the images of a dynamic acquisit...
void ShowHelpModelSpecific()
This function is used to print out specific help about the dynamic model and its options. It is pure virtual so must be implemented by children.
int ReadAndCheckOptionsList(string a_listOptions)
iLinearModel()
Constructor of iLinearModel. Simply set all data members to default values.
void ShowBasisFunctions()
This function is used to print the basis functions.
int CheckSpecificParametersForAllLinearModels()
This function is used to check parameters for all Linear Models. .
virtual int ReadAndCheckConfigurationFileSpecific()
This function is used to read options from a configuration file.
int EstimateParametersWithNNLS(oImageSpace *ap_ImageS, int a_ite)
#define FUNCTION_DYNAMICMODEL(CLASS)
int InitializeSpecific()
This function is used to initialize the parametric images and basis functions for all Linear Models...
#define CLASS_DYNAMICMODEL(NAME, CLASS)
This class holds all the matrices in the image domain that can be used in the algorithm: image...
int CheckSpecificParameters()
This function is used to check whether all member variables have been correctly initialized or not...
~iLinearModel()
Destructor of iLinearModel.
int Patlak_LS(oImageSpace *ap_ImageS, int a_ite)
Declaration of class vDynamicModel.
int NestedEM(oImageSpace *ap_ImageS, int a_ite)
int ReadAndCheckConfigurationFileSpecificToAllLinearModels()
This function is used to read parameters that are generic for all Linear Models. ...
int EstimateModelParameters(oImageSpace *ap_Image, int a_ite, int a_sset)