| | |
| | | } else { |
| | | islink = false |
| | | } |
| | | logger.Info("触发的区域id:",polygonId) |
| | | var labelTypes []int // 0为yolo标签,1为face标签 2为两者标签 |
| | | if sdkNames != "" && len(targets) == 0 { |
| | | args.RuleResult["yolo"] = append(args.RuleResult["yolo"].([]structure.Result), structure.Result{taskId, sdkNames, groupRule.GroupId, groupRule.DefenceState, groupRule.AlarmLevel, groupRule.GroupText, yolos, polygonId, islink,label}) |
| | |
| | | } |
| | | if faceFlag { |
| | | args.RuleResult["face"] = append(args.RuleResult["face"].([]structure.Result), structure.Result{taskId, sdkNames, groupRule.GroupId, groupRule.DefenceState, groupRule.AlarmLevel, groupRule.GroupText, faces, polygonId, islink,label}) |
| | | //logger.Info("-------------------face结果标签", len(args.RuleResult["face"].([]FaceResult))) |
| | | logger.Info("-------------------face结果标签", len(args.RuleResult["face"].([]structure.Result))) |
| | | labelTypes = append(labelTypes,1) |
| | | } |
| | | if len(targets) > 0 { |
| | |
| | | } |
| | | } |
| | | } |
| | | //logger.Println("-----------------------------------------------听说你是空的?",faces) |
| | | return faces |
| | | } |
| | | |
| | |
| | | if len(am.FilterData) > 0 { |
| | | locations = am.FilterData |
| | | } |
| | | //logger.Println("-----------------------------------------------听说你是空的?",faces) |
| | | return locations |
| | | } |
| | | func putTargetsToResult(am *structure.AreaMap) []*structure.Arg { |
| | |
| | | if len(am.AlarmObj) > 0 { |
| | | locations = am.AlarmObj |
| | | } |
| | | //logger.Println("-----------------------------------------------听说你是空的?",faces) |
| | | return locations |
| | | } |
| | | // 联动任务的处理 |