Skip to content

RuntimeError: sqrt_vml_cpu not implemented for 'Half'

Got this error when try to onnx export:

yolov5/utils/torch_utils.py", line 119, in fuse_conv_and_bn
    w_bn = torch.diag(bn.weight.div(torch.sqrt(bn.eps + bn.running_var)))
RuntimeError: sqrt_vml_cpu not implemented for 'Half'

any ideas? I am using pytorch 1.6 on GTX1080ti which might not have fp16 support.