参考的初始资源:
GitHub项目文档
B站视频
1.安装工具
打开Anaconda Prompt
1.创建虚拟环境
conda create -n isat_env python=3.8
conda activate isat_env
2.安装GPU版本pytorch
4070 Ti
CUDN12.5
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121
3.把项目git下来
进入想要存放的目录
F:cd F:\LI_\PycharmProject
git项目
git clone https://github.com/yatengLG/ISAT_with_segment_anything.git
进入项目目录,安装依赖
cd ISAT_with_segment_anything
pip install -r requirements.txt
(步骤2安装的GPU版本的pytorch并不会被步骤3pip install -r requirements.txt所包含的pytorch覆盖。已经安装过pytorch便不会再次安装)
4.验证是否安装成果
python
import torch
print("PyTorch 版本:", torch.__version__)
print("CUDA 是否可用:", torch.cuda.is_available())
print("GPU 名称:", torch.cuda.get_device_name(0) if torch.cuda.is_available() else "无")
应有
>>> import torch
>>>
>>> print("PyTorch 版本:", torch.__version__)
PyTorch 版本: 2.4.1+cu121
>>> print("CUDA 是否可用:", torch.cuda.is_available())
CUDA 是否可用: True
>>> print("GPU 名称:", torch.cuda.get_device_name(0) if torch.cuda.is_available() else "无")
GPU 名称: NVIDIA GeForce RTX 4070 Ti
5…运行软件
python main.py
2.软件使用演示
自己录的
至此,得到VOC格式的.png图像。
后续数据集的分割、放入模型中进行训练待更新…