Home

Awesome

NWPU-Crowd Sample Code


This repo is the official implementation of paper: NWPU-Crowd: A Large-Scale Benchmark for Crowd Counting. The code is developed based on C^3 Framework.

Compared with the original C^3 Framework,

These features will be merged into C^3 Framework as soon as possible.

Getting Started

Preparation

Training

Testing

We only provide an example to forward the model on the test set. You may need to modify it to test your models.

Pre-trained Models

We provide the pre-trained models in this link, which is a temporary share point of OneDrive. We will provide a permanent website ASAP.

Performance on the validation set

For an intuitive comparison, the visualization results of these methods are provided at this link. The overall results on val set:

MethodMAEMSEPSNRSSIM
MCNN [1]218.53700.6128.5580.875
C3F-VGG [2]105.79504.3929.9770.918
CSRNet [3]104.89433.4829.9010.883
CANNet [4]93.58489.9030.4280.870
SCAR [5]81.57397.9230.3560.920
SFCN+ [6]90.65487.1730.5180.933

About the leaderboard on the test set, please visit Crowd benchmark.

References

  1. Single-Image Crowd Counting via Multi-Column Convolutional Neural Network, CPVR, 2016.
  2. C^3 Framework: An Open-source PyTorch Code for Crowd Counting, arXiv, 2019.
  3. CSRNet: Dilated Convolutional Neural Networks for Understanding the Highly Congested Scenes, CVPR, 2018.
  4. Context-Aware Crowd Counting, CVPR, 2019.
  5. SCAR: Spatial-/Channel-wise Attention Regression Networks for Crowd Counting, Neurocomputing, 2019.
  6. Learning from Synthetic Data for Crowd Counting in the Wild, CVPR, 2019.

Evaluation Scheme

The Evaluation Python Code of the crowdbenchmark.com is shown in ./misc/evaluation_code.py, which is similar to our validation code in trainer.py.

Citation

If you find this project is useful for your research, please cite:

@article{gao2020nwpu,
  title={NWPU-Crowd: A Large-Scale Benchmark for Crowd Counting and Localization},
  author={Wang, Qi and Gao, Junyu and Lin, Wei and Li, Xuelong},
  journal={IEEE Transactions on Pattern Analysis and Machine Intelligence},
  doi={10.1109/TPAMI.2020.3013269},
  year={2020}
}

Our code borrows a lot from the C^3 Framework, you may cite:

@article{gao2019c,
  title={C$^3$ Framework: An Open-source PyTorch Code for Crowd Counting},
  author={Gao, Junyu and Lin, Wei and Zhao, Bin and Wang, Dong and Gao, Chenyu and Wen, Jun},
  journal={arXiv preprint arXiv:1907.02724},
  year={2019}
}

If you use crowd counting models in this repo (MCNN, C3F-VGG, CSRNet, CANNet, SCAR, and SFCN+), please cite them.