Fall detection and alarm method, equipment, medium and product
By adding the CPA enhancer module and the improved C2f module to the YOLOv8n model, combined with the Inner-EIoU loss function, the false alarm and missed alarm problems of fall detection in complex environments are solved, and high-precision real-time detection in different environments is achieved.
Patent Information
- Application Number
- CN202411319450.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-20
- Publication Date
- 2024-12-31
AI Technical Summary
Existing fall detection methods are prone to false alarms or missed alarms in complex environments, making it difficult to effectively deal with image degradation problems, affecting the accuracy and reliability of detection.
Using the fall detection method based on the YOLOv8n model, the fall detection model is constructed by adding the CPA enhancer module, the improved C2f module and the Inner-EIoU loss function, and the CPA enhancer module is used for dynamic analysis and adapting to image degradation. The improved C2f module is reduced The number of parameters and calculation amounts, the Inner-EIoU loss function improves the accuracy of target positioning.
It significantly improves the detection accuracy in degraded scenarios such as low light, fog, rain and snow, and occlusion, and realizes real-time fall detection across different environments, improving detection performance and stability.
Smart Images

Figure CN119229373A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of fall detection, and in particular to a fall detection and alarm method, device, medium and product. Background Art
[0002] With the rapid development of science and technology, surveillance cameras are increasingly deployed in various public places, providing strong support for public safety and personal health monitoring. As one of the important applications of intelligent monitoring technology, video image-based fall detection technology has shown significant application value in many fields such as elderly care, child safety, sports health, etc. By monitoring video images in real time, potential fall events can be automatically detected and identified, so that timely response measures can be taken to effectively prevent the occurrence of injury accidents.
[0003] However, in practical applications, image degradation has become one of the important factors affecting the accuracy of fall detection. Image degradation may be caused by a variety of factors, including but not limited to blur, occlusion, and illumination changes. These factors not only reduce image quality, but also increase the complexity and challenge of the detection algorithm. For example, blurry images may lead to unclear human contours, occlusion may cover up key feature information, and illumination changes may produce shadows and reflections, further interfering with the accuracy of the detection algorithm.
[0004] Traditional fall detection methods mostly rely on simple image processing techniques and machine learning algorithms, which lack sufficient robustness and adaptability, making it difficult to effectively deal with image degradation problems. Therefore, in complex environments, traditional methods are often prone to false positives or false negatives, which seriously affects the accuracy and reliability of fall detection.
[0005] In order to overcome the limitations of traditional methods and improve the accuracy and real-time performance of fall detection, researchers began to explore solutions based on advanced technologies such as deep learning. Among them, the YOLO (You Only Look Once) series of algorithms have attracted widespread attention for their excellent detection performance and real-time performance. However, the YOLO algorithm still has certain limitations when dealing with complex image degradation problems.
[0006] Therefore, how to improve the accuracy of fall detection in complex environments has become one of the current research hotspots. Summary of the invention
[0007] The purpose of this application is to provide a fall detection and alarm method, device, medium and product that can quickly and accurately detect falls in various image degradation scenarios, thereby achieving real-time detection across different environments.
[0008] To achieve the above objectives, this application provides the following solutions:
[0009] In a first aspect, the present application provides a fall detection and alarm method, the fall detection and alarm method comprising:
[0010] Obtain real-time video data of the area to be detected;
[0011] A fall detection model is constructed based on the YOLOv8n model; the fall detection model is to add a CPA enhancer module, an improved C2f module and adopt an Inner-EIoU loss function on the basis of the YOLOv8n model; the CPA enhancer module is used to dynamically analyze and adapt to image degradation through CoT prompts; the improved C2f module is to replace the bottleneck module in C2f with a ParametersNet structure;
[0012] Use the trained fall detection model to perform fall detection on the real-time video data of the detection area;
[0013] When the detection result shows that there is a fall, the alarm mechanism is triggered to sound an alarm.
[0014] Optionally, the acquiring real-time video data of the area to be detected specifically includes:
[0015] Using a surveillance camera to obtain real-time video data of the area to be detected; the surveillance camera has a built-in intelligent light control system and night vision function; the intelligent light control system is used to automatically adjust exposure parameters according to ambient light;
[0016] The surveillance camera adjusts the video frame rate according to the scene changes and detection results of the area to be detected.
[0017] Optionally, the CPA enhancer module comprises: a first RFAConv unit and a 4-level hierarchical encoder-decoder unit;
[0018] The first RFAConv unit is used to extract the underlying features of real-time video data;
[0019] Each level of the 4-level hierarchical encoder-decoder unit processes the underlying features through the RFAConv sub-unit to generate enhanced features; and combines the enhanced features with the real-time video data.
[0020] Optionally, the ParametersNet structure includes a first DBR unit and a second DBR unit; a first output end of the first DBR unit is connected to an input end of the second DBR unit, and a second output end of the first DBR unit is connected to an output end of the second DBR unit.
[0021] Optionally, the first DBR unit and the second DBR unit both include: a dynamic convolution layer, a BatchNorm layer and a ReLU activation function;
[0022] The dynamic convolution layer is used to integrate multiple convolution kernels through an attention mechanism.
[0023] Optionally, the step of acquiring real-time video data of the area to be detected further includes:
[0024] The real-time video data is preprocessed; the preprocessing includes: image denoising, contrast enhancement and resolution adjustment.
[0025] In a second aspect, the present application provides a fall detection and alarm device, the fall detection and alarm device comprising: a surveillance camera and an embedded computing unit;
[0026] The monitoring camera is used to obtain real-time video data of the area to be detected;
[0027] The embedded computing unit is integrated into the surveillance camera; the embedded computing unit is used to build a fall detection model based on the YOLOv8n model; the fall detection model is to add a CPA enhancer module, an improved C2f module and adopt an Inner-EIoU loss function on the basis of the YOLOv8n model; the CPA enhancer module is used to dynamically analyze and adapt to image degradation through CoT prompts; the improved C2f module replaces the bottleneck module in C2f with a ParametersNet structure; the trained fall detection model is used to perform fall detection on real-time video data of the detection area; when the detection result is that there is a fall behavior, the alarm mechanism is triggered to alarm.
[0028] In a third aspect, the present application provides a computer device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the fall detection and alarm method.
[0029] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, which implements the fall detection and alarm method when executed by a processor.
[0030] In a fifth aspect, the present application provides a computer program product, including a computer program, which implements the fall detection and alarm method when executed by a processor.
[0031] According to the specific embodiments provided in this application, this application discloses the following technical effects:
[0032] The present application provides a fall detection and alarm method, device, medium and product, and the improved YOLOv8n algorithm is called PCE-YOLO algorithm; the PCE-YOLO algorithm is to build a fall detection model by adding a Chain-of-Thought Prompted Adaptive (CPA) enhancer module, an improved Channel-to-Pixel (C2f) module and an Inner-EIoU loss function on the basis of the YOLOv8n model; and then the CPA enhancer module dynamically analyzes and adapts to image degradation through Chain-of-Thought (CoT) prompts, The detection accuracy in degraded scenarios such as weak light, fog, rain, snow, and occlusion is improved; the bottleneck module in C2f is replaced by the ParametersNet structure to obtain an improved C2f module, namely the Pm-C2f module; the Pm-C2f module can reduce the number of parameters, size, and computational complexity, which is beneficial to the deployment of terminal devices and can make the fall detection model more lightweight; the Inner-EloU loss function replaces the CloU loss function, that is, the center distance and the minimum closed box size are considered to improve the target positioning accuracy of the fall detection model at different scales; and the Inner-EloU loss function is more capable of handling the problem of large changes in target shape and size caused by angle changes in fall detection scenarios. This application can significantly improve the performance of fall detection in complex environments, and can quickly and accurately detect falls in various image degradation scenarios, thereby achieving real-time detection across different environments. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0034] Figure 1 This is a flow chart of a fall detection and alarm method in one embodiment of the present application;
[0035] Figure 2 It is a schematic diagram of the CPA enhancer module structure;
[0036] Figure 3 It is a schematic diagram of the structure of the Pm-C2f module;
[0037] Figure 4 Schematic diagram of ParametersNet structure;
[0038] Figure 5Schematic diagram of the original and generated image samples in the dataset;
[0039] Figure 6 A schematic diagram showing the comparison of PCE-YOLO and the original YOLOv8 algorithm on different indicators on different datasets;
[0040] Figure 7 Schematic diagram of pedestrian fall detection examples in different image degradation scenarios;
[0041] Figure 8 Schematic diagram of the comparison of five models on different indicators in the ablation experiment. DETAILED DESCRIPTION
[0042] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0043] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.
[0044] In an exemplary embodiment, Figure 1 As shown, a fall detection and alarm method is provided, which includes the following S101 to S104. Among them:
[0045] S101, obtaining real-time video data of the area to be detected;
[0046] S101 specifically includes:
[0047] The surveillance camera is used to obtain real-time video data of the area to be detected; the surveillance camera has a built-in intelligent light control system and night vision function, which can automatically adjust the exposure parameters according to the ambient light to avoid image quality problems caused by overexposure or underexposure; at the same time, it is equipped with a high-performance night vision function to ensure that clear and discernible video images can be obtained at night or in low light conditions; the intelligent light control system is used to automatically adjust the exposure parameters according to the ambient light; the surveillance camera uses a high-resolution, low-latency surveillance camera;
[0048] The surveillance camera adjusts the video frame rate according to the scene changes and detection results of the area to be detected. Specifically, when a moving object or a potential fall event is detected, the frame rate is automatically increased to capture more details, while in static or low-activity areas, the frame rate is reduced to reduce data transmission pressure and storage requirements; key frames are extracted from a continuous video stream at a certain interval (such as extracting several frames per second) as input data; this application can reduce the amount of data processing while retaining sufficient motion information for target detection.
[0049] Reasonably arrange the position and angle of the camera according to the requirements of the area to be inspected to ensure that the surveillance camera covers all blind spots, while minimizing the impact of blind spots and obstructions on video quality.
[0050] To improve image quality and reduce noise interference, S101 and later also include:
[0051] The real-time video data is preprocessed; the preprocessing includes: image denoising, contrast enhancement and resolution adjustment.
[0052] S102, constructing a fall detection model based on the YOLOv8n model; the fall detection model is to add a CPA enhancer module, an improved C2f module and adopt an Inner-EIoU loss function on the basis of the YOLOv8n model; the CPA enhancer module is used to dynamically analyze and adapt to image degradation through CoT prompts; the improved C2f module is to replace the bottleneck module in C2f with a ParametersNet structure;
[0053] ParameterNet is a method that proposes new design principles to increase the number of parameters while keeping FLOPs low. This method introduces dynamic convolution technology, using multiple convolution kernels to dynamically weight according to input features, thereby enhancing the capacity of the model without significantly increasing the computational cost.
[0054] Inner-EIoU is a loss function used in target detection tasks. It is an improvement and variant of the traditional IoU (Intersection over Union) and its extended version EIoU (Extended Intersection over Union). The purpose of Inner-EIoU is to better measure the overlap between the predicted box and the true box to improve the accuracy and efficiency of target detection.
[0055] IoU (Intersection over Union), that is, the intersection over union ratio. The closer the IoU value is to 1, the more overlap there is between the predicted box and the true box, and the better the detection effect. The IoU value is usually used to define the matching conditions in the target detection task. For example, IoU>0.5 is considered a correct detection.
[0056] like Figure 2 As shown, the CPA enhancer module includes: a first receptive-field attention convolution (RFAConv) unit and a 4-level hierarchical encoder-decoder unit;
[0057] The first RFAConv unit is used to extract the underlying features of real-time video data; the RFAConv unit is a new type of convolution operation designed to improve the performance of convolutional neural networks. This technology optimizes the working method of the convolution kernel by introducing the receptive field attention mechanism, especially when processing spatial features within the receptive field;
[0058] Each level of the 4-level hierarchical encoder-decoder unit processes the underlying features F through the RFAConv subunit o ; The encoder part is from the underlying feature F o First, we reduce the spatial size by downsampling to generate low-resolution latent features F l , the decoder part will F l Restore to high-resolution feature F h , and generate enhanced features F through RFAConv e ; and enhance feature F e Combined with real-time video data, output feature I e ;
[0059] like Figure 3 As shown in the figure, the improved C2f module introduces the ParametersNet structure, reduces the number of parameters, and replaces the bottleneck module in C2f; the parameters of the improved C2f module are 2.2 million, the computational effort is 5.8GFLOPs, and the performance is comparable to that of the original C2f module;
[0060] ParametersNet replaces the bottleneck module in C2f and redefines it as Pm bottleneck. The Pm bottleneck is as follows Figure 4As shown, the ParametersNet structure includes a first DBR unit and a second DBR unit; the first output end of the first DBR unit is connected to the input end of the second DBR unit, and the second output end of the first DBR unit is connected to the output end of the second DBR unit. The Pm bottleneck uses a DBR unit to replace the two convolutional block structures (CBS) units in the original bottleneck structure; the DBR module includes a dynamic convolution layer (DynamicConvolution), followed by a batch normalization (BatchNorm) layer and a ReLU activation function; the dynamic convolution layer integrates multiple convolution kernels through an attention mechanism to improve the performance of the model; the attention mechanism allows different convolution kernels to be used for different images, further enhancing the performance of the model; for a given input feature map X and each convolution weight matrix W, the dynamic convolution layer first needs to calculate the dynamic coefficient γ corresponding to each matrix i ; The calculation process of γ is shown in the formula: γ = softmax(MLP(Pool(X))); For different input samples X, global average pooling is first used to fuse the input information into a vector; then, the two-layer MLP module with softmax activation dynamically generates coefficients; After calculating the dynamic coefficient γ, the dynamic convolution calculation process of N dynamic experts is as follows: Y = X × W′,
[0061] The Inner-EIoU loss function combines the advantages of EIoU and Inner-IoU, has the aspect ratio consistency constraint and bounding box optimization of EIoU, and adds the internal area evaluation of Inner-IoU; in complex scenarios, such as occlusion, multiple distractors and small target detection, it can more accurately locate and adjust the prediction box; Inner-EIoU dynamically adjusts the weights in the loss function, adaptively balances difficult and easy samples, and enhances the robustness and convergence speed of the model; in practical applications, Inner-EIoU can significantly improve the detection accuracy and stability of the fall detection model, providing strong support for pedestrian fall detection systems.
[0062] S103, using the trained fall detection model to perform fall detection on the real-time video data of the detection area;
[0063] S104: When the detection result shows that a fall occurs, an alarm mechanism is triggered to sound an alarm.
[0064] When a fall is detected, the system supports multiple alarm modes such as sound, light flash, and text message, which can be flexibly selected according to the on-site environment and needs; for example, in a noisy environment, light flash and text message alarms can be selected to ensure that the alarm information can be conveyed to relevant personnel in a timely manner.
[0065] Alarms are prioritized according to the severity and urgency of the fall. For falls that indicate suspected serious injuries or where no one is helping for a long period of time, the system will automatically increase the alarm priority and seek help through more urgent alarm methods (such as automatically calling emergency numbers). The system supports connection to a remote monitoring platform, and transmits fall detection videos and alarm information in real time to the monitoring center or the relevant person in charge’s mobile phone APP, enabling remote monitoring and instant notification functions.
[0066] Among them, the determination of the severity and urgency of the fall behavior specifically includes the following methods:
[0067] 1. Pose Estimation
[0068] The posture estimation algorithm detects key points of the human body (such as the head, shoulders, knees, etc.) and determines changes in the human body posture. When falling, the human body posture will change significantly, for example:
[0069] Posture angle: If the body is in a horizontal position (lying down) after a fall and remains still for a long time, it can be considered that the fall is serious.
[0070] Key point location: For example, landing on the head or back may be more dangerous than landing on other parts (such as limbs). The distribution of key points estimated based on posture and combined with contact points can determine the severity of the fall.
[0071] 2. Speed and displacement during the fall
[0072] Image algorithms can track the trajectory and speed of a person's fall through frame-to-frame changes. For example:
[0073] Falling speed: If a person falls quickly in a short period of time, it may mean that the fall was more forceful.
[0074] Displacement: Analyze the size of the human body's displacement during the fall. If the displacement is large and stops suddenly, it means that the impact force is large and may cause serious injury.
[0075] 3. The time your body remains stationary after it touches the ground
[0076] Static time analysis: Use image algorithms to detect whether the body remains motionless for a long time after a fall. If there is no movement for a long time after a fall, it may mean that the person has lost consciousness or suffered more serious injuries.
[0077] Recovery attempts: If the person who has fallen is detected trying to stand up or move, the injury can be considered minor; conversely, if they are unable to stand up or resume activities, the severity of the fall is higher.
[0078] The following is an explanation through a specific embodiment: 7782 images were collected from the Internet, which depicted pedestrians falling in various scenes and annotated pedestrians in a falling state; in order to further simulate potential complex scenes and verify the performance of the fall detection model, this application synthesized degraded images including four types of real-life scenes based on the original images: low light, blur and occlusion, resulting in three additional data sets. The synthesized images of the image degradation scene are as follows: Figure 5 As shown; Figure 5 Two examples from image data are shown in the figure; the first column shows the original image; the second column shows the low-light scene simulated by changing the brightness of the original image; the third column shows the blurred scene simulated by adding blur effect and white scattering; the fourth column simulates local occlusion by adding black occlusion blocks; in order to verify the performance of the fall detection model under different image degradation conditions, the fall detection model will be trained and tested on these four different datasets.
[0079] The 7782 collected images and images synthesized under three degraded environments were divided into three sets of data sets: training, validation and testing in a ratio of 8:1:1, resulting in four data sets. The training set contains 80% of the images, while the validation set and the test set each contain 10% of the images. The original algorithm and the improved algorithm are trained, validated and tested on these four data sets to ensure a comprehensive evaluation of the performance of the model in different scenarios. During the training process, the Mosaic data augmentation function was disabled in the last 10 epochs of the training process in order to accelerate convergence.
[0080] Figure 5 The comparison of different scales of the proposed PCE-YOLO algorithm and the original YOLOv 8 algorithm on the original Fall image dataset and three other degraded image datasets is given; Figure 5As shown in the figure, when the PCE-YOLO algorithm processes the original Fall image dataset, its mAP0.5 is 3.31% higher than YOLOv8n, reaching 92.94%, and 1.54% higher than YOLOv8s; in the low-light degradation scene (Low-Light_fall), the mean average precision (meanAveragePrecision, mAP) of the PCE-YOLO algorithm is 91.47%, which is 4.4% and 1.57% higher than the mAPs of YOLOv8n and YOLOv8s respectively; in the occlusion degradation scene ( In the occlusion_fall dataset), PCE-YOLO's mAP is 88.14%, which is 4.71% and 3.03% higher than YOLOv8n and YOLOv8s respectively; in the fuzzy degradation scene (Fuzzy_fall dataset), PCE-YOLO's mAP is 87.67%, which is 5.71% and 2.78% higher than YOLOv8n and YOLOv8s respectively; In summary, the performance of the PCE-YOLO algorithm in various image degradation scenarios is better than the original YOLOv8n and YOLOv8s algorithms.
[0081] In order to deploy the fall detection model on the terminal platform, it is necessary to compare the model parameters, computational complexity, model size and FPS; for detailed data comparison, see Figure 6 ,like Figure 6 As shown in the figure, the parameters of the PCE-YOLO algorithm are 2.8M, which is less than 3.15M of YOLOv8n, but less than 11.16M of YOLOv8s, indicating that the PCE-YOLO algorithm has a lower number of parameters and complexity; in terms of computational complexity, the GFLOPs of the PCE-YOLO algorithm is 18.6, which is higher than 8.6 of YOLOv8n, but much lower than 28.8GFLOPs of YOLOv8s, indicating that the PCE-YOLO algorithm reduces the computational requirements while maintaining performance; the model size of the PCE-YOLO algorithm is 5.6MB, which is smaller than 6.1MB of YOLOv8n and 21.05MB of YOLOv8s, which makes the PCE-YOLO algorithm lighter and easier to deploy on terminal devices; although the PCE-YOLO algorithm introduces the CPA enhancement module to improve performance, its frame rate (Frames Per Second, FPS) is 210.5, which is lower than YOLOv8n's 273.5 and YOLOv8s's 253.7; In summary, the PCE-YOLO algorithm has advantages in the number of parameters, computational complexity, and model size.
[0082] Figure 7The object detection performance comparison between PCE-YOLO and YOLOv8s under different image degradation conditions is demonstrated; the PCE-YOLO algorithm can detect all instances of people falling in low-light, occlusion and blur degradation scenes; YOLOv8s missed one fall instance in low-light degradation, one in occlusion degradation, and two in blur degradation; actual verification shows that the detection performance of the PCE-YOLO algorithm is significantly better than that of YOLOv8s.
[0083] This application verifies the effectiveness of the improvement strategy through ablation experiments. Five different models are designed in the experiment to study the impact of the increase in network structure branches on model performance; the first group of models (M1) is the unimproved YOLOv8n algorithm as a benchmark; the second group of models (M2) adds a CPA enhancement module on the basis of YOLOv8n; the third group of models (M3) improves the C2f module of YOLOv8n and replaces it with Pm-C2f; the fourth group of models (M4) combines the improvements of the second and third groups, that is, the CPA enhancement module and the Pm-C2f module are used in YOLOv8n at the same time; the fifth group of models (M5) is the PCE-YOLO algorithm proposed in this application, which further uses the Inner-EIoU technology on the basis of the fourth group of models; the experimental results are Figure 8 In the figure, M1 to M5 represent the five models; the ablation experiment results show that after the introduction of the CPA-Enhancer module, the generalization ability of the M2 model is improved, and the mAP is 3.13% higher than that of the M1 model; the M3 model improves the C2f module on the basis of M1, improves the mAP, reduces the number of parameters and the number of gigafloating point operations per second (GFLOPs), and increases the FPS to 288; the mAP of the M4 model reaches 88.95%, surpassing M1, M2 and M3 in performance, and the model is lighter; the M5 model integrates all improvement strategies, and the mAP is further improved to 90.04%, the number of parameters is reduced, and the GFLOPs and FPS performance are better than M2; it can be seen that the present application can effectively improve the model performance, including generalization ability, computational efficiency and speed.
[0084] Based on the same inventive concept, the embodiment of the present application also provides a fall detection and alarm device for implementing the above-mentioned fall detection and alarm method. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above-mentioned method, so the specific limitations in one or more fall detection and alarm device embodiments provided below can refer to the above-mentioned limitations on the fall detection and alarm method, and will not be repeated here.
[0085] In an exemplary embodiment, a fall detection and alarm device is provided, comprising: a surveillance camera and an embedded computing unit;
[0086] The monitoring camera is used to obtain real-time video data of the area to be detected;
[0087] The embedded computing unit is integrated into the surveillance camera; the embedded computing unit is used to build a fall detection model based on the YOLOv8n model; the fall detection model is to add a CPA enhancer module, an improved C2f module and adopt an Inner-EIoU loss function on the basis of the YOLOv8n model; the CPA enhancer module is used to dynamically analyze and adapt to image degradation through CoT prompts; the improved C2f module replaces the bottleneck module in C2f with a ParametersNet structure; the trained fall detection model is used to perform fall detection on real-time video data of the detection area; when the detection result is that there is a fall behavior, the alarm mechanism is triggered to alarm.
[0088] In order to continuously improve the detection performance, feedback data is collected during the detection process, and the fall detection model is continuously optimized and trained. By analyzing false detections, missed detections, etc., the model parameters and structure are adjusted to adapt to more complex practical application scenarios.
[0089] Embedded computing units such as FPGA, ASIC or high-performance CPU / GPU modules process the real-time video data obtained by the surveillance camera; configure the data interface between the surveillance camera and the embedded computing unit to ensure that the video stream can be efficiently and stably transmitted to the computing unit for processing. At the same time, set up the necessary input and output interfaces to feedback the detection results to the user in real time or upload them to the cloud server.
[0090] In an exemplary embodiment, a computer device is provided, which may be a server or a terminal. The computer device includes a processor, a memory, an input / output interface (I / O for short) and a communication interface. The processor, the memory and the input / output interface are connected via a system bus, and the communication interface is connected to the system bus via the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, a fall detection and alarm method is implemented.
[0091] In an exemplary embodiment, a computer-readable storage medium is provided, storing a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.
[0092] In an exemplary embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.
[0093] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.
[0094] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM may be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).
[0095] The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. The non-relational database may include a distributed database based on blockchain, etc., but is not limited thereto. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but is not limited thereto.
[0096] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0097] This article uses specific examples to illustrate the principles and implementation methods of this application. The description of the above embodiments is only used to help understand the method and core ideas of this application. At the same time, for those skilled in the art, according to the ideas of this application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting this application.
Claims
1. A fall detection and alarm method, characterized in that: The fall detection and alarm method comprises: Obtain real-time video data of the area to be detected; A fall detection model is constructed based on the YOLOv8n model; the fall detection model is to add a CPA enhancer module, an improved C2f module and adopt an Inner-EIoU loss function on the basis of the YOLOv8n model; the CPA enhancer module is used to dynamically analyze and adapt to image degradation through CoT prompts; the improved C2f module is to replace the bottleneck module in C2f with a ParametersNet structure; Use the trained fall detection model to perform fall detection on the real-time video data of the detection area; When the detection result shows that there is a fall, the alarm mechanism is triggered to sound an alarm.
2. The fall detection and alarm method according to claim 1, characterized in that: The obtaining of real-time video data of the area to be detected specifically includes: Using a surveillance camera to obtain real-time video data of the area to be detected; the surveillance camera has a built-in intelligent light control system and night vision function; the intelligent light control system is used to automatically adjust exposure parameters according to ambient light; The surveillance camera adjusts the video frame rate according to the scene changes and detection results of the area to be detected.
3. The fall detection and alarm method according to claim 1, characterized in that: The CPA enhancer module includes: a first RFAConv unit and a 4-level hierarchical encoder-decoder unit; The first RFAConv unit is used to extract the underlying features of real-time video data; Each level of the 4-level hierarchical encoder-decoder unit processes the underlying features through the RFAConv sub-unit to generate enhanced features; and combines the enhanced features with the real-time video data.
4. The fall detection and alarm method according to claim 1, characterized in that: The ParametersNet structure includes a first DBR unit and a second DBR unit; a first output end of the first DBR unit is connected to an input end of the second DBR unit, and a second output end of the first DBR unit is connected to an output end of the second DBR unit.
5. The fall detection and alarm method according to claim 4, characterized in that: The first DBR unit and the second DBR unit both include: a dynamic convolution layer, a BatchNorm layer and a ReLU (rectified linear unit) activation function; The dynamic convolution layer is used to integrate multiple convolution kernels through an attention mechanism.
6. The fall detection and alarm method according to claim 1, characterized in that: The step of acquiring real-time video data of the area to be detected further includes: The real-time video data is preprocessed; the preprocessing includes: image denoising, contrast enhancement and resolution adjustment.
7. A fall detection and alarm device, characterized in that: The fall detection and alarm device includes: a surveillance camera and an embedded computing unit; The monitoring camera is used to obtain real-time video data of the area to be detected; The embedded computing unit is integrated into the surveillance camera; the embedded computing unit is used to build a fall detection model based on the YOLOv8n model; the fall detection model is to add a CPA enhancer module, an improved C2f module and adopt an Inner-EIoU loss function on the basis of the YOLOv8n model; the CPA enhancer module is used to dynamically analyze and adapt to image degradation through CoT prompts; the improved C2f module replaces the bottleneck module in C2f with a ParametersNet structure; the trained fall detection model is used to perform fall detection on real-time video data of the detection area; when the detection result is that there is a fall behavior, the alarm mechanism is triggered to alarm.
8. A computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the fall detection and alarm method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the fall detection and alarm method according to any one of claims 1 to 6 is implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the fall detection and alarm method according to any one of claims 1 to 6 is implemented.
