Has anybody heard of this cool command line program for Linux, that you can use to convert the formats of images with a single command, and even convert images to PDFs? Great for taking screenshots and converting the PNGs to PDFs so you can quickly include them in your research papers?

The program is called imagemagick, and it can be installed on Ubuntu with a simple

$ sudo apt-get install imagemagick

Then, to convert a file, just do

$ convert file.png file.pdf

And voilá! It works. Neat, eh?

So, everybody having a good holiday?? As for me, I got unlucky with my super sleek and shiny laptop and its motherboard got fried. So, for quite some time I was relegated to using a laptop which

(i) had a Spanish keyboard, on top of which I was using German and English layouts (oh yes, even for programming ;-) ), and

(ii) had the period/colon key missing (it had been ripped off), so I was using another keyboard connected via a USB port to type my periods and colons whenever they came up. And no, I could not only use the USB keyboard because that one in turn had some keys not in the best working order (!!! wait, it gets better soon !!!)

After bearing with all this for quite some time, I thought there has to be some way I can map the period/colon key to one of the keys I am not using, for example Pause, F12 etc., and do away with the additional USB keyboard, and thus make things a little better. So I finally stumbled upon Xmodmap, which my Ubuntu was pre-equipped with, of course, and figured out a simple way to accomplish the task at hand.

Use the following at the command line:

xmodmap -e "keysym Pause = period"
xmodmap -e "keysym F12 = colon"

And you’re done! Now Pause prints the period and F12 prints the colon, no matter whether you are using the German, English or Spanish layout. I guess if you put “period colon” together then the later character will be printed with shift, but I didn’t experiment with that.

I tried putting these lines in my .xinitrc file and then in my .profile, but for some reason it doesn’t seem to be running automatically when the computer boots. For the time being I am having to do it manually every ime the computer starts afresh.

Here is a list of all the “keysym” codes you can use with Xmodmap!

There you are – happy Xmodmapping ;-)

Infomap is an NLP software from Stanford which simulates a variant of a Latent Semantic Analysis, with term-term matrices (instead of term-document matrices) and singular value decomposition. In a nutshell it is a C program which is readymade for you to build semantic vector spaces and compute similarities between words or concepts.

To install it on Ubuntu, make sure you follow these steps:

  1. Install g++ (sudo apt-get install g++)
  2. Install gdmb (with dbm-compatible modules – refer to the README/ INSTALL file)
  3. Install Infomap

Hope that works!