README.md
April 25, 2025 ยท View on GitHub
Progressive Pretext Task Learning for Human Trajectory Prediction
Xiaotong Linโ
Tianming Liangโ
Jianhuang Laiโ
Jian-Fang Hu*โ
Sun Yat-sen University
ECCV 2024
๐ Abstract
๐ Implementation
I. Installation
Environment
- Python == 3.8.3
- PyTorch == 1.7.0
Dependencies
Install the dependencies from the requirements.txt:
pip install -r requirements.txt
Pre-trained Models and Pre-processed Data
We provide a complete set of pre-trained models, including:
- Well-pretrained model on Task-I:
- The model after warm-up:
- Well-pretrained model on Task-II:
- Well-trained model on Task-III:
You can download the pre-trained models and the pre-processed data from here.
File Structure
After the preparation work, the whole project should has the following structure:
./MemoNet
โโโ README.md
โโโ data # datasets
โ โโโ ETH_UCY
โ โ โโโ social_eth_test_256_0_50.pickle
โ โ โโโ social_eth_train_256_0_50.pickle
โ โ โโโ ...
โ โโโ ETH_image
โ โ โโโ eth.jpg
โ โ โโโ eth_H.txt
โ โ โโโ ...
โย ย โโโ social_sdd_test_4096_0_100.pickle
โย ย โโโ social_sdd_train_512_0_100.pickle
โโโ models # core models
โย ย โโโ layer_utils.py
โย ย โโโ model.py
โย ย โโโ ...
โโโ requirements.txt
โโโ run.sh
โโโ sddloader.py # sdd dataloader
โโโ test_PPT.py # testing code
โโโ train_PPT.py # training code
โโโ trainer # core operations to train the model
โย ย โโโ evaluations.py
โย ย โโโ test_final_trajectory.py
โย ย โโโ trainer_AIO.py
โโโ training # saved models/memory banks
โโโ Pretrained_Models
ย ย โโโ SDD
ย ย โ โโโ Model_ST
ย ย โ โโโ Model_Des_warm
ย ย โ โโโ Model_LT
ย ย โ โโโ Model_ALL
ย ย โโโ ETH_UCY
ย ย โโโ model_eth_res
ย ย โโโ model_hotel_res
ย ย โโโ ...
II. Training
Important configurations.
--mode: verify the current training mode,--model_Pretrain: pretrained model path,--info: path name to store the models,--gpu: number of devices to run the codes,
Training commands.
bash run.sh
III. Reproduce
To get the reported results, following
python test_PPT.py --reproduce --info reproduce --gpu 0
And the code will output:
./training/Pretrained_Models/SDD/model_ALL
Loaded data!
Test FDE_48s: 10.650254249572754 ------ Test ADE: 7.032739639282227
----------------------------------------------------------------------------------------------------
IV. Visualization
We also provide the visualization code for the ETH/UCY dataset. For example, to visualize trajectories in the univ scene, use the following command:
python test_PPT.py --vis --dataset_name eth --data_scene 'univ' --model_Pretrain './training/Pretrained_Models/ETH_UCY/model_univ' --gpu 0
๐ Overview
Qualitative Comparisons with Pure Diffusion
๐ Acknowledgements
We sincerely thank the authors of MemoNet for providing the source code from their CVPR 2022 publication. We also appreciate the pre-processed data from PECNet. These resources have been invaluable to our work, and we are immensely grateful for their support.
๐ Citation
If you find our work helpful, please cite:
@inproceedings{
lin2024progressive,
title={Progressive Pretext Task Learning for Human Trajectory Prediction},
author={Lin, Xiaotong and Liang, Tianming and Lai, Jianhuang and Hu, Jian-Fang},
booktitle={ECCV},
year={2024},
}