Select to view content in your preferred language

Extraction of geoTiff values.

5452
6
Jump to solution
03-06-2016 02:08 AM
Lars_HolmThomsen
Deactivated User

I have extracted RGB-values from points (in a shape-file) from 3 bands GeoTiff using spatial analyst.

Everything went fine except the values are not the save as shown when I click on the corresponding pixels with the info-tool. Why is this? Tiff_problem.jpg

1 Solution

Accepted Solutions
DanPatterson_Retired
MVP Emeritus

Extract Multi Values to Points—Help | ArcGIS for Desktop  you must have used this tool,

This statement suggests interpolation is used, but I would suspect for the locations with no points, but strange non-the-less

The interpolation option determines how the values will be obtained from the raster. The default option is to use the value at the center of the cell being sampled. The interpolation option will use bilinear interpolation to interpolate a value for the cell center. but to confirm, you chose None for interpolation.

The only other thing I can think of is that the environments should be check to ensure that the location of the raster is referenced so that the cell center is indeed the center, since the bottom left corner can be used for locating rasters, which may account for the perceived shift in values  And of course, you have ensured that both are in the same coordinate system, extents are proper and snap raster (not necessary I think in this case) are all set

View solution in original post

6 Replies
Lars_HolmThomsen
Deactivated User

So... this is strange...I found out that the values read by Spatial Analyst is not coming from the pixel underneath the point but from then pixel 1 pixel below (Y-direction) the point-pixel. Error? I'm I doing something wrong?

Tiff_problem_2.jpg

0 Kudos
DanPatterson_Retired
MVP Emeritus

Extract Multi Values to Points—Help | ArcGIS for Desktop  you must have used this tool,

This statement suggests interpolation is used, but I would suspect for the locations with no points, but strange non-the-less

The interpolation option determines how the values will be obtained from the raster. The default option is to use the value at the center of the cell being sampled. The interpolation option will use bilinear interpolation to interpolate a value for the cell center. but to confirm, you chose None for interpolation.

The only other thing I can think of is that the environments should be check to ensure that the location of the raster is referenced so that the cell center is indeed the center, since the bottom left corner can be used for locating rasters, which may account for the perceived shift in values  And of course, you have ensured that both are in the same coordinate system, extents are proper and snap raster (not necessary I think in this case) are all set

Lars_HolmThomsen
Deactivated User

Thanks Dan for your answer.

I think your answer was, even though the correct maybe, but it led me to try what was - I think - the solution.

I have been using no interpolation and yes... then coord sys are the same.

Your talk about the two ways of referencing the cell-values let me to try to save tiff file and load the copy....

This reveales that the copy is shifted half a cell downwards (to the south) compaired to the original. And now doing a new multi values to point analyses places the same values in the attribute table as found using the info-tool.

Well...I think we are dealing with an ArcMap error!

Hi from Lars

DanPatterson_Retired
MVP Emeritus

In the environments tab for any tool in ArcToolbox, I always recommend that everything be set explicitly, since it is not safe to assume that global settings will override tool settings.

Analysis environments and Spatial Analyst—Help | ArcGIS for Desktop

I explicitly set

Snap raster is particularly import because in conjunction with extent it ensures that the edges of raster align properly.  I see this half cell misalignment a lot in student assignments and it makes foul work of change detection...because change can appear along feature edges when none exist...the cause being misalignment.

Lars_HolmThomsen
Deactivated User

Hmmm - I can't find any settings that corrects this problem!

But, I'm sure it's just beacuse I can't find it.

Why is the original tiff file not read and projected correctly? Why is the copy projected differently?

Why does arcmap read a value incorrectly (spatial analyst tool) and correctly (info tool).

How do i determine - in this case and with other tiffs in the future - if a tiff is displayed correctly?

Can you please guide me?

0 Kudos
DanPatterson_Retired
MVP Emeritus
Depends upon the originating software and/or settings therein.  Any raster will either be defined by the lower left (or upper left) corner or the lower left (or upper left) center of the cell.  The only way you can tell is to find out what options were set in whatever software, then check them.  In arcmap, it is easy to check since you can examine the extents property for any layer.  It should be exactly what you defined based upon the cell size you chose.  I never trust any software, so I calculate the extent from a known LL or UL coordinate that I need, choose my cell size and calculate the diagonal opposite point from there (UR or LR).  I then check again after the image is created.  


0 Kudos