Hello,
I'm trying to setup a TOP network but I'm not sure how to proceed.
I have “old_sim”, which is a sequence of 50 work items, and “geo”, which is a single work item. Then I want to cache “new_sim”, which is another sequence of 50 items, and I need each of its frames to be dependent on both the corresponding frame of “old_sim” and “geo”.
Since I was able to set a dependency between “old_sim” and “new_sim” with a Map by Index, my first thought was to use a Map by Expression but I can't seem to find an expression that could work.
Is this the right approach?
Thank you.
Question about Map by Expression
1408 3 1- DemetrioT
- Member
- 2 posts
- Joined: 11月 2017
- Offline
- tpetrick
- スタッフ
- 585 posts
- Joined: 5月 2014
- Offline
- DemetrioT
- Member
- 2 posts
- Joined: 11月 2017
- Offline
Thank you tpetrick that works perfectly. I have a question about your setup though.
Sim2 is set to generate one item and depends on the previous nodes to generate the correct number. Is there a reason to set it to one even though it's a simulation? Why not set it to 50 like the others and put a Map by Index in between?
Sim2 is set to generate one item and depends on the previous nodes to generate the correct number. Is there a reason to set it to one even though it's a simulation? Why not set it to 50 like the others and put a Map by Index in between?
- tpetrick
- スタッフ
- 585 posts
- Joined: 5月 2014
- Offline
If you set it to 50 frames and use a mapper, the second simulation will have a hardcoded number of frames. It won't work with wedging, or if the upstream frame range is variable, or loaded from a file or something else in the scene. Attributes are not copied across mappers – each node above and below the mapper must be able to generate work items independently.
For example, with the setup I sent you can wire a wedge node into the first simulation, and the second simulation will also be wedged. PDG will correctly create 4 simulations in the second sim node, based on the work items in the partition by index.
For example, with the setup I sent you can wire a wedge node into the first simulation, and the second simulation will also be wedged. PDG will correctly create 4 simulations in the second sim node, based on the work items in the partition by index.
-
- Quick Links