Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkModelTraitsInterface.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef mitkModelTraitsInterface_h
14 #define mitkModelTraitsInterface_h
15 
16 #include <MitkModelFitExports.h>
17 
18 #include <itkArray.h>
19 #include <itkArray2D.h>
20 #include <itkObject.h>
21 
22 namespace mitk
23 {
37  {
38  public:
39 
41  typedef itk::Array<double> ModelResultType;
43  using ParameterValueType = double;
45  typedef itk::Array<ParameterValueType> ParametersType;
46 
48  typedef std::string ParameterNameType;
50  typedef std::vector<ParameterNameType> ParameterNamesType;
52  typedef ParametersType::SizeValueType ParametersSizeType;
57 
59  typedef std::map<ParameterNameType, double> ParamterScaleMapType;
61  typedef std::map<ParameterNameType, std::string> ParamterUnitMapType;
63  typedef std::map<ParameterNameType, double> DerivedParamterScaleMapType;
65  typedef std::map<ParameterNameType, std::string> DerivedParamterUnitMapType;
66 
68  typedef std::string FunctionStringType;
70  typedef std::string ModellClassIDType;
71 
78 
85 
91 
97 
103 
109 
115 
121 
126  virtual std::string GetModelDisplayName() const = 0;
127 
132  virtual std::string GetModelType() const = 0;
133 
139 
144  virtual ModellClassIDType GetClassID() const = 0;
145 
150  virtual std::string GetXName() const = 0;
151 
156  virtual std::string GetXAxisName() const = 0;
157 
162  virtual std::string GetXAxisUnit() const = 0;
163 
168  virtual std::string GetYAxisName() const = 0;
169 
174  virtual std::string GetYAxisUnit() const = 0;
175 
176  protected:
178  virtual ~ModelTraitsInterface() {};
179 
180  private:
181 
182  //No copy constructor allowed
184  void operator=(const ModelTraitsInterface&); //purposely not implemented
185  };
186 }
187 
188 #endif
#define MITKMODELFIT_EXPORT
Pure virtual interface that defines the traits (metadata) of a model used for fitting.
std::map< ParameterNameType, double > ParamterScaleMapType
Map type associating parameter names to their scaling factors.
std::string FunctionStringType
Type for the function string representation of the model.
virtual std::string GetYAxisUnit() const =0
Returns the unit of the y-axis.
virtual std::string GetModelType() const =0
Returns the type/category string of the model (e.g. "Linear", "Pharmacokinetic").
virtual DerivedParametersSizeType GetNumberOfDerivedParameters() const =0
Returns the number of derived parameters that can be computed by the model.
virtual std::string GetYAxisName() const =0
Returns the display name of the y-axis (e.g. "Signal Intensity").
ParametersType::SizeValueType ParametersSizeType
Type for the count of parameters.
itk::Array< double > ModelResultType
Type representing the model output signal as an array of doubles.
ParametersSizeType DerivedParametersSizeType
Type for the count of derived parameters.
virtual ParametersSizeType GetNumberOfParameters() const =0
Returns the number of parameters that must be defined when using the model to compute the signal (Get...
std::map< ParameterNameType, std::string > ParamterUnitMapType
Map type associating parameter names to their unit strings.
virtual std::string GetModelDisplayName() const =0
Returns the human-readable display name of the model.
virtual DerivedParameterNamesType GetDerivedParameterNames() const =0
Returns the names of derived parameters that can be computed by the model.
virtual ModellClassIDType GetClassID() const =0
Returns the unique class identifier for this model type.
virtual std::string GetXName() const =0
Returns the name of the independent variable used by the model (e.g. "x").
virtual ParamterUnitMapType GetParameterUnits() const =0
Returns the unit strings for all model parameters.
std::string ModellClassIDType
Type for the unique class identifier of the model.
virtual ParamterScaleMapType GetParameterScales() const =0
Returns the scaling factors for all model parameters.
virtual FunctionStringType GetFunctionString() const =0
Returns a parsable function string representing the model equation.
virtual DerivedParamterScaleMapType GetDerivedParameterScales() const =0
Returns the scaling factors for all derived parameters.
itk::Array< ParameterValueType > ParametersType
Type representing a vector of parameter values.
std::string ParameterNameType
Type used for parameter names.
std::map< ParameterNameType, std::string > DerivedParamterUnitMapType
Map type associating derived parameter names to their unit strings.
virtual std::string GetXAxisUnit() const =0
Returns the unit of the x-axis (e.g. "s", "ms").
double ParameterValueType
Type of a single parameter value.
std::map< ParameterNameType, double > DerivedParamterScaleMapType
Map type associating derived parameter names to their scaling factors.
virtual std::string GetXAxisName() const =0
Returns the display name of the x-axis (e.g. "Time").
ParameterNamesType DerivedParameterNamesType
Type for a list of derived parameter names.
virtual ParameterNamesType GetParameterNames() const =0
Returns the names of parameters that must be defined when using the model to compute the signal (GetS...
virtual DerivedParamterUnitMapType GetDerivedParameterUnits() const =0
Returns the unit strings for all derived parameters.
std::vector< ParameterNameType > ParameterNamesType
Type for a list of parameter names.
Find image slices visible on a given plane.