This project aims to estimate crowd density using only deep neural networks, without relying on any other detection methods. In the planning of this project, the refactoring of the code of the existing thesis method will be prioritized first, and then a new network architecture will be attempted to be used for density estimation
- đRefactor the code to improve readability
- đVisualization of results, output of images with bracketing and density maps
- đ ïžStructural harmonization, where only the network architecture is changed in the different approaches, while the rest remains unchanged
- đ[PLAN] Planning to refactor using Rust
- đ»[PLAN] Planning to design a real-time crowd estimation application
There are no special environmental requirements for this project, test with:
-
Ubuntu 22.04 | CUDA-11.8 | Pytorch-2.0.0 -
Windows 11 | CUDA-12.4 | Pytorch-2.4.0 -
[PLAN] Support for only-cpu in the future
This project use Kaggle-ShanghaiTech with Part-B, your file structure should be:
Crowd-Density-Estimation
ââdataset
â ââShanghaiTech_Crowd_Counting_Dataset
â ââpart_A_final
â â ââtest_data
â â â ââground_truth
â â â ââimages
â â ââtrain_data
â â ââground_truth
â â ââimages
â ââpart_B_final
â ââtest_data
â â ââground_truth
â â ââimages
â ââtrain_data
â ââground_truth
â ââimages
ââmodels
ââresult
ââckpt
ââdensity
ââimagesThe hyperparameters to be used for training are all set in config.py
python main.py --mode train
# or train&valid
python main.py --mode bothThe hyperparameters to be used for validate are all set in config.py
In this step, a density map and an RGB image with bounding boxes will be generated
- density map:
./result/density/[RUN_DATE]/ - rgb with boxes:
./result/image/[RUN_DATE]/
python main.py --mode test
# or train&valid
python main.py --mode both| Network | Best MAE â | Epoch |
|---|---|---|
| CAN | 9.329 | 100 |
| CAN(net structure revised) | 15.315 | 100(less time) |
| P2P-Net | ||
Context-Aware Crowd Counting
Rethinking Counting and Localization in Crowds:A Purely Point-Based Framework