Go to the USGS Home Page

USGS MIPS Sidescan Sonar Automatic Nadir Fix Procedure






The procedure outlined below identifies methods that can be used to select various parameters needed by the Nadir Fix/Nadir Improve portion of the USGS MIPS sidescan sonar processing package. It was developed to allow the user to process sidescan sonar image data in a more automatic fashion, especially while at sea. However, it can also be part of the full on-shore processing flow used to generate a final digital mosaic product. The procedure's objective is to subdue the blocky and high contrast appearance of the nadir area relative to the rest of the sidescan image. This is done by extracting a subset of pixels around nadir and automatically identifying pixels that are the most blocky and have a high contrast with their surrounding local neighborhood. These pixels are set to zero DN and 'filled in' using a smoothing/averaging procedure that affects only pixels with zero dns (i.e., leaves the rest/majority of the nadir pixels alone). The general sequence is:

     1. EXTRACT the nadir portion from the sidescan image.
     2. HIGH PASS FILTER (HPF) the nadir image with a very small
        local window.
     3. STENCIL/SET TO ZERO DN pixels in the nadir image that have
        large HPF values.
     4. FILL IN the zero dn pixels.
     5. INSERT fixed/improved nadir portion back into the sidescan image
To accomplish this automatically a method to select the various parameters for each of the programs involved based on the size of the image has been developed. The image size/number of samples of the input sidescan image, which is affected by the resolution selected in the program SLR2GR, is used. A detailed description of each of the five steps is given below.

1. NADIR EXTRACTION:
This step extracts the portion of the sidescan image that is to be consider the 'nadir' area that needs to be fixed/improved. What needs to be identifed automatically for this step is what part of the image should be extracted as the nadir image. The number of samples and the starting sample to be used to extract the nadir portion of the image for processing is computed by using the total number of samples of the input sidescan image. The number of samples and starting samples to be used to extract the nadir image can be computed as follows:

     NDRNS  =  2 * (NS * 0.027)
            =  (0.054 * NS)

      NDRNS = Number of Samples to extract as nadir
      NS    = Number of Samples of input image
      0.027 = 2.7% of input image size
              times 2 due to plus and minus pixels about nadir
 
      SS    =  NS/2 - NDRNS/2

      SS    = Starting Sample for nadir extraction

      NSOUT =  NDRNS

      NSOUT =  Number of Samples Out/to extract
2. HIGH PASS FILTER (HPF) SIZE SELECTION:
The extracted nadir portion/image now has to have a small HPF applied. The paramter that needs to be identified automatically in this step is the size of the HPF. The purpose of the filter is to enhance the very high frequencies within the nadir image, therefore, the size of nadir (which is based on the size of the input image) is used to identify what a high frequency is within the nadir image. A filter size that is about 10% of the nadir image generally gives good results:

     HPF SIZE NL and NS  =  0.1 * NDRNS + [1] or [2]
                            plus 1 or 2 should be used, as 
                            needed, to make the value odd; 
                            always round up to the nearest 
                            larger odd integer (e.g., 10.1 and 
                            10.9 both become 11 by 11 and 11.2 
                            should be 13 by 13 --- note, the
                            difference between 11 and 13 will
                            hardly be noticeable).  By using
                            the equation above for NDRNS 

     NL and NS  =  0.0054 * NS + [1] or [2] as needed
3. STENCIL MIN/MAX SELECTION:
The HPF results are now used to set pixels in the nadir image to zero dn based on the values of the HPF image (the program STENCIL is used to do this). Basically what we are doing here is identifying pixels in the nadir image that are very busy/blocky and/or have a high contrast with their local neighborhood. To do this in an automatic fashion we must 'look' at the histogram of the HPF image and identify/select the dn values that represent extreme values. The program PICSTR can be used to do this by setting the MIN and MAX at the desired percentage values. In general, by smoothing pixels that have HPF values that fall in the plus and minus 10% of the extreme edges gives acceptable results. MIN and MAX will be equal to the DN values that correspond to these percentages on the histogram/PICSTR print file:

      MIN  =  10% dn value
      MAX  =  90% dn value
This will smooth 20% of the pixels and leave 80% unchanged/with their original values. The MIN and MAX values determines the amount of smoothing that is applied, so changing them up or down will change the amount of smoothing that is done (i.e., 5% and 95% dn values will smooth less and 15% and 85% will smooth more).

The PICSTR program can be used on every image strip to identify the MIN and MAX values for the given image. However, this means that each image strip will have it own definition of what is blocky. If a constant definition is desired a MIN and MAX value can be selected by 'looking' at a few strips and then using the selected values for the rest of the strips collected during the same cruise. For example, if MIN and MAX values of 102 and 151 are selected, respectively, they could be used for the processing of the entire cruise data. This removes the need to use PICSTR for each strip and, more important, uses the same values everywhere/ for every image. Of course, the danger is that the MIN and MAX values selected early on may not be good ones for the strips collected later in the cruise; if so, new MIN and MAX values for the remainder of the cruise may have to be selected at that stage.

4. FILL IN THE HOLES/LPFZ:
This step is used to 'fill' in the zero dn holes generated by the stenciling done in step three. The program FILTER has an option called Low Pass Filter Zeroes (LPFZ --- the Z is very important for what we want to do). This spatial filtering option allows us to apply a low pass/smoothing filter affecting ONLY pixels with zero dn values. It uses only pixels with non-zero dn values to compute an average of the window being used and replaces the dn values of only pixels that have a dn value of zero (i.e., the holes created in the stenciling process). Besides using the Z option it is very important to set LOW equal to 1; this makes zero an invalid value so that they are not used to compute the average but are the only ones replaced. To do the filling gradually and ensure that all the holes get filled two LPFZs are applied:

     FILTER/LPFZ Number 1 (input file is nadir stenciled image)

     NL and NS  =  3
     LOW        =  1


     FILTER/LPFZ Number 2 (input file is LPFZ number 1 results)

     NL and NS  =  5
     LOW        =  1
5. INSERT the fixed/improved nadir image back into the sidescan sonar image:
This step inserts back into the sidescan sonar image the fixed/ improved nadir portion. The program DIGMOS is used with the same Starting Sample (SS) and Nadir NS (NDRNS) parameters used/ identified in step one (DIGMOS only needs to know SS because it automatically drops the entire nadir image back into the full image).

Keep in mind that this procedure/sequence of processing is designed for strip processing of large volumes of data in an AUTOMATIC mode. There will be times when improvements can be made over the auto- matically selected parameters (i.e., they will probably not be the 'best' values for every image). However, the automatically selected values should generally improve the blocky and high contrast appearance of the nadir portion in most images. The results may look to smoothed when the digital image is viewed interactively at a relatively large scale, but when hardcopy prints are made at typical scales the smooth appearance will often be difficult to see. Remember that the sequence shown here is the same one used in generating the 'best' on-shore type product, but the parameters are selected more interactively, rather than automatically.


Back to USGS MIPS Procedures

Author: Pat Chavez

U.S. Department of the Interior | U.S. Geological Survey | Jobs
Home | Search | Disclaimers & Privacy Web Rings
Send comments to webman@TerraWeb.wr.usgs.gov
URL:
Last Modified: Thu Oct 31 15:08:23 MST 2002
FirstGov: Your First Click to the U.S. Gov ernment