GTCODP: Code Graph-Based Transport Learning with Optimal Plan Alignment for Code Defects Prediction
Some researchers use GCL on code graphs to realize code defects prediction in an self-supervised manner. While graph contrastive learning is a popular self-supervised method for function level code defects prediction, it faces challenges in finding label-invariant augmented graphs and determining the exact extent of similarity between sample pairs. It means that even small disturbance applied to the code graph can change the label of the code graph, which will significantly reducing the prediction performance. To deal with this problem, we propose GTCODP. Motivated by Optimal Transport (OT) Theory, GTCODP utilizes Optimal Transport Plan Alignment, which eliminates the need of distinguishing between positive/negative pairs thus improving the function level code defects prediction performance. Besides, experiments show that in activemq, lucene and derby datasets, GTCODP average improves F1-Score for 2.6%, Precision for 1.8%, AUC for 0.87% and Recall for 2.9% compared with GCL.
Authors
- Yuhai Zhao (ORCID: https://orcid.org/0000-0002-1080-0859)
- Mingqian Yu
Institutions
- Northeastern University (CN)
Publication Details
- Published
- 2024-10-11
- DOI
- https://doi.org/10.1109/cbase64041.2024.10824402
- Primary Topic
- Software Engineering Research
- Type
- article
- Field-Weighted Citation Impact
- 0.00