ITK  4.6.0
Insight Segmentation and Registration Toolkit
itkObjectToObjectMultiMetricv4.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 
19 #ifndef __itkObjectToObjectMultiMetricv4_h
20 #define __itkObjectToObjectMultiMetricv4_h
21 
23 #include "itkArray.h"
24 #include <deque>
25 
26 namespace itk
27 {
92 template<unsigned int TFixedDimension, unsigned int TMovingDimension, typename TVirtualImage = Image<double, TFixedDimension>, class TInternalComputationValueType = double >
94  public ObjectToObjectMetric<TFixedDimension, TMovingDimension, TVirtualImage, TInternalComputationValueType>
95 {
96 public:
102 
105 
107  itkNewMacro( Self );
108 
110  typedef typename Superclass::MeasureType MeasureType;
119 
124  typedef std::deque<MetricBasePointer> MetricQueueType;
125 
126  typedef typename DerivativeType::ValueType WeightValueType;
129 
130  itkSetMacro(MetricWeights,WeightsArrayType);
131  itkGetMacro(MetricWeights,WeightsArrayType);
132 
134  void AddMetric( MetricType* metric );
135 
137  void ClearMetricQueue( void );
138 
141 
142  void Initialize(void) throw ( itk::ExceptionObject );
143 
145  virtual void SetMovingTransform( MovingTransformType * );
146 
148  virtual void SetFixedTransform( FixedTransformType * );
149 
154  MeasureType GetValue() const;
155 
156  virtual void GetDerivative( DerivativeType & ) const;
157 
164  void GetValueAndDerivative(MeasureType & value, DerivativeType & derivative) const;
165 
169 
173 
175  const MetricQueueType & GetMetricQueue() const;
176 
177  virtual bool SupportsArbitraryVirtualDomainSamples( void ) const;
178 
179 protected:
180 
182  virtual ~ObjectToObjectMultiMetricv4();
183  void PrintSelf(std::ostream & os, Indent indent) const;
184 
185 private:
186 
187  //purposely not implemented
188  ObjectToObjectMultiMetricv4(const Self &);
189  void operator=(const Self &);
190 
194 };
195 
196 } //end namespace itk
197 
198 #ifndef ITK_MANUAL_INSTANTIATION
199 #include "itkObjectToObjectMultiMetricv4.hxx"
200 #endif
201 
202 #endif
Light weight base class for most itk classes.
Superclass::NumberOfParametersType NumberOfParametersType
ObjectToObjectMetric< TFixedDimension, TMovingDimension, TVirtualImage, TInternalComputationValueType > Superclass
Transform< TInternalComputationValueType, TVirtualImage::ImageDimension, TFixedDimension > FixedTransformType
SizeValueType GetNumberOfMetrics() const
This class takes one ore more ObjectToObject metrics and assigns weights to their derivatives to comp...
Superclass::ParametersValueType ParametersValueType
Superclass::DerivativeValueType DerivativeValueType
TInternalComputationValueType ParametersValueType
virtual void SetMovingTransform(MovingTransformType *)
MeasureType GetValue() const
Computes similarity between regions of two objects.
unsigned long SizeValueType
Definition: itkIntTypes.h:143
Superclass::CoordinateRepresentationType CoordinateRepresentationType
Superclass::MeasureType MeasureType
Superclass::ParametersType ParametersType
Superclass::DerivativeType DerivativeType
Transform points and vectors from an input space to an output space.
Definition: itkTransform.h:82
Superclass::FixedTransformType FixedTransformType
Transform< TInternalComputationValueType, TVirtualImage::ImageDimension, TMovingDimension > MovingTransformType
Standard exception handling object.
virtual void GetDerivative(DerivativeType &) const
TInternalComputationValueType CoordinateRepresentationType
MetricValueArrayType GetValueArray() const
void PrintSelf(std::ostream &os, Indent indent) const
void AddMetric(MetricType *metric)
Superclass::MovingTransformType MovingTransformType
Superclass::NumberOfParametersType NumberOfParametersType
Control indentation during Print() invocation.
Definition: itkIndent.h:49
MeasureType GetWeightedValue() const
std::deque< MetricBasePointer > MetricQueueType
virtual bool SupportsArbitraryVirtualDomainSamples(void) const
const MetricQueueType & GetMetricQueue() const
void GetValueAndDerivative(MeasureType &value, DerivativeType &derivative) const
Superclass::DerivativeValueType DerivativeValueType
virtual void SetFixedTransform(FixedTransformType *)