Method for removing mountain shadow in optical remote sensing image

The method addresses the challenge of shadow removal in remote sensing images by using spectral similarity and terrain correction, improving image clarity and classification accuracy.

CN119648723APending Publication Date: 2025-03-18CHINA INST OF WATER RESOURCES & HYDROPOWER RES

Patent Information

Application Number
CN202411717491.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-27
Publication Date
2025-03-18

AI Technical Summary

Technical Problem

Shadows in optical remote sensing images hinder accurate land cover classification due to their low reflectance characteristics, leading to incomplete spectral information and misclassification of objects.

Method used

A method to remove shadows from optical remote sensing images by identifying shadow and non-shadow regions based on spectral data, establishing a spectral library for non-shadow areas, and generating new spectral data for shadow regions using similarity metrics, followed by optimization using terrain correction and wavelet transform algorithms.

Benefits of technology

The method enhances image clarity and target recognition, improving the accuracy and reliability of remote sensing data applications by producing shadow-free images with enhanced spectral information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119648723A_ABST
    Figure CN119648723A_ABST
Patent Text Reader

Abstract

The invention relates to a method for removing a mountain shadow in an optical remote sensing image. The removing method comprises the following steps: determining a shadow region and a non-shadow region in the optical remote sensing image according to spectral data of different wavebands; acquiring first spectral data of various ground objects in a non-shadow area, and establishing a non-shadow area spectrum library; according to the similarity between each second spectrum data in the shadow area and the first spectrum data in the non-shadow area spectrum library, obtaining reference spectrum data in the non-shadow area spectrum library, and respectively generating new spectrum data corresponding to the second spectrum data of each pixel in the shadow area; and generating a new shadow area according to the new spectral data, and merging to obtain a shadow-free remote sensing image. The shadow-free remote sensing image is obtained by removing the shadow, so that the image is clearer and brighter, the target recognition capability is enhanced, the information extraction precision is improved, and the application of the remote sensing data is more accurate and reliable.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of optical remote sensing, and in particular relates to a method, system, electronic device and storage medium for removing mountain shadows in optical remote sensing images. Background Art

[0002] Optical remote sensing images are images of the earth's surface captured from space or air by optical sensors. These sensors are usually installed on satellites or aircraft and can receive reflected or radiated electromagnetic waves in the visible and near-infrared bands from the earth's surface. Land object classification refers to the use of remote sensing images to identify different types of surface cover, such as buildings, water bodies, vegetation, etc., in order to better understand and manage the environment.

[0003] The shadow problem in remote sensing images is an important factor affecting the accuracy of object classification. The shadow area has low reflectivity, which makes its appearance in the image significantly different from the surrounding non-shadow area, resulting in incomplete spectral information of the image. Shadows may cause misclassification of objects. Since shadows change the spectral characteristics of objects, it is difficult for classification algorithms based on spectral characteristics to accurately distinguish between objects in shadows and actual different types of objects, which in turn affects the accuracy of classification results. Summary of the invention

[0004] To solve the above problems, the present invention provides a method, system, electronic device and storage medium for removing mountain shadows in optical remote sensing images. By removing shadows, a shadow-free remote sensing image is obtained, making the image clearer and brighter, enhancing the target recognition capability, improving the accuracy of information extraction, and making the application of remote sensing data more accurate and reliable.

[0005] In order to solve the above technical problems, the first aspect of the present invention provides a method for removing mountain shadows in optical remote sensing images, the method comprising:

[0006] Acquire an optical remote sensing image within a preset area, and determine a shadow area and a non-shadow area in the optical remote sensing image according to spectral data of different bands;

[0007] Acquire first spectral data of various types of ground objects in the non-shadow area, and establish a non-shadow area spectral library;

[0008] According to the similarity between the second spectrum data of each pixel in the shadow area and the first spectrum data in the non-shadow area spectrum library, first spectrum data whose similarity with the second spectrum data meets a preset requirement is obtained in the non-shadow area spectrum library as reference spectrum data;

[0009] Based on the reference spectral data, new spectral data corresponding to the second spectral data of each pixel in the shadow area are respectively generated; and a new shadow area is generated according to the new spectral data; and the new shadow area and the non-shadow area are merged to obtain a shadow-free remote sensing image.

[0010] According to a preferred embodiment of the present invention, after establishing the non-shadow region spectral library, the method further comprises:

[0011] Constructing a first spectral vector according to the first spectral data; constructing a second spectral vector according to the second spectral data of each pixel in the shadow area;

[0012] Calculating the mean and standard deviation of the first spectrum data in the non-shadow area spectrum library;

[0013] The first spectral vector and the second spectral vector are standardized based on the mean and the standard deviation.

[0014] According to a preferred embodiment of the present invention, according to the similarity between the second spectral data of each pixel in the shadow area and the first spectral data in the non-shadow area spectral library, obtaining the first spectral data whose similarity with the second spectral data meets the preset requirements in the non-shadow area spectral library as the reference spectral data includes:

[0015] Calculating the similarity between each of the second spectrum vectors and each of the first spectrum vectors;

[0016] For each of the second spectral vectors, in each of the first spectral vectors, a first spectral vector whose similarity to the second spectral vector meets a preset similarity requirement is determined; and the first spectral data corresponding to the first spectral vector whose similarity meets the preset similarity requirement is used as the reference spectral data.

[0017] According to a preferred embodiment of the present invention, the calculating the similarity between each of the second spectral vectors and each of the first spectral vectors includes:

[0018] The Mahalanobis distance between each of the second spectral vectors and each of the first spectral vectors is calculated as the similarity.

[0019] According to a preferred embodiment of the present invention, generating new spectral data corresponding to the second spectral data of each pixel in the shadow area based on the reference spectral data respectively includes:

[0020] For the second spectrum data of each pixel, a weighted sum is performed on the similarity between the second spectrum data and each reference spectrum data and each reference spectrum data to generate new spectrum data corresponding to the second spectrum data.

[0021] According to a preferred embodiment of the present invention, performing weighted summation of the similarities between the second spectral data and each of the reference spectral data and each of the reference spectral data to generate new spectral data corresponding to the second spectral data includes:

[0022] Constructing a reference spectrum vector according to the reference spectrum data;

[0023] Calculating the distance weight of each reference spectrum vector according to the Mahalanobis distance between the second spectrum vector and the corresponding reference spectrum vector;

[0024] A new spectrum vector is obtained by weighted summing up each of the reference spectrum vectors and the distance weights;

[0025] The new spectral data is generated according to the new spectral vector.

[0026] According to a preferred embodiment of the present invention, after determining the shadow area and the non-shadow area in the optical remote sensing image according to the spectral data of different bands, the removal method further comprises:

[0027] The brightness value of the shadow area is optimized by a terrain correction algorithm, and the contrast and image details of the shadow area are optimized by a wavelet transform algorithm.

[0028] In order to solve the above technical problems, the second aspect of the present invention provides a system for removing mountain shadows in optical remote sensing images, the removal system comprising:

[0029] A shadow area determination module is used to obtain an optical remote sensing image within a preset area, and determine a shadow area and a non-shadow area in the optical remote sensing image according to spectral data of different bands;

[0030] A spectrum library building module, used for acquiring first spectrum data of various types of ground objects in the non-shadow area and building a spectrum library in the non-shadow area;

[0031] a reference spectrum acquisition module, configured to acquire, according to the similarity between the second spectrum data of each pixel in the shadow area and the first spectrum data in the non-shadow area spectrum library, first spectrum data whose similarity with the second spectrum data meets preset requirements in the non-shadow area spectrum library as reference spectrum data;

[0032] The shadow area processing module is used to generate new spectral data corresponding to the second spectral data of each pixel in the shadow area based on the reference spectral data; generate a new shadow area according to the new spectral data; and merge the new shadow area with the non-shadow area to obtain a shadow-free remote sensing image.

[0033] In order to solve the above technical problem, the third aspect of the present invention provides an electronic device, comprising:

[0034] Processor; and

[0035] A memory storing computer executable instructions, wherein when the computer executable instructions are executed, the processor executes the method described in any one of the above embodiments.

[0036] In order to solve the above technical problems, the fourth aspect of the present invention proposes a computer storage medium, wherein the computer storage medium stores one or more programs, and when the one or more programs are executed by a processor, the method described in any one of the above embodiments is implemented.

[0037] Compared with the prior art, the present invention has the following advantages: the present invention determines the shadow area and non-shadow area in the optical remote sensing image through spectral data of different bands, establishes a spectral library of the non-shadow area, screens reference spectral data corresponding to the spectral data of the shadow area from the spectral library according to the similarity of the spectral data, generates new spectral data corresponding to each spectral data of the shadow area according to the reference spectral data, reconstructs the new shadow area, and finally combines the new shadow area and the non-shadow area to generate a shadow-free remote sensing image. The shadow-free remote sensing image is obtained by removing the shadow, making the image clearer and brighter, enhancing the target recognition capability, and improving the information extraction accuracy, so that the application of remote sensing data is more accurate and reliable.

[0038] Other features and advantages of the present disclosure will be described in the following description, and partly become apparent from the description, or be understood by implementing the present disclosure. The purpose and other advantages of the present disclosure can be realized and obtained by the structures pointed out in the description, claims and drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0040] Figure 1 A first schematic diagram of a method for removing mountain shadows in an optical remote sensing image according to an embodiment of the present disclosure is shown;

[0041] Figure 2 A schematic diagram of a method flow for optimizing the brightness value of a shadow area by using a terrain correction algorithm according to an embodiment of the present disclosure is shown;

[0042] Figure 3 A schematic diagram of a method flow for optimizing the contrast and image details of a shadow area by using a wavelet transform algorithm according to an embodiment of the present disclosure is shown;

[0043] Figure 4 A second flow chart of a method for removing mountain shadows in an optical remote sensing image according to an embodiment of the present disclosure is shown;

[0044] Figure 5 A third flow chart of a method for removing mountain shadows in an optical remote sensing image according to an embodiment of the present disclosure is shown;

[0045] Figure 6 A fourth flow chart of a method for removing mountain shadows in an optical remote sensing image according to an embodiment of the present disclosure is shown;

[0046] Figure 7 A block diagram of a system for removing mountain shadows in an optical remote sensing image according to an embodiment of the present disclosure is shown;

[0047] Figure 8 A schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0048] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.

[0049] The same reference numerals in the drawings represent the same or similar elements, components or parts, and thus the repeated description of the same or similar elements, components or parts may be omitted below. It should also be understood that although the first, second, third and other attributives representing the numbers may be used herein to describe various devices, elements, components or parts, these devices, elements, components or parts should not be limited by these attributives. In other words, these attributives are only used to distinguish one from another. For example, the first device may also be called the second device, but it does not deviate from the essential technical solution of the present invention. In addition, the terms "and / or" and "and / or" refer to all combinations including any one or more of the listed items.

[0050] See also Figure 1 , Figure 1 FIG. 1 is a flow chart of a method for removing mountain shadows in an optical remote sensing image provided by the present invention. Figure 1 As shown, the method includes:

[0051] S11. Acquire an optical remote sensing image within a preset area, and determine a shadow area and a non-shadow area in the optical remote sensing image according to spectral data of different bands.

[0052] In this embodiment, the optical remote sensing image is an image of the earth's surface captured from space or high altitude by optical sensors. These sensors are usually installed on satellites or aircraft and can receive reflected or radiated electromagnetic waves in the visible light and near-infrared bands from the earth's surface.

[0053] In this embodiment, the spectral data describes the reflection, absorption and emission characteristics of the ground object in different bands, which are determined by the physical and chemical properties of the ground object. In remote sensing image analysis, spectral features are used to distinguish different types of ground objects, such as vegetation, water, soil, buildings, etc.

[0054] In this embodiment, shadows usually show lower brightness on optical remote sensing images. Therefore, brightness can be used as a feature for shadow detection. It is also possible to construct a conversion model to suppress features such as vegetation and water bodies while enhancing shadows by combining the blue and dark appearance of shadows, as well as the reflective properties of vegetation and water bodies. Then, the shadow representation is converted into a color space, and candidate shadows are generated using the primary color component. It is also possible to convert the optical remote sensing image to an HSV color space, where the HSV model is a hexagonal pyramid color space based on hue (H), saturation (S) and brightness (V). Among them, H represents color information, S represents the purity of the color, and V represents the brightness of the color. In the HSV model, shadow areas usually have larger hue values ​​H and lower brightness V. Therefore, a colored RGB image can be converted into an HSV image, and the shadow area can be preliminarily segmented based on these characteristics.

[0055] S12. Acquire first spectral data of various types of ground objects in the non-shadow area, and establish a spectral library of the non-shadow area.

[0056] In this embodiment, the pre-trained supervised classification model can be used to classify and identify objects in the non-shadow area, determine the object classification map in the non-shadow area, and then obtain the first spectral data of each type of object according to the object classification map, and establish a non-shadow area spectral library based on the first spectral data of each type of object.

[0057] In this embodiment, for each type of ground object, a spectral data corresponding to the type of ground object is established and stored in the non-shadow area spectral library as sample spectral data. On the one hand, the number of samples in the non-shadow area spectral library can be reduced, and on the other hand, sufficient samples can be collected to represent the spectral variability of this type of ground object under non-shadow conditions.

[0058] In this embodiment, in this embodiment, supervised learning algorithm is an important method in machine learning, which trains the model by using labeled training data so that it can make predictions or decisions on new, unseen data. In a supervised learning algorithm, each training sample contains input variables (usually represented as features) and desired output variables (also called labels or targets). The goal of the algorithm is to learn the mapping relationship between input and output so that the output of new samples can be accurately predicted. Supervised learning algorithms can be divided into two categories: classification algorithms and regression algorithms.

[0059] In this embodiment, the supervised classification model in this scheme is obtained by training with a supervised learning algorithm. Specifically, multiple groups of historical optical remote sensing images are obtained, and category labels are added to the objects in the historical optical remote sensing images according to the types of objects in the historical optical remote sensing images; based on the category labels of the historical optical remote sensing images and the objects, a supervised classification model is constructed and trained.

[0060] In this embodiment, the images outside the shadow area in the optical remote sensing image are classified and identified by a supervised classification model obtained by pre-training, and the category of each object is determined. Specifically, the images outside the shadow area in the optical remote sensing image are input into the supervised classification algorithm, and the supervised classification algorithm determines the category of each object in the image, thereby completing the classification of objects in the optical remote sensing image except the shadow area.

[0061] S13, according to the similarity between the second spectrum data of each pixel in the shadow area and the first spectrum data in the non-shadow area spectrum library, obtain the first spectrum data whose similarity with the second spectrum data meets the preset requirement in the non-shadow area spectrum library as the reference spectrum data.

[0062] In this embodiment, each second spectral data in the shadow area is spectral data corresponding to each pixel point in the shadow area.

[0063] In this embodiment, the similarity between each second spectral data in the shadow area and the first spectral data in the non-shadow area spectral library is calculated. The spectral data can be converted into vector data, and the similarity between the spectral data can be determined by calculating the distance value or cosine value between the vectors.

[0064] In this embodiment, for the second spectral data of each pixel, the first spectral data whose similarity meets the preset requirements is selected in the non-shadow area spectral library. The preset requirements can be to select the first spectral data with the highest similarity to the second spectral data as the reference spectral data. Selecting the first spectral data with the highest similarity as the reference spectral data can directly replace the corresponding first spectral data to complete the spectral data in the shadow area. This method has high requirements on the similarity calculation process. When the replacement is accurate, the shadow area image finally obtained is more accurate, but it is also easy to have replacement errors and the robustness is poor. The first spectral data with a preset ranking before the similarity sorting of the second spectral data can also be selected as the reference spectral data. In this way, multiple corresponding first spectral data are selected as reference spectral data for the second spectral data. The robustness of the new spectral data finally used to replace the shadow area can be improved by multiple reference spectral data, but the accuracy will also be reduced to a certain extent. In this solution, since the reference spectral data is selected by similarity ranking, when the similarities are relatively low, it is possible to select the first spectral data with lower similarity. A limit value can be set for the similarity. When the similarity is lower than the limit value, the first spectral data is not selected.

[0065] In this embodiment, in order to further improve the accuracy of calculating the similarity between each second spectral data in the shadow area and the first spectral data in the non-shadow area spectral library, before calculating the similarity, the brightness of the shadow area can be adjusted and the details can be optimized. Specifically, the brightness value of the shadow area can be optimized by a terrain correction algorithm, and the contrast and image details of the shadow area can be optimized by a wavelet transform algorithm.

[0066] Specifically, Figure 2 As shown, Figure 2 The optimization of the brightness value of the shadow area by the terrain correction algorithm provided by the present invention comprises the following steps:

[0067] S21. Obtain the solar zenith angle and solar incidence angle of the shadow area through the digital elevation model of the preset area and the position of the shadow area.

[0068] In this embodiment, the solar incident angle is the angle between the direct sunlight and the wall normal. The solar zenith angle is the angle between the incident direction of the light and the zenith direction, that is, the angle between the incident light and the ground normal.

[0069] In this embodiment, DEM data is a digital elevation model of the earth's surface, which is composed of dot matrix data on the earth's surface, and each point has corresponding elevation information. These data are usually presented in the form of a grid, and each grid cell contains a height value, and these height values ​​are in meters.

[0070] S22. Based on the Minnaert terrain correction algorithm, the brightness of each position in the shadow area is optimized by the Minnaert constant corresponding to the solar zenith angle, the solar incidence angle and the reflection characteristics of the ground objects, and the shadow area with optimized brightness value, contrast and image details is generated.

[0071] In this embodiment, the Minnaert terrain correction algorithm is a terrain correction algorithm based on a non-Lambertian reflection model, which uses the coefficient k in the Minnaert function to characterize the bidirectional reflectance distribution function (BRDF) of the object, thereby adjusting the intensity of terrain correction. The algorithm takes into account the non-Lambertian characteristics of the surface and is closer to the actual reflection of the surface. Therefore, the correction result is stable and is suitable for terrain correction in most mountainous and hilly areas.

[0072] In this embodiment, the ground object type pre-classification: the ground object type of the image to be corrected is pre-classified, so that the coefficient k can be fitted and solved for each ground object type later. Coefficient k fitting solution: the coefficient k is fitted and solved for each ground object type band by band, and the coefficient k value of each ground object type in each band is obtained. Terrain correction: Minnaert terrain correction is performed on the remote sensing image of the range using the coefficient k of each ground object type in each band to obtain the corrected image.

[0073] Specifically, the Minnaert correction is used to adjust the brightness of remote sensing images in mountainous areas with uneven illumination according to the nonlinear reflectance characteristics of the objects.

[0074]

[0075] L′(x,y) is the corrected brightness at position (x,y), and L(x,y) is the original image at position (x,y); θ s is the solar zenith angle. i is the angle of incidence, calculated from the DEM data and the observation position. k is the Minnaert constant related to the reflectance characteristics of the object.

[0076] Specifically, Figure 3 As shown, Figure 3 The present invention provides a method for optimizing the contrast and image details of the shadow area by using a wavelet transform algorithm, which includes the following steps:

[0077] S31. Process the shadow area by using a wavelet transform algorithm to obtain a low-frequency sub-band and a high-frequency sub-band of the shadow area.

[0078] In this embodiment, a wavelet transform is performed on the shadow image, usually using a two-dimensional discrete wavelet transform (2D DWT). This process decomposes the image into four sub-bands: a low-frequency sub-band (LL) and three high-frequency sub-bands (LH, HL, HH). Low-frequency sub-band (LL): contains most of the energy and main structural information of the image, usually representing the smooth part of the image. High-frequency sub-band: LH (horizontal details): contains high-frequency information of the image in the horizontal direction, such as edges and textures. HL (vertical details): contains high-frequency information of the image in the vertical direction. HH (diagonal details): contains high-frequency information of the image in the diagonal direction.

[0079] S32: adjusting the contrast of the low-frequency sub-band by maintaining the minimum value of the low-frequency sub-band of the baseline of the image brightness.

[0080] S33, enhancing the image details of the high-frequency sub-band by using the high-frequency sub-band average value for stabilizing detail enhancement.

[0081] In this embodiment, the overall brightness and contrast of the image are enhanced by adjusting the low-frequency sub-band obtained by wavelet transform, and the details of the image, especially the edge and texture information, are enhanced by using the high-frequency sub-band.

[0082] By adjusting the coefficients of the high-frequency subband, image details are enhanced without introducing additional noise.

[0083] I″=α·(I′ LL -min(I′ LL ))+min(I′ LL )+λ·(I′ HF -μ(I′ HF ))

[0084] I″ refers to the image obtained after wavelet transformation enhancement; I′ LL It is the low-frequency subband obtained from wavelet transform, which contains the large-scale structural information of the image. α is the magnification factor for adjusting the contrast, which is adjusted according to the image contrast requirements and is greater than 1. min(I′ LL ) is the minimum value in the low-frequency subband, which is used to maintain the baseline of image brightness. HF It is the high-frequency subband obtained from wavelet transform, which contains the details and edge information of the image. λ is the detail enhancement coefficient, which is between 0 and 1 and is used to control the degree of detail enhancement. HF ) is the average value of the high frequency sub-band, which is used to stabilize the enhancement process and avoid noise caused by over-enhancement.

[0085] S34. Generate a shadow area processed by a wavelet transform algorithm based on the adjusted low-frequency sub-band and the enhanced high-frequency sub-band.

[0086] In this embodiment, after the shadow image is processed by the wavelet transform algorithm, a low-frequency sub-band and a high-frequency sub-band are generated based on the shadow image, and corresponding optimization adjustments are performed based on the information contained in the low-frequency sub-band and the high-frequency sub-band. Finally, a processed shadow area is generated based on the optimized low-frequency sub-band and the high-frequency sub-band.

[0087] S14, based on the reference spectral data, respectively generate new spectral data corresponding to the second spectral data of each pixel in the shadow area; and generate a new shadow area according to the new spectral data; merge the new shadow area and the non-shadow area to obtain a shadow-free remote sensing image.

[0088] In this embodiment, new spectral data for replacing each second spectral data in the shadow area is generated by using reference spectral data corresponding to each second spectral data, and each second spectral data in the shadow area is replaced by the new spectral data, that is, pixels corresponding to each second spectral data in the shadow area are replaced by pixels corresponding to the new spectral data, so as to obtain a new shadow area, and then generate a shadow-free remote sensing image.

[0089] In this embodiment, this scheme determines the shadow area and non-shadow area in the optical remote sensing image through spectral data of different bands, establishes a spectral library of the non-shadow area, screens reference spectral data corresponding to the spectral data of the shadow area from the spectral library according to the similarity of the spectral data, generates new spectral data corresponding to each spectral data of the shadow area according to the reference spectral data, reconstructs the new shadow area, and finally combines the new shadow area and the non-shadow area to generate a shadow-free remote sensing image. The shadow-free remote sensing image is obtained by removing the shadow, making the image clearer and brighter, enhancing the target recognition ability, and improving the information extraction accuracy, making the application of remote sensing data more accurate and reliable.

[0090] See also Figure 4 , Figure 4 The second flowchart of the method for removing mountain shadows in optical remote sensing images provided by the present invention is as follows: Figure 4 As shown, after S12, the following steps are also included:

[0091] S41, constructing a first spectrum vector according to the first spectrum data; and constructing a second spectrum vector according to the second spectrum data of each pixel in the shadow area.

[0092] In this embodiment, the first spectral vector and the second spectral vector refer to the spectral reflectance data for a certain pixel point obtained from the remote sensing image, and the data includes reflectance values ​​at different wavelengths. These values ​​form a vector, and each element represents the reflection or radiation intensity at a specific wavelength.

[0093] In this embodiment, the first spectral data corresponds to various types of ground objects, that is, the first spectral data corresponding to each pixel point of each type of ground object in the non-shadow area. Even if it is the same ground object, due to the light, angle, and ground object color, the various pixel points of the ground object in the non-shadow area will have certain differences. This solution constructs a corresponding spectral vector for each pixel point.

[0094] S42, calculating the mean and standard deviation of the first spectrum data in the non-shadow area spectrum library.

[0095] In this embodiment, the first spectral data in the non-shadow area spectral library can be obtained by averaging all the first spectral data of one type, that is, in the non-shadow area spectral library, one type of land object corresponds to one spectral data, which can reduce the amount of data in the spectral library and balance the spectral data of one type. Of course, all the first spectral data can also be stored in the non-shadow spectral library. In this way, the difference of spectral data of the same type of land objects can be retained and the data accuracy can be improved, but the calculation amount and data storage amount will be greatly increased.

[0096] In this embodiment, the mean and standard deviation of each first spectral data in the shadow area spectral library are calculated, thereby determining the volatility of the spectral data in the non-shadow area.

[0097] S43, standardize the first spectrum vector and the second spectrum vector based on the mean and the standard deviation.

[0098] In this embodiment, each first spectral vector and second spectral vector is standardized by the mean and standard deviation to eliminate the scale difference in the shadow area and the non-shadow area, so as to calculate the similarity between the first spectral data and the second spectral data and reduce the error.

[0099] Specifically, each spectral vector The standardized formula is:

[0100]

[0101] in, is the first spectral vector or the second spectral vector, is the first spectrum vector or the second spectrum vector after normalization, μ is the mean of the first spectrum data in the non-shadow area spectrum library, and σ is the standard deviation of the first spectrum data in the non-shadow area spectrum library.

[0102] See also Figure 5 , Figure 5 The third is a flow chart of a method for removing mountain shadows in an optical remote sensing image provided by the present invention. Figure 5 As shown, S13 includes the following steps:

[0103] S51 : Calculate the similarity between each second spectral vector and each first spectral vector.

[0104] In this embodiment, the spectral data contains many types of data, and it is difficult to directly calculate the statistical calculation indicators. In this solution, after the spectral data is converted into spectral vectors, the similarity values ​​between the vectors are calculated to determine the similarity between the spectral data.

[0105] In this embodiment, the Mahalanobis distance between each second spectral vector and each first spectral vector may be calculated as the similarity.

[0106] S52, for each second spectral vector, in each first spectral vector, determine a first spectral vector whose similarity with the second spectral vector meets a preset similarity requirement; and use first spectral data corresponding to the first spectral vector whose similarity meets the preset similarity requirement as reference spectral data.

[0107] In this embodiment, after the similarity between each first spectrum vector and the second spectrum vector is calculated, the first spectrum data corresponding to the first spectrum vector whose similarity meets the preset similarity requirement is used as the reference spectrum data.

[0108] See also Figure 6 , Figure 6 FIG. 4 is a flow chart of a method for removing mountain shadows in an optical remote sensing image provided by the present invention. Figure 6 As shown, S14 includes the following steps:

[0109] S61. Construct a reference spectrum vector according to the reference spectrum data.

[0110] In this embodiment, the reference spectral data and the reference spectral vector are the first spectral vector whose similarity with the second spectral vector meets the preset similarity requirement in the above embodiment, and the first spectral data corresponding thereto.

[0111] S62: Calculate the distance weight of each reference spectrum vector according to the Mahalanobis distance between the second spectrum vector and the corresponding reference spectrum vector.

[0112] In this embodiment, the distance weight of each reference spectral vector is calculated based on the Mahalanobis distance between the second spectral vector and the corresponding reference spectral vector. Since the smaller the Mahalanobis distance, the more similar the two vectors are, and the more important the corresponding reference spectral vector is to the second spectral vector, the corresponding distance weight is calculated based on the Mahalanobis distance.

[0113] S63, performing weighted summation of each reference spectral vector and the distance weight to obtain a new spectral vector.

[0114] In this embodiment, a new spectrum vector is obtained by weighted summation based on each reference spectrum vector and the corresponding distance weight.

[0115] Specifically, several reference spectral vectors that are most similar to the pixels in the shadow area have been found from the non-shadow area, and their spectral vectors are And the distances d1, d2, ..., d between the shadow pixels and these samples have been calculated. n . Then the new spectral vector of the shaded area is for:

[0116]

[0117] S64. Generate new spectral data according to the new spectral vector.

[0118] In this embodiment, since each parameter in the new spectrum vector is the spectrum reflectance data of the corresponding pixel, which includes reflectance values ​​at different wavelengths, the corresponding new spectrum data can be obtained directly from the parameters in the new spectrum vector.

[0119] See also Figure 7 , Figure 7 This is a block diagram of a system for removing mountain shadows in optical remote sensing images provided by the present invention. Figure 7 As shown, the removal system includes: a shadow area determination module 11 , a spectrum library establishment module 12 , a reference spectrum acquisition module 13 and a shadow area processing module 14 .

[0120] In this embodiment, the shadow area determination module 11 is used to obtain an optical remote sensing image within a preset area, and determine a shadow area and a non-shadow area in the optical remote sensing image according to spectral data of different bands.

[0121] In this embodiment, the spectrum library building module 12 is used to obtain first spectrum data of various types of ground objects in the non-shadow area and build a spectrum library in the non-shadow area.

[0122] In this embodiment, the reference spectrum acquisition module 13 is used to acquire, according to the similarity between the second spectrum data of each pixel in the shadow area and the first spectrum data in the non-shadow area spectrum library, the first spectrum data whose similarity with the second spectrum data meets the preset requirements in the non-shadow area spectrum library as the reference spectrum data.

[0123] In this embodiment, the shadow area processing module 14 is used to generate new spectral data corresponding to the second spectral data of each pixel in the shadow area based on the reference spectral data; and generate a new shadow area according to the new spectral data; merge the new shadow area and the non-shadow area to obtain a shadow-free remote sensing image.

[0124] In this embodiment, the removal system also includes: a standardization processing module, which is used to construct a first spectral vector based on the first spectral data; construct a second spectral vector based on the second spectral data of each pixel in the shadow area; calculate the mean and standard deviation of the first spectral data in the non-shadow area spectral library; and standardize the first spectral vector and the second spectral vector based on the mean and standard deviation.

[0125] In this embodiment, the reference spectrum acquisition module 13 is specifically used to calculate the similarity between each second spectrum vector and each first spectrum vector; for each second spectrum vector, in each first spectrum vector, determine the first spectrum vector whose similarity with the second spectrum vector meets the preset similarity requirement; and use the first spectrum data corresponding to the first spectrum vector whose similarity meets the preset similarity requirement as the reference spectrum data.

[0126] In this embodiment, the reference spectrum acquisition module 13 is specifically used to calculate the Mahalanobis distance between each second spectrum vector and each first spectrum vector as the similarity.

[0127] In this embodiment, the shadow area processing module 14 is specifically used to perform weighted summation of the similarity between the second spectrum data and each reference spectrum data and each reference spectrum data for the second spectrum data of each pixel, so as to generate new spectrum data corresponding to the second spectrum data.

[0128] In this embodiment, the shadow area processing module 14 is specifically used to construct a reference spectrum vector based on the reference spectrum data; calculate the distance weight of each reference spectrum vector based on the Mahalanobis distance between the second spectrum vector and the corresponding reference spectrum vector; perform weighted summation of each reference spectrum vector and the distance weight to obtain a new spectrum vector; and generate new spectrum data based on the new spectrum vector.

[0129] In this embodiment, the removal system further includes: a spectrum optimization module, which is used to optimize the brightness value of the shadow area through a terrain correction algorithm, and to optimize the contrast and image details of the shadow area through a wavelet transform algorithm.

[0130] In this embodiment, the spectral optimization module is specifically used to obtain the solar zenith angle and solar incidence angle of the shadow area by presetting the digital elevation model of the mountain area and the position of the shadow area; based on the Minnaert terrain correction algorithm, the brightness of each position of the shadow area is optimized by the Minnaert constant corresponding to the solar zenith angle, solar incidence angle and ground reflection characteristics, and the shadow area with optimized brightness value, contrast and image details is generated.

[0131] In this embodiment, the spectral optimization module is specifically used to process the shadow area through the wavelet transform algorithm to obtain the low-frequency subband and the high-frequency subband of the shadow area; adjust the contrast of the low-frequency subband by the minimum value of the low-frequency subband for maintaining the baseline of the image brightness; enhance the image details of the high-frequency subband by the average value of the high-frequency subband for stabilizing detail enhancement; and generate a shadow image processed by the wavelet transform algorithm based on the adjusted low-frequency subband and the enhanced high-frequency subband.

[0132] like Figure 8 As shown, an embodiment of the present invention provides an electronic device, including a processor 1110, a communication interface 1120, a memory 1130 and a communication bus 1140, wherein the processor 1110, the communication interface 1120, and the memory 1130 communicate with each other through the communication bus 1140;

[0133] Memory 1130, used for storing computer programs;

[0134] The processor 1110 is used to implement any of the above removal methods when executing the program stored in the memory 1130.

[0135] In the electronic device provided by the embodiment of the present invention, the processor 1110 obtains an optical remote sensing image in a preset area by executing a program stored in the memory 1130, determines the shadow area and non-shadow area in the optical remote sensing image according to the spectral data of different bands; obtains first spectral data of various types of ground objects in the non-shadow area, and establishes a spectral library of the non-shadow area; according to the similarity between the second spectral data of each pixel in the shadow area and the first spectral data in the spectral library of the non-shadow area, obtains the first spectral data whose similarity with the second spectral data meets the preset requirements in the spectral library of the non-shadow area as reference spectral data; based on the reference spectral data, generates new spectral data corresponding to the second spectral data of each pixel in the shadow area respectively; and generates a new shadow area according to the new spectral data; merges the new shadow area and the non-shadow area to obtain a remote sensing image without shadow.

[0136] The communication bus 1140 mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus 1140 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.

[0137] The communication interface 1120 is used for communication between the above electronic device and other devices.

[0138] The memory 1130 may include a random access memory 1130 (RAM), or may include a non-volatile memory 1130 (non-volatile memory), such as at least one disk memory 1130. Optionally, the memory 1130 may also be at least one storage device located away from the processor 1110.

[0139] The above-mentioned processor 1110 can be a general-purpose processor 1110, including a central processing unit 1110 (CPU), a network processor 1110 (NP), etc.; it can also be a digital signal processor 1110 (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.

[0140] An embodiment of the present invention provides a computer-readable storage medium, which stores one or more programs. The one or more programs can be executed by one or more processors 1110 to implement the removal method of any of the above embodiments.

[0141] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function according to the embodiment of the present invention is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, a computer, a server or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or a data center that includes one or more available media integrated. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk SolidStateDisk (SSD)), etc.

[0142] Although the present disclosure has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present disclosure.

Claims

1. A method for removing mountain shadows in optical remote sensing images, characterized in that: The method comprises: Acquire an optical remote sensing image within a preset area, and determine a shadow area and a non-shadow area in the optical remote sensing image according to spectral data of different bands; Acquire first spectral data of various types of ground objects in the non-shadow area, and establish a non-shadow area spectral library; According to the similarity between the second spectrum data of each pixel in the shadow area and the first spectrum data in the non-shadow area spectrum library, first spectrum data whose similarity with the second spectrum data meets a preset requirement is obtained in the non-shadow area spectrum library as reference spectrum data; Based on the reference spectral data, new spectral data corresponding to the second spectral data of each pixel in the shadow area are respectively generated; and a new shadow area is generated according to the new spectral data; and the new shadow area and the non-shadow area are merged to obtain a shadow-free remote sensing image.

2. The removal method according to claim 1, characterized in that: After the non-shadow region spectral library is established, the method further comprises: Constructing a first spectral vector according to the first spectral data; constructing a second spectral vector according to the second spectral data of each pixel in the shadow area; Calculating the mean and standard deviation of the first spectrum data in the non-shadow area spectrum library; The first spectral vector and the second spectral vector are standardized based on the mean and the standard deviation.

3. The removal method according to claim 2, characterized in that: The method of obtaining, according to the similarity between the second spectral data of each pixel in the shadow area and the first spectral data in the non-shadow area spectral library, first spectral data having a similarity to the second spectral data that meets a preset requirement in the non-shadow area spectral library as reference spectral data, comprises: Calculating the similarity between each of the second spectrum vectors and each of the first spectrum vectors; For each of the second spectral vectors, in each of the first spectral vectors, a first spectral vector whose similarity to the second spectral vector meets a preset similarity requirement is determined; and the first spectral data corresponding to the first spectral vector whose similarity meets the preset similarity requirement is used as the reference spectral data.

4. The removal method according to claim 3, characterized in that: The calculating the similarity between each of the second spectral vectors and each of the first spectral vectors includes: The Mahalanobis distance between each of the second spectral vectors and each of the first spectral vectors is calculated as the similarity.

5. The removal method according to claim 4, characterized in that: The step of generating new spectral data corresponding to the second spectral data of each pixel in the shadow area based on the reference spectral data comprises: For the second spectrum data of each pixel, a weighted sum is performed on the similarity between the second spectrum data and each reference spectrum data and each reference spectrum data to generate new spectrum data corresponding to the second spectrum data.

6. The removal method according to claim 5, characterized in that: The step of performing weighted summation of the similarities between the second spectral data and each of the reference spectral data and each of the reference spectral data to generate new spectral data corresponding to the second spectral data includes: Constructing a reference spectrum vector according to the reference spectrum data; Calculating the distance weight of each reference spectrum vector according to the Mahalanobis distance between the second spectrum vector and the corresponding reference spectrum vector; A new spectrum vector is obtained by weighted summing up each of the reference spectrum vectors and the distance weights; The new spectral data is generated according to the new spectral vector.

7. The removal method according to any one of claims 1 to 6, characterized in that: After determining the shadow area and the non-shadow area in the optical remote sensing image according to the spectral data of different wavebands, the removal method further comprises: The brightness value of the shadow area is optimized by a terrain correction algorithm, and the contrast and image details of the shadow area are optimized by a wavelet transform algorithm.

8. A system for removing mountain shadows in optical remote sensing images, characterized in that: The removal system comprises: A shadow area determination module is used to obtain an optical remote sensing image within a preset area, and determine a shadow area and a non-shadow area in the optical remote sensing image according to spectral data of different bands; A spectrum library building module, used for acquiring first spectrum data of various types of ground objects in the non-shadow area and building a spectrum library in the non-shadow area; a reference spectrum acquisition module, configured to acquire, according to the similarity between the second spectrum data of each pixel in the shadow area and the first spectrum data in the non-shadow area spectrum library, first spectrum data whose similarity with the second spectrum data meets preset requirements in the non-shadow area spectrum library as reference spectrum data; The shadow area processing module is used to generate new spectral data corresponding to the second spectral data of each pixel in the shadow area based on the reference spectral data; generate a new shadow area according to the new spectral data; and merge the new shadow area with the non-shadow area to obtain a shadow-free remote sensing image.

9. An electronic device, characterized in that: include: processor; as well as A memory storing computer executable instructions which, when executed, cause the processor to perform the method according to any one of claims 1-7.

10. A computer storage medium, characterized in that: in, The computer storage medium stores one or more programs, and when the one or more programs are executed by a processor, the method of any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Method for recovering spectral information of hill shade area of Landsat thematic mapper / enhanced thematic mapper plus (TM / ETM+) image

    CN102622738A

  • Remote sensing image shadow removal method and device and storage medium

    CN117522746A

  • Satellite Image Sequence Cloud Region Repairing Method and Apparatus

    US20230094679A1

  • AU2012100257A4

Cited By

  • Orthoimage mosaic method and system suitable for remote sensing image

    CN120047327A

  • Orthorectified Image Mosaicking Method and System Applicable to Remote Sensing Images

    CN120047327B

  • Remote sensing surveying and mapping target automatic identification method and system adopting deep learning and application

    CN121095768A