From 9c6fe9b56e15c13749b16414e27f107682995887 Mon Sep 17 00:00:00 2001
From: liuxiaolong <liuxiaolong@aiotlink.com>
Date: 星期二, 28 七月 2020 20:36:19 +0800
Subject: [PATCH] add ret showLabels
---
esutil/EsClient.go | 16 ++++++++++------
1 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/esutil/EsClient.go b/esutil/EsClient.go
index 53a9edd..ffe0ccb 100644
--- a/esutil/EsClient.go
+++ b/esutil/EsClient.go
@@ -135,14 +135,18 @@
if ti.TargetType == "FaceDetect" {
sLabelStr, ok := source["showLabels"]
if ok {
- labelArr := strings.Split(sLabelStr.(string), "/")
- if len(labelArr) == 3 {
- d["gender"] = labelArr[0]
- d["ageDescription"] = labelArr[1]
- d["race"] = labelArr[2]
- }
+ //labelArr := strings.Split(sLabelStr.(string), "/")
+ //if len(labelArr) == 3 {
+ // d["gender"] = labelArr[0]
+ // d["ageDescription"] = labelArr[1]
+ // d["race"] = labelArr[2]
+ //}
+ d["showLabels"] = sLabelStr
+ } else {
+ d["showLabels"] = ""
}
+
if bInfos,ok := source["baseInfo"]; ok && bInfos != nil {
bd := getSourceBaseInfo(bInfos)
fmt.Println("bd:", bd)
--
Gitblit v1.8.0