21 February 2012

IAP 2012 Recap

What I actually did:
  1. Run two phenomenal events (in one weekend, no less): Battlecode and Techfair. This really did take huge toll on me: for almost 75% of IAP, I felt that I had little to no time for myself because of all the work I needed to do and that every task was incredibly time-sensitive, which added even more stress. However, in the end, I really do have to say that they were worth every minute of early morning Java and sitting in SAO's office waiting for emails.
  2. Work out. I began my strenuous regime last IAP, having diligently gone to the Z center every morning to run and bicep curl. Unfortunately, I've gotten progressively lazier, so I worked out approximately three times each week. The upside was that I worked out with Jennifer, who taught me how to bench, squat, and deadlift, which turned out to be way shorter and more effective than my tedious routine! I'm extremely pleased at my results after one month.
  3. Move to BigRoom. Essentially I created a giant island in the middle of the room with two rows of desks against each other for maximum desk space for lab work and such. However, three monitors eat up quite a bit of space (and so does my uncased hackintosh).
  4. Mystery Hunt. This year's quest was lame because it was a giant mishmash of puzzles instead of having a unifying plot.
  5. Work on scooter. I finally re-ordered a bunch of parts, mainly for the hub motor, which is partially done, after the gruesome experience of creating a cancerous mixture of epoxy to secure the magnets onto the motor can. More on that in another post.
  6. Work on Power Mac G4 case mod. It's almost done! I'm serious! It just needs some blowing because I was a moron and didn't remove the motherboard when I was dremeling, which is now covered in tiny metallic shards.
What I didn't do:
  1. Power Mac G5 case mod. I'm surprised that my [lack of] self confidence is deterring me from mechanical projects since I'm extremely scared I'll make a mistake. It does make a nice base for my hackintosh, though.
  2. Finish projects. Ever since I read Steve Jobs (an incredible read, by the way), my standards for myself skyrocketed. Thus I now have an even harder time to deem a project finished, since it could always use some finer adjustments. 

18 February 2012

Lion's Terminator, except not really [updated]

Occasionally I've been getting messages from vim such as:

$ vim imageIO.py
Vim: Caught deadly signal ABRT

Vim: Finished.
Abort trap: 6

I thought that was nothing at first, but when it happened again today, I suddenly remembered that Lion will automatically terminate processes to keep memory usage reasonable while assisting having apps open, a là iOS.

[Update] I looked into Console.app for more details, and voilà!

Application Specific Information:
*** error for object 0x73612e312d347865: pointer being freed was not allocated

Said address looks suspiciously like ASCII as pointed out by superstar John Dong. Translating the little endian pointer to ASCII yields

>>> '\x73\x61\x2e\x31\x2d\x34\x78\x65'

Additional insight is greatly appreciated.

10 February 2012

24GiB RAM Put to Good Use

And this means I probably will pursue videography / video post-production as hobby. Thanks Apple!

And, for nostalgia, this is the video that got me interested (yep, eight good years ago):

09 February 2012

Using git-svn (and vim) for 6.005

Hey everyone,

I figured that some of you might want to bypass eclipse and using a mouse and use something more user friendly, say, vim. Here's a basic outline of getting it to work on Mac/Linux:

- Install git-svn. Mac users, you'll probably want to get it from macports.
- cd to the dir in which you want the projects to be and run

git svn clone https://svn.csail.mit.edu/6.005/sp12/users/$USER/ps0

replacing $USER with your athena handle (if your username is not the same as the same as your athena handle) and ps0 with the problem set you want

- run through the git-svn prompts. to sanity check: at some point, it should ask for your svn password.

You should be good to go!

As for JUnit tests, you need to first set the $CLASSPATH (preferably in your bashrc),

export CLASSPATH=$JUNIT_HOME/junit.jar:/myproject/classes:/myproject/lib/something.jar

get the JUnit jar(s), and then run

java org.junit.runner.JUnitCore <test class name>

Hope this helps!

Sources: http://junit.sourceforge.net/doc/faq/faq.htm#running_1