Archives for: January 2006

01/29/06

Permalink 08:46:48 pm, Categories: Work, 29 words   English (US)

Ski trip

This week I'm going on a company ski trip to Squaw Valley. I signed up for the beginner skiing group, and hopefully I will not sustain too much damage.

Permalink 08:41:58 pm, Categories: Home, 226 words   English (US)

No more speaker wires please

I've always been an audiophile of sorts, and always want my home theatre sound to be perfect. I currently have a Panasonic home theatre in a box system. Since I moved to Mountain View, CA, I haven't bothered to connect the rear speakers. The main reason is I cannot find a good way to hide speaker wires other than tearing up carpet. As I spent an hour trying to figure out where I could possibly hide the wires, I said screw it I don't really need rear speakers anyway. I'd like to have them, but it's just not worth the trouble.

My next big investment will be replacing this Panasonic with Bose's 3-2-1 home theatre system. This uses special 'technology' to simulate surround sound. I know it won't be as great as a full surround system, but I've heard Bose systems, and they are truly amazing in other ways. My temporary apartment happened to have a seemingly innocuous Bose Wave Radio system. When I listened to it, I literally could not believe how good it sounded. The bass was so good that it sounded like a subwoofer was somewhere in the room, but it was all coming from that small radio. The clarity and 'presence' of the music is just amazing.

I could also get the newer wireless surround speaker systems, which seem pretty cool. Still undecided.

Permalink 08:21:26 pm, Categories: Fun, 15 words   English (US)

Pitching Mother

Here's a pretty funny movie on what it must be like to make independent films.

Permalink 03:03:52 am, Categories: Movies, 365 words   English (US)

Match Point

I remember reading Dante's Inferno a long time ago, which seemed essentially to be a methodical descension into hell. That's what this movie felt like, and I mean that in a good way. It conveyed the impending train wreck feeling intensely.

I've always liked Woody Allen films. I don't know, his comedy just seems very truthful. This movie is a completely different Allen, and I thought it was very poetic, like Dante's Divine Comedy. Oh and Scarlett Johansen is beautiful in it.

The movie's moral question is whether everything that happens in life is pure luck. At the beginning of the film, a tennis ball hits the top of a net and shoots straight up. If it falls on the other side of the net, you win. If it falls on your side, you lose. There is an amazing scene towards the end of the movie that revisits this motif, and it's just beautifully done (I won't spoil it here). It's what distinguishes a great director from an average one.

The movie spends 2 hours dealing with a relationship and an affair. It's interesting, but it's just a means to convey a point. The point that our mere existence is based on luck. Those that are religious will probably hate this movie. It goes against all morals, justice, and what should happen to a 'bad guy' in a righteous world. But honestly, leaving the theatre I thought to myself, these people actually exist out there. There are people that get away with horrendous acts, and there are those that get caught for trivial acts. What price does the criminal pay when he gets away with his crime? What actually allowed him to get away with it? Was it pure luck? Are some people luckier than others, and why?

It could be said that such a criminal lives rife with guilt. How many times can the ball fall on the other side of the net?

The ending reminded me of The Godfather II, most importantly the last scene of Corleone after he has just killed his brother.

In short I thought the movie was excellent if you like movies that give you more deep questions than answers.

01/23/06

Permalink 01:50:33 am, Categories: Work, 113 words   English (US)

Week 1

Well I've just finished my first week at my new job. Though it wouldn't be wise of me to say much (and you may notice the new disclaimer on my site), I will say that I have a very challenging and fun time ahead of me.

I rode my bike to work 2 days of last week, due mostly to rain. I quickly realized that I needed gloves because by the time I got to the office my fingers were about to fall off. It's damn cold in the morning. I also found out it is illegal in CA to ride a bike at night without a light. Note to self to get one :).

01/20/06

Permalink 10:36:28 am, Categories: Television, 15 words   English (US)

Google on ABC World News

It appears ABC World News will be broadcasting from Google tonight. Check your local listings.

01/16/06

Permalink 01:10:22 pm, Categories: Fun, 4 words   English (US)

Russian street acrobatics

Some pretty amazing stunts.

01/13/06

Permalink 01:31:17 am, Categories: Fun, 15 words   English (US)

Credit card signatures

cc

Ever wonder just how well stores check credit card signatures? Check out this amusing experiment.

01/12/06

Permalink 03:45:18 pm, Categories: Car, 104 words   English (US)

License to drive

terminator

The honorable Schwarzenegger has granted me my driver's license. I missed 3 questions on the written test (6 maximum). I didn't have to take a driving test thank God. You actually have to study a bit. I remember one question that threw me off. It asked what was the speed limit in a business district if there is no posted limit. I had remembered 25 was for residential, but for some reason thought business was 35. It is actually 25 too.

They punched a hole in my FL driver's license and it is no longer valid :(. I have to get my car smog-checked before I can get my registration.

Permalink 12:57:26 am, Categories: Fun, 8 words   English (US)

Origin of ctrl-alt-del

Very funny, especially the look on Bill's face.

Permalink 12:35:52 am, Categories: Programming, 317 words   English (US)

Awstats and busy websites

I'm not sure why I ever liked Perl. For me, writing Perl after learning Python is like going to a PC after a Mac. It seems like you are going back in time, to caveman days.

Awstats is a fairly popular web log analysis tool. Unfortunately, when working with very large sites, on the order of 1.5gigs of logs a day, there are some shortcomings. The default CGI method reads its database every time it is called, which takes minutes with a large database. So it's best to create static reports.

Most of the time when a user goes to the main report page, that's all he will do. I'd like this initial report to load up fast, but I didn't want the default awstats static pages which doesn't have any form to run different reports. I wanted the speed benefit of static pages with the option to run specific reports from the CGI if needed. Seemed like a simple task I could do by modifying awstats.

I setup a script to create the static pages after importing a day's worth of data, then modified awstats to show the form submission info and dump out the static page (if it exists) instead of loading the whole database. It would only load the database if some other GET or POST options were sent to the CGI, which is a request for a tailored report. No more killing the CPU when someone hits the reports page.

It took awhile to get the modifications right. I honestly think that awstats is horrible Perl code. It's gotta be the ugliest thing I've ever seen. It's one of the many 'functional but ugly' Perl scripts. It has made me loathe Perl even more.

Update: Ok I was a little emotional when I wrote this. Perl is not that bad and I have seen some very elegant Perl code (Radiator comes to mind).

01/10/06

Permalink 02:08:19 am, Categories: Python, 46 words   English (US)

The anti-web framework

I came across web.py, quite possibly the simplest web framework ever. There is something very appealing to me about it. It provides just the basics and gives you the freedom to handle things how you wish. That's different from the other major Python web frameworks.

01/09/06

Permalink 11:17:59 pm, Categories: Work, Health, 129 words   English (US)

The bike

I purchased a bike recently. It's a pretty nice 'hybrid', meant for road and trail biking. The gear shifting is done by rotating the handles, which I thought was cool and easy to use.

This morning I timed how long it would take me to get to work: about 20 minutes. It was sunny and 60 degrees F so I didn't sweat at all even with a sweater and t-shirt. Going there is alot downhill, but coming back is a bit tougher. I took a trail that is right next to my apartment. As long as the weather is ok, I think this will be some good exercise.

Riding on roads is kinda scary, and I just need to get comfortable riding close to cars :). I'll definitely be wearing a helmet.

Permalink 10:42:06 pm, Categories: Website, 191 words   English (US)

I reddit

I think I first heard about Reddit from a Paul Graham article mentioning to leave comments 'via Reddit'. I've been using it ever since. I think it's one of the coolest sites out there, plus it is written in Python :).

This interview describes what the site does. I couldn't agree more with this comment:

As a couple of information junkies, Steve and I found ourselves with too many rss feeds and too many tabbed windows open every morning -- we wanted a front page we could go to every morning that was made for us. Del.icio.us/popular was definitely an inspiration, because it showed the potential of aggregation (I think I'm supposed to be calling this the Wisdom of Crowds), but we were after links that were more ephemeral than the reference material one usually bookmarks on del.icio.us.

You can think of it as first aggregating the most highly-rated links for the day, and second being able to learn what you like to read and tailoring the results for you. I've found some great material just by watching the top-rated links, which they provide an RSS feed for.

Permalink 10:31:11 pm, Categories: Fun, 19 words   English (US)

Funny videos

Some funny videos I recently saw on video.google.com.

01/07/06

Permalink 11:45:31 pm, Categories: Health, 368 words   English (US)

I feel the pounds coming already

Well I got my car this morning and did some unpacking today. I had to return my rental car to the San Jose airport, so I decided to try the public transportation to get back. There is a Caltrain and VTA station within a block from my apartment. So I went and studied some of the route maps and fares. I ended up taking the Caltrain from the airport to Mountain View. I also realized I could've used VTA as well, but I believe there are more stops. Caltrain is a double decker train that's actually very nice. They didn't check my ticket, and it seems that they do random checks only. That seems to put alot of trust in the commuters.

Anyway, I got back to my leased apartment and realized I left the garage opener for my temporary apartment in the rental car :(. I drove back there and they took the car for service and told me to come back tomorrow. I am not really making efficient use of public transportation am I.

One thing I have noticed here in the bay area is that the whole transportation system seems worlds ahead of anything I've ever seen. Even the stop lights, if they are red and it is not a busy intersection, they change immediately when I pull up, and immediately change to yellow after I leave! Also they have stoplights right at the entrance to the freeway which are on during high traffic. The roads are easy to understand, and I've gone to many destinations without once getting lost. I just get the impression that the department of transportation here is alot smarter than the one in Florida :).

So this evening I wanted to grab some healthy food at a greek deli I found, but alas they were closed. Then I noticed this thing called Carl's Jr. next to it. I never saw this in FL, so I figured what the hell. I had a "6 Dollar Burger" and fries which was probably the best fast food burger I've ever eaten. I just checked their nutrition info and the burger alone is 960 calories! shudder... I already feel guilty. I can't do this anymore, must... eat... healthy.

01/06/06

Permalink 09:03:38 pm, Categories: Home, 521 words   English (US)

Busy day

I did alot of unpacking today. I think I have more packing material than actual stuff. Slowly but surely my apartment is becoming a home. What sucked is they were doing some plumbing in my building and the water was off all day.

I have a plasma TV that was crated before being moved. A 3rd party had to come out to open the crate, and I also had Comcast coming out the same day. I was worried that I wouldn't have the TV ready before Comcast got here. Luckily the 'uncraters' came out to open the crate early. Then Comcast came out to hook up my cable TV and internet. The TV worked great, and I was given a cable modem self-install kit. After drueling over Discovery HD a bit, I ventured to get my internet access running.

Now I have a wireless router, but I couldn't hook that up to the modem because some software is required to run to setup the cable modem. I hate installing this crap on my system, so I tried just connecting my laptop to the modem and tried to browse. It redirected to a Comcast page requesting me to download the installation software. They had a Mac version, and it was like 64megs. What in the world is included in that setup?

After downloading the HQX file and running it, it starts up Internet Explorer for Mac and begins a setup process. My guess is the download included IE, because the setup was just a sequence of web pages. After putting in my account number it got to a screen and just hung. I killed IE and restarted the installation, which seemed to continue where it left off. Finally it told me to reboot. Hmm, I haven't rebooted my Mac since, well since I don't know when. This brought me horror flashbacks of Windows, but I complied.

The system comes up and I notice I have a different IP. However, I cannot access anything. DNS seems to work, but port 80 connections to anywhere fail. I tried running the setup again, but it just crashes with 'file not found'. Yay. Now I was about to call them and then thought to myself, what would they probably ask me to do? I remembered my past experiences with Adelphia, "Power down the modem...". Ok, I'll try power cycling the modem. Voila! It works.

Now I'm not going to work with my laptop connected to the modem, I need to setup my wireless router. Hm, they probably know my MAC address now and will prevent any other MAC from connecting. I don't know this for sure, but it's a safe assumption. So I went to my router setup and configured the MAC address cloning feature to be the same MAC as my Mac :). Plugged the router into the modem, and voila, I instantly have wireless.

So in general it was a pretty good day. I'm even getting my car delivered tomorrow! I'm really impressed with how smoothly this whole move is going. Everything is being done earlier than I expected and things just seem to work out.

01/05/06

Permalink 07:04:26 pm, Categories: Home, 24 words   English (US)

Pictures of my homes

Here is the really beautiful temporary housing I'm staying at.

Here is the apartment I'm moving into. It's also pretty nice for the price.

Permalink 02:44:59 pm, Categories: Home, 293 words   English (US)

Beware of Ohare

Well for the past few days I've been doing my move from FL to CA. I flew through Chicago Ohare airport and there was really bad weather there. We had to stay on the runway for 3 hours in Miami before taking off. It was also the most turbulent flight I have ever been through. People were almost panicking, and of course I was praying the plane didn't crash :). Luckily my connecting flight was also delayed, but I ended up running to catch the flight. All I had was a piece of toast for breakfast and ended up starving once I got to CA. Note to myself: never fly through Chicago again.

Everything else is going very smoothly. I've been staying at temporary housing in Santa Clara for the past few days to wait for my stuff to arrive. The temporary apartment is absolutely beautiful. The movers arrived with my stuff this morning. It took only 8 days to get from FL to CA! Incredible, I was expecting 3 weeks. I don't have a bed and will pick one up from a friend this weekend. My car is scheduled to arrive sometime next week.

Meanwhile I'm getting used to the area, and I'll also experiment with the public transportation. I need to take a written test for my CA driver's license. One thing also I found out is my Bank of America accounts can't be used at the Bank of America here. I can only do stuff online. So I basically need to open up local accounts at the BoA here. I found that quite strange. You would think that Bank of America is Bank of America everywhere, but that's not the case for CA at least.

I'll put up some pictures of my apartment soon.

01/03/06

Permalink 07:50:20 pm, Categories: Television, 8 words   English (US)

The Chronic of Narnia

Hah, can't believe I didn't catch this video.

01/01/06

Permalink 10:06:17 pm, Categories: Television, 28 words   English (US)

This Spartan Life

Tonight IFC played an episode of This Spartan Life which is basically a talk show made in the Halo game. Hehe the Solid Gold Elite Dancers are interesting.

Permalink 08:54:52 pm, Categories: Python, 201 words   English (US)

Gotta love EBNF

A friend of mine was recently asked in an interview to code a solution to check if a string was a slurpy. Interesting little problem, and I think a pretty good question.

I've been reading a pretty good book on Python text processing. There is a section on writing parsers, and the author talks about the simpleparse module that can take a grammar in EBNF format. The recursive grammar that defines a slurpy seems like it would be ideal for EBNF. I was bored so thought I would try, and found it pretty simple. Here is the code:

from simpleparse.parser import Parser

grammar = r"""
slump  := ('D' / 'E'), 'F'+, (slump / 'G')
slimp  := 'A', ('H' / ('B', slimp, 'C') / (slump, 'C'))
slurpy := slimp, slump
"""
parser = Parser(grammar)
testSlurpy = [ 'AHDFG', 'ADFGCDFFFFFG', 
   'ABAEFGCCDFEFFFFFG' ]

for testData in testSlurpy:
   success, children, nextcharacter = parser.parse(testData, 
      production="slurpy")

And there you have it. It's very natural to describe this in EBNF grammar. Of course the interviewer was probably looking for a real solution :). But alas I am a sysadmin and I always look for the lazy way out. There is less likelihood for me to make an error by using something like EBNF, and it's easier to understand.

Permalink 08:00:34 pm, Categories: Religion, 52 words   English (US)

Mark O'Brien

Disability causes me to believe more strongly in a duality between body and spirit, ...cause if I'm a soul, I'm just as good as you. And if I'm a body, then I'm up shit creek, ain't I?

I read a really touching article by someone who had polio most of his life.

Viraj's Weblog

Donate to keep this site going!

Amount USD $

January 2006
Mon Tue Wed Thu Fri Sat Sun
<<  <   >  >>
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31          

Search

Categories


Misc

Syndicate this blog XML

What is RSS?

powered by
b2evolution