0

So far I am using the Region Based Active Contour Segmentation by Chan Vese from the Paper "Active Contours Without Edges" to segment picture like this synthesized Image without any noise

This picture is very idealized (noiseless) and simple edge detection algorithms will fail for my OCT-images to be specific.

But when I am initializing multiple level set functions at different locations, the level sets always get attracted to the same high-contrast edges.

result of the chan-vese segmentation

And here is part of my code

lambda_in = lambda; lambda_out = lambda;
%Initialize with large box around perimeter of image.
Phi(1:m,1:n) = -1;  Phi(2:m-1,2:n-1)=1;
for t = 0:dt:T
%Approximate derivatives
Phi_x = (Phi(:,[2:n,n]) - Phi(:,[1,1:n-1]))/2;
Phi_y = (Phi([2:m,m],:) - Phi([1,1:m-1],:))/2;
Phi_xx = Phi(:,[2:n,n]) - 2*Phi + Phi(:,[1,1:n-1]);
Phi_yy = Phi([2:m,m],:) - 2*Phi + Phi([1,1:m-1],:);
Phi_xy = ( Phi([2:m,m],[2:n,n]) + Phi([1,1:m-1],[1,1:n-1]) - Phi([1,1:m-1],[2:n,n]) - Phi([2:m,m],[1,1:n-1]) ) / 4;

%Total variational term = Num/Den "Curvature of the contour"
Num = Phi_xx.*Phi_y.^2 - 2*Phi_x.*Phi_y.*Phi_xy + Phi_yy.*Phi_x.^2;
Den = (Phi_x.^2 + Phi_y.^2).^(3/2) + a;

%Compute average value.
c_in = sum([Phi>0].*f)/(a+sum([Phi>0])); %inside the contour
c_out = sum([Phi<0].*f)/(a+sum([Phi<0])); %outside the contour

%Add to previous iteration of u.
force = dt*epsilon./(pi*(epsilon^2+Phi.^2)).*( Num./Den  - lambda_in*(f-c_in).^2 + lambda_out*(f-c_out).^2);
Phi = Phi + force;

%Plotting ...
end

Prior knowledge is that the layer never overlay and mostly are stacked vertically.

So I am asking for a term that penalizes the spacing between different level set functions so that the level set functions do not get attracted by the same edges.

Has anyone done this? Anyhow are the level set functions applicable for this case?

Daniel R.
  • 774
  • 1
  • 7
  • 19
  • The chan vese algorithm works as a black and white image segmentation (not grayscale, black and white). Therefore if you want multiple segmentations, you need to modify the parameters taht control this BW conversion mathematically. I cant remember which ones are they, but you can – Ander Biguri Nov 04 '15 at 18:22
  • I am not sure what you mean with the BW conversion. I am not doing a BW conversion anywhere. Or did you mean that the chan vese only offers a segmentation of 2 groups (let's say black and white)? – Daniel R. Nov 04 '15 at 18:32
  • I mean, mathematically, it is based on a binary segmentation of the image. Not saying you do it explicitly, but the algorithm does it. – Ander Biguri Nov 04 '15 at 18:37
  • Ah, now i get it. That's why I try to use multiple level set functions so I can get multiple different binary segmentation of the image. For each level set function one unique segmentation. – Daniel R. Nov 04 '15 at 18:43
  • Exactly. And to do that, you just need to change your parameters every time you call the level set. With which valueS? that is image dependant – Ander Biguri Nov 04 '15 at 18:44
  • I think this [find horizon in high altitude photo](http://stackoverflow.com/a/22195176/2521214) will be much better for your task. Just modify it to remember all significant intensity bumps ... – Spektre Nov 05 '15 at 08:52

0 Answers0