diff --git a/Chapter02_Discrete_Bayes/discrete_bayes.ipynb b/Chapter02_Discrete_Bayes/discrete_bayes.ipynb index c4368af..271a2a2 100644 --- a/Chapter02_Discrete_Bayes/discrete_bayes.ipynb +++ b/Chapter02_Discrete_Bayes/discrete_bayes.ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:12fc2d9e63ea3d4311d2d3ce3dfde5992d34368a4a40f7e08114702fbe9359f6" + "signature": "sha256:44cac9d4e1b88b5a67224fee08c36f0fe84b55edfaf8f1ab7a1c996d083a36d8" }, "nbformat": 3, "nbformat_minor": 0, @@ -290,6 +290,9 @@ "\n", "I want to track my dog Simon, so I attach the device to his collar and then fire up Python, ready to try to write code to track him through the building. At first blush this may appear impossible. If I start listening to the sensor of Simon's collar I might read 'door', 'hall', 'hall', and so on. How can I use that information to determine where Simon is?\n", "\n", + "> This formulation, tracking an object in a hallway, has been used to explain the discrete Bayesian filter many times. The first published source that I am aware of is Fox 2003 [1]. Sebastian Thrun also uses this formulation in his excellent Coursera course *Artificial Intelligence for Robotics* [2] In fact, if you like watching videos, I highly recommend pausing reading this book in favor of first few lessons of that course, and then come back to this book for a deeper dive into the topic. \n", + "\n", + "\n", "To keep the problem small, we will assume that there are only 10 positions in a single hallway to consider, which we will number 0 to 9, where 1 is to the right of 0, 2 is to the right of 1, and so on. For reasons that will be clear later, we will also assume that the hallway is circular or rectangular. If you move right from position 9, you will be at position 0. \n", "\n", "When I begin listening to the sensor I have no reason to believe that Simon is at any particular position in the hallway. He is equally likely to be in any position. The probability that he is in each position is therefore 1/10. \n", @@ -416,7 +419,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "pos = np.array([0,1,0,0,0,0,0,0,0,0])\n", + "pos = np.array([0., 1., 0., 0., 0., 0., 0., 0., 0., 0.])\n", "print(pos)" ], "language": "python", @@ -426,11 +429,11 @@ "output_type": "stream", "stream": "stdout", "text": [ - "[0 1 0 0 0 0 0 0 0 0]\n" + "[ 0. 1. 0. 0. 0. 0. 0. 0. 0. 0.]\n" ] } ], - "prompt_number": 6 + "prompt_number": 4 }, { "cell_type": "markdown", @@ -1181,6 +1184,28 @@ "**Author notes:**\n", " Do I want to go to the multidimensional case? At least describe it, but why not implement it as well" ] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "References" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + " * [1] Dieter Fox, et. al. \"Bayesian Filters for Location Estimation\". IEEE Pervasive Computing, September 2003.\n", + " http://swarmlab.unimaas.nl/wp-content/uploads/2012/07/fox2003bayesian.pdf\n", + " \n", + " \n", + " * [2] Sebastian Thrun. \"Artificial Intelligence for Robotics\".\n", + " https://www.udacity.com/course/cs373\n", + " \n", + " " + ] } ], "metadata": {}