5.2 Dealing with cloud in MERIS L2 data |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Using MERIS class flags Using confidence flags to refine selection |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
References:
Downloads: Images: MER_RR_2COLRA 200402~.N1 Description
|
Atmospheric correction of MERIS (and other optical satellite data) starts with an algorithm that identifies pixels containing cloud. This processing step generally identifies cloudy pixels based on their brightness, and raises a CLOUD flag, which may be used during the L2 processing in order to mask clouds. Whilst it is easy to identify pixels that are fully cloud covered, partial cloud cover represents more of a problem. Edges of clouds, scattered small clouds and low level fog may be harder to identify, and L2 data sometimes contain sub-pixel cloud that has not been identified by the cloud-flagging algorithm. This causes problems for algorithms that rely on spectral ratios to calculate chlorophyll concentrations. I this section you will look at this problem in MERIS L2 data from the Benguela upwelling, and investigate ways of overcoming the problem of sub-pixel cloud that has not been flagged by the cloud-flagging routine. Activity:
As you can see, the image contains not just water pixels showing chlorophyll concentrations; there are also cloud pixels showing cloud top pressure, and land pixels with the top of atmosphere vegetation index (TOAVI). Along both edges are strips where no radiance samples were available to fill the MERIS product grid. Using MERIS class flagsTo produce a gridded image with valid chlorophyll concentrations the contributing scenes must contain only valid data. All other pixels must be masked. The class flags provided with the image data contain the information you need for this task.
The l2_flags text file is a list of named flags, each followed by a number. The numbers will allow you to use the l2_flags data set to mask all pixels containing unwanted data. 'MERIS level 2 flags' gives you a more detailed description of these flags and what they mean, along with the binary code of each flag. The flags data set contains all the flags related to the different geophysical data sets in the 'Bands' folder. Several pixels have been given more than one flag. This is the case for instance with pixels given the flag value 3655697. The key to the flags are in the binary version of this number.
Question 1.
The flag codes may be used to make a bitmask to remove invalid data from the algal_1 image. For instance, only pixels classified as water are of interest in a gridded image of chlorophyll concentrations, and the WATER flag allows you to select these pixels.
Activity: Using a class flag to select valid data
The formula follows the standard Bilko pattern (see figure (5K)). for details). Question 2.
if ((l2_flags&WATER)==WATER)
Note:
In the table above WATER = 2097152, a number where only one position (bit 21) has the value 1.
The pixel's FLAG VALUE = 4196353, which has 1 in three different bit positions,
each corresponding to a particular flag. If you are still unsure how to tackle this,
'Bitwise operators and Envisat flags'
explains. Having seen how the formula works, you wil now apply it to create a new image containing only water pixels.
Notice how the blank image is filled with data where the WATER flag holds true, while remaining pixels are white (255). The white pixels are those that have been classified as either land or cloud. Save the output as mer_20040201_a1w.dat before you continue. Using confidence flags to refine selectionYou'll probably also have noticed a number of dark pixels, most of which are near the edge of clouds, or associated with cloud in some other way. If you zoom in (double click on the image) you can read the value of some of these pixels on the status bar; the majority of these have been given the value 0 (black). These are pixels where the atmospheric correction failed, probably due to sub-pixel cloud; so the 0 here represents non-valid data, not water with no chlorophyll. There are also many scattered pixels that appear darker than their surroundings; their pattern follows the lines of the cloud bands, so we can assume that they also contain sub-pixel cloud. If these pixels were sufficiently anomalous to case problems for the aerosol correction, they would be accompanied by a confidence flag. A MERIS Confidence flag relates to the quality of the geophysical data in the pixel that contains the flag. Unlike class flags, which are mutually exclusive, confidence and science flags may be used in combination with each other and with the class flags. Often the conditions that give rise to one flag are also likely to trigger others. During processing from Level 1 (top of atmosphere radiances) to Level 2 (geophysical data) confidence flags are raised when
You can use confidence flags to modify the bitmask formula used to select valid pixels. For example, if the aerosol correction triggered a confidence flag for pixels containing scattered cloud, this flag may be used to mask the dark pixels you see in this algal_1 image.
Copy and paste the new formula to the stack and watch what happens to the image. Once you are sure the formula has worked, save it as mer2water_a1a.frm, and save a copy of the masked image created by the formula as mer_20040201_a1a.dat.
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Answers: |
In some cases applying the PCD_1_13 confidence flag may remove data of interest to a particular study. In the next section with we shall look at some alternative strategies to the most rigorous application of this flag. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|