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
89af053a
Commit
89af053a
authored
May 29, 2017
by
Vadim Pisarevsky
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #8797 from sovrasov:hog_sse_fix
parents
c397361a
6c164d86
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
hog.cpp
modules/objdetect/src/hog.cpp
+8
-2
No files found.
modules/objdetect/src/hog.cpp
View file @
89af053a
...
...
@@ -325,8 +325,14 @@ void HOGDescriptor::computeGradient(const Mat& img, Mat& grad, Mat& qangle,
#if CV_SSE2
__m128i
ithree
=
_mm_set1_epi32
(
3
);
for
(
;
x
<=
end
-
4
;
x
+=
4
)
_mm_storeu_si128
((
__m128i
*
)(
xmap
+
x
),
_mm_mullo_epi16
(
ithree
,
_mm_loadu_si128
((
const
__m128i
*
)(
xmap
+
x
))));
{
//emulation of _mm_mullo_epi32
__m128i
mul_res
=
_mm_loadu_si128
((
const
__m128i
*
)(
xmap
+
x
));
__m128i
tmp1
=
_mm_mul_epu32
(
ithree
,
mul_res
);
__m128i
tmp2
=
_mm_mul_epu32
(
_mm_srli_si128
(
ithree
,
4
),
_mm_srli_si128
(
mul_res
,
4
));
mul_res
=
_mm_unpacklo_epi32
(
_mm_shuffle_epi32
(
tmp1
,
_MM_SHUFFLE
(
0
,
0
,
2
,
0
)),
_mm_shuffle_epi32
(
tmp2
,
_MM_SHUFFLE
(
0
,
0
,
2
,
0
)));
_mm_storeu_si128
((
__m128i
*
)(
xmap
+
x
),
mul_res
);
}
#elif CV_NEON
int32x4_t
ithree
=
vdupq_n_s32
(
3
);
for
(
;
x
<=
end
-
4
;
x
+=
4
)
...
...
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