Deep Cropping via Attention Box Prediction and Aesthetics Assessment

Wenguan Wang, Jianbing Shen

Abstract

Automating photo cropping requires a delicate balance between identifying the primary subject and applying artistic judgment. This paper introduces a deep learning-based approach that mimics the human creative process through a "determine-then-adjust" strategy. By cascading two specialized neural networks—one for attention box prediction and another for aesthetic assessment—the proposed model achieves state-of-the-art accuracy while maintaining real-time performance.

Introduction

Photo cropping is a fundamental task in image editing, yet automating it remains challenging. It necessitates both semantic understanding (identifying what is important) and artistic judgment (determining what is visually pleasing). Traditional automated methods often rely on a "sliding-window" approach, generating and scoring thousands of candidate windows across an image. This process is computationally intensive and differs significantly from how humans crop photos. Humans typically identify a subject first and then refine the frame around it. Furthermore, the lack of large-scale, high-quality cropping datasets makes training end-to-end models difficult.

Proposed Method: A Two-Stage Architecture

The authors propose a unified deep architecture that decomposes cropping into two distinct stages, mirroring human heuristics.

1. Attention Box Prediction (ABP)

The first stage involves identifying an "initial crop" or attention box. Using a VGG-based backbone, the ABP network performs bounding box regression to locate the most informative region of the image. This step significantly narrows the search space for the final crop.

2. Aesthetics Assessment (AA)

Once the attention box is established, the system generates approximately 1,000 cropping candidates by applying small offsets to the box's corners. The AA network then evaluates these candidates to select the most aesthetically pleasing window. To handle various aspect ratios without image distortion, the authors utilize Region of Interest (RoI) pooling, extracting fixed-length feature vectors directly from shared convolutional maps.

3. Shared Backbone and Efficiency

A key innovation is the use of a shared backbone for both tasks. By performing convolutions only once on the full image and sharing features, the model avoids the heavy computational load of processing individual candidates separately. This multi-task setup also encourages the learning of more robust, generalizable features.

Experimental Setup

To overcome the scarcity of dedicated cropping data, the model is trained using indirect but related datasets:

  • SALICON: Eye-fixation data used to train the ABP network for importance recognition.
  • AVA (Aesthetic Visual Analysis): Human-rated aesthetic scores used to train the AA network.
  • Evaluation: The system was benchmarked on the MSR-ICD and FLMS datasets, which contain expert-provided ground truth crops.

Results and Discussion

The proposed method demonstrates significant improvements in both accuracy and speed:

  • Accuracy: On the MSR-ICD dataset, the model achieved an Intersection over Union (IoU) of 0.813, outperforming previous state-of-the-art methods like LCC (0.748).
  • Performance: The pipeline operates at 5 frames per second (fps), making it suitable for real-time applications on consumer devices.
  • Qualitative Success: The model effectively adheres to photographic principles, such as the "rule of thirds," and ensures that vital parts of the main subject are not truncated.

Conclusion and Future Work

This research highlights that effective photo cropping can be achieved by learning constituent skills—attention and aesthetics—separately and then combining them in a cascaded architecture. While the current model is robust, future iterations could incorporate more complex photographic rules like symmetry or color harmony. Additionally, integrating user-defined aspect ratio constraints would enhance its utility for specific platforms like social media.

Summary updated

BibTeX
@inproceedings{wang2017deep,
  author = {Wenguan Wang and Jianbing Shen},
  title = {{Deep Cropping via Attention Box Prediction and Aesthetics Assessment}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2017},
  doi = {10.1109/iccv.2017.240},
}
Figure