Automate the generation of ghx files

Hey folks, I need some help with this project I’m doing…
I need to create 200 different ghx files (and geometries) like the images below. And I can only use the same set of nodes (the ones in the last image) .
Is there a way that I can just tell the Grasshopper to generate X different files with pre-determined nodes(a c# code maybe)?
Thank you!

You could check the plugin Embryo. You cannot create X number of files but you can create X number of definitions using the same types of components then copy/paste them in separate files.

2 Likes

That is great, thankss
Is There a Way i can make the outputs be always solids?

You want to randomly connect a bunch of components but only if the final result is a specific type of shape?

No, They can be any shape, actually they need to be different

But they do need to be individual, closed polysurfaces?

Monkeys, typewriters and Shakespeare spring to mind.

3 Likes

Primordial soup?

polysurfaces, thats right
I need 200 ghx files with the max of 10 nodes that generates a polysurface

i mean, im trying to use embryo, but de outputs that ive been getting are not the most satisfatory. as u can see i cant get any surfaces. Is there a way i can change it?

You are wasting your time. I hope no one else falls for such a silly endeavor.

However, the probability that monkeys filling the observable universe would type a complete work such as Shakespeare’s Hamlet is so tiny that the chance of it occurring during a period of time hundreds of thousands of orders of magnitude longer than the age of the universe is extremely low (but technically not zero).

I’m not saying that generating random geometry is impossible. Just that connecting components randomly, as stated, is not the way to do it.

1 Like

Infinite monkey theorem has nothing to do with arranging grasshopper components where inputs have specific types.

Embryo can set if one input could have just one or multiple wires connected to it.

Dropping all these different types of components all of them together makes what you’re after close to impossible (the monkey has a better chance of writing a sentence compared to this).

Instead of dropping them all there, try creating 4-5 combinations of components.
Why would you put a Pipe, a circle, a loft and a cap together?

  • Pipe and a circle then you don’t need a cap.
  • pipe itself has a cap input so why the cap component?
  • loft and a circle? Instead use just a line and a pipe.
  • reduce the number of possibilities and you’ll get some results.

If you get a plywood plank drill holes where the most commonly used letters are on the keyboard and put it on a keyboard. Then lay it down in front of a monkey and it will type you a poem eventually.

2 Likes