Skip to content
Snippets Groups Projects
Commit 0f65277f authored by Stephan Seitz's avatar Stephan Seitz
Browse files

Add TODO

parent ffd1b9d7
No related merge requests found
......@@ -73,6 +73,8 @@ def create_autograd_function(autodiff_obj, use_cuda):
output_tensors = OrderedDict({f.name:
field_to_tensor_dict.get(f, kwargs[f.name])
for f in autodiff_obj.forward_output_fields})
# TODO: only if any of input tensors requires grad
for o in output_tensors.values():
if isinstance(o, torch.Tensor):
o.requires_grad = True
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment