Code2Img: Tree-Based Image Transformation for Scalable Code Clone Detection
The DOI matches its Crossref record; 7 of the 7 references it cites were found in a registry or an index.
Abstract
Code clone detection is an active research domain of software engineering. There are two core demands for clone detection: scalable detection and complicated clone detection. For scalable detection, existing approaches treat the source code as a text or token sequence and then calculate their similarity. However, the text-based and token-based approaches are difficult to detect complicated clone types due to the lack of consideration of code structure. The methods based on intermediate representations of code can effectively achieve complex clone types detection but are limited by the complexity of representations to be scalable. In this paper, we proposeCode2Img, a tree-based code clone detector, which satisfies scalability while detecting complicated clones effectively. Given the source code, we first perform clone filtering by the inverted index to locate the suspected clones. For each suspected clone, we create the adjacency image based on the adjacency matrix of the normalized abstract syntax tree (AST). Then we design an image encoder to highlight the structural details further and refine pixels of the image. Specifically, we employ the Markov model to encode the adjacency image into a state probability image and remove its useless pixels. By this, the original complex tree can be transformed into a one-dimensional vector while preserving the structural feature of the AST. Finally, we detect clones by calculating the Jaccard Similarity of these vectors. We conduct compa…
Overview
Integrity signals
Registry
Cites
Statistics
Verification
Claims the paper makes
Claims other papers make about this one
Each is checked against this paper’s own text: does it say what the citing paper says it does?
In the citing paper
“for Bef. problems we find that 6 solutions in easy and medium difficulties are Type-2 Clone (i.e., have some renamed unique identifiers) [49] to ground truth solutions.”
From No Need to Lift a Finger Anymore? Assessing the Quality of Code Generation by ChatGPT (2024) · cites this paper as [49]
Citations
Cites
DECKARD: Scalable and Accurate Tree-Based Detection of Code Clones
Jiang, L., Misherghi, G., Su, Z., & Glondu, S. (2007) · 29th International Conference on Software Engineering (ICSE'07) · doi:10.1109/icse.2007.30 · Cited by 1,039
A Novel Neural Source Code Representation Based on Abstract Syntax Tree
Zhang, J., Wang, X., Zhang, H., Sun, H., Wang, K., & Liu, X. (2019) · 2019 IEEE/ACM 41st International Conference on Software Engineering (ICSE) · doi:10.1109/icse.2019.00086 · Cited by 655
Roy, C. K., & Cordy, J. R. (2008) · 2008 16th IEEE International Conference on Program Comprehension · doi:10.1109/icpc.2008.41 · Cited by 533
Global optimization of a neural network-hidden Markov model hybrid
Bengio, Y., De Mori, R., Flammia, G., & Kompe, R. (1992) · IEEE Transactions on Neural Networks · doi:10.1109/72.125866 · Cited by 203
DéjàVu: a map of code duplicates on GitHub
Lopes, C. V., Maj, P., Martins, P., Saini, V., Yang, D., Zitny, J., Sajnani, H., & Vitek, J. (2017) · Proceedings of the ACM on Programming Languages · doi:10.1145/3133908 · Cited by 183
Evaluating clone detection tools with BigCloneBench
Svajlenko, J., & Roy, C. K. (2015) · 2015 IEEE International Conference on Software Maintenance and Evolution (ICSME) · doi:10.1109/icsm.2015.7332459 · Cited by 172
Searching for better configurations: a rigorous approach to clone evaluation
Wang, T., Harman, M., Jia, Y., & Krinke, J. (2013) · Proceedings of the 2013 9th Joint Meeting on Foundations of Software Engineering · doi:10.1145/2491411.2491420 · Cited by 147
Self-citation
Research works printed but not linked: 35
- 10.1007/s11432-017-9445-4 · doi:10.1007/s11432-017-9445-4
- 10.1145/3180155.3180179 · DOI
- 10.1109/ICSME.2017.46 · DOI · Paper page
- 10.1109/CSMR.2009.20 · DOI · Paper page
- 10.1109/TSE.2002.1019480 · DOI · Paper page
- 10.1007/978-981-16-1927-4_2 · DOI
- 10.1145/3324884.3416562 · DOI
- 10.1145/3236024.3236068 · DOI · Paper page
- 10.1109/SANER48275.2020.9054857 · DOI · Paper page
- 10.1007/BF00271633 · doi:10.1007/bf00271633
- 10.1145/2884781.2884877 · DOI · Paper page
- 10.1145/3468264.3468564 · DOI
- 10.1109/ACCESS.2020.2971545 · DOI
- 10.1007/s10664-019-09697-7 · DOI
- 10.1109/COMPSAC.2018.00045 · doi:10.1109/compsac.2018.00045
- Roy, 2007, A survey on software clone detection research, Queens School Comput. TR, 541, 64
- 10.1109/TSE.2007.70725 · DOI · Paper page
- 10.1145/2970276.2970326 · DOI · Paper page
- 10.24963/ijcai.2017/423 · DOI · Paper page
- 10.1145/3524610.3527896 · DOI
- 10.1609/aaai.v30i1.10139 · DOI · Paper page
- 10.1109/ISESE.2005.1541846 · DOI
- 10.1109/MSR.2017.15 · DOI
- 10.1109/WCRE.2012.48 · DOI
- 10.1109/IWSC.2017.7880507 · DOI
- 10.1109/ICSE-C.2017.78 · DOI
- Harris, 2007, Parallel prefix sum (scan) with CUDA, GPU Gems, 3, 851
- 10.1145/3236024.3236026 · DOI
- 10.1162/neco.1993.5.3.402 · DOI · Paper page
- 10.1109/SANER48275.2020.9054832 · DOI
- 10.1016/j.jss.2017.11.039 · DOI
- 10.1109/ICSM.2011.6080795 · DOI
- 10.1109/IWSC.2013.6613037 · DOI
- Yutao, TreeCen: Building tree graph for scalable semantic code clone detection, 1
- 10.1109/TR.2020.3001918 · DOI
Cited by
No Need to Lift a Finger Anymore? Assessing the Quality of Code Generation by ChatGPT
Liu, Z., Tang, Y., Luo, X., Zhou, Y., & Zhang, L. F. (2024) · IEEE Transactions on Software Engineering · doi:10.1109/tse.2024.3392499 · Cited by 128
“However, for Bef. problems we find that 6 solutions in easy and medium difficulties are Type-2 Clone (i.e., have some renamed unique identifiers) [49] to ground truth solutions.”
Background
Metadata
- Authors
- Hu, Y., Fang, Y., Sun, Y., Jia, Y., Wu, Y., Zou, D., & Jin, H.
- Affiliations
- Huazhong University of Science and Technology (CN)
- Nanyang Technological University (SG)
- Venue
- IEEE Transactions on Software Engineering
- Published
- 2023-09-01
- Volume
- 49
- Issue
- 9
- Pages
- 4429-4442
- ISSN
- 0098-5589 (ISSN-L)
- 1939-3520
- 2326-3881
- OpenAlex
- W4384499126
- Semantic Scholar
- ca4a6a2395ebc5c3f01fd979003a2c83d2cfc97c
- Cited by
- 9
- References
- 7
- Citations by year
- 2026: 3 · 2025: 1 · 2024: 5
- FWCI
- 2.11
- Type
- journal article
- Language
- en
- Open access
- closed
- Licence
- Locations
- IEEE Transactions on Software Engineering (publishedVersion)
- DR-NTU (Nanyang Technological University) (submittedVersion)
- Funders
- National Natural Science Foundation of China (62172168)
- Hubei Province Key R&D Technology Special Innovation Project (2021BAA032)
- Topics
- Physical Sciences › Computer Science › Information Systems › Software Engineering Research
- Physical Sciences › Computer Science › Software › Software Testing and Debugging Techniques
- Social Sciences › Education › Academic integrity and plagiarism
- Keywords
- code clone detection, abstract syntax tree, adjacency matrix, Markov model, Jaccard similarity, inverted index, scalability, source code structure
About these checks
Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.
Statistics and arithmetic are recomputed, not judged.
Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.
What counts as a claim ›How we measure confidence ›How we check this ›
Are you an author, or do you see a problem with this page? Request a review
How to cite
Cite CoChat for the checks on this page, and the paper for its own findings.
- This page
- CoChat. (2026). Citation check: Code2Img: Tree-Based Image Transformation for Scalable Code Clone Detection. https://app.cochat.ai/papers/10.1109/tse.2023.3295801
- The paper
- Hu, Y., Fang, Y., Sun, Y., Jia, Y., Wu, Y., Zou, D., & Jin, H. (2023). Code2Img: Tree-Based Image Transformation for Scalable Code Clone Detection. IEEE Transactions on Software Engineering. https://doi.org/10.1109/tse.2023.3295801
Data sources
Bibliographic data: Semantic Scholar, OpenAlex, Crossref.
Contains information from the Semantic Scholar Academic Graph Datasets, made available under the ODC Attribution License (ODC-BY 1.0).
Semantic Scholar’s data is described in: Kinney, R., et al. (2023). The Semantic Scholar Open Data Platform. arXiv:2301.10140.