Page 1 of 1

compile pytorch, torchvision, torchaudio in jetson nano

Posted: Tue May 31, 2022 8:56 pm
by henrywu

clang 8 is required for cuda 10.2.

Code: Select all

#!/bin/bash

#sudo apt-get install clang
## the dependencies
#sudo apt-get install ninja-build git cmake
#sudo apt-get install libjpeg-dev libopenmpi-dev libomp-dev ccache
#sudo apt-get install libopenblas-dev libblas-dev libeigen3-dev
#sudo -H pip3 install -U --user wheel mock pillow

export BUILD_CAFFE2_OPS=OFF
export USE_FBGEMM=OFF
export USE_FAKELOWP=OFF
export BUILD_TEST=OFF
export USE_MKLDNN=OFF
export USE_NNPACK=ON
export USE_XNNPACK=ON
export USE_QNNPACK=ON
export MAX_JOBS=4
export USE_OPENCV=OFF
export USE_NCCL=OFF
export USE_SYSTEM_NCCL=OFF
export PATH=/usr/lib/ccache:$PATH
# set clang compiler
export CC=clang-8
export CXX=clang++-8
# clean up the previous build, if necessary
#python3 setup.py clean
# start the build
python3 setup.py bdist_wheel

compile python 3.8 + tensorRT

Posted: Tue May 31, 2022 8:57 pm
by henrywu

compile pytorch, torchvision, torchaudio, openpifpaf in jetson nano

Posted: Fri Jun 03, 2022 9:51 am
by henrywu

Code: Select all

$export MAX_JOBS=4
$export CC=clang
$export CXX=clang++
$python setup.py bdist_wheel
...
[1158][nano][0][bash](18:46:56)[0](jetson) : ~/openpifpaf
$pip install dist/openpifpaf-0.13.4+2.gc7b05a2-cp38-cp38-linux_aarch64.whl --no-deps --ignore-installed
....