Keep all OpenCV classifier results (#36294)
This commit is contained in:
parent
22a1452946
commit
a062da05b4
1 changed files with 3 additions and 2 deletions
|
@ -160,6 +160,9 @@ class OpenCVImageProcessor(ImageProcessingEntity):
|
|||
"""Process the image."""
|
||||
cv_image = cv2.imdecode(numpy.asarray(bytearray(image)), cv2.IMREAD_UNCHANGED)
|
||||
|
||||
matches = {}
|
||||
total_matches = 0
|
||||
|
||||
for name, classifier in self._classifiers.items():
|
||||
scale = DEFAULT_SCALE
|
||||
neighbors = DEFAULT_NEIGHBORS
|
||||
|
@ -177,8 +180,6 @@ class OpenCVImageProcessor(ImageProcessingEntity):
|
|||
detections = cascade.detectMultiScale(
|
||||
cv_image, scaleFactor=scale, minNeighbors=neighbors, minSize=min_size
|
||||
)
|
||||
matches = {}
|
||||
total_matches = 0
|
||||
regions = []
|
||||
# pylint: disable=invalid-name
|
||||
for (x, y, w, h) in detections:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue