Data processing method and apparatus, terminal device, storage medium, and program product
By adaptively adjusting the gait detection time interval of wearable devices, the problem of data collection that cannot adapt to individual differences in existing technologies is solved, enabling low-power long-term monitoring, ensuring the collection of key information, and making it suitable for health monitoring and home medical observation.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA MOBILE COMM LTD RES INST
- Filing Date
- 2024-10-22
- Publication Date
- 2026-04-24
AI Technical Summary
Existing wearable devices have fixed time intervals for data collection, which cannot adapt to individual differences. This makes it impossible to accurately cover the monitoring of each user's human body status. Furthermore, continuous monitoring consumes too much power, and manual wake-up of the monitoring can easily miss key information, making it difficult to achieve long-term low-power home monitoring.
By adaptively adjusting the gait detection time interval, the acquisition time interval is dynamically adjusted according to the user's gait parameter change trend to conform to the preset trend, avoiding unnecessary power and resource waste. IMU sensors and adaptive algorithms are used for gait data acquisition and analysis.
It enables adaptive adjustment of gait data detection intervals under individual differences, reduces power consumption, avoids invalid data collection, meets the long-term low-power home monitoring needs, and ensures that key information is not missed.
Smart Images

Figure CN119454003B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a data processing method and apparatus, terminal equipment, storage medium, and program product. Background Technology
[0002] With the development of wearable device technology, it can be applied to the monitoring of human body conditions, such as gait monitoring. To achieve gait monitoring, wearable devices typically need to collect motion data. Currently, when using wearable devices for data collection, the collection mode is usually preset. For example, the collection mode of a wearable device may be preset at the factory according to the usage scenario, or it may be preset by the user during initial use. However, because each person's situation is different, their data collection mode, such as the data collection interval, actually needs to vary from person to person and is not a uniform time value. Therefore, a preset fixed collection mode cannot accurately cover the monitoring of each user's human body condition. Summary of the Invention
[0003] To address the aforementioned technical problems, embodiments of this application provide a data processing method and apparatus, a terminal device, a storage medium, and a program product.
[0004] In a first aspect, embodiments of this application relate to a data processing method applied to a first terminal, comprising:
[0005] Gait data of N1 gait detections in the first gait detection sub-cycle of the target object are collected according to a first time interval. Gait parameters corresponding to the N1 gait detections in the first gait detection sub-cycle are calculated based on the gait data of the N1 gait detections in the first gait detection sub-cycle. It is then determined whether the changing trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to a first trend. Wherein, N1 is an integer greater than or equal to 2. The first time interval is the time interval between each two adjacent gait detections in the N1 gait detections of the first gait detection sub-cycle.
[0006] If the trend of the change of gait parameters in the first gait detection sub-cycle does not conform to the first trend, the first time interval is adjusted, and the step of collecting gait data of N1 gait detections in the next second gait detection sub-cycle after the first gait detection sub-cycle is performed according to the adjusted time interval, until the trend of the change of gait parameters corresponding to the Nth gait detection sub-cycle obtained by collecting gait data according to the finally adjusted second time interval conforms to the first trend.
[0007] The second time interval is defined as the time interval between two adjacent gait detections in the N1th gait detection sub-cycle of each gait detection of the target object.
[0008] Secondly, embodiments of this application provide a data processing apparatus applied to a first terminal, comprising:
[0009] The first processing unit is configured to collect gait data of N1 gait detections in the first gait detection sub-cycle of the target object according to a first time interval, calculate the gait parameters corresponding to the N1 gait detections in the first gait detection sub-cycle based on the gait data of the N1 gait detections in the first gait detection sub-cycle, and determine whether the changing trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to a first trend; wherein, N1 is an integer greater than or equal to 2; the first time interval is the time interval between each two adjacent gait detections in the N1 gait detections of the first gait detection sub-cycle;
[0010] The second processing unit is used to adjust the first time interval when it is determined that the changing trend of the gait parameters of the first gait detection sub-cycle does not conform to the first trend, and to perform the step of collecting gait data of N1 gait detections in the next second gait detection sub-cycle after the first gait detection sub-cycle according to the adjusted time interval, until the changing trend of the corresponding gait parameters of the Nth gait detection sub-cycle calculated according to the finally adjusted second time interval conforms to the first trend.
[0011] The determining unit is used to determine the second time interval as the time interval between two adjacent gait detections in the N1th gait detection of each gait detection sub-cycle of the target object.
[0012] Thirdly, embodiments of this application provide a terminal device, including: a memory and a processor, wherein the memory stores computer-executable instructions, and the processor, when executing the computer-executable instructions in the memory, can implement the method described in the first aspect of the embodiments above.
[0013] Fourthly, embodiments of this application provide a computer storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method described in the first aspect of the embodiments above.
[0014] Fifthly, embodiments of this application provide a computer program product, including a computer program that, when executed by a processor, implements the method described in the first aspect of the embodiments.
[0015] The technical solution of this application embodiment utilizes the user's preset gait parameter change trend (i.e., the first trend) to adjust the time interval for gait detection. When the gait parameters corresponding to the gait data collected according to the adjusted time interval conform to the preset gait parameter change trend (i.e., the first trend), the adjusted time interval is determined to be the appropriate time interval for gait data detection. In this way, even when there are differences among each user, the time interval for gait data detection can be determined by adaptive adjustment to obtain a gait detection scheme suitable for each individual, avoiding the waste of power, time, and data acquisition resources. Attached Figure Description
[0016] Figure 1 Flowchart of the data processing method provided in the embodiments of this application Figure 1 ;
[0017] Figure 2 This is a schematic diagram of a hardware sensor;
[0018] Figure 3 This is a schematic diagram of gait parameter changes;
[0019] Figure 4 Flowchart of the data processing method provided in the embodiments of this application Figure 2 ;
[0020] Figure 5 A schematic diagram of the motion state detection process provided in an embodiment of this application;
[0021] Figure 6 Flowchart of the data processing method provided in the embodiments of this application Figure 3 ;
[0022] Figure 7 A flowchart illustrating the data acquisition and processing method provided in the embodiments of this application;
[0023] Figure 8 This is a schematic diagram of the structural composition of the data processing apparatus provided in the embodiments of this application;
[0024] Figure 9 This is a schematic diagram of the hardware structure of the terminal device provided in the embodiments of this application. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely represents selected embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0026] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be defined and explained in subsequent figures.
[0027] In this document, the term "and / or" merely describes a relationship, indicating that three relationships can exist. For example, A and / or B can represent three cases: A alone, A and B simultaneously, and B alone. Furthermore, the term "at least one" in this document means any combination of at least two of any one or more elements. For example, including at least one of A, B, and C can mean including any one or more elements selected from the set consisting of A, B, and C.
[0028] Wearable device technology can be used for health monitoring. For example, health smartwatches using photoelectric sensors can monitor blood pressure, pulse, etc., by calculating the periodic patterns of indicators such as hemoglobin transmittance using the "oscillometric method". This can be used for early warning of heart disease risks and to assist in home medical observation.
[0029] However, current wearable devices typically use a fixed data collection mode set at the factory: either continuous monitoring or manual wake-up monitoring. The first type, continuous monitoring, is limited by battery power, making it difficult to support long-term standby use. The second type, manual wake-up monitoring, is prone to missing some danger warnings and some natural monitoring information that requires the user to be in a conscious state, such as the white coat effect and the observer effect. It cannot present disease manifestations in a natural state, and the interval between each data collection varies from person to person, making it difficult to completely fix in advance.
[0030] Therefore, home-based mobile medical post-diagnosis management needs a method that can overcome the shortcomings of the two paradigms mentioned above, be tailored to individuals and business needs, not miss key information monitored under natural conditions, and avoid the power consumption caused by massive data collection, thus achieving long-term standby.
[0031] Taking Parkinson's disease, a neurological disorder, as an example, long-term monitoring can be used to adjust medication dosage. The brain lesions will manifest as motor symptoms such as tremors. These motor symptoms can be monitored using motion sensors.
[0032] (1) After taking the medication every day, under suitable physical condition, monitor the movement pattern of key gait indicators 5 times, with a certain time interval between each time (e.g., 1 hour interval, 2 minutes measurement each time. The interval time varies from person to person. Each person's physical condition and disease course are different, and the applicable effect of different drugs is different. It is necessary to find the cycle length from the "on period" when the drug is effective to the "off period" when it is ineffective. The 5 accurate monitoring needs to completely cover this cycle).
[0033] (2) Continue for 7 consecutive days and judge whether the changes in key gait indicators between each day and between each time are abnormal;
[0034] (3) For abnormal data, in addition to the periodicity of key gait indicators, doctors also need the original movement details for detailed analysis.
[0035] If the interval or the posture status of a certain monitoring is not up to standard, invalid data will be generated, and all data collection for a day will need to be redone, wasting the valuable standby power of the wearable device.
[0036] Long-term monitoring needs in natural home settings require a standby time of more than three months; current wearable devices such as mobile phones and watches cannot meet this standby requirement.
[0037] Wearable devices based on minimalist miniature inertial measurement units (IMUs) on the soles of the feet are suitable for long-term monitoring needs, but to achieve standby time of more than three months and meet stringent medical requirements, intelligent selection of data acquisition, storage, and transmission is necessary. The challenge lies in:
[0038] (1) Each person's situation is different, and the interval between each collection is also different. How can the intelligent system automatically provide a solution for selection, experimentation and correction that is suitable for each person and avoid wasting time and power?
[0039] (2) Check whether each data collection is in accordance with the collection posture, etc., to avoid wasting power due to unqualified data collection behavior;
[0040] (3) Abnormal data that does not conform to the periodic pattern requires more detailed raw data information in addition to the calculated index parameters. The periodic pattern needs to be judged after collecting data for a certain number of days. How to save resources and electricity waste most effectively.
[0041] The aforementioned needs and challenges determine that manual real-time monitoring by doctors is not suitable (requires home observation, a natural state, and avoidance of the white coat effect), nor is it suitable for patients to monitor themselves (high complexity, decreased ability of the elderly and patients, and difficulty in obtaining a natural posture without deliberate effort during manual monitoring), and ordinary wearable devices are difficult to meet (uninterrupted monitoring cannot meet the requirements of long-term low power consumption, and fixed paradigms are prone to missing key information).
[0042] The technical solution of this application can save resources and power wasted due to unsuitable single collection of unqualified data, multiple collections of unqualified data, and the regularity of periodic collection of unqualified data, thereby improving the long-term standby capability of minimalist wearable devices.
[0043] Below, in conjunction with Figures 1 to 7 The data processing methods of the embodiments of this application will be described in various embodiments.
[0044] Figure 1 Flowchart of the data processing method provided in the embodiments of this application Figure 1 Applied to the first terminal, including:
[0045] S101: Collect gait data of N1 gait detections of the first gait detection sub-cycle of the target object according to the first time interval, calculate the gait parameters corresponding to the N1 gait detections of the first gait detection sub-cycle based on the gait data of the first gait detection sub-cycle, and determine whether the changing trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to the first trend.
[0046] S102: If it is determined that the trend of the change of gait parameters in the first gait detection sub-cycle does not conform to the first trend, the first time interval is adjusted, and the step of collecting gait data of N1 gait detections in the next second gait detection sub-cycle after the first gait detection sub-cycle according to the adjusted time interval is executed, until the trend of the change of gait parameters corresponding to the Nth gait detection sub-cycle obtained by collecting gait data according to the finally adjusted second time interval conforms to the first trend.
[0047] S103: The second time interval is determined as the time interval between two adjacent gait detections in the N1th gait detection of each gait detection sub-cycle of the target object.
[0048] In this embodiment of the application, N1 is an integer greater than or equal to 2; the first time interval is the time interval between each two adjacent gait detections of the N1th gait detection of the first gait detection sub-cycle.
[0049] For example, a gait detection sub-cycle can be 1 day, and a gait detection sub-cycle requires 5 gait detections, meaning that 5 gait detections need to be performed per day. There is a time interval between the 5 gait detections, which can be preset with an initial value, such as the first time interval.
[0050] For example, if the target subject takes medication once a day, under suitable exercise conditions, from the time t0 after taking the medication to a period of time thereafter, such as within 12 hours, the entire time period includes the period after the target subject takes medication when the drug effect has not yet taken effect, the period when the drug effect is strongest, the period when the drug effect gradually weakens, and the period when the drug effect has basically disappeared. At different times, the impact on the target subject's gait parameters is different, and the performance of the target subject's gait parameters is different. The trend of the target subject's gait parameters throughout the entire time period should conform to an expected trend.
[0051] In practical applications, gait data can be collected using... Figure 2 The hardware sensor implementation shown is as follows: Figure 2 This image shows a smart insole with an embedded IMU sensor and the IMU chip. The IMU can collect gait data from the target object; the gait data collected by the IMU is six-axis sensor data, including raw acceleration and angular velocity data.
[0052] For each gait detection in the first gait detection sub-cycle, the target object is reminded to walk when the gait detection time arrives, thereby detecting the gait data of the target object in the walking state.
[0053] In this embodiment of the application, the number of categories of gait parameters corresponding to the N1 gait detections in the first gait detection sub-cycle is N2.
[0054] In this embodiment, gait parameters, also known as gait indices, include parameters such as stride length and gait cycle. The types of gait parameters are listed below:
[0055] 1) Duration of swing phase on one side of the leg: Among them, T i O This indicates the moment when the toes leave the ground in step i. This indicates the moment when the heel touches the ground in the (i+1)th step;
[0056] 2) Duration of unilateral foot support phase: stD i =T i O -T i HS Among them, T i HS T represents the moment when the heel strikes the ground in the i-th step. iO This indicates the moment when the toes leave the ground in step i;
[0057] 3) Unilateral foot height: in, This represents the highest vertical position of the foot in step i, while This indicates the lowest vertical position of the foot in the i-th step;
[0058] 4) Unilateral foot width: in, This represents the furthest horizontal position of the foot in step i, while This indicates the closest horizontal position of the foot in step i;
[0059] 5) Unilateral step length: in, This represents the furthest position of the foot in the longitudinal (front-back) direction during step i, while This indicates the closest vertical position of the foot in step i;
[0060] 6) Coefficient of variation of pitch angle and angular velocity during single-foot landing: Among them, hsPv i Let be the pitch angular velocity of one foot during the foot landing phase (loading phase) of the i-th gait cycle; Count is the total number of gait cycles; μ(hsPv) is the mean pitch angular velocity of one foot during the foot landing phase; s(hsPv) is the standard deviation of the pitch angular velocity of one foot during the foot landing phase.
[0061] 7) Coefficient of variation of pitch angle angular velocity during unilateral leg extension: Among them, toPv i Let μ(toPv) represent the pitch angular velocity of one leg during the push-off phase of the i-th gait cycle, μ(toPv) be the mean pitch angular velocity of one leg during the push-off phase, s(toPv) be the standard deviation of the pitch angular velocity of one leg during the push-off phase, and Count be the total number of gait cycles.
[0062] 8) Unilateral footwork has a high coefficient of variation: Here, s(sH) is the standard deviation of the step height, and μ(sH) is the mean of the step height. i It is the height of the i-th step, and Count is the number of steps;
[0063] 9) Coefficient of variation of swing width on one side: Where s(sW) is the standard deviation of the foot swing width, μ(sW) is the average foot swing width, sW is the foot swing width at step i, and Count represents the total number of steps;
[0064] 10) Coefficient of variation of unilateral foot length: Among them, sL i Let represent the step size of the i-th step, and Count represent the total number of steps taken.
[0065] It is understandable that when determining whether the changing trend of the step parameters corresponding to the first step detection sub-cycle conforms to the first trend, it can be determined whether the changing trend of some of the gait parameters listed above conforms to the first trend, or it can be determined whether the changing trend of all the gait parameters listed above conforms to the first trend.
[0066] Figure 3 A schematic diagram illustrating six possible trends in gait parameters after drug administration to the target subject.
[0067] Figure 3 In the diagram, t0 to t4 represent sampling times, and P0 to P4 represent gait parameter values at the corresponding sampling times. Time t0 is the data collection time immediately after medication administration, before the medication has taken effect. Therefore, P0 can be considered as a gait indicator before medication administration. Figure 3 The curves of type one represent changes in gait parameters inhibited by the drug, while the curves of type two represent changes in gait parameters promoted by the drug.
[0068] Figure 3 The curve represents the change in gait parameters. The five detection times are evenly distributed throughout the entire drug action period, with t2 being the time when the drug effect is strongest and t4 being the time when gait parameters recover before medication. However, in actual measurements, two scenarios may occur. Scenario one occurs because the sampling interval is too short, causing the collection to end before the drug effect disappears. Scenario two occurs because the sampling interval is too long, causing the drug effect to have largely disappeared by time t3. Both scenarios will lead to inaccurate detection of the drug's effect on gait. Therefore, it is necessary to adjust the detection time interval through a detection time planning algorithm to achieve the effect of the standard detection change curve.
[0069] In some implementations, determining whether the trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to the first trend in step S101 above can be achieved through the following steps:
[0070] S1011: Calculate the difference ratio and / or change ratio of each type of gait parameter in the N2 type of gait parameters in the first gait detection sub-cycle based on the values of the N1 gait detections corresponding to the N2 type gait parameters in the first gait detection sub-cycle.
[0071] S1012: Compare the difference ratio of various gait parameters in the first gait detection sub-cycle with the difference ratio threshold corresponding to each gait parameter to obtain a first comparison result; and / or, compare the change ratio of various gait parameters in the first gait detection sub-cycle with the change ratio threshold corresponding to each gait parameter to obtain a second comparison result;
[0072] S1013: Determine whether the changing trend of each gait parameter corresponding to the first gait detection sub-cycle conforms to the first trend based on the first comparison result and / or the second comparison result.
[0073] Combination Figure 3 In this embodiment of the application, the difference ratio and change ratio of gait parameters are introduced to determine whether the trend of gait parameter change conforms to the first trend. The specific method is as follows:
[0074] σ is the difference ratio, used to determine whether the state at time t4 has recovered to the state before medication, i.e., recovered to the state at time t0. The difference ratio σ is calculated using the following formula 1:
[0075]
[0076] ∈ represents the rate of change, used to determine whether the drug effect ends at time t3, i.e., the change in gait parameters is minimal during the process from t3 to t4. The rate of change ∈ is calculated using the following formula 2:
[0077]
[0078] The following conditions ① to ③ can be used to determine whether the trend of gait parameters conforms to the first trend by using the difference ratio σ and / or the change ratio ∈:
[0079]
[0080] σ threshold The difference ratio threshold is set to 0.1; ∈ threshold The change rate threshold is set to 0.1.
[0081] △T current In the calculation formula, condition ① corresponds to Figure 3 In scenario one, where the rate of change of gait parameters exceeds the difference rate threshold, the trend of gait parameter changes corresponds to... Figure 3 In case one, it does not conform to the trend of the standard curve; condition ② corresponds to... Figure 3 Case two, where the difference ratio of gait parameters is less than or equal to the difference ratio threshold, and the change ratio of gait parameters is less than or equal to the change ratio threshold, also does not conform to the trend of the standard curve. The first trend in this application embodiment is... Figure 3The trend of the standard curve in the diagram.
[0082] In some implementations, the first time interval can be adjusted in the following ways:
[0083] S1021: If the first comparison result is that the difference ratio of various gait parameters in the first gait detection sub-cycle is greater than the difference ratio threshold corresponding to various gait parameters, the first time interval is adjusted to the duration of the first time interval plus a set time step.
[0084] S1022: If the first comparison result is that the difference ratio of various gait parameters in the first gait detection sub-cycle is less than or equal to the difference ratio threshold corresponding to each type of gait parameter, and the second comparison result is that the change ratio of various gait parameters in the first gait detection sub-cycle is less than or equal to the change ratio threshold corresponding to each type of gait parameter, the first time interval is adjusted to the first time interval duration minus the set time step.
[0085] When adjusting the detection time, it can be done according to formula (3), where, in formula (3), △T last Δt represents the time interval between the last gait detection. adapt The time step for each adjustment of the gait detection time interval is set to 0.1h.
[0086] Condition ① corresponds to Figure 3 In scenario one, the detection time interval needs to be increased; condition ② corresponds to... Figure 3 In scenario two, the detection time interval needs to be reduced. In both scenarios, the difference ratio and change ratio of gait parameters still need to be calculated and judged in the next detection. Finally, condition ③ corresponds to... Figure 3 The standard change curve in the data does not require adjustment of the detection time interval, and the calculation and discrimination of the difference ratio and change ratio of gait parameters are no longer performed during subsequent detections.
[0087] The technical solution of this application embodiment utilizes the user's preset gait parameter change trend (i.e., the first trend) to adjust the time interval for gait detection. When the gait parameters corresponding to the gait data collected according to the adjusted time interval conform to the preset gait parameter change trend (i.e., the first trend), the adjusted time interval is determined to be the appropriate time interval for gait data detection. In this way, even when there are differences among each user, the time interval for gait data detection can be determined by adaptive adjustment to obtain a gait detection scheme suitable for each individual, avoiding the waste of power, time, and data acquisition resources. Figure 4 Flowchart of the data processing method provided in the embodiments of this application Figure 2 Applied to the first terminal, including:
[0088] S401: Adjust the first time interval to obtain the second time interval;
[0089] S402: Collect gait data of the target object for a specified period according to the second time interval;
[0090] S403: Calculate N4 gait parameters corresponding to each gait detection based on the gait data corresponding to each gait detection in the specified period;
[0091] S404: Perform lateral and / or longitudinal detection on each of the N4 gait parameters corresponding to each gait detection in the specified period, and determine whether there are any abnormalities in the gait data corresponding to each gait detection based on the detection results.
[0092] In this embodiment of the application, step S401 is based on the above. Figure 1 Steps S101 to S103 are implemented.
[0093] In this embodiment of the application, after determining the second time interval using step S401, gait data of the target object for a specified period are collected according to the second time interval.
[0094] In this embodiment of the application, the specified period includes N3 gait detection sub-periods, and each of the N3 gait detection sub-periods includes N1 gait detections. The second time interval is the time interval between the N1 gait detections included in each gait detection sub-period.
[0095] For example, the specified period can be 7 days, one gait detection sub-cycle is 1 day, and one gait detection sub-cycle requires 5 gait detections. That is, 5 gait detections are required per day. The time interval between each two adjacent gait detections is the second time interval. The time of the first gait detection in each gait detection sub-cycle is the moment when the target subject has just taken the medication.
[0096] For each gait detection in the first gait detection sub-cycle, the target object is reminded to walk when the gait detection time arrives, thereby detecting the gait data of the target object in the walking state.
[0097] In some implementations, step S402, collecting gait data of the target object for a specified period, can be achieved through the following steps:
[0098] S4021: For each gait detection in the specified period, after collecting the gait data of that gait detection, a motion detection algorithm is used to determine whether the target object's movement behavior in that gait detection is walking;
[0099] S4022: If it is determined that the target object's movement behavior in this gait detection is walking, save the collected gait data of this gait detection; otherwise, remind the target object to perform gait detection again until it is detected that the target object's movement behavior in this gait detection is walking.
[0100] In practical applications, N5 sets of gait data are collected for each gait detection in the specified period, and each set of gait data includes data from multiple dimensions.
[0101] For example, after determining that the target has taken the medication, the gait detection reminder module reminds the target to start gait detection, and at the same time, the data acquisition module is activated to collect the triaxial acceleration and triaxial angular velocity data output by the IMU in the insole in real time;
[0102] Motion detection algorithms are used to determine in real time whether a patient's movement behavior is walking, ensuring that data is saved and steps are counted only when the patient is walking, thereby improving the efficiency of storage and computing resource utilization.
[0103] In some implementations, step S404 can determine whether the target object's behavior is walking by using the following steps:
[0104] S4041: Perform dimensionality reduction and feature extraction on the first N6 gait data collected for this gait detection to obtain the differential features in the first N6 gait data;
[0105] S4042: Input the differential features into the motion behavior classification model to obtain the relative position of the differential features with respect to the hyperplane; determine whether the motion behavior detected in this gait detection is walking based on the relative position.
[0106] In this embodiment of the application, the hyperplane is a hyperplane obtained when training the motion behavior classification model, used to determine whether the running behavior is walking.
[0107] In practical applications, the motion state of a target object can be detected through... Figure 5 The method shown is used to achieve this. Figure 5 This is a schematic diagram of the motion state detection process provided in an embodiment of this application.
[0108] For each gait detection, the first n six-axis sensor data D are collected. n First, perform data dimensionality reduction and feature extraction. n =F(D) n ), where F is the dimensionality reduction calculation function, Feature n To obtain the features, the dimensionality reduction features reduce the six-axis sensor data in the original data to one dimension, and extract the differential features in the original data.
[0109] (1) The database contains n IMU six-axis data points, forming a matrix. Where x i Let be the row vector of the i-th row;
[0110] (2) Perform row zero mean, i.e.: Where x ij Let m be the j-th element of the i-th row vector, where m is the data dimension (6). This is the data matrix after row zero-mean normalization;
[0111] (3) Calculate the covariance matrix C. Where C is an m×m matrix;
[0112] (4) Calculate the eigenvalues and eigenvectors of C to obtain: λ1, λ2, ..., λ m c1, c2, ..., c m , where λ k For the k-th eigenvalue, c k For the corresponding m×1 feature vector, the standardized feature vector is:
[0113] (5) Arrange the eigenvalues from largest to smallest and select the largest eigenvalue λ. max , corresponding feature vector
[0114] (6) Multiplying the data matrix X by P reduces the data to 1 dimension, i.e.: Feature n =Y=XP, where Y is the n×1 dimensionality-reduced data.
[0115] (7) Determine whether the current state is walking by using the SVM binary classification model, i.e., state = F SVM (Feature n ), where F SVM The SVM model computes a function, where `state` represents the final output motion discrimination state. The SVM is first pre-trained on the dataset using supervised learning, and then further mapped to a high-dimensional space using a Gaussian kernel function φ(·). Among them l i For landmarks, all data are selected here as landmarks, i.e., i = 1, ..., n, δ is a hyperparameter, and landmark l i The center position of the mapping to the high-dimensional space is determined, and δ determines the degree of dispersion from the center position. In the process of continuous iterative adjustment, the optimal hyperplane for data classification is calculated, and support vectors are found near the hyperplane to maximize the margin of the classification boundary. Finally, the classification hyperplane is obtained, which can be represented by w and b, where w is the orientation parameter of the classification hyperplane and b is the position parameter.
[0116] (8) During testing, the dimensionality-reduced data is input into the SVM model. The kernel function maps the data to a high-dimensional space, determines the relative position of the input data on the hyperplane, and obtains the final patient movement type as walking or other. The calculation formula is as follows: Where x is the input data for the SVM, y is the label of the data location, y=1 indicates above the hyperplane, which is walking, and y=-1 indicates below the hyperplane, which is other behavior, which is not walking.
[0117] Based on the output of the motion detection algorithm, different operations are selected and executed.
[0118] (1) If the patient is not walking, remind the patient to start gait detection again through the gait detection reminder module;
[0119] (2) If the patient is walking, start storing gait data and use the peak detection algorithm to calculate the number of steps.
[0120] In this embodiment of the application, gait data is collected each time by determining in real time whether the target object is walking. If the target object is not walking, the target object is prompted to start walking, ensuring that gait data is collected when the target object is walking. This avoids the waste of resources caused by collecting unqualified gait data in a single collection.
[0121] In this embodiment of the application, after completing the gait data collection for all gait detection sub-cycles of a specified period, the first terminal calculates the gait parameters corresponding to each gait detection sub-cycle based on the gait data corresponding to each gait detection sub-cycle of the specified period. Here, the calculation of the types of gait parameters can be one or more.
[0122] In this embodiment of the application, for each gait parameter, the lateral detection is the detection of the changing trend of the gait parameter in the corresponding gait detection sub-cycle; the longitudinal detection is the detection of the deviation of the gait parameter from the average value of the gait parameter in the corresponding gait detection sub-cycle.
[0123] The specific detection methods for transverse and longitudinal inspections are described below.
[0124] Before performing lateral and / or longitudinal detection, the first terminal will first determine whether all gait detections for the specified period have been completed. If not, it will continue to remind the target to take medication and perform gait detections daily until all gait detections for the specified period are completed. If completed, it will use lateral and longitudinal detection algorithms to detect the gait parameter variation patterns of each gait detection sub-cycle and the gait parameter deviation value within a gait detection cycle (i.e., the specified period).
[0125] In some implementations, the step of lateral detection of gait parameters in step S404 above is as follows:
[0126] S4043: For each gait detection sub-cycle in the specified period, calculate the value of the second-order forward difference of each gait parameter in the N4 gait parameters corresponding to the sub-gait detection sub-cycle in the gait detection sub-cycle.
[0127] S4044: If the values of the second-order forward difference of each gait parameter in the gait detection sub-cycle meet the predetermined conditions, it is determined that the gait parameters corresponding to the gait detection sub-cycle conform to the second trend; otherwise, it is determined that the gait data corresponding to the gait detection sub-cycle is abnormal.
[0128] For lateral measurements, taking the observation of gait parameter changes in Parkinson's patients after a single dose of medication on the same day in five separate measurements as an example, clinical observations of Parkinson's patients after medication show that the drug's regulatory effect on gait gradually increases within 2 hours after administration, reaching its maximum around 2 hours, and then gradually weakens. Therefore, there are two possible trends in the changes of the corresponding gait parameters, such as... Figure 3 The standard variation curves are shown, with the horizontal axis representing time after medication and the vertical axis representing the magnitude of gait parameters. P0 to P4 represent different times t. i The gait parameter values are as follows.
[0129] △f(t i )=f(t i+1 )-f(t i )
[0130] △ 2 f(t j )=△f(t j+1 )-△f(t j )
[0131]
[0132] Where, f(t) j ) represents the gait parameter value at time i; △f(t) i ) represents the first-order forward difference, where i takes values of 0, 1, 2, and 3; △ 2 f(t j ) represents the second-order forward difference, with j taking values of 0, 1, and 2; Q represents the output of the lateral detection; condition ① is that the values of the second-order forward difference are all greater than 0, corresponding to a concave gait parameter curve, i.e., the corresponding... Figure 3 For the type 1 curve, condition ② is that the values of the second-order forward difference are all less than 0, and the corresponding gait parameter curve is an upwardly convex function, that is, the corresponding... Figure 3For the curves of type two, both cases conform to the normal variation pattern; condition ③ is that neither of the above conditions is met, which indicates that the lateral detection is abnormal. For each gait parameter listed in the embodiments of this application, the abnormality of the gait parameter is determined by the corresponding discrimination formula described above.
[0133] In some implementations, the step of longitudinal detection of gait parameters in step S404 above is as follows:
[0134] S4045: For each of the N4 gait parameters, calculate the average value of the gait parameter in each gait detection sub-cycle of all sub-cycles included in the specified period, and determine the maximum and minimum average values of the gait parameter in all sub-cycles included in the specified period, and calculate the longitudinal detection threshold of the gait parameter based on the maximum and minimum average values.
[0135] S4046: For the i-th gait detection in N1 gait detections of each gait detection sub-cycle, calculate the deviation between the gait parameters corresponding to the i-th gait detection and the corresponding average value of the gait parameters; where i ranges from 1 to N1.
[0136] S4047: Compare the deviation value with the longitudinal detection threshold. If the deviation value is greater than the longitudinal detection threshold, determine that the original gait data corresponding to the gait parameter is abnormal; otherwise, determine that the original gait data corresponding to the gait parameter is not abnormal.
[0137] For longitudinal detection, taking five longitudinal measurements of gait parameters after one medication administration within a gait detection cycle as an example, the gait parameter calculated from the j-th gait data collection on day i is represented as P. i,j Calculate the mean value of the gait parameters for the j-th time over one detection period. The calculation formula is: N=7, then calculate the gait parameters and mean for the j-th time each day. deviation If it is greater than the threshold P j,max and express The maximum and minimum values in △ i,j If the value is greater than γ, then an anomaly is determined to exist in the vertical direction.
[0138] In some implementations, after performing step S404, for gait data that is determined to be abnormal, the first terminal sends the abnormal gait data to the second terminal so that the second terminal can analyze it; for gait data that is determined not to be abnormal, the first terminal sends the gait parameters corresponding to the gait data that is not abnormal to the second terminal.
[0139] In practical applications, different operations are selected based on the different discrimination results of gait anomaly detection.
[0140] If no gait abnormalities are observed in either the lateral or longitudinal directions, only the processed gait parameters are transmitted to the second terminal, without transmitting the original data. This significantly reduces data transmission volume and communication power consumption. The second terminal can be a cloud server or a portable terminal such as a mobile phone.
[0141] If gait abnormalities occur laterally or longitudinally, in addition to transmitting the processed gait parameters to the second terminal, the system also requests the data acquisition module to transmit the cached original data of the abnormal portion.
[0142] In some implementations, the second terminal can be a mobile phone, and the data acquisition module of the first terminal can also transmit the abnormal gait cache data to the body domain gateway (mobile phone); after receiving the abnormal gait data, the data request and transmission module of the second terminal transmits the data and gait parameters to the server.
[0143] In practical applications, the abnormal data analysis module in the server receives and stores the data uploaded by the body domain gateway (mobile phone). For abnormal data, it sends it to the doctor's end for calculation and analysis. The doctor adjusts the medication of the target subject based on the abnormal analysis, such as adjusting the dosage and time of medication.
[0144] The technical solution of this application introduces lateral and longitudinal detection methods. By performing lateral and / or longitudinal detection on gait data collected each time in a user-specified period, abnormal data in the gait data collected each time in the specified period can be detected. Based on the detection results, the data to be transmitted to the second terminal or cloud server is determined. This includes transmitting only the processed gait parameters when no abnormalities are detected, thus avoiding the waste of unnecessary data transmission resources. When abnormalities are detected, in addition to the processed gait parameters, the original data corresponding to the abnormal gait parameters is also transmitted for analysis by other users.
[0145] Figure 6 Flowchart of the data processing method provided in the embodiments of this application Figure 3 Applied to the first terminal, including:
[0146] S601: Adjust the first time interval when collecting gait data of the target object to obtain the second time interval corresponding to the target object;
[0147] S602: Collect gait data of the target object for each medication cycle in the specified number of days according to the second time interval.
[0148] S603: Calculate N4 gait parameters corresponding to each gait detection based on the gait data corresponding to each gait detection in the specified number of days;
[0149] S604: Perform lateral and / or longitudinal detection on each of the N4 gait parameters corresponding to each gait detection in the specified number of days, and determine whether there are any abnormalities in the gait data corresponding to each gait detection based on the detection results.
[0150] In practical applications, the target group can be a patient with a specific condition, such as Parkinson's disease. The gait data collection can be gait data collection for a specified period of time after the patient takes the medication. By collecting gait data for a specified period after the patient takes the medication, doctors can analyze the patient's medication process and adjust the patient's medication based on the relevant data.
[0151] Because different patients have different medication habits, physical conditions, and drug absorption rates, the drug's effects may vary from patient to patient. Therefore, it is necessary to tailor a gait detection time for each patient. Step S601 above is the step of tailoring a suitable gait detection interval for the patient. In this step, the first time interval is an initial time interval, which may be set by the doctor based on the general medication time pattern or the theoretical medication time pattern. However, it may not be suitable for the individual patient. Therefore, it is necessary to first adjust the initial time interval so that the adjusted second time interval conforms to the gait detection pattern of the individual patient's medication process.
[0152] In this embodiment of the application, after determining the second time interval corresponding to an individual patient, gait data of the patient for a specified period is collected according to the second time interval. For example, gait data is collected for five time periods after each day of medication for a 7-day period.
[0153] After collecting gait data from five time periods during the patient's daily medication administration over a 7-day period, one or more gait parameters for each testing time period within the 7-day period are calculated based on the gait data collected for each time period.
[0154] Subsequently, lateral and / or longitudinal tests were performed on the gait parameters calculated for each testing period within 7 days to determine whether there were any abnormalities in the patient's gait data for each test.
[0155] This is a flowchart illustrating the data acquisition and processing method provided in the embodiments of this application. Figure 7 The entire process enables the improvement of adaptive periodic business patterns for wearable devices during long-term standby at home. Figure 7 The solution is based on Figure 2 The hardware sensor shown implements gait data acquisition. Figure 7 The entire process relies on data interaction between the IMU, smart gateway (usually a mobile phone), and cloud platform.
[0156] The acquisition and processing of gait data includes: raw acceleration and angular velocity data acquired by the IMU, calculated gait indices (stride length, gait cycle, etc.), and a set of periodically changing gait indices for each week, day, and time period.
[0157] Figure 7 The acquisition and processing of gait data in China involves three progressive and iterative steps: single, multiple, and periodic. These steps respectively determine the validity of a single acquisition, the interval between multiple acquisitions, and the abnormality of the periodic data.
[0158] first, Figure 7 The first discrimination level includes the personalized determination of the data acquisition time interval, which dynamically and adaptively adjusts the time interval based on the user's personalized detection time planning and the changing patterns of gait parameters. The first level mainly includes the following steps one through three.
[0159] Step 1: Based on the patient's condition management needs, the doctor sets fixed time slots for each medication during the home recovery period. At the first fixed time slot, the mobile phone will activate a medication reminder. The patient confirms that the medication has been taken on time. If the medication has been taken on time, proceed to the next step. If the medication has not been taken on time, repeat this step according to the new reminder time set by the doctor.
[0160] Step Two: Input the patient's gait parameters from the previous day into the detection time planning algorithm. Changes in gait parameters (e.g., stride length) after medication can be categorized as follows: Figure 3 The six scenarios are shown.
[0161] Step 3: When the scheduled testing time arrives, the medication reminder module will remind the patient to take their medication on time with a specific sound. After taking the medication, the patient can manually provide feedback on their medication status. If no feedback is provided within 2 minutes, the medication reminder module will remind the patient to take their medication again.
[0162] Figure 7 The second discrimination level includes real-time status discrimination of each gait data collection. It mainly performs parallel real-time discrimination based on three conditions: motion state, number of steps, and time period. If the conditions are met, it proceeds to the third level.
[0163] Figure 7 The third level of discrimination involves combining periodic patterns to identify abnormal data, mainly by determining whether there are abnormalities in gait data through lateral and longitudinal detection.
[0164] In general, Figure 7 This approach integrates a three-tiered progressive joint discrimination condition adaptation with a three-level data processing method. It includes: daily multiple intervals for adaptive determination of individual and disease characteristics; joint determination of motion state time to determine the validity of single data collection; and discrimination of joint patterns arising from convex and concave functions in 7-day cycle data collection. This determines the fusion of the three levels of data collection, storage, and transmission (raw data, feature data, and cycle data), ensuring the most precise use of power resources and improving the long-term standby capability of minimalist wearable devices for home use.
[0165] The first level of discrimination involves a method for determining the interval time multiple times per day based on individual patient and disease characteristics, along with the corresponding methods for collecting, storing, transmitting, and processing raw data. The second level of discrimination involves determining whether a single data collection meets the acceptable collection posture and medication status, along with the corresponding methods for collecting, storing, transmitting, and processing characteristic data and raw data. The third level of discrimination involves a method for identifying abnormal data that conforms to a 7-day periodic pattern, along with the corresponding methods for collecting, storing, transmitting, and processing characteristic data, raw data, and periodic data.
[0166] Figure 8 This is a schematic diagram of the structural composition of a data processing device provided in an embodiment of this application, applied to a first terminal, including:
[0167] The first processing unit 801 is configured to collect gait data of N1 gait detections in the first gait detection sub-cycle of the target object according to a first time interval, calculate the gait parameters corresponding to the N1 gait detections in the first gait detection sub-cycle based on the gait data of the N1 gait detections in the first gait detection sub-cycle, and determine whether the changing trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to a first trend; wherein, N1 is an integer greater than or equal to 2; the first time interval is the time interval between each two adjacent gait detections in the N1 gait detections of the first gait detection sub-cycle;
[0168] The second processing unit 802 is used to adjust the first time interval when it is determined that the changing trend of the gait parameters of the first gait detection sub-cycle does not conform to the first trend, and to perform the step of collecting gait data of N1 gait detections in the next second gait detection sub-cycle after the first gait detection sub-cycle according to the adjusted time interval, until the changing trend of the corresponding gait parameters of the Nth gait detection sub-cycle calculated according to the finally adjusted second time interval conforms to the first trend.
[0169] The determining unit 803 is used to determine the second time interval as the time interval between two adjacent gait detections of the N1th gait detection of each gait detection sub-cycle of the target object.
[0170] In some implementations, the number of gait parameter categories corresponding to the N1 gait detections in the first gait detection sub-cycle is N2, and the first processing unit is configured to:
[0171] The difference ratio and / or change ratio of each type of gait parameter in the N2 type of gait parameters in the first gait detection sub-cycle are calculated based on the values of the N1 gait detections in the first gait detection sub-cycle.
[0172] The difference ratio of various gait parameters in the first gait detection sub-cycle is compared with the difference ratio threshold corresponding to each gait parameter to obtain a first comparison result; and / or, the change ratio of various gait parameters in the first gait detection sub-cycle is compared with the change ratio threshold corresponding to each gait parameter to obtain a second comparison result.
[0173] Based on the first comparison result and / or the second comparison result, determine whether the changing trend of each gait parameter corresponding to the first gait detection sub-cycle conforms to the first trend.
[0174] In some embodiments, the second processing unit is configured to:
[0175] If the first comparison result is that the difference ratio of various gait parameters in the first gait detection sub-cycle is greater than the difference ratio threshold corresponding to various gait parameters, the first time interval is adjusted to the duration of the first time interval plus a set time step.
[0176] If the first comparison result is that the difference ratio of various gait parameters in the first gait detection sub-cycle is less than or equal to the difference ratio threshold corresponding to each gait parameter, and the second comparison result is that the change ratio of various gait parameters in the first gait detection sub-cycle is less than or equal to the change ratio threshold corresponding to each gait parameter, then the first time interval is adjusted to the first time interval duration minus the set time step.
[0177] In some embodiments, the apparatus further includes:
[0178] The acquisition unit is used to acquire gait data of the target object for a specified period according to the second time interval; wherein, the specified period includes N3 gait detection sub-periods, and each of the N3 gait detection sub-periods includes N1 gait detections;
[0179] The calculation unit is used to calculate N4 gait parameters corresponding to each gait detection based on the gait data corresponding to each gait detection in the specified period;
[0180] The detection unit is used to perform lateral and / or longitudinal detection on each of the N4 gait parameters corresponding to each gait detection in the specified period, and to determine whether there are any abnormalities in the gait data corresponding to each gait detection based on the detection results.
[0181] Specifically, for each gait parameter, the lateral detection detects the changing trend of the gait parameter in the corresponding gait detection sub-cycle; the longitudinal detection detects the deviation of the gait parameter from the average value of the gait parameter in the corresponding gait detection sub-cycle.
[0182] In some embodiments, the acquisition unit is configured to: for each gait detection within the specified period, after acquiring the gait data for that gait detection, use a motion detection algorithm to determine whether the target object's movement behavior in that gait detection is walking; if it is determined that the target object's movement behavior in that gait detection is walking, save the acquired gait data for that gait detection; otherwise, remind the target object to perform gait detection again until it is detected that the target object's movement behavior in that gait detection is walking.
[0183] In some implementations, each gait detection within the specified period collects N5 sets of gait data, each set of gait data including data from multiple dimensions. The acquisition unit is used to perform dimensionality reduction and feature extraction on the previous N6 gait data collected for that gait detection to obtain differential features in the previous N6 gait data; input the differential features into a motion behavior classification model to obtain the relative position of the differential features with respect to the hyperplane; and determine whether the motion behavior of that gait detection is walking based on the relative position; wherein, the hyperplane is a hyperplane obtained when training the motion behavior classification model to determine whether the running behavior is walking.
[0184] In some embodiments, the detection unit is configured to, for each gait detection sub-cycle in the specified period, calculate the value of the second-order forward difference of each of the N4 gait parameters corresponding to the gait detection sub-cycle in the gait detection sub-cycle; if the value of the second-order forward difference of each gait parameter in the gait detection sub-cycle satisfies a predetermined condition, determine that the gait parameters corresponding to the gait detection sub-cycle conform to a second trend; otherwise, determine that the gait data corresponding to the gait detection sub-cycle is abnormal.
[0185] In some embodiments, the detection unit is used for:
[0186] For each of the N4 gait parameters, calculate the average value of the gait parameter in each gait detection sub-cycle of all gait detection sub-cycles included in the specified period, and determine the maximum and minimum average values of the gait parameter in all gait detection sub-cycles included in the specified period. Calculate the longitudinal detection threshold of the gait parameter based on the maximum and minimum average values.
[0187] For the i-th gait detection in N1 gait detections of each gait detection sub-cycle, calculate the deviation between the gait parameters corresponding to the i-th gait detection and the corresponding average value of the gait parameters; where i ranges from 1 to N1.
[0188] The deviation value is compared with the longitudinal detection threshold. If the deviation value is greater than the longitudinal detection threshold, it is determined that the original gait data corresponding to the gait parameter is abnormal; otherwise, it is determined that the original gait data corresponding to the gait parameter is not abnormal.
[0189] In some embodiments, the apparatus further includes:
[0190] The sending unit is used to send abnormal gait data to the second terminal for analysis based on the abnormal gait data; and to send the gait parameters corresponding to the gait data that is determined to be non-abnormal to the second terminal.
[0191] In some implementations, each gait detection sub-cycle in the specified period corresponds to a gait detection cycle after the target object takes medication, and the acquisition unit is used to collect gait data of the target object for each medication cycle in the specified number of days.
[0192] Those skilled in the art should understand that Figure 8 The functions of each unit in the data processing device shown can be understood by referring to the relevant description of the aforementioned data processing method. Figure 8 The functions of each unit in the data processing device shown can be implemented by a program running on a processor or by specific logic circuits.
[0193] This application also provides a terminal device. Figure 9 This is a schematic diagram of the hardware structure of the terminal device according to an embodiment of this application, such as... Figure 9As shown, the terminal device includes: a communication component 903 for data transmission, at least one processor 901, and a memory 902 for storing computer programs that can run on the processor 901. The various components in the terminal are coupled together via a bus system 904. It is understood that the bus system 904 is used to implement communication between these components. In addition to a data bus, the bus system 904 also includes a power bus, a control bus, and a status signal bus. However, for clarity, in… Figure 9 The general designated all buses as Bus System 904.
[0194] Wherein, when the processor 901 executes the computer program, it performs at least the following: Figure 1 , Figure 4 or Figure 6 The steps of the method shown.
[0195] It is understood that memory 902 can be volatile memory or non-volatile memory, or both. Non-volatile memory can be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), ferromagnetic random access memory (FRAM), flash memory, magnetic surface memory, optical disc, or compact disc read-only memory (CD-ROM); magnetic surface memory can be disk storage or magnetic tape storage. Volatile memory can be random access memory (RAM), which is used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as Static Random Access Memory (SRAM), Synchronous Static Random Access Memory (SSRAM), Dynamic Random Access Memory (DRAM), Synchronous Dynamic Random Access Memory (SDRAM), Double Data Rate Synchronous Dynamic Random Access Memory (DDRSDRAM), Enhanced Synchronous Dynamic Random Access Memory (ESDRAM), SyncLink Dynamic Random Access Memory (SLDRAM), and Direct Rambus Random Access Memory (DRRAM).The memory 902 described in the embodiments of this application is intended to include, but is not limited to, these and any other suitable types of memory.
[0196] The methods disclosed in the embodiments of this application can be applied to or implemented by the processor 901. The processor 901 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the integrated logic circuit of the hardware in the processor 901 or by instructions in the form of software. The processor 901 may be a general-purpose processor, a DSP, or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The processor 901 can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor may be a microprocessor or any conventional processor, etc. The steps of the methods disclosed in the embodiments of this application can be directly manifested as being executed by a hardware decoding processor, or being executed by a combination of hardware and software modules in the decoding processor. The software modules may be located in a storage medium, which is located in the memory 902. The processor 901 reads the information in the memory 902 and combines it with its hardware to complete the steps of the aforementioned method.
[0197] In an exemplary embodiment, the terminal device may be implemented by one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), FPGAs, general-purpose processors, controllers, MCUs, microprocessors, or other electronic components to perform the aforementioned data processing method.
[0198] This application also provides a computer-readable storage medium storing a computer program thereon, characterized in that the program, when executed by a processor, is at least used to perform... Figure 1 , Figure 4 or Figure 6 The steps of the method are shown. The computer-readable storage medium may specifically be a memory. The memory may be, for example... Figure 9 The memory 902 shown.
[0199] This application also provides a computer program product, including a computer program, which can be generated by... Figure 9 The processor 901 in the terminal device executes to complete each step of the data processing method described in the first terminal-side embodiment.
[0200] The technical solutions described in the embodiments of this application can be combined arbitrarily without conflict.
[0201] In the several embodiments provided in this application, it should be understood that the disclosed methods and smart devices can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods, such as: multiple units or components can be combined, or integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the various components shown or discussed can be through some interfaces, and the indirect coupling or communication connection between devices or units can be electrical, mechanical, or other forms.
[0202] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the units may be selected to achieve the purpose of this embodiment according to actual needs.
[0203] In addition, each functional unit in the various embodiments of this application can be integrated into a second processing unit, or each unit can be a separate unit, or two or more units can be integrated into a unit; the integrated unit can be implemented in hardware or in the form of hardware plus software functional units.
[0204] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A data processing method, characterized in that, Applied to a first terminal, the method includes: Gait data of N1 gait detections in the first gait detection sub-cycle of the target object are collected according to a first time interval. Gait parameters corresponding to the N1 gait detections in the first gait detection sub-cycle are calculated based on the gait data of the N1 gait detections in the first gait detection sub-cycle. It is then determined whether the changing trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to a first trend. Wherein, N1 is an integer greater than or equal to 2. The first time interval is the time interval between each two adjacent gait detections in the N1 gait detections of the first gait detection sub-cycle. If the trend of the change of gait parameters in the first gait detection sub-cycle does not conform to the first trend, the first time interval is adjusted, and the step of collecting gait data of N1 gait detections in the next second gait detection sub-cycle after the first gait detection sub-cycle is performed according to the adjusted time interval, until the trend of the change of gait parameters corresponding to the Nth gait detection sub-cycle obtained by collecting gait data according to the finally adjusted second time interval conforms to the first trend. The second time interval is defined as the time interval between two adjacent gait detections in the N1 gait detection sub-cycles of the target object; The number of gait parameter categories corresponding to the N1 gait detections in the first gait detection sub-cycle is N2. Determining whether the changing trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to a first trend includes: calculating the difference ratio and / or change ratio of each type of gait parameter in the N2 types of gait parameters in the first gait detection sub-cycle based on the values of the N1 gait detections in the first gait detection sub-cycle; comparing the difference ratio of each type of gait parameter in the first gait detection sub-cycle with the difference ratio threshold corresponding to each type of gait parameter to obtain a first comparison result; and / or comparing the change ratio of each type of gait parameter in the first gait detection sub-cycle with the change ratio threshold corresponding to each type of gait parameter to obtain a second comparison result; and determining whether the changing trend of each gait parameter corresponding to the first gait detection sub-cycle conforms to the first trend based on the first comparison result and / or the second comparison result. The method further includes: Gait data of the target object for a specified period are collected according to the second time interval; wherein, the specified period includes N3 gait detection sub-periods, and each of the N3 gait detection sub-periods includes N1 gait detections; N4 gait parameters corresponding to each gait detection are calculated based on the gait data corresponding to each gait detection in the specified period; lateral and / or longitudinal detections are performed on each of the N4 gait parameters corresponding to each gait detection in the specified period, and the gait data corresponding to each gait detection is judged to be abnormal based on the detection results; wherein, for each gait parameter, the lateral detection is the detection of the changing trend of the gait parameter in its corresponding gait detection sub-period; the longitudinal detection is the detection of the deviation of the gait parameter relative to the average value of the gait parameters in the gait detection sub-periods, and the average value of the gait parameters in the gait detection sub-periods is the average value of the gait parameter in each gait detection sub-period in all gait detection sub-periods included in the specified period.
2. The method according to claim 1, characterized in that, The step of adjusting the first time interval when the trend of the gait parameters in the first gait detection sub-cycle does not conform to the first trend includes: If the first comparison result is that the difference ratio of various gait parameters in the first gait detection sub-cycle is greater than the difference ratio threshold corresponding to various gait parameters, the first time interval is adjusted to the duration of the first time interval plus a set time step. If the first comparison result is that the difference ratio of various gait parameters in the first gait detection sub-cycle is less than or equal to the difference ratio threshold corresponding to each gait parameter, and the second comparison result is that the change ratio of various gait parameters in the first gait detection sub-cycle is less than or equal to the change ratio threshold corresponding to each gait parameter, then the first time interval is adjusted to the first time interval duration minus the set time step.
3. The method according to claim 1, characterized in that, The collection of gait data of the target object at a specified period includes: For each gait detection within the specified period, after collecting the gait data for that gait detection, a motion detection algorithm is used to determine whether the target object's movement behavior in that gait detection is walking; If the target object's movement behavior in this gait detection is determined to be walking, the gait data collected in this gait detection is saved; otherwise, the target object is prompted to perform gait detection again until the target object's movement behavior in this gait detection is detected to be walking.
4. The method according to claim 3, characterized in that, Each gait detection within the specified period collects N5 sets of gait data, each set including data from multiple dimensions; the step of using a motion detection algorithm to determine whether the target object's movement behavior in that gait detection is walking includes: The N6 gait data collected for this gait detection are subjected to dimensionality reduction and feature extraction to obtain the differential features in the N6 gait data. The differential features are input into the motion behavior classification model to obtain the relative position of the differential features with respect to the hyperplane; the relative position is used to determine whether the motion behavior detected in this gait is walking; wherein, the hyperplane is the hyperplane obtained when training the motion behavior classification model to determine whether the running behavior is walking.
5. The method according to claim 1, characterized in that, The step of performing lateral detection on each of the N4 gait parameters corresponding to each gait detection in the specified period, and determining whether there are any anomalies in the gait data corresponding to each gait detection based on the detection results, includes: For each gait detection sub-cycle in the specified period, the value of the second-order forward difference of each gait parameter in the N4 gait parameters corresponding to the gait detection sub-cycle is calculated. If the value of the second-order forward difference of each gait parameter in the gait detection sub-cycle meets a predetermined condition, it is determined that the gait parameter corresponding to the gait detection sub-cycle conforms to the second trend; otherwise, it is determined that the gait data corresponding to the gait detection sub-cycle is abnormal.
6. The method according to claim 3, characterized in that, The step of performing longitudinal detection on each of the N4 gait parameters corresponding to each gait detection in the specified period, and determining whether there are any anomalies in the gait data corresponding to each gait detection based on the detection results, includes: For each of the N4 gait parameters, calculate the average value of the gait parameter in each gait detection sub-cycle of all gait detection sub-cycles included in the specified period, and determine the maximum and minimum average values of the gait parameter in all gait detection sub-cycles included in the specified period. Calculate the longitudinal detection threshold of the gait parameter based on the maximum and minimum average values. For the i-th gait detection in N1 gait detections of each gait detection sub-cycle, calculate the deviation between the gait parameters corresponding to the i-th gait detection and the corresponding average value of the gait parameters; where i ranges from 1 to N1. The deviation value is compared with the longitudinal detection threshold. If the deviation value is greater than the longitudinal detection threshold, it is determined that the original gait data corresponding to the gait parameter is abnormal; otherwise, it is determined that the original gait data corresponding to the gait parameter is not abnormal.
7. The method according to any one of claims 1 to 6, characterized in that, The method further includes: For gait data that is identified as abnormal, the abnormal gait data is sent to the second terminal so that the second terminal can analyze the abnormal gait data. For gait data that is determined to be free of abnormalities, the gait parameters corresponding to the gait data free of abnormalities are sent to the second terminal.
8. The method according to any one of claims 1 to 6, characterized in that, Each gait detection sub-cycle in the specified period corresponds to one gait detection cycle after the target object takes medication; The collection of gait data of the target object at a specified period includes: Collect gait data of the target subject for each medication cycle over a specified number of days.
9. A data processing apparatus, characterized in that, Applied to a first terminal, the device includes: The first processing unit is configured to collect gait data of N1 gait detections in the first gait detection sub-cycle of the target object according to a first time interval, calculate the gait parameters corresponding to the N1 gait detections in the first gait detection sub-cycle based on the gait data of the N1 gait detections in the first gait detection sub-cycle, and determine whether the changing trend of the gait parameters corresponding to the first gait detection sub-cycle conforms to a first trend; wherein, N1 is an integer greater than or equal to 2; the first time interval is the time interval between each two adjacent gait detections in the N1 gait detections of the first gait detection sub-cycle; The second processing unit is used to adjust the first time interval when it is determined that the changing trend of the gait parameters of the first gait detection sub-cycle does not conform to the first trend, and to perform the step of collecting gait data of N1 gait detections in the next second gait detection sub-cycle after the first gait detection sub-cycle according to the adjusted time interval, until the changing trend of the corresponding gait parameters of the Nth gait detection sub-cycle calculated according to the finally adjusted second time interval conforms to the first trend. The determining unit is configured to determine the second time interval as the time interval between two adjacent gait detections in the N1 gait detections of each gait detection sub-cycle of the target object; The number of gait parameter categories corresponding to the N1 gait detections in the first gait detection sub-cycle is N2. The first processing unit is configured to calculate the difference ratio and / or change ratio of each type of gait parameter in the N2 types of gait parameters in the first gait detection sub-cycle based on the values of the N2 types of gait parameters corresponding to the N1 gait detections in the first gait detection sub-cycle; compare the difference ratio of each type of gait parameter in the first gait detection sub-cycle with the difference ratio threshold corresponding to each type of gait parameter to obtain a first comparison result; and / or compare the change ratio of each type of gait parameter in the first gait detection sub-cycle with the change ratio threshold corresponding to each type of gait parameter to obtain a second comparison result; and determine whether the change trend of each gait parameter in the first gait detection sub-cycle conforms to a first trend based on the first comparison result and / or the second comparison result. The acquisition unit is used to acquire gait data of the target object for a specified period according to the second time interval; wherein, the specified period includes N3 gait detection sub-periods, and each of the N3 gait detection sub-periods includes N1 gait detections; The calculation unit is used to calculate N4 gait parameters corresponding to each gait detection based on the gait data corresponding to each gait detection in the specified period; The detection unit is used to perform lateral and / or longitudinal detection on each of the N4 gait parameters corresponding to each gait detection in the specified period, and to determine whether there are any abnormalities in the gait data corresponding to each gait detection based on the detection results. Specifically, for each gait parameter, the lateral detection detects the trend of change of the gait parameter in its corresponding gait detection sub-cycle; the longitudinal detection detects the deviation of the gait parameter from the average value of the gait parameters in the gait detection sub-cycle, wherein the average value of the gait parameter in the gait detection sub-cycle is the average value of the gait parameter in each gait detection sub-cycle in all gait detection sub-cycles included in the specified cycle.
10. A terminal device, characterized in that, The terminal device includes a memory and a processor, wherein the memory stores computer-executable instructions, and the processor, when executing the computer-executable instructions in the memory, can implement the method of any one of claims 1 to 8.
11. A computer storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1 to 8.
12. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1 to 8.
Citation Information
Patent Citations
Data dynamic collection method, device and system oriented to active security
CN107864071A
Gait information processing method
CN117747115A