Global Mapper v25.0

Converting USGS National Land Cover Data from ERDAS to Imagine to and ESRI Format

gregleon
gregleon Global Mapper UserTrusted User
edited August 2012 in Technical Support
I am trying to convert/tile and reproject the 2006 USGS NLCD which is in a ERDAS IMG format to ASCII GRID if possible. Any suggestions? Also, I want to grid into 1 square degree tiles if possible, this is done in the gridding dialog for rows/columns?
Thanks
Greg

Comments

  • global_mapper
    global_mapper Administrator
    edited July 2012
    Greg,

    If the IMG files are coming in as grids and not images, just use the File->Export Elevation DAta menu command to export to Arc ASCII Grid files. Use the Gridding tab of the export dialog to split into tiles of your required size.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Guru
    gmsupport@bluemarblegeo.com
    http://www.globalmapper.com
  • gregleon
    gregleon Global Mapper User Trusted User
    edited July 2012
    The IMG file appears to be a raster file, there is an associated IGE file that contains all of the actual data. Each pixel corresponds to a 30m bin that has a land use code( RGB Value - Pal IdX # and Land Use Name), so when I move on the map, the status bar on the bottom is telling me what land use type I am in. Basically I want to put the Pal Idx #( which correlates to a land use type) in an asci grid file. Is there a way to take this raster file and get into a Grid type format?
    Greg
  • global_mapper
    global_mapper Administrator
    edited July 2012
    Greg,

    Can you change the palette to be a grayscale one, so that palette index 0 is RGB(0,0,0), palette index 1 is RGB(1,1,1), etc? You can do this on the Palette tab of the Options dialog for the layer. Then use File->Export Raster Data to export a BIL file that is an 8-bit grayscale file. You can then load that BIL back in and you will be prompted to treat it as elevation or imagery. Select elevation, then you will have a grid that you can export to Arc ASCII Grid.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Guru
    gmsupport@bluemarblegeo.com
    http://www.globalmapper.com
  • gregleon
    gregleon Global Mapper User Trusted User
    edited July 2012
    I did as you recommended and it works great, Thanks!

    Two Questions question: Is there a straight forward way to re-grid upon export in lat/long square degree tiles? I noticed the ability to set export bounds, but this would require me to do each individual tile manually. I am trying to do this in one batch export. I can't seem to work out the regridding option( rows, columns or other) that would result in straightforward square degree tiles( 34.0 to 35.0N, -117.0 to -118.0)
  • global_mapper
    global_mapper Administrator
    edited July 2012
    If you set your projection to Geographic (if it's not already) on the Projection tab of the Configuration dialog, then do the export and set the Export Bounds to start on an exact degree boundary and end on an exact degree boundary, then on the Gridding tab specify to make the rows and columns 1 degree in size, that should work.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Guru
    gmsupport@bluemarblegeo.com
    http://www.globalmapper.com
  • gregleon
    gregleon Global Mapper User Trusted User
    edited July 2012
    Mike -
    I had one wrinkle in the conversion that is stumping me. The output ascii grid has a mix of integers and float values. I assumed this is caused by the step of repaletting/exporting to bil/importing bil to elevation grid in message #4 above. There were actually 99 ids in the original img file, but only 25 of those were assigned colors, land use types. So my first id in the source file was id# 21, I made this (1,1,1) and then #31 which I made (2,2,2)...etc up to (25,25,25). Is there an obvious step where I could have introduced the float values?
    Greg
  • global_mapper
    global_mapper Administrator
    edited July 2012
    Greg,

    Make sure to disable resampling for the files before you export. By default gridded files will use bilinear interpolation, so if any export samples aren't right on a sample center you will get an interpolated value, which could be non-integer. You definitely don't want resampling for this type of file.

    Thanks,

    Mike
    Global Mapper Guru
    gmsupport@bluemarblegeo.com
    http://www.globalmapper.com
  • gregleon
    gregleon Global Mapper User Trusted User
    edited July 2012
    Thanks - one more wrinkle, I did the img to bil export and turned of resampling, now when I import the bil back in, it does not give me the option to treat as elevation or raster file...any ideas...?
  • global_mapper
    global_mapper Administrator
    edited July 2012
    Did you make sure to export the BIL as a grayscale file? The BIL has to be an 8-bit BIL to get the prompt for elevation or imagery. If you created say a 24-bit RGB BIL then it would be assumed as imagery.

    Thanks,

    Mike
    Global Mapper Guru
    gmsupport@bluemarblegeo.com
    http://www.globalmapper.com
  • gregleon
    gregleon Global Mapper User Trusted User
    edited August 2012
    Mike -
    I have finally had some time to spend working on this again. I am able to get an import from bil via elevation however, it seems the elevation import is creating some artificial interpolation...like it is trying create a higher than 30m resolution elevation database...it is really obvious on the areas in rural areas where it is agricultural and then impervious surface where the road is....it looks like the elevation import is creating a canyon where the street is (it has a lower 8 bit value than the agricultural coding when I did the re-palleting) and interpolating. Is there a setup for elevation import where I can specify it to not interpolate like this?
  • global_mapper
    global_mapper Administrator
    edited August 2012
    By default elevation layers will be interpolated, which you don't want if the "elevations" are really land cover codes. You can turn this off on the Options dialog for the layer. Just set the resampling to 'Nearest Neighbor' (no resampling).

    Thanks,

    Mike
    Global Mapper Guru
    gmsupport@bluemarblegeo.com
    http://www.globalmapper.com