Select to view content in your preferred language

trouble with pixel depth and type

726
1
01-10-2013 06:54 AM
KatSuda
Emerging Contributor
I am working with unsigned 8-bit satellite images, processing and compositing them in various combinations.  I have several questions about pixel depth.

1.  I have read up on pixel depth and NoData values.  The help files say:

[INDENT]When NoData is added to a geodatabase raster (not in ArcSDE) that already has a full-bit range (meaning that all the values in the bit range, for example, 0 to 255, are all represented by at least one cell), it will be promoted to the next higher bit depth.[/INDENT]


Why then, do my 8-bit rasters all have a NoData value of 256 (Raster Dataset Properties)?  Wouldn't the value of 256 promote them to 16-bit rasters?


2.  I am using the NDVI as a layer in a raster composite.  Does it matter if it is 32-bit floating point when the other layers are 8-bit unsigned integer?

In the help files, it is written:

[INDENT]The equation ArcGIS uses to generate the output is as follows:

NDVI = ((IR - R)/(IR + R)) * 100 + 100

This will result in a value range of 0�??200 and fit within an 8-bit structure. [/INDENT]


I used a python script with the given equation, but it still comes out as 32-bit floating point.

Code follows:

[INDENT]    #make a list of the rasters to be processed
    rasters = arcpy.ListDatasets("t*", "Raster")

    #loop through the rasters to make the NDVI
    for raster in rasters:
[INDENT]        band3= raster + '/Band_3'
        band4= raster + '/Band_4'

        print "processing NDVI for " + raster
       
        NDVI = (Int(Raster(band4) - Raster(band3))/Int(Raster(band4)+ Raster(band3)))*100 + 100

        NDVI.save("v" + raster[1:])[/INDENT]
[/INDENT]

3.  If the bands do need to have the same pixel depth and type (to compare apples to apples with the various composite combinations), will it matter if I change them using the Copy Raster tool and set the output to 8-bit unsigned integer?

Thanks for help in understanding.

krs
0 Kudos
1 Reply
KatSuda
Emerging Contributor
In my earlier post, I didn't notice that the quotes says "in a geodatabase" the rasters are promoted.  My rasters are tiffs in a folder. Is there someone from ESRI that can explain better about pixel depth than what the help files say?

1.  can rasters of different pixel depths be composited?

2.  if a raster is promoted, how will that affect classification?  I have made combinations of different layers in my composites.  The final results (for the same area) have different pixel depths.  If I classify these composites, will the pixel depth cause differences not related to the differences in the different layer combinations?

3.  is the pixel depth something that only concerns the display?

ESRI?  Please help.

Thanks.
Kat
0 Kudos