Method, device, equipment and medium for identifying turning over of infants and young children when their bodies are covered

Through depth field calculation and image processing technology, it solves the problem of detecting infants and young children turning over when they are covered by obstructions, achieves accurate recognition and timely reminders under occlusion conditions, and improves the safety of infants and young children.

CN118379320BActive Publication Date: 2024-09-13NINGBO SIMSHINE INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410816587.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-24
Publication Date
2024-09-13
Estimated Expiration
2044-06-24

AI Technical Summary

Technical Problem

Existing technology makes it difficult to accurately detect infants and young children turning over when they are covered by an obstruction, resulting in monitoring difficulties and safety risks.

Method used

Depth field calculation and image processing technology are used to obtain real-time images in infant care scenarios, perform pre-analysis and depth field calculations, generate depth images to identify infants and toddlers turning over, and use depth information and filtering to reduce the impact of light changes. .

Benefits of technology

It can accurately detect the rolling movements of infants and young children when there are obstructions, which improves safety, reduces false alarms, and can maintain stable monitoring effects at night or in environments with insufficient light.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118379320B
    Figure CN118379320B
Patent Text Reader

Abstract

The present invention relates to the field of infant care technology, solves the problem in the prior art that it is impossible to accurately detect the turning over of infants under the condition of being covered by obstructions such as quilts, and provides a method, device, equipment and medium for identifying turning over when the body of an infant is obstructed. The method comprises: obtaining a real-time image in an infant care scene; pre-analyzing the real-time image, and when it is determined that the infant is located in a preset target area, obtaining the sleeping direction of the infant; performing depth field calculation on the real-time image after pre-analysis, and outputting adjacent first depth images and second depth images; processing the first depth image and the second depth image according to the sleeping direction of the infant to identify the turning over of the infant. The present invention can accurately detect the turning over of infants under the condition of being covered by obstructions such as quilts, and promptly remind the user, thereby ensuring the safety of the infant.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of infant care, and in particular to a method, device, equipment and medium for identifying turning over of an infant when the infant's body is obscured. Background Art

[0002] Detecting the turning over of infants and young children is crucial for monitoring their growth and development and ensuring their safety. Turning over is an important milestone in the early development of infants, marking the progress of their muscle development and motor coordination. Being able to accurately monitor this movement can not only help parents or guardians understand the development of their infants, but also prevent potential safety risks, such as preventing infants from suffocating or getting injured during turning over when they are unattended. However, in order to keep infants and young children warm, they are usually covered with quilts and other coverings. At this time, it becomes more difficult to accurately detect the turning over of infants and young children under the condition of being covered by quilts and other coverings. These coverings may not only limit the movement of infants and reduce the success rate of turning over, but also bring challenges to monitoring, because quilts and other objects may block the line of sight of the monitoring equipment, making it difficult for guardians to judge the exact position and movement of the baby. Therefore, the development of technologies and methods that can penetrate these coverings for effective monitoring is of great significance to ensure the safety of infants and young children and promote their healthy development.

[0003] The existing Chinese patent CN117173784A discloses a method, device, equipment and storage medium for detecting the turning over of infants and young children, the method comprising: obtaining a real-time video stream in an infant care scene, decomposing the real-time video stream into multiple frames of images; performing an infant face occlusion judgment on each of the images, and identifying the infant face occlusion situation; when it is identified that the infant face is not occluded, performing a facial analysis on the infant face, and outputting the infant face orientation; when the infant face orientation is a frontal face, detecting the turning over of the infant, and outputting the detection result. The above scheme relies on first identifying whether the infant face is occluded, and then further detecting the turning over of the infant when the face is not occluded and is a frontal face. However, when the infant is covered by obstructions such as quilts, the solution cannot accurately perform face detection and analysis, and therefore cannot effectively identify the orientation of the infant's face, which in turn affects the detection of turning over. This is mainly because the obstruction blocks the line of sight, making it impossible for the system to obtain the necessary facial features and body movement information, and thus unable to determine whether the infant has turned over.

[0004] Therefore, how to accurately detect the turning over action of infants and young children under the condition of being covered by covering objects such as quilts is an urgent problem to be solved. Summary of the invention

[0005] In view of this, the present invention provides a method, device, equipment and medium for identifying turning over of an infant when the body is obscured, so as to solve the problem in the prior art of accurately detecting the turning over action of an infant when there is no obstruction such as a quilt.

[0006] The technical solution adopted by the present invention is:

[0007] In a first aspect, the present invention provides a method for identifying turning over of an infant when the infant's body is obscured, the method comprising:

[0008] Get real-time images of infant care scenarios;

[0009] Pre-analyzing the real-time image, and obtaining the sleeping direction of the infant when it is determined that the infant is located in a preset target area;

[0010] Performing depth field calculation on the pre-analyzed real-time image, and outputting adjacent first depth image and second depth image;

[0011] The first depth image and the second depth image are processed according to the sleeping orientation of the infant to identify the turning over action of the infant.

[0012] Preferably, the pre-analysis of the real-time image, when it is determined that the infant is located in a preset target area, obtaining the sleeping orientation of the infant includes:

[0013] Inputting the real-time image into a pre-trained target detection model and outputting an infant head detection result;

[0014] If the head of an infant is detected, the position information of the head of the infant is obtained;

[0015] Acquire an image of the infant's head region according to the infant's head position information;

[0016] Perform image segmentation processing on the image of the infant's head area to obtain the sleeping orientation of the infant.

[0017] Preferably, performing image segmentation processing on the image of the infant's head region to obtain the infant's sleeping orientation includes:

[0018] Performing grayscale processing on the image of the infant's head region and outputting a grayscale image;

[0019] Performing threshold segmentation processing on the grayscale image to segment the grayscale image into a face area image and a hair area image;

[0020] Acquire first center point position information of the face area image and second center point position information of the hair area image;

[0021] The sleeping orientation of the infant is determined according to the first center point position information and the second center point position information.

[0022] Preferably, performing depth field calculation on the pre-analyzed real-time image and outputting adjacent first depth images and second depth images comprises:

[0023] Acquire a first image and a second image adjacent to each other in a real-time image;

[0024] Performing Gaussian filtering and median filtering on the first image and the second image, and outputting a first target image and a second target image after the filtering;

[0025] The first target image and the second target image are input into a depth calculation model, and a first depth image and a second depth image are output.

[0026] Preferably, the processing of the first depth image and the second depth image according to the sleeping orientation of the infant to identify the turning over action of the infant comprises:

[0027] Determining a depth difference image based on the first depth image and the second depth image;

[0028] Extracting features from the depth difference image, and outputting real-time spatial change intensity and real-time spatial change width;

[0029] Determining the location information of a third center point of the spatial change area according to the real-time spatial change extent;

[0030] If it is determined that the third center point is above the straight line where the infant sleeps, based on the position information of the third center point, a first threshold corresponding to a preset spatial variation intensity and a second threshold corresponding to a preset spatial variation width are obtained;

[0031] When the real-time spatial change intensity is greater than the first threshold and the real-time spatial change breadth is greater than the second threshold, it is identified as a turning over action of the infant.

[0032] Preferably, the extracting features from the depth difference image and outputting the real-time spatial variation intensity and the real-time spatial variation width comprises:

[0033] Accumulating the spatial change values ​​corresponding to the multiple frames of depth difference images, and outputting the total spatial change value as the real-time spatial change intensity;

[0034] Each of the spatial variation values ​​is compared with a preset spatial variation breadth evaluation threshold to determine the real-time spatial variation breadth.

[0035] Preferably, the obtaining of a preset first threshold corresponding to the spatial variation intensity and a second threshold corresponding to the spatial variation width comprises:

[0036] Acquire sample depth images of various target scenes related to infants and young children being blocked by obstructions, and acquire rolling action record data corresponding to the sample depth images;

[0037] According to the turning action record data, a first sequence corresponding to the sample space change intensity and a second sequence corresponding to the sample space change width are obtained;

[0038] Statistics are performed on the first sequence and the second sequence, and a minimum value in the first sequence is used as the first threshold, and a minimum value in the second sequence is used as the second threshold.

[0039] In a second aspect, the present invention provides a device for identifying turning over when the body of an infant is obscured, the device comprising:

[0040] An image acquisition module, used to acquire real-time images in infant care scenarios;

[0041] A pre-analysis module is used to pre-analyze the real-time image and obtain the sleeping direction of the infant when it is determined that the infant is located in a preset target area;

[0042] A depth analysis module, used to perform depth field calculation on the pre-analyzed real-time image and output adjacent first depth images and second depth images;

[0043] The turning over detection module is used to process the first depth image and the second depth image according to the sleeping direction of the infant to identify the turning over action of the infant.

[0044] In a third aspect, an embodiment of the present invention further provides an electronic device, comprising: at least one processor, at least one memory, and computer program instructions stored in the memory, which, when executed by the processor, implement the method of the first aspect in the above-mentioned embodiment.

[0045] In a fourth aspect, an embodiment of the present invention further provides a storage medium on which computer program instructions are stored, and when the computer program instructions are executed by a processor, the method of the first aspect in the above-mentioned embodiment is implemented.

[0046] In summary, the beneficial effects of the present invention are as follows:

[0047] The present invention provides a method, device, equipment and medium for identifying turning over of an infant when the body is obscured. The method comprises: obtaining a real-time image in an infant care scene; pre-analyzing the real-time image, and when it is determined that the infant is located in a preset target area, obtaining the sleeping direction of the infant; performing depth field calculation on the real-time image after the pre-analysis, and outputting adjacent first depth images and second depth images; and processing the first depth image and the second depth image according to the sleeping direction of the infant to identify the turning over action of the infant. The present invention uses depth images to detect the turning over movements of infants and young children, which solves the limitations of traditional methods under occlusion conditions. By measuring the distance between the object and the camera to generate an image, the shape and movement of the infant under the quilt and other occlusions can be seen, thereby effectively identifying the turning over and other movements. By using depth images for turning over detection, safety reminders can be issued in time when the infant turns over or makes other potentially dangerous movements, greatly improving the safety of the infant. This immediate response is particularly critical for preventing accidents caused by turning over. The depth image generated by depth field calculation and filtering processing is insensitive to light changes and can maintain a stable monitoring effect at night or in a dimly lit environment. Using depth information for turning over detection can more accurately identify the actual movements of the infant, and effectively reduce false alarms caused by occlusion or light influence compared to methods that only rely on two-dimensional images. Therefore, the present invention can accurately detect the turning over movements of infants and young children under the condition of being covered by quilts and other occlusions, and remind users in time, thereby ensuring the safety of the infant. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In order to more clearly illustrate the technical solution of the embodiment of the present invention, the drawings required for use in the embodiment of the present invention will be briefly introduced below. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work, and these are all within the protection scope of the present invention.

[0049] Figure 1 It is a schematic diagram of the overall working process of the method for identifying turning over when the body of an infant is obscured in Embodiment 1 of the present invention;

[0050] Figure 2 This is a schematic diagram of a process for pre-analyzing the real-time image in Embodiment 1 of the present invention;

[0051] Figure 3 This is a schematic diagram of the process of performing image segmentation processing on the infant head region image in Embodiment 1 of the present invention;

[0052] Figure 4 This is a schematic diagram of the process of performing depth field calculation and filtering processing on a real-time image after pre-analysis in Embodiment 1 of the present invention;

[0053] Figure 5It is a schematic diagram of the process of performing turnover detection on the depth image in Embodiment 1 of the present invention;

[0054] Figure 6 Schematic diagram of the process of extracting features from the depth difference image in Embodiment 1 of the present invention;

[0055] Figure 7 This is a schematic diagram of a process for obtaining a first threshold and a second threshold in Embodiment 1 of the present invention;

[0056] Figure 8 This is a structural block diagram of a device for identifying turning over when the body of an infant is obscured in Embodiment 2 of the present invention;

[0057] Fig. 9 It is a schematic diagram of the structure of the electronic device in Embodiment 3 of the present invention. DETAILED DESCRIPTION

[0058] In order to make the purpose, technical solution and advantages of the embodiment of the present invention clearer, the technical solution in the embodiment of the present invention will be clearly and completely described in conjunction with the drawings in the embodiment of the present invention. It should be noted that, in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is any such actual relationship or order between these entities or operations. In the description of the present invention, it should be understood that the orientation or position relationship indicated by the terms "center", "upper", "lower", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc. is based on the orientation or position relationship shown in the drawings, which is only for the convenience of describing the present application and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation of the present invention. Moreover, the term "include", "comprise" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such a process, method, article or device. In the absence of further restrictions, the elements defined by the phrase "comprising..." do not exclude the existence of other identical elements in the process, method, article or device comprising the elements. If there is no conflict, the embodiments of the present invention and the various features in the embodiments can be combined with each other, all within the protection scope of the present invention.

[0059] Example 1

[0060] See also Figure 1 Embodiment 1 of the present invention discloses a method for identifying turning over of an infant when the infant's body is obscured, the method comprising:

[0061] Get real-time images of infant care scenarios;

[0062] Specifically, a monocular camera is used with a 940nm infrared fill light to continuously capture real-time image sequences in the activity area of ​​the infants and young children being cared for. By combining visible light imaging and infrared fill light technology, the activities of infants and young children can be effectively monitored under different lighting conditions. A monocular camera refers to a device with only one camera. Compared with a multi-camera system, it is more economical, simpler to install and maintain. With a 940nm infrared fill light, this device can capture clear images in low-light or even completely dark environments. At the same time, 940nm infrared light is almost invisible to the human eye, which means it It will not disturb the sleep of infants and young children at night, while still providing sufficient light for the camera to capture high-quality images. This is especially suitable for all-weather infant care and monitoring, ensuring that parents or caregivers can understand the safety status and activities of infants and young children through image sequences during the day or at night. In addition, with the help of image processing and analysis technologies, such as motion detection and behavior recognition, the solution can also achieve more advanced monitoring functions, such as automatically detecting abnormal activities, turning over, crying, etc. of infants and young children, and sending alarms or notifications to caregivers in a timely manner, greatly improving the safety of infants and young children and the convenience of care.

[0063] Pre-analyzing the real-time image, and obtaining the sleeping direction of the infant when it is determined that the infant is located in a preset target area;

[0064] Specifically, the pre-analysis process in the real-time image determines whether the infant is in a preset target area, which includes at least: an infant bed and a cradle. When the infant is in the preset target area, the sleeping orientation of the infant is further obtained. This pre-analysis process helps to identify the position and posture of the infant, providing a more accurate information basis for subsequent monitoring and safety reminders.

[0065] In one embodiment, see Figure 2 , the turning over identification of the infant or child when the body is covered includes:

[0066] Inputting the real-time image into a pre-trained target detection model and outputting an infant head detection result;

[0067] If the head of an infant is detected, the position information of the head of the infant is obtained;

[0068] Specifically, the real-time image is input into a pre-trained target detection model, wherein the target detection model includes a deep learning model based on the YoloV8s architecture. Prior to this, the target detection model needs to be trained with a large-scale data set to learn and identify the features of the infant's head. The training process involves data collection, labeling, model selection and parameter tuning. Through iterative training of a large amount of data, the model is gradually optimized and finally achieves a high detection accuracy. Once the training is successfully completed and deployed in real-time monitoring, the head position of the infant can be stably and efficiently detected, providing accurate and reliable data support for subsequent monitoring and safety reminders. If the infant's head is detected by the target detection model, the infant's head position information Head(x,y,w,h) is obtained, where (x, y) represents the upper left corner coordinates of the head position, that is, the starting point position of the head area; and (w, h) represents the width and height of the head area, which is used to describe the size of the head area. Therefore, overall, Head(x,y,w,h) represents the position and size information of the area where the infant's head is located in the detected image.

[0069] Acquire an image of the infant's head region according to the infant's head position information;

[0070] Specifically, based on the infant's head position information obtained previously, an image segment of the head area, namely, the infant's head area image, is extracted from the original image. This step is based on the head position information. The head position is located in the original image, and the image segment of the head area is obtained by intercepting it according to the coordinates and size of the head position.

[0071] Perform image segmentation processing on the image of the infant's head area to obtain the sleeping orientation of the infant.

[0072] Specifically, the acquired image of the infant's head area is subjected to image segmentation processing. Image segmentation includes the process of decomposing the image into several areas or objects with specific features. The sleeping orientation of the infant in the head area is identified through image segmentation. This involves the use of computer vision techniques, such as image processing, feature extraction and classifiers, to obtain the sleeping orientation of the infant. By performing image segmentation processing on the infant's head area image, the sleeping orientation information is effectively extracted from the head area image, helping guardians understand the infant's sleeping position and thus better monitor and care for the infant.

[0073] In one embodiment, see Figure 3 The performing image segmentation processing on the image of the infant's head region to obtain the sleeping orientation of the infant includes:

[0074] Performing grayscale processing on the image of the infant's head region and outputting a grayscale image;

[0075] Specifically, first, according to the given head position information Head (x, y, w, h), an image segment of the head area is extracted from the original image and converted into a grayscale image. The image is converted into a grayscale image to simplify the complexity of image processing. The conversion methods include brightness method, maximum method, minimum method, average method and weighted average method, among which the brightness method is the most commonly used. The grayscale image is obtained by weighted averaging the pixel values ​​of the RGB channels. This is to reduce the complexity of the image and facilitate subsequent processing and analysis.

[0076] Performing threshold segmentation processing on the grayscale image to segment the grayscale image into a face area image and a hair area image;

[0077] Specifically, by performing threshold segmentation on the grayscale image, the image is divided into a hair area and a face area, so as to distinguish the hair and face in the head area of ​​the infant. The threshold segmentation is to divide the image into two areas by a pre-set pixel threshold of the segmentation, wherein the pixel value of one area is higher than the threshold, and the pixel value of the other area is lower than the threshold. In this case, the hair and the face can be separated by an appropriate threshold, thereby segmenting the grayscale image into a face area image and a hair area image; for example, the grayscale value of the hair area is set to be lower than the pixel threshold, and the grayscale value of the face area is set to be greater than or equal to the pixel threshold. By clearly distinguishing the hair area and the face area, a basis is provided for subsequent analysis and processing.

[0078] Acquire first center point position information of the face area image and second center point position information of the hair area image;

[0079] Specifically, in the hair region image and the face region image obtained by segmentation, the first center point F1 and the second center point F2 of the two regions are extracted. The extraction method includes: for example, weighted averaging the coordinates of all pixels in the hair region image to obtain the coordinates of the first center point of the hair region image. Morphological operations, such as corrosion, expansion, opening operation or closing operation, can also be used to process the region so as to more accurately locate the center point. For example, the pixels in the hair region image are connected to each other through expansion operation, and then the first center point F1 of the hair region image is calculated. After the first center point F1 and the second center point F2 of the hair region and the face region are extracted, the first center point position information of the face region image and the second center point position information of the hair region image can be accurately marked on the image, which facilitates subsequent analysis and processing.

[0080] The sleeping orientation of the infant is determined according to the first center point position information and the second center point position information.

[0081] Specifically, a vector is formed by connecting the center point F1 of the hair area and the center point F2 of the face area. The direction indicated by this vector is considered to be the sleeping orientation of the infant, based on the fact that the direction of the infant's head is roughly consistent with the orientation of the body. Therefore, the vector formed by F1 to F2 not only indicates the orientation of the head, but also indirectly indicates the orientation of the body. In practical applications, this is particularly helpful when the line of sight is not completely clear, such as when the infant is partially blocked by a quilt. The overall posture of the infant and whether turning over has occurred can still be inferred through the position and orientation of the head. Even when part of the infant's body is blocked, as long as the head area is still visible, the turning over of the infant can be effectively detected by analyzing the movement and orientation changes of the head. It reduces the reliance on completely unobstructed line of sight and improves the accuracy and reliability of monitoring the turning over of infants in actual monitoring scenarios, especially when the line of sight is limited.

[0082] Performing depth field calculation on the pre-analyzed real-time image, and outputting adjacent first depth image and second depth image;

[0083] Specifically, the depth field calculation is performed on the real-time image after pre-analysis, and the adjacent first depth image and second depth image are outputted, which involves converting the two-dimensional real-time image captured by the camera into three-dimensional depth information that can represent the distance of different objects in the scene from the camera. The depth field calculation usually relies on one or more of the following technologies, such as stereoscopic vision, structured light, and time of flight (ToF), to measure or estimate the depth of each point in the scene. After the depth data is calculated, filtering is performed. The purpose of this step is to remove noise and discontinuity in the depth data and improve the quality of the depth image. The filtering processing method includes one or more of the following algorithms: Gaussian filtering, median filtering, bilateral filtering, or edge-preserving filtering technology to ensure that the depth image maintains edge sharpness while reducing errors and inaccuracies. The output depth image provides rich three-dimensional spatial information for subsequent image processing. For example, in the infant monitoring scene, this enables the algorithm to more accurately identify the position, posture, and whether the infant has turned over or other actions, even in complex or low-light environments.

[0084] In one embodiment, see Figure 4 The performing of depth field calculation on the pre-analyzed real-time image and outputting adjacent first depth images and second depth images comprises:

[0085] Acquire a first image and a second image adjacent to each other in a real-time image;

[0086] Specifically, in the real-time video stream of infant monitoring, two adjacent frames of images are captured continuously, referred to as the first image and the second image, respectively. This is to extract dynamically changing information from the time series, such as the infant's slight movement or turning over. The two adjacent frames of images are selected to ensure the continuity and temporal correlation of the captured movements, thereby making subsequent depth calculations and motion detection more accurate and effective.

[0087] Gaussian filtering and median filtering are performed on the first image and the second image, and the first target image and the second target image after the filtering are output.

[0088] Specifically, after acquiring the first image and the second image, the first image and the second image are filtered to improve the quality and consistency of the images. First, Gaussian filtering is applied using a 5x5 filtering template to effectively reduce image noise and smooth the depth information of the image without excessively blurring important edge information. Then, median filtering uses a 3x3 filtering template to further eliminate noise and outliers, especially near depth faults and edges. Through the combination of the two filtering methods, clearer and more coherent filtered first and second target images are obtained, providing a more reliable basis for accurately detecting the turning over movements of infants and young children.

[0089] Inputting the first target image and the second target image into a depth calculation model, and outputting a first depth image and a second depth image;

[0090] Specifically, the first target image and the second target image are respectively input into the monocular depth field calculation model, and the first depth image and the second depth image are output; the monocular depth field calculation model includes a Mobile_Depth model, and the monocular depth field calculation model is specially designed to estimate the depth information from the monocular image, and the output depth image is a relative depth value, which is expressed in the form of a floating point number, for example, at time and At two consecutive moments, the first depth image corresponding to the first target image is calculated respectively A second depth image corresponding to the second target image ,in represents the pixel position on the image, and All are floating point numbers; by extracting the three-dimensional structural information of the scene from the originally flat image, including the relative distance between the infant and the surrounding environment, this is crucial for subsequent action recognition.

[0091] The first depth image and the second depth image are processed according to the sleeping orientation of the infant to identify the turning over action of the infant.

[0092] Specifically, after the first depth image and the second depth image are acquired, the first depth image and the second depth image are used in combination with the sleeping orientation of the infant to perform turnover detection. This process involves dynamically analyzing pixel changes in the first depth image and the second depth image to identify specific patterns or depth changes corresponding to the infant's turnover action. This analysis can be based on machine learning algorithms, especially those models that have been trained for human motion recognition. They can extract infant posture and motion change information from the first depth image and the second depth image. Once a pattern matching the turnover action is detected, a safety reminder mechanism will be immediately activated, including sending a notification to the parent or caregiver's mobile phone application, triggering a visual or audible alarm, thereby ensuring the safety of the infant and reminding the caregiver in real time to respond appropriately. This automated turnover detection and reminder system plays a key role in improving the quality of infant care and preventing accidental injuries, especially when the caregiver cannot monitor full-time.

[0093] In one embodiment, see Figure 5 The processing of the first depth image and the second depth image according to the sleeping orientation of the infant to identify the turning over action of the infant includes:

[0094] Determining a depth difference image based on the first depth image and the second depth image;

[0095] Specifically, depth difference analysis is to capture the spatial position change of the infant by calculating the difference between the first depth image and the second depth image, and the difference image reveals the depth change caused by the movement of the infant. Specifically: Among them, the depth difference image It reflects the changes in spatial depth caused by the movement of infants and young children; in this way, even slight movements can be reflected in the depth difference image, providing basic data for subsequent analysis.

[0096] Extracting features from the depth difference image, and outputting real-time spatial change intensity and real-time spatial change width;

[0097] Specifically, feature extraction is performed on the depth difference image to output real-time spatial change intensity and real-time spatial change breadth; the real-time spatial change intensity I reflects the total amount of change in the depth difference image, and is obtained by calculating the sum of the absolute values ​​of the depth value differences of all pixels in the difference image; the real-time spatial change breadth R measures the spatial range of the depth change, that is, the size of the area occupied by pixels whose changes exceed a certain threshold, and is achieved by calculating the number of pixels that meet certain conditions, the condition being that the depth difference value of the pixel exceeds a predetermined threshold.

[0098] In one embodiment, see Figure 6, the extracting features of the depth difference image and outputting the real-time spatial change intensity and the real-time spatial change width comprises:

[0099] Accumulating the spatial change values ​​corresponding to the multiple frames of depth difference images, and outputting the total spatial change value as the real-time spatial change intensity;

[0100] Each of the spatial variation values ​​is compared with a preset spatial variation breadth evaluation threshold to determine the real-time spatial variation breadth.

[0101] Specifically, based on the depth difference image , extract the spatial change features, accumulate the spatial change values ​​corresponding to the multiple frames of depth difference images, and output the total value of the spatial change as the real-time spatial change intensity; compare each of the spatial change values ​​with the preset spatial change breadth evaluation threshold Comparison is made to determine the extent of the real-time spatial variation.

[0102] Determining the location information of a third center point of the spatial change area according to the real-time spatial change extent;

[0103] Specifically, after analyzing the depth difference image, in order to determine whether the changes are related to the movement behavior of the infant, the spatial position of these changes needs to be further analyzed. The steps here are to find the depth change areas caused by the infant's turning over or other activities, and then determine whether the center position of these areas is consistent with the expected movement trajectory of the infant. First, calculate the center coordinates R (CenterX, CenterY) defined by the change area R (P1 (x, y), P2 (x, y), P3 (x, y), ... Pn (x, y)). This center coordinate reflects the average position of all significantly changed pixels and can be regarded as the "center of gravity" of the change area. This center of gravity position provides an accurate reference point, indicating the center of the area with the most significant depth change.

[0104] If it is determined that the third center point is above the straight line where the infant sleeps, based on the position information of the third center point, a first threshold corresponding to a preset spatial variation intensity and a second threshold corresponding to a preset spatial variation width are obtained;

[0105] Specifically, next, it is determined whether the center coordinate R (CenterX, CenterY) is located on the extension line of the line from the center point F1 of the head to the center point F2 of the face. This determination step is based on the fact that the movement of infants (such as turning over) usually leads to spatial changes consistent with the length direction of the body. If R (CenterX, CenterY) is located on the extension line from F1 to F2, it means that the observed depth change is likely due to the overall movement of the infant rather than local movements or external factors. This effectively links the analysis of spatial depth changes with the body direction of the infant, providing an intuitive and practical means for determining large-scale movement behaviors such as turning over of infants. By identifying depth changes consistent with the expected movement trajectory of infants, the accuracy and reliability of turning over detection can be improved, and it can work effectively even under partial occlusion conditions.

[0106] In one embodiment, see Figure 7 The step of obtaining a preset first threshold corresponding to the spatial variation intensity and a preset second threshold corresponding to the spatial variation width includes:

[0107] Acquire sample depth images of various target scenes related to infants and young children being blocked by obstructions, and acquire rolling action record data corresponding to the sample depth images;

[0108] Specifically, first, it is necessary to obtain sample depth images of various target scenarios related to infants and young children being obscured by obstructions under various environmental conditions (lighting, occlusion, etc.). The sample depth images include images of the infants and young children before and after turning over, as well as control images when no turning over occurs, and the turning over action record data corresponding to the sample depth images is obtained; this is to ensure that the model can work effectively under various actual conditions, while taking into account that different degrees of occlusion may affect the detection of turning over actions.

[0109] According to the turning action record data, a first sequence corresponding to the sample space change intensity and a second sequence corresponding to the sample space change width are obtained;

[0110] Specifically, based on the turning action record data, for each set of data, by analyzing the changes in the depth image before and after the turning action, the change intensity I sequence and the change range R sequence are calculated. These two sequences respectively represent the size and range of the depth change caused by the turning action, and are key indicators for judging whether turning has occurred.

[0111] Statistics are performed on the first sequence and the second sequence, and a minimum value in the first sequence is used as the first threshold, and a minimum value in the second sequence is used as the second threshold.

[0112] Specifically, by statistically analyzing the change intensity I sequence and change range R sequence of all collected turning actions, the minimum change intensity and change range values ​​that can distinguish turning actions from other non-turning states (such as small movements, resting, etc.) are found, and used as thresholds Imin and Rmin respectively. This means that when the subsequent deep image analysis shows that the change intensity and change range exceed these thresholds, it is considered that there is a high probability that a turning action has occurred. The advantage of this solution is that the threshold is set through actual data, which increases the practicality and accuracy of the detection method. By widely collecting data under different conditions, it can ensure that the model is more robust, can adapt to different environmental changes, and accurately identify the turning actions of infants and young children. In addition, this method provides a data-driven way to optimize the accuracy of turning detection through the analysis of a large number of actual situations, reducing false positives and false negatives caused by improper parameter selection.

[0113] When the real-time spatial change intensity is greater than the first threshold and the real-time spatial change breadth is greater than the second threshold, it is identified as a turning over action of the infant.

[0114] Specifically, if the real-time spatial change intensity I is greater than the set first threshold T, and the real-time spatial change breadth R is greater than the set second threshold T, it is identified that the infant has turned over. This means that sufficiently large depth changes are observed in the depth image, and these changes involve a sufficiently large spatial range, which is likely caused by the infant turning over or other large-scale movements. In this way, the turning over of infants can be quickly and accurately identified in real-time monitoring, so as to promptly remind the guardian to provide necessary care and attention. At the same time, since two thresholds are set, the turning over action can be judged more accurately according to the actual situation, reducing the possibility of false alarms and missed alarms, and improving the reliability and practicality of the monitoring system.

[0115] Example 2

[0116] See also Figure 8 Embodiment 2 of the present invention further provides a device for identifying turning over of an infant when the infant's body is obscured, the device comprising:

[0117] An image acquisition module, used to acquire real-time images in infant care scenarios;

[0118] A pre-analysis module is used to pre-analyze the real-time image and obtain the sleeping direction of the infant when it is determined that the infant is located in a preset target area;

[0119] A depth analysis module, used to perform depth field calculation on the pre-analyzed real-time image and output adjacent first depth images and second depth images;

[0120] The turning over detection module is used to process the first depth image and the second depth image according to the sleeping direction of the infant to identify the turning over action of the infant.

[0121] Specifically, a device for identifying turning over when the body of an infant is obscured provided in an embodiment of the present invention includes: an image acquisition module, used to acquire real-time images in an infant care scene; a pre-analysis module, used to pre-analyze the real-time images, and when it is determined that the infant is located in a preset target area, obtain the sleeping direction of the infant; a depth analysis module, used to perform depth field calculation on the real-time images after pre-analysis, and output adjacent first depth images and second depth images; a turning over detection module, used to process the first depth image and the second depth image according to the sleeping direction of the infant, and identify the turning over action of the infant. The device uses depth images to detect the turning over of infants and young children, which solves the limitations of traditional methods under occlusion conditions. By measuring the distance between the object and the camera to generate an image, the shape and movement of the infant under the quilt and other occlusions can be seen, thereby effectively identifying the turning over and other movements; turning over detection by depth images can issue safety reminders in time when the infant turns over or makes other potentially dangerous movements, greatly improving the safety of the infant. This immediate response is particularly critical for preventing accidents caused by turning over; the depth image generated by depth field calculation and filtering processing is insensitive to light changes, and can maintain a stable monitoring effect at night or in a dimly lit environment. Turning over detection using depth information can more accurately identify the actual movements of the infant, and effectively reduce false alarms caused by occlusion or light influence compared to methods that only rely on two-dimensional images; therefore, the present invention can accurately detect the turning over of infants and young children under the condition of being covered by quilts and other obstructions, and promptly remind users, thereby ensuring the safety of infants and young children.

[0122] Example 3

[0123] In addition, combined Figure 1 The method for identifying an infant turning over when the infant's body is obscured according to the first embodiment of the present invention can be implemented by an electronic device. Fig. 9 A schematic diagram of the hardware structure of an electronic device provided in Embodiment 3 of the present invention is shown.

[0124] The electronic device may include a processor and a memory storing computer program instructions.

[0125] Specifically, the processor may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiment of the present invention.

[0126] The memory may include a large capacity memory for data or instructions. By way of example and not limitation, the memory may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. Where appropriate, the memory may include a removable or non-removable (or fixed) medium. Where appropriate, the memory may be inside or outside the data processing device. In a particular embodiment, the memory is a non-volatile solid-state memory. In a particular embodiment, the memory includes a read-only memory (ROM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically rewritable ROM (EAROM) or a flash memory or a combination of two or more of these.

[0127] The processor reads and executes computer program instructions stored in the memory to implement any one of the methods for identifying an infant turning over when the infant's body is obscured in the above embodiments.

[0128] In one example, the electronic device may further include a communication interface and a bus. Fig. 9 As shown, the processor, memory, and communication interface are connected via a bus and communicate with each other.

[0129] The communication interface is mainly used to implement communication between the modules, devices, units and / or equipment in the embodiments of the present invention.

[0130] The bus includes hardware, software or both, and the components of the device are coupled to each other. For example, but not limitation, the bus may include an accelerated graphics port (AGP) or other graphics bus, an enhanced industrial standard architecture (EISA) bus, a front-side bus (FSB), a hypertransport (HT) interconnection, an industrial standard architecture (ISA) bus, an infinite bandwidth interconnection, a low pin count (LPC) bus, a memory bus, a microchannel architecture (MCA) bus, a peripheral component interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a serial advanced technology attachment (SATA) bus, a video electronics standard association local (VLB) bus or other suitable bus or a combination of two or more of these. Where appropriate, the bus may include one or more buses. Although the embodiments of the present invention describe and illustrate a specific bus, the present invention contemplates any suitable bus or interconnection.

[0131] Example 4

[0132] In addition, in combination with the method for identifying turning over when the body of an infant is obscured in the above-mentioned embodiment 1, the embodiment 4 of the present invention can also provide a computer-readable storage medium for implementation. The computer-readable storage medium stores computer program instructions; when the computer program instructions are executed by the processor, any of the methods for identifying turning over when the body of an infant is obscured in the above-mentioned embodiments is implemented.

[0133] In summary, the embodiments of the present invention provide a method, device, equipment and medium for identifying an infant turning over when the infant's body is obscured.

[0134] 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 the relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.

[0135] It should be clear that the present invention is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present invention.

[0136] The functional blocks shown in the structural block diagram described above can be implemented as hardware, software, firmware or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of the present invention are programs or code segments used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link by a data signal carried in a carrier. "Machine-readable medium" may include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROMs, flash memories, erasable ROMs (EROMs), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, etc. The code segment can be downloaded via a computer network such as the Internet, an intranet, etc.

[0137] It should also be noted that the exemplary embodiments mentioned in the present invention describe some methods or systems based on a series of steps or devices. However, the present invention is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiments, or in a different order from the embodiments, or several steps can be performed simultaneously.

[0138] The above is only a specific implementation of the present invention. Those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working process of the system, module and unit described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here. It should be understood that the protection scope of the present invention is not limited to this. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be covered within the protection scope of the present invention.

Claims

1. A method for identifying turning over of an infant when the infant's body is obscured, characterized in that: The method comprises: Get real-time images of infant care scenarios; Pre-analyzing the real-time image, and obtaining the sleeping direction of the infant when it is determined that the infant is located in a preset target area; Performing depth field calculation on the pre-analyzed real-time image, and outputting adjacent first depth image and second depth image; Processing the first depth image and the second depth image according to the sleeping orientation of the infant to identify the turning over action of the infant; The processing of the first depth image and the second depth image according to the sleeping orientation of the infant to identify the turning over action of the infant includes: Determining a depth difference image based on the first depth image and the second depth image; Extracting features from the depth difference image, and outputting real-time spatial change intensity and real-time spatial change width; Determining the location information of a third center point of the spatial change area according to the real-time spatial change extent; If it is determined that the third center point is above the straight line of the infant's sleeping direction according to the position information of the third center point, a first threshold corresponding to a preset spatial change intensity and a second threshold corresponding to a preset spatial change width are obtained; When the real-time spatial variation intensity is greater than the first threshold and the real-time spatial variation width is greater than the second threshold, it is recognized that the infant has turned over; Among them, the real-time spatial change intensity reflects the total amount of change in the depth difference image, which is obtained by calculating the sum of the absolute values ​​of the depth value differences of all pixels in the depth difference image. The real-time spatial change breadth measures the spatial range of depth changes, that is, the size of the area occupied by pixels whose changes exceed a certain threshold. It is achieved by calculating the number of pixels that meet certain conditions, that is, the depth difference value of the pixel exceeds a predetermined threshold.

2. The method for identifying turning over of an infant when the infant's body is obscured according to claim 1, characterized in that: The pre-analysis of the real-time image, when determining that the infant is located in a preset target area, obtaining the sleeping direction of the infant includes: Inputting the real-time image into a pre-trained target detection model and outputting an infant head detection result; If the head of an infant is detected, the position information of the head of the infant is obtained; Acquire an image of the infant's head region according to the infant's head position information; Perform image segmentation processing on the image of the infant's head area to obtain the sleeping orientation of the infant.

3. The method for identifying turning over of an infant when the infant's body is obscured according to claim 2, characterized in that: The performing image segmentation processing on the image of the infant's head region to obtain the sleeping orientation of the infant includes: Performing grayscale processing on the image of the infant's head region and outputting a grayscale image; Performing threshold segmentation processing on the grayscale image to segment the grayscale image into a face area image and a hair area image; Acquire first center point position information of the face area image and second center point position information of the hair area image; The sleeping orientation of the infant is determined according to the first center point position information and the second center point position information.

4. The method for identifying turning over of an infant when the infant's body is obscured according to claim 1, characterized in that: The performing depth field calculation on the pre-analyzed real-time image and outputting adjacent first depth images and second depth images comprises: Acquire a first image and a second image adjacent to each other in a real-time image; Performing Gaussian filtering and median filtering on the first image and the second image, and outputting a first target image and a second target image after the filtering; The first target image and the second target image are input into a depth calculation model, and a first depth image and a second depth image are output.

5. The method for identifying turning over of an infant when the infant's body is obscured according to claim 1, characterized in that: The step of extracting features from the depth difference image and outputting the real-time spatial change intensity and the real-time spatial change width comprises: Accumulating the spatial change values ​​corresponding to the multiple frames of depth difference images, and outputting the total spatial change value as the real-time spatial change intensity; Each of the spatial variation values ​​is compared with a preset spatial variation breadth evaluation threshold to determine the real-time spatial variation breadth.

6. The method for identifying turning over of an infant when the infant's body is obscured according to claim 1, characterized in that: The obtaining of a preset first threshold corresponding to the spatial variation intensity and a preset second threshold corresponding to the spatial variation width includes: Acquire sample depth images of various target scenes related to infants and young children being blocked by obstructions, and acquire rolling action record data corresponding to the sample depth images; According to the turning action record data, a first sequence corresponding to the sample space change intensity and a second sequence corresponding to the sample space change width are obtained; Statistics are performed on the first sequence and the second sequence, and a minimum value in the first sequence is used as the first threshold, and a minimum value in the second sequence is used as the second threshold.

7. A device for identifying turning over when the body of an infant is obscured, characterized in that: The device comprises: An image acquisition module, used to acquire real-time images in infant care scenarios; A pre-analysis module is used to pre-analyze the real-time image and obtain the sleeping direction of the infant when it is determined that the infant is located in a preset target area; A depth analysis module, used to perform depth field calculation on the pre-analyzed real-time image and output adjacent first depth images and second depth images; A turning over detection module, used to process the first depth image and the second depth image according to the sleeping orientation of the infant, and identify the turning over action of the infant; The processing of the first depth image and the second depth image according to the sleeping orientation of the infant to identify the turning over action of the infant includes: Determining a depth difference image based on the first depth image and the second depth image; Extracting features from the depth difference image, and outputting real-time spatial change intensity and real-time spatial change width; Determining the location information of a third center point of the spatial change area according to the real-time spatial change extent; If it is determined that the third center point is above the straight line of the infant's sleeping direction according to the position information of the third center point, a first threshold corresponding to a preset spatial change intensity and a second threshold corresponding to a preset spatial change width are obtained; When the real-time spatial variation intensity is greater than the first threshold and the real-time spatial variation width is greater than the second threshold, it is recognized that the infant has turned over; Among them, the real-time spatial change intensity reflects the total amount of change in the depth difference image, which is obtained by calculating the sum of the absolute values ​​of the depth value differences of all pixels in the depth difference image. The real-time spatial change breadth measures the spatial range of depth changes, that is, the size of the area occupied by pixels whose changes exceed a certain threshold. It is achieved by calculating the number of pixels that meet certain conditions, that is, the depth difference value of the pixel exceeds a predetermined threshold.

8. An electronic device, characterized in that: include: At least one processor, at least one memory and computer program instructions stored in the memory, when the computer program instructions are executed by the processor, implement the method according to any one of claims 1 to 6.

9. A storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 6 is implemented.