# \[resolved\] AttributeError: module 'torch.autograd' has no attribute 'grad'

**URL:** <https://discuss.pytorch.org/t/resolved-attributeerror-module-torch-autograd-has-no-attribute-grad/3784>\
**Category:** Uncategorized\
**Created:** [June 6, 2017, 8:17pm UTC](https://discuss.pytorch.org/t/resolved-attributeerror-module-torch-autograd-has-no-attribute-grad/3784 "2017-06-06T20:17:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ypxie](https://discuss.pytorch.org/letter_avatar_proxy/v4/letter/y/43a26b/32.png) [@ypxie](https://discuss.pytorch.org/u/ypxie)\
**Post date:** [June 6, 2017, 8:17pm UTC](https://discuss.pytorch.org/t/resolved-attributeerror-module-torch-autograd-has-no-attribute-grad/3784/1 "2017-06-06T20:17:50Z")

</div>

`gradients = autograd.grad(outputs=disc_interpolates, inputs=interpolates, AttributeError: module 'torch.autograd' has no attribute 'grad'`

---

<div class="post-metadata">

**Author:** ![ypxie](https://discuss.pytorch.org/letter_avatar_proxy/v4/letter/y/43a26b/32.png) [@ypxie](https://discuss.pytorch.org/u/ypxie)\
**Post date:** [June 6, 2017, 8:37pm UTC](https://discuss.pytorch.org/t/resolved-attributeerror-module-torch-autograd-has-no-attribute-grad/3784/2 "2017-06-06T20:37:26Z")

</div>

after a fresh installation from soure, the problem disappeared.
