Questions tagged [raster]

Raster is a data format consisting of regular grids of values, usually stored in an image-like format.

Filter by
Sorted by
Tagged with
3
votes
3answers
44 views

How can I calculate the raster counts within an overlapping polygon in QGIS?

I have a raster with land use classes (see image). I want to count the pixel values (i.e. the classes) within the blue perimeter. In QGIS, there is a tool called 'Raster layer unique values report' ...
0
votes
1answer
16 views

Python GDAL: Clip rasterfile with multi-polygon shapefile

I am trying to clip a raster file with a multi-polygon shapefile to get separate clipped-raster file for each polygon with its 'id' as part of the name of clipped-raster file. I tried the following ...
0
votes
1answer
8 views

Clip slope raster for values outside of percent grade range

I have a slope raster, but I would like to remove values (or make them no data value shading) outside a range which makes them too steep. I tried looking at the raster calculator, and I am not sure ...
0
votes
2answers
15 views

Make 0 values transparent or white on Google Earth Engine

I plotted a raster onto Google Earth Engine, with a colour palette, and created a legend as shown. // Pull the package from the GitHub repo which stores colour palettes to be used in GEE // See https:/...
1
vote
0answers
17 views

Grabbing SHAPE@ token with index for clipping raster using ArcPy with ArcGIS Pro

I have written code that selects rows of a buffer shapefile based on that file's intersection with a polygon that represents the extent of a raster. In the photo below, the code selects all of the red ...
0
votes
1answer
17 views

Why does {terra} r library not have a mean method for the project function?

Why when using the terra::project function, is there no 'mean' or 'max' or 'min' etc method for how one raster is projected to another resolution and alignment? https://rdrr.io/github/rspatial/terra/...
0
votes
1answer
19 views

Cannot coerce class to a data.frame

I'm using R to run a random forest to predict the distribution of sediment classes in a study area. I have a .csv of the locations where sediment has been sampled, and rasters of all my predictor ...
2
votes
1answer
29 views

Calculating mean of full pixels within a box in ArcMap or ArcGIS Pro?

I am trying to calculate the mean of pixels within a boundary. I am able to find the mean using the calculate Statistics and Zonal Statistics as a table GP tool in ArcMap. But, the issue is I would ...
0
votes
1answer
29 views

Seeking"Fill nodata" tool in ArcMap

I have some NoData cells in my grid (landuse) which I want to fill depending on the neighbouring cells - more precisely the edges. In QGIS there is a tool from GDAL that does exactly that. Is there an ...
0
votes
0answers
32 views

Unable to perform zonal statistics in Python because of affine error

I have a raster layer and a polygons layer I want to use for zonal statistics, however these two files may be in a completely different projection and CRS. I am trying to use the following python code ...
1
vote
1answer
22 views

Extracting Data From Natural Resources Canada - Canada west coast topo-bathymetric digital elevation model

I have been trying to figure out how to extract a single color DEM from this dataset available on Natural Resource Canada's Website, https://open.canada.ca/data/en/dataset/e6e11b99-f0cc-44f7-f5eb-...
2
votes
1answer
44 views

Unable to write raster from array using rasterio

I have two raster files, raster1 and raster2. I want to take raster1 and divide it by raster2 and produce an output raster for this calculation. I am using python and the rasterio package. For info on ...
0
votes
2answers
32 views

R: Get majority percentage after aggregation with modal function

I want to aggregate a raster using a majority filter (modal) and in addition to that, I want to have a layer in which every cell has the value of the majority percentage. For example: Pixel 1 has a ...
4
votes
1answer
50 views

QGIS slope output problems

I've been trying to calculate slope in percentage for a project I'm working on but keep running into this issue Whenever I calculate slope using the designated Slope tool or the r.slope.aspect tool I ...
0
votes
0answers
46 views

Why is 3 band RGB Image true colour?

“If you can't explain it to a 6-year-old, you don't understand it yourself,” said Albert Einstein. After working with GIS-Systems for a long time, I have found that sometimes the most basic questions ...
0
votes
0answers
34 views

Unable to divide rasters through gdal_calc.py because of unicode error

I am trying to use python in Jupyter Notebook to divide raster file A by raster file B. I am trying to use the gdal_calc.py program in a Jupyter Notebook cell, and not in the command line, and so I am ...
1
vote
1answer
41 views

How can I calculate the area of a 5-arcminute grid cell in square kilometers, given a known latitude and longitude? [closed]

I am trying to compute the area of a 5-arcminute grid cell (coming from a global dataset) in square kilometers given a known longitude, latitude. I was able to compute the vertical length of the grid ...
3
votes
2answers
157 views

Creating a raster from scratch in QGIS

I want to create raster structure with 3 columns and 3 rows (3x3). The raster resolution should be 10 m, and cell values should be set according to the attached picture. After that, I plan to ...
0
votes
0answers
31 views

Error in rasterFromXYZ(xyz = centroids[, c("lon", "lat", "id")], crs = WGS84) : y cell sizes are not regular

I'm trying to convert a csv file set of values into a raster but keep receiving the above error. #Set raster options to improve speed of calculation rasterOptions(tmptime = 4, progress = ...
0
votes
0answers
27 views

Unable to clip raster data

I'm having some trouble clipping raster data. Once upon a time I was able to but recently I am met with an error message when I run the process. I've tried using all the options ie, clip by mask layer,...
2
votes
0answers
24 views

Checking quality assurance of MOD10A1 NDSI for snow fraction retrieval

I have recently retrieved some snow fraction data over Fennoscandia from GEE for the first time. I realise the script has no quality assurance that is a built-in feature in MODIS imagery normally. ...
2
votes
0answers
13 views

Updating "no data" value of merged raster layer to be the same as the "unmerged" layer in QGIS?

I have many raster layers that I want to merge and a lot of these layers have gaps of no data. These gaps are specified as "no data" as pictured in image 1 I then go to the merge raster ...
0
votes
1answer
22 views

ArcGIS - Can't create shapefile showing footprint of raster extent

I'm trying to create a shapefile with the extent of my raster so that it can be used as a mask to clip with. My shapefile has no datapixels along its boundary and is irregularly shaped. So far I've ...
0
votes
0answers
42 views

Converting GeoTIFF to 3D shapefile?

I have a GeoTIFF in which the data represents flood heights. I want to create a 3D vector that shows the flood heights from the GeoTIFF. Please suggest any methodologies/tools if this is possible.
-1
votes
0answers
35 views

Distance analysis using barriers

I am not super experienced with ArcMap. I am using ArcMap 10.6 and I need some help getting distance around a barrier. Here is the issue: I have some mark recapture data regarding sea turtles. It is ...
0
votes
1answer
31 views

Python Gdal: Count pixels having a specific range of values [closed]

I have few hundred raster files and I want to count the number of pixels having values within a specific range. Following code works well when using == operator e.g., raster_file == 25, but gives ...
0
votes
0answers
16 views

RasterCalculator Not defined even thought imported arcpy library

I get an error message saying that "RasterCalculator is not defined" even though I have imported everything from arcpy.sa. Why is this happening? Code: import arcpy from arcpy import env ...
0
votes
1answer
19 views

Raster into PolyLine with Python

I have got a binary raster and I want to create a shapefile with PolyLines based on this raster. The only success I achieved is a shapefile with Polygone geometry (below). I did it with rasterio and ...
0
votes
0answers
16 views

Converting .tif image to classified polygon layer

My objective is to turn a .tif image layer (a classified map) into a a polygon layer (using the raster to polygon function) with the original map's classification scheme. The classified map contains ...
1
vote
1answer
38 views

Reprojecting NetCDF naming data from rotated pole coordinate system to WGS84 in R

I am using data from UKCP Local Projections at 2.2km Resolution. The data does not have any stored coordinate reference system. However, the associated documentation explains that UKCP use rotated ...
3
votes
2answers
58 views

Statistical summary using QGIS

I have 15 layers and I click on "show statistical summary" to calculate the same field for each layer. Is there any method to calculate all of them at once rather than doing it one by one?
0
votes
0answers
25 views

Merging overlapping multiband rasters in QGIS - massive files?

What is the best way to do this? I have two images that overlap about 20%, and they are 4 bands each. Same satellite provider, resolution, etc. so there's no apparent issue with alignment. Each file ...
0
votes
0answers
10 views

PC RasterTools plug in not installed

I had to force a close on QGIS 3.10 recently. Since then, I've had recurring message 'PC Raster Toolbox not installed' continually. Reinstalling the Toolbox makes no difference. I've uninstalled QGIS ...
1
vote
0answers
8 views

Is it possible to skip building raster attribute table for unique value symbology in ArcGIS Pro

I need to visualize a raster image in ArcGIS Pro. This image is quite large and I need to display it with a "unique value" value symbology. I have another layer with the same symbology and ...
2
votes
1answer
33 views

Create Function to a RasterStack

This is the function that I want to create: Erosivity_Factor = 1.74 * log[sum(montly²/annual)]+1.29 I have solved it using a loop: # Reproducible RasterStack with 12 layers Monlty<- stack(lapply(1:...
0
votes
0answers
39 views

Summing rasters in python with different shapes [duplicate]

I have a polygons shapefile with many individual overlapping polygons, each containing a unique value in the "Value" column. I want to iterate over each polygon in this shapefile (feature in ...
0
votes
0answers
9 views

How to interpolate raster values along boundary with existing raster coverage in ArcMap?

I have two rasters, for simplicity's sake imagine these as squares. The new raster is smaller and wholly contained within the existing raster. For simplicity's sake, imagine these as nested squares: ...
0
votes
0answers
27 views

Unable to write array to raster file using geocube in python

I have a polygons shapefile with many individual overlapping polygons, each containing a unique value in the "Value" column. I want to iterate over each polygon in this shapefile (feature in ...
0
votes
1answer
24 views

Clip Raster with Shapefile GDAL API

I am trying to clip a raster using a polygon an GDAL. The following code is running without an error but the ouputimage is all zeros. All files are in the same CRS. Is there a way to use GdalWarp with ...
0
votes
0answers
32 views

Unable to rasterize polygons within for loop in Python

I have a shapefile with many polygons, with three separate attribute value columns as "colors": Blue, Red, and Green. For each color, I want to rasterize each individual polygon with that ...
0
votes
0answers
39 views

Applying elevation correction to DEM raster in QGIS (using landcover classification vector)

I'm a wildlife ecologist attempting to correct a digital elevation map (DEM) generated from UAV data. As expected, I encountered a positive bias in my DEM elevations in areas of dense vegetation. I ...
2
votes
1answer
38 views

Downloading entire image collection of a particular month from 1990-2020 in GEE platform?

I am trying to download ERA-5 daily minimum temperature data of 10 years (2010-2020) for a particular month (at present for November) and a study area (an imported shapefile as WH). I have extracted ...
0
votes
0answers
31 views

Can QGIS clip a raster after Hillshade has been run on it? [duplicate]

I've been trying to clip a raster layer with a shapefile. I already ran Hillshade on the raster, but the clip operation produces a clipped raster file, but the hillshade has been removed. Is this how ...
1
vote
2answers
34 views

QGIS 3.22 Georeferencer Coordinate Reference System Selector not showing

I'm using QGIS 3.22 trying to go through the 3.16 training manual - 14 Module: Forestry Application - When following the manual instructions after opening the Georeferencer and loading the raster, ...
1
vote
0answers
21 views

Rasterizing in QGIS 3.16 - Rasterlayer doesn't show up

I would like to transfer a vector-layer (containing the attribute "Polygon NN") to a raster. After filling in all parameters and Rasterizing the vector layer, nothing shows up. I watched ...
1
vote
0answers
19 views

How do I separate results from a multi-geometry rioxarray clip opeartion?

I have MODIS data .hdf format and multiple polygons representing regions of interest. I can clip the raster using rioxarray such that polygons = [polygon1, polygon2, polygon3, ... ] with rioxarray....
1
vote
1answer
21 views

Weighting the flow accumulation raster by the slope raster in QGIS

I am trying to represent de equation of Mahoney et al. (2018) https://www.sciencedirect.com/science/article/abs/pii/S0022169418302877 Where Si is the slope in the cell i, ΣSup is is the sum of the ...
0
votes
0answers
25 views

ERROR 1: PROJ: tmerc: Invalid latitude

Im trying to warp(reproject) a raster layer to EPSG 4647 and keep getting the Error above. It works when I'm just right-clicking on the layer and set the CRS (it moves to the right position). But in a ...
2
votes
1answer
45 views

PyQGIS Legend doesn't update with renderer

I am using QGIS 3.22.2. I am relatively new to QGIS and have been trying to automate part of a workflow, including changing the rendering of a raster. Following the PyQGIS cookbook, I have this code: ...
0
votes
1answer
25 views

How to integrate DSM elevation values into a classification scheme?

I'm in the process of attempting to create a corrected DTM for a UAV flight of a salt marsh. As part of this process I'm trying to integrate mean elevation values from each cell of a raster DSM into ...

1
2 3 4 5
176