Commit d2263e97 authored by Guillaume Pasero's avatar Guillaume Pasero

TEST: set the seed for reproductible results

parent 82754ba6
......@@ -44,6 +44,8 @@
#include "otbVcaImageFilter.h"
#include "otbUnConstrainedLeastSquareImageFilter.h"
#include "itkMersenneTwisterRandomVariateGenerator.h"
int main(int argc, char* argv[])
{
if (argc != 7)
......@@ -71,6 +73,10 @@ int main(int argc, char* argv[])
typedef otb::VectorRescaleIntensityImageFilter<ImageType, ImageType> RescalerType;
typedef otb::VectorImageToMatrixImageFilter<ImageType> VectorImageToMatrixImageFilterType;
// We set the seed of the random number generator.
itk::Statistics::MersenneTwisterRandomVariateGenerator::GetInstance()->SetSeed(121212);
// We instantiate now the image reader and we set the image file name.
ReaderType::Pointer reader = ReaderType::New();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment