Thursday, March 08, 2007

outlook

I hate tags. They remind me of dog tags used in the war to identify casualties and inform their families. Presumptuous and Superficial. I hate them. Tags and Presumptions. Bah!!

Monday, February 26, 2007

The Golden Age

Giuseppe Tornatore, who shot to fame with the melodramatic Italian film Cinema Paradiso has compiled a collage of foreign films and this small piece was shown at the recently concluded Oscars. Fortunately I had my laptop right in front of me while watching it. Except a few that I missed out due to slow typing, a comprehensive list of the films referenced in the montage are:

Shoe Shine (Vittorio De Sica, 1946)
The Sea Inside (Alejandro Amenabar, 2004)
Rashomon (Akira Kurosawa, 1950)
La Strada (Federico Fellini, 1954)
Day for Night (Francois Truffaut, 1973)

Dersu Uzala (Akira Kurosawa, 1975)
All about my mother (Pedro Almodovar, 1999)
The official story (Luis Puenzo, 1985)
The Tin Drum (Volker Schlondorff, 1979)
No Man's Land (Danis Tanovic, 2001)
Forbidden Games(Rene Clement, 1952)

The discreet charm of the bourgeois (Luis Bunuel, 1972)
War and Peace (Sergei Bondarchuk, 1968)
Fanny and Alexander (Ingmar Bergman, 1982)
Mephisto (Istvan Szabo, 1981)
Crouching Tiger, Hidden Dragon (Ang Lee, 2002)
Mediterraneo (Gabriele Salvatores, 1991)
The Bicycle Thief (Vittorio De Sica, 1948)
8 1/2 (Federico Fellini, 1963)
Closely Watched Trains (Jiri Menzel, 1966)
Pelle, the conqueror (Bille August, 1987)
Journey of Hope (Xavier Koller, 1990)
Black Orpheus (Marcel Camus, 1959)
Walls of Malapaga (Rene Clement, 1949)
Cinema Paradiso (Giuseppe Tornatore, 1988)
Tsotsi (Gavin Hood, 2005)
Get out your handkerchief (Bertrand Blier, 1978)
Mon oncle (Jacques Tati, 1958)
Antonia's Line (Marleen Gorris, 1995)
Babette’s feast (Gabriel Axel, 1987)

Madame Rosa (Moshe Mizrahi, 1977)
Amarcord (Federico Fellini, 1973)
A man and a woman (Claude Lelouch, 1966)
Nights of Cabiria (Federico Fellini, 1957)
Kolya (Jan Sverak, 1996)
Burnt by the Sun (Nikita Mikhalkov, 1994)
Life is Beautiful (Roberto Benigni, 1997)
The Shop on Main Street (Jan Kadar & Elmar Klos, 1965)
Indochine (Regis Wargnier, 1992)

Saturday, February 24, 2007

Together in Electric Dreams

When installing straw (an RSS aggregator for Linux) through apt-get, I saw a library named libbonoboui.so scroll across the screen. A few clicks later, it turns out bonobo is a component architecture similar to COM for GNOME, only more advanced and also has bindings for Python (towards which I've grown a recent fascination). Anyway, it also reminded me of the artist Bonobo I've been listening to lately, along with Dntel, James Figurine, Lali Puna, Frou Frou and The Postal Service as a part of my foray into electronic music or more accurately indietronica. Technology used to create music. Now I think that technology is most effective when it is unobtrusive, when we reach that level of transcendence where our interface with it is seamless and subconscious. Frequently, this transparency is achieved through repetition and practice. Take for example a TV remote, cell phone, computer keyboard or a gaming joystick. After some time, our minds connect with these things obliviating their presence. It is then that we see through them into the other world. This other world can be three things - our world itself in which case technology just acts as a bridge for communication (cell phones, IM's), a manifested or generated world (gaming, music), or a hybrid of the previous two (Television). Of course, I'm ignoring the technologies that we don't interact with in daily life, but still co-exist in the background - the communication infrastructure, switches, routers, servers, software et cetera. These innovations are mostly non-interactive towards the consumer and hence do not directly affect us. What does influence us is what we interact with and this is where I think a lot of work needs to be done, both from a technological standpoint and from us. From a layman and purely end-user perspective, I guess I'd call these technological breakthroughs satisfactory when I next step into my room and don't see all the wires crisscrossing each other - the ethernet and telephone cables, wires from my desktop, modem, laptop, 5.1 speakers, headphones, ipod charger, cell-phone charger (ad infinitum). The good thing is we've laid out the foundation. Now, all we need to focus on is in removing the barriers, because I think technology fails when it starts to intrude into our lives. I've found out the basic pattern underlying most of my pet peeves - a loud ringing cell-phone, incessant honking in traffic, the (unbearable) noise from a car backing up, the clickety-clackety sounds from a mouse scroll wheel. All these are examples of either improperly designed technology or frequently just misuses of it. It is when technology intrudes that it disturbs. What needs to be understood is this: These devices are only the means, not an end in themselves (I couldn't help but draw the analogy from Kant). The end-user technology (no pun intended) only becomes useful when it appeals to the instinct and not the intellect. Personally I think my iPod shuffle is halfway there already and not attempting to sound anthropomorphic, this post is dedicated to it for giving me countless hours of pure listening pleasure amidst all the modern-day urban chaos.

Thursday, January 18, 2007

Filming Time

Auteur Theory aggrandizes the relationship between the director and the actor. By using the same actor for different films, the director attempts to form a psychological bridge between these films. A familiarity persists across all of them. But few actors can perform this feat well - carrying a character over completely different worlds without losing any perspective. Over time, I've found one actor who continues to impress me with her choice of directors and might just pull this off, and that's Naomi Watts. I mean any actor who's worked with people like David Lynch (Mullholand Dr), Alejandro Gonzalez Inarritu (21 Grams), John Curran (We don't live here anymore, The Painted Veil) and Marc Forster (Stay) has to be applauded. Her upcoming films with David Cronenberg and Michael Haneke only help to cement her role firmly amongst serious cinema. These two films along with Volver (Pedro Almodovar), Inland Empire (David Lynch) and Pan's Labyrinth (Guillermo del Toro) probably top my list of hope-to-see-soon films.

Thursday, November 23, 2006

The Philosophical Alien

Usually, my dreams follow a strict Freudian principle, but yesterday's was slightly aberrant. An old king went to meet his pet - a grotesque human-looking alien from outer space who lives in a tunnel underneath the palace. As the king bent down the tunnel and looked underneath, the alien turns his head towards him and says something like, "I always like to know more about the theory of the data than the data in the latest theory". If this sounds gibberish, then let me remind you that this was a dream (inherently meaning that nothing is supposed to make any sense) and was uttered by a philosophical alien who thinks all carbon-based life forms are nothing more than just gas....but I think I kind of understand what the alien meant....

Tuesday, October 03, 2006

Elevator Love Letter - Stars

My office glows, all night long,
It's a nuclear show, and the stars are gone,
Elevator, Elevator, Take me home....

Wednesday, September 27, 2006

An idiosyncratic protocol

Something happened recently that once again got me thinking quite deeply. I actually tend to like these "little revelations", as I call them. Now I've traditionally thought that a write() or a send() across a connected TCP socket would return an error if the error occured locally (such as permission rights, insufficient buffers etc). A write() would also be expected to report an error for a deceased connection ; isn't that what ECONNRESET and EPIPE are for? Well...yes, but not always. Let's imagine a normal scenario where one end of a TCP connection is always writing (A) and the other end always reading (B). Now suddenly, out of the blue, B freaks out and kills the connection, thereby sending a FIN to A. So far, so good. But A's TCP stack does not handle this FIN and instead forwards it onto the receive queue of A. This poor chap, having never gotten a decent education his entire life, never reads(). Thus the FIN is as good as ignored. This leads us to the interesting part, which is that B is closed and A does not even know of it. The next write call from A therefore happily succeeds and the data is sent over the wire. But B's TCP stack realizes that the connection is already closed on its end and hence sends an RST, indicating the connection no longer exists. Now, A's stack gets the RST and updates its socket error-status to indicate the connection is closed. So, all subsequent writes give us a SIGPIPE/EPIPE. Thus, the first write always goes through succesfully even though the other end is already closed, leading to some frantic nail-biting and hair-pulling....The way to solve this? A select() and a check to see if the connection is already closed before writing to it. But why does the kernel handle only RST (and update the error status) and not a FIN? Because a FIN only means that no writes will happen from that end...but any number of reads might still be done. This is the reason why shutdown(...SHUT_RD) will NOT send a FIN, but shutdown(...SHUT_WR) will issue a FIN. This is also the reason why the kernel does not handle a FIN, since its end might still want to write to it!

Sunday, September 17, 2006

Phase Shift

I just came across this as my system was rebooting:
"Shutting down anachronistic cron - Anacron."
Absolutely Brilliant.

Friday, September 01, 2006

favicon

My list of favourite applications on kubuntu:

Amarok - Rocks. Period.
Firefox - Need I say more.
apt-get - For installing updates and programs.
Katapult - Breathtaking. A stylish application-launcher.
keyTouch - For my Logitech keyboard's special keys.
VLC Player - Watching movies.
d4x - Download Manager.
k3b - CD/DVD Writer.
gimp - Minimal Image Editing.
kpdf/Adobe Reader - Pdf Viewer.
emacs - For everything else.

Monday, August 21, 2006

Elisp

The default yes-or-no-p function in Emacs is a total nightmare. However, one can alias it to y-or-n-p in order to enter y for "yes" and n for "no". But, it has its own quirk, which is not to clear the minibuffer after entering y or n. So, I wrote this tiny function to clear the minibuffer after the y/n response is typed. It's a useless & fun function to have.

(defun clear-y-or-n-p (prompt)

(interactive)
(prog1 (y-or-no-p prompt) (message nil)))

Another function, that actually does something is this:

(defun indent-buffer ()

"Indent the current buffer"
(interactive)
(indent-region (point-min) (point-max) nil))

This indents the entire buffer (or the rectangle) according to the current indentation. Very handy when editing files which have various levels of "2-spaces/4-spaces per tab" indentation(Ugh!).

Wednesday, August 09, 2006

19-19

His fingers were sweaty. Gripping the mouse as hard as real-world physics will allow him, he concentrated hard on the monitor in front of him ; eyes behind hard-rimmed glasses, searching frantically for that elusive rocket-launcher. Tension reaching a culminating point. One wrong move, one misfire, one sneeze even and it was all possibly over. The crosshair focussed intently in the centre of the screen. "The Temple Of Retribution." Retribution for what? he could'nt help but wonder. "All my life, I've been here. Walking through simulated walls, speaking with AI, completing quests. All from a dark corner in the room. Void. There are no dreams anymore. Just nightmares....of a fearsome creature from the depths of Hell." Convulsing in the darkness, looking at the scrolling lines of text in the chat rooms - One frag left. "I don't know the time anymore, or what day it is. The sweet smell of flowers, the cracking dawn of light, the melancholy of a sunset or the exhilaration of rain - Just memories now." He could see the rocket launcher ahead. The opponent was just rounding the corner of the central arena. "The fury of death. And the swiftness of rebirth. It's all just a respawn." The Tibetan Book Of The Dead. "The Red Rose. The last sight for the eyes." Mortality. "It's a scary thought. The thought of not thinking anymore." Silence. "I am". Time hit standstill. He stood rooted to the ground. Nothing mattered.Not the flipping rocket launcher hanging inches off the ground or the opponent lunging for it. Not the sight of a rocket hurtling at breakneck speed towards him, creating a tiny sonic boom behind it. Not the sneer of an invisible face. Microseconds later, the screen went black. The mouse was left dangling. The room was empty. A life was born. A new one. It was tabula rasa all over again.

Friday, July 28, 2006

A FoRtune Cookie

This brought a smile to my face.
"WoMan _does not_ replace `man', although it does use a number of the facilities implemented in the Emacs `man' library. WoMan and man can happily co-exist, which is very useful for comparison and debugging purposes. The only way in which WoMan affects `man' is that it adds a timer to indicate how long `man' has taken to format a man page."
(From the info page for WoMan - Emacs' manual page browser).

Tuesday, July 04, 2006

The Pill

It was raining outside.
I could see it through the curtains.
Thunderstorms bellowed in the distance.
We just sat looking at each other.
I could see he was reading my thoughts.
I was no longer uncomfortable.
I rested my arms against the velvet of the armchair.
I closed my eyes.
I could hear him speak for a long time.
A dark, monotonic voice.
I could feel it.
Something crawling up on my skin.
An experience that could be felt.
He stopped talking.
I opened my eyes.
He looked at me.
He outstretched his arms and opened up his palms.
There were two pills - one red and the other blue.
They were shining against the dim light in the room.
He said, "It does not end here. It begins. The blue pill returns you to the drab life you've been leading till now. The red pill shows you how deep the rabbit-hole really goes. It's your choice."
I looked at him.
I looked at the rain outside.
I chose the yellow pill.

Monday, July 03, 2006

"Long" Live The King

I was recently involved in a framework that had to provide consistent behavior over both 32 and 64 bit systems ; which was when I came across the wierd standards followed by some compilers, when it comes to data-type sizes, more specifically int, long and a pointer (abbreviated as ILP). Now, both gcc (Linux) and the VC++ compiler(Windows) use ILP32 when compiling for 32-bit systems. This means, that an int, a long and a pointer are all 32-bits in length. To support a 64-bit data type, the type long long has been added, in later compilers. But, on a 64-bit machine, things start to get a little hazy. There exists 3(yes, three!!!) standard conventions :
ILP64 (Int, Long and Pointer are 64-bits)
LP64 (An int is still 32-bits, but a long and pointer are 64-bits)
LLP64 (Both an int and a long are 32-bits, and only pointers are 64-bits).
Faced with these choices, one would think the ILP64 to be a fairly obvious choice. I mean, what's the use of a 64-bit number-crunching machine if one can't do native 64-bit arithmetic on it? But, Linux chose LP64, while Windows embraced the LLP64 standard.
One of the reasons against ILP64 from both these systems was that an int was(and still is) C's most popular data-type and extending it to 64-bits would likely waste more space (4 bytes extra), than it does now. Face it, the average programmer tends to use an int to return even a single bit such as 1 or 0. So, a programmer should be forced(by the compiler) to use 64-bits only when it's absolutely necessary. But, the other argument against ILP64 is an interesting one. Let's consider the types int and long on a 32-bit system. Both are 32-bits in length and are indistinguishable from each other. But why? Because, in the age of 16-bit systems, an int was 16-bits in length, but a long was 32-bits. As we moved onto 32-bit systems, an int became 32-bits, but a long remained the same. This is where we lost it. Should'nt long be 64-bits in length? I don't know why this was done(insufficent hardware support could've been the reason), but it was this mistake that made both int and long equal in size, which made programmers careless and start intermixing them. So, the best thing to fix it, is by making int remain at 32-bits, while extending the long to 64, and this was the approach Linux took. But, Windows faced with a bigger issue, that of "not breaking" existing code, which assumed an int and a long to be the same size. So, they went the way of LLP64, with an int and a long remaining at 32 bits, and the pointer extended to 64-bits. But, there's a subtle loophole here. The size of a long long variable in a 64-bit system, is not, as you would expect it to be, 128-bits, but it remains at 64. So, what happens when moving from a 64-bit to a 128-bit system? The same problems, that we struggled to avoid resurface. The legacy lives on.

Thursday, May 25, 2006

Motion Blur

The sheer diversity and ingenuity of today's programs never cease to amaze me. A new wave of programs that take advantage of the motion sensors in laptops have cropped up, and it just got really wierd and "interesting". MacBook Pros and Thinkpads have motion sensors built in to take care of impact-scenarios. "Nominally, it's there to protect the internal hard drive. The basic idea is if the accelerometer suddenly notices that the gravitational pull of earth is no longer present, the most likely explanation is that the laptop, sensor and all, is currently accelerating at 9.81 m/s² towards the earth. In that case, it will (wisely) try to turn the hard drive off in preparation for impact." So, now we have programs that let us switch between virtual desktops at a tap on the screen, squeal when the laptop is lifted of a table(to protect against thefts) and make light-saber noises as it's hurled across(ala Star Wars). Brace yourself, 'cause the next-gen of programs might just arrive like a fleet of warships hurtling through space. Oh, that reminds me, gotta grab my towel today. "Happy Towel Day" everyone!

Monday, May 15, 2006

Ruubeek's Cube

I broke my last Rubik's cube some months back. I'd just completed learning to solve it by that time, when the cube came apart in my hands. I tried putting it back together, but one of the center pieces was broken. The assembly of the cube is itself quite interesting. All the parts sit perfectly on top and beside each other, with a minimal scaffolding at the center ; and 'course there's more than one way to assemble it, meaning you can basically create a unsolvable cube (Now, there's a trick to play on someone). Anyway, I got my new cube a few days back, thanks to a friend from the US. It looks very rigid, just like the last one, and initially takes some time to loosen it ; but after that it's smooth sailing all the way, that is of course, if you know how to solve it. There are loads of tutorials on the web to get anyone started on this. But initially, the best way would be to just mess around with it a bit, try getting a particular piece to a particular place and such; get used to moving stuff in three dimensions as opposed to 2-D jigsaw puzzles.
The most basic approach to solve it uses layering. The 3x3 cube is split upto into 3 horizontal layers, and one goes about solving a layer at a time. The first two layers are pretty easy and basic intuitiveness is sufficient to complete them. The last layer is the most difficult of them all, partly because one has very little room to work with without disturbing the completed layers. If you're really good and patient at it, you might figure it out by yourself, or if you're like me, then search for the easiest algorithm, and solve it that-a-way. Either way, after some time, the modus operandi will gradually evolve right into the cuber's hands and a feeling of accomplishment is inevitable. This is a really good tutorial to get started with, and frankly I don't want to get past it. I'm just a casual end-user of the cube, not a geek trying to speed-cube my way into 16 seconds. Of course, if one is really good at it, then the 4x4 Rubik's Revenge is definitely the worthy adversary.

Tuesday, May 02, 2006

A Scanner Darkly

My last two novels, having similar dystopian themes, a political regime taking control of a war-waging humanity and the idea of a bleak future ( V For Vendetta and A Brave New World), I had pretty much decided to give myself a break from sci-fi. But, as so often happens with me, nothing ever goes according to plan. I fell, head over feet, for the trailer of A Scanner Darkly, the first film of its kind - purely cel-shaded, and gorgeous. The protagonist is voiced by Keanu Reeves, and there was something in it that just grasped me by the shoulders and shook me violently. I just had to read the book, by Philip K. Dick - a renowned sci-fi writer of his time. Truth be told, it was nothing like I imagined from a sci-fi author. The story weaves through the impact of drugs on our oh-so-impressionable minds, taking control of our brain and reducing us to pulp. I've begun to cherish this kind of writing, where there's not too much of emphasis placed on the technology ; but rather its effect on us and our moral values and principles. The shock with which we realize that every moment of our lives is hopelessly dependent on technology ; and our inability to accept that fact. I just hope the movie turns out to be as good as the book.

Thursday, April 20, 2006

So Sayeth, Wanda The Fish

Big Fish, directed by Tim Burton is one of the movies I kept missing regularly everytime it's shown on TV, along with Donnie Darko and Requiem for a Dream. I finally caught it yesterday on HBO, at a very odd hour of 1:00 AM. The movie was not something I expected, throwing me a bit off-guard ; and definitely not the sterotypical Burton. A fantasy of events woven in flashbacks to a skeptical son, it definitely has fantastic visuals. What is confusing is the fact whether the father is actually telling the truth or not ; because the stories he narrates are bizarre and impossible, in the world we live in ; but yet, there's some element of truth in it, as the son discovers that all characters from the story are not made-up manequins, but they actually exist ; albeit different from the way narrated. People gain immortality, through the stories told about them, sometimes by them, that live after they're long gone. A fine cast of Danny DeVito, Ewan McGregor, Jessica Lange and Albert Finney makes the film a memorable experience. Something that stays on your mind for quite sometime....

Friday, April 14, 2006

Visions Of Paradise

Oblivion seems to have quite created a rage in the gaming industry. An RPG that's raised quite a few eyebrows regarding its success and made gamers and critics alike, all over the world, cry in joy and heap accolades on it certainly doesn't happen quite so often in this world ; this geeky world of pumped up gaming rigs, artistic case mods, liquid cooling, high-end graphics cards, dual-core processors, ergonomic gaming keyboards and mice for the hunched-up gamer drooling over 21'' LCD screens, pumpin' metal into every friggin' marine, or blowing to smithereens every alien scum that dares to show its ugly face, or precariously managing a dwindling economy while warding off another enemy attack on the base, or getting lost in eerie caves and foggy tunnels trying to find a red fire-breathing dragon that's guarding an ancient treasure. If memory serves me right, the last such phenomenon is the now oh-so-popular World Of Warcraft. It might very well be the product that single-handedly boosted this industry the last year, and is still going strong. In fact, after recent reports of addicted gamers,virtual threats and ransoms, and viruses unleashed onto the virtual world killing virtual characters, it's gotten a bit frightening, to say the least. But these are the artificial worlds, entire universes created by games that we tend to lose ourselves in, staying up late trying to ward off that evil spell casted by a level 30 mage. Oblivion does this and more, it seems. I had'nt heard of this game, quite surprisingly (probably because I was not frequenting Gamespot or Gamespy or Kotaku or Pixel Kill or countless other sites out there), until a friend asked me if I'd read the review. I said no, but made a mental note to read it later. Needless to say, I was swept, swept hard by the current, swaying left and right before steadying myself and realising it's never, not even in my wildest dreams gonna run on my system. Still running a paltry processor with a single core and a borrowed withered-by-age graphics card, I solemnly retired to my usual gawking-over-every-new-game-while-
cursing-my-inability-and-staunch-stubborness-to-upgrade routine. I mentally ticked this one off too. Oblivion. Like the lone survivor of a ship-wreck who's lost the complete meaning of time and ticks off every day against the wall with a sharpened twig, I etched the name deep into my heart. One more game to play. My list is all the while getting longer, with each passing month, starting off from Painkiller:Battle out of Hell to Doom III, F.E.A.R, Quake IV, Call Of Duty 2, GTA:San Andreas, Serious Sam 2, LOTR: Battle for Middle Earth 2, Black And White 2, ad infinitum. What's one more to the list, eh? *Sigh*. Getting restless - but just a tad bit at having missed out on all the fun of my first love with computers. And with the release of Apple's Intel-based Mac systems and the beta Boot-Camp that dual-boots with Windows, I have all the more reason to vigorously scratch my head and ponder ; weighing in the positives and negatives of either upgrading my system now(which has complications I don't want to delve in right now), or wait for a sufficiently stable Intel Dual-Core Mac with a reliable Boot-Camp at an affordable price (yeah right!), or just give up on all this and settle for one of my two latest crushes, a DSLR or an electric guitar. Oh, the travails of free will :)

Friday, April 07, 2006

The Musical Harp

Pandora is a music lover's paradise. An eternity of fresh and eclectic music from authors all around the world, with a penchant for discovery and excitement like I've never experienced before. And I mean this from the humming C Major of my musical veins. Powered by the Music Genome Project and flashing a simple flash-based interface, it grips you right from the moment you step through the humming doors. The concept is ridiculously intuitive, even for a childish Steve Vai ("The Audience is listening"). I'm a long-time self proclaimed addict of Pandora. It made me discover some amazing artists. At the time I started using this service, I was more into a new-age, trance kind of music. I was listening to a lot of Enya, Chicane, Vangelis and Dido then. So, having set up my station to imitate music of this vague genre, I discovered some fabulous artists in Imogen Heap(Frou Frou), Bent, Pentatonik and Adrian Belew. After that, I had some recordings played to the tunes of 80's pop and Country. A few artists like The Decemberists, David Gray and Ph 7 captured my attention. Music, as an art form, uplifts the soul, brings on a sense of detachment from an inconsequentiality and propels the innate desire to be self-satisfied. A feeling of completeness, a full circle - Is that not what Life is all about? The Creation always outlives the creator. The creator is nothing more than an entity, a body form constrained by the physics of the universe. But not the creation. It is limitless. Not bounded by any laws or rules. It touches the heart, in a way nothing else can. That's all that matters in the end, I guess. A feeling of holding hands with Nature. An embrace with the skies. A tryst with the sea.
Every breath we take,
Every move we make,
Every bond we break,
Every step we take.........

If you haven't checked out Pandora, please do. Did I mention it's free?