ImFusion C++ SDK 4.4.0
ImFusion::ML::PixelwiseClassificationMetrics Class Reference

#include <ImFusion/ML/Metrics.h>

Compute dense classification related metrics between a label map and a ground truth segmentation Precisely, computes the sensitivity, specificity, precision and recall. More...

Inheritance diagram for ImFusion::ML::PixelwiseClassificationMetrics:

Detailed Description

Compute dense classification related metrics between a label map and a ground truth segmentation Precisely, computes the sensitivity, specificity, precision and recall.

Public Member Functions

DataScheme dataScheme () const override
 Returns the expected content of the input data.
std::vector< Record > compute (const DataItem &testItem) const override
 Generic method to compute the metric (each child class may have a dedicated and easier-to-use function) Result type is a vector (one record per frame) of maps (one entry per sub-metric).
std::vector< std::map< std::string, std::map< int, double > > > computePerLabel (const SharedImageSet &prediction, const SharedImageSet &target) const
Public Member Functions inherited from ImFusion::ML::Metric
bool isCompatibleWith (const DataItem &item, bool strictCheck=false) const
 Checks if the input data item is compatible with the template metric.
Public Member Functions inherited from ImFusion::Configurable
virtual void configure (const Properties *p)
 Configure this object instance by de-serializing the given Properties.
virtual void configuration (Properties *p) const
 Serialize the current object configuration into the given Properties object.
virtual void configureDefaults ()
 Retrieve the properties of this object, replaces values with their defaults and sets it again.
void registerParameter (ParameterBase *param)
 Register the given Parameter or SubProperty, so that it will be configured during configure()/configuration().
void unregisterParameter (const ParameterBase *param)
 Remove the given Parameter or SubProperty from the list of registered parameters.
 Configurable (const Configurable &rhs)
 Configurable (Configurable &&rhs) noexcept
Configurable & operator= (const Configurable &)
Configurable & operator= (Configurable &&) noexcept

Additional Inherited Members

Public Types inherited from ImFusion::ML::Metric
using Field = typename DataItem::Field
using DataScheme = std::map<Field, ElementType>
using Record = std::map<std::string, Eigen::MatrixXd>
Public Attributes inherited from ImFusion::Configurable
Signal signalParametersChanged
 Emitted whenever one of the registered Parameters' or SubPropertys' signalValueChanged signal was emitted.
Protected Member Functions inherited from ImFusion::ML::Metric
void assertValidDataScheme (const DataItem &testItem) const
 Asserts if the input data item is compatible with the template metric.
void throwMetricError (std::string msg) const
 Helper function to throw a dedicated error with more info.
Protected Attributes inherited from ImFusion::Configurable
std::vector< Paramm_params
 List of all registered Parameter and SubProperty instances.

Member Function Documentation

◆ dataScheme()

DataScheme ImFusion::ML::PixelwiseClassificationMetrics::dataScheme ( ) const
inlineoverridevirtual

Returns the expected content of the input data.

Implements ImFusion::ML::Metric.

◆ compute()

std::vector< Record > ImFusion::ML::PixelwiseClassificationMetrics::compute ( const DataItem & testItem) const
overridevirtual

Generic method to compute the metric (each child class may have a dedicated and easier-to-use function) Result type is a vector (one record per frame) of maps (one entry per sub-metric).

Implements ImFusion::ML::Metric.


The documentation for this class was generated from the following file:
  • ImFusion/ML/Metrics.h
Search Tab / S to search, Esc to close