Neat Feature

• Chris Liscio

The optimization I most recently added to FuzzMeasure solved a problem I was avoiding for far too long. Since I generalized my MLS calculation, I have noticed longer and longer delays on startup to calculate the sequences. Sequences of order 20 and above take especially long to compute (some can take up to 30 seconds!). </p> <p> In order to avoid this delay, I wanted to load the sequences from disk. The trouble I had with that approach is that I didn't want to require such a large download for my application. Furthermore, it would be more difficult for registration of an evaluation version of my software. </p> <p> Enter the compromise. I now calculate the MLS sequences when they are first selected by the user. Once they've been calculated, they're stored in the main bundle's resource directory (which is safe for users to move around their disks – I love bundles). Any time after that when a sequence order is selected, it's either calculated and saved, or pulled from disk. It seems to work pretty great now, and the time taken to start FuzzMeasure has dropped significantly! For the developers in the audience, this was made easy thanks to the NSCoding protocol, the NSArchiver class, and the NSUnarchiver class. Yay for Cocoa! </p>