UMEP-dev / UMEP

Urban Multi-scale Environmental Predictor
https://umep-docs.readthedocs.io/
59 stars 15 forks source link

Problem when running Urban Morphology: Morphometric Calculator (Point) #540

Closed jassssuiiii closed 5 months ago

jassssuiiii commented 11 months ago

Describe the bug Problem encountered when running Urban Morphology: Morphometric Calculator (Point)

To Reproduce Steps to reproduce the behavior:

  1. Go to 'Urban Morphology: Morphometric Calculator (Point)'
  2. choose point of interest
  3. Search distance: 200m, Wind direction search interval (degree): 5
  4. Select raster layers of DSM and DEM
  5. Select saving directory and run the plugin
  6. Error message appears:

    QGIS version: 3.20.2-Odense QGIS code revision: 9f59a156 Qt version: 5.15.2 Python version: 3.9.5 GDAL version: 3.3.1 GEOS version: 3.9.1-CAPI-1.14.2 PROJ version: Rel. 8.1.0, July 1st, 2021 PDAL version: 2.3.0 (git-version: eac774) Processing algorithm… Algorithm 'Urban Morphology: Morphometric Calculator (Point)' starting… Input parameters: { 'FILE_PREFIX' : 'RuleOfThumb', 'INPUT_DEM' : 'C:/../Merged DTM.tif', 'INPUT_DISTANCE' : 400, 'INPUT_DSM' : 'C:/../Merged DSM.tif', 'INPUT_DSMBUILD' : None, 'INPUT_INTERVAL' : 40, 'INPUT_POINT' : '355639.739613,170300.998768 [EPSG:27700]', 'INPUT_POINTLAYER' : None, 'OUTPUT_DIR' : 'C:\Users\yizhang\Desktop', 'OUTPUT_POINT' : 'TEMPORARY_OUTPUT', 'OUTPUT_POLYGON' : 'TEMPORARY_OUTPUT', 'ROUGH' : 0, 'SAVE_POINT' : True, 'USE_DSM_BUILD' : False }

    Point location obtained manually x = 355639.739613 y = 170300.998768 Traceback (most recent call last): File "C:../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:../python/plugins\processing_umep\util\imageMorphometricParms_v2.py", line 99, in imagemorphparam_v2 lineMid = a[0:imidy,imid] IndexError: only integers, slices (:), ellipsis (...), numpy.newaxis (None) and integer or boolean arrays are valid indices

    Execution failed after 0.23 seconds

    Loading resulting layers Algorithm 'Urban Morphology: Morphometric Calculator (Point)' finished

Desktop (please complete the following information):

Screenshots If applicable, add screenshots to help explain your problem.

Data If applicable, add data files to help us reproduce your problem.

Additional context

biglimp commented 11 months ago

I suspect there is an issue regarding CRS. Can you please share your data (DSM and DEM).

biglimp commented 10 months ago

@jassssuiiii , is this issue still valid? Can I close?

biglimp commented 5 months ago

No response. Please open a new issue if this is still a problem.