• Home
  • Search
  • Cross-Language Code Smell Detection via Transfer Learning
  • Cite Icon1
  • https://doi.org/10.3390/app15179293Copy DOI Icon

Cross-Language Code Smell Detection via Transfer Learning

Show More
  • Abstract
  • Literature Map
  • References
  • Citations
  • Similar Papers
Abstract

Code smells are code structures that indicate a potential issue in code design or implementation. These issues could affect the processes of code testing and maintenance, and overall software quality. Therefore, it is important to detect code smells in the early stages of software development to enhance system quality. Most studies have focused on detecting code smells of a single programming language. This article explores TL for cross-language code smell detection, where Java is the source, and both C# and Python are the target datasets, focusing on Large Class, Long Method, and Long Parameter List code smells. We conducted a comparison study across two transfer learning approaches—instance-based (Importance Weighting Classifier, Nearest Neighbors Weighting, and Transfer AdaBoost) and parameter-based (Transfer Tree, Transfer Forest)—with various base models. The results showed that the instance-based approach outperformed the parameter-based approach, particularly with Transfer AdaBoost using ensemble learning base models. The Transfer AdaBoost approach with Gradient Boosting and Extra Trees achieved consistent and robust results across both C# and Python, with an 83% winning rate, as indicated by the Wilcoxon signed-rank test. These findings underscore the effectiveness of transfer learning for cross-language code smell detection, supporting its generalizability across different programming languages.

Similar Papers
  • Research Article

A Systematic Review on Code Smell Detection Approaches in Open Source Projects

  • Apr 21, 2026
  • Software: Practice and Experience
  • Sawsan Alodibat +1
  • Research Article
  • Citations89

Bad Smell Detection Using Machine Learning Techniques: A Systematic Literature Review

  • Jan 07, 2020
  • Arabian Journal for Science and Engineering
  • Ahmed Al-Shaaby +2
  • Conference Article
  • Citations6

Applying Machine Learning to Customized Smell Detection

  • Oct 21, 2020
  • Daniel Oliveira +5
  • Conference Article
  • Citations8

Towards the Definition of Patterns and Code Smells for Multi-language Systems

  • Jul 01, 2020
  • Mouna Abidi +1
  • PDF
  • Research Article
  • Citations1

From code to insight: studying code representation techniques for ML-based God class detection to support intelligent IDEs

  • Jul 25, 2025
  • Automated Software Engineering
  • Elmohanad Haroon +2
  • Research Article
  • Citations59

Are you smelling it? Investigating how similar developers detect code smells

  • Sep 06, 2017
  • Information and Software Technology
  • Mário Hozano +3
  • Research Article
  • Citations6

Unsupervised Machine Learning for Effective Code Smell Detection: A Novel Method

  • Jan 01, 2024
  • Journal of Communications Software and Systems
  • Ruchin Gupta +3
  • Research Article

Editorial for the special issue on software refactoring: Application breadth and technical depth

  • Sep 18, 2024
  • Journal of Software: Evolution and Process
  • Zhenchang Xing
  • Research Article

Optimizing LSTM for Code Smell Detection: The Role of Data Balancing

  • Jan 01, 2024
  • Infocommunications journal
  • Alnor Adam Khleel Nasraldeen +1
  • Conference Article
  • Citations15

Machine learning based code smell detection through WekaNose

  • May 27, 2018
  • Umberto Azadi +2
  • Research Article
  • Citations5

OCL을 이용한 자동화된 코드스멜 탐지와 리팩토링

  • Dec 31, 2008
  • The KIPS Transactions:PartD
  • Tae-Woong Kim +1
  • Research Article
  • Citations52

Monitor-Based Instant Software Refactoring

  • Aug 01, 2013
  • IEEE Transactions on Software Engineering
  • Hui Liu +2
  • Research Article
  • Citations8

Improving and comparing performance of machine learning classifiers optimized by swarm intelligent algorithms for code smell detection

  • May 15, 2024
  • Science of Computer Programming
  • Shivani Jain +1
  • PDF
  • Research Article
  • Citations13

The problem of conceptualization in god class detection: agreement, strategies and decision drivers

  • Sep 18, 2014
  • Journal of Software Engineering Research and Development
  • José Amancio M Santos +3
  • Conference Article

Towards Understanding the Distribution and Evolution of Code Smells: An Empirical Study on Java and Python Projects (S)

  • Oct 28, 2024
  • Proceedings/Proceedings of the ... International Conference on Software Engineering and Knowledge Engineering
  • Qing Mi +3
Cactus Communications logo

Copyright 2026 Cactus Communications. All rights reserved.