Fixed backward pass of weighted euclidean loss, gradient test passes