Sunday, 10 January 2016

Visualizing relations and probabilities

It is not wrong if we say human vision is one the most advanced pattern recognition systems that exists. Just consider our vision system starts to work since we get born even before it! And starts collecting data, processing and ... consider your eyes get 10 samples per seconds from the environment while you are awake like 16 hours a day, here is how many images have been processed by a 30-year-old human being:

10 (image/sec) * 3600 (sec/hour) * 24 (hour/day) * 365 (day/year) * 30 (year) = 9,460,800,000

Now consider you have many shapes, objects, colors and ... in each of these captured images, how much we learn from them every second of our life!? Now you can understand why it is so much easy for a human being to recognize people, things, ... so much easy while it is still a very hard work for a machine.



This is a rich topic to discuss and I'm sure I'll back to it later, for now, let's get back to our probability subject and try to see how we can visualize our example in the previous post, the example was about someone who has 2 options to take his/her route from home to the office, we are monitoring his/her for a month and try to find a pattern from it.

Sample Bayesian Networks with transition probability
Look at the graph #1 in this picture, it shows the result of our monitoring period, our subject takes Route A with the probability of 83% and Route B with the probability of 17%. Now in graph #2, we've recorded another parameter when we collect data during the monitoring process which is the weather condition. It shows whenever it rains our subjects chooses Route B but if it doesn't rain it just chooses Route B just 17% of the times. And in graph #3 you see we have collected the time of the taking the route too.

It is obvious with information we have in graph #3 and by having the current situation we can have a better prediction of the taken route. All we need to know is if it's raining or not and the time of the day. If it is morning and the sky is clear we are sure our subjects will choose Route A to Route B with ratio of (75 x 83)/(17 x 25) which is about 15 / 1 while if we didn't have the weather condition and time of the day we could only say that he/she is going to take the routes with ratio of 83/14 or about 5 /1. This is in fact the basics of what our subject does somehow automatically in his/her mind, this is the basics of how we think.

By the way, any of the graphs in this picture is somehow a representation of a Bayesian Network or Markov Network.

No comments:

Post a comment