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

Error when running Urban Morphology: Morphometric Calculator (Point) #639

Closed 030Skript closed 2 months ago

030Skript commented 2 months ago

Hello together,

Describe the bug Problem encountered when try to run the Urban Morphology: Morphometric Calculator (Point) same issue like here: https://github.com/UMEP-dev/UMEP/issues/540

To Reproduce

Steps to reproduce the behavior:

Go to 'Urban Morphology: Morphometric Calculator (Point)'
Choose point of interest
Search distance: 200m, Wind direction search interval (degree): 5
Select raster layers of DSM and DEM
Select Kanda et al. (2013) Method
Add prefix, select saving directory and run the plugin

Error message appears: 2024-08-27T16:17:29    "CRITICAL    Traceback (most recent call last):
          File "C:\Users/User/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\processing_umep\preprocessor\imagemorphparmspoint_algorithm.py", line 247, in processAlgorithm
          immorphresult = morph.imagemorphparam_v2(dsm, dem, scale, 1, degree, feedback, 1)
          File "C:\Users/User/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\processing_umep\util\imageMorphometricParms_v2.py", line 100, in imagemorphparam_v2
          lineMid = a[0:imidy,imid]
         IndexError: only integers, slices (`:`), ellipsis (`...`), numpy.newaxis (`None`) and integer or boolean arrays are valid indices"

Desktop (please complete the following information):

Data https://tubcloud.tu-berlin.de/s/D6KtkbSS7TGjLfJ

DSM (Veg+Build), DEM (Ground) related Fluxtower

Additional context

I checked extent, resolution, dims, everything seemed to be fine. Also reprojected the data twice (EPSG: 4326/25833) but still encountering this issue. Especially strange because I used the same data in SUEWS Prepare and it worked perfectly fine. Basicly looking for Z0 for the FFP (I wasn't sure how to use the files/combine the values for Z0 created in SUEWS Prepare for build/veg as this is not my main topic).

Thank you in advance, I really appreciate your work! :)

biglimp commented 2 months ago

I might actually fixed this before but didnt submit to the repository. Try development version 2.0.30 and report back this fixed your issue.

030Skript commented 2 months ago

No more errors, so it seems to be working. Thank you very much đź‘Ť