This is the modified version of the repository RelationalGraphLearning, which provides a framework for training the RGL policy. It has been extended to additionally:
- Train additonal policies
- Train under additonal scenarios that consider social conformity
- Test under a set of metrics that evaluates both model performance and social comforminity.
This project assists in the research Metrics for Evaluating Social Conformity of Crowd Navigation Algorithms
- Install Python-RVO2 library
- Install socialforce library
- Install crowd_sim and crowd_nav into pip
pip install -e .
This repository are organized in two parts: crowd_sim/ folder contains the simulation environment and crowd_nav/ folder contains codes for training and testing the policies. Details of the simulation framework can be found here. Below are the instructions for training and testing policies, and they should be executed inside the crowd_nav/ folder.
python train.py --config 'condigs/icra_benchmark/<your_config_choice>.py' --output_dir 'data/<new_model_name>'
python train.py --output_dir 'data/<new_model_name>' --resume
This will produce checkpoints of the name "resumed_rl_model_.pth", where epoch count start from 0, to differentiate from originally trained checkpoints. To intergrate those resumed checkpoints, use the utility script "modify_model_name.py" in the base folder. This will rename all "resumed_rl_model_.pth" to "rl_model_<epoch + highest_existing_epoch>.pth", so epoch number continues from the highest one from existng model. It could also update "rl_model.pth" and "best_val.pth" to the latest checkpoint from the resumed training if the respective argument is set.
python utils/plot.py data/output/output.log
The remaining arguments to the training can be found at the bottom of train.py
To make your own config, follow the format of any other config that is not the base "config.py", which is inherited by all other configs.
python test.py --config 'condigs/icra_benchmark/<your_config_choice>.py' --model_dir 'data/<model_name>' --phase test
python test.py --config 'condigs/icra_benchmark/<your_config_choice>.py' --model_dir 'data/<model_name>' --phase test --visualize --test_case 0
The remaining arguments to the training can be found at the bottom of test.py