Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SVF in ViewAnalysis component #229

Closed
ayezioro opened this issue Jan 26, 2016 · 4 comments
Closed

SVF in ViewAnalysis component #229

ayezioro opened this issue Jan 26, 2016 · 4 comments

Comments

@ayezioro
Copy link
Contributor

Hi,
I'm dealing with the following error in the ViewAnalysis component when i try to do SVF analysis:

  1. Solution exception:name 'viewPtsWeights_' is not defined
    When i reinsert/reconnect all inputs it works. But when i save, close and open it complains again about the same.
    I notice that when i connect any of the possible values to the viewTypeOrPoints input the clean component changes the name of the input viewPtsWeights to viewResolution.
    When opening the file If i disconnect the _viewTypeOrPoints and reconnect it works.

Thanks,
-A.

@chriswmackey
Copy link
Member

@ayezioro ,
Thanks, as always, for finding these bugs. This one was happening because I made some of the inputs change their name depending on the viewType. It has now been fixed:
eec412d
-Chris

@ayezioro
Copy link
Contributor Author

ayezioro commented Feb 9, 2016

Hi Chris,
Unfortunately i'm asking to re-open the issue. As for this discussion (http://www.grasshopper3d.com/group/ladybug/forum/topics/error-on-the-run-daylight-simulation-component-for-the-sky-view?commentId=2985220%3AComment%3A1458580&xg_source=msg_com_gr_forum) i think i've found weird behaviours/bugs in the LB_ViewAnalysis regarding the SVF.
See this file: https://www.dropbox.com/s/p4kcno76k9nlzyh/viewVectorDisplay_AY.gh?dl=0
As you can see the vertical surfaces are receiving 100 and /or different results. Also you can see that the vectors are not "equally" located amongst the grid points. Some have all the hemisphere and others have only 1 pointing north.
In the case from the discussion i've found also that with resolution 0 i get some results and increasing the resolution i get a completely different set of results. Specially on east/west vertical surfaces.

Sorry for describing this so vaguely, but i can't catch exactly why is this happening.

Thanks,
-A.

@chriswmackey
Copy link
Member

@ayezioro ,
Thank you for posting this. There were a total of 3 issues that were present in the file you uploaded and the discussion you were having with Grasshope.

The first was a very severe bug in the function that runs the view analysis, which was assigning incorrect point weights to the vectors after the first mesh (this is why you were getting view values of 100 next to the surface). This resulted from the fact that I wanted to have the same function handle both cases of view points and view vectors and the view points are meant to make use of the point weights while they should be absent from the view vectors (they were not).

The second issue was that I was not accounting for the areas of the sky patches with the view vector calculations and I was treating each sky patch as if it had an equal area. This is not a huge error as the original intention of the Tregenza sky dome was to have as even a number of patches as possible. However, not accounting for the slight variations in area was causing errors of +/-2% that were not improving with higher view resolutions. I have since included weights for the vectors based on the patch area, which ensures that you can get very high accuracy simulations with high view resolutions. In the cases that I was trying with view resolutions of 3, all errors were below 1%.

The third issue was just a misunderstanding with what the output of the viewVectors is meant to be. Namely, I only return one copy of the view vectors so that I do not make the output too heavy but the calculation is actually projecting all of these vectors from all of the points. So, if you want to see a visual of the view vectors projecting from all of the points, you have the graft the points as they go into the 'vector Display' component. Otherwise, Grasshopper tries to assign one vector to each point.

All of this has been fixed with this github commit:
90f3898
And your fixed GH file can be found here:
https://www.dropbox.com/s/cbt32vbb0qyk11v/viewVectorDisplay_AY_CWM.gh?dl=0

-Chris

@ayezioro
Copy link
Contributor Author

ayezioro commented Feb 9, 2016

Wow!
So many things in such a small file, ah?
Thanks!!!
-A.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants