[quant][fx2trt] Enable comparison with implicit quant mode (#65043)
authorJerry Zhang <jerryzh@fb.com>
Sat, 18 Sep 2021 06:23:29 +0000 (23:23 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Sat, 18 Sep 2021 06:29:35 +0000 (23:29 -0700)
commitd3e36fade24eb38097c6f9dd8f90bcdadf077ade
treef8a8d4f172484c69d5aac844ca395c15b2126c75
parent4150b672aaa439913b66a3cf9ed4a2bae668621e
[quant][fx2trt] Enable comparison with implicit quant mode (#65043)

Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/65043

Currently got following result, will take a look at the executed graph again:
```
trt fp16 time (ms/iter) 1.0483217239379883
trt int8 time (ms/iter) 0.5329632759094238
trt implicit int8 time (ms/iter) 0.6769704818725586
PyTorch time (ms/iter) 6.453146934509277
```

Test Plan:
```
python torch/fx/experimental/fx2trt/example/quantized_resnet_test.py
```

Imported from OSS

Reviewed By: 842974287

Differential Revision: D30954871

fbshipit-source-id: 8d7ff82b8f5d0b7946fbd38a7cddede7d40b28aa
torch/fx/experimental/fx2trt/example/quantized_resnet_test.py