Questions tagged [rasterization]

The process of turning a vector into its raster equivalent

Filter by
Sorted by
Tagged with
15
votes
6answers
17k views

Burning stream network into DEM layer using ArcGIS Desktop?

I am working on a DEM that in an area where there is little relief. I would like to 'burn' the river network into the DEM so I can calculate flow accumulation and flow length accurately. I am ...
14
votes
6answers
5k views

Convert line shapefile to raster, value=total length of lines within cell

I have a line shapefile representing a road network. I wish to rasterize this data, with the resulting values in the raster showing the total length of the lines that fall within the raster cell. The ...
13
votes
2answers
7k views

How to split shapefile per feature in Python using GDAL?

is it possible to split a shapefile per feature in python? (best would be a solution where i can temporarily save the resulting vector objects to the memory instead to disk). The reason: I want to ...
12
votes
1answer
10k views

GDAL RasterizeLayer does not Burn All Polygons to Raster?

I am trying to burn a shapefile to a raster using GDAL's RasterizeLayer. I pre-create an area of interest raster from a different shapefile, given a specific pixel size. This AOI then serves as a base ...
9
votes
1answer
3k views

Processing vector to raster faster with R

I am converting vector to raster in R. However the process was too long. Is there possibility to put the script into multithread or GPU processing in order to do it more faster? My script to ...
9
votes
2answers
8k views

Convert several SpatialPointsDataFrames to raster

There are 100 SpatialPointsDataFrames in my Workspace. I loaded them on this way: filenames <- list.files(path="", pattern="XYhectareTravelTimes_ez+.*shp") for(i in ...
7
votes
3answers
2k views

Creating raster or vector raster from DEM point file?

i have a point shape of 75.000 elevation points in a regular 5 m grid. We now want to create a polygon grid with the elevation points as "centroids". Unfortunately, all attempts to do so fail: I ...
7
votes
2answers
5k views

Issue Trying to create Zonal Statistics using Gdal and Python.

I am trying to create zonal statistics using Python and Gdal. I have a polygon shapefile and a raster file, and in order to do so, I am using a piece of code I found in StackExchange. The raster and ...
7
votes
3answers
2k views

How to convert a point layer to a raster grid that shows the frequency of points per cell in QGIS

I have a point layer that shows the distribution of a species. Is it possible in QGIS to convert this point layer to a raster grid in which the value of each cell corresponds with the amount of points ...
7
votes
1answer
1k views

How to speed up extract(rstr,shp) ? - R

I am trying to create a function that takes in a shapefile and a binary (1's and 0's) raster, with the same extent, and extracts the values from the raster. Once this occurs I desire to sum up those ...
6
votes
1answer
2k views

Rasterize (Vector to raster) ERROR 6

I'm trying to convert a polygon to raster. This error pops up: ERROR 6: At least one of -3d, -burn or -a required. What am I missing?
6
votes
2answers
2k views

Create raster with grid cells values based on area covered by polygons

I have a polygon data with area covered by the forests (data is here - https://www.dropbox.com/s/zgckliydalljw6a/sp_data.zip?dl=0). I want to convert polygons to raster. The value of each grid cell ...
6
votes
0answers
2k views

Rasterize shapefile using another raster's size and resolution

Rasterizing a vector (shp) I face the following problem: I want my output file (the rasterized vector) to have the same resolution and dimensions as an existing raster. If I understand the interface ...
5
votes
2answers
1k views

Convert vector point data (shp) to raster (tif) using QGIS

Overall Question: How can I get the rendered tif image to keep the modifications seen in the image produced by map canvas? I am writing a standalone Python script. I have simplified my code below ...
5
votes
2answers
1k views

Using Rasterize tool in QGIS?

I've been following the steps in the book "An intro to using gis in marine biology, supplementary workbook seven". I'm trying to create a presence-absence map by turning the data layer of dolphin ...
5
votes
1answer
7k views

Rasterizing shapefiles with GDAL and Python?

I am trying to rasterize a shapefile, and write values from a specific column of the shapefile into the resulting GTiff. Here is what I've done so far, but that only creates a GTiff of zeros. from ...
5
votes
1answer
689 views

Calculating the percentage cover of multiple polygons

I am creating a habitat map for a woodland dependent species. I have multiple woodland polygons. Across the landscape the density of woodland varies widely and I would like to show that difference. I ...
5
votes
1answer
6k views

convert vector (point shape) to raster (tif) using python gdal lib in qgis

I'm trying to convert a vectorlayer (point- shapefile) to a raster-dataset (tiff) using python gdal-library in qgis. On Graphical UserInterface I simple choose the menue "raster->conversion->...
5
votes
1answer
935 views

Turning multiple vector layers into one raster in ArcGIS Desktop?

I want to make a raster out of the multitier view I have in ArcMap 9.3.1 . The layers in my ArcMap come from several datasets. I know there is a 'Feature to Raster' tool, but it converts one ...
5
votes
1answer
464 views

How to run gdal_rasterize with sql option?

I'm running gdal_rasterize via a python pipe. When using the -l option, the raster is created just fine but I can't manage to get -sql option to work. Well my raster will be created but consists only ...
5
votes
1answer
157 views

Vector to raster by maximum combined area

I need to convert a polygon to raster resulting in a raster with cell size of 250 meters and each cell value takes the value of the objects, with equal values, that together sum the largest surface ...
5
votes
1answer
479 views

Rasterize in QGIS using point as centroid (not vertex)

I'm attempting to make the full switch from ArcGIS to QGIS, but there are a few snags I'm hitting along the way, one of which is in the GDAL "Rasterize" function. My process goes like this: I have a ...
5
votes
2answers
712 views

GDAL (or other open-source) equivalent of Arc's Point To Raster Tool

I'm trying to convert a python script that relies on arcpy into one that only relies on open source modules, but I'm having some trouble. The bulk of my processing lies in one Arc tool "Point to ...
4
votes
3answers
208 views

Remove background when using Rasterize in QGIS

I used Rasterize (vector to raster). The result is shown below. There is a bright yellow background around the map after I used Rasterize. I want to know how I can remove this. The value 0 can be ...
4
votes
1answer
802 views

Rasterise Polygons with consistent resolution and size in QGIS

Using QGIS I want to rasterise a series of polygon layers so the output is the same size and resolution. I am using Rasterise, however am not getting the result I want. I have a raster that is the ...
4
votes
2answers
4k views

Problem with attribute field in rasterizing tool QGIS

I am trying to rasterize a vector layer using the "rasterize tool" in QGIS... The problem is that there is no "attribute fields" available to choose from (even though they exist!)...
4
votes
1answer
11k views

How to convert a regular point grid to raster? [duplicate]

Possible Duplicate: How to convert a point grid to a raster? I´d like to convert a regular grid (25 meter) of points (XYZ) to a raster. I have tried the GRASS-tool r.in.xyz but I always get a ...
4
votes
1answer
429 views

raster::rasterize set wrong values with enclosed polygons

Similarly to this post rasterize (R package raster) fail to rasterize island polygons? the rasterize function in the raster package is giving me problems with enclosed polygons. In my case, some ...
4
votes
2answers
7k views

Converting point grid to raster using GRASS?

If I load the original .csv file, I then have a map of the African continent represented by 14069 data points covering it at 40x40km resolution. Each data point shows solar radiation means across the ...
4
votes
1answer
123 views

Rasterise heights from a 3D linestring

I have a 3D network of streams represented using linestrings with Z-coordinates. I would like to rasterise this feature, where the raster values represent the linearly interpolated Z-values between 3D ...
4
votes
1answer
970 views

Python GDAL RasterizeLayer option parameter

I'm writing some code that's supposed to take multiple multipolygon layers and merge them into 1 raster. I can load in the datasets just fine and render them to an image (although I use this just for ...
4
votes
1answer
2k views

Rasterize vector file using gdal.RasterizeLayer() without losing attribute information in python

Is it possible to rasterize a vector file with gdal.RasterizeLayer(), saving attribute as Raster value ? Like gdal_rasterize can do with : gdal_rasterize -a attribute -ts rasterXsize rasterYsize -l ...
4
votes
1answer
274 views

Rasterizing multiple ogr vectors from different files using the GDAL python module?

I'm trying to create a single raster from several shapefiles. I think what I need to do is to merge many layers into a single 'MEM' object. Then re-project this object to a different coordinate system....
4
votes
1answer
742 views

Area-weighted rasterising of polygon data

I'm looking for any GIS tool to do detailed rasterising of polygons. I've checked GDAL's gdal_rasterize command (and API), and ArcGIS's Polygon to Raster tool, but they only rasterise 1 attribute per ...
3
votes
3answers
6k views

How to convert file .shp to .tif using ogr or python or gdal

I need to convert files. I'm trying to use gdal_rasterize gdal_rasterize -b 1 -burn 0 -l file file.shp work.tif and the output is the following: ERROR 10: Pointer 'hDS' is NULL in '...
3
votes
3answers
410 views

Export styled vector layers as TIFF raster?

I have contours that need to go on a TIFF file. They are both georeferenced and in the correct location. I am currently trying to use QGIS to bring them in and change the linetype/lineweight of the ...
3
votes
1answer
5k views

How to rasterize an object of class SpatialPolygonsDataframe in R

When I read a polygon shapefile into R using rgdal, it was imported as an object of class SpatialPolygonsDataframe. I need to rasterize the polygon, but the rasterize{raster} function requires it to ...
3
votes
2answers
3k views

Rasterizing polygons with the function “gdal_rasterize” in R

I'm using the function gdal_rasterize in R (package gdalUtils) to convert a polygon shapefile into a raster. Here is my code: r.test <- gdal_rasterize(src_datasource="df.shp", dst_filename="test....
3
votes
1answer
77 views

What does the vector to raster option in QGIS do, exactly?

I have a large point vector layer (a few million objects) with measured elevation values and have converted it to raster, using the raster>conversion>(vector to raster) option in QGIS. It seems to ...
3
votes
2answers
280 views

Creating raster layer from dictionary in PyQGIS?

In a dictionary such as below, I have a series of x,y coordinates as key and distance measured as values in dictionary. I want to convert this dictionary to a raster layer with PyQGIS, Can I do it? ...
3
votes
2answers
489 views

QGIS - point to raster - Summing attributes as value of raster

I'm trying to produce a raster layer. The aim is to show the summed heat consumption of every cell (100*100m). I created an point layer with all buildings and an attribute with their heat ...
3
votes
1answer
1k views

Choosing Point to Raster vs Feature to Raster in ArcGIS for Desktop?

I am converting point vector data to a raster dataset using nearest neighbor. I am using arcgis 10.2. The first step is to use the conversion toolbox, but there are two possible options: Point to ...
3
votes
2answers
678 views

QGIS Layer Style - Adding intensity/color if elements overlay

I have a layer with thousands of points. I have been asked to represent this layer in way that can be easily seen the level of concentration of points in the layer. So when there is much point ...
3
votes
1answer
776 views

Rasterize Point layer Error: Wrong value for -outsize parameter

I am trying to create a Euclidean distance raster from a point layer (in QGIS 3.0.3). From reading up on this topic in this forum I found that I should rasterize the point layer first. I also ...
3
votes
1answer
172 views

Rasterize stuck in QGIS

I have QGIS 2.18.15 and I'm trying to make a raster layer from polylines or points. every time I start the process, it looks like it's working but won't really do anything (the cursor turns to round ...
3
votes
1answer
7k views

Convert a SpatialPolygonsDataFrame to raster using rasterize function

I'm trying to convert my map (a SpatialPolygonsDataFrame) into a raster, using rasterize function, here is a bug that I don't understand... > class(parcel) # this is my map [1] "...
3
votes
1answer
64 views

r.surf.contour for large area

I have a vector file containing contour with 2m accuracy, covering a large area (All Hong Kong). I tried to generate an elevation raster map with the file, by first rasterized the vector, using v.to....
3
votes
1answer
449 views

Rasterize (vector to raster) QGIS 3.4

I am trying to rasterize a vector with the QGIS 3.4 rasterize tool (not saga or grass tools). I prefer using this tool cause it is much faster. The values which i would like to burn are found in the "...
3
votes
1answer
301 views

Rasterizing vector shapefiles using multiple burn in values

I have a vector shapefile of a geographic area that contains several different object codes that I need to rasterize all as one image. I am working with QGIS, but the Raster>conversion tool seems to ...
3
votes
1answer
127 views

Rasterizing Shapefiles onto TIFF loses style

I have two contour shapefiles, one for 2ft and one for 10ft contours. I want to put these on a TIFF file I have of the aerial. I achieved this by going to Raster > Conversion > Rasterize and using ...