ITK  5.2.0
Insight Toolkit
Public Types | Public Member Functions | Protected Member Functions | List of all members
itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType > Class Template Referenceabstract

#include <itkSingleValuedCostFunctionv4.h>

+ Inheritance diagram for itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >:
+ Collaboration diagram for itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >:

Public Types

using ConstPointer = SmartPointer< const Self >
 
using DerivativeType = Array< TInternalComputationValueType >
 
using MeasureType = TInternalComputationValueType
 
using ParametersType = typename Superclass::ParametersType
 
using Pointer = SmartPointer< Self >
 
using Self = SingleValuedCostFunctionv4Template
 
using Superclass = CostFunctionTemplate< TInternalComputationValueType >
 
- Public Types inherited from itk::CostFunctionTemplate< TInternalComputationValueType >
using ConstPointer = SmartPointer< const Self >
 
using ParametersType = OptimizerParameters< TInternalComputationValueType >
 
using ParametersValueType = TInternalComputationValueType
 
using Pointer = SmartPointer< Self >
 
using Self = CostFunctionTemplate
 
using Superclass = Object
 
- Public Types inherited from itk::Object
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = Object
 
using Superclass = LightObject
 
- Public Types inherited from itk::LightObject
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = LightObject
 

Public Member Functions

virtual const char * GetNameOfClass () const
 
virtual MeasureType GetValue () const =0
 
virtual void GetValueAndDerivative (MeasureType &value, DerivativeType &derivative) const =0
 
- Public Member Functions inherited from itk::CostFunctionTemplate< TInternalComputationValueType >
virtual unsigned int GetNumberOfParameters () const =0
 
- Public Member Functions inherited from itk::Object
unsigned long AddObserver (const EventObject &event, Command *)
 
unsigned long AddObserver (const EventObject &event, Command *) const
 
unsigned long AddObserver (const EventObject &event, std::function< void(const EventObject &)> function) const
 
LightObject::Pointer CreateAnother () const override
 
virtual void DebugOff () const
 
virtual void DebugOn () const
 
CommandGetCommand (unsigned long tag)
 
bool GetDebug () const
 
MetaDataDictionaryGetMetaDataDictionary ()
 
const MetaDataDictionaryGetMetaDataDictionary () const
 
virtual ModifiedTimeType GetMTime () const
 
virtual const TimeStampGetTimeStamp () const
 
bool HasObserver (const EventObject &event) const
 
void InvokeEvent (const EventObject &)
 
void InvokeEvent (const EventObject &) const
 
virtual void Modified () const
 
void Register () const override
 
void RemoveAllObservers ()
 
void RemoveObserver (unsigned long tag)
 
void SetDebug (bool debugFlag) const
 
void SetReferenceCount (int) override
 
void UnRegister () const noexcept override
 
void SetMetaDataDictionary (const MetaDataDictionary &rhs)
 
void SetMetaDataDictionary (MetaDataDictionary &&rrhs)
 
virtual void SetObjectName (std::string _arg)
 
virtual const std::string & GetObjectName () const
 
- Public Member Functions inherited from itk::LightObject
Pointer Clone () const
 
virtual void Delete ()
 
virtual int GetReferenceCount () const
 
void Print (std::ostream &os, Indent indent=0) const
 

Protected Member Functions

 SingleValuedCostFunctionv4Template ()=default
 
 ~SingleValuedCostFunctionv4Template () override=default
 
- Protected Member Functions inherited from itk::CostFunctionTemplate< TInternalComputationValueType >
 CostFunctionTemplate ()=default
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
 ~CostFunctionTemplate () override=default
 
- Protected Member Functions inherited from itk::Object
 Object ()
 
 ~Object () override
 
bool PrintObservers (std::ostream &os, Indent indent) const
 
virtual void SetTimeStamp (const TimeStamp &timeStamp)
 
- Protected Member Functions inherited from itk::LightObject
virtual LightObject::Pointer InternalClone () const
 
 LightObject ()
 
virtual void PrintHeader (std::ostream &os, Indent indent) const
 
virtual void PrintTrailer (std::ostream &os, Indent indent) const
 
virtual ~LightObject ()
 

Additional Inherited Members

- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool val)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 
- Protected Attributes inherited from itk::LightObject
std::atomic< int > m_ReferenceCount
 

Detailed Description

template<typename TInternalComputationValueType>
class itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >

This class is a base for a CostFunction that returns a single value.

This class differs from the SingleValuedCostFunction in that it is fine tunned for managing very large numbers of parameters. For example, to be used in conditions where the number of parameters is in the range of thousands or even millions. Due to the large number of parameters, the API of this class avoids any copying of the parameters array, and of the classes that have dimensionality related to the size of the parameters array.

As you look at the code of this class, keep in mind that the types ParametersType and DerivativeType will be some sort of array-like type with millions of elements.

Derived classes must provide implementations for: GetValue GetValueAndDerivative

Definition at line 50 of file itkSingleValuedCostFunctionv4.h.

Member Typedef Documentation

◆ ConstPointer

template<typename TInternalComputationValueType>
using itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::ConstPointer = SmartPointer<const Self>

Definition at line 59 of file itkSingleValuedCostFunctionv4.h.

◆ DerivativeType

template<typename TInternalComputationValueType>
using itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::DerivativeType = Array<TInternalComputationValueType>

DerivativeType type alias. It defines a type used to return the cost function derivative.

Definition at line 74 of file itkSingleValuedCostFunctionv4.h.

◆ MeasureType

template<typename TInternalComputationValueType>
using itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::MeasureType = TInternalComputationValueType

MeasureType type alias. It defines a type used to return the cost function value.

Definition at line 66 of file itkSingleValuedCostFunctionv4.h.

◆ ParametersType

template<typename TInternalComputationValueType>
using itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::ParametersType = typename Superclass::ParametersType

ParametersType type alias. It defines a position in the optimization search space.

Definition at line 70 of file itkSingleValuedCostFunctionv4.h.

◆ Pointer

template<typename TInternalComputationValueType>
using itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::Pointer = SmartPointer<Self>

Definition at line 58 of file itkSingleValuedCostFunctionv4.h.

◆ Self

template<typename TInternalComputationValueType>
using itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::Self = SingleValuedCostFunctionv4Template

Standard class type aliases.

Definition at line 56 of file itkSingleValuedCostFunctionv4.h.

◆ Superclass

template<typename TInternalComputationValueType>
using itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::Superclass = CostFunctionTemplate<TInternalComputationValueType>

Definition at line 57 of file itkSingleValuedCostFunctionv4.h.

Constructor & Destructor Documentation

◆ SingleValuedCostFunctionv4Template()

template<typename TInternalComputationValueType>
itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::SingleValuedCostFunctionv4Template ( )
protecteddefault

◆ ~SingleValuedCostFunctionv4Template()

template<typename TInternalComputationValueType>
itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::~SingleValuedCostFunctionv4Template ( )
overrideprotecteddefault

Member Function Documentation

◆ GetNameOfClass()

template<typename TInternalComputationValueType>
virtual const char* itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods).

Reimplemented from itk::CostFunctionTemplate< TInternalComputationValueType >.

Reimplemented in itk::ImageToImageMetricv4< TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits >, itk::MattesMutualInformationImageToImageMetricv4< TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits >, itk::ANTSNeighborhoodCorrelationImageToImageMetricv4< TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits >, itk::ObjectToObjectMultiMetricv4< TFixedDimension, TMovingDimension, TVirtualImage, TInternalComputationValueType >, itk::ObjectToObjectMetric< TFixedDimension, TMovingDimension, TVirtualImage, TParametersValueType >, itk::ObjectToObjectMetric< TFixedDimension, TMovingDimension, TVirtualImage, TInternalComputationValueType >, itk::ObjectToObjectMetric< TPointSet ::PointDimension, TPointSet ::PointDimension, Image< TInternalComputationValueType, TPointSet ::PointDimension >, TInternalComputationValueType >, itk::ObjectToObjectMetric< TFixedImage::ImageDimension, TMovingImage::ImageDimension, TVirtualImage, TInternalComputationValueType >, itk::ObjectToObjectMetric< TFixedPointSet::PointDimension, TMovingPointSet::PointDimension, Image< TInternalComputationValueType, TFixedPointSet::PointDimension >, TInternalComputationValueType >, itk::ObjectToObjectMetricBaseTemplate< TInternalComputationValueType >, itk::ObjectToObjectMetricBaseTemplate< TParametersValueType >, itk::CorrelationImageToImageMetricv4< TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits >, itk::PointSetToPointSetMetricWithIndexv4< TFixedPointSet, TMovingPointSet, TInternalComputationValueType >, itk::PointSetToPointSetMetricWithIndexv4< TPointSet, TPointSet, TInternalComputationValueType >, itk::JensenHavrdaCharvatTsallisPointSetToPointSetMetricv4< TPointSet, TInternalComputationValueType >, itk::PointSetToPointSetMetricv4< TFixedPointSet, TMovingPointSet, TInternalComputationValueType >, itk::PointSetToPointSetMetricv4< TPointSet, TPointSet, TInternalComputationValueType >, itk::DemonsImageToImageMetricv4< TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits >, itk::LabeledPointSetToPointSetMetricv4< TFixedPointSet, TMovingPointSet, TInternalComputationValueType >, itk::JointHistogramMutualInformationImageToImageMetricv4< TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits >, itk::ExpectationBasedPointSetToPointSetMetricv4< TFixedPointSet, TMovingPointSet, TInternalComputationValueType >, itk::MeanSquaresImageToImageMetricv4< TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits >, and itk::EuclideanDistancePointSetToPointSetMetricv4< TFixedPointSet, TMovingPointSet, TInternalComputationValueType >.

◆ GetValue()

template<typename TInternalComputationValueType>
virtual MeasureType itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::GetValue ( ) const
pure virtual

◆ GetValueAndDerivative()

template<typename TInternalComputationValueType>
virtual void itk::SingleValuedCostFunctionv4Template< TInternalComputationValueType >::GetValueAndDerivative ( MeasureType value,
DerivativeType derivative 
) const
pure virtual

This method returns the value and derivative of the cost function. derivative will be sized and allocated as needed by metric. If it's already proper size, no new allocation is done.


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