Found huge memory leak in Harvard Shuttle

Memory leak
Oops

So it turned out there was a huge memory leak in the Harvard Shuttle app I just released. I was doing a pretty good job of cleaning up my data structures, even though there was really no need to in a managed language like C#. But lo and behold, when I opened up Task Manager to kill something, I saw that my app took up over 500MB of RAM (!!!). Either way, I definitely should’ve ran a memory profile on the app before sending it out.

It took me a while to find a good tool to figure out where the memory leak was coming from. I eventually came across this post, which is a super detailed, step-by-step process on how to hunt down memory leaks with any C# app (for whatever reason, WinDBG didn’t play nice with my app; not sure if this is my fault, or a Windows Store app issue). For the TL;DR, you’ll need to download a tool called PerfView, which is linked in the article, and use that to create a diff between two snapshots of the heap for your app. From there, you can figure out where the memory leak is coming from.

More...

The sad state of shuttles at Harvard

Harvard Shuttle
A Windows 8 app for shuttles around Harvard

It’s April 2013, and there’s still not a great experience at Harvard for a simple task: finding a shuttle time that’s relevant to you. As far as I know, students on a laptop/desktop computer can find a shuttle time via one of the following ways:

  • Go to the official shuttle tracking website, which will display a map with a bunch of routes and moving shuttles
  • Go to Shuttleboy, which has an awesome interface but whose times were up until about a week or two ago, wrong for the 2012-2013 year. Update 3/12/18 - Shuttleboy appears to be dead.

I think that the official shuttle tracking tool is awful because it does not give users the information they want quickly, and (sadly) Shuttleboy was not usable (until just recently) because the times were actually wrong (trust me, this app I made originally depended on the Shuttleboy API, but when I tried integrating it with the official tool’s API, times were definitely off; it looks like they recently fixed them, as I just checked while writing this post haha). So, what should a good shuttle app do?

More...

This is not my first update in over a year...

Kinect-controlled Arduino car
An Arduino car controlled by a Kinect

So I finally sucked it up and purchased permanent hosting for this site a few months ago. The free hosting I was using would completely drop my site every other month if it didn’t get at least a certain number of views; this meant that every few months I would have to FTP my entire site plus a backup of the database back to the host. Of course, I totally forgot to make backups/make a script to back up my database, so I lost around 5 posts from over the summer :(

A lot has happened in the past year, and I’ve updated the about section accordingly. I interned at Microsoft with the Windows team over the summer, and I accepted an offer to come back this coming fall. I’m seriously geeked at the prospect of working on the Windows kernel. In the mean time, I’ve taken a lot more CS courses (7 courses, plus the ones I teach), and I feel like I’m a slightly better programmer compared to the guy who made the last post on this website :P

More...

Finish it!!!

New website
New look for the website

You are now (as of the time that this post was written) looking at the new site! I’ve finally gotten to a point where the new site is fully functional and looks semi-decent, so I decided to make the switch.

More...

Almost there...

Preview of the new website.
By Wiziq Inc.

I’ve almost finished with the new design. Right now the Projects page is almost done; the only thing missing right now is making programming language links active such that they lead to a list of projects.

Originally, I wanted to treat languages for projects like tags for posts: clicking a language will display all the projects that were “tagged” with that language. However, currently only one project is displayed at a time, so I think I’m going to make another separate page for viewing projects by language that may look more like a search results screen.

More...

Makeover

The current site
This is pretty ugly

This site needs some shaking up. It’s hard to read, has a pretty poor palette, and is pretty hard to navigate. It’s also pretty simple, and doesn’t provide me any design challenges.

So how am I going to remedy this?

More...

It's alive!!!!!!

Playlist shuffler
A fun, useful project for me

I’ve uploaded the Playlist Shuffler to a GitHub repo.

I believe you must be running Windows 7 in order to install the player, but I haven’t tested it on other operating systems.

Next up is stylizing this site!

More...

Nooooo!!! Apple broke my music player!!!

iTunes
By Benz.darkness, CC BY-SA 3.0

Now that I finally have some free time, I’ve been working on a couple of projects.

First, iTunes Match “broke” my custom music player, in a number of ways that weren’t really my fault. I was using someone else’s program to extract iTunes playlists from the iTunes Library xml file, and it was no longer working for some reason. On top of that, it always used tons of memory (it loaded all the songs into a large array), and took up to 10 minutes for 20,000+ songs.

In other words, this became a great opportunity for me to build a parser myself. So, I added a few C# files that does the same thing in about 5-10 seconds for 24,000 songs, since I just an XML stream reader.

More...