From 5768edb3a5ac192727f6d14cb76c5eab2e06be7e Mon Sep 17 00:00:00 2001 From: Manav Rathi Date: Tue, 21 May 2024 11:15:52 +0530 Subject: [PATCH] Thank you Laurens! --- web/apps/photos/src/services/face/f-index.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/web/apps/photos/src/services/face/f-index.ts b/web/apps/photos/src/services/face/f-index.ts index 53f2c41db9..fa2ad69fa7 100644 --- a/web/apps/photos/src/services/face/f-index.ts +++ b/web/apps/photos/src/services/face/f-index.ts @@ -220,8 +220,16 @@ const convertToYOLOInputFloat32ChannelsFirst = (imageBitmap: ImageBitmap) => { * * Only detections that exceed a minimum score are returned. * - * @param rows A Float32Array of shape [25200, 16], where each row - * represents a bounding box. + * @param rows A Float32Array of shape [25200, 16], where each row represents a + * face detection. + * + * YOLO detects a fixed number of faces, 25200, always from the input it is + * given. Each detection is a "row" of 16 bytes, containing the bounding box, + * score, and landmarks of the detection. + * + * We prune out detections with a score lower than our threshold. However, we + * will still be left with some overlapping detections of the same face: these + * we will deduplicate in {@link removeDuplicateDetections}. */ const filterExtractDetectionsFromYOLOOutput = ( rows: Float32Array,