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
cb63046d
Commit
cb63046d
authored
Jan 17, 2011
by
Anatoly Baksheev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gpu face detetcion:
1) fixed bug with error codes (enum NppStStatus) shift. 2) added some asserts
parent
6f87567e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
9 deletions
+11
-9
npp_staging.h
3rdparty/NPP_staging/npp_staging.h
+8
-8
cascadeclassifier.cpp
modules/gpu/src/cascadeclassifier.cpp
+2
-0
cascadeclassifier.cpp
samples/gpu/cascadeclassifier.cpp
+1
-1
No files found.
3rdparty/NPP_staging/npp_staging.h
View file @
cb63046d
...
...
@@ -188,14 +188,14 @@ struct NppStSize32u
enum
NppStStatus
{
//already present in NPP
//
NPP_SUCCESS = 0, ///< Successful operation (same as NPP_NO_ERROR)
//
NPP_ERROR = -1, ///< Unknown error
//
NPP_CUDA_KERNEL_EXECUTION_ERROR = -3, ///< CUDA kernel execution error
//
NPP_NULL_POINTER_ERROR = -4, ///< NULL pointer argument error
//
NPP_TEXTURE_BIND_ERROR = -24, ///< CUDA texture binding error or non-zero offset returned
//
NPP_MEMCPY_ERROR = -13, ///< CUDA memory copy error
//
NPP_MEM_ALLOC_ERR = -12, ///< CUDA memory allocation error
//
NPP_MEMFREE_ERR = -15, ///< CUDA memory deallocation error
__
NPP_SUCCESS
=
0
,
///< Successful operation (same as NPP_NO_ERROR)
__
NPP_ERROR
=
-
1
,
///< Unknown error
__
NPP_CUDA_KERNEL_EXECUTION_ERROR
=
-
3
,
///< CUDA kernel execution error
__
NPP_NULL_POINTER_ERROR
=
-
4
,
///< NULL pointer argument error
__
NPP_TEXTURE_BIND_ERROR
=
-
24
,
///< CUDA texture binding error or non-zero offset returned
__
NPP_MEMCPY_ERROR
=
-
13
,
///< CUDA memory copy error
__
NPP_MEM_ALLOC_ERR
=
-
12
,
///< CUDA memory allocation error
__
NPP_MEMFREE_ERR
=
-
15
,
///< CUDA memory deallocation error
//to be added
NPP_INVALID_ROI
,
///< Invalid region of interest argument
...
...
modules/gpu/src/cascadeclassifier.cpp
View file @
cb63046d
...
...
@@ -89,6 +89,7 @@ struct cv::gpu::CascadeClassifier_GPU::CascadeClassifierImpl
src_seg
.
size
=
src
.
step
*
src
.
rows
;
NCVMatrixReuse
<
Ncv8u
>
d_src
(
src_seg
,
devProp
.
textureAlignment
,
src
.
cols
,
src
.
rows
,
src
.
step
,
true
);
ncvAssertReturn
(
d_src
.
isMemReused
(),
NCV_ALLOCATOR_BAD_REUSE
);
//NCVMatrixAlloc<Ncv8u> d_src(*gpuAllocator, src.cols, src.rows);
//ncvAssertReturn(d_src.isMemAllocated(), NCV_ALLOCATOR_BAD_ALLOC);
...
...
@@ -106,6 +107,7 @@ struct cv::gpu::CascadeClassifier_GPU::CascadeClassifierImpl
objects_seg
.
begin
=
objects_beg
;
objects_seg
.
size
=
objects
.
step
*
objects
.
rows
;
NCVVectorReuse
<
NcvRect32u
>
d_rects
(
objects_seg
,
objects
.
cols
);
ncvAssertReturn
(
d_rects
.
isMemReused
(),
NCV_ALLOCATOR_BAD_REUSE
);
//NCVVectorAlloc<NcvRect32u> d_rects(*gpuAllocator, 100);
//ncvAssertReturn(d_rects.isMemAllocated(), NCV_ALLOCATOR_BAD_ALLOC);
...
...
samples/gpu/cascadeclassifier.cpp
View file @
cb63046d
...
...
@@ -84,7 +84,7 @@ int main( int argc, const char** argv )
/* parameters */
bool
useGPU
=
true
;
double
scale_factor
=
2
;
double
scale_factor
=
1
;
bool
visualizeInPlace
=
false
;
bool
findLargestObject
=
false
;
...
...
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