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
9ca45dab
Commit
9ca45dab
authored
Apr 29, 2011
by
Vadim Pisarevsky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed couple of integral-related bugs
parent
8da63785
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
6 deletions
+7
-6
sumpixels.cpp
modules/imgproc/src/sumpixels.cpp
+1
-1
test_filter.cpp
modules/imgproc/test/test_filter.cpp
+5
-4
cascadedetect.cpp
modules/objdetect/src/cascadedetect.cpp
+1
-1
No files found.
modules/imgproc/src/sumpixels.cpp
View file @
9ca45dab
...
...
@@ -214,7 +214,7 @@ void integral_##suffix( T* src, size_t srcstep, ST* sum, size_t sumstep, QT* sqs
DEF_INTEGRAL_FUNC
(
8u32
s
,
uchar
,
int
,
double
)
DEF_INTEGRAL_FUNC
(
8u32
f
,
uchar
,
float
,
double
)
DEF_INTEGRAL_FUNC
(
8u64
f
,
uchar
,
double
,
double
)
DEF_INTEGRAL_FUNC
(
32
f
,
float
,
float
,
float
)
DEF_INTEGRAL_FUNC
(
32
f
,
float
,
float
,
double
)
DEF_INTEGRAL_FUNC
(
32
f64f
,
float
,
double
,
double
)
DEF_INTEGRAL_FUNC
(
64
f
,
double
,
double
,
double
)
...
...
modules/imgproc/test/test_filter.cpp
View file @
9ca45dab
...
...
@@ -1576,7 +1576,7 @@ CV_IntegralTest::CV_IntegralTest()
test_array
[
REF_OUTPUT
].
push_back
(
NULL
);
test_array
[
REF_OUTPUT
].
push_back
(
NULL
);
test_array
[
REF_OUTPUT
].
push_back
(
NULL
);
element_wise_relative_error
=
fals
e
;
element_wise_relative_error
=
tru
e
;
}
...
...
@@ -1603,7 +1603,8 @@ void CV_IntegralTest::get_test_array_types_and_sizes( int test_case_idx,
depth
=
depth
==
0
?
CV_8U
:
CV_32F
;
cn
+=
cn
==
2
;
sum_depth
=
depth
==
CV_8U
&&
(
cvtest
::
randInt
(
rng
)
&
1
)
==
1
?
CV_32S
:
CV_64F
;
int
b
=
(
cvtest
::
randInt
(
rng
)
&
1
)
!=
0
;
sum_depth
=
depth
==
CV_8U
&&
b
?
CV_32S
:
b
?
CV_32F
:
CV_64F
;
types
[
INPUT
][
0
]
=
CV_MAKETYPE
(
depth
,
cn
);
types
[
OUTPUT
][
0
]
=
types
[
REF_OUTPUT
][
0
]
=
...
...
@@ -1626,10 +1627,10 @@ void CV_IntegralTest::get_test_array_types_and_sizes( int test_case_idx,
}
double
CV_IntegralTest
::
get_success_error_level
(
int
/*test_case_idx*/
,
int
i
,
int
j
)
double
CV_IntegralTest
::
get_success_error_level
(
int
,
int
i
,
int
j
)
{
int
depth
=
test_mat
[
i
][
j
].
depth
();
return
depth
==
CV_32S
?
0
:
FLT_EPSILON
;
return
depth
==
CV_32S
?
0
:
depth
==
CV_64F
?
FLT_EPSILON
:
5e-3
;
}
...
...
modules/objdetect/src/cascadedetect.cpp
View file @
9ca45dab
...
...
@@ -622,7 +622,7 @@ bool HaarEvaluator::setImage( const Mat &image, Size _origWinSize )
tilted0
.
create
(
rn
,
cn
,
CV_32S
);
}
sum
=
Mat
(
rn
,
cn
,
CV_32S
,
sum0
.
data
);
sqsum
=
Mat
(
rn
,
cn
,
CV_
32S
,
sqsum0
.
data
);
sqsum
=
Mat
(
rn
,
cn
,
CV_
64F
,
sqsum0
.
data
);
if
(
hasTiltedFeatures
)
{
...
...
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