This repository contains the guidelines of benchmark PKU PosterLayout and Pytorch implementation of DS-GAN for "PosterLayout: A New Benchmark and Approach for Content-aware Visual-Textual Presentation Layout", CVPR 2023.
For dataset details and downloads, please visit our project page.
Comparison of layouts generated by different approaches.
If your operating system is linux-64
, directly run
conda create --name yourenvname --file spec-file.txt
Otherwise, try
pip install -r requirements.txt
- Environment
Python 3.9
CUDA 11.0
- Module
torch==1.12.1
torchvision==0.13.1
timm==0.6.5
opencv-python==4.6.0.66
pandas==1.4.3
Pillow==9.2.0
- Download pre-trained weights from PKU Netdisk(pw: P04X) or Google Drive
- Put corresponding .pth files under
model_weight/
oroutput/
, as follow:
model_weight/
├─ resnet18-5c106cde.pth
├─ resnet50_a1_0-14fe96d1.pth
output/
├─ DS-GAN-Epoch300.pth
- Download PKU PosterLayout from the project page
- Unzip compressed files to corresponding directories
- Put directories under
Dataset/
, as follow:
Dataset/
├─ train/
│ ├─ inpainted_poster/
│ ├─ saliencymaps_basnet/
│ ├─ saliencymaps_pfpn/
├─ test/
│ ├─ image_canvas/
│ ├─ saliencymaps_basnet/
│ ├─ saliencymaps_pfpn/
├─ train_csv_9973.csv
- Training
sh train.sh
- Testing and Evaluating
sh test_n_eval.sh
If our work is helpful for your research, please cite our paper:
@inproceedings{Hsu-2023-posterlayout,
title={PosterLayout: A New Benchmark and Approach for Content-Aware Visual-Textual Presentation Layout},
author={HsiaoYuan Hsu, Xiangteng He, Yuxin Peng, Hao Kong and Qing Zhang},
booktitle={Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR)},
year={2023},
pages={6018-6026}
}
For any questions or further information, please email Ms. Hsu ([email protected]).