This repo provides source code for ICLR notable tiny paper "Key Patch Proposer: Key Patches Contain Rich Information".
This repo is a modification on the MAE repo.
You should follow the instruction of MAE to prepare your environment. https://github.com/facebookresearch/mae
To prepare images to be applied to KPP algorithm, you should collect them into a folder or you can rewrite dataset class in custom_datasets.py.
Run the following:
python KPP_main.py --data_path /path/to/your/images --ckpt /your/pretrained/ckpt.pth --output_dir /your/ourpur/dir --mask_ratio 0.75
You can also use --visulize True, to visulize what is generated by KPP algorithm in your images.