Preliminary Results and higher-order error sources

I have some test results today, and I'm quite happy with how they turned out.  Quick refresher of the parameters: range refers to the target distance in centimeters, a_ang is the rotation of the major axis of the projected ellipse, and b_ang is a measurement of the target's rotation about the major axis, both in radians.

The convention when dealing with rotated ellipses is to measure the angle of rotation of the major axis from +j (beh) clockwise (BEH!) but also, since I went through the trouble of rotating these images so that they're not sideways, a_ang is measured clockwise from -i.  The elliptical fit is programmed to run along the inside edge of the larger target circle.
{'range': 42.27010789888579, 'a_ang': -0.04591864992309163, 'b_ang': 0.3644755561635681}
Standard up front shot, I'm impressed that the software picked up that the target is actually tilted upwards relative to the camera though I think .36 radians (20 ish degrees) is an overestimate, I don't have an elegant way of measuring that angle directly, but if I had to guess I'd say it's actually a little lower than 15 degrees.  There are a few good reasons for this though.  Crucially, the range is just about spot-on (true range is ~44 cm).
{'range': 72.82038864679446, 'a_ang': 1.5144669062373437, 'b_ang': 0.602319823743206}
A good fit from a larger distance, true range is about 77 cm here and 0.6 radians on b_ang is just about as good as it gets (true b_ang is ~35 degrees which is ~.6 radians). 

Notice how the fitting ellipse overlaps the target on the side farther from the camera and undershoots the rim on the closer side.  This happens because of a subtle error source that may turn out to be a blessing in disguise.  

Essentially the math to make this observation meaningful assumes that all pixels of the ccd are collocated in the exact same point in space.  Because this is not the case, what you actually get when you image a tilted circle like this is not a regular ellipse. Since each pixel is spaced slightly differently on the ccd and each pixel will capture a differently-sized footprint on the target, the ellipse is going to be warped.  Specifically, pixels observing the closer parts of the surface will observe a smaller area than pixels observing parts further away, thus closer regions of the target will take up more pixels than further ones.  You end up with a shape that looks a little like a short, fat egg (standing up along its minor axis), with the region of the target towards the camera comparatively larger & wider than the region further away. 

You can see this effect much better in the image below, where it is aggravated by the fact that the target is close enough to the camera that the difference in distances from the camera to the close edge of the target and the far edge start to approach a significant portion of the range to the target centroid.

{'range': 42.838611744377914, 'a_ang': 1.3846912630127046, 'b_ang': 0.5895175878797532}


So what's to be done about this? Nothing, for now.  because the close edge projects further out and the far side projects closer, as long as you uniformly sample the inside rim of the target and choose a high-enough sample size for the fitting function, the warping of the close side & the far side will do a lot to cancel each other out and you end up with a faithful measurement and (again, crucially) an unperturbed major axis length & angle, from which further calculations and calibrations can be done to improve the fit if necessary.

I was going to talk about why this may be a good thing in this post, but this has been a lot and that will also be a chunk of blabber.  Maybe later.

Comments

Popular posts from this blog

The Future of MARCO

A Working Filter Actuator