<commit_before>/*=========================================================================

Program:   Medical Imaging & Interaction Toolkit
Language:  C++
Date:      $Date$
Version:   $Revision: 13129 $

Copyright (c) German Cancer Research Center, Division of Medical and
Biological Informatics. All rights reserved.
See MITKCopyright.txt or http://www.mitk.org/copyright.html for details.

This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE.  See the above copyright notices for more information.

=========================================================================*/

#include "mitkRigidRegistrationPreset.h"
#include <itkArray.h>

int mitkRigidRegistrationPresetTest(int argc, char* argv[])
{
  typedef itk::Array<double>               ArrayType;

  mitk::RigidRegistrationPreset* rrp = new mitk::RigidRegistrationPreset;
  std::cout<<"[PASSED]"<<std::endl;

  // Check if the default presets (in the Functionality directory) can be loaded.
  std::cout<<"Testing default parameter loading...\n";
  if(!rrp->LoadPreset())
  {
    std::cout<<"[FAILED]"<<std::endl;
    return EXIT_FAILURE;
  }
  std::cout<<"[PASSED]"<<std::endl;

  // Check if an exemplary parameter set can be extracted from the read presets.
  std::cout<<"Testing if exemplary default values match default parameters...\n";

  ArrayType transformValues = rrp->getTransformValues("ITK Image Registration 12");
  ArrayType metricValues = rrp->getMetricValues("ITK Image Registration 12");
  ArrayType optimizerValues = rrp->getOptimizerValues("ITK Image Registration 12");
  ArrayType interpolatorValues = rrp->getInterpolatorValues("ITK Image Registration 12");

  std::cout << transformValues[5] << metricValues[1] << optimizerValues[4] << interpolatorValues[0] << std::endl;

  if( !(transformValues[5]==0.001) || !(metricValues[1]==1) || !(optimizerValues[4]==0.1) || !(interpolatorValues[0]==0) )
  {
    std::cout<<"[FAILED]"<<std::endl;<commit_msg>COMP: Fix warnings<commit_after>/*=========================================================================

Program:   Medical Imaging & Interaction Toolkit
Language:  C++
Date:      $Date$
Version:   $Revision: 13129 $

Copyright (c) German Cancer Research Center, Division of Medical and
Biological Informatics. All rights reserved.
See MITKCopyright.txt or http://www.mitk.org/copyright.html for details.

This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE.  See the above copyright notices for more information.

=========================================================================*/

#include "mitkRigidRegistrationPreset.h"
#include <itkArray.h>

int mitkRigidRegistrationPresetTest(int /*argc*/, char* /*argv*/[])
{
  typedef itk::Array<double>               ArrayType;

  mitk::RigidRegistrationPreset* rrp = new mitk::RigidRegistrationPreset;
  std::cout<<"[PASSED]"<<std::endl;

  // Check if the default presets (in the Functionality directory) can be loaded.
  std::cout<<"Testing default parameter loading...\n";
  if(!rrp->LoadPreset())
  {
    std::cout<<"[FAILED]"<<std::endl;
    return EXIT_FAILURE;
  }
  std::cout<<"[PASSED]"<<std::endl;

  // Check if an exemplary parameter set can be extracted from the read presets.
  std::cout<<"Testing if exemplary default values match default parameters...\n";

  ArrayType transformValues = rrp->getTransformValues("ITK Image Registration 12");
  ArrayType metricValues = rrp->getMetricValues("ITK Image Registration 12");
  ArrayType optimizerValues = rrp->getOptimizerValues("ITK Image Registration 12");
  ArrayType interpolatorValues = rrp->getInterpolatorValues("ITK Image Registration 12");

  std::cout << transformValues[5] << metricValues[1] << optimizerValues[4] << interpolatorValues[0] << std::endl;

  if( !(transformValues[5]==0.001) || !(metricValues[1]==1) || !(optimizerValues[4]==0.1) || !(interpolatorValues[0]==0) )
  {
    std::cout<<"[FAILED]"<<std::endl;
{'fraction_non_alphanumeric': 0.1970406905055487, 'fraction_numerical': 0.014303329223181258, 'mean_word_length': 5.6600985221674875, 'pattern_counts': {'":': 0, '<': 67, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1679403', 'n_tokens_mistral': 1218, 'n_tokens_neox': 1127, 'n_words': 315}