Medical Imaging Interaction Toolkit  2018.4.99-6a3ea89d
Medical Imaging Interaction Toolkit
mitk::AIFBasedModelBase Class Reference

Base Class for all physiological perfusion models using an Aterial Input Function All AIF based models come with an array of AIF values and the corresponding TimeGrid ( AIF(t)) This class provides functions for setting the AIF Values and optionally a specific AIF TimeGrid. It also provides a method for interpolation of the AIF source array to a specified Timegrid that differs from AIFTimeGrid. The AIF must be set with an itk::Array. If no AIFTimeGrid is specified with the Setter, it is assumed that the AIFTimeGrid is the same as the ModelTimegrid (e.g. AIF is derived from data set to be fitted). In this case, AIFvalues must have the same length as ModelTimeGrid, otherwise an exception is generated. More...

#include <mitkAIFBasedModelBase.h>

Inheritance diagram for mitk::AIFBasedModelBase:
Collaboration diagram for mitk::AIFBasedModelBase:

Public Types

typedef AIFBasedModelBase Self
 
typedef ModelBase Superclass
 
typedef itk::SmartPointer< SelfPointer
 
typedef itk::SmartPointer< const SelfConstPointer
 
typedef itk::Array< double > AterialInputFunctionType
 
- Public Types inherited from mitk::ModelBase
typedef ModelBase Self
 
typedef itk::Object Superclass
 
typedef itk::SmartPointer< SelfPointer
 
typedef itk::SmartPointer< const SelfConstPointer
 
typedef ModelTraitsInterface::ModelResultType ModelResultType
 
typedef ModelTraitsInterface::ParameterValueType ParameterValueType
 
typedef ModelTraitsInterface::ParametersType ParametersType
 
typedef itk::Array< double > TimeGridType
 
typedef ModelTraitsInterface::ParameterNameType ParameterNameType
 
typedef ModelTraitsInterface::ParameterNamesType ParameterNamesType
 
typedef ModelTraitsInterface::ParametersSizeType ParametersSizeType
 
typedef ModelTraitsInterface::DerivedParameterNamesType DerivedParameterNamesType
 
typedef ModelTraitsInterface::DerivedParametersSizeType DerivedParametersSizeType
 
typedef double StaticParameterValueType
 
typedef std::vector< StaticParameterValueTypeStaticParameterValuesType
 
typedef std::map< ParameterNameType, StaticParameterValuesTypeStaticParameterMapType
 
typedef double DerivedParameterValueType
 
typedef std::map< ParameterNameType, DerivedParameterValueTypeDerivedParameterMapType
 
- Public Types inherited from mitk::ModelTraitsInterface
typedef itk::Array< double > ModelResultType
 
using ParameterValueType = double
 
typedef itk::Array< ParameterValueTypeParametersType
 
typedef std::string ParameterNameType
 
typedef std::vector< ParameterNameTypeParameterNamesType
 
typedef ParametersType::SizeValueType ParametersSizeType
 
typedef ParameterNamesType DerivedParameterNamesType
 
typedef ParametersSizeType DerivedParametersSizeType
 
typedef std::map< ParameterNameType, double > ParamterScaleMapType
 
typedef std::map< ParameterNameType, std::string > ParamterUnitMapType
 
typedef std::map< ParameterNameType, double > DerivedParamterScaleMapType
 
typedef std::map< ParameterNameType, std::string > DerivedParamterUnitMapType
 
typedef std::string FunctionStringType
 
typedef std::string ModellClassIDType
 

Public Member Functions

virtual const char * GetClassName () const
 
virtual const AterialInputFunctionTypeGetAterialInputFunctionValues ()
 
virtual const TimeGridTypeGetAterialInputFunctionTimeGrid ()
 
virtual void SetAterialInputFunctionValues (AterialInputFunctionType _arg)
 
virtual void SetAterialInputFunctionTimeGrid (TimeGridType _arg)
 
std::string GetXAxisName () const override
 
std::string GetXAxisUnit () const override
 
std::string GetYAxisName () const override
 
std::string GetYAxisUnit () const override
 
const TimeGridTypeGetCurrentAterialInputFunctionTimeGrid () const
 
const AterialInputFunctionType GetAterialInputFunction (TimeGridType currentTimeGrid) const
 
ParameterNamesType GetStaticParameterNames () const override
 
ParametersSizeType GetNumberOfStaticParameters () const override
 
ParamterUnitMapType GetStaticParameterUnits () const override
 
- Public Member Functions inherited from mitk::ModelBase
ParamterScaleMapType GetParameterScales () const override
 
ParamterUnitMapType GetParameterUnits () const override
 
DerivedParamterScaleMapType GetDerivedParameterScales () const override
 
DerivedParamterUnitMapType GetDerivedParameterUnits () const override
 
std::string GetModelDisplayName () const override
 
std::string GetModelType () const override
 
FunctionStringType GetFunctionString () const override
 
ModellClassIDType GetClassID () const override
 
std::string GetXName () const override
 
DerivedParameterNamesType GetDerivedParameterNames () const override
 
DerivedParametersSizeType GetNumberOfDerivedParameters () const override
 
void SetStaticParameters (const StaticParameterMapType &parameters, bool allParameters=true)
 
StaticParameterMapType GetStaticParameters () const
 
DerivedParameterMapType GetDerivedParameters (const ParametersType &parameters) const
 
virtual void SetTimeGrid (const TimeGridType &grid)
 
virtual const TimeGridTypeGetTimeGrid ()
 
ModelResultType GetSignal (const ParametersType &parameters) const
 
- Public Member Functions inherited from mitk::ModelTraitsInterface
virtual ParameterNamesType GetParameterNames () const =0
 
virtual ParametersSizeType GetNumberOfParameters () const =0
 

Static Public Attributes

static const std::string NAME_STATIC_PARAMETER_AIF
 
static const std::string NAME_STATIC_PARAMETER_AIFTimeGrid
 
static const std::string UNIT_STATIC_PARAMETER_AIF
 
static const std::string UNIT_STATIC_PARAMETER_AIFTimeGrid
 

Protected Member Functions

 AIFBasedModelBase ()
 
 ~AIFBasedModelBase () override
 
bool ValidateModel (std::string &error) const override
 
void PrintSelf (std::ostream &os, ::itk::Indent indent) const override
 
void SetStaticParameter (const ParameterNameType &name, const StaticParameterValuesType &values) override
 
StaticParameterValuesType GetStaticParameterValue (const ParameterNameType &name) const override
 
- Protected Member Functions inherited from mitk::ModelBase
virtual ModelResultType ComputeModelfunction (const ParametersType &parameters) const =0
 
virtual DerivedParameterMapType ComputeDerivedParameters (const ParametersType &parameters) const
 
 ModelBase ()
 
 ~ModelBase () override
 
void PrintSelf (std::ostream &os, ::itk::Indent indent) const override
 
- Protected Member Functions inherited from mitk::ModelTraitsInterface
 ModelTraitsInterface ()
 
virtual ~ModelTraitsInterface ()
 

Protected Attributes

TimeGridType m_AterialInputFunctionTimeGrid
 
AterialInputFunctionType m_AterialInputFunctionValues
 
- Protected Attributes inherited from mitk::ModelBase
TimeGridType m_TimeGrid
 

Detailed Description

Base Class for all physiological perfusion models using an Aterial Input Function All AIF based models come with an array of AIF values and the corresponding TimeGrid ( AIF(t)) This class provides functions for setting the AIF Values and optionally a specific AIF TimeGrid. It also provides a method for interpolation of the AIF source array to a specified Timegrid that differs from AIFTimeGrid. The AIF must be set with an itk::Array. If no AIFTimeGrid is specified with the Setter, it is assumed that the AIFTimeGrid is the same as the ModelTimegrid (e.g. AIF is derived from data set to be fitted). In this case, AIFvalues must have the same length as ModelTimeGrid, otherwise an exception is generated.

Definition at line 31 of file mitkAIFBasedModelBase.h.

Member Typedef Documentation

◆ AterialInputFunctionType

Typedef for Aterial InputFunction AIF(t)

Definition at line 52 of file mitkAIFBasedModelBase.h.

◆ ConstPointer

◆ Pointer

◆ Self

◆ Superclass

Constructor & Destructor Documentation

◆ AIFBasedModelBase()

mitk::AIFBasedModelBase::AIFBasedModelBase ( )
protected

Definition at line 49 of file mitkAIFBasedModelBase.cpp.

◆ ~AIFBasedModelBase()

mitk::AIFBasedModelBase::~AIFBasedModelBase ( )
overrideprotected

Definition at line 53 of file mitkAIFBasedModelBase.cpp.

Member Function Documentation

◆ GetAterialInputFunction()

◆ GetAterialInputFunctionTimeGrid()

virtual const TimeGridType& mitk::AIFBasedModelBase::GetAterialInputFunctionTimeGrid ( )
virtual

◆ GetAterialInputFunctionValues()

virtual const AterialInputFunctionType& mitk::AIFBasedModelBase::GetAterialInputFunctionValues ( )
virtual

◆ GetClassName()

◆ GetCurrentAterialInputFunctionTimeGrid()

const mitk::AIFBasedModelBase::TimeGridType & mitk::AIFBasedModelBase::GetCurrentAterialInputFunctionTimeGrid ( ) const

Returns the TimeGrid used for the AIF. Either the externally set AIF time grid or the time grid of the model if nothing is set.

Definition at line 58 of file mitkAIFBasedModelBase.cpp.

References m_AterialInputFunctionTimeGrid, and mitk::ModelBase::m_TimeGrid.

Referenced by GetAterialInputFunction().

◆ GetNumberOfStaticParameters()

mitk::AIFBasedModelBase::ParametersSizeType mitk::AIFBasedModelBase::GetNumberOfStaticParameters ( ) const
overridevirtual

Returns the number of static parameters that will be used when using the model to compute the signal (but are not defined via GetSignal()).

Implements mitk::ModelBase.

Reimplemented in mitk::NumericTwoCompartmentExchangeModel.

Definition at line 94 of file mitkAIFBasedModelBase.cpp.

◆ GetStaticParameterNames()

mitk::AIFBasedModelBase::ParameterNamesType mitk::AIFBasedModelBase::GetStaticParameterNames ( ) const
overridevirtual

Returns the names of static parameters that will be used when using the model to compute the signal (but are not defined via GetSignal()).

Implements mitk::ModelBase.

Reimplemented in mitk::NumericTwoCompartmentExchangeModel.

Definition at line 84 of file mitkAIFBasedModelBase.cpp.

References NAME_STATIC_PARAMETER_AIF, and NAME_STATIC_PARAMETER_AIFTimeGrid.

◆ GetStaticParameterUnits()

mitk::AIFBasedModelBase::ParamterUnitMapType mitk::AIFBasedModelBase::GetStaticParameterUnits ( ) const
overridevirtual

Default implementation returns no unit string ("") for every defined parameter.

Reimplemented from mitk::ModelBase.

Definition at line 101 of file mitkAIFBasedModelBase.cpp.

References NAME_STATIC_PARAMETER_AIF, NAME_STATIC_PARAMETER_AIFTimeGrid, UNIT_STATIC_PARAMETER_AIF, and UNIT_STATIC_PARAMETER_AIFTimeGrid.

◆ GetStaticParameterValue()

mitk::AIFBasedModelBase::StaticParameterValuesType mitk::AIFBasedModelBase::GetStaticParameterValue ( const ParameterNameType name) const
overrideprotectedvirtual

Helper function called by GetStaticParameters(). Implement in derived classes to realize the concrete retrieval of static parameters.

Implements mitk::ModelBase.

Reimplemented in mitk::NumericTwoCompartmentExchangeModel.

Definition at line 130 of file mitkAIFBasedModelBase.cpp.

References mitk::convertArrayToParameter(), m_AterialInputFunctionTimeGrid, m_AterialInputFunctionValues, NAME_STATIC_PARAMETER_AIF, and NAME_STATIC_PARAMETER_AIFTimeGrid.

◆ GetXAxisName()

std::string mitk::AIFBasedModelBase::GetXAxisName ( ) const
overridevirtual

Default implementation returns an empty string.

Reimplemented from mitk::ModelBase.

Definition at line 29 of file mitkAIFBasedModelBase.cpp.

◆ GetXAxisUnit()

std::string mitk::AIFBasedModelBase::GetXAxisUnit ( ) const
overridevirtual

Default implementation returns an empty string.

Reimplemented from mitk::ModelBase.

Definition at line 34 of file mitkAIFBasedModelBase.cpp.

◆ GetYAxisName()

std::string mitk::AIFBasedModelBase::GetYAxisName ( ) const
overridevirtual

Default implementation returns an empty string.

Reimplemented from mitk::ModelBase.

Definition at line 39 of file mitkAIFBasedModelBase.cpp.

◆ GetYAxisUnit()

std::string mitk::AIFBasedModelBase::GetYAxisUnit ( ) const
overridevirtual

Default implementation returns an empty string.

Reimplemented from mitk::ModelBase.

Definition at line 44 of file mitkAIFBasedModelBase.cpp.

◆ PrintSelf()

◆ SetAterialInputFunctionTimeGrid()

virtual void mitk::AIFBasedModelBase::SetAterialInputFunctionTimeGrid ( TimeGridType  _arg)
virtual

◆ SetAterialInputFunctionValues()

virtual void mitk::AIFBasedModelBase::SetAterialInputFunctionValues ( AterialInputFunctionType  _arg)
virtual

◆ SetStaticParameter()

void mitk::AIFBasedModelBase::SetStaticParameter ( const ParameterNameType name,
const StaticParameterValuesType values 
)
overrideprotectedvirtual

Helper function called by SetStaticParameters(). Implement in derived classes to realize the concrete setting of static parameters.

Implements mitk::ModelBase.

Reimplemented in mitk::NumericTwoCompartmentExchangeModel.

Definition at line 112 of file mitkAIFBasedModelBase.cpp.

References mitk::convertParameterToArray(), NAME_STATIC_PARAMETER_AIF, NAME_STATIC_PARAMETER_AIFTimeGrid, SetAterialInputFunctionTimeGrid(), and SetAterialInputFunctionValues().

◆ ValidateModel()

bool mitk::AIFBasedModelBase::ValidateModel ( std::string &  error) const
overrideprotectedvirtual

Reimplementation that checks if AIF and timegrid settings are valid.

Parameters
[out]errorSet internally to indicate the error reason if method returns false. Is used by GetSignal() for the exception comment.
Returns
Returns true if the model is valid and can compute a signal. Otherwise it returns false.

Reimplemented from mitk::ModelBase.

Definition at line 148 of file mitkAIFBasedModelBase.cpp.

References m_AterialInputFunctionTimeGrid, m_AterialInputFunctionValues, mitk::ModelBase::m_TimeGrid, and mitk::ModelBase::ValidateModel().

Member Data Documentation

◆ m_AterialInputFunctionTimeGrid

◆ m_AterialInputFunctionValues

◆ NAME_STATIC_PARAMETER_AIF

◆ NAME_STATIC_PARAMETER_AIFTimeGrid

◆ UNIT_STATIC_PARAMETER_AIF

const std::string mitk::AIFBasedModelBase::UNIT_STATIC_PARAMETER_AIF
static

Definition at line 48 of file mitkAIFBasedModelBase.h.

Referenced by GetStaticParameterUnits().

◆ UNIT_STATIC_PARAMETER_AIFTimeGrid

const std::string mitk::AIFBasedModelBase::UNIT_STATIC_PARAMETER_AIFTimeGrid
static

Definition at line 49 of file mitkAIFBasedModelBase.h.

Referenced by GetStaticParameterUnits().


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