UMEP-dev / UMEP

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

Python error when running the UMEP footprint model #591

Closed lkarch closed 3 months ago

lkarch commented 4 months ago

Hello,

Every time I try to run the Source Area Model I get the following python error: WARNING Traceback (most recent call last): File "/Users/User/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/UMEP/FootprintModel/footprint_model.py", line 572, in start_process fp.footprintiterKAM(iterations=it,z_0_input=z_0_input,z_d_input=z_d_input,z_ag=z_m_input,sigv=sigv, File "/Users/User/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/UMEP/FootprintModel/KingsFootprint_UMEP.py", line 132, in footprintiterKAM exc = -xsi/x[:,:,0] FloatingPointError: divide by zero encountered in divide

This happens even when I use the DSM and DEM files and the parameters from the UMEP tutorial (both for London and Reading).

Desktop:

biglimp commented 4 months ago

Hi, I cannot replicate your error. I just tested on the London dataset. Using the default settings from the tutorial. I can think of a couple issues that you can check.

  1. Try on QGIS 3.32
  2. Try something else than a macOS
  3. Make sure you set your point not close to the edge of the DSM
  4. Make sur eyou use the correct CRS

I have:

lkarch commented 4 months ago

Thank you! I tried using Windows 10 with QGIS 3.28 and I don't get this bug with this setup

biglimp commented 4 months ago

I found a PC with QGIS 3.34.1, Windows 10 and I dont get this bug. It seems to be closing in on the macOS. Would it be possible for you to try QGIS lower than 3.34 on a macOS? Personally, I dont have access to such a setup.

biglimp commented 3 months ago

@lkarch , did you solve this? Can I close?

lkarch commented 3 months ago

I did not manage to try on a lower version on macOS but it works perfectly on Windows 10! I think you can close.