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
84176fa0
Commit
84176fa0
authored
Oct 12, 2012
by
Kirill Kornyakov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added perf test for warpPerpsective with large resolutions
parent
fa368d62
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
46 additions
and
0 deletions
+46
-0
perf_warp.cpp
modules/imgproc/perf/perf_warp.cpp
+44
-0
ts_perf.hpp
modules/ts/include/opencv2/ts/ts_perf.hpp
+2
-0
No files found.
modules/imgproc/perf/perf_warp.cpp
View file @
84176fa0
...
@@ -80,6 +80,50 @@ PERF_TEST_P( TestWarpPerspective, WarpPerspective,
...
@@ -80,6 +80,50 @@ PERF_TEST_P( TestWarpPerspective, WarpPerspective,
SANITY_CHECK
(
dst
);
SANITY_CHECK
(
dst
);
}
}
PERF_TEST_P
(
TestWarpPerspective
,
WarpPerspectiveLarge
,
Combine
(
Values
(
sz3MP
,
sz5MP
),
ValuesIn
(
InterType
::
all
()
),
ValuesIn
(
BorderMode
::
all
()
)
)
)
{
Size
sz
;
int
borderMode
,
interType
;
sz
=
get
<
0
>
(
GetParam
());
borderMode
=
get
<
1
>
(
GetParam
());
interType
=
get
<
2
>
(
GetParam
());
string
resolution
;
if
(
sz
==
sz3MP
)
resolution
=
"3MP"
;
else
if
(
sz
==
sz5MP
)
resolution
=
"5MP"
;
else
FAIL
();
Mat
src
,
img
=
imread
(
getDataPath
(
"cv/shared/"
+
resolution
+
".png"
));
cvtColor
(
img
,
src
,
COLOR_BGR2BGRA
,
4
);
int
shift
=
103
;
Mat
srcVertices
=
(
Mat_
<
Vec2f
>
(
1
,
4
)
<<
Vec2f
(
0
,
0
),
Vec2f
(
sz
.
width
-
1
,
0
),
Vec2f
(
sz
.
width
-
1
,
sz
.
height
-
1
),
Vec2f
(
0
,
sz
.
height
-
1
));
Mat
dstVertices
=
(
Mat_
<
Vec2f
>
(
1
,
4
)
<<
Vec2f
(
0
,
shift
),
Vec2f
(
sz
.
width
-
shift
/
2
,
0
),
Vec2f
(
sz
.
width
-
shift
,
sz
.
height
-
shift
),
Vec2f
(
shift
/
2
,
sz
.
height
-
1
));
Mat
warpMat
=
getPerspectiveTransform
(
srcVertices
,
dstVertices
);
Mat
dst
(
sz
,
CV_8UC4
);
declare
.
in
(
src
).
out
(
dst
);
TEST_CYCLE
()
warpPerspective
(
src
,
dst
,
warpMat
,
sz
,
interType
,
borderMode
,
Scalar
::
all
(
150
)
);
SANITY_CHECK
(
dst
);
imwrite
(
"/home/kir/temp/dst"
+
resolution
+
".png"
,
dst
);
}
PERF_TEST_P
(
TestRemap
,
remap
,
PERF_TEST_P
(
TestRemap
,
remap
,
Combine
(
Combine
(
Values
(
TYPICAL_MAT_TYPES
),
Values
(
TYPICAL_MAT_TYPES
),
...
...
modules/ts/include/opencv2/ts/ts_perf.hpp
View file @
84176fa0
...
@@ -49,6 +49,8 @@ const cv::Size sz1440p = szWQHD;
...
@@ -49,6 +49,8 @@ const cv::Size sz1440p = szWQHD;
const
cv
::
Size
sz2160p
=
cv
::
Size
(
3840
,
2160
);
//UHDTV1 4K
const
cv
::
Size
sz2160p
=
cv
::
Size
(
3840
,
2160
);
//UHDTV1 4K
const
cv
::
Size
sz4320p
=
cv
::
Size
(
7680
,
4320
);
//UHDTV2 8K
const
cv
::
Size
sz4320p
=
cv
::
Size
(
7680
,
4320
);
//UHDTV2 8K
const
cv
::
Size
sz3MP
=
cv
::
Size
(
2048
,
1536
);
const
cv
::
Size
sz5MP
=
cv
::
Size
(
2592
,
1944
);
const
cv
::
Size
sz2K
=
cv
::
Size
(
2048
,
2048
);
const
cv
::
Size
sz2K
=
cv
::
Size
(
2048
,
2048
);
const
cv
::
Size
szODD
=
cv
::
Size
(
127
,
61
);
const
cv
::
Size
szODD
=
cv
::
Size
(
127
,
61
);
...
...
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