Reusing Deep Neural Network Models through Model Re-engineering
Binhang Qi, Hailong Sun, Xiang Gao, Hongyu Zhang, Zhaotian Li, Xudong Liu
Abstract
Training deep neural network (DNN) models, which has become an important task in today's software development, is often costly in terms of computational resources and time. With the inspiration of software reuse, building DNN models through reusing existing ones has gained increasing attention recently. Prior approaches to DNN model reuse have two main limitations: 1) reusing the entire model, while only a small part of the model's functionalities (labels) are required, would cause much overhead (e.g., computational and time costs for inference), and 2) model reuse would inherit the defects and weaknesses of the reused model, and hence put the new system under threats of security attack. To solve the above problem, we propose SeaM, a tool that re-engineers a trained DNN model to improve its reusability. Specifically, given a target problem and a trained model, SeaM utilizes a gradient-based search method to search for the model's weights that are relevant to the target problem. The re-engineered model that only retains the relevant weights is then reused to solve the target problem. Evaluation results on widely-used models show that the re-engineered models produced by SeaM only contain 10.11% weights of the original models, resulting 42.41% reduction in terms of inference time. For the target problem, the re-engineered models even outperform the original models in classification accuracy by 5.85%. Moreover, reusing the re-engineered models inherits an average of 57% fewer defects than reusing the entire model. We believe our approach to reducing reuse overhead and defect inheritance is one important step forward for practical model reuse.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext f9518784-c880-48ae-a69d-31792e36829aCited by top-tier papers5
- FracFace: Breaking the Visual Clues - Fractal-Based Privacy-Preserving Face RecognitionWanying Dai, Beibei Li, Naipeng Dong, Guangdong Bai et al.NeurIPS 2025 · 7 citations
- Modularizing while Training: A New Paradigm for Modularizing DNN ModelsBinhang Qi, Hailong Sun, Hongyu Zhang, Ruobing Zhao et al.ICSE 2024 · 3 citations
- DNN Modularization via Activation-Driven TrainingTuan Ngo, Abid Hassan, Saad Shafiq, Nenad MedvidovićICSE 2026 · 2 citations
- Speculative Automated Refactoring of Imperative Deep Learning Programs to Graph ExecutionRaffi Khatchadourian, Tatiana Castro Vélez, Mehdi Bagherzadeh, Nan Jia et al.ASE 2025 · 1 citation
- BDefects4NN: A Backdoor Defect Database for Controlled Localization Studies in Neural NetworksYisong Xiao, Aishan Liu, Xinwei Zhang, Tianyuan Zhang et al.ICSE 2025
Builds on13
- Model-Reuse Attacks on Deep Learning SystemsYujie Ji, Xinyang Zhang, Shouling Ji, Xiapu Luo et al.CCS 2018 · 197 citations
- Is neuron coverage a meaningful measure for testing deep neural networks?Fabrice Harel-Canada, Lingxiao Wang, Muhammad Ali Gulzar, Quanquan Gu et al.FSE 2020 · 149 citations
- With Great Training Comes Great Vulnerability: Practical Attacks against Transfer LearningBolun Wang, Yuanshun Yao, Bimal Viswanath, Haitao Zheng et al.USENIX Security 2018 · 126 citations
- A Target-Agnostic Attack on Deep Models: Exploiting Security Vulnerabilities of Transfer LearningShahbaz Rezaei, Xin LiuICLR 2020 · 49 citations
- On the Predictability of Pruning Across ScalesJonathan S. Rosenfeld, Jonathan Frankle, Michael Carbin, Nir ShavitICML 2021 · 47 citations
Related papers
- An Empirical Study of Pre-Trained Model Reuse in the Hugging Face Deep Learning Model RegistryWenxin Jiang, Nicholas Synovic, Matt Hyatt, Taylor R. Schorlemmer et al.ICSE 2023 · 62 citations
- ReMoS: Reducing Defect Inheritance in Transfer Learning via Relevant Model SlicingZiqi Zhang, Yuanchun Li, Jindong Wang, Bingyan Liu et al.ICSE 2022 · 28 citations
- Selective Amnesia: On Efficient, High-Fidelity and Blind Suppression of Backdoor Effects in Trojaned Machine Learning ModelsRui Zhu, Di Tang, Siyuan Tang, Xiaofeng Wang et al.S&P 2023
- On decomposing a deep neural network into modulesRangeet Pan, Hridesh RajanFSE 2020 · 38 citations
- Model LEGO: Creating Models Like Disassembling and Assembling Building BlocksJiacong Hu, Jing Gao, Jingwen Ye, Yang Gao et al.NeurIPS 2024 · 1 citation
