Path: news.mathworks.com!not-for-mail
From: "Sven" <sven.holcombe@gmail.deleteme.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Fit sphere to planar circles
Date: Fri, 10 Apr 2009 19:50:16 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 34
Message-ID: <gro7to$k0a$1@fred.mathworks.com>
References: <grgcp1$nkr$1@fred.mathworks.com> <c91073f0-2621-4779-b9a0-b2d3ad8083d2@z1g2000yqn.googlegroups.com> <11b5e1ed-fdcf-4eea-a9d5-f7c49b221c40@a7g2000yqk.googlegroups.com>
Reply-To: "Sven" <sven.holcombe@gmail.deleteme.com>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1239393016 20490 172.30.248.37 (10 Apr 2009 19:50:16 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Fri, 10 Apr 2009 19:50:16 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1326470
Xref: news.mathworks.com comp.soft-sys.matlab:531934


trancemissionxxi@gmail.com wrote in message <11b5e1ed-fdcf-4eea-a9d5-f7c49b221c40@a7g2000yqk.googlegroups.com>...
> Sven,
> 
> For some reason fspecial3 is not showing up on file exchange anymore.
> I googled it and the link is:
> 
> http://www.mathworks.com/matlabcentral/files/15981/fspecial3.m
> 
> I do 3D cell nuclei tracking, which are almost spherical, but I know
> about the acetabular issue from papers I read on hough transform
> (tried using it before for my problem).
> 
> Indeed the fft can become computationally intensive if the image and
> mask are large (for me largest volume element is 49x49x49 pixels).
> I like your idea on doing the convolution on the hough transformed
> circles/disks. Since you are done with using the grayscale and have
> binary data for the slice circles, why not resize the image and do
> convolution on smaller image size (if large matrices are a problem).
> Alternatively, you can use a scanning box algorithm on your new voxel
> volume with detected disks.
> 
> There's also this paper (not sure if you have access):
> http://dx.doi.org/10.1016/j.patrec.2005.11.019
> 
> Cheers.

Thanks Trance, that paper actually helped quite a lot. It essentially has an implementation of my "find the best sphere to fit a set of planar circles" problem, and it ends up boiling down to pretty simple trigonometry after you make the (fairly reasonable) assumption that the circles all have the same (x,y) location.

I had a little attempt at the fspecial3 approach, but as you know it is a little computationally expensive, and I'm quite happy with the results so far from the hough circles approach. The CT scans are often higher than 49x49 pixels across the area of interest without downsampling, so hough circles were much faster to compute than the full fft.

One further question to do with the next step of what I'm considering. Do you know or use any kind of radial filtering?  I'm wondering if I could somehow filter the image volume after I find the femoral head using the head centre and radius, in a way that would highlight the acetabular surface. I'm pretty sure a simple threshold outside the sphere would do a reasonable job, but I'd just like to know if what I'm thinking is effective and maybe even commonly used.

Cheers,
Sven.