Aerobic Exercise Fatigue Detection Based on Spatiotemporal Entropy and Label Technology

Excessive exercise can strengthen the body and make people happy, but it can also cause physical injury. To address this issue, this paper proposes the TFD-SE (Three-Frame Diﬀerence Spatiotemporal Entropy) algorithm and the LB (Label Propagation) algorithm, which are both based on SE (spatiotemporal entropy) and label technology. The TFD-SE algorithm calculates the diﬀerence image using the three-frame diﬀerence method, then calculates the SE of pixels in the diﬀerence image, and performs morphological ﬁltering and threshold segmentation, allowing it to detect moving objects eﬀectively. The signiﬁcance value of unlabeled nodes in the image is calculated using the LB algorithm. In both qualitative and quantitative comparisons, the experimental results show that both algorithms outperform other classical algorithms in terms of detection performance.


Introduction
Fatigue is caused by a variety of factors. Fatigue can be classified into four different categories [1][2][3]: according to the first classification, fatigue is a transitional state between waking and sleeping with no clear distinction between the two; according to the second classification, fatigue is divided into psychological and physiological fatigue; the third type of fatigue is divided into four categories: psychological, pathological, mental, and physical fatigue; and the fourth classification is based on the most common clinical fatigue symptoms. Athletes and soldiers are two examples of occupations that require extensive sports training on a daily basis. Overtraining weakens the training effect while also increasing the risk of more serious side effects such as syncope, muscle injury, and even sudden death [4]. As a result, sports fatigue detection is critical for human safety.
ere are two parts to sports fatigue detection: sports data acquisition and data-driven recognition algorithm [5].
Aerobic exercise fatigue detection plays an important role in the fields of biological identification, biological monitoring, production, and breeding. In recent years, many methods have been put forward to solve this problem. Among them, the background subtraction method is one of the most commonly used detection methods [6,7]. It subtracts the background frame from the current video frame and then selects a suitable threshold for binarization of the obtained image, so as to extract the moving target. Entropy is the representation of average information, which was first introduced in informatics. Knowledge about entropy has been widely used in the field of image segmentation [8,9]. e edge-based method is considered more suitable for semantic video image segmentation. Because people are very sensitive to the edges of moving objects, the effect of extracting the edges of moving objects from the background largely depends on the preset threshold [10]. Because different image sequences contain different image components and their variable characteristics are obviously different, any preset fixed threshold value is not suitable for aerobic exercise fatigue detection. Affected by physical factors such as friction and slippage, the shape and position of the sensor will cause errors in the data acquisition process, which will reduce the accuracy of the recognition algorithm and fail to get satisfactory results.
To detect aerobic exercise fatigue, this paper uses a combination of SE (spatiotemporal entropy) and labeling technology. e moving target can be detected directly by subtracting the current frame image from the background to obtain the difference image and then calculating the SE of the difference image. is method uses entropy to reflect the strength of biological fatigue and, when combined with label technology, reduces the algorithm's calculation time. is algorithm has low computational complexity, strong parameter robustness, and a clear target and is an effective biological aerobic exercise fatigue detection method when compared to the traditional SE method.

Related Work
In recent years, research on human fatigue at home and abroad, especially the research on the influence of fatigue on fatigue, has been increasing year by year. In [11] by comparing with the data of healthy people, it is found that the symmetry of the two parameters and the linear relationship between them are quite different. Literature [12] proves that the muscle imbalance in the lateral and middle parts of the lower leg under fatigue is related to the lateral deviation on the floor of the dynamometer. In literature [13], through running on the vertical pressure plate, the impact speed and pressure are obtained. e results showed that the peak acceleration of the tibia and the acceleration of the shoe upper decreased significantly. Literature [14] studied the characteristic changes of HRV (heart rate variability) of the subjects when riding a power bicycle and found that with the deepening of exercise, the peak value of the high-frequency power of HRV gradually increased from 0.25 Hz to 0.6 Hz, which indicated that the main energy of HRV would gradually shift to the right during exercise. Literature [15] used HRV to study different types of fatigue in healthy people and achieved good results. Literature [16] studied the change in the power spectrum of surface EMG (electromyography) signals before and after fatigue under constant static load and found that the power spectrum after fatigue shifted to the left compared with the whole and peak value before fatigue. Literature [17] found that the one-dimensional EMG time series has chaotic characteristics. ey calculated the information entropy of various EMG signals in the reconstructed two-dimensional phase space and analyzed the obtained results to determine the law between muscles and movements. In literature [18], using quantitative recursive analysis, it was found that the percentage of a deterministic segment of sEMG (surface electromyography signal) of biceps brachii continuously increased during exercise fatigue, and it was more sensitive than the change of median frequency MF (median frequency) with fatigue.
On the basis of SE, literature [19] proposes an algorithm for detecting human aerobic exercise fatigue. is method establishes a histogram to calculate the SE value of each pixel point and uses that value to determine whether the pixel point belongs to a moving target. An aerobic exercise fatigue detection algorithm based on entropy map and adaptive state label technology was proposed in the literature [20]. Literature [21] proposed a "center-surround" model, which was realized by using the spatial pyramid's local feature contrast of color, brightness, and direction. Despite the fact that the eye movement point prediction model is the origin of significance detection and has made significant progress, each of these methods has a flaw that will affect their performance in practice. To calculate saliency value, the literature [22] uses histogram information from the image luminance channel. For the first time, literature [23] introduced the saliency filter and used a high-dimensional Gaussian filter to fully express the contrast and saliency measurement standard. To detect salient targets, literature [24] fuses various prior information into conditional random fields. e contrast of the center surrounding the histogram, the spectral residual, and the color space distribution are among the prior data. Literature [25] integrates the appearance information alongside the spatial prior information to calculate the significance value of each pixel in the image one by one. ese comparison-based methods are simple to use and calculate, but the results are not always ideal when dealing with complex backgrounds.

SE-Based Aerobic Exercise Fatigue Detection.
Fatigue is a kind of discomfort felt by human beings. It is a kind of feeling after a great deal of physical or mental work. It will reduce people's ability to finish work. When exercise fatigue occurs, the athlete's heart load will increase continuously, becoming more irritable and irritable than usual, muscle soreness and flexibility will decrease, and the necessary thinking ability in competitive sports such as judgment and reaction will also decrease [3]. erefore, sports fatigue is a comprehensive physical and mental fatigue with mental, psychological, and physical strength.
As the human body's environment will change greatly during exercise, many physiological indexes of the human body will also change greatly. Among these indexes, which can be more related to the changing trend of human body fatigue, and how to select and calculate these indexes to better monitor and analyze human body exercise fatigue is still under in-depth study. In traditional sports fatigue assessments, the subjective (psychological) assessment method is often used to estimate the fatigue degree of the human body quickly, directly, and effectively. However, because sports fatigue is a complicated process, it lacks objectivity only through subjective evaluation, and it is difficult to analyze and evaluate it comprehensively and accurately.
State recognition has garnered a lot of interest as a new recognition technology. When people walk, the term "Li state" refers to the overall movement state of all body parts at any given time.
e size of the step, the degree of body shaking, and the habit of exertion are all different aspects of walking posture. e purpose of state recognition is to determine a person's identity based on their distinctive walking posture. Walking is a movement in which both legs alternately push and cushion the ground. e body's acceleration changes over time during a period of walking.
ere will be turning points in the acceleration signal, such as maximum and minimum when the lower limb is initially grounded, buffered, and pedaled. Entropy is a measure of how much information is contained in a piece of data in information theory. When entropy is at its maximum, the amount of information obtained is at its greatest.
If a random experiment has N possible results or a random message has N possible values, and the probability of their occurrence is, respectively p 1 , p 2 , . . . , p n , then the information amount of these events, that is, entropy, is defined as (1) Because entropy is a measure of information size, which indicates the degree of diversity of an event, entropy can be used to characterize the diversity of pixel states and then reflect the degree of motion intensity of pixel points.
An effective method of aerobic exercise fatigue detection must establish the corresponding relationship of moving targets along the time axis. At the same time, because moving targets not only have the temporal correlation of the moving areas but also have the correlation of spatial gray values, the 2D threshold is extended to detect meaningful aerobic exercise fatigue in the time domain.
In this paper, an aerobic exercise fatigue detection algorithm based on TFD-SE (three-frame difference spatialtemporal entropy) is proposed. e algorithm uses the threeframe difference method to get the difference image of video image sequence and uses the SE principle to detect aerobic exercise fatigue in the difference image. In the process of fatigue detection, first, divide the image sequence into 3×3 blocks and calculate the interframe contrast FCON and local variance LCON of the image sequence for each block. e probability density distribution of each pixel in the video can be obtained by calculating its histogram. According to the distribution probability of a pixel on the time axis, and the distribution probability of the pixel in space is obtained by spatial coordinates, the sampling space shown in Figure 1 is established in this paper.
Interframe contrast indicates the continuity of pixel gray levels in the same position in different frames in time direction, defined as follows: in which I(x, y, t n ) represents the gray value of the (x, y) position of the current block and I(x, y, t p ) represents the gray value of the current (x, y) block position of the reference image. e continuity of gray values of adjacent pixels in the same frame is represented by local variance, defined as follows: where MEAN(m) � (1/9) 2 x�0 2 y�0 I(x, y, t n ) is the average pixel gray value of the current block.
Calculating the histogram of an image yields the probability density distribution of each pixel. To calculate the histogram distribution of the pixel, a sliding window in time and space is used. e pixel's spatial variation and their variation over time are both represented in the sliding window.
After obtaining the histogram of each pixel, the probability density distribution of pixel (i, j) can be obtained by the following formula: where N is the sum of pixels in the rectangular window, that is, N � L × W × W. e probability density of each pixel can be obtained, and the entropy of each pixel can be calculated by (5) to obtain the SE image.
SE reflects the change of each pixel in the image in time and space. If the pixel belongs to the foreground target, E i,j is large, and if the pixel belongs to the background, E i,j is small. erefore, it can be judged whether the pixel is the foreground target by taking a certain threshold of the entropy image.
e flow of the algorithm is shown in Figure 2. To begin, edge extraction of video images is performed to obtain three consecutive frames of edge images, after which three frames of difference operations are performed on the  Scientific Programming three consecutive frames of edge images to obtain a difference image, a two-dimensional histogram of the difference image is established, the SE of the difference image is calculated, and finally, binarization and morphological processing complete the target extraction.

LB Aerobic Exercise Fatigue Detection.
e existing methods of aerobic exercise fatigue detection are basically bottom-up data-driven, and the basic framework is to first define the measurement standards of saliency and then analyze the salient areas or basic pixel units in the image according to these standards, so as to detect the salient targets. ese methods mainly use the feature information of salient targets to determine the measurement standard, or some methods detect salient targets according to the feature information of background areas.
In this paper, consider combining these two methods according to the different features information of the salient target and the background area and using the principle of LB (label propagation) to get the corresponding salient maps, respectively, and then fuse the salient maps through an improved Bayesian model to get the final detection result. Figure 3 is the algorithm flow chart of this paper. e LB algorithm is a semisupervised learning algorithm in a graph model. Its basic idea is to use labeled nodes as label nodes and estimate the unlabeled node information based on the propagation mechanism of the graph model. When the iteration ends, the propagation probability distribution of similar nodes is often similar. e nodes with high similarity are classified into the same class, and then the LB process ends. People generally do not focus their visual attention on the edge of the image. e salient objects in the original image basically do not touch the edge of the image. erefore, in this paper, the boundary node of the image is used as the seed node of background propagation, that is to say, the boundary node is used as the marked data to LB all other remaining nodes, so as to obtain the similarity measure between the remaining superpixels and the label superpixels, thus obtaining the saliency map based on the background prior information.
In order to meet the measure of significance, this paper needs to normalize the vector to the range of [0, 1]. erefore, according to the propagation formula, the saliency map using background prior as label node can be calculated, and the saliency value S b (i) of superpixel node is defined as where i represents a superpixel node in the image and y * represents a normalized vector. Because the background node is used as the label node in the LB process, the label value of the background area needs to be set to 1.
In most cases, good results can be obtained through the spread of background tags. However, in some images with complex background or low color contrast between foreground and background, the detection results obtained by background prior propagation are not ideal, and a large number of background areas are mistaken for significant targets. Now, use the foreground target as a label node, so the label vector is known. According to the propagation formula, vector S is normalized to the range of [0, 1], and then the saliency map using the foreground prior information as the label node is obtained. en the saliency value S f (i) of the superpixel node is defined as e object-like score is mapped to each pixel using the position relationship and the Gaussian kernel function. Finally, by adding and averaging each superpixel's objectlike score, some superpixels with higher object-like scores are chosen as reliable foreground label nodes. is paper converts the saliency map from superpixel level to pixel level before Bayesian fusion for calculation accuracy, which increases computational complexity but yields better detection results.
e formula for calculating the saliency map of pixel level is as follows: Among them, S(r i ) represents the saliency map of superpixel level, c p , c i , z p , z i represent the color feature and coordinate vector of pixel p or superpixel area i, respectively, G represents the number of areas directly adjacent to super pixel area r i , and Q i represents the normalization parameter. k 1 , k 2 are parameters that control color and position sensitivity.  In this paper, according to the foreground prior and background prior, errors will inevitably occur when selecting tag data, which will lead to inaccurate target detection after passing LB. However, use Bayesian fusion to combine the two propagation results, use the complementary relationship between background information and foreground information, improve the accuracy of the detection target through background LB, and effectively suppress the background area through foreground LB, and finally get the ideal detection effect.

Results Analysis and Discussion
Long-term aerobic exercise causes the body temperature to rise and the body heat to rise sharply. To keep the body from overheating, a lot of perspiration and heat dissipation is used to keep the body temperature balanced. e majority of the water lost through perspiration is water which comes primarily from plasma, intercellular fluid, and the intracellular fluid body. Dehydration will occur if water is not replenished in a timely manner, which will have a significant impact on exercise ability. When a person's water loss reaches 2% of their body weight, their working ability drops by 10% to 15%, and when it reaches 5% of their body weight, the athlete's sports ability drops by 10% to 30%.
In this section, the identification model for sports fatigue is constructed by the TFD-SE algorithm and its classification accuracy is tested. First, train the fatigue identification model with ECG (electrocardiogram) and EMG features, respectively, and check the accuracy, and then train and check with EMG feature fusion. Figures 4-6 are statistical results of the classification accuracy of the TFD-SE fatigue identification model constructed by three modes of EMG, ECG, and myocardial electrical feature fusion under a 50% cross-test. Figure 6 shows that the recognition model trained on ECG and EMG features has a stable comprehensive classification performance and good recognition ability for three types of fatigue states. As a result, the TFD-SE recognition model trained with myocardial electrical feature fusion outperforms the TFD-SE recognition model trained with ECG and EMG features.
Skeletal muscles generate a lot of heat when they are worked hard for a long time. e body will increase heat dissipation to the external environment in order to maintain a constant body temperature. Heat can only be dissipated through perspiration, especially during high-temperature seasons when the environment temperature is higher than the body temperature. e body will sweat a lot at this time, and a lot of electrolytes will be lost through sweat, resulting in electrolyte disorder, abnormal neuromuscular excitability, muscle spasms, and decreased exercise capacity. To demonstrate the effectiveness and comparability of the fusion strategy in this section, the unweighted fusion strategy corresponding to the Chinese style in this section is used separately based on tracking with the same features within the framework of the algorithm in this section, and the tracking error is shown in Figure 7.
e time cost of this algorithm mainly focuses on the extraction of each feature and the calculation of similarity, which is directly related to the size of the target and the number of particles. e larger the target, the more particles are obtained and the more time is spent. erefore, for larger targets, the calculation time can be reduced by sampling the target and reducing the resolution.
Correcting dehydration and providing energy soon after aerobic exercise can help you recover faster. e total amount of liquid and electrolytes lost during exercise should  be recovered effectively. To obtain rapid hydration, it is best to consume a sugar-electrolyte beverage after exercise. e sugar content of the beverage can range from 5% to 10%, and the sodium salt content can range from 30 to 40 milligrams equivalent. Vitamin C is an important hydrogen donor in the biological oxidation process, so it is important for aerobic endurance exercise as well. It can speed up the oxidation-reduction reaction in the body, allowing the body to gain more energy and thus improve exercise performance. As a result, taking vitamins after exercise can help to alleviate fatigue symptoms and delay the onset of exercise-induced fatigue.
In order to make this model more convincing in its aerobic exercise fatigue detection performance, compare it with other existing classic algorithms. In this paper, the F-measure value, recall rate, and AUC (area under the curve) value of these aerobic exercise fatigue detection algorithms will be evaluated on the ASD image database. e results are shown in Figures 8-10. e accuracy-recall curves of different models are shown in Figure 8. e model in this paper can achieve an accuracy of 0.96 in most range of recall rate and is obviously superior to most detection models. e detection effect of literature [18] is close to that of this model, and the detection performance is slightly higher only in some parts with a low recall rate.
Many isolated small areas and gaps often appear in the binarized image, which will affect the extraction of moving objects. erefore, the isolated small areas in the binarized image are removed by the image morphology method, and the small gaps are filled at the same time. In morphological processing of binary images, firstly, the isolated small areas are removed by the corrosion operation, and then the small gaps are filled by the expansion operation. On the one hand, it can eliminate noise, and on the other hand, it can smooth the image so that the moving target can be completely detected. Figure 9 shows the average accuracy rate-recall rate and f-measure value of different models. It can be seen that the average accuracy and F-measure value of this method can reach 9.4 and 8.8, respectively, which is also better than other methods.
It has been established that when the human body participates in high-intensity sports, the strength is primarily maintained by an increase in the central nervous system impulse frequency [16], and the central nervous system constantly sends out high-frequency impulses during the movement. Due to the abrupt change in illumination, color and texture features lose their tracking performance when pedestrians pass through the illumination area. Despite the fact that edge features are less affected by illumination, they lose   Scientific Programming their effectiveness due to strong edge interference from object shadows in the illumination area, as the literature [21] shows. Although the algorithm in this section is affected by the same influence, it also introduces the motion feature, which effectively distinguishes the moving pedestrian from the static background, allowing the tracking algorithm in this section to reliably track the target throughout the sequence. e texture features are a good supplement when there is background interference. When the head rotates out of the plane, the color and texture features change abruptly, whereas the edge features can effectively capture the head's contour occlusion, which has not changed significantly. Many features are affected to varying degrees when the occlusion occurs due to the various positions and degrees of occlusion, but after fusion, the tracking effect remains stable and effective. Figure 10 shows the comparison of the AUC values of different models. Aerobic exercise fatigue detection can be simply understood as a second-class classification problem, the purpose of which is to distinguish the prominent target from the background. e AUC value reflects the performance of this classification model. It can be seen from the figure that the AUC value of this model is slightly higher than those of other models and has reached 0.935.
It can be seen from the figure that highlights appear in some background areas. is is because there is no internal connection between the nodes in the background area of the image, which makes the detection algorithm unable to effectively distinguish the background area from the salient objects. After adding thegeodesic constraint, the connection between boundary areas is strengthened, and some obvious targets are not detected by using only one layer of neighbor nodes. is is because the neighbor nodes in the first layer did not make full use of the spatial information in the image, which led to missing some targets in aerobic exercise fatigue detection. However, if all the image nodes were regarded as neighbor's nodes, it would not only increase the amount of calculation, but also reduce the detection effect. e results obtained by the LB formula have been able to detect remarkable targets well in this paper, using the characteristics of boundary prior and geodesic constraints. e background tag nodes are then hoof selected, and the contact boundary of obvious targets is minimized as much as possible, making the method more robust in this paper. Bayesian fusion takes advantage of the complementary relationship between background and foreground prior information to effectively suppress background noise while uniformly highlighting the prominent targets.
e results of the experiments show that applying the entropy principle in informatics to the field of biological aerobic exercise fatigue detection is feasible and effective, and that it effectively improves and solves the problems of irregular movement and slow detection speed of biological targets in fatigue detection, as well as corroborates the theoretical basis that entropy can reflect the strength of moving targets. is method has a low algorithm complexity, strong parameter robustness, and superior antinoise ability when compared to the traditional aerobic exercise fatigue detection method. It is a reliable biological method for detecting aerobic exercise fatigue that can be applied to biological identification, biological monitoring, and other fields.

Conclusion
e detection of aerobic exercise fatigue is investigated in this paper using SE and tag technology, which collects and processes human gait acceleration signals. e TFD-SE is Literature [21] Literature [18] LB Model

Recall Accuracy
Overlap F-measure  Scientific Programming used to propose a new algorithm for detecting aerobic exercise fatigue. e results of the experiments show that using entropy-related principles in informatics to detect aerobic exercise fatigue is feasible and effective. Saliency maps based on foreground information propagation and saliency maps based on background information propagation can both be obtained using the LB algorithm at the same time. e saliency map generated by this model can effectively suppress background noise and highlight saliency targets uniformly and accurately, as evidenced by comparisons of visual effect maps. e relationship between EEG and exercise fatigue is only explored in a broad sense in this paper. In the future, more research and excavation will be done on this topic.

Data Availability
e data used to support the findings of this study are included within the article.

Conflicts of Interest
All the authors do not have any possible conflicts of interest.