From e128101563e715f24a9f7059839cfb5c01de1328 Mon Sep 17 00:00:00 2001 From: Jerry Yan <792602257@qq.com> Date: Fri, 28 Mar 2025 14:24:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=BA=E8=84=B8=E6=A3=80=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ycwl/basic/service/task/impl/TaskFaceServiceImpl.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/ycwl/basic/service/task/impl/TaskFaceServiceImpl.java b/src/main/java/com/ycwl/basic/service/task/impl/TaskFaceServiceImpl.java index 1b29ba4..7686820 100644 --- a/src/main/java/com/ycwl/basic/service/task/impl/TaskFaceServiceImpl.java +++ b/src/main/java/com/ycwl/basic/service/task/impl/TaskFaceServiceImpl.java @@ -221,8 +221,7 @@ public class TaskFaceServiceImpl implements TaskFaceService { } } final float _threshold = threshold; - List reject = new ArrayList<>(); - List faceSampleIds = new ArrayList<>(); + List faceSampleIds; try { SearchFaceResponse response = client.getAcsResponse(request); log.fillResponse(response); @@ -272,7 +271,6 @@ public class TaskFaceServiceImpl implements TaskFaceService { if (device != null) { record.setDeviceName(device.getName()); } - record.setMatched(item.getScore() > _threshold); record.setAccept(faceSampleIds.contains(optionalFse.get().getId())); record.setFaceUrl(optionalFse.get().getFaceUrl()); record.setShotDate(optionalFse.get().getCreateAt()); @@ -281,6 +279,7 @@ public class TaskFaceServiceImpl implements TaskFaceService { record.setFaceUrl(getFaceUrl(record.getFaceSampleId())); } record.setScore(item.getScore()); + record.setMatched(item.getScore() > _threshold); record.setConfidence(item.getConfidence()); collect.add(record); }