Acupuncture combined transcranial magnetic stimulation scheme selection method based on machine learning

By establishing a method for selecting acupuncture combined with transcranial magnetic stimulation through machine learning, we have solved the problems of slow efficacy and high risk in traditional treatment of dysphagia, and achieved more effective treatment selection and dynamic optimization.

CN121687388APending Publication Date: 2026-03-17ZHONGDA HOSPITAL SOUTHEAST UNIV

Patent Information

Application Number
CN202511854357.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-10
Publication Date
2026-03-17

AI Technical Summary

Technical Problem

In treating post-stroke dysphagia, traditional rehabilitation training is slow and has limited effectiveness, transcranial magnetic stimulation carries risks, and there is a lack of effective methods for selecting acupuncture combined with transcranial magnetic stimulation.

Method used

Using machine learning methods, acupuncture and transcranial magnetic stimulation data were recorded, a hierarchical random forest regression model was established, a database of acupuncture combined with transcranial magnetic stimulation protocols was constructed, the optimal stimulation protocol was selected using the reverse prediction method, and the treatment process was optimized by combining a multidimensional value function.

Benefits of technology

This approach effectively combines acupuncture with transcranial magnetic stimulation (TMS), improving the efficacy of treating dysphagia, reducing the risks associated with high-frequency TMS, and optimizing the dynamic changes and predictive accuracy of the treatment process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121687388A_ABST
    Figure CN121687388A_ABST
Patent Text Reader

Abstract

The invention provides a machine learning-based acupuncture combined transcranial magnetic stimulation scheme selection method, which comprises the following steps of: performing acupuncture on an object, recording acupuncture data, and obtaining acupuncture text characteristics; the acupuncture data comprises acupuncture object data and acupuncture operation data, the acupuncture object data comprises gender, age, disease name, symptom, medical history and living habit, and the acupuncture operation data comprises body position, acupuncture point, acupuncture sequence, needle inserting, needle moving and duration; performing transcranial magnetic stimulation on the needled object for multiple times to obtain transcranial magnetic stimulation data, the transcranial magnetic stimulation data including hot spot positioning, working parameters, process data and effect data, and obtaining transcranial magnetic stimulation features; establishing association between acupuncture text features and transcranial magnetic stimulation features, constructing a database storing multiple groups of acupuncture combined transcranial magnetic stimulation schemes, and selecting a layered random forest regression model for training; and selecting an acupuncture combined transcranial magnetic stimulation scheme from the database according to actual data by using a reverse prediction method.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of medical technology, and in particular to a method for selecting acupuncture combined with transcranial magnetic stimulation based on machine learning. Background Technology

[0002] According to the "China Stroke Prevention and Treatment Report (2023)," there are approximately 5.5 million new stroke cases in my country each year. Currently, treatments for post-stroke dysphagia include swallowing training, medication, and physical therapy. In addition, neurostimulation techniques, such as vagus nerve stimulation, are considered potential adjunctive methods for dysphagia rehabilitation. Traditional rehabilitation training has some efficacy for dysphagia, but its effects are slow, the treatment cycle is long, and the overall effect is limited. Transcranial magnetic stimulation (TMS) is a non-invasive neurostimulation technique primarily used to stimulate the cerebral cortex, offering unique advantages in the assessment and treatment of dysphagia. Patent application number 202010997945.0 discloses a multimodal stimulation system and method that achieves electrostimulation therapy by setting stimulation parameters and sequences, combining electric shock with acupuncture. However, TMS carries certain risks, especially the potential to induce epilepsy under high-frequency TMS. Therefore, selecting a combination of acupuncture and transcranial magnetic stimulation (TMS) in advance can solve the problem of excessively high TMS frequency, and machine learning to select the stimulation program is one solution. Summary of the Invention

[0003] The purpose of this invention is to provide a machine learning-based method for selecting acupuncture combined with transcranial magnetic stimulation (TMS) protocols, comprising: Step S100: Perform acupuncture on the object and record acupuncture data to obtain acupuncture text features; the acupuncture data includes acupuncture object data and acupuncture operation data, wherein the acupuncture object data includes gender, age, disease name, symptoms, medical history, and lifestyle habits, and the acupuncture operation data includes body position, acupoints, acupuncture sequence, needle insertion, needle manipulation, and duration. Step S200: Perform transcranial magnetic stimulation multiple times on the acupunctured object to obtain transcranial magnetic stimulation data. The transcranial magnetic stimulation data includes hot spot localization, working parameters, process data, and effect data to obtain transcranial magnetic stimulation characteristics. The process data includes image data and electrical signal data. Step S300: Establish the association between acupuncture text features and transcranial magnetic stimulation features, construct a database storing multiple sets of acupuncture combined with transcranial magnetic stimulation schemes, and select a hierarchical random forest regression model for training. The hierarchical division of the hierarchical random forest regression model is based on the number of transcranial magnetic stimulations. The features of the random forest regression model include features obtained using acupuncture data, hotspot localization, working parameters, and process data, and the labels are features obtained through effect data. Step S400: Using the reverse prediction method, hotspot locations and working parameters are obtained based on actual acupuncture data, process data, and effect data to form an acupuncture combined with transcranial magnetic stimulation scheme.

[0004] Furthermore, in step S200, the electrical signal data is read by electromyography to obtain the process text features of the electrical signal, which include the time domain features, frequency domain features, and time sequence features of the electrical signal.

[0005] Furthermore, in step S200, the image data is acquired through an image acquisition device with perspective capability, and structural motion features and image temporal features are obtained from the image data. The method for acquiring structural motion features includes: Step S211: Convert the swallowing process video obtained through dynamic contrast imaging into a sequence of frame images; Step S212: Use a deep learning model to perform semantic segmentation and identify key structures; Step S213: Use a key point tracking algorithm to track the motion of key structures in consecutive frames; Step S214: Extract key structural motion data and quantify them into numerical indicators as structural motion features.

[0006] Furthermore, in step S200, interference features are removed. The methods for obtaining interference features include: Step S221: Divide the motion process into several consecutive independent event points; Step S222: Divide the structural motion features and process text features into several categories according to independent event points. Each independent event point contains a set of structural motion feature and process text feature pairs. Step S223: Calculate the Pearson correlation coefficient between brain region activation intensity and structural motor characteristics. r 1; Step S224: Calculate the Pearson correlation coefficient between brain region activation intensity and process text features. r 2; Step S225, delete Pearson correlation coefficient r 1 < 0.7 and r The structural motion features and process text features corresponding to 2 < 0.7.

[0007] Furthermore, in step S200, the features obtained from the image data and electrical signal data are concatenated into a long process data feature vector.

[0008] Furthermore, the features extracted from the effect data include strength association features, temporal association features, and coordination association features; among which... The temporal correlation feature is the difference between the starting point of transcranial magnetic stimulation activation and the initial acquisition time of the process data feature vector; The intensity correlation feature is the Pearson correlation coefficient between process text features and structural motion features within a cycle; Coordination correlation features include muscle pair delay and motion pair delay. Muscle pair delay is the time difference between the onset of contraction of two different muscles read from electromyography, while motion pair delay is the time difference between the onset of physical motion of two different key structures in image data.

[0009] Furthermore, the specific process of step S400 includes: Step S401: Define the search space for hotspot location and working parameters, and generate candidate solutions within the search space. Step S402, for the first i One candidate scheme, and the features required to construct the random forest model. T i,t Label prediction is performed in the corresponding level of the random forest model to obtain the prediction results. Y pred,i,t ; Step S403, regarding the prediction effect Y pred,i,t The corresponding features are broken down into static features, decision variables, and dynamic features, and the static features, decision variables, and prediction results are then analyzed. Y pred,i,t Directly copy to predict future states S i,t+1 In this process, dynamic features are predicted and then written into the predicted future state. S i,t+1 In this context, the decision variables are hotspot location and working parameters, the static features are needle-punch text features, and the dynamic features are features obtained from process data. Step S404, predict the future state S i,t+1 The input is fed into a multidimensional value function for calculation, and the decision variable corresponding to the maximum output value is selected as the solution and output.

[0010] Furthermore, in step S403, a random forest model is used to predict dynamic features. The features of the random forest model training process are obtained through needle data, hotspot localization, working parameters, and effect data, and the labels are obtained through process data.

[0011] Furthermore, the process of establishing the multidimensional value function described in step S404 includes: Step S4041: Establish therapeutic value based on efficacy data V efficacy Specifically, this involves normalizing the features obtained from the effect data and then performing a weighted summation. Step S4042: Establish efficiency value based on operating parameters Vefficiency Specifically, this involves normalizing the features obtained from the working parameters and then performing a weighted summation. Step S4043: Establish trend value based on effect data trends V momentum Specifically, this involves calculating the efficacy value of the most recent treatments. V efficacy The slope; Step S4044: Establish security value based on process data V safety Specifically, a safety threshold is set, and the output value is calculated using a quadratic penalty function for features that exceed the safety threshold. Step S4045: Establish a multidimensional value function V ( S ), V ( S ) = We × V efficacy + Wf × V efficiency + Wm × V momentum + Ws × V safety , in, We , Wf , Wm , Ws The weights for each dimension.

[0012] Furthermore, in step S402, default values ​​are set for features that have not been assigned values.

[0013] Compared with the prior art, the present invention has the following advantages: (1) The present invention associates acupuncture data with TMS multidimensional response data and transforms the interaction between the two therapies into an analyzable mathematical model; (2) The present invention uses the number of TMS treatments as the standard for stratification, considers the dynamic changes in the treatment process, avoids the prediction bias caused by mixing all the data together, and makes the recommended scheme more in line with the actual time process of treatment; (3) The present invention adopts reverse prediction based on value optimization, without the need to pre-set the target prediction, and automatically selects the scheme that can make the state better through machine learning.

[0014] The present invention will now be further described with reference to the accompanying drawings. Attached Figure Description

[0015] Figure 1 This is a schematic diagram of the method flow of the present invention. Detailed Implementation

[0016] Combination Figure 1 A machine learning-based method for selecting acupuncture combined with transcranial magnetic stimulation (TMS) protocols, comprising: Step S100: Perform acupuncture on the object and record acupuncture data to obtain acupuncture text features; the acupuncture data includes acupuncture object data and acupuncture operation data, wherein the acupuncture object data includes gender, age, disease name, symptoms, medical history, and lifestyle habits, and the acupuncture operation data includes body position, acupoints, acupuncture sequence, needle insertion, needle manipulation, and duration. Step S200: Perform transcranial magnetic stimulation multiple times on the acupunctured object to obtain transcranial magnetic stimulation data. The transcranial magnetic stimulation data includes hot spot localization, working parameters, process data, and effect data to obtain transcranial magnetic stimulation characteristics. The process data includes image data and electrical signal data. Step S300: Establish the association between acupuncture text features and transcranial magnetic stimulation features, construct a database storing multiple sets of acupuncture combined with transcranial magnetic stimulation schemes, and select a hierarchical random forest regression model for training. The hierarchical division of the hierarchical random forest regression model is based on the number of transcranial magnetic stimulations. The features of the random forest regression model include features obtained using acupuncture data, hotspot localization, working parameters, and process data, and the labels are features obtained through effect data. Step S400 uses the reverse prediction method to obtain hotspot locations and working parameters based on actual acupuncture data, process data, and effect data, which serve as the acupuncture combined with transcranial magnetic stimulation (TMS) scheme. Step S100 requires setting a text template to record relevant descriptions of the acupuncture objects, facilitating the subsequent acquisition of descriptive text features (keywords, i.e., entities) during machine learning. The text template can be shown in Table 1, with features separated by periods (.").

[0017] Table 1. List of acupuncture text descriptions

[0018] Acupuncture operation data can also be obtained using a template for recording. The acupuncture operation data shown in Table 2 is plotted using the above-described text template embodiment.

[0019] Table 2 List of acupuncture operation data

[0020] First, feature extraction is required from the acupuncture data. Features include categorical features, numerical features, and vector features. Categorical features are those that can be classified, such as gender, disease name, body position, and acupoints. Numerical features are those represented in numerical form, such as age and market value. Vector features are obtained by processing the text description. The vector feature extraction process includes: Step S101: Establish a text feature database, which stores relevant feature descriptions and quantizes them; Step S102: The input text description containing acupuncture data is processed by word segmentation to obtain sub-word units, forming a unit dataset; Step S103: Input the sub-word units into the encoder to obtain the unit embedding vector; Step S104: Set the confidence level of the matching rules, perform multi-level matching on the word meta-database and text feature database to obtain candidate features, and the multi-level matching is in the order of confidence level as exact matching, synonym matching and semantic matching. Step S105: After performing conflict detection on the candidate features, the final needle-punched text features of the input text description are obtained.

[0021] In step S101, the scenarios in which transcranial magnetic stimulation can be applied mainly include the treatment of depression, obsessive-compulsive disorder, chronic neuropathic pain, stroke rehabilitation, addiction, etc. Therefore, when establishing the text feature database, all feature descriptions that may be involved in the above scenarios should be fully considered.

[0022] Steps S102 and S103 implement a context-aware lexical encoding process through RERT vectorization.

[0023] The matching process at each level in step S104 is as follows: (1) Exact matching process: Traverse the input words and perform string matching with the features in the text feature database. If the words and features are completely consistent, output the matching result; (2) Synonym matching process: For words that fail to match precisely, query the domain thesaurus to obtain all synonym variants of the word, and use the thesaurus set to match with the text feature database. If any synonym matches the feature keyword, output the matching result with a medium confidence level. (3) Semantic matching process: Calculate the cosine similarity between the word embedding vector and each feature description vector, sort them from high to low similarity, and select the feature with the largest similarity exceeding the threshold.

[0024] In step S105, conflict detection includes "the same word matching multiple features" and "multiple words matching the same feature". The solution for "the same word matching multiple features" is to select the feature with the highest confidence; the solution for "multiple words matching the same feature" is to select the feature that is matched by the most words.

[0025] In step S200, the transcranial magnetic stimulation (TMS) data acquisition methods vary depending on the monitoring site: for in vivo monitoring, data can be obtained through contrast imaging; for superficial muscle tissue, data can be obtained through electromyography (EMG). For example, when measuring stroke swallowing safety, contrast imaging is used to obtain swallowing process data, including {tongue churning, soft palate closure, laryngeal elevation and anterior displacement, epiglottic inversion, glottic closure, and cricopharyngeal muscle opening}; when measuring stroke rehabilitation motor function, EMG is used to measure the process data (i.e., motor threshold) of hand muscles (usually the abductor muscles of the thumb), including {MEP latency, MEP amplitude, and MEP duration}. In measuring stroke swallowing safety, a combination of contrast imaging and EMG can be used.

[0026] The hotspot localization mentioned in step S200 refers to the optimal stimulation location on the scalp that most effectively activates the target muscle (eliminating the maximum motor evoked potential) when TMS is applied. Taking the example in the table above, the specific method for hotspot localization includes: Step S201: Place the recording electrodes on the muscles to be tested according to their anatomical locations. Step S202: Place the center of the coil roughly on the ventral part of the contralateral primary motor cortex. Since the cortical control of swallowing is bilateral and there are individual differences, it is usually necessary to scan both cerebral hemispheres. Use the C3 (right hand) or C4 (left hand) point of the international 10-20 EEG system as the initial reference point. Step S203: Set a moderately high stimulation intensity, such as 50%-60% of the device's maximum output intensity, to ensure that a response can be induced. Step S204: Apply a single-pulse TMS at the initial reference point while observing the EMG screen; if the MEP is not visible, move the coil and proceed to step S203 to stimulate again until the MEP appears. Step S205: Using the center of the coil when the MEP is observed as the center point, perform grid division, apply a single pulse TMS multiple times at each point on the grid in sequence, and record the average amplitude and latency of the MEP. Step S206: Compare the average amplitude and latency of all points, and select the cerebral cortex location that can most stably induce the largest amplitude and the shortest latency.

[0027] The operating parameters in step S200 include {coil type, stimulation frequency, stimulation intensity, number of pulses, sequence mode, stimulation interval, and duration}. Descriptions of each operating parameter are shown in Table 3.

[0028] Table 3. List of Transcranial Magnetic Stimulation Operating Parameters

[0029] The process data in step S200 includes resting motion thresholds and physiological signal monitoring data. The physiological signal monitoring data includes two forms: image data and electrical signal data. Both forms of data are ultimately recorded numerically. Electrical signal data can be read using electromyography (EMG) to obtain time-domain features, frequency-domain features, and temporal features. In this embodiment, these features are referred to as process text features, as shown in Table 4.

[0030] Table 4 List of Process Text Features

[0031] For image data, such as when using contrast imaging to obtain information about the swallowing process in measuring stroke swallowing safety, image recognition technology is needed to identify and acquire process image features. These process image features include structural motion features and temporal image features. Methods for extracting process data and acquiring structural motion features from images include: Step S211: The swallowing process video obtained through dynamic contrast imaging is converted into a sequence of frame images and preprocessed. Step S212: Use deep learning models (such as U-Net, Mask R-CNN) to perform semantic segmentation and identify key structures; Step S213: Use key point tracking algorithms (such as Kanade-Lucas-Tracker, SIFT feature matching) to track the motion of key structures in consecutive frames; Step S214: Extract key structural motion data and quantify them into numerical indicators as structural motion features.

[0032] When measuring the swallowing safety of stroke patients as described above, contrast imaging was used to obtain the structural motion characteristics of the subject's swallowing. Taking {tongue stirring, soft palate closure, larynx elevation and forward movement, epiglottis inversion, glottis closure, cricopharyngeal muscle opening} as an example, the structural motion characteristics obtained by the key point tracking algorithm are shown in Table 5.

[0033] Table 5. List of structural motion image features involved in contrast imaging examinations for swallowing safety in stroke (partial).

[0034] Muscle discharges induced by varying transcranial magnetic stimulation (TMS) currents may include irrelevant muscle activity during the stimulation process, requiring the removal of this irrelevant noise. The removal process includes: Step S221: Divide the motion process into several consecutive independent event points; Step S222: Divide the structural motion features and process text features into several categories according to independent event points. Each independent event point contains a set of structural motion feature and process text feature pairs. Step S223: Calculate the Pearson correlation coefficient between brain region activation intensity and structural motor characteristics. r 1; Step S224: Calculate the Pearson correlation coefficient between brain region activation intensity and process text features. r 2; Step S225, delete Pearson correlation coefficient r 1 < 0.7 and r The structural motion features and process text features corresponding to 2 < 0.7.

[0035] In step S221, to ensure that the electromyography data and contrast imaging data are compared at the same time, the movement process needs to be divided into several consecutive independent event points. Taking the independent event points of swallowing as an example, the independent event points are divided into [T0, T1, T2, T3]. T0 is the swallowing initiation point, corresponding to the head of the bolus passing through the base of the tongue; T1 is the beginning of the pharyngeal phase, corresponding to the retraction of the base of the tongue contacting the posterior pharyngeal wall and the larynx beginning to rise; T2 is the maximum larynx elevation, corresponding to the larynx reaching its highest point and the cricopharyngeal muscle opening; T3 is the end of swallowing, corresponding to the bolus passing through the upper esophagus and the larynx beginning to descend.

[0036] In step S222, the relationship between the structural motion features and process text features in independent event points is established. The process corresponding to the independent event point can be represented by electromyography and angiography respectively. For example, in the maximum elevation of the larynx at the T2 event point, the electromyography data is represented by the data of the submental muscle group and the infrahyoid muscle group, while the angiography data is represented by the key points involved from the initiation of tongue elevation to the initiation of larynx elevation.

[0037] Steps S223, S224, and S225 require determining whether a linear relationship exists between brain activity and muscle activity. This determination primarily assesses the relationship between structural motor features and brain activity, with the relationship between procedural text features and brain activity serving as a reference. The Pearson correlation coefficient is used to calculate the correlation coefficient between brain region activation intensity (e.g., the β value of the primary motor cortex) and structural motor features / procedural text features. r 1 / r 2. If the Pearson correlation coefficient r A Pearson correlation coefficient ≥ 0.7 indicates a relationship between muscle activity and brain activity; if the Pearson correlation coefficient is 1, then the muscle activity is related to brain activity. r 1 < 0.7 and r A value of 2 < 0.7 indicates that the muscle activity is not related to brain activity. The procedural text features and structural kinematic features corresponding to muscle activities related to brain activity are preserved.

[0038] For transcranial magnetic stimulation (TMS) processes that involve both text features converted from physiological signals and image features from image data, multimodal data fusion is required. This involves concatenating the process text features and structural motion features into a long process data feature vector.

[0039] In addition to the structural kinematic features described in Table 5, process image features also include image temporal features. Image temporal features include the start time and duration of independent event points.

[0040] The features extracted from the effect data in this embodiment include intensity correlation features, time-series correlation features, and coordination correlation features. The acquisition methods for each indicator are as follows.

[0041] (1) Temporal correlation characteristics The starting point of TMS activation and the initial acquisition time of process data feature vectors were recorded separately during exercise; the difference between the two was calculated. This indicator assesses the speed from electrical activity to mechanical movement. Abnormal delays may indicate muscle disease or energy metabolism crisis, and TMS may need to be combined with neuromuscular electrical stimulation, or the rehabilitation focus may need to be adjusted to muscle endurance training.

[0042] (2) Intensity of correlation characteristics Continuous data of process text features and structural motion features are selected within one period, and the Pearson correlation coefficient between the two sequences is calculated. r 3, r The value of 3 ranges from [-1, 1]; if r If 3 is close to +1, the instruction manual indicates a strong positive correlation between the two features, meaning that the stronger the EMG signal, the greater the range of motion and the higher the neuromuscular efficiency; if... r A value close to 0 indicates no neural connection, meaning that neural drive has failed to effectively translate into mechanical movement, potentially indicating muscle degeneration, fatty infiltration, or tendon laxity; if... r A value close to -1 indicates a strong negative correlation, which is rare in actual physiology. Strongly positive correlations preserve the textual and structural motor features of the process. This assesses the efficiency of neural drive conversion into mechanical movement. If inefficient, TMS should focus on enhancing the output strength of specific cortical areas or combining it with muscle strength training.

[0043] (3) Characteristics of coordinated association Coordination correlation features include muscle-pair delay and motion-pair delay; the muscle-pair delay is the time difference between the onset of contraction of two different muscles, obtained from process text features; the motion-pair delay refers to the time difference between the onset of physical motion of two different key structures, obtained from image features. This metric assesses whether the activation sequence between different muscles is correct. Sequence disorder is a sign of impaired coordination, and TMS strategies should focus on improving the synchronicity between different muscle groups, rather than simply enhancing a single muscle.

[0044] In step S300, the data obtained in steps S100 and S200 are recorded in the database of the acupuncture combined with transcranial magnetic stimulation protocol according to a fixed template.

[0045] In step S300, a hierarchical random forest regression model is selected to train the acupuncture combined with transcranial magnetic stimulation (TMS) protocol. Considering that acupuncture combined with TMS is a periodic treatment, if each treatment protocol is treated separately as a sample, the correlation between multiple treatments for the same patient will be ignored. Furthermore, different patients require different numbers of treatments, and the therapeutic effect is not linearly related to the number of treatments. Therefore, the key variable of "number of treatments" must be considered when establishing the random forest regression model. Based on clinical results, the natural inflection point on most efficacy curves occurs after 6 treatments. Based on this, the number of treatments can be divided into the initial response period (1 treatment), the cumulative reinforcement period (2-6 treatments), and the plateau maintenance period (7 treatments or more), and training is performed for each level.

[0046] The sample features and labels selected for training each level are different. For the initial reaction period, the training features of the random forest are acupuncture text features, and the labels are weighted sums of three types of effect data: intensity correlation index, time-series correlation index, and coordination correlation index, along with patient satisfaction. The weights are shown in Table 6.

[0047] Table 6. Feature Classification and Weight Allocation Related to Efficacy Weights

[0048] For the cumulative enhancement period and the plateau maintenance period, the sample features need to be processed to obtain sample features and labels by considering the correlation between multiple treatments, including acupuncture text features and transcranial magnetic stimulation features. The processing methods are shown in Table 7.

[0049] Table 7 Features and Preprocessing Methods

[0050] Based on Tables 6 and 7, the random forest regression model was trained for the initial reaction period, the cumulative reinforcement period, and the plateau maintenance period, respectively. The training method is as follows: Step S301: Construct feature and label samples and divide them into training and test sets; Step S302: Initialize the random forest regression model, including the number of decision trees in the forest, the maximum depth of each decision tree, the minimum number of samples required for internal node repartitioning, the minimum number of samples required for leaf nodes, the maximum number of features considered for each decision tree, and the random seed; Step S303: Use training set samples to train the random forest model, and train each tree using randomly sampled samples and features. Step S304: Using the test set data, evaluate the model performance using mean squared error.

[0051] In step S302, each decision tree in the forest is trained as follows: Step S3021: Randomly select a subset of samples with replacement from all training samples; Step S3022: At each node of the tree, a subset of features is randomly selected from all features, and the best features and split points are selected from them to divide the data. The goal is to minimize the variance of the labels of the child nodes after splitting. Step S3023: Recursively repeat steps S3021 and S3022 until the stopping condition is met.

[0052] The difference between step S400 and step S300 is that step S400 features acupuncture text features, process text features, process image features, and features extracted from effect data, with labels including hotspot localization and working parameters. Therefore, the optimal acupuncture combined with transcranial magnetic stimulation is found using a backpropagation method. Since the random forest regression model cannot be directly solved, it is transformed into an optimization problem: In the database, a hotspot location and working parameters are sought so that when combined with known needle acupuncture text features, process text features, and process image features, the model predicts the most desired effect data.

[0053] Based on the above optimization problem, the specific process of step S400 is as follows: Step S401: Define the search space for hotspot location and working parameters, and generate candidate solutions within the search space. Step S402, for the first i One candidate scheme, and the features required to construct the random forest model. T i,t Label prediction is performed in the corresponding level of the random forest model to obtain the prediction results. Y pred,i,t ; Step S403, regarding the prediction effect Y pred,i,t The corresponding features are broken down into static features, decision variables, and dynamic features. The decision variables are hotspot location and operating parameters. The static features, decision variables, and prediction performance are also considered. Y pred,i,t Directly copy to predict future states S i,t+1 In this process, dynamic features are written into the prediction of future states after being made predictable. S i,t+1 middle; Step S404, predict the future state S i,t+1The input is fed into a multidimensional value function for calculation, and the decision variable corresponding to the maximum output value is selected as the solution and output.

[0054] In step S402, when selecting a transcranial magnetic stimulation (TMS) scheme for the first time, since the random forest model only has acupuncture text features, the remaining features are set to default values ​​before prediction when performing reverse prediction.

[0055] In step S403, static features refer to features obtained from data that remain constant during a single treatment, decision variables refer to hotspot location and operating parameters, and dynamic features are features obtained from data that changes with each TMS treatment. In this embodiment, acupuncture text features are used as static features, and the remaining features are dynamic features. After the above analysis, the acupuncture text features, as well as the hotspot location, operating parameters, and effect data from the transcranial magnetic stimulation features, are all known, and the predicted values ​​of the process data can be obtained using a random forest model. The difference between this and the random forest model in step S300 is that, when training the random forest model, the features selected are the acupuncture text features, as well as the features extracted from the hotspot location, operating parameters, and effect data, while the labels are the process data. The trained random forest model is then used to predict future states. S i,t+1 The process data obtained from the prediction of static features and decision variables already written in the system will be used to write the features involved in the predicted process data into the prediction of future states. S i,t+1 middle.

[0056] The multidimensional value function described in step S404 is used to evaluate and predict future states. S i,t+1 The comprehensive value of a multidimensional value function includes multiple dimensions such as efficacy, efficiency, trends, and safety. A method for constructing this multidimensional value function is as follows: Step S4041: Establish therapeutic value based on efficacy data V efficacy Specifically, this involves normalizing the features obtained from the effect data and then performing a weighted summation. Step S4042: Establish efficiency value based on operating parameters V efficiency Specifically, this involves normalizing the features obtained from the working parameters and then performing a weighted summation. Step S4043: Establish trend value based on effect data trends V momentum Specifically, this involves calculating the efficacy value of the most recent treatments. V efficacy The slope; Step S4044: Establish a safety threshold based on process data. V safety Specifically, a safety threshold is set, and a quadratic penalty function output value is calculated for features that exceed the threshold. Step S4045: Establish a multidimensional value function V ( S ), V ( S ) = We × V efficacy + Wf × V efficiency + Wm × V momentum + Ws × V safety , in, We , Wf , Wm , Ws The weights for each dimension.

Claims

1. A method for selecting acupuncture combined with transcranial magnetic stimulation based on machine learning, characterized in that, The method comprises the following steps: Step S100, acupuncture data of an object is recorded to obtain acupuncture text features; the acupuncture data comprises acupuncture object data and acupuncture operation data, wherein the acupuncture object data comprises gender, age, disease name, symptoms, medical history, and living habits, and the acupuncture operation data comprises body position, acupoint, acupuncture sequence, needle insertion, needle movement, and duration; Step S200, transcranial magnetic stimulation data of the object after acupuncture is obtained through multiple transcranial magnetic stimulations, the transcranial magnetic stimulation data comprises hotspot positioning, working parameters, process data, and effect data, and transcranial magnetic stimulation features are obtained, wherein the process data comprises image data and electrical signal data; Step S300, an association between the acupuncture text features and the transcranial magnetic stimulation features is established, a database for storing multiple acupuncture combined transcranial magnetic stimulation schemes is constructed, and a hierarchical random forest regression model is selected for training, wherein the hierarchical random forest regression model is divided into layers according to the number of transcranial magnetic stimulations, and the features of the random forest regression model comprise features obtained by using the acupuncture data, the hotspot positioning, the working parameters, and the process data, and the label is a feature obtained by the effect data; Step S400, the hotspot positioning and the working parameters are obtained as the acupuncture combined transcranial magnetic stimulation scheme by using the reverse prediction method according to the actual acupuncture data, the process data, and the effect data.

2. The method of claim 1, wherein, The electrical signal data in step S200 is obtained by electromyography reading, and electrical signal process text features are obtained, wherein the process text features comprise time domain features, frequency domain features, and time sequence features of the electrical signal.

3. The method of claim 2, wherein, The image data in step S200 is obtained by an image acquisition device with a perspective function, and structural motion features and image time sequence features are obtained by the image data, wherein the structural motion feature acquisition method comprises the following steps: Step S211, a swallowing process video obtained by dynamic contrast examination is converted into a frame image sequence; Step S212, a deep learning model is used for semantic segmentation to identify key structures; Step S213, a key point tracking algorithm is used to track the motion of the key structures in consecutive frames; Step S214, key structure motion data is extracted and quantified into numerical indicators as structural motion features.

4. The method of claim 3, wherein, The interference features in step S200 are deleted, and the interference feature acquisition method comprises the following steps: Step S221, a motion process is divided into a plurality of consecutive independent event points; Step S222, the structural motion features and the process text features are divided into a plurality of groups according to the independent event points, and each independent event point contains a group of structural motion features and process text feature pairs; Step S223, calculate the Pearson correlation coefficient between the brain region activation intensity and the structural motion features r 1; Step S224, calculate the Pearson correlation coefficient between the brain region activation intensity and the process text features r 2; Step S225, deleting the Pearson correlation coefficient r 1 < 0.7 and r 2 < 0.7 corresponding structure of the motion characteristics and process text feature pairs.

5. The method of claim 4, wherein, The features obtained by the image data and the electrical signal data are spliced into a long process data feature vector in step S200.

6. The method of claim 5, wherein, The features extracted according to the effect data comprise intensity correlation features, time sequence correlation features, and coordination correlation features; wherein The time sequence correlation feature is the difference between the starting point of the transcranial magnetic stimulation activation and the initial acquisition time of the process data feature vector; The intensity correlation feature is the Pearson correlation coefficient between the process text features and the structural motion features in a period. The coordination-related features include muscle pair latency, which is the time difference between the onset of contraction of two different muscles as read from electromyography, and movement pair latency, which is the time difference between the onset of physical movement of two different key structures in the image data.

7. The method of claim 1, wherein, The specific process of step S400 includes: Step S401, defining the search space of hot spot positioning and working parameters, and generating candidate schemes within the search space range; Step S402, for the first i candidate, the features required for constructing the random forest model T i,t , label prediction is performed in the corresponding level of the random forest model, and the prediction effect is obtained Y pred,i,t ; Step S403, for the predicted effect Y pred,i,t The corresponding feature is divided into static features, decision variables and dynamic features, and the static features, decision variables and predicted effects Y pred,i,t Directly copied to the predicted future state S i,t+1 In the dynamic feature is written into the predicted future state after prediction S i,t+1 In which the decision variable is hot spot positioning and working parameter, the static feature is acupuncture text feature, and the dynamic feature is the feature obtained by process data; Step S404, predicting the future state S i,t+1 The input is calculated in the multi-dimensional value function, and the decision variable corresponding to the maximum value of the output is selected as the scheme and output.

8. The method of claim 7, wherein, The prediction of dynamic features in step S403 adopts a random forest model, and the features of the random forest model training process are obtained through acupuncture data, hot spot positioning, working parameters and effect data, and the label is obtained through process data.

9. The method of claim 7, wherein, The multi-dimensional value function establishment process in step S404 includes: Step S4041, establishing the therapeutic effect value based on the effect data V efficacy , specifically, weighted sum after normalization of the features obtained from the effect data; Step S4042, establishing the efficiency value based on the working parameter V efficiency Specifically, the feature obtained from the working parameter is normalized and then weighted and summed. Step S4043, establishing a trend value based on the effect data trend V momentum , specifically calculating the slope of the last several times of efficacy value V efficacy ; Step S4044, establishing a security value based on the process data V safety Specifically, a security threshold is set, and a feature exceeding the security threshold is calculated by a quadratic penalty function to output a value. Step S4045, establishing a multi-dimensional value function V S ),​ V ( S ) = We × V efficacy + Wf × V efficiency + Wm × V momentum + Ws × V safety , wherein, We , Wf , Wm , Ws are the weights for each dimension.

10. The method of claim 7, wherein, In step S402, default values are set for features without assigned values.

Citation Information

Patent Citations

  • Multi-modal stimulation system and multi-modal stimulation method

    CN112206416A

Cited By

  • An interactive acupuncture therapy brain-computer interface model training system and method

    CN122153470A