Estimating defectiveness of source code: A predictive model using GitHub content

03/21/2018
by   Ritu Kapur, et al.
0

Two key contributions presented in this paper are: i) A method for building a dataset containing source code features extracted from source files taken from Open Source Software (OSS) and associated bug reports, ii) A predictive model for estimating defectiveness of a given source code. These artifacts can be useful for building tools and techniques pertaining to several automated software engineering areas such as bug localization, code review, and recommendation and program repair. In order to achieve our goal, we first extract coding style information (e.g. related to programming language constructs used in the source code) for source code files present on GitHub. Then the information available in bug reports (if any) associated with these source code files are extracted. Thus fetched un(/ semi)-structured information is then transformed into a structured knowledge base. We considered more than 30400 source code files from 20 different GitHub repositories with about 14950 associated bug reports across 4 bug tracking portals. The source code files considered are written in four programming languages (viz., C, C++, Java, and Python) and belong to different types of applications. A machine learning (ML) model for estimating the defectiveness of a given input source code is then trained using the knowledge base. In order to pick the best ML model, we evaluated 8 different ML algorithms such as Random Forest, K Nearest Neighbour and SVM with around 50 parameter configurations to compare their performance on our tasks. One of our findings shows that best K-fold (with k=5) cross-validation results are obtained with the NuSVM technique that gives a mean F1 score of 0.914.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
04/19/2020

BuGL – A Cross-Language Dataset for Bug Localization

Bug Localization is the process of locating potential error-prone files ...
research
04/15/2020

Ownership at Large – Open Problems and Challenges in Ownership Management

Software-intensive organizations rely on large numbers of software asset...
research
12/07/2022

Utilizing Source Code Syntax Patterns to Detect Bug Inducing Commits using Machine Learning Models

Detecting Bug Inducing Commit (BIC) or Just in Time (JIT) defect predict...
research
01/25/2022

Leveraging Structural Properties of Source Code Graphs for Just-In-Time Bug Prediction

The most common use of data visualization is to minimize the complexity ...
research
04/29/2021

Using Paragraph Vectors to improve our existing code review assisting tool-CRUSO

Code reviews are one of the effective methods to estimate defectiveness ...
research
04/10/2021

ManyTypes4Py: A Benchmark Python Dataset for Machine Learning-based Type Inference

In this paper, we present ManyTypes4Py, a large Python dataset for machi...
research
03/02/2021

Follow Your Nose – Which Code Smells are Worth Chasing?

The common use case of code smells assumes causality: Identify a smell, ...

Please sign up or login with your details

Forgot password? Click here to reset