Towards Demystifying Dimensions of Source Code Embeddings
Not on the map. Why?
Abstract (arXiv)
Source code representations are key in applying machine learning techniques for processing and analyzing programs. A popular approach in representing source code is neural source code embeddings that represents programs with high-dimensional vectors computed by training deep neural networks on a large volume of programs. Although successful, there is little known about the contents of these vectors and their characteristics. In this paper, we present our preliminary results towards better understanding the contents of code2vec neural source code embeddings. In particular, in a small case study, we use the code2vec embeddings to create binary SVM classifiers and compare their performance with the handcrafted features. Our results suggest that the handcrafted features can perform very close to the highly-dimensional code2vec embeddings, and the information gains are more evenly distributed in the code2vec embeddings compared to the handcrafted features. We also find that the code2vec embeddings are more resilient to the removal of dimensions with low information gains than the handcrafted features. We hope our results serve a stepping stone toward principled analysis and evaluation of these code representations.
Key facts. Cited by 9 papers in the map (data through 14 Oct 2026). First posted on arXiv 29 Aug 2020.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2021: 4; 2022: 2; 2023: 3.
9 papers.
- 2021A Survey on Machine Learning Techniques for Source Code Analysiscited by 24
- 2021Understanding Neural Code Intelligence Through Program Simplificationcited by 22
- 2021Memorization and Generalization in Neural Code Intelligence Modelscited by 19
- 2022Syntax-Guided Program Reduction for Understanding Neural Code Intelligence Modelscited by 7
- 2021Code2Snapshot: Using Code Snapshots for Learning Representations of Source Codecited by 4
- 2023Study of Distractors in Neural Models of Codecited by 2
- 2023Redundancy and Concept Analysis for Code-trained Language Modelscited by 1
- 2022Extracting Label-specific Key Input Features for Neural Code Intelligence Modelscited by 0
- 2023A Study of Variable-Role-based Feature Enrichment in Neural Models of Codecited by 0
- 2023Redundancy and Concept Analysis for Code-trained Language Models1 May 2023
- 2023A Study of Variable-Role-based Feature Enrichment in Neural Models of Code8 Mar 2023
- 2023Study of Distractors in Neural Models of Code3 Mar 2023
- 2022Syntax-Guided Program Reduction for Understanding Neural Code Intelligence Models28 May 2022
- 2022Extracting Label-specific Key Input Features for Neural Code Intelligence Models14 Feb 2022
- 2021Code2Snapshot: Using Code Snapshots for Learning Representations of Source Code1 Nov 2021
- 2021A Survey on Machine Learning Techniques for Source Code Analysis18 Oct 2021
- 2021Memorization and Generalization in Neural Code Intelligence Models16 Jun 2021
- 2021Understanding Neural Code Intelligence Through Program Simplification7 Jun 2021