Spectral data processing method and apparatus based on adaptive convolution, device, and medium
By generating region-adaptive convolution kernels and combining spectral gradient attention maps and local spectral statistics to dynamically adjust the convolution kernels, the problem of insufficient identification of weak targets in hyperspectral data in traditional techniques is solved, achieving higher detection accuracy and robustness.
Patent Information
- Application Number
- PCT/CN2026/090530
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2025-05-20
- Filing Date
- 2026-04-14
- Publication Date
- 2026-11-26
AI Technical Summary
Traditional techniques cannot effectively adapt to the spectral heterogeneity between targets and background in hyperspectral data, resulting in insufficient sensitivity for identifying weak targets, especially in complex environments where there are high error rates and false negative rates.
By generating region-adaptive convolution kernels and combining spectral gradient attention maps and local spectral statistics, the shape and weight of the convolution kernels are dynamically adjusted to process hyperspectral data and improve feature extraction capabilities.
It improves the detection accuracy of weak targets in hyperspectral data, overcomes the problems of static convolution kernels and insufficient feature extraction in traditional methods, and can effectively handle target detection tasks in complex backgrounds.
Smart Images

Figure CN2026090530_26112026_PF_FP_ABST
Abstract
Description
Adaptive convolution-based spectral data processing methods, devices, equipment, and media
[0001] This application claims priority to Chinese Patent Application No. 202510650951.1, filed on May 20, 2025, entitled "A method, apparatus, device and medium for spectral data processing based on adaptive convolution", the entire contents of which are incorporated herein by reference. Technical Field
[0002] This application relates to the field of image processing technology, and in particular to a method, apparatus, device and medium for spectral data processing based on adaptive convolution. Background Technology
[0003] In hyperspectral image processing, healthcare, and agricultural insurance, the high dimensionality of data, weak target signals, and complex backgrounds pose significant challenges to traditional technologies. Particularly in hyperspectral image processing, traditional methods rely heavily on hand-designed feature extractors and statistical detectors, such as principal component analysis and matched filtering. While effective in simple scenarios, these methods have limited performance in complex environments. The inventors recognized that these methods cannot effectively address the spectral heterogeneity between targets and backgrounds in hyperspectral data, making it difficult to accurately identify weak targets. For example, while existing deformable convolutional and dynamic filtering networks attempt to adapt to data variations through geometric deformation or dynamic weight adjustments to the kernel shape, these methods fail to adequately consider local spectral statistical properties (such as gradient distribution or inter-band correlation), resulting in insufficient sensitivity to weak targets. This limitation significantly increases false positive and false negative rates, especially when processing complex spectral features (such as mineral mixtures or pollutants), making it difficult to meet the needs of practical applications of hyperspectral data.
[0004] In the healthcare field, while existing medical image processing methods have improved the accuracy of image analysis by leveraging deep learning's convolutional neural networks, they still have significant limitations when processing high-dimensional data and complex images (such as tumors and organ structures in medical images). Traditional techniques rely on conventional convolutional kernels that are often too fixed and difficult to adapt to the complex spectral variations of different tissues and lesion regions. Furthermore, standard convolutional operations typically use static kernels, which cannot adaptively process different regions of data, especially lacking in handling detailed information in minute areas such as tumor margins. Therefore, in image analysis of various lesions and target detection in medical images, traditional techniques cannot comprehensively solve the problem of accurately locating and processing faint targets.
[0005] In the field of agricultural insurance, especially in crop detection and loss assessment, traditional methods typically rely on manually designed feature extraction techniques and experience-based rules for crop health assessment and risk prediction. However, these traditional methods often struggle to achieve accurate prediction and real-time monitoring under the influence of complex weather conditions, different soil types, and variations in crop growth cycles. Traditional technologies cannot fully utilize the rich spectral information and spatial features in hyperspectral data, resulting in insufficient sensitivity in identifying risks such as pests, diseases, droughts, or floods, easily leading to misjudgments or missed detections. While the development of deep learning and hyperspectral image processing technologies has led to some progress in improving detection accuracy, these methods still suffer from high error rates and missed detection rates in complex environments because they rely on static convolution kernels, cannot adapt to spectral changes during crop growth, and fail to effectively consider spectral statistical characteristics. Summary of the Invention
[0006] The main objective of this application is to provide a method, apparatus, device, and storage medium for spectral data processing based on adaptive convolution, which aims to solve the technical problem that traditional techniques cannot effectively adapt to the spectral heterogeneity between targets and background in hyperspectral data, resulting in insufficient sensitivity for identifying weak targets.
[0007] To achieve the above objectives, this application provides a spectral data processing method based on adaptive convolution, comprising:
[0008] Acquire input spectral data;
[0009] Based on the input spectral data, a spectral gradient attention map is determined;
[0010] Determine the spectral statistics of local data blocks in the input spectral data;
[0011] Based on the spectral statistics, generate kernel parameters;
[0012] Based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated.
[0013] The input spectral data is processed by the region-adaptive convolution kernel to obtain the first feature stream;
[0014] Perform derivative analysis on the input spectral data to generate a second feature stream;
[0015] The first feature stream and the second feature stream are fused to generate a fused feature, and a target detection result is generated based on the fused feature.
[0016] Furthermore, to achieve the above objectives, this application provides a spectral data processing apparatus based on adaptive convolution, comprising:
[0017] The data acquisition module is used to acquire input spectral data;
[0018] The spectral gradient calculation module is used to determine the spectral gradient attention map based on the input spectral data.
[0019] The spectral statistics determination module is used to determine the spectral statistics of local data blocks in the input spectral data;
[0020] A kernel parameter generation module is used to generate kernel parameters based on the spectral statistics.
[0021] An adaptive convolution kernel generation module is used to generate a region adaptive convolution kernel based on a base convolution kernel, the spectral gradient attention map, and the kernel parameters.
[0022] The feature extraction module is used to process the input spectral data through the region adaptive convolution kernel to obtain a first feature stream;
[0023] The derivative analysis module is used to perform derivative analysis on the input spectral data to generate a second feature stream;
[0024] The feature fusion and target detection module is used to fuse the first feature stream and the second feature stream to generate fused features, and to generate target detection results based on the fused features.
[0025] Furthermore, to achieve the above objectives, this application also provides a computer device, the computer device including a memory, a processor, and an adaptive convolution-based spectral data processing program stored in the memory and executable on the processor, wherein when the adaptive convolution-based spectral data processing program is executed by the processor, it implements the following steps of the adaptive convolution-based spectral data processing method as described above:
[0026] Acquire input spectral data;
[0027] Based on the input spectral data, a spectral gradient attention map is determined;
[0028] Determine the spectral statistics of local data blocks in the input spectral data;
[0029] Based on the spectral statistics, generate kernel parameters;
[0030] Based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated.
[0031] The input spectral data is processed by the region-adaptive convolution kernel to obtain the first feature stream;
[0032] Perform derivative analysis on the input spectral data to generate a second feature stream;
[0033] The first feature stream and the second feature stream are fused to generate a fused feature, and a target detection result is generated based on the fused feature.
[0034] Furthermore, to achieve the above objectives, this application also provides a non-volatile computer-readable storage medium storing an adaptive convolution-based spectral data processing program, which, when executed by a processor, implements the steps of the adaptive convolution-based spectral data processing method described above.
[0035] Beneficial effects: This application improves the detection accuracy of weak targets in hyperspectral data by adjusting the convolution kernel structure and combining spectral gradient information, overcoming the problems of static convolution kernels and insufficient feature extraction in traditional methods, and can effectively handle target detection tasks in complex backgrounds. Attached Figure Description
[0036] The present application will be further described below with reference to the accompanying drawings and embodiments. In the accompanying drawings:
[0037] Figure 1 is a schematic diagram of an application environment for a spectral data processing method based on adaptive convolution in one embodiment of this application;
[0038] Figure 2 is a flowchart illustrating an embodiment of the spectral data processing method based on adaptive convolution of this application;
[0039] Figure 3 is a schematic diagram of the functional modules of a preferred embodiment of the spectral data processing device based on adaptive convolution of this application;
[0040] Figure 4 is a structural schematic diagram of a computer device according to an embodiment of this application;
[0041] Figure 5 is another structural schematic diagram of a computer device according to one embodiment of this application. Detailed Implementation
[0042] It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the scope of this application.
[0043] The adaptive convolution-based spectral data processing method provided in this application can be applied in the application environment shown in Figure 1, where the user terminal communicates with the server via a network. The server can obtain input spectral data from the user terminal, generate a spectral gradient attention map based on the input spectral data, obtain spectral statistics of local data blocks and generate kernel parameters, generate a region adaptive convolution kernel based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, process the input spectral data using this convolution kernel to obtain a feature stream, perform derivative analysis to generate a second feature stream, and finally fuse the two feature streams to generate a target detection result based on the fused features. This application improves the detection accuracy of weak targets in hyperspectral data by adjusting the convolution kernel structure and combining spectral gradient information, overcoming the problems of static convolution kernels and insufficient feature extraction in traditional methods, and can effectively handle target detection tasks in complex backgrounds. The user terminal can be, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server can be implemented using a standalone server or a server cluster consisting of multiple servers. The following detailed description of specific embodiments further illustrates this application.
[0044] Please refer to Figure 2, which is a flowchart illustrating an embodiment of the adaptive convolution-based spectral data processing method provided in this application. It should be noted that although a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than that shown here.
[0045] As shown in Figure 2, the spectral data processing method based on adaptive convolution proposed in this application includes the following steps:
[0046] S10, acquire input spectral data;
[0047] In this embodiment, acquiring input spectral data can involve obtaining hyperspectral images or spectral data from the external environment and converting them into a digital format suitable for subsequent processing. Spectral data reflects the reflection or radiation characteristics of a target object on electromagnetic waves of different wavelengths. By acquiring this data, the chemical composition, surface structure, and environmental conditions of the object can be revealed. Acquiring input spectral data typically relies on specialized sensing devices, such as hyperspectral cameras, remote sensing satellites, or UAV-borne sensors. These sensing devices scan the target area to obtain spectral image data containing multiple bands. Each band represents the reflection intensity of the target in a specific electromagnetic band, and typically includes dozens to hundreds of bands, forming a multidimensional dataset.
[0048] First, spectral imaging technology is needed to acquire data from the target area. Data acquisition devices, such as hyperspectral sensors or cameras, sequentially capture images of the target area in different spectral bands according to predetermined settings. Each image contains reflection or radiation data of that area within a specific wavelength range. The acquired data often has high dimensionality; each pixel is assigned a vector containing the reflection intensity across multiple spectral bands. To ensure data quality and accuracy, in practice, the acquired spectral data typically undergoes preprocessing, such as radiometric correction, geometric correction, and noise filtering. Radiometric correction eliminates inconsistencies in the responses of different sensors, while geometric correction ensures the accurate spatial positioning of each pixel in the image.
[0049] In specific applications such as crop health monitoring, mineral resource exploration, and environmental pollution analysis, the acquisition of spectral data often needs to be optimized in conjunction with the specific application objectives. For example, in agriculture, when scanning farmland with spectral sensors, the growth status and health condition of different crops will affect the reflectance characteristics of the spectral data. Using appropriate wavelengths (such as near-infrared and visible light bands) can help accurately identify the health status of crops. In this process, the selection and setting of the sensor are key factors determining the data quality. Different sensors may have different spectral response characteristics, resulting in differences in the quality of the acquired data.
[0050] Depending on the specific needs, the acquired spectral data can be categorized into different spatial and spectral resolutions. For example, high-resolution sensors can provide detailed spatial information, while high-spectral-resolution devices can acquire more spectral information, thus providing richer spectral features for subsequent data processing and analysis. In this case, the acquired spectral data needs to be stored, transmitted, and subsequently processed to ensure it meets the analytical requirements of different targets.
[0051] The acquisition of input spectral data is achieved through the use of hyperspectral imagers. These devices can perform high-precision scanning of a large area in a short time, thereby acquiring a complete hyperspectral image. Spectral data acquisition is typically performed within a specific wavelength range, capturing reflected light from the object's surface through the sensor's spectral response. Modern spectral sensors generally employ a scanning mode, progressively acquiring the reflection intensity of each band, and ultimately combining all band data into a single image containing multiple bands.
[0052] This embodiment provides rich spectral information through high-precision spectral data acquisition to support subsequent target detection and feature extraction, particularly in the fields of agriculture and environmental monitoring, improving the identification accuracy of various targets such as crops and environmental quality. By dynamically adjusting the sensor configuration and selecting appropriate bands, it can effectively adapt to different application scenarios, overcoming the problems of static feature extraction and lack of detail capture in traditional methods.
[0053] S20, Based on the input spectral data, determine the spectral gradient attention map;
[0054] In this embodiment, determining the spectral gradient attention map based on the input spectral data aims to highlight important regions in the image by calculating gradient information in the input spectral data, and to provide effective guidance for subsequent feature extraction. The generation process of the spectral gradient attention map mainly relies on gradient calculation techniques, which can reflect the degree of change of the image in the spatial and spectral dimensions. Specifically, the spectral gradient represents the rate of change of each pixel in the image in the spectral and spatial directions, and is often used to reveal the difference between the target and the background in the image, helping to further improve the accuracy of target detection.
[0055] Spectral gradient calculation typically involves two aspects: spatial gradient and spectral gradient. The spatial gradient reflects the changes in an image's spatial location, while the spectral gradient reflects the changes in the image across different spectral bands. In practical applications, the spatial gradient can be calculated along the spatial dimension of the image by applying gradient operators (such as the Sobel operator), while the spectral gradient calculates the changes of each pixel across different spectral bands. By calculating both spatial and spectral gradients, a gradient magnitude map can be obtained. This map represents the gradient intensity of each region in the image and is typically used to mark regions with significant changes, which may contain important target information.
[0056] Spectral gradients can be calculated by applying appropriate gradient operators to each pixel of the input spectral data in both the spatial and spectral dimensions. First, a gradient operator (such as the Sobel operator) is applied to the spatial dimension of the input spectral data to calculate the spatial gradient components. Then, a gradient operator (such as a gradient filter) is applied to the spectral dimension to calculate the spectral gradient components. The spatial and spectral gradients are then combined to obtain a gradient magnitude map, which represents the intensity of change in each region. To enhance computational accuracy, the gradient magnitude map is typically normalized to a uniform range for subsequent processing.
[0057] In practice, common techniques for calculating spectral gradient attention maps include the Sobel operator and the Prewitt operator. These operators effectively capture edge features in images and help distinguish target and non-target regions in complex backgrounds. For specific applications, gradient calculation methods can be adjusted as needed to achieve optimal feature extraction results. For example, in agricultural monitoring, by selecting appropriate bands and using suitable gradient operators, the difference between crops and the background can be effectively highlighted, thereby improving the accuracy of target detection.
[0058] In practice, the generation of spectral gradient attention maps can be achieved using efficient image processing algorithms. First, input data is acquired using a hyperspectral imaging sensor, containing information from multiple spectral bands. For each pixel, the spatial gradient is calculated using the Sobel operator or another appropriate gradient operator. This process can be easily implemented using existing image processing libraries such as OpenCV. Next, the gradient operator is applied to calculate the changes in the spectral dimensions, obtaining the gradient information for each band. Finally, the spatial and spectral gradients are synthesized to generate a gradient magnitude map, which is then normalized to obtain the spectral gradient attention map.
[0059] In specific applications, such as agricultural monitoring, gradient calculations can be performed by selecting specific spectral bands (such as near-infrared or visible light bands) based on the spectral characteristics of the crop. This allows the calculated gradient information to more effectively reflect the differences between the crop and the background, further improving the accuracy of target detection.
[0060] This embodiment effectively enhances key features in images by calculating spectral gradient attention maps, especially against complex backgrounds, highlighting the difference between the target area and the background. This improves the ability to identify weak targets during subsequent feature extraction, particularly in fields such as crop monitoring and environmental monitoring, thereby increasing detection accuracy and reliability. The spectral gradient attention map provides effective input for subsequent dynamic convolution and feature fusion, significantly enhancing target detection performance.
[0061] S30, determine the spectral statistics of local data blocks in the input spectral data;
[0062] In this embodiment, determining the spectral statistics of local data blocks in the input spectral data aims to extract valuable local feature information from the hyperspectral image, providing strong support for subsequent feature generation and target detection. In this process, the spectral data is divided into multiple local data blocks, each containing a portion of the pixels in the image. These data blocks are typically small regions, effectively capturing the spectral features within that region. Spectral statistics include mean, variance, and skewness, which reflect the distribution characteristics of the spectral data, helping to describe the spectral behavior and characteristics of the target, especially highlighting the difference between the target and the background in complex environments.
[0063] Specifically, the calculation of spectral statistics for local data blocks includes the following key parts:
[0064] Spectral mean calculation: The spectral mean reflects the average value of all spectral bands in each local data block, representing the overall distribution of the spectral characteristics of that region. The mean is typically calculated by taking the arithmetic mean of the reflectance intensity of each pixel within that region across different bands.
[0065] Spectral variance calculation: Variance reflects the degree of fluctuation in spectral data. A larger variance usually means that there are greater spectral variations in that region, which may indicate the presence of a significant target or foreign object. The variance calculation process is achieved by finding the difference between the reflectance intensity of each pixel and the mean value of that local region.
[0066] Spectral skewness calculation: Skewness reflects the skewness of spectral data distribution and can reveal the symmetry of spectral data in a region. If the spectral values in a certain band are skewed (e.g., biased towards higher or lower values), the skewness value will be larger. Calculating skewness through third-order moment analysis can further reveal the distribution characteristics of spectral data.
[0067] These statistics can comprehensively describe the spectral information of a local region, providing richer spectral features. The calculation process in this step typically involves statistical analysis of the spectral bands within each local data block, and the resulting spectral statistical features are used to generate subsequent kernel parameters and other features.
[0068] In practical implementation, the input spectral data first needs to be divided into blocks, dividing the entire image into multiple small regions, called local data blocks. Each local data block typically has a certain size, which can be adjusted according to the image resolution and application requirements. For example, in agricultural monitoring applications, the size of the local data block can be adjusted according to the crop growth area, while in environmental monitoring, it can be divided according to the size of different pollution areas. For each local data block, its spectral mean is first calculated, which can be obtained by averaging the reflectance intensity of each pixel within the data block across multiple bands. Next, the variance and skewness are calculated. The variance calculation involves the difference between the reflectance intensity of each pixel and the mean, while the skewness is measured by calculating the third moment to measure the degree of skewness in the distribution of the spectral data. These statistics, through feature extraction of local regions, provide important information for subsequent kernel parameter generation. Through statistical analysis of multiple local data blocks, the overall spectral features of the image region can be obtained, providing strong support for target detection and classification. Furthermore, in terms of data storage and computation, the statistics for each local data block can be stored using an efficient data structure, facilitating subsequent processing. Meanwhile, to improve computational efficiency, optimizations can be made when calculating variance and skewness to reduce redundant calculations, and parallel computing techniques can be used to improve the overall processing speed.
[0069] This embodiment extracts key information from each local region by calculating spectral statistics of local data blocks in the input spectral data, providing richer and more efficient spectral features for subsequent target detection. By calculating statistics such as mean, variance, and skewness, the spectral characteristics of different regions in the image can be comprehensively described, providing reliable input for subsequent dynamic convolution and feature fusion. This effectively improves the accuracy and precision of detection in complex backgrounds and for weak targets, providing strong data support, especially in fields such as crop health monitoring and environmental pollution detection.
[0070] S40, Generate kernel parameters based on the spectral statistics;
[0071] In this embodiment, generating kernel parameters based on the spectral statistics aims to transform the spectral statistical characteristics of local data blocks into kernel parameters suitable for subsequent convolution operations. Spectral statistics (including mean, variance, skewness, etc.) provide rich local feature information for spectral data, and the process of generating kernel parameters maps this feature information to the adjustment of the convolution kernel, so as to dynamically adjust the shape and weights of the filter during the convolution operation.
[0072] Generating kernel parameters first requires inputting spectral statistics, which are typically calculated in the previous step through spectral analysis of local data blocks. Processing these spectral statistics yields latent features that contribute to the subsequent kernel deformation. These latent features are then fed into the parameter prediction model for nonlinear mapping, generating latent variable representations that reflect the spectral characteristics and spatial structure information of the local region. Through this representation, the model can perform more detailed modeling of the spectral features of the local region and generate kernel parameters applicable to that region.
[0073] In this process, the parametric prediction model typically includes an encoder that performs a nonlinear mapping on the input spectral statistics. The encoder is a neural network-based structure that, through training, learns how to transform spectral statistical properties into kernel deformation parameters adapted to different targets. The generated latent variable representations undergo a linear transformation to obtain the kernel deformation parameters. These parameters determine the shape and size of the convolutional kernel, enabling it to better adapt to the local features and variations of the input data. The generated kernel parameters are then normalized to ensure the stability and validity of the parameter values.
[0074] In implementation, spectral statistics are first collected and preprocessed using sensor devices. The resulting statistical properties, such as spectral mean, variance, and skewness, are then input into the parameter prediction model. This model can be a deep neural network, particularly one with an encoder structure, such as the Transformer encoder, to perform a nonlinear mapping of these statistics. Specifically, the spectral statistics are concatenated into a vector and provided as input to the encoder. The encoder extracts features from the input data, learning how to associate spectral statistics with target features to generate latent variable representations suitable for the region. Then, through a linear transformation, these latent variable representations are converted into kernel transformation parameters.
[0075] To further improve the accuracy and adaptability of kernel parameter generation, the generated kernel parameters can be normalized. Normalization ensures that the kernel parameter values are within a uniform range, thus avoiding numerical overflow or instability in subsequent convolution operations. The normalized kernel parameters can be directly applied to convolution operations for dynamic kernel adjustment, thereby enhancing the accuracy of object detection.
[0076] This embodiment generates kernel parameters based on spectral statistics, enabling dynamic adjustment of the convolution kernel to adapt to the spectral characteristics of different regions. This improves the ability to identify weak targets, especially in hyperspectral data, by providing detailed modeling of the spectral differences between the target and the background, thereby enhancing the accuracy of target detection. In complex backgrounds and diverse target scenarios, the generated kernel parameters effectively adapt to data variations, overcoming the limitations of static convolution kernels in traditional methods, and providing more flexible and efficient support for subsequent feature extraction and target detection.
[0077] S50, based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated;
[0078] In this embodiment, the purpose of generating region-adaptive convolution kernels is to dynamically adjust the shape and weights of the convolution kernels by combining spectral gradient information and local spectral statistical properties, so that they can better adapt to the spectral differences between the target and the background in hyperspectral data. This process involves combining the basic convolution kernel with the spectral gradient attention map and kernel parameters, and generating a convolution kernel that can adapt to spectral and spatial characteristics through element-wise operations and nonlinear transformations.
[0079] First, the basic convolutional kernel is loaded as an initialization template into the kernel deformation processing module. The basic convolutional kernel is a fixed-shape kernel, typically used to capture common features in images, such as edges and textures. However, hyperspectral image data has high dimensionality and rich spectral information; relying solely on the basic convolutional kernel often fails to accurately capture target features, especially in regions with significant spectral heterogeneity. To enhance the adaptability of the basic convolutional kernel, it must be dynamically adjusted according to the characteristics of the input data.
[0080] In this process, the spectral gradient attention map plays a crucial role. A spectral gradient attention map reflects changes in spectral information and can highlight regions of significant spectral variation, such as the interface between the target and the background. By using the spectral gradient attention map, the convolution kernel can be adjusted based on areas of significant spectral variation in the image, allowing the kernel to focus more on these changing regions and enhancing the ability to identify faint targets.
[0081] Next, element-wise multiplication of the basic convolution kernel is performed using the kernel parameters to generate an initial deformation kernel. The kernel parameters are feature parameters generated based on spectral statistics. By modeling the spectral statistical characteristics of local regions, these parameters can effectively guide changes in the convolution kernel's shape. The element-wise multiplication operation multiplies each element of the basic convolution kernel with the corresponding kernel parameter, thereby generating an initial deformation kernel adapted to the current data characteristics.
[0082] Then, the initial deformation kernel is input into a multilayer perceptron (MLP) for nonlinear transformation. The MLP is a neural network structure capable of capturing complex nonlinear relationships. It further processes the initial deformation kernel, making the shape and weights of the convolutional kernel more consistent with the characteristics of the input data. In this process, the MLP generates intermediate deformation kernels through multiple levels of nonlinear transformation. These intermediate kernels contain more spatial and spectral information, providing more accurate feature extraction capabilities for subsequent object detection.
[0083] The scaling factor of the intermediate deformation kernel is adjusted based on the spectral gradient attention map. The spectral gradient attention map effectively reflects the spectral changes of the target region in the image, and therefore can serve as an important basis for adjusting the spectral dimension of the convolution kernel. By scaling the intermediate deformation kernel, the convolution kernel can be made more concentrated in the target region in the spectral dimension, improving the response capability to the target signal.
[0084] The adjusted intermediate deformation kernel is normalized to generate the final region-adaptive convolution kernel. Normalization ensures the stability of the convolution kernel, preventing values from becoming too large or too small in subsequent convolution operations. Through this process, the resulting region-adaptive convolution kernel can adaptively adjust according to the spectral and spatial characteristics of the input data, significantly improving the accuracy of target detection.
[0085] In practical implementation, standard convolutional kernels, such as 3x3 or 5x5 kernels, can be used as initialization templates. The generation of the spectral gradient attention map depends on the acquisition and processing of hyperspectral image data. The Sobel operator or other gradient operators can be used to calculate the spectral gradient in the image. The calculated spectral gradient information is then normalized to generate a standardized spectral gradient attention map. Based on this attention map, subsequent adjustments to the convolutional kernel can better focus on spectral changes in the target region. The generation of kernel parameters depends on the calculation of spectral statistics. Latent variable representations can be generated using a deep neural network model, and further linear transformations can be used to obtain kernel deformation parameters. Parameter adjustments in this process can be optimized through model training to adapt to different spectral features. After the convolutional kernel is generated, it is input into a multilayer perceptron for nonlinear transformation to generate an adaptive intermediate deformation kernel. Finally, the intermediate deformation kernel is normalized to ensure that the generated convolutional kernel is stable and effective in subsequent calculations.
[0086] This embodiment generates a region-adaptive convolution kernel based on a basic convolution kernel, a spectral gradient attention map, and kernel parameters. This effectively addresses the problem that traditional static convolution kernels cannot adapt to the spectral heterogeneity of targets and backgrounds in hyperspectral data. The generated region-adaptive convolution kernel can flexibly adjust according to the spectral and spatial characteristics of the input data, significantly improving the accuracy of target detection, especially in the identification of complex backgrounds and faint targets, which has significant practical application value. It not only enhances the ability to identify targets but also strengthens the robustness of the detection system in complex scenes.
[0087] S60, the input spectral data is processed by the region adaptive convolution kernel to obtain the first feature stream;
[0088] In this embodiment, the input spectral data is processed using a region-adaptive convolutional kernel to generate a first feature stream, aiming to extract useful features from the input data using the generated adaptive convolutional kernel. This process utilizes a dynamically adjusted convolutional kernel that automatically adapts to the spectral features of different regions, thereby improving the accuracy of feature extraction in target detection. By capturing spatial and spectral variations in the input spectral data, the region-adaptive convolutional kernel can more accurately identify target regions and enhance the response to weak signals.
[0089] First, the generated region-adaptive convolutional kernel is applied to the input spectral data. The input spectral data is typically hyperspectral image data, which contains information from multiple spectral bands, reflecting the reflectance intensity at different bands. The region-adaptive convolutional kernel can effectively extract key information from this multidimensional data, especially when dealing with data with significant spectral heterogeneity; its dynamic adjustment capability can significantly improve the accuracy of target region recognition.
[0090] Specifically, the region-adaptive convolutional kernel performs convolution operations within each local region. The convolution operation involves a sliding window approach, where the kernel is used to perform local operations on local regions within the input spectral data, progressively calculating local features. During this process, the kernel is adjusted based on the spectral gradient attention map and local spectral statistics in the image to better respond to the features of the target region.
[0091] After the convolution operation is completed, a preliminary feature map (i.e., a convolutional feature map) is obtained, which contains local feature information of the input data in the spatial and spectral dimensions. However, since these feature maps often still contain complex background information, further processing is required to improve the effectiveness of the features.
[0092] In practical implementation, the first step is to acquire input hyperspectral image data. This data can come from hyperspectral cameras, satellite remote sensing equipment, etc., obtaining the reflectance intensity information of each pixel in multiple spectral bands, forming a multidimensional dataset. Then, a generated region-adaptive convolutional kernel is applied to this spectral data for convolution operations. Each local data block is processed by the convolutional kernel to obtain a corresponding initial convolutional feature map. Next, the convolutional feature map is activated using a non-linear activation function (such as ReLU or Sigmoid). The activation function introduces a non-linear transformation, enabling the convolutional features to adapt to more diverse image data features and enhancing the response of the target region. The activated feature map obtained after activation highlights the target features more clearly and suppresses background interference. Subsequently, feature compression or fusion can be performed on the activated feature map to improve the effectiveness of the feature stream. Through a feature channel compression module, the computational load can be reduced and redundant information can be effectively removed, ultimately obtaining a more refined first feature stream. This feature stream contains the core information of the input spectral data, has high resolution and strong feature representation capabilities, and can provide high-quality input data for subsequent target detection tasks.
[0093] This embodiment utilizes a region-adaptive convolutional kernel to process the input spectral data, significantly improving target recognition accuracy. Traditional convolutional kernels often struggle to adapt to the complex spectral characteristics of hyperspectral images, while the region-adaptive convolutional kernel, guided by spectral gradient attention maps and local spectral statistics, can automatically adapt to spectral differences in the image. It performs exceptionally well in recognizing complex backgrounds and faint targets, effectively enhancing target detection accuracy and reducing false negatives. It exhibits significant advantages, particularly when processing hyperspectral data with spectral heterogeneity.
[0094] S70, perform derivative analysis on the input spectral data to generate a second feature stream;
[0095] In this embodiment, the main purpose of performing derivative analysis on the input spectral data to generate the second feature stream is to extract important information related to spatial and spectral characteristic changes by analyzing the rate of change (i.e., derivative) of the spectral data, thus providing more in-depth features for target detection. Derivative analysis can not only help reveal changes in local regions of an image, but also identify subtle differences between the target and the background by capturing these changes.
[0096] For each pixel of the input spectral data, derivative calculations involve both the spatial and spectral dimensions of the image. The spatial derivative reflects the changes in the image's spatial location, helping to identify edges of targets or transitions between regions. The spectral derivative reflects the changes in the image across different spectral bands, helping to reveal the characteristics of targets in different bands. By calculating the derivatives of the spectral data in both spatial and spectral dimensions, local variation features of the image can be effectively extracted; these features are often closely related to the presence of target regions.
[0097] Hyperspectral data is often affected by sensor noise and environmental noise. Directly calculating derivatives may amplify the noise, thus affecting the accuracy of subsequent analyses. Therefore, a noise suppression layer is usually added before performing derivative analysis. The purpose of the noise suppression layer is to reduce the impact of noise on data analysis and enhance the ability to distinguish between signals and noise. Noise suppression can be achieved in various ways, such as using convolutional neural networks (CNNs) for noise removal or using simple filtering methods for smoothing.
[0098] After calculating the derivative, the resulting derivative feature map typically contains a wealth of information, but this information may not be suitable for direct object detection. To make these features more discriminative, nonlinear activation processing is required. Activation functions (such as ReLU or Sigmoid) can transform these original features nonlinearly, making them more suitable for subsequent convolution operations. The activated derivative features can highlight important information regions in the image while suppressing interference from background information.
[0099] Finally, the derivative activation features are fused with the input spectral data through residual connections to generate a second feature stream. Residual connections are a technique for fusing different feature data, aiming to enhance the expressiveness of feature information without losing the original data. Here, the residual connection between the derivative activation features and the input spectral data ensures that the original information of the spectral data is preserved, while combining the feature information extracted by derivative analysis with the original data to generate a richer second feature stream. In this way, the second feature stream can effectively improve the accuracy of target recognition, especially in the identification of complex backgrounds and weak targets.
[0100] This embodiment effectively enhances the detection capability of weak targets in images by performing derivative analysis and generating a second feature flow. Derivative analysis can capture changes in spatial and spectral dimensions in images, especially edges and transition regions, thereby improving the response of target regions. In complex backgrounds and with high noise levels, derivative analysis can effectively suppress noise through nonlinear activation and residual connections, enhancing the recognition capability of target features.
[0101] S80, the first feature stream and the second feature stream are fused to generate a fused feature, and a target detection result is generated based on the fused feature.
[0102] In this embodiment, the feature stream fusion process aims to improve the accuracy and robustness of target detection by combining information from different feature streams. The first feature stream originates from features obtained by processing the input spectral data using region-adaptive convolutional kernels, while the second feature stream originates from features generated after processing the input spectral data using derivative analysis. These two feature streams extract information from different aspects of the spectral data. The first feature stream primarily focuses on the spatial and spectral features of local regions, while the second feature stream emphasizes subtle changes in the image and the edge information of the target.
[0103] First, the first and second feature streams need to be fused. They contain different feature information: the first feature stream extracts overall features from the image through convolution operations, while the second feature stream captures subtle changes and target edges through derivative analysis. Therefore, fusing their information provides more comprehensive image features, increasing the accuracy of object detection.
[0104] Fusion operations can be implemented in several ways, including additive fusion, concatenation fusion, or weighted fusion using attention mechanisms. The specific method chosen depends on the requirements of the application scenario. In additive fusion, features from the first and second feature streams at the same location are summed; while in concatenation fusion, features from the first and second feature streams are concatenated along the channel dimension to form a new feature map. Furthermore, attention mechanisms can be used to assign different weights to different feature streams during fusion, thereby enhancing attention to key regions. Regardless of the method used, the fused feature map will contain information from both feature streams, which can be complementary, providing a richer feature representation.
[0105] The fused feature maps are then fed into an object detection network to generate the final detection result. In object detection tasks, generating object detection results typically involves the following steps:
[0106] Region Candidate Generation: Based on the fused feature maps, potential target regions in the image are identified using region proposal network (RPN) algorithms. These region candidates are typically image regions that may contain the target. After further processing, the location of the target is finally determined.
[0107] Target classification: Each candidate region is classified to determine whether it contains a target and to which category the target belongs. Classification is typically performed using fully connected layers or convolutional layers.
[0108] Bounding box regression: Regressing the bounding box of each candidate region accurately locates the target's boundary. Bounding box regression refines the candidate regions, ensuring the accuracy of the detection results.
[0109] The generated target detection results can be the target category and its location in the image, typically represented by bounding boxes and category labels. This method allows the fused features to help improve detection accuracy, especially in detecting complex backgrounds and faint targets.
[0110] In one specific implementation, raw data is extracted from a hyperspectral image, which includes reflectance intensity across multiple spectral bands. Hyperspectral images contain extensive spectral information, with each pixel having a series of band values, typically each band covering a specific wavelength range. According to tabular data, different band regions exhibit different spectral characteristics, and each region has varying spectral response capabilities, allowing subsequent processing steps to be adjusted based on these characteristics. For example, chlorophyll exhibits strong reflectance characteristics in the high-standard region (550-650 nm). Hyperspectral reflectance in this band is significant for crop health monitoring. The low-standard region (700-850 nm) is typically associated with a high plateau in the near-infrared, exhibiting characteristics of a water absorption band. This band is crucial for monitoring crop water and environmental changes. Anomaly regions (900-950 nm) are associated with a water absorption band and can effectively identify spectral information related to plant water content. Each region has different reflectance characteristics. The data can be represented as:
[0111]
[0112] Where H is the height of the image, W is the width of the image, and B is the number of bands. The reflection intensity of each pixel location in different bands represents the spectral characteristics of that location.
[0113] For the input spectral cube Calculate the spectral gradient attention map G:
[0114]
[0115] In the formula, ∇ represents the space-spectral gradient operator. Describing the L2 norm, For spatial coordinates, For spectral band indexing, This indicates finding the partial derivative. For position The gradient magnitude at a given point. This calculation is achieved through separable 3D convolution, using the Sobel operator in both the spatial and spectral dimensions, resulting in high computational efficiency and effective highlighting of spectral abrupt change regions. This design allows the model to automatically focus on discriminative spectral regions, improving the detection capability of weak targets.
[0116] For each local image patch Calculate three spectral statistics:
[0117] Mean:
[0118] variance:
[0119] Skewness:
[0120] in These are numerically stable terms. These statistics, after being concatenated, are input into the Transformer encoder of the parameter analysis model:
[0121]
[0122] in," " indicates vector concatenation. Output latent variables" Used to modulate nuclear deformation parameters, where This represents the feature dimension of the latent variable. Compared to directly predicting a large number of convolution kernel parameters, this indirect prediction method greatly reduces computational complexity while maintaining sensitivity to spectral characteristics.
[0123] Basic convolution kernel The gating deformation module generates instance-specific kernels, namely region-adaptive convolution kernels. :
[0124]
[0125] in For element-wise multiplication, It is the sigmoid activation function. For learnable weight matrix, As a bias term, MLP is a two-layer perceptron (hidden layer dimension). This design allows each spatial location (i,j) to have a unique convolution kernel, enabling adaptive matching to local spectral properties.
[0126] Output of dynamic convolution and Derivative calculation output Perform gating fusion:
[0127]
[0128] in, For adaptive fusion weights, It is the sigmoid activation function. and These are learnable parameters. This design can automatically adjust the fusion ratio based on the spectral gradient magnitude, enhancing feature selectivity while preserving the noise immunity of ZNNs. The final loss function is defined as:
[0129]
[0130] in, Loss for target detection ,in For real labels, To predict probabilities, This indicates the calculation of the logarithm. Feature consistency loss is defined as the mean squared error between the dynamically convolutional features and the ideal feature representation. ,in Features generated by dynamic convolution, This is a target feature representation based on expert knowledge. This represents the Frobenius norm. and These are the weighting coefficients.
[0131] This embodiment effectively improves the accuracy and robustness of target detection by fusing information from different feature streams. The first feature stream extracts global features of the image through convolution operations, while the second feature stream captures subtle changes and edge information in the image through derivative analysis. The fusion of the two provides more comprehensive information for target detection, significantly improving accuracy, especially in detecting complex backgrounds and faint targets. Furthermore, the fused features enhance sensitivity to variations in different spectral and spatial dimensions, thereby improving the reliability of the detection results.
[0132] In one embodiment, step S20 above includes:
[0133] S201, Apply the first directional gradient operator to the spatial dimension of the input spectral data to generate spatial gradient components;
[0134] S202, apply the second directional gradient operator to the spectral dimension of the input spectral data to generate spectral gradient components;
[0135] S203, Norm synthesis is performed on the spatial gradient component and the spectral gradient component to generate a gradient magnitude map;
[0136] S204, normalize the gradient magnitude map to generate the spectral gradient attention map.
[0137] In this embodiment, the purpose of generating a spectral gradient attention map is to highlight important target regions in the image by calculating the gradient information of the input spectral data, particularly the spectral and spatial variations. The spectral gradient attention map helps the detection algorithm accurately focus on regions with significant changes in the image, especially the edges or transition areas between the target region and the background.
[0138] Spatial gradient calculation is primarily used to capture the edge and contour information of objects in an image. By calculating the gradient of the spatial dimension of the input spectral data, variations in the horizontal and vertical directions of the image can be revealed. Gradient operators (such as the Sobel operator) can effectively detect edge features in an image by calculating the differences between neighboring pixels. In hyperspectral images, this process helps detect boundaries between different regions, such as the dividing lines between different crop species or transition areas between crops and the background. In this way, spatial gradient components are obtained, which represent the intensity of variation of each pixel in the image in spatial directions (such as horizontal and vertical).
[0139] Spectral gradient calculation captures the spectral differences in an image by evaluating the variations between different bands in the input spectral data. In hyperspectral images, different crops or substances typically exhibit different reflectance characteristics at different spectral bands. By calculating the spectral differences between different bands, the spectral heterogeneity between target and background regions in an image can be revealed. Spectral gradient calculation usually relies on differential processing of the reflectance intensity of adjacent bands. By comparing the spectral band information of each pixel and calculating the degree of change between each band, the spectral gradient information at each location in the image is obtained. This effectively captures regions with significant spectral differences in the image, which often correspond to target regions.
[0140] Spatial and spectral gradients capture the spatial and spectral variations of an image, respectively, but their synthesis provides more comprehensive information. Therefore, when generating a spectral gradient attention map, the spatial and spectral gradient components must first be merged. This synthesis is typically achieved by calculating the norms of both components and combining spatial and spectral variation information to generate a comprehensive gradient magnitude map. The gradient magnitude map represents the intensity of gradient changes in an image, which helps to highlight edges and transitions in target regions. By calculating the combined magnitude of the spatial and spectral gradients, an image feature map integrating spectral and spatial information can be obtained, emphasizing regions with important features in the image.
[0141] Finally, the gradient magnitude map is normalized to ensure its values are within a reasonable range, preventing instability in subsequent processing due to excessively large or small values. Normalization can be achieved through simple maximum value normalization or Z-score standardization, ensuring consistency of gradient information across different regions and features in the image. The normalized spectral gradient attention map effectively reflects important regions in the input spectral data, especially the difference between the target region and the background. This gradient attention map not only provides information on spatial and spectral dimensional variations but also assists the subsequent feature extraction process through optimized values, enabling more accurate identification of key regions in object detection.
[0142] This embodiment utilizes an attention map generation method based on spatial and spectral gradients to effectively enhance the saliency of target regions in images, particularly in the detection of complex backgrounds and faint targets. The spectral gradient attention map, by fusing spatial and spectral variation information, results in a stronger response from the target region, thereby improving detection accuracy and robustness.
[0143] In one embodiment, step S30 above includes:
[0144] S301, the input spectral data is divided into multiple local data blocks;
[0145] S302, Perform arithmetic mean analysis on all spectral band values of each local data block to generate the spectral mean feature of the local data block;
[0146] S303, perform variance analysis on the spectral band values of the local data block, and combine the numerical stability term to eliminate the zero variance error to generate spectral variance features;
[0147] S304, Perform third-order moment analysis on the spectral band values of the local data block to generate spectral skewness characteristics;
[0148] S305, the spectral mean feature, spectral variance feature and spectral skewness feature are vector-concatenated to generate the spectral statistics of the local data block.
[0149] In this embodiment, spectral statistical features of local regions are extracted from hyperspectral images to provide accurate spectral information for subsequent processing. Each local data block will generate representative statistical features by analyzing its spectral characteristics. These features include spectral mean, spectral variance, and spectral skewness, which help improve the accuracy of target detection, especially in the detection of complex backgrounds and weak targets.
[0150] The input spectral data first needs to be divided into multiple local data blocks, each consisting of a set of pixel regions. The spatial extent of these pixel regions is set according to the required analysis precision. For example, an image might be divided into 5×5 or 10×10 pixel blocks, each containing information from multiple spectral bands. This approach allows for detailed analysis of local regions within the image, capturing spectral variations in the target region while avoiding interference from background areas. This local data block division facilitates finer-grained image processing, enabling focus on changes in individual small regions within the image during object detection tasks, rather than just a global analysis of the entire image. This method allows the system to adaptively process different regions spatially, improving the accuracy and sensitivity of subsequent object detection algorithms.
[0151] Within each local data block, the values of all spectral bands are arithmetically averaged. The purpose of this process is to extract the average reflectance intensity information of the local data block across all spectral bands, thereby obtaining the spectral mean feature of that region. The spectral mean feature provides global spectral information for each region in the image, aiding subsequent feature processing. For example, the spectral mean features of healthy and diseased crops often differ significantly; by extracting the mean feature, the system can help identify healthy and damaged areas. In practice, the data from all spectral bands are simply averaged to obtain the mean feature of that local data block. These features provide preliminary spectral information for subsequent analysis, helping the system better understand and distinguish different regions in the image.
[0152] Variance is a measure of the dispersion of data. In image analysis, variance helps determine the variation of spectral band values within a region. A large variance indicates significant variation in the spectral characteristics of the region, potentially suggesting the presence of target information; a small variance indicates relatively stable spectral characteristics, possibly indicating background. When calculating variance, numerical instability can occur because spectral band values in some regions may approach zero. Therefore, a numerical stabilization term is introduced to eliminate the influence of zero-variance error. This ensures the accuracy of the variance calculation results and avoids errors caused by noise or small areas in the image.
[0153] Spectral skewness reflects the asymmetry of data distribution. In image analysis, skewness features help the system understand the distribution of spectral characteristics in a given region. A large skewness value indicates that the spectral distribution is biased towards one end, potentially representing a specific substance or regional feature. Spectral skewness features can further reveal the spectral differences between target and background regions in an image, thereby improving detection accuracy. Third-moment analysis is used to measure the skewness of data distribution and can further uncover the asymmetry of spectral variations in an image. By extracting spectral skewness, the system can identify regions with significant variations in the spectral dimensions, making it particularly suitable for detecting weak targets.
[0154] All extracted spectral statistical features (mean, variance, and skewness) are vector-concatenated to generate spectral statistics for local data blocks. This process integrates all spectral features of the local region, providing rich spectral information for subsequent target detection. By concatenating these features, the system can obtain the comprehensive spectral characteristics of each local data block, providing a complete spectral description for the target detection algorithm. The concatenated spectral statistics can better capture the spectral features in the image, especially the differences between the target region and the background region. The concatenation operation can combine multiple features of the local region, thus providing a more comprehensive image understanding.
[0155] This embodiment effectively captures important spectral features in an image by extracting spectral statistics from each local data block. The spectral mean feature provides spectral information for each region, the spectral variance feature reflects the degree of spectral variation within the region, and the spectral skewness feature reveals the asymmetry of the spectral distribution within the region. By fusing these features, the accuracy of target detection can be improved, especially in the identification of complex backgrounds and weak targets, effectively enhancing the response to target regions.
[0156] In one embodiment, step S40 above includes:
[0157] S401, Input the spectral statistics into the parameter analysis model;
[0158] S402, The encoder of the parameter analysis model performs a nonlinear mapping on the spectral statistics to generate a latent variable representation;
[0159] S403, Perform a linear transformation on the latent variable representation to generate kernel deformation parameters;
[0160] S404, normalize the nuclear deformation parameters to generate the nuclear parameters.
[0161] In this embodiment, kernel parameters capable of adjusting the shape of the convolution kernel are generated using spectral statistics. The process of generating kernel parameters involves processing the spectral statistics using a parametric analysis model to extract key feature information relevant to the target region. This process enables the generation of dynamically adaptable convolution kernels, thereby improving the accuracy and robustness of target detection, especially in the detection of complex backgrounds and weak targets.
[0162] In this process, the previously extracted spectral statistics (such as spectral mean, spectral variance, and spectral skewness) are first input into the parametric analysis model. These spectral statistics summarize the spectral information of each local data block, providing a foundation for subsequent convolutional kernel generation. These statistics help the model identify the spectral characteristics and variations in different regions of the image, serving as input information for generating kernel parameters. The parametric analysis model can be a neural network model; commonly used models include fully connected neural networks (FCNN) or convolutional neural networks (CNN). The input spectral statistics are processed layer by layer through the model for feature extraction, extracting features useful for object detection.
[0163] Once the spectral statistics are input into the parametric analysis model, they are then nonlinearly mapped by the model's encoder. The encoder typically consists of multi-layered neural networks (such as convolutional layers and fully connected layers), processing the input using nonlinear activation functions (such as ReLU and Sigmoid). The purpose of this nonlinear mapping is to transform the original spectral statistics into more complex feature representations (i.e., latent variables), which better capture the high-dimensional features and patterns in the input data. Through nonlinear mapping, the linear relationships contained in the original spectral statistics are expanded into more complex and high-dimensional latent feature representations, which provide more meaningful information for generating convolutional kernel parameters. For example, latent variable representations can reveal the complex relationships between spectral and spatial properties in an image, thereby helping to generate convolutional kernels suitable for the current image features.
[0164] After generating the latent variable representation, the next step is to perform a linear transformation on the latent variables. This linear transformation maps the latent variable representation to a new space to generate kernel deformation parameters. Linear transformations are typically implemented using matrix multiplication and addition operations, which can be done using a fully connected layer or a simple matrix transformation layer. Kernel deformation parameters represent the dynamic adjustment of the convolution kernel's shape and features; the shape of the convolution kernel changes according to different spectral statistical features. Kernel deformation parameters help generate a convolution kernel that adapts to the current image features, enabling the convolution kernel to more accurately capture target regions in the image. For example, for complex backgrounds or faint targets in an image, kernel deformation parameters can make the convolution kernel have a stronger response in specific regions, thereby improving the accuracy of target detection.
[0165] To ensure the stability of the kernel deformation parameters and make them suitable for subsequent convolution operations, the kernel deformation parameters need to be normalized. Normalization typically employs methods such as L2 norm normalization or Z-score normalization to scale the kernel deformation parameters to a suitable range. This process helps stabilize the training process of the neural network and avoids model instability caused by parameters that are too large or too small. After normalization, the generated kernel parameters will adapt to different features in the image, ensuring that the convolution kernel can efficiently extract the spectral features of the target region. The normalized kernel parameters can be used as input to a dynamic convolution kernel, and after adjustment, can be directly used for subsequent feature extraction and object detection tasks.
[0166] This embodiment utilizes spectral statistics to generate kernel parameters, effectively improving the adaptability of convolutional kernels when processing hyperspectral data. Dynamically adjusted convolutional kernels can respond more accurately to target regions in images based on spectral and spatial characteristics. This effectively addresses the shortcomings of traditional static convolutional kernels in complex spectral and background environments, significantly improving target detection accuracy, especially when processing high-dimensional data, weak targets, and complex backgrounds.
[0167] In one embodiment, step S50 above includes:
[0168] S501, perform element-wise multiplication of the basic convolution kernel with the kernel parameters to generate the initial deformation kernel;
[0169] S502, the initial deformation kernel is input into a multilayer perceptron for nonlinear transformation to generate an intermediate deformation kernel;
[0170] S503, adjust the scaling factor of the spectral dimension of the intermediate deformation kernel according to the spectral gradient attention map;
[0171] S504, the adjusted intermediate deformation kernel is normalized to generate the region adaptive convolution kernel.
[0172] In this embodiment, a region-adaptive convolutional kernel is generated by combining a basic convolutional kernel, a spectral gradient attention map, and kernel parameters. This kernel can be dynamically adjusted according to the local spectral characteristics of the image, helping to extract features related to the target and thus improving the accuracy of target detection.
[0173] The basic convolutional kernel is typically a predefined kernel that performs standard convolution operations in an image. In hyperspectral image processing, due to the diversity of spectral and spatial dimensions in images, the basic convolutional kernel may not be able to directly adapt to different regional features. To adapt to different spectral variations and spatial features, the basic convolutional kernel is first multiplied element-wise with kernel parameters generated from the input spectral data. Element-wise multiplication multiplies each element of the basic convolutional kernel with its corresponding kernel parameter, thus deforming the kernel. The purpose of this operation is to change the weights of the convolutional kernel by adjusting the kernel parameters, making it more adaptable to the features of the current input data. The generated initial deformed kernel provides a dynamically adjusted basic kernel for subsequent convolution operations based on image features, thereby improving the responsiveness to target regions in the image.
[0174] Preliminary deformed convolutional kernels are generated, but these deformed kernels may still not perfectly adapt to different spectral properties or target features. Therefore, further nonlinear transformation using a multilayer perceptron (MLP) is required. An MLP is a neural network composed of multiple fully connected layers that can learn more complex feature maps by processing the initial deformed kernel. In this process, the MLP takes the initial deformed kernel as input and processes it through multiple nonlinear activation layers (such as ReLU, Sigmoid, etc.) to generate intermediate deformed kernels. This process enables the convolutional kernel to learn the spectral and spatial features of the image at multiple levels, further enhancing its adaptability.
[0175] A spectral gradient attention map is a map generated during image processing by calculating the gradient changes in the spectrum of an image. This map represents important feature regions in the image. It highlights areas of significant variation, helping convolution operations focus on these key regions. In this process, the spectral dimension of the intermediate deformation kernel can be scaled and adjusted using the spectral gradient attention map. The values of the spectral gradient attention map represent the intensity of variation between different bands in the image, and therefore can be used as adjustment coefficients to determine the weight distribution of the intermediate deformation kernel across different bands. Specifically, scaling the spectral dimension of the intermediate deformation kernel using the values in the spectral gradient attention map allows the convolution kernel to have a higher response in important regions (such as target boundaries or target areas), thereby improving target detection accuracy.
[0176] Finally, normalization is applied to the adjusted intermediate deformation kernel to ensure that the kernel value does not become too large or too small, causing model instability. Normalization typically uses L2 norm or Z-score standardization to scale the kernel value to a reasonable range. Through normalization, the generated region-adaptive convolutional kernel remains stable under different image features and application scenarios, effectively performing convolution operations with the image to extract important spatial and spectral features. This final convolutional kernel adapts to different spectral and spatial characteristics, thereby improving object detection performance, especially in the detection of complex backgrounds and weak targets.
[0177] For example, a basic convolutional kernel is typically a standard convolutional kernel, such as a 3×3 or 5×5 matrix. A basic 3×3 convolutional kernel might look like this:
[0178]
[0179] This basic convolutional kernel is able to detect edge features in an image. It is fixed and does not dynamically adjust for the spectral features in the input data.
[0180] A spectral gradient attention map is generated by calculating the spectral gradient of the input spectral data. This map highlights regions in the image with significant spectral variations (e.g., edges between the target and background). Assume the gradient magnitude map calculated using the Sobel operator is as follows:
[0181]
[0182] Each value here represents the gradient intensity at the corresponding location in the image. Larger values indicate greater spectral variation in the region, potentially containing target information.
[0183] Based on the previously calculated spectral statistics (such as mean, variance, and skewness), kernel parameters are generated. These kernel parameters are used to adjust the shape and size of the convolution kernel. Assume the generated kernel parameter matrix is as follows:
[0184]
[0185] These kernel parameters reflect the spectral characteristics of each location in the image, and for each location, the magnitude of the kernel parameter determines the response intensity of the convolution kernel at that location.
[0186] The base convolution kernel is multiplied element-wise with its kernel parameters. Each element of the kernel is multiplied by the corresponding kernel parameter, thus adjusting the shape and response of the kernel. For example, the first element (0) of the base convolution kernel is multiplied by the first element (1, 2) of the kernel parameters to obtain a new kernel element. Continuing this operation, we obtain the initially adjusted convolution kernel:
[0187]
[0188] This kernel has been adjusted based on the spectral features in the image. Although it still maintains the structure of the convolution kernel, its response has been optimized based on the spectral gradient and kernel parameters.
[0189] The initial deformation kernel is fed into a multilayer perceptron (MLP) for nonlinear transformation. The MLP further processes the kernel through multiple neural network layers to generate intermediate deformation kernels. This transformation enables the convolutional kernel to capture more nonlinear relationships, thus better adapting to the complexity of the input data. Assume the intermediate deformation kernel obtained after MLP processing is as follows:
[0190]
[0191] This intermediate deformation kernel undergoes nonlinear transformation, enabling it to better adapt to complex features and targets in the image.
[0192] Based on the spectral gradient attention map, the spectral dimension of the intermediate deformation kernel is further scaled and adjusted. For example, in certain regions of the spectral gradient map, the gradient value is large, indicating that the region may contain important target information. Therefore, the spectral dimension of the convolution kernel needs to be amplified in these regions to enhance the response to the target region.
[0193] Assume the adjusted result is as follows:
[0194]
[0195] Here, the response of the convolution kernel is enhanced in the target region, thus making the convolution operation more capable of identifying important target regions.
[0196] Finally, the adjusted intermediate deformation kernel is normalized to ensure its numerical stability. Normalization aims to prevent computational instability in subsequent convolution operations due to excessively large or small kernel values. The final region-adaptive convolution kernel after normalization might look like this:
[0197]
[0198] By normalizing, the final value of the convolution kernel is scaled to a suitable range, thereby ensuring the stability of the convolution operation.
[0199] The adjusted region-adaptive convolutional kernel represents a significant improvement over the initial base kernel. Guided by a spectral gradient attention map, the kernel responds more accurately to target regions in the image, especially when there are significant spectral differences between the target region and the background. The adjusted kernel not only captures the spatial features of the target region but also adapts to spectral characteristics, enhancing target recognition capabilities.
[0200] This embodiment improves the adaptability of convolution kernels to different regional features in hyperspectral data by dynamically adjusting the convolution kernel. After adjusting the kernel parameters and spectral gradient attention map, the basic convolution kernel can better capture the spectral characteristics and spatial variations of the target region in the image, especially in the detection of complex backgrounds and weak targets, which can significantly improve the accuracy and robustness of target detection.
[0201] In one embodiment, step S60 above includes:
[0202] S601, using the region adaptive convolution kernel, perform convolution operation on each local data block in the input spectral data to generate an initial convolution feature map;
[0203] S602, Perform non-linear activation processing on the initial convolutional feature map to generate an activated feature map;
[0204] S603, the activated feature map is input into the feature channel compression module, and the first feature stream is generated through dimensionality reduction convolution operation.
[0205] In this embodiment, the input spectral data is processed using a region-adaptive convolution kernel to extract useful image features, particularly effective in identifying key regions in images, especially in applications such as target detection, crop monitoring, and medical image analysis. The generation process of the first feature stream includes steps such as convolution operations, nonlinear activation, and feature channel compression.
[0206] The input spectral data is first divided into multiple local data blocks, each containing a certain number of pixels and spectral bands. Each local data block is then convolved using a region-adaptive convolution kernel to extract its spectral features. During this process, the region-adaptive convolution kernel dynamically adjusts the weights of the convolution operation based on the local features of the image, making the kernel more adaptable to the spectral information and spatial distribution of each data block. The initial convolutional feature map is the output after the convolution operation, reflecting the spectral and spatial features of each local region in the image. Through the region-adaptive convolution kernel, the initial convolutional feature map captures important regional features in the image, particularly the differences between the target region and the background region. This initial feature map provides a coarse feature representation for subsequent feature extraction.
[0207] After convolution, the initial convolutional feature map typically contains relatively simple features of the image, such as edges and shapes. However, these features require non-linear activation to better represent the complex features of the image. Non-linear activation functions, such as ReLU (Rectified Linear Unit) or Sigmoid, are used to activate the feature map. By introducing non-linear transformations, activation functions enable the feature map to express more complex image information. Non-linear activation not only enhances the feature extraction capability of convolution operations but also helps the network model learn higher-level abstract features in the image. After activation, the generated activated feature map contains more information about the image, improving the accuracy and stability of subsequent analysis.
[0208] Activation feature maps contain rich information about an image, but subsequent processing may present challenges in terms of computational efficiency and resource consumption. To effectively compress feature maps and reduce computational burden, a feature channel compression module is needed to perform dimensionality reduction on the activation feature maps. This module reduces the number of channels in the feature map through dimensionality reduction convolution operations while retaining the most critical feature information. Dimensionality reduction convolution operations typically use 1×1 convolution kernels, which reduces the number of channels in the feature map while maintaining feature validity. The resulting first feature stream contains important features extracted from the input spectral data, exhibiting high computational efficiency and preserving the core information of the image. This feature stream will serve as input for subsequent object detection and analysis.
[0209] This embodiment utilizes a region-adaptive convolution kernel to adaptively handle the complex characteristics of input spectral data, especially when there are significant differences between the target and background in the image. The non-linear activation step further enhances the expressive power of the convolutional features, enabling the feature map to better capture detailed information about the target region. The feature channel compression module reduces the number of channels in the feature map through dimensionality reduction convolution operations, improving computational efficiency while ensuring feature integrity.
[0210] In one embodiment, step S70 above includes:
[0211] S701, construct a derivative analysis network including a noise suppression layer;
[0212] S702, Extract the joint spectral and spatial derivative features of the input spectral data through the derivative analysis network;
[0213] S703, perform nonlinear activation processing on the joint spectral and spatial derivative features to generate derivative activation features;
[0214] S704, the derivative activation feature is residually concatenated with the input spectral data to generate the second feature stream.
[0215] In this embodiment, spectral and spatial features are extracted from the input spectral data through derivative analysis to generate a second feature stream. Derivative analysis can effectively identify minute details of spectral changes in the image, especially boundary information. The introduction of a noise suppression layer ensures the stability and accuracy of the data, avoiding errors caused by sensor noise. This process improves the robustness of target detection, especially in low signal-to-noise ratio environments.
[0216] Hyperspectral images are often affected by sensor noise, which can lead to the loss of image details and affect the accuracy of subsequent analysis. To effectively reduce the interference of noise on derivative analysis, a noise suppression layer is introduced. This layer typically employs filtering techniques or denoising networks, such as Convolutional Denoising Autoencoders (CDAEs) or Noise Robust Neural Networks (NRNNs). These methods identify and remove irrelevant noise, ensuring high-quality input data. By denoising the input spectral data, the noise suppression layer improves the signal-to-noise ratio, preventing errors caused by noise in the image from propagating to subsequent analysis and processing steps. The denoised data more accurately reflects the spectral and spatial characteristics of the target region in the image, enhancing the robustness of target detection.
[0217] After noise suppression, derivative analysis is performed on the denoised spectral data. Derivative analysis is primarily used to extract joint spectral and spatial features from an image, especially at target boundaries and transition regions. This process can be implemented using convolutional neural networks (CNNs) or other gradient-based models. Through derivative analysis, changes in the image's spatial and spectral dimensions can be calculated, revealing spectral differences and spatial boundaries within the image. Joint derivative features combine information from both spatial and spectral dimensions, effectively capturing transition regions between the target and the background. The spectral and spatial characteristics of an image are often closely related, especially in hyperspectral images, where the reflectance intensity of different bands exhibits similar spatial trends. Joint derivative analysis comprehensively considers these dimensions, thereby generating feature information with strong discriminative power.
[0218] After extracting joint spectral and spatial derivative features, nonlinear activation functions are typically used to enhance their expressive power. Nonlinear activation processes, such as ReLU (Rectified Linear Unit) or Sigmoid, enable the network model to learn more complex feature maps. This process helps to uncover higher-order features in the image, transforming the input linear features into nonlinear features, allowing the model to better adapt to and express different details in complex images. The derivative activation features generated after nonlinear activation contain more complex spatial and spectral information, providing richer feature representations for subsequent feature fusion and object detection.
[0219] After generating derivative activation features, to preserve key information from the original input data and enhance the representation of derivative features, residual connections are established between the derivative activation features and the input spectral data. Residual connections effectively prevent information loss and enhance the training efficiency of the network. Through residual connections, the original spectral data and derivative activation features can be passed in parallel, ensuring that the model not only utilizes derivative features but also retains key information from the original data.
[0220] This embodiment utilizes derivative analysis to generate a second feature stream, which effectively improves the accuracy of target detection, especially in the detection of complex backgrounds and weak targets. The introduction of a noise suppression layer enhances data quality and ensures the stability of the analysis; derivative analysis extracts detailed information in spectral and spatial dimensions, enhancing sensitivity to target boundaries and spectral features; residual connections preserve important information from the original data while strengthening the learning of new features. Combining these features significantly improves the robustness and accuracy of detection.
[0221] In one embodiment, an adaptive convolution-based spectral data processing device is provided, which corresponds one-to-one with the adaptive convolution-based spectral data processing method described in the above embodiments. Referring to Figure 3, Figure 3 is a functional block diagram of a preferred embodiment of the adaptive convolution-based spectral data processing device of this application. The device comprises a data acquisition module 10, a spectral gradient calculation module 20, a spectral statistics determination module 30, a kernel parameter generation module 40, an adaptive convolution kernel generation module 50, a feature extraction module 60, a derivative analysis module 70, and a feature fusion and target detection module 80. Detailed descriptions of each functional module are as follows:
[0222] Data acquisition module 10 is used to acquire input spectral data;
[0223] The spectral gradient calculation module 20 is used to determine the spectral gradient attention map based on the input spectral data;
[0224] The spectral statistics determination module 30 is used to determine the spectral statistics of local data blocks in the input spectral data;
[0225] The kernel parameter generation module 40 is used to generate kernel parameters based on the spectral statistics.
[0226] The adaptive convolution kernel generation module 50 is used to generate a region adaptive convolution kernel based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters.
[0227] Feature extraction module 60 is used to process the input spectral data through the region adaptive convolution kernel to obtain a first feature stream;
[0228] The derivative analysis module 70 is used to perform derivative analysis on the input spectral data to generate a second feature stream;
[0229] The feature fusion and target detection module 80 is used to fuse the first feature stream and the second feature stream to generate fused features, and to generate target detection results based on the fused features.
[0230] For preferred embodiments of the adaptive convolution-based spectral data processing apparatus, please refer to the foregoing limitations on the adaptive convolution-based spectral data processing method, which will not be repeated here. Each module in the aforementioned adaptive convolution-based spectral data processing apparatus can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.
[0231] In one embodiment, a computer device is provided, which can be a server, and its internal structure diagram is shown in Figure 4. The computer device includes a processor, memory, a network interface, and a database connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile and / or volatile storage media and internal memory. The non-volatile storage media stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface is used to communicate with external user terminals via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a server-side adaptive convolution-based spectral data processing method.
[0232] In one embodiment, a computer device is provided, which can be a user terminal, and its internal structure diagram can be as shown in Figure 5. The computer device includes a processor, memory, network interface, display screen, and input device connected via a system bus. The processor of the computer device provides computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external server via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a user terminal-side method for spectral data processing based on adaptive convolution.
[0233] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to perform the following steps:
[0234] Acquire input spectral data;
[0235] Based on the input spectral data, a spectral gradient attention map is determined;
[0236] Determine the spectral statistics of local data blocks in the input spectral data;
[0237] Based on the spectral statistics, generate kernel parameters;
[0238] Based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated.
[0239] The input spectral data is processed by the region-adaptive convolution kernel to obtain the first feature stream;
[0240] Perform derivative analysis on the input spectral data to generate a second feature stream;
[0241] The first feature stream and the second feature stream are fused to generate a fused feature, and a target detection result is generated based on the fused feature.
[0242] In one embodiment, a computer-readable storage medium is provided, which may be non-volatile or volatile, and a computer program is stored thereon, which, when executed by a processor, performs the following steps:
[0243] Acquire input spectral data;
[0244] Based on the input spectral data, a spectral gradient attention map is determined;
[0245] Determine the spectral statistics of local data blocks in the input spectral data;
[0246] Based on the spectral statistics, generate kernel parameters;
[0247] Based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated.
[0248] The input spectral data is processed by the region-adaptive convolution kernel to obtain the first feature stream;
[0249] Perform derivative analysis on the input spectral data to generate a second feature stream;
[0250] The first feature stream and the second feature stream are fused to generate a fused feature, and a target detection result is generated based on the fused feature.
[0251] It should be noted that the functions or steps that can be implemented by the non-volatile computer-readable storage medium or computer device described above can be referred to the relevant descriptions on the server side and user side in the foregoing method embodiments. To avoid repetition, they will not be described one by one here.
[0252] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0253] It should be noted that if any AI models, software tools, or components not belonging to this company appear in the embodiments of this application, they are merely illustrative examples and do not represent actual use. The embodiments described above are only used to illustrate the technical solutions of this application and are not intended to limit them; although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A method of spectral data processing based on adaptive convolution, wherein, Includes the following steps: Acquire input spectral data; Based on the input spectral data, a spectral gradient attention map is determined; Determine the spectral statistics of local data blocks in the input spectral data; Based on the spectral statistics, generate kernel parameters; Based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated. The input spectral data is processed by the region-adaptive convolution kernel to obtain the first feature stream; Perform derivative analysis on the input spectral data to generate a second feature stream; The first feature stream and the second feature stream are fused to generate a fused feature, and a target detection result is generated based on the fused feature.
2. The adaptive convolution-based spectral data processing method of claim 1, wherein, Based on the input spectral data, a spectral gradient attention map is determined, including: The first directional gradient operator is applied to the spatial dimension of the input spectral data to generate spatial gradient components; The second directional gradient operator is applied to the spectral dimension of the input spectral data to generate spectral gradient components; Norm synthesis is performed on the spatial gradient components and spectral gradient components to generate a gradient magnitude map; The gradient magnitude map is normalized to generate the spectral gradient attention map.
3. The adaptive convolution-based spectral data processing method of claim 2, wherein, Applying a first directional gradient operator to the spatial dimension of the input spectral data to generate spatial gradient components includes: The first directional gradient operator is the Sobel operator. The Sobel operator is applied to the spatial dimension of the input spectral data to calculate the difference between adjacent pixels. Based on the differences between the adjacent pixels, determine the changes in the input spectral data in the horizontal direction and in the vertical direction; Spatial gradient components are generated based on the changes in the input spectral data in the horizontal and vertical directions.
4. The adaptive convolution-based spectral data processing method of claim 1, wherein, Determining the spectral statistics of local data blocks in the input spectral data includes: The input spectral data is divided into multiple local data blocks; The spectral mean characteristics of each local data block are generated by performing an arithmetic mean analysis on all spectral band values. A variance analysis is performed on the spectral band values of the local data block, and the zero variance error is eliminated by combining the numerical stability term to generate spectral variance features. Third-order moment analysis is performed on the spectral band values of the local data block to generate spectral skewness characteristics; The spectral mean feature, spectral variance feature, and spectral skewness feature are concatenated into vectors to generate the spectral statistics of the local data block.
5. The adaptive convolution-based spectral data processing method of claim 4, wherein, An arithmetic mean analysis is performed on all spectral band values of each local data block to generate the spectral mean characteristics of the local data block, including: The average reflection intensity information of the local data block in all spectral bands is obtained by averaging the values of all spectral bands of the local data block. The average reflection intensity information is used as the spectral mean feature of the local data block.
6. The adaptive convolution-based spectral data processing method of claim 4, wherein, Third-order moment analysis is performed on the spectral band values of the local data block to generate spectral skewness characteristics, including: The skewness of the data distribution of the spectral band values of the local data block is measured by third-order moment analysis. Based on the skewness of the data distribution, the asymmetry of spectral variations in the local data blocks is explored; Based on the aforementioned asymmetry, spectral skewness characteristics are generated.
7. The adaptive convolution based spectral data processing method of claim 1, wherein, Based on the spectral statistics, kernel parameters are generated, including: Input the spectral statistics into the parameter analysis model; The encoder of the parameter analysis model performs a nonlinear mapping on the spectral statistics to generate latent variable representations; A linear transformation is performed on the latent variable representation to generate kernel deformation parameters; The nuclear deformation parameters are normalized to generate the nuclear parameters.
8. The adaptive convolution-based spectral data processing method of claim 1, wherein, Based on the base convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated, including: The basic convolution kernel is multiplied element-wise with the kernel parameters to generate the initial deformation kernel; The initial deformation kernel is input into a multilayer perceptron for nonlinear transformation to generate an intermediate deformation kernel. The spectral dimension of the intermediate deformation kernel is adjusted by a scaling factor based on the spectral gradient attention map. The adjusted intermediate deformation kernel is normalized to generate the region adaptive convolution kernel.
9. The adaptive convolution based spectral data processing method of claim 1, wherein, The input spectral data is processed by the region-adaptive convolution kernel to obtain a first feature stream, including: The region-adaptive convolution kernel is used to perform convolution operations on each local data block in the input spectral data to generate an initial convolutional feature map. The initial convolutional feature map is subjected to non-linear activation processing to generate an activated feature map; The activated feature map is input into the feature channel compression module, and the first feature stream is generated through a dimension reduction convolution operation.
10. The adaptive convolution-based spectral data processing method of claim 9, wherein, The region-adaptive convolution kernel is used to perform convolution operations on each local data block in the input spectral data to generate an initial convolutional feature map, including: The region-adaptive convolution kernel dynamically adjusts the weights of the convolution operation based on the local features of each local data block, so that the region-adaptive convolution kernel adapts to the spectral information and spatial distribution of each local data block. By dynamically adjusting the weights of the convolution operation and then performing a region-adaptive convolution kernel, convolution operations are performed on each local data block to extract the spectral features of each local data block. The output obtained after the convolution operation, which reflects the spectral and spatial features of each local data block, is used as the initial convolution feature map.
11. The adaptive convolution based spectral data processing method as claimed in claim 1, wherein, Performing derivative analysis on the input spectral data to generate a second feature stream includes: Construct a derivative analysis network that includes a noise suppression layer; The spectral and spatial joint derivative features of the input spectral data are extracted using the derivative analysis network. The spectral and spatial joint derivative features are subjected to nonlinear activation processing to generate derivative activation features; The derivative activation feature is residually concatenated with the input spectral data to generate the second feature stream.
12. The adaptive convolution-based spectral data processing method of claim 11, wherein, Extracting the joint spectral and spatial derivative features of the input spectral data through the derivative analysis network includes: Derivative analysis is performed on the denoised spectral data using a convolutional neural network or a gradient-based model in the derivative analysis network. The derivative analysis is used to calculate the changes in the image in the spatial and spectral dimensions. Based on the changes in the spatial and spectral dimensions of the image, features representing the transition region between the target and the background are extracted as joint spectral and spatial derivative features.
13. An apparatus for processing spectral data based on adaptive convolution, wherein, The adaptive convolution-based spectral data processing device includes: The data acquisition module is used to acquire input spectral data; The spectral gradient calculation module is used to determine the spectral gradient attention map based on the input spectral data. The spectral statistics determination module is used to determine the spectral statistics of local data blocks in the input spectral data; A kernel parameter generation module is used to generate kernel parameters based on the spectral statistics. An adaptive convolution kernel generation module is used to generate a region adaptive convolution kernel based on a base convolution kernel, the spectral gradient attention map, and the kernel parameters. The feature extraction module is used to process the input spectral data through the region adaptive convolution kernel to obtain a first feature stream; The derivative analysis module is used to perform derivative analysis on the input spectral data to generate a second feature stream; The feature fusion and target detection module is used to fuse the first feature stream and the second feature stream to generate fused features, and to generate target detection results based on the fused features.
14. A computer device, wherein, The computer device includes a memory, a processor, and an adaptive convolution-based spectral data processing program stored in the memory and executable on the processor. When executed by the processor, the adaptive convolution-based spectral data processing program implements the following steps of the adaptive convolution-based spectral data processing method: Acquire input spectral data; Based on the input spectral data, a spectral gradient attention map is determined; Determine the spectral statistics of local data blocks in the input spectral data; Based on the spectral statistics, generate kernel parameters; Based on the basic convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated. The input spectral data is processed by the region-adaptive convolution kernel to obtain the first feature stream; Perform derivative analysis on the input spectral data to generate a second feature stream; The first feature stream and the second feature stream are fused to generate a fused feature, and a target detection result is generated based on the fused feature.
15. The computer device of claim 14, wherein, Based on the input spectral data, a spectral gradient attention map is determined, including: The first directional gradient operator is applied to the spatial dimension of the input spectral data to generate spatial gradient components; The second directional gradient operator is applied to the spectral dimension of the input spectral data to generate spectral gradient components; Norm synthesis is performed on the spatial gradient components and spectral gradient components to generate a gradient magnitude map; The gradient magnitude map is normalized to generate the spectral gradient attention map.
16. The computer device of claim 14, wherein, Determining the spectral statistics of local data blocks in the input spectral data includes: The input spectral data is divided into multiple local data blocks; The spectral mean characteristics of each local data block are generated by performing an arithmetic mean analysis on all spectral band values. A variance analysis is performed on the spectral band values of the local data block, and the zero variance error is eliminated by combining the numerical stability term to generate spectral variance features. Third-order moment analysis is performed on the spectral band values of the local data block to generate spectral skewness characteristics; The spectral mean feature, spectral variance feature, and spectral skewness feature are concatenated into vectors to generate the spectral statistics of the local data block.
17. The computer device of claim 14, wherein, Based on the spectral statistics, kernel parameters are generated, including: Input the spectral statistics into the parameter analysis model; The encoder of the parameter analysis model performs a nonlinear mapping on the spectral statistics to generate latent variable representations; A linear transformation is performed on the latent variable representation to generate kernel deformation parameters; The nuclear deformation parameters are normalized to generate the nuclear parameters.
18. The computer device of claim 14, wherein, Based on the base convolution kernel, the spectral gradient attention map, and the kernel parameters, a region-adaptive convolution kernel is generated, including: The basic convolution kernel is multiplied element-wise with the kernel parameters to generate the initial deformation kernel; The initial deformation kernel is input into a multilayer perceptron for nonlinear transformation to generate an intermediate deformation kernel. The spectral dimension of the intermediate deformation kernel is adjusted by a scaling factor based on the spectral gradient attention map. The adjusted intermediate deformation kernel is normalized to generate the region adaptive convolution kernel.
19. The computer device of claim 14, wherein, The input spectral data is processed by the region-adaptive convolutional kernel to obtain a first feature stream, including: The region-adaptive convolution kernel is used to perform convolution operations on each local data block in the input spectral data to generate an initial convolutional feature map. The initial convolutional feature map is subjected to non-linear activation processing to generate an activated feature map; The activated feature map is input into the feature channel compression module, and the first feature stream is generated through a dimension reduction convolution operation.
20. A non-transitory computer readable storage medium, wherein, The storage medium stores a spectral data processing program based on adaptive convolution, which, when executed by a processor, implements the steps of the spectral data processing method based on adaptive convolution as described in any one of claims 1-12.
