Hyperspectral image encoding method, decoding method and related equipment
By dividing hyperspectral images into basic images and additional images, and optimizing network parameters using spectral interpolation processing and spectral super-resolution network, the problem of low encoding compression efficiency in the prior art is solved, and more efficient data compression is achieved.
Patent Information
- Application Number
- CN202510093365.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-21
- Publication Date
- 2025-04-22
- Estimated Expiration
- 2045-01-21
AI Technical Summary
When encoding and compressing hyperspectral images, the prior art ignores the complex and unique spectral characteristics in the image, resulting in low compression efficiency.
By dividing hyperspectral images into basic images and additional images, network parameters are optimized to improve coding compression efficiency using spectral interpolation processing and spectral super-resolution networks.
It improves the encoding and compression efficiency of hyperspectral images, reduces the amount of data transmission, and retains important spectral information.
Smart Images

Figure CN119562059B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a hyperspectral image encoding method, a decoding method and related equipment. Background Art
[0002] Hyperspectral images are composed of multiple spectral bands, covering a wide range of wavelengths, and providing rich spectral information beyond the visible spectrum, so they can be widely used in a variety of scene representations, such as supporting medical diagnosis, precision agriculture, and environmental monitoring. As a result, the complex and extensive spectral data in hyperspectral images brings more transmission and storage challenges. Therefore, it is necessary to appropriately encode hyperspectral images to compress the amount of data transmission, thereby improving the transmission efficiency of hyperspectral images.
[0003] In the related art, for encoding and compressing hyperspectral images, a trained deep learning network is usually used to extract image features in the hyperspectral image as encoding and compression data, thereby achieving compressed data transmission. However, since the deep learning network relies too much on end-to-end learning, it ignores the complex and unique spectral characteristics of the hyperspectral image. Therefore, in the process of encoding and compressing, more data needs to be retained to ensure the image features that characterize the hyperspectral image, resulting in low compression efficiency when directly using a deep learning network to encode and compress hyperspectral images. Summary of the invention
[0004] The embodiments of the present application provide a hyperspectral image encoding method, a decoding method and related devices, which can improve the encoding compression efficiency of hyperspectral images.
[0005] To achieve the above object, a first aspect of an embodiment of the present application proposes a hyperspectral image encoding method, the method comprising:
[0006] Dividing the hyperspectral image into a basic image and an additional image, wherein the basic image includes anchor band data and the additional image includes non-anchor band data;
[0007] Performing spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data;
[0008] Obtaining an actual residual image based on a difference between the additional image and the interpolated basic image;
[0009] Inputting the basic image into a spectral super-resolution network to generate a predicted residual image, and obtaining optimized network parameters based on the difference between the actual residual image and the predicted residual image;
[0010] Image encoding data of the hyperspectral image is obtained based on the optimized network parameters and the basic image.
[0011] In some embodiments, the basic image includes a plurality of basic pixels, and inputting the basic image into a spectral super-resolution network to generate a predicted residual image includes:
[0012] Extracting features of each of the basic pixels one by one to obtain basic pixel features;
[0013] Inputting each of the basic pixel features into the spectral super-resolution network one by one to obtain the corresponding prediction residual pixels under the current network parameters;
[0014] All the prediction residual pixels are combined to obtain the prediction residual image.
[0015] In some embodiments, extracting features from each of the basic pixels to obtain basic pixel features includes:
[0016] Based on the image parameters of the hyperspectral image, normalizing the pixel coordinates of the basic pixels to obtain normalized coordinates;
[0017] Based on the maximum band value and the minimum band value of the hyperspectral image, the band value of the basic pixel is normalized to obtain a normalized band value;
[0018] The basic pixel feature is obtained based on the normalized coordinates and the normalized band value.
[0019] In some embodiments, obtaining optimized network parameters based on the difference between the actual residual image and the predicted residual image includes:
[0020] Based on the difference between the actual residual image and the predicted residual image, a norm processing is performed to obtain a predicted residual value;
[0021] A prediction error optimization function is generated based on the prediction residual value, and the prediction error optimization function is minimized to obtain the optimized network parameters.
[0022] In some embodiments, the basic image includes a plurality of anchor band data, and the performing spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image including non-anchor band data includes:
[0023] Taking the bands composed of every two adjacent anchor band data as target interpolation bands one by one;
[0024] Determining a plurality of similar anchor band data in the target interpolation band;
[0025] The target interpolation band is interpolated based on the plurality of similar anchor band data to obtain the interpolation basic image.
[0026] In some embodiments, dividing the hyperspectral image into a basic image and an additional image comprises:
[0027] Based on the image parameters of the hyperspectral image, uniform band sampling is performed on the hyperspectral image to obtain a plurality of anchor band data, and the basic image is formed based on all the anchor band data;
[0028] The additional image is obtained by combining a plurality of non-anchor band data in the hyperspectral image except the basic image.
[0029] In some embodiments, the obtaining the image encoding data of the hyperspectral image based on the optimized network parameters and the basic image includes:
[0030] Acquire image header information, and encode the image header information based on a header encoder to obtain a header bit stream;
[0031] Performing encoding processing on the optimized network parameters based on an auxiliary encoder to obtain an auxiliary bit stream;
[0032] Encoding the basic image based on a basic encoder to obtain a basic bit stream;
[0033] The image coding data is obtained based on the header bit stream, the auxiliary bit stream and the basic bit stream.
[0034] To achieve the above object, a second aspect of an embodiment of the present application proposes a hyperspectral image decoding method, the method comprising:
[0035] Get optimized network parameters and basic images;
[0036] Performing spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data;
[0037] Inputting the optimized network parameters and the basic image into a spectral super-resolution network to generate a predicted residual image;
[0038] Obtaining an additional image containing non-anchor band data based on the cumulative sum of the interpolated basic image and the predicted residual image;
[0039] Spectral integration is performed based on the basic image and the additional image to obtain a decoded hyperspectral image.
[0040] To achieve the above-mentioned purpose, a third aspect of an embodiment of the present application proposes a hyperspectral image encoding device, the device comprising:
[0041] An image division module, used for dividing the hyperspectral image into a basic image and an additional image, wherein the basic image includes anchor band data and the additional image includes non-anchor band data;
[0042] A first interpolation module is used to perform spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data;
[0043] an actual residual calculation module, configured to obtain an actual residual image based on a difference between the additional image and the interpolated basic image;
[0044] An optimization parameter calculation module, used for inputting the basic image into a spectral super-resolution network to generate a predicted residual image, and obtaining optimized network parameters based on a difference between the actual residual image and the predicted residual image;
[0045] A coding data generation module is used to obtain image coding data of the hyperspectral image based on the optimized network parameters and the basic image.
[0046] To achieve the above-mentioned purpose, a fourth aspect of the embodiments of the present application provides a hyperspectral image encoding device, the device comprising:
[0047] Image acquisition module, used to obtain optimized network parameters and basic images;
[0048] A second interpolation module is used to perform spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data;
[0049] A residual image generation module, inputting the optimized network parameters and the basic image into a spectral super-resolution network to generate a predicted residual image;
[0050] An additional image generation module, used for obtaining an additional image containing non-anchor band data based on the cumulative sum of the interpolated basic image and the predicted residual image;
[0051] The decoding data generating module is used to perform spectral integration based on the basic image and the additional image to obtain a decoded hyperspectral image.
[0052] To achieve the above-mentioned purpose, a fifth aspect of an embodiment of the present application proposes an electronic device, comprising a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the hyperspectral image encoding method as described in the first aspect is implemented.
[0053] To achieve the above-mentioned purpose, the sixth aspect of the embodiments of the present application proposes a storage medium, which is a computer-readable storage medium, and the storage medium stores a computer program. When the computer program is executed by a processor, the hyperspectral image encoding method described in the first aspect is implemented.
[0054] The hyperspectral image encoding method, decoding method and related equipment proposed in the embodiments of the present application, the encoding method includes: first, dividing the hyperspectral image into a basic image and an additional image, the basic image includes anchor band data, and the additional image includes non-anchor band data; then, spectral interpolation processing is performed on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data; next, based on the difference between the additional image and the interpolated basic image, an actual residual image is obtained; thereafter, the basic image is input into a spectral super-resolution network to generate a predicted residual image, and based on the difference between the actual residual image and the predicted residual image, optimized network parameters are obtained; finally, image encoding data of the hyperspectral image is obtained based on the optimized network parameters and the basic image. The embodiment of the present application first divides the hyperspectral image into a basic image composed of anchor band data that can be directly encoded and transmitted, and an additional image composed of non-anchor band data that cannot be directly encoded and transmitted, and then uses the difference between the interpolated basic image containing non-anchor band data obtained by interpolating the basic image and the additional image to obtain an actual residual image that can be used as a prediction target of a spectral super-resolution network, and uses the spectral super-resolution network to fit the actual residual image and the predicted residual image to obtain optimized network parameters for characterizing the characteristics of non-anchor band data in the additional image and that can be directly encoded and compressed, so as to obtain image encoding data with high compression efficiency of the hyperspectral image after encoding and compression based on the optimized network parameters and the basic image, thereby effectively improving the encoding compression efficiency of the hyperspectral image.
[0055] Other features and advantages of the present application will be described in the following description, and partly become apparent from the description, or understood by practicing the present application. The purpose and other advantages of the present application can be realized and obtained by the structures specifically pointed out in the description, claims and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] Figure 1 This is a flowchart of a hyperspectral image encoding method provided by an embodiment of the present application.
[0057] Figure 2 yes Figure 1 Flow chart of step 101 in FIG.
[0058] Figure 3 yes Figure 1 Flow chart of step 102 in FIG.
[0059] Figure 4 yes Figure 1 Flow chart of step 104 in FIG.
[0060] Figure 5 yes Figure 4 Flow chart of step 401 in FIG.
[0061] Figure 6 yes Figure 1 Another flow chart of step 104 in FIG.
[0062] Figure 7 This is a schematic diagram of the architecture of a spectral super-resolution network provided in yet another embodiment of the present application.
[0063] Figure 8 yes Figure 1 Flow chart of step 105 in FIG.
[0064] Fig. 9 This is a schematic diagram of the architecture flow of a hyperspectral image encoding method provided by yet another embodiment of the present application.
[0065] Fig.10 This is a flowchart of a hyperspectral image decoding method provided by another embodiment of the present application.
[0066] Fig.11 This is a schematic diagram of the architecture flow of a hyperspectral image decoding method provided by yet another embodiment of the present application.
[0067] Fig.12 It is a schematic diagram of the structure of a hyperspectral image encoding device provided in yet another embodiment of the present application.
[0068] Fig.13 It is a structural schematic diagram of a hyperspectral image decoding device provided in yet another embodiment of the present application.
[0069] Fig.14 This is a schematic diagram of the hardware structure of an electronic device provided in yet another embodiment of the present application. DETAILED DESCRIPTION
[0070] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0071] It should be noted that although the functional modules are divided in the device schematic and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart.
[0072] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0073] Hyperspectral images (HSI) consist of multiple spectral bands, covering a wide range of wavelengths, and providing rich spectral information beyond the visible spectrum, so that they can be widely used in a variety of scene characterizations, such as supporting medical diagnosis, precision agriculture, and environmental monitoring. As a result, the complex and extensive spectral data in hyperspectral images brings more transmission and storage challenges. Effective compression algorithms are essential to exploit the inherent redundancy between spectral bands, which can reduce the data size while retaining information that is critical to downstream applications. Therefore, it is necessary to appropriately encode hyperspectral images to compress the amount of data transmission, thereby improving the transmission efficiency of hyperspectral images.
[0074] Hyperspectral images (HSI) are usually represented as high-bit-depth data to preserve their wide dynamic range. Traditional image compression methods, such as JPEG 2000, JPEG XL, and CCSDS 123.0-B-2 standards, are often used to compress these images. To improve performance, methods specifically designed for HSI compression emphasize spectral correlations, including inter-band linear prediction lookup table-assisted prediction and removal of local spectral outliers. However, these methods that rely on hand-crafted priors usually fail to fully capture the rich spectral correlations in high-bit-depth spectral representations, resulting in poor performance.
[0075] In the related art, for encoding and compressing hyperspectral images, a trained deep learning network is usually used to extract image features in the hyperspectral image as encoding and compression data, thereby achieving compressed data transmission. However, since the deep learning network relies too much on end-to-end learning, it ignores the complex and unique spectral characteristics of the hyperspectral image. Therefore, in the process of encoding and compressing, more data needs to be retained to ensure the image features that characterize the hyperspectral image, resulting in low compression efficiency when directly using a deep learning network to encode and compress hyperspectral images.
[0076] In addition, spectral super-resolution (SSR) is a promising solution. Early studies focused on providing classical signal recovery techniques for undersampled signal recovery. Subsequently, better performance was achieved using deep neural networks to effectively model the spectral properties of HSI. These methods are able to recover spectra from the visible spectrum, providing a potential solution to reduce HSI storage by retaining only part of the spectral information. However, the potential of SSR in HSI compression remains underexplored due to its limited integration with compression techniques.
[0077] Based on this, in order to improve the coding and compression efficiency of hyperspectral images, the embodiment of the present application integrates spectral super-resolution and advanced compression technology into a unified framework to bridge the gap between the two. The embodiment of the present application first divides the hyperspectral image into a basic image composed of anchor band data that can be directly encoded and transmitted, and an additional image composed of non-anchor band data that cannot be directly encoded and transmitted, and then uses the difference between the interpolated basic image containing non-anchor band data obtained by interpolating the basic image and the additional image to obtain an actual residual image that can be used as a prediction target of the spectral super-resolution network, and uses the spectral super-resolution network to fit the actual residual image and the predicted residual image to obtain optimized network parameters for characterizing the characteristics of non-anchor band data in the additional image and can be directly encoded and compressed, so as to obtain image coding data with high compression efficiency of the hyperspectral image after encoding and compression based on the optimized network parameters and the basic image, thereby effectively improving the coding and compression efficiency of the hyperspectral image.
[0078] The hyperspectral image encoding method in the embodiment of the present application will be described in detail below. Figure 1 , is an optional flow chart of the hyperspectral image encoding method provided in an embodiment of the present application, Figure 1 The method may include but is not limited to steps 101 to 105. It can also be understood that this embodiment Figure 1 The order of steps 101 to 105 is not specifically limited, and the order of steps can be adjusted or some steps can be reduced or increased according to actual needs. The hyperspectral image encoding method provided in the embodiment of the present application can be applied to any intelligent terminal with computing and processing capabilities.
[0079] Step 101: Divide the hyperspectral image into a basic image and an additional image.
[0080] The following is a detailed description of step 101.
[0081] In some embodiments, for hyperspectral images , whose image parameters include image height H, image width W and number of spectral bands C, and the number of anchor bands is First, the hyperspectral image Input spectrum segmentation module to divide it into basic images and additional images The basic image Can be directly encoded and transmitted, which consists of anchor band data; in contrast, additional images It cannot be directly encoded and transmitted, and consists of non-anchor band data.
[0082] How to perform image segmentation will be further described below.
[0083] Reference Figure 2 , dividing the hyperspectral image into a basic image and an additional image, including the following steps 201 to 202.
[0084] Step 201: Based on image parameters of the hyperspectral image, uniform band sampling is performed on the hyperspectral image to obtain a plurality of anchor band data, and a basic image is formed based on all the anchor band data.
[0085] Step 202: Combine multiple non-anchor band data in the hyperspectral image except the basic image to obtain an additional image.
[0086] Steps 201 to 202 are described in detail below.
[0087] In some embodiments, the spectrum segmentation module obtains the hyperspectral image Afterwards, based on the hyperspectral image The number of anchor bands in the image parameters of , by using hyperspectral images The bands are uniformly sampled to extract multiple anchor band data, and then the basic image is composed based on all the anchor band data. As shown in the following formula (1).
[0088] (1)
[0089] Among them, the sampling anchor number corresponding to the anchor band data As shown in the following formula (2).
[0090] (2)
[0091] In addition, the hyperspectral image Remove the base image Additional images are obtained by combining multiple non-anchor band data As shown in the following formula (3).
[0092] (3)
[0093] Through the above steps 201 to 202, the bands of the hyperspectral image are uniformly sampled using the number of anchor bands in the image parameters to obtain multiple anchor band data that can be directly encoded and compressed to obtain a basic image, and the remaining data is used as an additional image, thereby achieving accurate division of the hyperspectral image in the spectral division module, so as to facilitate the accuracy of subsequent feature extraction of the additional image, thereby improving the coding compression reliability of the hyperspectral image.
[0094] Step 102: Perform spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data.
[0095] The following is a detailed description of step 102.
[0096] In some embodiments, after obtaining the basic image and additional images After that, in order to accurately extract features from the additional images, it is necessary to calculate the basic image and additional images The image difference between them. And because the basic image is composed of anchor band data, while additional images It is composed of non-anchor band data, so it is necessary to first Input spectral interpolation module to base image The anchor band data in the image is spectrally interpolated to obtain an interpolated basic image containing non-anchor band data. , which makes it easier to calculate the interpolation basic image and additional images The difference between the images.
[0097] How to perform spectral interpolation processing on the anchor band data in the basic image will be further described in detail below.
[0098] Reference Figure 3 , performing spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data, including the following steps 301 to 303.
[0099] Step 301: taking each band formed by two adjacent anchor band data as a target interpolation band one by one.
[0100] Step 302: Determine a plurality of similar anchor band data in a target interpolation band.
[0101] Step 303: interpolating the target interpolation band based on multiple similar anchor band data to obtain an interpolated basic image.
[0102] Steps 301 to 303 are described in detail below.
[0103] In some embodiments, the spectral interpolation module receives the base image Afterwards, using the base image The anchor bands in the interpolation module are used to interpolate the non-anchor bands. In the spectral interpolation module, cubic spline interpolation is used, which is a technique that has been proven to be able to reconstruct smooth curves from discrete points. The interpolated image As a reference for the non-anchored band values, the spectral super-resolution network only predicts the interpolated residual. In this way, the prior assumption of second-order spectral continuity is implicitly introduced, thereby reducing the risk of value drift during the training process of the spectral super-resolution network.
[0104] Specifically, in the spectral interpolation module, considering that the cubic curve is uniquely determined by four points, the bands composed of every two adjacent anchor band data are taken as the target interpolation bands one by one, and then based on the continuity of the spectrum, multiple similar anchor band data (usually ), and then interpolate these multiple similar anchor band data to the target interpolation band to obtain the interpolation basic image .
[0105] Through the above steps 301 to 303, the anchor bands in the basic image are used in the spectral interpolation module, and the non-anchor bands in the basic image are interpolated using cubic spline interpolation to obtain an interpolated basic image that can be used to characterize the basic image and contains non-anchor band data, thereby facilitating subsequent encoding processing using the image difference between the interpolated basic image and the additional image, so as to reduce the risk of value drift in the training process of the spectral super-resolution network, thereby improving the reliability of hyperspectral image encoding.
[0106] Step 103: Obtain an actual residual image based on the difference between the additional image and the interpolated basic image.
[0107] The following is a detailed description of step 103.
[0108] In some embodiments, in the spectral interpolation module, after obtaining the interpolation basic image After that, the interpolated basic image will be further From the attached image Subtract, that is, based on the additional image and interpolated base image The difference between and additional images The actual residual image corresponding to the difference residual As shown in the following formula (4).
[0109] (4)
[0110] Step 104: Input the basic image into the spectral super-resolution network to generate a predicted residual image, and obtain optimized network parameters based on the difference between the actual residual image and the predicted residual image.
[0111] Step 104 is described in detail below.
[0112] In some embodiments, after obtaining the image for representing the basic image and additional images The actual residual image corresponding to the difference residual Afterwards, it is used as the prediction target of the spectral super-resolution network.
[0113] In some embodiments, as a key component, a lightweight spectral super-resolution network (LSSRN) is used to The features extracted from the image are used as input to output the predicted residual image. , so that it is convenient to use the prediction residual image later The actual residual image The difference between the network parameters of the spectral super-resolution network (LSSRN) Optimize to obtain the hyperspectral image Additional features of the optimized network parameters , which makes it easier to use the optimized network parameters Encoding compression.
[0114] How to generate the prediction residual image in the spectral super-resolution network is further described below.
[0115] Reference Figure 4 , inputting the basic image into the spectral super-resolution network to generate a predicted residual image, including the following steps 401 to 403.
[0116] Step 401: Extract features of each basic pixel one by one to obtain basic pixel features.
[0117] Step 401 is described in detail below.
[0118] In some embodiments, the spectral super-resolution network obtains a base image After that, it is necessary to extract geometric feature information from the basic image to facilitate subsequent prediction processing. Therefore, for a basic image composed of multiple basic pixels First, extract the features of each basic pixel one by one to obtain the basic pixel features corresponding to each basic pixel , the following will further describe how to extract features for each basic pixel.
[0119] Reference Figure 5, feature extraction is performed on each basic pixel to obtain basic pixel features, including the following steps 501 to 503.
[0120] Step 501: Based on the image parameters of the hyperspectral image, the pixel coordinates of the basic pixels are normalized to obtain normalized coordinates.
[0121] Step 502: Based on the maximum band value and the minimum band value of the hyperspectral image, the band value of the basic pixel is normalized to obtain a normalized band value.
[0122] Step 503: Obtain basic pixel features based on the normalized coordinates and the normalized band values.
[0123] Steps 501 to 503 are described in detail below.
[0124] In some embodiments, in the spectral super-resolution network, firstly based on the hyperspectral image The image height H and image width W in the image parameters are mapped to the pixel coordinates corresponding to each basic pixel one by one Perform normalization to obtain the normalized coordinates corresponding to each basic pixel As shown in the following formula (5).
[0125] (5)
[0126] Next, based on the hyperspectral image The maximum band value in the image parameters and minimum band value , normalize the band value corresponding to each basic pixel one by one to obtain the normalized band value As shown in the following formula (6).
[0127] (6)
[0128] Then based on the normalized coordinates and normalized band values , get the basic pixel features corresponding to each basic pixel In general, each basic pixel generates Basic pixel features.
[0129] Step 402: Input each basic pixel feature into the spectral super-resolution network one by one to obtain the corresponding prediction residual pixel under the current network parameters.
[0130] Step 403: Combine all prediction residual pixels to obtain a prediction residual image.
[0131] Steps 402 to 403 are described in detail below.
[0132] In some embodiments, in the spectral super-resolution network, after obtaining the basic image The basic pixel features corresponding to each basic pixel in After that, each basic pixel feature is transformed one by one Input into the lightweight multi-layer perceptron (MLP) in the spectral super-resolution network to obtain the current network parameters in the spectral super-resolution network The corresponding prediction residual pixel As shown in the following formula (7).
[0133] (7)
[0134] It is understandable that MLP strikes a balance between efficiency and capturing complex spectral patterns. Specifically, a sinusoidal activation function is used in the hidden layer, which proves to be effective in capturing fine-grained details. The input size is consistent with the length of the pixel-by-pixel feature, and the output size corresponds to the number of non-anchored spectral bands. By default, the hyperparameters of the MLP, including the hidden layer size and the number of hidden layers, are set to 32 and 1 in this embodiment. By adjusting these hyperparameters, the capacity of the network can be effectively controlled and adapted to specific coding compression task requirements.
[0135] Then combine all basic pixel features in the order of basic pixels In the current network parameters The corresponding prediction residual pixel , to get the basic image In the current network parameters The corresponding prediction residual image is .
[0136] Through the above steps 401 to 403, and steps 501 to 503, the relevant data of each basic pixel in the basic image is normalized to obtain the basic pixel features used to characterize the features of each basic pixel. Next, the lightweight multi-layer perceptron in the spectral super-resolution network is used to infer and reconstruct the image of each basic pixel one by one and combine them, so as to accurately obtain the predicted residual image corresponding to the basic image under the current network parameters, so as to optimize the network parameters by using the difference between the predicted residual image and the actual residual image, thereby improving the reliability and compression efficiency of hyperspectral image encoding.
[0137] In some embodiments, after obtaining the basic image In the current network parameters The corresponding prediction residual image is After that, the actual residual image will be further and the prediction residual image The difference between the values of and is used to obtain the optimized network parameters that represent the characteristics of the non-anchor band data in the additional image and can be directly encoded and compressed. , as described below.
[0138] Reference Figure 6 , based on the difference between the actual residual image and the predicted residual image, the optimized network parameters are obtained, including the following steps 601 to 602.
[0139] Step 601: Based on the difference between the actual residual image and the predicted residual image, a norm process is performed to obtain a predicted residual value.
[0140] Step 602: Generate a prediction error optimization function based on the prediction residual value, minimize the prediction error optimization function, and obtain optimized network parameters.
[0141] Steps 601 to 602 are described in detail below.
[0142] In some embodiments, in a spectral super-resolution network, an optimized network parameter is generated The optimization process aims to minimize the prediction error between the predicted prediction residual image and the actual residual image.
[0143] Therefore, based on the difference between the actual residual image and the predicted residual image, the predicted residual value is obtained by performing the two-norm processing. Next, based on the predicted residual value The image height H and image width W in the image parameters of the hyperspectral image are used to generate a prediction error optimization function, and the prediction error optimization function is minimized to obtain the optimized network parameters As shown in the following formula (8).
[0144] (8)
[0145] Through the above steps 601 to 602, in the spectral super-resolution network, the prediction error optimization function generated by the predicted residual value representing the gap between the actual residual image and the predicted residual image is minimized to gradually adjust the network parameters so that the predicted residual image approaches the actual residual image, so as to obtain the network parameters corresponding to the time when the predicted residual image and the actual residual image are most similar as the optimized network parameters, so as to facilitate the subsequent use of the optimized network parameters directly as the characteristics of the non-anchor band data in the additional image for encoding and compression, thereby greatly improving the encoding and compression efficiency while maintaining the accuracy and reliability of the encoding and compression of the hyperspectral image.
[0146] Reference Figure 7, is a schematic diagram of the architecture of a spectral super-resolution network provided in an embodiment of the present application. Figure 7 As shown in , as a key component of the framework, the spectral super-resolution network takes the features extracted from the base image as input, outputs a predicted residual image, and gradually adjusts the network parameters based on the difference between the predicted residual image and the actual residual image to obtain the optimal optimized network parameters. Figure 7 As shown in , the spectral super-resolution network mainly includes a lightweight multi-layer perceptron that extracts pixel features from a basic image, performs prediction processing on the basic image, and a reconstruction process that gradually adjusts network parameters based on the difference between the predicted residual image and the actual residual image.
[0147] Step 105: Obtain image encoding data of the hyperspectral image based on the optimized network parameters and the basic image.
[0148] Step 105 is described in detail below.
[0149] In some embodiments, after obtaining the optimized network parameters that can be directly used for encoding and compression processing and the base image Afterwards, the network parameters will be optimized based on and the base image The compression encoding process is performed to obtain the image encoding data of the hyperspectral image, as described in detail below.
[0150] Reference Figure 8 , obtaining image coding data of a hyperspectral image based on optimized network parameters and a basic image, includes the following steps 801 to 804.
[0151] Step 801: Obtain image header information, and encode the image header information based on a header encoder to obtain a header bit stream.
[0152] Step 802: Encode the optimized network parameters based on the auxiliary encoder to obtain an auxiliary bit stream.
[0153] Step 803: Encode the basic image based on the basic encoder to obtain a basic bit stream.
[0154] Step 804: Obtain image coding data based on the header bitstream, the auxiliary bitstream and the basic bitstream.
[0155] Steps 801 to 804 are described in detail below.
[0156] In some embodiments, in addition to optimizing network parameters and the base image In addition, it is also necessary to obtain the necessary image header information in the hyperspectral image, where the image header information includes the number of image bands (i.e., the number of spectral bands C), image parameters (i.e., the number of anchor bands K), and network size parameters of the hyperspectral image. Then, the image header information is encoded based on the header encoder to obtain the header bitstream, and the network parameters are optimized based on the auxiliary encoder. Encoding is performed to obtain an auxiliary bit stream, and the basic image is encoded based on the basic encoder The encoding process is performed to obtain a basic bit stream. Therefore, the complete image encoding data corresponding to the hyperspectral image includes a header bit stream, an auxiliary bit stream and a basic bit stream.
[0157] Reference Fig. 9 , is a schematic diagram of the architecture flow of a hyperspectral image encoding method provided in an embodiment of the present application. Fig. 9 As shown in the figure, for the encoding and compression processing of the hyperspectral image, the hyperspectral image is first input into the spectrum division module for image division to obtain the basic spectrum image (i.e., the basic image ) and supplementary spectral images (i.e., additional images ), then, the spectral interpolation module performs Interpolation is performed to produce a preliminary estimate of the additional image (i.e., the interpolated basic image Then, a lightweight spectral super-resolution network (LSSRN) is applied to the base image Perform spectral super-resolution to restore the predicted residual image corresponding to the hyperspectral image , and based on the prediction residual image and the interpolated base image With attached image The actual residual image generated by the difference between The difference between them is used to generate the optimized network parameters As supplementary information, the necessary header information and basic image are finally And optimize network parameters The coding and compression processing is performed separately to realize the coding and compression process of the hyperspectral image, thereby greatly improving the coding and compression efficiency while maintaining the accuracy and reliability of the coding and compression of the hyperspectral image.
[0158] In contrast, the present application embodiment also provides a hyperspectral image decoding method, and the hyperspectral image decoding method in the present application embodiment will be described in detail below. Fig.10 , is an optional flow chart of the hyperspectral image decoding method provided in the embodiment of the present application, Fig.10 The method in the embodiment may include but is not limited to steps 1001 to 1005. Fig.10The order of step 1001 to step 1005 is not specifically limited, and the order of steps can be adjusted or some steps can be reduced or increased according to actual needs. The hyperspectral image decoding method provided in the embodiment of the present application can also be applied to any intelligent terminal with computing and processing capabilities.
[0159] Step 1001: Obtain optimized network parameters and basic images.
[0160] Step 1002: Perform spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data.
[0161] Step 1003: Input the optimized network parameters and the basic image into the spectral super-resolution network to generate a predicted residual image.
[0162] Step 1004: Obtain an additional image containing non-anchor band data based on the cumulative sum of the interpolated basic image and the predicted residual image.
[0163] Step 1005: Perform spectral integration based on the basic image and the additional image to obtain a decoded hyperspectral image.
[0164] Steps 1001 to 1005 are described in detail below.
[0165] Reference Fig.11 , is a schematic diagram of the architecture flow of a hyperspectral image decoding method provided in an embodiment of the present application. Fig.11 As shown in , the decoding stage corresponds to the encoding stage, reconstructing the original hyperspectral image from the compressed bitstream. Specifically, the image bitstream is first divided into three sub-bitstreams: header bitstream, base bitstream and auxiliary bitstream, and each sub-bitstream is decoded by the corresponding decoder.
[0166] Next, use the decoded optimized network parameters and the base image And the necessary header information to reconstruct the spectral super-resolution network. Specifically, it includes: The anchor band data in is spectrally interpolated to obtain the interpolated basic image containing non-anchor band data. ; Then, the network parameters will be optimized and the base image Input spectral super-resolution network to generate optimized network parameters Next basic image The corresponding prediction residual image ; Further, based on the interpolation basic image and the prediction residual image The sum of the sums includes the basic image Additional images of non-anchor band data beyond the included data , and finally the basic image and additional images Perform spectral integration to obtain the decoded and reconstructed hyperspectral image .
[0167] The HSI coding compression method provided by the implementation of the present application divides the hyperspectral image into two sub-images, each consisting of two different groups of bands: the basic image contains anchor bands, and the additional image contains non-anchor bands. The basic image is losslessly compressed using a traditional codec, thereby ensuring the retention of key information; the additional image is efficiently compressed by overfitting a lightweight super-resolution network during the encoding process to predict non-anchor bands. The optimized network parameters are encoded as additional information to ensure high-quality spectral super-resolution during decoding. This method achieves a significant reduction in bit consumption because the optimized network parameters have almost no storage overhead, but can effectively perform high-quality spectral recovery during decoding, thereby improving compression efficiency.
[0168] The hyperspectral image encoding method, decoding method and related equipment proposed in the embodiments of the present application, the encoding method includes: first, based on the image parameters of the hyperspectral image, uniform band sampling is performed on the hyperspectral image to obtain multiple anchor band data, and a basic image is composed based on all the anchor band data, and multiple non-anchor band data other than the basic image in the hyperspectral image are combined to obtain an additional image, the basic image includes the anchor band data, and the additional image includes the non-anchor band data; then, the bands composed of every two adjacent anchor band data are used as target interpolation bands one by one, and multiple similar anchor band data in the target interpolation band are determined, and the target interpolation band is interpolated based on the multiple similar anchor band data to obtain an interpolated basic image; next, based on the difference between the additional image and the interpolated basic image, an actual residual image is obtained; thereafter, each basic Pixels, based on the image parameters of the hyperspectral image, the pixel coordinates of the basic pixels are normalized to obtain the normalized coordinates, based on the maximum band value and the minimum band value of the hyperspectral image, the band values of the basic pixels are normalized to obtain the normalized band values, based on the normalized coordinates and the normalized band values, the basic pixel features are obtained, each basic pixel feature is input into the spectral super-resolution network one by one, and the corresponding predicted residual pixels under the current network parameters are obtained, all predicted residual pixels are combined to obtain a predicted residual image, and based on the difference between the actual residual image and the predicted residual image, norm processing is performed to obtain the predicted residual value, a prediction error optimization function is generated based on the predicted residual value, the prediction error optimization function is minimized to obtain the optimized network parameters; finally, the image encoding data of the hyperspectral image is obtained based on the optimized network parameters and the basic image.
[0169] In the embodiment of the present application, the hyperspectral image is first divided into a basic image composed of anchor band data that can be directly encoded and transmitted, and an additional image composed of non-anchor band data that cannot be directly encoded and transmitted, and then the interpolated basic image containing non-anchor band data obtained by interpolating the basic image is used to obtain the difference between the additional image and the actual residual image that can be used as a prediction target of the spectral super-resolution network, and the spectral super-resolution network is used to fit the actual residual image and the predicted residual image to obtain optimized network parameters for characterizing the characteristics of the non-anchor band data in the additional image and for directly encoding and compressing the image, so as to obtain the hyperspectral image after encoding and compressing based on the optimized network parameters and the basic image. The invention can obtain image coding data with high compression efficiency of the image, thereby effectively improving the coding compression efficiency of the hyperspectral image; and, using the number of anchor bands in the image parameters to uniformly sample the bands of the hyperspectral image, so as to obtain multiple anchor band data that can be directly coded and compressed to obtain a basic image, and use the remaining data as an additional image, so as to realize accurate division of the hyperspectral image in the spectral division module, so as to facilitate the accuracy of subsequent feature extraction of the additional image, thereby improving the coding compression reliability of the hyperspectral image; and, in the spectral interpolation module, using the anchor bands in the basic image, and using cubic spline interpolation to interpolate the non-anchor bands in the basic image, so as to obtain a basic image that can be used to characterize the basic image. The image also contains an interpolated basic image of non-anchor band data, which makes it easier to use the image difference between the interpolated basic image and the additional image for subsequent encoding processing to reduce the risk of value drift in the training process of the spectral super-resolution network, thereby improving the reliability of hyperspectral image encoding; in addition, the relevant data of each basic pixel in the basic image is normalized to obtain the basic pixel features used to characterize the features of each basic pixel. Next, the lightweight multi-layer perceptron in the spectral super-resolution network is used to infer and reconstruct each basic pixel feature one by one and combine them, so as to accurately obtain the predicted residual image corresponding to the basic image under the current network parameters, so as to facilitate the subsequent use of the predicted residual image and the actual residual image. The network parameters are optimized by the difference, thereby improving the reliability and compression efficiency of the hyperspectral image encoding; in addition, in the spectral super-resolution network, the prediction error optimization function generated by the predicted residual value representing the gap between the actual residual image and the predicted residual image is minimized to gradually adjust the network parameters so that the predicted residual image approaches the actual residual image, so as to obtain the network parameters corresponding to the time when the predicted residual image and the actual residual image are most similar as the optimized network parameters, so as to facilitate the subsequent direct use of the optimized network parameters as the characteristics of the non-anchor band data in the additional image for encoding and compression, thereby greatly improving the encoding and compression efficiency while maintaining the accuracy and reliability of the encoding and compression of the hyperspectral image.
[0170] The present application also provides a hyperspectral image encoding device, which can implement the above-mentioned hyperspectral image encoding method. Fig.12 , the device 1200 comprises:
[0171] An image division module 1210 is used to divide the hyperspectral image into a basic image and an additional image, wherein the basic image includes anchor band data and the additional image includes non-anchor band data;
[0172] The first interpolation module 1220 is used to perform spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data;
[0173] An actual residual calculation module 1230, configured to obtain an actual residual image based on a difference between the additional image and the interpolated basic image;
[0174] The optimization parameter calculation module 1240 is used to input the basic image into the spectral super-resolution network to generate a predicted residual image, and obtain the optimized network parameters based on the difference between the actual residual image and the predicted residual image;
[0175] The coding data generating module 1250 is used to obtain the image coding data of the hyperspectral image based on the optimized network parameters and the basic image.
[0176] In some embodiments, the optimization parameter calculation module 1240 is further used to:
[0177] Extract features of each basic pixel one by one to obtain basic pixel features;
[0178] Input each basic pixel feature into the spectral super-resolution network one by one to obtain the corresponding prediction residual pixel under the current network parameters;
[0179] Combine all prediction residual pixels to obtain a prediction residual image.
[0180] In some embodiments, the optimization parameter calculation module 1240 is further used to:
[0181] Based on the image parameters of the hyperspectral image, the pixel coordinates of the basic pixels are normalized to obtain normalized coordinates;
[0182] Based on the maximum band value and the minimum band value of the hyperspectral image, the band value of the basic pixel is normalized to obtain the normalized band value;
[0183] Based on the normalized coordinates and normalized band values, basic pixel features are obtained.
[0184] In some embodiments, the optimization parameter calculation module 1240 is further used to:
[0185] Based on the difference between the actual residual image and the predicted residual image, the norm processing is performed to obtain the predicted residual value;
[0186] A prediction error optimization function is generated based on the prediction residual value, and the prediction error optimization function is minimized to obtain the optimized network parameters.
[0187] In some embodiments, the first interpolation module 1220 is further configured to:
[0188] The bands composed of every two adjacent anchor band data are taken as the target interpolation bands one by one;
[0189] determining a plurality of similar anchor band data in a target interpolation band;
[0190] The target interpolation band is interpolated based on multiple similar anchor band data to obtain an interpolation basic image.
[0191] In some embodiments, the image segmentation module 1210 is further configured to:
[0192] Based on the image parameters of the hyperspectral image, uniform band sampling is performed on the hyperspectral image to obtain multiple anchor band data, and a basic image is formed based on all the anchor band data;
[0193] The additional image is obtained by combining multiple non-anchor band data in the hyperspectral image except the basic image.
[0194] In some embodiments, the encoding data generation module 1250 is further configured to:
[0195] Obtaining image header information, and encoding the image header information based on a header encoder to obtain a header bit stream;
[0196] Encoding the optimized network parameters based on the auxiliary encoder to obtain an auxiliary bit stream;
[0197] Encode the basic image based on the basic encoder to obtain a basic bit stream;
[0198] Image coding data is obtained based on the header bitstream, the auxiliary bitstream and the basic bitstream.
[0199] In the above embodiments, the description of each embodiment has its own emphasis. For the part not described in detail in a certain embodiment, the specific implementation of the hyperspectral image encoding device is basically consistent with the specific implementation of the above hyperspectral image encoding method, and will not be repeated here.
[0200] In the embodiment of the present application, the hyperspectral image encoding device first divides the hyperspectral image into a basic image composed of anchor band data that can be directly encoded and transmitted, and an additional image composed of non-anchor band data that cannot be directly encoded and transmitted, and then uses the difference between the interpolated basic image containing non-anchor band data obtained by interpolating the basic image and the additional image to obtain an actual residual image that can be used as a prediction target of the spectral super-resolution network, and uses the spectral super-resolution network to fit the actual residual image and the predicted residual image to obtain optimized network parameters for characterizing the characteristics of the non-anchor band data in the additional image and for directly encoding and compressing the image, thereby encoding based on the optimized network parameters and the basic image. After code compression, image coding data with high compression efficiency of the hyperspectral image is obtained, thereby effectively improving the coding compression efficiency of the hyperspectral image; and, the number of anchor bands in the image parameters is used to uniformly sample the bands of the hyperspectral image to obtain multiple anchor band data that can be directly coded and compressed to obtain a basic image, and the remaining data is used as an additional image, so as to achieve accurate division of the hyperspectral image in the spectral division module, so as to facilitate the accuracy of subsequent feature extraction of the additional image, thereby improving the coding compression reliability of the hyperspectral image; and, in the spectral interpolation module, the anchor bands in the basic image are used, and the non-anchor bands in the basic image are interpolated by cubic spline interpolation to obtain An interpolated basic image is obtained that represents the basic image and contains non-anchor band data, so that it is convenient to use the image difference between the interpolated basic image and the additional image for subsequent encoding processing to reduce the risk of value drift in the training process of the spectral super-resolution network, thereby improving the reliability of hyperspectral image encoding; in addition, the relevant data of each basic pixel in the basic image is normalized to obtain the basic pixel features used to characterize the features of each basic pixel. Next, the lightweight multi-layer perceptron in the spectral super-resolution network is used to infer and reconstruct the image for each basic pixel feature one by one and combine them, so as to accurately obtain the predicted residual image corresponding to the basic image under the current network parameters, so as to facilitate the subsequent use of the predicted residual image and the actual residual image The network parameters are optimized by the difference between the actual residual image and the predicted residual image, thereby improving the reliability and compression efficiency of the hyperspectral image encoding; in addition, in the spectral super-resolution network, the prediction error optimization function generated by the predicted residual value representing the gap between the actual residual image and the predicted residual image is minimized to gradually adjust the network parameters so that the predicted residual image approaches the actual residual image, so as to obtain the network parameters corresponding to the time when the predicted residual image and the actual residual image are most similar as the optimized network parameters, so as to facilitate the subsequent direct use of the optimized network parameters as the characteristics of the non-anchor band data in the additional image for encoding and compression, thereby greatly improving the encoding and compression efficiency while maintaining the accuracy and reliability of the encoding and compression of the hyperspectral image.
[0201] The present application also provides a hyperspectral image decoding device, which can implement the above hyperspectral image decoding method. Fig.13 , the device 1300 comprises:
[0202] An image acquisition module 1310 is used to acquire optimized network parameters and basic images;
[0203] The second interpolation module 1320 is used to perform spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data;
[0204] The residual image generation module 1330 inputs the optimized network parameters and the basic image into the spectral super-resolution network to generate a predicted residual image;
[0205] An additional image generation module 1340, configured to obtain an additional image containing non-anchor band data based on the cumulative sum of the interpolated basic image and the predicted residual image;
[0206] The decoded data generation module 1350 is used to perform spectral integration based on the basic image and the additional image to obtain a decoded hyperspectral image.
[0207] In the above embodiments, the description of each embodiment has its own emphasis. For the part not described in detail in a certain embodiment, the specific implementation of the hyperspectral image encoding device is basically consistent with the specific implementation of the above hyperspectral image decoding method, and will not be repeated here.
[0208] The present application also provides an electronic device, including:
[0209] at least one memory;
[0210] at least one processor;
[0211] at least one program;
[0212] The program is stored in the memory, and the processor executes the at least one program to implement the hyperspectral image encoding method implemented in the present application. The electronic device can be any intelligent terminal including a mobile phone, a tablet computer, a personal digital assistant (PDA), a car computer, etc.
[0213] See also Fig.14 , Fig.14 The hardware structure of an electronic device of another embodiment is illustrated, and the electronic device includes:
[0214] The processor 1401 may be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present application;
[0215] The memory 1402 can be implemented in the form of ROM (Read Only Memory), static storage device, dynamic storage device or RAM (Random Access Memory). The memory 1402 can store operating systems and other applications. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 1402, and the processor 1401 is used to call and execute the hyperspectral image encoding method of the embodiments of this application;
[0216] Input / output interface 1403, used to implement information input and output;
[0217] The communication interface 1404 is used to realize the communication interaction between the device and other devices. The communication can be realized through a wired manner (such as USB, network cable, etc.) or a wireless manner (such as mobile network, WIFI, Bluetooth, etc.);
[0218] A bus 1405 that transmits information between various components of the device (e.g., the processor 1401, the memory 1402, the input / output interface 1403, and the communication interface 1404);
[0219] The processor 1401 , the memory 1402 , the input / output interface 1403 and the communication interface 1404 are connected to each other in communication within the device via a bus 1405 .
[0220] The embodiment of the present application further provides a storage medium, which is a computer-readable storage medium. The storage medium stores a computer program, and when the computer program is executed by a processor, the above-mentioned hyperspectral image encoding method is implemented.
[0221] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0222] The embodiments described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. Those skilled in the art will appreciate that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
[0223] Those skilled in the art will appreciate that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.
[0224] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0225] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.
[0226] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0227] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0228] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the above units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. The mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0229] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0230] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0231] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including multiple instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), disk or optical disk and other media that can store programs.
[0232] The preferred embodiments of the present invention are described above with reference to the accompanying drawings, but the scope of the rights of the present invention is not limited thereto. Any modification, equivalent substitution and improvement made by a person skilled in the art without departing from the scope and essence of the present invention should be within the scope of the rights of the present invention.
Claims
1. A hyperspectral image encoding method, characterized in that: The method comprises: Dividing the hyperspectral image into a basic image and an additional image, wherein the basic image includes anchor band data and the additional image includes non-anchor band data; Performing spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data; Obtaining an actual residual image based on a difference between the additional image and the interpolated basic image; Inputting the basic image into a spectral super-resolution network to generate a predicted residual image, and obtaining optimized network parameters based on the difference between the actual residual image and the predicted residual image; Obtaining image coding data of the hyperspectral image based on the optimized network parameters and the basic image; The step of obtaining an optimized network parameter based on a difference between the actual residual image and the predicted residual image comprises: Based on the difference between the actual residual image and the predicted residual image, a norm processing is performed to obtain a predicted residual value; A prediction error optimization function is generated based on the prediction residual value, and the prediction error optimization function is minimized to obtain the optimized network parameters, wherein the optimized network parameters represent the characteristics of the non-anchor band data in the additional image.
2. The hyperspectral image encoding method according to claim 1, characterized in that: The basic image includes a plurality of basic pixels, and the step of inputting the basic image into a spectral super-resolution network to generate a predicted residual image includes: Extracting features of each of the basic pixels one by one to obtain basic pixel features; Inputting each of the basic pixel features into the spectral super-resolution network one by one to obtain corresponding prediction residual pixels under current network parameters; All the prediction residual pixels are combined to obtain the prediction residual image.
3. The hyperspectral image encoding method according to claim 2, characterized in that: The step of extracting features from each of the basic pixels to obtain basic pixel features includes: Based on the image parameters of the hyperspectral image, normalizing the pixel coordinates of the basic pixels to obtain normalized coordinates; Based on the maximum band value and the minimum band value of the hyperspectral image, the band value of the basic pixel is normalized to obtain a normalized band value; The basic pixel feature is obtained based on the normalized coordinates and the normalized band value.
4. The hyperspectral image encoding method according to claim 1, characterized in that: The basic image includes a plurality of anchor band data, and the spectral interpolation processing is performed on the anchor band data in the basic image to obtain an interpolated basic image including non-anchor band data, including: Taking the bands composed of every two adjacent anchor band data as target interpolation bands one by one; Determining a plurality of similar anchor band data in the target interpolation band; The target interpolation band is interpolated based on the plurality of similar anchor band data to obtain the interpolation basic image.
5. The hyperspectral image encoding method according to claim 1, characterized in that: The step of dividing the hyperspectral image into a basic image and an additional image comprises: Based on the image parameters of the hyperspectral image, uniform band sampling is performed on the hyperspectral image to obtain a plurality of anchor band data, and the basic image is formed based on all the anchor band data; The additional image is obtained by combining a plurality of non-anchor band data in the hyperspectral image except the basic image.
6. The hyperspectral image encoding method according to claim 1, characterized in that: The step of obtaining the image encoding data of the hyperspectral image based on the optimized network parameters and the basic image comprises: Acquire image header information, and encode the image header information based on a header encoder to obtain a header bit stream; Performing encoding processing on the optimized network parameters based on an auxiliary encoder to obtain an auxiliary bit stream; Encoding the basic image based on a basic encoder to obtain a basic bit stream; The image coding data is obtained based on the header bit stream, the auxiliary bit stream and the basic bit stream.
7. A hyperspectral image decoding method, characterized in that: The method comprises: Obtaining optimized network parameters and a basic image, wherein the optimized network parameters and the basic image are generated by the hyperspectral image encoding method according to claim 1; Performing spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data; Inputting the optimized network parameters and the basic image into a spectral super-resolution network to generate a predicted residual image; Obtaining an additional image containing non-anchor band data based on the cumulative sum of the interpolated basic image and the predicted residual image; Spectral integration is performed based on the basic image and the additional image to obtain a decoded hyperspectral image.
8. A hyperspectral image encoding device, characterized in that: The device comprises: An image division module, used for dividing the hyperspectral image into a basic image and an additional image, wherein the basic image includes anchor band data and the additional image includes non-anchor band data; A first interpolation module is used to perform spectral interpolation processing on the anchor band data in the basic image to obtain an interpolated basic image containing non-anchor band data; an actual residual calculation module, configured to obtain an actual residual image based on a difference between the additional image and the interpolated basic image; An optimization parameter calculation module, used for inputting the basic image into a spectral super-resolution network to generate a predicted residual image, and obtaining optimized network parameters based on a difference between the actual residual image and the predicted residual image; A coding data generating module, used for obtaining image coding data of the hyperspectral image based on the optimized network parameters and the basic image; The step of obtaining an optimized network parameter based on a difference between the actual residual image and the predicted residual image comprises: Based on the difference between the actual residual image and the predicted residual image, a norm processing is performed to obtain a predicted residual value; A prediction error optimization function is generated based on the prediction residual value, and the prediction error optimization function is minimized to obtain the optimized network parameters, wherein the optimized network parameters represent the characteristics of the non-anchor band data in the additional image.
9. An electronic device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the hyperspectral image encoding method according to any one of claims 1 to 6 or the hyperspectral image decoding method according to claim 7 is implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the hyperspectral image encoding method according to any one of claims 1 to 6 or the hyperspectral image decoding method according to claim 7 is implemented.
Citation Information
Patent Citations
Hyperspectral image lossless compression method based on deep learning
CN108960333A
Hyper-spectral and panchromatic image fusion method for extracting multi-scale spatial-spectral characteristics based on AE
CN112634137A