CN114327045B - Fall detection method and system based on category imbalance signals - Google Patents
Fall detection method and system based on category imbalance signals Download PDFInfo
- Publication number
- CN114327045B CN114327045B CN202111448595.3A CN202111448595A CN114327045B CN 114327045 B CN114327045 B CN 114327045B CN 202111448595 A CN202111448595 A CN 202111448595A CN 114327045 B CN114327045 B CN 114327045B
- Authority
- CN
- China
- Prior art keywords
- category
- action
- data
- test data
- optimal
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000001514 detection method Methods 0.000 title claims abstract description 45
- 230000009471 action Effects 0.000 claims abstract description 127
- 238000012360 testing method Methods 0.000 claims abstract description 86
- 238000013136 deep learning model Methods 0.000 claims abstract description 45
- 230000000694 effects Effects 0.000 claims abstract description 40
- 238000012549 training Methods 0.000 claims abstract description 30
- 238000000034 method Methods 0.000 claims abstract description 27
- 230000001133 acceleration Effects 0.000 claims abstract description 9
- 238000004364 calculation method Methods 0.000 claims description 20
- 238000010606 normalization Methods 0.000 claims description 19
- 238000004422 calculation algorithm Methods 0.000 claims description 16
- 230000006870 function Effects 0.000 claims description 15
- 230000008569 process Effects 0.000 claims description 10
- 230000004913 activation Effects 0.000 claims description 4
- 238000012545 processing Methods 0.000 claims description 3
- 230000006399 behavior Effects 0.000 abstract description 2
- 238000013135 deep learning Methods 0.000 description 7
- 238000007781 pre-processing Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 230000007613 environmental effect Effects 0.000 description 2
- 238000000605 extraction Methods 0.000 description 2
- 238000010801 machine learning Methods 0.000 description 2
- 238000012795 verification Methods 0.000 description 2
- 208000010392 Bone Fractures Diseases 0.000 description 1
- 208000024172 Cardiovascular disease Diseases 0.000 description 1
- 206010017076 Fracture Diseases 0.000 description 1
- 206010017577 Gait disturbance Diseases 0.000 description 1
- 206010019196 Head injury Diseases 0.000 description 1
- 206010033799 Paralysis Diseases 0.000 description 1
- 208000003443 Unconsciousness Diseases 0.000 description 1
- 230000032683 aging Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 208000026106 cerebrovascular disease Diseases 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000004590 computer program Methods 0.000 description 1
- 230000008034 disappearance Effects 0.000 description 1
- 230000002526 effect on cardiovascular system Effects 0.000 description 1
- 238000002474 experimental method Methods 0.000 description 1
- 238000004880 explosion Methods 0.000 description 1
- 239000012634 fragment Substances 0.000 description 1
- 239000011159 matrix material Substances 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000001902 propagating effect Effects 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
- 230000011218 segmentation Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Landscapes
- Measurement Of The Respiration, Hearing Ability, Form, And Blood Characteristics Of Living Organisms (AREA)
Abstract
The invention relates to a fall detection method and a fall detection system based on category imbalance signals, belongs to the technical field of behavior recognition, and solves the problem that in the prior art, due to fall detection category imbalance, fall event signals are difficult to accurately recognize from a large number of daily activities. The method comprises the following steps: acquiring action test data of a user acquired by intelligent wearable equipment in real time; the action test data includes: acceleration data and angular velocity values; inputting the motion test data into an optimal deep learning model, and identifying the motion category of the motion test data to acquire probability values of each motion category; comparing the probability value of each action category with an optimal threshold value, and predicting the action category corresponding to the action test data; the optimal threshold is used for shifting the prediction result to an action category with low occurrence probability according to the unbalance rate of the sample data set used in the training of the deep learning model. Fall detection based on category imbalance data is achieved.
Description
Technical Field
The invention relates to the technical field of behavior recognition, in particular to a fall detection method and system based on category imbalance signals.
Background
It is well known that falls can lead to serious consequences, such as paralysis, fracture, head injury, and the like, particularly for the elderly. Cardiovascular and cerebrovascular diseases and gait disturbance of the elderly can cause falling, so that the patient is unconscious and stunned. Falls have become the biggest potential hazard threatening the life safety of the elderly. In addition, the aging of the human mouth is increasingly serious worldwide, the number and the solitary proportion of the aged are increased year by year, the solitary aged can hardly save oneself once falling, and the solitary aged has important application significance for falling detection of the aged under the condition.
Currently, fall detection can be categorized into the following three categories according to the source of the data: video image-based fall detection, environmental sensor-based fall detection, and wearable device-based fall detection. Fall detection based on video images is limited by the coverage of the camera and requires that the detected person cannot be blocked by other objects; fall detection based on an environmental sensor also requires advanced equipment arrangement and detection can only be performed in a fixed range; the equipment based on the fall detection of wearable equipment is small in size and convenient to carry, and data during exercise are directly acquired to perform feature extraction and classification.
However, traditional algorithms for fall detection based on wearable devices include a thresholding method and a machine learning method, the thresholding method is simple to calculate and easy to deploy, but the thresholding method is not very generalized among different users; the machine learning method requires manual setting of the features of the data in advance, and selection of the features is a difficult problem. In addition, most of traditional detection algorithms perform model training in an ideal data set, the daily activity data in the ideal data set are balanced with the types of the falling event data, in real life, the falling event is an occasional event, the daily life data collected by a sensor are far more than the falling event data, the detection problems of unbalanced types are solved, and the traditional algorithm is difficult to accurately identify the falling event signals from a large amount of daily activities.
Therefore, a fall detection method and system suitable for category imbalance data are lacking in the prior art.
Disclosure of Invention
In view of the above analysis, the embodiments of the present invention aim to provide a fall detection method and system based on a category imbalance signal, so as to solve the problem that it is difficult to accurately identify a fall event signal from a large amount of daily activities due to the existing fall detection category imbalance.
In one aspect, an embodiment of the present invention provides a fall detection method based on a category imbalance signal, including:
Acquiring action test data of a user acquired by intelligent wearable equipment in real time; the action test data includes: acceleration data and angular velocity values;
Inputting the motion test data into an optimal deep learning model, and identifying the motion category of the motion test data to acquire probability values of each motion category;
Comparing the probability value of each action category with an optimal threshold value, and predicting the action category corresponding to the action test data;
The optimal threshold is used for shifting the prediction result to an action category with low occurrence probability according to the unbalance rate of the sample data set used in the training of the deep learning model.
Further, the optimal deep learning model includes:
the residual error connection module is used for extracting characteristics of the action test data;
The full-connection softmax layer is used for classifying the characteristics of the motion test data and outputting probability values of the motion test data corresponding to each motion category;
And the threshold moving algorithm layer is used for adjusting the classification threshold, acquiring an optimal threshold and judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold.
Further, the adjusting the classification threshold to obtain the optimal threshold includes:
Acquiring a sample data set, dividing the data in the sample data set into daily activity sample data and falling sample data, and counting the daily activity sample data quantity and the falling sample data quantity;
Calculating the sample unbalance rate according to the ratio of the daily life sample data quantity to the falling sample data quantity;
and adjusting classification thresholds according to the sample unbalance rate, and determining the optimal threshold, wherein the optimal threshold is a falling action threshold lambda *.
Further, the optimal threshold λ * is expressed as:
λ*=k×e-ρ/a+b
Wherein lambda * is the optimal threshold, k is the default threshold of the classifier, ρ is the unbalance rate of the sample data set, a and b are constants, n max is the number of daily life data in the sample data set, and n min is the number of falling sample data in the sample data set.
Further, the action categories include fall actions and daily activity actions; judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold value, comprising:
When a falling probability value p output by certain action test data is compared with an optimal threshold lambda *, if p is more than or equal to lambda *, the optimal deep learning model predicts that the action test data is a falling action;
When the daily activity probability value q output by certain action test data is compared with the optimal threshold lambda *, if q is less than or equal to 1-lambda *, the optimal deep learning model predicts that the action test data is a falling action.
Further, the residual connection module includes:
The convolution layer is used for extracting characteristic information in the original data;
The batch normalization layer is used for carrying out normalization processing on the characteristic information and then carrying out nonlinear calculation on the activation function;
and the residual error connection calculation unit is used for linearly superposing the extracted characteristic information with the original data.
Further, the convolution layer includes: a first convolution layer, a second convolution layer;
The batch normalization layer includes: a first normalization layer and a second normalization layer;
The residual error connection module comprises four first to fourth residual error connection units which are sequentially connected, and each of the first to fourth residual error connection units comprises the following components in sequence: the first convolution layer, the first normalization layer, the second convolution layer, the second normalization layer and the residual error are connected with the calculating subunit;
The first convolution layer and the second convolution layer in the first residual error connection unit comprise 64 convolution kernels;
the first convolution layer and the second convolution layer in the second residual error connection unit comprise 128 convolution kernels;
The first convolution layer and the second convolution layer in the third residual error connection unit comprise 256 convolution kernels;
The first convolution layer and the second convolution layer in the fourth residual error connection unit comprise 512 convolution kernels;
All convolution kernels in the first to fourth residual connection units are 1x3 convolution kernels.
Further, in the process of model training of the deep learning model, error in the model training process is calculated through the cross entropy loss function, and when the error is stable, the deep learning model is the optimal deep learning model.
In another aspect, an embodiment of the present invention provides a fall detection system based on a category imbalance signal, including:
The data acquisition module is used for acquiring action test data of a user acquired by the intelligent wearable equipment in real time; the action test data includes: acceleration data and angular velocity values;
The probability calculation module is used for inputting the motion test data into an optimal deep learning model, identifying the motion category of the motion test data and obtaining the probability value of each motion category;
the prediction module is used for comparing the probability value of each action category with an optimal threshold value and predicting the action category corresponding to the action test data; the optimal threshold is used for shifting the prediction result to an action category with low occurrence probability according to the unbalance rate of the sample data set used in the training of the deep learning model.
Further, the optimal deep learning model in the probability calculation module includes:
the residual error connection module is used for extracting characteristics of the action test data;
The full-connection softmax layer is used for classifying the characteristics of the motion test data and outputting probability values of the motion test data corresponding to each motion category;
And the threshold moving algorithm layer is used for adjusting the classification threshold, acquiring an optimal threshold and judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold.
Compared with the prior art, the invention has at least one of the following beneficial effects:
1. According to the method, the class imbalance condition of real life activities is optimized through an algorithm value moving method, so that the prediction result of the optimal deep learning model moves towards a small number of falling data classes, the deviation of a plurality of daily activity classes is reduced, the model can be ensured to detect sporadic falling event data with low occurrence probability from a large number of daily activity data, and the detection precision is high;
2. The invention is based on the deep learning network model, the deep learning method can automatically identify deep features from a large amount of data and adjust parameters of the model, and compared with the traditional algorithm model, the deep learning method can more accurately detect and identify falling events, the network model is trained and the parameters are adjusted through category unbalanced data acquired in real life, the trained model has good detection capability on the occurrence of small probability falling events, falling data signals can be identified from a large amount of daily activity data, and the condition of missing detection is reduced;
3. According to the real life falling data set established after certain preprocessing is carried out according to the data acquired by the accelerometer and the gyroscope in the intelligent wearable equipment, the established class unbalanced falling detection model is trained and tested on the real life falling data set, and the intelligent wearable equipment is more suitable for being applied to real life.
In the invention, the technical schemes can be mutually combined to realize more preferable combination schemes. Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention may be realized and attained by the structure particularly pointed out in the written description and drawings.
Drawings
The drawings are only for purposes of illustrating particular embodiments and are not to be construed as limiting the invention, like reference numerals being used to refer to like parts throughout the several views.
Fig. 1 is a flowchart of a fall detection method based on a class imbalance signal according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of a deep learning model module according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of a raw data preprocessing process according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of a residual connection module according to an embodiment of the present invention;
FIG. 5 is a graph of a threshold shift function fitted to experimental data, according to one embodiment of the present invention;
Fig. 6 is a block diagram of a fall detection system based on a class imbalance signal according to an embodiment of the invention.
Detailed Description
The following detailed description of preferred embodiments of the application is made in connection with the accompanying drawings, which form a part hereof, and together with the description of the embodiments of the application, are used to explain the principles of the application and are not intended to limit the scope of the application.
As shown in fig. 1, in one embodiment of the present invention, a fall detection method based on a class imbalance signal is disclosed, including:
S10, acquiring action test data of a user acquired by intelligent wearable equipment in real time; the action test data includes: acceleration data and angular velocity values; specifically, according to the accelerometer and the gyroscope of the intelligent wearable device on the user, the acceleration data and the angular velocity value of each action category of the user in daily life are collected. In particular, the accelerometer and gyroscope are integrated on a smart wearable device, the position of which relative to the wearable device is fixed, optionally one wearable device comprising one accelerometer and one gyroscope, the wearable device being fixed at the waist of the user.
S20, inputting the motion test data into an optimal deep learning model, and identifying the motion category of the motion test data to acquire probability values of each motion category; specifically, the action categories include fall actions and daily activity actions; and inputting the acceleration data and the angular velocity value in the real-time acquisition data into an optimal deep learning model, wherein the optimal deep learning model outputs a falling action probability value and a daily activity action probability value corresponding to the real-time acquisition data.
As shown in fig. 2, the optimal deep learning model includes:
the residual error connection module 10 is used for extracting characteristics of the motion test data;
The full-connection softmax layer 20 is used for classifying the characteristics of the motion test data and outputting probability values of the motion test data corresponding to each motion category;
And the threshold moving algorithm layer 30 is used for adjusting the classification threshold, acquiring an optimal threshold and judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold.
S30, comparing the probability value of each action category with an optimal threshold value, and predicting the action category corresponding to the action test data; the optimal threshold is used for shifting the prediction result to an action category with low occurrence probability according to the unbalance rate of the sample data set used in the training of the deep learning model. Specifically, the fall motion probability value and the daily activity motion probability value are compared with an optimal threshold value to predict whether a fall motion occurs. Specifically, determining the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold value comprises the following steps:
When a falling probability value p output by certain action test data is compared with an optimal threshold lambda *, if p is more than or equal to lambda *, the optimal deep learning model predicts that the action test data is a falling action;
When the daily activity probability value q output by certain action test data is compared with the optimal threshold lambda *, if q is less than or equal to 1-lambda *, the optimal deep learning model predicts that the action test data is a falling action.
After the deep learning model is built, training is carried out on the model by using a training set and a verification set, parameters in the model are determined, in a living application scene, data of an accelerometer and a gyroscope are collected in real time by using a user wearing device, as shown in fig. 3, the data in 3s before and after the peak value of the data are marked as falling actions, continuous time sequence data are intercepted into fragments by using a sliding window with the width of 1s, after the real-time collection is preprocessed, whether falling events occur is predicted by inputting the data into the trained model.
The above method focuses on training of the optimal deep learning model and determining of the optimal threshold, so this embodiment provides a specific training method of the optimal deep learning model and determining method of the optimal threshold, which are specifically as follows:
Specifically, as shown in fig. 2, the deep learning model includes:
The residual error connection module 10 is used for extracting characteristics of the motion test data; specifically, the residual connection module 10 includes: the convolution layer is used for extracting characteristic information in the original signal; the batch normalization layer is used for carrying out normalization processing on the characteristic information and then carrying out nonlinear calculation on the activation function; and the residual error connection calculation unit is used for linearly superposing the extracted characteristic information with the original data. Specifically, the introduction of the residual connection calculation unit may skip one or more layers, and linearly superimpose the input original data and the feature information extracted from the original data by nonlinear change, so that, on one hand, the residual connection module 10 may better fit the classification function to obtain higher classification precision, and on the other hand, how to make the residual connection module 10 solve the problem of optimizing training when the layer number deepens.
Specifically, in the deep learning model training process, the training process of the residual error connection module is divided into two phases, specifically, a first phase is a phase of data propagation from a low level to a high level, namely a forward propagation phase, and a second phase is a process of propagating and training an error from the high level to a bottom level, namely a backward propagation phase, when the obtained result of the forward propagation does not accord with the expected result. Specifically, the training process of the residual connection module 10 is as follows: 1. initializing a weight value by a network; 2. the input data is transmitted forwards through a convolution layer and the like to obtain an output value; 3. solving an error between an output value and a target value of the network; 4. when the error is greater than 0, the error is transmitted back to the network; 5. and updating the weight according to the obtained error, and then carrying out forward propagation calculation again.
Specifically, the residual connection module 10 includes four first to fourth residual connection units sequentially connected, and specifically, as shown in fig. 4, each residual connection unit includes: the first convolution layer, the first normalization layer (Batch Normalization layers), the second convolution layer, the second normalization layer and the residual error connection calculation subunit; the first convolution layer and the second convolution layer in the first residual error connecting unit comprise 64 convolution kernels, the first convolution layer and the second convolution layer in the second residual error connecting unit comprise 128 convolution kernels, the first convolution layer and the second convolution layer in the third residual error connecting unit comprise 256 convolution kernels, and the first convolution layer and the second convolution layer in the fourth residual error connecting unit comprise 512 convolution kernels; more specifically, all convolution kernels in the first to fourth residual connection units are 1x3 convolution kernels; the number of the four residual connection units is increased to enable better extraction of deep features of the data.
Specifically, according to time sequence data of accelerometers and gyroscopes of a large number of users on intelligent wearable equipment, a sample data set of daily activities and falling of the people is formed; specifically, in the process of establishing a data set, daily life data and data simulating falling of a plurality of users are collected, a sample data set containing a large amount of data is established, parameters of an algorithm model are adjusted through the sample data set before use, and errors of model prediction are reduced.
Randomly dividing a sample data set into a training set and a verification set according to the ratio of 3:1; preprocessing the data in the original acquired sample dataset, specifically, the preprocessing comprises segmentation and marking of the data: firstly, marking the data of each segment, wherein 0 represents daily activity action data, 1 represents falling event action data, and then cutting the original continuous data into segments by using a sliding window.
Specifically, before the residual connection module 10 is trained, initializing original parameters of the residual connection module 10, wherein a weight parameter adopts an Xavier initialization mode, and a bias parameter adopts an all 0 initialization mode; the training set is used as the input of the residual connection module 10, the residual connection module 10 is trained for a plurality of times, after the parameter adjustment and training are carried out for a plurality of times, the error is reduced along with the counter propagation calculation times of the model, when the calculation times are enough, the error of the model tends to be stable from rapid reduction in initial training, and the network model weight with good performance in the test set is obtained. Optionally, in this embodiment, the function of calculating the error by the residual connection module 10 uses a cross entropy loss function, and it is found from experiments that after 50 times of back propagation calculation, the error is stable, so that the training calculation parameters of the model are set to be 50, and the model training is completed after 50 times of back propagation calculation.
In this embodiment, the softmax layer is fully connected, firstly, the weight matrix obtained by the residual error connection module 10 converts input data into output with the same number of categories, and then the softmax activation function converts each category probability of the output into probability within the range of 0-1, and ensures that the sum of the probabilities of all categories is 1. And comparing the probability value of each action category corresponding to the output action test data of the fully connected softmax layer 20 with an optimal threshold value, and predicting the action category corresponding to the action test data.
In the deep learning network, as the network depth increases, the characteristics in the sample data set can be better extracted, and the model performance is better, but as the network depth increases, the gradient vanishes and other problems are brought. The residual connection module 10 can well solve the problems of gradient disappearance and gradient explosion of the deep learning model.
Specifically, the adjusting the classification threshold to obtain the optimal threshold includes:
S100, acquiring a sample data set, dividing the data in the sample data set into daily activity sample data and falling sample data, and counting the daily activity sample data quantity and the falling sample data quantity;
S200, calculating the sample unbalance rate according to the ratio of the daily life sample data quantity to the falling sample data quantity;
And S300, adjusting classification thresholds according to the sample unbalance rate, and determining the optimal threshold, wherein the optimal threshold is a falling action threshold lambda *. The optimal threshold lambda * is expressed as:
λ*=k×e-ρ/a+b
Wherein lambda * is the optimal threshold, k is the default threshold of the classifier, ρ is the unbalance rate of the sample data set, a and b are constants, n max is the number of daily life data in the sample data set, and n min is the number of falling sample data in the sample data set. Optionally, the default threshold k=0.5 of the classifier; a and b are determined through a threshold movement function curve, and the threshold movement function curve is obtained by fitting a falling action test threshold corresponding to different unbalance rates in an experimental data set;
Specifically, the threshold movement function curve obtained through experimental data fitting specifically includes:
acquiring an experimental data set, dividing the experimental data set into a training set and a testing set, extracting characteristics of the input training set by using a threshold movement algorithm layer in a deep learning model, and outputting a falling action probability value p 'and a daily activity action probability value q' corresponding to the data, wherein p '+q' =1, and setting a falling action threshold value as lambda ', wherein the daily activity action threshold value is 1-lambda';
When the falling action probability value p 'corresponding to the output data is more than or equal to lambda', the prediction result is classified as falling action; when the motion probability value q 'of the daily activity is more than or equal to 1-lambda', classifying the prediction result as the daily activity motion; when the falling action threshold satisfies the formula (1), the falling action threshold is a falling action test threshold corresponding to the unbalance rate of the experimental data set As shown in fig. 5, a threshold movement function curve is obtained by fitting different unbalance rates to fall motion test thresholds, wherein the scale is fall motion test threshold points corresponding to the different unbalance rates, and the curve is a threshold movement function curve obtained by fitting the fall motion test thresholds and the unbalance rates. Fall action test threshold corresponding to different unbalance ratesThe expression is as follows:
where f represents the probability of occurrence of minority class data (i.e. fall motion data) in the training set, and f λ′ represents the probability of predicted minority class data (i.e. fall motion data) in the test set at the threshold λ'.
The higher the unbalance rate of the collected raw data, the more the threshold of the classifier is shifted towards the minority class. The optimal threshold determined according to the optimal threshold determining formula can improve the classification precision of the deep learning model on the class unbalanced data and reduce the omission of few classes.
Compared with the prior art, in the fall detection method based on the class imbalance signals, the class imbalance condition of real life activities is optimized through an algorithm value moving method, so that the prediction result of the optimal deep learning model moves to a small number of fall data classes, the deviation of most daily activity classes is reduced, the model can be ensured to detect accidental fall event data with lower occurrence probability from a large number of daily activity data, and the detection precision is higher; the invention is based on the deep learning network model, the deep learning method can automatically identify deep features from a large amount of data and adjust parameters of the model, and compared with the traditional algorithm model, the deep learning method can more accurately detect and identify falling events, the network model is trained and the parameters are adjusted through category unbalanced data acquired in real life, the trained model has good detection capability on the occurrence of small probability falling events, falling data signals can be identified from a large amount of daily activity data, and the condition of missing detection is reduced; finally, according to the data acquired by the accelerometer and the gyroscope in the intelligent wearable device, the real life falling data set established after certain preprocessing is carried out, and the established type unbalanced falling detection model is trained and tested on the real life falling data set, so that the intelligent wearable device is more suitable for being applied to real life.
As shown in fig. 6, in one embodiment of the present invention, a fall detection system based on a class imbalance signal is disclosed, comprising:
The data acquisition module 10 is used for acquiring action test data of a user acquired by the intelligent wearable equipment in real time; the action test data includes: acceleration data and angular velocity values;
The probability calculation module 20 is configured to input the motion test data into an optimal deep learning model, perform motion category recognition of the motion test data, and obtain probability values of each motion category;
A prediction module 30, configured to compare the probability value of each action category with an optimal threshold value, and predict an action category corresponding to the action test data; the optimal threshold is used for shifting the prediction result to an action category with low occurrence probability according to the unbalance rate of the sample data set used in the training of the deep learning model.
Specifically, the optimal deep learning model in the probability calculation module includes:
the residual error connection module is used for extracting characteristics of the action test data;
The full-connection softmax layer is used for classifying the characteristics of the motion test data and outputting probability values of the motion test data corresponding to each motion category;
And the threshold moving algorithm layer is used for adjusting the classification threshold, acquiring an optimal threshold and judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold. Specifically, the threshold shifting algorithm layer includes:
The sample data acquisition unit is used for acquiring a sample data set, dividing the data in the sample data set into daily activity sample data and falling sample data, and counting the daily activity sample data quantity and the falling sample data quantity;
The unbalance rate acquisition unit is used for calculating the sample unbalance rate according to the ratio of the daily life sample data quantity to the falling sample data quantity;
An optimal threshold confirming unit, configured to adjust classification thresholds according to the sample unbalance rate, and determine the optimal threshold, where the optimal threshold is a falling action threshold lambda *; the optimal threshold lambda * is expressed as:
λ*=k×e-ρ/a+b
Wherein lambda * is the optimal threshold, k is the default threshold of the classifier, ρ is the unbalance rate of the sample data set, a and b are constants, n max is the number of daily life data in the sample data set, and n min is the number of falling sample data in the sample data set.
Those skilled in the art will appreciate that all or part of the flow of the methods of the embodiments described above may be accomplished by way of a computer program to instruct associated hardware, where the program may be stored on a computer readable storage medium. Wherein the computer readable storage medium is a magnetic disk, an optical disk, a read-only memory or a random access memory, etc.
The present invention is not limited to the above-mentioned embodiments, and any changes or substitutions that can be easily understood by those skilled in the art within the technical scope of the present invention are intended to be included in the scope of the present invention.
Claims (8)
1. A fall detection method based on category imbalance signals, comprising:
Acquiring action test data of a user acquired by intelligent wearable equipment in real time; the action test data includes: acceleration data and angular velocity values;
Inputting the motion test data into an optimal deep learning model, and identifying the motion category of the motion test data to acquire probability values of each motion category;
Comparing the probability value of each action category with an optimal threshold value, and predicting the action category corresponding to the action test data; the method for obtaining the optimal threshold value comprises the following steps:
Acquiring a sample data set, dividing the data in the sample data set into daily activity sample data and falling sample data, and counting the daily activity sample data quantity and the falling sample data quantity;
Calculating a sample unbalance rate according to the ratio of the number of the daily activity sample data to the number of the falling sample data;
According to the sample unbalance rate, adjusting a classification threshold, determining the optimal threshold, wherein the optimal threshold is a falling action threshold lambda *, and is expressed as:
*=k×e-p/a+b
Wherein lambda * is the optimal threshold, k is the default classification threshold of the classifier, ρ is the sample unbalance rate of the sample data set, a and b are constants, n max is the number of daily activity data in the sample data set, and n min is the number of falling sample data in the sample data set;
The optimal threshold is used for shifting the prediction result to an action category with low occurrence probability according to the unbalance rate of the sample data set used in the training of the deep learning model.
2. A fall detection method based on a category imbalance signal as claimed in claim 1, wherein,
The optimal deep learning model comprises:
the residual error connection module is used for extracting characteristics of the action test data;
The full-connection softmax layer is used for classifying the characteristics of the motion test data and outputting probability values of the motion test data corresponding to each motion category;
And the threshold moving algorithm layer is used for adjusting the classification threshold, acquiring an optimal threshold and judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold.
3. A fall detection method based on a category imbalance signal as claimed in claim 1, wherein,
The action category includes fall actions and daily activity actions; judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold value, comprising:
When a falling probability value p output by certain action test data is compared with an optimal threshold lambda *, if p is more than or equal to lambda *, the optimal deep learning model predicts that the action test data is a falling action;
When the daily activity probability value q output by certain action test data is compared with the optimal threshold lambda *, if q is less than or equal to 1-lambda *, the optimal deep learning model predicts that the action test data is a falling action.
4. A fall detection method based on a category imbalance signal as claimed in claim 2, wherein,
The residual connection module comprises:
The convolution layer is used for extracting characteristic information in the original data;
The batch normalization layer is used for carrying out normalization processing on the characteristic information and then carrying out nonlinear calculation on the activation function;
and the residual error connection calculation unit is used for linearly superposing the extracted characteristic information with the original data.
5. A fall detection method based on a category imbalance signal as claimed in claim 4, wherein,
The convolution layer includes: a first convolution layer, a second convolution layer;
The batch normalization layer includes: a first normalization layer and a second normalization layer;
The residual error connection module comprises four first to fourth residual error connection units which are sequentially connected, and each of the first to fourth residual error connection units comprises the following components in sequence: the first convolution layer, the first normalization layer, the second convolution layer, the second normalization layer and the residual error are connected with the calculating subunit;
The first convolution layer and the second convolution layer in the first residual error connection unit comprise 64 convolution kernels;
the first convolution layer and the second convolution layer in the second residual error connection unit comprise 128 convolution kernels;
The first convolution layer and the second convolution layer in the third residual error connection unit comprise 256 convolution kernels;
The first convolution layer and the second convolution layer in the fourth residual error connection unit comprise 512 convolution kernels;
All convolution kernels in the first to fourth residual connection units are 1x3 convolution kernels.
6. A fall detection method based on a category imbalance signal as claimed in claim 1, wherein,
In the process of model training of the deep learning model, calculating the error in the model training process through the cross entropy loss function, and when the error is stable, the deep learning model is the optimal deep learning model.
7. A fall detection system based on a category imbalance signal, comprising:
The data acquisition module is used for acquiring action test data of a user acquired by the intelligent wearable equipment in real time; the action test data includes: acceleration data and angular velocity values;
The probability calculation module is used for inputting the motion test data into an optimal deep learning model, identifying the motion category of the motion test data and obtaining the probability value of each motion category;
The prediction module is used for comparing the probability value of each action category with an optimal threshold value and predicting the action category corresponding to the action test data; the optimal threshold is used for shifting the prediction result to an action category with low occurrence probability according to the unbalance rate of a sample data set used during training of the deep learning model; the method for obtaining the optimal threshold value comprises the following steps:
Acquiring a sample data set, dividing the data in the sample data set into daily activity sample data and falling sample data, and counting the daily activity sample data quantity and the falling sample data quantity;
Calculating a sample unbalance rate according to the ratio of the number of the daily activity sample data to the number of the falling sample data;
According to the sample unbalance rate, adjusting a classification threshold, determining the optimal threshold, wherein the optimal threshold is a falling action threshold lambda *, and is expressed as:
λ*=k×e-ρ/a+b
Wherein lambda * is the optimal threshold, k is the default classification threshold of the classifier, ρ is the sample imbalance rate of the sample dataset, a and b are constants, n max is the number of daily activity data in the sample dataset, and n min is the number of falling sample data in the sample dataset.
8. A fall detection system based on a category imbalance signal as claimed in claim 7, wherein,
The optimal deep learning model in the probability calculation module comprises:
the residual error connection module is used for extracting characteristics of the action test data;
The full-connection softmax layer is used for classifying the characteristics of the motion test data and outputting probability values of the motion test data corresponding to each motion category;
And the threshold moving algorithm layer is used for adjusting the classification threshold, acquiring an optimal threshold and judging the action category of the action test data according to the relation between the probability value of each action category and the optimal threshold.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111448595.3A CN114327045B (en) | 2021-11-30 | 2021-11-30 | Fall detection method and system based on category imbalance signals |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111448595.3A CN114327045B (en) | 2021-11-30 | 2021-11-30 | Fall detection method and system based on category imbalance signals |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114327045A CN114327045A (en) | 2022-04-12 |
CN114327045B true CN114327045B (en) | 2024-07-26 |
Family
ID=81048062
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111448595.3A Active CN114327045B (en) | 2021-11-30 | 2021-11-30 | Fall detection method and system based on category imbalance signals |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114327045B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114983447B (en) * | 2022-08-01 | 2023-06-20 | 广东海洋大学 | Human action recognition, analysis and storage wearable device based on AI technology |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107578061A (en) * | 2017-08-16 | 2018-01-12 | 哈尔滨工业大学深圳研究生院 | Based on the imbalanced data classification issue method for minimizing loss study |
CN111488850A (en) * | 2020-04-17 | 2020-08-04 | 电子科技大学 | Neural network-based old people falling detection method |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US11182691B1 (en) * | 2014-08-14 | 2021-11-23 | Amazon Technologies, Inc. | Category-based sampling of machine learning data |
US20190102674A1 (en) * | 2017-09-29 | 2019-04-04 | Here Global B.V. | Method, apparatus, and system for selecting training observations for machine learning models |
CN112016597B (en) * | 2020-08-12 | 2023-07-18 | 河海大学常州校区 | Depth sampling method based on Bayesian unbalance measurement in machine learning |
CN112595906B (en) * | 2020-10-09 | 2022-05-10 | 国网浙江省电力有限公司湖州供电公司 | Method for judging abnormal operation of transformer area |
CN113220960A (en) * | 2021-05-12 | 2021-08-06 | 西安理工大学 | Unbalanced time series data classification method based on autonomous learning |
-
2021
- 2021-11-30 CN CN202111448595.3A patent/CN114327045B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107578061A (en) * | 2017-08-16 | 2018-01-12 | 哈尔滨工业大学深圳研究生院 | Based on the imbalanced data classification issue method for minimizing loss study |
CN111488850A (en) * | 2020-04-17 | 2020-08-04 | 电子科技大学 | Neural network-based old people falling detection method |
Also Published As
Publication number | Publication date |
---|---|
CN114327045A (en) | 2022-04-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108446733A (en) | A kind of human body behavior monitoring and intelligent identification Method based on multi-sensor data | |
CN107220617A (en) | Human body attitude identifying system and method | |
CN105160318A (en) | Facial expression based lie detection method and system | |
CN112560723B (en) | Fall detection method and system based on morphological recognition and speed estimation | |
CN107909027A (en) | It is a kind of that there is the quick human body target detection method for blocking processing | |
CN105268171B (en) | gait monitoring method, device and wearable device | |
Jensen et al. | Classification of kinematic swimming data with emphasis on resource consumption | |
CN107016233A (en) | The association analysis method and system of motor behavior and cognitive ability | |
US20210150284A1 (en) | Classification model building apparatus and classification model building method thereof | |
CN113642432B (en) | Method for recognizing human body posture by convolutional neural network based on covariance matrix transformation | |
KR20120052610A (en) | Apparatus and method for recognizing motion using neural network learning algorithm | |
CN112801000B (en) | Household old man falling detection method and system based on multi-feature fusion | |
CN110414306B (en) | Baby abnormal behavior detection method based on meanshift algorithm and SVM | |
CN114626419B (en) | Action recognition method based on channel state information in WIFI and improved convolutional neural network | |
CN114898470A (en) | Fall behavior detection method and system based on improved YOLOv5 | |
CN109101943A (en) | It is a kind of for detecting the machine vision method of Falls Among Old People | |
CN114327045B (en) | Fall detection method and system based on category imbalance signals | |
CN112464738A (en) | Improved naive Bayes algorithm user behavior identification method based on mobile phone sensor | |
CN117133057A (en) | Physical exercise counting and illegal action distinguishing method based on human body gesture recognition | |
CN111144167A (en) | Gait information identification optimization method, system and storage medium | |
US20220027726A1 (en) | Pre-processing device, pre-processing method, and pre-processing program | |
Keller et al. | SMOTE and ENN based XGBoost prediction model for Parkinson’s disease detection | |
CN116747495A (en) | Action counting method and device, terminal equipment and readable storage medium | |
US20230127412A1 (en) | Method for prevention of fall risk and apparatus for performing the method | |
Cenedese et al. | A parsimonious approach for activity recognition with wearable devices: An application to cross-country skiing |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |