Saturday, March 15, 2008

Lucene

http://en.wikipedia.org/wiki/Lucene

http://news.ycombinator.com/item?id=137802

Lucene is a fast text search engine. Nutch is a derivative project that also has web crawling etc. There is pyLucene too - Python interface for Java based Lucene.

Friday, February 29, 2008

Cool Quote

"I sometimes edit my .emacs file in vim."

From : Mark Tran's Blog

Sunday, February 24, 2008

Did Today:

Parsed email with Python
Poached egg (tasty)
Read some "Ender's Game"
Got bluetooth working my laptop
Installed Arc
Ran news.yc - played with it

Monday, February 18, 2008

Since I acknowledge that I don't know much, I am able to learn more. I didn't learn much all through college as I had this sense of greatness as someone who had been coding since 11. Gaa... Had I been more open about my stupidity, I could have got more done, instead of feeling the need to seem elite and shit... Anyway, lesson learned and onward we march.

This is the article that triggered these thoughts:
Gmail's Humble Beginning

GNU date

I didn't know that you can use date strings with this tool

kiru@kiru-laptop:~$ date
Mon Feb 18 07:25:16 PST 2008
kiru@kiru-laptop:~$ date --date "ten years ago"
date: invalid date `ten years ago'
kiru@kiru-laptop:~$ man date
kiru@kiru-laptop:~$ date --date="ten years ago"
date: invalid date `ten years ago'
kiru@kiru-laptop:~$ date --date="10 years ago"
Wed Feb 18 07:25:57 PST 1998
kiru@kiru-laptop:~$ date --date="10 years and 12 days ago"
date: invalid date `10 years and 12 days ago'
kiru@kiru-laptop:~$ date --date="10 years 12 days ago"
Tue Feb 6 07:26:28 PST 2018

[more info]

Human friendly date strings are awesome. It would be a nice feature to have in my webapps. I need to wrap this GNU tool in Python/Javascript code. I wonder if there is one already.

Thursday, February 7, 2008

I didn't know about Python signal handling before. I think I lost a lot of my cockiness and feel much more humble now.

I was browsing these 15 exercises for learning a new programming language. I attempted this in Python: "Display series of numbers (1,2,3,4, 5....etc) in an infinite loop. The program should quit if someone hits a specific key (Say ESC key)." Really trivial execise, right?I've done the exact same thing in C about a goddamn decade ago using getchar. I realized that I don't know the Python equivalent. Googling gets me kinda unrelated stuff like marriage without sex! Hmm. Ok. Then I came across this good example. Then I wrote this: Pgm1. It calls that fn when Ctrl-C is pressed.

Miles to go still...

Wednesday, February 6, 2008

I thought I'll construct a computer from scratch. Instead of messing with hardware, I thought I'll build each of the fundamental hardware components - primarily NAND gates - using software and take it from there. In effect, it would be a computer inside a computer.

Though I've groked it, I've not been a fan of structuring my programs using object oriented techniques so far. I wanted to model an electronic circuit with resistors, batteries and wires (and later, the other components like transistors). I am doing this to slowly build up a computer as popularized by 'From NAND To Tetris in 12 Steps'.

I ended up getting an intro to OO in Python.