Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
imu
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mobile_robotics
wolf_projects
wolf_lib
plugins
imu
Commits
263cb1e1
Commit
263cb1e1
authored
4 weeks ago
by
cont-integration
Browse files
Options
Downloads
Patches
Plain Diff
[skip ci] applied clang format
parent
8afb7294
No related branches found
No related tags found
1 merge request
!49
Draft: Resolve "Adapt to new sensor constructors in core"
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
include/imu/processor/processor_imu_3d.h
+15
-15
15 additions, 15 deletions
include/imu/processor/processor_imu_3d.h
src/processor/processor_imu_3d.cpp
+17
-17
17 additions, 17 deletions
src/processor/processor_imu_3d.cpp
with
32 additions
and
32 deletions
include/imu/processor/processor_imu_3d.h
+
15
−
15
View file @
263cb1e1
...
...
@@ -54,36 +54,36 @@ class ProcessorImu3d : public ProcessorMotion
const
Eigen
::
MatrixXd
&
_data_cov
,
const
Eigen
::
VectorXd
&
_calib
,
const
double
_dt
,
Eigen
::
VectorXd
&
_delta
,
Eigen
::
MatrixXd
&
_delta_cov
,
Eigen
::
MatrixXd
&
_jacobian_calib
)
const
override
;
Eigen
::
VectorXd
&
_delta
,
Eigen
::
MatrixXd
&
_delta_cov
,
Eigen
::
MatrixXd
&
_jacobian_calib
)
const
override
;
void
deltaPlusDelta
(
const
Eigen
::
VectorXd
&
_delta_preint
,
const
Eigen
::
VectorXd
&
_delta
,
const
double
_dt
,
Eigen
::
VectorXd
&
_delta_preint_plus_delta
)
const
override
;
Eigen
::
VectorXd
&
_delta_preint_plus_delta
)
const
override
;
void
deltaPlusDelta
(
const
Eigen
::
VectorXd
&
_delta_preint
,
const
Eigen
::
VectorXd
&
_delta
,
const
double
_dt
,
Eigen
::
VectorXd
&
_delta_preint_plus_delta
,
Eigen
::
MatrixXd
&
_jacobian_delta_preint
,
Eigen
::
MatrixXd
&
_jacobian_delta
)
const
override
;
Eigen
::
VectorXd
&
_delta_preint_plus_delta
,
Eigen
::
MatrixXd
&
_jacobian_delta_preint
,
Eigen
::
MatrixXd
&
_jacobian_delta
)
const
override
;
void
statePlusDelta
(
const
VectorComposite
&
_x
,
const
Eigen
::
VectorXd
&
_delta
,
const
double
_Dt
,
VectorComposite
&
_x_plus_delta
)
const
override
;
VectorComposite
&
_x_plus_delta
)
const
override
;
Eigen
::
VectorXd
deltaZero
()
const
override
;
Eigen
::
VectorXd
correctDelta
(
const
Eigen
::
VectorXd
&
delta_preint
,
const
Eigen
::
VectorXd
&
delta_step
)
const
override
;
VectorXd
getCalibration
(
const
CaptureBaseConstPtr
_capture
=
nullptr
)
const
override
;
void
setCalibration
(
const
CaptureBasePtr
_capture
,
const
VectorXd
&
_calibration
)
override
;
bool
voteForKeyFrame
()
const
override
;
CaptureMotionPtr
emplaceCapture
(
const
FrameBasePtr
&
_frame_own
,
const
SensorBasePtr
&
_sensor
,
const
TimeStamp
&
_ts
,
const
VectorXd
&
_data
,
const
MatrixXd
&
_data_cov
,
const
VectorXd
&
_calib
,
const
VectorXd
&
_calib_preint
,
CaptureMotionPtr
emplaceCapture
(
const
FrameBasePtr
&
_frame_own
,
const
SensorBasePtr
&
_sensor
,
const
TimeStamp
&
_ts
,
const
VectorXd
&
_data
,
const
MatrixXd
&
_data_cov
,
const
VectorXd
&
_calib
,
const
VectorXd
&
_calib_preint
,
const
CaptureBasePtr
&
_capture_origin
)
override
;
virtual
void
emplaceFeaturesAndFactors
(
CaptureBasePtr
_capture_origin
,
CaptureMotionPtr
_capture_own
)
override
;
...
...
This diff is collapsed.
Click to expand it.
src/processor/processor_imu_3d.cpp
+
17
−
17
View file @
263cb1e1
...
...
@@ -100,13 +100,13 @@ bool ProcessorImu3d::voteForKeyFrame() const
return
false
;
}
CaptureMotionPtr
ProcessorImu3d
::
emplaceCapture
(
const
FrameBasePtr
&
_frame_own
,
const
SensorBasePtr
&
_sensor
,
const
TimeStamp
&
_ts
,
const
VectorXd
&
_data
,
const
MatrixXd
&
_data_cov
,
const
VectorXd
&
_calib
,
const
VectorXd
&
_calib_preint
,
CaptureMotionPtr
ProcessorImu3d
::
emplaceCapture
(
const
FrameBasePtr
&
_frame_own
,
const
SensorBasePtr
&
_sensor
,
const
TimeStamp
&
_ts
,
const
VectorXd
&
_data
,
const
MatrixXd
&
_data_cov
,
const
VectorXd
&
_calib
,
const
VectorXd
&
_calib_preint
,
const
CaptureBasePtr
&
_capture_origin
)
{
auto
cap_motion
=
std
::
static_pointer_cast
<
CaptureMotion
>
(
...
...
@@ -178,9 +178,9 @@ void ProcessorImu3d::computeCurrentDelta(const Eigen::VectorXd &_data,
const
Eigen
::
MatrixXd
&
_data_cov
,
const
Eigen
::
VectorXd
&
_calib
,
const
double
_dt
,
Eigen
::
VectorXd
&
_delta
,
Eigen
::
MatrixXd
&
_delta_cov
,
Eigen
::
MatrixXd
&
_jac_delta_calib
)
const
Eigen
::
VectorXd
&
_delta
,
Eigen
::
MatrixXd
&
_delta_cov
,
Eigen
::
MatrixXd
&
_jac_delta_calib
)
const
{
assert
(
_data
.
size
()
==
data_size_
&&
"Wrong data size!"
);
...
...
@@ -219,7 +219,7 @@ void ProcessorImu3d::computeCurrentDelta(const Eigen::VectorXd &_data,
void
ProcessorImu3d
::
deltaPlusDelta
(
const
Eigen
::
VectorXd
&
_delta_preint
,
const
Eigen
::
VectorXd
&
_delta
,
const
double
_dt
,
Eigen
::
VectorXd
&
_delta_preint_plus_delta
)
const
Eigen
::
VectorXd
&
_delta_preint_plus_delta
)
const
{
/* MATHS according to Sola-16
* Dp' = Dp + Dv*dt + 1/2*Dq*(a-a_b)*dt^2 = Dp + Dv*dt + Dq*dp if dp =
...
...
@@ -236,7 +236,7 @@ void ProcessorImu3d::deltaPlusDelta(const Eigen::VectorXd &_delta_preint,
void
ProcessorImu3d
::
statePlusDelta
(
const
VectorComposite
&
_x
,
const
Eigen
::
VectorXd
&
_delta
,
const
double
_dt
,
VectorComposite
&
_x_plus_delta
)
const
VectorComposite
&
_x_plus_delta
)
const
{
assert
(
_delta
.
size
()
==
10
&&
"Wrong _delta vector size"
);
assert
(
_dt
>=
0
&&
"Time interval _dt is negative!"
);
...
...
@@ -256,9 +256,9 @@ void ProcessorImu3d::statePlusDelta(const VectorComposite &_x,
void
ProcessorImu3d
::
deltaPlusDelta
(
const
Eigen
::
VectorXd
&
_delta_preint
,
const
Eigen
::
VectorXd
&
_delta
,
const
double
_dt
,
Eigen
::
VectorXd
&
_delta_preint_plus_delta
,
Eigen
::
MatrixXd
&
_jacobian_delta_preint
,
Eigen
::
MatrixXd
&
_jacobian_delta
)
const
Eigen
::
VectorXd
&
_delta_preint_plus_delta
,
Eigen
::
MatrixXd
&
_jacobian_delta_preint
,
Eigen
::
MatrixXd
&
_jacobian_delta
)
const
{
/*
* Expression of the delta integration step, D' = D (+) d:
...
...
@@ -530,8 +530,8 @@ bool ProcessorImu3d::recomputeStates() const
const
auto
&
cap_origin
=
cap
->
getOriginCapture
();
const
auto
&
frm_origin
=
cap_origin
->
getFrame
();
const
auto
&
delta
=
VectorComposite
({{
'P'
,
ftr
->
getMeasurement
().
head
<
3
>
()},
{
'O'
,
ftr
->
getMeasurement
().
segment
<
4
>
(
3
)},
{
'V'
,
ftr
->
getMeasurement
().
tail
<
3
>
()}});
{
'O'
,
ftr
->
getMeasurement
().
segment
<
4
>
(
3
)},
{
'V'
,
ftr
->
getMeasurement
().
tail
<
3
>
()}});
const
auto
&
x_origin
=
frm_origin
->
getState
();
auto
dt
=
cap
->
getTimeStamp
()
-
cap_origin
->
getTimeStamp
();
auto
x
=
imu
::
composeOverState
(
x_origin
,
delta
,
dt
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment