ITK  5.2.0
Insight Toolkit
itkLevelSetEquationOverlapPenaltyTerm.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  * 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 itkLevelSetEquationOverlapPenaltyTerm_h
20 #define itkLevelSetEquationOverlapPenaltyTerm_h
21 
24 
25 namespace itk
26 {
45 template <typename TInput, // Input image or mesh
46  typename TLevelSetContainer>
47 class ITK_TEMPLATE_EXPORT LevelSetEquationOverlapPenaltyTerm
48  : public LevelSetEquationTermBase<TInput, TLevelSetContainer>
49 {
50 public:
51  ITK_DISALLOW_COPY_AND_MOVE(LevelSetEquationOverlapPenaltyTerm);
53 
58 
60  itkNewMacro(Self);
61 
64 
65  using InputImageType = typename Superclass::InputImageType;
66  using InputImagePointer = typename Superclass::InputImagePointer;
67  using InputPixelType = typename Superclass::InputPixelType;
68  using InputPixelRealType = typename Superclass::InputPixelRealType;
69 
70  using LevelSetContainerType = typename Superclass::LevelSetContainerType;
71  using LevelSetContainerPointer = typename Superclass::LevelSetContainerPointer;
72  using LevelSetType = typename Superclass::LevelSetType;
73  using LevelSetPointer = typename Superclass::LevelSetPointer;
74  using LevelSetOutputPixelType = typename Superclass::LevelSetOutputPixelType;
75  using LevelSetOutputRealType = typename Superclass::LevelSetOutputRealType;
76  using LevelSetInputIndexType = typename Superclass::LevelSetInputIndexType;
77  using LevelSetGradientType = typename Superclass::LevelSetGradientType;
78  using LevelSetHessianType = typename Superclass::LevelSetHessianType;
79  using LevelSetIdentifierType = typename Superclass::LevelSetIdentifierType;
80 
81  using HeavisideType = typename Superclass::HeavisideType;
82  using HeavisideConstPointer = typename Superclass::HeavisideConstPointer;
83 
84  using LevelSetDataType = typename Superclass::LevelSetDataType;
85 
86  using DomainMapImageFilterType = typename Superclass::DomainMapImageFilterType;
87  using CacheImageType = typename Superclass::CacheImageType;
88 
89  using IdListType = typename LevelSetContainerType::IdListType;
90  using IdListIterator = typename LevelSetContainerType::IdListIterator;
91  using IdListConstIterator = typename LevelSetContainerType::IdListConstIterator;
92 
94 
95 
97  void
98  Update() override;
99 
101  void
102  InitializeParameters() override;
103 
105  void
106  Initialize(const LevelSetInputIndexType & index) override;
107 
110  virtual void
111  ComputeSumTerm(const LevelSetInputIndexType & index, LevelSetOutputRealType & sum);
112 
114  void
115  UpdatePixel(const LevelSetInputIndexType & index,
116  const LevelSetOutputRealType & oldValue,
117  const LevelSetOutputRealType & newValue) override;
118 
119 
120 protected:
122 
123  ~LevelSetEquationOverlapPenaltyTerm() override = default;
124 
127  Value(const LevelSetInputIndexType & index) override;
128 
131  Value(const LevelSetInputIndexType & index, const LevelSetDataType & data) override;
132 
133 private:
136 };
137 
138 } // namespace itk
139 #ifndef ITK_MANUAL_INSTANTIATION
140 # include "itkLevelSetEquationOverlapPenaltyTerm.hxx"
141 #endif
142 
143 #endif
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetPointer
typename Superclass::LevelSetPointer LevelSetPointer
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:73
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetIdentifierType
typename Superclass::LevelSetIdentifierType LevelSetIdentifierType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:79
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetHessianType
typename Superclass::LevelSetHessianType LevelSetHessianType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:78
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetDataType
typename Superclass::LevelSetDataType LevelSetDataType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:84
itk::CompensatedSummation
Perform more precise accumulation of floating point numbers.
Definition: itkCompensatedSummation.h:66
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetOutputPixelType
typename Superclass::LevelSetOutputPixelType LevelSetOutputPixelType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:74
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetContainerPointer
typename Superclass::LevelSetContainerPointer LevelSetContainerPointer
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:71
itk::LevelSetEquationOverlapPenaltyTerm::InputImageType
typename Superclass::InputImageType InputImageType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:65
itk::LevelSetEquationOverlapPenaltyTerm::IdListConstIterator
typename LevelSetContainerType::IdListConstIterator IdListConstIterator
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:91
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetType
typename Superclass::LevelSetType LevelSetType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:72
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetInputIndexType
typename Superclass::LevelSetInputIndexType LevelSetInputIndexType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:76
itk::SmartPointer< Self >
itkCompensatedSummation.h
itk::LevelSetEquationOverlapPenaltyTerm::InputImagePointer
typename Superclass::InputImagePointer InputImagePointer
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:66
itk::LevelSetEquationOverlapPenaltyTerm::InputPixelRealType
typename Superclass::InputPixelRealType InputPixelRealType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:68
itk::LightObject
Light weight base class for most itk classes.
Definition: itkLightObject.h:59
itk::LevelSetEquationOverlapPenaltyTerm::IdListType
typename LevelSetContainerType::IdListType IdListType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:89
itk::LevelSetEquationOverlapPenaltyTerm::DomainMapImageFilterType
typename Superclass::DomainMapImageFilterType DomainMapImageFilterType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:86
itk::LevelSetEquationOverlapPenaltyTerm::CacheImageType
typename Superclass::CacheImageType CacheImageType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:87
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetContainerType
typename Superclass::LevelSetContainerType LevelSetContainerType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:70
itk::LevelSetEquationOverlapPenaltyTerm
Class to represent the overlap penalty among many level-sets.
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:47
itk::LevelSetEquationOverlapPenaltyTerm::m_CacheImage
CacheImageType * m_CacheImage
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:135
itk::LevelSetEquationTermBase
Abstract class to represents a term in the level-set evolution PDE.
Definition: itkLevelSetEquationTermBase.h:49
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itk::LevelSetEquationOverlapPenaltyTerm::m_DomainMapImageFilter
DomainMapImageFilterType * m_DomainMapImageFilter
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:134
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetGradientType
typename Superclass::LevelSetGradientType LevelSetGradientType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:77
itkLevelSetEquationTermBase.h
itk::LevelSetEquationOverlapPenaltyTerm::HeavisideConstPointer
typename Superclass::HeavisideConstPointer HeavisideConstPointer
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:82
itk::LevelSetEquationOverlapPenaltyTerm::LevelSetOutputRealType
typename Superclass::LevelSetOutputRealType LevelSetOutputRealType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:75
itk::LevelSetEquationOverlapPenaltyTerm::HeavisideType
typename Superclass::HeavisideType HeavisideType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:81
itk::LevelSetEquationOverlapPenaltyTerm::InputPixelType
typename Superclass::InputPixelType InputPixelType
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:67
itk::LevelSetEquationOverlapPenaltyTerm::IdListIterator
typename LevelSetContainerType::IdListIterator IdListIterator
Definition: itkLevelSetEquationOverlapPenaltyTerm.h:90