https://github.com/rlabbe/Kalman-and-Bayesian-Filters-in-Pyt...
It uses Jupyter Notebooks to run code in the browser. Check out the book, or run online using Binder.
21–30 of 74 posts
https://github.com/rlabbe/Kalman-and-Bayesian-Filters-in-Pyt...
It uses Jupyter Notebooks to run code in the browser. Check out the book, or run online using Binder.
What a giant of his field! Here he is receiving the National medal of Science from Barack Obama[1]
http://www.ethlife.ethz.ch/archive_articles/091008_kalman_pe...
Edit: This is wrong. This is a particle filter, another type of Bayesian filter. I can't delete now, so please downvote to hide. I made a Kalman Filter visualization[1] last year to learn more about them. It's amazing to see how good a result you can get from very poor sensor data. In the visualization, a lawnmower (green dot) is tracked (blue circle) using triangulation. The distance sensors have very low accuracy (…
Earlier quoted context omitted.
Interesting. I don't see generic Kalman filter implementations too often. Thanks for sharing. I've always found that determining where to put outputs from disparate sensors as opposed to just filtering a single observation like the GPS output in your example is challenging. Have you tried extending this to include input from other sensors (e.g. accelerometer, gyroscope, magnetometer, etc.)?
I actually found it to be such a pain in the ass to tune, it didn't even seem that great on iPhones with plain old GPS compared to a hacky bundle of heuristics. I left the code on github because why not, and it turned out over the years people have used it for various things.
Here's some ancient code from those days: https://github.com/Qworg/Robot-Sensor-Fusion
If folks are interested, here's some ancient (and likely awful) code I wrote for it. It has a MH set, a Fuzzy set, a PF and a SPKF as well: https://github.com/Qworg/Robot-Sensor-Fusion
Just last week I needed to smooth out a display reading on an oven controller. The RTD was being read way too fast so I'd get a lot of flicker between values due to ADC resolution. In the back of my head I remembered one word: Kalman. This line of code fixed it right up: static float display_temp = 0; display_temp += 0.04 * (adc_temp - display_temp);
The alpha-beta filter is the position/velocity version, and is commonly seen in settings where less is known about the system dynamics, or there's not enough CPU for matrix math. See https://en.wikipedia.org/wiki/Alpha_beta_filter
Edit: This is wrong. This is a particle filter, another type of Bayesian filter. I can't delete now, so please downvote to hide. I made a Kalman Filter visualization[1] last year to learn more about them. It's amazing to see how good a result you can get from very poor sensor data. In the visualization, a lawnmower (green dot) is tracked (blue circle) using triangulation. The distance sensors have very low accuracy (…
If you are interested in learning about them in depth, I'll toot my own horn and point you to my interactive book on them: https://github.com/rlabbe/Kalman-and-Bayesian-Filters-in-Pyt... It uses Jupyter Notebooks to run code in the browser. Check out the book, or run online using Binder.