hat said, the processes that would benefit most from it in Rhino and Grasshopper actually lend themselves remarkably well to multi-threading. Things like Intersections, Meshing, operations on individual items in arrays would all benefit since they involve a lot of repetition where one iteration does not depend on the previous one.
Rhino4 was not designed to be threadsafe, and there were places where it was not possible to thread certain tasks. For example, imagine the Contour command. You'd think that it would be a piece of cake to thread that, you assign the first 25 contour intersections to core 1, the next 25 to core 2, the next 25 to core 3 and so on and so forth. But as it turns out intersecting a Brep and a Plane requires Rhino to build a spatial tree of the Brep first (assuming it doesn't exist yet). These trees vastly speed up a lot of operations and they are created lazily, meaning they get created the first time they are needed. Now we suddenly have four threads all trying to run a Brep Plane intersection and all trying to build the same spatial tree at the same time. This cannot end well. So in Rhino5 we made sure that when the spatial tree is getting build, every other thread that tries to access the Brep gets put on hold until the tree is done.
Then there's problems that the Intersection function might store temporary data on the Brep during the intersection, which makes threading intersections on the same Brep an absolute impossibility.
Then there's the even worse problem that the Intersection function might store temporary data in a static cache, which means you cannot run the function more than once at a time, even if it's on different Breps.
In Rhino5 we tried to rectify all of these problems. I think we got most of them by now.
When Grasshopper switches to Rhino5 for good, we'll start looking into threading a lot more seriously, not in the least because we'll also switch to .NET 4, which has some pretty cool mechanisms for writing decent MT code.
Until then, we'll have to stick to good old fashioned optimization. Christoph's problem was that it takes 12 minutes to open a file. Even if you thread that and you get 100% efficiency (which you won't, there's always additional overhead when threading) it would still take 3 minutes if you have 4 cores. It's an improvement sure, but not much of one. I'd like to know exactly where all that time is spend, then maybe we can remove specific bottlenecks.
--
David Rutten
david@mcneel.com
Poprad, Slovakia…
TB of RAM. I think I'm going to start a GoFundMe campaign to buy one for myself :)
2- The server's cost is about $13 an hour. I get free access to supercomputer through my university and xsede.org because I earned an NSF Honorable mention last March, however, the supercomputers available through both resources are a little complicated for me to use, as opposed to the one available from amazon that has Microsoft server 2012 already installed.
3- I wanted to run 400 annual glare simulations for 400 different views.
4- I tried a to perform annual glare simulation for one view on my Dell XPS that has Intel Core i7-6700HQ processor and 16GB of system memory. The simulation took 2 hours to complete. Radiance parameter ab was set to 6.
5- I wanted to obtain the batch file for each view so I can run them on the server. So I used the fly component to run all 400 simulations and closed the cmd windows, that wasn't bad ( for me at least) because I asked my son to this job for me, he was just glad to help me :)
6- I created one batch file using this cmd command:
dir /s /b *.bat > runall.bat
This created a file with the path to each .bat file. I edited this file in Notepad++ to include the word "start" at the beginning of each line. This was done using the "find and replace" dialogue box.
7- I split my newly created batch file into 3 batch files, each one has about 130 file names and " start" before the file names.
8- installed radiance on my server
9- Ran the first batch file on the server, this started 130 cmd windows performing my simulations, CPU usage was anywhere between 90% to 100% and about 105 GB of RAMs were used.
10. It took about 5 hours to complete all 130 simulations, I expected to run all in 2 hours but can't complain because this would've taken about 260 hours to run on my laptop. After the simulations done I ran the second and then the third batch files ( total of about 15 hours).
11. I got 400 valid dgb files. Couldn't be happier!
…
rld.wolfram.com/EnnepersMinimalSurface.html
when i type the equations for z,y,z it says a syntax error so i obviously do not understand how to construct an expression. (screen capture attached)
Any help/explanation of using this function would be greatly appreciated
thanks so much
Capture.JPG…
how it look like:
Thanks again!
import rhinoscriptsyntax as rs
#flag 1 = intersecting, or one inside another#flag 0 = not intersecting, or just touching each other
def checkintersection(obj,brep,tol): test = rs.IsObjectInBox(obj, rs.BoundingBox(brep), test_mode=True) insec=rs.IntersectBreps(obj,brep,tol) if test == True and not insec: flag = 1 elif insec: insec=rs.IntersectBreps(obj,brep,tol) #if one object is inside the other flag1 = minDistanceTwoBreps(obj1, obj2, tol) flag2 = minDistanceTwoBreps(obj2, obj1, tol) rs.DeleteObjects(insec) if flag1 == 0 and flag2== 0 : flag = 0 else: flag = 1 return flag
def minDistanceTwoBreps(obj1, obj2, tol): if (tol is None) or tol < 0.0: tol = rs.UnitAbsoluteTolerance() pt1 = rs.SurfaceVolumeCentroid(obj1)[0] pt2 = rs.BrepClosestPoint(obj2, pt1)[0] dist = 100 precision = 3 # the larger the number - the more precise the distance i = 0 while (dist > tol) and (i < precision): pt1 = rs.BrepClosestPoint(obj1, pt2)[0] pt2 = rs.BrepClosestPoint(obj2, pt1)[0] dist = rs.Distance(pt1,pt2) i += 1 if dist <= tol: flag = 0 else: flag = 1 return flag
obj1 = rs.GetObject("select object 1")obj2 = rs.GetObject("select object 2")tol = rs.UnitAbsoluteTolerance()
flag = checkintersection(obj1, obj2, tol)
print flag…
ion of surfaces and/or "solids" : it's a very complex assembly of "components" either bespoke or widely available in the market. This demo combo summarizes the "common" cases (but the insulation for the opaque parts is WRONG 100%):
2. Contemporary trends (a bit of nonsense) point towards "liquid" forms. These ARE NOT made via "classic" linear systems. Very few actually can do it (I mean: do it yielding a building that doesn't leak]). Here's a totally wrong take on that matter from a very reputable Swiss facade maker:
And er ... hmm ... this :
3. Facade systems (curtain walls, that is) are classified in 4 classes: (a) the good old known humble stuff like the one shown in the first image (b) semi structural [yes], (c) structural [NO] and (d) planar frame-less systems.
4. Designing any proper facade is impossible with Rhino/GH: you'll need totally different software apps to do it - in real life - despite what most people believe/hope/wish.
5. Designing anything without a proper bottom-top approach (I.e. : first do the pistons then the engine) is the best recipe for not becoming (ever) a pro .…
Dogs) i.e. the Holly Grail in Engineering/Design ... although rather easy is 100% impossible without code (especially when you need to manage "solution variations" (alternatives) and recall them any time) ... but I have a strong feeling that you wouldn't be able to handle this: expert only territory. Make a test: get a flat 2d grid of points (a Tree with a single dimension) and attempt to modify Z in points that you choose on a per point basis.
"Impossible" eh?
3. Without Mesh Machine areas like this:
would buy you a ticket to hell (one way).
All in all: doing this properly (The interactive part whilst checking valid typologies PLUS this, this and that) IS NOT a task for a novice by any means. I would strongly suggest ... er ... hmm ... the Soap Opera approach (but this also requires code if a non rectangular grid is used as a "mesh template").…
e point in each pair that has the lowest Z value (then later the highest Z)... The problem is the intersections are not returned sorted by Z, sometimes the lower point is first in the list, sometimes last. So I need to sort those pairs of points by Z value.I noticed the sort points component does not have any inputs for sort criteria... RhinoScript SortPoints allows you to sort by:
blnOrder
Optional. Number. The component sort order, where:
Value
Component Sort Order
0 (default)
X, Y, Z
1
X, Z, Y
2
Y, X, Z
3
Y, Z, X
4
Z, X, Y
5
Z, Y, X
Will we get something like this in GH? For now I think I can manage to analyze the Z for each and re-order the points, but a more comprehensive point sorting tool might be nice... no? Or did I miss something obvious? --Thx, --Mitch…
n due at the end of march. i am hoping to see if i can do this as a sort of "HIVE MIND" experiment with one or two or more posters to the forum. i have uploaded two files to http://www.formpig.com/nine_bar-FAR and I have the following goals:
1. To "kinematically iterate" various formal building envelopes based upon a 50' x 100' lot that "conform" to the nine bar linkage geometry.
2. This lot would have "setbacks" consisting of two 5' side setbacks, a 10' rear yard setback and a 25' front yard setback. max height on the structure is 32' and the allowable overhangs into the setbacks are 2'. I would like to find a way to use the "nine bar geometry" to construct a series of iterations for "floors", "walls" and "ceilings", which would then be tied to a volumetric (cubic volume), or a total square footage (perhaps based upon two horizontal section cuts) which was based upon a given number that I will provide per local building code.
3. Laid on top of this we would also have "mcmansion ordinance" requirements based upon the pdf enclosed. i expect to have this "tent restriction" data in digital form to upload to ftp shortly.
It would be up to you individually or collectively to determine how best to position this "in the real world" based upon the lot, setbacks, zoning requirements etc. For instance, perhaps the nine bar configuration has its vertices coplanar with the 50' x 100' x 32' envelope restrictions and then the chosen volume is "trimmed' by the setback requirements. Or perhaps the nine-bar configuration is generated completely within the setbacks, or perhaps it is generated 2' outside of the setbacks so as to take advantage of the 2' overhang allowance on the setbacks, etc.
*
Given an opportunity to develop the work in a second phase we would have an opportunity to tie this into various efficiencies such as Bill of Materials (wall floor and ceiling square foot calculations), envelope to volume calculations, solar panel efficiencies (solar orientation and envelope geometry) etc, etc (love to get suggestions for this).
*
I've become /really/ convinced that this would be a /really/ interesting entry based upon my just finishing up Kas Oosterhuis' Towards a New Kind of Building: A Designer's Guide for Non-Standard Architecture". In an ideal world I was hoping that it would be possible to hash this out discussion-wise and then literally passing it around on the list after someone eventually made the first move by tossing out a rough ghx script. My expectation would be to finalize it rapidly in the next two weeks. Something of a contemporary version of a design charette.
However, I realize this may not be workable so if you have experience in this arena and particularly if you think this is a brief that is straighforward enough to be almost literally implemented in Grasshopper, please contact me for any wage and/or contract fee requirements.
I'm getting a bit of a late jump on this but my hope is that with the right participant(s) that I can thrash it together quick enough for the first round.
info@formpig.com…
The PC actually stops working because after a few seconds the simulation starts the fan inside the PC all of a sudden stops and for the next 5-10 mins I cannot do anything, even alt+ctrl+canc. After I wait for that time i get the followig error:
the ReadMe says:
{0;0;0}0. Grid-based Radiance simulation1. The component is checking ad, as, ar and aa values. This is just to make sure that the results are accurate enough.2. -ar is set to 300.3. Good to go!4. Current working directory is set to: C:\Users\Luigi\Desktop\Prova__\Prova_1\gridBasedSimulation\5. Found a trans material... Resetting st parameter from 0.85 to 0.011276004966. WMIC PROCESS get Commandline7. WMIC PROCESS get Commandline8. WMIC PROCESS get Commandline9. WMIC PROCESS get Commandline10. WMIC PROCESS get Commandline11. WMIC PROCESS get Commandline12. WMIC PROCESS get Commandline13. WMIC PROCESS get Commandline14. WMIC PROCESS get Commandline15. WMIC PROCESS get Commandline16. WMIC PROCESS get Commandline17. WMIC PROCESS get Commandline18. WMIC PROCESS get Commandline19. WMIC PROCESS get Commandline20. WMIC PROCESS get Commandline21. WMIC PROCESS get Commandline22. WMIC PROCESS get Commandline23. WMIC PROCESS get Commandline24. WMIC PROCESS get Commandline25. WMIC PROCESS get Commandline26. WMIC PROCESS get Commandline27. WMIC PROCESS get Commandline28. WMIC PROCESS get Commandline29. WMIC PROCESS get Commandline30. WMIC PROCESS get Commandline31. WMIC PROCESS get Commandline32. WMIC PROCESS get Commandline33. WMIC PROCESS get Commandline34. WMIC PROCESS get Commandline35. WMIC PROCESS get Commandline36. WMIC PROCESS get Commandline37. WMIC PROCESS get Commandline38. WMIC PROCESS get Commandline39. WMIC PROCESS get Commandline40. WMIC PROCESS get Commandline41. WMIC PROCESS get Commandline42. WMIC PROCESS get Commandline43. WMIC PROCESS get Commandline44. WMIC PROCESS get Commandline45. WMIC PROCESS get Commandline46. WMIC PROCESS get Commandline47. WMIC PROCESS get Commandline48. WMIC PROCESS get Commandline49. WMIC PROCESS get Commandline50. WMIC PROCESS get Commandline51. WMIC PROCESS get Commandline52. WMIC PROCESS get Commandline53. WMIC PROCESS get Commandline54. WMIC PROCESS get Commandline55. WMIC PROCESS get Commandline56. WMIC PROCESS get Commandline57. WMIC PROCESS get Commandline58. WMIC PROCESS get Commandline59. WMIC PROCESS get Commandline60. WMIC PROCESS get Commandline61. WMIC PROCESS get Commandline62. WMIC PROCESS get Commandline63. WMIC PROCESS get Commandline64. WMIC PROCESS get Commandline65. WMIC PROCESS get Commandline66. WMIC PROCESS get Commandline67. WMIC PROCESS get Commandline68. WMIC PROCESS get Commandline69. WMIC PROCESS get Commandline70. WMIC PROCESS get Commandline71. WMIC PROCESS get Commandline72. WMIC PROCESS get Commandline73. WMIC PROCESS get Commandline74. WMIC PROCESS get Commandline75. WMIC PROCESS get Commandline76. WMIC PROCESS get Commandline77. WMIC PROCESS get Commandline78. WMIC PROCESS get Commandline79. WMIC PROCESS get Commandline80. WMIC PROCESS get Commandline81. WMIC PROCESS get Commandline82. WMIC PROCESS get Commandline83. WMIC PROCESS get Commandline84. WMIC PROCESS get Commandline85. WMIC PROCESS get Commandline86. WMIC PROCESS get Commandline87. WMIC PROCESS get Commandline88. WMIC PROCESS get Commandline89. WMIC PROCESS get Commandline90. WMIC PROCESS get Commandline91. WMIC PROCESS get Commandline92. WMIC PROCESS get Commandline93. WMIC PROCESS get Commandline94. WMIC PROCESS get Commandline95. WMIC PROCESS get Commandline96. WMIC PROCESS get Commandline97. WMIC PROCESS get Commandline98. WMIC PROCESS get Commandline99. WMIC PROCESS get Commandline100. WMIC PROCESS get Commandline101. WMIC PROCESS get Commandline102. WMIC PROCESS get Commandline103. WMIC PROCESS get Commandline104. WMIC PROCESS get Commandline105. WMIC PROCESS get Commandline106. WMIC PROCESS get Commandline107. WMIC PROCESS get Commandline108. WMIC PROCESS get Commandline109. WMIC PROCESS get Commandline110. WMIC PROCESS get Commandline111. WMIC PROCESS get Commandline112. WMIC PROCESS get Commandline113. WMIC PROCESS get Commandline114. WMIC PROCESS get Commandline115. WMIC PROCESS get Commandline116. WMIC PROCESS get Commandline117. WMIC PROCESS get Commandline118. WMIC PROCESS get Commandline119. WMIC PROCESS get Commandline120. WMIC PROCESS get Commandline121. WMIC PROCESS get Commandline122. WMIC PROCESS get Commandline123. WMIC PROCESS get Commandline124. WMIC PROCESS get Commandline125. WMIC PROCESS get Commandline126. WMIC PROCESS get Commandline127. WMIC PROCESS get Commandline128. WMIC PROCESS get Commandline129. WMIC PROCESS get Commandline130. WMIC PROCESS get Commandline131. WMIC PROCESS get Commandline132. WMIC PROCESS get Commandline133. WMIC PROCESS get Commandline134. WMIC PROCESS get Commandline135. WMIC PROCESS get Commandline136. WMIC PROCESS get Commandline137. WMIC PROCESS get Commandline138. WMIC PROCESS get Commandline139. WMIC PROCESS get Commandline140. WMIC PROCESS get Commandline141. WMIC PROCESS get Commandline142. WMIC PROCESS get Commandline143. WMIC PROCESS get Commandline144. WMIC PROCESS get Commandline145. WMIC PROCESS get Commandline146. WMIC PROCESS get Commandline147. WMIC PROCESS get Commandline148. WMIC PROCESS get Commandline149. WMIC PROCESS get Commandline150. WMIC PROCESS get Commandline151. WMIC PROCESS get Commandline152. WMIC PROCESS get Commandline153. WMIC PROCESS get Commandline154. WMIC PROCESS get Commandline155. WMIC PROCESS get Commandline156. WMIC PROCESS get Commandline157. WMIC PROCESS get Commandline158. WMIC PROCESS get Commandline159. WMIC PROCESS get Commandline160. WMIC PROCESS get Commandline161. WMIC PROCESS get Commandline162. WMIC PROCESS get Commandline163. WMIC PROCESS get Commandline164. WMIC PROCESS get Commandline165. WMIC PROCESS get Commandline166. WMIC PROCESS get Commandline167. WMIC PROCESS get Commandline168. WMIC PROCESS get Commandline169. WMIC PROCESS get Commandline170. WMIC PROCESS get Commandline171. WMIC PROCESS get Commandline172. WMIC PROCESS get Commandline173. WMIC PROCESS get Commandline174. WMIC PROCESS get Commandline175. WMIC PROCESS get Commandline176. WMIC PROCESS get Commandline177. WMIC PROCESS get Commandline178. WMIC PROCESS get Commandline179. WMIC PROCESS get Commandline180. WMIC PROCESS get Commandline181. WMIC PROCESS get Commandline182. WMIC PROCESS get Commandline183. WMIC PROCESS get Commandline184. WMIC PROCESS get Commandline185. WMIC PROCESS get Commandline186. WMIC PROCESS get Commandline187. WMIC PROCESS get Commandline188. WMIC PROCESS get Commandline189. WMIC PROCESS get Commandline190. WMIC PROCESS get Commandline191. WMIC PROCESS get Commandline192. WMIC PROCESS get Commandline193. WMIC PROCESS get Commandline194. WMIC PROCESS get Commandline195. WMIC PROCESS get Commandline196. WMIC PROCESS get Commandline197. WMIC PROCESS get Commandline198. Runtime error (IndexOutOfRangeException): index out of range: 0199. Traceback: line 320, in script
The thing is that if I raise the -aa parameter from 0.05 to 0.1 all works fine..
Is this only related to my PC then?? What should I do to solve this issue?
Thanks again for your help
Luigi…
I am not knowledgeable about google maps nor google maps api, but from what I read the two components will definitely show a bit different results due to different topography sources.If it is judging by this 2010 article, your Terrain Generator component offers much higher precisions for USA. Precision goes up to a couple of meters, which is amazing!!On the global scale it offers either SRTM 1 or 3 arc-second data or 30 arc-second GLOBE data. Again this is from the mentioned article, I couldn't find this information by searching the Google Maps website.Terrain Generator 2 component always uses SRTM 1 arc-second data from opentopography.org, and it is limited to 60 degrees north and does not have data for Antarctica. It does not come with satellite image either which is another very convenient feature that you have!I couldn't find information about the allowed radius provided by the Google maps api free account. I limited the "radius_" input to 100 000 meters, even though opentopography.org provides more than that (I successfully downloaded 300 000, but Rhino 5 was not able to create a topography on my PC from such a large amount of data).Even though I couldn't compare the results from two components, by looking at your upper example_LB_terrain_generator.gh definition: set the "I" input of "Surface from points" component to True. In this way the surface will be interpolated through points, which is what we want.
Again thank you for the permission, and I look forward seeing those high precision topography that Google maps offers!!…