Make sure you compile ITK and your program with Release.<br><br><div class="gmail_quote">On Mon, Oct 8, 2012 at 8:46 AM, XiongXiang Zhang <span dir="ltr"><<a href="mailto:zhangxx110@126.com" target="_blank">zhangxx110@126.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial">
<div>Hi,</div>
<div>We filter an image (noised.tif 606*601) with BilateralImageFilter like this:</div>
<div> </div>
<div>//instance reader</div>
<div> ReaderType::Pointer reader = ReaderType::New();<br> reader->SetFileName( argv[1] );</div>
<div> </div>
<div>//instance filter</div>
<div> typedef itk::BilateralImageFilter<InputImageType, OutputImageType > FilterType;<br> FilterType::Pointer filter = FilterType::New();</div>
<div>filter->SetInput( reader->GetOutput() );</div>
<div> </div>
<div> ...........</div>
<div>//instance writer</div>
<div> typedef itk::ImageFileWriter< WriteImageType > WriterType;<br> WriterType::Pointer writer = WriterType::New();<br> writer->SetFileName( argv[2] );</div>
<div><br> writer->SetInput( filter->GetOutput() );</div>
<div> </div>
<div>//update<br> writer->Update();</div>
<div> </div>
<div>Run the program, <strong>CPU </strong>utilization last for 100% . It takes several quarters to filter the TIF image. IS there some </div>
<div>efficient method to filter the TIF iamge?</div>
<div>Thanks.</div><span class="HOEnZb"><font color="#888888">
<div>XiongXiang Zhang</div></font></span></div></div><br><br><span title="neteasefooter"><span></span></span><br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at<br>
<a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Kitware offers ITK Training Courses, for more information visit:<br>
<a href="http://kitware.com/products/protraining.php" target="_blank">http://kitware.com/products/protraining.php</a><br>
<br>
Please keep messages on-topic and check the ITK FAQ at:<br>
<a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.itk.org/mailman/listinfo/insight-developers" target="_blank">http://www.itk.org/mailman/listinfo/insight-developers</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Unpaid intern in BillsBasement at noware dot com<br><br>