Parametric design
About Rhino & Grasshopper and PARAM-O.

ISSUE between Grasshopper coordinate points and ArchiCAD components

Nader Belal
Mentor
Hi there,

I just wanted to draw your attention to an issue I have just experienced (not a problem, but it might be for big or highly detailed models).

I have created a GHpython component that takes points (in Rhino or GH) and adjusts their number of decimal spaces with the aim to get X, Y, Z coordinates, 2D point coordinates, and 3D point coordinates from the input list (to model a mesh).

I have observed that in GHpython if I have created a list comprehension functions that export the 3D point coordinates as text in a Rhino format (the one with curly brackets) it take about 3x more than if I used rhino.geometry.point3D method.

In Grasshopper that usually doesn't happen.

Best regards,
Nader Belal
A good friend of mine have once told me that I´m so brute that I´m capable of creating a GDL script capable of creating GDLs.
4 REPLIES 4
leceta
Expert
Hi moonlight, please have a look to the attached image
Nader Belal
Mentor
THank you.

Side question, why are you using an iterator ??
A good friend of mine have once told me that I´m so brute that I´m capable of creating a GDL script capable of creating GDLs.
leceta
Expert
I'am not sure what are you calling "iterator" to.

If you refer to the "for loop", its just make sure processing time is significant enough for GH to be printed.
If you refer to Xrange , there is not particular reason. I started my test using really really big numbers (dont ask my why), so I considered a good idea to use xrange because of its better memory management, but range could also be valid as long as this is just a test code (I guess "range" is faster than "xrange", I'am not sure)

P.S: after looking at google, I see that the "for loop" is considered an iterator, and that xrange is not an iterator but a "immutable sequence", as a tuple. Lesson learned!
leceta
Expert
FWIW, in relation to the floating point numbers rounding technique you are using, my current conclusion is that they are not effective, at least in this context (GH + ironPython).