Hi everyone,
I'm constantly having a problem when using "Extract by Mask". The output of this tool is coming with an "extra" area that is not in my original shapefile. I've attached three figures showing my raster file (NLCD 2011), a shapefile with some counties from Georgia, and the output when I tried to extract the raster file using the shapefile. As you can see, especially on the northeast part of the figure, there are "extra" areas in my output. I also had this same problem with different other files in completely different locations.
This error is similar to the black border error of projected satellite images and DEM, but in my case, these extra areas have real data, they are not just a black square, but part of the original data.
All my files are on the same coordinate system (WGS_1984_UTM_Zone_17N)
Is there any solution?
Thank you!!
Steve,
1) I first tried to use GDB as my workspace (I had some success in the past using GDB, then extract data from this GDB to create a TIF). Therefore, my workspace is GDB, as showed in this picture that I've attached on this reply.
2) FGDBR as you can see on the attachment.
3) Columns: 13858, Rows: 16564
4) ArcGIS Desktop 10.5
Thank you very much!
Fabio
This might be related to a bug that got fixed post 10.5.
Please try the following;
PolygonToRaster using your shapefile as input (use any field), however in the Environment settings , set the Processing extent and cell size equal to this problematic output raster that you created using ExtractByMask.
Does the "block" of data appear in the northeast?
Not sure if this'll work but it is worth a try. When running ExtractByMask (or PolygonToRaster) in the Environment settings change Tile Size (Raster Storage) to 1024 by 1024
-Steve
Steve,
I didn't get the block in the northeast when setting the extent to be equal to the problematic raster (I didn't find where to set the cell size equal though).
I tried to set tile size to 1024 by 1024, but it yielded the same output.
Do you think that if I update my version to 10.6 would solve this problem?
Other suggestion?
Thanks!
Fabio
To set the cellsize for PolygonToRaster you can use the environment
or via the Cellsize parameter on the tool, drag the rasterlayer from the table of content into the control or browse to the raster dataset on disk.
Steve,
I tried PolygonToRaster using the same processing extent and cell size, and the output does not have the "block" on the northeast.
Thanks
Steve,
I used Dissolve to create a big polygon of all counties and tried again. Now it worked!
Thanks!
Fabio
That is great.
If this raster has a value of 1 and NoData elsewhere you can use the Times tool rather than ExtractByMask until you change to ArcGIS 10.6.
-Steve
Steve
Good to know! I'll try this approach if I have this same problem in the future.
Thank you for your attention!
Fabio