Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mobile_robotics
wolf_projects
wolf_lib
plugins
apriltag
Commits
49fb5ae7
Commit
49fb5ae7
authored
Jul 27, 2021
by
mederic_fourmy
Browse files
votefor KF slightly modified + install error fixed
parent
b88cc71b
Changes
6
Hide whitespace changes
Inline
Side-by-side
.gitignore
View file @
49fb5ae7
...
...
@@ -34,6 +34,5 @@ test/map_apriltag_save.yaml
build_release/
apriltag.found
apriltagw.found
Testing/Temporary/LastTest.log
Testing/Temporary/CTestCostData.txt
CMakeLists.txt
View file @
49fb5ae7
...
...
@@ -141,7 +141,6 @@ SET(HDRS_CAPTURE
SET
(
HDRS_COMMON
)
SET
(
HDRS_FACTOR
include/core/factor/factor_kf_lmk_pose_3d_with_extrinsics.h
)
SET
(
HDRS_FEATURE
include/apriltag/feature/feature_apriltag.h
...
...
demos/processor_tracker_landmark_apriltag.yaml
View file @
49fb5ae7
...
...
@@ -28,10 +28,10 @@ noise:
std_pix
:
20
# pixel error
vote
:
voting
active
:
true
voting
_
active
:
true
min_time_vote
:
0
# s
max_time_vote
:
0
# s
min_features_for_keyframe
:
12
min_features_for_keyframe
:
12
# does not make sense
nb_vote_for_every_first
:
50
reestimate_last_frame
:
true
# for a better prior on the new keyframe: use only if no motion processor
...
...
src/processor/processor_tracker_landmark_apriltag.cpp
View file @
49fb5ae7
...
...
@@ -335,13 +335,18 @@ bool ProcessorTrackerLandmarkApriltag::voteForKeyFrame() const
double
dt_incoming_origin
=
getIncoming
()
->
getTimeStamp
().
get
()
-
getOrigin
()
->
getTimeStamp
().
get
();
bool
more_than_min_time_vote
=
dt_incoming_origin
>
min_time_vote_
;
bool
too_long_since_last_KF
=
dt_incoming_origin
>
max_time_vote_
;
bool
enough_features_in_last
=
detections_last_
.
size
()
>=
min_features_for_keyframe_
;
bool
enough_features_in_incoming
=
detections_incoming_
.
size
()
>=
min_features_for_keyframe_
;
// no detection in incoming capture and a minimum time since last KF has past
if
(
enough_features_in_last
and
!
enough_features_in_incoming
and
more_than_min_time_vote
)
return
true
;
// the elapsed time since last KF is too long
if
(
too_long_since_last_KF
){
if
(
enough_features_in_last
and
too_long_since_last_KF
){
return
true
;
}
// no detection in incoming capture and a minimum time since last KF has past
if
((
detections_incoming_
.
size
()
<
min_features_for_keyframe_
)
and
more_than_min_time_vote
)
return
true
;
// Vote for every image processed at the beginning if possible
if
(
nb_vote_
<
nb_vote_for_every_first_
){
...
...
src/yaml/processor_tracker_landmark_apriltag_yaml.cpp
View file @
49fb5ae7
...
...
@@ -62,7 +62,7 @@ static ParamsProcessorBasePtr createParamsProcessorLandmarkApriltag(const std::s
params
->
std_pix_
=
noise
[
"std_pix"
]
.
as
<
double
>
();
YAML
::
Node
vote
=
config
[
"vote"
];
params
->
voting_active
=
vote
[
"voting
active"
]
.
as
<
bool
>
();
params
->
voting_active
=
vote
[
"voting
_
active"
]
.
as
<
bool
>
();
params
->
min_time_vote_
=
vote
[
"min_time_vote"
]
.
as
<
double
>
();
params
->
max_time_vote_
=
vote
[
"max_time_vote"
]
.
as
<
double
>
();
params
->
min_features_for_keyframe
=
vote
[
"min_features_for_keyframe"
]
.
as
<
unsigned
int
>
();
...
...
test/processor_tracker_landmark_apriltag.yaml
View file @
49fb5ae7
...
...
@@ -28,10 +28,10 @@ noise:
std_pix
:
20
# pixel error
vote
:
voting
active
:
true
voting
_
active
:
true
min_time_vote
:
0
# s
max_time_vote
:
0
# s
min_features_for_keyframe
:
12
min_features_for_keyframe
:
12
# no sense
nb_vote_for_every_first
:
50
reestimate_last_frame
:
true
# for a better prior on the new keyframe: use only if no motion processor
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment