A hazard warning method for children's smart watches based on environmental recognition
By installing a camera on the smartwatch and performing image processing and random forest algorithm analysis, the real-time identification of children's safety status is solved, and the accuracy of safety warnings and driving safety is improved.
Patent Information
- Application Number
- CN202510405944.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-02
- Publication Date
- 2025-08-08
- Estimated Expiration
- 2045-04-02
AI Technical Summary
The prior art is difficult to accurately identify children's safety status in real time in complex environments, especially in the case of light changes and object occlusion, which cannot effectively warn of potential safety hazards.
Install a mini camera on the smart watch to capture environmental images in real time and perform preprocessing, extract edges, textures and shape features, detect object movements through image frame differential method, use random forest algorithm to build models, analyze the behavioral status of children and environmental objects, and output early warning signals.
It realizes accurate identification and real-time monitoring of children's safety status under complex lighting and occlusion conditions, reducing the occurrence of traffic accidents.
Smart Images

Figure CN119919894B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of electronic products, and in particular to a danger warning method for children's smart watches based on environment recognition. Background Art
[0002] In recent years, the smartwatch market has grown rapidly, becoming an indispensable part of modern life. With rising health awareness and technological advancements, more and more consumers are beginning to focus on the functionality of smartwatches, not just for timekeeping but also for health monitoring, communication, and positioning. Whether they're sports enthusiasts, students, or office workers, smartwatches, with their convenience and versatility, meet people's technological needs in their daily lives.
[0003] However, in practical applications, how to monitor children's status in real time and promptly detect and warn of potential safety hazards has become an urgent problem to be solved. Objects in the environment are constantly moving and changing, and they may also be obscured, all of which can affect recognition accuracy. Summary of the Invention
[0004] In order to solve the above technical problems, a danger warning method for children's smart watches based on environmental recognition is provided. This technical solution solves the problems raised in the above background technology.
[0005] In order to achieve the above objects, the technical solution adopted by the present invention is:
[0006] A children's smart watch hazard warning method based on environment recognition, comprising:
[0007] Install a miniature camera on the smartwatch and debug the camera, adjusting its angle and focal length parameters to ensure that the camera captures a full view of the child's surroundings;
[0008] The camera captures a continuous sequence of images in the environment in real time, and performs denoising, enhancement and grayscale processing on the captured images in sequence;
[0009] Extract edge, texture, and shape features from the preprocessed image;
[0010] Based on the image frame difference method, the motion of objects in the environment is detected by performing image dynamic detection on the continuous image sequence captured by the camera in real time;
[0011] By analyzing the texture of each feature and based on the movement of objects in the environment, the behavioral state of the environmental objects and the behavioral state of the children are extracted;
[0012] Using the random forest algorithm, the behavioral states of environmental objects are linked to dangerous situations of children;
[0013] The model constructed by the random forest algorithm is trained using a historical environmental monitoring dataset containing various environmental scenarios to obtain a classification and recognition model.
[0014] The continuous image sequence in the environment captured by the camera in real time is input into the classification and recognition model, and the corresponding warning signal and prompt signal are output to the child and the child's guardian respectively.
[0015] Preferably, the camera captures a continuous image sequence in the environment in real time, and performs denoising, enhancement and grayscale processing on the captured images in sequence, specifically including:
[0016] Use image processing library to capture live images from camera;
[0017] Use a median filter to remove noise from the image and replace the value of each pixel in the continuous image sequence of the environment with the median of its neighboring pixel values;
[0018] By analyzing the pixel value distribution of the image, the pixel value of each pixel is redistributed to even the contrast of the image;
[0019] Multiply all pixel values of the image by a preset constant to enhance the brightness of the image;
[0020] Get the weighted coefficients of human eye sensitivity to red, green and blue;
[0021] Substitute the red, green and blue color components of each pixel in the continuous image sequence in the environment into the weighted average formula to obtain the grayscale value of each pixel in the continuous image sequence in the environment;
[0022] The weighted average formula is: ,
[0023] Where, is the grayscale value of the pixel in the i-th row and j-th column, are the weighted coefficients of human eye sensitivity to red, green and blue respectively, are the red, green and blue color components of the pixel in the i-th row and j-th column respectively.
[0024] Preferably, the step of extracting edge, texture and shape features from the preprocessed image specifically includes:
[0025] Get the third-order Laplace operator;
[0026] Perform convolution operation on the third-order Laplace operator and the preprocessed image to obtain the new pixel value of each pixel;
[0027] In the image after Laplace operation, the zero-crossing points where the pixel values change from positive to negative or from negative to positive are identified and the zero-crossing points are output as the edge points of the image;
[0028] Set the neighborhood of each pixel to 8 pixels within a 3×3 range centered on the pixel;
[0029] Determine whether the grayscale value of each neighboring pixel is greater than or equal to the grayscale value of the central pixel. If so, output the binary bit of the neighboring pixel as 1; if not, output the binary bit of the neighboring pixel as 0;
[0030] Combining the 8 binary bits clockwise from the upper left corner, we get an 8-bit binary number.
[0031] Output the decimal number corresponding to the binary number as the texture feature value of the pixel position;
[0032] Calculate the frequency of texture eigenvalues in each image and construct a texture eigenvalue frequency histogram;
[0033] Based on the graphics formed by edge points, its area, perimeter and direction are output as shape features;
[0034] The Laplace operator is: ,
[0035] Where, is the third-order Laplace operator;
[0036] The convolution operation is: ,
[0037] Where, The new pixel value of the pixel at row i and column j.
[0038] Preferably, the image frame difference method is based on performing image dynamic detection on a continuous image sequence in the environment captured in real time by a camera to detect the motion of objects in the environment, specifically comprising:
[0039] Continuously capture two adjacent frames of images from a continuous image sequence of the environment captured by the camera in real time;
[0040] For each pixel position of the two frames of image, calculate the difference in their grayscale values;
[0041] The minimum amplitude of pixel value change that can be recognized by the human eye is used as the preset difference threshold;
[0042] Determine whether the difference in the grayscale value of each pixel is greater than a preset difference threshold. If so, output that the pixel is in motion; if not, output that the pixel belongs to a static background;
[0043] Cluster all pixels with motion to form connected regions, and output each connected region as a moving target in the environment;
[0044] Repeatedly capture subsequent adjacent images to perform image dynamic detection, track the motion trajectory of each moving target and calculate the real-time motion speed of each moving target.
[0045] Preferably, the calculating of the real-time motion speed of each moving target comprises the following steps:
[0046] According to the motion trajectory of the moving target, the initial motion speed of the moving target is calculated;
[0047] The minimum value of the initial movement speed is used as the child's movement speed;
[0048] The child's movement speed is reversely superimposed on the preliminary movement speed to obtain the real-time movement speed of the moving target.
[0049] Preferably, the extracting the behavior states of the environmental objects and the behavior states of the children based on the movement of the objects in the environment through texture analysis of each feature specifically includes:
[0050] Based on the texture analysis of each feature, locate the facial area of the moving target;
[0051] When the moving object does not have a facial region, the speed reduction condition when the distance between the moving object and the child is less than the safe distance is regarded as the behavior state of the environmental object;
[0052] When the moving object has a facial region, locating key feature points in the facial region of the moving object, wherein the key feature points include eyes, mouth, and eyebrows;
[0053] Analyze the texture of the facial area and extract facial expression features;
[0054] Compare the extracted facial expression features with the known expression database to identify the current facial expression of the moving target;
[0055] Count the number of blinks per unit time, and determine the eye opening and closing status based on pupil occlusion, and summarize and output the eye status of the moving target;
[0056] Extract and classify features of images of the hand area to identify hand movements of moving targets;
[0057] Track hand movements in continuous image frames, analyze the continuity and changes of hand movements, and output them as gestures of moving targets;
[0058] The current facial expression, eye state and gesture of the moving target are regarded as the behavioral state of the environmental object;
[0059] The same analysis steps as for the motion target are used to obtain the child’s current facial expression, eye state, and gesture movement, which are used as the child’s behavioral state.
[0060] Preferably, the training of the model constructed by the random forest algorithm using a historical environmental monitoring data set containing various environmental scenarios to obtain a classification recognition model specifically includes:
[0061] S101: Setting the historical environmental monitoring database as a model training dataset;
[0062] S102: Randomly select an unselected data subset from the historical environmental monitoring database as the root node of the decision tree;
[0063] S103: establishing a first leaf node at the root node based on the different behavior states of the moving target as a splitting criterion;
[0064] S104: establishing a second leaf node at the first leaf node based on the difference in the children's behavioral states as a splitting criterion;
[0065] S105: Summarize the root node and all its leaf nodes and output them as a decision tree;
[0066] S106: Determine whether corresponding decision trees are established for all data subsets in the historical environment monitoring database. If so, output all decision trees as classification and recognition models. If not, return to step S102.
[0067] Compared with the prior art, the present invention has the following beneficial effects:
[0068] By setting up the detection of the movement of objects in the environment, extracting the behavioral status of environmental objects and the behavioral status of children, and obtaining a classification and recognition model, real-time monitoring and early warning of the status of children and their guardians can be achieved, driving safety can be improved, and the occurrence of traffic accidents can be reduced. By preprocessing images (such as denoising, enhancement and grayscale processing), and using advanced classification and recognition algorithms (such as random forest algorithm), accurate identification of children's safety status can be achieved under complex lighting and occlusion conditions. BRIEF DESCRIPTION OF THE DRAWINGS
[0069] Figure 1 This is a flow chart of the danger warning method for children's smart watches based on environmental recognition of the present invention;
[0070] Figure 2 This is a flow chart of a method for sequentially performing denoising, enhancement and grayscale processing on a captured image according to the present invention;
[0071] Figure 3 A flow chart of a method for extracting edge, texture and shape features from a preprocessed image according to the present invention;
[0072] Figure 4This is a flow chart of a method for performing image dynamic detection on a continuous image sequence in an environment captured in real time by a camera according to the present invention;
[0073] Figure 5 Flowchart of the method for calculating the real-time motion speed of each moving target of the present invention;
[0074] Figure 6 A flow chart of the method for extracting the behavioral states of environmental objects and children according to the present invention;
[0075] Figure 7 This is a flow chart of the method for training a model constructed using the random forest algorithm of the present invention. DETAILED DESCRIPTION
[0076] The following description is intended to disclose the present invention so that those skilled in the art can implement the present invention. The preferred embodiments described below are merely examples, and those skilled in the art may conceive of other obvious variations.
[0077] Reference Figure 1 As shown, a danger warning method for a children's smart watch based on environment recognition includes:
[0078] Install a miniature camera on the smartwatch and debug the camera, adjusting its angle and focal length parameters to ensure that the camera captures a full view of the child's surroundings;
[0079] The camera captures a continuous sequence of images in the environment in real time, and performs denoising, enhancement and grayscale processing on the captured images in sequence;
[0080] Extract edge, texture, and shape features from the preprocessed image;
[0081] Based on the image frame difference method, the motion of objects in the environment is detected by performing image dynamic detection on the continuous image sequence captured by the camera in real time;
[0082] By analyzing the texture of each feature and based on the movement of objects in the environment, the behavioral state of the environmental objects and the behavioral state of the children are extracted;
[0083] Using the random forest algorithm, the behavioral states of environmental objects are linked to dangerous situations of children;
[0084] The model constructed by the random forest algorithm is trained using a historical environmental monitoring dataset containing various environmental scenarios to obtain a classification and recognition model.
[0085] The continuous image sequence in the environment captured by the camera in real time is input into the classification and recognition model, and the corresponding warning signal and prompt signal are output to the child and the child's guardian respectively.
[0086] Reference Figure 2 As shown, the camera captures a continuous image sequence in the environment in real time, and performs denoising, enhancement and grayscale processing on the captured images in sequence, specifically including:
[0087] Use image processing library to capture live images from camera;
[0088] Use a median filter to remove noise from the image and replace the value of each pixel in the continuous image sequence of the environment with the median of its neighboring pixel values;
[0089] By analyzing the pixel value distribution of the image, the pixel value of each pixel is redistributed to even the contrast of the image;
[0090] Multiply all pixel values of the image by a preset constant to enhance the brightness of the image;
[0091] Get the weighted coefficients of human eye sensitivity to red, green and blue;
[0092] Substitute the red, green and blue color components of each pixel in the continuous image sequence in the environment into the weighted average formula to obtain the grayscale value of each pixel in the continuous image sequence in the environment;
[0093] The weighted average formula is: ,
[0094] Where, is the grayscale value of the pixel in the i-th row and j-th column, are the weighted coefficients of human eye sensitivity to red, green and blue respectively, are the red, green and blue color components of the pixel in the i-th row and j-th column respectively.
[0095] Obtain the weighted coefficients of the human eye's sensitivity to red, green, and blue. Generally, the human eye is most sensitive to green, second most sensitive to red, and least sensitive to blue. Therefore, the weighted coefficients of green, red, and blue can be set to 0.59, 0.30, and 0.11, respectively (these coefficients are based on the characteristics of the human visual system).
[0096] Reference Figure 3 As shown in Figure 2, extracting edge, texture, and shape features from the preprocessed image specifically includes:
[0097] Get the third-order Laplace operator;
[0098] Perform convolution operation on the third-order Laplace operator and the preprocessed image to obtain the new pixel value of each pixel;
[0099] In the image after Laplace operation, the zero-crossing points where the pixel values change from positive to negative or from negative to positive are identified and the zero-crossing points are output as the edge points of the image;
[0100] Set the neighborhood of each pixel to 8 pixels within a 3×3 range centered on the pixel;
[0101] Determine whether the grayscale value of each neighboring pixel is greater than or equal to the grayscale value of the central pixel. If so, output the binary bit of the neighboring pixel as 1; if not, output the binary bit of the neighboring pixel as 0;
[0102] Combining the 8 binary bits clockwise from the upper left corner, we get an 8-bit binary number.
[0103] Output the decimal number corresponding to the binary number as the texture feature value of the pixel position;
[0104] Calculate the frequency of texture eigenvalues in each image and construct a texture eigenvalue frequency histogram;
[0105] Based on the graphics formed by edge points, its area, perimeter and direction are output as shape features;
[0106] The Laplace operator is: ,
[0107] Where, is the third-order Laplace operator;
[0108] The convolution operation is: ,
[0109] Where, The new pixel value of the pixel at row i and column j.
[0110] For each closed figure, its area, perimeter and direction are calculated as shape features. The area can be obtained by counting the number of pixels inside the figure; the perimeter can be obtained by traversing the edge points of the figure and calculating the sum of the distances between adjacent points; the direction can be obtained by calculating the angle between the long axis of the figure and the horizontal axis.
[0111] Reference Figure 4 As shown in the figure, based on the image frame difference method, the image dynamic detection is performed on the continuous image sequence in the environment captured by the camera in real time, and the motion of the objects in the environment is detected specifically including:
[0112] Continuously capture two adjacent frames of images from a continuous image sequence of the environment captured by the camera in real time;
[0113] For each pixel position of the two frames of image, calculate the difference in their grayscale values;
[0114] The minimum amplitude of pixel value change that can be recognized by the human eye is used as the preset difference threshold;
[0115] Determine whether the difference in the grayscale value of each pixel is greater than a preset difference threshold. If so, output that the pixel is in motion; if not, output that the pixel belongs to a static background;
[0116] Cluster all pixels with motion to form connected regions, and output each connected region as a moving target in the environment;
[0117] Repeatedly capture subsequent adjacent images to perform image dynamic detection, track the motion trajectory of each moving target and calculate the real-time motion speed of each moving target.
[0118] Based on the sensitivity to changes in lighting in the environment, a difference threshold is preset. This threshold is used to distinguish between grayscale value changes caused by object motion and grayscale value changes caused by lighting changes. The setting of the difference threshold needs to be adjusted according to actual lighting conditions and camera performance.
[0119] Reference Figure 5 As shown, calculating the real-time motion speed of each moving target includes the following steps:
[0120] According to the motion trajectory of the moving target, the initial motion speed of the moving target is calculated;
[0121] The minimum value of the initial movement speed is used as the child's movement speed;
[0122] The child's movement speed is reversely superimposed on the preliminary movement speed to obtain the real-time movement speed of the moving target.
[0123] During the movement of objects in the environment, children may also move. When the movements of the two are superimposed, it is difficult to identify the true movement of the object. Usually, the identification of stationary objects can be used and used as markers. Then, based on the markers as a reference, the speed of all objects can be obtained. However, this requires the identification of stationary objects. Since children will continue to move, the markers will continue to change as the children move. The identification of stationary objects requires a more complex algorithm to be set. This is because children's movements are irregular, and the changes of stationary objects in the image are also irregular. Therefore, the recognition algorithm must be relatively complex, and when there is a problem with the recognition, it is easy to cause deviations in all subsequent speed calculations. In this solution, considering that the movement of objects in the image is the superposition of children's movement and the actual movement of the object, its minimum value must be the superposition of children's movement and 0. Therefore, based on the minimum value of the obtained speed, the speed of the child can be obtained, and then the actual speed of the object can be obtained, and subsequent judgments can be made based on this.
[0124] Reference Figure 6 As shown in the figure, by analyzing the texture of each feature and based on the movement of objects in the environment, the behavioral states of environmental objects and children are extracted, including:
[0125] Based on the texture analysis of each feature, locate the facial area of the moving target;
[0126] When the moving object does not have a facial region, the speed reduction condition when the distance between the moving object and the child is less than the safe distance is regarded as the behavior state of the environmental object;
[0127] When the moving object has a facial region, locating key feature points in the facial region of the moving object, wherein the key feature points include eyes, mouth, and eyebrows;
[0128] Analyze the texture of the facial area and extract facial expression features;
[0129] Compare the extracted facial expression features with the known expression database to identify the current facial expression of the moving target;
[0130] Count the number of blinks per unit time, and determine the eye opening and closing status based on pupil occlusion, and summarize and output the eye status of the moving target;
[0131] Extract and classify features of images of the hand area to identify hand movements of moving targets;
[0132] Track hand movements in continuous image frames, analyze the continuity and changes of hand movements, and output them as gestures of moving targets;
[0133] The current facial expression, eye state and gesture of the moving target are regarded as the behavioral state of the environmental object;
[0134] The same analysis steps as for the motion target are used to obtain the child’s current facial expression, eye state, and gesture movement, which are used as the child’s behavioral state.
[0135] Texture analysis is performed on the located facial area. By calculating features such as facial muscle deformation and texture changes, facial expression features are extracted. These features can reflect the target's emotional state, such as joy, anger, sorrow, and happiness, providing reliable data support for subsequent warnings of dangerous behaviors.
[0136] Some objects are not living things but can move and also need to be identified. The main purpose is to obtain their speed when they are close to children, and make judgments and settings in subsequent models. If the speed is still too high when close to children, there is a certain risk and an early warning is required.
[0137] Reference Figure 7 As shown in the figure, the model constructed by the random forest algorithm is trained using a historical environmental monitoring dataset containing various environmental scenarios. The classification and recognition model obtained specifically includes:
[0138] S101: Setting the historical environmental monitoring database as a model training dataset;
[0139] S102: Randomly select an unselected data subset from the historical environmental monitoring database as the root node of the decision tree;
[0140] S103: establishing a first leaf node at the root node based on the different behavior states of the moving target as a splitting criterion;
[0141] S104: establishing a second leaf node at the first leaf node based on the difference in the children's behavioral states as a splitting criterion;
[0142] S105: Summarize the root node and all its leaf nodes and output them as a decision tree;
[0143] S106: Determine whether corresponding decision trees are established for all data subsets in the historical environment monitoring database. If so, output all decision trees as classification and recognition models. If not, return to step S102.
[0144] The core of the random forest algorithm is to create multiple decision trees and let these trees predict samples independently. The final prediction result is based on the vote (for classification problems) or average (for regression problems) of the prediction results of all trees. When building each tree, the algorithm randomly extracts samples and features from the original data set. This randomness helps improve the generalization ability of the model.
[0145] Furthermore, the present solution also proposes a computer-readable storage medium on which a computer-readable program is stored. When the computer-readable program is called, the above-mentioned children's smart watch danger warning method based on environmental recognition is executed.
[0146] It is understandable that the storage medium may be a magnetic medium, such as a floppy disk, a hard disk, or a magnetic tape; an optical medium, such as a DVD; or a semiconductor medium, such as a solid state disk (SSD).
[0147] In summary, the advantages of the present invention are: by setting up a detection system for the movement of objects in the environment, extracting the behavioral status of environmental objects and the behavioral status of children, and obtaining a classification and recognition model, real-time monitoring and early warning of the status of children and their guardians can be achieved, driving safety can be improved, and the occurrence of traffic accidents can be reduced. By preprocessing images (such as denoising, enhancement, and grayscale processing), and using advanced classification and recognition algorithms (such as the random forest algorithm), accurate identification of the safety status of children can be achieved under complex lighting and occlusion conditions.
[0148] The above shows and describes the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The above embodiments and descriptions merely illustrate the principles of the present invention. Various changes and modifications may be made to the present invention without departing from the spirit and scope of the present invention. Such changes and modifications are intended to fall within the scope of the present invention. The scope of protection claimed by the present invention is defined by the appended claims and their equivalents.
Claims
1. A children's smart watch danger warning method based on environment recognition, characterized in that: include: Install a miniature camera on the smartwatch and debug the camera, adjusting its angle and focal length parameters to ensure that the camera captures a full view of the child's surroundings; The camera captures a continuous sequence of images in the environment in real time, and performs denoising, enhancement and grayscale processing on the captured images in sequence; Extract edge, texture, and shape features from the preprocessed image; Based on the image frame difference method, the motion of objects in the environment is detected by performing image dynamic detection on the continuous image sequence captured by the camera in real time; By analyzing the texture of each feature and based on the movement of objects in the environment, the behavioral state of the environmental objects and the behavioral state of the children are extracted; Using the random forest algorithm, the behavioral states of environmental objects are linked to dangerous situations of children; The model constructed by the random forest algorithm is trained using a historical environmental monitoring dataset containing various environmental scenarios to obtain a classification and recognition model. The continuous image sequence of the environment captured by the camera in real time is input into the classification and recognition model, and the corresponding warning signal and prompt signal are output to the child and the child's guardian respectively; The extraction of the behavior states of the environmental objects and the behavior states of the children based on the movement of the objects in the environment through texture analysis of each feature specifically includes: Based on the texture analysis of each feature, locate the facial area of the moving target; When the moving object does not have a facial region, the speed reduction condition when the distance between the moving object and the child is less than the safe distance is regarded as the behavior state of the environmental object; When the moving target has a facial area, the current facial expression, eye state and gesture of the moving target are regarded as the behavioral state of the environmental object; The same analysis steps as for the motion target are used to obtain the child’s current facial expression, eye state, and gesture movement, which are used as the child’s behavioral state.
2. The method for warning danger of a children's smart watch based on environment recognition according to claim 1, characterized in that: The camera captures a continuous image sequence in the environment in real time, and performs denoising, enhancement and grayscale processing on the captured images in sequence, specifically including: Use image processing library to capture live images from camera; Use a median filter to remove noise from the image and replace the value of each pixel in the continuous image sequence of the environment with the median of its neighboring pixel values; By analyzing the pixel value distribution of the image, the pixel value of each pixel is redistributed to even out the contrast of the image; Multiply all pixel values of the image by a preset constant to enhance the brightness of the image; Get the weighted coefficients of human eye sensitivity to red, green and blue; Substitute the red, green and blue color components of each pixel in the continuous image sequence in the environment into the weighted average formula to obtain the grayscale value of each pixel in the continuous image sequence in the environment; The weighted average formula is: , Where, is the grayscale value of the pixel in the i-th row and j-th column, are the weighted coefficients of human eye sensitivity to red, green and blue respectively, are the red, green and blue color components of the pixel in the i-th row and j-th column respectively.
3. The method for warning danger of a children's smart watch based on environment recognition according to claim 2, characterized in that: The extracting of edge, texture and shape features from the preprocessed image specifically includes: Get the third-order Laplace operator; Perform convolution operation on the third-order Laplace operator and the preprocessed image to obtain the new pixel value of each pixel; In the image after Laplace operation, the zero-crossing points where the pixel values change from positive to negative or from negative to positive are identified and the zero-crossing points are output as the edge points of the image; Set the neighborhood of each pixel to 8 pixels within a 3×3 range centered on the pixel; Determine whether the grayscale value of each neighboring pixel is greater than or equal to the grayscale value of the central pixel. If so, output the binary bit of the neighboring pixel as 1; if not, output the binary bit of the neighboring pixel as 0; Combining the 8 binary bits clockwise from the upper left corner, we get an 8-bit binary number. Output the decimal number corresponding to the binary number as the texture feature value of the pixel position; Calculate the frequency of texture eigenvalues in each image and construct a texture eigenvalue frequency histogram; Based on the graphics formed by edge points, its area, perimeter and direction are output as shape features; The Laplace operator is: , Where, is the third-order Laplace operator; The convolution operation is: , Where, The new pixel value of the pixel at row i and column j.
4. The method for warning danger of a children's smart watch based on environment recognition according to claim 3 is characterized in that: The image frame difference method is based on performing image dynamic detection on a continuous image sequence in an environment captured in real time by a camera to detect the motion of objects in the environment. Specifically, the detection includes: Continuously capture two adjacent frames of images from a continuous image sequence of the environment captured by the camera in real time; For each pixel position of the two frames of image, calculate the difference in their grayscale values; The minimum amplitude of pixel value change that can be recognized by the human eye is used as the preset difference threshold; Determine whether the difference in the grayscale value of each pixel is greater than a preset difference threshold. If so, output that the pixel is in motion; if not, output that the pixel belongs to a static background; Cluster all pixels with motion to form connected regions, and output each connected region as a moving target in the environment; Repeatedly capture subsequent adjacent images to perform image dynamic detection, track the motion trajectory of each moving target and calculate the real-time motion speed of each moving target.
5. The method for warning danger of a children's smart watch based on environment recognition according to claim 4 is characterized in that: The calculation of the real-time motion speed of each moving target comprises the following steps: According to the motion trajectory of the moving target, the initial motion speed of the moving target is calculated; The minimum value of the initial movement speed is used as the child's movement speed; The child's movement speed is reversely superimposed on the preliminary movement speed to obtain the real-time movement speed of the moving target.
6. The method for warning danger of a children's smart watch based on environment recognition according to claim 5, characterized in that: When the moving target has a facial area, the current facial expression, eye state, and gesture of the moving target are used as the behavior state of the environmental object, specifically including: Positioning key feature points in the facial area of the moving target, wherein the key feature points include eyes, mouth and eyebrows; Analyze the texture of the facial area and extract facial expression features; Compare the extracted facial expression features with the known expression database to identify the current facial expression of the moving target; Count the number of blinks per unit time, and determine the eye opening and closing status based on pupil occlusion, and summarize and output the eye status of the moving target; Extract and classify features of images of the hand area to identify hand movements of moving targets; Track hand movements in continuous image frames, analyze the continuity and changes of hand movements, and output them as gesture movements of moving targets.
7. The method for warning danger of a children's smart watch based on environment recognition according to claim 6, characterized in that: The model constructed by the random forest algorithm is trained using a historical environmental monitoring data set containing various environmental scenarios to obtain a classification and recognition model, specifically including: S101: Setting the historical environmental monitoring database as a model training dataset; S102: Randomly select an unselected data subset from the historical environmental monitoring database as the root node of the decision tree; S103: establishing a first leaf node at the root node based on the different behavior states of the moving target as a splitting criterion; S104: establishing a second leaf node at the first leaf node based on the difference in the children's behavioral states as a splitting criterion; S105: Summarize the root node and all its leaf nodes and output them as a decision tree; S106: Determine whether corresponding decision trees are established for all data subsets in the historical environment monitoring database. If so, output all decision trees as classification and recognition models. If not, return to step S102.
Citation Information
Patent Citations
Miniature early warning robot for danger and persecution of kid
CN110211330A
Environmental security sensing method and related equipment
CN117173622A