ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkLevelSetEvolutionStoppingCriterion.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 itkLevelSetEvolutionStoppingCriterion_h
20 #define itkLevelSetEvolutionStoppingCriterion_h
21 
23 #include "itkNumericTraits.h"
24 #include "itkIntTypes.h"
25 
26 namespace itk
27 {
31  template< typename TLevelSetContainer >
32  class ITK_TEMPLATE_EXPORT LevelSetEvolutionStoppingCriterion : public StoppingCriterionBase
33  {
34  public:
39 
42 
43  typedef TLevelSetContainer LevelSetContainerType;
44  typedef typename LevelSetContainerType::Pointer LevelSetContainerPointer;
45 
46  typedef typename LevelSetContainerType::LevelSetIdentifierType
48 
49  typedef typename LevelSetContainerType::LevelSetType LevelSetType;
50  typedef typename LevelSetContainerType::LevelSetPointer LevelSetPointer;
51 
52  typedef typename LevelSetContainerType::InputIndexType InputIndexType;
53  typedef typename LevelSetContainerType::OutputType OutputType;
54  typedef typename LevelSetContainerType::OutputRealType OutputRealType;
55  typedef typename LevelSetContainerType::GradientType GradientType;
56  typedef typename LevelSetContainerType::HessianType HessianType;
57 
58  typedef typename LevelSetContainerType::HeavisideType HeavisideType;
59  typedef typename LevelSetContainerType::HeavisideType HeavisidePointer;
60 
62 
63  itkSetObjectMacro( LevelSetContainer, LevelSetContainerType );
64  itkGetModifiableObjectMacro(LevelSetContainer, LevelSetContainerType );
65 
66  itkSetMacro( NumberOfIterations, IterationIdType );
67  itkGetMacro( NumberOfIterations, IterationIdType );
68 
69  itkSetMacro( CurrentIteration, IterationIdType );
70  itkGetMacro( CurrentIteration, IterationIdType );
71 
72  itkSetMacro( RMSChangeAccumulator, OutputRealType );
73  itkGetMacro( RMSChangeAccumulator, OutputRealType );
74 
75  protected:
78 
80  virtual ~LevelSetEvolutionStoppingCriterion() ITK_OVERRIDE;
81 
82  LevelSetContainerPointer m_LevelSetContainer;
83  OutputRealType m_RMSChangeAccumulator;
84  IterationIdType m_NumberOfIterations;
85  IterationIdType m_CurrentIteration;
86 
87  private:
88  ITK_DISALLOW_COPY_AND_ASSIGN(LevelSetEvolutionStoppingCriterion);
89  };
90  }
91 #ifndef ITK_MANUAL_INSTANTIATION
92 #include "itkLevelSetEvolutionStoppingCriterion.hxx"
93 #endif
94 #endif
LevelSetContainerType::LevelSetPointer LevelSetPointer
SizeValueType IdentifierType
Definition: itkIntTypes.h:147
Container of Level-Sets.
LevelSetContainerType::LevelSetIdentifierType LevelSetIdentifierType
An abstract base class to represent a stopping criterion for an iterative algorithm.