Data sync issue in Anemone

Hi Guys,

Any tips with Anemone loops to sync the recorded data?

If you see with the attached example with ANY delay on the inside of the loop the data streams are complete out of sync with each other:

Any tips? Open to using other loop methods as well.

Cheers

DK

240614_Data Sync Issue in Anemone.gh (11.6 KB)

OK - I may have solved the problem myself:

Still keen to hear from others about how they work with this?

Cheers

DK

240614_Data Sync Issue in Anemone - possible solution.gh (11.4 KB)

OK - this example works perfectly in a new GH panel.

If I copy the code to my main app the buffer timing no longer has an effect - the loop runs at full speed and the data gets out of sync.

That’s fully strange! Anyone else seen this issue?

Cheers

DK

Ditch the Data Dam.

1 Like

Hi Joseph, could you tell me a little more? I use DataDam in a few places, why would it have any effect on the speed of Anemone?

Cheers

DK

Also, putting a Data Dam component in my test code still allows for control over the loop speed.

Its only when copy/paste the test code into my main application that the Buffer seems to have no effect on the loop?

Cheers

DK

Anemone end loop component wait until the current solution completed (aka all component expired are fully re-calculated), then it will trigger another cycle of the loop, over and over.

Data Dam component does not expire anything, so Anemone will not wait for you to press the play button on it. Wrong premise.

If you can explain what you are trying to do, maybe we can find another solution.

1 Like

Hi Riccardo,

I dont have a Data Dam component in the Anemone Loop - so I’m not sure why you and Joseph have mentioned this?

I can get Anemone to have a control over its loop speed when I just build a little example on a clean GH, but copy the same code in to my main program (not even connected to anything) and the Anemone Loop runs as fast a possible - not waiting at all for the data inputs.

Cheers

DK

Your first, initial picture have a data dam component.


I think anemone is not meant to be “slowed down” or stopped.

Either use the iteration count “N” initial input and gradually increase that, or ditch anemone and maybe use only data dams completely.

You certainly do :bangbang:

Write a real Anemone loop that does something, without Data Dam, and get back to us.

The first example I was using the data dam with a 500ms delay to SIMULATE a much larger piece of code that takes time to complete. In particular a Kangaroo a based relaxation model.

I’ve had this system going for a while but just in the last few days noticed that the loop was pushing out 2/3/4 times as much data than the rest of the program was able to calculate. Now I can see that I need to slow the loop down, but it refuses to in my main canvas.

Cheers

DK

a Kangaroo solver inside anemone? Hopefully Zombie solver…

Still, we have no idea what you are doing and why you are doing this way, impossible to help properly, sorry.

If you expect few iterations, try to use entwine and explode tree component, and just use a couple of data dams with “never” time, and you manually cycle through iteration by pressing play buttons

Hi Riccardo,

Yes the zombie solver in K2, the code is actually something I’ve had in production for a while, I just went looking at a minor bug yesterday and actually found a whole rabbit hole on an issue.

This video show the behavior I would expect - first half of the video - with the Buffer keeping the loop to a 1 sec cycle and my ‘faux’ slow code being 0.25 and 0.5 sec to complete everything staying in sync.

Copy the code from the test file and drop it into my production code and WTF - it flys away at full speed - not even slightly slowing down for the Buffer component.

Very weird!

Any ideas brains trust?

Cheers

DK

The Not gate wired to Loop End ‘E’ input is completely unnecessary and should be removed. Default for that input is ‘False’. It can be set ‘True’ by code in the loop to terminate the loop.

I’ve never seen or used the Buffer component before, yet written hundreds of Anemone loops over the years. Great plugin.

Hi Joseph

Thanks, removing the NOT gate doesnt stop the run away issue in my main code.

I still say it is a very strange problem, my next port of call is to copy in blocks of the main code to test what might trigger the run away issue.

Cheers

DK

I didn’t say it would. It indicates limited understanding of Anemone though.