John Hunter wrote: > On Dec 10, 2007 8:51 AM, Michael Droettboom <[EMAIL PROTECTED]> wrote: > >> I have 8-spline approximation working on the trunk and on the transforms >> branch. (r4679) > > Thanks Michael, I was working on this myself but it is hard for me to > keep up with you :-)
No problem. I wasn't sure if you were still on vacation... Feel free to replace mine with whatever you came up with if you see further benefit. > In reading the paper Charlie sent and links therein > (http://www.tinaja.com/glib/ellipse4.pdf and > http://itc.ktu.lt/itc354/Riskus354.pdf), one comment was that the > usual magic number > > offset = 4.0 * (npy.sqrt(2) - 1) / 3.0 > > is not ideal. When I tested the JPLs test script with one of the > suggested magic numbers which minimize the SS errors with 4 points on > the ellipse, the error was smaller than what we were getting with the > one above (I used k=0.55191496 from the Rivus paper). The first thing I tried when I saw Lancaster's paper (from Charlie's e-mail) was to leave it as four splines and use his suggested number of 0.551784. That improved things for James' example, but not nearly enough. There were still around 10 pixels between where the ellipses should be and where they were. It's possible that an even better magic number exists (I gather Lancaster's was arrived at by experimentation), but I was doubtful that one could be found that would be as good as just going to 8 splines. > I see you are > using a different formula for the magic number in the trunk. Do you > think we could see additional accuracy with a different magic number > as discussed in these papers? For the 8 spline approximation I put in the trunk this morning, I used Lancaster's suggested magic number of 0.2652031. (MAGIC45 is just the rectilinear distance of the MAGIC number at a 45 degree angle). Again, feel free to tinker, but that number seemed "good enough" on James' example. Cheers, Mike -- Michael Droettboom Science Software Branch Operations and Engineering Division Space Telescope Science Institute Operated by AURA for NASA ------------------------------------------------------------------------- SF.Net email is sponsored by: Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel