23 #ifndef otbCzihoSOMNeighborhoodBehaviorFunctor_h
24 #define otbCzihoSOMNeighborhoodBehaviorFunctor_h
69 template <
unsigned int VDimension>
70 itk::Size<VDimension>
operator()(
unsigned int currentIteration,
unsigned int numberOfIterations,
const itk::Size<VDimension>& sizeInit)
const
72 itk::Size<VDimension> theSize;
73 double weightening = ::std::pow(1.0 -
static_cast<double>(currentIteration) /
static_cast<double>(numberOfIterations), 2.0);
74 for (
unsigned int i = 0; i < VDimension; ++i)
76 theSize[i] =
static_cast<typename itk::Size<VDimension>::SizeValueType
>(
static_cast<double>(sizeInit[i]) * weightening);