ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkGradientMagnitudeSigmoidFeatureGenerator.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Insight Segmentation & Registration Toolkit
4  Module: itkGradientMagnitudeSigmoidFeatureGenerator.h
5  Language: C++
6  Date: $Date$
7  Version: $Revision$
8 
9  Copyright (c) Insight Software Consortium. All rights reserved.
10  See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
11 
12  This software is distributed WITHOUT ANY WARRANTY; without even
13  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14  PURPOSE. See the above copyright notices for more information.
15 
16 =========================================================================*/
17 #ifndef itkGradientMagnitudeSigmoidFeatureGenerator_h
18 #define itkGradientMagnitudeSigmoidFeatureGenerator_h
19 
20 #include "itkFeatureGenerator.h"
21 #include "itkImage.h"
22 #include "itkImageSpatialObject.h"
24 #include "itkSigmoidImageFilter.h"
25 
26 namespace itk
27 {
28 
41 template <unsigned int NDimension>
42 class ITK_TEMPLATE_EXPORT GradientMagnitudeSigmoidFeatureGenerator : public FeatureGenerator<NDimension>
43 {
44 public:
45  ITK_DISALLOW_COPY_AND_ASSIGN(GradientMagnitudeSigmoidFeatureGenerator);
46 
52 
54  itkNewMacro(Self);
55 
58 
60  static constexpr unsigned int Dimension = NDimension;
61 
64  using InputPixelType = signed short;
68  using SpatialObjectType = typename Superclass::SpatialObjectType;
69 
72  void SetInput( const SpatialObjectType * input );
73  const SpatialObjectType * GetInput() const;
75 
78  const SpatialObjectType * GetFeature() const;
79 
82  itkSetMacro( Sigma, double );
83  itkGetMacro( Sigma, double );
85 
87  itkSetMacro( Alpha, double );
88  itkGetMacro( Alpha, double );
90 
92  itkSetMacro( Beta, double );
93  itkGetMacro( Beta, double );
95 
96 protected:
99  void PrintSelf(std::ostream& os, Indent indent) const override;
100 
103  void GenerateData () override;
104 
105 private:
106  using InternalPixelType = float;
108 
111 
113 
117 
121 
124 
125  double m_Sigma;
126  double m_Alpha;
127  double m_Beta;
128 };
129 
130 } // end namespace itk
131 
132 #ifndef ITK_MANUAL_INSTANTIATION
133 # include "itkGradientMagnitudeSigmoidFeatureGenerator.hxx"
134 #endif
135 
136 #endif
Computes the Magnitude of the Gradient of an image by convolution with the first derivative of a Gaus...
Generates a feature image by computing the gradient magnitude of the input image and applying a sigmo...
Light weight base class for most itk classes.
Computes the sigmoid function pixel-wise.
typename InputImageSpatialObjectType::Pointer InputImageSpatialObjectPointer
Class that generates features (typically images) used as input for a segmentation method...
Implementation of the composite pattern.
virtual void SetInput(const DataObjectIdentifierType &key, DataObject *input)
Protected method for setting indexed and named inputs.
Implementation of an image as spatial object.
Control indentation during Print() invocation.
Definition: itkIndent.h:49
Templated n-dimensional image class.
Definition: itkImage.h:75