Grasshopper

algorithmic modeling for Rhino

What are the main differences between Hoopsnake and Anemone? Is one better than the other? Do they have different purposes?

Views: 5371

Replies to This Discussion

I asked myself the same question.

So I tried a simple example and found that Hoopsnake is more reliable in the way that the data order is maintained during loops. 

Hoopsnake is no longer supported and I could never get it to work.  Anemone has never failed me, it is more intuitive, has the expandable list of data paths, works with nested loops, etc.  Anemone is better!

There is also another component, called (just) »Loop«.

I have tried all three. Personally I would suggest everybody to use Anemone. It's the most intuitive one imho.

Anemone is my personal favorite. It works better as part of "in-line" logic in a definition, in that it can be automatically triggered to rerun the entire loop. With the latest release, it is also by far the fastest option available - the new "Fast Loop" components are amazing. 

I was just playing with the new Anemone "Fast Loop" - WOW, it's fast!  Not sure yet how it works when connected to "slow" components?  It lacks the "Output after last" feature so isn't suitable for inner nested loops, I guess.  Example attached.

By the way, Anemone has a great tutorial GH file.

I just looked at »Loop«, mentioned above by Lucas, but it made no sense to me at all.  

Attachments:

I'm going to prepare some tutorials soon.

The Fast Loop is by default set to Output after last  (that's actually a part of the trick to make it fast). I've tested it with some simple nested loops and it seems that it works properly. PM me if you will find any bugs with some more complex loops.

Looking forward to the tutorials!

Is it possible to add a branch to a data tree with every loop and on every loop process each branch?

Is it possible to add a branch to a data tree on some loops (randomly)?

Or is adding a branch to a data tree during a loop a bad idea / not possible / stupid?

Well, it only depends how you structure your definition. Anemone never really changes any data tree paths inside the loop, it only prepends one integer in case you're recording (and it is applied only to the data trees in the loop end outputs). 

If you don't like the way Anemone handles recording, you can always record data streams selectively by using the Merge components (merge loop start output with newly computed data and put it back into the loop end inputs). 

  • Is it possible to add a branch to a data tree with every loop and on every loop process each branch?
  • That would require nested loop - where the outer one loops the whole data tree, while the nested one iterates over every branch.
  • Is it possible to add a branch to a data tree on some loops (randomly)?
  • Can't see why not.
  • Or is adding a branch to a data tree during a loop a bad idea / not possible / stupid?
  • Anemone doesn't rely on data tree you're looping (it  basically doesn't care about it, you just have to provide any data into the loop end).

Maybe my question is actually a GH question, not an Anenome question!

In my definition I am moving points along vectors. I also add new points and vectors but cull them based on a probability.

I have points and vectors looping.

I couldn't get the vector direction to do exactly what I wanted but that's another issue.

It is supposed to simulate leaf venation! Instead, it's art :)

I want to try a different approach... I want to create a data structure so each branch is a list of points in a polyline. I also want to be able to have matching data trees that would hold radii to represent a thickness at each polyline vertex. (So I could potentially use these as field strengths in cocoon or strut radii in exoskeleton)

I want to randomly create a new polyline databranch that represents an offshoot from an existing polyline and, likewise, add a similar branch to the radii thickness data tree.

Attachments:

I think we basically broke this discussion (which is supposed to be Hoopsnake<>Anemone comparison). Please post a separate discussion in the Anemone group so we won't make this forum a garbage.

Fast comment to your post : That's a really nice definition... The only thing which is a problem with looping data trees is that it's really hard to create a definition which supports dynamic data trees (those with changing data tree topology). It's much easier with scripting, but still... I usually try to operate only with lists.

OK, will start a new discussion in Anenome group... it's just so tempting to ask a question when everyone's in the same room :)

Back on track... I prefer Anenome to Hoopsnake. I particularly like the ability to press escape to break to loop when I've done something wrong!

Hello Mateusz,

Perhaps I should start a separate thread for this...  I've spent quite a bit of time playing with nested "Fast Loops", including retrofitting code examples that work fine using the "Classic" loops.  As far as I know, none have succeeded.  The outer loops seem to be triggered by every cycle of the inner loops, as if "Output after last" isn't working.

Here is just one example of moving a brick along a curve.  The "Classic" nested loop version works as expected: RecursiveBrick_2016_Jan2b.gh.

The "Fast Loop" version fails with the outer loop not waiting for the inner loop to complete: RecursiveBrick_2016_Jan4a.gh.

I've hooked up data recorders and tried many variations of this code and other examples, all without success.  Is there something wrong with my wiring?  Or are there cases where "Fast Loops" fail, nested or otherwise?

Maybe you can explain "Fast Loops" in general, what makes them fast, when to use them vs. "Classic" loops?

I love Anemone (thank you!) and fast is great, of course, unless it fails where Classic succeeds reliably.

Attachments:

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service