A machine learning-based automatic classification method for traditional Chinese medicine constitution
By extracting and caching features from photoplethysmography pulse waves, skin temperature, and triaxial acceleration sequences, and combining phase difference scalars and signal-to-noise ratio weighting coefficients to modulate model parameters, the noise interference problem in multimodal time series data processing of machine learning models is solved, thereby improving the accuracy and robustness of automatic TCM constitution classification.
Patent Information
- Application Number
- CN202611251792.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-18
- Publication Date
- 2026-11-20
AI Technical Summary
Existing machine learning models, when processing multimodal time-series data, lack a mechanism to compensate for transient impulse noise, leading to initial feature coordinate shifts, neglecting periodic oscillation properties resulting in feature fusion misalignment, and rigid covariance measurement scales causing low signal-to-noise ratio data to interfere with global clustering, resulting in incorrect classification label output.
By acquiring photoplethysmography pulse wave, skin temperature and triaxial acceleration sequences, downsampling and buffering are performed to extract the pulse wave step sequence and acceleration energy integral, calculate the recovery attenuation scalar, and use the phase difference scalar and signal-to-noise ratio weight coefficient to modulate the inverse covariance matrix of the machine learning model, adaptively adjusting the feature coordinates and distance metric.
It effectively eliminates feature coordinate offset caused by transient impulse noise, reduces the probability of multimodal feature misalignment, improves the model's classification robustness in dynamic noise environments, and reduces the false alarm rate.
Smart Images

Figure CN123138909A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of natural language processing technology, and in particular to an automatic classification method for traditional Chinese medicine constitution based on machine learning. Background Technology
[0002] Existing technologies, when using machine learning models to automatically classify TCM constitution states, typically collect multimodal time-series data such as photoplethysmography (PPG) and body temperature at fixed time intervals, and input this data into a classification network for feature mapping and result output. However, in actual model deployment and edge computing node operation scenarios, the following data processing deficiencies exist: First, edge nodes inevitably introduce transient impulse noise caused by mechanical perturbations when collecting time-series data. Conventional feature extraction networks do not establish a correlation compensation mechanism between the perturbation physical quantity and the attenuation characteristics of the input signal. The transient impulse noise will be misjudged by the model as a sudden change in the true feature, causing the initial feature vector to shift in the embedding space.
[0003] Secondly, modal data of different dimensions (such as body temperature and heart rate variability) have inherent asynchronous periodic oscillation properties. Conventional models directly extract multi-source features under the same static timestamp for forced alignment, ignoring the temporal phase difference between multimodal data, which causes feature misalignment of heterogeneous data in the input fusion layer and destroys the temporal correlation of feature tensors.
[0004] Finally, during long-term inference, the background noise of the input data will dynamically change with the hardware status. If the covariance matrix in the classification model maintains a static parameter setting, when receiving low-signal-to-noise ratio, poor-quality data blocks, the model cannot adaptively adjust the spatial distance metric scale, causing local high-frequency background noise to interfere with global feature clustering, resulting in a significant increase in the false alarm rate of the centroid optimization result of the classification model. Summary of the Invention
[0005] This invention provides a machine learning-based automatic classification method for TCM constitution, which addresses the technical problems of existing machine learning models when processing multimodal time-series data. These problems include the lack of a mechanism to compensate for transient impulse noise, leading to initial feature coordinate shifts; the neglect of periodic oscillation attributes, resulting in feature fusion misalignment; and the rigidity of the covariance metric, causing low signal-to-noise ratio data to interfere with global clustering results, ultimately resulting in incorrect model classification label output.
[0006] In view of the above problems, the present invention provides an automatic classification method for TCM constitution based on machine learning, comprising the following steps: Acquire photoplethysmography (PPG) sequences, skin temperature sequences, and triaxial acceleration sequences containing global timestamps; The skin temperature sequence and the heart rate variability sequence extracted from the photoplethysmography pulse wave sequence are downsampled and buffered with a first sampling period to generate downsampled low-frequency sequence pairs; at the same time, when the scalar value of the triaxial acceleration sequence exceeds a first acceleration threshold, a target time window index is generated, and the pulse wave step sequence is directionally truncated based on the target time window index. Extract the attenuation features of the pulse wave step sequence as it falls from the peak, and obtain the acceleration energy integral within the interval corresponding to the target time window index. Based on the attenuation features and the acceleration energy integral, calculate the recovery attenuation scalar. The fundamental components of the two sequences in the downsampled low-frequency sequence pair are extracted respectively, and the cross-correlation of the fundamental components on the time axis is performed to generate a phase difference scalar. The phase difference scalar is used to perform modulation calculation on the recovery attenuation scalar to generate a compliance feature index; the compliance feature index is used as feature coordinates and input into a pre-deployed machine learning classification model to calculate the spatial distance between the feature coordinates and the preset reference centroid in the machine learning classification model, and a TCM constitution classification label instruction is generated based on the spatial distance.
[0007] The technical solution provided in this application has at least the following technical effects: To address the issue of transient impulse noise interference feature extraction, this scheme generates a target time window index when the scalar value of the triaxial acceleration sequence exceeds a first acceleration threshold, and extracts the pulse wave step sequence accordingly. The recovered attenuation scalar is calculated by combining the acceleration energy integral with the pulse wave features. This step substitutes the physical quantity characterizing the perturbation intensity into the hyperbolic tangent operator for saturation mapping compensation, correcting the attenuation slope calculation deviation caused by transient impulse noise and eliminating the coordinate offset of the initial feature vector in the embedding space from the source.
[0008] To address the issue of temporal misalignment in multimodal features, this scheme extracts the fundamental component of downsampled low-frequency sequence pairs, performs cross-correlation calculations to generate a phase difference scalar, and combines this with the intraday hourly count and a reference phase angle constant to generate a temporal bias. This bias is then input into an exponential decay operator to generate a phase compensation multiplier. This step utilizes the dynamic phase difference and a periodic function to perform adaptive nonlinear multiplicative scaling on the recovered decay scalar, thereby aligning heterogeneous features with periodic oscillation properties on the time axis and reducing the probability of feature misalignment in the input fusion layer of multimodal data.
[0009] To address the issue of rigid distance metric scales in models, this scheme calculates contact quality parameters by extracting the AC and DC component amplitudes of the photoplethysmography (PPG) pulse wave sequence. Signal-to-noise ratio (SNR) weighting coefficients are then generated based on the body motion frequency, and these dynamic coefficients are used to directly modulate the inverse covariance matrix in the machine learning model. This step enables the machine learning classification model to dynamically shrink or expand the spatial distance weights of the corresponding dimension based on the SNR of the current data block when performing weighted Mahalanobis distance calculations. This automatically reduces the interference of poor-quality input data on the global centroid optimization results, improving the model's robustness in dynamically noisy environments. Attached Figure Description
[0010] Figure 1 A flowchart of an automatic TCM constitution classification method based on machine learning provided in an embodiment of the present invention; Figure 2 This is a hardware topology diagram of the present invention. Detailed Implementation
[0011] The above technical solutions will now be described in detail with reference to the accompanying drawings and specific embodiments to provide a better understanding of them. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. It should be understood that the present invention is not limited to the exemplary embodiments used only to explain the present invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention. Furthermore, it should be noted that, for ease of description, only the parts related to the present invention are shown in the drawings, not all of them.
[0012] Example: Please refer to Figure 1 and Figure 2 The basic physical architecture of the TCM constitution automatic classification system consists of physiological signal acquisition nodes and state calculation nodes. The physiological signal acquisition nodes establish a communication connection with the state calculation nodes through a data transmission link. Each physiological signal acquisition node is internally equipped with a battery module and a microprocessor. Due to limitations in microprocessor computing power and battery module power reserves, the signal processing mechanism within the physiological signal acquisition node employs a dual-track architecture of downsampling and perturbation event wake-up.
[0013] Upon system power-on initialization, the physiological signal acquisition node activates its sensor array, continuously acquiring photoplethysmography (PPG) sequences, skin temperature sequences, and triaxial acceleration sequences, all containing global timestamps. Simultaneously, the data distribution and scheduling rules are activated. The state resolution node performs downsampling and buffering operations on the skin temperature sequence and the heart rate variability sequence extracted from the PPG sequence at the first sampling period, generating downsampled low-frequency sequence pairs. Simultaneously with the generation of these downsampled low-frequency sequence pairs, the state resolution node continuously monitors the scalar value of the triaxial acceleration sequence. When the scalar value of the triaxial acceleration sequence exceeds a first acceleration threshold, the state resolution node generates a target time window index and directionally extracts the pulse wave step sequence based on this index.
[0014] After the pulse wave step sequence is directionally truncated, the state solver node extracts the attenuation characteristics of the pulse wave step sequence as it falls from the peak, and calculates the recovered attenuation scalar by combining this with the acceleration energy integral within the corresponding interval of the acquired target time window index. After generating the recovered attenuation scalar, the state solver node calculates the fundamental component of the downsampled low-frequency sequence pair to obtain the phase difference scalar. The phase difference scalar is then used to modulate the recovered attenuation scalar to generate a compliance feature index. This compliance feature index, as feature coordinates, is input into a pre-deployed machine learning classification model, mapping and outputting a TCM constitution classification label instruction.
[0015] Triggered by the generation of downsampled low-frequency sequence pairs and the directional truncation of pulse wave step sequences, the state resolution node establishes a dual-track circular buffer within its memory. This buffer contains a low-frequency buffer track and a high-frequency buffer track. For the low-frequency buffer track, the state resolution node performs mean thinning on the skin temperature and heart rate variability sequences during the first sampling period. The parameter configuration for the first sampling period is pre-calibrated based on the physiological rate of change of low-frequency physiological signals such as skin temperature and heart rate variability. The time series data after mean thinning is pushed onto the low-frequency buffer track. For the high-frequency buffer track, it is in a bus clock suspended state by default. The state resolution node extracts the orthogonal acceleration components of the X, Y, and Z axes of the triaxial acceleration sequence in real time, performs a sum of squares calculation on these components, takes the square root of the sum of squares, and subtracts the 1g gravitational acceleration constant to generate the scalar values for the triaxial acceleration sequence. When the scalar value of the triaxial acceleration sequence exceeds the first acceleration threshold, a hardware interrupt signal is generated and sent to the state resolution node. Upon receiving the hardware interrupt signal, the state resolution node wakes up the clock signal of the high-frequency buffer track, uses the generated target time window index to backtrack and lock the historical high-frequency waveforms in the memory, and copies and extracts the original high-frequency waveforms within the interval corresponding to the target time window index as a pulse wave step sequence.
[0016] During the generation of downsampled low-frequency sequence pairs and the extraction of pulse wave step sequences, the state resolution node simultaneously performs the calculation of the signal-to-noise ratio (SNR) weighting coefficients. The state resolution node reads the photoplethysmography (PPG) sequence within the interval corresponding to the target time window index and extracts the AC and DC component amplitudes of the PPG sequence. After dividing the AC component amplitude by the DC component amplitude, an amplitude ratio constant representing the contact quality parameter of the signal acquisition source is generated. Along with the generation of the amplitude ratio constant, the state resolution node extracts the zero-crossing rate constant of the triaxial acceleration sequence within the interval corresponding to the target time window index as the body motion frequency. The state resolution node extracts the amplitude ratio constant as the signal intensity numerator, extracts the zero-crossing rate constant, and adds a preset zero-noise floor bias as the noise denominator; the signal intensity numerator is divided by the noise denominator, and the output quotient, after extreme value clamping and normalization processing, is used as the SNR weighting coefficient. After being output, the SNR weighting coefficient is pushed into the feature processing queue and participates in the modulation calculation of the preset inverse covariance matrix of the machine learning classification model in the subsequent spatial mapping stage.
[0017] As the pulse wave step sequence is selectively truncated, the state solver node sends instructions to the memory bus to initiate the dynamic optimization and truncation calculation of the first baseline. The state solver node traces back along the historical timeline to obtain the time interval before the generation of the target time window index. Within this time interval, the state solver node continuously monitors the triaxial acceleration scalar. When the triaxial acceleration scalar meets the preset steady-state zero bias condition, the state solver node extracts the average pulse wave amplitude within the time interval and sets this average amplitude as the first baseline. After the first baseline is generated, the state solver node synchronously inputs the pulse wave step sequence and the first baseline into the arithmetic logic unit, calculates the point-by-point numerical difference between the pulse wave step sequence and the first baseline, and generates a difference sequence. For the difference sequence, the state solver node pushes a preset bias constant into the arithmetic register and performs a minimum value bottoming-out operation point-by-point between the difference sequence and the bias constant, generating a physiologically limited lower bound sequence. As the physiological lower bound restricted sequence is generated, the state solution node loads a preset amplitude reference constant from the read-only memory, and performs a scaling division operation on the physiological lower bound restricted sequence using the amplitude reference constant to generate a dimensionless normalized difference sequence.
[0018] After the normalized difference sequence is generated, the state solution node performs a natural logarithm space mapping on it. This mapping transforms the exponential decay process of blood vessels under hydrodynamic constraints into a linearized decay trend, outputting a linearized sequence. Within the time interval corresponding to the target time window index, the state solution node invokes the least squares calculation logic. This logic constructs a residual sum of squares function between the discrete points of the actual linearized sequence and the target fitted straight line equation, and performs a minimum operation on the residual sum of squares function. The absolute slope of the univariate linear regression fitted line that minimizes the residual sum of squares is then extracted as the absolute slope. The absolute slope quantifies the instantaneous potential energy release rate of the blood vessel wall under the Windkessel elastic cavity effect in the biofluid dynamics model.
[0019] After the absolute slope is extracted, the state solution node reads the triaxial acceleration sequence within the interval corresponding to the target time window index, executes the trapezoidal discrete integral algorithm, and outputs the sum of the physical work area under the envelope of the discrete data points of the triaxial acceleration sequence as the acceleration energy integral. The data flow process of extracting the absolute slope and generating the compensation multiplier is as follows: a bias constant is introduced to the difference sequence to perform a minimum value bottoming constraint, generating a physiologically lower bound restricted sequence; based on the preset amplitude benchmark constant, the physiologically lower bound restricted sequence is normalized to generate a normalized difference sequence; logarithmic space mapping is performed on the normalized difference sequence to linearize the decay trend, and the absolute slope of the linearized sequence is extracted using univariate linear regression within the time interval corresponding to the target time window index.
[0020] In the parallel computing chain, the acceleration energy integral is normalized based on a preset first excitation constant. The normalized energy integral is then input into a hyperbolic tangent operator for upper limit saturation mapping, generating a bounded characteristic parameter representing the physiological compensation limit. The bounded characteristic parameter is then scaled using a preset weight constant and added to a constant 1 to generate a compensation multiplier. Finally, the state solution node feeds the absolute slope and the compensation multiplier into a hardware multiplier to perform a multiplication instruction, generating a recovery decay scalar.
[0021] Within the first evaluation period set by the system, if the scalar value of the triaxial acceleration sequence exceeds the first acceleration threshold multiple times, the state solution node generates multiple target time window indices and calculates multiple candidate decay scalars in parallel. The duration of the first evaluation period is calibrated based on the physical delay characteristics of human steady-state metabolism. The state solution node extracts the ratio of the AC component amplitude to the DC component amplitude of the corresponding interval of each target time window index as a weighting coefficient. After normalizing all weighting coefficients, it calculates the weighted expected value of multiple candidate decay scalars based on the weighting coefficients. The weighted expected value is used as the recovery decay scalar within the first evaluation period and input into the subsequent solution queue.
[0022] Within the parallel time slot of the recovery attenuation scalar solution instruction cycle, the state solution node wakes up the digital filtering processing unit for the skin temperature sequence and heart rate variability sequence buffered in the generation stage for the downsampled low-frequency sequence. The digital filtering processing unit initializes the Butterworth ultra-low-pass filter according to the set low-frequency cutoff frequency parameters and second-order pole configuration. The digital filtering processing unit then performs low-pass filtering on the skin temperature sequence and heart rate variability sequence using the Butterworth ultra-low-pass filter, extracting the time sequence that satisfies the upper limit constraint of the first frequency band threshold as the fundamental component. The fundamental components extracted from the skin temperature sequence and the fundamental components extracted from the heart rate variability sequence physically characterize the perinatal rhythm envelope curves of the endocrine and nervous systems.
[0023] With the fundamental component extraction complete, the state solver node pushes the fundamental components obtained from the skin temperature sequence and the heart rate variability sequence into the sliding cross-correlation function calculation queue in parallel. The cross-correlation function calculation module performs a sliding displacement cross-multiplication and addition operation along the time axis with a fixed step size constant, extracting the displacement array of sample points one by one and calculating the corresponding dot product sum to generate a cross-correlation sequence distribution numerical matrix. After the cross-correlation sequence distribution numerical matrix is generated, the state solver node executes an optimization command to lock the absolute position of the global peak in the cross-correlation sequence distribution numerical matrix and extracts the time axis displacement sample point values corresponding to the absolute position of the global peak. The time axis displacement sample point values enter the scaling converter and perform a multiplication calibration operation with the preset sampling period values to generate a phase difference scalar in physical time dimensions. The phase difference scalar quantifies and maps the physical conduction time difference between the autonomic nerve electrical signal conduction rate and the endocrine fluid metabolic diffusion rate in the temporal space within the system model.
[0024] After the execution of the calculation instructions for the phase difference scalar and the recovery attenuation scalar is completed, the state calculation node initiates the modulation calculation process for the recovery attenuation scalar. Based on the global timestamp corresponding to the truncated pulse wave step sequence, the state calculation node obtains the time zone offset constant of the system's current geographical location; after adding the absolute number of seconds corresponding to the time zone offset constant to the global timestamp, it performs a modulo operation with a period of the absolute number of seconds corresponding to 24 hours, and sends the modulo remainder to the division register to divide by the absolute number of seconds corresponding to a single hour, extracting the corresponding local hour of the day as the time variable. The specific formula for extracting the time variable is: in, Global timestamp This represents the absolute number of seconds corresponding to the time zone offset constant. This pre-compensation mechanism eliminates the circadian rhythm phase reversal error caused by cross-time zone edge devices uploading multimodal data at the physical level.
[0025] The state resolution node divides the time variable by the biological clock period constant and multiplies it by the constant pi, extracts the result, and subtracts the reference phase angle constant to generate an intermediate floating-point variable. This intermediate floating-point variable is input to the cosine function module for periodic mapping, generating a timing bias. After the timing bias is generated, the state resolution node extracts the previously generated phase difference scalar, and sends the timing bias, phase difference scalar, and modulation constant to the arithmetic logic unit for multiplication scaling, outputting a scaled numerical variable. The state resolution node then inputs the scaled numerical variable into an exponential decay operator with a base of the natural constant to perform nonlinear penalty mapping, generating a phase compensation multiplier. At the fluid dynamics and physiological rhythm constraints level, when the time variable corresponds to the trough of the sympathetic nerve tension wave in the physical time environment, the cosine function module outputs a negative extreme physical characteristic. The exponential decay operator performs positive exponential numerical amplification or negative exponential numerical penalty operations on the scaled numerical variable based on the distribution of the phase difference scalar. The state resolution node calls the system multiplier to multiply the recovery decay scalar by the phase compensation multiplier, outputting a compliance characteristic exponent.
[0026] The formula for calculating the compliance characteristic index is: in, For compliance characteristics index, This is the recovery decay scalar calculated at time t. For phase difference scalar, The modulation constant is is the reference phase angle constant, cos is the cosine function, and exp is the exponential function with the natural constant as the base.
[0027] After the compliance feature index completes its calculation, it is transmitted as feature coordinates via the data bus and input into the machine learning classification model pre-deployed within the state resolution node. The preset reference centroid, which is fixed in the underlying data table of the machine learning classification model, is pre-generated by the offline calibration program. The offline calibration program extracts a set of historical compliance feature indices containing TCM constitution classification labels, performs coordinate vector arithmetic mean calculation on historical compliance feature indices belonging to the same TCM constitution classification label within the topological space, and fixes the arithmetic mean coordinates as the preset reference centroid.
[0028] The state resolution node extracts the pre-defined inverse covariance matrix from the machine learning classification model, and simultaneously extracts the signal-to-noise ratio (SNR) weight coefficients output from the SNR calculation queue. The state resolution node executes a matrix modulation instruction, modulating the inverse covariance matrix using the SNR weight coefficients. In the computation kernel, the matrix modulation instruction is represented by a matrix scalar multiplication operation between the SNR weight coefficients and the diagonal elements of the inverse covariance matrix, generating the modulated inverse covariance matrix. Once the modulated inverse covariance matrix is ready, the state resolution node executes a weighted Mahalanobis distance calculation program based on the input feature coordinates, the pre-defined reference centroid, and the modulated inverse covariance matrix. The weighted Mahalanobis distance calculation program performs a subtraction operation between the feature coordinate matrix and the pre-defined reference centroid matrix to generate a difference vector matrix, calculates the transpose of the difference vector matrix, and performs a continuous matrix multiplication instruction on the transpose of the difference vector matrix, the modulated inverse covariance matrix, and the original difference vector matrix. The square root of the output scalar of the continuous matrix multiplication instruction is then calculated, outputting the spatial distance scalar between the feature coordinates and the pre-defined reference centroid. The minimum value optimization algorithm is executed based on the spatial distance scalar. The state solution node locks the nearest preset reference centroid spatial position and generates the corresponding TCM constitution classification label instruction for the preset reference centroid spatial position.
[0029] To ensure that the state solver node does not experience logic stack overflow events when receiving extreme edge input variables, the built-in parameter calibration module of the state solver node establishes a boundary envelope system for physical constants. For the logarithmic space mapping and minimum value bottoming-out stage of the difference sequence, the calibration domain of the bias constant is limited to a defined floating-point constant range based on the quantization noise level of the underlying hardware analog-to-digital converter. When an external random physical perturbation causes the transient acquisition extreme value of the pulse wave step sequence to fall below the first baseline, the minimum value bottoming-out operation replaces the lower bound of the difference sequence operation with the bias constant. This lower bound replacement action cuts off the out-of-bounds addressing path for the logarithmic space mapping operator to receive negative or zero input variables in the underlying data link.
[0030] For the upper bound saturation mapping stage of the hyperbolic tangent operator and the nonlinear penalty mapping stage of the exponential decay operator, the weight constant and modulation constant are fixed and locked based on the linear regression confidence interval of clinical sample characteristic data under physiological limits. The weight constant constrains the numerical jump limit of the compensation multiplier in response to transient signal abrupt changes. The boundary conditions of the modulation constant are simultaneously limited to control the maximum exponential multiplication penalty amplitude of the sympathetic rhythm on the recovery decay scalar. Constrained by the convergence boundary of the weight constant and modulation constant, the hyperbolic tangent operator and the exponential decay operator constrain the extreme values of the fluctuation of the compliance characteristic exponent.
[0031] With the hard-coded locking of the registers in the operational boundary envelope system, a mathematical convergence path is constructed within the arithmetic logic unit of the state solution node for extreme data inputs triggered by the triaxial acceleration sequence under extreme space physics scenarios. As the scalar value of the triaxial acceleration sequence exhibits a rapidly increasing extreme value abrupt change, the acceleration energy integral approaches the limit of infinity. When the acceleration energy integral approaches the limit of infinity, the hyperbolic tangent operator receives the extreme value variable and performs limit convergence operations. The upper limit saturation mapping value output by the hyperbolic tangent operator converges to a constant 1. After the upper limit saturation mapping value output by the hyperbolic tangent operator converges to a constant 1, the output extreme value of the compensation multiplier is enveloped within the fixed constant boundary of the sum of constant 1 and the weight constant due to the amplitude multiplication scaling effect of the weight constant. The fixed constant boundary cuts off the logical divergence path of the microprocessor to derive the infinitely large recovery decay scalar.
[0032] Mapping to the data flow path of extreme value abrupt changes, when the scalar value of the triaxial acceleration sequence is in a weak state with a low threshold, the obtained acceleration energy integral approaches the lower bound limit of 0. When the acceleration energy integral approaches 0, the hyperbolic tangent operator receives the input parameter and performs a degenerate operation, and the upper limit saturation mapping value output by the hyperbolic tangent operator converges to 0. As the upper limit saturation mapping value output by the hyperbolic tangent operator converges to 0, the constant 1 and the value of 0 are added together, and the compensation multiplier smoothly degenerates to the constant 1. After the compensation multiplier degenerates to the constant 1, the multiplier multiplies the extracted absolute slope with the constant 1, and the calculation equation for the decay scalar is degenerates to the absolute slope value. The equation dimensionality reduction and degenerate mechanism excludes the condition of the acceleration energy integral as a denominator in the calculation in the underlying logic operation circuit.
[0033] For computing architectures where the built-in microprocessors of physiological signal acquisition nodes or state calculation nodes lack hardware floating-point units, the system bus is configured with a degraded equivalent alternative computation path. During the system's factory programming stage, the compiler pre-discretizes and slices the exponential convergence mapping model inside the hyperbolic tangent operator and the cosine function curve inside the periodic oscillation operator, generating a fixed static mapping mesh. The fixed static mapping mesh is directly written into the read-only address range of read-only memory, forming a discrete data lookup table. When the state calculation node receives the acceleration energy integral and timing bias, the state calculation node, guided by the interrupt controller, bypasses the hardware floating-point unit and directly inputs the acceleration energy integral and timing bias into an integer shift register, performing a bit-right shift scaling operation on the input variables. After the bit-right shift scaling operation is completed, the integer shift register generates an integer index pointer. The integer index pointer is pointed to the corresponding memory address space of the discrete data lookup table. The state solution node extracts two adjacent discrete anchor point values from the discrete data lookup table based on integer index pointers. It then invokes fixed-point adders and multipliers to perform first-order linear interpolation approximation operations on these two anchor point values, generating equivalent approximation parameters to approximate the output results of the floating-point hyperbolic tangent and cosine functions. After the equivalent approximation parameters are generated, they are substituted into the subsequent calculation queues for compensation multipliers and phase compensation multipliers.
[0034] As the upper limit saturation mapping instruction is executed within the arithmetic logic unit, alternative paths are pre-set within the state solution node. When the addressing path of the hyperbolic tangent operator is bypassed, the logic stearation mapping operator is activated by the interrupt controller. The logic stearation mapping operator receives the normalized energy integral, combines it with the sign of a negative constant, and forms the negative exponent variable of the natural constant Euler number. The natural constant Euler number participates in the natural exponent operation and is added to constant 1, then used as the denominator for division. It then undergoes division with constant 1 to generate the basic logic stearation floating-point variable. The basic logic stearation floating-point variable enters the multiply-accumulate arithmetic unit, undergoes a pre-set first-order linear constant scaling operation, and outputs the equivalent upper limit saturation mapping value. The equivalent upper limit saturation mapping value enters the addition and superposition operation sequence of the compensation multiplier.
[0035] For the data generation path of the absolute slope, when the logarithmic space mapping operator is in a suspended state, the state solution node extracts the first physical timestamp corresponding to the peak extreme value in the difference sequence. The state solution node monitors the waveform decline amplitude of the difference sequence along the time axis and locks the second physical timestamp corresponding to the difference amplitude decaying to half the value of the peak extreme value. The state solution node subtracts the first physical timestamp from the second physical timestamp to calculate the physical time span scalar, and uses the physical time span scalar as the half-life constant. The half-life constant is sent to the division register and performs a reciprocal operation on the constant 1 to generate the characteristic substitution slope. The characteristic substitution slope is transmitted to the hardware multiplier, multiplied by the compensation multiplier instead of the absolute slope, and outputs the restored decay scalar.
[0036] The data transfer task involving the acquisition of multi-source physiological signals and the decoupling of state characteristics relies on an underlying physical infrastructure. The printed circuit board of the physiological signal acquisition node integrates a photoelectric transmitter / receiver, a negative temperature coefficient thermistor patch, a microelectromechanical system (MEMS) triaxial accelerometer, and an ultra-low power Bluetooth baseband chip. The photoelectric transmitter / receiver acquires and outputs a photoplethysmography (PPG) sequence containing a global timestamp. The PPG patch acquires and outputs a skin temperature sequence. The MEMS triaxial accelerometer captures and outputs a triaxial acceleration sequence. The PPG sequence, skin temperature sequence, and triaxial acceleration sequence, all containing global timestamps, are continuously transmitted outwards via a data transmission link established by the ultra-low power Bluetooth baseband chip.
[0037] The state resolution node is internally configured with a mobile terminal microprocessor chip architecture. This architecture includes read-only memory, random access memory, cache memory, and arithmetic logic units. Reading instructions for acquiring photoplethysmography (PPG), skin temperature, and triaxial acceleration sequences containing global timestamps are captured by the general-purpose registers of the PPG chip architecture, triggering a direct memory access and transfer program. The automatic TCM constitution classification device, as a compiled machine code instruction stream, is burned into and permanently stored within the memory address space of the state resolution node.
[0038] For the operations of extracting the fundamental components of the two sequences in the downsampled low-frequency sequence pair and performing cross-correlation calculations on the time axis to generate a phase difference scalar, the state calculation node calls the built-in digital signal processing core or the multiply-accumulate accumulator inside the neural network processor to perform hardware-level computational acceleration. The multiply-accumulate accumulator synchronously processes floating-point multiplication operations and register accumulation operations within a single machine clock cycle, hardening the software algorithm logic of cross-correlation calculation into a high-low level toggling operation of a silicon-based transistor array.
[0039] Computer-readable storage media, serving as the physical carrier of all computational instructions and characteristic coordinate state variables, encompasses both non-volatile and volatile storage elements within the system architecture. Non-volatile storage elements include flash memory chips, electrically erasable programmable read-only memory (EEPROM), and solid-state drives (SSDs). Volatile storage elements include dynamic random access memory (DRAM). The compiled machine code instruction stream is written into the physical silicon layer of the non-volatile storage element before the state resolution node is powered on. Within the time window corresponding to when the scalar value of the triaxial acceleration sequence exceeds the first acceleration threshold, the machine code instruction stream, along with the calculated phase difference scalar, recovery decay scalar, and compliance characteristic index, are loaded into the capacitance matrix of the volatile storage element to form a resident state, completing the mapping calculation of the characteristic coordinates at the hardware physical layer.
[0040] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A machine learning-based automatic classification method for TCM constitution, characterized in that, Includes the following steps: Acquire photoplethysmography (PPG) sequences, skin temperature sequences, and triaxial acceleration sequences containing global timestamps; The skin temperature sequence and the heart rate variability sequence extracted from the photoplethysmography pulse wave sequence are downsampled and buffered with a first sampling period to generate downsampled low-frequency sequence pairs; at the same time, when the scalar value of the triaxial acceleration sequence exceeds a first acceleration threshold, a target time window index is generated, and the pulse wave step sequence is directionally truncated based on the target time window index. Extract the attenuation features of the pulse wave step sequence as it falls from the peak, and obtain the acceleration energy integral within the interval corresponding to the target time window index. Based on the attenuation features and the acceleration energy integral, calculate the recovery attenuation scalar. The fundamental components of the two sequences in the downsampled low-frequency sequence pair are extracted respectively, and the cross-correlation of the fundamental components on the time axis is performed to generate a phase difference scalar. The phase difference scalar is used to perform modulation calculation on the recovery attenuation scalar to generate a compliance feature index; the compliance feature index is used as feature coordinates and input into a pre-deployed machine learning classification model to calculate the spatial distance between the feature coordinates and the preset reference centroid in the machine learning classification model, and a TCM constitution classification label instruction is generated based on the spatial distance.
2. The method according to claim 1, characterized in that, In the process of generating the downsampled low-frequency sequence pair and truncating the pulse wave step sequence, the method further includes: The AC component amplitude and DC component amplitude of the photoplethysmography sequence are extracted, and the AC component amplitude is divided by the DC component amplitude to generate an amplitude ratio constant, which is used as the contact quality parameter of the signal acquisition source. Extract the body motion frequency within the interval corresponding to the target time window index as the zero-crossing rate constant; extract the amplitude ratio constant as the signal strength numerator; extract the zero-crossing rate constant and add a preset anti-zero noise floor bias as the noise denominator; divide the signal strength numerator by the noise denominator, and the output quotient is processed by extreme value clamping and normalization, and then used as the signal-to-noise ratio weighting coefficient. When calculating the spatial distance between the feature coordinates and the preset reference centroid, the preset inverse covariance matrix in the machine learning classification model is extracted, the inverse covariance matrix is modulated using the signal-to-noise ratio weight coefficient, and the weighted Mahalanobis distance is calculated based on the modulated inverse covariance matrix as the spatial distance.
3. The method according to claim 1, characterized in that, The steps for calculating the recovery attenuation scalar include: The average pulse wave amplitude value before the generation of the target time window index is obtained as the first baseline; Calculate the difference sequence between the pulse wave step sequence and the first baseline; Logarithmic mapping and least squares fitting are performed on the difference sequence to extract the absolute slope of the univariate linear regression; In parallel, the acceleration energy integral is calculated using the hyperbolic tangent function to generate a compensation multiplier; The absolute slope is multiplied by the compensation multiplier to generate the recovery attenuation scalar.
4. The method according to claim 3, characterized in that, The steps for extracting the absolute slope include: A bias constant is introduced into the difference sequence to implement a minimum value bottoming constraint, generating a physiologically lower bound restricted sequence; Based on a preset amplitude reference constant, the physiological lower bound restricted sequence is subjected to dimensional normalization to generate a normalized difference sequence. Log-space mapping is performed on the normalized difference sequence to linearize the decay trend, and the absolute slope of the linearized sequence is extracted using univariate linear regression within the time interval corresponding to the target time window index, which is used as the absolute slope. The steps for generating the compensated multiplier include: The acceleration energy integral is normalized based on a preset first excitation constant. The normalized energy integral is then input into the hyperbolic tangent operator for upper limit saturation mapping to generate a bounded characteristic parameter that characterizes the physiological compensation limit. The bounded feature parameter is scaled using a preset weight constant, and then added to the constant 1 to generate the compensation multiplier.
5. The method according to claim 1, characterized in that, The steps for extracting the fundamental components of the two sequences in the downsampled low-frequency sequence pair respectively include: The skin temperature sequence and the heart rate variability sequence in the downsampled low-frequency sequence pair are respectively subjected to low-pass filtering to extract the time series that meet the upper limit constraint of the first frequency band threshold, which is used as the fundamental component.
6. The method according to claim 1, characterized in that, The step of performing modulation calculations on the recovery attenuation scalar using the phase difference scalar to generate the compliance characteristic index includes: Based on the global timestamp corresponding to the pulse wave step sequence, the time zone offset constant of the current geographical location of the system is obtained; after adding the absolute number of seconds corresponding to the time zone offset constant to the global timestamp, a modulo operation with the absolute number of seconds corresponding to 24 hours as the period is performed, and the modulo remainder is divided by the absolute number of seconds corresponding to a single hour to extract the corresponding local intraday hour as the time variable. Combined with the preset biological clock cycle constant and the reference phase angle constant, the time series offset is extracted using the periodic oscillation operator. The timing offset, the phase difference scalar, and the preset modulation constant are multiplied and scaled, and then an exponential decay operator is input for nonlinear penalty mapping to generate a phase compensation multiplier. The compliance characteristic index is generated by multiplying the recovery attenuation scalar with the phase compensation multiplier.
7. The method according to claim 6, characterized in that, The formula for generating the compliance characteristic index is as follows: in, The compliance characteristic index is... The recovery decay scalar is calculated at time t. Let the phase difference scalar be... The modulation constant is... Let be the reference phase angle constant, cos be the cosine function, and exp be the exponential function with the natural constant as the base.
8. The method according to any one of claims 1 to 7, characterized in that, The method further includes: If the scalar value of the triaxial acceleration sequence exceeds the first acceleration threshold multiple times during the first evaluation period, multiple target time window indices are generated, and multiple candidate decay scalars are calculated accordingly. The ratio of the AC component amplitude to the DC component amplitude of the photoplethysmography sequence within the corresponding interval of each target time window index is extracted and used as the corresponding weighting coefficient. Based on the weighting coefficient, the weighted expected value of the multiple candidate attenuation scalars is calculated, and the weighted expected value is used as the recovery attenuation scalar within the first evaluation period.
9. An automatic TCM constitution classification device, characterized in that, include: Memory, used to store computer programs; A processor, communicatively connected to the memory, is used to implement the method as described in any one of claims 1 to 8 when executing the computer program.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method as described in any one of claims 1 to 8.
