• Home
  • Search
  • Improve Representation for Cross-Language Clone Detection by Pretrain Using Tree Autoencoder
  • Cite Icon1
  • https://doi.org/10.32604/iasc.2022.027349Copy DOI Icon

Improve Representation for Cross-Language Clone Detection by Pretrain Using Tree Autoencoder

Show More
  • Abstract
  • Highlights & Summary
  • PDF
  • Literature Map
  • References
  • Citations
  • Similar Papers
Abstract

With the rise of deep learning in recent years, many code clone detection (CCD) methods use deep learning techniques and achieve promising results, so is cross-language CCD. However, deep learning techniques require a dataset to train the models. The dataset is typically small and has a gap between real-world clones due to the difficulty of collecting datasets for cross-language CCD. This creates a data bottleneck problem: data scale and quality issues will cause that model with a better design can still not reach its full potential. To mitigate this, we propose a tree autoencoder (TAE) architecture. It uses unsupervised learning to pretrain with abstract syntax trees (ASTs) of a large-scale dataset, then fine-tunes the trained encoder in the downstream CCD task. Our proposed TAE contains a tree Long Short-Term Memory (LSTM) encoder and a tree LSTM decoder. We design a novel embedding method for AST nodes, including type embedding and value embedding. In the training of TAE, we present an “encode and decode by layers” strategy and a node-level batch size design. For the CCD dataset, we propose a negative sampling method based on probability distribution. The experimental results on two datasets verify the effeteness of our embedding method, as well as that TAE and its pretrain enhance the performance of the CCD model. The node context information is well captured, and the reconstruction accuracy of the node-value reaches 95.45%. TAE pretrain improves the performance of CCD with a 4% increase in F1 score, which alleviates the data bottleneck problem.

Loading PDF

Similar Papers
  • Conference Article
  • Citations1

Research on the Model of Legacy Software Reuse Based on Code Clone Detection

  • Sep 01, 2013
  • Meng Fanqi +1
  • Conference Article
  • Citations61

Incremental Code Clone Detection: A PDG-based Approach

  • Oct 01, 2011
  • Yoshiki Higo +3
  • Conference Article
  • Citations12

Rule-directed code clone synchronization

  • May 01, 2016
  • Xiao Cheng +4
  • Research Article

Code Clone Detection Model: A SWOT Analysis Perspective

  • Oct 01, 2018
  • Advanced Science Letters
  • Al-Fahim Mubarak-Ali +2
  • Conference Article

Code Clone Detection via Software Visualization Representation Learning

  • Jul 01, 2023
  • Proceedings/Proceedings of the ... International Conference on Software Engineering and Knowledge Engineering
  • Shaojian Qiu +4
  • Dissertation

Real-world applicable deep learning techniques

  • Jan 01, 2020
  • Ning Liu
  • Research Article
  • Citations8

Deep Learning for Financial Markets: A Case-Based Analysis of BRICS Nations in the Era of Intelligent Forecasting

  • Jan 05, 2025
  • Journal of Economics, Finance and Accounting Studies
  • Shake Ibna Abir +10
  • Research Article

Enhancing Seizure Detection Accuracy in Wearable EEG Devices Using Deep Learning Algorithms

  • Jan 01, 2025
  • Journal of Disability Research
  • Mohammed Alarfaj +4
  • Conference Article
  • Citations4

A Model-driven Approach for Token Based Code Clone Detection Techniques - An Introduction to UMLCCD

  • Mar 02, 2019
  • Qurat Ul Ain +3
  • Book Chapter
  • Citations25

Code Clone Detection—A Systematic Review

  • Jan 01, 2021
  • G Shobha +3
  • PDF
  • Research Article
  • Citations19

Adaptive Method for Exploring Deep Learning Techniques for Subtyping and Prediction of Liver Disease

  • Feb 12, 2024
  • Applied Sciences
  • Ali Mohammed Hendi +5
  • PDF
  • Research Article
  • Citations6

TCCCD: Triplet-Based Cross-Language Code Clone Detection

  • Nov 06, 2023
  • Applied Sciences
  • Yong Fang +3
  • Research Article

A survey on deep learning techniques in real-time applications

  • Jan 01, 2022
  • i-manager’s Journal on Pattern Recognition
  • Rekha Miriyala Kanthi +2
  • Conference Article
  • Citations3

Supporting clone analysis with tag cloud visualization

  • Nov 16, 2014
  • Manamu Sano +4
  • Conference Article
  • Citations4

A Deep Learning Based Approach to Detect Code Clones

  • Dec 01, 2020
  • Guangjie Li +3
Cactus Communications logo

Copyright 2026 Cactus Communications. All rights reserved.