IMTA icon indicating copy to clipboard operation
IMTA copied to clipboard

Why is the input saved in the GradientRescaleFunction?

Open arturandre opened this issue 1 year ago • 0 comments

At the forward method on the GradientRescaleFunction, the input tensor is saved to be used in the backward function:

https://github.com/kalviny/IMTA/blob/a9378373241c3247db01f826e3cd8025702fa54b/models/msdnet_ge.py#LL11C6-L11C6

and at the backward function, the saved input is retrieved:

https://github.com/kalviny/IMTA/blob/a9378373241c3247db01f826e3cd8025702fa54b/models/msdnet_ge.py#LL19C10-L19C10

however, it is never used in the backward function. So is there any reason for saving the input in the first place?

arturandre avatar Jun 21 '23 21:06 arturandre