Questions tagged [rasterization]

The process of turning a vector into its raster equivalent

Filter by
Sorted by
Tagged with
15
votes
6answers
19k 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 ...
15
votes
2answers
9k views

Splitting 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 ...
14
votes
6answers
6k 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 ...
12
votes
1answer
11k 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 ...
10
votes
5answers
784 views

Creating raster where each cell records distance to sea?

I want to create a raster with a 25 metre × 25 metre resolution, where each cell contains the distance to the nearest coastline, as calculated from the center of the cell. To do this, all I have is a ...
9
votes
1answer
4k 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
10k 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 ...
9
votes
3answers
3k views

Converting point layer to raster grid that shows frequency of points per cell uisng 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 ...
8
votes
1answer
3k 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 ...
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
1answer
2k 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
3k 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
222 views

Using GDAL tool rasterize with QGIS so that points represent center of grid

I want to convert point data into a grid and used the gdal tool rasterize. The tool works but unfortunately the result looks like this. The converted point does not represent the center of the grid ...
6
votes
2answers
3k 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
1answer
647 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
11k 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
2answers
2k 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 for ...
5
votes
2answers
2k 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
820 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
8k 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
956 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
632 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
228 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
2answers
746 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 ...
5
votes
1answer
810 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 ...
5
votes
1answer
125 views

Rasterize/Filter with Burn and Weight variables in QGIS

Using QGIS 3.10.1, I am attempting to rasterize some demographic polygons, and then apply a filter (Gaussian) to create a smooth/graduated surface. This works fine for some of my values (e.g. total ...
4
votes
3answers
9k 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 '...
4
votes
2answers
849 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 ...
4
votes
3answers
411 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
1k 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
564 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
971 views

Calling gdalogr:rasterize algorithm in python console in QGIS?

I'm trying to rasterize a simple line-vector layer. I can do it by using QGIS GUI, but I want to do the same with python console. Unfortunately it always gives back an "Error: Wrong number of ...
4
votes
1answer
133 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
2k 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
374 views

Generating raster (spec. GeoTiff) out of mesh file (.ply)?

I created a mesh file using OpenDroneMap program out of 100 geotagged jpgs, and I would like to know how to generate a raster image out of the resultant .ply file? Has anyone done this? Meshlab has ...
4
votes
1answer
2k views

Rasterizing polygon grid in Python (geopandas & rasterio)

I am trying to rasterize a custom polygon grid with one or more columns. Preferably I'd like to create multi-band rasters from multiple GeoDataFrame columns (in polygon grid), but I have got stuck ...
4
votes
1answer
425 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
0answers
51 views

QGIS export to PDF - rasterize only basemap layers but keep others as vectors

I am building my own map in QGIS 3.4 in which I created a basemap from ESRI satellite imagery and a ESRI hillshade overlay. On top I have several custom vector layers (country borders, city names etc.)...
4
votes
0answers
879 views

QGIS create raster from CSV and find raster index [duplicate]

I have a CSV with about 2 Mio. entries with X and Y coordinates WGS84 and many attributes. The X and Y coordinate are the south west coordinate of 100 meter by 100 meter grid over a country. But the ...
3
votes
3answers
741 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
6k 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
4k 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
87 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
65 views

Rasterization of polygons, calculation of the area covered

In R environment I have (1) a SpatialPolygonDataFrame with number of polygons: polys; (2) raster grid of resolution 10'000 m: grid. Both of them are in the LAEA coordination system. What I need is to ...
3
votes
1answer
1k views

Render raster tiles from a Mapbox GL style

I'm struggling to put together the appropriate stack for rendering raster tiles (for display of slippy maps) from a given Mapbox GL style. Style specifications: First there were the Mapnik XML ...

1
2 3 4 5
7