Jafar
|
Class for prediction of the movement of a line in a sequenze of images. More...
Class for prediction of the movement of a line in a sequenze of images.
This Class provides containers and functions to predict the new position of a line in an image after it was tracked over prior images.
Definition at line 40 of file lsPredictor2D.hpp.
#include <lsPredictor2D.hpp>
Public Member Functions | |
void | initPredictor (double mx, double my, double phi, double rho, double theta, PredictionModel model=PERP_MIDPOINT_PROJ) |
Initializes the Kalman filters for prediction. | |
void | updatePredictor (double mxOld, double myOld, double phiOld, double mxNew, double myNew, double phiNew, double rhoNew, double thetaNew) |
Updates the predition model. | |
double | getPredictionEP (double x1Old, double y1Old, double x2Old, double y2Old, double &x1Pred, double &y1Pred, double &x2Pred, double &y2Pred, double l=0) |
Get the prediction for new endpoints. | |
double | benchmarkTest () |
Get the benchmark value. | |
Private Attributes | |
PredictionModel | predMod |
Type of motion model. | |
uint | nUpdates |
Number of updates. | |
double | cDist |
Distance of last prediction to measurement. | |
double | benchmark |
Indicator for the reliability of the prediction, small value is good. | |
filter::ConstantVelocityKalmanFilter | xKF |
Constant velocity modell for x coordinate of midpoint. | |
filter::ConstantVelocityKalmanFilter | yKF |
Constant velocity modell for y coordinate of midpoint. | |
filter::ConstantVelocityKalmanFilter | phiKF |
Constant velocity modell for direction of line. | |
filter::ConstantVelocityKalmanFilter | rhoKF |
Constant velocity modell for polar coordinate rho. | |
filter::ConstantVelocityKalmanFilter | thetaKF |
Constant velocity modell for polar coordinate theta. | |
filter::ConstantVelocityKalmanFilter | dKF |
Constant position modell for perpendicular difference of lines. | |
filter::ConstantVelocityKalmanFilter | alphaKF |
Constant velocity modell for angular difference. | |
filter::ConstantVelocityKalmanFilter | xPKF |
Constant velocity modell for x coordinate of midpoint, updated with perpendicular motion. | |
filter::ConstantVelocityKalmanFilter | yPKF |
Constant velocity modell for y coordinate of midpoint, updated with perpendicular motion. | |
filter::ConstantVelocityKalmanFilter | phiPKF |
Constant velocity modell for direction of line for perpendicular update. |
double jafar::lines::LsPredictor2D::benchmarkTest | ( | ) | [inline] |
Get the benchmark value.
This function provides a value that indicates if we can trust in the prediction modell. That test is not well realised for all prediction models. Should be improved.
Definition at line 98 of file lsPredictor2D.hpp.
References benchmark.
double jafar::lines::LsPredictor2D::getPredictionEP | ( | double | x1Old, |
double | y1Old, | ||
double | x2Old, | ||
double | y2Old, | ||
double & | x1Pred, | ||
double & | y1Pred, | ||
double & | x2Pred, | ||
double & | y2Pred, | ||
double | l = 0 |
||
) |
Get the prediction for new endpoints.
This function provides the prediction of a line in endpoint representation. The motion prediction is only reliable if the line was tracked over prior states and if the mortion did not change to much. A constant velocity model is used.
void jafar::lines::LsPredictor2D::initPredictor | ( | double | mx, |
double | my, | ||
double | phi, | ||
double | rho, | ||
double | theta, | ||
PredictionModel | model = PERP_MIDPOINT_PROJ |
||
) |
Initializes the Kalman filters for prediction.
Initializes the Kalman filters for prediction. The recommended prediction model is PERP_MIDPOINT_PROJ. Depending on the prediction model the parameters that are really necessary changes.
MIDPOINT_X_Y Requires mx, my, phi
POLAR_COORD, Requires rho, theta
ONLY_PERP_MOTION, Requires mx my phi
PERP_MIDPOINT_PROJ Requires mx, my, phi
void jafar::lines::LsPredictor2D::updatePredictor | ( | double | mxOld, |
double | myOld, | ||
double | phiOld, | ||
double | mxNew, | ||
double | myNew, | ||
double | phiNew, | ||
double | rhoNew, | ||
double | thetaNew | ||
) |
Updates the predition model.
Updates the Kalman filters for prediction. The variances for measurements and process noise are hard encoded. Depending on the prediction model the parameters that are really necessary changes.
MIDPOINT_X_Y Requires mxNew, myNew, phiNew
POLAR_COORD Requires rhoNew, thetaNew
ONLY_PERP_MOTION Requires mxOld myOld phiOld mxNew myNew phiNew
PERP_MIDPOINT_PROJ Requires mxNew, myNew, phiNew
Generated on Wed Oct 15 2014 00:37:42 for Jafar by doxygen 1.7.6.1 |