ImportError: libGL.so.1: cannot open shared object file: No such file or dir

原因:由于容器内部的问题所引起的

方法1:需要更新apt,安装libgl1-mesa-glx

apt update
apt install libgl1-mesa-glx

方法2:

pip uninstall opencv-python -y
pip install opencv-python-headless -i https://pypi.tuna.tsinghua.edu.cn/simple

你可能感兴趣的:(#,Python,环境配置与算法部署,python,开发语言)