RegionClip环境安装踩坑指南

RegionClip环境安装

RegionClip环境安装)

复制代码
特别强调,不要单独去安装detectron2,会出现model.clip不存在的错误,通过python -m pip install -e RegionCLIP就可以

问题1

复制代码
问题:torch-cuda版本不一致无法通过
解决:pip install torch==1.12.1+cu113 torchvision==0.13.1+cu113 torchaudio==0.12.1 --extra-index-url https://download.pytorch.org/whl/cu113

问题2

复制代码
问题2: pkg_resources.extern.packaging.version.InvalidVersion: Invalid version: 'RegionCLIP'
解决:降低setuptools版本 如:pip install setuptools==59.0.1 参考:https://github.com/microsoft/RegionCLIP/issues/60

问题3

复制代码
问题:torch版本和cuda版本不一致
解决:一起指定安装:pip install torch==1.12.1+cu113 torchvision==0.13.1+cu113 torchaudio==0.12.1 --extra-index-url https://download.pytorch.org/whl/cu113

问题4

复制代码
问题:KeyError: 'Non-existent config key: MODEL.CLIP'
解决:使用方法安装
git clone git@github.com:microsoft/RegionCLIP.git
python -m pip install -e RegionCLIP

问题5

复制代码
问题:AttributeError: module 'PIL.Image' has no attribute 'LINEAR'
解决:降低Pillow版本,如:pip install Pillow==8.4.0
相关推荐
c8i1 小时前
django中的FBV 和 CBV
python·django
c8i1 小时前
python中的闭包和装饰器
python
这里有鱼汤4 小时前
小白必看:QMT里的miniQMT入门教程
后端·python
TF男孩14 小时前
ARQ:一款低成本的消息队列,实现每秒万级吞吐
后端·python·消息队列
该用户已不存在19 小时前
Mojo vs Python vs Rust: 2025年搞AI,该学哪个?
后端·python·rust
站大爷IP21 小时前
Java调用Python的5种实用方案:从简单到进阶的全场景解析
python
用户8356290780511 天前
从手动编辑到代码生成:Python 助你高效创建 Word 文档
后端·python
c8i1 天前
python中类的基本结构、特殊属性于MRO理解
python
liwulin05061 天前
【ESP32-CAM】HELLO WORLD
python
Doris_20231 天前
Python条件判断语句 if、elif 、else
前端·后端·python