pytorch->onnx->tf->tflite
1.pytorch->onnx try: import onnx print('\nStarting ONNX export with onnx %s...' % onnx.__version__) f = opt.weights.replace('.pth', '.onnx').replace('.pt', '.onnx') # filename torch.onnx.export(model, img, f, v