【香橙派4B】2、安装OpenCV、pip3,更新下载源

目录

安装OpenCV

安装pip3

永久更换pip3下载源

更新下载源

AttributeError: module 'serial' has no attribute 'Serial'问题解决

安装OpenCV

apt install libopencv-dev python3-opencv

安装pip3

//orangepi@orangepi:~$ sudo apt-get install -y python3-pip
sudo apt-get install -y python3-pip

永久更换pip3下载源

orangepi@orangepi:~$ mkdir -p ~/.pip
orangepi@orangepi:~$ cat < ~/.pip/pip.conf
>[global]
>timeout = 6000
>index-url = https://pypi.tuna.tsinghua.edu.cn/simple
>trusted-host = pypi.tuna.tsinghua.edu.cn
>EOF
mkdir -p ~/.pip
cat < ~/.pip/pip.conf
[global]
timeout = 6000
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
trusted-host = pypi.tuna.tsinghua.edu.cn
EOF

更新下载源

//root@orangepi4:~# apt update
apt update

AttributeError: module 'serial' has no attribute 'Serial'问题解决

pip3 install serial
pip3 install pyserial

你可能感兴趣的:(香橙派4B,python,嵌入式硬件,opencv,ubuntu,计算机视觉)