diff --git a/Testing/Code/Learning/SVMPointSetExample.cxx b/Testing/Code/Learning/SVMPointSetExample.cxx index 33a759d04609af5d4a408de6f200b2a78d47e7c8..ea484cb01eeaa21d087fb6b02735afe617480651 100755 --- a/Testing/Code/Learning/SVMPointSetExample.cxx +++ b/Testing/Code/Learning/SVMPointSetExample.cxx @@ -184,8 +184,6 @@ int main( int argc, char* argv[] ) classifier->Update() ; /* Build the class map */ - std::cout << "Output image creation" << std::endl; - std::cout << "classifier get output" << std::endl; ClassifierType::OutputType* membershipSample = diff --git a/Testing/Code/Learning/otbSVMClassifierImage.cxx b/Testing/Code/Learning/otbSVMClassifierImage.cxx index 00b3ddc6820cede32ac4c133a9ba4d6137196683..52b20999af25a1f9eb6a489b186f8d75c21baec2 100644 --- a/Testing/Code/Learning/otbSVMClassifierImage.cxx +++ b/Testing/Code/Learning/otbSVMClassifierImage.cxx @@ -26,7 +26,8 @@ #include "itkListSample.h" -#include "itkVectorImage.h" +#include "otbImage.h" +#include "otbVectorImage.h" #include "itkImageToListAdaptor.h" #include "otbSVMClassifier.h" #include "otbImageFileReader.h" @@ -67,7 +68,7 @@ int otbSVMClassifierImage(int argc, char* argv[] ) - typedef itk::Image< itk::FixedArray<InputPixelType,3>, Dimension > InputImageType; + typedef otb::Image< itk::FixedArray<InputPixelType,3>, Dimension > InputImageType; typedef otb::ImageFileReader< InputImageType > ReaderType; @@ -82,66 +83,6 @@ int otbSVMClassifierImage(int argc, char* argv[] ) std::cout << "Image read" << std::endl; -/* - typedef itk::PointSet< InputVectorType, Dimension > - MeasurePointSetType; - - - MeasurePointSetType::Pointer mPSet = MeasurePointSetType::New(); - - typedef MeasurePointSetType::PointType MeasurePointType; - - typedef MeasurePointSetType::PointsContainer MeasurePointsContainer; - - MeasurePointsContainer::Pointer mCont = MeasurePointsContainer::New(); - - - typedef itk::ImageRegionIterator< InputImageType> InputIteratorType; - InputIteratorType inIt( reader->GetOutput(), - reader->GetOutput()->GetBufferedRegion() ); - - inIt.GoToBegin(); - - std::cout << "Building the pointset" << std::endl; - - unsigned long pointId=0; - while(!inIt.IsAtEnd() ) - { - - - MeasurePointType mP; - - mP[0] = inIt.GetIndex()[0]; - mP[1] = inIt.GetIndex()[1]; - - - InputVectorType measure; - measure.push_back(inIt.Get()[0]); - measure.push_back(inIt.Get()[1]); - measure.push_back(inIt.Get()[2]); - - - - mCont->InsertElement( pointId , mP ); - mPSet->SetPointData( pointId, measure ); - - - - ++inIt; - ++pointId; - } - - std::cout << "Set the points" << std::endl; - - mPSet->SetPoints( mCont ); - - std::cout << "PointSet built" << std::endl; - - typedef itk::Statistics::PointSetToListAdaptor< MeasurePointSetType > - SampleType; - SampleType::Pointer sample = SampleType::New(); - sample->SetPointSet( mPSet ); -*/ typedef itk::Statistics::ImageToListAdaptor< InputImageType > SampleType; SampleType::Pointer sample = SampleType::New(); @@ -171,7 +112,7 @@ int otbSVMClassifierImage(int argc, char* argv[] ) std::cout << "Output image creation" << std::endl; typedef ClassifierType::ClassLabelType OutputPixelType; - typedef itk::Image< OutputPixelType, Dimension > OutputImageType; + typedef otb::Image< OutputPixelType, Dimension > OutputImageType; OutputImageType::Pointer outputImage = OutputImageType::New(); @@ -223,7 +164,7 @@ int otbSVMClassifierImage(int argc, char* argv[] ) } - typedef itk::Image< unsigned char, Dimension > FileImageType; + typedef otb::Image< unsigned char, Dimension > FileImageType; typedef itk::RescaleIntensityImageFilter< OutputImageType, diff --git a/Testing/Code/Learning/otbSVMClassifierPointSet.cxx b/Testing/Code/Learning/otbSVMClassifierPointSet.cxx index 6a148742820ec7a4c4a6538169f1fd30635b7db2..12f0a1c5bc4ec412757c4893dbf2d18775436733 100644 --- a/Testing/Code/Learning/otbSVMClassifierPointSet.cxx +++ b/Testing/Code/Learning/otbSVMClassifierPointSet.cxx @@ -113,7 +113,6 @@ int otbSVMClassifierPointSet(int argc, char* argv[] ) classifier->Update() ; /* Build the class map */ - std::cout << "Output image creation" << std::endl; std::cout << "classifier get output" << std::endl; diff --git a/Testing/Code/Learning/otbSVMImageModelEstimatorNew.cxx b/Testing/Code/Learning/otbSVMImageModelEstimatorNew.cxx index de924c8cc7ea074f8bdbf4aa8807ef54fbf23132..6fd2d54fd8911c9d8a76c084bc7145d86409c945 100644 --- a/Testing/Code/Learning/otbSVMImageModelEstimatorNew.cxx +++ b/Testing/Code/Learning/otbSVMImageModelEstimatorNew.cxx @@ -17,8 +17,8 @@ #include "itkExceptionObject.h" -#include "itkImage.h" -#include "itkVectorImage.h" +#include "otbImage.h" +#include "otbVectorImage.h" #include <iostream> #include "otbSVMImageModelEstimator.h" @@ -31,9 +31,9 @@ int otbSVMImageModelEstimatorNew( int argc, char* argv[] ) typedef double InputPixelType; const unsigned int Dimension = 2; - typedef itk::VectorImage< InputPixelType, Dimension > InputImageType; + typedef otb::VectorImage< InputPixelType, Dimension > InputImageType; - typedef itk::Image< InputPixelType, Dimension > TrainingImageType; + typedef otb::Image< InputPixelType, Dimension > TrainingImageType; typedef std::vector<double> VectorType; diff --git a/Testing/Code/Learning/otbSVMImageModelEstimatorTrain.cxx b/Testing/Code/Learning/otbSVMImageModelEstimatorTrain.cxx index f7f14435abe136775241bd9c3dc400d55cc8cb99..70fe4a0f6ae552fa60c47ba034b460380029f5f0 100644 --- a/Testing/Code/Learning/otbSVMImageModelEstimatorTrain.cxx +++ b/Testing/Code/Learning/otbSVMImageModelEstimatorTrain.cxx @@ -17,7 +17,8 @@ #include "itkExceptionObject.h" -#include "itkImage.h" +#include "otbImage.h" +#include "otbVectorImage.h" #include <iostream> #include "otbSVMImageModelEstimator.h" @@ -37,9 +38,9 @@ int otbSVMImageModelEstimatorTrain( int argc, char* argv[] ) typedef double InputPixelType; const unsigned int Dimension = 2; - typedef itk::VectorImage< InputPixelType, Dimension > InputImageType; + typedef otb::VectorImage< InputPixelType, Dimension > InputImageType; - typedef itk::Image< InputPixelType, Dimension > TrainingImageType; + typedef otb::Image< InputPixelType, Dimension > TrainingImageType; typedef std::vector<double> VectorType; diff --git a/Testing/Code/Learning/otbSVMMembershipFunctionLoadModel.cxx b/Testing/Code/Learning/otbSVMMembershipFunctionLoadModel.cxx index c1b3395da2d65a3aec70089365ba3ace959ad06c..72d9039986911394e5ba5f206125898239603464 100644 --- a/Testing/Code/Learning/otbSVMMembershipFunctionLoadModel.cxx +++ b/Testing/Code/Learning/otbSVMMembershipFunctionLoadModel.cxx @@ -17,7 +17,6 @@ #include "itkExceptionObject.h" -#include "itkImage.h" #include <iostream> #include "otbSVMMembershipFunction.h" diff --git a/Testing/Code/Learning/otbSVMMembershipFunctionNew.cxx b/Testing/Code/Learning/otbSVMMembershipFunctionNew.cxx index e2354e176d4efe7a74537cae21c1c2f596fe4750..dbcda6f26b554925d325018c737628bc5ee6fba0 100644 --- a/Testing/Code/Learning/otbSVMMembershipFunctionNew.cxx +++ b/Testing/Code/Learning/otbSVMMembershipFunctionNew.cxx @@ -17,7 +17,6 @@ #include "itkExceptionObject.h" -#include "itkImage.h" #include <iostream> #include "otbSVMMembershipFunction.h" diff --git a/Testing/Code/Learning/otbSVMModelAllocateProblem.cxx b/Testing/Code/Learning/otbSVMModelAllocateProblem.cxx index 6478595fecaa3d5ac5ef13c61d659ff223031c6d..6f37d3e2b29dfa869c2223c4ef85dae297fb3fab 100644 --- a/Testing/Code/Learning/otbSVMModelAllocateProblem.cxx +++ b/Testing/Code/Learning/otbSVMModelAllocateProblem.cxx @@ -17,7 +17,7 @@ #include "itkExceptionObject.h" -#include "itkImage.h" +#include "otbImage.h" #include <iostream> #include "otbSVMModel.h" @@ -31,7 +31,7 @@ int otbSVMModelAllocateProblem( int argc, char* argv[] ) typedef unsigned char LabelPixelType; const unsigned int Dimension = 2; - typedef itk::Image< InputPixelType, Dimension > InputImageType; + typedef otb::Image< InputPixelType, Dimension > InputImageType; typedef otb::SVMModel< InputPixelType, LabelPixelType > ModelType; diff --git a/Testing/Code/Learning/otbSVMModelLoad.cxx b/Testing/Code/Learning/otbSVMModelLoad.cxx index f5497c2d6eaf43db0d39711a5e21be0bbb27c381..6f22e73509b00355ffa4caef2d6171699f431a3b 100644 --- a/Testing/Code/Learning/otbSVMModelLoad.cxx +++ b/Testing/Code/Learning/otbSVMModelLoad.cxx @@ -17,7 +17,7 @@ #include "itkExceptionObject.h" -#include "itkImage.h" +#include "otbImage.h" #include <iostream> #include "otbSVMModel.h" @@ -31,7 +31,7 @@ int otbSVMModelLoad( int argc, char* argv[] ) typedef unsigned char LabelPixelType; const unsigned int Dimension = 2; - typedef itk::Image< InputPixelType, Dimension > InputImageType; + typedef otb::Image< InputPixelType, Dimension > InputImageType; typedef otb::SVMModel< InputPixelType, LabelPixelType > ModelType; diff --git a/Testing/Code/Learning/otbSVMModelLoadSave.cxx b/Testing/Code/Learning/otbSVMModelLoadSave.cxx index 8dda8525db3fee527f27e5e4e1684f94a04e6c0a..9f6b21b86557dcb1bb4561d4528a056e54c781a9 100644 --- a/Testing/Code/Learning/otbSVMModelLoadSave.cxx +++ b/Testing/Code/Learning/otbSVMModelLoadSave.cxx @@ -17,7 +17,7 @@ #include "itkExceptionObject.h" -#include "itkImage.h" +#include "otbImage.h" #include <iostream> #include "otbSVMModel.h" @@ -31,7 +31,7 @@ int otbSVMModelLoadSave( int argc, char* argv[] ) typedef unsigned char LabelPixelType; const unsigned int Dimension = 2; - typedef itk::Image< InputPixelType, Dimension > InputImageType; + typedef otb::Image< InputPixelType, Dimension > InputImageType; typedef otb::SVMModel< InputPixelType, LabelPixelType > ModelType; diff --git a/Testing/Code/Learning/otbSVMModelNew.cxx b/Testing/Code/Learning/otbSVMModelNew.cxx index f7c695d10841ff0aef4c28eed2cdf98890f8a29b..736a6d2eeb54f8c2eda0759607a561f72eed1948 100644 --- a/Testing/Code/Learning/otbSVMModelNew.cxx +++ b/Testing/Code/Learning/otbSVMModelNew.cxx @@ -17,7 +17,7 @@ #include "itkExceptionObject.h" -#include "itkImage.h" +#include "otbImage.h" #include <iostream> #include "otbSVMModel.h" @@ -31,7 +31,7 @@ int otbSVMModelNew( int argc, char* argv[] ) typedef unsigned char LabelPixelType; const unsigned int Dimension = 2; - typedef itk::Image< InputPixelType, Dimension > InputImageType; + typedef otb::Image< InputPixelType, Dimension > InputImageType; typedef otb::SVMModel< InputPixelType, LabelPixelType > ModelType;