• About

    Swaroop C H is 29 years of age. He is a coder and startupper. He has previously worked at Yahoo!, Adobe, his own startup and Infibeam.


    Read more about him


    Email: swaroop (at) swaroopch.com

  • Subscription

    If you want to know when new stories and articles appear on this website, you can receive them via:

  • I'm a Wannabe Hacker

    The Glider: A Universal Hacker Emblem

Archive for March, 2005

Overtime

Friday, March 11th, 2005

I still can’t stop laughing at this:

(IRC chat room) Ben174 : If they only realized 90% of the overtime they pay me is only cause i like staying here playing with Kazaa when the bandwidth picks up after hours. ChrisLMB : If any of my employees did that they’d be fired instantly. Ben174 : Where u work? ChrisLMB : I’m the CTO at LowerMyBills.com * * Ben174 (BenWright@TeraPro33-41.LowerMyBills.com) Quit (Leaving)

:lol:

(via Kapil)

Tautologies are overrated

Thursday, March 10th, 2005

[code] $ python2.4

True,False = False, True True False False True a = True if a: ... print 'Hello World' ... if not a: ... print 'Hello World' ... Hello World [/code]

I am a big-time Python fan but this is crazy!

(discovered via python-list)

The Job Spool

Thursday, March 10th, 2005

Today, I got a job offer in my inbox from … err, let’s just say a well known company. They say some quite interesting things like "We have received your profile through one of our employees and find that it matches some of the openings we have with us. These openings are in our Imaging & Printing Group Development Center" and then they say that the job profile has to do with printer drivers for Windows and hardware design! How the heck did my profile match that?

Anyway, I still can’t make out whether this is just spam or it is for real ; although, there is a telephone number, address and all that.

However, I’m not looking for a change. The job profile would have to be something really mindblowing for me to even consider a change from Yahoo!. If any recruiter is reading this, please see what Ted Leung says to recruiters, the same 4 points apply to me. Thank you.

Gymmitment

Wednesday, March 9th, 2005

I’ve finally made it to day 3 of gym. If my ‘gymmitment’ makes it through 7 days, then I think I’ll be regular and get back in shape. I want to regain the fitness I had exactly a year ago.

I thought it was a funny coincidence that Manish Jethani made a commitment on the same day. The very same day, I realized we go to the same gym when I bumped into him! This was the first time I’ve talked to him offline :smile:

Indian Music Online

Tuesday, March 8th, 2005

Most music sites will work only on Windows and that too specifically IE – so I was glad to see that MusicIndiaOnline now works on Linux using the RealOne Player. Their FAQ answers about how to get it to work on Linux.

Btw, I really like this album by Om – The Fusion Band, especially the ‘Maula’ and ‘Mohana’ songs.

Its great that I get to hear these songs for free. Now that I have heard these songs and really like them, I can buy the cassette/CD from the music shop knowing that the money is well-spent. I usually have a good nose errr…. pair of ears for music but off late, I’ve bought a few cassettes which I’m sure I’m never gonna hear again.

Tip: Mepis Linux comes with RealOne installed. So I didn’t have to do anything to get this working. It just worked out of the box. I like this so much that I want to say it again – ‘It just works.’

Yahoo! is a 10 year old kid

Thursday, March 3rd, 2005

Yesterday was Yahoo!’s 10th birthday party and has officially completed 10 years today :D .. the day started off with each of us getting a Y! branded bucket full of chocolates.

Happy 10th Birthday Yahoo! Yahoo! 1995-2005 A Bucketful

The Bangalorean Yahoos sponsor a National Child Labour Plan School and we had the kids come over in the morning as part of our celebration. About 50 kids had come and apparently, there was a Tom and Jerry show. I had come in around 11 (as usual) and saw the mail regarding this. I went downstairs to the 3rd floor and I see 50 kids shouting and playing and laughing, total chaos! It was good to be back in that school atmosphere. There were lot of games planned and about 7 of us came ad-hoc to help the kids have a good time.

Skipping Drawing Bowling

There was drawing, bowling, basketball, skipping, throwing the hoop, playing with the big hoop (I forgot what this is actually called, this is where you have a big circular ring and you try to shake it with your hips), one kid did this really well and with such ease that we were jealous, and there were many other games as well. The fun lasted for about a couple of hours and then we had to force the kids to leave the games and go for lunch.

Basketball The Hoop The Hoop Lunch

After we lunch, we tried to gather all the children. Avinash and myself had a hard time to shepherd all the kids but they were such a sweet bunch and they were so full of enthu that it made it easy. One particular kid won lots of pencils but he gave it back to Ankit and asked him to give to the teacher so that they can give it to the other children. That was so heart-rending and reminds me about the kind of life the kids previously had. Its not hard to imagine that these kids were forced to do child labour and had a hard life. They now have a school to go to and hopefully they learn to lead a good life as well.

We asked the kids to sing ‘Happy Birthday’ to Yahoo! and boy, can those kids sing loud! And I mean really loud. Even yahoos from the other floors heard it. (I had recorded the video of it but it was too big so I couldn’t upload it.) Then we finally gave an incentive (ok, ok, we totally bribed them) that if they studied well in school and made the teachers proud, then we would have more such parties for them. All this interaction was in Kannada since they don’t know English and Avinash did most of the talking ; he would make a good lecturer indeed ;)

This was followed by a treasure hunt ironically titled ‘The Great Yahoo! Search’. Each wing of each floor was a separate team. All I can say is ‘dhoondthey reh jaooge’ became our theme! :lol: We had really cryptic clues and we had a load of fun trying to figure out what they meant. For example, ‘One key to help us all, one bang to find it. One key to cool us all, one fire to fight it’… we struggled for half an hour on trying to figure that one. Think about this before you read the next few lines :mrgreen:

Treasure Hunt Treasure Hunt

That one really had us scratching our heads. We looked in the refridgerator and lifted up fire hydrants. One of us even broke the fire alarm thinking a bang could lead us to the answer! :lol: That was a big ruckus, the security came running thinking it was an actual fire. The answer finally turned out to be a key on top of the tubelight next to the fire extinguisher and water cooler in the 2nd floor! This led to finally 4 more clues which we solved pretty quickly. By the time we finished the 3rd clue, one of the teams had already won, but that didn’t stop us from proceeding further. This was hell lot of fun and we had a lot of running around. A cool way of making us all get up from our seats ;) I wish we can do more of such things. Big thanks to Shivku and Ankit for organizing this.

In the evening, we had a showing of the video depicting the 10 years of Yahoo! Its hard to imagine how 2 kids in a trailer in Stanford University with a bunch of computers with wires all around and clothes thrown all over the place led to the "biggest website in the world with 165 million registered users, 345 million unique visitors a month, $49 billion market cap, and a 62 per­cent increase in revenue last quarter , bringing 2004 total revenue to $3. billion".

There was a whole lot of laughs and funny moments in the video with David and Jerry telling their story. The most poignant moment was when Jerry explains that the yellow and violet colors were especially chosen because they were the most cheapest colors available when they were painting the office walls :lol: , and now they symbolize the vibrancy and colorful nature of the company.

At the end of the video, I realized how invaluable Yahoo! really is and how the Internet really means Yahoo! to many people. What started out as a simple directory of content on the internet has become the hottest destination for anything and everything from searching for jobs to looking after pets and of course my favorite parts – mail, calendar, addressbook and notepad. Yes, Google is in the limelight now (and for good reason) but let us not forget that Yahoo! does much more and there are more exciting things are on the cards in the coming months. What I find striking is that Yahoo! has had competitors in all the fields and yet each Yahoo! vertical has been consistently in the top 2 or 3 in each of the fields from mail to jobs to search and so on.

Let's party Party Party animal Circle of dance Party

This was followed by chaats for the hungry and then the party started. The music was played by one of the DJs from Spinn. It was a long and hard party. I still have the beats sounding in my head. All in all, Yahoo! sure knows how to party and emphasizes what I term the Yahoo! way – ‘Work hard and party harder’ :D

Yahoo! Search Python API Howto

Tuesday, March 1st, 2005

I guess most of you would’ve heard the announcement by now that a Yahoo! Search Developer Network a.k.a. YSDN has been started. The idea is to build a community around Yahoo! Search by opening up search webservices (with documentation) along with mailing lists, a blog and even a wiki. I haven’t had much time to explore it, but here’s what I’ve explored so far. This is more of a ‘how i did it’ rather than ‘howto’ but oh well, let’s get on with it.

First, I got an application ID. You need a Yahoo! ID to get a appID. Since I had already logged into my mail, I didn’t need to sign in. I gave a very unimaginative name ‘qpicsearch’ – I was thinking of creating an image search GUI using PyQt. I clicked on ‘Submit Registration’ and done.

I downloaded the SDK and read the FAQ. Python is my language of choice and as you can see from the title of this post, I am concentrating on that. Then, I installed the Python API:

[code] python setup.py build sudo python setup.py install [/code]

It first gave me an error that /usr/lib/python2.3/config/Makefile was not found, so I installed the python-dev debian package, the installation then proceeded smoothly.

The pYsearch-1.0/docs/ directory has some nifty pydoc-generated documentation. It helped me get started with my first program:

[python]

!/usr/bin/env python

import sys from yahoo.search.webservices import ImageSearch

app_id = ‘qpicsearch’ # your appid here! searcher = ImageSearch(app_id) searcher.query = sys.argv[1] searcher.results = 1

results = searcher.parse_results() for result in results:

    for key, value in result.items():
            print key, '->', value

[/python]

and I ran it like this:

[code] $ python qpicsearch1.py bangalore Thumbnail -> {'Url': u'http://re2.mm-c.yimg.com/image/548038611', 'Width': 120, 'Height': 81} Publisher -> RefererUrl -> http://www.zonevoyage.com/photos/inde/imagepages/image1.htm Copyright -> Title -> IND Bangalore VBangal1 Url -> http://www.zonevoyage.com/photos/inde/images/IND-Bangalore-VBangal1.jpg ClickUrl -> http://www.zonevoyage.com/photos/inde/images/IND-Bangalore-VBangal1.jpg Summary -> Width -> 450 FileSize -> 43602 Height -> 304 FileFormat -> jpeg Restrictions -> [/code]

That’s an amazingly small program and does so much cool stuff. Leif has designed a very intuitive API. Hats off to him!

Next, I wanted to create a GUI using PyQt. So, I opened the Qt Designer and drag-and-dropped a line input, button and iconview widgets.

Qt Designer

I used urllib2 to download the actual images and then used QIconViewItem to display each of the images. I even put in a nifty progress bar that indicates how many images have been downloaded. So, here’s the result!

QPicView GUI to search for images using Yahoo! Search

Pretty neat, eh? There’s actually much much more – local search, news search, video search and of course, the web search. I wonder what kind of applications will start using the Y! Search API. There’s a whole range of possibilities. As the Chinese proverb goes, ‘May you live in interesting times!’

Note:

  • The source files are here. This is just a 20 minute hack, so if you are using this, YMMV.

  • Since I used the GPLed edition of Qt, the QPicSearch source is also GPLed. However, you can reuse the idea, as you wish, in your own applications. Update: As ac commented, I found out that I can release PyQt-based apps using any GPL-compatible license. So, the code is under BSD license now.

  • I have set the number of results to just 3 in the source. Change this number to whatever you want and run ./run.sh to generate new code from the uic file and it will automatically run the application as well. This requires pyuic to be installed.