# Difference between apply an call for an autograd function

**URL:** <https://discuss.pytorch.org/t/difference-between-apply-an-call-for-an-autograd-function/13845>\
**Category:** Uncategorized\
**Created:** [February 20, 2018, 2:25pm UTC](https://discuss.pytorch.org/t/difference-between-apply-an-call-for-an-autograd-function/13845 "2018-02-20T14:25:38Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![albanD](https://discuss.pytorch.org/user_avatar/discuss.pytorch.org/alband/32/215_2.png) [@albanD](https://discuss.pytorch.org/u/albanD)\
**Post date:** [February 20, 2018, 2:37pm UTC](https://discuss.pytorch.org/t/difference-between-apply-an-call-for-an-autograd-function/13845/6 "2018-02-20T14:37:59Z")

</div>

Each call to `.apply` will have a different context. So you can save everything you need in it without risk.  
Note that if you need to save input or outputs, you should use the `ctx.save_for_backward`.

---

_[View the full topic](https://discuss.pytorch.org/t/difference-between-apply-an-call-for-an-autograd-function/13845)._
