iSmallNet环境配置

iSmallNet环境配置

论文地址:iSmallNet: Multi-scale Nested Network with Label Decoupling for Infrared Small Target Detection
项目地址:https://github.com/huzhihen/iSmallNet

第一步:Pytorch环境搭建

1.1 安装pytorch环境

conda create -n pytorch-iSmallNet python=3.9
conda activate pytorch-iSmallNet
conda install pytorch==1.12.0 torchvision==0.13.0 torchaudio==0.12.0 cudatoolkit=11.3 -c pytorch

1.2 验证pytorch环境

python                     # 3.9.13
import torch
torch.__version__          # 1.12.0
torch.version.cuda         # 11.3
torch.cuda.is_available()  # True
exit()

第二步:安装其它包

2.1 安装其他包

conda install tqdm
conda install tensorboard
pip install opencv-python
pip install Pillow==6.2.2 --user
pip install scikit-image

2.2 安装apex

git clone https://github.com/NVIDIA/apex
cd apex
python setup.py install

第三步:克隆项目地址和下载数据集

3.1 克隆项目地址

git clone git@github.com:huzhihen/iSmallNet.git

3.2 下载数据集并存放到 data/ 文件夹下,组织成以下所示的结构

NUAA-SIRST
NUDT-SIRST
IRSTD-1k

iSmallNet
├── data
│   ├── NUAA-SIRST
│   │   ├── image
│   │   ├── mask
│   │   ├── train.txt
│   │   ├── test.txt
│   ├── NUDT-SIRST
│   │   ├── image
│   │   ├── mask
│   │   ├── train.txt
│   │   ├── test.txt
│   ├── IRSTD-1k
│   │   ├── image
│   │   ├── mask
│   │   ├── train.txt
│   │   ├── test.txt
├── eval
├── train
├── utils.py

第四步:训练、测试以及可视化

python utils.py --dataset [dataset-name]
python train.py --dataset [dataset-name]
python test.py --dataset [dataset-name]
python visualization.py --dataset [dataset-name]
python eval.py --dataset [dataset-name]

至此,iSmallNet环境配置完满结束!感谢大家的观看!

  • 3
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值