Skip to main content
Log in

Optimizing seam carving on multi-GPU systems for real-time content-aware image resizing

  • Published:
The Journal of Supercomputing Aims and scope Submit manuscript

Abstract

Image resizing is increasingly important for picture sharing and exchanging between various personal electronic equipments. Seam Carving is a state-of-the-art approach for effective image resizing because of its content-aware characteristic. However, complex computation and memory access patterns make it time consuming and prevent its wide usage in real-time image processing. To address these problems, we propose a novel algorithm, called Non-Cumulative Seam Carving (NCSC), which removes main computation bottleneck. Furthermore, we also propose Partial update of Index Map (PIM) algorithm to reduce computation amount. Finally, we implement our algorithm on a multi-GPU platform. Results show that our approach achieves maximum \(10\times \) speedup over the original seam carving implementation on a single-GPU system. It also presents maximum \(103\times \) speedup on a two-GPU system over the single-thread CPU implementation of original seam carving algorithm. NCSC only takes 0.10 s to reduce a \(1024 \times 640\) image to 70 % in width on a two-GPU platform compared to 11 s with the traditional seam carving on a single-thread CPU system.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13
Fig. 14
Fig. 15
Fig. 16
Fig. 17
Fig. 18
Fig. 19
Fig. 20
Fig. 21
Fig. 22
Fig. 23

Similar content being viewed by others

References

  1. Achanta R, Süsstrunk S (2009) Saliency detection for content-aware image resizing. In: ICIP, IEEE pp 1005–1008

  2. ARM (2013) Mali OpenCL SDK v1.1.0 Documentation. http://malideveloper.arm.com/develop-for-mali/tutorials-developer-guides/sdk-tutorials/mali-opencl-sdk-tutorial/

  3. Avidan S, Shamir A (2007) Seam carving for content-aware image resizing. ACM Trans Graph 26(3):10

    Article  Google Scholar 

  4. Cebrian JM, Guerrero GD (2012) Energy efficiency analysis of GPUs. In: Proc. High-Performance, Power-Aware Computing-3rd HPPAC’12, Proc. IEEE International Parallel and Distributed Processing Symposium Workshops & Ph.D. Forum (26th IPDPS’12), IEEE Computer Society, Shanghai, China, pp 1014–1022

  5. Chen LQ, Xie X (2003) A visual attention model for adapting images on small displays. Multimed Syst 9(4):353–364

    Article  Google Scholar 

  6. Ciocca G, Cusano C (2007) Self-adaptive image cropping for small displays. IEEE Trans Consum Electron 53(4):1622–1627

    Article  Google Scholar 

  7. Duarte R, Sendag R (2012) Accelerating and characterizing seam carving using a heterogeneous cpu-gpu system. PDPTA

  8. Harris M (2007) Optimizing parallel reduction in cuda (2007). CUDA SDK Whitepaper

  9. Hong S, Kim SK (2011) Accelerating CUDA graph algorithms at maximum warp. In: Proceedings of the 16th ACM/SIGPLAN Symposium on Principles and Practice of Parallel Programming (16th PPOPP’11), ACM Press, San Antonio, TX, USA, pp 267–276

  10. Lee VW, Kim C (2010) Debunking the 100X GPU vs. CPU myth: an evaluation of throughput computing on CPU and GPU. In: Proc. 37th International Symposium on Computer Architecture (37th ISCA’10), ACM SIGARCH, Saint-Malo, France pp 451–460

  11. Mansfield A, Gehler P (2012) Visibility maps for improving seam carving. In: Proceedings of the 11th European Conference on Trends and Topics in Computer Vision-Volume Part II, ECCV’10, Springer, Berlin, Heidelberg, pp 131–144

  12. NVIDIA: Cuda C Programming Guide (2014). http://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html

  13. Pritch (2009) Shift-map image editing. In: Computer Vision, 2009 IEEE 12th International Conference on, IEEE, pp 151–158

  14. Santella A, Agrawala M (2006) Gaze-based interaction for semi-automatic photo cropping. In: Proceedings of the SIGCHI Conference on Human Factors in Computing Systems, CHI ’06, ACM, New York, NY, USA, pp 771–780

  15. Stultz J (2008) Seam carving: parallelizing a novel new image resizing algorithm. http://beowulf.lcs.mit.edu/18.337-2008/projects/reports/stultz-6338.pdf

  16. Suh B, Ling H (2003) Automatic thumbnail cropping and its effectiveness. In: UIST, ACM pp 95–104

  17. Thilagam K, Karthikeyan S (2011) An efficient method for content aware image resizing using psc. Int J Comput Technol Appl 2(4) 807–812

  18. Thilagam K, Karthikeyan S (2012) Article: optimized image resizing using piecewise seam carving. Int J Comput Appl 42(14):24–30 Published by Foundation of Computer Science, New York, USA

    Google Scholar 

  19. Zhai J, Chen W, Zheng W (2010) Phantom: predicting performance of parallel applications on large-scale parallel machines using a single node. ACM SIGPLAN Not 45(5):305–314

Download references

Acknowledgments

We sincerely thank the anonymous reviewers for their valuable comments and suggestions. Special thanks goes to Feng Zhang, Xiongchao Tang, Heng Lin, Haojie Wang, Bowen Yu and Haoyu Dong for taking the time and efforts to participate in our survey. This work has been partially supported by the NSFC project 61472201 and National High-Tech Research and Development Plan (863 project) 2012AA010901.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Jidong Zhai.

Additional information

A preliminary version containing some of the results in this paper has been published in the ICPADS 2014.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Kim, I., Zhai, J., Li, Y. et al. Optimizing seam carving on multi-GPU systems for real-time content-aware image resizing. J Supercomput 71, 3500–3524 (2015). https://doi.org/10.1007/s11227-015-1446-4

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11227-015-1446-4

Keywords

Navigation