shkolnick-kun fb8be02b3a Added CoC. | 3 gadi atpakaļ | |
---|---|---|
doc | 3 gadi atpakaļ | |
src | 3 gadi atpakaļ | |
tests | 3 gadi atpakaļ | |
.gitignore | 3 gadi atpakaļ | |
CODE_OF_CONDUCT.md | 3 gadi atpakaļ | |
LICENSE | 3 gadi atpakaļ | |
MANIFEST.in | 3 gadi atpakaļ | |
README.md | 3 gadi atpakaļ | |
pyproject.toml | 3 gadi atpakaļ | |
requirements-dev.txt | 3 gadi atpakaļ | |
requirements.txt | 3 gadi atpakaļ | |
setup.cfg | 3 gadi atpakaļ | |
setup.py | 3 gadi atpakaļ |
YAFL means Yet Another Filtering Library.
Here you can find some Kalman filter variants:
Algorithm family | Basic | Adaptive | Robust | Adaptive robust |
---|---|---|---|---|
SUD EKF | ✓ | ✓ | ✓ | ✓ |
SUD UKF | ✓ | ✓ | ✓ | ✓ |
UD UKF | ✓ | ✓ |
where:
For all EKF variants we have Bierman and Joseph updates. For sequential UD-factorized UKF only Bierman updates are available.
And yes, we can actually use EKF tricks with UKF!
The library is written in C and is intended for embedded systems usage:
To use the library you need to:
/*yafl_config.h*/
#ifndef YAFL_CONFIG_H
#define YAFL_CONFIG_H
#include <math.h>
#include <stdint.h>
#ifdef DEBUG
/*
In this example we will use standard output.
You can actually use any printf implementation you want.
*/
# include <stdio.h>
# define YAFL_LOG(...) fprintf(stderr, __VA_ARGS__)
/*
Using branch speculation may save some clocks...
*/
# ifdef __GNUC__
# define YAFL_UNLIKELY(x) __builtin_expect((x), 0)
# else /*__GNUC__*/
# define YAFL_UNLIKELY(x) (x)
# endif/*__GNUC__*/
#else /*DEBUG*/
/*
Here we have "Never" actually, but you can use some of above definitions if you want.
*/
# define YAFL_UNLIKELY(x) (0)
#endif/*DEBUG*/
#define YAFL_EPS (1.0e-7)
#define YAFL_SQRT sqrtf
#define YAFL_ABS fabs
typedef float yaflFloat;
typedef int32_t yaflInt;
/* WARNING!!!
Fast UKF SSR updates may give dramatically incorrect results in case of adaptive Bierman filter
*/
//#define YAFL_USE_FAST_UKF
#endif // YAFL_CONFIG_H
We also have a Python extension for prototyping purposes. Python 3.5+ with 64bit is supproted.
To use the extension you need to:
install it:
# Cython, numpy, scipy, setuptools, wheel
# are needed at this point
pip install path_to/yaflpy-\<latest version\>.tar.gz
Python
import yaflpy
write some code which use the extension.
[West1981] M. West, "Robust Sequential Approximate Bayesian Estimation", J. R. Statist. Soc. B (1981), 43, No. 2, pp. 157-166