https://github.com/DengPingFan/SINet
Configuring your environment (Prerequisites):
Note that SINet is only tested on Ubuntu OS with the following environments. It may work on other operating systems as well but we do not guarantee that it will.
Creating a virtual environment in terminal:
conda create -n SINet python=3.6
.
conda create --name SINet-pytorch pyhton=3.7.4 (这是我的环境)Installing necessary packages:
pip install -r requirements.txt
.(Optional: only for training) Installing NVIDIA-Apex for accelerate training process with mixed precision. (Instructions) (Under CUDA-10.0 and Cudnn-7.4).
Downloading Training and Testing Sets:
downloading NEW testing dataset (COD10K-test + CAMO-test + CHAMELEON) and move it into./Dataset/TestDataset/
, which can be found in this Google Drive link or Baidu Pan link with the fetch code: z83z.
测试集(以COD10K为例)路径: ./Dataset/TestDataset/COD10K
download NEW training dataset (COD10K-train) which can be found in this Google Drive link or Baidu Pan link with the fetch code:djq2. Please refer to our original paper for other training data.
Testing Configuration:
After you download all the pre-trained model and testing data, just runMyTest.py
to generate the final prediction map: replace your trained model directory (--model_path
) and assign your the save directory of the inferred mask (--test_save
)
Note that we re-trained our model (marked as $\diamondsuit$ in the following figure) equipped with mixed training strategy of Apex lib (mode=O1
) and get better performance in 40 epoch. Here we provide a new pre-trained model (Baidu Drive [fetch code:2pp2]/Google Drive) here. Later, We will try different backbones based SINet to improve performance and provide more comprehensive comparison.下载所有预先训练的模型和测试数据后,只需运行
MyTest.py
要生成最终的预测图:替换训练的模型目录(--model_path),并分配推断掩码的保存目录(--test_save)请注意,我们重新训练了我们的模型(下图中标记为$\diamondsuit$),采用Apex-lib(模式=O1)的混合训练策略,在40个历元中获得了更好的性能。这里我们提供了一个新的预训练模型(Baidu Drive[fetch代码:2pp2]/谷歌硬盘)这里。稍后,我们将尝试基于不同的主干网来提高性能,并提供更全面的比较。