Medical Imaging Interaction Toolkit  2018.4.99-b20efe7f
Medical Imaging Interaction Toolkit
mitkNavigationDataEvaluationFilter.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 
14 #ifndef MITKNavigationDataEvaluationFilter_H_HEADER_INCLUDED_
15 #define MITKNavigationDataEvaluationFilter_H_HEADER_INCLUDED_
16 
18 #include <mitkPointSet.h>
19 #include <itkQuaternionRigidTransform.h>
20 #include <itkTransform.h>
21 
22 
23 namespace mitk {
24 
32  {
33 
34  public:
35 
37  itkFactorylessNewMacro(Self);
38  itkCloneMacro(Self);
39 
41  void ResetStatistic();
42 
44  int GetNumberOfAnalysedNavigationData(int input);
46  int GetNumberOfInvalidSamples(int input);
48  double GetPercentageOfInvalidSamples(int input);
50  mitk::Point3D GetPositionMean(int input);
52  mitk::Vector3D GetPositionStandardDeviation(int input);
54  mitk::Vector3D GetPositionSampleStandardDeviation(int input);
55 
57  mitk::Quaternion GetQuaternionMean(int input);
59  mitk::Quaternion GetQuaternionStandardDeviation(int input);
61  mitk::Vector3D GetEulerAnglesMean(int input);
63  double GetEulerAnglesRMS(int input);
65  double GetEulerAnglesRMSDegree(int input);
66 
68  double GetPositionErrorMean(int input);
70  double GetPositionErrorStandardDeviation(int input);
72  double GetPositionErrorSampleStandardDeviation(int input);
74  double GetPositionErrorRMS(int input);
76  double GetPositionErrorMedian(int input);
78  double GetPositionErrorMax(int input);
80  double GetPositionErrorMin(int input);
81 
83  mitk::Point3D GetLoggedPosition(unsigned int i, int input);
84 
86  mitk::Quaternion GetLoggedOrientation(unsigned int i, int input);
87 
88  protected:
89 
92 
98  void GenerateData() override;
99 
101  void CreateMembersForAllInputs();
102 
103 
104  std::map<std::size_t,std::vector<mitk::Point3D> > m_LoggedPositions; //a map here, to have one list for every navigation data
105  std::map<std::size_t,std::vector<mitk::Quaternion> > m_LoggedQuaternions;
106  std::map<std::size_t,int> m_InvalidSamples;
107 
108  mitk::Quaternion GetMean(std::vector<mitk::Quaternion> list);
109 
110  mitk::PointSet::Pointer VectorToPointSet(std::vector<mitk::Point3D> pSet);
111 
112  mitk::PointSet::Pointer VectorToPointSet(std::vector<mitk::Vector3D> pSet);
113 
115  std::vector<mitk::Vector3D> QuaternionsToEulerAngles(std::vector<mitk::Quaternion> quaterions); //in radians
116  std::vector<mitk::Vector3D> QuaternionsToEulerAnglesGrad(std::vector<mitk::Quaternion> quaterions); //in degree
117 
118  };
119 } // namespace mitk
120 
121 #endif /* MITKNavigationDataEvaluationFilter_H_HEADER_INCLUDED_ */
std::map< std::vcl_size_t, std::vector< mitk::Quaternion > > m_LoggedQuaternions
NavigationDataToNavigationDataFilter is the base class of all filters that receive NavigationDatas as...
DataCollection - Class to facilitate loading/accessing structured data.
#define MITKIGT_EXPORT
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:40
vnl_quaternion< ScalarType > Quaternion
std::map< std::vcl_size_t, std::vector< mitk::Point3D > > m_LoggedPositions
NavigationDataEvaluationFilter calculates statistical data (mean value, mean error, etc.) on the input navigation data. Input navigation data are set 1:1 on output navigation data.