A Multi-Level Muscle Fatigue Monitoring Method Based on Dual Clustering and Confused Sample Screening
By employing a dual clustering model and a distance difference threshold screening method, the muscle fatigue categories are refined, solving the problems of insufficient category refinement and high computational cost in existing technologies, and enabling real-time and detailed monitoring of muscle fatigue.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-15
- Publication Date
- 2026-03-10
AI Technical Summary
Existing muscle fatigue assessment methods based on surface electromyography signals suffer from insufficient categorization, lack of unified labeling standards, susceptibility to subjectivity, high computational costs, and difficulty in providing real-time feedback on muscle fatigue status.
A dual clustering model combined with a distance difference threshold screening method is adopted. Fatigue categories are refined through unsupervised clustering technology. Clustering models at the initial and subdivided category levels are constructed using multi-channel intermediate frequency signal features. Muscle fatigue levels are identified by screening through confused samples.
It enables more detailed grading of muscle fatigue, improves the practicality and rationality of monitoring methods, reduces computational costs, and can reflect the fatigue development process in real time.
Smart Images

Figure CN120878149B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of muscle fatigue monitoring technology, specifically a multi-level muscle fatigue monitoring method based on dual clustering and confused sample screening. Background Technology
[0002] Muscle fatigue refers to a temporary decline in muscle capacity after sustained work and contraction, making it difficult for the body to maintain expected strength. This phenomenon occurs frequently in daily physiological activities, manifesting as muscle weakness or soreness. Muscle fatigue not only leads to reduced work capacity, decreased work efficiency, inattention, slower operation speed, and reduced coordination and flexibility, thus increasing the risk of errors and accidents, but it can also cause muscle injury and hinder normal exercise rehabilitation. Therefore, the ability to accurately and meticulously assess muscle fatigue is of great significance in occupational health, sports health, and rehabilitation medicine. This disclosure focuses on assessing localized muscle fatigue.
[0003] Research on muscle fatigue assessment has seen a proliferation of machine learning and deep learning methods based on surface electromyography (sEMG). While machine learning methods rely on feature extraction techniques, and deep learning methods can automatically extract features from raw signals, robust feature extraction techniques are often required for better results. Currently, considering the complex non-stationary and nonlinear variations of EMG signals, research on nonlinear features such as entropy, recursive quantization analysis, and fractal dimension is becoming mainstream. However, traditional linear feature extraction methods (such as time domain, frequency domain, and time-frequency domain) remain meaningful because their computational speed is generally faster than nonlinear methods. To ensure real-time performance as much as possible, this invention discloses the classic frequency domain feature, median frequency (MF), as a feature for assessing fatigue.
[0004] Existing fatigue classification and assessment studies based on surface electromyography (EMG) signals mainly consist of supervised classification tasks. Since there is currently no gold standard for measuring fatigue, these studies lack a unified standard for labeling real-world data. Typically, the initial stage of exercise is labeled as non-fatigue, while the later stages, up to the point of extreme fatigue, are labeled as fatigue. More refined methods label the intermediate states between these two as fatigue transition states. Alternatively, during experiments, a rating scale such as RPE can be used to record participants' feedback in real time and use this as the true label for the data.
[0005] Most studies on muscle fatigue classification and assessment, especially supervised studies, heavily rely on accurate data and true labels. The accuracy of the labels directly affects the evaluation and optimization of the classification model. To ensure label accuracy as much as possible, most studies reduce the number of categories, usually to no more than three. However, this approach cannot eliminate the influence of subjectivity, nor can it meticulously track the nonlinear changes in muscle fatigue, which is detrimental to developing more detailed and reasonable fatigue monitoring and early warning plans in fields such as sports rehabilitation and occupational health protection. Furthermore, the refinement of categories is easily affected by subjectivity; for example, labeling methods using subjective scales may lead to a decrease in label accuracy. In addition, to capture the nonlinear changes in electromyographic signals for more accurate fatigue classification, some studies use nonlinear features such as entropy, which improves accuracy but also increases computational costs and affects the real-time performance of the system.
[0006] Therefore, the current research on muscle fatigue classification and assessment based on surface electromyography signals has the following problems that urgently need to be solved: (1) The categories of classification and assessment are not detailed enough, making it difficult to grasp the changes in the fatigue development process in detail; (2) Supervised research methods lack unified standards in data labeling, and are easily inaccurate when the categories are refined due to subjectivity, which does not conform to the actual fatigue situation; (3) When introducing more robust features, the computational cost increases, and if the system is required to provide real-time feedback on the user's muscle fatigue, these costs need to be considered accordingly. Summary of the Invention
[0007] The purpose of this invention is to provide a multi-level muscle fatigue monitoring method based on dual clustering and confused sample screening. This method sets a distance difference threshold and combines it with a dual clustering model to jointly screen and process confused samples, thereby refining fatigue categories. The embodiments extend from a three-class classification to a five-class classification, striving to accurately reflect the fatigue development process. This method employs unsupervised clustering technology, does not rely on subjective labels, and only uses the true labels recorded by subjective scales as a rough fatigue assessment reference for the clustering results. This method only utilizes multi-channel intermediate frequency signals as fatigue features to ensure real-time performance; its main computational burden is concentrated on the Fast Fourier Transform.
[0008] To achieve the above objectives, the present invention provides the following technical solution:
[0009] A method for monitoring multi-level muscle fatigue includes the following steps:
[0010] Collect multi-channel raw electromyographic signals of local muscles during continuous dynamic or static contraction until fatigue, and form raw signal sequences;
[0011] The original signal sequence is preprocessed and multi-channel intermediate frequency features are extracted to obtain an intermediate frequency feature sequence;
[0012] Based on the aforementioned mid-frequency feature sequence, a dual clustering model is constructed;
[0013] Multi-channel electromyography (EMG) signals of the same local muscle during continuous dynamic or static contraction until fatigue are acquired in real time. The multi-channel EMG signals are preprocessed and multi-channel mid-frequency features are extracted to obtain a real-time sample feature sequence.
[0014] Using the aforementioned dual clustering model, confused samples are filtered from the real-time sample feature sequences to obtain muscle fatigue monitoring results.
[0015] In one possible implementation, a dual clustering model is constructed based on the mid-frequency feature sequence, specifically including:
[0016] Based on the mid-frequency feature sequence, the process of local muscle contraction until fatigue is divided into continuous dynamic or static contraction, resulting in an initial classification level and a sub-classification level. The initial classification level contains N muscle fatigue categories, and the sub-classification level contains M muscle fatigue categories, where M > N.
[0017] The MiniBatchKMeans algorithm is used to generate initial classification-level cluster centers. Intermediate cluster centers at the sub-category level are obtained through interpolation. Based on the initial classification-level cluster centers, a first clustering model is generated. Based on the initial classification-level cluster centers and the intermediate sub-category level cluster centers, a second clustering model is generated. The first and second clustering models are used as a dual clustering model.
[0018] In one possible implementation, after constructing the dual clustering model, the method further includes: determining the category transformation matrix of the first clustering model and the second clustering model, and the minimum distance difference matrix of the cluster centers of the first clustering model.
[0019] Specifically, determining the category transformation matrix of the first clustering model and the second clustering model includes: summing the mid-frequency features of each channel of the cluster center of the dual clustering model, sorting them from largest to smallest to obtain the sorted index matrix. The index matrix represents the relationship between the clustering labels output by the dual clustering model and the real muscle fatigue category. Based on the index matrix, a relationship dictionary between the clustering labels output by the dual clustering model and the real muscle fatigue category is determined, and the category transformation matrix is obtained based on this relationship dictionary.
[0020] Determining the minimum distance difference matrix for cluster centers specifically includes: traversing the cluster centers of the first clustering model, calculating the distances between the current cluster center and other cluster centers, as well as the distance between the current cluster center and itself, sorting the distance values in ascending order, traversing the sorted distance values, filtering out the minimum and second-smallest distances adjacent to the true muscle fatigue category, subtracting the minimum and second-smallest distances to obtain the minimum distance difference for that cluster center, and obtaining the minimum distance difference matrix after traversal.
[0021] In one possible implementation, the dual clustering model is used to perform confused sample screening on the real-time sample feature sequence to obtain muscle fatigue monitoring results, specifically including:
[0022] Input the real-time sample feature sequence into the dual clustering model to obtain the predicted category y1 of the first clustering model and the predicted category y2 of the second clustering model;
[0023] Calculate the distance between the real-time sample feature sequence and all cluster centers of the first clustering model. Sort the distance values in ascending order. Iterate through the sorted distance values and select the minimum and second smallest distances. Calculate the difference between the minimum and second smallest distances to obtain the sample distance difference.
[0024] Based on the predicted category y1, the corresponding cluster center is determined. The minimum distance difference matrix of the cluster centers of the first clustering model is indexed through this cluster center to obtain the distance between the cluster center and its nearest neighbor, thus obtaining the center distance difference. The center distance difference is multiplied by a preset ratio to obtain a screening threshold. The first screening is performed based on the relationship between the sample distance difference and the screening threshold to obtain non-confused samples or suspected confused samples. The suspected confused samples are then combined with the predicted category y2 for a second screening to determine whether they are confused or non-confused samples. The confused samples are output as an intermediate category. The non-confused samples are used to update the dual clustering model, the category transformation matrix, and the minimum distance difference matrix of the cluster centers. After the above screening steps, the final category is output. The final category and the intermediate category are used as the muscle fatigue monitoring results.
[0025] In one possible implementation, suspected confounding samples are then subjected to a second screening using a dual clustering model, specifically including:
[0026] When both predicted category y1 and predicted category y2 are the lowest or highest category in their respective clustering models, the category of the real-time sample feature sequence can be confidently identified as predicted category y1; when both predicted category y1 and predicted category y2 are the intermediate categories in their respective clustering models, the category of the real-time sample feature sequence can also be confidently identified as predicted category y1.
[0027] If any other situation occurs, it indicates that the category of the new sample is a transitional category between two categories, and the feature sequence of the real-time sample is identified as a confusing sample.
[0028] In one possible implementation, suspected confounding samples are then subjected to a second screening using a dual clustering model, specifically including:
[0029] The real-time sample feature sequences are input into the first and second clustering models, respectively. Two predicted categories, y_true1 and y_true2, are obtained through a category transformation matrix. The initial classification level contains k_down muscle fatigue levels, and the sub-class levels contain k_up muscle fatigue levels.
[0030] When none of the following three conditions are met, the real-time sample feature sequence is determined to be a confused sample:
[0031] ①y_true1 is equal to the floor (k_down / 2) and y_true2 is equal to the floor (k_up / 2);
[0032] ②y_true1 equals 0 and y_true2 equals 0;
[0033] ③y_true1 equals k_down-1 and y_true2 equals k_up-1;
[0034] Otherwise, the real-time sample feature sequence is determined to be a non-confused sample.
[0035] In one possible implementation, the obfuscated sample output intermediate state category specifically includes:
[0036] Calculate the distance between the real-time sample feature sequence and all cluster centers of the first clustering model. Sort the distance values in ascending order. Iterate through the sorted distance values and select the true classes corresponding to the smallest and second smallest distances, denoted as class1 and class2. The "intermediate state" is (class1+class2) / 2. Then, make the following judgment:
[0037] ① Determine whether y_true1 is less than the value after rounding down (k_down / 2) and whether y_true2 is greater than the value after rounding down (k_up / 2); if the conditions are met, the final category is "intermediate state" + 1;
[0038] ② Determine whether y_true1 is greater than the value after rounding down (k_down / 2) and whether y_true2 is less than the value after rounding down (k_up / 2); if the conditions are met, the final category is "intermediate state"-1; if neither of the above two conditions is met, the final category is "intermediate state".
[0039] The result of the "intermediate state" is used as the intermediate state category.
[0040] In one possible implementation, the unconfused samples are used to update the dual clustering model, the category transition matrix, and the minimum distance difference matrix between cluster centers, specifically including:
[0041] Unconfused samples are updated using the following preset formula.
[0042]
[0043] Where x i It is the single input sample. It is the old cluster center. It is the updated cluster center, n k It is the current cluster center μ k The number of samples included.
[0044] In one possible implementation, when the real-time sample feature sequence is a continuous-time sample, an improved voting mechanism is used to process the intermediate or final category to obtain the final muscle fatigue monitoring result.
[0045] Compared with the prior art, the advantages of this invention are as follows:
[0046] 1. This invention provides a more detailed classification of muscle fatigue. Theoretically, by constructing and optimizing models with different numbers of categories multiple times, the degree of fatigue development can be refined to the maximum extent, which differs from the fixed number of categories such as binary or tri-classification commonly used in existing technologies.
[0047] 2. This invention proposes using an unsupervised clustering model to address the problem of refined classification of muscle fatigue. Unlike supervised methods that rely on precise labels to train the model and evaluate classification performance, the clustering model used in this invention can be constructed without labeled data and can automatically determine the classification category based on the characteristics of the data features, thereby significantly improving the practicality of muscle fatigue monitoring methods.
[0048] 3. This invention still uses a subjective scale method for rough labeling of the samples used. Unlike supervised methods that use these labels as the gold standard to measure the classification accuracy of individual samples, this invention regards these labels as holistic labels reflecting a certain stage of fatigue development. It is no longer limited to the accuracy of individual samples, but focuses on the accuracy of the overall sample. This better reflects the nonlinear, complex, and restorative characteristics of fatigue development, thereby significantly improving the rationality of muscle fatigue monitoring methods.
[0049] 4. This invention innovatively proposes a dual clustering model and a sample screening method based on distance difference thresholds. By combining these two methods, it is possible to effectively identify confusing samples among new samples and, through reclassification, achieve a more refined understanding of muscle fatigue levels.
[0050] 5. This invention proposes an improved voting mechanism for classifying continuous-time samples. Compared to traditional voting mechanisms, the improved mechanism takes into account the non-abrupt nature of fatigue development, maintaining not only a voting queue but also retaining the previous voting results, which influence the next vote based on user-defined weights. Therefore, this improvement more fully utilizes the continuous temporal characteristics of the samples, making the judgment process smoother and more realistic. Attached Figure Description
[0051] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0052] Figure 1 This is a flowchart illustrating the overall process of the multi-level muscle fatigue monitoring method used in this embodiment of the invention.
[0053] Figure 2 The following is a detailed flowchart of the multi-level fatigue monitoring method in this embodiment of the invention, which is divided into two parts: a method for constructing a dual clustering model and a real-time discrimination method. The left side is a detailed flowchart of the method for constructing a dual clustering model, and the right side is a detailed flowchart of the real-time discrimination method.
[0054] Figure 3 This is a schematic diagram illustrating the reference electrode positions and experimental methods for acquiring 8-channel electromyography signals during sustained static contraction of forearm muscles in an embodiment of the present invention. Figure 3 (a) shows the reference electrode position during the experiment. Figure 3 (b) describes the experimental method;
[0055] Figure 4 This is a schematic diagram illustrating the principle of the method for filtering confused samples based on a distance difference threshold in an example of the present invention.
[0056] Figure 5 This is a training set clustering diagram obtained by using a method to filter confusing samples after constructing a dual clustering model in an embodiment of the present invention, wherein the circled part is the confusing samples in the training set;
[0057] Figure 6 This is the RPE subjective scale used in the example of the present invention to reference the classification effect. The checkmarks in the scale record the subjective feedback of a subject during the real-time collection of data over a continuous period of time.
[0058] Figure 7 This is a schematic diagram of the improved voting mechanism in an embodiment of the present invention. Detailed Implementation
[0059] The technical solutions of the embodiments of the present invention 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. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.
[0060] Example:
[0061] It should be noted that the terms "comprising" and "having" and any variations thereof in the embodiments of the present invention are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not necessarily limited to those steps or units that are explicitly listed, but may include other steps or units that are not explicitly listed or that are inherent to such processes, methods, products, or devices.
[0062] Figure 1 This is a flowchart illustrating the overall process of the multi-level muscle fatigue monitoring method used in this embodiment of the invention. Figure 1 As shown in the figure, this invention proposes a multi-level muscle fatigue monitoring method, which may specifically include the following steps:
[0063] Step 110: Collect multi-channel raw electromyographic signals of local muscles during continuous dynamic or static contraction until fatigue, and form raw signal sequences.
[0064] Figure 2 The following is a detailed flowchart of the multi-level fatigue monitoring method in this embodiment of the invention, which is divided into two parts: a method for constructing a dual clustering model and a real-time discrimination method. The left side is a detailed flowchart of the method for constructing a dual clustering model, and the right side is a detailed flowchart of the real-time discrimination method. Figure 3 This is a reference schematic diagram showing the reference electrode positions and experimental methods for collecting 8-channel electromyography signals during sustained static contraction of forearm muscles in an embodiment of the present invention, as shown below. Figure 2 As shown, in this embodiment, an 8-channel electromyography (EMG) sensor with a 2kHz frequency is used. For details on the specific placement of the electrodes, please refer to [link to documentation]. Figure 3 (a): Using the extensor carpi ulnaris muscle of the forearm as the localization point, eight sets of medical gel electrodes are placed in a ring at equal intervals. Each set consists of two medical gel electrodes arranged longitudinally; the potential difference between them reflects the original electromyographic signal of the muscle at that location. Each set of electrodes corresponds to one channel, forming an eight-channel system. It is important to note that... Figure 3 (a) There is an undrawn electrode in the forearm back view shown on the left, which is intended to illustrate that the most prominent part of the ulna should be avoided when placing the electrode, as this area is basically uncovered by muscle.
[0065] Regarding the specific implementation method of sustained static contraction, in this embodiment, the experiment uses a method of continuously squeezing a hand gripper until it is impossible to hold the position, to simulate the development process of sustained static contraction of the forearm muscles until fatigue. See the relevant schematic diagram. Figure 3 (b)
[0066] Step 120: Preprocess the original signal sequence and extract multi-channel intermediate frequency features to obtain an intermediate frequency feature sequence.
[0067] Before constructing the dual clustering model in this embodiment, a series of processes need to be performed on the original electromyographic signals, such as... Figure 2 As shown, it can be divided into two steps: preprocessing and mid-frequency feature extraction.
[0068] Step 121: Electromyography signal preprocessing.
[0069] For dynamic contractions, methods such as the short-time energy thresholding method can be used to extract the active segment of the electromyographic (EMG) signal before preprocessing. However, this embodiment uses a continuous static contraction-triggered fatigue mode, so it is processed directly. The raw EMG signal is often accompanied by various noises, such as baseline drift and power frequency interference. First, filtering is performed. To meet real-time requirements, this embodiment does not use complex filters, but uses a classic filtering method: first, a 50Hz notch filter is used to filter out power frequency interference, and then an 8th-order Butterworth bandpass filter from 20 to 500Hz is used to filter out baseline drift, thereby obtaining the main frequency band of the EMG signal. After filtering, windowing is performed. Considering that muscle fatigue development is nonlinear but not abrupt, the window length should not be too short. This embodiment uses a window length of 2000 sample points, i.e., 1 second. To make the decision smoother, the windows need to overlap, so the step size is set to 1000, i.e., 50% overlap between windows.
[0070] Step 121: Extraction of mid-frequency features.
[0071] The intermediate frequency (IF) refers to the midpoint frequency of the signal power spectrum. In frequency domain analysis, when the power spectrum of an electromyographic (EMG) signal is arranged according to its frequency distribution, the IF is the frequency value that divides the power spectrum into two equal parts, meaning that the power on either side of this frequency point accounts for 50% of the total power. During muscle contraction, the frequency distribution of the EMG signal changes. Numerous studies have shown that changes in the IF can reflect muscle fatigue; when fatigue occurs, the IF typically decreases. Based on this characteristic, this embodiment uses 8-channel IF features for clustering model construction.
[0072] Furthermore, in this embodiment, each window sample is used as the basic unit. Before extracting the intermediate frequency, a fast Fourier transform is performed to obtain the spectrum and power spectrum of each window. Then, according to the formula:
[0073]
[0074] The intermediate frequency (IF) values for each channel of each window are obtained, resulting in an IF feature set containing 8 channels, where PSD represents the power spectral density of the window. After the IF feature set is constructed, this embodiment further performs maximum and minimum value normalization processing on it, using the following normalization formula:
[0075]
[0076] Where X represents the sample value of a certain channel, X min X represents the minimum value of this channel. max This represents the maximum value of that channel. Therefore, this method performs normalization processing separately for each channel of the multi-channel data.
[0077] Step 130: Construct a dual clustering model based on the mid-frequency feature sequence.
[0078] The key to this invention lies in expanding a clustering model with fewer categories to create new clusters, thereby refining the fatigue categories. The crucial element in expanding these new clusters is the distance-difference-based confusion sample screening method, which will be introduced later. However, relying solely on this screening method may lead to some non-confusion samples being misclassified as confusion samples. Therefore, this invention proposes using a second clustering model with the same number of clusters as the final refined clusters for auxiliary discrimination.
[0079] In this embodiment, the aforementioned steps have yielded a normalized 8-channel intermediate frequency feature set. Subsequently, the construction of these two clustering models with different numbers of classes can begin, as detailed below. Figure 2 As shown:
[0080] Step 131: Determine the initial category and subcategories
[0081] This embodiment references most supervised classification methods, determining the initial category as a three-category system with labels 0, 1, and 2. Subsequently, the subcategories are expanded using an interpolation method, resulting in five subcategories: 0.5, 1, 1.5, and 2. This establishes transitional categories between the original three categories. Theoretically, this approach allows for continuous refinement, approximating the optimal category for muscle fatigue development in any specific work, exercise, or rehabilitation scenario.
[0082] Step 132: Construct three-class and five-class clustering models
[0083] This embodiment first constructs a three-class clustering model, specifically using the MiniBatchKMeans clustering algorithm. This algorithm is an optimized version of the traditional K-Means algorithm. By updating the cluster centers using only a small random subset of the dataset (i.e., a minibatch) in each iteration, it significantly reduces the computational cost of processing the entire dataset in each iteration of the traditional K-Means algorithm, thereby improving efficiency and meeting real-time requirements. Its objective function is the same as that of the traditional K-Means algorithm, which is to minimize the sum of squared distances from a data point to its nearest cluster center:
[0084]
[0085] Where n is the total number of data points. i It is the i-th data point, μ k It is the kth cluster center, r ik It is an indicator variable representing the data point x. i Does it belong to the cluster center μ? k Then, assuming each iteration uses a mini-batch of data of size b, the update formula is as follows:
[0086]
[0087] in It is the old cluster center. It is the updated cluster center, x i These are sample points within a small batch of samples. k It is the current cluster center μ k The number of samples included. B is the current mini-batch sample set. |B| is the size of the mini-batch sample. In this embodiment, a batch of 100 samples with |B| = 100 is used for processing. Simultaneously, the cluster center initialization method is set to kmeans++. This initialization method, by more reasonably selecting the initial cluster centers, can effectively improve the initial quality of clustering, thereby accelerating the convergence speed of the algorithm and improving the quality of the final clustering results. The specific steps are as follows: ① Randomly select a point from the dataset as the first cluster center; ② For each point in the dataset, denoted as x... i Calculate its distance to the selected cluster center C = {c1, c2, ..., c} j The shortest distance dx i C):
[0088]
[0089] ③ The next cluster center is selected based on probability, where the selection probability is Px. i It is proportional to the square of the distance.
[0090]
[0091] Where X represents all points in the dataset, meaning the farther away a point is, the higher its probability of being selected. ④ Repeat steps ② and ③ until all k cluster centers are selected.
[0092] Furthermore, MiniBatchKMeans can continuously accept new samples and update cluster centers based on the incremental update mechanism of small batch data (through the partial_fit method of MiniBatchKMeans in scikit-learn), thus making the method adaptive.
[0093] Furthermore, after constructing the three-class clustering model, the five-class clustering model can be constructed. This embodiment also uses MiniBatchKMeans as the construction algorithm, but the initialization method no longer directly uses kmes++. Instead, it first extracts the three cluster centers corresponding to the three-class clustering model, sums the values of each channel, and sorts them. Then, it takes the mean of the middle cluster center and the two end cluster centers, obtaining two additional mean points. Finally, it combines these three cluster centers into a total of five points as the initialization points for the five-class model. This initialization method not only accelerates the calculation and convergence speed of the five-class model but also makes the clustering results more consistent with the actual transition situation of fatigue development.
[0094] Step 133: Calculate the category transformation matrix, which is used to transform the true category.
[0095] Since clustering methods are unsupervised, the categories assigned by the clustering method itself may not accurately reflect the actual situation. This invention innovatively proposes utilizing the characteristics of mid-frequency features—that is, mid-frequency features decrease as fatigue increases—to determine a category transformation matrix for both three-class and five-class classification models. Specifically, the sum of each channel of the cluster centers in both models is calculated, and then the results are sorted from largest to smallest to obtain a sorted index matrix. The index matrix reflects the relationship between the original index and the sorted position. Taking the three-class clustering model in this embodiment as an example, the sorted index matrix is [1,2,0]. This indicates that after the three-class clustering model automatically divides the categories, the mid-frequency feature sum of each channel in category 0 is at the last position, i.e., the smallest. According to the mid-frequency characteristic (the smallest corresponds to the heaviest fatigue), the true category of category 0 should be 2; the mid-frequency feature sum of each channel in category 1 is at the first position, i.e., the largest. According to the mid-frequency characteristic (the largest corresponds to the lightest fatigue), the true category of category 1 should be 0; the mid-frequency feature sum of each channel in category 2 is in the middle, so its true category should be 1. Furthermore, a correspondence dictionary {0:2,1:0,2:1} can be constructed, and the category transformation matrix TT can be obtained as [2,0,1] through this dictionary. The three-class classification model only needs to use its prediction result as the index of this matrix to obtain the true category. For example, when the prediction result is 0, its true category is TT[0] = 2. With the help of this matrix, subsequent category judgments and mutual calculations will not be prone to errors.
[0096] 134. Calculate the minimum distance difference matrix of the three-class cluster centers for use in implementing the discrimination method.
[0097] In this embodiment, the minimum distance difference matrix of the three-category cluster centers is a necessary condition for the first step of filtering confused samples in the subsequent real-time discrimination method. It actually records the straight-line distance between each cluster center and its nearest neighbor in the true class (true class difference is 1), such as... Figure 4 The distance between points A and D in the matrix. To obtain this matrix, we first need to calculate the distance matrix between cluster centers (including the distance to themselves), then sort the different cluster centers in ascending order. By traversing the sorted matrix, we find the minimum distance and the second smallest distance between two truly adjacent classes (the difference between the truly adjacent classes is 1). The difference between the two is the minimum distance difference for that cluster center. By traversing each cluster center in this way, we can obtain the final minimum distance difference matrix. The overall process can be expressed by the following formula:
[0098]
[0099] Where M i D represents the minimum distance difference between the i-th cluster centers in the minimum distance difference matrix. ij d represents the cluster center i and d jThe distances between them, where labeli and labelj represent the cluster centers d, respectively. i and d j The true category label, in this embodiment of the invention, refers to the definition of category adjacency in this invention, and converts the part of the formula that expresses category adjacency into the representation of |labelj)-labeli)|=1.
[0100] Thus, the dual-model construction part of this embodiment, namely Figure 2 The detailed steps for the left half have been thoroughly analyzed; the next step is... Figure 2 The right half, i.e., the real-time discrimination part.
[0101] Step 140: Real-time acquisition of multi-channel electromyographic signals of the same local muscle during continuous dynamic or static contraction until fatigue, preprocessing of the multi-channel electromyographic signals and extraction of multi-channel mid-frequency features to obtain real-time sample feature sequences.
[0102] In this embodiment, this step is basically the same as step 120. The electrode position remains unchanged, and the 8-channel electromyography data of the forearm during continuous static contraction is collected. The only difference is that in this acquisition process, after collecting sample points of the window length (still set to a window length of 2000 and a step size of 1000), the subsequent steps will be directly entered.
[0103] Step 150: Using the aforementioned dual clustering model, perform confusion sample screening on the real-time sample feature sequence to obtain muscle fatigue monitoring results.
[0104] For newly acquired real-time sample feature sequences (hereinafter referred to as new samples), the specific steps of the multi-level muscle fatigue monitoring method based on screening for confusing samples proposed in this invention are as follows. This embodiment will screen the new samples twice to determine whether they are confusing samples. First, the first screening is based on a distance difference threshold, which is determined by the minimum distance difference between the three-category cluster centers corresponding to the new sample. However, multiple rounds of experiments in this embodiment show that relying solely on this threshold for screening can lead to some samples that should be confidently classified as specific categories being mistakenly classified as confusing samples. Therefore, in order to "reclaim" these samples, this embodiment will perform a second screening of the new samples according to the steps of this invention. The second screening will combine the two prediction results of the dual clustering model (which need to be converted to the true category by the category transformation matrix obtained in step 133) to re-determine the category confidence of the new sample. If the new sample still cannot be confidently determined after joint determination by the dual clustering model, it will ultimately be identified as a confusing sample and classified as a new "intermediate state" according to the present invention.
[0105] Regarding the specific implementation of these two screening methods, as follows: Figure 2 As shown, this embodiment breaks it down into a series of calculation and judgment processes, specifically including:
[0106] Step 151: Calculate the distance between the new sample and the cluster centers of the three-class clustering model to form a distance matrix. In this embodiment, this matrix is used to reflect the similarity relationship between the new sample and each cluster center point, and is used for subsequent minimum distance difference calculation.
[0107] Step 152: Sort the distance matrix in ascending order, and extract the first two values and their corresponding true class values class1 and class2 (using the class transformation matrix obtained in step 133). The determination of class1 and class2 is crucial here.
[0108] Step 153: Determine if the absolute value of the difference between class1 and class2 is 1 (i.e., whether the true classes are adjacent). If it is 1, the new sample is a "reasonable" sample. In the three-class clustering space of this embodiment, after processing the class transformation matrix obtained in step 133, there are three classes: 0, 1, and 2, corresponding to three cluster centers, where 0 represents the least fatigued and 2 represents the most fatigued. Therefore, the sample closest to the cluster center corresponding to class1 should be the second closest to the cluster center corresponding to class1-1 or class1+1 (under reasonable circumstances, adjacent classes are close), that is, |class1-class2| should be 1 under reasonable circumstances. This "reasonable" new sample will be sent to the subsequent first screening step (step 154). If the absolute value of the difference is not 1, the new sample belongs to the "free" sample described in this invention, and its final class will be set to class1, and it will not be used for subsequent model updates.
[0109] Step 154: After being deemed "reasonable" in step 153, this embodiment will perform the first screening of the new sample. Its simplified one-dimensional schematic diagram is as follows: Figure 4 As shown. Before filtering, firstly, using class1, the distance of AD in the graph is determined using the minimum distance difference matrix of cluster centers, and then according to the formula:
[0110] TH = K × Distance(AD),
[0111] The screening threshold TH can be determined, where K is the distance calculated by multiplying the scaling factor Distance (AD) by AD. In this embodiment, K is set to 0.2. Assume the new sample point E is located at... Figure 4 When the point to the left of the shown point belongs to class1, and class1 is the class corresponding to cluster center 1, then...
[0112] Distance (DF) - Distance (AD) <TH
[0113] When the distance between the new sample point E and cluster center 2 is DF, it indicates that the new sample point E is a suspected confounding sample, where Distance(DF) is the distance between the new sample point and cluster center 2, and Distance(AD) is equal to its distance from cluster center 1. Similarly, when the new sample point E is located at... Figure 4 When the point is to the right of the midpoint, the processing approach remains the same.
[0114] Furthermore, in this embodiment, the initial screening operation after determining the screening threshold is as follows: It is determined whether the absolute value of the difference between the first two values of the sorted distance matrix obtained in step 152 is less than the threshold. If it is less than the threshold, the new sample is identified as a suspected confusing sample and sent to step 155 for secondary screening; if it is greater than the threshold, it is directly sent to step 156 for update judgment.
[0115] Step 155: For samples identified as suspected confusion samples in step 154, this embodiment will perform a second screening, specifically as follows: (1) The new sample obtains two prediction results through a dual clustering model, and obtains the true predicted categories y_true1 and y_true2 through a category transformation matrix (y_true1 corresponds to a three-class classification model, and y_true2 corresponds to a five-class classification model); (2) If the category of y_true1 is 1 and the category of y_true2 is 2, then the new sample is confirmed to be of category 1 and sent to step 156 for update judgment; (3) If the above conditions are not met, further determine whether the category of y_true1 is 0 and whether the category of y_true2 is 0. If they are met, then the new sample is confirmed to be of category 0 and sent to step 156 for update judgment; (4) If the above conditions are still not met, further determine whether the category of y_true1 is 2 and whether the category of y_true2 is 4. If they are met, then the new sample is confirmed to be of category 2 and sent to step 156 for update judgment. (5) If all the above conditions are not met, then the sample is determined to be a confused sample, and the "intermediate (class1+class2) / 2 state" is calculated first, and then the following judgment is made: (5.1) If y_true1 is less than 1 and y_true2 is greater than 2, then the final category is "intermediate state" + 1. (5.2) If the above conditions are not met, further determine whether y_true1 is greater than 1 and whether y_true2 is less than 2. If they are met, then the final category is "intermediate state" - 1. If they are still not met, then the final category is determined to be "intermediate state".
[0116] Step 156, Update Judgment: For the new sample submitted to this step, this embodiment will determine whether the sample has already been used to update the model. If it has been updated, the final category is determined to be class1 after the model update; if it has not been updated, the sample will be used to update the dual clustering model.
[0117] Step 157: Update the dual clustering model: Based on the MiniBatchKMeans clustering algorithm used in this embodiment, when a single sample is input, the cluster centers can be updated according to that sample. The update formula is as follows:
[0118]
[0119] Where x i It is the single input sample. It is the old cluster center. It is the updated cluster center, n k It is the current cluster center μ k The number of samples included, and the other variables, are the same as in step 132. This formula can be used to update the dual clustering model. By leveraging the characteristics of the MiniBatchKMeans clustering algorithm to introduce an update function, the recognition method of this invention becomes more real-time.
[0120] Step 158: Recalculate the minimum distance difference matrix between the class transition matrix and the three-class cluster centers. Because the dual clustering model has been updated, the original class transition matrix and minimum distance difference matrix also need to be updated.
[0121] Step 159: In this embodiment, after the new samples are used to update the model, they are sent back to step 151 for two more rounds of filtering. After each step, a final category is obtained. Although this second judgment increases the overhead, its impact on real-time performance is negligible. The purpose is to sacrifice some overhead for more accurate filtering and discrimination.
[0122] Preferably, to visualize the actual effect of the two screenings, this embodiment also performs a sample-by-sample two-screening process on the sample feature set used to construct the dual clustering model, such as... Figure 5 The scatter plot shows the screening results, where the cluster centers marked 'x' (cross) are circled, the normal classification samples are marked 'o' (circle), and the confused samples are marked 's' (square). Furthermore, two regions are delineated based on the approximate distribution of the confused samples. It can be seen that these two regions are located at the midpoint between the three cluster centers, which is consistent with the principle and idea of screening confused samples in this invention.
[0123] Step 160: After completing all steps in Step 150 and determining the final category of the new sample, the next step is to determine whether the new sample belongs to the continuous-time sample category. If it does not belong, the final category is directly output; if it does belong, an improved voting mechanism is initiated for final judgment, and the final voting result is output. Furthermore, by using the improved voting mechanism, the continuity characteristic of continuous-time samples can be fully utilized, combining the previous voting result with the current voting queue, thereby obtaining a smoother and more realistic judgment result.
[0124] like Figure 7 As shown, the improved voting mechanism principle diagram used in this embodiment is based on the improved voting mechanism proposed in this invention. Specifically, when a new category is input, the voting queue will make the following judgments: (1) If the queue is not full, the category will directly enter the queue, the voting result will be the input category, and it will be directly output; (2) If the queue is full, the category at the head of the queue will be removed first, then the new category will be added to the queue, and finally, the voting will be conducted according to the formula:
[0125]
[0126] The final voting score is calculated, where sum(queue) represents the sum of all elements in the queue, p represents the previous voting result, k represents the weight of the previous voting result, and L represents the queue length. In this embodiment, L = 5 and k = 1.5.
[0127] After obtaining the final voting score, the method for converting the voting score into the voting result is set by the user. In this embodiment, the specific rules are as follows: (1) When the voting score is less than or equal to 0.25, the voting category is determined to be 0; (2) When the voting score is greater than 0.25 and less than 0.75, the voting category is determined to be 0.5; (3) When the voting score is greater than or equal to 0.75 and less than or equal to 1.25, the voting category is determined to be 1; (4) When the voting score is greater than 1.25 and less than 1.75, the voting category is determined to be 1.5; (5) When the voting score is greater than or equal to 1.75, the voting category is determined to be 2.
[0128] In this embodiment, each subject was continuously collected, judged, and updated in real time during the real-time discrimination process. Therefore, each new sample is continuous in time, and an improved voting mechanism should be used for the final discrimination.
[0129] Thus, the real-time discrimination part of this embodiment, namely Figure 2 The specific steps in the right half have been thoroughly analyzed.
[0130] For example, in this embodiment, a segment of real-time continuous data collected from a subject and its corresponding subjective scale are extracted, such as... Figure 6As shown, this is used to roughly evaluate (subjective scales are highly subjective and can only roughly assess trends) the effectiveness of the multi-level muscle fatigue monitoring method based on dual clustering and confused sample screening proposed in this invention. First, Figure 6 The subjective scale records the subjects' subjective feelings at 20-second intervals, thus each recording corresponds to 40 real-time classification results (window length 2000, step size 1000, sampling frequency 2kHz). The classification results before and after voting are then shown here:
[0131]
[0132] If Figure 6 The subjective rating scale's recording levels are roughly divided into five categories (levels 6-10 correspond to 0-0.5; levels 11-14 correspond to 0.5-1; levels 15-18 correspond to 1-1.5 or 1-2; levels 19-20 correspond to 1.5-2). From the classification results without voting, it can be seen that the categories with higher frequency of occurrence in every 40 classification results generally correspond to the recording levels in the subjective rating scale. However, due to the nonlinear and restorative characteristics of fatigue, the classification results exhibit some fluctuation within a 1-second window. After processing with the improved voting mechanism, the classification results are smoother and basically match the recording levels in the subjective rating scale. In summary, the effectiveness of this invention has been evaluated and verified.
[0133] As an application example, this example provides a multi-level muscle fatigue monitoring method based on dual clustering and confused sample screening, which is specifically applicable to scenarios of continuous static contraction of local muscles and can be widely used in occupational health, sports rehabilitation and other fields.
[0134] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the present invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.
[0135] The above embodiments are merely illustrative of the technical concept and features of the present invention, and are intended to enable those skilled in the art to understand the content of the present invention and implement it accordingly. They should not be construed as limiting the scope of protection of the present invention. All equivalent changes or modifications made based on the essence of the content of the present invention should be covered within the scope of protection of the present invention.
Claims
1. A multi-stage muscle fatigue monitoring method, characterized by, The method comprises the steps of: Collecting multi-channel raw electromyography signals of local muscles during continuous dynamic or static contraction until fatigue, to form a raw signal sequence; Preprocessing the raw signal sequence and extracting multi-channel medium frequency features to obtain a medium frequency feature sequence; Based on the medium frequency feature sequence, a double clustering model is constructed, wherein the double clustering model is constructed, specifically including: based on the medium frequency feature sequence, the process of local muscles continuously contracting until fatigue is divided to obtain an initial classification level and a fine classification level, the initial classification level contains N muscle fatigue categories, and the fine classification level contains M muscle fatigue categories, M>N; the MiniBatchKMeans algorithm is used to generate the clustering centers of the initial classification level, the intermediate clustering centers of the fine classification level are obtained through the insertion operation, and the first clustering model is generated based on the clustering centers of the initial classification level; the second clustering model is generated based on the clustering centers of the initial classification level and the intermediate clustering centers of the fine classification level, the first clustering model and the second clustering model are taken as the double clustering model; the class conversion matrix of the first clustering model and the second clustering model and the minimum distance difference matrix of the clustering centers of the first clustering model are determined, Wherein, the class conversion matrix of the first clustering model and the second clustering model is determined, specifically including: summing up the medium frequency features of each channel of the clustering centers of the double clustering model respectively, and sorting them from large to small respectively to obtain an index matrix, the index matrix represents the relationship between the clustering labels output by the double clustering model and the real muscle fatigue categories, a relationship dictionary between the clustering labels output by the double clustering model and the real muscle fatigue categories is determined according to the index matrix, and the class conversion matrix is converted according to the relationship dictionary; The minimum distance difference matrix of the clustering centers is determined, specifically including: traversing the clustering centers of the first clustering model, calculating the distance between the current clustering center and other clustering centers and the distance between the current clustering center and itself, sorting the distance values from small to large, traversing the sorted distance values, screening out the minimum distance and the second minimum distance adjacent to the real muscle fatigue categories, and calculating the minimum distance difference of the current clustering center by subtracting the minimum distance from the second minimum distance. After the traversal is completed, the minimum distance difference matrix is obtained; Real-time collecting multi-channel electromyography signals of the same local muscles during continuous dynamic or static contraction until fatigue, preprocessing the multi-channel electromyography signals and extracting multi-channel medium frequency features to obtain a real-time sample feature sequence; Using the double clustering model, the real-time sample feature sequence is screened for confused samples to obtain a muscle fatigue monitoring result.
2. The multi-stage muscle fatigue monitoring method of claim 1, wherein, Using the double clustering model, the real-time sample feature sequence is screened for confused samples to obtain a muscle fatigue monitoring result, specifically including: The real-time sample feature sequence is input into the double clustering model to obtain the predicted class y1 of the first clustering model and the predicted class y2 of the second clustering model; The distance between the real-time sample feature sequence and all clustering centers of the first clustering model is calculated, the distance values are sorted from small to large, the sorted distance values are traversed, the minimum distance and the second minimum distance are screened out, and the sample distance difference is obtained by subtracting the minimum distance from the second minimum distance. Based on the predicted category y1, a corresponding cluster center is determined, through which a cluster center minimum distance difference matrix of the first cluster model is indexed, the distance between the cluster center and its nearest neighboring cluster center is obtained, and a center distance difference is obtained. The center distance difference is multiplied by a preset ratio to obtain a screening threshold. The first screening is performed according to the relationship between the sample distance difference and the screening threshold, and non-confusion samples or suspected confusion samples are obtained. The suspected confusion samples are then subjected to the second screening in combination with the predicted category y2, and confusion samples or non-confusion samples are determined. The confusion samples output an intermediate state category. The non-confusion samples are used to update the dual cluster model, the category conversion matrix and the cluster center minimum distance difference matrix, and the final category is output through the above-mentioned first screening and second screening. The final category and the intermediate state category are taken as the muscle fatigue monitoring result.
3. The multi-stage muscle fatigue monitoring method of claim 2, wherein, The suspected confusion samples are subjected to the second screening in combination with the dual cluster model, and specifically include: When the predicted category y1 and the predicted category y2 are the lowest or highest category of the respective cluster model, the category of the real-time sample feature sequence can be determined as the predicted category y1; when the predicted category y1 and the predicted category y2 are the intermediate category of the respective cluster model, the category of the real-time sample feature sequence can also be determined as the predicted category y1; If other conditions occur, it indicates that the category of the real-time sample is a transition category between two categories, and the real-time sample feature sequence is determined as a confusion sample.
4. The multi-stage muscle fatigue monitoring method of claim 2, wherein, The suspected confusion samples are subjected to the second screening in combination with the dual cluster model, and specifically include: The real-time sample feature sequence is input into the first cluster model and the second cluster model, respectively, two predicted categories are obtained through the category conversion matrix, which are y_true1 and y_true2, the initial classification level includes k_down muscle fatigue degrees, and the fine classification level includes k_up muscle fatigue degrees, When the following three conditions are not met, the real-time sample feature sequence is determined as a confusion sample: (1) y_true1 is equal to the integer part of (k_down / 2) and y_true2 is equal to the integer part of (k_up / 2); (2) y_true1 is equal to 0 and y_true2 is equal to 0; (3) y_true1 is equal to k_down-1 and y_true2 is equal to k_up-1; Otherwise, the real-time sample feature sequence is determined as a non-confusion sample.
5. The multi-stage muscle fatigue monitoring method of claim 4, wherein, The confusion sample outputs an intermediate state category, and specifically includes: The distances between the real-time sample feature sequence and all cluster centers of the first clustering model are calculated, the distance values are sorted in ascending order, the sorted distance values are traversed, and the real muscle fatigue categories corresponding to the minimum distance and the second minimum distance are filtered out as class1 and class2, and the "intermediate state" is and the following judgment is made: ① Determine whether y_true1 is less than the integer part of (k_down / 2) and y_true2 is greater than the integer part of (k_up / 2); if the conditions are met, the final category is "intermediate state" + 1; ② Determine whether y_true1 is greater than the integer part of (k_down / 2) and y_true2 is less than the integer part of (k_up / 2); if the conditions are met, the final category is "intermediate state" - 1; if the above conditions ① and ② are not met, the final category is "intermediate state"; The result of "intermediate state" is taken as the intermediate state category.
6. The multi-stage muscle fatigue monitoring method of claim 2, wherein, The non-confusion sample is used for updating a dual clustering model, a category conversion matrix and a clustering center minimum distance difference matrix, and specifically comprises: The non-confusion sample is updated by a preset formula, , wherein is the current input single sample, is the old cluster center, is the updated cluster center, is the current cluster center the number of samples contained.
7. The multi-stage muscle fatigue monitoring method according to claim 1, characterized in that, When the real-time sample feature sequence is a continuous time sample, an improved voting mechanism is used to process the intermediate state category or the final category to obtain a final muscle fatigue monitoring result.
Citation Information
Patent Citations
Muscle fatigue recognition method fusing electromyographic signal multi-fractal and LSTM (Long Short Term Memory)
CN116244584A
Classification of musculoskeletal form using machine learning model
US20200051446A1