All Projects → GengDavid → Pytorch Cpn

GengDavid / Pytorch Cpn

Licence: gpl-3.0
A PyTorch re-implementation of CPN (Cascaded Pyramid Network for Multi-Person Pose Estimation)

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Pytorch Cpn

Pose Residual Network Pytorch
Code for the Pose Residual Network introduced in 'MultiPoseNet: Fast Multi-Person Pose Estimation using Pose Residual Network' paper https://arxiv.org/abs/1807.04067
Stars: ✭ 277 (-31.27%)
Mutual labels:  deep-neural-networks, pose-estimation
Unofficial Implement Of Openpose
Implement of Openpose use Tensorflow
Stars: ✭ 222 (-44.91%)
Mutual labels:  deep-neural-networks, pose-estimation
Poseestimationformobile
💃 Real-time single person pose estimation for Android and iOS.
Stars: ✭ 783 (+94.29%)
Mutual labels:  deep-neural-networks, pose-estimation
Pose Residual Network
Code for the Pose Residual Network introduced in 'MultiPoseNet: Fast Multi-Person Pose Estimation using Pose Residual Network (ECCV 2018)' paper
Stars: ✭ 337 (-16.38%)
Mutual labels:  deep-neural-networks, pose-estimation
Rmdl
RMDL: Random Multimodel Deep Learning for Classification
Stars: ✭ 375 (-6.95%)
Mutual labels:  deep-neural-networks
Magnet
Deep Learning Projects that Build Themselves
Stars: ✭ 351 (-12.9%)
Mutual labels:  deep-neural-networks
Curl
CURL: Contrastive Unsupervised Representation Learning for Sample-Efficient Reinforcement Learning
Stars: ✭ 346 (-14.14%)
Mutual labels:  deep-neural-networks
Real Time Gesrec
Real-time Hand Gesture Recognition with PyTorch on EgoGesture, NvGesture, Jester, Kinetics and UCF101
Stars: ✭ 339 (-15.88%)
Mutual labels:  deep-neural-networks
Neuronlp2
Deep neural models for core NLP tasks (Pytorch version)
Stars: ✭ 397 (-1.49%)
Mutual labels:  deep-neural-networks
Taso
The Tensor Algebra SuperOptimizer for Deep Learning
Stars: ✭ 391 (-2.98%)
Mutual labels:  deep-neural-networks
Mobilenetv2.pytorch
72.8% MobileNetV2 1.0 model on ImageNet and a spectrum of pre-trained MobileNetV2 models
Stars: ✭ 369 (-8.44%)
Mutual labels:  deep-neural-networks
Predictive Maintenance Using Lstm
Example of Multiple Multivariate Time Series Prediction with LSTM Recurrent Neural Networks in Python with Keras.
Stars: ✭ 352 (-12.66%)
Mutual labels:  deep-neural-networks
First Steps Towards Deep Learning
This is an open sourced book on deep learning.
Stars: ✭ 376 (-6.7%)
Mutual labels:  deep-neural-networks
Action Recognition Visual Attention
Action recognition using soft attention based deep recurrent neural networks
Stars: ✭ 350 (-13.15%)
Mutual labels:  deep-neural-networks
Deeprobust
A pytorch adversarial library for attack and defense methods on images and graphs
Stars: ✭ 388 (-3.72%)
Mutual labels:  deep-neural-networks
Pytorch Human Pose Estimation
Implementation of various human pose estimation models in pytorch on multiple datasets (MPII & COCO) along with pretrained models
Stars: ✭ 346 (-14.14%)
Mutual labels:  pose-estimation
Easy Deep Learning With Keras
Keras tutorial for beginners (using TF backend)
Stars: ✭ 367 (-8.93%)
Mutual labels:  deep-neural-networks
Densebody pytorch
PyTorch implementation of CloudWalk's recent work DenseBody
Stars: ✭ 378 (-6.2%)
Mutual labels:  pose-estimation
Openrec
OpenRec is an open-source and modular library for neural network-inspired recommendation algorithms
Stars: ✭ 360 (-10.67%)
Mutual labels:  deep-neural-networks
Openchem
OpenChem: Deep Learning toolkit for Computational Chemistry and Drug Design Research
Stars: ✭ 356 (-11.66%)
Mutual labels:  deep-neural-networks

PyTorch CPN(Cascaded Pyramid Network)

This is a PyTorch re-implementation of CPN (Cascaded Pyramid Network), winner of MSCOCO keypoints2017 challenge. The TensorFlow version can be found here, which is implemented by the paper author.

Evaluation results on COCO minival dataset

Method Base Model Input Size BBox AP @0.5:0.95 AP @0.5 AP @0.75 AP medium AP large
CPN ResNet-50 256x192 Ground Truth 71.2 91.4 78.3 68.6 75.2
CPN ResNet-50 256x192 Detection Result 69.2 88.0 76.2 65.8 75.6
CPN ResNet-50 384x288 Ground Truth 74.1 92.5 80.6 70.6 79.5
CPN ResNet-50 384x288 Detection Result 72.2 89.2 78.6 68.1 79.3
CPN ResNet-101* 384x288 Ground Truth 74.0 92.3 80.6 71.1 78.7
CPN ResNet-101* 384x288 Detection Result 72.3 89.2 78.9 68.7 79.1

Thanks Tiamo666 and mingloo for training and testing ResNet-50-384x288CPN model. And thanks Tiamo666 for training and testing ResNet-101-384x288CPN model.
If you have interests in this repo, welcome to test other model configurations together.

* CPN-ResNet-101-384x288 model is fine-tuned from the previous pre-trained model. If you train it from scratch, it should get a higher result.

Usage

For training

  1. Clone the repository
git clone https://github.com/GengDavid/pytorch-cpn

We'll call the directory that you cloned ROOT_DIR.

  1. Download MSCOCO2017 images and annotations from http://cocodataset.org/#download. And put images and annotation files follow the struture showed in data/README.md
    After placing data and annotation files. Please run label_transform.py at ROOT_DIR to transform the annotation fomat.

  2. Initialize cocoapi

git submodule init
git submodule update
cd cocoapi/PythonAPI
make

It will build cocoapi tools automatically.

  1. Install requirement
    This repo require following dependences.
  • PyTorch >= 0.4.1
  • numpy >= 1.7.1
  • scipy >= 0.13.2
  • python-opencv >= 3.3.1
  • tqdm > 4.11.1
  • skimage >= 0.13.1
  1. Training
cd ROOT_DIR/MODEL_DIR/
python3 train.py

For example, to train CPN with input resolution 256x192, just change directory into ROOT_DIR/256.192.model, and run the script.

For more args, see by using

python train.py --help

For Validation

cd ROOT_DIR/MODEL_DIR/
python3 test.py -t PRE-TRAINED_MODEL_NAME

-t meas use which pre-trained model to test.
For more args, see by using

python test.py --help

If you want to test a pre-trained model, please place the pre-trained model into ROOT_DIR/MODEL_DIR/checkpoint directory. Please make sure your have put the corresponding model into the folder.

For example, to run pre-trained CPN model with input resolution 256x192,

python3 test.py -t 'CPN256x192'

This pre-trained model is provided below.

Pre-trained models:

COCO.res50.256x192.CPN (updated!)
COCO.res50.384x288.CPN (updated!)
COCO.res101.384x288.CPN* (new)
* CPN-ResNet-101-384x288 model is fine-tuned from the previous pre-trained model. If you train it from scratch, it should get a higher result.

Detection results on Minival dataset

The detection results are tranformed from results in tf version of cpn.
detection_minival

Acknowledgements

Thanks chenyilun95, bearpaw and last-one for sharing their codes, which helps me a lot to build this repo.
Thanks Tiamo666 for testing ResNet-50-384x288CPN and ResNet-101-384x288CPNmodel.
Thanks mingloo for contribution.
Thanks mkocabas for helping me test other configurations.

Others

If you have any questions or find some mistakes about this re-implementation, please open an issue to let me know.
If you want to know more details about the original implementation, you can check tf version of cpn.

Troubleshooting

  1. Thanks Tiamo666 to point it out that the refineNet is implemented in a different way from the original paper(this can reach a higher results, but it will cost more memory).
  2. See issue #10 and issue #7.
    Codes and results have been updated!(2018/9/6)

Reference

[1] Chen, Y., Wang, Z., Peng, Y., Zhang, Z., Yu, G., Sun, J.: Cascaded pyramid network for multi-person pose estimation. CVPR (2018)

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].