Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
a37640cd
Commit
a37640cd
authored
Aug 18, 2014
by
Alexander Shishkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update perf_pnp.cpp
parent
3c3d695d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
5 deletions
+11
-5
perf_pnp.cpp
modules/calib3d/perf/perf_pnp.cpp
+11
-5
No files found.
modules/calib3d/perf/perf_pnp.cpp
View file @
a37640cd
...
...
@@ -10,7 +10,7 @@ using namespace perf;
using
std
::
tr1
::
make_tuple
;
using
std
::
tr1
::
get
;
CV_ENUM
(
pnpAlgo
,
SOLVEPNP_ITERATIVE
,
SOLVEPNP_EPNP
,
SOLVEPNP_
DLS
/*, P3P*/
)
CV_ENUM
(
pnpAlgo
,
SOLVEPNP_ITERATIVE
,
SOLVEPNP_EPNP
,
SOLVEPNP_
P3P
,
SOLVEPNP_DLS
)
typedef
std
::
tr1
::
tuple
<
int
,
pnpAlgo
>
PointsNum_Algo_t
;
typedef
perf
::
TestBaseWithParam
<
PointsNum_Algo_t
>
PointsNum_Algo
;
...
...
@@ -20,7 +20,7 @@ typedef perf::TestBaseWithParam<int> PointsNum;
PERF_TEST_P
(
PointsNum_Algo
,
solvePnP
,
testing
::
Combine
(
testing
::
Values
(
4
,
3
*
9
,
7
*
13
),
//TODO: find why results on 4 points are too unstable
testing
::
Values
((
int
)
SOLVEPNP_ITERATIVE
,
(
int
)
SOLVEPNP_EPNP
,
(
int
)
SOLVEPNP_DLS
)
testing
::
Values
((
int
)
SOLVEPNP_ITERATIVE
,
(
int
)
SOLVEPNP_EPNP
)
)
)
{
...
...
@@ -62,9 +62,15 @@ PERF_TEST_P(PointsNum_Algo, solvePnP,
SANITY_CHECK
(
tvec
,
1e-6
);
}
PERF_TEST
(
PointsNum_Algo
,
solveP3P
)
PERF_TEST_P
(
PointsNum_Algo
,
solvePnPSmallPoints
,
testing
::
Combine
(
testing
::
Values
(
4
),
//TODO: find why results on 4 points are too unstable
testing
::
Values
((
int
)
SOLVEPNP_P3P
,
(
int
)
SOLVEPNP_DLS
)
)
)
{
int
pointsNum
=
4
;
int
pointsNum
=
get
<
0
>
(
GetParam
());
pnpAlgo
algo
=
get
<
1
>
(
GetParam
());
vector
<
Point2f
>
points2d
(
pointsNum
);
vector
<
Point3f
>
points3d
(
pointsNum
);
...
...
@@ -94,7 +100,7 @@ PERF_TEST(PointsNum_Algo, solveP3P)
TEST_CYCLE_N
(
1000
)
{
solvePnP
(
points3d
,
points2d
,
intrinsics
,
distortion
,
rvec
,
tvec
,
false
,
SOLVEPNP_P3P
);
solvePnP
(
points3d
,
points2d
,
intrinsics
,
distortion
,
rvec
,
tvec
,
false
,
algo
);
}
SANITY_CHECK
(
rvec
,
1e-6
);
...
...
Write
Preview
Markdown
is supported
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