Open dontLoveBugs opened 5 years ago
You're right! I'll fix it.
You're right! I'll fix it.
Have you solved this problem now?
@dontLoveBugs Hello, can you review my issue ? I think the bilinear kernel is wrong
You're right! I'll fix it.
'tuple' object can not be modified. Your code just get an generator.
I have searched online, the grad of output can not be modified, if you want modify the grad of input, you need to return the modified grad of input , like : def _set_lr(module, grad_input, grad_output): return (grad_input[i] * 0.1 for i in range(len(grad_input)))
you can try it. My question is : Why change the p_conv gradients, Is it to avoid affecting the learning of another feature extraction branch?
@XinZhangNLPR the you is becuse the backforward_hook expected tuple, not 'generator'
I have searched online, the grad of output can not be modified, if you want modify the grad of input, you need to return the modified grad of input , like : def _set_lr(module, grad_input, grad_output): return (grad_input[i] * 0.1 for i in range(len(grad_input)))
you can try it. My question is : Why change the p_conv gradients, Is it to avoid affecting the learning of another feature extraction branch?
Your suggestion still return a generator not a tuple
You're right! I'll fix it.
it seems this bug has not fixed yet
You set the gradient of p_conv and m_conv to 0.1 times the other layers, but I find the gradient has no change after backward. I use the following code to test.
The gradient of p_conv is same with the grad_input, but I think the gradient of p_conv is 0.1 times the gradient of the grad_input. Am I wrong?