Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
laser_scan_utils
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
labrobotica
algorithms
laser_scan_utils
Commits
cb09614a
Commit
cb09614a
authored
10 months ago
by
Joan Vallvé Navarro
Browse files
Options
Downloads
Patches
Plain Diff
param name changed
parent
2cbcc821
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#18699
passed
10 months ago
Stage: license
Stage: none
Stage: csm
Stage: falko
Stage: csm_falko
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include/laser_scan_utils/icp.h
+3
-3
3 additions, 3 deletions
include/laser_scan_utils/icp.h
src/icp.cpp
+1
-1
1 addition, 1 deletion
src/icp.cpp
test/gtest_icp.cpp
+4
-4
4 additions, 4 deletions
test/gtest_icp.cpp
with
8 additions
and
8 deletions
include/laser_scan_utils/icp.h
+
3
−
3
View file @
cb09614a
...
@@ -42,7 +42,7 @@ namespace laserscanutils
...
@@ -42,7 +42,7 @@ namespace laserscanutils
double
error
;
// Total correspondence error
double
error
;
// Total correspondence error
double
mean_error
;
// Average error (total error / nvalid)
double
mean_error
;
// Average error (total error / nvalid)
double
points_ratio
;
// Ratio of valid correspondences of totall amount of points
double
points_ratio
;
// Ratio of valid correspondences of totall amount of points
unsigned
int
attempts
;
// Number of ICP calls to obtain a valid result (<= params.
icp_
attempts)
unsigned
int
attempts
;
// Number of ICP calls to obtain a valid result (<= params.attempts)
};
};
struct
icpParams
struct
icpParams
...
@@ -127,7 +127,7 @@ namespace laserscanutils
...
@@ -127,7 +127,7 @@ namespace laserscanutils
double
cov_max_eigv_factor
;
// Factor multiplying the direction of the max eigenvalue of the cov output of csm
double
cov_max_eigv_factor
;
// Factor multiplying the direction of the max eigenvalue of the cov output of csm
// Attempts ------------------------------------------------------------------
// Attempts ------------------------------------------------------------------
unsigned
int
icp_
attempts
;
// number of icp attempts if result fails (not valid or error > restart_threshold_mean_error)
unsigned
int
attempts
;
// number of icp attempts if result fails (not valid or error > restart_threshold_mean_error)
double
perturbation_new_attempts
;
// perturbation noise amplitude applied to initial guess in new attempts
double
perturbation_new_attempts
;
// perturbation noise amplitude applied to initial guess in new attempts
// Validation ----------------------------------------------------------------
// Validation ----------------------------------------------------------------
...
@@ -167,7 +167,7 @@ namespace laserscanutils
...
@@ -167,7 +167,7 @@ namespace laserscanutils
std
::
cout
<<
"do_compute_covariance: "
<<
std
::
to_string
(
do_compute_covariance
)
<<
std
::
endl
;
std
::
cout
<<
"do_compute_covariance: "
<<
std
::
to_string
(
do_compute_covariance
)
<<
std
::
endl
;
std
::
cout
<<
"cov_factor: "
<<
std
::
to_string
(
cov_factor
)
<<
std
::
endl
;
std
::
cout
<<
"cov_factor: "
<<
std
::
to_string
(
cov_factor
)
<<
std
::
endl
;
std
::
cout
<<
"cov_max_eigv_factor: "
<<
std
::
to_string
(
cov_max_eigv_factor
)
<<
std
::
endl
;
std
::
cout
<<
"cov_max_eigv_factor: "
<<
std
::
to_string
(
cov_max_eigv_factor
)
<<
std
::
endl
;
std
::
cout
<<
"
icp_
attempts: "
<<
std
::
to_string
(
icp_
attempts
)
<<
std
::
endl
;
std
::
cout
<<
"attempts: "
<<
std
::
to_string
(
attempts
)
<<
std
::
endl
;
std
::
cout
<<
"perturbation_new_attempts: "
<<
std
::
to_string
(
perturbation_new_attempts
)
<<
std
::
endl
;
std
::
cout
<<
"perturbation_new_attempts: "
<<
std
::
to_string
(
perturbation_new_attempts
)
<<
std
::
endl
;
std
::
cout
<<
"max_mean_error: "
<<
std
::
to_string
(
max_mean_error
)
<<
std
::
endl
;
std
::
cout
<<
"max_mean_error: "
<<
std
::
to_string
(
max_mean_error
)
<<
std
::
endl
;
std
::
cout
<<
"min_points_ratio: "
<<
std
::
to_string
(
min_points_ratio
)
<<
std
::
endl
;
std
::
cout
<<
"min_points_ratio: "
<<
std
::
to_string
(
min_points_ratio
)
<<
std
::
endl
;
...
...
This diff is collapsed.
Click to expand it.
src/icp.cpp
+
1
−
1
View file @
cb09614a
...
@@ -208,7 +208,7 @@ icpOutput ICP::align(const LaserScan &_current_ls,
...
@@ -208,7 +208,7 @@ icpOutput ICP::align(const LaserScan &_current_ls,
std
::
cout
<<
"Invalid result, trying again!"
<<
std
::
endl
;
std
::
cout
<<
"Invalid result, trying again!"
<<
std
::
endl
;
}
}
}
while
(
not
result
.
valid
and
result
.
attempts
<
_icp_params
.
icp_
attempts
);
}
while
(
not
result
.
valid
and
result
.
attempts
<
_icp_params
.
attempts
);
// if valid, copy transformation values and grow covariance
// if valid, copy transformation values and grow covariance
if
(
result
.
valid
)
if
(
result
.
valid
)
...
...
This diff is collapsed.
Click to expand it.
test/gtest_icp.cpp
+
4
−
4
View file @
cb09614a
...
@@ -268,7 +268,7 @@ TEST(TestIcp, TestIcpSame1)
...
@@ -268,7 +268,7 @@ TEST(TestIcp, TestIcpSame1)
// icp
// icp
auto
icp_params
=
icp_params_default
;
auto
icp_params
=
icp_params_default
;
icp_params
.
icp_
attempts
=
n_attempts
;
icp_params
.
attempts
=
n_attempts
;
// icp_params.verbose = true;
// icp_params.verbose = true;
// no perturbation
// no perturbation
...
@@ -318,7 +318,7 @@ TEST(TestIcp, TestIcpSame2)
...
@@ -318,7 +318,7 @@ TEST(TestIcp, TestIcpSame2)
LaserScanParams
scan_params
=
generateLaserScanParams
(
0
,
1
);
LaserScanParams
scan_params
=
generateLaserScanParams
(
0
,
1
);
double
pert
=
0.0
;
double
pert
=
0.0
;
auto
icp_params
=
icp_params_default
;
auto
icp_params
=
icp_params_default
;
icp_params
.
icp_
attempts
=
n_attempts
;
icp_params
.
attempts
=
n_attempts
;
for
(
auto
i
=
0
;
i
<
N
;
i
++
)
for
(
auto
i
=
0
;
i
<
N
;
i
++
)
{
{
...
@@ -375,7 +375,7 @@ TEST(TestIcp, TestIcp1)
...
@@ -375,7 +375,7 @@ TEST(TestIcp, TestIcp1)
LaserScan
scan_ref
,
scan_tar
;
LaserScan
scan_ref
,
scan_tar
;
auto
icp_params
=
icp_params_default
;
auto
icp_params
=
icp_params_default
;
icp_params
.
icp_
attempts
=
n_attempts
;
icp_params
.
attempts
=
n_attempts
;
double
pert
=
0.0
;
double
pert
=
0.0
;
...
@@ -421,7 +421,7 @@ TEST(TestIcp, TestIcp10)
...
@@ -421,7 +421,7 @@ TEST(TestIcp, TestIcp10)
LaserScan
scan_ref
,
scan_tar
;
LaserScan
scan_ref
,
scan_tar
;
auto
icp_params
=
icp_params_default
;
auto
icp_params
=
icp_params_default
;
icp_params
.
icp_
attempts
=
n_attempts
;
icp_params
.
attempts
=
n_attempts
;
icp_params
.
verbose
=
true
;
icp_params
.
verbose
=
true
;
double
pert
=
0.0
;
double
pert
=
0.0
;
...
...
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