Well, segfault does not print python trace. At least, using print (thats cheap, I know), before each instruction I found that it occurs before the .backward().
Interestingly, some iterations are working ok, then, at one point it segfault

Edit: also note that the size of the output looks constant i.e. it is always the same iteration which fails