The Bayesian Approach

For the people, who are unaware of , there are two approaches to Probability. I studied about these in the math courses in my Undergrad, but was never told of these being two different approaches to probability theory. Alas!!

1) The Classical Approach (also called the frequentist view)

2) The Bayesian Approach (also called the subjectivist view)

I shall be talking about the latter.. (as it is the one used in Machine Learning! and also my personal favourite :) )

The essence of the Bayesian approach to Probability:

You believe that you like a person. You don’t know how much you like him/her. The actions of the person towards you affect your liking or the belief (your belief that you like the person) you have towards him/her. This is common-sense. The beauty of the Bayesian principle lies in, encoding/representing the above common-sense fact using math.

An important thing one should be keeping in mind is that the Bayesian approach to Probability talks about ‘your’ beliefs on a subject. My belief about the Tajmahal is great. Another person’s might not be the same. This is the main difference when compared with the classical approach.

A simple example to explain the difference between the classical and the bayesian view is: Let us take the usual coin-tossing experiment. I toss a coin a 100 times, and then set out to estimate the probability of getting a heads when i toss it the 101th time.

1) Classical approach: You take a note of the number of times heads has appeared in all these 100 flips and then find the probability of getting heads by using: (No.of heads appeared)/(Total times the coin has tossed). You use this value for your future experiments saying that, in my first 100 coin tosses, i got heads 60 times (say), so the 101th time when I toss a coin, there is chance of getting a head than a tail!

2) Bayesian approach: Your aim of this experiment is not to know the probability of a coin showing heads in your first 100 tosses, but to know what might the coin show on the 101th toss or on the tosses later. Well, in this case the probability as obtained by these 2 methods might be the same, but your approach of seeing things is what that matters most.

Say, you have a belief that the coin shows tails. Now with every toss of the coin showing tails, you increase this belief or yours, and with every occurrence of a head, you decrease your belief. (You increase your likeliness about a person, for every nice thing he/she does towards you…isn’t it?) This is the Bayesian view of seeing things.

P(coin = tails|E) = P(E|coin = tails) * P(coin = tails)/P(E) <– the bayes theorem.

P(coin = tails) — Your initial belief that the coin shows tails.

P(E|coin = tails) — Now, given you believe that the coin shows tails, you test that against the Experiment, E. If in this test of yours, if you notice that the coin is infact showing tails, then your belief, P(coin = tails|E) gets increased.

(because, P(coin=tails | E) is proportional to P(E|coin = tails)*P(coin = tails) , from the above equation.)

You obtain the final value after completing the experiment. Now, based on this value you might take decisions on the future tosses.

Remember the word ‘belief’ is synonymous with ‘probability’ when u see things in bayesian perspective.

The coin-tossing experiment might not be a very good example to differentiate the bayesian and classical approaches.. I’ll try to give a better insight into this issue sometime later when it is being discussed with some machine learning problem. Just know that there are different views of seeing things, and the latter is the convenient one. It is convenient because it represents a common-sense/reality fact.

The Bayesian view is very very useful when dealing with Machine Learning stuff. and I’m a Bayesian. :)

#A good explanation on Bayesian philosophy. And there are many more!

(Abridged contents from "The Bayesian" by Vinay Gryffindor)

Posted bySandeep Sekharamantri at 1:48 PM 0 comments  

Random Rambling

Life seems to be on the run. Just a month ago I used hog like a horse and slumber like a sloth all through the lovely week and go out to explore the countryside (or whatever was left of it in coimbatore) on the weekends. Now I lead a friday to monday life. The rest of the time just flies by.

Wake up on a monday morning with those legendary monday blues at about 8am. Get ready and go through the rush hour to office. The next thing worth mentioning is the beer bash on friday. The missing pieces in between are filled by me sitting in front of a computer, me drinking coffee and me banging my head all the time trying to figure out how in pluto's name do these software professionals survive, let alone make millions by just kutting all day long!!!

I had had enough of the software life. One full year filled with copied codes, reproduced assignments and sloppy professors. I expected the industry to be a lot better considering that we Indians make a lot of dollars doing IT development. And the industry was an awesome experience, at least in the beginning. I walked into NetApp to a great welcome. My manager walked with me upto my cubicle which already had my name plate on it. I had a free laptop with internet. New found friends took me to the pantry where food was free. I was told that on fridays beer was served, free ofcourse. The software industry employs some of the best looking girls too. And for a rough and hardened mechite like me this was paradise. I totally freaked out the first few days utilising every freebie that I could get. But suddenly I realised that I missed something amidst the partying. THE WORK!. What exactly do these software guys do to live that way? Well, they just code and code and code and more code!

In BITS I heard my computer science 'engineering' friends talk about development work happening in the MNC's in the nation and felt that they would be working at the fore-front of cutting edge computer science technology someday soon. They also talked about something called "testing" in a much demeaning way and I got the impression that it was just people putting in x=1 and x=0 to test whether a code is working or not.

Indeed even within the industry I found 'engineers' talk the same way about development and testing jobs. But soon I realised that these so called engineers do the same things, whether its development or testing, whether he's a fresher or a manager with 30years experience. They all do the same things. They all code and code and code! The interface might change, the exterior might change, the pay package might change, their timings can change, but their core work does not. They just code.

Well, 1 month into my internship and I have firmly decided never to go back to a pure software industry and work with software 'engineers' (they love that term in these companies!)

Engineering, in my opinion, is the useful manipulation of the laws of nature. Engineering has physics as its most fundamental building block. And that is how we were taught in school. If you are good in physics you can become an engineer. A computer science problem, even in its most primitive basic format cannot be remotely related to physics and hence it cannot be related to engineering.

I got into a little trouble when I started discussing this angle with my manager and asked him why he was not called a computer scientist instead of a software engineer!!

I am happy that I made a job with a core manufacturing firm where they have real engineers who practice engineering in the real sense of the term.

The trouble with living life from friday to monday is that you get these niggling seconds in between your orkut and free juices where you let your thoughts ramble randomly. And when you sit down to write a blog at the first chance you get, you are lost and those random sentiments desist to form a chorus. What results is this aphrodisiac poop that you have just read.

Posted bySandeep Sekharamantri at 10:49 PM 4 comments  

My first instruction!!

Getting settled in your cube or office
If there is no chair, borrow one from a conference room. Then contact the Workplace Resources people; they will get you a less fancy but more adjustable one. It may take them several days though. If your conference room chair disappears in the meantime, just go borrow another one. You have the right to sit down.
If you don't have a computer yet, twiddle your thumbs a few times, then go to lunch. In NB, there is the food court, but it's kind of doubtful, although the restaurants on the upper floors are ok. Better yet, wherever you are, just ask your co-workers to suggest a place to eat. Or look for write-ups of local eateries on the web. If all else fails, get in your car and drive around aimlessly.
If there is no name tag on your cubicle, just wait. One will show up in a week or two. If you just can't wait, ask your manager to ping the process.

I guess working in a new company has its advantages!

Posted bySandeep Sekharamantri at 4:44 PM 0 comments  

A wonder!

A blind boy is walking down the street distributing small yellow pamphlets shounting out loudly " मुझे वोट दो".

My first impression was that it was an ad-film made to create awareness about the blind and their ascendency to normal life.

The boy slowly moves his hand over the eaflet and it shows a pencil sketch of the Taj Mahal.

सुना है कि बहुत सुंदर है।

please वोट दिजियेना।

What is it about this national craze, even international media frenzy, that is creating such moving ads? Can a monument made by a lover in memory of his love capture the imagination of a nation like never before? Is it really a national symbol?

A national symbol unites the people in a way that no other can. It is a solidarity, constituted by the feeling of the sacrifices one has made in the past and of those that one is prepared to make in the future.

Take national anthem, for example, sung on national holidays. No matter how banal the words and the tune we sing it in, there is in this singing an experience of simultaneity. At precisely such moments, people completely unkown to each other utter the same verses to the same melody. The image: resonance, the echoed physical realisation of the one community. How selfless this resonance feels.

Can a monument like the Taj achieve something remotely similar to such a feeling?

Whenever a foriegner thinks of India, he thinks of snake charmers, elephants and the Taj. An international dignitary always takes time off his busy schedule to visit the taj. Its globally acknowledged that the Taj is considered the symbol of love, the ultimate tribute to any human emotion. An edifice that epitomises an expression that is natural to every human being. It is this poignant intercourse of sentiment with marble that sets the Taj apart from any other monument.

The world is in its awe. Poets are praising it, minstrels singing of it, psychologists getting deep about it, boys and girls dreaming of it. Billboards selling it, industries built on it, kings and queens and streetsweepers hot in its pursuit.

This country has one chance to make all this sustain forever. It is this chance to enlist the Taj as one of the new seven wonders of the world. If voting is required to prove its worth, then so be it. We as a nation of a billion should be happy to see the Taj i a place where it actualy belongs.

These are the exact feelings one gets when he thinks of the new seven wonders campaign. This is another such moment when a person wholly unkown to you ponders over the same feelings. He wants his national sysmbol to be respected by the international community.

I have never seen the Taj for real in my life so far.

सुना है कि बहुत सुंदर है।
please वोट दिजियेना




Vote here

or sms TAJ to 4567

Posted bySandeep Sekharamantri at 5:46 PM 3 comments  

The moments that defined me

This is where it all begins.....my BITSian life!



A trip of epic proportions A trip that brought out more stories in a single fortnight than the rest of my BITSian life put together. The credit goes to Maddy and MLM travels.




The "Kukka" posh b'days!!!









Few of the best B'day celebs happened in this hallowed wing.

The last trip with the wing as a WHOLE!


A generation awakens



The most amazing assoc grubs




The festivals

Diwali in 2nd year , Rakhi in 3rd year


The one thing that I truly LEARNED in BITS....CATIAv5R14



The BEST thing that ever happened in my BITSian life, my wingies!!!





My most favourite place in BITS



A thousand memories!!!


TORQUE- Bend your minds for a Moment


Times, when they were good!

Times, when they got better!

My BITSian life at its ZENITH!

One day I shall lead them all!

The best juniors a senior can ever hope for


Psenti-SEM!!!


The Pillars of my BITSian Life




The fruits of my four year labour

Presenting

Sekharamantri Ratna Sandeep

BE (Hons) Mechanical

BE (Hons) Computer Science

Posted bySandeep Sekharamantri at 5:43 PM 4 comments  

गूगल हिंदी

मैंने देखा कि ये गूगल का नया अविष्कार है।

ये तो बढिया है।

ये नयी यन्त्र machine learning कि सहायता से काम कर्ता है।

मैंने इसे अभी अभी देखा है और सोचा क्यों ना इसे मैं आजमा के देखू ।

इस चीज़ ने थो मुझे बहोत खुश कर दिया है ।

गूगल हिंदी रोक्ज़!!!

Posted bySandeep Sekharamantri at 12:57 PM 0 comments  

When the end is near, why do I crave for the begining

Sandy's one line status message sums it up aptly. The end is approaching, and I hope to wake up from my dream in my first year and start all over again!

This what I see in the status messages everyday in my gtalk. Ofcourse, there is that occassional "Last one month in this God forsaken place" and a little more of blasphemy, but that is just an expresion of anguish at the system which is stubborn enough to test us even in the ultimate month of our union at BITS Pilani.

I have no idea why I felt like this today, but if I had a chance to go back and start from the begining, I would love to go back in time and do it exactly the same as I had done in the past four years.

Lots of meomries......I guess i shall organise them one day soon !

Posted bySandeep Sekharamantri at 6:41 PM 2 comments  

PhD blues


I am not even done with my undergraduation and the title seems very outlandish for my position.


BITSians are very popular for their laid back inquisitiveness, but there was this guest lecture by Dr.P.Anandan from Microsoft Research India that even the most fair-minded BITSian looked forward to.


The man talked about every computer science related subject that we could concieve of. He spoke of computer vision, geometry tranfer in networks, image processing, power savings, processor designs, languge processing and even technology for the meagre.


His main aim though was to encourage more BITSians to pursue a PhD. He motivated us to do a lot of things in ways that normal BISians would not even think of. A truly talented induvidual, he did get me thinking on what to do with my future.


I definetly see some PhD blues!

Posted bySandeep Sekharamantri at 5:03 PM 1 comments  

Permission Denied

Four years of BITSian life has made a man out of me. I do not get desolate when my favourite team loses a match. I do not get hysterical with emotions when I do something out of the ordinary. Hell, I do not feel even a dimunitive smidgen of remorse when I do not complete my assignment.

There was a time, a bygone era which few highbrows love to call their "wonder years", whenI used to shudder and even holler in dread at the very thought of missing a deadline for my homework. But now I am a man. I do not despair when I do not complete my work. I brazenly reproduce the work of my comrades, notwithstanding some skillful morphing.

Today, as usual, I was least bothered about submitting my PLCC assignmnet II until my groupie turned up, as always in a chop-chop fashion. So I sat down and morphed the code of a prodigy who still lives in his "wonder years". After four excruciating hours of strenous labour I pressed the "enter" key to submit my assignment. The screen immediately flashd a message :

Permission Denied

Four hours of precious time wasted, hope shattered, morale hit rockbottom.

This I take as a message from the almighty himself. I am a man and to show the right path to a faithful soldier of humanity like me The Lord himself has transmuted into the prithvi server.
I take the word of lord as my command.

Thou shalt not submit thy assignments

Posted bySandeep Sekharamantri at 10:17 PM 1 comments  

The contrast

Yesterday was a stirring day that progressed with a frenetic promptness. It started with a normal BITSian supT. The aftenoon came and along with it brought the president of india with it. The evening was possessed by Oracle and its representatives making a very lucid allocution on the work they were carrying out at Oracle IDC at Bangalore. The evening sun set and setup a rendezvous with yet another powerful citizen, albeit of USA, Vivek Paul, the richest BITSian alumni.
After all this excitement in a single day one would hope that the next day would be set apart for rest. Well, it definetly was and it turned out to be one big boring day. I spent the whole day lazing around and sleeping.
But I found these amazing activities that people could do on a boring day. Read on!
Ride the bus for one block.
Bring a camcorder to a funeral.
Have a staring contest with a baby.
Pay your apartment rent short by 10paisa.
Ask the Akshay bakery if they have urinal cakes.
Return to work the day after you've been fired.
Call work on your day off and say you aren't going.
When the phone rings, pick it up and ask for somebody.
When ordering a pizza, emphasize the this order is "to go".
Hire a bodyguard and then start as many fights as possible.
Conduct a telephone call while you're straining on the toilet.
As the bus comes, hold out your thumb as if you're hitchhiking.
Watch a movie with the volume muted and speak for the characters.
Call a furniture store and ask if they have a swimming pool table.
While driving, smile and wave at every driver that gets mad at you.
Say to somebody in the bogz, "So, takin' a ______, huh?"
Find a construction site and tell them you're bored and offer to help out.
File a restraining order against your pets. ("Tommy, quit following me!")
Call the library and speak quietly so you don't disturb anybody there.
Name your pet God. "Come here, God, come here! God wanna go outside?"
Donate your old, worn socks and dirty underwear to NSS or MY India.
Send someone an invitation to your party, and write in it that they're not invited.
Call the phone number on a "Lost Dog" sign and tell them you haven't found it yet.
Enter a room full of people, and ask them all to leave because you need time alone.
When you enter a movie theater containing very few people, sit next to one of them.
Guys: Announce "Whoa, that was a close one!" after zipping up at a restoom urinal.
For an answering machine message, just say that "you called to leave a message. Bye."
When someone on the phone says you have the wrong number, ask what the right one is.
Get on an elevator full of people and push all the number buttons so it stops at every floor.
In a movie theater, constantly whisper to the person beside you, "Here comes the next part."
When you see a crime scene, approach the officer in charge and ask, "So, what do we got?"
Mail your Christmas packages a few days late. On the box, write, "Do not open 'til Christmas."
While driving, ask someone for directions in a heavy foreign accent. Afterwards, thank them in perfect English.
Have a perfectly boring day!

Posted bySandeep Sekharamantri at 5:53 PM 1 comments  

He came, He waved, He conquered!!


The most awaited moment of recent BITSian history happened today, and it was worth the wait.

Even though we could not get the audi pases, we made most of what we had.

At 2:30PM a BIG gang of students stood outside the library, under the scorching sun, jubiliating at every sound of a passing automobile in anticipation of the most powerful man in the country.

The moment finally arrived at 2:48PM.

A short, frail looking old man, extremely healthy for his 76 summers, walked out of a small ambasador car (which was followed by a long fleet of other vehicles) under the shade of a blue umbrella. He hopped up the library stairs and into the shade of the library roof. Then as if an afterthought, he walked straight back into the sun, sending his security men into a tizzy. An old man with white flowing silvery hair, stood on the library stairs and waved at us!

The President of India had arrived!!!

After a short 3 minute walk inside the library he walked out and straight into his car. This time he ordered his driver to drive slow. The entire convoy of 27 cars went past us at less than 10kmph. Dr.Kalam unfolded his blinds of the car and watched all of us shouting and waving in exhilaration of having the first citizen of the nation wave back and smile at us.

Once inside the audi, after the initial formalities of the welcome speech by the VC, the most awaited "invited lecture" in BITSian history began. Dr.Kalam talked about "Convergence of Technology". He felt BITS, with all its multidisciplinary approach and flexibilities was the right venue to broach such a discussion. The man started with World-Class systems, drifted into nano-technology and carbon nano-tubes. He talked about bioSciences and its culmination with information technology to form bio-informatics. He spoke of design and manufacturing and the strides our nation was taking in these fields. He then spoke of INdia's commitment to global development by citing an example of our support in helping in wiring the 53 african nations in one BIG wired network. He sought active BITSian support in this initiative.

Then there was a small QnA session. The normal questions regarding poverty level in india, multi-cultural affects on students in 21st century, moon mission etc were asked and answered with aplomb by his excellency.
KrishnaHasa from my-india gave a small intro about my india and asked Dr.Kalam about how
students could channelise their forces for better utilisation of communities like my-india. The president promptly replied that the most important goal of a student is excellence in education. The activities like social service, my-india etc can be carried out in your liesure time as on sundays and holidays, but he again emphasised that the foremost aim of a student is excellence in academics and nothing else.
Sindu Anand was the last to ask the question. She asked something related to righteousness.
His excellency ended his speech in BITS by answering this question with the following words and made us repaet them after him.

"When there is righteousness in the hearts, there is beauty of character
When there is beauty of character, there is harmony in the home
When there is harmony in the home, there is order in the nation
When there is order in the nation, there is peace in the world"

After this he left the auditorium and proceeded on his journey to jaipur.

The much awaited visit had come to an end and we were fortunate to be a part of it.

Posted bySandeep Sekharamantri at 4:51 PM 4 comments  

Day 2

It is amazing how many people reminded me about blogging today.
My day started on a lazy note, a normal BITSian starting to yet another lousy day. The first thing that caught my eye in the paper was about someone's blog being closed by Google. I reminded myself to fill in Day 2........ya..there was still time for that to be done as the day progressed.

Today was the day when I promised myself that I would attend classes, yes all three of them, one after another. Sometimes these dashes of testosterone , or the lack of them, lead humans to take terrific decisions whose conseqences they are not really ready to be responsible for. I somehow managed to wade through the tides of boredome, frustration and utter despair that were thrown at me in the compnet and PLCC classes. Then in MSD class, there was again this faint hint of sticking your duties....attend clases regularly, study religioulsy,blog daily....BLOG daily??!!, now when did MSD start teaching about blogs??...somehow that came out of his wise mouth today.

And then, Dt prodded me to write a blog of my own. I havent told him till now that I did open an account with BLOGGER, but I will tel him in good time....and he will be happy to see himself in these records!

Posted bySandeep Sekharamantri at 6:10 PM 0 comments  

Day 1

Ok, this is the fifth blog that I am using. I will make sure this will be the last one and I will stick with this for sometime. :)

Posted bySandeep Sekharamantri at 2:58 PM 0 comments