Using the Describe() function to return descriptive information about an image

Raster files also contain descriptive information, which can be returned by the Describe() function.

Getting ready

A raster dataset can also be described through the use of the Describe() function. In this recipe, you will describe a raster dataset by returning its extent and spatial reference. The Describe() function contains a reference to the general purpose Dataset properties group as well, which contains a reference to the SpatialReference object for the dataset. The SpatialReference object can then be used to get detailed spatial reference information for the dataset.

How to do it…

Follow these steps to learn how to obtain descriptive information about a raster ...

Get Programming ArcGIS 10.1 with Python Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.