Vehicle alarm method, device and equipment and storage medium

By not recognizing continuous N frames in vehicle sentry mode, it is considered as a person walking away, and reducing misidentification and reporting through position information comparison, the power consumption problem caused by fluctuations and misidentification in vehicle sentry mode is solved, and the effect of correct reporting and power saving is achieved.

CN119625678APending Publication Date: 2025-03-14THUNDERSOFT (NANJING) CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411644410.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-18
Publication Date
2025-03-14

AI Technical Summary

Technical Problem

In the existing vehicle sentry mode, the algorithm recognizes fluctuations and causes the early warning to be reported, and in case of misidentification, the alarm will be reported continuously, which consumes the car's power.

Method used

By not recognizing the talent in continuous N frames in vehicle sentry mode, the person has been deemed to have gone away, solving the problem of algorithm recognition fluctuations. At the same time, save the position information of the reported objects and compare them. Only output the alarm information when the overlapping degree meets the alarm conditions to avoid continuous reporting caused by misidentification.

Benefits of technology

Ensure that the early warning can be reported correctly when people stand in the alarm area, reduce the number of alarms caused by misidentification, and save the power of the car.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119625678A_ABST
    Figure CN119625678A_ABST
Patent Text Reader

Abstract

The invention discloses a vehicle alarm method, device and equipment and a storage medium. Comprising the following steps: when detecting that a target person exists in a preset range of the whole body of a vehicle according to a target image shot by a camera of the vehicle, tracking and shooting the target person by adopting a target tracking algorithm to obtain continuous N frames of images; performing personnel detection on the N frames of images to obtain target personnel detection results corresponding to the N frames of images; under the condition that the target person detection result indicates that the target person exists in the preset range around the vehicle, whether the current time reaches a vehicle alarm starting condition or not is determined; when it is determined that the current time reaches the vehicle alarm starting condition, the overlapping degree of a first detection frame of a target person in an image shot at the current time and a second detection frame of the target person in a reported image is obtained; and when it is determined that the image shot at the current time meets an alarm condition according to the overlapping degree, reporting the image shot at the current time, and outputting alarm information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of vehicle safety technology, and in particular to a vehicle alarm method, device, equipment and storage medium. Background Art

[0002] The vehicle sentry mode uses the vehicle's existing sensors, cameras and other hardware to monitor the vehicle and its surroundings in real time. When the vehicle is parked, the sentry mode is automatically activated and uses various sensors and cameras on the vehicle body to monitor suspicious activities in the vehicle and its surroundings. The owner can view the video information of the cameras around the vehicle body in real time through the mobile phone APP, and receive timely alarm notifications when the vehicle is hit or moved.

[0003] In the existing vehicle sentry mode, suspicious persons need to be identified in each frame within a continuous period of time (usually 10 seconds). If a frame fails to identify the person, the software will assume that the person has left the alarm area and the timer will stop. It is difficult for the algorithm to ensure stable identification of suspicious persons, and some frames will fail to identify them, which will result in the statistical time not being able to continue, and thus the warning cannot be reported.

[0004] At the same time, in some special scenes, such as low light, human-shaped pillars, human-shaped billboards, etc., the algorithm may misidentify suspicious persons when they are not pedestrians, and then report to the police. Since these fixed obstacles remain stationary after parking, the alarm will be continuously reported, and the car will continue to shoot videos, which will continue to consume the car's power. Summary of the invention

[0005] The embodiments of the present application provide a vehicle alarm method, device, equipment and storage medium, which can solve the problem of being unable to report due to fluctuations in algorithm recognition and the problem of continuous reporting and consumption of vehicle power. The technical solution is as follows:

[0006] On the one hand, an embodiment of the present application provides a vehicle alarm method, the method comprising:

[0007] When a target person is detected within a preset range around the vehicle according to a target image captured by a camera of the vehicle, a target tracking algorithm is used to track and capture the target person to obtain N consecutive frames of images, where N is a positive integer greater than 1;

[0008] Performing person detection on the N frames of images respectively to obtain target person detection results corresponding to the N frames of images;

[0009] When the target person detection result indicates that the target person exists within a preset range around the vehicle, determining whether the vehicle alarm activation condition is met at the current time;

[0010] When it is determined that the vehicle alarm activation condition is met at the current time, the degree of overlap between the first detection frame of the target person in the image taken at the current time and the second detection frame of the target person in the reported image is obtained;

[0011] When it is determined according to the overlap degree that the image shot at the current time meets the alarm condition, the image shot at the current time is reported and alarm information is output.

[0012] On the other hand, an embodiment of the present application provides a vehicle alarm device, the device comprising:

[0013] An N-frame image acquisition module is used to track and shoot the target person using a target tracking algorithm when a target person is detected within a preset range around the vehicle according to the target image captured by the vehicle's camera, to obtain N consecutive frames of images, where N is a positive integer greater than 1;

[0014] A detection result acquisition module is used to perform personnel detection on the N frames of images respectively to obtain target personnel detection results corresponding to the N frames of images;

[0015] An alarm condition determination module, used to determine whether a vehicle alarm activation condition is met at a current time when the target person detection result indicates that the target person exists within a preset range around the vehicle;

[0016] An overlap degree acquisition module, used to acquire the overlap degree of a first detection frame of a target person in an image taken at the current time and a second detection frame of a target person in a reported image when it is determined that the vehicle alarm activation condition is met at the current time;

[0017] The alarm information output module is used to report the image shot at the current time and output alarm information when it is determined according to the overlap degree that the image shot at the current time meets the alarm condition.

[0018] On the other hand, an embodiment of the present application provides a computer device, which includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set are loaded and executed by the processor to implement the vehicle alarm method described in the above aspects.

[0019] On the other hand, an embodiment of the present application provides a computer-readable storage medium, which stores at least one instruction, at least one program, a code set or an instruction set. The at least one instruction, the at least one program, the code set or the instruction set are loaded and executed by a processor to implement the vehicle alarm method described in the above aspects.

[0020] On the other hand, an embodiment of the present application provides a computer program product, which, when executed, is used to execute the vehicle alarm method described in the above aspects.

[0021] In the technical solution provided by the embodiment of the present application, in the vehicle sentry mode, if no person is recognized for N consecutive frames (N is a configurable number), it is considered that the person has left. This solves the problem of being unable to report due to fluctuations in algorithm recognition. When a person stands in the alarm area, the report can be made correctly.

[0022] At the same time, the location information of the reported objects is saved, and before reporting, it is compared with the historically reported objects. The alarm information is output only when the same ID and the overlap degree indicate that the alarm conditions are met. Therefore, in the case of misidentification, it will only be reported once for the first time, and will not be reported afterwards, which can solve the problem of continuous reporting and the problem of consuming car power. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] Figure 1 A flowchart of a vehicle alarm method provided in an embodiment of the present application;

[0024] Figure 2 A schematic diagram of a data processing flow provided in an embodiment of the present application;

[0025] Figure 3 A schematic diagram of a vehicle alarm processing flow provided in an embodiment of the present application;

[0026] Figure 4 A schematic diagram of an image reporting process provided in an embodiment of the present application;

[0027] Figure 5 is a block diagram of a vehicle alarm device provided by an embodiment of the present application;

[0028] Figure 6 It is a structural block diagram of a computer device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0029] The implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.

[0030] Reference Figure 1 , shows a flow chart of the steps of a vehicle alarm method provided by an embodiment of the present application. Figure 1 As shown, the vehicle alarm method may include: step 101, step 102, step 103, step 104 and step 105.

[0031] Step 101: When a target person is detected within a preset range around the vehicle based on a target image captured by a camera of the vehicle, a target tracking algorithm is used to track and capture the target person to obtain N consecutive frames of images, where N is a positive integer greater than 1.

[0032] The embodiments of the present application can be applied to scenarios where a filtering strategy and an anti-false alarm strategy are used to perform vehicle alarms in a vehicle sentinel mode.

[0033] Vehicle Sentinel Mode (Sentinel Mode or Sentry Mode) is an intelligent vehicle safety system designed to improve the safety of the vehicle when it is parked. Sentry Mode usually includes the following working states:

[0034] Standby mode: When the vehicle is in sentry mode, it will automatically enter standby mode. At this time, the vehicle will automatically monitor suspicious activities around the vehicle through the front camera, side cameras and rear view cameras.

[0035] Alert state: When the vehicle detects a threat around it, Sentry Mode will automatically enter alert state. At this time, the vehicle's headlights may light up briefly, and the on-board camera will start recording and save the video for a certain length of time.

[0036] Alarm state: If a serious threat is detected (such as vehicle damage), Sentry Mode will enter the alarm state. At this time, the on-board camera will continue to record and activate the alarm system, such as vehicle horns, flashing lights, etc. At the same time, the owner's mobile phone APP will receive an alarm notification so that timely response measures can be taken.

[0037] In the vehicle sentry mode, the vehicle's camera can be used to capture images around the vehicle, and based on the captured images, it can be determined whether there are suspicious persons around the vehicle (i.e., whether there are persons who may cause damage to the vehicle). The specific process can be: 1. The vehicle's camera is used to capture images around the vehicle, and the captured images are identified (such as by target detection algorithms, etc.) to identify whether there are persons around the vehicle. 2. If there are persons around the vehicle, an ID can be assigned to the identified persons, and the distance between the person and the vehicle can be calculated. If the distance is within the preset distance range, the person is identified as a target person (i.e., a suspicious person).

[0038] When the target person is detected within a preset range (which may be a manually set range or a system-defined range) around the vehicle according to the target image captured by the vehicle's camera, the target person may be tracked and photographed using a target tracking algorithm to obtain N consecutive frames of images. Specifically, the target tracking algorithm may be used to identify the trajectory of the target person, and a video may be shot for a period of time according to the trajectory, and the video may contain N consecutive frames of images.

[0039] In this example, the target tracking algorithm may be a Kalman filter, a particle filter, an optical flow method, a method based on deep learning, or the like. When a target person is detected, the captured image may be reported, a timer may be started for timing, and the target person may be tracked and photographed. The implementation process may be described in detail in conjunction with the following specific implementation methods.

[0040] In a specific implementation of the present application, the above step 101 may include:

[0041] Sub-step A1: When a target person is detected within a preset range around the vehicle based on a target image captured by a camera of the vehicle, the target image is reported and timing is started.

[0042] In this embodiment, when it is detected that a target person exists within a preset range around the vehicle based on a target image captured by a camera of the vehicle, the target image is reported and timing is started.

[0043] It can be understood that corresponding timers can be set for different target persons to start timing.

[0044] After the target image is reported and timing starts, sub-step A2 is executed.

[0045] Sub-step A2: using the target tracking algorithm to track and photograph the target person according to the person identification of the target person, to obtain the continuous N frames of images.

[0046] After the target image is reported and timing starts, a target tracking algorithm may be used to track and photograph the target person according to the person identification of the target person, to obtain the continuous N frames of images.

[0047] After the target person is tracked and photographed using the target tracking algorithm to obtain N consecutive frames of images, step 102 is executed.

[0048] Step 102: Performing person detection on the N frames of images respectively to obtain target person detection results corresponding to the N frames of images.

[0049] After the target person is tracked and photographed by using the target tracking algorithm to obtain N consecutive frames of images, the person detection can be performed on the N frames of images respectively to obtain the target person detection results corresponding to the N frames of images.

[0050] In this embodiment, the algorithm for performing personnel detection on N frames of images may be a traditional algorithm such as HOG+SVM, sliding window, etc. It may also be a deep learning-based algorithm, such as YOLO (You Only Look Once), SSD (Single Shot MultiBox Detector), Faster R-CNN, etc. These methods perform well in personnel detection tasks with high accuracy and real-time performance.

[0051] When using deep learning-based algorithms for detection, first, you can select a trained person detection model and load it into memory, and adjust the model parameters according to specific needs, such as confidence threshold, non-maximum suppression (NMS) parameters, etc. Then, you can traverse N frames of images and apply the person detection algorithm to each frame of the image. The algorithm will output the bounding box, confidence and other detection results of each detected person.

[0052] When the target person detection result indicates that there is a target person within the preset range around the vehicle, the acquired target person image containing the target person is reported within the preset timing duration and at the preset reporting time interval. For example, when the target person is detected to exist within the preset range around the vehicle, the target person can be tracked and photographed by video, the preset timing duration is 5 minutes, and the reporting time interval is 1 minute. Then, a frame of image containing the target person can be reported from the beginning of the timing, which is defined as the 0th minute. After an interval of 1 minute (i.e., the 1st minute), an image containing the target person is reported again. By analogy, an image containing the target person can be reported once at the 2nd minute, the 3rd minute, the 4th minute, and the 5th minute, etc.

[0053] It can be understood that the above examples are merely examples listed for a better understanding of the technical solutions of the embodiments of the present application, and are not intended to be the sole limitation to the embodiments.

[0054] After performing person detection on N frames of images respectively to obtain target person detection results corresponding to the N frames of images, step 103 is executed.

[0055] Step 103: When the target person detection result indicates that the target person exists within a preset range around the vehicle, determining whether the current time meets the vehicle alarm activation condition.

[0056] After obtaining the target person detection results corresponding to N frames of images, it can be indicated whether there is a target person within a preset range around the vehicle based on the target person detection results (i.e., whether there are people around the vehicle who are within a preset range around the vehicle and appear repeatedly).

[0057] If the target person detection result indicates that there is no target person in N frames of images, the image corresponding to the target person will not be reported, and the timing operation of the timer corresponding to the target person will be stopped, that is, the target person does not pose a risk of damaging the vehicle, and the alarm for the target person will be lifted.

[0058] The embodiment of the present application considers that the person has left after failing to identify the person for N consecutive frames (N is configurable). This solves the problem of being unable to report due to fluctuations in algorithm recognition. When a person stands in the alarm area, the report can be made correctly.

[0059] When the target person detection result indicates that there is a target person within the preset range around the vehicle, it can be determined whether the current time meets the vehicle alarm activation condition. Specifically, a vehicle alarm activation duration can be preset, and when the duration between the current time and the timing activation time reaches the preset duration, it can be determined that the current time meets the vehicle alarm activation condition.

[0060] When it is determined that the vehicle alarm condition has not been met at the current time, the tracking and photographing of the target person will continue.

[0061] After determining that the current time reaches the vehicle alarm activation condition, step 104 is executed.

[0062] Step 104: when it is determined that the vehicle alarm activation condition is met at the current time, the degree of overlap between the first detection frame of the target person in the image captured at the current time and the second detection frame of the target person in the reported image is obtained.

[0063] After obtaining N consecutive frames of images, the vehicle's camera will use a target tracking algorithm to continuously track and photograph the target person. In this example, the image taken at the current time is an image containing the target person taken when the vehicle alarm activation condition is met during the process of the camera continuously tracking and photographing the target person.

[0064] When it is determined that the vehicle alarm activation condition is met at the current time, the current image to be reported can be obtained, wherein the current image to be reported can be an image of the target person taken by the vehicle's camera at the current time, or can be a randomly selected frame of the image of the target person from multiple frames of images taken by the vehicle's camera within a preset time range from the current time.

[0065] Among them, the implementation method for determining whether the current time meets the vehicle alarm activation conditions can be: obtaining the timing start time of the timer corresponding to the target person, and when the duration between the current time and the timing start time reaches the preset timing duration, determining that the current time meets the vehicle alarm activation conditions.

[0066] Furthermore, a first detection frame of the target person in the current image to be reported can be obtained, and the first detection frame can be a detection frame of the target person output by performing target person detection on the image to be reported through an algorithm based on deep learning. At the same time, a second detection frame of the target person in the reported image can be obtained.

[0067] Finally, the degree of overlap between the first detection frame and the second detection frame can be obtained, and the degree of overlap can be used to represent the overlapping area of ​​the first detection frame and the second detection frame. Specifically, the first detection frame corresponding to the current image to be reported can be obtained based on the personnel detection result of the current image to be reported, and the second detection frame can be obtained based on the personnel detection result of the image reported most recently from the current time in the reported image. The intersection-and-union ratio parameter between the first detection frame and the second detection frame is calculated, and the intersection-and-union ratio parameter is used as the degree of overlap between the first detection frame and the second detection frame.

[0068] After the overlap degree between the first detection frame and the second detection frame is obtained, step 105 is performed.

[0069] Step 105: When it is determined that the overlap degree indicates that the image to be reported meets an alarm condition, the image to be reported is reported and alarm information is output.

[0070] After the overlap degree between the first detection frame and the second detection frame is obtained, it can be determined whether the image to be reported meets the alarm condition according to the overlap degree.

[0071] If the overlap degree indicates that the image to be reported does not meet the alarm condition, it means that there is a false detection of the target person. At this time, the image to be reported is no longer reported, and the timing of the timer corresponding to the target person is stopped.

[0072] When it is determined that the overlap degree indicates that the image to be reported meets the alarm condition, the image to be reported is reported and the alarm information is output. When determining whether the overlap degree satisfies the alarm condition for the image to be reported, an intersection-and-union ratio threshold can be determined based on the area of ​​the first detection frame, and when the intersection-and-union ratio parameter is greater than the intersection-and-union ratio threshold, it is determined that the overlap degree between the first detection frame and the second detection frame meets the alarm condition.

[0073] That is, different detection box areas correspond to different thresholds, and the setting method can be as follows:

[0074] 1. When the detection box area is ≤ (50px50px), the threshold is set to 85%.

[0075] 2. When (50px*50px)<detection frame area≤(80px*80px), the threshold is set to 90%.

[0076] 3. When the detection box area is greater than (80px*80px), the threshold is set to 92%, etc.

[0077] The embodiments of the present application are aimed at some special scenarios, such as low light, human-shaped pillars, human-shaped billboards, etc. At this time, the algorithm may have the problem of misidentification, identifying suspicious persons who are not pedestrians, and then reporting the alarm. Since these fixed obstacles remain motionless after parking, the alarm will be continuously reported, and the car will continue to shoot videos, which will continue to consume the car's power. By using the IOU matching degree >= threshold for the same ID, no report will be made. In this way, when a misidentification occurs, it will only be reported once for the first time, and it will not be reported afterwards. It solves the problem of continuous reporting and the problem of consuming car power.

[0078] Next, combine Figure 2 The data flow processing is described in detail.

[0079] like Figure 2 As shown, CSC (Color Space Convert) refers to using opengl to do color space conversion, and the algorithm requires the input format to be RGB.

[0080] Data Preprocessing (data preprocessing) buffer resize, etc. After using the input buffer, return the buffer to the consumer queue.

[0081] Object Detector assigns an id to the identified person based on the output of the object detection algorithm.

[0082] Distance Measure is used to determine the distance between the target and the vehicle.

[0083] Data statistic: The timer detects the current statistical id and a map of people who have timed out appears on the screen.

[0084] Warning Strategy: Decide whether to issue an alarm based on the reporting strategy.

[0085] like Figure 2As shown, first, the cameras (Camera0, ..., Camera1) on the vehicle can capture images around the vehicle when the vehicle is in vehicle sentry mode, and the SDK user calls the thread to obtain the captured image to perform CSC processing on the captured original image and output the original image RGBbuffer. Then, the original image RGBbuffer can be output to the producer queue in the SDK internal thread. Furthermore, the original image RGBbuffer in the producer queue can be subjected to Data Preprocess processing, such as resizing, preprocessing, etc. After preprocessing, the preprocessed image can be sent to the consumer queue for storage. At the same time, the preprocessed image can be subjected to Object Detector and output to the next preprocessing module. The next preprocessing module can cut out the image based on the result of target detection on the original image according to the original image RGBbuffer and the model reasoning output information, and perform resize and deepsort preprocessing again. The DeepSORT algorithm relies on the target detector to determine the target position of each frame in the video. Furthermore, object tracting and target tracking can be performed based on the model reasoning output information. At the same time, distance measurement can be performed, and data statistics can be performed to determine in real time whether the alarm strategy is met, that is, Warning Strategy: whether to alarm is determined based on the reporting strategy. When the alarm condition is met, a report is made, that is, DVR, which stands for Digital Video Recorder, is an electronic device specially used to record and store video data. It converts analog video signals into digital signals and uses hard disks or other storage devices to save these digital video data. The emergence of DVR has greatly promoted the development of video surveillance technology, making the recording, storage, playback and transmission of video data more convenient and efficient.

[0086] Next, combine Figure 3 The statistical process in the alarm process is described in detail. Figure 3 As shown, the statistical process of the vehicle sentry alarm may include:

[0087] 1. Distance detection, that is, input the suspicious person list newlist, which needs to be input once for each frame.

[0088] 2. Determine whether newlist is empty. If so, determine whether the most recently reported state is the "alarm on" state. If not, do nothing. If yes, determine whether the "alarm cancel" timer is not working. If not, do nothing. If yes, cancel the alarm and start the 3s timer. Further determine whether the timer has expired? And whether the timer has been canceled? If it has been canceled, do nothing. If the timer has expired, report the "alarm cancel" signal.

[0089] 3. If newlist is not empty, the "alarm cancel" timer stops and determines whether the following three situations exist:

[0090] (1) When a new suspicious person is detected, it can be determined whether the task queue is not full. If not, no action is taken. If yes, the "alarm start" timer is turned on for the newly discovered person. Then, it is determined whether the timer has expired and whether the timer has been canceled. If it has been canceled, no action is taken. If the timer has expired, it is determined whether the current state is an alarm state. If not, the task queue is cleared and the "alarm cancel" signal is reported. If the current state is an alarm state, no action is taken.

[0091] (2) When a reduction in personnel is detected, the elimination number corresponding to the ID can be increased by 1, and it is determined whether the elimination number of the ID = N (N is the number of ID detections set for elimination and alarm)? If not, no processing is performed. If so, the "alarm start" timer corresponding to the ID can be stopped.

[0092] (3) The list of suspicious persons has not changed and no action will be taken at this time.

[0093] Next, combine Figure 4 The implementation process of the two reporting strategies provided in this embodiment is described in detail. Figure 4 As shown, the process may include:

[0094] 1. A detection result is received, which indicates that the captured image contains a suspicious person.

[0095] 2. Update the latest rectangular frame information, that is, update the existing detection rectangular frame of the suspicious person according to the detection rectangular frame of the latest captured image.

[0096] 3. Determine whether the 10s timing has expired. If so, proceed to step 4.

[0097] 4. Determine whether this is the first time the suspicious person has been reported. If so, proceed to step 5; if not, proceed to step 6.

[0098] 5. Report 1 and the location of the object, and insert it into the comparison object list (i.e. id + location).

[0099] 6. Traverse the comparison object list to see if the same id exists. If not, go to step 7. If yes, go to step 8.

[0100] 7. If the same ID does not exist, can we determine whether the list is full? If yes, remove the oldest image from the queue, insert the current object information, and then report it. If not, insert the object information into the comparison object list and then report it.

[0101] 8. Calculate the ratio of the distance between the center points of the two frames and the diagonal of the smallest outer rectangle of the two frames, and then determine whether the IOU is ≤ 0.1 (i.e. the threshold). If so, do not report it. If not, update the object information of the corresponding ID and report it.

[0102] The above-mentioned filtering scheme (i.e., the judgment scheme of N consecutive frames of images) provided in the embodiment of the present application can also be used to calculate the residence time of pedestrians or objects, such as the calculation of illegal parking time: when the surveillance camera captures an illegally parked car, the timing starts, and when the timing reaches a certain time, it is considered not to be temporary parking, etc.

[0103] The above IOU false alarm prevention strategy can also be used to identify scenes where people or objects are not moving. For example, you can take a photo of a person who is sitting for a long time. If the person does not move for a long time, the IOU matching degree will be higher. At this time, you can remind the person to move.

[0104] The vehicle alarm method provided in the embodiment of the present application is to track and shoot the target person by using the target tracking algorithm when the target person is detected within the preset range around the vehicle according to the target image captured by the camera of the vehicle, and obtain continuous N frames of images, where N is a positive integer greater than 1. Personnel detection is performed on the N frames of images respectively to obtain the target person detection results corresponding to the N frames of images. When the target person detection result indicates that the target person exists within the preset range around the vehicle, it is determined whether the vehicle alarm activation condition is met at the current time. When it is determined that the vehicle alarm activation condition is met at the current time, the degree of overlap between the first detection frame of the target person in the image captured at the current time and the second detection frame of the target person in the reported image is obtained. When it is determined that the image captured at the current time meets the alarm condition according to the degree of overlap, the image captured at the current time is reported, and the alarm information is output. In the embodiment of the present application, when the person is not recognized in N consecutive frames (N is a configurable number) in the vehicle sentry mode, it is considered that the person has walked away. This solves the problem of being unable to report due to fluctuations in algorithm recognition. When a person stands in the alarm area, the report can be made correctly. At the same time, the location information of the reported objects is saved, and before reporting, it is compared with the historically reported objects. The alarm information is output only when the same ID and the overlap degree indicate that the alarm conditions are met. Therefore, in the case of misidentification, it will only be reported once for the first time, and will not be reported afterwards, which can solve the problem of continuous reporting and the problem of consuming car power.

[0105] The following is an embodiment of the device of the present application, which can be used to execute the embodiment of the method of the present application. For details not disclosed in the embodiment of the device of the present application, please refer to the embodiment of the method of the present application.

[0106] Reference Figure 5 , shows a schematic diagram of the structure of a vehicle alarm device provided by an embodiment of the present application. Figure 5 As shown, the vehicle alarm device 500 may include the following modules:

[0107] The N-frame image acquisition module 510 is used to track and shoot the target person using a target tracking algorithm when a target person is detected within a preset range around the vehicle according to the target image captured by the camera of the vehicle, so as to obtain N consecutive frames of images, where N is a positive integer greater than 1;

[0108] A detection result acquisition module 520 is used to perform person detection on the N frames of images respectively to obtain target person detection results corresponding to the N frames of images;

[0109] An alarm condition determination module 530 is used to determine whether the vehicle alarm activation condition is met at the current time when the target person detection result indicates that the target person exists within a preset range around the vehicle;

[0110] The overlap degree acquisition module 540 is used to acquire the overlap degree of the first detection frame of the target person in the image taken at the current time and the second detection frame of the target person in the reported image when it is determined that the vehicle alarm activation condition is met at the current time;

[0111] The alarm information output module 550 is used to report the image shot at the current time and output alarm information when it is determined according to the overlap degree that the image shot at the current time meets the alarm condition.

[0112] Optionally, the N-frame image acquisition module includes:

[0113] A timer start unit, configured to report the target image and start timing when a target person is detected within a preset range around the vehicle according to the target image taken by the camera of the vehicle;

[0114] The N-frame image acquisition unit is used to use the target tracking algorithm to track and shoot the target person according to the person identification of the target person, so as to obtain the continuous N-frame images.

[0115] Optionally, the device further comprises:

[0116] The personnel image reporting module is used to report the acquired target person image containing the target person within a preset timing duration and at a preset reporting time when the target person detection result indicates that the target person exists within a preset range around the vehicle.

[0117] Optionally, the alarm condition determination module includes:

[0118] A start time acquisition unit, used to acquire the timing start time;

[0119] The alarm condition determination unit is used to determine that the current time reaches the vehicle alarm activation condition when the duration between the current time and the timing start time reaches a preset timing duration.

[0120] Optionally, the overlap degree acquisition module includes:

[0121] a detection frame acquisition unit, configured to obtain a first detection frame corresponding to the image shot at the current time according to the person detection result of the image shot at the current time, and obtain a second detection frame according to the person detection result of the image reported most recently from the current time among the reported images;

[0122] The overlap degree obtaining unit is used to calculate an intersection-and-union ratio parameter between the first detection frame and the second detection frame, where the intersection-and-union ratio parameter is the overlap degree between the first detection frame and the second detection frame.

[0123] Optionally, the alarm information output module includes:

[0124] a threshold determination unit, configured to determine an intersection-over-union ratio threshold according to a detection frame area of ​​the first detection frame;

[0125] A condition determination unit is used to determine whether the overlap degree between the first detection frame and the second detection frame meets the alarm condition when the intersection-over-union ratio parameter is greater than the intersection-over-union ratio threshold.

[0126] Optionally, the device further comprises:

[0127] The timing stop module is used to not report the image corresponding to the target person and stop the timing operation on the target person when the target person detection result indicates that the target person does not exist in the N frames of images.

[0128] The vehicle alarm device provided in the embodiment of the present application, when the target person exists within the preset range around the vehicle according to the target image captured by the camera of the vehicle, the target person is tracked and photographed by the target tracking algorithm to obtain continuous N frames of images, where N is a positive integer greater than 1. Personnel detection is performed on the N frames of images respectively to obtain the target person detection results corresponding to the N frames of images. When the target person detection result indicates that the target person exists within the preset range around the vehicle, it is determined whether the vehicle alarm activation condition is reached at the current time. When it is determined that the vehicle alarm activation condition is reached at the current time, the overlap degree of the first detection frame of the target person in the image captured at the current time and the second detection frame of the target person in the reported image is obtained. When it is determined that the image captured at the current time meets the alarm condition according to the overlap degree, the image captured at the current time is reported, and the alarm information is output. In the embodiment of the present application, when the person cannot be identified in N consecutive frames (N is a configurable number) in the vehicle sentry mode, it is considered that the person has walked away. This solves the problem of being unable to report due to fluctuations in algorithm recognition. When a person stands in the alarm area, the report can be made correctly. At the same time, the location information of the reported objects is saved, and before reporting, it is compared with the historically reported objects. The alarm information is output only when the same ID and the overlap degree indicate that the alarm conditions are met. Therefore, in the case of misidentification, it will only be reported once for the first time, and will not be reported afterwards, which can solve the problem of continuous reporting and the problem of consuming car power.

[0129] It should be noted that the device provided in the above embodiment, when implementing its functions, is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the device and method embodiments provided in the above embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.

[0130] Please refer to Figure 6 , which shows a block diagram of a computer device provided in one embodiment of the present application. The computer device can be used to implement the vehicle alarm method provided in the above embodiment. The computer device can be a PC or a server, or other devices with data processing and storage capabilities. Specifically:

[0131] The computer device 600 includes a central processing unit (CPU) 601, a system memory 604 including a random access memory (RAM) 602 and a read-only memory (ROM) 603, and a system bus 605 connecting the system memory 604 and the central processing unit 1001. The computer device 600 also includes a basic input / output system (I / O system) 606 that helps transfer information between various components in the computer, and a large-capacity storage device 607 for storing an operating system 613, application programs 614, and other program modules 615.

[0132] The basic input / output system 606 includes a display 608 for displaying information and an input device 609 such as a mouse and a keyboard for user inputting information. The display 608 and the input device 609 are connected to the central processing unit 601 through an input / output controller 610 connected to the system bus 605. The basic input / output system 606 may also include an input / output controller 610 for receiving and processing inputs from a plurality of other devices such as a keyboard, a mouse, or an electronic stylus. Similarly, the input / output controller 610 also provides output to a display screen, a printer, or other types of output devices.

[0133] The mass storage device 607 is connected to the central processing unit 601 through a mass storage controller (not shown) connected to the system bus 605. The mass storage device 607 and its associated computer readable medium provide non-volatile storage for the computer device 600. That is, the mass storage device 607 may include a computer readable medium (not shown) such as a hard disk or a CD-ROM drive.

[0134] Without loss of generality, the computer readable medium may include computer storage media and communication media. Computer storage media include volatile and non-volatile, removable and non-removable media implemented by any method or technology for storing information such as computer readable instructions, data structures, program modules or other data. Computer storage media include RAM, ROM, EPROM, EEPROM, flash memory or other solid-state memory technology, CD-ROM, DVD or other optical storage, tape cassettes, magnetic tapes, disk storage or other magnetic storage devices. Of course, those skilled in the art will appreciate that the computer storage media is not limited to the above. The above-mentioned system memory 604 and mass storage device 607 can be collectively referred to as memory.

[0135] According to various embodiments of the present application, the computer device 600 can also be connected to a remote computer on the network through a network such as the Internet. That is, the computer device 600 can be connected to the network 612 through the network interface unit 611 connected to the system bus 605, or the network interface unit 611 can be used to connect to other types of networks or remote computer systems (not shown).

[0136] The memory further includes one or more programs, which are stored in the memory and configured to be executed by one or more processors. The one or more programs include instructions for executing the vehicle alarm method.

[0137] In an example embodiment, a computer device is also provided, the computer device comprising a processor and a memory, wherein the memory stores at least one instruction, at least one program, code set or instruction set. The at least one instruction, at least one program, code set or instruction set is configured to be executed by one or more processors to implement the above vehicle alarm method.

[0138] In an exemplary embodiment, a computer-readable storage medium is also provided, in which at least one instruction, at least one program, a code set or an instruction set is stored. When the at least one instruction, the at least one program, the code set or the instruction set is executed by a processor of a computer device, the above-mentioned vehicle alarm method is implemented.

[0139] Optionally, the computer-readable storage medium may be a ROM, RAM, CD-ROM, magnetic tape, floppy disk, optical data storage device, etc.

[0140] In an exemplary embodiment, a computer program product is also provided. When the computer program product is executed, it is used to implement the above-mentioned vehicle alarm method.

[0141] It should be understood that the "plurality" mentioned in this article refers to two or more. "And / or" describes the association relationship of the associated objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the associated objects are in an "or" relationship.

[0142] The above description is only an exemplary embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. A vehicle alarm method, characterized in that: The method comprises: When a target person is detected within a preset range around the vehicle according to a target image captured by a camera of the vehicle, a target tracking algorithm is used to track and capture the target person to obtain N consecutive frames of images, where N is a positive integer greater than 1; Performing person detection on the N frames of images respectively to obtain target person detection results corresponding to the N frames of images; When the target person detection result indicates that the target person exists within a preset range around the vehicle, determining whether the vehicle alarm activation condition is met at the current time; When it is determined that the vehicle alarm activation condition is met at the current time, the degree of overlap between the first detection frame of the target person in the image taken at the current time and the second detection frame of the target person in the reported image is obtained; When it is determined according to the overlap degree that the image shot at the current time meets the alarm condition, the image shot at the current time is reported and alarm information is output.

2. The method according to claim 1, characterized in that: When a target person is detected within a preset range around the vehicle according to the target image captured by the camera of the vehicle, a target tracking algorithm is used to track and capture the target person to obtain N consecutive frames of images, including: When a target person is detected within a preset range around the vehicle according to a target image captured by a camera of the vehicle, the target image is reported and timing is started; The target tracking algorithm is used to track and shoot the target person according to the person identification of the target person, so as to obtain the continuous N frames of images.

3. The method according to claim 2, characterized in that After performing personnel detection on the N frames of images respectively to obtain target personnel detection results corresponding to the N frames of images, the method further includes: When the target person detection result indicates that the target person exists within a preset range around the vehicle, the acquired target person image containing the target person is reported within a preset timing duration and at a preset reporting time interval.

4. The method according to claim 2, characterized in that: Determine whether the vehicle alarm activation conditions are met at the current time, including: Get the timing start time; When the duration between the current time and the timing start time reaches the preset timing duration, it is determined that the current time reaches the vehicle alarm activation condition.

5. The method according to claim 1, characterized in that The obtaining of the overlap degree between the first detection frame of the target person in the image captured at the current time and the second detection frame of the target person in the reported image includes: Obtaining a first detection frame corresponding to the image shot at the current time according to a person detection result of the image shot at the current time, and obtaining a second detection frame according to a person detection result of an image reported most recently from the current time among the reported images; An intersection-over-union (IoU) parameter between the first detection frame and the second detection frame is calculated, where the IoU parameter is a degree of overlap between the first detection frame and the second detection frame.

6. The method according to claim 5, characterized in that Determining, according to the overlap degree, that the image captured at the current time meets the alarm condition includes: Determining an intersection-over-union ratio threshold according to a detection frame area of ​​the first detection frame; When the IoU parameter is greater than the IoU threshold, it is determined that the overlap degree between the first detection frame and the second detection frame meets the alarm condition.

7. The method according to claim 1, characterized in that After performing personnel detection on the N frames of images respectively to obtain target personnel detection results corresponding to the N frames of images, the method further includes: When the target person detection result indicates that the target person does not exist in any of the N frames of images, the image corresponding to the target person is not reported, and the timing operation for the target person is stopped.

8. A vehicle alarm device, characterized in that: The device comprises: An N-frame image acquisition module is used to track and shoot the target person using a target tracking algorithm when a target person is detected within a preset range around the vehicle according to the target image captured by the vehicle's camera, to obtain N consecutive frames of images, where N is a positive integer greater than 1; A detection result acquisition module is used to perform personnel detection on the N frames of images respectively to obtain target personnel detection results corresponding to the N frames of images; An alarm condition determination module, used to determine whether a vehicle alarm activation condition is met at a current time when the target person detection result indicates that the target person exists within a preset range around the vehicle; An overlap degree acquisition module, used to acquire the overlap degree of a first detection frame of a target person in an image taken at the current time and a second detection frame of a target person in a reported image when it is determined that the vehicle alarm activation condition is met at the current time; The alarm information output module is used to report the image shot at the current time and output alarm information when it is determined according to the overlap degree that the image shot at the current time meets the alarm condition.

9. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement the method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: The storage medium stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement the method as described in any one of claims 1 to 7.

Citation Information

Cited By

  • Vehicle alarm method and device, vehicle, storage medium and program product

    CN120503740A