Skip to content
Snippets Groups Projects
Commit 1893c174 authored by Joan Solà Ortega's avatar Joan Solà Ortega
Browse files

remove sizes info from Motion

parent f9a757d6
No related branches found
No related tags found
1 merge request!343WIP: Resolve "Complete state vector new data structure?"
......@@ -21,7 +21,6 @@ using namespace Eigen;
struct Motion
{
public:
SizeEigen data_size_, delta_size_, cov_size_, calib_size_;
TimeStamp ts_; ///< Time stamp
Eigen::VectorXd data_; ///< instantaneous motion data
Eigen::MatrixXd data_cov_; ///< covariance of the instantaneous data
......@@ -47,7 +46,6 @@ struct Motion
const MatrixXd& _jacobian_calib);
~Motion();
private:
void resize(SizeEigen _data_s, SizeEigen _delta_s, SizeEigen _delta_cov_s, SizeEigen _calib_s);
}; ///< One instance of the buffered data, corresponding to a particular time stamp.
......
......@@ -12,10 +12,6 @@ Motion::Motion(const TimeStamp& _ts,
const MatrixXd& _jac_delta,
const MatrixXd& _jac_delta_int,
const MatrixXd& _jac_calib) :
data_size_(_data.size()),
delta_size_(_delta.size()),
cov_size_(_delta_cov.cols()),
calib_size_(_jac_calib.cols()),
ts_(_ts),
data_(_data),
data_cov_(_data_cov),
......@@ -34,32 +30,14 @@ Motion::Motion(const TimeStamp& _ts,
SizeEigen _delta_size,
SizeEigen _cov_size,
SizeEigen _calib_size) :
data_size_(_data_size),
delta_size_(_delta_size),
cov_size_(_cov_size),
calib_size_(_calib_size),
ts_(_ts)
{
resize(_data_size, _delta_size, _cov_size, _calib_size);
}
Motion::~Motion()
{
}
void Motion::resize(SizeEigen _data_s, SizeEigen _delta_s, SizeEigen _delta_cov_s, SizeEigen _calib_s)
{
data_.resize(_data_s);
data_cov_.resize(_data_s, _data_s);
delta_.resize(_delta_s);
delta_cov_.resize(_delta_cov_s, _delta_cov_s);
delta_integr_.resize(_delta_s);
delta_integr_cov_.resize(_delta_cov_s, _delta_cov_s);
jacobian_delta_.resize(_delta_cov_s, _delta_cov_s);
jacobian_delta_integr_.resize(_delta_cov_s, _delta_cov_s);
jacobian_calib_.resize(_delta_cov_s, _calib_s);
}
////////////////////////////////////////////////////////////////////////////////////////
MotionBuffer::MotionBuffer()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment