Select to view content in your preferred language

Snap Raster Issue

984
2
04-19-2023 07:34 AM
JasonMcEachern
New Contributor II

I am on version 3.1.1 and the Environments setting 'Snap Raster' no longer seems to work. The setting is there and you can use it but the resulting raster cells are never coincident.

This seems to be true for the Clip Raster and the Copy Raster geoprocessing tools. I suspect the Snap Raster environmental setting no longer works for any similar tools.

One of my colleagues is at ArcPro version 3.03 and the Snap Raster seems to work just fine in his version.

The image below is to show the cells lack of coincidence. I produced this using the Clip Raster tool version 3.1.1.

JasonMcEachern_0-1681914544908.png

 

 

Tags (2)
2 Replies
JasonMcEachern
New Contributor II

Just as a follow up, another colleague suggested I use the Extract by Mask tool and that seems to work and the cells are coincident.

RebekahZehnder
New Contributor II

I've noticed the same issue.  At some point, Clip Raster stopped respecting the "NO_MAINTAIN_EXTENT" parameter, and now with 3.1 it doesn't respect the snap raster environment setting, either.  As you pointed out, Extract by Mask provides a workaround, but this is a bug that needs to be fixed.  I have a lot of scripts that use this workflow and are suddenly producing incorrect results.

According to the documentation, maintaining cell alignment is supposed to be the tool's default behavior. 

"NO_MAINTAIN_EXTENTThe cell alignment of the input raster will be maintained and the output extent will be adjusted accordingly. This is the default."

The documentation also says the tool supports the snap raster environment setting.

Tags (1)
0 Kudos