AnsweredAssumed Answered

Feed model with raster files, a shapefile clip feature, a layer file - output to kmz?

Question asked by EJAY_L on May 28, 2013
Latest reply on May 28, 2013 by EJAY_L
The challenge is to
1) Clip all the rasters in a folder with a polygon shapefiles
    -rasters will be selected based on a field called tileName in the shapefile that contains all the raster names, e.g. 1955_30_146.tif;
2) Apply symbology from a saved layer file(.lyr);
3) Save the clipped rasters and export them to kmz files.

See below for supporting info if you would like to jump in to tackle the issue:

Background info:

a. A folder contains all the GeoTIFs - scanned and georeferenced air photos rasters.
b. A manually created polygon shapefile - outlining the areas and removing overlapping.
c. The attribute table of the polygon shapefile has all file names of the GeoTIFs( "tileName=1955_30_146.tif").
d. Software: ArcGIS Desktop 10, Arcview License with Spatial Analysis Extension.

Here how it works in ArcMap for a single process:

1. In ArcMap, select a polygon in the shapefile and use that to clip a related raster from a folder
    -the shapefile has a field call tilename which lists the names of all the TIF rasters
    -so the tilename field is used to determine an input raster
2. The clipped raster will be added to the table of content; as its colour range have changed, the image becomes brighter!
4. Apply sympology to the raster from a saved layer files (.lyr) so that the colour matches that prior to that being clipped.
    -save the raster with the new symbology?
5. Export raster to a KML file.

Can a model be built with ModelBuilder to allow user to feed the data with a folder(TIF raster files), a polygon shapefile, and a layer files(apply same symbology to all rasters), and output locations?

Once this done, I imagine it will be possible to export the model to a python script which can be scheduled to run with window's task scheduler, for example. It is an extended task to the answer from this post.

Feel free to ask where I didn't make myself understood.

Your help will be appreciated.