panlei
2019-11-13 7e71b19cab380b069e0270c11b81294145a51e5f
insertdata/insertDataToEs.go
@@ -76,7 +76,7 @@
type Target struct {
   TargetId       string  `json:"targetId"`
   TargetScore    float64 `json:"targetScore"`
   TargetLocation Points
   TargetLocation Points  `json:"targetLocation"`
}
type Points struct {
@@ -85,8 +85,8 @@
}
type Point struct {
   Lat float64 `json:"lat"`
   Lon float64 `json:"lon"`
   X float64 `json:"x"`
   Y float64 `json:"y"`
}
//  yolo行为的数据结构
@@ -249,7 +249,7 @@
            if err1 != nil {
               logger.Error("上传ES出错!---", err1)
            } else {
               logger.Info("插入es返回的信息:", resp1)
               logger.Info("插入es返回的信息(人脸):", resp1)
               // 发出录像信号
               ruleserver.AddLxMessage(&protomsg.VideotapeInfo{EsDataId: msg.Push.PushId, CameraId: msg.Cid, TaskId: msg.Tasklab.Taskid, VideoUrl: msg.Push.VideoUrl, ImgId: i.Id, SdkIds: []string{}, Type: 1})
            }
@@ -451,7 +451,7 @@
            if err2 != nil {
               logger.Error("往ES插入数据失败", err)
            } else {
               logger.Debug("插入es返回的数据信息是:", resp1)
               logger.Debug("插入es返回的数据信息是(yolo):", resp1)
               // 发出录像信号
               ruleserver.AddLxMessage(&protomsg.VideotapeInfo{EsDataId: msg.Push.PushId, CameraId: msg.Cid, TaskId: msg.Tasklab.Taskid, VideoUrl: msg.Push.VideoUrl, ImgId: i.Id, SdkIds: []string{}, Type: 2})
               logger.Warn("__________________________________________往ES插入yolo数据成功")