Converting 2D golf swing sequences into 3D models

Saturday, March 1, 2008

Something Like Tomographic Reconstruction

The motion history masks have a lot of good signal that we want to take advantage to supply hints to the RANSAC fitting about where the boundaries of the swing trajectories are. We are using a projection slice approach to try and get a gift wrap fit around the border of the swing.

We first sum up the the number of white pixels in each column. Then we scan from left to right to compute two things:
  • The index of the leftmost column with at least THRESHOLD% pixels white.
  • The index of the rightmost column with at least THRESHOLD% pixels white.
These indices give us two lines representing the boundary of the object projected onto the x-axis.

We rotate the image and repeat this process, giving us similar projections along multiple directions. The polygon enclosed by these boundaries is an approximation of the boundary of the object.

The following are the results of running this process on the binary upswing motion history image from a previous post. The thresholds for the images below are 3%, 6%, and 9%, and we evaluate projections in 16 directions.







The following is the result for the corresponding upswing with a threshold of 5%.



Notice that the intensity of the mask is duller than the original. This is probably an artifact from the way we are manually rotating images, but it doesn't seem to affect the results.

Also note we have not yet computed the enclosing polygon; we are simply drawing the boundary lines from each projection.

No comments: