I’ve exported my model to onnx and verifying the exported model by torch.linalg.norm( torch_out - onnx_out)
. These outputs are inferred from torch.ones tensors. I get difference norms below,
center diff: 0.0001215097145177424, tensor shape: torch.Size([1, 2, 468, 468])
center_z diff: 0.000555071048438549, tensor shape: torch.Size([1, 1, 468, 468])
dim diff: 0.0008262245682999492, tensor shape: torch.Size([1, 3, 468, 468])
rot diff: 0.0005295916926115751, tensor shape: torch.Size([1, 2, 468, 468])
hm diff: 0.0025102065410465, tensor shape: torch.Size([1, 3, 468, 468])
VFE diff: 0.12264608591794968, tensor shape: torch.Size([10000, 64])
Torch export and inference were performed while model was in eval()
and with torch.no_grad()
Are these differences expected and reasonable or might something be wrong?
Thanks!