Giter VIP home page Giter VIP logo

few-shot-keypoint-detection's Introduction

Few-shot-keypoint-detection

This is the official implementation for the paper few-shot keypoint detection with uncertainty learning for unseen species (CVPR2022).

For convenience, we show how to train and test the FSKD model only in Animal pose dataset.

1. FSKD Pipeline

2. Requirements.

  • Python 3.8.5
  • Pytorch 1.7.0

3. Model Training

  • Download dataset.
    Since the official Animal pose dataset has been corrected multiple times by its author due to noisy annotations, the current official one is different from the one which we used. Moreover, the annotation format is different, too. Therefore, we upload the Animal pose dataset that we used on the cloud and please use this one. The animal pose dataset should have the folder structure as follows:
|--Animal_Dataset_Combined  
   |--gt
   |--images
   |--readme.txt
  • Modify the dataset path in "annotation_prepare.py" and run this python file to generate the local annotation files. An "annotation_prepare" folder will appear and there are five json files generated as:
|--annotation_prepare
   |-- cat.json
   |-- dog.json
   |-- cow.json
   |-- horse.json
   |-- sheep.json
  • Generate saliency maps using the pre-trained saliency detector SCRN. The saliency map is used to prune auxiliary keypoints out of foreground region.

  • Modify the 'saliency_maps_root' in dict 'opts', and run 'main.py'.

4. Model Testing

  • Modify the paths in "eval.py" and run it.

5. FAQ

  • The testing result may have some variations because it is tested using episodes. Moreover, FSKD is very challenging, so the detector may pose some uncertainty in novel keypoint detection. The scores would be more stable if more episodes are tested.
  • The current pipeline is the starting of FSKD. We believe the code will be better along with the research progress of FSKD in the future.

6. Citation

If you use our code for your research, please cite our paper. Many thanks!

@InProceedings{Lu_2022_CVPR,
    author    = {Lu, Changsheng and Koniusz, Piotr},
    title     = {Few-Shot Keypoint Detection With Uncertainty Learning for Unseen Species},
    booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
    month     = {June},
    year      = {2022},
    pages     = {19416-19426}
}

few-shot-keypoint-detection's People

Contributors

alanlusun avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.