The engine plan file is not compatible with this version of TensorRT, expecting library version 5.1....

The engine plan file is not compatible with this version of TensorRT, expecting library version 5.1.2 got 5.1.5,please rebuild!!!
run ldd program command and result as follows:
libnvinfer.so.5 => /home/ouzh/downloads/TensorRT-5.1.2.2/targets/x86_64-linux-gnu/lib/libnvinfer.so.5 (0x00007fac3b57d000)
link 5.1.2,but why got 5.1.5?

solved

How did you solve the problem?

Ensure the same version of TensorRT when building and running the engine!

Built it on 5.1.5 and running it on 5.1.5. Still gives me the same error.