Hyperspectral brain tumor intraoperative near-real-time classification method based on diffusion spatial spectrum feature domain learning model
Through the method based on the diffusion empty spectrum feature domain learning model, the problems of insufficient accuracy and high-dimensional data processing problems of traditional brain tumor classification methods are solved, and high-precision and low-complexity intraoperative brain tumor classification are achieved, which is suitable for complex scenarios and dynamic environments.
Patent Information
- Application Number
- CN202510315948.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-18
- Publication Date
- 2025-05-13
AI Technical Summary
The traditional intraoperative brain tumor classification methods have problems such as limited accuracy, reliance on subjective judgment, and insufficient real-time performance. The high-dimensional data processing problems and the 'dimensional disaster' phenomenon of hyperspectral images pose challenges to their application.
A nearly real-time intraoperative classification method of hyperspectral brain tumor based on diffusion null spectrum feature domain learning model is adopted. Through diffusion hidden spatial features and null spectrum feature learning, the learning class's non-offset ability is enhanced, and deep feature extraction and efficient classification are achieved.
It significantly improves the classification accuracy of hyperspectral images, reduces the computational complexity, enhances the adaptability to complex scenes, reduces manual intervention, and improves the computing efficiency of the system and the stability and reliability in practical applications.
Smart Images

Figure CN119992220A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of medical image processing and artificial intelligence technology, and in particular to a near real-time classification method for hyperspectral brain tumors during surgery based on a diffusion spatial spectrum feature domain learning model. Background Art
[0002] Rapid pathological classification of brain tumors is crucial to the smooth progress of surgery and patient prognosis. Accurately judging the nature and boundaries of brain tumors during surgery can help surgeons precisely remove diseased tissue while preserving normal tissue as much as possible and reducing the risk of postoperative complications. Rapid pathological classification not only improves the real-time decision-making ability of surgery, but also effectively shortens the operation time. However, traditional methods are limited by time, accuracy and subjective judgment, and it is difficult to meet the needs of complex cases. More efficient and reliable technical means are urgently needed to assist intraoperative decision-making.
[0003] Currently, intraoperative pathological classification mainly relies on rapid frozen section technology, where pathologists perform pathological analysis on tissue samples to help surgeons determine the nature and boundaries of tumors. However, this method is limited by the quality of sample processing and relies on the subjective judgment of pathologists, which may lead to a high risk of error.
[0004] Hyperspectral imaging technology, with its excellent spectral resolution, can provide rich spectral data and is an important tool in the field of medical imaging. However, the use of hyperspectral imaging technology for intraoperative brain tumor detection still faces many challenges, such as complex tissue structure, highly similar spectral features, and slight differences between tumors and normal tissues. In addition, the large amount of hyperspectral data, high measurement complexity, and strong correlation between bands make the amount of computation based on hyperspectral image analysis and processing large, which brings a great computational burden to the computer. In short, the high feature dimension, high redundancy, and high data volume of hyperspectral images greatly increase the difficulty of data analysis and easily cause the "dimensionality disaster" phenomenon.
[0005] Methods for brain tumor classification in near-real-time hyperspectral images during surgery can be roughly divided into several categories: algorithms based on traditional feature extraction and machine learning methods. Traditional feature methods include spectral angle mapping (SAM) and principal component analysis (PCA), which extract and classify features from spectral information in hyperspectral images. Machine learning methods such as support vector machine (SVM), random forest and K nearest neighbor (KNN) are applied to brain tumor detection. The detection accuracy is improved by classifying and modeling the extracted features. Due to the reliance on manually extracted features, the processing ability for high-dimensional data is limited. Therefore, the research focus in this field is on how to efficiently and quickly process hyperspectral image data and extract information related to brain tumor features from it. To this end, the application of deep learning technology provides a new solution for hyperspectral image processing. Deep learning algorithms can automatically extract complex features from a large number of hyperspectral images and perform efficient pattern recognition. Through training on massive data, the algorithm can significantly improve the recognition accuracy of tumor features and reduce the error rate of human judgment, thereby achieving more comprehensive and accurate tumor detection.
[0006] In summary, rapid intraoperative pathological classification of brain tumors plays a key role in the successful implementation of surgery and the prognosis of patients. Although traditional rapid frozen section technology and surgical navigation methods can assist intraoperative decision-making to a certain extent, they still have problems such as limited accuracy, reliance on subjective judgment, and lack of real-time performance. Hyperspectral imaging technology has become an important tool in the field of medical imaging due to its rich spectral information, but the difficulty in processing high-dimensional data and the "dimensionality disaster" phenomenon pose challenges to its application. Although traditional feature extraction and machine learning methods have shown certain advantages in hyperspectral image analysis, their ability to automatically extract complex features and process high-dimensional data is still insufficient. The introduction of deep learning technology provides a new direction for the rapid processing of hyperspectral images and the accurate classification of brain tumors. Through automated feature extraction and efficient pattern recognition, deep learning not only improves detection accuracy, but also effectively reduces human errors, laying the foundation for achieving near-real-time and high-precision brain tumor detection during surgery. Summary of the invention
[0007] In view of the defects of the prior art, the present invention provides a near real-time classification method for hyperspectral brain tumors during surgery based on a diffusion spatial spectrum feature domain learning model. By integrating the spatial spectrum feature learning capability of the diffusion model, it is possible to perform deep feature extraction and efficient classification of hyperspectral images acquired during surgery, thereby achieving rapid pathological diagnosis of brain tumors during surgery. This method is particularly suitable for real-time analysis of complex spectral and spatial structure information in an operating room environment, providing doctors with accurate intraoperative tumor classification and auxiliary decision-making for resection.
[0008] In order to achieve the above invention object, the technical solution adopted by the present invention is as follows:
[0009] A near real-time intraoperative classification method for hyperspectral brain tumors based on a diffuse spatial spectral feature domain learning model comprises the following steps:
[0010] Step 1: Collect hyperspectral brain tumor image data through the intraoperative near-real-time brain tumor hyperspectral standard image acquisition platform to construct a standard training dataset for brain tumor classification;
[0011] Step 2: Construct a hyperspectral brain tumor classification network model based on a diffuse spatial spectrum feature domain learning model. This model enhances the learning class non-bias capability by diffusing latent space features.
[0012] Step 3: training the hyperspectral brain tumor classification network model according to the brain tumor tissue hyperspectral classification dataset to obtain a trained hyperspectral brain tumor classification network model;
[0013] Step 4: Deploy the hyperspectral brain tumor classification network model in the hyperspectral standard image acquisition platform, classify the ex vivo brain tumor tissue through the hyperspectral brain tumor classification network model, and output the corresponding classification results. Finally, a rapid classification report of brain tumors is generated to achieve near real-time brain tumor detection during surgery.
[0014] Furthermore, step 1 includes the following sub-steps:
[0015] Step 1.1: Collect high-quality hyperspectral images of brain tumor tissue through the hyperspectral standard acquisition platform, and cut out a small piece of corresponding tissue specimen for pathological "gold standard" diagnosis as the image annotation result;
[0016] Step 1.2: Use the pathological "gold standard" diagnosis results to label the ex vivo brain tumor tissue and determine the different types of brain tumors;
[0017] Step 1.3: Randomly divide the standard data set into training data, validation data and test data with random seeds;
[0018] Step 1.4: Arrange the hyperspectral image files and the corresponding category files, calibrate the spectrum of brain tumors through standard reflectors, and form a standard training data set for brain tumor detection.
[0019] Furthermore, step 2 includes the following steps:
[0020] Step 2.1: Design a hyperspectral brain tumor classification network model based on a diffusion spatial-spectral feature domain learning model, integrate the forward generation and reverse inversion process of the diffusion model, combine spatial and spectral features, and gradually capture the potential distribution of the data;
[0021] Step 2.2: Based on the brain tumor classification training dataset, set the input and output sizes of the network and configure related parameters, including the input image size, number of output categories, learning rate, optimizer type, and loss function.
[0022] Furthermore, step 3 includes the following sub-steps:
[0023] Step 3.1: Set the number of training rounds for the hyperspectral brain tumor classification network model to ensure that the model is fully learned and the loss converges;
[0024] Step 3.2: Input the hyperspectral image training data set into the hyperspectral brain tumor classification network model constructed in step 2 for training. During the training process, the network continuously adjusts parameters to improve the detection effect.
[0025] Step 3.3: After training is completed, save the optimized network parameters and weight files.
[0026] Furthermore, step 4 includes the following sub-steps:
[0027] Step 4.1: Deploy the trained hyperspectral brain tumor classification network on the hyperspectral standard acquisition platform to achieve near real-time detection of brain tumors during surgery;
[0028] Step 4.2: Obtain the intraoperative hyperspectral image to be detected, and ensure that the acquisition method and instrument are a standard hyperspectral acquisition platform;
[0029] Step 4.3: Preprocess the hyperspectral image to be classified to ensure that the image patches meet the standard input specifications;
[0030] Step 4.4: Input the processed hyperspectral image into the trained diffusion spatial spectrum feature domain learning network;
[0031] Step 4.5: Obtain the classification results of the tumor segments, identify the brain tumor type, and generate a prediction analysis report of the brain tumor category.
[0032] Furthermore, the diffusion spatial-spectral feature domain learning model gradually adds noise through a forward diffusion process and simulates the evolution from high-dimensional feature space to latent space, and gradually restores clean features through a reverse denoising process to reconstruct samples with a similar distribution to the original data from the noise.
[0033] Furthermore, the diffusion spatial-spectral feature domain learning model introduces a diffusion model in the joint spatial-spectral feature space, and through the process of forward diffusion and reverse denoising, it strengthens the feature expression and data distribution modeling, thereby improving the classification performance.
[0034] Furthermore, the spectral range of the hyperspectral image data is 400-1000nm, the number of bands is 128 bands, and the spatial resolution is 696×520.
[0035] Furthermore, the classification network maps the feature vector to the output category through a global adaptive pooling layer and a fully connected layer, and finally outputs the prediction result of brain tumor classification.
[0036] Compared with the prior art, the advantages of the present invention are:
[0037] 1. Improve the accuracy of hyperspectral image classification
[0038] The present invention introduces a diffusion spatial-spectral feature domain learning model to more effectively extract the spatial and spectral features of images when processing hyperspectral images. The model can overcome the problem of insufficient classification accuracy of traditional methods in complex scenes and significantly improve the accuracy and robustness of classification results.
[0039] 2. Efficient data processing and feature extraction
[0040] Through deep feature extraction technology and optimization strategies, the invention can effectively extract important information from large amounts of data, reduce redundant features, and reduce computational complexity. In high-dimensional data processing, it can ensure a balance between processing speed and accuracy, and improve the overall system's computing efficiency.
[0041] 3. Optimize the model training process
[0042] The learning model designed by the present invention adopts advanced optimization algorithms during the training process, which can accelerate convergence, reduce the occurrence of overfitting, and improve training efficiency. In particular, the present invention can maintain high generalization ability and adaptability when the data volume is large and the samples are complex.
[0043] 4. Enhance the ability to adapt to complex scenarios
[0044] Traditional hyperspectral image classification methods often fail in complex scenes. However, the present invention introduces a learning strategy of diffuse spatial spectral feature domain, which enables the model to maintain good performance and significantly enhance adaptability when facing images with high noise, high dimensionality and complex background.
[0045] 5. Reduce manual intervention and optimize processing flow
[0046] The automatic feature extraction and classification method of the present invention reduces the need for manual intervention and can automatically classify and analyze images, which not only improves work efficiency, but also reduces human errors and optimizes the overall processing flow.
[0047] 6. Enhance stability and reliability in practical applications
[0048] The present invention fully considers the noise, interference and incompleteness of data in the real environment in the process of optimizing the algorithm and feature extraction. Therefore, in practical applications, it can effectively improve the stability and reliability of the model and ensure the accuracy of the classification results. It is particularly suitable for real-time monitoring in dynamic environments. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] Figure 1 A flow chart is constructed for a data set of an embodiment of the present invention;
[0050] Figure 2 A flowchart of constructing a diffusion spatial spectrum feature domain learning network according to an embodiment of the present invention;
[0051] Figure 3 This is a flow chart of training and testing in accordance with an embodiment of the present invention;
[0052] Figure 4 This is a diagram of a network structure based on diffuse spatial spectrum feature domain learning in an embodiment of the present invention;
[0053] Figure 5 This is a structural diagram of a diffusion spatial spectrum feature domain learning module according to an embodiment of the present invention;
[0054] Figure 6 The following is an example of experimental results of an embodiment of the present invention. DETAILED DESCRIPTION
[0055] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below with reference to the accompanying drawings and examples.
[0056] The present invention provides a near real-time classification method for hyperspectral brain tumors during surgery based on a diffuse spatial spectrum feature domain learning model, comprising the following steps:
[0057] Step 1: Collect hyperspectral brain tumor image data through the intraoperative near-real-time brain tumor hyperspectral standard image acquisition platform to construct a standard training dataset for brain tumor classification;
[0058] Step 2: Construct a classification model based on diffuse spatial spectrum feature domain learning. This model enhances the learning class non-bias capability by diffusing latent space features.
[0059] Step 3: Train the network model according to the brain tumor tissue hyperspectral classification dataset to obtain a trained hyperspectral brain tumor classification network;
[0060] Step 4: Deployed in the hyperspectral standard image acquisition platform, the trained model network is used to classify the ex vivo brain tumor tissue and output the corresponding classification results. Finally, a rapid classification report of brain tumors is generated to achieve near real-time brain tumor detection during surgery.
[0061] like Figure 1 As shown, step 1 includes the following sub-steps:
[0062] Step 1.1: Collect high-quality hyperspectral images of brain tumor tissues through the hyperspectral standard acquisition platform, and cut out a small piece of corresponding tissue specimens for pathological "gold standard" diagnosis as the image annotation result to ensure the accuracy of the training data set annotation;
[0063] Step 1.2: Use the pathological "gold standard" diagnosis results to label the ex vivo brain tumor tissue and determine the different types of brain tumors;
[0064] Step 1.3: To verify the effectiveness of the algorithm and the generalization ability of the model, the standard data set is randomly divided and random seed randomization is performed: 80% of the hyperspectral data is used as training data, the remaining 10% of the data is used as validation data, and 10% of the data is used as test data. The experiment is repeated 3 times to verify the generalization ability of the model;
[0065] Step 1.4: Arrange the hyperspectral image files and the corresponding category files, calibrate the spectrum of brain tumors through standard reflectors, and form a standard training data set for brain tumor detection.
[0066] like Figure 2 and 3 As shown, step 2 includes the following steps:
[0067] Step 2.1: Design a diffusion spatial-spectral feature domain learning model. This module integrates the forward generation and reverse inversion process of the diffusion model, combines spatial and spectral features, and gradually captures the potential distribution of the data. The model input port receives all the spectral information in the hyperspectral image, performs deep feature extraction and optimization on the data through spatial-spectral joint modeling, and finally generates analysis results for tumor categories at the output port;
[0068] Step 2.2: Based on the brain tumor classification training dataset, set the input and output size of the network and configure related parameters, including the input image size, the number of output categories, the learning rate, the optimizer type, and the loss function. The learning rate is set to an appropriate range (such as 0.001), the optimizer is Adam or SGD, and the loss function is cross entropy loss to ensure the optimization effect of the model in the classification task.
[0069] The step 3 includes the following sub-steps:
[0070] Step 3.1: Set the number of training rounds for the diffusion spatial spectral feature domain learning model to ensure that the model is fully learned and the loss converges;
[0071] Step 3.2: Input the hyperspectral image training data set into the network constructed in step 2 for training. During the training process, the network continuously adjusts parameters to improve the detection effect.
[0072] Step 3.3: After training is completed, save the optimized network parameters and weight files for subsequent use.
[0073] The step 4 includes the following sub-steps:
[0074] Step 4.1: Deploy on a standard hyperspectral acquisition platform to complete near real-time detection of brain tumors during surgery;
[0075] Step 4.2: Obtain the intraoperative hyperspectral image to be tested, ensure that the acquisition method and instrument are a standard hyperspectral acquisition platform, and that the software preprocesses the image in accordance with the training data;
[0076] Step 4.3: For the hyperspectral image to be classified, process the image according to the network input requirements and fill in the insufficient length and width to ensure that the image block meets the standard input specifications;
[0077] Step 4.4: Input the processed hyperspectral image into the trained diffusion spatial spectrum feature domain learning network;
[0078] Step 4.5: Obtain the classification results of the tumor segments, identify the brain tumor types, obtain the prediction analysis report of each brain tumor type, and provide it to the doctor for intraoperative decision support.
[0079] According to the above hyperspectral brain tumor intraoperative near real-time classification method, the following example process is performed:
[0080] Resection and processing of tumor tissue, cutting it into standard sizes (10-30mm 2 ) After the tissue pieces are collected, they are placed in the specified grid positions in the biological experiment tray in a standard manner, and the cut pieces are evenly arranged. Brain tumor tissue data are collected using a hyperspectral acquisition platform. The spectral range of the data is 400-1000nm, the number of bands is 128 bands, and the spatial resolution is 696×520. Standard reflector correction is used to ensure data consistency, and data from about 500 surgeries are accumulated to ensure that the spatial resolution of each cut piece meets 128×128, which helps to form a standardized hyperspectral image dataset for deep learning.
[0081] Build a hybrid spatial-spectral feature attention network, such as Figure 4 As shown in the figure, the whole network consists of 5 parts. The first part contains convolution layer, pooling layer and activation function. It is used to extract the spatial features of the input hyperspectral image. The convolution operation can be expressed by the following formula:
[0082]
[0083] Among them, f(x,y) is the output feature map, and w is the convolution kernel. Through the convolution layer, the model can extract the spatial features and spectral feature maps of the image layer by layer, highlighting the shallow texture feature information. The pooling layer is used for downsampling, reducing the size of the feature map, focusing on high-representation feature information, reducing computational complexity and improving the generalization ability of the model. Commonly used pooling methods include maximum pooling and average pooling. Using 2×2 maximum pooling, the pooling operation can be expressed as
[0084] Y i,j =MaxPooling(X 2i,2j ,X 2i+1,2j ,X 2i,2j+1 ,X 2i+1,2j+1 )
[0085] The activation function usually uses ReLU (Rectified Linear Unit), which can introduce nonlinearity and enable the model to learn more complex features. The formula of ReLU is:
[0086] Y = ReLU(x)
[0087] This nonlinear activation function can suppress negative values and highlight positive features, thereby helping the model learn more diverse features.
[0088] The second part is the convolution layer, pooling layer and activation function. The size of the convolution kernel is 256*3*3. The brain tumor hyperspectral image is deeply extracted and padding is performed to obtain a feature map of size 256*16*16. The feature map is further extracted to capture deep semantic features using the local characteristics of convolution.
[0089] The third part is to build a variational autoencoder module, which uses probability distribution to represent the latent space of the data, so that the model can not only extract high-dimensional features from the input, but also generate data similar to the input distribution. It mainly consists of two parts: the encoder and the decoder. By constraining and optimizing the distribution of the latent space, the model can effectively learn the implicit features of the data. It consists of two parts, the encoder and the decoder. The KL divergence is used to measure the difference between the latent distribution q(z|x) output by the encoder and the standard normal distribution p(z). The purpose is to make the latent representation generated by the encoder more consistent with the standard distribution, so that the model has smoothness in the latent space and enhances the generation ability. The formula for KL divergence is:
[0090] loss KL =KL(q(z|x)||p(z))
[0091] The reconstruction error is used to measure the difference between the sample Y generated by the decoder and the original input x, usually expressed as mean square error (MSE) or binary cross entropy (BCE). The formula for the reconstruction error is:
[0092] loss construction =-E q(z|x) [logp(x|z)]
[0093] Optimize through KL divergence and reconstruction error, the formula is:
[0094] loss total =αloss KL +βloss constructiion
[0095] Where q(z|x) is the approximate posterior and p(z) is the prior distribution. By minimizing this loss function, the variational autoencoder can learn the distribution of data in the latent space and generate new samples while maintaining the characteristics of the data.
[0096] Part IV, such as Figure 5 As shown in the figure, a diffusion spatial-spectral feature domain learning module is constructed. Combining spatial and spectral features, the diffusion model gradually learns the potential distribution of data, thereby effectively improving the classification performance. The core idea is to introduce a diffusion model in the joint spatial-spectral feature space, and strengthen feature expression and data distribution modeling through the process of forward diffusion and reverse denoising.
[0097] It consists of two processes: forward diffusion: adding noise to the spatial spectrum joint features, simulating the gradual evolution from high-dimensional feature space to latent space through multi-step iterations, gradually adding noise to the data, simulating the evolution from the real data distribution q(x t ) to the standard Gaussian distribution p(z). For each step t, the formula for forward diffusion is:
[0098]
[0099] Reverse denoising: Using the reverse diffusion process, we gradually recover clean feature representations from the noise and enhance the distinguishability of features. We gradually denoise from Gaussian noise and reconstruct samples with a distribution similar to the original data. The reverse process uses a neural network parameterized model p θ (x t-1 |x t )conduct:
[0100] p θ (x t-1 |x t )=N(x t-1 ;μ θ (x t ,t),∑ θ (xt ,t))
[0101] The diffusion spatial spectrum feature domain learning module captures the global distribution and local details of the data through the diffusion process, effectively enhancing the feature expression ability, thereby obtaining a more robust feature representation. At the same time, the denoising mechanism of reverse diffusion improves the purity of the features, eliminates unnecessary interference, and significantly improves the classification accuracy. In addition, the module has strong domain adaptation capabilities through feature domain alignment, and can perform well in multi-source data or different scenarios, making it suitable for cross-domain learning tasks. Thanks to diffusion modeling, the model also has a high generalization ability, can better adapt to new data, and improve robustness in practical applications.
[0102] The fifth part is the classification head, which consists of a global adaptive pooling layer and a fully connected layer, and is used to map the previous feature vector to the output category. Assuming the input vector is X, the global pooling layer reduces the feature map to a single vector, and usually uses global average pooling to summarize all spatial information. The formula is:
[0103] Y = AdaptiveAvgPooling(X)
[0104] Finally, the high-dimensional features are compressed into low-dimensional representations to capture the complex nonlinear relationships between features. At the same time, as the last layer of the model, it can also be directly combined with the loss function of the classification task (such as cross entropy loss) and continuously optimized through back propagation to further improve the accuracy of classification. In this way, the model can output the final prediction result of brain tumor classification based on the input data characteristics. Assume that the input vector is X i , the functional function is FC(·), then the output is:
[0105] Y=FC(X i )
[0106] Finally, the class probability analysis of brain tumor tissue is output, such as Figure 6 shown.
[0107] The process of training the network model includes the following steps: First, the hyperspectral images of brain tumors are input into the model, and the model is trained using a standardized training data set. The model performance is continuously improved by calculating the loss function, performing gradient backpropagation and iterative optimization, and finally saving the parameters and weight files obtained during the training process. Next, the trained model is used to verify the test data set and evaluate its effect. Finally, the trained model is deployed to the target platform for practical application.
[0108] The method according to the present invention described above can be implemented in hardware, firmware, or as software or computer code that can be stored in a recording medium (such as a CD ROM, RAM, floppy disk, hard disk or magneto-optical disk), or as computer code that is originally stored in a remote recording medium or a non-transitory machine-readable medium downloaded through a network and will be stored in a local recording medium, so that the method described herein can be stored in such software processing on a recording medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware (such as an ASIC or FPGA). It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component (e.g., RAM, ROM, flash memory, etc.) that can store or receive software or computer code, and when the software or computer code is accessed and executed by a computer, a processor, or hardware, the hyperspectral brain tumor intraoperative near real-time classification method described herein is implemented. In addition, when a general-purpose computer accesses the code for implementing the processing shown herein, the execution of the code converts the general-purpose computer into a dedicated computer for executing the processing shown herein.
[0109] Those skilled in the art will appreciate that the embodiments described herein are intended to help readers understand the implementation methods of the present invention, and should be understood that the protection scope of the present invention is not limited to such special statements and embodiments. Those skilled in the art can make various other specific variations and combinations that do not deviate from the essence of the present invention based on the technical revelations disclosed by the present invention, and these variations and combinations are still within the protection scope of the present invention.
Claims
1. A near real-time intraoperative classification method for hyperspectral brain tumors based on a diffuse spatial spectral feature domain learning model, characterized by: The following steps are involved: Step 1: Collect hyperspectral brain tumor image data through the intraoperative near-real-time brain tumor hyperspectral standard image acquisition platform to construct a standard training dataset for brain tumor classification; Step 2: Construct a hyperspectral brain tumor classification network model based on a diffuse spatial spectrum feature domain learning model. This model enhances the learning class non-bias capability by diffusing latent space features. Step 3: training the hyperspectral brain tumor classification network model according to the brain tumor tissue hyperspectral classification dataset to obtain a trained hyperspectral brain tumor classification network model; Step 4: Deploy the hyperspectral brain tumor classification network model in the hyperspectral standard image acquisition platform, classify the ex vivo brain tumor tissue through the hyperspectral brain tumor classification network model, and output the corresponding classification results; finally, generate a rapid classification report of the brain tumor to achieve near real-time brain tumor detection during surgery.
2. The hyperspectral brain tumor intraoperative near real-time classification method according to claim 1, characterized in that: Step 1 includes the following sub-steps: Step 1.1: Collect high-quality hyperspectral images of brain tumor tissue through the hyperspectral standard acquisition platform, and cut a small piece of corresponding tissue specimen for pathological "gold standard" diagnosis as the image annotation result; Step 1.2: Use the pathological "gold standard" diagnosis results to label the ex vivo brain tumor tissue and determine the different types of brain tumors; Step 1.3: Randomly divide the standard data set into training data, validation data and test data with random seeds; Step 1.4: Arrange the hyperspectral image files and the corresponding category files, calibrate the spectrum of brain tumors through standard reflectors, and form a standard training data set for brain tumor detection.
3. The hyperspectral brain tumor intraoperative near real-time classification method according to claim 1, characterized in that: Step 2 includes the following steps: Step 2.1: Design a hyperspectral brain tumor classification network model based on a diffusion spatial-spectral feature domain learning model, integrate the forward generation and reverse inversion process of the diffusion model, combine spatial and spectral features, and gradually capture the potential distribution of the data; Step 2.2: Based on the brain tumor classification training dataset, set the input and output sizes of the network and configure related parameters, including the input image size, number of output categories, learning rate, optimizer type, and loss function.
4. The hyperspectral brain tumor intraoperative near real-time classification method according to claim 1, characterized in that: Step 3 includes the following sub-steps: Step 3.1: Set the number of training rounds for the hyperspectral brain tumor classification network model to ensure that the model is fully learned and the loss converges; Step 3.2: Input the hyperspectral image training data set into the hyperspectral brain tumor classification network model constructed in step 2 for training. During the training process, the network continuously adjusts parameters to improve the detection effect. Step 3.3: After training is completed, save the optimized network parameters and weight files.
5. The hyperspectral brain tumor intraoperative near real-time classification method according to claim 1, characterized in that: Step 4 includes the following sub-steps: Step 4.1: Deploy the trained hyperspectral brain tumor classification network on the hyperspectral standard acquisition platform to achieve near real-time detection of brain tumors during surgery; Step 4.2: Obtain the intraoperative hyperspectral image to be detected, and ensure that the acquisition method and instrument are a standard hyperspectral acquisition platform; Step 4.3: Preprocess the hyperspectral image to be classified to ensure that the image patches meet the standard input specifications; Step 4.4: Input the processed hyperspectral image into the trained diffusion spatial spectrum feature domain learning network; Step 4.5: Obtain the classification results of the tumor segments, identify the brain tumor type, and generate a prediction analysis report of the brain tumor category.
6. The hyperspectral brain tumor intraoperative near real-time classification method according to any one of claims 1 to 5, characterized in that: The diffusion spatial-spectral feature domain learning model gradually adds noise through the forward diffusion process and simulates the evolution from high-dimensional feature space to latent space, and gradually restores clean features through the reverse denoising process to reconstruct samples similar to the original data distribution from the noise.
7. The hyperspectral brain tumor intraoperative near real-time classification method according to claim 6, characterized in that: The diffusion spatial-spectral feature domain learning model introduces a diffusion model in the joint spatial-spectral feature space. Through the process of forward diffusion and reverse denoising, it strengthens feature expression and data distribution modeling and improves classification performance.
8. The hyperspectral brain tumor intraoperative near real-time classification method according to claim 1, characterized in that: The spectral range of the hyperspectral image data is 400-1000nm, the number of bands is 128 bands, and the spatial resolution is 696×520.
9. The hyperspectral brain tumor intraoperative near real-time classification method according to claim 1, characterized in that: The classification network maps feature vectors to output categories through a global adaptive pooling layer and a fully connected layer, and finally outputs a prediction result of brain tumor classification.