Jagged contours from mosaic dataset

1456
7
Jump to solution
04-19-2013 11:30 AM
RyanKelso
Occasional Contributor III
I created a file geodatabase mosaic dataset combining lidar-derived DEM TIFFs from a number of different surveys.  It combines multiple cell sizes and horizontal datums.  There is a lot to love about the mosaic dataset, I like it.

But I'm having a problem with generating contours from the master mosaic.  In areas where the source data is the lower resolution (6ft pixels vs 3ft) the contours appear jagged, blocky, pixelized, however you want to say it.  What is really throwing me off, though, is if I generate the contours directly from the source mosaic that has 6ft pixels, the contours are much more acceptably smooth, as they should be.

I'm attaching an example, it is a transition area where there is overlap between 3ft and 6ft pixels.  The yellow contours come from the master mosaic and it's easy to see what I'm talking about.  The purple contours come from the 6ft pixel source mosaic.  I'd appreciate any help with this!
0 Kudos
1 Solution

Accepted Solutions
SteveLynch
Esri Regular Contributor
The Mosaic dataset consists of many rasters with different cell sizes. Spatial Analyst, by default, uses the largest cell size when more than 1 raster is used. For example, raster1 has a cell size of 10 and raster2 has a cell size of 20. When you use the Plus tool the output will have a cell size of 20.


Spatial Analyst uses the largest cell size when there is more than 1 input raster, however, Mosaic datasets default to the smallest cell size, so in your case it'll resample to 3ft.

Steve

View solution in original post

0 Kudos
7 Replies
RyanKelso
Occasional Contributor III
Hmm, I wasn't sure whether to post this here, on the Spatial Analyst forum, or the desktop general forum.  Maybe this was the wrong place...  I can't be the only person who has encountered this before.
0 Kudos
SteveLynch
Esri Regular Contributor
The Mosaic dataset consists of many rasters with different cell sizes. Spatial Analyst, by default, uses the largest cell size when more than 1 raster is used. For example, raster1 has a cell size of 10 and raster2 has a cell size of 20. When you use the Plus tool the output will have a cell size of 20.

This is what is happening with Contour, all the rasters are resampled to have a cell size=largest.

Steve
0 Kudos
RyanKelso
Occasional Contributor III
Steve, thanks for the reply.  I think I get what you're saying, but I'm not sure because I don't understand how that matters in the scenario I'm describing.

In my case, I have 6-foot and 3-foot pixels.  If what you're saying applies, then the 3-foot pixels are getting resampled to 6-foot so they are the ones that should look jagged, or they all should look that way if all cells are being resampled.  But if you look at my picture, the contours on the north half look fine, that is the area represented by 3-foot pixels.  It's the ones generated from the original 6-foot pixels that look bad.  And when I generate these contours from the source mosaic with all 6-foot pixels (the purple lines in my example) they look fine, so it's not like this resolution is "too low" to look good at this scale.

Besides, I can take the 3-foot source mosaic, resample it to 6-foot using either Nearest or Bilinear, create contours from it and they look perfectly fine.  So unless Spatial Analyst uses some other resampling method that isn't as good, why should this even matter?
0 Kudos
SteveLynch
Esri Regular Contributor
Spatial Analyst resamples using Nearest. Automatic resampling is triggered when there are different cell sizes, changes in processing environment and/or projection changes.

What you could try is to copy your raster from the mosaic dataset into a single raster dataset, use CopyRaster. You will then see what the cell size is and this is basically the raster that'll be contoured.

Regards
Steve
0 Kudos
RyanKelso
Occasional Contributor III
So it sounds like you're saying Spatial Analyst doesn't provide the user any way to control how it resamples data?  I may also be seeing this same issue in areas of the mosaic that are being projected on the fly.

That's a real bummer, because I thought one of the big advantages to using the mosaic dataset is that you could combine original source data even in different coordinate systems and resolutions, on the fly.  The assumption being, you could run geoprocessing tools on the dataset and get acceptable results.

Anyways, I do appreciate your responses, Steve.
0 Kudos
SteveLynch
Esri Regular Contributor
The Mosaic dataset consists of many rasters with different cell sizes. Spatial Analyst, by default, uses the largest cell size when more than 1 raster is used. For example, raster1 has a cell size of 10 and raster2 has a cell size of 20. When you use the Plus tool the output will have a cell size of 20.


Spatial Analyst uses the largest cell size when there is more than 1 input raster, however, Mosaic datasets default to the smallest cell size, so in your case it'll resample to 3ft.

Steve
0 Kudos
RyanKelso
Occasional Contributor III
Thanks Steve.  It's not the answer I was hoping for but at least I understand what's happening now.
0 Kudos