Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
Navigation
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
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
Software
ArmarX
Skills
Navigation
Commits
89a5ac04
Commit
89a5ac04
authored
2 years ago
by
Timo Weberruß
Browse files
Options
Downloads
Patches
Plain Diff
Fix unit test dependency
parent
008820ca
No related branches found
No related tags found
2 merge requests
!109
Social layers
,
!55
Draft: Implement human grouping
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
source/armarx/navigation/human/CMakeLists.txt
+2
-0
2 additions, 0 deletions
source/armarx/navigation/human/CMakeLists.txt
source/armarx/navigation/human/test/human_test.cpp
+19
-15
19 additions, 15 deletions
source/armarx/navigation/human/test/human_test.cpp
with
21 additions
and
15 deletions
source/armarx/navigation/human/CMakeLists.txt
+
2
−
0
View file @
89a5ac04
...
...
@@ -23,6 +23,7 @@ armarx_add_library(teb_human
CombinedDistance.cpp
ConvexHullGenerator.cpp
MovementDistance.cpp
HEADERS
types.h
aron_conversions.h
...
...
@@ -47,6 +48,7 @@ armarx_add_test(human_test
PUBLIC
ArmarXCore
armarx_navigation::core
armarx_navigation::human
PRIVATE
range-v3::range-v3
...
...
This diff is collapsed.
Click to expand it.
source/armarx/navigation/human/test/human_test.cpp
+
19
−
15
View file @
89a5ac04
...
...
@@ -38,6 +38,7 @@
#include
<armarx/navigation/Test.h>
#include
<armarx/navigation/core/basic_types.h>
#include
<armarx/navigation/human/Test.h>
#include
<armarx/navigation/human/types.h>
using
armarx
::
navigation
::
core
::
Pose2D
;
...
...
@@ -46,21 +47,24 @@ using armarx::navigation::human::Human;
BOOST_AUTO_TEST_CASE
(
testEuclideanDistance
)
{
// EuclideanDistance distance = EuclideanDistance();
// Pose2D pose1 = Pose2D::Identity();
// pose1.translation() = Eigen::Vector2f(3, 4);
// pose1.linear() = Eigen::Rotation2Df(1.1).toRotationMatrix();
// Human h1 = {.pose = pose1,
// .linearVelocity = Eigen::Vector2f(0.2, 0.1),
// .detectionTime = armarx::DateTime::Now()};
// Pose2D pose2 = Pose2D::Identity();
// pose2.translation() = Eigen::Vector2f(6, 8);
// pose2.linear() = Eigen::Rotation2Df(2.3).toRotationMatrix();
// Human h2 = {.pose = pose2,
// .linearVelocity = Eigen::Vector2f(0.5, 0.8),
// .detectionTime = armarx::DateTime::Now()};
const
EuclideanDistance
distance
=
EuclideanDistance
();
Pose2D
pose1
=
Pose2D
::
Identity
();
pose1
.
translation
()
=
Eigen
::
Vector2f
(
3
,
4
);
pose1
.
linear
()
=
Eigen
::
Rotation2Df
(
1.1
).
toRotationMatrix
();
const
Human
h1
=
{.
pose
=
pose1
,
.
linearVelocity
=
Eigen
::
Vector2f
(
0.2
,
0.1
),
.
detectionTime
=
armarx
::
DateTime
::
Now
()};
Pose2D
pose2
=
Pose2D
::
Identity
();
pose2
.
translation
()
=
Eigen
::
Vector2f
(
6
,
8
);
pose2
.
linear
()
=
Eigen
::
Rotation2Df
(
2.3
).
toRotationMatrix
();
const
Human
h2
=
{.
pose
=
pose2
,
.
linearVelocity
=
Eigen
::
Vector2f
(
0.5
,
0.8
),
.
detectionTime
=
armarx
::
DateTime
::
Now
()};
double
d
=
distance
.
computeDistance
(
h1
,
h2
);
ARMARX_INFO
<<
"Distance is"
+
std
::
to_string
(
d
);
BOOST_CHECK_CLOSE
(
d
,
4
,
0.001
);
}
//BOOST_AUTO_TEST_CASE(testPathLength)
...
...
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