Hi,
Out of curiosity, do you have custom cpp code in your backward?
Because pytorch should never raise such an unfriendly error message.
If you did not have custom code, can you provide a small code snippet to reproduce this please?