过滤/标准化不良信号的算法
使用 GPS 开发跟踪应用程序。 一切都很好,但有时由于封闭区域或恶劣天气,我得到的分数不准确。 当你绘制它们时,它看起来不太正确,有很多跳跃/跳跃。
我应该运行什么算法来过滤掉不良信号 对我来说,这看起来像是模糊算法的应用,但你觉得怎么样?
Working on a tracking application using GPS.
It is all fine, but sometimes because of the closed areas or bad weather I get inaccurate points. When you plot them, it just doesn't look right, with lots of hops/jumps.
What algorithm should I run to filter out the bad signals
It looks like an application of a blurring algorithm to me, but what do you think?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
有几个选项:
我喜欢使用过滤器 - 卡尔曼过滤器是典型的(通常也是最好的)解决方案 - 它使用比便宜的 IIR(无限脉冲响应)滤波器更好的预测平均量:
FilteredValue = FilteredValue * 0.75 + NewValue * 0.25
您可以获得每秒提供 4-5 次修复的 GPS 模块,这将允许您使用高于具有合理响应时间的“廉价”过滤器。
您还可以简单地获得更好的 GPS(SiRF III 或更好),该 GPS 噪音较小且室内接收效果更好(如果可能)。
消费者 GPS 装置会尽可能“捕捉到道路”,因此消费者不会看到偏离道路的错误,以及其他一些技术。
卡尔曼算法并不容易实现,但在没有外部数据集或传感器(例如道路速度)的情况下,它是最好的选择。 请查看 http://www.google.com/search?q= open%20source%20kalman%20filter 获取代码和教程。
-亚当
There are a few options:
I like to use filters - A Kalman filter is the typical (and often best) solution - it uses an amount of predictive averaging which is better than a cheap IIR (Infinite Impulse Response) filter:
FilteredValue = FilteredValue * 0.75 + NewValue * 0.25
You can get GPS modules which give you 4-5 fixes per second, which will allow you to use the above 'cheap' filter with reasonable response times.
You can also simply get a better GPS (SiRF III or better) that isn't as noisy and has better indoor reception (where possible).
Consumer GPS units "snap to road" where possible, so errors off the road are not seen by the consumer, as well as a few of the other techniques.
A Kalman isn't easy to implement, but without an external dataset or sensor (such as road speed), it's the best option. Check out http://www.google.com/search?q=open%20source%20kalman%20filter for code and tutorials on it.
-Adam
回复:在存在“流行”噪声的情况下进行过滤——
我发现做到这一点的最简单方法之一是:
其中 alpha = 1/tau 且 tau 是所讨论的低通滤波器的时间常数,表示为上述代码迭代之间的时间的倍数。 值
LARGEST_SANE_DELTA
表示newValue
中可能发生的较大变化,并限制输入中过大的变化。 也许有更好的方法来拒绝这种类型的噪音,但它们更复杂,而我提到的方法非常简单。re: filtering in the presence of "pop" noise--
One of the easiest ways I've found to do this is:
where alpha = 1/tau and tau is the time constant of the low-pass-filter in question, expressed in multiples of the time between iterations of the above code. The value
LARGEST_SANE_DELTA
represents a large possible change innewValue
and clips excessively large variation in input. There are perhaps better ways of rejecting this type of noise, but they are more complicated, and the one I mentioned is pretty simple.使用卡尔曼滤波器。
Use Kalman filter.