I have 180+ Landsat Raster Layers open. Part of the layer names in the TOC include the date the image was taken.

Landsat Raster Layers

I'm trying to get weighted average NDVI for each layer in one summary table. This is the output of my model currently:

model output attribute table.

I can't figure out how to get the names of the rasters into a new field. Here's my process so far...

  1. Add Landsat NDVI layers from ArcGIS online
  2. Select by location to only include rasters in my polygon
  3. Add selected rasters to map, creating what you see there in TOC
  4. Run batch extract by mask tool. Here I can't customize names of output. The batch tool is awful. However, in ModelBuilder I can't iterate through these rasters because they aren't in a Raster Catalog, yet. There doesn't seem to be a way to export these directly to a Catalog without first running a tool, probably because they are huge files and from ArcGIS online?
  5. Save each extracted raster in a Raster Catalog
  6. Run the model which iterates through this new Raster Catalog, runs a series of calculations and gives me the output table you see.

I can very painstakingly manually add dates to the summary table. Obviously not scalable and that's why I'm here. Seems that I can't use ModelBuilder to fix the issue due to what I described above.

What can I do to get the raster names reflecting what you see in the TOC when I run the Extract by Mask tool?

I don't know any Python yet.

  • Are you using ArcGIS Pro or ArcMap?
    – PolyGeo
    Feb 23, 2021 at 20:31
  • ArcMap. I have both though so if you think this is more easily accomplished in Pro I'm all ears.
    – Alex
    Feb 25, 2021 at 14:51
  • 1
    I think it would be easier to achieve using ArcPy but if I was attempting to do it using ModelBuilder then my choice would be to use ArcGIS Pro. Whichever you decide to ask about I think you should include a test model that illustrates what you have tried and where you are stuck.
    – PolyGeo
    Feb 25, 2021 at 19:45

1 Answer 1


I agree with @PolyGeo, this type of processing tends to be much easier if scripted in Python, as you are now discovering the limitations of ModelBuilder, not particularly great for looping type workflows.

That said if you have the very latest version of ArcGIS Pro (2.7) then you can use the new Iterate Layers iterator which can step through layers in a map document. I've not had cause to use it yet so can't comment on usability but it appears to behave like the other model iterators. This can provide you an opportunity for a non-coding route if you are not familiar with Python.

  • Thanks, I just discovered the existence of this iterator but for some reason it doesn't show up in my university's version of ArcPro. Probably a licensing issue. I'll start learning python I suppose...
    – Alex
    Mar 5, 2021 at 22:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.