Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [ppygis]

PPyGIS is an extension for Psycopg which adds support for PostGIS geometry objects

0
votes
0answers
29 views

How to get user and password of Oracle Spatial layer in QGIS?

I wonder if it is possible to get the user and password for a Oracle Spatial database if they are stored in the Oracle Spatial connection information. I get layer source, but password and user are ...
1
vote
1answer
29 views

QGIS 2.18: Filter line-layer by QgsExpression

I have a line layer on which I want to run a filter within a python script. I am trying to achieve this via QgsExpression and QgsFeatureRequest. Below you see the same filter that I want to apply in ...
2
votes
2answers
64 views

Write to QGIS python console from plugin with sys.stdout

From my own QGIS plugin, I want to print text to the python console (see motivation below). Most simply, I use import sys sys.stdout.write('Outputtext') And get: AttributeError: 'NoneType' ...
1
vote
1answer
48 views

pygis zoom to selected layer

I selected the layer I want to zoom in and I can actually zoom in using the python console that Qgis provides using iface.zoomToActiveLayer() but if I do the same in my code, is like that line is ...
1
vote
1answer
54 views

QGIS python script crashed with minidump written to C

I have written a python script which has two input vector layers (one point-layer and one line-layer). The outpout is another line-layer. But when I try too set the geometry for the new edge, the ...
1
vote
1answer
50 views

Joining attributes after selecting one polygon which intersects another using geopandas?

To select the polygons which overlap other layer's polygons, I came up with this code based on what I found on this site: import geopandas as gpd import fiona import os import sys # Get the current ...
2
votes
0answers
55 views

Insert point layer as input for GRASS viewshed in QGIS 3.2 modeler

I’m building a QGIS (3.2 Bonn) tool for my colleagues using graphical modeler. The tool should get 3 inputs: DEM raster layer, vector layer of points, vector layer of a point of interest (POI). The ...
2
votes
1answer
134 views

Running Powershell Script from QGIS Actions or Python Console

Is anyone able to explain how the Windows/Open Actions work? And also the python console? I have a powerscript .ps1 file I was wanting to launch from either of these options and it just doesn't seem ...
1
vote
1answer
322 views

Creating a portable map package file folder

I am searching for an expression or some assistance in changing filepaths and links to photos within attributes to relative paths. I have used QConsolidate to create a folder with all the files and ...
1
vote
0answers
18 views

pyqgis composer legend error(no print)

i want to use composer in pyqgis standalone script to create some easy mas using one raster. my output image is correct i have the image but that code cant print show the legend in the map, any ...
3
votes
2answers
80 views

Rectangle Buffer (with dimensions given in metres) around Points on map (lat long). Using QGIS 3.0

I have points on a map of the globe given with lat|long coordinates. I want to create a rectangular buffer around each one, but I want to be able to set the dimension of this buffer in metres. The ...
0
votes
1answer
27 views

Analysing and mapping intersection of layers with one layer with overlapping Polygons

I have one layer (a_layer) with approx 400 overlapping polygons and no more data as the fid. I want to analyse how many countys (b_layer) are coverd by each polygon of tha a_layer. I was thinking to ...
1
vote
1answer
37 views

Fill or inserting new field based on comparison of two other field

I have a layer Network with two different columns Route and section I need a query or function that compare Route rows , and section rows, and create or rather fill the new_field with this ...
1
vote
1answer
320 views

How to batch export rasters as GeoTIFF with new CRS?

I need some help concerning the exporting of a large batch of raster-files (mostly SID-types) as GeoTIFFs in a reference system (WGS 84) that is different from the one in which the original files were ...
0
votes
1answer
2k views

Cannot access coords property of LineString in GeoDataFrame

How can I access the coords property of a LineString in GeoDataFrames? I can access other properties, such as area, length, etc, as documented in the Shapely documentation. See reproducible example ...
0
votes
1answer
72 views

standalone script using grass7:v.clean gives erro

I am writing a standalone script using QGIS processing plugins. everything works but after adding a new command it gives me some errors. The command is as folloing: processing.runalg("grass7:v.clean",...
1
vote
1answer
1k views

MGRS grid in QGIS

I'm trying to generate a Military Grid Reference System (MGRS) grid on QGIS (with polygons in scale of 100m), such a grid will be similar to when importing a grid made of shapefiles (such as http://...
2
votes
1answer
213 views

QGIS treatment modeler to python script

I'm trying to make a little tool who do a concave hull, and calculate its surface in a new field. I'm not a python pro, so I began with treatment modeler like this : It works very well ! But I have ...
1
vote
0answers
56 views

Keep dialog displayed while processing

I'm working on a plug-in for QGIS and I'm a bit stuck on a problem with my dialog (realized on Qt Designer). Indeed, I added a progression bar wich seems to work, but I can't really check this ...
1
vote
0answers
23 views

Append object from another layer to the new layer through form (drop-down list)

I'm trying to get to know is it possible to append object from another layer to the new layer through form (drop-down list)? Do I need to create an application? If yes please tell me what language ...
1
vote
1answer
913 views

Get a point value with psycopg2 and PPyGIS

I'm trying to setup a basic working postgis setup with python ppygis package. >>> import psycopg2 >>> import ppygis >>> connection = psycopg2.connect(database='spre', user='...