POST
|
I am currently using ArcGIS Desktop 10.7.1 and have encountered a problem that I can unfortunately not solve, and I have not found any forum entries that are similar enough to troubleshoot with. I am trying to export a filled and clipped (with "Extract by Mask") DEM and a classified land use raster (with numerical values for each class, derived using Iso Cluster Classification) at the same resolution so that I can use it in other programs (e.g. MATLAB ). Upon exporting and opening in other programs, these rasters only consist of x,y data with the location, whereas all z data or classification data is missing (either showing 0, NaN (in MATLAB) or -9999). I have attempted the following in both MATLAB and Python IDLE: Exported as ASCII Exported as GeoTIFF¨ Exported as ESRI Grid Exported as a rendered GeoTIFF Exported as a jpeg For all of these options, I have attempted using extent and spatial reference as "Data Frame" and as "Raster Dataset", which makes no difference in the output. The exported files seem to read fine in ArcGIS, but not in the other programs. I have been able to successfully read rasters from other sources (raw images, QGIS) within MATLAB and Python using the same setup, so I believe the problem is with the ArcGIS export of rasters since the issue only occurs once I have edited the images in ArcGIS.
... View more
07-02-2020
04:55 AM
|
0
|
2
|
589
|
POST
|
Hello everyone, I am quite new to ArcGIS so this may be simple, but I just cannot find the right answer to this. I have two rasters (.tif) that I have derived from Sentinel images. One is a raster with land use classification derived from training sample data and Supervised Classification at 10 m resolution. It has 5 classes (buil-up/bare, forests, mining pits, croplands/grasslands, and cloud cover). I have also computed the MNDWI for each raster cell based on green and SWIR bands at 20 m resolution. I have noticed that in the LU raster, it has wrongly classified water bodies as either cropland or forest. I want to correct this by assigning values in the LU layer that are cropland or forest as water bodies where the MNDWI is higher than 0.4. I have tried overlays, selection by attributes, and the raster calculator in various forms, but I keep getting error messages. The conditionals I use in the raster editor (e.g. something like: water = ("LU.tif" == "cropland") & ("mndwi.tif" >= 0.4) do not compile. I feel like I am missing something very obvious. I was able to extract the water bodies using watbod = "mndwi.tif" >= 0.4, but now I cannot use it to extract the relevant cells in the cropland/forest LU layer - I can often compile, but then get a layer with results spanning 0 to 0. Is this because of the differing resolutions? Where am I failing here? One additional note: I often also encounter the error notice: "The truth value of a raster is ambiguous. Invalid use of raster with Boolean operator or function." In this case, I had tried variations of watbod_new = "LU.tif" == "cropland" & "watbod" == 1, with watbod = 1 being the extracted waterbodies. Adding parentheses resulted in a raster with the value being 0 everywhere.
... View more
03-29-2020
06:52 AM
|
0
|
1
|
1530
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|