An online cropping demo is avaliable !

The demo's API is also avaliable !

Abstract

Image cropping aims at improving the aesthetic quality of images by adjusting their composition. Most previous methods rely on the sliding window mechanism. The sliding window mechanism requires fixed aspect ratios and limits the cropping region with arbitrary size. Moreover, the sliding window method usually produces tens of thousands of windows which is very time-consuming. Motivated by these challenges and also inspired by the human's cropping process, we firstly formulate the aesthetic image cropping as a sequential decision-making process and propose an Aesthetics Aware Reinforcement Learning (A2-RL) framework to address this problem. Particularly, the proposed method develops an aesthetics aware reward function which especially benefits image cropping. Similar to human's decision making and to better utilize the historical experience, we use a LSTM based state representation including both the current and historical experience. We train the agent using the actor-critic architecture in an end-to-end manner. The agent is evaluated on several popular unseen cropping databases. Experiment results show that our method achieves the state-of-the-art performance with much fewer candidate windows and much less time compared with previous methods.

Code and Extras

You can find the code on Github, including:
  • Test code (uses TensorFlow/Python)
  • Pretrained models and datasets
  • Step-by-step tutorial to run our algorithm

Bibtex

@inproceedings{li2018a2rl,
  title={A2-RL: Aesthetics Aware Reinforcement Learning for Image Cropping},
  author={Li, Debang and Wu, Huikai and Zhang, Junge and Huang, Kaiqi},
  booktitle={CVPR},
  year={2018}
}

Results from Flickr Cropping Dataset (for Comparision Results)

Flag Counter