[Insight-developers] Not work when using BilateralImageFilter

Xiaoxiao Liu xiaoxiao.liu at kitware.com
Mon Oct 8 09:50:42 EDT 2012


Hi XiongXiang,

Did you set the sigmas ?:

  bilateralFilter->SetDomainSigma(domainSigma);
  bilateralFilter->SetRangeSigma(rangeSigma);


Here is an example of using BilateralImageFilter:

http://www.itk.org/Doxygen/html/classitk_1_1BilateralImageFilter.html


It's better to post your full section of code and the corresponding testing
image for others to give a full diagnosis.


-Xiaoxiao


On Mon, Oct 8, 2012 at 8:46 AM, XiongXiang Zhang <zhangxx110 at 126.com> wrote:

> Hi,
> We filter an image (noised.tif 606*601) with BilateralImageFilter like
> this:
>
> //instance reader
>  ReaderType::Pointer reader = ReaderType::New();
>  reader->SetFileName( argv[1] );
>
> //instance filter
>  typedef itk::BilateralImageFilter<InputImageType, OutputImageType >
> FilterType;
>   FilterType::Pointer filter = FilterType::New();
> filter->SetInput( reader->GetOutput() );
>
>  ...........
> //instance writer
>  typedef itk::ImageFileWriter< WriteImageType >  WriterType;
>   WriterType::Pointer writer = WriterType::New();
>   writer->SetFileName( argv[2] );
>
>   writer->SetInput(  filter->GetOutput() );
>
> //update
>   writer->Update();
>
> Run the program, *CPU *utilization last for 100% . It takes several
> quarters to filter the TIF image. IS there some
> efficient method to filter the TIF iamge?
> Thanks.
> XiongXiang Zhang
>
>
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-developers
>
>


-- 


---------------------------------------------
*Xiaoxiao Liu*, Ph.D.
R & D Engineer
Kitware Inc <http://www.kitware.com/>.
Clifton Park, NY
Phone: (518) 881-4924  or  (518) 371-3971 x124
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-developers/attachments/20121008/15a09c8d/attachment.htm>


More information about the Insight-developers mailing list