Jetbot
基本設定
更改預設python
cd /usr/bin
sudo rm python
sudo ln -s python3.6 python
設定CUDA
vi ~/.bashrc
# 加入路徑
export CUDA_HOME=/usr/local/cuda-10.2
export LD_LIBRARY_PATH=/usr/local/cuda-10.2/lib64:$LD_LIBRARY_PATH
export PATH=/usr/local/cuda-10.2/bin:$PATH
# 重啟
source ~/.bashrc
# 查看是否設定成功
nvcc -V
安裝基本工具
sudo apt update
sudo apt install python3-pip python3-dev build-essential
sudo -H pip3 install --upgrade pip
sudo apt install git cmake
sudo apt install libatlas-base-dev gfortran
sudo apt install libhdf5-serial-dev hdf5-tools
sudo apt install libcanberra-gtk-module libcanberra-gtk3-module
安裝jetson工具
#安裝jetson-stats
sudo -H pip3 install jetson-stats
sudo systemctl restart jetson_stats.service
#查詢JetPack版本與軟體版本
jetson_release
# 執行Jtop監控工具,可查看CPU與GPU的相關資訊,也可將目前安裝的library顯示出來
sudo jtop
確認tensorRT
dpkg-query -W tensorrt
固定IP Address
#vi /etc/network/interfaces
auto wlan0
iface wlan0 inet static
address 192.168.3.241
netmask 255.255.255.0
gateway 192.168.3.254
wpa-ssid [wifi-ssid]
wpa-psk [wifipasswd]
XRDP 遠端桌面
安裝tightvncserver跟xrdp套件,重啟Jetson Nano
sudo apt update
sudo apt install tightvncserver xrdp
sudo reboot
安裝xubuntu-desktop
sudo apt install xubuntu-desktop
echo xfce4-session >~/.xsession
重啟xrdp服務
sudo service xrdp restart
參考資料:
https://blog.cavedu.com/2019/12/19/jetson-nano-remote-desktop-windows-mac-osx/
掛載NAS
在/etc/fastab加入下方一行:
//[NAS IP]/[資料夾] /home/[掛載路徑] cifs username=[帳號],password=[密碼],uid=[uid],gid=[gid],sec=ntlmssp,user_xattr 0 0
執行sudo mount -a重新執行fstab
安裝ArchiConda
https://github.com/Archiconda/build-tools/releases
wget https://github.com/Archiconda/build-tools/releases/download/0.2.3/Archiconda3-0.2.3-Linux-aarch64.sh
echo ". /home/jetbot/archiconda3/etc/profile.d/conda.sh" >> ~/.bashrc
設定Yolov5
安裝onnx
sudo apt install protobuf-compiler libprotoc-dev
pip3 install Cython
pip3 install onnx==1.9.0
安裝常用套件
Python套件的AppStore: https://pypi.org/
PS.安裝matplotlib之前,先移除內建的python3-matplotlib:sudo apt remove python3-matplotlib
重要套件:pip3 install -U numpy==1.19.4 protobuf==3.3.0 cython pillow scipy
pip3 install -U matplotlib==3.3.2
機器學習:pip3 install scikit-learn cvzone
網路爬蟲:pip3 install -U requests beautifulsoup4 selenium pandas
若要在虛擬環境下使用上述套件,請在activate檔案中加入:
系統安裝的套件:export PYTHONPATH=/usr/lib/python3.6/dist-packages:$PYTHONPATH
使用者安裝的套件:export PYTHONPATH=/home/jetbot/.local/lib/python3.6/site-packages:$PYTHONPATH
sudo免密碼
sudo visudo
%sudo ALL=(ALL:ALL) NOPASSWD:ALL
備份SD卡
查看SD卡掛載在哪裡
lsblk
備份前先sync
sync
安裝dc3dd
sudo apt install dc3dd
將SD卡寫成img檔
sudo dc3dd if=/dev/mmcblk0 of=[USB掛載路徑]/myimg.img