Opened 21 months ago

Last modified 7 months ago

#3494 new defect

r.thin crashes the wxGUI after 84 passes

Reported by: pitstop Owned by: grass-dev@…
Priority: normal Milestone: 7.4.5
Component: wxGUI Version: svn-releasebranch74
Keywords: r.thin Cc:
CPU: Unspecified Platform: MSWindows 7

Description

Hi Community,

I wanted to use r.thin on a raster map before r.to.vect on the result but r.thin crashes after 84 passes every time. Smaller number of iterations run without any problems. I was able to reproduce the error by using r.thin on the elevation.dem from the Spearfish data set. The following error is printed to the console.

Exception in thread Thread-25:
Traceback (most recent call last):
  File "C:\OSGEO4~1\apps\Python27\lib\threading.py", line
808, in __bootstrap_inner
    self.run()
  File "C:\OSGEO4~1\apps\grass\grass-7.4.0\gui\wxpython\core
\gconsole.py", line 156, in run
    self.resultQ.put((requestId, self.requestCmd.run()))
  File "C:\OSGEO4~1\apps\grass\grass-7.4.0\gui\wxpython\core
\gcmd.py", line 614, in run
    self._redirect_stream()
  File "C:\OSGEO4~1\apps\grass\grass-7.4.0\gui\wxpython\core
\gcmd.py", line 643, in _redirect_stream
    self.stderr.write(line)
  File "C:\OSGEO4~1\apps\grass\grass-7.4.0\gui\wxpython\core
\gconsole.py", line 300, in write
    self.message += line.split(':', 1)[1].strip() + '\n'
IndexError: list index out of range

Any Ideas what might be going wrong?

The output of g.versoin -rge

version=7.4.0
date=2018
revision=r72154
build_date=2018-01-27
build_platform=x86_64-w64-mingw32
build_off_t_size=8
libgis_revision=70829 
libgis_date="2017-04-04 09:43:02 +0200 (Tue, 04 Apr 2017) "
proj4=4.9.3
gdal=2.2.3
geos=3.5.0
sqlite=3.17.0

Cheers,

Stefan

Change History (4)

comment:1 in reply to:  description ; Changed 21 months ago by mlennert

Replying to pitstop:

Hi Community,

I wanted to use r.thin on a raster map before r.to.vect on the result but r.thin crashes after 84 passes every time. Smaller number of iterations run without any problems. I was able to reproduce the error by using r.thin on the elevation.dem from the Spearfish data set.

While this should probably be handled more gracefully, could you explain what you are trying to do with r.thin ? Why would you run r.thin on a DEM ? r.thin is meant to thin raster lines (represented by some form of discrete pixel values) to single pixel width so as to make their vectorisation possible. Running it on a raster map with a continuous variable doesn't make sense in my understanding.

comment:2 in reply to:  1 Changed 21 months ago by mmetz

Component: RasterwxGUI

Replying to mlennert:

Replying to pitstop:

Hi Community,

I wanted to use r.thin on a raster map before r.to.vect on the result but r.thin crashes after 84 passes every time. Smaller number of iterations run without any problems. I was able to reproduce the error by using r.thin on the elevation.dem from the Spearfish data set.

While this should probably be handled more gracefully,

On the OS command line

g.region -p rast=elevation.dem
r.thin in=elevation.dem out=elevation.dem.thin it=1000

finishes successfully after 229 passes.

Apparently the problem is that the gui can't handle the messages produced by r.thin, i.e. the gui crashes, not r.thin.

comment:3 Changed 20 months ago by martinl

Milestone: 7.2.4

comment:4 Changed 7 months ago by neteler

Keywords: r.thin added
Milestone: 7.2.47.4.5
Summary: r.thin crashes after 84 passesr.thin crashes the wxGUI after 84 passes
Version: 7.4.0svn-releasebranch74
Note: See TracTickets for help on using tickets.