在Jetson Nano上编译FastDeploy

2023-05-16

1. C++库的编译

git clone https://github.com/PaddlePaddle/FastDeploy.git
cd FastDeploy
mkdir build && cd build
sudo cmake -D CMAKE_CUDA_COMPILER="/usr/local/cuda/bin/nvcc" ..
sudo cmake .. -DBUILD_ON_JETSON=ON \
         -DENABLE_VISION=ON \
         -DCMAKE_INSTALL_PREFIX=${PWD}/installed_fastdeploy
sudo make -j8
make install

编译完成后,在CMAKE_INSTALL_PREFIX指定的目录下(上述编译脚本对应的路径为FastDeploy/build/installed_fastdeploy)会生成FastDeploy对应的C++推理库,如下图所示:
在这里插入图片描述

2. Python库的编译

git clone https://github.com/PaddlePaddle/FastDeploy.git
cd FastDeploy/python
export BUILD_ON_JETSON=ON
export ENABLE_VISION=ON
python3 setup.py build
python3 setup.py bdist_wheel

编译后的whl文件将会在FastDeploy/python/dist目录中生成。

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

在Jetson Nano上编译FastDeploy 的相关文章

随机推荐