Allows for imputing new placements into AbstractComputations during tracing via a role_map, which is a map of placement names to placement names. I considered making this a mapping of PlacementExpression->PlacementExpression or Placement->Placement, but did not want to require having these objects in scope when building the role_map dict.
The role_map can be provided either to the pm.computation decorator directly, or to an existing AbstractComputation class via the with_role_map method.
Closes #1112
Allows for imputing new placements into
AbstractComputation
s during tracing via arole_map
, which is a map of placement names to placement names. I considered making this a mapping ofPlacementExpression
->PlacementExpression
orPlacement
->Placement
, but did not want to require having these objects in scope when building therole_map
dict.The
role_map
can be provided either to thepm.computation
decorator directly, or to an existingAbstractComputation
class via thewith_role_map
method.