17 #include "mapDeploymentDLLHelper.h"
18 #include "mapDiscreteElements.h"
19 #include "mapITKTransMattesMIMultiResRegistrationAlgorithm.h"
20 #include "mapConfigure.h"
26 typedef map::core::discrete::Elements<3>::InternalImageType
ImageType;
32 class MultiModalTranslationDefaultRegistrationAlgorithm :
33 public map::algorithm::boxed::ITKTransMattesMIMultiResRegistrationAlgorithm<ImageType, ImageType, ::map::algorithm::MITK_MultiModal_translation_defaultUIDPolicy, SealedFixedInterpolatorPolicyMacro< ::itk::LinearInterpolateImageFunction<ImageType, map::core::continuous::ScalarType> >, map::algorithm::itk::NoComponentInitializationPolicy>
36 typedef MultiModalTranslationDefaultRegistrationAlgorithm Self;
38 typedef ITKTransMattesMIMultiResRegistrationAlgorithm<ImageType, ImageType, ::map::algorithm::MITK_MultiModal_translation_defaultUIDPolicy, SealedFixedInterpolatorPolicyMacro< ::itk::LinearInterpolateImageFunction<ImageType, map::core::continuous::ScalarType> >, map::algorithm::itk::NoComponentInitializationPolicy>
41 typedef ::itk::SmartPointer<Self>
Pointer;
44 itkTypeMacro(MultiModalTranslationDefaultRegistrationAlgorithm,
45 ITKEuler3DMattesMIMultiResRegistrationAlgorithm);
46 mapNewAlgorithmMacro(Self);
49 MultiModalTranslationDefaultRegistrationAlgorithm()
53 virtual ~MultiModalTranslationDefaultRegistrationAlgorithm()
57 void configureAlgorithm()
59 Superclass::configureAlgorithm();
61 this->setResolutionLevels(3);
62 this->_preInitialize =
true;
63 this->_useCenterOfGravity =
false;
66 ConcreteOptimizerType::ScalesType scales(3);
71 this->getConcreteOptimizerControl()->getConcreteOptimizer()->SetScales(scales);
72 this->getConcreteOptimizerControl()->getConcreteOptimizer()->SetMaximumStepLength(3.00);
73 this->getConcreteOptimizerControl()->getConcreteOptimizer()->SetMinimumStepLength(0.5);
74 this->getConcreteOptimizerControl()->getConcreteOptimizer()->SetNumberOfIterations(200);
75 this->getConcreteOptimizerControl()->getConcreteOptimizer()->SetRelaxationFactor(0.8);
76 this->getConcreteOptimizerControl()->getConcreteOptimizer()->SetGradientMagnitudeTolerance(1e-4);
79 this->getConcreteMetricControl()->getConcreteMetric()->SetNumberOfHistogramBins(30);
80 this->getConcreteMetricControl()->getConcreteMetric()->SetUseAllPixels(
true);
81 this->getConcreteMetricControl()->getConcreteMetric()->ReinitializeSeed();
82 this->getConcreteMetricControl()->getConcreteMetric()->UseExplicitPDFDerivativesOn();
88 Superclass::doInterLevelSetup();
90 if (this->getCurrentLevel() != 0)
92 getConcreteMetricControl()->getConcreteMetric()->SetUseAllPixels(
false);
94 unsigned int nrOfSmpl = ::itk::Math::Round<unsigned int, double>
95 (this->getMovingImage()->GetLargestPossibleRegion().GetNumberOfPixels() * 0.15);
97 getConcreteMetricControl()->getConcreteMetric()->SetNumberOfSpatialSamples(nrOfSmpl);
103 MultiModalTranslationDefaultRegistrationAlgorithm(
const Self& source);
104 void operator=(
const Self&);
mapDeployAlgorithmMacro(mitk::MultiModalTranslationDefaultRegistrationAlgorithm)
itk::SmartPointer< Self > Pointer
DataCollection - Class to facilitate loading/accessing structured data.
itkEventMacroDeclaration(FocusChangedEvent, itk::AnyEvent) class MITKCORE_EXPORT TestingRenderingManager typedef RenderingManager Superclass
itk::SmartPointer< const Self > ConstPointer
map::core::discrete::Elements< 3 >::InternalImageType ImageType