Skip to main content

Accelerating All 5-Vertex Subgraphs Counting Using GPUs

  • Conference paper
  • First Online:
Database and Expert Systems Applications (DEXA 2020)

Part of the book series: Lecture Notes in Computer Science ((LNISA,volume 12391))

Included in the following conference series:

Abstract

The subgraph counting problem is the problem of counting the number of occurrences of graph patterns in the target graph and is widely used as a fundamental technique for network analyses in different domains. The computational cost of subgraph counting grows drastically as the size of the pattern increases; it takes much time even with the state-of-the-art algorithms when counting 5-vertex patterns. To this problem, this paper proposes a subgraph counting method using GPUs. More precisely, we employ one of the state-of-the-art algorithms for 5-vertex subgraph counting and extend it so that counting is executed in parallel using massive threads. We conducted experiments for evaluating the performance of our proposed method by using real-world datasets, and the results demonstrate that our proposed method is about 4x to 10x and about 3\(\times \) to 5\(\times \) times faster than the original method in computing 5-vertex and 4-vertex subgraphs, respectively.

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

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 79.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 99.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    We have slightly changed the definition from the original one in the ESCAPE paper to maintain the consistency of the theorem.

References

  1. Escape. https://bitbucket.org/seshadhri/escape

  2. Openacc-standard.org. https://www.openacc.org/sites/default/files/inline-images/Specification/OpenACC.3.0.pdf

  3. Ahmed, N.K., Neville, J., Rossi, R.A., Duffield, N.: Efficient graphlet counting for large networks. In: 2015 IEEE International Conference on Data Mining, pp. 1–10. IEEE (2015)

    Google Scholar 

  4. Bhuiyan, M.A., Rahman, M., Rahman, M., Al Hasan, M.: Guise: uniform sampling of graphlets for large graph analysis. In: 2012 IEEE 12th International Conference on Data Mining, pp. 91–100. IEEE (2012)

    Google Scholar 

  5. Chiba, N., Nishizeki, T.: Arboricity and subgraph listing algorithms. SIAM J. Comput. 14(1), 210–223 (1985)

    Article  MathSciNet  Google Scholar 

  6. Choobdar, S., Ribeiro, P., Bugla, S., Silva, F.: Comparison of co-authorship networks across scientific fields using motifs. In: 2012 IEEE/ACM International Conference on Advances in Social Networks Analysis and Mining, pp. 147–152. IEEE (2012)

    Google Scholar 

  7. Durak, N., Pinar, A., Kolda, T.G., Seshadhri, C.: Degree relations of triangles in real-world networks and graph models. In: Proceedings of the 21st ACM International Conference on Information and Knowledge Management, pp. 1712–1716 (2012)

    Google Scholar 

  8. Elenberg, E.R., Shanmugam, K., Borokhovich, M., Dimakis, A.G.: Distributed estimation of graph 4-profiles. In: Proceedings of the 25th International Conference on World Wide Web, pp. 483–493 (2016)

    Google Scholar 

  9. Ho č evar, T.ž., Dem š ar, J.: A combinatorial approach to graphlet counting. Bioinformatics 30(4), 559–565 (2014)

    Google Scholar 

  10. Hayes, W., Sun, K., Pr ž ulj, N.š.a.: Graphlet-based measures are suitable for biological network comparison. Bioinformatics 29(4), 483–491 (2013)

    Google Scholar 

  11. Jha, M., Seshadhri, C., Pinar, A.: Path sampling: a fast and provable method for estimating 4-vertex subgraph counts. In: Proceedings of the 24th International Conference on World Wide Web, pp. 495–505 (2015)

    Google Scholar 

  12. Leskovec, J., Krevl, A.: SNAP Datasets : Stanford large network dataset collection. http://snap.stanford.edu/data June 2014

  13. Marcus, D., Shavitt, Y.: Rage-a rapid graphlet enumerator for large networks. Comput. Netw. 56(2), 810–819 (2012)

    Article  Google Scholar 

  14. Ortmann, Mark, Brandes, Ulrik: Quad census computation: simple, efficient, and orbit-aware. In: Wierzbicki, Adam, Brandes, Ulrik, Schweitzer, Frank, Pedreschi, Dino (eds.) NetSci-X 2016. LNCS, vol. 9564, pp. 1–13. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-28361-6_1

    Chapter  Google Scholar 

  15. Pinar, A., Seshadhri, C., Vishal, V.: Escape: efficiently counting all 5-vertex subgraphs. In: Proceedings of the 26th International Conference on World Wide Web, pp. 1431–1440. International World Wide Web Conferences Steering Committee (2017)

    Google Scholar 

  16. Rahman, M., Bhuiyan, M., Hasan, M.A.: Graft: an approximate graphlet counting algorithm for large graph analysis. In: Proceedings of the 21st ACM International Conference on Information and Knowledge Management, pp. 1467–1471 (2012)

    Google Scholar 

  17. Rahman, M., Bhuiyan, M.A., Al Hasan, M.: Graft: an efficient graphlet counting method for large graph analysis. IEEE Trans. Knowl. Data Eng. 26(10), 2466–2478 (2014)

    Article  Google Scholar 

  18. Ribeiro, P., Paredes, P., Silva, M.E., Aparicio, D., Silva, F.: A survey on subgraph counting: concepts, algorithms and applications to network motifs and graphlets. arXiv preprint arXiv:1910.13011 (2019)

  19. Rossi, R.A., Ahmed, N.K.: The network data repository with interactive graph analytics and visualization. In: AAAI (2015). http://networkrepository.com

  20. Rossi, R.A., Zhou, R.: Leveraging multiple GPUS and CPUS for graphlet counting in large networks. In: Proceedings of the 25th ACM International on Conference on Information and Knowledge Management, pp. 1783–1792. ACM (2016)

    Google Scholar 

  21. Rupp, M., Schneider, G.: Graph kernels for molecular similarity. Molecular Inform. 29(4), 266–273 (2010)

    Article  Google Scholar 

  22. Schank, Thomas, Wagner, Dorothea: Finding, counting and listing all triangles in large graphs, an experimental study. In: Nikoletseas, Sotiris E. (ed.) WEA 2005. LNCS, vol. 3503, pp. 606–609. Springer, Heidelberg (2005). https://doi.org/10.1007/11427186_54

    Chapter  MATH  Google Scholar 

  23. Shizuka, D., McDonald, D.B.: A social network perspective on measurements of dominance hierarchies. Animal Behav. 83(4), 925–934 (2012)

    Article  Google Scholar 

  24. Sporns, O., Kötter, R.: Motifs in brain networks. PLoS Biology 2(11) 56–62 (2004)

    Google Scholar 

  25. Tsourakakis, C.E., Pachocki, J., Mitzenmacher, M.: Scalable motif-aware graph clustering. In: Proceedings of the 26th International Conference on World Wide Web, pp. 1451–1460 (2017)

    Google Scholar 

  26. Wang, P., Zhao, J., Zhang, X., Li, Z., Cheng, J., Lui, J.C., Towsley, D., Tao, J., Guan, X.: Moss-5: a fast method of approximating counts of 5-node graphlets in large graphs. IEEE Trans. Knowl. Data Eng. 30(1), 73–86 (2017)

    Article  Google Scholar 

Download references

Acknowledgement

We thank to Prof. Hiroaki Shiokawa and Prof. Ryohei Kobayashi at the Center for Computational Sciences, University of Tsukuba for their useful discussions and support. This research was supported (in part) by Multidisciplinary Cooperative Research Program in CCS, University of Tsukuba.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Shuya Suganami .

Editor information

Editors and Affiliations

Appendices

Appendix

A Counting Other Subgraphs

Table 3. Additional Notation

For other subgraphs, we can use simple formulas as described below. We can easily parallelize them.

$$\begin{aligned} F_{3}&= \sum _{(i,j \in E}(d(i)-)(d(j)-1) - 3F_{1}, F_{4} = \sum _{i \in V}\left( {\begin{array}{c}d(i)\\ 3\end{array}}\right) , F_{5} = \sum _{i \in V}t(i)(d(i)-2),\\[-0.5em] F_{6}&= \sum _{i \in V}\sum _{j \prec i}\left( {\begin{array}{c}W_{++}(i,j)+W_{+-}(i,j)\\ 2\end{array}}\right) , F_{7} = \sum _{(i,n) \in E}\left( {\begin{array}{c}|T(i,j)|\\ 2\end{array}}\right) , F_{9} = \sum _{i \in V}\left( {\begin{array}{c}d(i)\\ 4\end{array}}\right) \\[-0.5em] F_{10}&= \sum _{(i,j) \in E}[(d(i)-1)\left( {\begin{array}{c}(d(j)-1)\\ 2\end{array}}\right) + (d(j)-1)\left( {\begin{array}{c}(d(i)-1)\\ 2\end{array}}\right) ] - 2F_{5}\\[-2.0em]\\ F_{11}&= \sum _{i \in V}\sum _{(i,j) \in E}(d(j)-1) - 4F_{6} - F_{5} - 3F_{1}, F_{12} = \sum _{i \in V}t(i)(d(i)-2)\\[-0.5em] F_{13}&= \sum _{(i,j) \in E}((d(i)-1)t(j)+(d(j)-1)t(i)) - 4F_{7} - 6F_{1} - 2F_{5}\\[-0.5em] F_{14}&= \sum _{(i,j) \in E}|T(i,j)|(d(i)-2)(d(j)-2) - 2F_{7}, F_{15} = \sum _{i \in V}C_{4}(i)(d(i)-2) -2F_{7}\\[-0.7em] F_{17}&= \sum _{i \in V}\left( {\begin{array}{c}t_{i}\\ 2\end{array}}\right) - 2F_{7}, F_{18} = \sum _{(i,j) \in E}\sum _{k \in T(i,j)}(d(k) -2)(|T(i,j)| - 1) - 12F_{8}\\[-1.0em] F_{19}&= \sum _{(i,j) \in E}\left( {\begin{array}{c}|T(i,j)|\\ 2\end{array}}\right) (d(i) + d(j) - 6), F_{20} = \sum _{(i,j) \in E}C_{4}(i,j)|T(i,j)| - 4F_{7}\\[-1em] F_{21}&= \sum _{i \in V}\sum _{i \prec j}\left( {\begin{array}{c}W(i,j)\\ 3\end{array}}\right) , F_{22}= \sum _{(i,j) \in E}\left( {\begin{array}{c}|T(i,j)|\\ 3\end{array}}\right) , F_{23} = \sum _{i \in V}K_{4}(i)(d(i)-3)\\[-0.5em] F_{24}&= \sum _{(i,j) \in E}\sum _{k \in T(i,j)}((|T(i,j)| - 1)(|T(i,k)| - 1)\\[-0.5em]&+ (|T(i,j)|-1)(|T(j,k)|-1) + (|T(j,k)| - 1)(|T(i,k)|-1))\\[-0.5em] F_{26}&= \sum _{u < |diamondValue[u]|} \left( {\begin{array}{c}diamonValue[u]\\ 2\end{array}}\right) , F_{27} = \sum _{(i,j) \in E}K_{4}(i,j)(|T(i,j)|-2) \end{aligned}$$

Rights and permissions

Reprints and permissions

Copyright information

© 2020 Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Suganami, S., Amagasa, T., Kitagawa, H. (2020). Accelerating All 5-Vertex Subgraphs Counting Using GPUs. In: Hartmann, S., Küng, J., Kotsis, G., Tjoa, A.M., Khalil, I. (eds) Database and Expert Systems Applications. DEXA 2020. Lecture Notes in Computer Science(), vol 12391. Springer, Cham. https://doi.org/10.1007/978-3-030-59003-1_4

Download citation

  • DOI: https://doi.org/10.1007/978-3-030-59003-1_4

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-030-59002-4

  • Online ISBN: 978-3-030-59003-1

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics