<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small">I don&#39;t think there is any stock filter which does what you want. And I still don&#39;t understand your situation. Can you show us an example slice and wanted result?</div>

</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, May 22, 2013 at 10:50 PM, Gib Bogle <span dir="ltr">&lt;<a href="mailto:g.bogle@auckland.ac.nz" target="_blank">g.bogle@auckland.ac.nz</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000">
    <div>The reason why I don&#39;t think erode will
      work is that the part of the image that contains the information
      of interest is made up of many disconnected pieces, not very
      different from the boundary layer that I want to remove.  The only
      thing that I can use to distinguish the pixels that need to be
      removed is that they are near the outside of the region.  If I
      apply erosion I will remove many small but important features
      (this is labelled vasculature, and I do not want to lose fine
      capillaries).<br>
      <br>
      Gib<div><div class="h5"><br>
      <br>
      On 22/05/2013 11:12 p.m., Dženan Zukić wrote:<br>
    </div></div></div><div><div class="h5">
    <blockquote type="cite">
      
      <div dir="ltr">
        <div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small"><a href="http://www.itk.org/Doxygen/html/group__MathematicalMorphologyImageFilters.html" target="_blank">http://www.itk.org/Doxygen/html/group__MathematicalMorphologyImageFilters.html</a><br>


        </div>
        <div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small"><br>
        </div>
        <div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small">What
          you probably want to do is BinaryErode and BinaryDilate.</div>
      </div>
      <div class="gmail_extra"><br>
        <br>
        <div class="gmail_quote">On Wed, May 22, 2013 at 7:04 AM, gib <span dir="ltr">&lt;<a href="mailto:g.bogle@auckland.ac.nz" target="_blank">g.bogle@auckland.ac.nz</a>&gt;</span>
          wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">It&#39;s hard
            to know what to call the processing I want to apply.  I have
            a set<br>
            of biological images (actually a 3D image, but for now I&#39;m
            happy to process<br>
            the frames one-by-one) in which the region of interest has
            an irregular and<br>
            incomplete labelled layer around the boundary.  The staining
            of the layer<br>
            was unintended, and its presence interferes with the
            segmentation that I am<br>
            doing.  The part of the image that I want to extract is made
            up of many<br>
            disconnected objects, and there is not much difference in
            the intensity<br>
            ranges of the objects of interest and the unwanted edge.  I
            am willing to<br>
            trim a few pixels off the boundary all the way around - this
            will not cause<br>
            much loss of information.  What I need is way to determine a
            sequence of<br>
            pixels that in some sense defines the extent of the labelled
            region in the<br>
            image, rather like a 2D shrink wrapping.  I could then use
            this to shave or<br>
            peel off the outer layer of pixels.<br>
            <br>
            Does this process have a name?  Are there any existing
            filters or code to do<br>
            this?  Any clever suggestions (I have some ideas)?<br>
            <br>
            Thanks<br>
            Gib<br>
            <br>
            <br>
            <br>
            --<br>
            View this message in context: <a href="http://itk-insight-users.2283740.n2.nabble.com/Peel-an-image-tp7583137.html" target="_blank">http://itk-insight-users.2283740.n2.nabble.com/Peel-an-image-tp7583137.html</a><br>


            Sent from the ITK Insight Users mailing list archive at
            Nabble.com.<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://www.kitware.com/products/protraining.php" target="_blank">http://www.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-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
          </blockquote>
        </div>
        <br>
      </div>
    </blockquote>
    <br>
    <br>
    </div></div><span class="HOEnZb"><font color="#888888"><pre cols="80">-- 
Dr. Gib Bogle
Senior Research Fellow
Auckland Bioengineering Institute
University of Auckland
New Zealand

<a href="http://www.bioeng.auckland.ac.nz" target="_blank">http://www.bioeng.auckland.ac.nz</a>

<a href="mailto:g.bogle@auckland.ac.nz" target="_blank">g.bogle@auckland.ac.nz</a>
(64-9) 373-7599 Ext. 87030
</pre>
  </font></span></div>

</blockquote></div><br></div>