ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkLevelSetEquationOverlapPenaltyTerm.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 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_ASSIGN(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 Update() override;
98 
100  void InitializeParameters() override;
101 
103  void Initialize( const LevelSetInputIndexType& index ) override;
104 
107  virtual void ComputeSumTerm( const LevelSetInputIndexType& index,
108  LevelSetOutputRealType& sum );
109 
111  void UpdatePixel( const LevelSetInputIndexType& index,
112  const LevelSetOutputRealType& oldValue,
113  const LevelSetOutputRealType& newValue ) override;
114 
115 
116 protected:
118 
119  ~LevelSetEquationOverlapPenaltyTerm() override = default;
120 
122  LevelSetOutputRealType Value( const LevelSetInputIndexType& index ) override;
123 
126  const LevelSetDataType& data ) override;
127 
128 private:
131 };
132 
133 }
134 #ifndef ITK_MANUAL_INSTANTIATION
135 #include "itkLevelSetEquationOverlapPenaltyTerm.hxx"
136 #endif
137 
138 #endif
typename Superclass::LevelSetOutputPixelType LevelSetOutputPixelType
typename Superclass::LevelSetDataType LevelSetDataType
typename Superclass::LevelSetGradientType LevelSetGradientType
Light weight base class for most itk classes.
typename Superclass::InputPixelRealType InputPixelRealType
typename Superclass::LevelSetIdentifierType LevelSetIdentifierType
typename LevelSetContainerType::IdListType IdListType
typename Superclass::HeavisideConstPointer HeavisideConstPointer
typename Superclass::DomainMapImageFilterType DomainMapImageFilterType
Abstract class to represents a term in the level-set evolution PDE.
typename Superclass::LevelSetContainerType LevelSetContainerType
typename Superclass::LevelSetInputIndexType LevelSetInputIndexType
Class to represent the overlap penalty among many level-sets.
Perform more precise accumulation of floating point numbers.
typename LevelSetContainerType::IdListIterator IdListIterator
typename Superclass::InputImagePointer InputImagePointer
typename LevelSetContainerType::IdListConstIterator IdListConstIterator
typename Superclass::LevelSetContainerPointer LevelSetContainerPointer
typename Superclass::LevelSetOutputRealType LevelSetOutputRealType
typename Superclass::LevelSetHessianType LevelSetHessianType