Is what you suggest the same as setting X.data = pre-processing(X.data) or would autograd record that change on X’s data?
Also, given that the network parameters are all after the pre-processing layer, is it really necessary to wrap Y in a Variable after X as a tensor? Wouldn’t it be the same as having X as a Variable, pre-processing that variable and computing the gradients on that X? For doing parameter updates, I mean…