Thyroid nodule classification system based on ultrasonic radio frequency signals
Through the thyroid nodule classification system based on ultrasonic radio frequency signals, using neural network model and dynamic weight generation layer technologies, the ultrasonic radio frequency signals are directly analyzed in-depth, solving the problems of information loss and noise interference in traditional methods, and achieving high-precision thyroid nodule classification.
Patent Information
- Application Number
- CN202411913954.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-24
- Publication Date
- 2025-05-27
- Estimated Expiration
- 2044-12-24
AI Technical Summary
Traditional ultrasonic two-dimensional grayscale images have problems with information loss in thyroid nodules diagnosis, and the high-dimensional complexity and noise interference processing efficiency of ultrasonic radio frequency signals are inefficient.
The thyroid nodule classification system based on ultrasonic radio frequency signals is adopted to directly analyze the original ultrasonic radio frequency signals through neural network models to avoid information loss during image reconstruction, and the dynamic weight generation layer and self-attention layer are used to dynamically adjust the weight of the feature vector to improve the ability to capture key information.
It significantly improves the accuracy and reliability of high-precision classification of thyroid nodules, reduces the need for manual intervention, and improves diagnostic efficiency and accuracy.
Smart Images

Figure CN120046031A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image processing and computer vision technology, and in particular to a thyroid nodule classification system based on ultrasonic radio frequency signals. Background Art
[0002] Thyroid nodules are a common and critical disease among thyroid diseases. The accurate assessment of their prognosis is of vital importance for the formulation of scientific and reasonable clinical treatment plans. Traditionally, doctors mainly rely on ultrasonic two-dimensional grayscale images to assess the prognosis of thyroid nodules, but this method has the problem of information loss.
[0003] The original radio frequency (RF) signal, as the original data source of ultrasound imaging, contains rich tissue characteristics and pathological information. It contains information on the depth axis and the time axis. The depth axis reflects the depth of the ultrasound beam penetrating the tissue, helping doctors understand the hierarchical structure of the target area; the time axis represents the time interval from the emission to the reception of the ultrasound beam. By processing this information, the physical characteristics of the tissue can be understood. However, traditional two-dimensional grayscale images often lose a lot of detailed information in the RF signal during the reconstruction process, which affects the accuracy and reliability of the diagnosis.
[0004] Direct in-depth analysis of RF signals is expected to fundamentally avoid information loss in the image reconstruction process and improve the accuracy of diagnosis. However, the high-dimensional complexity and noise interference characteristics of RF signals pose huge challenges to traditional signal analysis methods. In the past, the processing of RF signals often relied on manual feature extraction by doctors. This process not only requires doctors to have profound medical knowledge and rich clinical experience, but also requires them to spend a lot of time and energy to manually outline the area of interest. This processing method is not only inefficient, but also difficult to effectively cope with the recognition needs of massive data and complex patterns.
[0005] With the rapid development of deep learning technology, automated feature learning and classification methods based on RF signals have gradually emerged, bringing new breakthroughs in the prognosis of thyroid nodules. However, how to make full use of the high-dimensional information in RF signals, effectively eliminate the interference components in the noise, and avoid manual intervention to improve the efficiency and accuracy of diagnosis in this process is still a major technical problem that needs to be solved urgently. Summary of the invention
[0006] In view of the high-dimensional complexity and noise interference characteristics inherent in ultrasonic radio frequency signals, as well as the inevitable information loss problem in the image reconstruction process, the present invention proposes a thyroid nodule classification system based on ultrasonic radio frequency signals, which directly deeply analyzes the original ultrasonic radio frequency signals, thus effectively avoiding the information loss that may be introduced in the image reconstruction link, and can accurately capture and analyze the key information in the ultrasonic radio frequency signals, realizing high-precision classification of thyroid nodules. This not only significantly improves the accuracy and reliability of classification, but also greatly reduces the need for manual intervention, effectively solving the problem of low efficiency of manual processing in traditional methods.
[0007] A thyroid nodule classification system based on ultrasonic radio frequency signals disclosed by the present invention at least includes:
[0008] A data acquisition module, configured to acquire ultrasonic radio frequency signal data of thyroid nodules, preprocess the ultrasonic radio frequency signals to form a corresponding instance set one by one, and construct a labeled data set based on the instance set;
[0009] A model construction module, configured to construct a neural network model for feature classification of thyroid nodules, and train the neural network model based on the data set;
[0010] The neural network model at least includes:
[0011] A feature transformation layer, configured to extract features from the instances in the instance set, and add corresponding position encodings to form a first feature vector sequence;
[0012] A dynamic weight generation layer, configured to calculate the weight parameters of each first feature vector in the first feature vector sequence, and calculate a second feature vector through the weight parameters and the first feature vectors corresponding to the weight parameters, obtaining a second feature vector sequence;
[0013] A self-attention layer, configured to calculate a third feature vector sequence for the second feature vector sequence through a self-attention mechanism;
[0014] A classification probability fusion layer, configured to calculate the classification probabilities corresponding one by one to the third feature vectors in the third feature vector sequence, and fuse the classification probabilities to obtain an overall classification prediction result;
[0015] A classification module, configured to perform feature classification on thyroid nodules based on the trained neural network model and the input ultrasonic radio frequency signal data of thyroid nodules.
[0016] In a preferred embodiment, the acquisition of the ultrasonic radio frequency signal data of thyroid nodules specifically includes the following steps:
[0017] Step S101: Select a probe suitable for thyroid nodule examination;
[0018] Step S102: Locate the thyroid nodule in the ultrasonic image through the probe, and collect the static ultrasonic radio frequency signal data of the thyroid nodule;
[0019] Step S103: Slowly move the probe from the position where the thyroid nodule does not appear to the position where the thyroid nodule completely disappears, and collect the dynamic ultrasonic radio frequency signal data during the whole process.
[0020] In a preferred embodiment, the static ultrasonic radio frequency signal data includes the static ultrasonic radio frequency signal data of the standard transverse section and the standard longitudinal section of the thyroid nodule;
[0021] The dynamic ultrasonic radio frequency signal data includes the dynamic ultrasonic radio frequency signal data of the standard transverse section and the standard longitudinal section of the thyroid nodule.
[0022] In a preferred embodiment, the preprocessing of the ultrasonic radio frequency signal data to form a corresponding instance set specifically includes the following steps:
[0023] Step S201: Convert the collected ultrasonic radio frequency signal data into an m×n matrix data, where m is the number of depth intervals and n is the number of ultrasonic radio frequency signal lines;
[0024] Step S202: Perform data enhancement on the matrix data through one or more combinations of band-pass filtering, digital gain, envelope detection, or logarithmic compression to obtain a feature matrix;
[0025] Step S203: Sample from the feature matrix to form an instance set containing at least one instance, and the instance set is represented as:
[0026] {I 1 , I 2 , …, I n}
[0027] where I i represents the i-th instance.
[0028] In a preferred embodiment, Step S201 specifically includes the following steps:
[0029] Step S2011: Based on the maximum depth and sampling interval on the depth axis of the ultrasonic radio frequency signal data, determine the number of depth intervals m;
[0030] Step S2012: Based on the number of sampling points on the time axis of the ultrasonic radio frequency signal data, determine the number of ultrasonic radio frequency signal lines n;
[0031] Step S2013, create an initial matrix with dimensions of m×n, and set the elements within the initialized initial matrix;
[0032] Step S2014, extract the sampling values of each ultrasonic radio frequency signal line within the corresponding depth interval, and fill the extracted sampling values into the corresponding positions of the initial matrix to obtain m×n matrix data. The extraction is implemented using the following calculation method:
[0033] RF(t,d) = S t,d
[0034] where t is the time axis of the ultrasonic radio frequency signal data, d is the depth axis of the ultrasonic radio frequency signal data, and S t,d is the sampling value of the ultrasonic radio frequency signal data at time t and depth d.
[0035] In a preferred embodiment, step S202 specifically includes the following steps:
[0036] Step S2021, obtain a first feature matrix by subjecting the matrix data to band-pass filtering. The band-pass filtering is implemented using the following calculation method:
[0037]
[0038] where S t,d (f) is the spectrum of the ultrasonic radio frequency signal data, and h(f)df is the frequency response of the band-pass filter;
[0039] Step S2022, obtain a second feature matrix by subjecting the first feature matrix to digital gain. The digital gain is implemented using the following calculation method:
[0040]
[0041] where G is the gain factor;
[0042] Step S2023, obtain a third feature matrix by subjecting the second feature matrix to envelope detection. The envelope detection is implemented using the following calculation method:
[0043]
[0044] where is the Hilbert transform;
[0045] Step S2024, obtain the feature matrix by subjecting the third feature matrix to logarithmic compression. The logarithmic compression is implemented using the following calculation method:
[0046] S log (t,d) = log(1 + α·|S env (t,d)|)
[0047] Among them, α is the logarithmic compression coefficient.
[0048] In a preferred embodiment, the feature transformation layer includes a number of convolutional neural network layers. The convolutional neural network layers are used to extract features from the instances in the instance set, and corresponding position encoding is added to form the first feature vector sequence. The specific calculation method is as follows:
[0049] h i =W enc I i +PE i
[0050] H = [h 1 , h 2 , …, h n T
[0051] Among them, I i is the i-th instance in the instance set; W enc is the weight matrix of the convolutional neural network layer; PE i is the position encoding corresponding to the i-th instance; h i is the i-th first feature vector in the first feature vector sequence; H is the first feature vector sequence.
[0052] In a preferred embodiment, the dynamic weight generation layer includes a multi-layer perceptron connected to the output end of the feature transformation layer, and a softmax normalization layer connected to the output end of the multi-layer perceptron. The multi-layer perceptron is used to extract the features of the first feature vectors in the first feature vector sequence. The specific calculation method is as follows:
[0053] a i = MLP(h i )
[0054] The softmax normalization layer is used to convert the output a i of the multi-layer perceptron into a probability distribution, so as to obtain the weight parameters of each first feature vector in the first feature vector sequence. The specific calculation method is as follows:
[0055]
[0056] Among them, a i is the output of the i-th first feature vector in the first feature vector sequence in the multi-layer perceptron; w i is the weight parameter of the i-th first feature vector, and the w i satisfies the following relationship:
[0057]
[0058] Calculate the second feature vector through the weight parameter and the first feature vector corresponding to the weight parameter to obtain a sequence of second feature vectors. The specific implementation method is as follows:
[0059]
[0060] Wherein, is the i-th second feature vector, is the sequence of second feature vectors.
[0061] In a preferred embodiment, the self-attention layer calculates the query vector Q, the key vector K, and the value vector V by setting trainable projection matrices W Q , W K and W V , respectively. The specific calculation method is as follows:
[0062]
[0063] Wherein, is the sequence of second feature vectors,
[0064] Calculate the attention weights through the query vector Q and the key vector K, and calculate the sequence of third feature vectors based on the attention weights and the value vector V. The specific calculation method is as follows:
[0065]
[0066] Z = {z 1 , z 2 , …, z n}
[0067] Wherein, z i is the i-th third feature vector of the sequence of third feature vectors, and Z is the sequence of third feature vectors.
[0068] In a preferred embodiment, the classification probability fusion layer obtains the corresponding classification probabilities by passing each third feature vector in the sequence of third feature vectors through a classification head, and obtains the overall classification prediction probability by weighted averaging all the classification probabilities, so as to obtain the overall classification prediction result. The specific implementation method is as follows:
[0069]
[0070] Wherein, σ is the classification function softmax, is the overall classification prediction probability, and t i is the weight parameter for training the i-th third feature vector.
[0071] Compared with the prior art, a thyroid nodule classification system based on ultrasonic radio frequency signals disclosed by the present invention has the following beneficial effects:
[0072] (1) The thyroid nodule classification system disclosed by the present invention includes a data acquisition module, a model construction module, and a classification module. The data acquisition module is used to acquire ultrasonic radio frequency signal data of thyroid nodules. The system directly uses ultrasonic radio frequency (RF) signals as the data source, avoiding information loss during the reconstruction process of traditional two-dimensional gray-scale images. The RF signals contain rich tissue characteristics and pathological information, which helps to more accurately classify the characteristics of thyroid nodules. The model construction module is used to construct a neural network model for classifying the characteristics of thyroid nodules and train the neural network model based on a data set. Through the constructed neural network model, features are automatically extracted from the RF signals and classified without the need for doctors to manually delineate regions of interest or extract features. This greatly improves the efficiency and accuracy of diagnosis, while reducing the requirements for doctors' professional knowledge and experience. The neural network model constructed by the model construction module of the present invention includes a feature transformation layer, a dynamic weight generation layer, a self-attention layer, and a classification probability fusion layer. The dynamic weight generation layer and the self-attention layer can dynamically adjust the weights of feature vectors and focus on the features that have a greater impact on the classification results. This helps to improve the model's ability to capture key information and further improve the accuracy of classification. The thyroid nodule classification system disclosed by the present invention realizes an end-to-end classification process from data acquisition to feature classification. This not only simplifies the classification process but also makes the entire process more standardized and controllable, helping to improve the consistency and reliability of classification results. The system can be expanded and optimized according to actual needs to meet the requirements of different medical institutions and data sets.
[0073] (2) In the data acquisition module of the thyroid nodule classification system based on ultrasonic radio frequency signals disclosed by the present invention, the thyroid nodule is located in the ultrasonic image through a probe, and static ultrasonic radio frequency signal data of the thyroid nodule is acquired, which can accurately capture the characteristics such as the shape, size, and boundary of the nodule, providing strong support for subsequent analysis and classification. The probe is slowly moved from the position where the thyroid nodule does not appear to the position where the thyroid nodule completely disappears, and dynamic ultrasonic radio frequency signal data during the whole process is acquired, which can comprehensively reflect the characteristics of the thyroid nodule at different positions and different angles, helping the neural network model to more accurately evaluate the nature and scope of the nodule. By combining static and dynamic ultrasonic radio frequency signal data, the neural network model can comprehensively evaluate and analyze the thyroid nodule, improving the accuracy and reliability of classification.
[0074] (3) The data acquisition module disclosed in the present invention preprocesses the ultrasonic radio frequency signal data to form a corresponding instance set, converts the acquired ultrasonic radio frequency signal data into m×n matrix data, and obtains the first feature matrix through band-pass filtering. Through band-pass filtering, the low-frequency and high-frequency noises in the ultrasonic radio frequency signal data can be effectively removed, and the signals within a specific frequency range related to thyroid nodules are retained, thereby improving the signal quality and highlighting the specific frequency components in the signal. These components are often related to the specific pathological characteristics of thyroid nodules and are helpful for subsequent feature extraction and analysis. The first feature matrix is obtained as the second feature matrix through digital gain. Through digital gain, the amplitude of the signal can be adjusted as needed, so that weak signals are enhanced, facilitating subsequent processing and analysis. The second feature matrix is obtained as the third feature matrix through envelope detection. Envelope detection can extract the amplitude envelope of the signal, that is, the instantaneous amplitude change of the signal, which is crucial for analyzing the characteristics such as the boundary and morphology of thyroid nodules. Through envelope detection, the complex ultrasonic radio frequency signal data can be simplified into more easily processed amplitude information, facilitating subsequent feature extraction and classification. The third feature matrix is obtained as the feature matrix through logarithmic compression. Logarithmic compression can compress the dynamic range of the signal into a smaller range, making the signal change more smoothly, facilitating observation and analysis. Through logarithmic compression, the contrast of the weak part in the signal can be enhanced, making the detailed information clearer, which helps to improve the accuracy of diagnosis. Logarithmic compression is a non-linear processing method that can better adapt to the non-linear characteristics of ultrasonic radio frequency signal data and improve the processing effect. Through a series of processing steps such as band-pass filtering, digital gain, envelope detection, and logarithmic compression, the quality of the ultrasonic radio frequency signal data can be significantly improved, providing strong support for subsequent feature extraction, classification, and diagnosis. The parameters in the entire processing flow (such as the frequency range of the band-pass filter, the gain factor, the logarithmic compression coefficient, etc.) can be adjusted according to the actual situation to adapt to the ultrasonic radio frequency signal data of different patients and improve the flexibility and adaptability of the processing.
[0075] (4) The dynamic weight generation layer disclosed in the present invention includes a multi-layer perceptron connected to the output end of the feature conversion layer, and a softmax normalization layer connected to the output end of the multi-layer perceptron. The multi-layer perceptron is used to extract the features of the first feature vector in the first feature vector sequence. Through the multi-layer perceptron (MLP), further extraction and conversion of the first feature vector can learn the complex relationships and non-linear features between the first feature vectors. The softmax normalization layer is used to normalize the output a of the multi-layer perceptron iIt is transformed into a probability distribution to obtain the weight parameters of each first eigenvector in the first eigenvector sequence. Weight parameters are dynamically assigned to each first eigenvector, and these weight parameters reflect the importance of each first eigenvector in the overall sequence. The dynamic weight mechanism allows the model to adjust the contribution degree of each first eigenvector according to the specific content of the input data, thereby improving the adaptability and expression ability of the model to the data. By introducing weight parameters, the model can more finely capture the key information and patterns in the sequence data. Brief Description of the Drawings
[0076] Figure 1 It is the overall flowchart of an embodiment of a thyroid nodule classification system based on ultrasonic radiofrequency signals according to the present invention;
[0077] Figure 2 It is the schematic diagram of the preprocessing of ultrasonic radiofrequency signal data in an embodiment of a thyroid nodule classification system based on ultrasonic radiofrequency signals according to the present invention;
[0078] Figure 3 It is the flowchart of the dynamic weight generation layer in an embodiment of a thyroid nodule classification system based on ultrasonic radiofrequency signals according to the present invention;
[0079] Figure 4 It is the visualization diagram after the preprocessing of ultrasonic radiofrequency signal data in an embodiment of a thyroid nodule classification system based on ultrasonic radiofrequency signals according to the present invention. Detailed Embodiment
[0080] In order to make the objectives, technical solutions and advantages of the present invention clearer and more understandable, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0081] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although some embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. On the contrary, these embodiments are provided to more thoroughly and completely understand the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not used to limit the protection scope of the present disclosure.
[0082] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the technical field to which this application belongs. The terms used in the specification of this application herein are only for the purpose of describing specific embodiments and are not intended to limit this application. The term "or / and" used herein includes any and all combinations of one or more of the related listed items.
[0083] In addition, in the present invention, descriptions such as "first", "second", etc. are for descriptive purposes only, and do not particularly refer to the order or sequence. Nor are they used to limit the present invention. They are merely used to distinguish components or operations described with the same technical terms, and should not be construed as indicating or implying their relative importance or implicitly indicating the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include at least one such feature. In addition, the technical solutions between various embodiments can be combined with each other, but it must be based on the ability of those of ordinary skill in the art to implement. When the combination of technical solutions results in contradictions or cannot be implemented, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection required by the present invention.
[0084] A thyroid nodule classification system based on ultrasonic radio frequency signals in this embodiment at least includes a data acquisition module, a model construction module, and a classification module.
[0085] The data acquisition module, as Figure 1 shown, is used to collect ultrasonic radio frequency signal data of thyroid nodules, preprocess the ultrasonic radio frequency signals to form a corresponding instance set one by one, and construct a labeled data set based on the instance set. The system directly uses ultrasonic radio frequency (RF) signals as the data source, avoiding information loss during the reconstruction process of traditional two-dimensional gray-scale images. RF signals contain rich tissue characteristics and pathological information, which helps to more accurately classify the characteristics of thyroid nodules.
[0086] In this embodiment, the steps of collecting ultrasonic radio frequency signal data of thyroid nodules specifically include the following steps:
[0087] Step S101: Select a probe suitable for thyroid nodule examination, which can ensure that the collected ultrasonic radio frequency signal data has higher professionalism and pertinence, and helps to more accurately reflect the pathological characteristics of thyroid nodules;
[0088] Step S102: Locate the thyroid nodule in the ultrasonic image through the probe and collect the static ultrasonic radio frequency signal data of the thyroid nodule. Collecting the static ultrasonic radio frequency signal data of the thyroid nodule can accurately capture the characteristics of the nodule such as its shape, size, and boundary, providing strong support for subsequent analysis and classification;
[0089] Step S103: Slowly move the probe from the position where the thyroid nodule does not appear to the position where the thyroid nodule completely disappears, and collect the dynamic ultrasound radiofrequency signal data during the whole process, which can comprehensively reflect the characteristics of the thyroid nodule at different positions and angles, and helps the neural network model to more accurately evaluate the nature and scope of the nodule. By combining the static and dynamic ultrasound radiofrequency signal data, the neural network model can comprehensively evaluate and analyze the thyroid nodule, improving the accuracy and reliability of classification.
[0090] In an embodiment shown in the present invention, the static ultrasound radiofrequency signal data includes the static ultrasound radiofrequency signal data of the standard transverse section and the standard longitudinal section of the thyroid nodule. The static ultrasound radiofrequency signal data of the standard transverse section and the standard longitudinal section includes the morphological characteristics for comprehensively evaluating the thyroid nodule, such as the size, shape, whether the edge is smooth, and whether the internal echo is uniform, etc. These information are of important value for the subsequent classification of the thyroid nodule. The dynamic ultrasound radiofrequency signal data includes the dynamic ultrasound radiofrequency signal data of the standard transverse section and the standard longitudinal section of the thyroid nodule. The dynamic ultrasound radiofrequency signal data contains the change information of the thyroid nodule in different states. By comparing the static and dynamic data, the system can more comprehensively understand the characteristics and changes of the thyroid nodule, thereby improving the accuracy of classification.
[0091] In this embodiment, the ultrasound radiofrequency signal data is preprocessed to form a corresponding instance set, which specifically includes the following steps:
[0092] Step S201: Convert the collected ultrasound radiofrequency signal data into an m×n matrix data, where m is the number of depth intervals and n is the number of ultrasound radiofrequency signal lines;
[0093] It should be noted that according to the settings of the external ultrasound acquisition device, the maximum depth and sampling depth of the ultrasound radiofrequency signal are determined. By dividing the maximum depth into m equally spaced depth intervals. The number of ultrasound radiofrequency signal lines n is determined by the number of probe scans or the number of sampling points on the time axis applicable to the examination of the thyroid nodule.
[0094] In this embodiment, step S201 specifically includes the following steps:
[0095] Step S2011: Based on the maximum depth and sampling interval on the depth axis of the ultrasound radiofrequency signal data, determine the number of depth intervals m;
[0096] Step S2012: Based on the number of sampling points on the time axis of the ultrasound radiofrequency signal data, determine the number of ultrasound radiofrequency signal lines n;
[0097] Step S2013: Create an initial matrix with a dimension of m×n and set the elements in the initial matrix;
[0098] Step S2014, extract the sampling values of each ultrasonic radio frequency signal line in the corresponding depth range, and fill the extracted sampling values into the corresponding positions of the initial matrix to obtain m×n matrix data. The extraction is implemented by the following calculation method:
[0099] RF(t,d)=S t,d
[0100] where t is the time axis of the ultrasonic radio frequency signal data, d is the depth axis of the ultrasonic radio frequency signal data, and S t,d is the sampling value of the ultrasonic radio frequency signal data at time t and depth d.
[0101] Step S202, perform data enhancement on the matrix data through one or more combinations of band-pass filtering, digital gain, envelope detection, or logarithmic compression to obtain a feature matrix;
[0102] It should be noted that through a series of processing steps such as band-pass filtering, digital gain, envelope detection, and logarithmic compression, the quality of the ultrasonic radio frequency signal data can be significantly improved, providing strong support for subsequent feature extraction, classification, and diagnosis. The parameters in the entire processing flow (such as the frequency range of the band-pass filter, the gain factor, the logarithmic compression coefficient, etc.) can be adjusted according to the actual situation to adapt to the ultrasonic radio frequency signal data of different patients and improve the flexibility and adaptability of the processing. In this embodiment, Step S202, as Figure 2 shown, specifically includes the following steps:
[0103] Step S2021, perform band-pass filtering on the matrix data to obtain a first feature matrix. The band-pass filtering is implemented by the following calculation method:
[0104]
[0105] where S t,d (f) is the spectrum of the ultrasonic radio frequency signal data, and h(f)df is the frequency response of the band-pass filter;
[0106] By performing band-pass filtering, low-frequency and high-frequency noises in the ultrasonic radio frequency signal data can be effectively removed, and the signals within a specific frequency range related to thyroid nodules can be retained, thereby improving the signal quality and highlighting the specific frequency components in the signal. These components are often related to the specific pathological characteristics of thyroid nodules and are helpful for subsequent feature extraction and analysis.
[0107] Step S2022, perform digital gain on the first feature matrix to obtain a second feature matrix. The digital gain is implemented by the following calculation method:
[0108]
[0109] Among them, G is the gain factor;
[0110] Through digital gain, the amplitude of the signal can be adjusted as needed, so that weak signals are enhanced, the amplitude differences between different signal sources are balanced, or specific output requirements are met, facilitating subsequent processing and analysis.
[0111] Step S2023, obtaining a third feature matrix by envelope detection of the second feature matrix, and the envelope detection is implemented by the following calculation method:
[0112]
[0113] Among them, is the Hilbert transform;
[0114] Envelope detection can extract the amplitude envelope of the signal, that is, the instantaneous amplitude change of the signal, which is crucial for analyzing the characteristics such as the boundary and morphology of thyroid nodules. Through envelope detection, the complex ultrasonic radio frequency signal data can be simplified into more easily processed amplitude information, facilitating subsequent feature extraction and classification.
[0115] Step S2024, obtaining the feature matrix by logarithmic compression of the third feature matrix, and the logarithmic compression is implemented by the following calculation method:
[0116] S log (t, d) = log(1 + α·|S env (t, d)|)
[0117] Among them, α is the logarithmic compression coefficient.
[0118] Logarithmic compression can compress the dynamic range of the signal into a smaller range, making the signal change more smoothly, facilitating observation and analysis. Through logarithmic compression, the contrast of the weak part in the signal can be enhanced, making the detailed information clearer, which helps to improve the accuracy of diagnosis. Logarithmic compression is a non-linear processing method, which can better adapt to the non-linear characteristics of ultrasonic radio frequency signal data and improve the processing effect. As Figure 4 shown, the original ultrasonic radio frequency signal data is band-pass filtered to remove noise, then digital gain adjustment is applied to enhance the amplitude of the signal, then envelope detection is performed to extract the envelope information of the signal, and finally logarithmic compression is applied to obtain the feature matrix, and the visualization result of the feature matrix.
[0119] Step S203, sampling from the feature matrix to form an instance set containing at least one instance, and the instance set is expressed as:
[0120] {I 1 , I 2 , …, I n}
[0121] Among them, I i represents the i-th instance.
[0122] In this embodiment, the sampling sliding window method samples at least one instance from the feature matrix, and is specifically implemented by the following method:
[0123] Based on the number of rows and columns of the instance, a window is defined;
[0124] The window starts from the upper left corner of the matrix and slides on the feature matrix according to the specified stride;
[0125] At each slide, the elements within the window are extracted as an instance;
[0126] Repeat the above process until the window slides across the entire feature matrix.
[0127] In this embodiment, each instance contains ultrasonic radio frequency (RF) signal information within a certain depth range. A number of instances form an instance set, and a corresponding label is added to each instance set. A number of instance sets with added labels form a labeled data set. Preferably, the data set is divided into a training set and a validation set, and the ratio of the training set to the validation set is 4:1.
[0128] The model construction module is used to construct a neural network model for feature classification of thyroid nodules and train the neural network model based on the data set; the neural network model at least includes:
[0129] The feature transformation layer is used to extract features from the instances in the instance set and add corresponding position encodings to form a first feature vector sequence;
[0130] The dynamic weight generation layer is used to calculate the weight parameters of each first feature vector in the first feature vector sequence, and calculate the second feature vector through the weight parameters and the first feature vectors corresponding to the weight parameters to obtain a second feature vector sequence;
[0131] The self-attention layer is used to calculate a third feature vector sequence for the second feature vector sequence through the self-attention mechanism;
[0132] The classification probability fusion layer is used to calculate the classification probabilities corresponding one by one to the third feature vectors within the third feature vector sequence and fuse the classification probabilities to obtain an overall classification prediction result.
[0133] The dynamic weight generation layer and the self-attention layer can dynamically adjust the weights of the feature vectors and focus on the features that have a greater impact on the classification results. This helps to improve the model's ability to capture key information and further enhance the accuracy of classification. Through the constructed neural network model, features are automatically extracted from the RF signals and classified without the need for doctors to manually delineate the regions of interest or perform feature extraction. This greatly improves the efficiency and accuracy of diagnosis while reducing the requirements for doctors' professional knowledge and experience.
[0134] In this embodiment, as Figure 3 shown, the feature transformation layer includes several convolutional neural network layers. The convolutional neural network layers are used to extract features from the instances in the instance set and add the corresponding positional encoding to form the first feature vector sequence. The specific implementation is as follows:
[0135] h i =W enc I i +PE i
[0136] H=[h 1 ,h 2 ,…,h n T
[0137] where, I i is the i-th instance in the instance set; W enc is the weight matrix of the convolutional neural network layer; PE i is the positional encoding corresponding to the i-th instance; h i is the i-th first feature vector in the first feature vector sequence; H is the first feature vector sequence. Through the feature transformation layer, more useful and higher-level feature representations are extracted from the original feature matrix, and by adding positional encoding, the sensitivity of the constructed neural network model to position is enhanced, the relative positions between different instances are learned, and the expressive ability and generalization ability of the model are enhanced.
[0138] In this embodiment, the dynamic weight generation layer includes a multi-layer perceptron connected to the output end of the feature transformation layer, and a softmax normalization layer connected to the output end of the multi-layer perceptron. The multi-layer perceptron is used to extract the features of the first feature vectors in the first feature vector sequence. By further extracting and transforming the first feature vectors through the multi-layer perceptron (MLP), the complex relationships and non-linear features between the first feature vectors can be learned. The specific implementation is as follows:
[0139] a i =MLP(h i )
[0140] The softmax normalization layer is used to convert the output a of the multi-layer perceptron i into a probability distribution, thereby obtaining the weight parameter of each first feature vector in the first feature vector sequence, dynamically assigning weight parameters to each first feature vector, and these weight parameters reflect the importance of each first feature vector in the overall sequence. The following calculation method is adopted to achieve this:
[0141]
[0142] where a i is the output of the multi-layer perceptron for the i-th first feature vector in the first feature vector sequence; w i is the weight parameter of the i-th first feature vector, and w i satisfies the following relationship:
[0143]
[0144] The second feature vector is calculated through the weight parameter and the first feature vector corresponding to the weight parameter to obtain the second feature vector sequence. The following method is specifically adopted to achieve this:
[0145]
[0146] where is the i-th second feature vector, is the second feature vector sequence. The dynamic weight mechanism allows the model to adjust the contribution degree of each first feature vector according to the specific content of the input data, thereby improving the adaptability and expression ability of the model to the data. By introducing weight parameters, the model can more finely capture the key information and patterns in the sequence data.
[0147] In this embodiment, the self-attention layer calculates the query vector Q, the key vector K, and the value vector V by setting the trainable projection matrices W Q , W K and W V , respectively. The following calculation method is specifically adopted:
[0148]
[0149] where is the second feature vector sequence. The attention weights are calculated through the query vector Q and the key vector K, and the third feature vector sequence is calculated based on the attention weights and the value vector V. The following calculation method is specifically adopted:
[0150]
[0151] Z = {z 1 , z 2 , …, z n}}
[0152] where z i is the i-th third feature vector of the third feature vector sequence, and Z is the third feature vector sequence. Through the attention mechanism, the global and local features of the RF signal matrix are captured.
[0153] In this embodiment, the classification probability fusion layer obtains the corresponding classification probability for each third feature vector in the third feature vector sequence through the classification head, and obtains the overall classification prediction probability by the weighted average method for all the classification probabilities, so as to obtain the overall classification prediction result, which is specifically implemented by the following calculation method:
[0154]
[0155] where σ is the classification function softmax, is the overall classification prediction probability, and t i is the weight parameter of the trainable i-th third feature vector.
[0156] In this embodiment, in order to train and optimize the neural network model, the cross-entropy loss function is used as the objective function, and this function evaluates the prediction performance of the model according to the true label value. During the training process, the training set data is used to continuously adjust the hyperparameters of the network, aiming to improve the classification accuracy and effect. At the same time, in order to verify the generalization ability of the model and further optimize the model parameters, a validation set is introduced. In the validation stage, the cross-entropy loss function is also used to evaluate the performance of the model on unseen data, and the parameters are iteratively adjusted accordingly, in order to achieve better classification performance.
[0157] The classification module is used to classify the features of the thyroid nodule based on the trained neural network model through the input ultrasonic RF signal data of the thyroid nodule. The thyroid nodule classification system established in the embodiment shown in the present invention realizes an end-to-end classification process from data acquisition to feature classification. This not only simplifies the classification process, but also makes the whole process more standardized and controllable, which helps to improve the consistency and reliability of the classification results. The system can be extended and optimized according to actual needs to meet the requirements of different medical institutions and data sets.
[0158] In summary, the above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A thyroid nodule classification system based on ultrasonic radio frequency signals, characterized in that: At least: A data acquisition module, used for acquiring ultrasound radio frequency signal data of thyroid nodules, preprocessing the ultrasound radio frequency signals to form a one-to-one corresponding instance set, and constructing a labeled data set based on the instance set; A model building module, used to build a neural network model for feature classification of thyroid nodules, and train the neural network model based on the data set; The neural network model at least includes: A feature conversion layer, used for extracting features from instances in the instance set and adding corresponding position codes to form a first feature vector sequence; A dynamic weight generation layer, used to calculate a weight parameter of each first eigenvector in the first eigenvector sequence, and calculate a second eigenvector by using the weight parameter and the first eigenvector corresponding to the weight parameter to obtain a second eigenvector sequence; A self-attention layer, used to calculate the second feature vector sequence through a self-attention mechanism to obtain a third feature vector sequence; A classification probability fusion layer, used to calculate the classification probabilities corresponding to the third eigenvectors in the third eigenvector sequence, and fuse the classification probabilities to obtain an overall classification prediction result; The classification module is used to perform feature classification of thyroid nodules based on the trained neural network model and through the input ultrasonic radio frequency signal data of the thyroid nodules.
2. A thyroid nodule classification system based on ultrasonic radio frequency signals according to claim 1, characterized in that: The step of collecting the ultrasonic radio frequency signal data of the thyroid nodule specifically comprises the following steps: Step S101, selecting a probe suitable for thyroid nodule examination; Step S102, locating the thyroid nodule in the ultrasound image by using the probe, and collecting static ultrasound radio frequency signal data of the thyroid nodule; Step S103, slowly moving the probe from the position where the thyroid nodule does not appear to the position where the thyroid nodule completely disappears, and collecting dynamic ultrasonic radio frequency signal data during the whole process.
3. A thyroid nodule classification system based on ultrasonic radio frequency signals according to claim 2, characterized in that: The static ultrasound radio frequency signal data includes static ultrasound radio frequency signal data of a standard cross section and a standard longitudinal section of a thyroid nodule; The dynamic ultrasound radio frequency signal data includes dynamic ultrasound radio frequency signal data of a standard cross section and a standard longitudinal section of a thyroid nodule.
4. A thyroid nodule classification system based on ultrasonic radio frequency signals according to any one of claims 1 to 3, characterized in that: The preprocessing of the ultrasonic radio frequency signal data to form a one-to-one corresponding instance set specifically includes the following steps: Step S201, converting the collected ultrasonic radio frequency signal data into m×n matrix data, where m is the number of depth intervals and n is the number of ultrasonic radio frequency signal lines; Step S202, performing data enhancement on the matrix data by one or more combinations of bandpass filtering, digital gain, envelope detection or logarithmic compression to obtain a feature matrix; Step S203: sampling from the feature matrix to form an instance set including at least one instance, wherein the instance set is represented as: {I1,I2,…,I n } Among them, I i represents the i-th instance.
5. A thyroid nodule classification system based on ultrasonic radio frequency signals according to claim 4, characterized in that: The step S201 specifically includes the following steps: Step S2011, determining the number m of depth intervals based on the maximum depth and sampling interval on the depth axis of the ultrasonic radio frequency signal data; Step S2012, determining the number n of ultrasonic radio frequency signal lines based on the number of sampling points on the time axis of the ultrasonic radio frequency signal data; Step S2013, creating an initial matrix with a dimension of m×n, and setting and initializing the elements in the initial matrix; Step S2014, extracting the sampling value of each ultrasonic radio frequency signal line in the corresponding depth interval, and filling the extracted sampling value into the corresponding position of the initial matrix to obtain m×n matrix data, and the extraction is implemented by the following calculation method: RF(t,d)=S t,d Wherein, t is the time axis of the ultrasonic radio frequency signal data, d is the depth axis of the ultrasonic radio frequency signal data, S t,d is the sampling value of the ultrasonic radio frequency signal data at time t and depth d.
6. A thyroid nodule classification system based on ultrasonic radio frequency signals according to claim 5, characterized in that: The step S202 specifically includes the following steps: Step S2021, the matrix data is subjected to bandpass filtering to obtain a first characteristic matrix, wherein the bandpass filtering is implemented by the following calculation method: Among them, S t,d (f) is the frequency spectrum of the ultrasonic RF signal data, and h(f)df is the frequency response of the bandpass filter; Step S2022: obtain a second characteristic matrix by digitally gaining the first characteristic matrix, wherein the digital gain is calculated by the following method: Where G is the gain factor; Step S2023: Obtain a third characteristic matrix by performing envelope detection on the second characteristic matrix. The envelope detection is implemented by the following calculation method: in, is the Hilbert transform; Step S2024: logarithmically compress the third characteristic matrix to obtain the characteristic matrix. The logarithmic compression is implemented by the following calculation method: S log (t,d)=log(1+α·|S env (t,d)|) Where α is the logarithmic compression factor.
7. A thyroid nodule classification system based on ultrasonic radio frequency signals according to any one of claims 1-3 or 5-6, characterized in that: The feature conversion layer includes several convolutional neural network layers, which extract features from the instances in the instance set and add corresponding position codes to form the first feature vector sequence, which is specifically implemented by the following calculation method: h i =W enc I i +PE i H=[h1,h2,…,h n ] T Among them, I i is the i-th instance in the instance set; W enc is the weight matrix of the convolutional neural network layer; PE i is the position code corresponding to the i-th instance; i is the i-th first eigenvector in the first eigenvector sequence; H is the first eigenvector sequence.
8. A thyroid nodule classification system based on ultrasonic radio frequency signals according to claim 7, characterized in that: The dynamic weight generation layer includes a multi-layer perceptron connected to the output end of the feature conversion layer, and a softmax normalization layer connected to the output end of the multi-layer perceptron, wherein the multi-layer perceptron is used to extract the features of the first feature vector in the first feature vector sequence, and is implemented by the following calculation method: a i =MLP(h i ) The softmax normalization layer is used to convert the output a of the multi-layer perceptron i Convert it into a probability distribution, so as to obtain the weight parameter of each first eigenvector in the first eigenvector sequence, which is implemented by the following calculation method: Among them, a i is the output of the i-th first feature vector in the first feature vector sequence in the multilayer perceptron; w i is the weight parameter of the i-th first eigenvector, and the w i Satisfies the following relationship: The second eigenvector is calculated by using the weight parameter and the first eigenvector corresponding to the weight parameter to obtain a second eigenvector sequence, which is specifically implemented by the following method: in, is the i-th second eigenvector, is the second eigenvector sequence.
9. A thyroid nodule classification system based on ultrasonic radio frequency signals according to claim 8, characterized in that: The self-attention layer is constructed by setting a trainable projection matrix W Q , W K and W V , respectively calculate the query vector Q, key vector K and value vector V, and use the following calculation method: in, is the second eigenvector sequence, The attention weight is calculated by the query vector Q and the key vector K, and the third feature vector sequence is calculated based on the attention weight and the value vector V. Specifically, the following calculation method is used: Z={z1,z2,…,z n } Among them, z i is the i-th third eigenvector of the third eigenvector sequence, and Z is the third eigenvector sequence.
10. A thyroid nodule classification system based on ultrasonic radio frequency signals according to claim 9, characterized in that: The classification probability fusion layer obtains the corresponding classification probability by passing each third feature vector in the third feature vector sequence through the classification head, and obtains the overall classification prediction probability by weighted average method for all the classification probabilities, thereby obtaining the overall classification prediction result, which is specifically implemented by the following calculation method: Among them, σ is the classification function softmax, is the overall classification prediction probability, t i is a trainable weight parameter of the i-th third eigenvector.
Citation Information
Patent Citations
Neural network model and ultrasonic beam forming method based on neural network model
CN110874828A
Breast tumor screening method and device based on broadband ultrasonic echo characteristics
CN115227293A
Nail and breast multi-mode ultrasonic image classification method and system based on deep learning network
CN118470432A
Use of a method for processing data obtained by means of ultrasound
DE102017121581A1
Method for Improved Ultrasonic Detection
US20100063393A1
Cited By
Ultrasonic image semantic segmentation method and system fusing radio frequency signals
CN121121106A