|
Medical Imaging Interaction Toolkit
2018.4.99-389bf124
Medical Imaging Interaction Toolkit
|
Container class for storing the computed image statistics. More...
#include <mitkImageStatisticsContainer.h>
Public Types | |
| using | StatisticNameVector = std::vector< std::string > |
Public Member Functions | |
| ImageStatisticsObject () | |
| void | AddStatistic (const std::string &key, StatisticsVariantType value) |
| Adds a statistic to the statistics object. More... | |
| const StatisticNameVector & | GetCustomStatisticNames () const |
| Returns the names of all custom statistics (defined at runtime and no default names). More... | |
| StatisticNameVector | GetAllStatisticNames () const |
| Returns the names of all statistics (default and custom defined) Additional custom keys are added at the end in a sorted order. More... | |
| StatisticNameVector | GetExistingStatisticNames () const |
| bool | HasStatistic (const std::string &name) const |
| template<typename TType > | |
| TType | GetValueConverted (const std::string &name) const |
| Converts the requested value to the defined type. More... | |
| StatisticsVariantType | GetValueNonConverted (const std::string &name) const |
| Returns the requested value. More... | |
| void | Reset () |
Static Public Member Functions | |
| static const StatisticNameVector & | GetDefaultStatisticNames () |
| Returns the names of the default statistics. More... | |
Public Attributes | |
| HistogramType::ConstPointer | m_Histogram |
Container class for storing the computed image statistics.
The statistics are stored in a map <name,value> with value as boost::variant<RealType, VoxelCountType, IndexType >. The type used to create the boost::variant is important as only this type can be recovered lateron.
Definition at line 61 of file mitkImageStatisticsContainer.h.
| using mitk::ImageStatisticsContainer::ImageStatisticsObject::StatisticNameVector = std::vector<std::string> |
Definition at line 70 of file mitkImageStatisticsContainer.h.
| mitk::ImageStatisticsContainer::ImageStatisticsObject::ImageStatisticsObject | ( | ) |
Definition at line 39 of file mitkImageStatisticsContainer.cpp.
References mitk::ImageStatisticsContainer::Reset().
| void mitk::ImageStatisticsContainer::ImageStatisticsObject::AddStatistic | ( | const std::string & | key, |
| StatisticsVariantType | value | ||
| ) |
Adds a statistic to the statistics object.
if already a statistic with that name is included, it is overwritten
Definition at line 41 of file mitkImageStatisticsContainer.cpp.
Referenced by mitk::ComputeIntensityProfileStatistics(), mitk::PointSetDifferenceStatisticsCalculator::ComputeStatistics(), and mitk::ImageStatisticsCalculator::GetStatistics().
| ImageStatisticsContainer::ImageStatisticsObject::StatisticNameVector mitk::ImageStatisticsContainer::ImageStatisticsObject::GetAllStatisticNames | ( | ) | const |
Returns the names of all statistics (default and custom defined) Additional custom keys are added at the end in a sorted order.
Definition at line 67 of file mitkImageStatisticsContainer.cpp.
| const ImageStatisticsContainer::ImageStatisticsObject::StatisticNameVector & mitk::ImageStatisticsContainer::ImageStatisticsObject::GetCustomStatisticNames | ( | ) | const |
Returns the names of all custom statistics (defined at runtime and no default names).
Definition at line 61 of file mitkImageStatisticsContainer.cpp.
Referenced by mitk::GetAllStatisticNames().
|
static |
Returns the names of the default statistics.
The order is derived from the image statistics plugin.
Definition at line 55 of file mitkImageStatisticsContainer.cpp.
Referenced by mitk::GetAllStatisticNames().
| ImageStatisticsContainer::ImageStatisticsObject::StatisticNameVector mitk::ImageStatisticsContainer::ImageStatisticsObject::GetExistingStatisticNames | ( | ) | const |
Definition at line 77 of file mitkImageStatisticsContainer.cpp.
|
inline |
Converts the requested value to the defined type.
| name | defined string on creation (AddStatistic) |
| if | no statistics with key name was found. |
Definition at line 99 of file mitkImageStatisticsContainer.h.
Referenced by mitk::PointSetDifferenceStatisticsCalculator::GetMax(), mitk::PointSetDifferenceStatisticsCalculator::GetMean(), mitk::PointSetDifferenceStatisticsCalculator::GetMedian(), mitk::PointSetDifferenceStatisticsCalculator::GetMin(), mitk::PointSetDifferenceStatisticsCalculator::GetNumberOfPoints(), mitk::PointSetDifferenceStatisticsCalculator::GetRMS(), mitk::PointSetDifferenceStatisticsCalculator::GetSD(), and mitk::PointSetDifferenceStatisticsCalculator::GetVariance().
| ImageStatisticsContainer::StatisticsVariantType mitk::ImageStatisticsContainer::ImageStatisticsObject::GetValueNonConverted | ( | const std::string & | name | ) | const |
Returns the requested value.
| if | no statistics with key name was found. |
Definition at line 93 of file mitkImageStatisticsContainer.cpp.
References mitkThrow.
Referenced by QmitkStatisticsCalculator::ComputeLesionVolume(), and QmitkImageStatisticsTreeItem::data().
| bool mitk::ImageStatisticsContainer::ImageStatisticsObject::HasStatistic | ( | const std::string & | name | ) | const |
Definition at line 88 of file mitkImageStatisticsContainer.cpp.
Referenced by QmitkStatisticsCalculator::ComputeLesionVolume(), and QmitkImageStatisticsTreeItem::data().
| void mitk::ImageStatisticsContainer::ImageStatisticsObject::Reset | ( | void | ) |
Definition at line 106 of file mitkImageStatisticsContainer.cpp.
| HistogramType::ConstPointer mitk::ImageStatisticsContainer::ImageStatisticsObject::m_Histogram |
Definition at line 113 of file mitkImageStatisticsContainer.h.
Referenced by mitk::ImageStatisticsCalculator::GetStatistics().