Intelligent perimeter detection method and equipment

文档序号:191406 发布日期:2021-11-02 浏览:22次 中文

阅读说明:本技术 一种智能周界检测的方法和设备 (Intelligent perimeter detection method and equipment ) 是由 王家超 褚洪涛 宋志豪 陈维国 元方 张凡超 于 2021-07-16 设计创作,主要内容包括:本发明提供了一种智能周界检测的方法和设备,涉及人工智能和探测设备技术领域。该方法包括:收集授权人的证件照片作为授权数据库;利用训练后的计算机视觉识别模型,对数据库中的照片进行特征提取,获取识别到的人脸码;存储获取的人脸特征码;接入天然气无人值守站的监控视频;使用RTSP协议采集视频流,对视频进行图像分帧处理;识别到人脸后,提取人脸图片和授权数据库进行相似度匹配,对不匹配的情况记录入侵次数;设定入侵次数的阈值,根据模型检测人脸的准确率与每秒编码视频到图片帧的次数综合设计。利用该方法对边界环境进行监控,设备包括视频监控和计算机,解决了检测连续时间序列图片中间断性检测出错的问题。(The invention provides an intelligent perimeter detection method and equipment, and relates to the technical field of artificial intelligence and detection equipment. The method comprises the following steps: collecting certificate photos of an authorizer as an authorization database; carrying out feature extraction on the photos in the database by using the trained computer vision recognition model to obtain recognized face codes; storing the acquired face feature codes; accessing a monitoring video of the natural gas unattended station; collecting a video stream by using an RTSP (real time streaming protocol), and performing image framing processing on the video; after the face is identified, extracting a face picture and performing similarity matching with an authorization database, and recording the invasion times under the condition of mismatching; and setting a threshold value of the intrusion times, and comprehensively designing according to the accuracy rate of detecting the human face by the model and the times from coding the video to picture frames per second. The method is used for monitoring the boundary environment, and the equipment comprises video monitoring and a computer, so that the problem of discontinuous detection error in the continuous time sequence picture is solved.)

1. A method of intelligent perimeter detection, the steps comprising:

s1, collecting certificate photos of an authorizer, and establishing an authorization database;

s2, utilizing the trained computer vision recognition model to extract the characteristics of the photos in the database,

s3, acquiring the recognized face code and storing the acquired face feature code;

s4, accessing a monitoring video;

s5, collecting a video stream by using an RTSP (real time streaming protocol), and performing image framing processing on the video;

s6, after the face is identified, extracting a face picture and performing similarity matching with an authorization database, and recording the intrusion frequency under the condition of no match;

and S7, setting a threshold value of the intrusion frequency, and comprehensively setting the accuracy of detecting the human face according to the model and the frequency from the video to the picture frame coded per second.

2. The intelligent perimeter detection method of claim 1, wherein the certificate photo shows the front face of the head and has clear five sense organs.

3. The intelligent perimeter detection method according to claim 1, wherein the computer vision recognition model training utilizes face data for training, and utilizes a surface model to extract corresponding face codes from the penultimate layer full connection.

4. The method of claim 1, wherein during the video framing process, the cv2.videocapture function accesses the video stream to uniformly code the video picture frames using the key frame I as the image base, the forward predicted frame P, and the bidirectional interpolated frame B as the locally changed image data.

5. The method for intelligent perimeter detection according to claim 4, wherein the framing Base64 code-converting the picture frames through a video Capture.

6. The intelligent perimeter detection method according to claim 1, wherein during the face recognition, the face is subjected to feature extraction; and (4) carrying out similarity matching on the extracted face picture in an authorization database, and setting a threshold value of a matching score.

7. The intelligent perimeter detection method of claim 6 wherein the threshold matching score is 80%; when the face reaching or exceeding the threshold score exceeds 0, judging that the matching is successful, and recording the intrusion frequency as 0; and when the face reaching or exceeding the threshold score is 0, judging that the matching is unsuccessful, and recording the number of the invasion plus 1.

8. The intelligent perimeter detection method of claim 7, wherein after the threshold of the number of intrusions is reached, a warning model is started; when the quality of video acquisition is improved, the threshold value of the matching score is reduced; when the number of picture frames coded per second increases, the threshold of the matching score is raised.

9. An intelligent perimeter detection device, which utilizes the intelligent perimeter detection method as claimed in any one of claims 1 to 8, and is characterized by comprising a video acquisition device, a face recognition control system and an alarm device, wherein the video acquisition device is accessed to the video data of a camera of a natural gas unattended station, and the face recognition control system records the intrusion frequency after receiving the video data and controls the alarm device to give an alarm.

10. The intelligent perimeter detection device of claim 9, wherein the face recognition control system compresses video data and then detects the video.

Technical Field

The invention relates to the technical field of artificial intelligence and detection equipment, in particular to an intelligent perimeter detection method and equipment.

Background

Conventional perimeter intrusion may use detectors, including infrared, microwave, cable, laser, video, radar or other sensors. However, these detection methods can only distinguish large classes, and cannot distinguish specific fine-grained classes, such as the type of intrusion. Along with the flow of artificial intelligence, the target object comprises the application of a face recognition algorithm in various industries. It can be applied to perimeter intrusion scenes, and has the advantage of being able to identify people or objects. However, in the identification process, due to the fact that the model generalization capability is insufficient and the quality of externally acquired data is low, identification errors occur, reported signals are disordered, and system disorder is caused.

The generalization capability of the artificial intelligence model in the prior art needs to be further improved, so that the false alarm fault-tolerant capability of the whole system is improved. When the computer vision model detects continuous time sequence pictures, a target object disappears for a while, and signal disorder and disasters are caused. The problem exists in various reasons, such as the angle change of the target object during the detection, insufficient processing stability of the visual model, and the problem of the quality of the whole image frame caused by other factors.

Disclosure of Invention

In order to solve the problem of signal disappearance of perimeter intrusion detection, compute resources and transmission burden and improve the fault-tolerant performance of perimeter intrusion target identification and target tracking in a video scene, the invention provides an intelligent perimeter detection method and equipment, and the specific technical scheme is as follows.

A method of intelligent perimeter detection, the steps comprising:

s1, collecting certificate photos of an authorizer, and establishing an authorization database;

s2, utilizing the trained computer vision recognition model to extract the characteristics of the photos in the database,

s3, acquiring the recognized face code and storing the acquired face feature code;

s4, accessing a monitoring video;

s5, collecting a video stream by using an RTSP (real time streaming protocol), and performing image framing processing on the video;

s6, after the face is identified, extracting a face picture and performing similarity matching with an authorization database, and recording the intrusion frequency under the condition of no match;

and S7, setting a threshold value of the intrusion frequency, and comprehensively setting the accuracy of detecting the human face according to the model and the frequency from the video to the picture frame coded per second.

Preferably, the certificate photo shows the front of the head with clear five sense organs.

Preferably, the computer vision recognition model training utilizes the face data to train, and utilizes the surface model to extract the corresponding face code through the full connection of the penultimate layer.

Preferably, in the process of image framing processing of the video, the cv2.videocapture function accesses the video stream to uniformly code the picture frame of the video by using the key frame I as an image base, using the forward prediction frame P and the bidirectional interpolation frame B as local change image data.

Preferably, the picture frames are subjected to Base64 code conversion through a function video capture.

Further preferably, during face recognition, feature extraction is performed on the face; and (4) carrying out similarity matching on the extracted face picture in an authorization database, and setting a threshold value of a matching score.

It is further preferred that the threshold value for the match score is 80%; when the face reaching or exceeding the threshold score exceeds 0, judging that the matching is successful, and recording the intrusion frequency as 0; and when the face reaching or exceeding the threshold score is 0, judging that the matching is unsuccessful, and recording the number of the invasion plus 1.

Further preferably, after the threshold value of the intrusion frequency is reached, the warning model is started; when the quality of video acquisition is improved, the threshold value of the matching score is reduced; when the number of picture frames coded per second increases, the threshold of the matching score is raised.

The intelligent perimeter detection equipment comprises a video acquisition device, a face recognition control system and an alarm device, wherein the video acquisition device is connected with the video data of a camera of a natural gas unattended station, and the face recognition control system records the invasion times after receiving the video data and controls the alarm device to give an alarm.

It is still further preferred that the face recognition control system compresses the video data and then detects the video.

The intelligent perimeter detection method and the equipment provided by the invention have the beneficial effects that: the method can solve the problem that when a computer vision model detects continuous time sequence pictures, when a target appears in the pictures during the detection, the model detects errors discontinuously. The method can improve the generalization capability of the whole artificial intelligence model by utilizing equipment, thereby improving the fault tolerance capability of misinformation. In addition, the method also solves the problem of target detection failure caused by accidental problems caused by factors such as environment, models and the like.

Drawings

In order to more clearly illustrate the embodiments or technical solutions of the present invention, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained based on these drawings without creative efforts.

FIG. 1 is a schematic flow diagram of a method of intelligent perimeter detection;

fig. 2 is a flow chart of the operation of the apparatus.

Detailed Description

The method and the device for intelligent perimeter detection provided by the invention are described in detail with reference to fig. 1 and fig. 2.

A method of intelligent perimeter detection, the steps comprising:

s1, collecting certificate photos of an authorizer, and establishing an authorization database.

The certificate photo shows the front of the head with clear five sense organs. The requirements of the pictures can be that the recent five sense organs shot by the passport standard are clear and have no obstruction, the sitting posture is correct, and the like.

And S2, utilizing the trained computer vision recognition model to extract the features of the photos in the database.

And training the computer vision recognition model by using the face data, and extracting a corresponding face code by using the surface model and the full connection of the penultimate layer. The method can select a computer vision recognition face model as a model for third-party training, the training method is carried out by utilizing a large amount of face training data, the adopted recognition model is a surface, and a middle-to-last second layer full link memory is used for extracting a corresponding face code; the subsequent face recognition models are all the models, and the face recognition model can also adopt other face recognition models, and the models are required to be capable of extracting feature codes of faces.

And S3, acquiring the recognized face code and storing the acquired face feature code. The face code can be stored in a computer and stored in a face recognition control system, and after storage, data security measures can be set.

And S4, accessing the monitoring video. For example, when the natural gas unattended station is used, the monitoring video data of the natural gas unattended station can be directly accessed. The method can also be applied to an LNG unloading scene, and safety targets in the unloading scene are monitored in real time until the targets appear.

And S5, acquiring a video stream by using an RTSP (real time streaming protocol), and performing image framing processing on the video.

Specifically, in the process of image framing processing of a video, a cv2.videocapture function is accessed into a video stream, and a forward prediction frame P and a bidirectional interpolation frame B are used as local change image data to uniformly code a video image frame by taking a key frame I as an image base. And carrying out Base64 code conversion on the picture frames through a function video Capture of the sub-frames, transmitting the converted picture frames into an identification algorithm interface, sequentially transmitting the picture frames to a computer to identify a video model according to time sequence, and carrying out face identification.

And S6, after the face is identified, extracting a face picture and performing similarity matching with an authorization database, and recording the intrusion frequency under the condition of no match.

During face recognition, extracting features of the face; and (4) carrying out similarity matching on the extracted face picture in an authorization database, and setting a threshold value of a matching score. The threshold value of the matching score is 80%, and corresponding setting can be carried out according to the accuracy and experience of the visual model; when the face reaching or exceeding the threshold score exceeds 0, judging that the matching is successful, indicating that the safety does not need warning, and recording the intrusion frequency as 0; and when the face reaching or exceeding the threshold score is 0, judging that the matching is unsuccessful, indicating that the matching is unsafe and the face is not authorized, and recording the number of intrusion plus 1.

And S7, setting a threshold value of the intrusion frequency, and comprehensively setting the accuracy of detecting the human face according to the model and the frequency from the video to the picture frame coded per second.

Setting the intrusion frequency as 3 as a threshold value, and starting an alarm model after the threshold value of the intrusion frequency is reached; when the quality of video acquisition is improved, the threshold value of the matching score is reduced; when the number of picture frames coded per second increases, the threshold of the matching score is raised. Specifically, the threshold of the intrusion frequency is designed comprehensively according to the accuracy of detecting the human face by the model and the frequency from the video to the picture frame coded per second. When the accuracy of the face recognition model is high and the quality of video acquisition is high, the threshold value can be set small. This threshold can be set larger when the number of frames per second of pictures is large. When there are many picture frames encoded per second, there will be consumption of calculation performance, consumption of memory, and consumption of transmission. Therefore, a parameter for encoding a large number of picture frames per unit time is not recommended.

The intelligent perimeter detection equipment comprises a video acquisition device, a face recognition control system and an alarm device, wherein the video acquisition device is connected with the video data of a camera of a natural gas unattended station, and the face recognition control system records the invasion times after receiving the video data and controls the alarm device to give an alarm. The face recognition control system compresses video data and then detects the video. At the time of video to picture frame coding, a frequency of 3 frames per second may be employed.

In the device, after video stream is processed, picture frames are coded, then a computer visually identifies a target object, the target in a scene is monitored in real time, and the coordinates of the target are reported when the target appears; when the target disappears, and the target disappears after 3 times, the reported target disappears, and the control system accurately judges the result and sends out a corresponding instruction.

The method can solve the problem that when a computer vision model detects continuous time sequence pictures, when a target appears in the pictures during the detection, the model detects errors discontinuously. The method can improve the generalization capability of the whole artificial intelligence model by utilizing equipment, thereby improving the fault tolerance capability of misinformation. In addition, the method also solves the problem of target detection failure caused by accidental problems caused by factors such as environment, models and the like.

It is to be understood that the above description is not intended to limit the present invention, and the present invention is not limited to the above examples, and those skilled in the art may make modifications, alterations, additions or substitutions within the spirit and scope of the present invention.

8页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种基于统计分析的LNG卸车风险预测方法及评估系统

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!