Posts

Showing posts from 2009

Flash game: Cargo Bridge

Image
I came across this fun little puzzle game called Cargo Bridge on Kongregate . Most levels are quite do-able (with lots of walkthroughs available if you're stuck). Thus I shall only post solutions for the more difficult levels. Oh, and the game is a little buggy so if solutions which should work keeps failing for some reason, try deleting the offending joint and rebuilding. Or quit to the main menu and restart the level. Level 12: A non-optimal-but-definitely-works solution for those who are stuck. =) Level 16: This level is quite a pain. One of the suggested solutions on the walkthrough actually had an arched bridge which didn't work well for me as the little guy got stuck. I then came across another solution which was flat, but broke too easily. Thus I modified the support structure and hey presto, it worked! Level 18: Probably one of the most difficult levels. Thanks to Tasselfoot for his walkthrough on YouTube for giving birth to this solution. Don't worry if...

Useful Linux commands

Posted more for self reference, though I hope it can help some other poor souls out there. Linux pipes We all know how useful pipes are, and a quick search will net you tons of information on how to use it. Let's say you wish to find files that have not been accessed for the last 30 days $ find -atime +30 -type f If you wish to delete them, you can either use find 's -exec option, or pipe them using xargs . $ find -atime +30 -type f -exec rm {} \; $ find -atime +30 -type f | xargs rm I also managed to find another reference from Linux Commando about the xargs option: xargs splits up its input arguments at spaces (and newlines). If a file name (or path name) has spaces in it, e.g., "can not do this.pdf", xargs will misinterpret it and thinks there are multiple files. The solution is to invoke xargs with the -0 (zero) parameter. xargs will separate filenames by NUL instead of whitespace. Also, the find command needs the -print0 parameter: this puts a NUL between filen...

SanDisk Cruzer U3 Removal

For anyone having problems removing the U3 program on their SanDisk drive, please note that the removal program does not appear to work on a Vista machine. I was having problems running the removal (both LaunchPad -> Device Settings and the removal software provided on SanDisk Support site). This appears to be a problem with Vista re-detecting the drive mid-way through the removal, crashing the program in the process. Plugging it into a Windows XP machine and running the software did the trick though. U3 removal software from SanDisk Support

Install SMT decoder Moses on WinXP - Part 2

In the second part of this series, we're going to install the SRI Language Modeling Toolkit (SRILM). Read Installing SMT decoder Moses on WinXP - Part 1 . Install SRILM Note: For purposes of this tutorial, we're going to assume the following directories: Cygwin installation directory : c:\cygwin SRILM installation directory : c:\cygwin\mysmts\srilm So from the Cygwin shell, the SRILM directory will be [me@cygwin /mysmts/srilm] $ Download SRILM to your Cygwin drive. (e.g. c:\cygwin\home\<yourname>) Add SRILM to Cygwin bash path Edit "c:\cygwin\home\<yourname>\.bashrc" and add the following lines (replace with own directories as necessary): export PATH=$PATH:/mysmts/srilm/bin:/mysmts/srilm/bin/cygwin export MANPATH=$MANPATH:/mysmts/srilm/man Extract SRILM Create folder and extract the srilm.tgz archive $ mkdir –p /mysmts/srilm $ cd /mysmts/srilm $ tar zxvf /home/<yourname>/srilm.tgz $ chmod –R u+w * Compile SRILM Check that the system is correctly id...

WMP mini mode not available on XP 64-bit

Just a quick note to anyone else who might be trying to get Windows Media Player (10 & 11) to work in the 64-bit version of Windows XP Pro: the official statement from Microsoft is The mini Player mode is not functional on x64 computers. http://technet.microsoft.com/en-us/library/bb490863.aspx While I can live without the function, it does make you wonder about Microsoft's commitment to their product lines...

Installing SMT decoder Moses on WinXP - Part 1

Image
This is posted for my own reference for installing the statistical machine translation decoder Moses with SRILM on a WinXP system, hopefully it'll help anyone else having difficulties with the setup. Install Cygwin Get Cygwin Install required packages Ensure that the following packages will be installed: For general compiling - binutils, gcc/g++, make For SRILM - diffutils (needed for ‘cmp’ command when testing), gawk, perl, tcltk, tcsh For Moses - autoconf, automake, python (for running tuning script), rsync (for script generation), zlib Note: Select "View Full" to make the search easier. Run Cygwin Run Cygwin to ensure successful installation and initialize your bash profile, then quit by typing $ logout Install SMT decoder Moses on WinXP - Part 2