Skip to content

fangzy97/hcnet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HCNet

Hierarchical Context-Agnostic Network with Contrastive Feature Diversity for One-Shot Semantic Segmentation

avg

Usage

Requirements

python==3.7, torch==1.6, opencv-python, tensorboardX

Dataset

Prepare related datasets: Pascal-5i (VOC 2012, SBD) and COCO-20i (COCO 2014)

Pre-trained models

  • Pre-trained backbones and models can be found in Google Driver
  • Download backbones and put the pth files under initmodel/ folder

Test and Train

  • Specify the path of datasets and pre-trained models in the data/config file

  • Use the following command

    sh tool/test.sh|train.sh {data} {model} {split_backbone}
    

    E.g. Test HCNet with ResNet50 on the split 0 of PASCAL-5i:

    sh tool/test.sh pascal hcnet split0_resnet50
    
  • We provide trained Models with the ResNet-50 and VGG-16 backbone on Pascal-5i and COCO-20i for performance evalution. You can download them from Google Driver

References

The code is based on semseg and PFENet. Thanks for their great work!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published