Problem with DF Run Urban Weather Generator (DragonFly) component

I wanted to ask you how to solve this problem:

  1. Solution exception:The UWG failed to run:
    UWG model simulation failed.
    math domain error
    Traceback (most recent call last):
    File “C:\Program Files\ladybug_tools\python\lib\site-packages\uwg\cli\”, line 50, in simulate_json_model
    File “C:\Program Files\ladybug_tools\python\lib\site-packages\uwg\”, line 1352, in simulate
    File “C:\Program Files\ladybug_tools\python\lib\site-packages\uwg\”, line 38, in urbflux
    BEM[j].building.BEMCalc(UCM, BEM[j], forc, parameter, simTime)
    File “C:\Program Files\ladybug_tools\python\lib\site-packages\uwg\”, line 539, in BEMCalc
    psychrometrics(self.indoor_temp, self.indoor_hum, forc.pres)
    File “C:\Program Files\ladybug_tools\python\lib\site-packages\uwg\”, line 52, in psychrometrics
    alpha = log(_pw)
    ValueError: math domain error

I have this situation in model, I don’t know if the buildings that start from the bottom are a problem.:

How to resolve?

Hey @icryptonite ,

It sounds like this issue has more to do with your weather file than it does with the model geometry since the module that’s failing is the psychometrics module and it seems like you’re trying to compute an impossible relative humidity.

Do you want to upload your EPW and your .json file written by the “Run UWG” component to see if I can recreate the error?

Thank you for your answer @chris .

Sure, this is EPW file:
ITA_Roma-Ciampino.162390_IGDG (2).zip (157.1 KB)

Unfortunately the .json file also failed to be created due to the problem I presented.

Now the UWG run component gives me this problem without having changed any geometry:

0. Runtime error (AssertionException): Building footprint areas [0.22969963195 m2] cannot be larger than the terrain area [0.0175140171821 m2].

  line 301, in to_uwg_dict, "C:\Program Files\ladybug_tools\python\Lib\site-packages\dragonfly_uwg\properties\"
  line 26, in model_to_uwg, "C:\Program Files\ladybug_tools\python\Lib\site-packages\dragonfly_uwg\"
  line 48, in run_uwg, "C:\Program Files\ladybug_tools\python\Lib\site-packages\dragonfly_uwg\"
  line 86, in script

I’m also sure the building footprints are smaller than the surface.
I will wait for your reply.

I am also sending you the structure of the .gh file becouse I cannot upload files heavier than 1.96mb.

@icryptonite ,

That message pretty clearly tells you something is wrong. The combined area of the buildings in your district is less than one square meter. So you’re pretty clearly using the wrong units in your Rhino model.

I didn’t have any issues simulating your EPW for a month with the sample file here. I recommend starting small and then gradually working towards greater complexity.

Thank you @chris for your very kind reply, I tried with your file and actually now everything works correctly. I don’t know exactly why we honestly worked on the same structure.

However I wanted to take advantage of your presence to ask you if it is necessary to cut the buildings to obtain a correct analysis or if the plugin only considers the part of the building that is above the mesh and therefore I can leave the buildings starting from scratch, and if which I can’t do so could you send me a structure that works correctly with the plugin? Because I tried to cut them with project but then I get non regular polysurfaces and I get Room2D error of course.

1 Like

Hi @icryptonite ,

If you are asking whether the workflow knows what parts of your building are a basement based on the terrain input, the answer is “no it does not.” You would need to set some of the stories of your dragonfly buildings to basements using the DF BC by Orientation component. So the default is to consider everything above ground and, if you ask my opinion, this is good enough as long as you don’t have two or more stories below ground.