Skip to content

Commit 7014032

Browse files
committed
change to _contorl in NeuralSDE
1 parent 3b3fd7b commit 7014032

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

torchdyn/core/neuralde.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,9 +150,9 @@ def _prep_sdeint(self, x:torch.Tensor):
150150
# datasets-control set routine. Is performed once at the beginning of odeint since the control is fixed to IC
151151
excess_dims = 0
152152
for _, module in self.defunc.named_modules():
153-
if hasattr(module, 'u'):
153+
if hasattr(module, '_control'):
154154
self.controlled = True
155-
module.u = x[:, excess_dims:].detach()
155+
module._control = x[:, excess_dims:].detach()
156156

157157
return x
158158

0 commit comments

Comments
 (0)