Long length detailed explanation of radio calibration, atmospheric correction, supervised classification, mask statistics, vegetation coverage operation
1. Preamble
The Landsat satellite is a remote sensing data source most frequently contacted by remote sensing beginners and even remote sensing practitioners and related research scholars. Today we will learn some related operations of ENVI through an example.
1.1 Introduction to the experiment area
When you browse Google Earth or Google Maps, have you noticed that the satellite imagery of northern Shaanxi will have an obvious outline feature like the one above. This sharply defined area is Wuqi County in Shaanxi, as shown below:
In 1998, Wuqi was a crucial year for Wuqi: this year, the county was the first country to start the exploration of returning farmland to forests in the whole country. Within the scope of the policy of "closing mountains, prohibiting grazing and raising livestock in houses", an ecological environment construction aimed at changing the living environment was launched vigorously in Wuqi County. In the past 20 years, Wu Qi has accumulatively converted 2,437,900 acres of farmland into forests, and has become the first county in the country to return farmland to forests because of the earliest seal, fastest return, and largest area. The clearly visible outline on this satellite image is a testimony of people's transformation of nature.
1.2 Data query selection
First open ArcMAP, load county-level zoning vectors across the country, use the attribute search function to select Wuqi County:
this way Wuqi County is selected, and then right-click to export the selected Wuqi County's zoning as a single SHP file:
then load Landsat's PATH and ROW The vector file, marked PATH and ROW:
We can know that covering Wuqi County requires 128,034 and 128,035 Landsat data:
Next we can set the frame coordinate system of the current view to UTM-48N:
open the edit, draw a better than Wu Qi large county rectangle, as our study area (because we needed outside Wuqi County and the county part of the data to make comparison, so we did not use zoning vector Wuqi), and then export the rectangle as a new SHP file:
access Down to enter the USGS query data, USGS can import the SHP file in the study area, compress the SHP file into a ZIP file can be imported:
Next, select the satellite query, the data we selected this time is May 19, 1997 Landsat5 and Landsat8 on June 14, 2018. When USGS queries data, you can first check whether the selected data is ideal through textures, such as cloud amount:
Second, pretreatment
Let's take the two scenes in 2018 as an example to introduce the general preprocessing process, which involves data cutting, radiation calibration, mask use, atmospheric correction and other operations. First open the ENVI software to open the data. The conventional method is to use OpenAs to find the Landsat satellite: the
lazy method is to drag and drop the MTL.txt file in the decompressed folder directly into the ENVI window: do
n’t use the Laystack tool to privately use these. Combining the bands is not only laborious, but also the combined files do not carry the calibration parameters, so they cannot be followed up.
2.1 Radiation calibration
The conventional method is generally to calibrate the entire scene data, but in this case, if the study area is relatively small, it will increase the amount of data and the running time, so we can first crop and then perform radiation calibration.
Cutting the time needed to MASK option is set to YES, this is based on the actual shape of the cut, the default is NO crop bounding rectangle
clipping complete data, calibration parameters are, we can be assured of a radiometric calibration:
Next, Perform the radiation calibration operation on the cropped data. Remember to choose Aplly FLAASH Settings. The output path should be as little as possible in Chinese:
Next, we also perform the radiation calibration operation on the other scene data above. In fact, there is one in the radiation calibration tool. For the cropping option, we can do cropping and radiation calibration together:
2.2 Mask statistics
After radiation calibration, FLAASH atmospheric correction is generally performed. Because the atmospheric correction option has an average elevation option, we interspersed into a mask statistics step. The ENVI installation directory comes with a global DEM data with a resolution of 900 meters. If you do n’t want to download DEM, you can use this to perform mask statistical average elevation.
First open the data, click the statistical tool in the toolbox, select Build MASK in the MASK option, when defining the MASK, you can choose to import the ROI that we draw yourself as shown below:
You can also choose the SHP file of our study area:
import After ROI or SHP, you can perform mask statistics: the
following figure is the result of mask statistics. The average elevation is about 1500 meters, which is actually similar to Baidu's results:
2.3 Atmospheric correction
For different shooting times, the data of different bands need to be individually calibrated for atmospheric correction after radiation calibration. For the data of the upper and lower scenes shot on the same day on the same band, because the shooting time interval of the two scenes is generally short, the atmospheric conditions are almost the same. It can be spliced before atmospheric correction.
2.3.1 Single scene atmospheric correction
Let's first introduce single scene atmospheric correction. The input and output paths of FLAASH atmospheric correction are as concise as possible. The short path does not include Chinese. If the average elevation is in KM, the elevation we just counted is 1500 meters, so Fill in 1.5KM here, open the MTL file in the flight time notepad or writing board, and there is the scene center time. In addition, do n’t forget to choose KT:
block processing is also best to turn off, it is not easy to report errors:
then use the same for another scene operating.
To view the spectral curve after atmospheric correction, we can insert a new view. View 1 opens the data before atmospheric correction, and View 2 opens the data after atmospheric correction:
zoom in to find a vegetation area, click the cursor tool, and copy the GEO coordinates:
Paste the copied GEO coordinates into the search window, and click the spectral curve button to display the spectral curve at this coordinate point:
perform the same operation on another view, so that the spectral curves before and after atmospheric correction are displayed separately:
2.3.2 Atmospheric correction after splicing
The data involved this time is the same scene with two scenes taken on the same day. We can first stitch the data after radiation calibration and then correct the atmosphere. Since the data of the upper and lower scenes in this area are cross-banded, one is 48 and the other is 49. Re-projection is required before stitching. This time we choose 48 bands, so we need to re-project the data of 128034 to UTM 48N:
open the re-projection tool The output coordinate system is set as follows:
After reprojection, the data type of the radiation calibration is changed from the original BIL to BSQ, so we also need to convert the data type, because the input data type of FLAASH atmospheric correction is BIL:
For two When the data is superimposed with a black background, such as the following figure, you need to edit the header file first and add the ignore background value:
for the error in editing the header file, you can enter the classic mode so that you will not get an error:
ignore the background value after the two The data is superimposed normally:
start the mosaic tool to splice, you can generate a splicing line:
edit the splicing line, try to draw the splicing line along the linear feature:
the data shot on the same day do not select the histogram to match:
the result after mosaic:
next Atmospheric correction is performed, and the parameters are filled in similarly to the previous article, except where the flight time is, which scene accounts for the proportion To fill a larger view of that flight time.
3. Supervision classification
The data can be supervised and classified. For visual selection of samples, we need to select the most suitable combination method for visual interpretation. The following figure shows the display effect of different band combinations of Landsat8 data in this area:
this time we choose 654 combination selection The samples can of course also be switched to other combinations for interpretation at any time:
Combined with the natural conditions of the field, we have selected seven categories of forest land, slope farmland, irrigated land, grassland, waters, residential land and bare land for supervised classification.
The data was taken on June 14th, and the growth of the forest land is shown as bright green under the combination of 654:
Since northern Shaanxi entered the rainy season in July and August, there is basically no effective irrigation on the slope farmland, so the crop growth of the slope farmland in June It is still very weak, shown in red: the
flat land with irrigated conditions is named as watered land, showing distinctive characteristics of cultivated land texture, bright green color:
Perhaps the most headache for everyone to do supervised classification is the selection of grassland samples, big cities Better still, there are some parks and the like, or the typical grassland areas of northwest, southwest, and Qinghai-Tibet, but in other areas where the distribution of grassland is not prominent, the grassland is really difficult to choose, and the grassland will be scattered on some beaches and riversides In these places, grassland does not have the typical texture of cultivated land:
water samples:
residential land samples:
bare land samples:
this time, more than 15 samples of each category were selected to ensure uniform distribution, and then the separability was calculated, and the separability was 1.8 The above is good:
adopt the SVM classification method:
4. Inversion of vegetation coverage
In this chapter, we talk about the vegetation coverage inversion operation, which requires the results of NDVI and supervised classification.
4.1 Calculating NDVI
There are two ways to calculate NDVI, one is to use BandMath, the other is to use NDVI tool, no matter which method you need to choose the right band:
the results of these two methods are the same: the
calculated NDVI needs to be counted If there are any outliers, if there are outliers, you can enter the formula in the band operation: b1> -1 <1 to remove the outliers. For the statistics of the irregular research area, please refer to the previous method of statistical DEM. Only the statistics of the area of the research area are masked. To exclude the influence of background.
4.2 Build mask
In this step, we need to use the results of the previous supervised classification to make each category as a mask file. First open ApplyMask, choose NDVI as the reference image, select BuildMask option, first constructed woodland mask are:
importing data when the result of the selection mask supervised classification:
forest land is 1, so we are here to range from 1:
access Build it down in order. The masks for slope farmland, watered land, grassland, residential area, and bare land are similar to the above, except that the range of values requires special attention, not to be confused:
4.3 NDVI maximum and minimum statistics
Next, use the statistical tool to count the NDVI interval of each land type. First, the NDVI range of the forest land is counted: to
determine the maximum value and the minimum value, you can choose the inflection point of the histogram, or you can choose the confidence interval of 2% -98% level, or you can Select the mutation of the statistical value, for example, the statistical value suddenly changes from three digits to four digits or from two digits to three digits: the
following figure is the statistical results of each land type
4.4 Calculation of vegetation coverage
First calculate NDVIsoil, enter the formula: b1 0.5406 + b2 0.1914 + b3 0.4151 + b4 0.4638 + b6 0.0331 + b7 0.077
and then calculate NDVIveg, the same way, enter the formula: b1 0.8912 + b2 0.6951 + b3 0.6992 + b4 0.7124 + b6 0.5713+ b7 0.4096
Finally calculate the vegetation coverage
. Remove the outliers for the vegetation coverage results: b1> 0 <1, so that the outliers and Inf in the water can be removed:
V. Data display
The above describes the operation process we carried out on the 2018 data of the research area. The same method was used to perform the same operation on the 1997 data to obtain two phases of data results.
We separately extracted the forest land for the two periods of supervised classification data, and input b1 eq 1 to the band operation to extract the forest land:
use the New color slice option to color render the extracted forest land and superimpose the administrative area, which can be clearly seen Over the past 20 years, the forest land expansion in Wuqi County:
Mask statistics can also be used for area statistics, which will not be explained again this time.
It is also possible to import GIS mapping. We take vegetation coverage as an example to import GIS operations:
First, Save as TIF file under File in ENVI, and then use Arcmap to load,
click the classification in the symbol system, set to a unified break:
For the first time to open the TIF file, prompt to calculate histogram must select YES, so that the image can be displayed normally:
select Ribbon, add annotations:
switch layout views, insert data frames, insert legends, north arrows, etc .: just
export the map:
Okay, here is the introduction today, if you are interested, you can pay attention to it, blog home page:
https: // blog .csdn.net / qq_46071146
More good articles: