paper-with-me

홈 › Papers

Demystifying What Code Summarization Models Learned

2023-03-04 · Yu Wang, Ke Wang

Study patterns that models have learned has long been a focus of pattern recognition research. Explaining what patterns are discovered from training data, and how patterns are generalized to unseen data are instrumental to understanding and advancing the pattern recognition methods. Unfortunately, the vast majority of the application domains deal with continuous data (i.e. statistical in nature) out of which extracted patterns can not be formally defined. For example, in image classification, there does not exist a principle definition for a label of cat or dog. Even in natural language, the meaning of a word can vary with the context it is surrounded by. Unlike the aforementioned data format, programs are a unique data structure with a well-defined syntax and semantics, which creates a golden opportunity to formalize what models have learned from source code. This paper presents the first formal definition of patterns discovered by code summarization models (i.e. models that predict the name of a method given its body), and gives a sound algorithm to infer a context-free grammar (CFG) that formally describes the learned patterns. We realize our approach in PATIC which produces CFGs for summarizing the patterns discovered by code summarization models. In particular, we pick two prominent instances, code2vec and code2seq, to evaluate PATIC. PATIC shows that the patterns extracted by each model are heavily restricted to local, and syntactic code structures with little to none semantic implication. Based on these findings, we present two example uses of the formal definition of patterns: a new method for evaluating the robustness and a new technique for improving the accuracy of code summarization models. Our work opens up this exciting, new direction of studying what models have learned from source code.

📄 PDF Abstract BibTeX arXiv:2303.02333

Code (0)

등록된 구현이 없습니다.

Tasks

Code Summarizationimage-classificationImage Classification

Methods 이 논문이 사용한 방법론

None 설명 없음

Similar Papers 제목 키워드 기반

Demystifying Multi-Faceted Video Summarization: Tradeoff Between Diversity,Representation, Coverage and Importance

2019-01-03 · Vishal Kaushal, Rishabh Iyer, Khoshrav Doctor, Anurag Sahoo 외

This paper addresses automatic summarization of videos in a unified manner. In particular, we propose a framework for multi-faceted summarization for extractive, query base and entity summarization (summarization at the …

DiversityVideo Summarization

Demystifying Variational Diffusion Models

2024-01-11 · Fabio De Sousa Ribeiro, Ben Glocker

Despite the growing popularity of diffusion models, gaining a deep understanding of the model class remains somewhat elusive for the uninitiated in non-equilibrium statistical physics. With that in mind, we present what …

Sparse Dictionary-based Attributes for Action Recognition and Summarization

2013-08-01 · Qiang Qiu, Zhuolin Jiang, Rama Chellappa

We present an approach for dictionary learning of action attributes via information maximization. We unify the class distribution and appearance information into an objective function for learning a sparse dictionary of …

Action RecognitionDictionary LearningTemporal Action Localization

Demystifying Contrastive Self-Supervised Learning: Invariances, Augmentations and Dataset Biases

2020-07-28 · NeurIPS 2020 12 · Senthil Purushwalkam, Abhinav Gupta

Self-supervised representation learning approaches have recently surpassed their supervised learning counterparts on downstream tasks like object detection and image classification. Somewhat mysteriously the recent gains…

ClassificationGeneral Classificationimage-classificationImage Classification+7

Demystifying the Mechanisms Behind Emergent Exploration in Goal-conditioned RL

2025-10-15 · Mahsa Bastankhah, Grace Liu, Dilip Arumugam, Thomas L. Griffiths 외 arxiv

In this work, we take a first step toward elucidating the mechanisms behind emergent exploration in unsupervised reinforcement learning. We study Single-Goal Contrastive Reinforcement Learning (SGCRL), a self-supervised …

Reinforcement Learning