mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-05-03 06:50:58 +00:00
Compare commits
3 Commits
53c8aa25cb
...
0947bffeef
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0947bffeef | ||
|
|
ff34739f40 | ||
|
|
a37f804469 |
@ -30,7 +30,7 @@ http {
|
|||||||
|
|
||||||
gzip on;
|
gzip on;
|
||||||
gzip_comp_level 6;
|
gzip_comp_level 6;
|
||||||
gzip_types text/plain text/css application/json application/x-javascript application/javascript text/javascript image/svg+xml image/x-icon image/bmp image/png image/gif image/jpeg image/jpg;
|
gzip_types text/plain text/css application/json application/x-javascript application/javascript text/javascript image/svg+xml image/x-icon image/bmp;
|
||||||
gzip_proxied no-cache no-store private expired auth;
|
gzip_proxied no-cache no-store private expired auth;
|
||||||
gzip_vary on;
|
gzip_vary on;
|
||||||
|
|
||||||
|
|||||||
@ -10,7 +10,7 @@ from scipy import stats
|
|||||||
|
|
||||||
from frigate.config import FrigateConfig
|
from frigate.config import FrigateConfig
|
||||||
from frigate.const import MODEL_CACHE_DIR
|
from frigate.const import MODEL_CACHE_DIR
|
||||||
from frigate.embeddings.onnx.facenet import ArcfaceEmbedding
|
from frigate.embeddings.onnx.face_embedding import ArcfaceEmbedding
|
||||||
|
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
@ -329,7 +329,7 @@ class ArcFaceRecognizer(FaceRecognizer):
|
|||||||
cosine_similarity = dot_product / (magnitude_A * magnitude_B)
|
cosine_similarity = dot_product / (magnitude_A * magnitude_B)
|
||||||
confidence = self.similarity_to_confidence(cosine_similarity)
|
confidence = self.similarity_to_confidence(cosine_similarity)
|
||||||
|
|
||||||
if cosine_similarity > score:
|
if confidence > score:
|
||||||
score = confidence
|
score = confidence
|
||||||
label = name
|
label = name
|
||||||
|
|
||||||
|
|||||||
@ -90,8 +90,7 @@ class ArcfaceEmbedding(BaseEmbedding):
|
|||||||
frame[y_center : y_center + og_h, x_center : x_center + og_w] = og
|
frame[y_center : y_center + og_h, x_center : x_center + og_w] = og
|
||||||
|
|
||||||
# run arcface normalization
|
# run arcface normalization
|
||||||
normalized_image = frame.astype(np.float32) / 255.0
|
frame = (frame / 127.5) - 1.0
|
||||||
frame = (normalized_image - 0.5) / 0.5
|
|
||||||
|
|
||||||
frame = np.transpose(frame, (2, 0, 1))
|
frame = np.transpose(frame, (2, 0, 1))
|
||||||
frame = np.expand_dims(frame, axis=0)
|
frame = np.expand_dims(frame, axis=0)
|
||||||
@ -11,9 +11,9 @@
|
|||||||
"frigatePlus": "Frigate+ Settings - Frigate"
|
"frigatePlus": "Frigate+ Settings - Frigate"
|
||||||
},
|
},
|
||||||
"menu": {
|
"menu": {
|
||||||
"uiSettings": "UI Settings",
|
"ui": "UI",
|
||||||
"classificationSettings": "Classification Settings",
|
"classification": "Classification",
|
||||||
"cameraSettings": "Camera Settings",
|
"cameras": "Camera Settings",
|
||||||
"masksAndZones": "Masks / Zones",
|
"masksAndZones": "Masks / Zones",
|
||||||
"motionTuner": "Motion Tuner",
|
"motionTuner": "Motion Tuner",
|
||||||
"debug": "Debug",
|
"debug": "Debug",
|
||||||
|
|||||||
@ -11,9 +11,9 @@
|
|||||||
"frigatePlus": "Frigate+ 设置 - Frigate"
|
"frigatePlus": "Frigate+ 设置 - Frigate"
|
||||||
},
|
},
|
||||||
"menu": {
|
"menu": {
|
||||||
"uiSettings": "界面设置",
|
"ui": "界面设置",
|
||||||
"classificationSettings": "分类设置",
|
"classification": "分类设置",
|
||||||
"cameraSettings": "摄像头设置",
|
"cameras": "摄像头设置",
|
||||||
"masksAndZones": "遮罩/ 区域",
|
"masksAndZones": "遮罩/ 区域",
|
||||||
"motionTuner": "运动调整器",
|
"motionTuner": "运动调整器",
|
||||||
"debug": "调试",
|
"debug": "调试",
|
||||||
@ -109,16 +109,16 @@
|
|||||||
"desc": "人脸识别功能允许为人物分配名称,当识别到他们的面孔时,Frigate 会将人物的名字作为子标签进行分配。这些信息会显示在界面、过滤器以及通知中。",
|
"desc": "人脸识别功能允许为人物分配名称,当识别到他们的面孔时,Frigate 会将人物的名字作为子标签进行分配。这些信息会显示在界面、过滤器以及通知中。",
|
||||||
"readTheDocumentation": "阅读文档(英文)",
|
"readTheDocumentation": "阅读文档(英文)",
|
||||||
"modelSize": {
|
"modelSize": {
|
||||||
"label": "模型大小",
|
"label": "模型大小",
|
||||||
"desc": "用于人脸识别的模型尺寸。",
|
"desc": "用于人脸识别的模型尺寸。",
|
||||||
"small": {
|
"small": {
|
||||||
"title": "小模型",
|
"title": "小模型",
|
||||||
"desc": "使用<em>小模型</em>将采用OpenCV的局部二值模式直方图(LBPH)算法,可在大多数CPU上高效运行。"
|
"desc": "使用<em>小模型</em>将采用OpenCV的局部二值模式直方图(LBPH)算法,可在大多数CPU上高效运行。"
|
||||||
},
|
},
|
||||||
"large": {
|
"large": {
|
||||||
"title": "大模型",
|
"title": "大模型",
|
||||||
"desc": "使用<em>大模型</em>将采用ArcFace人脸嵌入模型,若适用将自动在GPU上运行。"
|
"desc": "使用<em>大模型</em>将采用ArcFace人脸嵌入模型,若适用将自动在GPU上运行。"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"licensePlateRecognition": {
|
"licensePlateRecognition": {
|
||||||
@ -565,8 +565,8 @@
|
|||||||
"modelSelect": "您可以在Frigate+上选择可用的模型。请注意,只能选择与当前探测器配置兼容的模型。"
|
"modelSelect": "您可以在Frigate+上选择可用的模型。请注意,只能选择与当前探测器配置兼容的模型。"
|
||||||
},
|
},
|
||||||
"toast": {
|
"toast": {
|
||||||
"success": "Frigate+ 设置已保存。请重启 Frigate 以应用更改。",
|
"success": "Frigate+ 设置已保存。请重启 Frigate 以应用更改。",
|
||||||
"error": "配置更改保存失败:{{errorMessage}}"
|
"error": "配置更改保存失败:{{errorMessage}}"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user