Note: Not all frames can draw a Heatmap image, which may be a bug.
This code has been tested on Ubuntu 18.04, Python 3.7, Pytorch 1.7.1, CUDA 11.1. Please install related libraries before running this code:
pip install -r requirements.txt
cd toolkit/utils/
python setup.py build_ext --inplace
cd /path/to/SiamCAR-CAM
conda activate SiamCAR
export PYTHONPATH=./:$PYTHONPATH
python tools/CAM-demo.py \
--dataset_dir /path/to/dataset/root \ # dataset path
--dataset UAV123 \ # dataset name(OTB100, GOT-10k, LaSOT, UAV123)
--snapshot snapshot/general_model.pth \ # tracker_name
--format bmp \ # save fomat (pdf,png,jpg,bmp)
--CAM_name GroupCAM \ # CAM_name (GroupCAM, GradCAM, GradCAMpp, SmoothGradCAM, ScoreCAM)
--save_dir /path/to/save \ # save dir
--config ./experiments/siamcar_r50/config.yaml \ # config file
--register_layer softmax \ # module register name
cd /path/to/SiamCAR-CAM
conda activate SiamCAR
export PYTHONPATH=./:$PYTHONPATH
python tools/tune.py \
--dataset_dir /path/to/dataset/root \ # dataset path
--dataset UAV123 \ # dataset name(OTB100, LaSOText, LaSOT, UAV123, VOT2016, VOT2018, VOT2019)
--snapshot snapshot/general_model.pth \ # tracker_name
--config ./experiments/siamcar_r50/config.yaml \ # config file
1.Fixed errors in image normalization due to different versions of torchvision.
2.Fix the UnNormalize dimension error.
1.Fixed an error caused by the addition of tensor and numpy data in the show_cam function due to version problems
1.Fixed a problem with missing "time.txt" files during GOT10k testing.
1.Add SiamCAR hyperparameter search code.
1.The code supports the drawing of multiple CAM
2.Add Rise visualization code
Fix bug in parameter search
Fixed the issue that parameters could not be searched under GOT-10k
1.Fix a code bug from 2022.11.20