15
Come Spring…
I have been doing one too many posts about poetry of late. But with Spring tip toeing in with all its splendor, can you blame me? Spring has been an inspiration for poets from nearly all languages. Who hasn’t heard of “If Winter comes, can Spring be far behind?” (P.B. Shelley). Urdu poetry too is rich with ideas inspired by Spring. However, its treatment of the topic is very peculiar, but interesting nevertheless.
Urdu poetry is very metaphoric. Nightingale (bulbul) represents a lover while the beloved takes form of a flower (gul). The heart (dil) is seat of tenderness and impatience while the liver (jigar) stands for pain and perseverance. Shirt collar ( garebaan ) represents ego which is always assumed to be torn in the case of lovers (aashiq ka chaak garebaan). The lover and beloved (refered to as aashiq and mehboob respectively) have a very special place in Urdu poetry. Restricting it to the conventional boy-meets-girl type of love would be unfair. Infact, anyone who seeks a purpose with heart and soul is a true blue aashiq.
Now Spring is a very significant occasion for our Urdu aashiqs (the actual plural is usshaaq) as per poetry. While the world celebrates the opulence of color and fragrance as the flora turns into its full bloom, the aashiq grows melancholic. The beauty of Spring brings to mind the lost mehboob. As flowers of bright red color blossom, the wounds in aashiq’s heart start to bleed. The masses join in Spring celebrations, but the aashiq’s pain augments as he laments the loss of his mehboob.
The following is a collection of verses (ashaar) that convey the same meaning. I have made a modest attempt to translate it into English. Translation of poetry from its original language is the same as looking at the shadow of fire or the reflection of moon in water. Nevertheless, it is better than nothing.
Finally, how can we skip Faiz’s classic poem “Bahaar aai”. Have a happy spring!
11
Faiz meets Meer
In my second semester of BS, a teacher recited a ‘misra’ of Faiz. In regular Urdu poetry, a poem consists of couplets, and each line of a couplet is called ‘misra’. The misra in question was “Hum aa gaye to garmi-e-bazaar dekhna”. The situation that led the teacher in question, Mr. Alvi, to recite poetry impromptu is very interesting. A group of students in our class never took Mr. Alvi’s class, much to his infuriation. One lucky day, the abovementioned group entered the class when Mr. Alvi was halfway through his lecture. A sarcastic smile played on his lips when he noticed the ‘notorious’ students joining his class. He just read the above misra and continued his lecture. Literally translated, it means “The bazaar lights up the moment I enter”.
The lecture had been and gone, but I couldn’t get the misra out of my head. The next day, I asked Mr. Alvi to share the other misra with me. To my utter disappointment, he neither remembered the poet of the poem, nor the other misra. When I went home, I googled it up but to no avail. On a whim, I sifted through the contents of “Kuliyaat-e-Faiz” (Complete works of Faiz) from my personal library. After an hour or so, I found it. Sheer joy!
Fast forward 6 years. Today I was reading Meer Taqi Meer’s poetry and I came across a poem that instantly reminded me of Faiz’s “garmi-e-bazaar” poem. This time, I was fortunate enough to find the poem online. There is a very interesting link between these two poems. I can’t believe it’s a coincidence that the poems match in ‘bahr’, ‘qafia’ and ‘radeef’ (different aspects of poetic metre). Clearly, Faiz got his inspiration from Meer. I can imagine how it feels breaking the Da Vinci code. Granted, we can scale it down a bit in my case
. Here are the poems I’ve been talking about.
9
Birds and Fireflies
Basking in the sun on a lazy winter afternoon can do strange things. For one, it can wake up timid dreams. Like birds, they flutter their wings, and soar up in the blue skies. It was on a winter afternoon of the kind I just described that my friend, Mustafa, decided to visit me for a cup of tea. Mustafa was my roommate during boarding school days, and therefore, a very dear friend. They say wine gets better with time. I suppose that holds for friendship too.
Mustafa arrived at 4 pm, as promised. We exhausted topics such as current affairs, politics, health, kids, not-to-mention, a dozen ‘shami kebabs’, chicken patties and a cake. An hour later, we had our second round of tea. There was nothing more to say. We just sat there in comfortable silence, sipping away from our tea cups. Suddenly, Mustafa brought up the subject of dreams.
Mustafa: Remember, how we used to chase after fireflies when we were kids. I feel that we are still doing the same.
Me: Wow, you seem to be in a really poignant mood.
Mustafa: Right, I am in my philosopher shoes now. But try to think about it. We have spent half our lives and intend to spend the remaining trying to achieve something that seems to be bright and luminous like those fireflies. We catch it and tuck it under our pillows, only to find out the next morning that it was nothing but an ugly insect. Each morning, we resolve to find the real glow, yet it’s the ugly insect that sleeps under our pillows every single night. This barren pursuit stretches over our entire lives till we die with the image of the luminous firefly engraved in our lifeless eyes. Tell me very honestly, why are you a banker?
Me: Because the financial incentives are excellent. I can afford to have a good house, a car and good education for my kids.
Mustafa: I know about all these things. What I want to ask is: What is it that being a banker does for YOU that any other job cannot.
Me: Well, I am good with numbers.
Mustafa: And I am very good at dishwashing. Does this mean I should be a dishwasher at a restaurant?
Me: It’s a balance between what you are good at and how much you get paid for offering your expertise.
Mustafa: Being good at something does not imply that you like it too. My wife thinks I am good at dishwashing and I agree. Yet, this isn’t something I dream of doing day in day out. I am also good at painting. If given a particularly lucrative opportunity, I will happily give up my career in engineering to become a full time painter. But the truth is that I am an engineer, and not a painter. So how much does it take to swindle someone from pursuing their dreams and make them do what they are good at ?
Me: But that’s the irony of creativity, isn’t it? Talk about painters, poets, writers, musicians; if lucky stars are shining upon them, they might be catapulted to heights of fame, but that’s a rare case. Majority of them reverberate in empty air, like an unsung melody.
Mustafa: I don’t think it has anything to do with creativity. Being creative in Science pays really well. The Microsofts and Googles of the world are hunting for people with innovative ideas. It’s about liquidity. Scientific creativity has high liquidity, artistic creativity—not so much. The loss ratio is much, much higher in the latter case.
Me: As per the books I have read, liquidity is ‘the ability of an asset to be converted into cash quickly and without any price discount’. How do you tie this into your argument?
Mustafa: It’s very straightforward. Creativity is gauged by its profitability—its potential to be commercialized. An employee at a software house gets more or at least competitive salary as a PhD in Philosophy.
Me: You cannot deny the importance of money. You don’t want to paint living in a ghetto with children crying for food.
Mustafa: That’s an excessively grim picture. Try to improve it a bit.
Me: Well, how about being a painter and residing in a not-so-posh area, driving a Suzuki instead of your Accord and your children studying in a Government/Public school.
Mustafa: Interesting, but my answer is no. I want to keep all the ‘good’ things I have as we speak, therefore I intend to keep my current job. My employers have made a good investment. They have quoted an excellent price for my services – and my dreams!
It was getting late and cold. Mustafa took a last sip of his now cold tea and drove away. After closing the gate after him, I stood in the lawn for a few moments. Dusk was setting in and the horizon was painted in several hues; pink, orange, yellow, red and purple. The sky was blotted with flocks of birds returning to their nests after a day of toil and sweat. Out of the blue, my eyes caught sight of a lonely firefly in the hedge. In a single swift movement, I got hold of the insect. The little thing squirmed in my fingers as I inspected its shiny tail. After a few fleeting moments, I let go of it. My mind had caught glimpse of true light, and there was no way I could be fooled by a deceptive insect—at least that particular night.
5
Playing with ALOT of network traffic
I was involved in a project that required analyzing and mining information of interest from large network traces (spanning TB’s of data). This was my first time with network data of this magnitude so i learnt quite a few things by hit and trial. I decided to do a quick post to summarize my experience and ‘humble’ insights!
1. Whenever you get a dataset, don’t take the data-provider’s word for it. Do the following:
a): Find out what are the time settings on the machine on which the capture was taken.
Reason: All capture files actually maintain timestamps in terms of the standard epoch (The time in seconds since epoch (Jan 1, 1970 00:00:00)). However, any tool you use to view the dump file will change this time according to the local time settings on your machine. Most tools, including Wireshark even change the sequence of packets so don’t believe what you see in Wireshark and use your own script to verify timestamps.
b): Calculate the duration of capture by subtracting start timestamp from the end timestamp. If the duration makes sense, you are good to go, otherwise you’ll have to write a script to print interarrival times between packets and mark the ones in which this time is unacceptably large. You might want to investigate why.
c): Run a script to calculate incomplete handshakes. It will give you an idea what kind of data you have at hand.
d): Run a script to calculate data loss based on packet Seq and Ack numbers.
2. Split the data into 1 GB files. Can’t emphasize this enough. Barring the initial overhead involved in splitting the file (took about 10 hours to split 238 GB), it saves so much time and effort and makes debugging alot easier. If a script halts, you know where to restart or where to look for problem. Also, many so called state of the art tools tend to crash when presented with a large chunk of data.
3. You *may* want to further split data based on ibnound and outb ound traffic. Alternately, instead of physically seperating inbound and outbound traffic, you can implement filters in your script (i prefer this
.
4. Make provision for statefulness in all your scripts. Print out useful information in log files so that even if the script crashes, you can pinpoint the problem.
5. Always test your script on a small chunk of data before unleashing it on the data giant.
6. Python+Scapy is a bad bad choice for parsing pcap files. In high level languages, Java’s jpcap is probably the best bet. A python script that took above 72 hours to parse 238 GB data, did the same in 2.30 hours when reimplemented in Java.
7. Enable remote access on your machines. Saves a great deal of time. But be ‘careful’ — don’t turn it into a hacker fiesta!
8. Replicate data and results wherever they can fit. Hard disks will fail, computers will crash and all hell will break loose the moment you decide to do anything worthwhile with your data.
Now that i am familiar with Bro IDS, i intend to do a re- of this post mentioning things you can use Bro to do for you. Why reinvent the wheel?
See you again, soon-
5
Dealing with vector graphics in LaTeX
There are a number of ways to include your drawings in your LaTeX file. I prefer to go the traditional route, i.e., convert the drawing to .eps format and include it in the LaTeX file. However, this too has the potential to turn into a real pain. The final .pdf might look ok at a first glance but as you zoom in, the figures don’t look as crisp as you’d like them to be.
To cut a long story short, vector graphics tend to throw tantrums when they need to be represented in raster form. I tried a number of methods to get around this problem. Finally, i reached the conclusion that nothing works like OLETeX. In the following paragraphs, i describe my journey in the graphics desert and how i found an oasis in OLETeX.
How to generate eps file from a visio file:
If you have a printable object (png img, word, visio drawing etc.), you can convert it to .eps format by following these steps:
- Add a new printer and select MS Color Printer from the list.
- Open your visio drawing and select print. Check the option print to file and click print. Save the file with the extension .ps. We’ll call our file drawing.ps
- Download latest version of Ghostscript which is an interpreter for Adobe Systems’ PostScript and Portable Document Format (PDF) page description languages.
- Download GSView which provides gui for handling ps files using Ghostscript. By the way, you can skip GSView and use command line to get things going with Ghostscript as your interpreter.
- Now lets turn our attention to drawing.ps. Open it using GSView and from the file menu, select PS TO EPS option. I do not particularly like GSView’s bounding box calculation, so I like to keep the ‘automatically calculate bounding box’ unchecked and do it manually when prompted. Save the file with the extension .eps.
What the hell is a bounding box?
Now if you open your newly created drawing.eps, go to options and select ‘show bounding box’, you’ll see a dotted box. So this is your bounding box, no points for guessing. More formally, bounding box is the smallest box that can contain your figure. Often, there is unnecessary white space around a figure which looks nasty, but really screws things up if you embed your figure inside LaTeX. Obviously, the main problem lies with your bounding box. This problem can be solved in two ways:
- Specify the bounding box coordinates in your LaTeX file where you define your figure.
- Change the eps source file.
I don’t prefer the first option as I believe that a LaTeX source file should not reflect its author’s idiosyncrasies. In simple words, it should be clean, with bare minimum frills. Coming to the second option, it may look tedious and freaky at a glance, but it’s not so difficult.
All you have to do is to open your drawing.eps with word, notepad or whatever text editor you can get your hands on. You should see something like %%bounding-box somewhere at the beginning of the file. You’ll see four numbers or coordinates following the %%bounding-box tag. These four points define your bounding box and correspond to <bbllx bblly bburx bbury> where the first two points correspond to (x,y) coordinates of the lower left corner of your bounding box and the last two relate to its upper right corner. You can change these to reflect your desired bounding box. Open drawing.eps with GSView and point the cursor to the lower left corner of your figure. Note down the coordinates displayed at the bottom of the window. Now do the same for the upper right corner of your figure. Enter this information in the drawing.eps source file and save the changes. Congrats, you’re done!
Come OLETeX
You can bypass all this hassle by using a tool called OLETeX. I could not install it on my Windows 7 (apparently it doesn’t go well with x64 architectures). But it works fine on Windows 9x, Vista, XP and the likes. Gives really great results.
What’s Cooking?
Chatter Box
- Usman on Ali Khayam
- abc on Ali Khayam
- Sheharbano on Self Appraisal and Intellectual Arrogance
- Usman on Self Appraisal and Intellectual Arrogance
- Sheharbano on Ali Khayam











