An image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering

By introducing the PISA module and the spatial-frequency cross-domain residual coupling bottleneck layer into the MST++ model, and combining dynamic frequency domain filtering and customized loss functions, the hardware limitations of traditional hyperspectral imaging equipment and the robustness and computational complexity of the MST++ model under complex lighting conditions are solved, achieving efficient spectral reconstruction results.

CN122335581APending Publication Date: 2026-07-03NORTHEAST FORESTRY UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-04-28
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

Traditional hyperspectral imaging equipment is expensive and bulky, making it difficult to meet the real-time hyperspectral data acquisition needs of dynamic scenarios such as UAVs or satellite remote sensing. Furthermore, existing spectral reconstruction methods based on the MST++ model have poor robustness in complex lighting environments, making it difficult to effectively separate the coupling relationship between light intensity and material spectral waveforms. They also have high computational complexity and are difficult to model in a way that takes into account both global spatial and frequency characteristics.

Method used

By introducing the PISA module and the spatial-frequency cross-domain residual coupling bottleneck layer, combined with dynamic frequency domain filtering and customized loss functions, the robustness of the model to complex lighting environments is improved, enabling joint modeling of global spatial and frequency features and reducing computational overhead.

Benefits of technology

It significantly improves the fidelity and robustness of spectral reconstruction in complex environments, reduces computational overhead, adapts to remote sensing image processing at different resolutions, preserves high-frequency edge details and spectral curve topology, and enhances the model's generalization ability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122335581A_ABST
    Figure CN122335581A_ABST
Patent Text Reader

Abstract

This invention discloses an image spectral reconstruction method that integrates physical priors and dynamic frequency domain filtering. The method is as follows: Step 1, download a forest hyperspectral dataset; Step 2, extract the RGB bands from the hyperspectral data and synthesize them into an RGB image; Step 3, design and introduce a PISA module into the encoder and decoder; Step 4, construct a spatial-frequency cross-domain residual coupling bottleneck layer; Step 5, construct a customized hybrid loss function for UAV forestry scenarios; Step 6, integrate the PISA module, the spatial-frequency cross-domain residual coupling bottleneck layer, and the hybrid loss function into the MST++ framework to obtain an improved MST++ model. The improved MST++ model is deployed in a forest hyperspectral image reconstruction task to reconstruct newly input RGB images and obtain output hyperspectral data. This invention can improve the robustness of the model to complex lighting and shadows while maintaining the advantages of multi-stage cascading networks.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of computer vision and remote sensing image processing technology, and relates to a spectral reconstruction method based on an improved MST++ model. Background Technology

[0002] Hyperspectral images not only contain high-precision two-dimensional spatial information but also record continuous, high-spectral-resolution three-dimensional band information, enabling them to precisely reflect the intrinsic physicochemical properties of the measured substances. Therefore, hyperspectral imaging technology plays an irreplaceable role in many cutting-edge applications. For example, in remote sensing image processing tasks such as smart agriculture and forestry ecological monitoring, in-depth analysis of specific spectral bands in hyperspectral images allows for the non-destructive and accurate inversion of leaf chlorophyll content and assessment of vegetation growth stress and health status. Furthermore, it has great application potential in fields such as medical diagnosis, geological exploration, and materials testing.

[0003] Traditional hyperspectral imaging equipment typically relies on complex optical spectroscopic systems, which generally suffer from limitations such as high hardware costs, large size, and long imaging times, making it difficult to meet the real-time acquisition needs of hyperspectral data in dynamic scenarios such as UAVs or satellite remote sensing. To overcome these hardware limitations, computational methods for reconstructing hyperspectral images from RGB images have gradually become a research hotspot in this field, mainly categorized into prior-based methods and data-driven methods. Prior-based methods primarily utilize statistical information from images, such as the sparsity of spatial structure and the correlation between spectra, as constraints to solve inverse problems. Typical examples include dictionary learning, manifold learning, and Gaussian processes. However, these methods reveal significant shortcomings in practical applications: their model performance is highly dependent on manually designed prior assumptions and known camera spectral response functions. In complex and variable real-world remote sensing scenarios, when the camera parameters for acquiring RGB images are unknown, or when manually designed prior features are insufficient to cover the complex real-world conditions, the representational power of these methods will significantly decrease, easily leading to the loss of high-frequency details and a decline in spectral reconstruction accuracy. Given the limitations of prior-based methods, recent research has shifted entirely to data-driven deep learning methods. These methods do not rely on manually designed prior features or precisely calibrated camera parameters. Instead, they leverage the powerful feature extraction capabilities of neural networks to directly learn the complex nonlinear mapping relationship between broadband RGB images and narrowband hyperspectral data from a large amount of data, thereby achieving higher spectral reconstruction quality and robustness. Among numerous data-driven spectral reconstruction methods, Transformer-based models, with their powerful long-range spatial dependency modeling capabilities, have gradually become a leading direction in this field. The classic MST++ model, in particular, has been proposed and received widespread attention. This model, with its multi-stage cascaded progressive architecture and unique spectral self-attention mechanism, has established a highly representative baseline performance in the task of reconstructing hyperspectral images from RGB images, achieving good joint extraction of spatial details and spectral features.

[0004] However, despite the advantages that the native MST++ model shows on standard datasets, its infrastructure still reveals the following significant technical bottlenecks when facing complex and ever-changing real-world remote sensing applications:

[0005] First, the native MST++ model and its spectral attention mechanism are highly sensitive to complex lighting environments and lack effective perception of the physical nature of the spectral spectrum of matter.

[0006] The native MST++ model directly fits the absolute light intensity values ​​of image features when calculating attention. However, in real-world outdoor remote sensing environments, such as farmland or forests under natural light, there are often drastic changes in light intensity or large areas of shadow. The native multi-head self-attention mechanism cannot effectively decouple the ambient light intensity from the true spectral waveform of the material, leading to severe distortion of the reconstructed spectral curve under lighting interference. This results in a failure to accurately reflect the true spectral reflectance of the target material, and the model exhibits poor generalization ability and robustness under complex conditions.

[0007] Second, the native MST++ architecture has limitations in the joint modeling of spatial features and global frequency features, and it is difficult to balance the global receptive field and computational overhead.

[0008] In high-quality remote sensing spectral reconstruction tasks, it is necessary to capture both local fine-grained spectral interaction features and extract global spatial context information. The native MST++ primarily relies on spatial window attention or standard attention modules. When capturing long-range global spatial dependencies, the computational complexity increases exponentially with increasing image spatial resolution. Furthermore, the native architecture lacks explicit modeling of image frequency domain features and has insufficient adaptability to varying resolution inputs from remote sensing images, limiting its flexibility and inference efficiency in practical high-resolution remote sensing deployments. Summary of the Invention

[0009] To address the problems existing in the prior art, this invention provides an image spectral reconstruction method that integrates physical priors and dynamic frequency domain filtering. While maintaining the advantages of multi-stage cascading networks, it improves the robustness of the model to complex lighting and shadows, and achieves joint modeling of global spatial and frequency features with lower computational overhead, so as to meet the high-precision and flexible deployment requirements of large-scale remote sensing images.

[0010] The objective of this invention is achieved through the following technical solution:

[0011] An image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering includes the following steps:

[0012] Step 1: Download the forest hyperspectral dataset captured by the drone;

[0013] Step 2: Extract the RGB bands from the hyperspectral data, synthesize them into an RGB image, and divide the hyperspectral data and RGB image into 400... 512 small data pairs are used to divide the data into training, validation, and test sets.

[0014] Step 3: Design and introduce the PISA module into the encoder and decoder. The network topology of the PISA module includes a multi-branch linear mapping layer, a shape-aware flow computing branch, an intensity reconstruction flow computing branch, and an output fusion layer with position encoding.

[0015] Step 4: Construct a space-frequency cross-domain residual coupling bottleneck layer between the encoder and decoder in the multi-stage cascaded network;

[0016] Step 5: Construct a customized hybrid loss function for unmanned aerial vehicle (UAV) forestry scenarios;

[0017] Step 6: Integrate the PISA module from Step 3, the spatial-frequency cross-domain residual coupling bottleneck layer from Step 4, and the customized hybrid loss function from Step 5 into the MST++ framework to obtain the improved MST++ model. Use the improved MST++ model for end-to-end training on the training and validation sets from Step 2 to obtain the optimal improved MST++ model. Finally, deploy the trained improved MST++ model in the forest hyperspectral image reconstruction task and use the test set to reconstruct the newly input RGB image to obtain the output hyperspectral data.

[0018] Compared with the prior art, the present invention has the following advantages:

[0019] 1. This invention overcomes the limitations of traditional feature extraction mechanisms in terms of light sensitivity, significantly improving the fidelity of spectral reconstruction in complex forest environments. Addressing the issues of deep shadows and drastic light intensity fluctuations caused by terrain undulations and mutual occlusion of tree canopies in UAV remote sensing imaging, this invention innovatively introduces a PISA module into the encoder-decoder. This module, starting from physical mechanisms, constructs a dual-branch system of shape perception and intensity reconstruction. Through Standard Normal Transform (SNV), it physically decouples ambient light intensity from the true spectral waveform of the material, effectively eliminating baseline drift in reflectance. This enables the model to resist light interference, accurately reconstruct the true objective spectral characteristics of forest trees, and significantly reduce the relative error of spectral reconstruction.

[0020] 2. This invention achieves global spatial receptive field feature coverage with extremely low computational overhead and possesses excellent multi-source image resolution adaptation capabilities. Addressing the bottleneck of difficulty in capturing large-scale ground feature context dependencies in high-resolution UAV imagery and the excessively high computational complexity of global self-attention, this invention constructs a spatial-frequency cross-domain residual coupling bottleneck layer. By using a two-dimensional fast Fourier transform to convert spatial features to the frequency domain for dynamic filtering, it effectively achieves the macroscopic perception capability of global large-kernel convolution while avoiding computational overload. Furthermore, the module's built-in frequency domain resolution adaptive resampling mechanism allows the model to perfectly adapt to arbitrary image sizes acquired by different UAV sensors, greatly enhancing the algorithm's engineering feasibility and generalization capabilities.

[0021] 3. This invention effectively overcomes training instability under extreme lighting conditions and accurately preserves high-frequency edge details and spectral curve topology of the canopy. Addressing the stringent requirements of forestry biochemical parameter inversion, this invention customizes a hybrid loss function that integrates relative absolute error, spectral angle mapping, and spatial gradient. By forcibly injecting a safety truncation factor and employing a numerical overflow prevention mechanism, it completely resolves the gradient explosion problem caused by deep shadow regions and the abnormal calculation of the inverse cosine function, ensuring extremely high stability in end-to-end model training. Simultaneously, the L1 norm-based spatial gradient constraint effectively avoids the over-smoothing phenomenon common in deep networks, maximizing the preservation of sharp textures and key waveform features such as red edges at canopy boundaries. Attached Figure Description

[0022] Figure 1 This is a schematic diagram of a network architecture based on the improved MST++ model. Detailed Implementation

[0023] The technical solution of the present invention will be further described below with reference to the accompanying drawings, but it is not limited thereto. Any modifications or equivalent substitutions to the technical solution of the present invention that do not depart from the spirit and scope of the technical solution of the present invention should be covered within the protection scope of the present invention.

[0024] This invention provides an image spectral reconstruction method that integrates physical priors and dynamic frequency domain filtering, the method comprising the following steps:

[0025] Step 1: Download the forest hyperspectral dataset captured by the drone, specifically the co-aligned hyperspectral and LiDAR data collected in the drought-stressed European beech forest of the Rhӧn Biosphere Reserve. This hyperspectral data was processed into surface reflectance data and orthorectified by the NERC Field Spectroscopy Facility.

[0026] Step 2: Extract the RGB bands from the hyperspectral data, synthesize them into an RGB image, and divide the hyperspectral data and RGB image into 400... The data is divided into 512 small data pairs, which are then used to create a training set, a validation set, and a test set.

[0027] Step 3: Design and incorporate the PISA module into the encoder and decoder:

[0028] In this step, the network topology of the PISA module includes a multi-branch linear mapping layer, a shape-aware flow computation branch, an intensity reconstruction flow computation branch, and an output fusion layer with positional encoding. The specific construction and computation steps of the input features in the PISA module are as follows:

[0029] Step 3.1: Multi-branch linear mapping and multi-head spectral dimension rearrangement of input features:

[0030] Let the spatial-spectral joint feature map input to the PISA module be... ,in For batch size, and These represent the spatial height and width of the feature map, respectively. The number of spectral channels is a characteristic feature.

[0031] First, the feature map in the spatial dimension Perform a flattening operation to reshape it into a two-dimensional serialized feature. ,in This represents the total number of pixels in the space.

[0032] Subsequently, four parallel, unbiased linear projection layers are constructed to sequence the two-dimensional features. Mapping to a high-dimensional feature subspace, initial query features are generated respectively. Initial bond features Initial value characteristics and initial gating :

[0033]

[0034]

[0035]

[0036]

[0037] in, These are the learnable weight matrices for the four linear projection layers. For the number of attention heads, The feature dimensions for each attention head.

[0038] The feature tensor generated by the above mapping is transformed from dimension... Reshaping into a multi-head attention dimension Then, consider the last two dimensions of these four tensors, namely the spatial dimension. With spectral feature dimension Perform a transpose operation to construct a multi-head feature matrix expanded along the spectral channel dimension: query matrix Key matrix Value matrix and gating matrix And the dimensions of the above four matrices are all .

[0039] Step 3.2: Construct a shape-aware flow and perform standard normal transformation and shape attention calculation:

[0040] Transposed query matrix AND key matrix Input to the shape-aware flow branch.

[0041] First, a standard normal transformation (SNV) operator is constructed in the shape-aware flow branch to process the query matrix. Bond matrix In the spectral dimension Standardization processes are performed on each of the above:

[0042]

[0043]

[0044] in, ; and Each is a matrix and Along the spectral dimension Calculated local mean; and Along the spectral dimension Calculated local standard deviation; This is a set minimum constant.

[0045] Secondly, the matrix after processing by the SNV operator and In dimensions Perform L2 norm normalization to obtain the normalized matrix. and :

[0046]

[0047]

[0048] Constructing a structure with a learnable shape temperature coefficient The attention computation graph will normalize the bond matrix. Transpose of the normalized query matrix Perform matrix multiplication, multiplying the scalar by the aforementioned temperature coefficient. Then, activation is performed using the Softmax function, and the output dimension is... Shape Attention Matrix :

[0049]

[0050] Step 3.3: Construct the intensity recombination flow for dynamic gating aggregation:

[0051] In the intensity reorganization flow branch, the shape attention matrix output from step 3.2 is used. Compared with the value matrix generated in step 3.1 Perform matrix multiplication aggregation calculations.

[0052] At the same time, the gated matrix generated in step 3.1 Applying the Sigmoid activation function .

[0053] The attention aggregation result is combined with the activated gated features using a Hadamard product to generate a reconstructed feature matrix. :

[0054]

[0055] Subsequently, the recombined feature matrix Perform an inverse dimensional transformation, involving rearrangement and concatenation operations, to restore it to its serialized feature dimensions. .

[0056] Step 3.4, Output fusion mapping with dynamic position encoding:

[0057] The reconstructed feature matrix after dimension restoration is input into a biased linear projection layer for channel dimension mapping, and then reconstructed back into the two-dimensional topological structure of the spatial image to obtain the backbone feature map. .

[0058] Simultaneously construct the position encoder branch: extract the initial value features generated in step 3.1. Reshape it into Then, the data is input into the position encoder. The position encoder consists of two grouped convolutional layers with a GELU activation function sandwiched in between, and its calculation process is as follows:

[0059]

[0060] The dimensions generated by the above calculations are: Location-encoded feature map Finally, a residual fusion node with gated scaling is constructed to integrate the backbone feature map. After scaling by the Sigmoid function, it is compared with the position-encoded feature map. Element-wise additive fusion is performed to output the final feature map of the physical perception spectral attention module. :

[0061]

[0062] Step 4: Construct the space-frequency cross-domain residual coupling bottleneck layer:

[0063] In this step, a spatial-frequency cross-domain residual coupling bottleneck layer is constructed between the encoder and decoder of the multi-stage cascaded network. This bottleneck layer includes a physically-sensing spectral interaction module, a dynamic frequency-domain filtering network, and residual coupling nodes. It performs progressive calculations on the feature map downsampled by the encoder. The specific processing flow is as follows:

[0064] Step 4.1, Spatial feature extraction based on the physical sensing spectral interaction module:

[0065] Let the feature map input to the bottleneck layer be... ,in For batch size, For the bottleneck layer channel dimension, and This represents the height and width of the space after downsampling.

[0066] feature map The input is sent to the physical sensing spectrum interaction module. This module consists of... The feature map consists of a series of cascaded basic residual blocks. Each basic residual block contains sequentially connected layer normalization, the PISA operator from step 3, the feedforward neural network, and the corresponding cross-layer addition node. After After mapping the spatial spectral features of each basic residual block, output the spatial interaction feature map. .

[0067] Step 4.2: Calculation of global spatial correction based on dynamic frequency domain filtering network:

[0068] Spatial interaction feature map The input is fed into a dynamic frequency domain filter network to calculate the frequency domain correction features.

[0069] First of all, The execution layer performs normalization and swaps the tensor dimensions, reshaping it into a channel-based post-feature map. .

[0070] Constructing a dynamic route weight generation branch: for Along spatial dimensions and Perform global average pooling to compress it into a one-dimensional channel vector. ;Will The inputs are sequentially fed into a multilayer perceptron (MLP) and a softmax activation function to generate a dynamic routing weight tensor. ,in The preset number of frequency domain filters, The set number of dimensional expansion channels.

[0071] Constructing a feature cross-domain transformation branch: using a linear projection layer to... The number of channels has been expanded to Extended spatial features are obtained after processing with the StarReLU activation function. Along spatial dimensions Perform a two-dimensional real fast Fourier transform to convert it from the spatial domain to the frequency domain:

[0072]

[0073] Due to the conjugate symmetry of the real-number fast Fourier transform, the dimension of the transformed frequency domain feature tensor becomes The frequency domain dimension of the spatial width , Represents the complex field.

[0074] Step 4.3: Perform frequency domain resolution adaptive resampling and dynamic weight modulation.

[0075] In a dynamic frequency domain filtering network, initialize a set of learnable complex weight bases with real and imaginary parts. ,in and This is the preset reference frequency domain size.

[0076] Execute resolution adaptive resampling mechanism: extract the current frequency domain feature tensor Frequency domain space size and with the preset reference size Perform a conditional comparison. If the dimensions do not match, then... The last two dimensions are merged and transposed to reshape it into the form of... The pseudo-image tensor is obtained; bicubic interpolation is applied to this pseudo-image tensor to resample its spatial dimensions to a matching value. After resampling, it is restored to a complex tensor format to obtain a size-aligned complex weighted basis. If the size matches, then directly... Convert to complex form for use.

[0077] Perform frequency domain dynamic modulation: apply dynamic routing weight tensor Complex weighted basis converted to complex format and aligned to size By performing the Einstein summation convention tensor product operation, a customized frequency domain modulation filter for the current input features is calculated. :

[0078]

[0079] frequency domain feature tensor With modulation filter Perform element-wise Hadamard product operations in the complex domain to complete frequency domain filtering:

[0080]

[0081] Step 4.4: Fusion of Inverse Fourier Transform and Cross-Domain Residual Features:

[0082] For the modulated frequency domain feature tensor Perform a two-dimensional real inverse fast Fourier transform, specifying the target space size to be restored. To restore it from the frequency domain to the spatial domain:

[0083]

[0084] in, This represents a two-dimensional real inverse fast Fourier transform operator, which is used to map complex frequency domain signals containing low-frequency and high-frequency modulation information back to the real space domain. To restore the real-valued feature tensor to the spatial domain. This is achieved through a linear mapping layer. The channel dimension is determined by Compress back to the initial number of channels in the bottleneck layer Then, perform a tensor transpose operation to obtain the final global space correction tensor. Finally, at the residual coupling node, the spatial interaction feature map output in step 4.1 is... With the global space correction tensor generated in step 4.4 Perform element-wise addition operations in both spatial and channel dimensions:

[0085]

[0086] This completes the fusion of spatial spectral features and frequency macroscopic features, outputting a refined feature map of the spatial-frequency cross-domain residual coupling bottleneck layer. It is then fed into the decoder of the multi-stage cascaded network for upsampling and reconstruction.

[0087] Step 5: Construct a customized hybrid loss function for drone forestry scenarios and perform end-to-end network parameter optimization:

[0088] In this step, during the model training phase, a multi-dimensional hybrid loss function integrating relative absolute error, spectral angle mapping, and spatial gradient differences is constructed. Gradient backpropagation and end-to-end optimization are then performed on the parameters of the multi-stage cascaded network and its individual modules. Let the predicted hyperspectral image tensor output by the network's forward propagation be... The corresponding batch of real hyperspectral image label tensors is ,in For batch size, This represents the number of spectral channels. and These represent the image spatial height and width, respectively. The specific construction and calculation steps of the hybrid loss function are as follows:

[0089] Step 5.1: Construct the basic relative absolute error loss with a safety cutoff factor:

[0090] Extracting the prediction tensor With the real label tensor Perform element-wise absolute difference calculations in the spatial and channel dimensions to obtain the absolute error tensor. ,in Constructing a relative error denominator: to prevent errors in the real label tensor. In the low-value range, i.e., the pixel region approaching zero, if a division-to-zero overflow occurs or an unbounded anomalous gradient is calculated, a constant-level safety cutoff factor is introduced into the denominator. This constitutes the modified denominator term. The absolute error tensor Perform element-wise division with the corrected denominator and compute the tensor across all dimensions. The global mathematical expectation on the surface yields the basic relative absolute error loss term. :

[0091]

[0092] Step 5.2: Construct the anti-overflow spectral angle mapping loss (SAM Loss):

[0093] For prediction tensor With the real label tensor Perform a dimension transpose operation to reshape it from a channel-preceding tensor to a channel-postceding tensor form, resulting in the following: and .in, The predicted spectral tensor is the channel postposition, used to characterize the reconstructed spectral continuous waveform vector output by the network at each spatial pixel. This is the true reference tensor after the channel, used to represent the objective real-world reflectance spectral vector of the corresponding spatial pixel. Along the spectral feature dimension... ,calculate and The pixel-wise vector dot product generates the dot product tensor. :

[0094]

[0095] Calculate separately and Along the spectral dimension The L2 norm is used to obtain the predicted spectral modulus tensor. With the true spectral modulus tensor ,in Constructing the cosine similarity tensor : Convert the dot product tensor Divide by the product of the two modulus tensors and introduce a small bias term into the denominator. To maintain numerical stability:

[0096]

[0097] To prevent the domain of the inverse cosine function from exceeding its bounds due to floating-point precision errors in computers, the cosine similarity tensor... Perform a numerical truncation operation to strictly constrain it to a closed interval. Between these, the corrected similarity tensor is obtained. .

[0098] Finally, for The spectral angle mapping loss term is calculated by applying the inverse cosine function element by element and taking the global average. :

[0099]

[0100] Step 5.3: Construct the L1 norm-based spatial gradient difference loss:

[0101] In the spatial dimension, the prediction tensor is approximated by using the first-order difference between adjacent pixels. With the real label tensor The horizontal and vertical gradients. The horizontal direction is defined as along the width dimension. Differential slicing operation:

[0102]

[0103]

[0104] in, and Let represent the predicted image gradient tensor and the true image gradient tensor in the horizontal direction, respectively. ; They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor obtained by shifting one pixel to the right in the width dimension; and They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor that remains after removing the last column of pixels in the width dimension.

[0105] Define the vertical direction, that is, along the height dimension. Differential slicing operation:

[0106]

[0107]

[0108] in, and Let represent the predicted image gradient tensor and the true image gradient tensor in the vertical direction, respectively. ; and They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor obtained by shifting down one pixel in the height dimension; and They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor retained after removing the last row of pixels in the height dimension.

[0109] The L1 norm is used to measure the differences in horizontal and vertical gradients between the predicted and ground truth images, respectively, to construct a spatial gradient loss term. :

[0110]

[0111] in, This represents taking the absolute value of all elements in the tensor and calculating the global mathematical expectation.

[0112] Step 5.4, Hybrid Loss Aggregation and Backpropagation Optimization:

[0113] Initialize network weights and define the three hyperparameters of the hybrid loss function: weight coefficients, base relative absolute error weights, and weights. Spectral angle mapping weights and spatial gradient weights The three independent loss terms constructed in steps 5.1-5.3 are linearly weighted and summed to generate the total loss scalar used for the current batch gradient update. :

[0114]

[0115] scalar of total loss The automatic differentiation engine fed into the deep learning framework calculates the gradients of all learnable parameters in the network and uses the Adam optimizer to perform gradient descent and parameter updates until the network converges.

[0116] Step 6: Integrate the PISA module from Step 3, the spatial-frequency cross-domain residual coupling bottleneck layer from Step 4, and the customized hybrid loss function from Step 5 into the MST++ framework to obtain the improved MST++ model. Use the improved MST++ model for end-to-end training on the training and validation sets from Step 2 to obtain the optimal improved MST++ model. Finally, deploy the trained improved MST++ model in the forest hyperspectral image reconstruction task and use the test set to reconstruct the newly input RGB image to obtain the output hyperspectral data.

[0117] Example 1:

[0118] Step 1: In this embodiment, a publicly available UAV forest hyperspectral dataset, specifically co-aligned hyperspectral and LiDAR data collected in drought-stressed European beech forests of the Rhön Biosphere Reserve, Germany, is used as the experimental data source. This dataset, collected from drought-stressed European beech forest sub-regions within the Rhön Biosphere Reserve, includes hyperspectral imagery acquired by a UAV platform and spatially aligned LiDAR data. The hyperspectral data has been preprocessed into surface reflectance products and orthorectified by the NERC Field Spectroscopy Facility, effectively mitigating the impact of sensor attitude variations and terrain undulations on the radiometric and geometric quality of the original images.

[0119] Step 2: Divide the preprocessed dataset into training, validation, and test sets according to a preset ratio of 18:1:1. This division method ensures sufficient training samples while maintaining the objectivity of model tuning and performance evaluation, thereby improving the reliability and reproducibility of experimental results.

[0120] Step 3: To address the reflectance baseline drift phenomenon in remote sensing images caused by terrain undulations and differences in illumination angles, sequential reconstruction and spectral channel feature space mapping are performed. In the initial stage of feature processing, the spatial-spectral joint feature data output from the previous network layer is received and defined as a multidimensional tensor. .in, Characterization batches, and The spatial scale of the characteristic plane, This represents the total number of channels in the frequency band. To overcome the fixed receptive field limitation of local convolution and establish global dependencies across pixels, the system first performs one-dimensional serialization reconstruction on the input tensor along the height and width directions, transforming it into sequential features. Subsequently, four independent parameterized mapping branches are configured. Using the learnable weight matrices of the corresponding branches, linear projection calculations are performed on the sequence features to generate an initial set of feature vectors for multi-head computation.

[0121]

[0122]

[0123]

[0124]

[0125] In the above formula, This determines the expansion of the channel dimensions after projection. The number of attention heads calculated for each group. The subspace feature dimension is defined as follows. After projection, the resulting feature tensor undergoes multi-head dimension decomposition, and the memory order of the spatial pixel dimension and frequency band dimension is swapped. This dimension transposition operation switches the computational domain from conventional pixel-level interaction to spectral-level interaction, thereby generating a dimension of... query matrix Key matrix Value matrix and gating matrix .

[0126] After obtaining the interaction matrix, the network then performs baseline calibration and waveform similarity analysis based on standard normal transform. To eliminate abrupt changes in absolute reflected light intensity caused by differences in external illumination for similar ground features, the system constructs a purely waveform-driven shape-aware branch. The query matrix is ​​then extracted. Bond matrix A standard normal transformation (SNV) along the spectral dimension is performed pixel-by-pixel within the high-dimensional subspace of the features. Specifically, for the matrix... Any given batch Attention and spatial pixels The spectral vector at that location, along the spectral dimension Local mean With local standard deviation The discrete statistical expression is:

[0127]

[0128]

[0129] matrix Local mean with standard deviation The calculation is performed using completely symmetric logic. Based on the extracted statistics, distribution alignment and mean removal are then performed:

[0130]

[0131]

[0132] After denoising, the absolute numerical differences within the matrix are smoothed out, retaining only the relative trends of the spectral curves. To adapt it to the calculation criteria of cosine distance, the tensor needs further L2 norm measurement and normalization. For example, the formula for calculating its L2 norm component along the spectral dimension is:

[0133]

[0134] Then, a precise normalization mapping is performed:

[0135]

[0136]

[0137] After completing the waveform feature alignment described above, a preset learnable temperature coefficient tensor is introduced. The matrix multiplication operation is performed to obtain the waveform correlation weights, and then the probability distribution is mapped through the Softmax function to output an attention matrix representing the waveform similarity. :

[0138]

[0139] After similarity analysis, the subsequent processing steps involve energy feature reconstruction and signal-to-noise ratio gating. After extracting high-fidelity spectral waveform correlation information, the network simultaneously activates the intensity reconstruction branch to recover the true physical light intensity energy of ground features. The system retrieves the original value matrix that was not corrupted by baseline calibration. The shape attention matrix generated above A weighted aggregation operation is performed on it. Simultaneously, a gating matrix is ​​used. Channel-level dynamic attenuation filtering is performed on the features. This is achieved by applying the Sigmoid activation function. Compress the range of the gate tensor to The frequency band is adaptively suppressed to suppress frequency characteristics severely affected by atmospheric water vapor absorption or thermal noise. The convergence process and the gated attenuation process are executed synchronously via the Hadamard product:

[0140]

[0141] After the calculation is completed, the feature matrix is ​​reorganized. It will be reversed and restored to its original state. The flattened tensor specification.

[0142] Finally, this module performs spatial structure restoration and cross-layer feature fusion. Given that the initial serialization operation deconstructs the topological relationships of the image on a two-dimensional plane, this embodiment establishes a dedicated spatial structure inverse transformation and position prior injection mechanism at the module output. First, the output projection layer with a bias term is used to... Perform channel number compression and reconstruction, and then restore it to a two-dimensional spatially arranged backbone feature map using a view reshaping function. Secondly, extract the initial value features generated in the aforementioned initial mapping stage. Morphological reconstruction was performed to obtain A network structure utilizing two groups of grouped deep convolutional layers enclosing nonlinear activation layers (GELU) generates location feature maps by providing prior information on the relative positions of features with extremely low computational cost, based on the translation invariance of local convolutions.

[0143]

[0144] At the terminal node output by the PISA module, a residual stacking branch with adaptive activation scaling is constructed. (Branch feature map) First pass The function calculates its own scaled scalar map, which, after self-multiplication and scaling, is compared with the aforementioned positional feature map. Perform pixel-by-pixel alignment and accumulation to obtain the final refined output of the module:

[0145]

[0146] Output Keep the original input The tensor size is then directly input into the next stage of the space-frequency joint bottleneck network or the decoding upsampling layer.

[0147] Step 4: Construct a spatial-frequency cross-domain residual coupling bottleneck layer for dual-domain feature depth refinement. In high-resolution UAV or satellite remote sensing image processing, traditional convolution or local window calculations are often limited by a finite receptive field, making it difficult to capture the spatial contextual dependencies of ground features over a large scale; while directly applying a global self-attention mechanism would lead to a quadratic explosion in computational complexity. To overcome this technical bottleneck, this embodiment deploys a spatial-frequency cross-domain residual coupling bottleneck layer between the encoder and decoder of a multi-stage cascaded network. This bottleneck layer, by introducing frequency domain transformation, achieves feature coverage of the global spatial receptive field with extremely low computational overhead. Its specific forward propagation and calculation steps are as follows:

[0148] First, spatial feature extraction is performed based on the physical sensing spectral interaction module. The deep feature map output by the receiving network encoder after multi-level downsampling is defined as a tensor. ,in For batch size, For the current layer channel dimension, and These represent the height and width of the feature plane, respectively. The feature map... Import it into the physical sensing spectrum interaction module at the front end of the bottleneck layer. This module internally stacks... Each residual feature block undergoes layer normalization, PISA operator calculation (as described in step 3), and feedforward neural network mapping in sequence. The physical function of this stage is to perform in-depth cross-channel waveform interaction and fidelity extraction of the local spectral absorption features of ground objects within the downsampled low-resolution space using the PISA operator, outputting a spatial interaction feature map with local hyperspectral resolution. .

[0149] Subsequently, a spatial-to-frequency domain feature transformation and dynamic route generation are performed. To compensate for the lack of global context awareness in the aforementioned spatial operations, the system uses the spatial interaction feature map... A dynamic frequency domain filtering network is imported to extract the low-frequency structure and high-frequency texture of the global spatial distribution. First, for Perform a post-reordering of the channel dimension to generate a tensor. Then, the dynamic routing feature extraction branch is enabled, utilizing global average pooling along the spatial dimension. Feature compression is performed to obtain a vector representing the global channel distribution state. :

[0150]

[0151] vector The input is fed into a dimensionality reduction-up network composed of multilayer sensing mechanisms, and normalized and activated by the Softmax function to generate a dynamic routing weight tensor for controlling the frequency domain filter. , For the number of filter bases, The number of intermediate expansion channels is set. This routing weight generation mechanism enables the network to adaptively allocate the response ratios of different frequency domain filters based on the global statistical features of the current input image. The frequency domain feature transformation branch is simultaneously enabled: through a linear projection layer... The number of channels has been expanded to The extended spatial domain features are obtained by performing a nonlinear mapping using the StarReLU activation function. .against Along the spatial plane, i.e., dimension and Perform a two-dimensional real-number fast Fourier transform:

[0152]

[0153] Under the mathematical properties of the Fourier transform, the features of each pixel distributed in the spatial domain are converted into amplitude and phase information of different frequency bases in the frequency domain, and the feature tensor evolves into a complex domain representation. Based on the Nyquist sampling theorem and the conjugate symmetry of the real fast Fourier transform, the dimension of the frequency domain bandwidth is reduced to... .

[0154] After completing the frequency domain transformation, the network performs frequency domain resolution adaptive resampling and dynamic filter modulation. To address the varying input image sizes from multiple remote sensing sensors and the network's need to process images of arbitrary resolution during the inference phase, this embodiment incorporates a resolution adaptation mechanism within the frequency domain filtering module. During the initialization phase, the network defines a set of learnable complex weight bases. ,in and Using a preset baseline frequency domain scale, the two components of the last dimension represent the real and imaginary parts of the complex weights, respectively. In each forward computation, the system extracts the current frequency domain feature tensor in real time. Actual size If detected The system triggers a dynamic resampling process: of The dimension and the real and imaginary parts of the complex number are merged and fronted to reconstruct a form of... The pseudo-feature map format is then used; subsequently, a bicubic interpolation algorithm is applied to the pseudo-feature map to smoothly interpolate it to the current actual size while preserving the distortion-free topological structure of the low-frequency distribution of the frequency domain weights. After interpolation, reverse dimensionality decomposition and complexification are performed to generate a complex weighted basis with strictly aligned dimensions. After completing the size alignment, the dynamic route weight tensor generated in the previous stages will be... With complex weighted basis Perform Einstein summation tensor product:

[0155]

[0156] The generated modulation filter Subsequently, with the frequency domain feature tensor Perform element-wise complex Hadamard product operation:

[0157]

[0158] The frequency domain multiplication described above is equivalent to performing a global large kernel convolution with the full receptive field in the spatial domain, thereby achieving joint response modulation of the macroscopic low-frequency structure and microscopic high-frequency details of remote sensing images.

[0159] Finally, inverse Fourier transform and cross-domain residual feature compensation are performed. This applies to the modulated frequency domain features. Perform a two-dimensional real inverse fast Fourier transform, constraining the spatial size of the reconstructed target to be the original input scale. This maps it back from the complex frequency domain to the real space domain:

[0160]

[0161] in Then, the channel dimension is changed from... through a linear projection layer. Compression restored to initial channel count It then performs memory transpose to restore the tensor arrangement format of the channel front, and finally outputs a global space correction tensor. At the end of the bottleneck layer's feature convergence, the conventional channel splicing operation was abandoned, and a cross-domain residual compensation node was constructed. This node integrates the spatial interactive feature map output from the preceding stages, which focuses on local spectral waveform fidelity. The global spatial correction tensor associated with the above-mentioned global spatial topology includes the global spatial correction tensor. Perform direct accumulation pixel by pixel:

[0162]

[0163] The physical significance of this residual compensation mechanism lies in using high-fidelity local spectral features as the basis features, while superimposing the global features obtained through complex frequency domain transformation as residual perturbations. This architecture not only ensures the smoothness of gradient backpropagation in extremely deep networks but also facilitates the deep coupling of local fine-grained spectral physical information and global macroscopic spatial distribution information in a two-domain dimension. (Refined feature map) It is then fed into the decoder of a multi-stage cascaded network for the final hyperspectral data cube reconstruction.

[0164] Step 5: Construct a customized hybrid loss function to perform end-to-end network parameter optimization. In multi-source UAV remote sensing and forestry hyperspectral detection scenarios, due to the complex canopy structure, large areas of deep shadow often exist within the image, and the inversion of forestry biochemical parameters highly depends on the waveform characteristics of the continuous spectrum and the high-frequency texture of leaf edges. To address these multi-dimensional physical constraints, this embodiment constructs a multi-objective hybrid loss function that integrates relative absolute error, spectral angle mapping, and spatial gradient to guide the end-to-end update of network parameters. Given the hyperspectral image tensor predicted by the network... and the corresponding real label tensor The detailed implementation mechanism of this loss function is as follows:

[0165] First, a relative-absolute error evaluation based on a safety truncation is performed. Conventional mean squared error or absolute error, when calculating the global loss, tends to dominate the gradient update direction of bright pixels with high reflectivity, causing the network to ignore features of low-reflectivity shadow regions. To balance the photometric weights across the entire image, this embodiment uses relative-absolute error as the basic numerical approximation constraint. First, in the discrete coordinates corresponding to the space and channels... At this point, calculate the pixel-by-pixel absolute deviation between the predicted and actual values:

[0166]

[0167] In the gaps between tree canopies and deep shadow areas of drone forestry imagery, the true reflectance... The value of this factor tends to approach zero. If it is directly used as the denominator, the derivative will tend to infinity during backpropagation, leading to a severe gradient explosion. To address this numerical instability, this embodiment forcibly injects a constant-level safety cutoff factor into the error denominator. Subsequently, the global mathematical expectation of the full tensor is calculated, and the basic relative absolute error loss term is constructed. :

[0168]

[0169] The physical meaning of this cutoff factor is that, while ensuring the accuracy of the relative error calculation in bright areas, it sets a maximum penalty upper limit for deep shadow areas, thus ensuring the training stability of the model in extreme lighting contrast scenarios.

[0170] After completing the basic error assessment, the system further introduces spectral angle mapping constraints based on an anti-overflow mechanism. Relying solely on basic relative errors cannot guarantee that the topological structure of the multi-channel spectral curves will not be distorted, and these waveform structures are the core basis for observing the physiological state of trees and retrieving physicochemical parameters. Therefore, this embodiment introduces spectral angle mapping to specifically constrain waveform similarity in high-dimensional spectral space. First, tensor rearrangement is performed to... and Convert to channel post-format Then at the given spatial pixel position At each location, calculate the dot product of the predicted spectral vector and the true spectral vector. and the L2 norm modulus of both. and Its discrete expansion is:

[0171]

[0172]

[0173] Based on this, the cosine of the spectral angle between spatial pixels is calculated by dividing the dot product by the product of the moduli:

[0174]

[0175] in, To prevent small bias terms from being applied to zero vector inputs.

[0176] Furthermore, in low-level floating-point arithmetic in computers, the cosine value may appear truncated due to precision truncation. Invalid values ​​cause NaN exceptions to be thrown when calculating the gradient of the inverse cosine function. To avoid this runtime error, this embodiment applies a mandatory numerical truncation constraint to the cosine similarity:

[0177]

[0178] Finally, the inverse cosine function is applied to map to radian space and the average value of the entire image is calculated to generate the spectral angle mapping loss term. :

[0179]

[0180] Simultaneously, to overcome the problem of excessive feature smoothing that deep convolutional networks tend to cause when reconstructing images and to protect the sharp texture at the canopy boundary, this embodiment constructs a spatial gradient structure protection mechanism based on the L1 norm, introducing gradient difference constraints based on the first derivative of the image space. The predicted tensor and the true label tensor are extracted in the horizontal direction, i.e., the width dimension. The single-step translation difference matrix, and the vertical dimension, i.e., the height dimension. The single-step translation difference matrix:

[0181]

[0182]

[0183] To address the high-frequency edge features extracted via differential extraction, this embodiment abandons the commonly used L2 norm penalty and instead uses the L1 norm to measure the difference between the predicted and true gradients. The difference in horizontal gradients is used as the basis for this measurement. For example, the specific calculation formula is as follows:

[0184]

[0185] Similarly, calculate the vertical gradient difference. Combining the two terms yields the spatial gradient loss term. The physical motivation for choosing the L1 norm as a metric is that the gradient distribution of natural images exhibits strong sparsity. The L1 norm can effectively bring the network output gradient closer to the real edge gradient while avoiding the infinite amplification of unpredictable local high-frequency noise, as the L2 norm does, thus maintaining the sharpness and purity of the reconstructed image boundaries.

[0186] After completing the multi-dimensional constraint calculations, the system finally performs joint backpropagation using the hybrid loss function. At the end of each forward iteration cycle, the system linearly weights and fuses the loss terms of the three dimensions according to the set weight hyperparameters:

[0187]

[0188] in, The convergence scale of absolute values ​​across the entire graph is considered. Controlling the physical alignment strength of ground feature waveforms Adjust the enhancement level of local edge textures. Total loss scalar. After generation, it is handed over to the automatic differential graph engine of the deep learning framework. The system calculates the differential graph based on the chain rule. The set of partial derivative matrices relative to all learnable parameters in the network , where the parameter set It covers the linear projection layer weights and shape temperature coefficients mentioned in step 3, as well as the multilayer perceptron weight matrix and complex weight basis mentioned in step 4. Combined with the preset learning rate and optimization algorithms such as Adam, it drives the network parameters to achieve cross-domain joint optimization and end-to-end convergence.

[0189] Example 2:

[0190] Based on the comparative test results in Table 1, the model proposed in this invention (Our_model) demonstrates a strong performance advantage on the test set, especially in key indicators such as mean relative absolute error (MRAE), peak signal-to-noise ratio (PSNR), and spectral angle mapping (SAM). Specifically: MRAE: Our_model's MRAE is 0.1744, which is excellent compared to the baseline models MST++ (0.2238) and Restormer (0.2317), indicating a significant reduction in relative error in UAV forest image spectral reconstruction tasks. Compared to HSCNN+ (0.2864), Our_model's MRAE is reduced by 0.112. PSNR: Our_model's PSNR is 28.24, which is 1.18 higher than MST++ (27.06), indicating a significant improvement in the spatial quality and fidelity of the predicted reconstructed image, making it particularly suitable for scenarios where the fine inversion of forestry biochemical parameters such as chlorophyll content requires high image reconstruction accuracy. SSIM: Our_model's SSIM is 0.8356, an improvement of 0.0143 compared to MST++ (0.8213), demonstrating excellent performance in structural similarity and better preservation of complex spatial structural textures and high-frequency edges such as the canopy boundary and leaf outlines. SAM: Our_model's SAM is 4.6184, significantly lower than MST++ (5.2223) and MPRNet (5.6613), proving its significant performance improvement in maintaining the topological consistency of vegetation feature spectral curves and reducing spectral distortion. RMSE: Our_model's RMSE is 0.0433, a reduction of 0.0098 compared to other comparative models, such as Restormer (0.0531), indicating that its absolute deviation from the actual vegetation reflectance is minimized.

[0191] Table 1. Performance comparison of different spectral reconstruction models on the test set.

[0192]

[0193] In summary, Our_model achieved optimal performance across all five evaluation metrics—MRAE, RMSE, PSNR, SSIM, and SAM—demonstrating significant improvements, particularly in restoring local spatial details and aligning with the true spectral waveforms of vegetation against complex canopy backgrounds with large areas of shading. Furthermore, in terms of physical spectral fidelity, it more accurately reproduces the true objective spectral characteristics of trees, meeting the high-precision requirements of practical forestry applications. Therefore, the algorithm proposed in this invention has great potential for application in forestry hyperspectral image reconstruction tasks, especially suitable for deployment environments requiring high spectral accuracy and spatial resolution, such as UAV-based forestry remote sensing, tree species identification, and physiological state assessment.

Claims

1. An image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering, characterized in that... The method includes the following steps: Step 1: Download the forest hyperspectral dataset captured by the drone; Step 2: Extract the RGB bands from the hyperspectral data, synthesize them into an RGB image, and divide the hyperspectral data and RGB image into 400... 512 small data pairs are used to divide the data into training, validation, and test sets. Step 3: Design and introduce the PISA module into the encoder and decoder. The network topology of the PISA module includes a multi-branch linear mapping layer, a shape-aware flow computing branch, an intensity reconstruction flow computing branch, and an output fusion layer with position encoding. Step 4: Construct a space-frequency cross-domain residual coupling bottleneck layer between the encoder and decoder in the multi-stage cascaded network; Step 5: Construct a customized hybrid loss function for unmanned aerial vehicle (UAV) forestry scenarios; Step 6: Integrate the PISA module from Step 3, the spatial-frequency cross-domain residual coupling bottleneck layer from Step 4, and the customized hybrid loss function from Step 5 into the MST++ framework to obtain the improved MST++ model. Use the improved MST++ model for end-to-end training on the training and validation sets from Step 2 to obtain the optimal improved MST++ model. Finally, deploy the trained improved MST++ model in the forest hyperspectral image reconstruction task and use the test set to reconstruct the newly input RGB image to obtain the output hyperspectral data.

2. The image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering according to claim 1, characterized in that... In step 3, the specific construction and calculation steps of the input features in the PISA module are as follows: Step 3.1: Multi-branch linear mapping and multi-head spectral dimension rearrangement of input features: Let the spatial-spectral joint feature map input to the PISA module be... ,in For batch size, and These represent the spatial height and width of the feature map, respectively. The number of spectral channels is a characteristic feature; First, the feature map in the spatial dimension Perform a flattening operation to reshape it into a two-dimensional serialized feature. ,in Indicates the total number of pixels in the space; Subsequently, four parallel, unbiased linear projection layers are constructed to sequence the two-dimensional features. Mapping to a high-dimensional feature subspace, initial query features are generated respectively. Initial bond features Initial value characteristics and initial gating : in, These are the learnable weight matrices for the four linear projection layers. For the number of attention heads, Feature dimensions for each attention head; The feature tensor generated by the above mapping is transformed from dimension... Reshaping into a multi-head attention dimension Then, for the last two dimensions of these four tensors, namely the spatial dimension... With spectral feature dimension Perform a transpose operation to construct a multi-head feature matrix expanded along the spectral channel dimension: query matrix Key matrix Value matrix and gating matrix And the dimensions of the above four matrices are all ; Step 3.2: Construct a shape-aware flow and perform standard normal transformation and shape attention calculation: Transposed query matrix AND key matrix Input to the shape-aware flow branch; First, a standard normal transformation (SNV) operator is constructed in the shape-aware flow branch to perform a query matrix. Bond matrix In the spectral dimension Standardization processes are performed on each of the above: in, ; and Each is a matrix and Along the spectral dimension Calculated local mean; and Along the spectral dimension Calculated local standard deviation; It is a constant; Secondly, the matrix after processing by the SNV operator and In dimensions Perform L2 norm normalization to obtain the normalized matrix. and : Constructing a structure with a learnable shape temperature coefficient The attention computation graph will normalize the bond matrix. Transpose of the normalized query matrix Perform matrix multiplication, multiplying the scalar by the aforementioned temperature coefficient. Then, activation is performed using the Softmax function, and the output dimension is... Shape Attention Matrix : Step 3.3: Construct the intensity recombination flow for dynamic gating aggregation: In the intensity reorganization flow branch, the shape attention matrix output from step 3.2 is used. Compared with the value matrix generated in step 3.1 Perform matrix multiplication aggregation calculations; At the same time, the gated matrix generated in step 3.1 Applying the Sigmoid activation function ; The attention aggregation result is combined with the activated gated features using a Hadamard product to generate a reconstructed feature matrix. : Subsequently, the recombined feature matrix Perform an inverse dimensional transformation, involving rearrangement and concatenation operations, to restore it to its serialized feature dimensions. ; Step 3.4, Output fusion mapping with dynamic position encoding: The reconstructed feature matrix after dimension restoration is input into a biased linear projection layer for channel dimension mapping, and then reconstructed back into the two-dimensional topological structure of the spatial image to obtain the backbone feature map. ; Simultaneously construct the position encoder branch: extract the initial value features generated in step 3.

1. Reshape it into Then, it is input into the position encoder to generate a dimension of Location-encoded feature map ; Finally, a residual fusion node with gated scaling is constructed to integrate the backbone feature map. After scaling by the Sigmoid function, it is compared with the position-encoded feature map. Element-wise additive fusion is performed to output the final feature map of the physical perception spectral attention module. : 。 3. The image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering according to claim 2, characterized in that... The position encoder consists of two grouped convolutional layers connected in series with a GELU activation function sandwiched in between. Its calculation process is as follows: 。 4. The image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering according to claim 1, characterized in that... The bottleneck layer includes a physical sensing spectral interaction module, a dynamic frequency domain filtering network, and residual coupling nodes. It performs progressive calculations on the feature map output by the encoder downsampling. The specific processing flow is as follows: Step 4.1, Spatial feature extraction based on the physical sensing spectral interaction module: Let the feature map input to the bottleneck layer be... ,in For batch size, For the bottleneck layer channel dimension, and The height and width of the space after downsampling; feature map The data is input into the physical sensing spectrum interaction module and then processed. After mapping the spatial spectral features of each basic residual block, output the spatial interaction feature map. ; Step 4.2: Calculation of global spatial correction based on dynamic frequency domain filtering network: Spatial interaction feature map The input is fed into a dynamic frequency domain filtering network to calculate the frequency domain correction features: First of all, The execution layer performs normalization and swaps the tensor dimensions, reshaping it into a channel-based post-feature map. ; Constructing a dynamic route weight generation branch: for Along spatial dimensions and Perform global average pooling to compress it into a one-dimensional channel vector. ;Will The inputs are sequentially fed into the multilayer perceptron and the Softmax activation function to generate a dynamic routing weight tensor. ,in The preset number of frequency domain filters, The set number of dimensional expansion channels; Constructing a feature cross-domain transformation branch: using a linear projection layer to... The number of channels has been expanded to Extended spatial features are obtained after processing with the StarReLU activation function. Along spatial dimensions Perform a two-dimensional real fast Fourier transform to convert it from the spatial domain to the frequency domain: Due to the conjugate symmetry of the real-number fast Fourier transform, the dimension of the transformed frequency domain feature tensor becomes The frequency domain dimension of the spatial width , Represents the field of complex numbers; Step 4.3: Perform frequency domain resolution adaptive resampling and dynamic weight modulation. In a dynamic frequency domain filtering network, initialize a set of learnable complex weight bases with real and imaginary parts. ,in and The preset reference frequency domain size; Execute resolution adaptive resampling mechanism: extract the current frequency domain feature tensor Frequency domain space size and with the preset reference size Perform a conditional comparison; if the dimensions do not match, then... The last two dimensions are merged and transposed to reshape it into the form of... The pseudo-image tensor is obtained; bicubic interpolation is applied to this pseudo-image tensor to resample its spatial dimensions to a matching value. After resampling, it is restored to a complex tensor format to obtain a size-aligned complex weighted basis. If the size matches, then directly... Convert to complex form for use; Perform frequency domain dynamic modulation: apply dynamic routing weight tensor Complex weighted basis converted to complex format and aligned to size By performing the Einstein summation convention tensor product operation, a customized frequency domain modulation filter for the current input features is calculated. : frequency domain feature tensor With modulation filter Perform element-wise Hadamard product operations in the complex domain to complete frequency domain filtering: Step 4.4: Fusion of Inverse Fourier Transform and Cross-Domain Residual Features: For the modulated frequency domain feature tensor Perform a two-dimensional real inverse fast Fourier transform, specifying the target space size to be restored. To restore it from the frequency domain to the spatial domain: in, This represents the two-dimensional real inverse fast Fourier transform operator. To restore the real-valued feature tensor to the spatial domain; Through the linear mapping layer The channel dimension is determined by Compress back to the initial number of channels in the bottleneck layer Then, perform a tensor transpose operation to obtain the final global space correction tensor. ; Finally, at the residual coupling node, the spatial interaction feature map output in step 4.1 is... With the global space correction tensor generated in step 4.4 Perform element-wise addition operations in both spatial and channel dimensions: This completes the fusion of spatial spectral features and frequency macroscopic features, outputting a refined feature map of the spatial-frequency cross-domain residual coupling bottleneck layer. It is then fed into the decoder of the multi-stage cascaded network for upsampling and reconstruction.

5. The image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering according to claim 4, characterized in that... The physical sensing spectral interaction module It consists of a series of basic residual blocks, each containing a layer normalization, the PISA operator from step 3, a feedforward neural network, and a corresponding cross-layer addition node connected in sequence.

6. The image spectral reconstruction method integrating physical priors and dynamic frequency domain filtering according to claim 4, characterized in that... In step 5, let the predicted hyperspectral image tensor output by the network forward propagation be... The corresponding batch of real hyperspectral image label tensors is ,in For batch size, This represents the number of spectral channels. and The specific steps for constructing and calculating the mixture loss function, which represents the image spatial height and width respectively, are as follows: Step 5.1: Construct the basic relative absolute error loss with a safety cutoff factor: Extracting the prediction tensor With the real label tensor Perform element-wise absolute difference calculations in the spatial and channel dimensions to obtain the absolute error tensor. ,in ; Constructing a relative error denominator: Introducing a constant-level safety cutoff factor into the denominator. This constitutes the modified denominator term. ; the absolute error tensor Perform element-wise division with the corrected denominator and compute the tensor across all dimensions. The global mathematical expectation on the surface yields the basic relative absolute error loss term. : Step 5.2: Construct the spillover prevention spectral angle mapping loss: For prediction tensor With the real label tensor Perform a dimension transpose operation to reshape it from a channel-preceding tensor to a channel-postceding tensor form, resulting in the following: and ,in, For the predicted spectral tensor after the channel, The true reference tensor after the channel; Along the spectral feature dimension ,calculate and The pixel-wise vector dot product generates the dot product tensor. : Calculate separately and Along the spectral dimension The L2 norm is used to obtain the predicted spectral modulus tensor. With the true spectral modulus tensor ,in ; Constructing the cosine similarity tensor : Convert the dot product tensor Divide by the product of the two modulus tensors and introduce a small bias term into the denominator. To maintain numerical stability: cosine similarity tensor Perform a numerical truncation operation to strictly constrain it to a closed interval. Between these, the corrected similarity tensor is obtained. ; Finally, for The spectral angle mapping loss term is calculated by applying the inverse cosine function element by element and taking the global average. : Step 5.3: Construct the L1 norm-based spatial gradient difference loss: Define the horizontal direction, that is, along the width dimension. Differential slicing operation: in, and Let represent the predicted image gradient tensor and the true image gradient tensor in the horizontal direction, respectively. ; They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor obtained by shifting one pixel to the right in the width dimension; and They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor retained after removing the last column of pixels in the width dimension; Define the vertical direction, that is, along the height dimension. Differential slicing operation: in, and Let represent the predicted image gradient tensor and the true image gradient tensor in the vertical direction, respectively. ; and They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor obtained by shifting down one pixel in the height dimension; and They represent the prediction tensors respectively. With the real label tensor The sub-slice tensor retained after removing the last row of pixels in the height dimension; The L1 norm is used to measure the differences in horizontal and vertical gradients between the predicted and ground truth images, respectively, to construct a spatial gradient loss term. : in, This means taking the absolute value of all elements in the tensor and calculating the global mathematical expectation; Step 5.4, Hybrid Loss Aggregation and Backpropagation Optimization: Initialize network weights and define the three hyperparameters of the hybrid loss function: weight coefficients, base relative absolute error weights, and weights. Spectral angle mapping weights and spatial gradient weights ; The three independent loss terms constructed in steps 5.1-5.3 are linearly weighted and summed to generate the total loss scalar used for the gradient update of the current batch. : scalar of total loss The automatic differentiation engine fed into the deep learning framework calculates the gradients of all learnable parameters in the network and uses the Adam optimizer to perform gradient descent and parameter updates until the network converges.