If I add the pm.set_data line, then I get the following error:
TypeError: The variable `actor` must be a `SharedVariable` (created through `pm.MutableData()` or `pm.Data(mutable=True)`) to allow updating. The current type is: <class 'pytensor.tensor.var.TensorConstant'>
Not sure what to run pm.Data(mutable=True) on.