On Wed, Nov 14, 2012 at 7:17 PM, Richard Beare <span dir="ltr"><<a href="mailto:richard.beare@gmail.com" target="_blank">richard.beare@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
These will both modify other parts of the image as well, which you may<br>
not want. In the past I have use the following approach which is easy<br>
if the lines have a constant brightness or colour setting making it<br>
trivial to define a mask containing just the features you want to<br>
remove.<br>
<br>
The simple option then is to apply a median filter to the original<br>
image and replace the mask voxels with the values output by the median<br>
filter - all of which can be done with masking and arithmetic<br>
operations. Alternatively you could use a mask filling by<br>
interpolation approach (Poisson editing), which is more sophisticated.<br>
Dave Doria published some ITK/VTK methods for this, and Matlab has a<br>
function that does it.</blockquote><div><br></div><div>Here is the code that Richard was referring to: <a href="https://github.com/daviddoria/PoissonEditing">https://github.com/daviddoria/PoissonEditing</a></div><div><br>
</div><div>but as he mentioned, it may be overkill and you might get just as good of a result with something like median filtering. In either case, you have to know which pixel are corrupt before you can fix them (if you don't want to modify the rest of the data).</div>
<div><br></div><div>Also, I don't see GrayscaleGrindImageFilter here <a href="http://www.itk.org/Doxygen/html/classes.html">http://www.itk.org/Doxygen/html/classes.html</a> ?</div><div><br></div><div>David</div></div>