Open eb8680 opened 7 months ago
I think this will be resolved by #528
@SamWitty I'm reassigning this to you since I think it corresponds to your comment on #528:
I'd like to add a tiny PR that adds an optional name kwarg to the existing dynamical systems interventions, which should change the counterfactual behavior from "one world per state variable" to "one world per static/dynamic intervention". That will also hopefully make it much easier to index into worlds produced from dynamical systems interventions. I know this PR is already intended to lead to interventions on dynamics, but figured it would be worth mentioning how it will improve the ergonomics (with a minor change) of the existing dynamical systems interventions. Thoughts?
I think this issue was resolved by #528 but you might want to try writing unit tests for the counterfactual
and dynamical
modules to verify that the new behavior is what you want.
Currently, applying
split
to a container object like atuple
ordict
within aMultiWorldCounterfactual
context may result in a newsplit
for each element of the container. The correct behavior in this case would instead be tosplit
once and share the new index variable across all elements of the container.