ITK  6.0.0
Insight Toolkit
itkLabeledPointSetToPointSetMetricv4.h
Go to the documentation of this file.
1/*=========================================================================
2 *
3 * Copyright NumFOCUS
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 * https://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#ifndef itkLabeledPointSetToPointSetMetricv4_h
19#define itkLabeledPointSetToPointSetMetricv4_h
20
22
23#include <vector>
24
25namespace itk
26{
52template <typename TFixedPointSet,
53 typename TMovingPointSet = TFixedPointSet,
54 class TInternalComputationValueType = double>
55class ITK_TEMPLATE_EXPORT LabeledPointSetToPointSetMetricv4
56 : public PointSetToPointSetMetricv4<TFixedPointSet, TMovingPointSet, TInternalComputationValueType>
57{
58public:
59 ITK_DISALLOW_COPY_AND_MOVE(LabeledPointSetToPointSetMetricv4);
60
66
68 itkNewMacro(Self);
69
71 itkOverrideGetNameOfClassMacro(LabeledPointSetToPointSetMetricv4);
72
73 using FixedPointSetType = TFixedPointSet;
75 using MovingPointSetType = TMovingPointSet;
77
79 using typename Superclass::MeasureType;
80 using typename Superclass::DerivativeType;
81 using typename Superclass::LocalDerivativeType;
82 using typename Superclass::PointType;
83 using typename Superclass::PointIdentifier;
84
85 using LabelType = typename Superclass::PixelType;
86 using LabelSetType = std::vector<LabelType>;
87
90
95 void
96 Initialize() override;
97
103 GetLocalNeighborhoodValue(const PointType &, const LabelType &) const override;
104
109 void
111 MeasureType &,
113 const LabelType &) const override;
114
119 itkSetObjectMacro(PointSetMetric, PointSetMetricType);
120 itkGetModifiableObjectMacro(PointSetMetric, PointSetMetricType);
126 itkConceptMacro(LabelTypeIsInteger, (Concept::IsInteger<LabelType>));
127
128protected:
131
133 void
134 PrintSelf(std::ostream & os, Indent indent) const override;
135
136private:
141 void
143
150
157
158 PointSetMetricPointer m_PointSetMetric{};
159 std::vector<PointSetMetricPointer> m_PointSetMetricClones{};
160
161 LabelSetType m_FixedPointSetLabels{};
162 LabelSetType m_MovingPointSetLabels{};
163 LabelSetType m_CommonPointSetLabels{};
164};
165} // end namespace itk
166
167#ifndef ITK_MANUAL_INSTANTIATION
168# include "itkLabeledPointSetToPointSetMetricv4.hxx"
169#endif
170
171#endif
Simulate a standard C array with copy semantics.
Definition: itkFixedArray.h:54
Control indentation during Print() invocation.
Definition: itkIndent.h:50
Computes the distance metric and gradient between two labeled point sets.
typename FixedPointSetType::Pointer FixedPointSetPointer
FixedPointSetPointer GetLabeledFixedPointSet(const LabelType) const
~LabeledPointSetToPointSetMetricv4() override=default
MovingPointSetPointer GetLabeledMovingPointSet(const LabelType) const
void PrintSelf(std::ostream &os, Indent indent) const override
MeasureType GetLocalNeighborhoodValue(const PointType &, const LabelType &) const override
typename PointSetMetricType::Pointer PointSetMetricPointer
typename MovingPointSetType::Pointer MovingPointSetPointer
void GetLocalNeighborhoodValueAndDerivative(const PointType &, MeasureType &, LocalDerivativeType &, const LabelType &) const override
Light weight base class for most itk classes.
Computes similarity between two point sets.
BinaryGeneratorImageFilter< TInputImage1, TInputImage2, TOutputImage > Superclass
SmartPointer< Self > Pointer
#define itkConceptMacro(name, concept)
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....