“事故发生现场”
执行./sample_mnist
报错error while loading shared libraries: libnvinfer.so.8: cannot open shared object file: No such file or directory…
事故解决
在控制台输入以下命令:

vi ~/.bashrc

随后在末尾添加:

export PATH=/test_for_learnning/tensorrt/TensorRT-8.4.1.5/bin:$PATH
export LD_LIBRARY_PATH=/test_for_learnning/tensorrt/TensorRT-8.4.1.5/lib:$LD_LIBRARY_PATH
export LIBRARY_PATH=/test_for_learnning/tensorrt/TensorRT-8.4.1.5/lib:$LIBRARY_PATH

最后输入命令就可以了:

source .bashrc

参考:https://zhuanlan.zhihu.com/p/618174145?utm_id=0

Logo

北京人形旗下天工造物具身智能开源社区,聚焦具身天工与慧思开物两大平台

更多推荐