Questions tagged [pygrass]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2
votes
0answers
23 views

GRASS GIS: r.out.gdal raises an exception and hangs if it's called multiple consecutive times

I'm using a small python routine (grass.script, pygrass) to handle several operations on sentinel2 imagery. I'm calling r.out.gdal inside the script and a very annoying problem occurs: when it is ...
0
votes
1answer
18 views

PyGRASS r.mapcalc crashes with ERROR: Unable to make mapset element

I'm trying to load a GeoTIFF and then do some calculations on it with r.mapcalc the code is as follows: from grass.pygrass.modules.shortcuts import general as g from grass.pygrass.modules.shortcuts ...
0
votes
1answer
30 views

Exporting a GeoTIFF with PyGRASS

I want to export a GeoTIFF with PyGRASS but i can't figure out how I can do that. my code so far: # import grass python libraries from grass.pygrass.modules.shortcuts import general as g from grass....
0
votes
1answer
22 views

How to load data into R via PyGRASS?

I have a remote machine where my GRASS binaries (7.8) are available and I want to apply this solution https://gis.stackexchange.com/a/255899/36712 to my data set of thousands of small images. In most ...
2
votes
0answers
53 views

Using Pygrass Functions in Jupyter gives XML Error

I have been trying to use pygrass from grass78 with Python 3.7 inside a Jupyter notebook and have run into an issue where I can import grass modules, but cannot call any pygrass functions, e.g, r....
1
vote
0answers
33 views

Can't create a vector map with VectorTopo in new mapset after switching

I need to create vector maps in different mapsets with pygrass. However, there seems to be a "hidden" global variable which prevents mapset in pygrass from changing. It sort of "memorizes" the mapset ...
2
votes
1answer
193 views

grass GIS + spyder python script error

I'm getting crazy with grass gis and python. I want to call a grass function from an external python script (using spyder for instance). I've installed QGIS + GRASS with the OSGeo4W64 installation ...
1
vote
1answer
166 views

pyGRASS on MacOS: unable to import pygrass.raster

I am running GRASS 7.3 on Mac OS 10.11.5 El Capitan. I'm trying to figure out how to get GRASS GIS running via python scripting (pygrass). I'd like to be able to access raster data programatically. ...
1
vote
0answers
80 views

Running Python script in GRASS every time map extent is altered

I am looking to develop a python script that triggers every time the user zooms or pans to a new map extent. The script I have in mind will clip a raster to the visible extent thus reclassifying the ...
1
vote
1answer
767 views

GRASS python API [closed]

I have Ubuntu 16.04 64 bit and python 2.7.12 on my system. I have installed GRASS GIS 7 from the Ubuntu software support (I thing not is the better choose for install). Now I want to take GRASS ...
2
votes
1answer
2k views

Exception using PyGRASS: “No module named 'core'”

I am trying PyGRASS on Ubuntu 14.04. I have GRASS 7 installed from the UbuntuGIS PPA: $ dpkg -l | grep grass ii grass 7.0.4-1~trusty1 ...