qgis

How do I access a shapefile using gdal?

How do I access a shapefile using gdal? Question: I am trying to use the following code to access a shapefile: import os from osgeo import gdal from osgeo import ogr from osgeo import osr shp_path = "xxxxxxxx" if __name__==’__main__’: ogr.RegisterAll() gdal.SetConfigOption("SHAPE_ENCODING", "UTF-8") gdal.SetConfigOption("GDAL_FILENAME_IS_UTF8", "YES") oDriver = ogr.GetDriverByName("ESRI Shapefile") path_list= os.listdir(shp_path) for dir in path_list: …

Total answers: 1

Error while installing QGIS on Ubuntu 20.04

Error while installing QGIS on Ubuntu 20.04 Question: I’m trying to install QGIS for ubuntu 20.04 with this guide https://freegistutorial.com/install-qgis-on-ubuntu-20-04-focal-fossa/ I managed step one and successfully installed and upgradedgnupg software-properties-common, but when trying out step 2 i get the following message: gpg: key 46B5721DBBD2996A: public key "QGIS Archive Automatic Signing Key (2021) <[email protected]>" imported gpg: …

Total answers: 1

Issues resampling raster to the resolution of another raster

Issues resampling raster to the resolution of another raster Question: I am trying to take a population raster and resample+reproject it to match the shape and resolution of a precipitation raster. Data Links: Population Data: https://figshare.com/ndownloader/files/10257111 Precipitation Data: https://www.ncei.noaa.gov/data/nclimgrid-monthly/access/nclimgrid_prcp.nc The Population Data is a series of rasters per decade of 5 different population models covering …

Total answers: 1

How to use Graphviz Python module in Qgis Environment?

How to use Graphviz Python module in Qgis Environment? Question: I installed the graphviz python module with pip commend python -m pip install graphviz later i set the environment system variables then tried in small code in Qgis python console import graphviz print(‘Graphviz running’) dot = graphviz.Digraph(‘YPN-PN-101′, comment=’SLD’) dot.node(‘YPN-CA-1’, ‘CABINATE’) dot.node(‘YPN-AN-1-1’, ‘AN1’) dot.node(‘YPN-AN-2-1’, ‘AN2’) dot.node(‘YPN-AN-3-1’, …

Total answers: 1