blythe_dan

ModelBuilder- renaming of raster files during iterative model run

Discussion created by blythe_dan on Apr 22, 2013
Latest reply on Apr 22, 2013 by blythe_dan
I am using an iterative model to run a set of raster files (as list variables) through several tools, namely:
1. define projection
2. build attribute table
3. clip
4. project raster
5. resample
6. clip
7. calculate statistics

When the model reaches step 4 (Project Raster), it fails to execute. I identified the problem as being the numeric characters at the beginning of each filename in the intermediate dataset between steps 3 and 4; that is, the filenames that are output from step 3 (Clip) all begin with a number (e.g. 01_Clip.tif, 02_Clip.tip, 03_Clip.tif, etc.). These filenames were automatically generated by Model Builder when I built the model.

To remedy the problem, I manually changed each filename in that intermediate dataset, such that they end with a number (e.g. Clip_01.tif, Clip_02.tif, Clip_03.tif, etc.). However, as soon as I ran the model again, those filenames defaulted back to their original format, and the same problem occurred at step 4.

I am unsure of how to control the filenames if Model Builder automatically generates an unacceptable format at the start of each model run. Any suggestions would be greatly appreciated.

Outcomes