A conceptual framework for clone detection using machine learning
Javad Ghofrani, Mahdi Mohseni, Arezoo Bozorgmehr · 2017
Code clones can happen in any software project. One of the challenges is that, code clones come in various forms which makes them hard to detect using standard templates. Due to this variety in structure and form of semantically similar clones, machine learning techniques are required to detect them. Recently in many domains, e.g., natural language processing, deep neural networks drew a lot of attention due to their accuracy. In this paper, we exploit the results of some convolutional neural networks for code summarization to find the code clones. We use the generated descriptions for two code snippets as a metric to measure the similarities between them. We propose a vector similarity measure to calculate a similarity indicator between these measures which can decide which code snippets are clones.