[GRASS-user] r.width.funct in correct version
Helmut Kudrnovsky
hellik at web.de
Tue Mar 5 03:04:39 PST 2019
margherita wrote
> Hi,
>
> I could not reproduce the error. To me the example just works, there are
> only some deprecation warnings.
>
> r.width.funct map=dist2out image=test
> 100%
> Tot. cells 88407.0
> Tot. area 8840700.0
> Max distance 7714.591101
> /usr/lib64/python2.7/site-packages/matplotlib/cbook.py:136:
> MatplotlibDeprecationWarning: The WX backend is deprecated. It's untested
> and will be removed in Matplotlib 2.2. Use the WXAgg backend instead. See
> Matplotlib usage FAQ for more info on backends.
> warnings.warn(message, mplDeprecation, stacklevel=1)
> ===========================
> Width Function | quantiles
> ===========================
> 883 | 0.05
> 1756 | 0.15
> 2763 | 0.3
> 3218 | 0.4
> 3661 | 0.5
> 4218 | 0.6
> 4893 | 0.7
> 5926 | 0.85
> 6984 | 0.95
>
>
> Done!
>
> Kind regards,
tested here with
GRASS Version: 7.4.2
GRASS SVN revision: r73591
Build date: 2018-10-23
Build platform: x86_64-w64-mingw32
GDAL: 2.3.2
PROJ.4: 5.2.0
GEOS: 3.7.0
SQLite: 3.17.0
Python: 2.7.14
wxPython: 2.8.12.1
Platform: Windows-7-6.1.7601-SP1 (OSGeo4W)
++++++++++
r.width.funct --verbose map=dist2out at user1 image=C:\temp\baer\test.png
('Tot. cells', 88407.0)
('Tot. area', 8840700.0)
('Max distance', 7714.591101)
Traceback (most recent call last):
File "C:\Users\KUDRNOVSKY\AppData\Roaming\GRASS7\addons/sc
ripts/r.width.funct.py", line 135, in <module>
sys.exit(main())
File "C:\Users\KUDRNOVSKY\AppData\Roaming\GRASS7\addons/sc
ripts/r.width.funct.py", line 84, in main
prc[0,0] , prc[0,1] = findint(kl,0.05) , 0.05
File "C:\Users\KUDRNOVSKY\AppData\Roaming\GRASS7\addons/sc
ripts/r.width.funct.py", line 128, in findint
z1, z2, f1, f2 = kl[int(Xf[0])][0], kl[int(Xf[0]-1)][0],
kl[int(Xf[0])][1], kl[int(Xf[0]-1)][1]
IndexError: invalid index to scalar variable.
+++++++++
still the same error
-----
best regards
Helmut
--
Sent from: http://osgeo-org.1560.x6.nabble.com/Grass-Users-f3884509.html
More information about the grass-user
mailing list