利用torch2trt工具进行模型加速时,得到的模型大小会变大,后来查到的官方回复如下:
TensorRT makes tradeoffs between memory usage and performance that can increase the size of the memory reserved by the plan files.
This is something that is being actively investigated and improved upon.
However, looking at the verbose log might help understand where the memory usage is coming from.