AttributeError: module 'PIL.Image' has no attribute 'LINEAR'
pillow包与torchvision的版本不匹配,降级pillow解决
pip uninstall pillow
pip install pillow==9.0.1 --no-cache-dir
AttributeError: module 'distutils' has no attribute 'version'
setuptools版本太高,不匹配
pip uninstall setuptools
conda install setuptools==58.0.4
shapely/set_operations.py:134: RuntimeWarning: invalid value encountered in intersection
降级shapely,不再有该警告:
pip uninstall shapely
pip install shapely==1.7.1
也可选择关闭警告:
python -W ignore::RuntimeWarning ***.py