8 #ifndef OIMAGEDIMENSIONSANDQUANTIFICATION_HH 9 #define OIMAGEDIMENSIONSANDQUANTIFICATION_HH 1 11 #include "gVariables.hh" 12 #include "sOutputManager.hh" 13 #include "gOptions.hh" 14 #include "oDynamicDataManager.hh" 15 #include "oArterialInputCurve.hh" 29 #define DYN_RECO_FRAMING 1 31 #define DYN_RECO_GATING 2 33 #define DYN_RECO_MCGATING 3 35 #define DYN_RECO_IPMC 4 191 int a_respMotionCorrectionFlag,
int a_cardMotionCorrectionFlag,
int a_invMotionCorrectionFlag,
192 int a_nbRespGates,
int a_nbCardGates );
209 inline int DynamicSwitch( int64_t a_currentEventIndex, uint32_t a_currentTime,
int a_bed,
int a_th )
string m_cardBasisFunctionsFile
uint32_t GetFrameTimeStartInMs(int a_bed, int a_frame)
int InitializeFramingAndQuantification()
A function used to initialize the framing and quantification tables.
string m_respBasisFunctionsFile
int GetCurrentRespGate(int a_th)
Return the index indicating the current respiratory gate for this thread.
This class is designed to be a mother virtual class for DataFile.
int SetSPECTIsotope(int a_bed, const string &a_isotope)
int SetPETIsotope(int a_bed, const string &a_isotope)
FLTNB GetListPMotionWeightInFrameForLMS(int a_fr, int a_pmsset)
void SetNbCardGates(int a_nbCardGates)
oImageDimensionsAndQuantification()
The constructor of oImageDimensionsAndQuantification.
void SetRespMotionFlagOn()
set the respiratory motion flag to 'true'
oDynamicDataManager * mp_DynamicDataManager
int GetNbThreadsForImageComputation()
bool GetIgnoreDecaCorrectionFlag()
int GetPMotionFirstIndexForFrame(int a_fr)
bool IsCardMotionEnabled()
FLTNB GetFrameDurationInSec(int a_bed, int a_frame)
void SetCardMotionFlagOn()
set the cardiac motion flag to 'true'
FLTNB GetBedPosition(int a_bedIndex)
int GetCurrentPMotionIndex(int a_th)
void ResetCurrentDynamicIndices()
FLTNB ** m2p_respBasisFunctions
FLTNB GetTimeBasisCoefficient(int a_timeBasisFunction, int a_timeFrame)
void SetIgnoreNormCorrectionFlag(bool a_ignoreNormCorrectionFlag)
Set the boolean m_ignoreNormCorrectionFlag to a_ignoreNormCorrectionFlag.
This class gathers the information about the dynamic splitting of the data.
bool m_ignoreNormCorrectionFlag
bool m_ignoreRandCorrectionFlag
void SetCardMotionFlagOn()
int GetCurrentCardGate(int a_th)
void ResetCurrentDynamicIndices()
Reset to 0 the multithreaded dynamic arrays gathering the indices of current frame, gates and involuntary motion.
bool m_ignoreAttnCorrectionFlag
FLTNB *** m3p_quantificationFactors
void SetFOVSizeX(FLTNB a_fovSizeX)
uint32_t ** m2p_frameDurationsInMs
bool GetIgnoreCaliCorrectionFlag()
int GetCurrentCardImage(int a_th)
void SetVoxSizeY(FLTNB a_voxSizeY)
void SetnbFramesToSkip(int a_FramesToSkip)
int SetCalibrationFactor(int a_bed, FLTNB a_calibrationFactor)
void CheckNumberOfProjectionThreadsConsistencyWithDataFileSize(vDataFile **a2p_DataFile)
void SetOffsetZ(FLTNB a_offsetZ)
int DealWithBedPositions(vDataFile **a2p_DataFile)
int GetCurrentCardImage(int a_th)
void SetVoxSizeX(FLTNB a_voxSizeX)
int m_nbCardBasisFunctions
int GetPMotionLastIndexForFrame(int a_fr)
void SetNbRespGates(int a_nbRespGates)
void SetNbVoxY(INTNB a_nbVoxY)
int GetNbIPatMotionSubsets()
return the number of involuntary patient motion transformations
bool m_ignoreFdurCorrectionFlag
int GetNbMultiModalImages()
bool m_ignoreCaliCorrectionFlag
void SetTimeBasisFunctions(FLTNB **a_m2pTimeBasisFunctions)
int GetPMotionLastIndexForFrame(int a_fr)
int m_nbThreadsForImageComputation
int m_nbThreadsForProjection
FLTNB GetFrameTimeStartInSec(int a_bed, int a_frame)
int DynamicSwitch(int64_t a_currentEventIndex, uint32_t a_currentTime, int a_bed, int a_th)
FLTNB GetFinalTimeStopInSec(int a_bed)
void SetNbRespBasisFunctions(int a_nbRespBasisFunctions)
FLTNB ** m2p_cardBasisFunctions
bool GetIgnoreAttnCorrectionFlag()
int SetNbThreads(const string &a_nbThreads)
void SetTimeStaticFlag(bool a_flag)
void SetIgnoreScatCorrectionFlag(bool a_ignoreScatCorrectionFlag)
Set the boolean m_ignoreScatCorrectionFlag to a_ignoreScatCorrectionFlag.
~oImageDimensionsAndQuantification()
The destructor of oImageDimensionsAndQuantification.
void SetIgnoreAttnCorrectionFlag(bool a_ignoreAttnCorrectionFlag)
Set the boolean m_ignoreAttnCorrectionFlag to a_ignoreAttnCorrectionFlag.
bool GetIgnoreRandCorrectionFlag()
FLTNB ** m2p_timeBasisFunctions
void SetFOVSizeY(FLTNB a_fovSizeY)
int DynamicSwitch(int64_t a_index, uint32_t a_time, int a_bed, int a_th)
FLTNB GetListPMotionWeightInFrameForLMS(int a_fr, int a_pmsset)
void SetRespBasisFunctions(FLTNB **a_m2pRespBasisFunctions)
void SetNbVoxZ(INTNB a_nbVoxZ)
int GetNb2ndMotImgsForLMS()
return the number of secundary motion (typically cardiac) images to be used in the ImageSpace matrice...
uint32_t GetFrameDurationInMs(int a_bed, int a_frame)
void SetOffsetY(FLTNB a_offsetY)
int ResetQuantificationFactors()
If already initialized, set the quantification factors to 1.
int CheckParameters()
A function used to check the parameters settings.
FLTNB GetFrameTimeStopInSec(int a_bed, int a_frame)
void SetRespMotionFlagOn()
int GetCurrentRespImage(int a_th)
void SetCardStaticFlag(bool a_flag)
uint32_t * GetFramesTimeStopArray(int a_bed)
bool IsCardMotionEnabled()
int GetNbIPatMotionSubsets()
FLTNB GetRespBasisCoefficient(int a_respBasisFunction, int a_respGate)
void SetCardBasisFunctions(FLTNB **a_m2pCardBasisFunctions)
int Initialize()
A function used to initialize all that is needed.
int m_nbRespBasisFunctions
string m_ignoredCorrectionsList
void SetNbCardBasisFunctions(int a_nbCardBasisFunctions)
bool GateDurationProvided()
void SetFOVSizeZ(FLTNB a_fovSizeZ)
int GetNbTimeBasisFunctions()
int GetCurrentTimeFrame(int a_th)
Return the index indicating the current time frame for this thread.
bool GateDurationProvided()
FLTNB GetCardBasisCoefficient(int a_cardBasisFunction, int a_cardGate)
uint32_t ** m2p_frameTimeStartInMs
void SetIgnoreFdurCorrectionFlag(bool a_ignoreFdurCorrectionFlag)
Set the boolean m_ignoreFdurCorrectionFlag to a_ignoreFdurCorrectionFlag.
uint32_t * GetFramesTimeDurationsArray(int a_bed)
bool m_ignoreBratCorrectionFlag
FLTNB GetQuantificationFactor(int a_bed, int a_frame, int a_respGate, int a_cardGate)
bool m_ignoreScatCorrectionFlag
void SetIgnoreBratCorrectionFlag(bool a_ignoreBratCorrectionFlag)
Set the boolean m_ignoreBratCorrectionFlag to a_ignoreBratCorrectionFlag.
int GetCurrentCardGate(int a_th)
bool IsRespMotionEnabled()
int InitDynamicData(string a_pathTo4DDataSplittingFile, int a_respMotionCorrectionFlag, int a_cardMotionCorrectionFlag, int a_invMotionCorrectionFlag, int a_nbRespGates, int a_nbCardGates)
bool IsRespMotionEnabled()
int GetCurrentRespImage(int a_th)
void SetIgnoredCorrections(const string &a_ignoredCorrectionsList)
void SetRespStaticFlag(bool a_flag)
void SetFOVOutMasking(FLTNB a_fovOutPercent, INTNB a_nbSliceOutMask)
void SetNbBeds(int a_nbBeds)
int GetNb1stMotImgsForLMS(int a_fr)
uint32_t ** m2p_frameTimeStopInMs
uint32_t * GetFramesTimeStartsArray(int a_bed)
bool GetIgnoreScatCorrectionFlag()
void SetVoxSizeZ(FLTNB a_voxSizeZ)
int ProcessAndSetMask(FLTNB *ap_maskImage)
uint32_t GetFinalTimeStopInMs(int a_bed)
int m_nbTimeBasisFunctions
HPFLTNB GetdurationPerGate(int a_fr, int a_respGate)
int CheckDynamicParameters(int64_t a_nbEvents)
void SetIgnoreCaliCorrectionFlag(bool a_ignoreCaliCorrectionFlag)
Set the boolean m_ignoreCaliCorrectionFlag to a_ignoreCaliCorrectionFlag.
void SetIgnoreRandCorrectionFlag(bool a_ignoreRandCorrectionFlag)
Set the boolean m_ignoreRandCorrectionFlag to a_ignoreRandCorrectionFlag.
void SetCardBasisFunctionsFile(const string &a_cardBasisFunctionsFile)
int GetNbThreadsForProjection()
int GetNb2ndMotImgsForLMS()
void SetIgnoreDecaCorrectionFlag(bool a_ignoreDecaCorrectionFlag)
Set the boolean m_ignoreDecaCorrectionFlag to a_ignoreDecaCorrectionFlag.
void SetNbVoxX(INTNB a_nbVoxX)
void SetOffsetX(FLTNB a_offsetX)
This class is designed to manage all dimensions and quantification related stuff. ...
uint32_t GetFrameTimeStopInMs(int a_bed, int a_frame)
HPFLTNB GetDurationPerGate(int a_fr, int a_respGate)
int GetCurrentRespGate(int a_th)
bool GetIgnoreFdurCorrectionFlag()
void SetFrames(const string &a_frameList)
void SetNbTimeBasisFunctions(int a_nbTimeBasisFunctions)
bool GetProvidedBedPositionFlag()
INTNB GetNbSliceOutMask()
void SetNbMultiModalImages(int a_nbMultiModalImages)
int GetCurrentTimeFrame(int a_th)
void SetDefault()
A function used to set number of threads and MPI instances to 1 and bypass the CheckParameters() func...
void SetVerbose(int a_verbose)
bool m_ignoreDecaCorrectionFlag
int SetAcquisitionTime(int a_bed, FLTNB a_timeStartInSec, FLTNB a_durationInSec, string a_GateListDurationsInSec)
int InitializeIgnoredCorrections()
A function used to initialize the ignored corrections.
bool IsVoxelMasked(INTNB a_voxIndex)
void SetMPIRankAndSize(int a_mpiRank, int a_mpiSize)
void SetRespBasisFunctionsFile(const string &a_respBasisFunctionsFile)
int GetPMotionFirstIndexForFrame(int a_fr)
bool m_providedBedPosition
bool GetIgnoreBratCorrectionFlag()
int GetNbCardBasisFunctions()
int GetNbRespBasisFunctions()
int GetNb1stMotImgsForLMS(int a_fr)
int SetFlipOut(const string &a_flipOut)
void SetPMotionFlagOn()
set the involuntary patient motion flag to 'true'
int GetCurrentPMotionIndex(int a_th)
int SetDynamicSpecificQuantificationFactors(const string &a_quantificationFile)
bool GetIgnoreNormCorrectionFlag()