X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;ds=sidebyside;f=segmentation%2FclitkMotionMaskGenericFilter.txx;h=56fadac84f5e977f016677a0cd68bce42470e62c;hb=80ddaed8a2022748b22a8d2bb85371e4502408db;hp=414a2f69042a5494b2355472c5785f3d31604efd;hpb=01efc03d2d7e88c82197f8f500239573c8b67c39;p=clitk.git diff --git a/segmentation/clitkMotionMaskGenericFilter.txx b/segmentation/clitkMotionMaskGenericFilter.txx index 414a2f6..56fadac 100644 --- a/segmentation/clitkMotionMaskGenericFilter.txx +++ b/segmentation/clitkMotionMaskGenericFilter.txx @@ -377,6 +377,8 @@ MotionMaskGenericFilter::GetLungsImage(typename itk::Image connectFilter->SetBackgroundValue(0); connectFilter->SetFullyConnected(true); if (m_Verbose) std::cout<<"Labeling the connected components..."<Update(); + if (m_Verbose) std::cout<<"found "<< connectFilter->GetObjectCount() << std::endl; //--------------------------------- // Sort the labels according to size @@ -384,7 +386,7 @@ MotionMaskGenericFilter::GetLungsImage(typename itk::Image typename RelabelFilterType::Pointer relabelFilter=RelabelFilterType::New(); relabelFilter->SetInput(connectFilter->GetOutput()); if (m_Verbose) std::cout<<"Sorting the labels..."< (relabelFilter->GetOutput(), "/home/jef/tmp/labels.mhd"); + // writeImage (relabelFilter->GetOutput(), "/home/vdelmon/tmp/labels.mhd"); //--------------------------------- // Keep the label @@ -944,6 +946,10 @@ MotionMaskGenericFilter::UpdateWithDimAndPixelType() distanceMapImageFilter->SetInsideIsPositive(false); if (m_Verbose) std::cout<<"Calculating the distance map..."<Update(); + if (m_ArgsInfo.writeDistMap_given) { + writeImage(distanceMapImageFilter->GetOutput(), m_ArgsInfo.writeDistMap_arg, m_Verbose); + + } //--------------------------------- // Grow while monitoring detection point