UMEP-dev / UMEP

Urban Multi-scale Environmental Predictor
https://umep-docs.readthedocs.io/
GNU General Public License v3.0
62 stars 15 forks source link

SUEWS simple Morphometric calculator error #657

Closed guscarthd closed 1 month ago

guscarthd commented 1 month ago

The SUEWS simple Morphometric calculator do not work in QGIS 3.38. When using Kanada et al. (2013) as roughness calculator method the following message occur and no output is created:

WARNING    Traceback (most recent call last):               File "C:\Users/tessa/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\UMEP\ImageMorphParmsPoint\imagemorphparmspoint_v1.py", line 461, in start_process               dsm = dataset.ReadAsArray().astype(np.float)               ^^^^^^^^               File "C:\PROGRA~1\QGIS33~1.3\apps\Python312\Lib\site-packages\numpy__init.py", line 338, in getattr               raise AttributeError(former_attrs__[attr])              AttributeError: module 'numpy' has no attribute 'float'.              np.float was a deprecated alias for the builtin float. To avoid this error in existing code, use float by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.float64 here.              The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:               https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?

And when using rule of thumb (no output is created):

WARNING    Traceback (most recent call last):               File "C:\Users/tessa/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\UMEP-SuPy-QGIS3\ImageMorphParmsPoint\imagemorphparmspoint_v1.py", line 495, in start_process               zH = immorphresult["zH"]               ~~~~~^^^^^^              TypeError: 'NoneType' object is not subscriptable

biglimp commented 1 month ago

This issue is fixed in latest version of UMEP for Processing