C#

Compiling Mono SVN on Slicehost/Rackspace Cloud

The following should do the trick. This is an update from my old Mono script. Disclaimer: If your system explodes, your cat dies, or anything else happens because of this script, I am not to blame. If everything works though, I’m always here. Hugs.

More >

Optimization

I needed to optimize a function for my neural network. How hard could it be? It’s only one function, and it’s <5 lines at that…

After spawning a huge thread, I’m left to wonder: why didn’t I continue learning ML after my functional languages class? Blargh!

Benchmarks after the break… More >

Windows XP Registry Hacks

I finally graduate in about 2 months. However, much to my dismay, I have to finish my social volunteer work. No, I didn’t do anything weird – it’s just a graduation requisite. I’ve been working at my university’s computer division, so I’ve had to format anywhere between 4 and 15 laptops every day. Yes. Every. Single. Day.

Unfortunately, most of the laptops are Dell C610s – in other words, 1GHz, 256MB RAM and they’re running Windows XP. You can probably tell that it’s very fun to optimize each system. (I’m proud of myself, they run pretty nicely for the low specs they’re sporting…)

With this in mind, I decided to code a .NET 3.5 application (free, of course) that does the job for me and also manages to be fully extensible through the use of a text-based hack database.

If you’re interested in downloading it, give it a go here. Read more if you’re interested in some of the example hacks, as well as the database specification.

More >

iBrainer

Shameless plug:

iBrainer is now ready for public use. Feel free to give it a try, either on download.com or iBrainer.net

In a nutshell: fix your MP3 collection in a snap. No more Unknown Artist or fixing tags yourself.

I might be biased, but I use it all the time — and I’m loving it!

Unicode to DOS Filenames

DOS is a pain. .NET doesn’t get along too well with DOS either, since everything .NET is Unicode – just like everything, actually.

How to change from Unicode (aka, Kanji characters) to DOS Filenames:

[DllImport("kernel32.dll", CharSet = CharSet.Auto, SetLastError = true)]
static extern uint GetShortPathName([MarshalAs(UnmanagedType.LPTStr)] string lpszLongPath, [MarshalAs(UnmanagedType.LPTStr)] StringBuilder lpszShortPath, uint cchBuffer);

public static string ToDOSPathName(String longName) {
StringBuilder shortNameBuffer = new StringBuilder(256);
uint bufferSize = (uint)shortNameBuffer.Capacity;

uint result = GetShortPathName(longName, shortNameBuffer, bufferSize);

return shortNameBuffer.ToString();
}