Gh2组件更新需求:

希望在GH2中更新几个GH1的组件:
Value list
Stream Filter
Stream Gate
Entwine

Value List hasn’t been ported yet.
Entwine hasn’t been ported either.

I recommend Sift and Combine instead of Stream Filter and Stream Gate, both in gh1 and gh2. If that’s not an option, I’d like to understand why.

I added Entwine, it will be in the next release.

3 Likes

ok,gh2的筛选与合并组件也能用,只不过用法比起gh1中的流门复杂一点点。

And I’m almost ready with Value List.

5 Likes

非常棒,谢谢

Thanks @DavidRutten for Entwine ! Is it intentionnal to force user to flatten their trees ? In GH1, there is an option to either flatten or keep the structure.

Maybe there is another way to build a tree from trees in GH2, but I did not find it yet

Not exactly, in GH1 it is either flatten or graft. A similar be achieved this way though, you can then choose to add additional grafting if needed:

Right, bad wording from me, sorry about that.

In your example, the trees have different branching level and indexes ; which is something I try to avoid in general, and I don’t really see what you’re achieving here - Merge would work just the same as Entwine here.

My general use case for Entwine is to build data trees out of other data trees. I would have trees with the same branching levels and indexes and use Entwine to stack these into upper-level branches (instead of merging items per-branch, which is where I would use Merge). I do not see how to do this yet in GH2.

You’re correct, mine was a stupid example, I’m sorry about that. I’ll add this to YT

Just spreading out ideas for future components…
:innocent:

1 Like

@flixchameroy I’ve added RH-75671 entwine in G2 graft option

1 Like

I added four modes to the Entwine component.

  1. Merge {…}
  2. Flatten {0}
  3. Graft Left {0;…}
  4. Graft Right {…,0}

The way they all work is that the final paths in the entwined tree are a combination of the original path (encoded using the ellipsis … symbol) and a constant path fragment. By default the constant fragment is just the index of the input, but you can override it by specifically naming each input.

I’m not sure when this will become publicly available, I’m working on something quite long-term at the moment and had to re-release an old version a few weeks ago.

4 Likes

Curious what the long-term thing is?

Yeah I’m not going to tell until I’ve at least got a working proof-of-concept.

Thought you might say that…looking forward to seeing it!