Network


Latest external collaboration on country level. Dive into details by clicking on the dots.

Hotspot


Dive into the research topics where Mohammad Ghafari is active.

Publication


Featured researches published by Mohammad Ghafari.


software visualization | 2016

Towards Actionable Visualisation in Software Development

Leonel Merino; Mohammad Ghafari; Oscar Nierstrasz

Although abundant studies have shown how visualisation can help software developers to perform their daily tasks, visualisation is still not a common practice since developers have little support for adopting a proper visualisation for their needs. In this paper we review the 346 papers published in SOFTVIS/VISSOFT venues and identify 65 design study papers that describe how visualisation is used to alleviate various difficulties in software development. We classify these studies into several problem domains that we collected from the research on software development community, and highlight the characteristics of each study. On the one hand, we support software developers to put visualisation in action by mapping existing techniques to particular needs in various problem domains. On the other hand, we help researchers in the field by exposing domains with little visualisation support. We found a disconnect between the problem domains on which visualisation have focused and the domains that get the most attention from practitioners.


Proceedings of the 11th edition of the International Workshop on Smalltalk Technologies | 2016

Inferring Types by Mining Class Usage Frequency from Inline Caches

Nevena Milojković; Clément Béra; Mohammad Ghafari; Oscar Nierstrasz

Dynamically typed languages allow developers to write more expressive source code, but their lack of static information about types of variables increases the complexity of a program. Static type information about types of variables facilitates program comprehension and maintenance. Simple type inference algorithms suffer from the problem of false positives or negatives, thus complex approaches are required to avoid this problem. We propose a simple heuristic that uses easily accessible run-time information about the usage of each class as a receiver type for a message send. This frequency serves as a proxy for the likelihood that a run-time type of the variable is that class and it is used to promote the correct type towards the top of the list of possible types for a variable. Our evaluation of a proof-of-concept prototype implemented in Pharo Smalltalk shows that our heuristic is reasonably precise to detect correct types on average in 65.92% to 82.83% of cases.


Journal of Software: Evolution and Process | 2017

Mining unit test cases to synthesize API usage examples.

Mohammad Ghafari; Konstantin Rubinov; Mohammad Mehdi Pourhashem Kallehbasti

Software developers study and reuse existing source code to understand how to properly use application programming interfaces (APIs). However, manually finding sufficient and adequate code examples for a given API is a difficult and a time‐consuming activity. Existing approaches to find or generate examples assume availability of a reasonable set of client code that uses the API. This assumption does not hold for newly released API libraries, non‐widely used APIs, nor private ones.


2017 IEEE Workshop on Machine Learning Techniques for Software Quality Evaluation (MaLTeSQuE) | 2017

Hyperparameter optimization to improve bug prediction accuracy

Haidar Osman; Mohammad Ghafari; Oscar Nierstrasz

Bug prediction is a technique that strives to identify where defects will appear in a software system. Bug prediction employs machine learning to predict defects in software entities based on software metrics. These machine learning models usually have adjustable parameters, called hyperparameters, that need to be tuned for the prediction problem at hand. However, most studies in the literature keep the model hyperparameters set to the default values provided by the used machine learning frameworks. In this paper we investigate whether optimizing the hyperparameters of a machine learning model improves its prediction power. We study two machine learning algorithms: k-nearest neighbours (IBK) and support vector machines (SVM). We carry out experiments on five open source Java systems. Our results show that (i) models differ in their sensitivity to their hyperparameters, (ii) tuning hyperparameters gives at least as accurate models for SVM and significantly more accurate models for IBK, and (iii) most of the default values are changed during the tuning phase. Based on these findings we recommend tuning hyperparameters as a necessary step before using a machine learning model in bug prediction.


2017 IEEE Workshop on Machine Learning Techniques for Software Quality Evaluation (MaLTeSQuE) | 2017

Automatic feature selection by regularization to improve bug prediction accuracy

Haidar Osman; Mohammad Ghafari; Oscar Nierstrasz

Bug prediction has been a hot research topic for the past two decades, during which different machine learning models based on a variety of software metrics have been proposed. Feature selection is a technique that removes noisy and redundant features to improve the accuracy and generalizability of a prediction model. Although feature selection is important, it adds yet another step to the process of building a bug prediction model and increases its complexity. Recent advances in machine learning introduce embedded feature selection methods that allow a prediction model to carry out feature selection automatically as part of the training process. The effect of these methods on bug prediction is unknown. In this paper we study regularization as an embedded feature selection method in bug prediction models. Specifically, we study the impact of three regularization methods (Ridge, Lasso, and ElasticNet) on linear and Poisson Regression as bug predictors for five open source Java systems. Our results show that the three regularization methods reduce the prediction error of the regressors and improve their stability.


software visualization | 2016

MetaVis: Exploring Actionable Visualization

Leonel Merino; Mohammad Ghafari; Oscar Nierstrasz; Alexandre Bergel; Juraj Kubelka

Software visualization can be very useful for answering complex questions that arise in the software development process. Although modern visualization engines offer expressive APIs for building such visualizations, developers often have difficulties to (1) identify a suitable visualization technique to answer their particular development question, and to (2) implement that visualization using the existing APIs. Examples that illustrate the usage of an engine to build concrete visualizations offer a good starting point, but developers may have to traverse long lists of categories and analyze examples one-by-one to find a suitable one. We propose MetaVis, a tool that fills the gap between existing visualization techniques and their practical applications during software development. We classify questions frequently formulated by software developers and for each, based on our expertise, identify suitable visualizations. MetaVis uses tags mined from these questions to offer a tag-iconic cloud-based visualization. Each tag links to suitable visualizations that developers can explore, modify and try out. We present initial results of an implementation of MetaVis in the Pharo programming environment. The tool visualizes 76 developers questions assigned to 49 visualization examples.


software visualization | 2016

Walls, Pillars and Beams: A 3D Decomposition of Quality Anomalies

Yuriy Tymchuk; Leonel Merino; Mohammad Ghafari; Oscar Nierstrasz

Quality rules are used to capture important implementation and design decisions embedded in a software systems architecture. They can automatically analyze software and assign quality grades to its components. To provide a meaningful evaluation of quality, rules have to stay up-to-date with the continuously evolving system that they describe. However one would encounter unexpected anomalies during a historical overview because the notion of quality is always changing, while the qualitative evolution analysis requires it to remain constant. To understand the anomalies in a quality history of a real-world software system we use an immersive visualization that lays out the quality fluctuations in three dimensions based on two co-evolving properties: quality rules and source code. This helps us to identify and separate the impact caused by the changes of each property, and allows us to detect significant mistakes that happened during the development process.


mining software repositories | 2017

Exception evolution in long-lived Java systems

Haidar Osman; Andrei Chiş; Claudio Corrodi; Mohammad Ghafari; Oscar Nierstrasz

Exception handling allows developers to deal with abnormal situations that disrupt the execution flow of a program. There are mainly three types of exceptions: standard exceptions provided by the programming language itself, custom exceptions defined by the project developers, and third-party exceptions defined in external libraries. We conjecture that there are multiple factors that affect the use of these exception types. We perform an empirical study on long-lived Java projects to investigate these factors. In particular, we analyze how developers rely on the different types of exceptions in throw statements and exception handlers. We confirm that the domain, the type, and the development phase of a project affect the exception handling patterns. We observe that applications have significantly more error handling code than libraries and they increasingly rely on custom exceptions. Also, projects that belong to different domains have different preferences of exception types. For instance, content management systems rely more on custom exceptions than standard exceptions whereas the opposite is true in parsing frameworks.


Proceedings of the 11th edition of the International Workshop on Smalltalk Technologies | 2016

CommunityExplorer: A Framework for Visualizing Collaboration Networks

Leonel Merino; Dominik Seliner; Mohammad Ghafari; Oscar Nierstrasz

Understanding the network of collaborations, identifying the key players, potential future collaborators, and trends in the field are very important to carry out a project successfully. In this paper, we present CommunityExplorer, a visualization framework that facilitates presenting, exploring, and understanding the network of collaborations at once. The framework performs data extraction, parsing, and modeling automatically. It is easy to adopt and utilizes a bigraph visualization that scales well.We demonstrate the advantage of CommunityExplorer to identify the collaboration of authors on 346 and 104 research papers published in SOTFVIS/VISSOFT and IWST communities respectively. We found that even though SOFTVIS/VISSOFT has more contributors, IWST exhibits more collaboration.We discovered that contributors in IWST are more resilient than those in SOFTVIS/VISSOFT, which are more volatile. Moreover, collaboration in IWST is concentrated in a single large group, while in SOFTVIS/VISSOFT it is spread among many tiny groups and a few medium-sized ones.


Proceedings of the 11th edition of the International Workshop on Smalltalk Technologies | 2016

The Object Repository: Pulling Objects out of the Ecosystem

Boris Spasojevic; Mohammad Ghafari; Oscar Nierstrasz

In this paper we propose the idea of constructing an Object Repository -- a repository of code snippets that, when executed, produce an instance of some class. Such a repository may be useful for several software engineering tasks like augmenting software documentation, testing object inspectors, improving program comprehension etc. We mine code snippets from existing software systems via brute force execution of code segments obtained through converting AST nodes of methods to source code. The gathered snippets are known to be executable, and this is a novelty which is not possible with existing approaches. We show that applying the proposed approach to 141 open source Pharo projects results in an Object Repository that can instantiate almost 80% of the available classes in these projects.

Collaboration


Dive into the Mohammad Ghafari's collaboration.

Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar

Mircea Lungu

University of Groningen

View shared research outputs
Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar
Top Co-Authors

Avatar
Researchain Logo
Decentralizing Knowledge