[Insight-users] Use Initial Segmentation as Input Level-Set

Juan Cardelino juan.cardelino at gmail.com
Tue Aug 16 07:28:07 EDT 2011


What are the output parameters when you initialize with Fast Marching?
In addition, why don't you save the F.M initialization to a file and
then use this as initialization.
Because maybe the problem is the output of the previous segmentation itself.
As a good practice, never try two changes at the same time.
First, try that you are able to use an initial segmentation from file
using a simple level set (generated with FM and saved for instance).
Second, and if the previous works, analyze what happens with the
initial segmentation.

If you could provide some images it will be also very helpful.

On Tue, Aug 16, 2011 at 5:37 AM, Abayiz <abayiz at yahoo.com> wrote:
> Hello Juan,
> Thank you again for your sincere answer.
> That itk code called "GeodesicActiveContourImageFilter.cxx" works well if I
> didn't change it, just using Fast Marching method to produce the level set
> as original. After my change, the initial contour is the result of another
> segmentation method, using thresholding, and the parameters I provided is as
> follows:
> ************
> sigma = 1.0
> sigmasoidAlpha = 1.0
> sigmasoidBeta = 1.0
> propagationScaling = 5
> ************
> And, the final screen gives out these parameters:
> ************
> Max. no. iterations: 800
> Max. RMS error: 0.02
> No. elpased iterations: 17
> RMS change: 0.0166297
> ************
>
> I changed the propagation scaling from 5 to 2, and it gives out these:
>
> ************
> Max. no. iterations: 800
> Max. RMS error: 0.02
> No. elpased iterations: 16
> RMS change: 0.00562183
> ************
>
> How can I obtain a better result with these?
>
> Looking forward to receive your helpful suggestions. Thanks in advance :)
>
> Regards,
> Abayiz
>
>
>
> ________________________________
> From: Juan Cardelino <juan.cardelino at gmail.com>
> To: Abayiz <abayiz at yahoo.com>
> Cc: itk <insight-users at itk.org>
> Sent: Monday, August 15, 2011 4:04 PM
> Subject: Re: [Insight-users] Use Initial Segmentation as Input Level-Set
>
> Hello, Abayiz,
>
> Thank you for the further details, however more work is required to
> diagnose the problem.
>
> The Geodesic Active Contour algorithm only moves the curve if you are
> close to the object to detect. To solve that, it is usual to add a
> constant inflation/deflation force that moves the front outwards or
> inwards. So setting this parameter you should see the curve move,
> unless of course you are already over the boundaries of the object of
> interest. Have you checked that?
> In ITK's jargon, the parameter that controls this propagation is
> called propagation scaling.
>
> In addition, trying with a simple binary example (even in 2d) could
> also serve you to debug. Lets say, a white cube/square over a black
> background and the initial contour being a sphere/circle outside the
> cube using a deflation force.
>
> How about the initial contour? Was it hand drawn? or is it the result
> of another segmentation? Because a common mistake here is to invert
> the initial level set and you could observe weird behaviours
>
> What were the final parameters of the evolution? Number of iterations,
> RMS error value?
>
> Finally, you should look in the GeodesicActiveContourImageFilter
> example, where an observer is attached to the filter. This observer is
> helpful to show how the curve evolves, you could show the current
> number of iteration and the actual RMS change value.
>
> Try to provide answers for all these questions and show here their results.
> HTH.
> Best,
>         Juan
>
> On Mon, Aug 15, 2011 at 4:52 AM, Abayiz <abayiz at yahoo.com> wrote:
>> Hello,
>>
>> Thank you for your reply.
>> I just used the "GeodesicActiveContourImageFilter.cxx" in ITK to perform
>> the
>> level-set segmentation. And I used a reader to read the initially
>> segmented
>> data, then give that data as the input to the
>> "GeodesicActiveContourFilter",
>> that is, in the original code, it was like:
>>
>> *****************
>>   typedef   float           InternalPixelType;
>>   const     unsigned int    Dimension = 3;
>>   typedef itk::Image< InternalPixelType, Dimension >  InternalImageType;
>>
>> typedef  itk::FastMarchingImageFilter<
>>                               InternalImageType,
>>                               InternalImageType >
>> FastMarchingFilterType;
>> FastMarchingFilterType::Pointer  fastMarching =
>> FastMarchingFilterType::New();
>> ...
>> geodesicActiveContour->SetInput(  fastMarching->GetOutput() );
>> *****************
>> But, I changed it as:
>>
>> *****************
>> typedef  itk::ImageFileReader< InternalImageType > ReaderType;
>> ReaderType::Pointer reader2 = ReaderType::New();
>> reader2->SetFileName( argv[10] );
>> geodesicActiveContour->SetInput(  reader2->GetOutput() );
>> *****************
>> The code compiles, but the result is nothing but exactly the same as the
>> initially segmented data, which was read and given to the
>> "GeodesicActiveContourFilter", even if I changed several kinds of
>> parameters.
>>
>> Am I doing something wrong here??
>> Looking forward to receive your suggestions. Thanks in advance.
>>
>> Regards,
>> Abayiz
>>
>>
>>
>>
>>
>>
>>
>> ________________________________
>> From: Juan Cardelino <juan.cardelino at gmail.com>
>> To: Abayiz <abayiz at yahoo.com>
>> Cc: itk <insight-users at itk.org>
>> Sent: Monday, August 15, 2011 2:31 AM
>> Subject: Re: [Insight-users] Use Initial Segmentation as Input Level-Set
>>
>> On Sun, Aug 14, 2011 at 9:29 AM, Abayiz <abayiz at yahoo.com> wrote:
>>> Hello,
>>> I want to perform level-set segmentation using a set of already achieved
>>> initially segmented 3D data. What I tried was giving the initial
>>> segmented
>>> data as the output of the level-set filter  (for instance instead of
>>> giving
>>> FastMarchingFilter->GetOutput(), I gave reader->GetOutput, after reading
>>> the
>>> data) . But it didn't work. How can I do this??
>>
>> Well I do exactly that and works, it is just a matter of details. If
>> you provide more information about how exactly do you implement it
>> maybe we can help you.
>> In addition, it would help if you also tell us what exactly "didn't
>> work means". It doesn't compile? The program crashes? It gives
>> unexpected output?
>> Please try to be more precise, we are not seeing your screen so we
>> can't possibly guess what is going on.
>>
>>
>>> Sincerely thank you in advance!
>>> Regards,
>>> Abayiz
>>>
>>> _____________________________________
>>> 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://www.kitware.com/products/protraining.html
>>>
>>> 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-users
>>>
>>>
>>
>>
>>
>
>
>


More information about the Insight-users mailing list