Method for recognizing movement state of treatment head, therapeutic instrument and storage medium
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-28
- Publication Date
- 2026-08-11
AI Technical Summary
当前大多是基于固定的压力阈值来判断是否运动,而不同用户的控制力度不同,而带来运动状态识别结果的巨大差异
[0040]本申请实施例提供的治疗头运动状态的识别方法,包括:
Smart Images

Figure CN121338262B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of medical aesthetics technology, and in particular to a method for recognizing the movement state of a treatment head, a treatment device, and a storage medium. Background Technology
[0002] With the improvement of living standards, more and more people are paying more attention to medical aesthetics. Medical aesthetics refers to the beauty methods that use beauty instruments to repair and reshape a person's appearance and the shape of various parts of the body.
[0003] In medical aesthetics, professionals use cosmetic instruments to perform procedures on the human body. Typically, these procedures are performed by professionally trained doctors or staff in qualified workplaces.
[0004] However, with the miniaturization of beauty devices, some can now be used anytime, anywhere, such as at home or in the car. In these scenarios, the user typically holds the device, placing the treatment head against their face and rotating it in circles. This allows the treatment head to emit energy such as ultrasound or laser to act on the face, achieving effects like skin tightening, whitening, and wrinkle reduction. During this process, the treatment head emits energy according to the number of rotations, avoiding either overly concentrated energy that could damage the face or insufficient energy to achieve the desired effect.
[0005] During treatment, the user presses the treatment head firmly against their face and slides it in circles; when not receiving treatment, the user stops moving the treatment head and gently presses it against their face in preparation for treatment. Based on this, the pressure on the treatment head can be used to determine whether it is moving. Currently, most methods determine movement based on a fixed pressure threshold, but different users have different levels of control, leading to significant differences in the results of movement recognition. Summary of the Invention
[0006] This invention provides a method for identifying the motion state of a treatment head, a treatment device, and a storage medium to improve the accuracy of identifying the motion state of the treatment head.
[0007] The first aspect of this application provides a method for recognizing the motion state of a treatment head, wherein the treatment head is connected to at least one sensor, and the method includes:
[0008] Real-time baseline signal and real-time peak signal are extracted from the waveform data output by the at least one sensor, wherein the real-time baseline signal is used to characterize the background signal when the treatment head is in a stationary state;
[0009] Based on the time corresponding to the waveform data and the real-time peak signal, the current movement speed of the treatment head is determined;
[0010] Combining the real-time baseline signal with the current movement speed of the treatment head, a preset classification algorithm is used to classify the movement state of the treatment head. The movement state includes stationary, fast movement, and slow movement. Fast movement is used to characterize movement within a first preset speed range, and slow movement is used to characterize movement within a second preset speed range. The minimum speed value of the first preset speed range is greater than the maximum speed value of the second preset speed range.
[0011] As an optional embodiment, before extracting the real-time baseline signal and real-time peak signal from the waveform data output by the at least one sensor, the method further includes:
[0012] The waveform data is preprocessed to obtain preprocessed waveform data, wherein the preprocessing process includes:
[0013] The waveform data is cached according to a preset time window size to obtain multiple cached window data, wherein the waveform data includes time and amplitude;
[0014] For the multiple window data, obtain the window data distribution of the previous time step in the multiple window data, the window data distribution includes high-frequency data distribution and low-frequency data distribution;
[0015] Based on the window data distribution at the previous moment, the first weight of the high-frequency filter and the second weight of the low-frequency filter in the filter are adjusted in real time to obtain the real-time adjusted filter. The high-frequency filter is used to filter the high-frequency components in the window data, and the low-frequency filter is used to filter the low-frequency components in the window data.
[0016] The window data at the next time step is filtered using the real-time adjusted filter to obtain preprocessed window data.
[0017] As an optional embodiment, extracting the real-time baseline signal from the waveform data output by the at least one sensor includes:
[0018] The real-time baseline signal is extracted from the preprocessed waveform data;
[0019] Before extracting the real-time baseline signal from the preprocessed waveform data, the method further includes:
[0020] For each preprocessed window of data, the feature value of the window data is calculated. The feature value includes at least one of the first-order difference mean, signal slope, main frequency, variance, and target time difference between peak and peak values of the window data.
[0021] Based on the feature value, the false peaks in the preprocessed window data are eliminated to obtain the window data after the false peaks are eliminated.
[0022] As an optional embodiment, extracting the real-time baseline signal from the preprocessed waveform data includes:
[0023] Based on the window data after eliminating false peaks, the real-time baseline signal and real-time peak signal are extracted.
[0024] As an optional embodiment, extracting the real-time baseline signal based on the window data after eliminating false peaks includes:
[0025] Perform amplitude fluctuation detection, slope detection, or mean stability detection on the window data after eliminating false peaks;
[0026] The real-time baseline signal is extracted based on the results of the amplitude fluctuation detection, the slope detection, or the mean stability detection.
[0027] As an optional embodiment, extracting the real-time peak signal based on the window data after eliminating false peaks includes:
[0028] The window data after eliminating false peaks is subjected to maximum search or dynamic threshold filtering using a sliding window.
[0029] Based on the search results for maximum values or the filtering results for dynamic thresholds, the real-time peak signals in the window data after eliminating false peaks are determined.
[0030] As an optional embodiment, the step of classifying the motion state of the treatment head by combining the real-time baseline signal with the current motion velocity of the treatment head and using a preset classification algorithm includes:
[0031] By combining the feature values of the window data, the real-time baseline signal, the current movement speed of the treatment head, and the movement state of the treatment head at the previous moment, a classification algorithm is used to classify the movement state of the treatment head at the next moment.
[0032] As an optional embodiment, determining the current movement speed of the treatment head based on the time corresponding to the waveform data and the real-time peak signal includes:
[0033] Based on the time corresponding to the waveform data and the number of real-time peak signals, the number of peaks per unit time is calculated, wherein the distance between two adjacent peaks is considered as the treatment head moving in one revolution.
[0034] The angular velocity of the current movement of the treatment head is calculated based on the unit time and the number of wave peaks within the unit time.
[0035] A second aspect of this application provides a treatment device, comprising at least:
[0036] The treatment head, at least one sensor communicatively connected to the treatment head, a controller communicatively connected to the treatment head, and a memory storing a preset program, wherein the controller, when executing the preset program, is used to execute the treatment head motion state recognition method provided in the first aspect of the present application.
[0037] A third aspect of this application provides a computer-readable storage medium having a computer program stored thereon. When executed by a processor, the computer program is used to perform the method for recognizing the motion state of a treatment head provided in the first aspect of this application.
[0038] The fourth aspect of this application provides a computer program product having a computer program stored thereon. When the computer program is executed by a processor, it is used to perform the method for recognizing the motion state of a treatment head provided in the first aspect of this application.
[0039] As can be seen from the above technical solutions, the embodiments of the present invention have the following advantages:
[0040] The method for recognizing the motion state of the treatment head provided in this application includes:
[0041] Real-time baseline signal and real-time peak signal are extracted from waveform data output by at least one sensor. The real-time baseline signal is used to characterize the background signal when the treatment head is stationary. Based on the time corresponding to the waveform data and the real-time peak signal, the current motion speed of the treatment head is determined. Combining the real-time baseline signal and the current motion speed of the treatment head, a preset classification algorithm is used to classify the motion state of the treatment head. The motion state includes stationary, fast motion, and slow motion. Fast motion is used to characterize motion within a first preset speed range, and slow motion is used to characterize motion within a second preset speed range. The minimum speed value of the first preset speed range is greater than the maximum speed value of the second preset speed range.
[0042] The method for identifying the motion state of the treatment head provided in this embodiment determines the motion speed of the treatment head based on the extracted real-time peak signal. On the one hand, compared with the existing method based on a fixed threshold to determine the motion state, it improves the accuracy of motion state classification. On the other hand, since the baseline signal behaves differently under different motion states, determining the motion state of the treatment head based on the real-time baseline signal and the current motion speed of the treatment head is equivalent to having an additional auxiliary judgment information, thereby further improving the accuracy of motion state classification. Attached Figure Description
[0043] Figure 1 This is one embodiment of the method for recognizing the motion state of the treatment head in the embodiments of this application;
[0044] Figure 2 This is a schematic diagram of an embodiment of preprocessing waveform data in this application.
[0045] Figure 3 This is a schematic diagram of an embodiment of eliminating false peaks in preprocessed window data in this application.
[0046] Figure 4 This is a schematic diagram of an embodiment of extracting real-time baseline signals from window data after eliminating false peaks in this application.
[0047] Figure 5 This is a schematic diagram of an embodiment of extracting real-time peak signals from window data after eliminating false peaks in this application.
[0048] Figure 6 This is a schematic diagram of one embodiment of the therapeutic device in this application;
[0049] Figure 7 This is a schematic diagram of the real-time peak signal and the implemented baseline signal in the embodiments of this application;
[0050] Figure 8 This is a schematic diagram of the real-time peak signal and real-time baseline signal after filtering in an embodiment of this application. Detailed Implementation
[0051] This invention provides a method for identifying the motion state of a treatment head, a treatment device, and a storage medium, which improves the accuracy of classifying the motion state of the treatment head.
[0052] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0053] The terms "first," "second," "third," "fourth," etc., used in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0054] The therapeutic device in this embodiment includes at least a controller, a drive module, and a treatment head. A transducer is installed inside the treatment head, and at least one sensor is installed at a preset position where the treatment head contacts the target object. The controller controls the drive module to emit an ultrasonic drive signal to the transducer inside the treatment head, thereby driving the transducer to emit an ultrasonic signal. When the ultrasonic signal reaches the target object, ultrasonic energy is emitted to the target object to tighten or remove wrinkles. The at least one sensor in this embodiment is used to sense the user's operating pressure during the process of the user performing a circular motion on the target object (such as performing a circular motion on the face, neck, or other areas to be treated, i.e., performing a circular motion), and to judge the movement state of the treatment head based on the sensed pressure.
[0055] For ease of understanding, the method for recognizing the movement state of the treatment head in the embodiments of this application is described below. Please refer to [link / reference]. Figure 1 One embodiment of the method for recognizing the movement state of the treatment head in this application includes:
[0056] 101. Extract the real-time baseline signal and the real-time peak signal from the waveform data output by at least one sensor, wherein the real-time baseline signal is used to characterize the background signal when the treatment head is in different motion states;
[0057] In the process of treating a target object using a treatment head, existing technologies typically incorporate pressure sensors on the treatment head to identify its current movement. The pressure value detected by the sensor is compared to a preset pressure threshold to determine the treatment head's movement state. During treatment, the treatment head moves against the face, neck, or other areas to be treated; when not being treated, the treatment head is either not in contact with the area or only lightly touching it. Therefore, when the pressure value detected by the pressure sensor exceeds the preset pressure threshold, the treatment head is considered to be in motion; conversely, when the pressure value detected by the pressure sensor is less than the preset threshold, the treatment head is considered to be stationary.
[0058] However, existing methods for determining the motion state of the treatment head by detecting pressure thresholds often suffer from significant errors in judging the motion state of the treatment head due to individual differences during operation. For example, some people apply greater pressure to the treatment head during operation, while others apply less pressure, but both treatment heads remain stationary.
[0059] To address this issue, embodiments of this application can connect at least one sensor to the treatment head, and during the movement of the treatment head, the motion state of the sensor can be determined by the waveform data collected in real time by the sensor.
[0060] Specifically, the sensors in this application embodiment can be different types of pressure sensors, such as piezoresistive pressure sensors, capacitive pressure sensors, strain gauge pressure sensors, piezoelectric pressure sensors, resonant pressure sensors, optical pressure sensors, or inductive pressure sensors. Among them, piezoresistive pressure sensors are based on the semiconductor piezoresistive effect, where the resistivity changes after being subjected to force, and have the characteristics of high accuracy, small size, and low power consumption. Capacitive pressure sensors utilize the characteristic that the distance between the capacitor plates changes with pressure, and have the characteristics of high sensitivity, small temperature drift, and fast response, making them suitable for high-precision and micro-pressure measurement scenarios. Strain gauge pressure sensors measure pressure based on the resistance change of the strain gauge after deformation under force, and have the characteristics of simple structure, low cost, and strong stability, making them suitable for medium and low pressure and conventional industrial scenarios. Piezoelectric pressure sensors rely on the charge generated by piezoelectric materials (such as quartz and piezoelectric ceramics) under force to measure pressure, and have the characteristics of high dynamic response speed. In practical applications, the type of pressure sensor can be freely selected according to the actual needs of the scenario, and no specific restrictions are placed on the type of pressure sensor here.
[0061] During the judgment process, it is necessary to extract the real-time baseline signal and the real-time peak signal from the waveform data collected in real time by at least one sensor. In this embodiment, the real-time baseline signal is used to characterize the background signal when the treatment head is in different motion states. It is mainly used to provide a reference benchmark to eliminate the inherent noise of the treatment head itself, signal drift and external environmental interference.
[0062] Furthermore, the real-time peak signal collected in this embodiment is used to calculate the movement speed of the treatment head. The process of calculating the movement speed of the treatment head based on the real-time peak signal will be described in the following steps and will not be repeated here.
[0063] 102. Determine the current movement speed of the treatment head based on the time corresponding to the waveform data and the real-time peak signal;
[0064] After obtaining the waveform data and real-time peak signal, the movement speed of the treatment head can be calculated based on the time data and real-time peak signal in the waveform signal.
[0065] In waveform data, the horizontal axis is generally time and the vertical axis represents amplitude. Therefore, after obtaining the waveform data, the current speed of the treatment head during the circular motion can be determined based on the time on the horizontal axis and the number of real-time peak signals in the waveform data.
[0066] During the circular motion of the treatment head, a sensor is usually installed at the end of the treatment head. Therefore, the treatment head can sense the pressure of the operator through the sensor. The greater the pressure of the operator on the treatment head, the greater the pressure sensed by the sensor. During the circular motion of the treatment head, according to the user's operating habits, the force is generally greater at the beginning and end of the circle. Therefore, the distance between two adjacent peaks can be regarded as one circle of the treatment head. Thus, the angular velocity of the treatment head can be calculated based on the time difference between two peaks and the number of circles. For example, if the time difference between adjacent peaks is t, and the treatment head has moved one circle, that is, moved 360°, then the angular velocity of the treatment head can be calculated based on 2π and t.
[0067] To make it easier to understand, the following will be combined with Figure 7 Please provide an explanation, such as Figure 7 As shown, since there are two peaks between t1 and t2, the angular velocity of the treatment head between t1 and t2 can be calculated as W1 = 2π / (t2 - t1), and the angular velocity between t2 and t3 can be calculated as W2 = 2π / (t3 - t2), and so on. The angular velocities of the treatment head in different time intervals can be calculated sequentially. Here, π refers to the mathematical constant pi.
[0068] It should be noted that the angular velocity of the treatment head calculated in the embodiments of this application is generally only suitable for scenarios where the treatment head is making circular motion, and not suitable for scenarios where the treatment head is making linear motion or non-closed circular motion.
[0069] 103. Combining the real-time baseline signal with the current motion speed of the treatment head, a preset classification algorithm is used to classify the motion state of the treatment head. The motion state includes stationary, fast motion, and slow motion. Fast motion is used to represent motion within a first preset speed range, and slow motion is used to represent motion within a second preset speed range. The minimum speed value of the first preset speed range is greater than the maximum speed value of the second preset speed range.
[0070] After obtaining the real-time baseline signal and the current movement speed of the treatment head, a preset classification algorithm can be used to classify the movement state of the treatment head. The movement state includes stationary, fast movement, and slow movement. It should be noted that fast movement and slow movement in this embodiment are relative. Fast movement is used to characterize movement within a first preset speed range, and slow movement is used to characterize movement within a second preset speed range. The minimum speed value within the first preset speed range must be greater than the maximum speed value within the second preset speed range.
[0071] Specifically, the classification algorithms in the embodiments of this application include, but are not limited to, random forest classification algorithm, gradient boosting tree classification algorithm, decision tree classification algorithm, support vector machine and other classification algorithms. No specific limitation is made on the specific classification algorithm here.
[0072] In this embodiment, the real-time peak signal of the treatment head during movement is extracted from the waveform data collected by at least one sensor. Based on the time in the waveform data and the real-time peak signal, the current movement speed of the treatment head is calculated. Furthermore, the movement state of the treatment head is classified by combining the real-time baseline signal in the waveform data and the current movement speed of the treatment head. Because this embodiment classifies the movement state of the treatment head based on its current movement speed, it improves the accuracy of movement state identification compared to the prior art. Furthermore, since the baseline signal behaves differently in different movement states, determining the movement state of the treatment head based on the real-time baseline signal and the current movement speed of the treatment head provides an additional auxiliary judgment information, thereby further improving the accuracy of movement state classification.
[0073] based on Figure 1In this embodiment, before step 101, preprocessing can be performed on the waveform data to filter out high-frequency noise and low-frequency interference. This is because during the waveform data acquisition process, instantaneous pulses or rapid fluctuations may occur, as well as slowly changing low-frequency interference such as baseline drift. To acquire the real-time baseline signal and real-time peak signal in the waveform data, pre-filtering processing of the waveform data is necessary. For details, please refer to [link to relevant documentation]. Figure 2 One embodiment of preprocessing waveform data in this application includes:
[0074] 201. Cache the waveform data according to the preset time window size to obtain multiple window data after caching. The waveform data includes time and amplitude.
[0075] Specifically, in order to avoid the problem of excessive data volume and low processing efficiency caused by receiving too much waveform data at once, the embodiments of this application can also cache the received waveform data according to a preset time window size to obtain multiple window data after caching.
[0076] When receiving 1 minute of waveform data, the waveform data can be cached into multiple window data according to a preset time window, such as 5 seconds, 10 seconds or 20 seconds. For example, when caching according to a 20-second window size, the waveform data can be cached into 3 window data.
[0077] 202. For multiple window data, obtain the window data distribution of the previous time step in the multiple window data, including high-frequency data distribution and low-frequency data distribution;
[0078] In order to perform effective filtering for each window of data, this application embodiment can also obtain the window data distribution of the previous moment in multiple window data. For example, when the waveform data of 1 minute includes 3 window data, it corresponds to obtaining the data distribution of the first window. The window data distribution in this application mainly includes high-frequency data and low-frequency data, so as to execute step 203 according to the data distribution.
[0079] 203. Based on the window data distribution at the previous moment, the first weight of the high-frequency filter and the second weight of the low-frequency filter in the filter are adjusted in real time to obtain the real-time adjusted filter. The high-frequency filter is used to filter the high-frequency components in the window data, and the low-frequency filter is used to filter the low-frequency components in the window data.
[0080] After obtaining the window data distribution of multiple windows at the previous time step, the weights of different filters in the filter can be adjusted according to the window data distribution of the previous time step. Then, the window data at the next time step is filtered according to the adjusted filter weights. For example, after adjusting the weights of the high-frequency and low-frequency filters in the filter based on the data distribution of the first window, the window data in the second window can be filtered according to the adjusted filter weights. Similarly, the weights of different filters in the filter can be adjusted according to the data distribution of the second window, and the window data in the third window can be filtered according to the adjusted filter weights. Of course, for the window data in the first window, the window data in the first window can be filtered according to the filter weights set in the initialization.
[0081] Specifically, the filters in this application embodiment mainly include high-frequency filters and low-frequency filters. Therefore, when adjusting the weight distribution of high-frequency filters and low-frequency filters in the filter, the high-frequency data distribution and low-frequency data distribution in the window data distribution at the previous moment are mainly referenced. When there is a lot of high-frequency noise in the window data, the weight of the high-frequency filter is increased, and when there is a lot of low-frequency noise, the weight of the low-frequency filter is increased, so as to more effectively filter out high-frequency noise and low-frequency noise in each window data.
[0082] 204. Using the real-time adjusted filter, filter the window data at the next time step to obtain the preprocessed window data.
[0083] Once the real-time adjusted filter is obtained, the window data at the next time step can be filtered according to the real-time adjusted filter to obtain the preprocessed window data.
[0084] For ease of understanding, regarding Figure 7 The waveform data shown Figure 8 The paper presents a method for using real-time adjusted high-frequency and low-frequency filters to... Figure 7 This is a schematic diagram of the waveform after filtering the waveform data. Figure 8 The waveform signal in Figure 7 In contrast, it significantly filters out high-frequency and low-frequency noise in the window data, thereby improving the accuracy of subsequent data operations using waveform data.
[0085] Furthermore, after obtaining the preprocessed window data, normalization processing can be performed on multiple window data to transform data of different ranges, units, or distributions to a unified standard scale, thereby facilitating comparison between data.
[0086] In this embodiment of the application, before extracting the real-time baseline signal and the real-time peak signal from the waveform data, the waveform data is preprocessed. During the preprocessing process, the weights of the high-frequency filter and the low-frequency filter in the filter are adjusted in real time according to the window data distribution at the previous moment, thereby effectively filtering out noise signals in the waveform data.
[0087] Furthermore, the method of caching waveform data by setting a preset window size in this application also allows the data results of the first window to be reused directly when an error occurs in processing the data of the second window, thereby reducing the frequency of calculations and lowering the complexity of calculations.
[0088] based on Figure 2 In this embodiment, after obtaining the preprocessed window data, to prevent false peaks from appearing in the waveform data due to user errors such as hand tremors during operation, this application embodiment can further eliminate false peaks in the preprocessed window data. For details, please refer to... Figure 3 The embodiments of this application for eliminating false peaks in preprocessed window data include:
[0089] 301. For each preprocessed window of data, calculate the feature value of the window data. The feature value includes at least one of the following: the first-order difference mean of the window data, the signal slope, the main frequency, the variance, and the target time difference between the peak and peak values.
[0090] After obtaining the preprocessed window data, in order to identify false peaks in the preprocessed window data, this embodiment of the application can also calculate the feature values of the window data. The feature values here include at least the first-order difference mean of the window data, the signal slope, the main frequency, the variance, and the target time difference between the peak and peak values.
[0091] Specifically, the first-order difference mean is mainly used to describe the overall average trend of the window data, reflecting the average level of the difference between adjacent data points. It's easy to understand that normal peaks have approximately the same amplitude without large fluctuations. Therefore, if the first-order difference mean in the window data shows large fluctuations, it means there are false peaks with instantaneous large or small fluctuations. Thus, the magnitude of the first-order difference mean can be used to determine whether there are false peaks in the window data. The signal slope reflects the speed of waveform data change. Generally, the signal slope of normal peak data is a value within a fixed range. If the signal slope changes abruptly, it indicates the presence of some false peaks. The false peaks in the window data can be eliminated based on the abrupt slope value. The dominant frequency reflects the dominant frequency corresponding to a normal peak. Frequency values: The dominant frequency value of a normal peak generally falls within a certain range. If the dominant frequency value of some peaks differs significantly from the aforementioned range, it can be determined that the peak is a false peak. Variance reflects the discrete distribution of the data. The larger the variance, the more dispersed the data; the smaller the variance, the more concentrated the data is around the average. The variance of a normal peak generally falls within a certain range. If the variance of the window data does not fall within this range, it can be determined that a false peak exists in the window data. The target time difference between peaks refers to the time difference between adjacent peaks. The time difference between normal peaks generally falls within a fixed range. If the time difference between adjacent peaks in the window data exceeds this fixed range, it can be determined that a false peak exists in the window data.
[0092] 302. Based on the eigenvalues, eliminate the false peaks in the preprocessed window data to obtain the window data after eliminating the false peaks.
[0093] In step 301, when it is determined that there are false peaks in the preprocessed window data based on the feature values, the false peaks are eliminated according to the corresponding feature values. Therefore, when the feature value is the first-order difference mean, the false peaks can be eliminated based on the abnormal first-order difference mean. When the feature value is the signal slope, the false peaks are eliminated based on the abnormal slope value. When the feature value is the abnormal dominant frequency, the false peaks are eliminated based on the abnormal dominant frequency. When the feature value is the variance, the false peaks can be determined based on the abnormal variance value and eliminated. When the feature value is the target time difference between peak values, the false peaks can be eliminated based on the abnormal time difference between peak values.
[0094] In this embodiment, the process of eliminating abnormal peaks in preprocessed window data using eigenvalues is described in detail, thereby avoiding interference from abnormal data on waveform data and improving the accuracy of waveform data.
[0095] against Figure 3In the embodiments described below, the processes of extracting the real-time baseline signal and extracting the real-time peak signal from the window data after eliminating false peaks are described respectively:
[0096] I. Extracting the real-time baseline signal from the window data after eliminating false peaks
[0097] Please see Figure 4 :
[0098] 401. Perform amplitude fluctuation detection, slope detection, or mean stability detection on the window data after eliminating false peaks;
[0099] The baseline signal is mainly used to characterize the background signal or inherent noise of the treatment head under different motion states. For the same motion state, the baseline signal is generally relatively stable, so amplitude fluctuation detection, slope detection or mean stability detection can be performed on the window data.
[0100] Specifically, when performing amplitude band detection on window data, the variance of the window data can be calculated. Since the baseline data is generally relatively stable, the variance generally does not change much. When the variance is less than a preset threshold (for reference, the preset threshold here can be 5%-10% of the standard deviation of the window data), the data is determined to be the baseline data.
[0101] When performing slope detection on window data, the difference fitting trend of the window data can be extracted. If the difference fitting trend is a horizontal line, then the data is determined to be the baseline data.
[0102] When performing mean stability testing on window data, the mean of the window data can be calculated. Since baseline data is generally relatively stable, the mean will not fluctuate greatly. When the change in the mean is less than a preset threshold, the data is determined to be baseline data.
[0103] 402. Extract the real-time baseline signal based on the results of amplitude fluctuation detection, slope detection, or mean stability detection.
[0104] As in step 401, when performing amplitude fluctuation detection, slope detection, or mean stability detection on the window data, the real-time baseline signal can be extracted from the window data after eliminating false peaks based on the results of amplitude fluctuation detection (variance is less than a preset threshold), slope detection (difference fitting trend is a horizontal line), or mean stability detection (mean change is less than a preset threshold).
[0105] In this embodiment, amplitude fluctuation detection, slope detection, or mean stability detection can be performed on the window data, and the real-time baseline signal can be extracted from the window data after eliminating false peaks based on the corresponding detection results, thereby improving the convenience of extracting the real-time baseline signal.
[0106] II. Extracting Real-Time Peak Signals from Window Data After Eliminating False Peaks
[0107] Please see Figure 5 :
[0108] 501. Perform maximum search or dynamic threshold filtering on the window data after eliminating false peaks using a sliding window.
[0109] Waveform data is generally composed of a baseline signal and a peak signal. The value of the peak signal is significantly greater than that of the baseline signal. Therefore, in this embodiment of the application, for the window data after eliminating false peaks, a maximum value search can be performed in the manner of a sliding window, and the searched maximum value can be determined as the peak signal within the window data. Alternatively, dynamic threshold filtering can be performed (generally, the peak value is greater than the mean plus the standard deviation). Therefore, the data in the window data that is greater than the mean plus the standard deviation can be determined as the peak signal within the window data.
[0110] It is easy to understand that the distribution of window data is different when the treatment head is in different motion states. For example, when the treatment head is stationary, there are no peaks in the window data. When the treatment head is moving slowly, there are fewer peaks in the window data. When the treatment head is moving fast, there are more peaks in the window data. Therefore, the mean + standard deviation is different when the treatment head is in different motion states. Thus, the mean + standard deviation in this application is a dynamically changing value.
[0111] 502. Based on the search results for maximum values or the results of dynamic threshold filtering, determine the real-time peak signal in the window data after eliminating false peaks.
[0112] After performing a maximum search or dynamic threshold filtering on the window data, the real-time peak signal can be determined from the window data after eliminating false peaks, based on the results of the maximum search or the dynamic threshold filtering.
[0113] In this embodiment, a maximum value search or dynamic threshold filtering can be performed on the window data, and the real-time peak signal can be extracted from the window data after eliminating false peaks based on the maximum value search result or the dynamic threshold filtering result, thereby improving the convenience of extracting the real-time peak signal.
[0114] The following describes the process of classifying the motion state of the treatment head using a preset classification algorithm, combining the real-time baseline signal and the current motion velocity of the treatment head:
[0115] As an optional embodiment, in the process of classifying the motion state of the treatment head, this application embodiment may combine the feature values of the window data, the real-time baseline signal, the current motion speed of the treatment head and the motion state of the treatment head at the previous moment, and use a classification algorithm to classify the motion state of the treatment head at the next moment.
[0116] To facilitate understanding, the following description uses the random forest algorithm as an example to illustrate the process of classifying the motion state of the treatment head at the next moment by combining the feature values of the window data, the real-time baseline signal, the current motion velocity of the treatment head, and the motion state of the treatment head at the previous moment:
[0117] The process of classifying the motion state of the treatment head in the next moment using the random forest algorithm can be divided into the following steps, combining input features (window data feature values, real-time baseline signal, current motion speed, and previous motion state):
[0118] Before using the random forest algorithm, training data needs to be constructed first, and then the random forest algorithm needs to be trained using the training data, where:
[0119] 1. The process of constructing training data includes: collecting historical data and dividing the historical data into training data (80% of the total historical data) and test data (20% of the total historical data). The historical data includes the feature values of the window data, the real-time baseline signal, the current motion speed, the motion state at the previous moment, and the "motion state of the treatment head at the next moment" as a label.
[0120] 2. The training process includes: generating multiple subsets of samples from the training data (where the number of subsets is the same as the number of decision trees), and each subset is used to train one decision tree. The process of constructing a single decision tree includes:
[0121] For each decision tree, when splitting at each node, some features (such as total number of features - 2) are randomly selected from all input features (window features, baseline signal, current velocity, previous state) as candidate splitting features. The optimal splitting point is selected by calculating information gain (such as Gini index, entropy). The nodes are recursively split until the stopping condition is met (such as the number of node samples is less than the threshold, or the tree depth reaches the upper limit).
[0122] By integrating multiple decision trees, the random forest model is completed after all decision trees have been trained independently.
[0123] 3. Model Evaluation and Optimization
[0124] Validate the performance of multiple decision trees using test data and evaluate classification effectiveness through accuracy. If performance is unsatisfactory, adjust model hyperparameters: such as increasing the number of decision trees (to improve stability); or adjusting the maximum depth of the decision tree and the minimum number of samples for node splits (to avoid overfitting); or optimizing feature selection (such as removing redundant features and retaining features strongly correlated with the motion state).
[0125] 4. Real-time classification: Predicting the motion state in the next moment.
[0126] After model deployment, the real-time prediction process is as follows:
[0127] Real-time feature extraction: Calculate window features (such as statistics of the last 5 moments) and real-time baseline signals (such as current baseline deviation) from the window data collected at the current moment to obtain the current motion speed and the motion state at the previous moment;
[0128] Feature input model: The processed features are input into the trained random forest algorithm model;
[0129] Integrated voting: Each decision tree outputs a predicted label for the "next moment motion state", and finally the "majority vote" (i.e. the label with the most votes) is used as the final classification result to output the next moment motion state of the treatment head.
[0130] Through the above process, the random forest algorithm model can combine multi-dimensional features (time window trend, baseline correction, current and historical motion states) and utilize the anti-interference and stability of ensemble learning to achieve accurate classification of the motion state of the treatment head at the next moment.
[0131] This application embodiment describes in detail the process of classifying the motion state of the treatment head in the next moment by combining the feature values of window data, real-time baseline signal, current motion speed of the treatment head and the motion state of the treatment head at the previous moment, using a classification algorithm. The feature information collected in this process reflects the real-time state information of the treatment head, thereby improving both the accuracy and convenience of classifying the motion state of the treatment head.
[0132] Furthermore, in this embodiment of the application, after outputting the motion state of the treatment head, the size of the preset time window for buffering waveform data can be adjusted according to the output motion state. For example, if the current output motion state of the treatment head is stationary, the size of the preset time window can be increased when buffering waveform data according to the preset time window size at the next moment to improve the processing speed of waveform data. When the motion state of the treatment head is fast or slow, the size of the preset time window is decreased to improve the accuracy of processing waveform data in the preset time window.
[0133] To make it easier to understand, the following example is provided:
[0134] For example, if the preset time window size is 2 seconds, the preset time window size can be increased in the next moment if the previous output of the treatment head's motion state is stationary, such as adjusting 2 seconds to 4 seconds, to improve the processing speed of waveform data. If the previous output of the treatment head's motion state is fast or slow, the preset time window can be adjusted from 2 seconds to 1 second in the next moment to reduce the amount of waveform data in the preset time window, thereby improving the accuracy of waveform data processing in the preset time window.
[0135] It is understood that, in various embodiments of the present invention, the order of the steps does not imply the order of execution. The execution order of each step should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0136] The above describes in detail the method for recognizing the motion state of the treatment head in the embodiments of this application. The following describes in detail the treatment device in the embodiments of this application. Please refer to [link / reference]. Figure 6 The therapeutic device in this application embodiment includes at least a therapeutic head 601, at least one sensor 602 communicatively connected to the therapeutic head, and a controller 603 and a memory 604 communicatively connected to the therapeutic head 601. The memory 604 stores a preset program, and the controller 603 executes the preset program to implement the various steps in the above method embodiments of this application embodiment.
[0137] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0138] The above describes the therapeutic device in the embodiments of the present invention. The following describes the computer device in the embodiments of the present invention from the perspective of hardware processing:
[0139] This computer device is used to implement the functions of a therapeutic instrument. One embodiment of the computer device in this invention includes:
[0140] Processor and memory;
[0141] The memory is used to store computer programs, and when the processor executes the computer programs stored in the memory, it can implement the various steps in the above method embodiments.
[0142] It is understood that when the processor in the computer device described above executes the computer program, it can also realize the functions of each unit in the corresponding device embodiments described above, which will not be repeated here. For example, the computer program can be divided into one or more modules / units, which are stored in the memory and executed by the processor to complete the present invention. The one or more modules / units can be a series of computer program instruction segments capable of performing specific functions, which describe the execution process of the computer program in the therapeutic device. For example, the computer program can be divided into units in the aforementioned therapeutic device, and each unit can realize the specific functions described in the corresponding therapeutic devices above.
[0143] The computer device may be a desktop computer, laptop, handheld computer, or cloud server, etc. The computer device may include, but is not limited to, a processor and memory. Those skilled in the art will understand that the processor and memory are merely examples of a computer device and do not constitute a limitation on the computer device. It may include more or fewer components, or a combination of certain components, or different components. For example, the computer device may also include input / output devices, network access devices, buses, etc.
[0144] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the computer device, connecting various parts of the computer device via various interfaces and lines.
[0145] The memory can be used to store the computer programs and / or modules. The processor implements various functions of the computer device by running or executing the computer programs and / or modules stored in the memory and by calling data stored in the memory. The memory may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function, etc.; the data storage area may store data created according to the use of the terminal, etc. In addition, the memory may include high-speed random access memory, and may also include non-volatile memory, such as hard disk, RAM, plug-in hard disk, smart media card (SMC), secure digital card (SD card), flash card, at least one disk storage device, flash memory device, or other volatile solid-state storage device.
[0146] The present invention also provides a computer-readable storage medium for implementing the functions of a therapeutic device, wherein a computer program is stored thereon, and when the computer program is executed by a processor, the processor can be used to perform the various steps in the above method embodiments.
[0147] It is understood that if the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a corresponding computer-readable storage medium. Based on this understanding, all or part of the processes in the above-described embodiments of the present invention can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the above-described method embodiments. The computer program includes computer program code, which can be in the form of source code, object code, executable file, or some intermediate form. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording media, USB flash drive, portable hard drive, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc. It should be noted that the content included in the computer-readable medium can be appropriately added or removed according to the requirements of patent practice in different jurisdictions. For example, in some jurisdictions, according to patent practice, the computer-readable medium does not include electrical carrier signals and telecommunication signals.
[0148] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between apparatuses or units through some interfaces, and may be electrical, mechanical, or other forms.
[0149] The units described 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 can be selected to achieve the purpose of this embodiment according to actual needs.
[0150] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0151] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for recognizing head movement states during treatment, wherein, The treatment head is connected to at least one pressure sensor that contacts a preset position on the target object, and the method includes: Real-time baseline signal and real-time peak signal are extracted from the waveform data output by the at least one pressure sensor, wherein the real-time baseline signal is used to characterize the background signal when the treatment head is in a stationary state; Based on the time corresponding to the waveform data and the real-time peak signal, the current speed of the treatment head in the circular motion is determined, wherein the distance between two adjacent peaks is considered as the treatment head moving one revolution; Combining the real-time baseline signal with the current movement speed of the treatment head, a preset classification algorithm is used to classify the movement state of the treatment head. The movement state includes stationary, fast movement, and slow movement. Fast movement is used to characterize movement within a first preset speed range, and slow movement is used to characterize movement within a second preset speed range. The minimum speed value of the first preset speed range is greater than the maximum speed value of the second preset speed range.
2. The method according to claim 1, characterized in that, Before extracting the real-time baseline signal and real-time peak signal from the waveform data output by the at least one pressure sensor, the method further includes: The waveform data is preprocessed to obtain preprocessed waveform data, wherein the preprocessing process includes: The waveform data is cached according to a preset time window size to obtain multiple cached window data, wherein the waveform data includes time and amplitude; For the multiple window data, obtain the window data distribution of the previous time step in the multiple window data, the window data distribution includes high-frequency data distribution and low-frequency data distribution; Based on the window data distribution at the previous moment, the first weight of the high-frequency filter and the second weight of the low-frequency filter in the filter are adjusted in real time to obtain the real-time adjusted filter. The high-frequency filter is used to filter the high-frequency components in the window data, and the low-frequency filter is used to filter the low-frequency components in the window data. The window data at the next time step is filtered using the real-time adjusted filter to obtain preprocessed window data.
3. The method according to claim 2, characterized in that, Extracting the real-time baseline signal and real-time peak signal from the waveform data output by the at least one pressure sensor includes: The real-time baseline signal and the real-time peak signal are extracted from the preprocessed waveform data; Before extracting the real-time baseline signal and the real-time peak signal from the preprocessed waveform data, the method further includes: For each preprocessed window of data, the feature value of the window data is calculated. The feature value includes at least one of the first-order difference mean, signal slope, main frequency, variance, and target time difference between peak and peak values of the window data. Based on the feature value, the false peaks in the preprocessed window data are eliminated to obtain the window data after the false peaks are eliminated.
4. The method according to claim 3, characterized in that, Extracting the real-time baseline signal from the preprocessed waveform data includes: Perform amplitude fluctuation detection, slope detection, or mean stability detection on the window data after eliminating false peaks; The real-time baseline signal is extracted based on the results of the amplitude fluctuation detection, the slope detection, or the mean stability detection.
5. The method according to claim 3, characterized in that, Extracting the real-time peak signal from the preprocessed waveform data includes: The window data after eliminating false peaks is subjected to maximum search or dynamic threshold filtering using a sliding window. Based on the search results for maximum values or the filtering results for dynamic thresholds, the real-time peak signals in the window data after eliminating false peaks are determined.
6. The method according to claim 3, characterized in that, The step of classifying the motion state of the treatment head by combining the real-time baseline signal with the current motion velocity of the treatment head and using a preset classification algorithm includes: By combining the feature values of the window data, the real-time baseline signal, the current movement speed of the treatment head, and the movement state of the treatment head at the previous moment, a classification algorithm is used to classify the movement state of the treatment head at the next moment.
7. The method according to claim 1, characterized in that, Determining the current movement speed of the treatment head based on the time corresponding to the waveform data and the real-time peak signal includes: Based on the time corresponding to the waveform data and the number of real-time peak signals, the number of peaks per unit time is calculated; The angular velocity of the current movement of the treatment head is calculated based on the unit time and the number of wave peaks within the unit time.
8. A therapeutic device, characterized in that, At least including: The treatment head, at least one pressure sensor communicatively connected to the treatment head and in contact with a preset position of a target object, and a controller communicatively connected to the treatment head and a memory storing a preset program, wherein the controller, when executing the preset program, is used to perform the method for recognizing the movement state of the treatment head as described in any one of claims 1 to 7.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it is used to implement the method for recognizing the motion state of the treatment head as described in any one of claims 1 to 7.
10. A computer program product having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it is used to implement the method for recognizing the motion state of the treatment head as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Radio frequency therapeutic apparatus and motion trail identification system thereof
CN119386380A
KR20240133054A