19 #include <itkFRPROptimizer.h>
38 OptimizerPointer->SetMaximize(
m_Controls.m_Maximize->isChecked());
39 OptimizerPointer->SetStepLength(
m_Controls.m_StepLengthFRPR->text().toFloat());
40 if (
m_Controls.m_FletchReevesFRPR->isChecked())
42 OptimizerPointer->SetToFletchReeves();
46 OptimizerPointer->SetToPolakRibiere();
48 OptimizerPointer->SetMaximumIteration(
m_Controls.m_IterationsFRPR->text().toInt());
49 return OptimizerPointer.GetPointer();
54 itk::Array<double> optimizerValues;
55 optimizerValues.SetSize(4);
56 optimizerValues.fill(0);
57 optimizerValues[0] =
m_Controls.m_Maximize->isChecked();
58 optimizerValues[1] =
m_Controls.m_FletchReevesFRPR->isChecked();
59 optimizerValues[2] =
m_Controls.m_StepLengthFRPR->text().toFloat();
60 optimizerValues[3] =
m_Controls.m_IterationsFRPR->text().toInt();
61 return optimizerValues;
66 m_Controls.m_Maximize->setChecked(optimizerValues[0]);
67 m_Controls.m_FletchReevesFRPR->setChecked(optimizerValues[1]);
68 m_Controls.m_PolakRibiereFRPR->setChecked(!optimizerValues[1]);
69 m_Controls.m_StepLengthFRPR->setText(QString::number(optimizerValues[2]));
70 m_Controls.m_IterationsFRPR->setText(QString::number(optimizerValues[3]));
86 QValidator *validatorLineEditInput =
new QIntValidator(0, 20000000,
this);
87 m_Controls.m_IterationsFRPR->setValidator(validatorLineEditInput);
88 QValidator *validatorLineEditInputFloat =
new QDoubleValidator(0, 20000000, 8,
this);
89 m_Controls.m_StepLengthFRPR->setValidator(validatorLineEditInputFloat);
QmitkFRPROptimizerView(QWidget *parent=nullptr, Qt::WindowFlags f=nullptr)
virtual QString GetName() override
virtual itk::Object::Pointer GetOptimizer() override
itk::SmartPointer< Self > Pointer
int m_NumberTransformParameters
virtual itk::Array< double > GetOptimizerParameters() override
virtual void SetupUI(QWidget *parent) override
virtual void SetNumberOfTransformParameters(int transformParameters) override
Widget for rigid registration.
~QmitkFRPROptimizerView()
Ui::QmitkFRPROptimizerControls m_Controls
virtual mitk::OptimizerParameters::OptimizerType GetOptimizerType() override
OptimizerType
Unique integer value for every optimizer.
virtual void SetOptimizerParameters(itk::Array< double > metricValues) override
static itkEventMacro(BoundingShapeInteractionEvent, itk::AnyEvent) class MITKBOUNDINGSHAPE_EXPORT BoundingShapeInteractor Pointer New()
Basic interaction methods for mitk::GeometryData.